From c2597b63f13e10b72cd8df0833771cc9cc3d5ee9 Mon Sep 17 00:00:00 2001 From: mmalerba Date: Thu, 17 Nov 2016 10:13:06 -0800 Subject: [PATCH] fix(elevation): change elevations to match spec (#1857) --- src/lib/button/_button-base.scss | 6 ++++++ src/lib/card/card.scss | 6 +----- src/lib/core/style/_menu-common.scss | 4 ++-- src/lib/sidenav/sidenav.scss | 6 +++--- src/lib/snack-bar/snack-bar-container.scss | 2 +- 5 files changed, 13 insertions(+), 11 deletions(-) diff --git a/src/lib/button/_button-base.scss b/src/lib/button/_button-base.scss index 35ce27c3b57a..5949a0d93925 100644 --- a/src/lib/button/_button-base.scss +++ b/src/lib/button/_button-base.scss @@ -88,6 +88,8 @@ $md-mini-fab-padding: 8px !default; @mixin md-fab($size, $padding) { @extend %md-raised-button; + @include md-elevation(6); + // Reset the min-width from the button base. min-width: 0; @@ -98,6 +100,10 @@ $md-mini-fab-padding: 8px !default; flex-shrink: 0; + &:active { + @include md-elevation(12); + } + i, md-icon { padding: $padding 0; line-height: $md-icon-button-line-height; diff --git a/src/lib/card/card.scss b/src/lib/card/card.scss index adfd8ebf4c5a..84ce66567c13 100644 --- a/src/lib/card/card.scss +++ b/src/lib/card/card.scss @@ -8,7 +8,7 @@ $md-card-border-radius: 2px !default; $md-card-header-size: 40px !default; md-card { - @include md-elevation(1); + @include md-elevation(2); @include md-elevation-transition; display: block; position: relative; @@ -17,10 +17,6 @@ md-card { font-family: $md-font-family; } -md-card:hover { - @include md-elevation(2); -} - .md-card-flat { box-shadow: none; } diff --git a/src/lib/core/style/_menu-common.scss b/src/lib/core/style/_menu-common.scss index fc96304e1791..e0f53fee3fa8 100644 --- a/src/lib/core/style/_menu-common.scss +++ b/src/lib/core/style/_menu-common.scss @@ -13,7 +13,7 @@ $md-menu-font-size: 16px !default; $md-menu-side-padding: 16px !default; @mixin md-menu-base() { - @include md-elevation(2); + @include md-elevation(8); min-width: $md-menu-overlay-min-width; max-width: $md-menu-overlay-max-width; @@ -86,4 +86,4 @@ $md-menu-side-padding: 16px !default; transform-origin: left bottom; } } -} \ No newline at end of file +} diff --git a/src/lib/sidenav/sidenav.scss b/src/lib/sidenav/sidenav.scss index 34b67918c9b8..4f6f9e1d26a3 100644 --- a/src/lib/sidenav/sidenav.scss +++ b/src/lib/sidenav/sidenav.scss @@ -20,12 +20,12 @@ transform: translate3d($close, 0, 0); } &.md-sidenav-opening { - @include md-elevation(1); + @include md-elevation(16); visibility: visible; transform: translate3d($open, 0, 0); } &.md-sidenav-opened { - @include md-elevation(1); + @include md-elevation(16); transform: translate3d($open, 0, 0); } } @@ -132,4 +132,4 @@ md-sidenav { .md-sidenav-invalid { display: none; -} \ No newline at end of file +} diff --git a/src/lib/snack-bar/snack-bar-container.scss b/src/lib/snack-bar/snack-bar-container.scss index aa9f1d69ebe0..3b6e39e10e7c 100644 --- a/src/lib/snack-bar/snack-bar-container.scss +++ b/src/lib/snack-bar/snack-bar-container.scss @@ -7,7 +7,7 @@ $md-snack-bar-max-width: 568px !default; :host { - @include md-elevation(24); + @include md-elevation(6); background: #323232; border-radius: 2px; box-sizing: content-box;