* Ensure max specificity of 001 in all Preflight rules
* Update changelog
* Update changelog
---------
Co-authored-by: Adam Wathan <4323180+adamwathan@users.noreply.github.com>
Co-authored-by: Jordan Pittman <jordan@cryptica.me>
* 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>
* add `*` as child variant
* add `*` as allowed variant character
* update test to reflect Lightning CSS output
* add `childVariant` test
* Update changelog
---------
Co-authored-by: Adam Wathan <4323180+adamwathan@users.noreply.github.com>
Co-authored-by: Robin Malfait <malfait.robin@gmail.com>
Co-authored-by: Gregor Kaczmarczyk <github@aggreggator.de>
* feat(preflight): simplify sans-serif font stack
`-apple-system` and `BlinkMacSystemFont` were historically needed for
IE11 and chakra-based Edge (The one that wasn't chromium-based).
https://caniuse.com/font-family-system-ui has more details around it.
* further simplify `font-family`
* update tests
* update changelog
---------
Co-authored-by: Robin Malfait <malfait.robin@gmail.com>
* Add forced-colors variant
Also add a contrast-custom variant to match custom contrast preferences
* use `toMatchSnapshot` instead of `toMatchFormattedCss`
More info: https://github.com/tailwindlabs/tailwindcss/pull/12170
* remove `contrast-custom` variant
* move `forcedColorsVariants` next to `prefersContrastVariants`
* update changelog
---------
Co-authored-by: Robin Malfait <malfait.robin@gmail.com>
* Add forced-colors-adjust utilities
* Update forcedColorsAdjust.test.js
* use `toMatchSnapshot` instead of `toMatchFormattedCss`
More info: https://github.com/tailwindlabs/tailwindcss/pull/12170
* rename `forced-colors-adjust` -> `forced-color-adjust`
Dropped the `s` in `colors`.
* update changelog
* fix typo
* use full `forced-color-adjust-auto` and `forced-color-adjust-none` names
---------
Co-authored-by: Robin Malfait <malfait.robin@gmail.com>
* Extend current preflight `html` styles to support other root/host scopes
Supports SVG root scope, ShadowDOM, and presumably other root scopes
* Replace `:root` with `html`
* Update tests
* Update changelog
---------
Co-authored-by: Jonathan Reinink <jonathan@reinink.ca>
* Extend opacity scale to include all steps of 5
* Update changelog
---------
Co-authored-by: Adam Wathan <4323180+adamwathan@users.noreply.github.com>
* Add `has-*` variants for `:has(...)` pseudo-class
* Update changelog
* Fix mistake in test
---------
Co-authored-by: Adam Wathan <4323180+adamwathan@users.noreply.github.com>
* add test to verify `["util1","util2"]` works
* update extractor regex, to reduce valid values in the arbitrary value part
Co-authored-by: Autom <mijnnaamis2112@hotmail.com>
* add special case with deeply nested `[]`
* update changelog
* move oxide changelog itemsto the bottom
---------
Co-authored-by: Autom <mijnnaamis2112@hotmail.com>
* Refactor
* Keep traversing sibling nodes
* Make sure the root node has a source location for the end
* Add source map test for at-rule variants
* Update changelog
* Generate types: do not intersect with Config theme type when generating DefaultTheme
* Merge default theme in ResolvedConfig
* UnwrapResolvables on theme.extend as well
* Apply extend to overrides and default theme
* Omit extend from DefaultTheme
* Relax generic constraints, better generic variable names
* Fall back to ThemeConfig if key not in DefaultTheme
* Split out ThemeConfigCustomizable to avoid anys in ThemeConfigResolved
* Allow custom theme properties
* handle TypeScript error
* apply prettier formatting
* update changelog
* change type name
---------
Co-authored-by: Nikita Gaidakov <ngaidakov@podfather.com>
Co-authored-by: Robin Malfait <malfait.robin@gmail.com>