Skip to content

Commit 983fd14

Browse files
reininkadamwathan
andcommitted
Tweak order of outline plugins
Co-Authored-By: Adam Wathan <[email protected]>
1 parent 3999253 commit 983fd14

File tree

4 files changed

+19
-19
lines changed

4 files changed

+19
-19
lines changed

src/corePlugins.js

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1801,6 +1801,14 @@ export let corePlugins = {
18011801
})
18021802
},
18031803

1804+
outlineWidth: createUtilityPlugin('outlineWidth', [['outline', ['outline-width']]], {
1805+
type: ['length', 'number', 'percentage'],
1806+
}),
1807+
1808+
outlineOffset: createUtilityPlugin('outlineOffset', [['outline-offset', ['outline-offset']]], {
1809+
type: ['length', 'number', 'percentage'],
1810+
}),
1811+
18041812
outlineColor: ({ matchUtilities, theme }) => {
18051813
matchUtilities(
18061814
{
@@ -1812,14 +1820,6 @@ export let corePlugins = {
18121820
)
18131821
},
18141822

1815-
outlineWidth: createUtilityPlugin('outlineWidth', [['outline', ['outline-width']]], {
1816-
type: ['length', 'number', 'percentage'],
1817-
}),
1818-
1819-
outlineOffset: createUtilityPlugin('outlineOffset', [['outline-offset', ['outline-offset']]], {
1820-
type: ['length', 'number', 'percentage'],
1821-
}),
1822-
18231823
ringWidth: ({ matchUtilities, addBase, addUtilities, theme }) => {
18241824
let ringOpacityDefault = theme('ringOpacity.DEFAULT', '0.5')
18251825
let ringColorDefault = withAlphaValue(

stubs/defaultConfig.stub.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -701,14 +701,14 @@ module.exports = {
701701
placeholderColor: ({ theme }) => theme('colors'),
702702
placeholderOpacity: ({ theme }) => theme('opacity'),
703703
outlineColor: ({ theme }) => theme('colors'),
704-
outlineWidth: {
704+
outlineOffset: {
705705
0: '0px',
706706
1: '1px',
707707
2: '2px',
708708
4: '4px',
709709
8: '8px',
710710
},
711-
outlineOffset: {
711+
outlineWidth: {
712712
0: '0px',
713713
1: '1px',
714714
2: '2px',

tests/arbitrary-values.test.css

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -859,12 +859,6 @@
859859
box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000),
860860
var(--tw-shadow);
861861
}
862-
.outline-\[black\] {
863-
outline-color: black;
864-
}
865-
.outline-\[color\:var\(--outline\)\] {
866-
outline-color: var(--outline);
867-
}
868862
.outline-\[10px\] {
869863
outline-width: 10px;
870864
}
@@ -874,6 +868,12 @@
874868
.outline-offset-\[10px\] {
875869
outline-offset: 10px;
876870
}
871+
.outline-\[black\] {
872+
outline-color: black;
873+
}
874+
.outline-\[color\:var\(--outline\)\] {
875+
outline-color: var(--outline);
876+
}
877877
.ring-\[10px\] {
878878
--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width)
879879
var(--tw-ring-offset-color);

tests/basic-usage.test.css

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -830,15 +830,15 @@
830830
.outline-none {
831831
outline-style: none;
832832
}
833-
.outline-black {
834-
outline-color: #000;
835-
}
836833
.outline-4 {
837834
outline-width: 4px;
838835
}
839836
.outline-offset-2 {
840837
outline-offset: 2px;
841838
}
839+
.outline-black {
840+
outline-color: #000;
841+
}
842842
.ring {
843843
--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width)
844844
var(--tw-ring-offset-color);

0 commit comments

Comments
 (0)