tailwindcss/packages/@tailwindcss-upgrade/src
Robin Malfait 57be02a983
Improve in-* variant migrations (#15054)
While testing the codemods on some projects, I noticed some issues with
the migration to the new `in-*` variant.

One such example is that we checked for `&` at the end, instead of ` &`
(the whitespace is significant).

This meant that `[figure>&]:my-0` was converted to `in-[figure>]:my-0`
which is wrong. In this case, we want to keep it as `[figure>&]:my-0`.

Additionally this PR brings back the migration from `group-[]:flex` to
`in-[.group]:flex`. If you are using a prefix, then `group-[]:tw-flex`
is migrated to `tw:in-[.tw\:group]:flex`.

Last but not least, this does some internal refactors to group
migrations logically together.
2024-11-20 15:47:26 +01:00
..
codemods Upgrade: don't show error during upgrade when analyzing external URL import (#15040) 2024-11-19 15:52:30 +01:00
commands/help Add initial codemod tooling (#14434) 2024-09-18 16:45:43 +02:00
template Improve in-* variant migrations (#15054) 2024-11-20 15:47:26 +01:00
utils Use resolveJsId when resolving tailwindcss/package.json (#15041) 2024-11-19 18:39:49 +01:00
index.test.ts Remove input borders by default (#14929) 2024-11-08 15:29:41 -05:00
index.ts Upgrade: Error when project is already using Tailwind CSS v4 (#15015) 2024-11-19 15:53:02 +01:00
migrate-js-config.ts Implement compat for <alpha-value> from v3 (#15033) 2024-11-19 10:01:45 -05:00
migrate-postcss.ts Improve PostCSS migration (#15046) 2024-11-19 22:56:29 +01:00
migrate-prettier.ts Improve robustness when upgrading (#15038) 2024-11-19 14:29:51 +01:00
migrate.ts Improve root file detection (#15048) 2024-11-20 00:20:40 +01:00
stylesheet.ts Resolve imports from CSS file (#15010) 2024-11-15 22:06:52 +01:00