complementary
Return the complementary color: the OKLCH hue rotated 180°, with lightness, chroma and alpha unchanged. Not gamut mapped.
import { complementary } from '@pbroom/color-kit';index.ts:28function complementary(color: Color): Color;Parameters
Returns
ColorA new Color
Example
import { complementary, parse } from '@pbroom/color-kit';
complementary(parse('oklch(0.7 0.15 30)')); // → { l: 0.7, c: 0.15, h: 210, alpha: 1 }