Skip to content

Commit 062e097

Browse files
The guide + nav unification — v0.9.0
docs/guide.html: the narrative middle the site lacked — from first CSS string to emitted shaders. Sections: start here (with a deliberate honest-correction: the first block shows mix() called with strings and immediately corrects it, teaching the string boundary), the five- sentence mental model (incl. THE pitfall: Lab L is 0-100, OKLab L is 0-1), which-space-by-task cheat sheet, wide gamut without tears (three mapping methods in one sentence each), into the shader, the spectral layer, the performance playbook (three tiers with measured numbers), and why to trust the numbers. House style enforced: every example RUNS LIVE in the page against the bundled library -- the green output boxes are computed at load, so the docs cannot drift from the code. Verified in preview: all six live boxes compute; the three-way mix comparison demonstrates sRGB's muddy middle (C 0.047) vs OKLCH (C 0.21) with real numbers; the gamut box shows hue 32.11 -> 32.11 preserved through cusp mapping. Nav unified across all seven pages (guide first); README leads with the guide link. CHANGELOG covers 0.9.0 = playground + guide. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
1 parent 31c7a78 commit 062e097

13 files changed

Lines changed: 337 additions & 3 deletions

CHANGELOG.md

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,22 @@ All notable changes. The project follows semver; until 1.0, minor versions
44
may adjust APIs (none have needed to yet — the API audit before 0.7.0 found
55
no renames worth their churn).
66

7+
## 0.9.0 — 2026-06-12
8+
9+
The front doors.
10+
11+
- **The converter playground** (`docs/convert.html`): any CSS color in,
12+
all 42 spaces out with copyable serializations, gamut badges,
13+
exact-cusp-mapped previews, nearest named color, WCAG contrast, CVD
14+
swatches, and a CCT line when the color plausibly is a light.
15+
- **The guide** (`docs/guide.html`): the narrative walk from
16+
`parseTo('#ff8800', 'oklch')` to emitted shaders — mental model,
17+
which-space-when, wide-gamut workflow, codegen, the spectral layer,
18+
performance tiers, and why to trust the numbers. Every example runs
19+
live against the library in the page, so the documentation cannot lie
20+
about its outputs.
21+
- Site nav unified across all seven pages; README leads with the guide.
22+
723
## 0.8.0 — 2026-06-12
824

925
The string boundary opens — by decision, not drift.

README.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,9 @@
44
> **Every color space, every illuminant — digit-identical in JS, GLSL, and WGSL.**
55
66
[![npm](https://img.shields.io/npm/v/whitepoint)](https://www.npmjs.com/package/whitepoint)
7+
[**→ the guide**](https://somejohnbforya.github.io/whitepoint/guide.html)
8+
from your first CSS string to emitted shaders, with live examples.
9+
710
[![CI](https://github.com/somejohnbforya/whitepoint/actions/workflows/ci.yml/badge.svg)](https://github.com/somejohnbforya/whitepoint/actions/workflows/ci.yml)
811
&nbsp;[**live demos**](https://somejohnbforya.github.io/whitepoint/)
912
· [**measured accuracy**](https://somejohnbforya.github.io/whitepoint/accuracy.html)

docs/accuracy.html

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@
3838
<nav><div class="navin">
3939
<a class="brand" href="./index.html">whitepoint</a>
4040
<div class="navlinks">
41+
<a href="./guide.html">guide</a>
4142
<a href="./index.html">demos</a>
4243
<a href="./convert.html">convert</a>
4344
<a href="./light.html">light lab</a>

docs/api.html

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@
3333
<nav><div class="navin">
3434
<a class="brand" href="./index.html">whitepoint</a>
3535
<div class="navlinks">
36+
<a href="./guide.html">guide</a>
3637
<a href="./index.html">demos</a>
3738
<a href="./convert.html">convert</a>
3839
<a href="./light.html">light lab</a>

docs/convert.html

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,7 @@
6161
<nav><div class="navin">
6262
<a class="brand" href="./index.html">whitepoint</a>
6363
<div class="navlinks">
64+
<a href="./guide.html">guide</a>
6465
<a href="./index.html">demos</a>
6566
<a class="here" href="./convert.html">convert</a>
6667
<a href="./light.html">light lab</a>

docs/guide.html

Lines changed: 307 additions & 0 deletions
Large diffs are not rendered by default.

docs/index.html

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,7 @@
6868
<nav><div class="navin">
6969
<a class="brand" href="./index.html">whitepoint</a>
7070
<div class="navlinks">
71+
<a href="./guide.html">guide</a>
7172
<a class="here" href="./index.html">demos</a>
7273
<a href="./convert.html">convert</a>
7374
<a href="./light.html">light lab</a>

docs/light.html

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,7 @@
5555
<nav><div class="navin">
5656
<a class="brand" href="./index.html">whitepoint</a>
5757
<div class="navlinks">
58+
<a href="./guide.html">guide</a>
5859
<a href="./index.html">demos</a>
5960
<a href="./convert.html">convert</a>
6061
<a class="here" href="./light.html">light lab</a>

docs/recipes.html

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@
3636
<nav><div class="navin">
3737
<a class="brand" href="./index.html">whitepoint</a>
3838
<div class="navlinks">
39+
<a href="./guide.html">guide</a>
3940
<a href="./index.html">demos</a>
4041
<a href="./convert.html">convert</a>
4142
<a href="./light.html">light lab</a>

package-lock.json

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)