From 8c60d9c7a63ab8598e7367bf7ef2b31afe1bdae6 Mon Sep 17 00:00:00 2001 From: Marcy Sutton Date: Wed, 6 May 2015 16:27:21 -0700 Subject: [PATCH] fix(tooltip): update to spec, remove max-width Closes #656 --- src/components/tooltip/tooltip.scss | 31 +++++++++++++++++++++++++---- 1 file changed, 27 insertions(+), 4 deletions(-) diff --git a/src/components/tooltip/tooltip.scss b/src/components/tooltip/tooltip.scss index 34aaa6387c8..665861ce77c 100644 --- a/src/components/tooltip/tooltip.scss +++ b/src/components/tooltip/tooltip.scss @@ -1,11 +1,26 @@ +$tooltip-fontsize-lg: rem(1); +$tooltip-fontsize-sm: rem(1.4); +$tooltip-height-lg: rem(2.2); +$tooltip-height-sm: rem(3.2); +$tooltip-top-margin-lg: rem(1.4); +$tooltip-top-margin-sm: rem(2.4); +$tooltip-lr-padding-lg: rem(0.8); +$tooltip-lr-padding-sm: rem(1.6); +$tooltip-max-width: rem(3.20); + md-tooltip { position: absolute; - font-size: 14px; z-index: $z-index-tooltip; overflow: hidden; pointer-events: none; border-radius: 4px; + font-weight: 500; + font-size: $tooltip-fontsize-sm; + @media screen and (min-width: $layout-breakpoint-sm) { + font-size: $tooltip-fontsize-lg; + } + .md-background { position: absolute; border-radius: 50%; @@ -28,17 +43,25 @@ md-tooltip { } } } - .md-content { position: relative; - max-width: 240px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; - padding: 8px; background: transparent; opacity: 0; + + height: $tooltip-height-sm; + line-height: $tooltip-height-sm; + padding-left: $tooltip-lr-padding-sm; + padding-right: $tooltip-lr-padding-sm; + @media screen and (min-width: $layout-breakpoint-sm) { + height: $tooltip-height-lg; + line-height: $tooltip-height-lg; + padding-left: $tooltip-lr-padding-lg; + padding-right: $tooltip-lr-padding-lg; + } &.md-show-add { transition: $swift-ease-out; opacity: 0;