bigbluebutton-Github/bigbluebutton-html5/imports/ui/components/polling/component.jsx
2016-05-13 09:39:10 -05:00

21 lines
546 B
JavaScript
Executable File

import React from 'react';
import {Button} from '../shared/Button.jsx';
export default class PollingComponent extends React.Component {
render() {
const poll = this.props.poll;
return (
<div>
{poll.answers.map((pollAnswer, index) => {
return (
<Button className="button mediumFont" key={index}
onClick={() => this.props.handleVote(poll.pollId, pollAnswer)} componentClass="span">
{pollAnswer.key}
</Button>
);
})}
</div>
);
}
};