Sha256: 2a5435986bec066ef29ffdfa457bdfe1a9b9cafd0220ca1b226277e3deb118af
Contents?: true
Size: 617 Bytes
Versions: 2
Compression:
Stored size: 617 Bytes
Contents
import { PropTypes } from 'react'; import Icon from '../application/icon.component'; const VoteButton = ({ buttonClassName, iconName, votes, voteAction, disabled }) => ( <button className={buttonClassName} onClick={() => voteAction()} disabled={disabled}> <Icon name={iconName} iconExtraClassName="icon--small" /> { ` ${votes}` } </button> ); VoteButton.propTypes = { buttonClassName: PropTypes.string.isRequired, iconName: PropTypes.string.isRequired, votes: PropTypes.number.isRequired, voteAction: PropTypes.func.isRequired, disabled: PropTypes.bool }; export default VoteButton;
Version data entries
2 entries across 2 versions & 2 rubygems
Version | Path |
---|---|
decidim-comments-0.0.2 | app/frontend/comments/vote_button.component.jsx |
decidim-0.0.2 | decidim-comments/app/frontend/comments/vote_button.component.jsx |