Skip to content

Commit

Permalink
Add logical properties support for float and clear (#12480)
Browse files Browse the repository at this point in the history
  • Loading branch information
datlechin authored Nov 27, 2023
1 parent ec0fe42 commit bce0481
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/corePlugins.js
Original file line number Diff line number Diff line change
Expand Up @@ -684,6 +684,8 @@ export let corePlugins = {

float: ({ addUtilities }) => {
addUtilities({
'.float-start': { float: 'inline-start' },
'.float-end': { float: 'inline-end' },
'.float-right': { float: 'right' },
'.float-left': { float: 'left' },
'.float-none': { float: 'none' },
Expand All @@ -692,6 +694,8 @@ export let corePlugins = {

clear: ({ addUtilities }) => {
addUtilities({
'.clear-start': { clear: 'inline-start' },
'.clear-end': { clear: 'inline-end' },
'.clear-left': { clear: 'left' },
'.clear-right': { clear: 'right' },
'.clear-both': { clear: 'both' },
Expand Down
8 changes: 8 additions & 0 deletions tests/plugins/__snapshots__/clear.test.js.snap
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,14 @@

exports[`should test the 'clear' plugin 1`] = `
"
.clear-start {
clear: inline-start;
}
.clear-end {
clear: inline-end;
}
.clear-left {
clear: left;
}
Expand Down
8 changes: 8 additions & 0 deletions tests/plugins/__snapshots__/float.test.js.snap
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,14 @@

exports[`should test the 'float' plugin 1`] = `
"
.float-start {
float: inline-start;
}
.float-end {
float: inline-end;
}
.float-right {
float: right;
}
Expand Down

0 comments on commit bce0481

Please sign in to comment.