okchroma 0.3.0 → 0.3.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  **A color-system engine.** Give it one brand hex, or two, and it resolves a complete
4
4
  light and dark token system whose contrast requirements are solved during generation,
5
- then emits it as CSS custom properties, Figma variables, or DTCG requirement tokens.
5
+ then emits it as CSS custom properties or Figma variables.
6
6
 
7
7
  Every family (neutral, brand, brand-alt, critical, warning, positive, info) carries the
8
8
  same scale: 3 papers, 4 highlighters, 1 crayon, 1 pencil, 2 pens, plus the stamp (the
@@ -10,10 +10,10 @@ solid fill with its hover and pressed states, its edge, and its text). The neutr
10
10
  the two poles. Light and dark resolve together and ship on the same names, so a token is
11
11
  mapped once and holds for any brand.
12
12
 
13
- Contrast is built into the math, not checked afterwards: `crayon-26` reads on every paper
14
- at 3:1 (the non-text bar), `pencil-47` at 4.5:1, `pen-58` and `pen-70` at 4.5:1 on every
15
- paper and highlighter in both directions; the stamp's text passes 4.5:1 on the fill and
16
- brand and signal fills clear APCA Lc 65 on top. Each claim, its scope, and the audit that
13
+ Contrast is built into the math, not checked afterwards: crayon reads on every paper at
14
+ 3:1 (the non-text bar), pencil at 4.5:1, pen at 4.5:1 on every paper and highlighter in
15
+ both directions; the stamp's text passes 4.5:1 on its fill. APCA is used once, as a booster
16
+ that nudges the stamp fill until its text reads at Lc 65. Each claim, its scope, and the audit that
17
17
  proves it: [Guarantees](https://egerrity.github.io/okchroma/#/docs/guarantees).
18
18
 
19
19
  > The reserved-role-per-stop model is a conceptual nod to
@@ -41,8 +41,7 @@ const css = brandCss('acme', 'Acme', theme.themed, theme.secondary?.scale ?? nul
41
41
  // and data-theme="dark" on it for dark mode
42
42
  ```
43
43
 
44
- The Figma tree comes from `themeToFigma`, the DTCG requirement tokens from
45
- `emitDtcgRamp`. Signatures, the full input, and an end-to-end example:
44
+ The Figma tree comes from `themeToFigma`. Signatures, the full input, and an end-to-end example:
46
45
  [Install and API](https://egerrity.github.io/okchroma/#/docs/install).
47
46
 
48
47
  ## Run from source
@@ -67,12 +66,12 @@ The docs site is the source: [egerrity.github.io/okchroma/#/docs](https://egerri
67
66
  - [Output contract](https://egerrity.github.io/okchroma/#/docs/output): the naming grammar, families and prefixes, modes and selectors, a live CSS block and Figma tree.
68
67
  - [Guarantees](https://egerrity.github.io/okchroma/#/docs/guarantees): every claim stated exactly, and how it is verified.
69
68
  - [How the theme is generated](https://egerrity.github.io/okchroma/#/docs/generation): the pipeline in execution order, with the constants and the code that runs each step.
70
- - [Signals and companions](https://egerrity.github.io/okchroma/#/docs/signals), [Requirement tokens](https://egerrity.github.io/okchroma/#/docs/token-schema), [Reference](https://egerrity.github.io/okchroma/#/docs/reference).
69
+ - [Signals and companions](https://egerrity.github.io/okchroma/#/docs/signals) and the [Reference](https://egerrity.github.io/okchroma/#/docs/reference): glossary, constants, option types.
71
70
 
72
71
  In the repo: [docs/architecture.md](docs/architecture.md) (the maintainer's map: modules,
73
72
  pipeline stages, data structures, the extended plugin's zones),
74
73
  [docs/scale.md](docs/scale.md) (the scale and its declared targets),
75
- [docs/schema.md](docs/schema.md) (the requirement-token format in the repo),
74
+ [docs/schema.md](docs/schema.md) (the format of the experimental DTCG export),
76
75
  [docs/agents.md](docs/agents.md) (how a coding agent consuming the tokens should read
77
76
  them), and [CHANGELOG.md](CHANGELOG.md).
78
77
 
@@ -919,9 +919,9 @@ var P_LIFT = { hue: "warm-torsion", L: "perceptual-lift", chroma: "ladder" };
919
919
  var P_FIXED = { hue: "warm-torsion", L: "fixed", chroma: "ladder" };
920
920
  var P_TEXT = { hue: "warm-torsion", L: "perceptual", chroma: "brand" };
921
921
  var S8 = { metric: "wcag", against: "paper-5", target: STOP_8_NONTEXT_CONTRAST, level: "AA" };
922
- var T9 = { metric: "wcag", against: "paper-3", target: PENCIL_9_CONTRAST, level: "AA" };
922
+ var T9 = { metric: "wcag", against: "paper-5", target: PENCIL_9_CONTRAST, level: "AA" };
923
923
  var T10 = { metric: "wcag", against: "highlighter-20", target: PEN_10_CONTRAST, level: "AA" };
924
- var T11 = { metric: "wcag", against: "paper-3", target: PEN_11_CONTRAST_FLOOR, level: "AAA" };
924
+ var T11 = { metric: "wcag", against: "paper-5", target: PEN_11_CONTRAST_FLOOR, level: "AAA" };
925
925
  var ONS = { onFill: { metric: "apca-pole", enforce: true, ratioFloor: 4.5, coEnforceLc: 65 } };
926
926
  var LIGHT = {
927
927
  stops: [
@@ -840,9 +840,9 @@ var P_LIFT = { hue: "warm-torsion", L: "perceptual-lift", chroma: "ladder" };
840
840
  var P_FIXED = { hue: "warm-torsion", L: "fixed", chroma: "ladder" };
841
841
  var P_TEXT = { hue: "warm-torsion", L: "perceptual", chroma: "brand" };
842
842
  var S8 = { metric: "wcag", against: "paper-5", target: STOP_8_NONTEXT_CONTRAST, level: "AA" };
843
- var T9 = { metric: "wcag", against: "paper-3", target: PENCIL_9_CONTRAST, level: "AA" };
843
+ var T9 = { metric: "wcag", against: "paper-5", target: PENCIL_9_CONTRAST, level: "AA" };
844
844
  var T10 = { metric: "wcag", against: "highlighter-20", target: PEN_10_CONTRAST, level: "AA" };
845
- var T11 = { metric: "wcag", against: "paper-3", target: PEN_11_CONTRAST_FLOOR, level: "AAA" };
845
+ var T11 = { metric: "wcag", against: "paper-5", target: PEN_11_CONTRAST_FLOOR, level: "AAA" };
846
846
  var ONS = { onFill: { metric: "apca-pole", enforce: true, ratioFloor: 4.5, coEnforceLc: 65 } };
847
847
  var LIGHT = {
848
848
  stops: [
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "okchroma",
3
- "version": "0.3.0",
3
+ "version": "0.3.1",
4
4
  "license": "MIT",
5
5
  "description": "Color token engine: one brand hex in, a full WCAG-enforced light+dark token system out (CSS variables, DTCG JSON, Figma variables)",
6
6
  "repository": {