tailwindcss/tests
Adam Wathan fbdb858e97 Improve relative precedence of rtl, ltr, forced-colors and dark variants (#12584)
* Reduce specificity of `rtl`, `ltr`, and `dark` variants

Reduce specificity of `rtl`, `ltr`, and `dark` variants (when using `darkMode: 'class'`) to make them the same as other variants. This also sorts the LTR/RTL and dark variants later in the variant plugin list to ensure that the reduced specificity doesn't cause them to start "losing" to other variants to keep things as backwards compatible as possible.

Resolves a long-standing issue where `darkMode: 'media'` and `darkMode: 'class'` had different specificity, which meant switching your dark mode strategy could break your site.

* Update changelog

---------

Co-authored-by: Adam Wathan <4323180+adamwathan@users.noreply.github.com>
2023-12-18 13:58:22 -05:00
..
fixtures remove unused fixture files 2021-12-15 18:13:09 +01:00
plugins Fix gradient stop positions with transparent colors and/or variants (#11002) 2023-04-13 16:12:12 -04:00
postcss-plugins/nesting Improve CSS output in tests to better reflect reality (#10454) 2023-01-31 15:37:49 +01:00
util Improve relative precedence of rtl, ltr, forced-colors and dark variants (#12584) 2023-12-18 13:58:22 -05:00
animations.test.js Escape animation names when prefixes contain special characters (#11470) 2023-07-13 11:48:35 -04:00
any-type.test.js Fix gradient stop positions with transparent colors and/or variants (#11002) 2023-04-13 16:12:12 -04:00
apply.test.js Improve relative precedence of rtl, ltr, forced-colors and dark variants (#12584) 2023-12-18 13:58:22 -05:00
arbitrary-properties.test.js Improve CSS output in tests to better reflect reality (#10454) 2023-01-31 15:37:49 +01:00
arbitrary-values.oxide.test.css Ensure repeating-conic-gradient is detected as an image (#11180) 2023-07-13 11:48:35 -04:00
arbitrary-values.test.css Ensure repeating-conic-gradient is detected as an image (#11180) 2023-07-13 11:48:35 -04:00
arbitrary-values.test.html Ensure repeating-conic-gradient is detected as an image (#11180) 2023-07-13 11:48:35 -04:00
arbitrary-values.test.js Fix candidate detection regex 2023-12-04 11:23:33 -05:00
arbitrary-variants.test.js Add has-* variants for :has(...) pseudo-class (#11318) 2023-12-18 13:57:08 -05:00
basic-usage.oxide.test.css feat(preflight): simplify sans-serif font stack (#11748) 2023-12-18 13:58:22 -05:00
basic-usage.test.css feat(preflight): simplify sans-serif font stack (#11748) 2023-12-18 13:58:22 -05:00
basic-usage.test.js Add support for text-wrap property (#11320) 2023-12-18 13:57:22 -05:00
blocklist.test.js refactor log.warn checks in tests 2023-03-17 14:49:36 +01:00
collapse-adjacent-rules.test.js Disable color opacity plugins by default in the oxide engine (#10618) 2023-02-17 20:21:22 +01:00
collapse-duplicate-declarations.test.js Improve CSS output in tests to better reflect reality (#10454) 2023-01-31 15:37:49 +01:00
color-opacity-modifiers.test.js Fix gradient stop positions with transparent colors and/or variants (#11002) 2023-04-13 16:12:12 -04:00
color.test.js Parse alpha value from rgba/hsla colors when using variables (#10429) 2023-01-31 14:36:38 -05:00
combined-selectors.test.js Improve CSS output in tests to better reflect reality (#10454) 2023-01-31 15:37:49 +01:00
configurePlugins.test.js Run test suite against both engines (#10373) 2023-01-20 18:45:04 +01:00
containerPlugin.test.js Improve CSS output in tests to better reflect reality (#10454) 2023-01-31 15:37:49 +01:00
context-reuse.test.html inline tests (#10362) 2023-01-19 11:42:52 +01:00
context-reuse.test.js Improve CSS output in tests to better reflect reality (#10454) 2023-01-31 15:37:49 +01:00
custom-extractors.test.js Run test suite against both engines (#10373) 2023-01-20 18:45:04 +01:00
custom-plugins.test.js Improve CSS output in tests to better reflect reality (#10454) 2023-01-31 15:37:49 +01:00
custom-separator.test.js Improve relative precedence of rtl, ltr, forced-colors and dark variants (#12584) 2023-12-18 13:58:22 -05:00
custom-transformers.test.js Run test suite against both engines (#10373) 2023-01-20 18:45:04 +01:00
customConfig.test.js Enable ESM and TS based config files (#10785) 2023-03-15 17:04:18 -04:00
dark-mode.test.js Improve relative precedence of rtl, ltr, forced-colors and dark variants (#12584) 2023-12-18 13:58:22 -05:00
default-extractor.test.js Fix support for container query utilities with arbitrary values (#12534) 2023-12-05 12:27:48 -05:00
defaultConfig.test.js Enable ESM and TS based config files (#10785) 2023-03-15 17:04:18 -04:00
defaultTheme.test.js Enable ESM and TS based config files (#10785) 2023-03-15 17:04:18 -04:00
detect-nesting.test.js Run test suite against both engines (#10373) 2023-01-20 18:45:04 +01:00
escapeClassName.test.js Run test suite against both engines (#10373) 2023-01-20 18:45:04 +01:00
evaluateTailwindFunctions.test.js Fix incorrectly generated CSS when using square brackets inside arbitrary properties (#11709) 2023-10-23 15:25:03 -04:00
experimental.test.js Use :is to make important selector option insensitive to DOM order (#10835) 2023-03-21 17:50:44 +01:00
extractor-edge-cases.test.js Run test suite against both engines (#10373) 2023-01-20 18:45:04 +01:00
flattenColorPalette.test.js Run test suite against both engines (#10373) 2023-01-20 18:45:04 +01:00
format-variant-selector.test.js Improve relative precedence of rtl, ltr, forced-colors and dark variants (#12584) 2023-12-18 13:58:22 -05:00
generate-rules.test.js Run test suite against both engines (#10373) 2023-01-20 18:45:04 +01:00
getClassList.test.js Extend opacity scale to include all steps of 5 (#11832) 2023-12-18 13:57:52 -05:00
getSortOrder.test.js Fix sorting of utilities that share multiple candidates (#12173) 2023-10-23 15:47:42 -04:00
getVariants.test.js Don't prefix arbitrary classes in peer/group variants (#11454) 2023-07-13 11:50:43 -04:00
import-syntax.test.js Disable color opacity plugins by default in the oxide engine (#10618) 2023-02-17 20:21:22 +01:00
important-boolean.test.js Improve relative precedence of rtl, ltr, forced-colors and dark variants (#12584) 2023-12-18 13:58:22 -05:00
important-modifier-prefix.test.js Run test suite against both engines (#10373) 2023-01-20 18:45:04 +01:00
important-modifier.test.js Fix use of :where(.btn) when matching !btn (#10601) 2023-02-16 10:13:42 -05:00
important-selector.test.js Improve relative precedence of rtl, ltr, forced-colors and dark variants (#12584) 2023-12-18 13:58:22 -05:00
kitchen-sink.test.js Improve relative precedence of rtl, ltr, forced-colors and dark variants (#12584) 2023-12-18 13:58:22 -05:00
layer-at-rules.test.js Improve CSS output in tests to better reflect reality (#10454) 2023-01-31 15:37:49 +01:00
layer-without-tailwind.test.js Improve CSS output in tests to better reflect reality (#10454) 2023-01-31 15:37:49 +01:00
match-components.test.js Improve CSS output in tests to better reflect reality (#10454) 2023-01-31 15:37:49 +01:00
match-utilities.test.js Revert "Prepare for the v3.2.6" 2023-02-08 17:39:43 +01:00
match-variants.test.js Disable color opacity plugins by default in the oxide engine (#10618) 2023-02-17 20:21:22 +01:00
min-max-screen-variants.test.js refactor log.warn checks in tests 2023-03-17 14:49:36 +01:00
minimum-impact-selector.test.js Run test suite against both engines (#10373) 2023-01-20 18:45:04 +01:00
modify-selectors.test.js Sort by layer inside variants layer (#10505) 2023-02-06 16:27:01 +01:00
mutable.test.js Run test suite against both engines (#10373) 2023-01-20 18:45:04 +01:00
negated-content-ignore.test.html Fix using negated content globs (#5625) 2021-09-29 11:15:31 +01:00
negated-content-include.test.html Fix using negated content globs (#5625) 2021-09-29 11:15:31 +01:00
negated-content.test.js Run test suite against both engines (#10373) 2023-01-20 18:45:04 +01:00
negateValue.test.js Run test suite against both engines (#10373) 2023-01-20 18:45:04 +01:00
negative-prefix.test.js Don't crash when given applying a variant to a negated version of a simple utility (#12514) 2023-12-01 11:46:18 -05:00
normalize-config.test.js refactor log.warn checks in tests 2023-03-17 14:49:36 +01:00
normalize-data-types.test.js Don’t add spaces to negative numbers following a comma (#12324) 2023-10-30 14:45:46 -04:00
normalize-screens.test.js Run test suite against both engines (#10373) 2023-01-20 18:45:04 +01:00
opacity.test.js Handle variable colors that have variable fallback values (#12049) 2023-10-23 15:25:58 -04:00
oxide-svelte.test.css Fix gradient stop positions with transparent colors and/or variants (#11002) 2023-04-13 16:12:12 -04:00
oxide.test.js Revert "Prepare for the v3.2.6" 2023-02-08 17:39:43 +01:00
oxide.test.svelte Oxide (#10252) 2023-01-13 12:22:00 +01:00
parallel-variants.test.js Don’t move unknown pseudo-elements to the end of selectors (#10962) 2023-04-07 10:45:47 -04:00
parseAnimationValue.test.js Run test suite against both engines (#10373) 2023-01-20 18:45:04 +01:00
parseObjectStyles.test.js Improve CSS output in tests to better reflect reality (#10454) 2023-01-31 15:37:49 +01:00
prefers-contrast.test.js Disable color opacity plugins by default in the oxide engine (#10618) 2023-02-17 20:21:22 +01:00
prefix.test.js Improve relative precedence of rtl, ltr, forced-colors and dark variants (#12584) 2023-12-18 13:58:22 -05:00
prefixSelector.test.js Run test suite against both engines (#10373) 2023-01-20 18:45:04 +01:00
preflight.test.js Use Lightning CSS in the PostCSS Plugin (#10399) 2023-01-23 20:44:31 +01:00
raw-content.oxide.test.css feat(preflight): simplify sans-serif font stack (#11748) 2023-12-18 13:58:22 -05:00
raw-content.test.css feat(preflight): simplify sans-serif font stack (#11748) 2023-12-18 13:58:22 -05:00
raw-content.test.js Revert "Prepare for the v3.2.6" 2023-02-08 17:39:43 +01:00
relative-purge-paths.test.html inline tests (#10362) 2023-01-19 11:42:52 +01:00
relative-purge-paths.test.js Run test suite against both engines (#10373) 2023-01-20 18:45:04 +01:00
resolve-defaults-at-rules.test.js Improve CSS output in tests to better reflect reality (#10454) 2023-01-31 15:37:49 +01:00
resolveConfig.test.js feat(preflight): simplify sans-serif font stack (#11748) 2023-12-18 13:58:22 -05:00
responsive-and-variants-atrules.test.js Improve CSS output in tests to better reflect reality (#10454) 2023-01-31 15:37:49 +01:00
safelist.test.js Disable color opacity plugins by default in the oxide engine (#10618) 2023-02-17 20:21:22 +01:00
screenAtRule.test.js Enable ESM and TS based config files (#10785) 2023-03-15 17:04:18 -04:00
shared-state.test.js Run test suite against both engines (#10373) 2023-01-20 18:45:04 +01:00
source-maps.test.js Disable tap highlights on iOS (#12299) 2023-12-18 13:58:22 -05:00
syntax-lit-html.test.js Disable color opacity plugins by default in the oxide engine (#10618) 2023-02-17 20:21:22 +01:00
syntax-svelte.test.js Run test suite against both engines (#10373) 2023-01-20 18:45:04 +01:00
syntax-svelte.test.svelte Rename svelte tests 2021-09-21 12:37:49 -04:00
tailwind-screens.test.js Improve CSS output in tests to better reflect reality (#10454) 2023-01-31 15:37:49 +01:00
to-path.test.js Run test suite against both engines (#10373) 2023-01-20 18:45:04 +01:00
variants.oxide.test.css Improve relative precedence of rtl, ltr, forced-colors and dark variants (#12584) 2023-12-18 13:58:22 -05:00
variants.test.css Improve relative precedence of rtl, ltr, forced-colors and dark variants (#12584) 2023-12-18 13:58:22 -05:00
variants.test.html Move forced-colors variant after dark variant (#12582) 2023-12-18 13:58:22 -05:00
variants.test.js Improve relative precedence of rtl, ltr, forced-colors and dark variants (#12584) 2023-12-18 13:58:22 -05:00
warnings.test.js refactor log.warn checks in tests 2023-03-17 14:49:36 +01:00
withAlphaVariable.test.js Run test suite against both engines (#10373) 2023-01-20 18:45:04 +01:00