2016-08-25 00:56:44 +09:00
|
|
|
import StatusListContainer from '../containers/status_list_container';
|
|
|
|
import ColumnHeader from './column_header';
|
2016-08-31 23:15:12 +09:00
|
|
|
import PureRenderMixin from 'react-addons-pure-render-mixin';
|
2016-08-25 00:56:44 +09:00
|
|
|
|
|
|
|
const Column = React.createClass({
|
2016-08-31 23:15:12 +09:00
|
|
|
|
2016-08-25 00:56:44 +09:00
|
|
|
propTypes: {
|
2016-09-06 07:44:28 +09:00
|
|
|
type: React.PropTypes.string,
|
|
|
|
icon: React.PropTypes.string
|
2016-08-25 00:56:44 +09:00
|
|
|
},
|
|
|
|
|
2016-08-31 23:15:12 +09:00
|
|
|
mixins: [PureRenderMixin],
|
|
|
|
|
2016-09-06 07:44:28 +09:00
|
|
|
handleHeaderClick () {
|
|
|
|
let node = ReactDOM.findDOMNode(this);
|
|
|
|
node.querySelector('.scrollable').scrollTo(0, 0);
|
|
|
|
},
|
|
|
|
|
2016-08-31 23:15:12 +09:00
|
|
|
render () {
|
2016-08-25 00:56:44 +09:00
|
|
|
return (
|
2016-08-26 02:52:55 +09:00
|
|
|
<div style={{ width: '380px', flex: '0 0 auto', background: '#282c37', margin: '10px', marginRight: '0', display: 'flex', flexDirection: 'column' }}>
|
2016-09-06 07:44:28 +09:00
|
|
|
<ColumnHeader icon={this.props.icon} type={this.props.type} onClick={this.handleHeaderClick} />
|
2016-08-25 00:56:44 +09:00
|
|
|
<StatusListContainer type={this.props.type} />
|
|
|
|
</div>
|
|
|
|
);
|
|
|
|
}
|
2016-08-31 23:15:12 +09:00
|
|
|
|
2016-08-25 00:56:44 +09:00
|
|
|
});
|
|
|
|
|
|
|
|
export default Column;
|