chore: home screen

This commit is contained in:
Kyle Gill
2019-04-08 09:08:00 -06:00
parent e8a8f41d81
commit 37b633ea82
11 changed files with 3676 additions and 1 deletions

View File

@@ -14,6 +14,7 @@ import Year from "./components/screens/Year"
import User from "./components/screens/User"
import Login from "./components/screens/Login"
import Register from "./components/screens/Register"
import Start from "./components/screens/Start"
import PrivateRoute from "./components/PrivateRoute"
import { withAuthentication } from "./components/session"
@@ -95,6 +96,7 @@ class App extends Component {
<Route path="/user" component={User} exact />
<Route path="/login" component={Login} exact />
<Route path="/register" component={Register} exact />
<Route path="/" component={Start} exact />
</RouteLayout>
</Router>
</ThemeProvider>

View File

@@ -1,11 +1,11 @@
import React from "react"
import styled from "@emotion/styled"
import { withTheme } from "emotion-theming"
import { Link } from "react-router-dom"
import { SIZES } from "../../styles/constants"
import Icon from "../Icon"
import { H1 } from "../elements"
import { StyledLink as Link } from "../elements"
const SeekHeader = styled.header`
display: flex;

View File

@@ -0,0 +1,38 @@
import React, { Component } from "react"
import { Link } from "react-router-dom"
import styled from "@emotion/styled"
import { withTheme } from "emotion-theming"
import { Button } from "../../elements"
import { todayUrl } from "../../../utils/date"
const StartGrid = styled.div`
margin: 0 auto;
text-align: center;
margin-top: 30px;
max-width: 350px;
line-height: 1.5;
color: ${props => props.theme.colors.secondary};
height: 100%;
`
class Start extends Component {
render() {
const { theme } = this.props
return (
<StartGrid>
<div style={{ margin: 10 }}>
Use your journal as a place to record thoughts and events from the
day. Your journal works offline and from any device. You can add it to
your homescreen for faster access and write from a mobile device or
type up your entries from your computer.
</div>
<Link to={todayUrl()} style={{ textDecoration: "none" }}>
<Button colors={theme.colors}>Begin Writing</Button>
</Link>
</StartGrid>
)
}
}
export default withTheme(Start)

View File

@@ -0,0 +1,2 @@
import Start from "./Start"
export default Start