From 2050a5ad061365140332a2ad89ac90feb9b5fb65 Mon Sep 17 00:00:00 2001 From: Robin Malfait Date: Fri, 21 Feb 2025 11:21:23 +0100 Subject: [PATCH 01/11] update tests to reflect order change --- .../tailwindcss/src/compat/plugin-api.test.ts | 16 +-- packages/tailwindcss/src/utilities.test.ts | 128 +++++++++--------- 2 files changed, 72 insertions(+), 72 deletions(-) diff --git a/packages/tailwindcss/src/compat/plugin-api.test.ts b/packages/tailwindcss/src/compat/plugin-api.test.ts index 14d0849a4eec..b786f2311e28 100644 --- a/packages/tailwindcss/src/compat/plugin-api.test.ts +++ b/packages/tailwindcss/src/compat/plugin-api.test.ts @@ -3047,6 +3047,14 @@ describe('addUtilities()', () => { ).toMatchInlineSnapshot( ` "@layer utilities { + .j { + &.j { + color: red; + } + .j& { + color: red; + } + } .a { & .b:hover .c { color: red; @@ -3087,14 +3095,6 @@ describe('addUtilities()', () => { color: red; } } - .j { - &.j { - color: red; - } - .j& { - color: red; - } - } }" `, ) diff --git a/packages/tailwindcss/src/utilities.test.ts b/packages/tailwindcss/src/utilities.test.ts index 79ac4700655e..6eae5013029e 100644 --- a/packages/tailwindcss/src/utilities.test.ts +++ b/packages/tailwindcss/src/utilities.test.ts @@ -4214,16 +4214,16 @@ test('translate-y', async () => { test('translate-z', async () => { expect(await run(['translate-y-px', '-translate-z-[var(--value)]'])).toMatchInlineSnapshot(` - ".translate-y-px { - --tw-translate-y: 1px; - translate: var(--tw-translate-x) var(--tw-translate-y); - } - - .-translate-z-\\[var\\(--value\\)\\] { + ".-translate-z-\\[var\\(--value\\)\\] { --tw-translate-z: calc(var(--value) * -1); translate: var(--tw-translate-x) var(--tw-translate-y) var(--tw-translate-z); } + .translate-y-px { + --tw-translate-y: 1px; + translate: var(--tw-translate-x) var(--tw-translate-y); + } + @property --tw-translate-x { syntax: "*"; inherits: false; @@ -12573,6 +12573,10 @@ test('font', async () => { --font-weight-bold: 650; } + .font-sans { + font-family: var(--font-sans); + } + .font-\\[\\"arial_rounded\\"\\] { font-family: arial rounded; } @@ -12585,10 +12589,6 @@ test('font', async () => { font-family: ui-sans-serif; } - .font-sans { - font-family: var(--font-sans); - } - .font-\\[100\\] { --tw-font-weight: 100; font-weight: 100; @@ -14155,15 +14155,7 @@ test('contain', async () => { 'contain-[unset]', ]), ).toMatchInlineSnapshot(` - ".contain-\\[unset\\] { - contain: unset; - } - - .contain-content { - contain: content; - } - - .contain-inline-size { + ".contain-inline-size { --tw-contain-size: inline-size; contain: var(--tw-contain-size, ) var(--tw-contain-layout, ) var(--tw-contain-paint, ) var(--tw-contain-style, ); } @@ -14173,10 +14165,6 @@ test('contain', async () => { contain: var(--tw-contain-size, ) var(--tw-contain-layout, ) var(--tw-contain-paint, ) var(--tw-contain-style, ); } - .contain-none { - contain: none; - } - .contain-paint { --tw-contain-paint: paint; contain: var(--tw-contain-size, ) var(--tw-contain-layout, ) var(--tw-contain-paint, ) var(--tw-contain-style, ); @@ -14187,15 +14175,27 @@ test('contain', async () => { contain: var(--tw-contain-size, ) var(--tw-contain-layout, ) var(--tw-contain-paint, ) var(--tw-contain-style, ); } - .contain-strict { - contain: strict; - } - .contain-style { --tw-contain-style: style; contain: var(--tw-contain-size, ) var(--tw-contain-layout, ) var(--tw-contain-paint, ) var(--tw-contain-style, ); } + .contain-\\[unset\\] { + contain: unset; + } + + .contain-content { + contain: content; + } + + .contain-none { + contain: none; + } + + .contain-strict { + contain: strict; + } + @property --tw-contain-size { syntax: "*"; inherits: false @@ -14424,10 +14424,6 @@ test('font-variant-numeric', async () => { font-variant-numeric: var(--tw-ordinal, ) var(--tw-slashed-zero, ) var(--tw-numeric-figure, ) var(--tw-numeric-spacing, ) var(--tw-numeric-fraction, ); } - .normal-nums { - font-variant-numeric: normal; - } - .oldstyle-nums { --tw-numeric-figure: oldstyle-nums; font-variant-numeric: var(--tw-ordinal, ) var(--tw-slashed-zero, ) var(--tw-numeric-figure, ) var(--tw-numeric-spacing, ) var(--tw-numeric-fraction, ); @@ -14458,6 +14454,10 @@ test('font-variant-numeric', async () => { font-variant-numeric: var(--tw-ordinal, ) var(--tw-slashed-zero, ) var(--tw-numeric-figure, ) var(--tw-numeric-spacing, ) var(--tw-numeric-fraction, ); } + .normal-nums { + font-variant-numeric: normal; + } + @property --tw-ordinal { syntax: "*"; inherits: false @@ -16385,28 +16385,28 @@ test('@container', async () => { '@container-[size]/sidebar', ]), ).toMatchInlineSnapshot(` - ".\\@container { - container-type: inline-size; + ".\\@container-\\[size\\]\\/sidebar { + container: sidebar / size; } - .\\@container-\\[size\\] { - container-type: size; + .\\@container-normal\\/sidebar { + container: sidebar; } - .\\@container-\\[size\\]\\/sidebar { - container: sidebar / size; + .\\@container\\/sidebar { + container: sidebar / inline-size; } - .\\@container-normal { - container-type: normal; + .\\@container { + container-type: inline-size; } - .\\@container-normal\\/sidebar { - container: sidebar; + .\\@container-\\[size\\] { + container-type: size; } - .\\@container\\/sidebar { - container: sidebar / inline-size; + .\\@container-normal { + container-type: normal; }" `) expect( @@ -17579,24 +17579,24 @@ describe('custom utilities', () => { 'example-[12px]/[16px]', ]), ).toMatchInlineSnapshot(` - ".example-\\[12px\\] { - --value: 12px; - } - - .example-\\[12px\\]\\/\\[16px\\] { + ".example-\\[12px\\]\\/\\[16px\\] { --value: 12px; --modifier: 16px; --modifier-with-calc: calc(16px * 2); } - .example-sm { - --value: var(--value-sm); - } - .example-sm\\/7 { --value: var(--value-sm); --modifier: var(--modifier-7); --modifier-with-calc: calc(var(--modifier-7) * 2); + } + + .example-\\[12px\\] { + --value: 12px; + } + + .example-sm { + --value: var(--value-sm); }" `) expect( @@ -17651,15 +17651,15 @@ describe('custom utilities', () => { ` expect(await compileCss(input, ['example-xs', 'example-xs/6'])).toMatchInlineSnapshot(` - ".example-xs { + ".example-xs\\/6 { font-size: var(--text-xs); line-height: var(--text-xs--line-height); + line-height: 6; } - .example-xs\\/6 { + .example-xs { font-size: var(--text-xs); line-height: var(--text-xs--line-height); - line-height: 6; }" `) expect(await compileCss(input, ['example-foo', 'example-xs/foo'])).toEqual('') @@ -17682,15 +17682,15 @@ describe('custom utilities', () => { ` expect(await compileCss(input, ['example-xs', 'example-xs/6'])).toMatchInlineSnapshot(` - ".example-xs { + ".example-xs\\/6 { font-size: var(--text-xs); line-height: var(--text-xs--line-height); + line-height: 6; } - .example-xs\\/6 { + .example-xs { font-size: var(--text-xs); line-height: var(--text-xs--line-height); - line-height: 6; }" `) expect(await compileCss(input, ['example-foo', 'example-xs/foo'])).toEqual('') @@ -17713,15 +17713,15 @@ describe('custom utilities', () => { ` expect(await compileCss(input, ['example-xs', 'example-xs/6'])).toMatchInlineSnapshot(` - ".example-xs { + ".example-xs\\/6 { font-size: var(--text-xs); line-height: var(--text-xs--line-height); + line-height: 6; } - .example-xs\\/6 { + .example-xs { font-size: var(--text-xs); line-height: var(--text-xs--line-height); - line-height: 6; }" `) expect(await compileCss(input, ['example-foo', 'example-xs/foo'])).toEqual('') @@ -17744,15 +17744,15 @@ describe('custom utilities', () => { ` expect(await compileCss(input, ['example-xs', 'example-xs/6'])).toMatchInlineSnapshot(` - ".example-xs { + ".example-xs\\/6 { font-size: var(--text-xs); line-height: var(--text-xs--line-height); + line-height: 6; } - .example-xs\\/6 { + .example-xs { font-size: var(--text-xs); line-height: var(--text-xs--line-height); - line-height: 6; }" `) expect(await compileCss(input, ['example-foo', 'example-xs/foo'])).toEqual('') From c5f21f896fe5e87d9f3ed7cb1c6173baa9102a0e Mon Sep 17 00:00:00 2001 From: Robin Malfait Date: Fri, 21 Feb 2025 11:21:38 +0100 Subject: [PATCH 02/11] track total order and total property count --- packages/tailwindcss/src/compile.ts | 48 +++++++++++++++++++---------- 1 file changed, 31 insertions(+), 17 deletions(-) diff --git a/packages/tailwindcss/src/compile.ts b/packages/tailwindcss/src/compile.ts index 6b48073b5823..749a3024e4e2 100644 --- a/packages/tailwindcss/src/compile.ts +++ b/packages/tailwindcss/src/compile.ts @@ -23,7 +23,7 @@ export function compileCandidates( ) { let nodeSorting = new Map< AstNode, - { properties: number[]; variants: bigint; candidate: string } + { properties: { order: number[]; count: number }; variants: bigint; candidate: string } >() let astNodes: AstNode[] = [] let matches = new Map() @@ -95,18 +95,19 @@ export function compileCandidates( // Find the first property that is different between the two rules let offset = 0 while ( - aSorting.properties.length < offset && - zSorting.properties.length < offset && - aSorting.properties[offset] === zSorting.properties[offset] + aSorting.properties.order.length < offset && + zSorting.properties.order.length < offset && + aSorting.properties.order[offset] === zSorting.properties.order[offset] ) { offset += 1 } return ( // Sort by lowest property index first - (aSorting.properties[offset] ?? Infinity) - (zSorting.properties[offset] ?? Infinity) || + (aSorting.properties.order[offset] ?? Infinity) - + (zSorting.properties.order[offset] ?? Infinity) || // Sort by most properties first, then by least properties - zSorting.properties.length - aSorting.properties.length || + zSorting.properties.count - aSorting.properties.count || // Sort alphabetically compare(aSorting.candidate, zSorting.candidate) ) @@ -124,7 +125,10 @@ export function compileAstNodes(candidate: Candidate, designSystem: DesignSystem let rules: { node: AstNode - propertySort: number[] + propertySort: { + order: number[] + count: number + } }[] = [] let selector = `.${escape(candidate.raw)}` @@ -310,24 +314,31 @@ function applyImportant(ast: AstNode[]): void { function getPropertySort(nodes: AstNode[]) { // Determine sort order based on properties used - let propertySort = new Set() + let order = new Set() + let count = 0 let q: AstNode[] = nodes.slice() + let seenTwSort = false + while (q.length > 0) { // SAFETY: At this point it is safe to use TypeScript's non-null assertion // operator because we guarded against `q.length > 0` above. let node = q.shift()! if (node.kind === 'declaration') { - if (node.property === '--tw-sort') { - let idx = GLOBAL_PROPERTY_ORDER.indexOf(node.value ?? '') - if (idx !== -1) { - propertySort.add(idx) - break + count++ + + if (!seenTwSort) { + if (node.property === '--tw-sort') { + let idx = GLOBAL_PROPERTY_ORDER.indexOf(node.value ?? '') + if (idx !== -1) { + order.add(idx) + seenTwSort = true + } } - } - let idx = GLOBAL_PROPERTY_ORDER.indexOf(node.property) - if (idx !== -1) propertySort.add(idx) + let idx = GLOBAL_PROPERTY_ORDER.indexOf(node.property) + if (idx !== -1) order.add(idx) + } } else if (node.kind === 'rule' || node.kind === 'at-rule') { for (let child of node.nodes) { q.push(child) @@ -335,5 +346,8 @@ function getPropertySort(nodes: AstNode[]) { } } - return Array.from(propertySort).sort((a, z) => a - z) + return { + order: Array.from(order).sort((a, z) => a - z), + count, + } } From bee815e22164de48b74acc785a40b7519adeabe7 Mon Sep 17 00:00:00 2001 From: Robin Malfait Date: Fri, 21 Feb 2025 11:26:16 +0100 Subject: [PATCH 03/11] add integration test to verify `prose-invert` exists after `prose-stone` --- integrations/cli/plugins.test.ts | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/integrations/cli/plugins.test.ts b/integrations/cli/plugins.test.ts index 833b0f6779a6..0597e247be50 100644 --- a/integrations/cli/plugins.test.ts +++ b/integrations/cli/plugins.test.ts @@ -14,7 +14,7 @@ test( } `, 'index.html': html` -
+

Headline

Until now, trying to style an article, document, or blog post with Tailwind has been a @@ -28,9 +28,18 @@ test( `, }, }, - async ({ fs, exec }) => { + async ({ fs, exec, expect }) => { await exec('pnpm tailwindcss --input src/index.css --output dist/out.css') + // Verify that `prose-stone` is defined before `prose-invert` + { + let contents = await fs.read('dist/out.css') + let proseInvertIdx = contents.indexOf('.prose-invert') + let proseStoneIdx = contents.indexOf('.prose-stone') + + expect(proseStoneIdx).toBeLessThan(proseInvertIdx) + } + await fs.expectFileToContain('dist/out.css', [ candidate`prose`, ':where(h1):not(:where([class~="not-prose"],[class~="not-prose"] *))', From 74799f6b90e81f3fc8d1cea4803830fbeb664103 Mon Sep 17 00:00:00 2001 From: Robin Malfait Date: Fri, 21 Feb 2025 11:41:26 +0100 Subject: [PATCH 04/11] update changelog --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 702e1e2af3ee..757bdbe5eefe 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -23,6 +23,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - Vite: Ensure Astro production builds contain classes for client-only components ([#16631](https://github.com/tailwindlabs/tailwindcss/pull/16631)) - Vite: Ensure utility classes are read without escaping special characters ([#16631](https://github.com/tailwindlabs/tailwindcss/pull/16631)) - Allow `theme(…)` options when using `@import` ([#16514](https://github.com/tailwindlabs/tailwindcss/pull/16514)) +- Use amount of properties when sorting ([#16715](https://github.com/tailwindlabs/tailwindcss/pull/16715)) ## [4.0.7] - 2025-02-18 From 17aa1b029ad984df3fad61464b3f1975b6e35d60 Mon Sep 17 00:00:00 2001 From: Robin Malfait Date: Fri, 21 Feb 2025 12:04:27 +0100 Subject: [PATCH 05/11] use early return --- packages/tailwindcss/src/compile.ts | 21 +++++++++++---------- 1 file changed, 11 insertions(+), 10 deletions(-) diff --git a/packages/tailwindcss/src/compile.ts b/packages/tailwindcss/src/compile.ts index 749a3024e4e2..69165ab1d673 100644 --- a/packages/tailwindcss/src/compile.ts +++ b/packages/tailwindcss/src/compile.ts @@ -327,18 +327,19 @@ function getPropertySort(nodes: AstNode[]) { if (node.kind === 'declaration') { count++ - if (!seenTwSort) { - if (node.property === '--tw-sort') { - let idx = GLOBAL_PROPERTY_ORDER.indexOf(node.value ?? '') - if (idx !== -1) { - order.add(idx) - seenTwSort = true - } + if (seenTwSort) continue + + if (node.property === '--tw-sort') { + let idx = GLOBAL_PROPERTY_ORDER.indexOf(node.value ?? '') + if (idx !== -1) { + order.add(idx) + seenTwSort = true + continue } - - let idx = GLOBAL_PROPERTY_ORDER.indexOf(node.property) - if (idx !== -1) order.add(idx) } + + let idx = GLOBAL_PROPERTY_ORDER.indexOf(node.property) + if (idx !== -1) order.add(idx) } else if (node.kind === 'rule' || node.kind === 'at-rule') { for (let child of node.nodes) { q.push(child) From dbebcb76d5e886bf3444c543ffab353be66d8234 Mon Sep 17 00:00:00 2001 From: Robin Malfait Date: Fri, 21 Feb 2025 12:28:42 +0100 Subject: [PATCH 06/11] add missing `--tw-translate-z` to property-order list --- packages/tailwindcss/src/property-order.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/packages/tailwindcss/src/property-order.ts b/packages/tailwindcss/src/property-order.ts index 90290d54c0a3..f2ed4bc51721 100644 --- a/packages/tailwindcss/src/property-order.ts +++ b/packages/tailwindcss/src/property-order.ts @@ -75,6 +75,7 @@ export default [ 'translate', '--tw-translate-x', '--tw-translate-y', + '--tw-translate-z', 'scale', '--tw-scale-x', '--tw-scale-y', From ba67f6a98b43c6aaf6c761746a20835db5f2e4ad Mon Sep 17 00:00:00 2001 From: Robin Malfait Date: Fri, 21 Feb 2025 12:29:00 +0100 Subject: [PATCH 07/11] fix swapped conditions --- packages/tailwindcss/src/compile.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/tailwindcss/src/compile.ts b/packages/tailwindcss/src/compile.ts index 69165ab1d673..5764e40247bb 100644 --- a/packages/tailwindcss/src/compile.ts +++ b/packages/tailwindcss/src/compile.ts @@ -95,8 +95,8 @@ export function compileCandidates( // Find the first property that is different between the two rules let offset = 0 while ( - aSorting.properties.order.length < offset && - zSorting.properties.order.length < offset && + offset < aSorting.properties.order.length && + offset < zSorting.properties.order.length && aSorting.properties.order[offset] === zSorting.properties.order[offset] ) { offset += 1 From 35542b1ea4141f1d2e07e9242d93c13a624cdf4e Mon Sep 17 00:00:00 2001 From: Robin Malfait Date: Fri, 21 Feb 2025 12:29:40 +0100 Subject: [PATCH 08/11] fix incorrect sort --- packages/tailwindcss/src/utilities.test.ts | 32 +++++++++++----------- 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/packages/tailwindcss/src/utilities.test.ts b/packages/tailwindcss/src/utilities.test.ts index 6eae5013029e..213e6e4cf1f1 100644 --- a/packages/tailwindcss/src/utilities.test.ts +++ b/packages/tailwindcss/src/utilities.test.ts @@ -4214,16 +4214,16 @@ test('translate-y', async () => { test('translate-z', async () => { expect(await run(['translate-y-px', '-translate-z-[var(--value)]'])).toMatchInlineSnapshot(` - ".-translate-z-\\[var\\(--value\\)\\] { - --tw-translate-z: calc(var(--value) * -1); - translate: var(--tw-translate-x) var(--tw-translate-y) var(--tw-translate-z); - } - - .translate-y-px { + ".translate-y-px { --tw-translate-y: 1px; translate: var(--tw-translate-x) var(--tw-translate-y); } + .-translate-z-\\[var\\(--value\\)\\] { + --tw-translate-z: calc(var(--value) * -1); + translate: var(--tw-translate-x) var(--tw-translate-y) var(--tw-translate-z); + } + @property --tw-translate-x { syntax: "*"; inherits: false; @@ -5458,12 +5458,7 @@ test('touch-pan', async () => { 'touch-pan-down', ]), ).toMatchInlineSnapshot(` - ".touch-pan-down { - --tw-pan-y: pan-down; - touch-action: var(--tw-pan-x, ) var(--tw-pan-y, ) var(--tw-pinch-zoom, ); - } - - .touch-pan-left { + ".touch-pan-left { --tw-pan-x: pan-left; touch-action: var(--tw-pan-x, ) var(--tw-pan-y, ) var(--tw-pinch-zoom, ); } @@ -5473,13 +5468,18 @@ test('touch-pan', async () => { touch-action: var(--tw-pan-x, ) var(--tw-pan-y, ) var(--tw-pinch-zoom, ); } - .touch-pan-up { - --tw-pan-y: pan-up; + .touch-pan-x { + --tw-pan-x: pan-x; touch-action: var(--tw-pan-x, ) var(--tw-pan-y, ) var(--tw-pinch-zoom, ); } - .touch-pan-x { - --tw-pan-x: pan-x; + .touch-pan-down { + --tw-pan-y: pan-down; + touch-action: var(--tw-pan-x, ) var(--tw-pan-y, ) var(--tw-pinch-zoom, ); + } + + .touch-pan-up { + --tw-pan-y: pan-up; touch-action: var(--tw-pan-x, ) var(--tw-pan-y, ) var(--tw-pinch-zoom, ); } From fc8ffac9c12f442048ec7da413b6811497cea440 Mon Sep 17 00:00:00 2001 From: Robin Malfait Date: Fri, 21 Feb 2025 12:30:19 +0100 Subject: [PATCH 09/11] use correct `translate-z-*` property in `translate-z` tests --- packages/tailwindcss/src/utilities.test.ts | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/packages/tailwindcss/src/utilities.test.ts b/packages/tailwindcss/src/utilities.test.ts index 213e6e4cf1f1..710ceade2128 100644 --- a/packages/tailwindcss/src/utilities.test.ts +++ b/packages/tailwindcss/src/utilities.test.ts @@ -4213,14 +4213,15 @@ test('translate-y', async () => { }) test('translate-z', async () => { - expect(await run(['translate-y-px', '-translate-z-[var(--value)]'])).toMatchInlineSnapshot(` - ".translate-y-px { - --tw-translate-y: 1px; - translate: var(--tw-translate-x) var(--tw-translate-y); + expect(await run(['translate-z-px', '-translate-z-[var(--value)]'])).toMatchInlineSnapshot(` + ".-translate-z-\\[var\\(--value\\)\\] { + --tw-translate-z: calc(var(--value) * -1); + translate: var(--tw-translate-x) var(--tw-translate-y) var(--tw-translate-z); } - .-translate-z-\\[var\\(--value\\)\\] { - --tw-translate-z: calc(var(--value) * -1); + .translate-z-px { + --tw-translate-z: 1px; + translate: var(--tw-translate-x) var(--tw-translate-y) var(--tw-translate-z); translate: var(--tw-translate-x) var(--tw-translate-y) var(--tw-translate-z); } From 7b18c796782c540beb90274bc91c52733d761917 Mon Sep 17 00:00:00 2001 From: Robin Malfait Date: Fri, 21 Feb 2025 12:33:54 +0100 Subject: [PATCH 10/11] only count declarations with a value set --- packages/tailwindcss/src/compile.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/packages/tailwindcss/src/compile.ts b/packages/tailwindcss/src/compile.ts index 5764e40247bb..269acee03d08 100644 --- a/packages/tailwindcss/src/compile.ts +++ b/packages/tailwindcss/src/compile.ts @@ -325,7 +325,8 @@ function getPropertySort(nodes: AstNode[]) { // operator because we guarded against `q.length > 0` above. let node = q.shift()! if (node.kind === 'declaration') { - count++ + // Empty strings should still be counted, e.g.: `--tw-foo:;` is valid + if (node.value !== undefined) count++ if (seenTwSort) continue From be480ec35fa660a462d9f2e101d7140e841d78e3 Mon Sep 17 00:00:00 2001 From: Robin Malfait Date: Fri, 21 Feb 2025 12:34:47 +0100 Subject: [PATCH 11/11] update tests --- packages/tailwindcss/src/utilities.test.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/packages/tailwindcss/src/utilities.test.ts b/packages/tailwindcss/src/utilities.test.ts index 710ceade2128..2f00dcebe4b0 100644 --- a/packages/tailwindcss/src/utilities.test.ts +++ b/packages/tailwindcss/src/utilities.test.ts @@ -12574,10 +12574,6 @@ test('font', async () => { --font-weight-bold: 650; } - .font-sans { - font-family: var(--font-sans); - } - .font-\\[\\"arial_rounded\\"\\] { font-family: arial rounded; } @@ -12590,6 +12586,10 @@ test('font', async () => { font-family: ui-sans-serif; } + .font-sans { + font-family: var(--font-sans); + } + .font-\\[100\\] { --tw-font-weight: 100; font-weight: 100;