palettes
Six palettes any library mood can be drawn in: `storybook` (as authored), `realistic`, `cartoon`, `moody`, `pastel` and `noir`. Each reshapes the grade, sky, haze, ink / paper and takes its toon ramp from its own ramp set. `Palettes.apply(mood, name)` returns a new mood; `Moods.g…
moodKit.palettes
Six palettes any library mood can be drawn in: storybook (as authored), realistic, cartoon, moody, pastel and noir. Each reshapes the grade, sky, haze, ink / paper and takes its toon ramp from its own ramp set. Palettes.apply(mood, name) returns a new mood; Moods.get("dusk.noir") uses it.
Interface
What this asset declares: the schema it conforms to, what it exposes, and the rendered structured payload.
conforms to
zero/source-extract/v2strict Palettes: whole looks any library mood can be drawn in. `storybook` is the mood as authored; `realistic`, `cartoon`, `moody`, `pastel` and `noir` reshape its grade, sky, haze, toon ramp set and ink / paper. `Palettes.apply(mood, name)` returns a new mood; the mood keeps its explicit ramp only in storybook, every other palette takes the ramp from its own ramp set.
lerp(a: number, b: number, t: number) → number return a
| arg | type | description |
|---|---|---|
| a | number | |
| b | number | |
| t | number |
toward(c: { number }?, target: number, t: number) → void
| arg | type | description |
|---|---|---|
| c | { number }? | |
| target | number | |
| t | number |
saturate(c: { number }?, s: number, scale: number?) → void
| arg | type | description |
|---|---|---|
| c | { number }? | |
| s | number | |
| scale | number? |
skyBy(sky: Map?, s: number, scale: number, whiten: number?) → Map
| arg | type | description |
|---|---|---|
| sky | Map? | |
| s | number | |
| scale | number | |
| whiten | number? |
grade(g: Map) → void
| arg | type | description |
|---|---|---|
| g | Map |
sky(s: Map?) → void
| arg | type | description |
|---|---|---|
| s | Map? |
grade(g: Map) → void
| arg | type | description |
|---|---|---|
| g | Map |
sky(s: Map?) → void
| arg | type | description |
|---|---|---|
| s | Map? |
grade(g: Map) → void
| arg | type | description |
|---|---|---|
| g | Map |
sky(s: Map?) → void
| arg | type | description |
|---|---|---|
| s | Map? |
grade(g: Map) → void
| arg | type | description |
|---|---|---|
| g | Map |
sky(s: Map?) → void
| arg | type | description |
|---|---|---|
| s | Map? |
grade(g: Map) → void
| arg | type | description |
|---|---|---|
| g | Map |
sky(s: Map?) → void
| arg | type | description |
|---|---|---|
| s | Map? |
deepClone(t: any) → any
| arg | type | description |
|---|---|---|
| t | any |
has(name: string) → boolean
True when `name` is a palette.
| arg | type | description |
|---|---|---|
| name | string |
apply(mood: Map, name: string?) → Map
A new mood: `mood` drawn in palette `name` (storybook leaves it as authored, filling in its ramp from the storybook set when it has none).
| arg | type | description |
|---|---|---|
| mood | Map | |
| name | string? |
Sub-parts
Everything contained inside this part. Assets are composite children (clickable cards). Files are leaf payloads. Expand any row to view its source.
Showing up to 3 levels deep. Open a part to see what it holds further down.
Problems
Everything affecting this asset right now: its own problems, anything wrong inside it, and problems on its direct dependencies.
agent_score is exposed.+ quality × 0.35
+ performance × 0.25
± compat factor
Usability ratings
Did the part work as advertised when consumers tried to drop it in. Separate from upvotes: those are taste; this is "did it function".
Scoped to this part · feeds back into the world's score.