Function Signature
js
oklabToHex(L: number, a: number, b: number): stringParameters
L(number): OKLab lightness.a(number): OKLab green-red axis.b(number): OKLab blue-yellow axis.
Return Value
A lowercase HEX string in the format #rrggbb.
js
const lab = hexToOklab("#ff6600");
oklabToHex(lab.L, lab.a, lab.b);
// "#ff6600"Usage Notes
- Out-of-gamut OKLab values are clipped to valid sRGB.
- Use with
hexToOklabfor round-trip operations.