tailwindcss
tailwindcss copied to clipboard
v3: Allow hyphen character in regex pattern to use support queries as is
This is the v3 equivalent of PR #13596
Matching for the hyphen character in the existing regex to use support queries as-is
Resolves #13594
Tests (w/ updated):
- ✅
supports-[display:grid]:grid - ✅
supports-[transform-origin:5%_5%]:underline - ✅
supports-[not(foo:bar)]:underline - ✅
supports-[(foo:bar)or(bar:baz)]:underline - ✅
supports-[(foo:bar)and(bar:baz)]:underline - ✅
supports-[(foo:bar)_and_(bar:baz)]:grid - ✅
supports-[(foo:bar)_and_(bar:baz)_or(baz:qux)]:grid - ✅
supports-[container-type]:underline - ✅
supports-grid:underline - ✅
supports-[--test]:flex - ✅
supports-[selector(A_>_B)]:underline - ✅
supports-[font-format(opentype)]:grid - ✅
supports-[font-tech(color-COLRv1)]:flex
@adamwathan @RobinMalfait Just a reminder that this PR is ready to merge (after syncing).
Its v4 equivalent was merged via #13596.
This PR resolves issue https://github.com/tailwindlabs/tailwindcss/issues/13594#issuecomment-2081229532.