]> git.ipfire.org Git - thirdparty/foundation/foundation-sites.git/commitdiff
Simplify Sass for tooltips
authorGeoff Kimball <geoff@zurb.com>
Tue, 24 Nov 2015 22:59:56 +0000 (14:59 -0800)
committerGeoff Kimball <geoff@zurb.com>
Tue, 24 Nov 2015 22:59:56 +0000 (14:59 -0800)
scss/components/_tooltip.scss

index d08a85215ba5d0520be44042f7e176df6b0220f5..a28c3e69cf9fdcd0c572433e0f7ab0224ddf861d 100644 (file)
@@ -43,10 +43,7 @@ $tooltip-radius: $global-radius !default;
   font-weight: bold;
   position: relative;
   display: inline-block;
-
-  &:hover {
-    cursor: help;
-  }
+  cursor: help;
 }
 
 @mixin tooltip {
@@ -59,7 +56,6 @@ $tooltip-radius: $global-radius !default;
   top: calc(100% + #{$tooltip-pip-height});
   max-width: 10rem !important;
   border-radius: $tooltip-radius;
-  // visibility: hidden;
 
   &::before {
     @include css-triangle($tooltip-pip-width, $tooltip-background-color, up);
@@ -69,33 +65,27 @@ $tooltip-radius: $global-radius !default;
     transform: translateX(-50%);
   }
 
-  &.top {
-    &::before {
-      @include css-triangle($tooltip-pip-width, $tooltip-background-color, down);
-      top: 100%;
-      bottom: auto;
-    }
+  &.top::before {
+    @include css-triangle($tooltip-pip-width, $tooltip-background-color, down);
+    top: 100%;
+    bottom: auto;
   }
 
-  &.left {
-    &::before {
-      @include css-triangle($tooltip-pip-width, $tooltip-background-color, right);
-      bottom: auto;
-      left: 100%;
-      top: 50%;
-      transform: translateY(-50%);
-    }
+  &.left::before {
+    @include css-triangle($tooltip-pip-width, $tooltip-background-color, right);
+    bottom: auto;
+    left: 100%;
+    top: 50%;
+    transform: translateY(-50%);
   }
 
-  &.right {
-    &::before {
-      @include css-triangle($tooltip-pip-width, $tooltip-background-color, left);
-      bottom: auto;
-      left: auto;
-      right: 100%;
-      top: 50%;
-      transform: translateY(-50%);
-    }
+  &.right::before {
+    @include css-triangle($tooltip-pip-width, $tooltip-background-color, left);
+    bottom: auto;
+    left: auto;
+    right: 100%;
+    top: 50%;
+    transform: translateY(-50%);
   }
 }