tailwindcss/packages
Philipp Spiess 17ca56d386
Fix bug with nested @apply rules in utility classes (#17924) (#17925)
Fixes #17924

When an `@apply` pointed to utility that nested usages of `@apply`,
these nested usages were not properly carried through the dependency
chain. This was because we were only tracking dependencies on the
immediate parent rather than all parents.

To fix this, this PR:

- Modifies the dependency resolution to track dependencies through the
entire parent path
- Uses a `walk(…)` for the node replacement logic so that all nested
`@apply` usages are also resolved (as these are now tracked in the
dependency list anyways

## Test Plan

- Added a regression test for #17924 to the unit tests and ensure
existing tests don't break
2025-05-08 18:26:07 +02:00
..
@tailwindcss-browser Update h3 1.15.1 → 1.15.3 (patch) (#17873) 2025-05-05 10:30:10 +00:00
@tailwindcss-cli Write to log file when using DEBUG=* (#17906) 2025-05-07 10:19:54 -04:00
@tailwindcss-node Prepare v4.1.5 release (#17830) 2025-04-30 16:57:44 +02:00
@tailwindcss-postcss Prepare v4.1.5 release (#17830) 2025-04-30 16:57:44 +02:00
@tailwindcss-standalone Prepare v4.1.5 release (#17830) 2025-04-30 16:57:44 +02:00
@tailwindcss-upgrade Make upgrades faster (#17898) 2025-05-06 20:02:13 +02:00
@tailwindcss-vite Prepare v4.1.5 release (#17830) 2025-04-30 16:57:44 +02:00
internal-example-plugin Prefix internal modules with internal-* (#14074) 2024-07-29 10:58:07 -04:00
tailwindcss Fix bug with nested @apply rules in utility classes (#17924) (#17925) 2025-05-08 18:26:07 +02:00
tsconfig.base.json Improve debug logs (#15303) 2024-12-11 15:27:20 +01:00