diff --git a/website/source/assets/stylesheets/_footer.scss b/website/source/assets/stylesheets/_footer.scss index c16acff753..c50ce8190a 100644 --- a/website/source/assets/stylesheets/_footer.scss +++ b/website/source/assets/stylesheets/_footer.scss @@ -1,210 +1,88 @@ - -#footer-wrap{ - background-color: white; - padding: 0 0 50px 0; -} - -body.page-home{ - #footer{ - margin-top: -40px; - } +body.page-sub{ + #footer{ + padding: 40px 0; + margin-top: 0; + } } #footer{ - padding: 140px 0 40px; - color: black; - - a{ - color: black; - } - + background-color: white; + padding: 100px 0 60px; + margin-top: -40px; + &.white{ + background-color: $black; .footer-links{ - margin-bottom: 20px; - - .li-under a:hover::after, - .li-under a:focus::after { - opacity: 1; - -webkit-transform: skewY(15deg) translateY(8px); - -moz-transform: skewY(15deg) translateY(8px); - transform: skewY(15deg) translateY(8px); - } - - .li-under a::after { - background-color: $purple; - } - - li{ - a{ - text-transform: uppercase; - font-size: 12px; - letter-spacing: 3px; - @include transition( color 0.3s ease ); - font-weight: 400; - - &:hover{ - color: $purple; - @include transition( color 0.3s ease ); - background-color: transparent; - } - } - } + li > a { + @include project-footer-a-subpage-style(); + } } + } - .buttons.navbar-nav{ - float: none; - display: inline-block; - margin-bottom: 30px; - margin-top: 0px; - - li{ - &.first{ - margin-right: 12px; - } - - &.download{ - a{ - background: image-url('icon-download-purple.png') 8px 6px no-repeat; - @include img-retina("icon-download-purple.png", "icon-download-purple@2x.png", 20px, 20px); - } - } - - &.github{ - a{ - background: image-url('icon-github-purple.png') 8px 6px no-repeat; - @include img-retina("icon-github-purple.png", "icon-github-purple@2x.png", 20px, 20px); - } - } - } - - li > a { - padding-top: 6px; - padding-bottom: 6px; - padding-left: 40px; - } + .footer-links{ + li > a { + @include project-footer-a-style(); } + } - .footer-hashi{ - float: right; - padding-top: 5px; - letter-spacing: 2px; + .hashicorp-project{ + margin-top: 24px; + } - a{ - color: black; - font-weight: $font-weight-lato-xb; - } - - span{ - margin-right: 10px; - } - - .hashi-logo{ - display: inline-block; - vertical-align: middle; - i{ - display: inline-block; - width: 37px; - height: 40px; - background: image-url('footer-hashicorp-logo.png') 0 0 no-repeat; - @include img-retina("footer-hashicorp-logo.png", "footer-hashicorp-logo@2x.png", 37px, 40px); - } - } - } + .pull-right{ + padding-right: 15px; + } } -.page-sub{ - #footer-wrap{ - padding: 0; - } +.edit-page-link{ + position: absolute; + top: -70px; + right: 30px;; - #footer{ - padding: 140px 0 100px; - background-color: $black; - transform: none; - - >.container{ - transform: none; - } - - a{ - color: white; - } - - .footer-hashi{ - color: white; - - .hashi-logo{ - i{ - background: image-url('footer-hashicorp-white-logo.png') 0 0 no-repeat; - @include img-retina("footer-hashicorp-white-logo.png", "footer-hashicorp-white-logo@2x.png", 37px, 40px); - } - } - } - } -} - - -@media (min-width: 1500px) { - body.page-home{ - #footer{ - margin-top: -60px; - padding: 190px 0 40px; - } - } + a{ + text-transform: uppercase; + color: $black; + font-size: 13px; + } } @media (max-width: 992px) { - .page-sub #footer, #footer{ - .footer-hashi { - padding-top: 14px; - span{ - margin-right: 6px; - } - .hashi-logo{ - i{ - margin-top: -6px; - width: 20px; - height: 22px; - background-size: 20px 22px; - } - } - } + .footer-links { + display: block; + text-align: center; + + ul{ + display: inline-block;; + float: none !important; } - -} - -@media (max-width: 768px) { - #footer{ - padding: 100px 0 40px; - text-align: center; - - .footer-links{ - float: none; - display: inline-block; - } - - .footer-hashi { - float: none; - display: inline-block; - - .pull-right{ - float: none !important; - } - } + .footer-hashi{ + display: block; + float: none !important; } + } } -@media (max-width: 320px) { - #footer{ - text-align: center; +@media (max-width: 414px) { + #footer{ + ul{ + display: block; + li{ + display: block; + float: none; + } - .footer-links{ - .li-under{ - float: none !important; - } + &.external-links{ + li{ + svg{ + position: relative; + left: 0; + top: 2px; + margin-top: 0; + margin-right: 4px; + } } + } } + } } - - diff --git a/website/source/assets/stylesheets/hashicorp-shared/_hashicorp-header.scss b/website/source/assets/stylesheets/hashicorp-shared/_hashicorp-header.scss index c9bc593b65..e9bbe501e7 100755 --- a/website/source/assets/stylesheets/hashicorp-shared/_hashicorp-header.scss +++ b/website/source/assets/stylesheets/hashicorp-shared/_hashicorp-header.scss @@ -4,33 +4,21 @@ // - Edits should not be made here // -------------------------------------------------- -#header { +#header{ position: relative; + margin-bottom: 0; +} + +.navigation { color: black; text-rendering: optimizeLegibility; - margin-bottom: 0; transition: all 1s ease; &.white{ - color: white; .navbar-brand { .logo { color: white; } - - .by{ - color: white; - font-weight: 300; - svg{ - path, - polygon{ - fill: white; - } - line{ - stroke: white; - } - } - } } .main-links, @@ -41,109 +29,40 @@ } } } + } - .nav > li > a:hover, .nav > li > a:focus { - color: white; + &.black{ + .navbar-brand { + .logo { + color: black; + } } - .navbar-header{ - .navbar-toggle{ - .icon-bar{ - border: 1px solid white; - } + .main-links, + .external-links { + li > a { + color: black; } } } - .navbar-header{ - .navbar-toggle{ - height: $header-height; - margin: 0; - padding-right: 15px; - border-radius: 0; - .icon-bar{ - border: 1px solid $black; - border-radius: 0; - } - } - } - - .navbar-brand { - display: block; + .navbar-toggle{ height: $header-height; - padding: 0; - margin: 0 10px 0 0 ; - - .logo{ - display: inline-block; - height: $header-height; - vertical-align:top; - padding: 0; - line-height: $header-height; - padding-left: $project-logo-width + $project-logo-pad-left; - background-position: 0 center; - @include transition(all 300ms ease-in); - - &:hover{ - @include transition(all 300ms ease-in); - text-decoration: none; - } - } - - .by{ - display: inline-block; - vertical-align:top; - height: $header-height; - margin-left: 3px; - padding-top: 2px; - color: black; - line-height: $header-height; - font-family: $header-font-family; - font-weight: 600; - font-size: 0; - text-decoration: none; - - .svg-wrap{ - font-size: 13px; - } - - svg{ - &.svg-by{ - width: $by-hashicorp-width; - height: $by-hashicorp-height; - margin-bottom: -4px; - margin-left: 4px; - } - - &.svg-logo{ - width: 16px; - height: 16px; - margin-bottom: -3px; - margin-left: 4px; - } - - path, - polygon{ - fill: black; - @include transition(all 300ms ease-in); - - &:hover{ - @include transition(all 300ms ease-in); - } - } - line{ - stroke: black; - @include transition(all 300ms ease-in); - - &:hover{ - @include transition(all 300ms ease-in); - } - } - } + margin: 0; + border-radius: 0; + .icon-bar{ + border: 1px solid $black; + border-radius: 0; } } .external-links { + &.white{ + svg path{ + fill: $white; + } + } + li { position: relative; @@ -157,6 +76,8 @@ } } + @include project-svg-external-links-style(); + &.download{ margin-right: 10px; } @@ -181,28 +102,222 @@ .main-links, .external-links { + &.white{ + li > a { + color: white; + } + } li > a { @include hashi-a-style(); margin: 0 10px; padding-top: 1px; line-height: $header-height; + @include project-a-style(); } } .nav > li > a:hover, .nav > li > a:focus { background-color: transparent; - color: $black; @include transition( all 300ms ease-in ); } } +.navbar-brand { + display: block; + height: $header-height; + padding: 0; + margin: 0 10px 0 0; + + .logo{ + display: inline-block; + height: $header-height; + vertical-align:top; + padding: 0; + line-height: $header-height; + padding-left: $project-logo-width + $project-logo-pad-left; + background-position: 0 center; + @include transition(all 300ms ease-in); + + &:hover{ + @include transition(all 300ms ease-in); + text-decoration: none; + } + } +} + +.navbar-toggle{ + &.white{ + .icon-bar{ + border: 1px solid white; + } + } +} + +.by-hashicorp{ + display: inline-block; + vertical-align:top; + height: $header-height; + margin-left: 3px; + padding-top: 2px; + color: black; + line-height: $header-height; + font-family: $header-font-family; + font-weight: 600; + font-size: 0; + text-decoration: none; + + &.white{ + color: white; + font-weight: 300; + svg{ + path, + polygon{ + fill: white; + } + line{ + stroke: white; + } + } + + &:focus, + &:hover{ + text-decoration: none; + color: white; + } + } + + &:focus, + &:hover{ + text-decoration: none; + } + + .svg-wrap{ + font-size: 13px; + } + + svg{ + &.svg-by{ + width: $by-hashicorp-width; + height: $by-hashicorp-height; + margin-bottom: -4px; + margin-left: 4px; + } + + &.svg-logo{ + width: 16px; + height: 16px; + margin-bottom: -3px; + margin-left: 4px; + } + + path, + polygon{ + fill: black; + @include transition(all 300ms ease-in); + + &:hover{ + @include transition(all 300ms ease-in); + } + } + line{ + stroke: black; + @include transition(all 300ms ease-in); + + &:hover{ + @include transition(all 300ms ease-in); + } + } + } +} + +.hashicorp-project{ + display: inline-block; + height: 30px; + line-height: 30px; + text-decoration: none; + font-size: 14px; + color: $black; + font-weight: 600; + + &.white{ + color: white; + svg{ + path, + polygon{ + fill: white; + } + line{ + stroke: white; + } + } + } + + &:focus{ + text-decoration: none; + } + + &:hover{ + text-decoration: none; + svg{ + &.svg-by{ + line{ + stroke: $purple; + } + } + } + } + + span{ + margin-right: 4px; + font-family: $header-font-family; + font-weight: 500; + } + + span, + svg{ + display: inline-block; + } + + svg{ + &.svg-by{ + width: $by-hashicorp-width; + height: $by-hashicorp-height; + margin-bottom: -4px; + margin-left: -3px; + } + + &.svg-logo{ + width: 30px; + height: 30px; + margin-bottom: -10px; + margin-left: -1px; + } + + path, + line{ + fill: $black; + @include transition(all 300ms ease-in); + + &:hover{ + @include transition(all 300ms ease-in); + } + } + } +} + +@media (max-width: 480px) { + .navigation { + .main-links{ + margin-right: 0; + } + } +} + @media (max-width: 414px) { #header { - .navbar-header{ - .navbar-toggle{ - padding-top: 10px; - height: $header-mobile-height; - } + .navbar-toggle{ + padding-top: 10px; + height: $header-mobile-height; } .navbar-brand { @@ -212,7 +327,7 @@ height: $header-mobile-height; line-height: $header-mobile-height; } - .by{ + .by-hashicorp{ height: $header-mobile-height; line-height: $header-mobile-height; padding-top: 0; diff --git a/website/source/assets/stylesheets/hashicorp-shared/_project-utility.scss b/website/source/assets/stylesheets/hashicorp-shared/_project-utility.scss index 1a511152df..5e51f91d5f 100755 --- a/website/source/assets/stylesheets/hashicorp-shared/_project-utility.scss +++ b/website/source/assets/stylesheets/hashicorp-shared/_project-utility.scss @@ -16,5 +16,56 @@ $project-logo-pad-left: 8px; &:hover{ color: $white; + opacity: 1; + } +} + +@mixin project-footer-a-style{ + color: $black; + font-weight: 400; + + &:hover{ + color: $purple; + + svg path{ + fill: $purple; + } + } +} + +@mixin project-footer-a-subpage-style{ + color: $white; + font-weight: 400; + + svg path{ + fill: $white; + } + + &:hover{ + color: $purple; + + svg path{ + fill: $purple; + } + } +} + +@mixin project-svg-external-links-style{ + svg path{ + fill: $black; + } + + &:hover{ + svg path{ + fill: $blue; + } + } +} + +@mixin project-by-hashicorp-style{ + &:hover{ + line{ + stroke: $blue; + } } } diff --git a/website/source/layouts/_footer.erb b/website/source/layouts/_footer.erb index d42c55cac6..1be5b8d471 100644 --- a/website/source/layouts/_footer.erb +++ b/website/source/layouts/_footer.erb @@ -1,28 +1,43 @@ -
+