diff --git a/src/lib/default-config.ts b/src/lib/default-config.ts index 438e0ad..68fb031 100644 --- a/src/lib/default-config.ts +++ b/src/lib/default-config.ts @@ -1658,6 +1658,11 @@ export const getDefaultConfig = () => { * @see https://tailwindcss.com/docs/just-in-time-mode#caret-color-utilities */ 'caret-color': [{ caret: [colors] }], + /** + * Field Sizing + * @see https://tailwindcss.com/docs/field-sizing + */ + 'field-sizing': [{ 'field-sizing': ['fixed', 'content'] }], /** * Pointer Events * @see https://tailwindcss.com/docs/pointer-events diff --git a/src/lib/types.ts b/src/lib/types.ts index efc2db6..c58346b 100644 --- a/src/lib/types.ts +++ b/src/lib/types.ts @@ -285,6 +285,7 @@ export type DefaultClassGroupIds = | 'duration' | 'ease' | 'end' + | 'field-sizing' | 'fill' | 'filter' | 'flex-direction' @@ -323,8 +324,8 @@ export type DefaultClassGroupIds = | 'indent' | 'inset-ring-color' | 'inset-ring-w' - | 'inset-shadow' | 'inset-shadow-color' + | 'inset-shadow' | 'inset-x' | 'inset-y' | 'inset' diff --git a/tests/class-map.test.ts b/tests/class-map.test.ts index 24e59d1..19f5744 100644 --- a/tests/class-map.test.ts +++ b/tests/class-map.test.ts @@ -109,6 +109,7 @@ test('class map has correct class groups at first part', () => { duration: ['duration'], ease: ['ease'], end: ['end'], + field: ['field-sizing'], fill: ['fill'], filter: ['filter'], fixed: ['position'], diff --git a/tests/tailwind-css-versions.test.ts b/tests/tailwind-css-versions.test.ts index add4964..63a3449 100644 --- a/tests/tailwind-css-versions.test.ts +++ b/tests/tailwind-css-versions.test.ts @@ -74,6 +74,7 @@ test('supports Tailwind CSS v4.0 features', () => { expect(twMerge('ring-4 ring-orange inset-ring inset-ring-3 inset-ring-blue')).toBe( 'ring-4 ring-orange inset-ring-3 inset-ring-blue', ) + expect(twMerge('field-sizing-content field-sizing-fixed')).toBe('field-sizing-fixed') // TODO: Remove proto expect(twMerge('')).toBe('')