From 6658bc9825c3209e96aef726d4c0377cf18758f6 Mon Sep 17 00:00:00 2001 From: George Lima Date: Mon, 10 Dec 2018 21:11:19 -0300 Subject: [PATCH] hotfix: remove layout absolute position --- app/components/layout.js | 7 +------ app/components/sidebar.js | 3 --- app/router/router.js | 13 ++++++++++--- 3 files changed, 11 insertions(+), 12 deletions(-) diff --git a/app/components/layout.js b/app/components/layout.js index ed67ae4..da7f568 100644 --- a/app/components/layout.js +++ b/app/components/layout.js @@ -4,12 +4,7 @@ import React from 'react'; import styled from 'styled-components'; const Layout = styled.div` - display: flex; - flex-direction: column; - position: absolute; - width: calc(100vw - 200px); - left: 200px; - top: 0; + width: 100%; height: 100vh; background: ${props => props.theme.colors.secondary}; `; diff --git a/app/components/sidebar.js b/app/components/sidebar.js index 9307af1..2dc953f 100644 --- a/app/components/sidebar.js +++ b/app/components/sidebar.js @@ -9,9 +9,6 @@ const Wrapper = styled.div` display: flex; flex-direction: column; width: 200px; - position: absolute; - left: 0; - top: 0; height: 100vh; font-family: ${props => props.theme.fontFamily} background-color: ${props => props.theme.colors.sidebarBg}; diff --git a/app/router/router.js b/app/router/router.js index eed4172..626c179 100644 --- a/app/router/router.js +++ b/app/router/router.js @@ -1,7 +1,8 @@ // @flow -import React, { Fragment } from 'react'; +import React from 'react'; import { Route, Switch } from 'react-router-dom'; +import styled from 'styled-components'; import { ScrollTopComponent } from './scroll-top'; import { SidebarContainer } from '../containers/sidebar'; @@ -17,8 +18,14 @@ import { DASHBOARD_ROUTE, SEND_ROUTE, RECEIVE_ROUTE, SETTINGS_ROUTE, CONSOLE_ROUTE, } from '../constants/routes'; +const Wrapper = styled.div` + display: flex; + flex-direction: row; + width: 100vw; +`; + export const RouterComponent = () => ( - + {/* $FlowFixMe */} @@ -33,5 +40,5 @@ export const RouterComponent = () => ( - + );