]> git.ipfire.org Git - thirdparty/foundation/foundation-sites.git/commitdiff
feat: add z-index to the Close Button with the "$closebutton-z-index" setting 11566/head
authorNicolas Coden <nicolas@ncoden.fr>
Sat, 27 Oct 2018 19:18:03 +0000 (21:18 +0200)
committerNicolas Coden <nicolas@ncoden.fr>
Sat, 27 Oct 2018 19:23:42 +0000 (21:23 +0200)
We cannot ensure the Close Button to always be on top of others elements. This commit add a `z-index` to the Close Button and a setting to customize it.

Related to https://github.com/zurb/foundation-sites/issues/11544

scss/components/_close-button.scss

index 927741f01bf377900f4c70dc1085c8b95ecca5a3..bc0e1b82ca3ddae4360e7611cc52b573fe97aac0 100644 (file)
 /// @type List
 $closebutton-position: right top !default;
 
+/// Default z-index for a close button.
+/// @type Number
+$closebutton-z-index: 10 !default;
+
 /// Right (or left) offset(s) for a close button.
 /// @type Number|Map
 $closebutton-offset-horizontal: (
@@ -83,6 +87,7 @@ $closebutton-color-hover: $black !default;
 
   @include disable-mouse-outline;
   position: absolute;
+  z-index: $closebutton-z-index;
   color: $closebutton-color;
   cursor: pointer;