chore: move screens into routes folder
This commit is contained in:
@@ -48,6 +48,7 @@ module.exports = {
|
|||||||
aliases: {
|
aliases: {
|
||||||
components: "./components",
|
components: "./components",
|
||||||
img: "./img",
|
img: "./img",
|
||||||
|
routes: "./routes",
|
||||||
styles: "./styles",
|
styles: "./styles",
|
||||||
utils: "./utils",
|
utils: "./utils",
|
||||||
},
|
},
|
||||||
|
|||||||
12
src/App.js
12
src/App.js
@@ -8,12 +8,12 @@ import { SIZES } from "./styles/constants"
|
|||||||
|
|
||||||
import theme from "./styles/theme"
|
import theme from "./styles/theme"
|
||||||
import Navbar from "./components/Navbar"
|
import Navbar from "./components/Navbar"
|
||||||
import Day from "./components/screens/Day"
|
import Day from "routes/Day"
|
||||||
import Month from "./components/screens/Month"
|
import Month from "routes/Month"
|
||||||
import Year from "./components/screens/Year"
|
import Year from "routes/Year"
|
||||||
import User from "./components/screens/User"
|
import User from "routes/User"
|
||||||
import Search from "./components/screens/Search"
|
import Search from "routes/Search"
|
||||||
import Welcome from "./components/screens/Welcome"
|
import Welcome from "routes/Welcome"
|
||||||
import PrivateRoute from "./components/PrivateRoute"
|
import PrivateRoute from "./components/PrivateRoute"
|
||||||
|
|
||||||
import { OnlineContext } from "./components/context/online"
|
import { OnlineContext } from "./components/context/online"
|
||||||
|
|||||||
@@ -3,7 +3,7 @@ import { Helmet } from "react-helmet"
|
|||||||
import { Global, css } from "@emotion/core"
|
import { Global, css } from "@emotion/core"
|
||||||
import styled from "@emotion/styled"
|
import styled from "@emotion/styled"
|
||||||
|
|
||||||
import { SimpleNavbar } from "../Navbar"
|
import { SimpleNavbar } from "components/Navbar"
|
||||||
import { withTheme } from "emotion-theming"
|
import { withTheme } from "emotion-theming"
|
||||||
|
|
||||||
const Layout = ({ children, theme }) => (
|
const Layout = ({ children, theme }) => (
|
||||||
|
|||||||
@@ -2,9 +2,9 @@ import React from "react"
|
|||||||
import { compose } from "recompose"
|
import { compose } from "recompose"
|
||||||
import { withTheme } from "emotion-theming"
|
import { withTheme } from "emotion-theming"
|
||||||
|
|
||||||
import { Button } from "../elements"
|
import { Button } from "components/elements"
|
||||||
|
|
||||||
import { withFirebase } from "../firebase"
|
import { withFirebase } from "components/firebase"
|
||||||
|
|
||||||
const SignOutButton = ({ firebase, theme }) => (
|
const SignOutButton = ({ firebase, theme }) => (
|
||||||
<Button
|
<Button
|
||||||
|
|||||||
@@ -1,2 +0,0 @@
|
|||||||
import Day from "./Day"
|
|
||||||
export default Day
|
|
||||||
@@ -1,2 +0,0 @@
|
|||||||
import Month from "./Month"
|
|
||||||
export default Month
|
|
||||||
@@ -1,2 +0,0 @@
|
|||||||
import Search from "./Search"
|
|
||||||
export default Search
|
|
||||||
@@ -1,2 +0,0 @@
|
|||||||
import Start from "./Start"
|
|
||||||
export default Start
|
|
||||||
@@ -1,2 +0,0 @@
|
|||||||
import User from "./User"
|
|
||||||
export default User
|
|
||||||
@@ -1,2 +0,0 @@
|
|||||||
import Welcome from "./Welcome"
|
|
||||||
export default Welcome
|
|
||||||
@@ -1,2 +0,0 @@
|
|||||||
import Year from "./Year"
|
|
||||||
export default Year
|
|
||||||
@@ -1,7 +1,7 @@
|
|||||||
import React from "react"
|
import React from "react"
|
||||||
|
|
||||||
import AuthUserContext from "./context"
|
import AuthUserContext from "./context"
|
||||||
import { withFirebase } from "../firebase"
|
import { withFirebase } from "components/firebase"
|
||||||
|
|
||||||
const withAuthentication = Component => {
|
const withAuthentication = Component => {
|
||||||
class WithAuthentication extends React.Component {
|
class WithAuthentication extends React.Component {
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
import React from "react"
|
import React from "react"
|
||||||
import { SimpleNavbar } from "components/Navbar"
|
import { SimpleNavbar } from "components/Navbar"
|
||||||
import Index from "components/screens/Start/index"
|
import Index from "routes/Start"
|
||||||
import Layout from "components/Layout"
|
import Layout from "components/Layout"
|
||||||
import Container from "components/container"
|
import Container from "components/container"
|
||||||
|
|
||||||
|
|||||||
@@ -1,5 +1,4 @@
|
|||||||
import React, { Component } from "react"
|
import React, { Component } from "react"
|
||||||
import { AppLink as Link } from "components/elements"
|
|
||||||
import styled from "@emotion/styled"
|
import styled from "@emotion/styled"
|
||||||
import {
|
import {
|
||||||
isAfter,
|
isAfter,
|
||||||
@@ -12,7 +11,8 @@ import {
|
|||||||
startOfMonth,
|
startOfMonth,
|
||||||
} from "date-fns"
|
} from "date-fns"
|
||||||
|
|
||||||
import Seek from "../../Seek"
|
import { AppLink as Link } from "components/elements"
|
||||||
|
import Seek from "components/Seek"
|
||||||
|
|
||||||
const YearCardGrid = styled.div`
|
const YearCardGrid = styled.div`
|
||||||
display: grid;
|
display: grid;
|
||||||
@@ -7,8 +7,8 @@ import { withTheme } from "emotion-theming"
|
|||||||
import { SIZES } from "styles/constants"
|
import { SIZES } from "styles/constants"
|
||||||
import { Button, P } from "components/elements"
|
import { Button, P } from "components/elements"
|
||||||
import { todayUrl } from "utils/date"
|
import { todayUrl } from "utils/date"
|
||||||
import Icon from "component/Icon"
|
import Icon from "components/Icon"
|
||||||
import Logo from "component/Logo"
|
import Logo from "components/Logo"
|
||||||
|
|
||||||
const StartGrid = styled.div`
|
const StartGrid = styled.div`
|
||||||
margin-top: 30px;
|
margin-top: 30px;
|
||||||
@@ -5,12 +5,11 @@ import { compose } from "recompose"
|
|||||||
import { format } from "date-fns"
|
import { format } from "date-fns"
|
||||||
import { BeatLoader } from "react-spinners"
|
import { BeatLoader } from "react-spinners"
|
||||||
|
|
||||||
|
import { SIZES } from "styles/constants"
|
||||||
import { withFirebase } from "components/firebase"
|
import { withFirebase } from "components/firebase"
|
||||||
import { withAuthentication } from "components/session"
|
import { withAuthentication } from "components/session"
|
||||||
import { SIZES } from "styles/constants"
|
import SignOut from "components/SignOut"
|
||||||
|
import { Button } from "components/elements"
|
||||||
import SignOut from "../../SignOut"
|
|
||||||
import { Button } from "../../elements"
|
|
||||||
|
|
||||||
const ProfileGrid = styled.div`
|
const ProfileGrid = styled.div`
|
||||||
display: grid;
|
display: grid;
|
||||||
@@ -1,11 +1,11 @@
|
|||||||
import React, { Component } from "react"
|
import React, { Component } from "react"
|
||||||
import { AppLink as Link } from "components/elements"
|
|
||||||
import styled from "@emotion/styled"
|
|
||||||
import { addYears, subYears, format, isThisYear, getMonth } from "date-fns"
|
import { addYears, subYears, format, isThisYear, getMonth } from "date-fns"
|
||||||
|
import styled from "@emotion/styled"
|
||||||
import { withTheme } from "emotion-theming"
|
import { withTheme } from "emotion-theming"
|
||||||
|
|
||||||
|
import { AppLink as Link } from "components/elements"
|
||||||
|
import Seek from "components/Seek"
|
||||||
import { months } from "utils/date"
|
import { months } from "utils/date"
|
||||||
import Seek from "../../Seek"
|
|
||||||
|
|
||||||
const MonthCardGrid = styled.div`
|
const MonthCardGrid = styled.div`
|
||||||
display: grid;
|
display: grid;
|
||||||
Reference in New Issue
Block a user