Skip to content

Commit

Permalink
🐛 fix(_generator.scss): Forward missing override parameter
Browse files Browse the repository at this point in the history
  • Loading branch information
Spiderpig86 committed Aug 6, 2023
1 parent ffe1579 commit f859448
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 9 deletions.
2 changes: 1 addition & 1 deletion src/base/spacing.scss
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
@use '../internal' as *;

@include utility-with-body($prefix: '', $generate-viewports: 'true', $override: '!important') using
($variant-prefix, $prefix, $common-class, $delimiter, $key, $suffix-str, $variant-suffix) {
($variant-prefix, $prefix, $common-class, $delimiter, $key, $suffix-str, $variant-suffix, $override) {
@each $class, $size in $spacing-system {
/* Margin */
.#{$variant-prefix}#{$prefix}m#{$delimiter}#{$class}#{$suffix-str} #{$variant-suffix}{
Expand Down
12 changes: 6 additions & 6 deletions src/internal/_generator.scss
Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,8 @@ $default-variant-delimiter: '\\:';
$value,
$override
)
using ($variant-prefix, $prefix, $common-class, $delimiter, $key, $suffix-str, $variant-suffix) {
@content ($variant-prefix, $prefix, $common-class, $delimiter, $key, $suffix-str, $variant-suffix);
using ($variant-prefix, $prefix, $common-class, $delimiter, $key, $suffix-str, $variant-suffix, $override) {
@content ($variant-prefix, $prefix, $common-class, $delimiter, $key, $suffix-str, $variant-suffix, $override);
}
}
}
Expand Down Expand Up @@ -88,7 +88,7 @@ $default-variant-delimiter: '\\:';
$value,
$override
)
using ($variant-prefix, $prefix, $common-class, $delimiter, $key, $suffix-str, $variant-suffix) {
using ($variant-prefix, $prefix, $common-class, $delimiter, $key, $suffix-str, $variant-suffix, $override) {
.#{$variant-prefix}#{$prefix}#{$common-class}#{$key}#{$suffix-str}#{$variant-suffix} {
@include mixins.explode-properties($value, $override);
}
Expand Down Expand Up @@ -159,7 +159,7 @@ $default-variant-delimiter: '\\:';
}

@media (prefers-color-scheme: #{$variant}) {
@content ($variant-prefix, $prefix, $common-class, $delimiter, $key, $suffix-str, $variant-suffix);
@content ($variant-prefix, $prefix, $common-class, $delimiter, $key, $suffix-str, $variant-suffix, $override);
}
} @else if $variant == 'reduce-motion' {
$variant-prefix: '';
Expand All @@ -174,7 +174,7 @@ $default-variant-delimiter: '\\:';
}

@media (prefers-reduced-motion: reduce) {
@content ($variant-prefix, $prefix, $common-class, $delimiter, $key, $suffix-str, $variant-suffix);
@content ($variant-prefix, $prefix, $common-class, $delimiter, $key, $suffix-str, $variant-suffix, $override);
}
} @else {
$variant-prefix: '';
Expand All @@ -189,7 +189,7 @@ $default-variant-delimiter: '\\:';
$suffix-str: $delimiter + $suffix;
}

@content ($variant-prefix, $prefix, $common-class, $delimiter, $key, $suffix-str, $variant-suffix);
@content ($variant-prefix, $prefix, $common-class, $delimiter, $key, $suffix-str, $variant-suffix, $override);
}
}

Expand Down
4 changes: 2 additions & 2 deletions tests/internal/_generator.spec.scss
Original file line number Diff line number Diff line change
Expand Up @@ -150,11 +150,11 @@
$generate-viewports: 'true',
$override: '!important'
)
using ($variant-prefix, $prefix, $common-class, $delimiter, $key, $suffix-str, $variant-suffix) {
using ($variant-prefix, $prefix, $common-class, $delimiter, $key, $suffix-str, $variant-suffix, $override) {
$colors: red, white;
@each $color in $colors {
.#{$variant-prefix}#{$prefix}#{$color}#{$suffix-str}#{$variant-suffix} {
color: #{$color} !important;
color: #{$color} #{$override};
}
}
}
Expand Down

0 comments on commit f859448

Please sign in to comment.