aboutsummaryrefslogtreecommitdiff
path: root/docs/design
diff options
context:
space:
mode:
authorCraig Jennings <c@cjennings.net>2026-06-08 21:05:21 -0500
committerCraig Jennings <c@cjennings.net>2026-06-08 21:05:21 -0500
commit22605426c9839e2a64fa32533c73246a7b6f2f33 (patch)
tree052946c01207cc0b96eac5d265e084abe9397c89 /docs/design
parent09d1ba4e0bc02cc9bf3ae61d8b7b3b5a28681616 (diff)
downloaddotemacs-22605426c9839e2a64fa32533c73246a7b6f2f33.tar.gz
dotemacs-22605426c9839e2a64fa32533c73246a7b6f2f33.zip
feat(theme-studio): add an OKLCH edit mode to the picker
Perceptual-metrics Phase 4a. The picker gains an edit-model toggle (HSV / OKLCH) held in its own pkModel state, orthogonal to the existing AA/AAA contrast mask (pkMode). The two never share state: one is how you edit the color, the other is what constraint you mask. In OKLCH mode the picker shows L, C, and H as paired range and number inputs that drive the color through oklch2hex, updating the hex field, swatch, readouts, and the HSV cursor. When the requested chroma is out of sRGB gamut the dials snap to the reachable color and a "chroma clamped to sRGB" line appears. HSV stays the default, and the SV square keeps editing in HSV (the C×L plane is Phase 4b). An SV drag in OKLCH mode refreshes the dials so the two surfaces stay consistent. A #oklchtest headless guard asserts switching to OKLCH preserves the color, toggling the mask leaves pkModel alone, switching the model leaves pkMode alone, the dials drive the color to a known OKLCH target, and an out-of-gamut chroma raises the clamp status.
Diffstat (limited to 'docs/design')
0 files changed, 0 insertions, 0 deletions