mirror of
https://github.com/ascribe/onion.git
synced 2024-06-30 21:52:08 +02:00
24 lines
668 B
JavaScript
24 lines
668 B
JavaScript
'use strict';
|
|
|
|
import React from 'react';
|
|
|
|
let AccordionListItemTableToggle = React.createClass({
|
|
propTypes: {
|
|
className: React.PropTypes.string,
|
|
onClick: React.PropTypes.func,
|
|
show: React.PropTypes.bool,
|
|
numOfTableItems: React.PropTypes.number
|
|
},
|
|
|
|
render() {
|
|
return (
|
|
<span
|
|
className={this.props.className}
|
|
onClick={this.props.onClick}>
|
|
{this.props.show ? 'Hide all ' + this.props.numOfTableItems + ' Editions' : 'Show all ' + this.props.numOfTableItems + ' Editions'}
|
|
</span>
|
|
);
|
|
}
|
|
});
|
|
|
|
export default AccordionListItemTableToggle; |