Skip to content

Add support for Tailwind CSS v4.2#651

Merged
dcastil merged 11 commits intomainfrom
feature/add-support-for-tailwind-css-v4.2
Feb 18, 2026
Merged

Add support for Tailwind CSS v4.2#651
dcastil merged 11 commits intomainfrom
feature/add-support-for-tailwind-css-v4.2

Conversation

@dcastil
Copy link
Owner

@dcastil dcastil commented Feb 18, 2026

Release: https://github.com/tailwindlabs/tailwindcss/releases/tag/v4.2.0

Changes to check

Added

  • Add mauve, olive, mist, and taupe color palettes to the default theme (#19627)
  • Add @tailwindcss/webpack package to run Tailwind CSS as a webpack plugin (#19610)
  • Add pbs-* and pbe-* utilities for padding-block-start and padding-block-end (#19601)
  • Add mbs-* and mbe-* utilities for margin-block-start and margin-block-end (#19601)
  • Add scroll-pbs-* and scroll-pbe-* utilities for scroll-padding-block-start and scroll-padding-block-end (#19601)
  • Add scroll-mbs-* and scroll-mbe-* utilities for scroll-margin-block-start and scroll-margin-block-end (#19601)
  • Add border-bs-* and border-be-* utilities for border-block-start and border-block-end (#19601)
  • Add inline-*, min-inline-*, max-inline-* utilities for inline-size, min-inline-size, and max-inline-size (#19612)
  • Add block-*, min-block-*, max-block-* utilities for block-size, min-block-size, and max-block-size (#19612)
  • Add inset-s-*, inset-e-*, inset-bs-*, inset-be-* utilities for inset-inline-start, inset-inline-end, inset-block-start, and inset-block-end (#19613)
  • Add font-features-* utility for font-feature-settings (#19623)

Fixed

  • Prevent double @supports wrapper for color-mix values (#19450)
  • Allow whitespace around @source inline() argument (#19461)
  • Emit comment when source maps are saved to files when using @tailwindcss/cli (#19447)
  • Detect utilities containing capital letters followed by numbers (#19465)
  • Fix class extraction for Rails' strict locals (#19525)
  • Align @utility name validation with Oxide scanner rules (#19524)
  • Fix infinite loop when using @variant inside @custom-variant (#19633)
  • Allow multiples of .25 in aspect-* fractions (e.g. aspect-8.5/11) (#19688)
  • Ensure changes to external files listed via @source trigger a full page reload when using @tailwindcss/vite (#19670)
  • Improve performance of Oxide scanner in bigger projects by reducing file system walks (#19632)
  • Ensure import aliases in Astro v5 work without crashing when using @tailwindcss/vite (#19677)
  • Allow escape characters in @utility names to improve support with formatters such as Biome (#19626)
  • Fix incorrect canonicalization results when canonicalizing multiple times (#19675)
  • Add .jj to default ignored content directories (#19687)

Deprecated

  • Deprecate start-* and end-* utilities in favor of inline-s-* and inline-e-* utilities (#19613)

@github-actions github-actions bot added context-v3 Related to tailwind-merge v3 feature Is new feature labels Feb 18, 2026
@github-actions
Copy link

github-actions bot commented Feb 18, 2026

Metrics report

At head commit 7a4cacf and base commit d2bbc29 at 2026-02-18T23:33:18.541Z

Size

Export Size original Size minified Size minified and Brotli compressed
tailwind-merge esm 100.18 kB +5.1% 🔴 27.24 kB +4.0% 🔴 7.08 kB +1.8% 🔴
 › extendTailwindMerge 99.40 kB +5.1% 🔴 26.53 kB +4.2% 🔴 6.90 kB +3.0% 🔴
 › getDefaultConfig 80.02 kB +6.5% 🔴 21.38 kB +5.2% 🔴 5.10 kB +4.2% 🔴
 › twMerge 97.08 kB +5.3% 🔴 25.68 kB +4.3% 🔴 6.66 kB +1.9% 🔴
 › validators 4.95 kB +0.4% 🔴 1.85 kB +1.1% 🔴 0.76 kB +0.5% 🔴
tailwind-merge cjs 100.44 kB +5.1% 🔴 33.66 kB +3.3% 🔴 7.57 kB +3.3% 🔴
tailwind-merge/es5 esm 106.19 kB +4.9% 🔴 29.37 kB +4.0% 🔴 7.37 kB +2.4% 🔴
 › extendTailwindMerge 104.95 kB +5.0% 🔴 28.66 kB +4.1% 🔴 7.15 kB +3.0% 🔴
 › getDefaultConfig 82.77 kB +6.4% 🔴 22.68 kB +5.2% 🔴 5.15 kB +2.5% 🔴
 › twMerge 102.05 kB +5.1% 🔴 27.59 kB +4.3% 🔴 6.93 kB +2.7% 🔴
 › validators 6.70 kB +0.3% 🔴 2.46 kB +0.8% 🔴 0.82 kB -0.2% 🟢
tailwind-merge/es5 cjs 106.45 kB +4.9% 🔴 35.82 kB +3.3% 🔴 7.72 kB +1.6% 🔴
All size metrics
Export Size original Size minified Size minified and Brotli compressed
tailwind-merge esm 100.18 kB +5.1% 🔴 27.24 kB +4.0% 🔴 7.08 kB +1.8% 🔴
 › createTailwindMerge 17.11 kB 0% 4.25 kB 0% 1.62 kB 0%
 › extendTailwindMerge 99.40 kB +5.1% 🔴 26.53 kB +4.2% 🔴 6.90 kB +3.0% 🔴
 › fromTheme 0.27 kB 0% 0.09 kB 0% 0.08 kB 0%
 › getDefaultConfig 80.02 kB +6.5% 🔴 21.38 kB +5.2% 🔴 5.10 kB +4.2% 🔴
 › mergeConfigs 2.20 kB 0% 0.80 kB 0% 0.27 kB 0%
 › twJoin 1.18 kB 0% 0.24 kB 0% 0.16 kB 0%
 › twMerge 97.08 kB +5.3% 🔴 25.68 kB +4.3% 🔴 6.66 kB +1.9% 🔴
 › validators 4.95 kB +0.4% 🔴 1.85 kB +1.1% 🔴 0.76 kB +0.5% 🔴
tailwind-merge cjs 100.44 kB +5.1% 🔴 33.66 kB +3.3% 🔴 7.57 kB +3.3% 🔴
tailwind-merge/es5 esm 106.19 kB +4.9% 🔴 29.37 kB +4.0% 🔴 7.37 kB +2.4% 🔴
 › createTailwindMerge 19.26 kB 0% 4.86 kB 0% 1.77 kB 0%
 › extendTailwindMerge 104.95 kB +5.0% 🔴 28.66 kB +4.1% 🔴 7.15 kB +3.0% 🔴
 › fromTheme 0.25 kB 0% 0.11 kB 0% 0.08 kB 0%
 › getDefaultConfig 82.77 kB +6.4% 🔴 22.68 kB +5.2% 🔴 5.15 kB +2.5% 🔴
 › mergeConfigs 2.45 kB 0% 0.87 kB 0% 0.29 kB 0%
 › twJoin 1.21 kB 0% 0.30 kB 0% 0.18 kB 0%
 › twMerge 102.05 kB +5.1% 🔴 27.59 kB +4.3% 🔴 6.93 kB +2.7% 🔴
 › validators 6.70 kB +0.3% 🔴 2.46 kB +0.8% 🔴 0.82 kB -0.2% 🟢
tailwind-merge/es5 cjs 106.45 kB +4.9% 🔴 35.82 kB +3.3% 🔴 7.72 kB +1.6% 🔴

@codspeed-hq
Copy link

codspeed-hq bot commented Feb 18, 2026

Merging this PR will improve performance by 12.83%

⚡ 1 improved benchmark
✅ 6 untouched benchmarks

Performance Changes

Benchmark BASE HEAD Efficiency
init 4 ms 3.5 ms +12.83%

Comparing feature/add-support-for-tailwind-css-v4.2 (7a4cacf) with main (d2bbc29)

Open in CodSpeed

@dcastil dcastil marked this pull request as draft February 18, 2026 22:00
@dcastil
Copy link
Owner Author

dcastil commented Feb 18, 2026

Documenting merging behavior between logical and directional properties here.

We can't merge logical properties with directional properties very well because the logical properties depend on the writing mode.

It is probably known that *-inline-start will map to the left in languages that go from left to right and to the right in languages that go from right to left. But it can also map to the top, so we can't even set a conflict with the class group covering the x axis.

This is how I'll implement it for now.

But I see that in the majority of cases, tailwind-merge is used in left-to-right languages and it would be a benefit if tailwind-merge would properly merge logical with directional properties. Maybe it will be worth adding a config that sets them in conflict in the future.

@dcastil dcastil marked this pull request as ready for review February 18, 2026 23:35
@dcastil dcastil merged commit 6c1f77c into main Feb 18, 2026
6 checks passed
@dcastil dcastil deleted the feature/add-support-for-tailwind-css-v4.2 branch February 18, 2026 23:41
@github-actions
Copy link

This was addressed in release v3.4.1-dev.6c1f77ca717df7d2685eb783c568ef7696148171.

@github-actions
Copy link

This was addressed in release v3.5.0.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

context-v3 Related to tailwind-merge v3 feature Is new feature

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant

Comments