Skip to content

Commit 82ca52a

Browse files
committed
fix: add RTL support
1 parent bf6a3e4 commit 82ca52a

File tree

2 files changed

+28
-4
lines changed

2 files changed

+28
-4
lines changed

scss/mixins/_float.scss

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,21 @@
11
// stylelint-disable declaration-no-important
22

33
@mixin float-left() {
4-
float: left !important;
4+
@include ltr {
5+
float: left !important;
6+
}
7+
@include rtl {
8+
float: right !important;
9+
}
510
@include deprecate("The `float-left` mixin", "v4.3.0", "v5");
611
}
712
@mixin float-right() {
8-
float: right !important;
13+
@include ltr {
14+
float: right !important;
15+
}
16+
@include rtl {
17+
float: left !important;
18+
}
919
@include deprecate("The `float-right` mixin", "v4.3.0", "v5");
1020
}
1121
@mixin float-none() {

scss/utilities/_float.scss

Lines changed: 16 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,22 @@
44
@include media-breakpoint-up($breakpoint) {
55
$infix: breakpoint-infix($breakpoint, $grid-breakpoints);
66

7-
.float#{$infix}-left { float: left !important; }
8-
.float#{$infix}-right { float: right !important; }
7+
.float#{$infix}-left {
8+
@include ltr {
9+
float: left !important;
10+
}
11+
@include rtl {
12+
float: right !important;
13+
}
14+
}
15+
.float#{$infix}-right {
16+
@include ltr {
17+
float: right !important;
18+
}
19+
@include rtl {
20+
float: left !important;
21+
}
22+
}
923
.float#{$infix}-none { float: none !important; }
1024
}
1125
}

0 commit comments

Comments
 (0)