OKLCH Studio · Tailwind v3 → v4
Tailwind neutral-300: v3 #d4d4d4 vs v4 oklch(0.870 0.000 0.0)
Unchangedneutral-300 is effectively the same colour in v3 and v4 (ΔE-OK 0.01).
| v3 hex | #d4d4d4 |
|---|---|
| v3 as oklch() | oklch(0.870 0.000 0.0) |
| v4 oklch() | oklch(0.870 0.000 0.0) |
| v4 hex | #D4D4D4 |
| ΔE-OK (×100) | 0.01 |
| ΔL (v4 − v3) | 0 |
| ΔC (v4 − v3) | 0 |
| ΔH (v4 − v3) | 0° |
Copy code
Tailwind v3 usage
color: #d4d4d4;
// tailwind.config.js (v3)
colors.neutral[300] // #d4d4d4Tailwind v4 @theme token
@theme {
--color-neutral-300: oklch(0.870 0.000 0.0);
}
.example {
color: var(--color-neutral-300);
}Keep the v3 colour in v4
@theme {
--color-neutral-300: #d4d4d4;
}