From 8fe46d1f9a83752a2f8483c536a00916f49b90b1 Mon Sep 17 00:00:00 2001 From: Berkeley Martinez Date: Mon, 8 Jan 2018 11:59:13 -0800 Subject: [PATCH] feat(App): Make full size --- client/less/main.less | 5 +++++ common/app/app.less | 4 ++++ server/views/layout-react.jade | 6 +++--- 3 files changed, 12 insertions(+), 3 deletions(-) diff --git a/client/less/main.less b/client/less/main.less index 4a337d20b6..814a479b8a 100644 --- a/client/less/main.less +++ b/client/less/main.less @@ -985,6 +985,11 @@ and (max-width : 400px) { } } +.full-size { + height: 100%; + width: 100%; +} + // surrounding downstream import with &{} // creates locally scoped imports // and prevents vaiables from overwriting each other diff --git a/common/app/app.less b/common/app/app.less index 100910c75f..88d45ba25e 100644 --- a/common/app/app.less +++ b/common/app/app.less @@ -8,12 +8,16 @@ // they are painted using css so the // nav is on top again .grid(@direction: column); + height: 100%; + width: 100%; } .@{ns}-content { // makes the inital content height 0px // then lets it grow to fit the rest of the space flex: 1 0 0px; + // allow content to adapt to screen size + display: flex; } .@{ns}-centered { diff --git a/server/views/layout-react.jade b/server/views/layout-react.jade index 535701fc2c..1140a9760d 100644 --- a/server/views/layout-react.jade +++ b/server/views/layout-react.jade @@ -1,13 +1,13 @@ doctype html -html(lang='en') +html(lang='en').full-size head if title title= title else title freeCodeCamp include partials/react-stylesheets - body - #fcc!= markup + body.full-size + #fcc.full-size!= markup script!= state script. window.webpackManifest = !{JSON.stringify(chunkManifest || {})};