OKLCH Studio · Tailwind v3 → v4
Tailwind green-400: v3 #4ade80 vs v4 oklch(0.792 0.209 151.7)
ChangedIn v4, green-400 is darker and more saturated than in v3 (ΔL -0.008, ΔC +0.027, ΔH 0.0°).
| v3 hex | #4ade80 |
|---|---|
| v3 as oklch() | oklch(0.800 0.182 151.7) |
| v4 oklch() | oklch(0.792 0.209 151.7) |
| v4 hex | #05DF72 |
| ΔE-OK (×100) | 2.82 |
| ΔL (v4 − v3) | -0.008 |
| ΔC (v4 − v3) | 0.027 |
| ΔH (v4 − v3) | 0° |
Copy code
Tailwind v3 usage
color: #4ade80;
// tailwind.config.js (v3)
colors.green[400] // #4ade80Tailwind v4 @theme token
@theme {
--color-green-400: oklch(0.792 0.209 151.7);
}
.example {
color: var(--color-green-400);
}Keep the v3 colour in v4
@theme {
--color-green-400: #4ade80;
}