OKLCH Studio · Tailwind v3 → v4
Tailwind green-300: v3 #86efac vs v4 oklch(0.871 0.150 154.4)
Subtle shiftIn v4, green-300 is more saturated than in v3 (ΔL 0.000, ΔC +0.014, ΔH 0.0°).
| v3 hex | #86efac |
|---|---|
| v3 as oklch() | oklch(0.871 0.136 154.4) |
| v4 oklch() | oklch(0.871 0.150 154.4) |
| v4 hex | #7BF1A8 |
| ΔE-OK (×100) | 1.37 |
| ΔL (v4 − v3) | 0 |
| ΔC (v4 − v3) | 0.014 |
| ΔH (v4 − v3) | 0° |
Copy code
Tailwind v3 usage
color: #86efac;
// tailwind.config.js (v3)
colors.green[300] // #86efacTailwind v4 @theme token
@theme {
--color-green-300: oklch(0.871 0.150 154.4);
}
.example {
color: var(--color-green-300);
}Keep the v3 colour in v4
@theme {
--color-green-300: #86efac;
}