]> git.ipfire.org Git - thirdparty/bulma.git/commitdiff
Add and use $navbar-breakpoint variable; Fixes #1042 (#2109)
authorBenjamin Melançon <ben@agaric.com>
Tue, 2 Oct 2018 05:40:16 +0000 (01:40 -0400)
committerJeremy Thomas <bbxdesign@gmail.com>
Tue, 2 Oct 2018 05:40:16 +0000 (06:40 +0100)
* Add a navbar-breakpoint variable (as yet unused)

* Replace hard-coded +touch, +desktop with $navbar-breakpoint variable

Using the fine +until and +from mixins, respectively.

sass/components/navbar.sass

index e6470f04111aa708291ece78efb0d372a1671a49..3d1064915bad30aa7309106f4c55ab26e6d33a17 100644 (file)
@@ -44,6 +44,8 @@ $navbar-divider-height: 2px !default
 
 $navbar-bottom-box-shadow-size: 0 -2px 0 0 !default
 
+$navbar-breakpoint: $desktop !default
+
 =navbar-fixed
   left: 0
   position: fixed
@@ -74,7 +76,7 @@ $navbar-bottom-box-shadow-size: 0 -2px 0 0 !default
         .navbar-link
           &::after
             border-color: $color-invert
-      +desktop
+      +from($navbar-breakpoint)
         .navbar-start,
         .navbar-end
           & > .navbar-item,
@@ -221,7 +223,7 @@ a.navbar-item,
   height: $navbar-divider-height
   margin: 0.5rem 0
 
-+touch
++until($navbar-breakpoint)
   .navbar > .container
     display: block
   .navbar-brand,
@@ -262,7 +264,7 @@ a.navbar-item,
     &.has-navbar-fixed-bottom-touch
       padding-bottom: $navbar-height
 
-+desktop
++from($navbar-breakpoint)
   .navbar,
   .navbar-menu,
   .navbar-start,