]> git.ipfire.org Git - thirdparty/foundation/foundation-sites.git/commitdiff
fix sass deprecations
authorJoe Workman <joe@workmanmail.com>
Mon, 5 Aug 2024 15:00:20 +0000 (08:00 -0700)
committerJoe Workman <joe@workmanmail.com>
Mon, 5 Aug 2024 15:00:20 +0000 (08:00 -0700)
19 files changed:
scss/_global.scss
scss/components/_breadcrumbs.scss
scss/components/_button-group.scss
scss/components/_button.scss
scss/components/_callout.scss
scss/components/_close-button.scss
scss/components/_off-canvas.scss
scss/components/_orbit.scss
scss/components/_pagination.scss
scss/components/_reveal.scss
scss/components/_slider.scss
scss/components/_table.scss
scss/components/_tabs.scss
scss/components/_top-bar.scss
scss/forms/_select.scss
scss/forms/_text.scss
scss/grid/_position.scss
scss/prototype/_separator.scss
scss/xy-grid/_grid.scss

index 2235b83720f6f53cfb59b593e8608f872e43b6a3..8e3998b0b8d78f142e439408cb5afa28bb3693ac 100644 (file)
@@ -221,7 +221,6 @@ $global-color-pick-contrast-tolerance: 0 !default;
 
   // Reset <button> styles created by most browsers
   button {
-    @include disable-mouse-outline;
     padding: 0;
     appearance: none;
     border: 0;
@@ -229,6 +228,7 @@ $global-color-pick-contrast-tolerance: 0 !default;
     background: transparent;
     line-height: 1;
     cursor: $global-button-cursor;
+    @include disable-mouse-outline;
   }
 
   // Prevent text overflow on pre
