okami.mom/strata

git clone https://git.nkp.pet/okami.mom/strata

Niko1221Merge f-clean-3 (321794636): docs and history (cleanup step 3, items 3.0-3.10); release manifest and capability table with checks, history/ with pointers, link check, tools/ split, bench index; owner OK'd the wording 11-082b36e8a02

main
4.1 KiB55 linesraw

T03 · Primary, disabled and on states

Phase 1 · 11 findings (1 high, 7 medium, 3 low) · Depends on: nothing, can start now

Goal

Enabled and disabled primary buttons look the same, dark-mode primary buttons are green on green, toggle "on" is barely visible, and checkboxes use browser blue. Define the states once in the shared components.

Files to change

These are the likely files. Read them before editing, and change others only if the fix needs it.

  • src/components/ui.tsx (Button, Toggle, Checkbox)
  • src/styles/app.css
  • src/styles/kit/ (only if the token lives there; keep sync:kit working)

Findings to fix (high and medium)

#SeverityStateIssueSuggested fix
1HighGLOBALPrimary buttons (New chat, Send, Approve, Open preview) use the same pale-green tint enabled or disabled; Approve looks disabled, Send-enabled ≈ Send-disabledsolid #10b981 + white for enabled; neutral grey for disabled
2MediumGLOBAL-chatAt 1280×720 the composer (3-line empty textarea + toolbar + stats) takes ~250px; reading area is ~420px1-line composer that grows; stats inline in toolbar
3MediumGLOBALNative checkboxes render browser blue (#2563eb) — off-paletteaccent-color: #10b981 (or ink) app-wide
4Mediumskills-*Toggle "on" state is pale mint with a white knob — barely distinguishable from "off"solid #10b981 track when on
5Mediumtasks-populatedRow actions are unlabeled icons (pencil, paper-plane for "run now", toggle); paper-plane reads as "send"tooltips + text "Run now"; label the toggle "On schedule"
6Mediumtasks-detail-*Detail view keeps list chrome (Demo note, "Deleted tasks" checkbox, search, sort) and the generic subtitle; "All tasks" is a centred underlined link above contentbreadcrumb "Tasks › Daily briefing" top-left; hide list controls
7Mediumdark-*Primary buttons in dark (Approve, Open preview, Save setup and load, New chat) are dark green fill with green text (~3:1)solid #10b981 with #0b1f17 or white text; same rule as light
8Mediumdark-skills-overview / dark-skills-edit"On" toggles in dark are a dark green track with a dark knob — on vs off is hard to tellbright #10b981 track + white knob when on

Optional polish (low)

Do these only if the task is otherwise done and the budget allows.

#SeverityStateIssueSuggested fix
1LowGLOBAL-sidebarTask rows show pencil + trash icons permanently on every rowreveal on hover/focus
2Lowdark-*Disabled "Save for next load" in dark is near-invisible green-on-greenneutral disabled style shared with light
3Lowdark-preview-pdf / dark-preview-websitePDF page and website preview stay bright white/cream inside the dark panel — expected for document content, but there's no frame or dimming optionthin border + optional "Dim document" toggle

How to check

Run these and fix anything that fails:

  • npm run typecheck
  • node --test tests/ (all existing tests stay green)
  • npm run check (typecheck, UI audit, contrast, measure, luminance)
  • npm run build

Task-specific checks:

  • Primary enabled: solid #10b981 with white text, both themes. Disabled: neutral fill (#eef1f4 light / a neutral grey in dark) with muted text, not a green tint.
  • Toggle on: bright green track and white knob, both themes. Off: neutral track.
  • Checkboxes use the brand green via accent-color or a custom control.
  • npm run contrast passes; add the new states to it if they are not covered.
  • Each finding above is resolved, or marked "already fixed by Txx" or "not reproducible" with a one-line reason.

Screens to re-capture and compare with the audit screenshots in docs/evidence/audit-2026-10-07/:

  • tasks-populated-light.png

Done when

  • All checks pass.
  • Commit on branch fix/t03-control-states with message T03: Primary, disabled and on states.
  • Append a short entry to audit-fixes/PROGRESS.md: what changed, which findings were fixed, skipped or not reproducible, and anything the reviewer should look at.
1# T03 · Primary, disabled and on states
2
3**Phase 1** · 11 findings (1 high, 7 medium, 3 low) · Depends on: nothing, can start now
4
5## Goal
6Enabled and disabled primary buttons look the same, dark-mode primary buttons are green on green, toggle "on" is barely visible, and checkboxes use browser blue. Define the states once in the shared components.
7
8## Files to change
9These are the likely files. Read them before editing, and change others only if the fix needs it.
10- `src/components/ui.tsx` (Button, Toggle, Checkbox)
11- `src/styles/app.css`
12- `src/styles/kit/` (only if the token lives there; keep sync:kit working)
13
14## Findings to fix (high and medium)
15| # | Severity | State | Issue | Suggested fix |
16|---|---|---|---|---|
17| 1 | High | `GLOBAL` | Primary buttons (New chat, Send, Approve, Open preview) use the same pale-green tint enabled or disabled; Approve looks disabled, Send-enabled ≈ Send-disabled | solid #10b981 + white for enabled; neutral grey for disabled |
18| 2 | Medium | `GLOBAL-chat` | At 1280×720 the composer (3-line empty textarea + toolbar + stats) takes ~250px; reading area is ~420px | 1-line composer that grows; stats inline in toolbar |
19| 3 | Medium | `GLOBAL` | Native checkboxes render browser blue (#2563eb) — off-palette | accent-color: #10b981 (or ink) app-wide |
20| 4 | Medium | `skills-*` | Toggle "on" state is pale mint with a white knob — barely distinguishable from "off" | solid #10b981 track when on |
21| 5 | Medium | `tasks-populated` | Row actions are unlabeled icons (pencil, paper-plane for "run now", toggle); paper-plane reads as "send" | tooltips + text "Run now"; label the toggle "On schedule" |
22| 6 | Medium | `tasks-detail-*` | Detail view keeps list chrome (Demo note, "Deleted tasks" checkbox, search, sort) and the generic subtitle; "All tasks" is a centred underlined link above content | breadcrumb "Tasks › Daily briefing" top-left; hide list controls |
23| 7 | Medium | `dark-*` | Primary buttons in dark (Approve, Open preview, Save setup and load, New chat) are dark green fill with green text (~3:1) | solid #10b981 with #0b1f17 or white text; same rule as light |
24| 8 | Medium | `dark-skills-overview / dark-skills-edit` | "On" toggles in dark are a dark green track with a dark knob — on vs off is hard to tell | bright #10b981 track + white knob when on |
25
26## Optional polish (low)
27Do these only if the task is otherwise done and the budget allows.
28
29| # | Severity | State | Issue | Suggested fix |
30|---|---|---|---|---|
31| 1 | Low | `GLOBAL-sidebar` | Task rows show pencil + trash icons permanently on every row | reveal on hover/focus |
32| 2 | Low | `dark-*` | Disabled "Save for next load" in dark is near-invisible green-on-green | neutral disabled style shared with light |
33| 3 | Low | `dark-preview-pdf / dark-preview-website` | PDF page and website preview stay bright white/cream inside the dark panel — expected for document content, but there's no frame or dimming option | thin border + optional "Dim document" toggle |
34
35## How to check
36Run these and fix anything that fails:
37- `npm run typecheck`
38- `node --test tests/` (all existing tests stay green)
39- `npm run check` (typecheck, UI audit, contrast, measure, luminance)
40- `npm run build`
41
42Task-specific checks:
43- [ ] Primary enabled: solid #10b981 with white text, both themes. Disabled: neutral fill (#eef1f4 light / a neutral grey in dark) with muted text, not a green tint.
44- [ ] Toggle on: bright green track and white knob, both themes. Off: neutral track.
45- [ ] Checkboxes use the brand green via accent-color or a custom control.
46- [ ] `npm run contrast` passes; add the new states to it if they are not covered.
47- [ ] Each finding above is resolved, or marked "already fixed by Txx" or "not reproducible" with a one-line reason.
48
49Screens to re-capture and compare with the audit screenshots in `docs/evidence/audit-2026-10-07/`:
50- `tasks-populated-light.png`
51
52## Done when
53- All checks pass.
54- Commit on branch `fix/t03-control-states` with message `T03: Primary, disabled and on states`.
55- Append a short entry to `audit-fixes/PROGRESS.md`: what changed, which findings were fixed, skipped or not reproducible, and anything the reviewer should look at.