bigbluebutton-Github/bigbluebutton-html5/imports/ui/components/polling/component.jsx
2016-05-20 10:37:19 -03:00

21 lines
547 B
JavaScript
Executable File

import React from 'react';
import Button from '../button/component.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>
);
}
};