WCAG contrast math — hand-rolled, zero dependencies.
Implements the WCAG 2.x relative-luminance and contrast-ratio definitions, plus a color
parser (hex / rgb() / rgba()) and alpha compositing so low-opacity colors (grid lines, faded
text) can be measured against a known background. Pure; unit-tested under node:test.
WCAG contrast math — hand-rolled, zero dependencies.
Implements the WCAG 2.x relative-luminance and contrast-ratio definitions, plus a color parser (hex / rgb() / rgba()) and alpha compositing so low-opacity colors (grid lines, faded text) can be measured against a known background. Pure; unit-tested under node:test.