index e9e08c8c72b66abfbbb901bef239eabdba4ddaf3..d4e2289f11c7d9f90abff80c91fd377870f08abc 100644 (file)
@@ -62,10 +62,11 @@ $breadcrumbs-item-separator-color: $medium-gray !default;
 
 /// Adds styles for a breadcrumbs container, along with the styles for the `<li>` and `<a>` elements inside of it.
 @mixin breadcrumbs-container {
-  @include clearfix;
   margin: $breadcrumbs-margin;
   list-style: none;
 
+  @include clearfix;
+
   // Item wrapper
   li {
     float: #{$global-left};
index 4734408a137f2c04c8d915356cdf79e1da316240..54e290900dee3d9beb49389a41d6e7af88f5d72c 100644 (file)
@@ -33,7 +33,6 @@ $buttongroup-radius-on-each: true !default;
   $child-selector: $buttongroup-child-selector,
   $spacing: $buttongroup-spacing
 ) {
-  @include clearfix;
   margin-bottom: $buttongroup-margin;
 
   @if $global-flexbox {
@@ -51,6 +50,8 @@ $buttongroup-radius-on-each: true !default;
     font-size: 0;
   }
 
+  @include clearfix;
+
   #{$child-selector} {
     margin: 0;
     margin-#{$global-right}: $spacing;
index 8e7a231b04baa93724d1caeba82fd74e7ebb406c..197f72e6b2f2c805e95b32263bd8fdb050b39e88 100644 (file)
@@ -95,10 +95,19 @@ $button-responsive-expanded: false !default;
 
 // TODO: Document button-base() mixin
 @mixin button-base {
-  @include disable-mouse-outline;
   display: inline-block;
   vertical-align: middle;
   margin: $button-margin;
+  border: $button-border;
+  border-radius: $button-radius;
+  transition: $button-transition;
+  font-family: $button-font-family;
+  font-size: map-get($button-sizes, default);
+  font-weight: $button-font-weight;
+  -webkit-appearance: none; // sass-lint:disable-line no-vendor-prefixes
+  line-height: 1;
+  text-align: center;
+  cursor: pointer;
 
   @if (type-of($button-padding) == 'map') {
     @each $size, $padding in $button-padding {
@@ -111,16 +120,7 @@ $button-responsive-expanded: false !default;
     padding: $button-padding;
   }
 
-  border: $button-border;
-  border-radius: $button-radius;
-  transition: $button-transition;
-  font-family: $button-font-family;
-  font-size: map-get($button-sizes, default);
-  font-weight: $button-font-weight;
-  -webkit-appearance: none; // sass-lint:disable-line no-vendor-prefixes
-  line-height: 1;
-  text-align: center;
-  cursor: pointer;
+  @include disable-mouse-outline;
 }
 
 /// Expands a button to make it full-width.
index c8472c04a1c522ec31b4e3d09a67b765a5d22008..52f171e3f5c1509b695824b2260086dd6fac2380 100644 (file)
@@ -85,8 +85,8 @@ $callout-link-tint: 30% !default;
 /// Adds styles for a callout.
 /// @param {Color} $color [$callout-background] - Color to use.
 @mixin callout($color: $callout-background) {
-  @include callout-base;
   @include callout-style($color);
+  @include callout-base;
 }
 
 @mixin foundation-callout {
index 40f737f079188a589474a2d65866f543dcced06b..49ad96844e5ba460a0f756c9a37c82636762e835 100644 (file)
@@ -92,12 +92,13 @@ $closebutton-color-hover: $black !default;
   $x: nth($closebutton-position, 1);
   $y: nth($closebutton-position, 2);
 
-  @include disable-mouse-outline;
   position: absolute;
   z-index: $closebutton-z-index;
   color: $closebutton-color;
   cursor: pointer;
 
+  @include disable-mouse-outline;
+
   &:hover,
   &:focus {
     color: $closebutton-color-hover;
index 5a8894bddb52a09f37453b1da46187eb4ab9ae3f..4a020193acc5ce529ff1b70d0e88d8fd65308908 100644 (file)
@@ -143,7 +143,11 @@ $maincontent-class: 'off-canvas-content' !default;
   $transition: $offcanvas-transition-length $offcanvas-transition-timing,
   $fixed: true
 ) {
-  @include disable-mouse-outline;
+  // Set the off-canvas z-index.
+  z-index: $offcanvas-push-zindex;
+  transition: transform $transition;
+  backface-visibility: hidden;
+  background: $background;
 
   @if $fixed == true {
     position: fixed;
@@ -152,19 +156,13 @@ $maincontent-class: 'off-canvas-content' !default;
     position: absolute;
   }
 
-  // Set the off-canvas z-index.
-  z-index: $offcanvas-push-zindex;
+  @include disable-mouse-outline;
 
   // Increase CSS specificity
   &.is-transition-push {
     z-index: $offcanvas-push-zindex;
   }
 
-  transition: transform $transition;
-  backface-visibility: hidden;
-
-  background: $background;
-
   // Hide inactive off-canvas within the content that have the same position
   &.is-closed {
     visibility: hidden;
index 06761cc47070ab21ea3128a7b80216528b8734a5..6d15da3c7a3a7569fe2cb1882c890f7f8c129a03 100644 (file)
@@ -102,11 +102,11 @@ $orbit-control-zindex: 10 !default;
 
 /// Adds base styles for the next/previous buttons in an Orbit slider. These styles are shared between the `.orbit-next` and `.orbit-previous` classes in the default CSS.
 @mixin orbit-control {
-  @include disable-mouse-outline;
-  @include vertical-center;
   z-index: $orbit-control-zindex;
   padding: $orbit-control-padding;
   color: $white;
+  @include vertical-center;
+  @include disable-mouse-outline;
 
   &:hover,
   &:active,
@@ -128,11 +128,11 @@ $orbit-control-zindex: 10 !default;
 
 /// Adds styles for a container of Orbit bullets. /// Adds styles for the Orbit previous button. These styles are used on the `.orbit-bullets` class.
 @mixin orbit-bullets {
-  @include disable-mouse-outline;
   position: relative;
   margin-top: $orbit-bullet-margin-top;
   margin-bottom: $orbit-bullet-margin-bottom;
   text-align: center;
+  @include disable-mouse-outline;
 
   button {
     width: $orbit-bullet-diameter;
index f8a8c1477011460e489a4b2931f03d8adb1331b9..2276a39dbe167e7dce2dd42f140c8106e76cc068 100644 (file)
@@ -83,9 +83,9 @@ $pagination-arrow-next: '\00BB' !default;
   $padding: $pagination-item-padding,
   $background-hover: $pagination-item-background-hover
 ) {
-  @include clearfix;
   margin-#{$global-left}: 0;
   margin-bottom: $margin-bottom;
+  @include clearfix;
 
   // List item
   li {
index 83555774b19b19cb9cf0e54e9fdb8b6f1d67cbfd..533503ea5f83032c82657d66d7fbed731699f67e 100644 (file)
@@ -69,7 +69,6 @@ $reveal-overlay-background: rgba($black, 0.45) !default;
 
 /// Adds base styles for a modal.
 @mixin reveal-modal-base {
-  @include disable-mouse-outline;
   z-index: $reveal-zindex + 1;
   // Workaround android browser z-index bug
   backface-visibility: hidden;
@@ -81,6 +80,8 @@ $reveal-overlay-background: rgba($black, 0.45) !default;
   border-radius: $reveal-radius;
   background-color: $reveal-background;
 
+  @include disable-mouse-outline;
+
   @include breakpoint(medium) {
     min-height: 0;
   }
@@ -153,8 +154,6 @@ $reveal-overlay-background: rgba($black, 0.45) !default;
 
   // Modal container
   .reveal {
-    @include reveal-modal-base;
-    @include reveal-modal-width($reveal-width);
     position: relative;
     top: 100px;
     margin-right: auto;
@@ -162,6 +161,9 @@ $reveal-overlay-background: rgba($black, 0.45) !default;
     overflow-y: auto;
     -webkit-overflow-scrolling: touch;
 
+    @include reveal-modal-base;
+    @include reveal-modal-width($reveal-width);
+
     // Remove padding
     &.collapse {
       padding: 0;
index 142f4a5b3d0160ac8d01a9358d88253bda7027b3..672a05b7818247ef43b5d0fbf5645a95835f3683 100755 (executable)
@@ -50,8 +50,6 @@ $slider-transition: all 0.2s ease-in-out !default;
 
 /// Adds the general styles for the slider handles.
 @mixin slider-handle {
-  @include disable-mouse-outline;
-  @include vertical-center;
   left: 0;
   z-index: 1;
   cursor: grab;
@@ -65,6 +63,9 @@ $slider-transition: all 0.2s ease-in-out !default;
   transition: $slider-transition;
   touch-action: manipulation;
 
+  @include vertical-center;
+  @include disable-mouse-outline;
+
   &:hover {
     background-color: scale-color($slider-handle-background, $lightness: -15%);
   }
index 1a46d33109dde39ef8844917203566426daee2cc..c3c1c94ed77086a288989abdd52721aeeab9da51 100644 (file)
@@ -165,8 +165,8 @@ $table-stack-breakpoint: medium !default;
 
     &.unstriped {
       tbody {
-        @include -zf-table-unstripe();
         background-color: $table-background;
+        @include -zf-table-unstripe();
       }
     }
   }
index f100b967c8bf512b9fae752f59ac010d6da9997f..1b570ab4f0bdf52f122b44c5689e956ded735120 100644 (file)
@@ -59,11 +59,11 @@ $tab-content-padding: 1rem !default;
   $background: $tab-background,
   $border-color: $tab-content-border
 ) {
-  @include clearfix;
   margin: $margin;
   border: 1px solid $border-color;
   background: $background;
   list-style-type: none;
+  @include clearfix;
 }
 
 /// Augments a tab container to have vertical tabs. Use this in conjunction with `tabs-container()`.
@@ -87,12 +87,12 @@ $tab-content-padding: 1rem !default;
   float: #{$global-left};
 
   > a {
-    @include disable-mouse-outline;
     display: block;
     padding: $padding;
     font-size: $font-size;
     line-height: 1;
     color: $color;
+    @include disable-mouse-outline;
 
     &:hover {
       background: $background-hover;
index 83e01fc9a02fc15dc7b1c874e7275c1212f3718e..81366515221c7fc183c0bad4135b2e6ca3b21493 100644 (file)
@@ -32,6 +32,8 @@ $topbar-unstack-breakpoint: medium !default;
 
 /// Adds styles for a top bar container.
 @mixin top-bar-container {
+  padding: $topbar-padding;
+
   @if $global-flexbox {
     display: flex;
     flex-wrap: nowrap;
@@ -42,8 +44,6 @@ $topbar-unstack-breakpoint: medium !default;
     @include clearfix;
   }
 
-  padding: $topbar-padding;
-
   &,
   ul {
     background-color: $topbar-background;
index f09419af89ca2470b913260673b541fbecdf3e4e..bdbdc01d726fba15616af4981e410d990c96979e 100644 (file)
@@ -36,18 +36,19 @@ $select-radius: $global-radius !default;
   line-height: $input-line-height;
   color: $input-color;
 
+  @if has-value($input-transition) {
+    transition: $input-transition;
+  }
+
   @if $select-triangle-color != transparent {
-    @include background-triangle($select-triangle-color);
     background-origin: content-box;
     background-position: $global-right (-$form-spacing) center;
     background-repeat: no-repeat;
     background-size: 9px 6px;
 
     padding-#{$global-right}: ($form-spacing * 1.5);
-  }
 
-  @if has-value($input-transition) {
-    transition: $input-transition;
+    @include background-triangle($select-triangle-color);
   }
 
   // Focus state
index 0081c53a005f56732a55b47b3241921975ffaed7..cdb4c20647c0d28e648bc94e8491f921e7905995 100644 (file)
@@ -124,8 +124,8 @@ $form-button-radius: $global-radius !default;
   // Text inputs
   #{text-inputs()},
   textarea {
-    @include form-element;
     appearance: none;
+    @include form-element;
   }
 
   // Text areas
index 40f71344e9cd5c613e586f4a9b103b9c392e3dd0..c277bb19275a5b7a58cd429f9d881703ed4a6a3e 100644 (file)
 
   // Center positioning
   @else if $position == center {
+    margin-left: auto;
+    margin-right: auto;
     &, &:last-child:not(:first-child) {
       float: none;
       clear: both;
     }
-    margin-right: auto;
-    margin-left: auto;
   }
 
   @else {
 
 /// Reset a position definition.
 @mixin grid-column-unposition {
-  @include grid-column-position(auto);
   position: static;
   margin-right: 0;
   margin-left: 0;
+  @include grid-column-position(auto);
 }
 
 /// Offsets a column to the right by `$n` columns.
index 62876a2b9c391b1a33c5f1c4ced7fb3ec4d6b49f..086c4db84f67da89a744599df5d1fc2d93b980dc 100644 (file)
@@ -43,8 +43,8 @@ $prototype-separator-margin-top: $global-margin !default;
   $background: $prototype-separator-background,
   $top: $prototype-separator-margin-top
 ) {
-  @include clearfix;
   text-align: $align !important;
+  @include clearfix;
 
   &::after {
     @include position(relative);
index 3fdf474256cff7dbce33ffb4d12f180bcefdbb18..7baae2be2d8c99d691ea13e05752fba5e97f0794 100644 (file)
   $width: $grid-container,
   $padding: $grid-container-padding
 ) {
-  @include xy-gutters($gutters: $padding, $gutter-type: padding);
-
   max-width: $width;
   margin-left: auto;
   margin-right: auto;
+
+  @include xy-gutters($gutters: $padding, $gutter-type: padding);
 }
 
 /// Creates a container for your flex cells.