gab-social/app/javascript/gabsocial/components/columns_area/columns_area.js
mgabdev 3d509c84a2 Another large update for all components
reorganization, linting, updating file imports, consolidation
warning: there will be errors in this commit
todo: update webpack, add missing styles, scss files, consolidate group page components.
2019-08-09 12:06:27 -04:00

45 lines
1.1 KiB
JavaScript

import './columns_area.scss';
export default class ColumnsArea extends PureComponent {
static propTypes = {
children: PropTypes.node,
layout: PropTypes.object,
};
render () {
const { children } = this.props;
const layout = this.props.layout || {LEFT:null,RIGHT:null};
console.log("layout:", layout);
return (
<div className='page'>
<div className='page__columns'>
<div className='columns-area__panels'>
<div className='columns-area__panels__pane columns-area__panels__pane--left'>
<div className='columns-area__panels__pane__inner'>
{layout.LEFT}
</div>
</div>
<div className='columns-area__panels__main'>
<div className='columns-area columns-area--mobile'>
{children}
</div>
</div>
<div className='columns-area__panels__pane columns-area__panels__pane--right'>
<div className='columns-area__panels__pane__inner'>
{layout.RIGHT}
</div>
</div>
</div>
</div>
</div>
)
}
}