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