tailwindcss/packages
Adam Wathan cf77420b0c
Ensure --inset-ring=* and --inset-shadow-* variables are ignored by inset-* utilities (#14855)
This PR fixes a issue where utilities like `inset-x-*`, `left-*`,
`top-*`, etc. mistakenly pull values from the `--inset-ring-*` and
`--inset-shadow-*` theme namespaces.

For example, the class `left-shadow-sm` currently generates this CSS:

```css
.left-shadow-sm {
  left: var(
    --inset-shadow-sm,
    inset 0 1px 1px rgb(0 0 0 / 0.05)
  );
}
```

This happens because the `--inset-ring-*` and `--inset-shadow-*`
namespaces collide with the `--inset-*` namespace.

We were already handling this manually for just the `inset-*` utilities
but didn't realize we needed to handle it for every related utility, so
this PR fixes that.

This also fixes an issue where IntelliSense would suggest classes like
`inset-x-shadow-sm` when they shouldn't actually exist.

To do this we've created this new concept of `ignoredThemeKeys` in the
relevant APIs to make sure these are filtered out at the source.

---------

Co-authored-by: Adam Wathan <4323180+adamwathan@users.noreply.github.com>
2024-11-01 13:48:42 -04:00
..
@tailwindcss-cli Prepare v4.0.0-alpha.31 release (#14823) 2024-10-30 07:53:51 -04:00
@tailwindcss-node Prepare v4.0.0-alpha.31 release (#14823) 2024-10-30 07:53:51 -04:00
@tailwindcss-postcss Remove --drop-shadow-none from default theme (#14847) 2024-10-31 14:24:18 -04:00
@tailwindcss-standalone Prepare v4.0.0-alpha.31 release (#14823) 2024-10-30 07:53:51 -04:00
@tailwindcss-upgrade Remove whitespace around , separator (#14838) 2024-10-31 10:15:52 +01:00
@tailwindcss-vite Prepare v4.0.0-alpha.31 release (#14823) 2024-10-30 07:53:51 -04:00
internal-example-plugin Prefix internal modules with internal-* (#14074) 2024-07-29 10:58:07 -04:00
tailwindcss Ensure --inset-ring=* and --inset-shadow-* variables are ignored by inset-* utilities (#14855) 2024-11-01 13:48:42 -04:00
tsconfig.base.json introduce v4 codebase 2024-03-05 14:29:15 +01:00