Layout changes
This commit is contained in:
@ -36,13 +36,13 @@ class Layout extends React.Component {
|
||||
|
||||
@keydown(['/', 't'])
|
||||
search() {
|
||||
// if (!this.props.search) return;
|
||||
if (!this.props.user) return;
|
||||
_.defer(() => browserHistory.push('/search'));
|
||||
}
|
||||
|
||||
@keydown(['d'])
|
||||
dashboard() {
|
||||
// if (!this.props.search) return;
|
||||
if (!this.props.user) return;
|
||||
_.defer(() => browserHistory.push('/'));
|
||||
}
|
||||
|
||||
@ -75,11 +75,12 @@ class Layout extends React.Component {
|
||||
</span>
|
||||
</div>
|
||||
<Flex className={ styles.headerRight }>
|
||||
{ user.user && (
|
||||
<Flex>
|
||||
<Flex align="center" className={ styles.actions }>
|
||||
{ this.props.actions }
|
||||
</Flex>
|
||||
{ user.user && (
|
||||
<Flex>
|
||||
{ this.props.search && (
|
||||
<Flex>
|
||||
<div
|
||||
@ -104,6 +105,7 @@ class Layout extends React.Component {
|
||||
</Flex>
|
||||
) }
|
||||
</Flex>
|
||||
</Flex>
|
||||
</div>
|
||||
|
||||
<div
|
||||
|
@ -2,6 +2,9 @@ import React from 'react';
|
||||
import { observer } from 'mobx-react';
|
||||
import { browserHistory } from 'react-router'
|
||||
|
||||
import { Flex } from 'reflexbox';
|
||||
import Layout from 'components/Layout';
|
||||
import CenteredContent from 'components/CenteredContent';
|
||||
import SlackAuthLink from 'components/SlackAuthLink';
|
||||
|
||||
import styles from './Home.scss';
|
||||
@ -20,8 +23,9 @@ export default class Home extends React.Component {
|
||||
|
||||
render() {
|
||||
return (
|
||||
<div className={ styles.container }>
|
||||
<div className={ styles.content }>
|
||||
<Flex auto>
|
||||
<Layout>
|
||||
<CenteredContent>
|
||||
<div className={ styles.intro }>
|
||||
<h1>Atlas</h1>
|
||||
<p>Simple, fast, markdown.</p>
|
||||
@ -38,8 +42,9 @@ export default class Home extends React.Component {
|
||||
/>
|
||||
</SlackAuthLink>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</CenteredContent>
|
||||
</Layout>
|
||||
</Flex>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user