From 515ef5e1b5823b52a60cba3bdad322a4c7dfcf12 Mon Sep 17 00:00:00 2001 From: Sam Lu Date: Tue, 31 Jul 2018 23:57:25 -0500 Subject: [PATCH] Fix sass to override old base and main on all pages and mobile views --- src/styles/_cards.sass | 1 - src/styles/_footer.sass | 8 +- src/styles/_navbar.sass | 11 +- src/styles/_typography.sass | 15 ++- src/styles/project-landing.sass | 16 ++- src/styles/projects-index-collection.sass | 1 + src/templates/layout.pug | 129 +++++++++++----------- src/templates/projects/landing.pug | 3 +- 8 files changed, 106 insertions(+), 78 deletions(-) diff --git a/src/styles/_cards.sass b/src/styles/_cards.sass index 72c88ac..29d01ee 100644 --- a/src/styles/_cards.sass +++ b/src/styles/_cards.sass @@ -18,7 +18,6 @@ overflow: hidden width: 100% +media-breakpoint-up(sm) - margin-bottom: 10px height: 203px max-height: 203px min-height: 203px diff --git a/src/styles/_footer.sass b/src/styles/_footer.sass index cf0c1ff..4e1dfb8 100644 --- a/src/styles/_footer.sass +++ b/src/styles/_footer.sass @@ -45,6 +45,12 @@ footer.container-fluid a color: #6d6d6e font-size: 16px + &:hover + color: #3F3F40 .social-icons .list-inline-item:not(:last-child) - margin-right: 22px \ No newline at end of file + margin-right: 22px + a + opacity: 1 + &:hover + opacity: 0.8 \ No newline at end of file diff --git a/src/styles/_navbar.sass b/src/styles/_navbar.sass index 41ea385..ecf74fa 100644 --- a/src/styles/_navbar.sass +++ b/src/styles/_navbar.sass @@ -3,6 +3,7 @@ nav.navbar height: auto min-height: 48px padding: 2px 20px + position: sticky +media-breakpoint-up(md) box-shadow: 0 2px 2px -2px rgba(0,0,0,.15) height: 56px @@ -85,13 +86,13 @@ nav.navbar .gravatar width: 32px border-radius: 50% + .dropdown-menu + margin-top: -2px + .dropdown:hover>.dropdown-menu + display: block #userDropdown .nav-link padding-top: 4px padding-bottom: 0 padding-right: 0 - outline: none -.navbar+.page-content - padding-top: 0 -.container-page - background: #fff \ No newline at end of file + outline: none \ No newline at end of file diff --git a/src/styles/_typography.sass b/src/styles/_typography.sass index adae317..cecd532 100644 --- a/src/styles/_typography.sass +++ b/src/styles/_typography.sass @@ -8,15 +8,20 @@ body color: #212529 h1, h2, h3, h4, h5 font-family: 'Source Sans Pro', sans-serif + margin-top: 0 + margin-bottom: .5rem h1 font-size: 48px line-height: 57px + font-weight: 500 h2 font-size: 36px line-height: 47px + font-weight: 500 h3 font-size: 27px line-height: 38px + font-weight: 500 h4 font-size 21px font-weight: 500 @@ -26,7 +31,13 @@ h5 letter-spacing: 0.6px p font-size: 20px - line-height: 32px + line-height: 1.5 + margin-bottom: 1rem .lead font-size: 20px - letter-spacing: 0.4px \ No newline at end of file + letter-spacing: 0.4px +a + color: #007bff + &:hover + color: #007bff + text-decoration: underline \ No newline at end of file diff --git a/src/styles/project-landing.sass b/src/styles/project-landing.sass index bacbc91..a9403f7 100644 --- a/src/styles/project-landing.sass +++ b/src/styles/project-landing.sass @@ -1,6 +1,7 @@ @import ../styles/colors @import ../styles/breakpoints @import ../styles/typography +@import ../styles/base @import ../styles/navbar @import ../styles/jumbotron @import ../styles/navbar-secondary @@ -9,6 +10,16 @@ @import ../styles/cards @import ../styles/footer +/* Undo main.css padding + ================================================================== */ +section.node-details-container.project + padding-bottom: 0 + .node-details-title + padding-top: 0 + padding-bottom: 0 + +/* Landing Page Sass + ================================================================== */ .cta-arrow img padding-left: 11px @@ -17,8 +28,9 @@ max-width: 1190px h1, p - max-width: 730px - margin: auto + max-width: 700px + margin-left: auto + margin-right: auto section margin-top: 104px +media-breakpoint-up(sm) diff --git a/src/styles/projects-index-collection.sass b/src/styles/projects-index-collection.sass index e5fbdfc..7089d64 100644 --- a/src/styles/projects-index-collection.sass +++ b/src/styles/projects-index-collection.sass @@ -1,6 +1,7 @@ @import ../styles/colors @import ../styles/breakpoints @import ../styles/typography +@import ../styles/base @import ../styles/navbar @import ../styles/jumbotron @import ../styles/navbar-secondary diff --git a/src/templates/layout.pug b/src/templates/layout.pug index 5762399..b60c0b3 100644 --- a/src/templates/layout.pug +++ b/src/templates/layout.pug @@ -164,72 +164,71 @@ html(lang="en") | {% block body %}{% endblock %} | {% block footer_container %} - footer#footer-container.container-fluid + footer.container-fluid | {% block footer_navigation %} - #footer-navigation - .container.py-5 - .row - .col-4 - h5 Blender Cloud - p A creative hub for your projects, powered by free and open source software. - ul.list-inline.social-icons - li.list-inline-item - a(href="https://www.facebook.com/BlenderCloudOfficial/") - img(src="../../static/assets/img/icons/icon-social-facebook.svg", alt="alt") - li.list-inline-item - a(href="https://twitter.com/Blender_Cloud") - img(src="../../static/assets/img/icons/icon-social-twitter.svg", alt="alt") - li.list-inline-item - a(href="https://www.youtube.com/channel/UC5qvW9fotdsSJkCguB_t-kQ") - img(src="../../static/assets/img/icons/icon-social-youtube.svg", alt="alt") - .col - h5 Libraries - ul.list-unstyled.text-small - li - a(href="#") HDRI - li - a(href="#") Textures - li - a(href="#") Characters - .col - h5 Training - ul.list-unstyled.text-small - li - a(href="#") Art Gallery - li - a(href="#") Courses - li - a(href="#") Workshops - .col - h5 Resources - ul.list-unstyled.text-small - li - a(href="https://www.blender.org") Blender - li - a(href="https://store.blender.org/") Blender Store - li - a(href="#") Contact Us - li - a(href="{{ url_for('cloud.terms_and_conditions') }}") Terms and Conditions - li - a(href="{{ url_for('cloud.privacy') }}") Privacy - .col - h5 Services - ul.list-unstyled.text-small - li - a(href="#") Attract - li - a(href="#") Blender Cloud Add-on - li - a(href="#") Blender Sync - li - a(href="#") Flamenco - li - a(href="#") Image Sharing - li - a(href="#") Private Projects - li - a(href="#") Texture Browser + .container.py-5 + .row + .col-4 + h5 Blender Cloud + p A creative hub for your projects, powered by free and open source software. + ul.list-inline.social-icons + li.list-inline-item + a(href="https://www.facebook.com/BlenderCloudOfficial/") + img(src="../../static/assets/img/icons/icon-social-facebook.svg", alt="alt") + li.list-inline-item + a(href="https://twitter.com/Blender_Cloud") + img(src="../../static/assets/img/icons/icon-social-twitter.svg", alt="alt") + li.list-inline-item + a(href="https://www.youtube.com/channel/UC5qvW9fotdsSJkCguB_t-kQ") + img(src="../../static/assets/img/icons/icon-social-youtube.svg", alt="alt") + .col + h5 Libraries + ul.list-unstyled.text-small + li + a(href="#") HDRI + li + a(href="#") Textures + li + a(href="#") Characters + .col + h5 Training + ul.list-unstyled.text-small + li + a(href="#") Art Gallery + li + a(href="#") Courses + li + a(href="#") Workshops + .col + h5 Resources + ul.list-unstyled.text-small + li + a(href="https://www.blender.org") Blender + li + a(href="https://store.blender.org/") Blender Store + li + a(href="#") Contact Us + li + a(href="{{ url_for('cloud.terms_and_conditions') }}") Terms and Conditions + li + a(href="{{ url_for('cloud.privacy') }}") Privacy + .col + h5 Services + ul.list-unstyled.text-small + li + a(href="#") Attract + li + a(href="#") Blender Cloud Add-on + li + a(href="#") Blender Sync + li + a(href="#") Flamenco + li + a(href="#") Image Sharing + li + a(href="#") Private Projects + li + a(href="#") Texture Browser | {% endblock footer_navigation %} //- Scroll Up Arrow. Not sure if it's necessary diff --git a/src/templates/projects/landing.pug b/src/templates/projects/landing.pug index 96a0874..a5d4ce5 100644 --- a/src/templates/projects/landing.pug +++ b/src/templates/projects/landing.pug @@ -78,8 +78,7 @@ script(src="{{ url_for('static_pillar', filename='assets/js/vendor/videojs-hotke | {% endblock %} | {% block css %} -link(href="{{ url_for('static_pillar', filename='assets/css/font-pillar.css') }}", rel="stylesheet") -//- link(href="{{ url_for('static_pillar', filename='assets/css/base.css') }}", rel="stylesheet") +| {{ super() }} link(href="{{ url_for('static_cloud', filename='assets/css/project-landing.css') }}", rel="stylesheet") | {% endblock %}