From 131f93927c3d033221fc05e4944c130edcad7ce1 Mon Sep 17 00:00:00 2001 From: Georg Hopp Date: Sat, 17 Sep 2016 02:18:44 +0200 Subject: [PATCH] Make teaser sections always 100% viewport size and content sections variable length --- app/assets/stylesheets/welcome.scss | 35 +++++------- app/views/layouts/application.html.erb | 78 +++++++++++++------------- 2 files changed, 52 insertions(+), 61 deletions(-) diff --git a/app/assets/stylesheets/welcome.scss b/app/assets/stylesheets/welcome.scss index 2043e27..6ec8721 100644 --- a/app/assets/stylesheets/welcome.scss +++ b/app/assets/stylesheets/welcome.scss @@ -116,26 +116,29 @@ p { border-bottom: 2px solid rgb(255,255,255); } -#content { - position: absolute; - top: 0px; - left: 0px; - width: 100%; - height: 100%; -} #section1 .content, #section3 .content, #section5 .content { color: rgb(214,206,204); } #section2, #section4, #section6 { background-color: rgb(255,255,255); + padding: 2em 0 2em 0; } #section1 { - background: image_url("me.jpg") fixed; - background-position: center top; + background: image_url("me.jpg") center top fixed; } #section3 { - background: image_url("waldschrat.jpg") fixed; - background-position: center top; + background: image_url("waldschrat.jpg") center top fixed; +} +#section1, #section3, #section5 { + height: 100vh; // make this responsive... +} +.content { + position: relative; + width: 90%; + top: 50%; + left: 50%; + transform: translate(-50%, 0); + z-index: 1; } #footer { @@ -230,7 +233,6 @@ p { .section { position: relative; - height: 100%; overflow: hidden; } .section .watermark { @@ -330,15 +332,6 @@ p { position: relative; } -.content { - position: relative; - width: 90%; - height: 90%; - top: 50%; - left: 50%; - transform: translate(-50%, -50%); - z-index: 1; -} .textbox { text-align: center; border-style: solid; diff --git a/app/views/layouts/application.html.erb b/app/views/layouts/application.html.erb index 02533bc..c2902ca 100644 --- a/app/views/layouts/application.html.erb +++ b/app/views/layouts/application.html.erb @@ -24,52 +24,50 @@ -
- <%= yield %> + <%= yield %> - -
+ + Creative Commons License + + + <%= image_tag("gpl-v3-red.svg", height: "30") %> + + +