Skip to content

Commit 086c0bf

Browse files
authored
🐛 Enable 0.x with negative margins @ v4 (#33593)
* 🐛 Enable `0.x` with negative margins @ v4 I set it as below, but no negative margin was added. `$spacers: (0\.5: ($spacer * .125));` After investigating, it seems that `0 \ .5` is also evaluated as 0. So I changed it to string comparison. HTML example: `<img class="mt-n0.5">` * 💚 Clear CI errors
1 parent 538ea32 commit 086c0bf

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

scss/utilities/_spacing.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@
3030

3131
// Negative margins (e.g., where `.mb-n1` is negative version of `.mb-1`)
3232
@each $size, $length in $spacers {
33-
@if $size != 0 {
33+
@if "#{$size}" != "0" {
3434
.m#{$infix}-n#{$size} { margin: -$length !important; }
3535
.mt#{$infix}-n#{$size},
3636
.my#{$infix}-n#{$size} {

0 commit comments

Comments
 (0)