forge
Explore
Log in

Don't you dare go Hollow

The darkroom design language becomes the binding contract

Browse files at this commit

ea79249d292d1eae1fb6d7c1d94b797ea71d7783Ahmet Kaan GümüşParent: 91e6316
  • docs
    • the darkroom design language becomes the binding contract
Show full message
📝 docs: the darkroom design language becomes the binding contract
DESIGN.mdadded+228 -0
@@ -0,0 +1,228 @@
1+# edith — Design Language: The Darkroom
2+
3+This document is the binding design contract for edith's UI. It was distilled from the approved
4+concept mock ("Darkroom", 2026-08-20) and it outlives that mock: every existing surface is being
5+rebuilt to this language, and **every future feature must be designed inside it**. When a change
6+cannot be expressed in this language, the language gets amended here first — in the same diff —
7+never silently violated.
8+
9+Visual reference (playable mock, v16).
10+
11+---
12+
13+## 1. Thesis
14+
15+**The film paints the tool. The tool itself is achromatic.**
16+
17+edith is a darkroom: a dim, stable, monochrome room whose only colors are extracted from the
18+footage on the bench, and whose only pure white is the lamp — the playhead and the splices.
19+The editor sits in this room for eight to twelve hours; everything below exists to keep that
20+person in their groove.
21+
22+Three laws derive everything else:
23+
24+1. **Chrome is achromatic.** No panel, button, tab, slider, or scrollbar carries a hue. Loudness
25+ is luminance, never saturation.
26+2. **Film-extracted inks are the only color.** Each source contributes one ink, quantized from
27+ its own frames (hue kept; saturation/lightness clamped into the WCAG-passing band). Inks mark
28+ *identity* — spines, waveforms, traces, dots — never chrome.
29+3. **White is the lamp.** `#FFFFFF` is reserved for the playhead, its flag, and splice marks.
30+ Nothing else may be pure white.
31+
32+## 2. Tokens
33+
34+Surfaces (dark-only; no light theme, ever):
35+
36+| Token | Value | Role |
37+|---|---|---|
38+| `canvas` | `#050607` | app ground, bench background |
39+| `panel` | `#0E1013` | spine, dock, ledger, plates' parent surfaces |
40+| `raised` | `#14171B` – `#17191D` | hover fill step, active verb fill |
41+| `hairline` | `#22262B` | 1px separations *within* a panel |
42+| seam | `rgba(0,0,0,.7)` | 1px panel-to-panel boundary |
43+| plate | `#050607` on `panel` | readout/notice/menu/cue body |
44+
45+Ink (text) ladder — four levels, all WCAG ≥4.5:1 on their surfaces:
46+
47+| Token | Value | Role |
48+|---|---|---|
49+| `ink1` | `#E6E9EC` | primary: values, active labels, timecode digits |
50+| `ink2` | `#9BA3AC` | secondary: labels, resting verbs, cue text |
51+| `ink3` | `#5E656D` | tertiary: chords at rest, metadata, section heads |
52+| `ink4` | `#3C4249` | faintest: decaying notices, dimmed-room hints |
53+
54+Film inks: extracted per source at import (quantize dominant hues → clamp S/L into the contrast
55+band). Reference extraction from the standing test frame: azure `#64B5D1`, magenta `#D164B5`,
56+green `#64D19A`, violet `#7F64D1`, teal `#64D1D1`. The wheel caps at **12 hues**; beyond 12,
57+hues repeat and the name plate carries identity (the dot was always the secondary cue).
58+Selection uses the complement-leaning second ink (magenta against azure), not a chrome accent.
59+
60+**Ink demotion rule:** extraction is ambient — it just happens. Re-inking a source is a
61+once-a-project act and lives behind right-click on the source's dot. Ink controls never occupy
62+the Sources tab, a toolbar, or any burst-use surface.
63+
64+**Safelight:** the empty room (no footage) is warm monochrome (`#0A0908` family) with amber
65+`#FF9D57` on exactly one glyph. When footage lands, a 900ms skippable film-leader fade hands the
66+room to the film's inks. The 12 legacy palettes survive only as safelight hue choices.
67+
68+Guard: the existing `no_colour_is_written_outside_the_theme` test remains the enforcement
69+mechanism — every value above is a theme token, never a literal at a call site.
70+
71+## 3. Type
72+
73+Two faces, fixed roles (bundled, no runtime deps):
74+
75+- **Archivo** — the room's voice: labels, verbs, section heads. Weights 400/500/700.
76+- **Spline Sans Mono** — everything the film says: timecode, chords, readouts, metadata,
77+ cue text, the ledger. Mono = data; if a string is *about the footage or a key*, it is mono.
78+
79+Scale: 13px hero timecode (700, colons in `ink3`) · 10.5px labels/rows (500) · 9.5–10px chords
80+and metadata (500) · 9px section heads (Archivo 700, uppercase, +0.14em letter-spacing, `ink3`).
81+Nothing below 8px. No italics. Tabular figures wherever digits align.
82+
83+## 4. Ghost grammar — the control language
84+
85+- **Flow controls are ghosts:** borderless glyph + dim chord (`ink2` glyph, `ink3` chord).
86+ Hover = one fill step (`raised`) + ink brighten. Active = `ink1` + fill. No borders, no boxes,
87+ no icon assets — glyphs are hand-drawn/typographic.
88+- **Boxes are commitments:** the single bordered chip is reserved for commit-class actions
89+ (Export). If a second boxed control ever appears on one surface, one of them is wrong.
90+- **Readouts are plates:** dark (`canvas`-on-`panel`) rectangles carrying mono text. Notices,
91+ menus, chips, cues, and tooltips are all the same plate.
92+- **Every command wears its chord**, everywhere it appears — spine, menus, verbs, the `?`
93+ overlay. Nothing lives only in a menu; nothing lives only on a key. (This kills the
94+ shortcut-sync defect class permanently: the UI *is* the shortcut sheet.)
95+- **The most-read element anchors its region** — timecode leads the time band; the film leads
96+ the room.
97+- Radii: 0 for lanes/clips/room chrome · 2px plates · 3px verbs/controls · 4–6px floating
98+ (menus, sheets). No pills, no circles except source dots.
99+- Hover never adds hue. Focus/selection ring = 1px `ink1` (lamp-adjacent, not colored).
100+
101+## 5. The stance — layout
102+
103+Fixed geography; nothing moves, nothing occludes the picture:
104+
105+```
106+┌──┬──────────────────────────────┬──────┐
107+│ │ SCREEN │ │
108+│sp│ (picture — top, never │ dock │
109+│in│ occluded) │ Src/ │
110+│e │ │ Clip │
111+│ ├──────────────────────────────┤ tabs │
112+│56│ TIME BAND: timecode → ghost │ │
113+│px│ transport → cut readout → │ │
114+│ │ contact strip → [Export] │ │
115+│ ├──────────────────────────────┤ │
116+│ │ BENCH (lanes V/A/S) │ │
117+│ ├──────────────────────────────┤ │
118+│ │ LEDGER (project · state) │ │
119+└──┴──────────────────────────────┴──────┘
120+```
121+
122+- **Spine** (56px, left): every command as ghost glyph + chord, grouped by task frequency.
123+- **Screen**: the picture. Never covered — not by drawers, notices, drags, or menus. Two-up
124+ OUT|IN judging renders *in* the screen at rest on a cut.
125+- **Time band**: timecode leads; ghost transport; cut readout (`14/37`); the **contact strip**
126+ (whole-film motion-trace minimap, `FILM` label, viewport bracket with grip notches — click
127+ jumps, drag pans); boxed **Export** at the end.
128+- **Bench**: lanes. Clip anatomy = ink spine (3px left edge) + real thumbnails/waveform in the
129+ source's ink + name plate + splice gaps in lamp white.
130+- **Ledger**: project identity (`name.edith · saved`), last action, export progress, position.
131+ State lives here, notices rise from here.
132+- **Dock** (right, the only side panel): Sources tab (assembly: filter, usage chips, import) and
133+ Clip tab (verbs: Speed / Colour / Transform / EQ as ghost verbs over param rows).
134+
135+Session continuity: a room reopens exactly as left — playhead, subject cut, viewport, dock tab.
136+
137+## 6. Cut machinery — the interaction core
138+
139+The cut is the subject. Grammar (implement before any cosmetics):
140+
141+- `,` `.` — walk cuts (shift = stride 10). The cut readout is the odometer.
142+- `[` `]` — no-aim trim of the subject cut, frame detents, works at any zoom (even 4px clips).
143+- `/` — loop-trim: loop around the subject cut while trimming (the modernized Avid trim mode).
144+- Two-up OUT|IN on the screen when resting on a cut.
145+- `j k l` — shuttle; `s` — split; `↵` context-dependent commit; `esc` always retreats.
146+- Param rows: drag while playing; value ghosts on the frame; `r` resets; live row takes the ink.
147+- Colour verb: `v` holds previous shot beside current (matching is comparative).
148+- Subtitle cues: cue edge is a cut — the same `,` `.` `[` `]` grammar applies; text edits on the
149+ picture where subtitles live.
150+
151+## 7. Scale — the degradation ladder
152+
153+Clips degrade **by width, one layer per threshold**, never all at once:
154+full anatomy (thumbnails, trace, plates, chips) → drop chips → drop labels (<48px; labels never
155+truncate into soup) → spine + trace only → sliver fill + splice gaps (film scale). Navigation
156+never depends on pixels: `,` `.` + contact strip work identically at 100 clips. Lanes compress
157+evenly to 5, then scroll behind the pinned ruler and track heads.
158+
159+## 8. Notices — how the room speaks
160+
161+No full-width bars, no covering the picture, ever. A notice is a plate rising above the ledger,
162+one at a time; severity is a **3px left spine**, not a color flood:
163+
164+- grey `#5E656D` — *told you* (self-fades)
165+- amber `#D1B564` — *worth a look* (carries a jump action: `go to cut ,31`)
166+- red `#C85050` — *needs a decision* (the decision is on the plate: `relink ↵ / later esc`)
167+
168+Every failure names its remedy, and the wound stays visible where it lives (dark clips in the
169+lane). **A refusal string is a claim:** shipping "cannot be decoded" requires a test proving the
170+capability is genuinely absent — otherwise it is a bug, not a message. A verb the state refuses
171+(in menus) greys out with its reason on hover; it never disappears.
172+
173+## 9. Menus and the keys overlay
174+
175+- **Right-click = verbs of the thing under the cursor** (clip menu: clip verbs; lane head: lane
176+ verbs; source dot: ink acts). Plate styling, chords on every row, destructive verbs below a
177+ rule line. Never a junk drawer.
178+- **`?` held** dims the room one fill step and surfaces chords *in place* beside their controls;
179+ release restores. No modal cheat-sheet; learning stays geographic. The film keeps playing.
180+
181+## 10. The joy layer
182+
183+Game-feel, not gamification. All specs ≤150ms, ease-out, tied to real actions, honor
184+`prefers-reduced-motion`; all sound behind one toggle, −30dB, and **always silent while the
185+film's own audio plays**.
186+
187+- Split: 80ms white splice flash + dry mechanical tick.
188+- Trim nudge: 60ms detent per frame (rotary-encoder feel); held key = ratchet.
189+- Cut jump: 2-frame snap flash on arrival.
190+- Drop: 80ms magnetic settle + 1-frame squash. Never a teleport.
191+- JKL: optional pitch cue per speed step; blade leans 1px at 4×.
192+- Export: breathing ribbon on the boxed chip; film-leader countdown on open.
193+
194+**Never-list:** no badges, streaks, confetti, or celebration copy; nothing moves during playback
195+except the blade; no sound over film audio; no animation as decoration (every motion reports a
196+state change).
197+
198+## 11. Adding a feature — the checklist
199+
200+Before any new surface merges, it answers:
201+
202+1. **Frequency row:** which editor task, done how many times per hour, justifies its pixels?
203+ Burst-use surfaces (screen, bench, time band) are the most expensive land.
204+2. **Grammar fit:** flow → ghost; commitment → the box (is it really commit-class?);
205+ readout → plate; identity → ink; alarm → notice spine.
206+3. **Chord:** it has one, wears it everywhere it appears, and joins the `?` overlay.
207+4. **Scale:** define its degradation ladder step-by-width before merge.
208+5. **Achromatic check:** zero new hues in chrome; film inks only for identity; white only if it
209+ is literally the lamp.
210+6. **Occlusion check:** the picture stays visible; nothing floats over the screen.
211+7. **States:** empty (safelight-composed, never bare), refusing (reason named), failing
212+ (notice plate with remedy).
213+8. **Feel:** one ≤150ms motion spec from §10's vocabulary, or a stated reason for none.
214+9. **Continuity:** its state survives room close/reopen.
215+
216+If a feature fails the checklist, either the feature changes or this document does — explicitly.
217+
218+## 12. Implementation order
219+
220+1. Token substrate in `crates/app/src/ui/theme.rs` (extend the 34-role system; keep the
221+ `no_colour_is_written_outside_the_theme` guard green).
222+2. The stance behind a flag (spine / screen / time band / bench / ledger / dock skeleton).
223+3. Cut machinery (`,` `.` `[` `]` `/`, two-up, readout) — before cosmetics.
224+4. Dock (Sources assembly + Clip verbs).
225+5. Ink extraction + grading pipeline; source dots; selection ink.
226+6. Traces + contact strip.
227+7. Notices, session continuity, safelight empty room, `?` overlay.
228+8. Joy layer last — it polishes verbs that already work.