about summary refs log tree commit diff
path: root/app/assets/javascripts/components/features/ui/index.jsx
blob: 0bc235b5344b4423bb0b6074fbbad1376522db33 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
import ColumnsArea            from './components/columns_area';
import Column                 from './components/column';
import Drawer                 from './components/drawer';
import ComposeFormContainer   from './containers/compose_form_container';
import FollowFormContainer    from './containers/follow_form_container';
import UploadFormContainer    from './containers/upload_form_container';
import StatusListContainer    from './containers/status_list_container';
import NotificationsContainer from './containers/notifications_container';
import NavigationContainer    from './containers/navigation_container';
import PureRenderMixin        from 'react-addons-pure-render-mixin';
import LoadingBarContainer    from './containers/loading_bar_container';

const UI = React.createClass({

  propTypes: {
    router: React.PropTypes.object
  },

  mixins: [PureRenderMixin],

  render () {
    return (
      <div style={{ flex: '0 0 auto', display: 'flex', width: '100%', height: '100%', background: '#1a1c23' }}>
        <Drawer>
          <div style={{ flex: '1 1 auto' }}>
            <NavigationContainer />
            <ComposeFormContainer />
            <UploadFormContainer />
          </div>

          <FollowFormContainer />
        </Drawer>

        <ColumnsArea>
          <Column icon='home' heading='Home'>
            <StatusListContainer type='home' />
          </Column>

          <Column icon='at' heading='Mentions'>
            <StatusListContainer type='mentions' />
          </Column>

          {this.props.children}
        </ColumnsArea>

        <NotificationsContainer />
        <LoadingBarContainer style={{ backgroundColor: '#2b90d9', left: '0', top: '0' }} />
      </div>
    );
  }

});

export default UI;