@micha.bigler/ui-core-micha 3.11.1 → 3.12.0

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.
@@ -0,0 +1,80 @@
1
+ # UCM-THEME-16: Dark-safe info box in `QrSignupManager`
2
+
3
+ # A. Envelope, authored by the Expertenchat
4
+
5
+ ## Goal & expected outcome
6
+
7
+ The "Signup Access / valid until" box under a generated signup QR code stays readable in dark mode. Today it
8
+ paints a fixed light ground, `grey.50` (`#FAFAFA`), under the theme's secondary text; in dark that is
9
+ `#AAB5BF` on `#FAFAFA`, **2.00:1**. After this order the box takes `background.subtle`, which resolves per
10
+ mode: light `#F4F5F6` (5.37:1 for its text), dark `#20262C` (7.32:1).
11
+
12
+ ## Decided (operator, 2026-10-02)
13
+
14
+ - **`src/components/QrSignupManager.jsx:376`**: `bgcolor: 'grey.50'` -> `bgcolor: 'background.subtle'`.
15
+ **The light change is accepted**: `#FAFAFA` -> `#F4F5F6`, a 1.05:1 step, barely visible.
16
+ - **`src/components/QrSignupManager.jsx:361`** (`bgcolor: '#ffffff'` behind the QR code itself) **stays white
17
+ on purpose**: a QR code needs a light quiet zone to scan. Recorded in `docs/DARK-TOKENS.md`.
18
+ - **`src/messaging/ReadTicks.jsx:14`** (`DM_SENT_COLOR = 'grey.500'`) **stays unchanged.** It already clears
19
+ contrast in dark (6.07:1 on the dark paper). The candidate `text.disabled` (`#6A7178`) is the value the file's
20
+ own comment records as rejected, because it read too close to the "read" state. In light the tick sits at
21
+ 2.68:1 on white. That is a pre-existing condition, softened by the icon shape (Done vs DoneAll), and not
22
+ part of this order.
23
+
24
+ These decisions replace the register row's original question ("accept the small light change, or add a
25
+ token"), raised by the `UCM-THEME-14` review.
26
+
27
+ ## Scope + non-goals
28
+
29
+ In scope: the one property at `QrSignupManager.jsx:376`; `CHANGELOG.md`; a **patch** release.
30
+
31
+ Non-goals: no change to `ReadTicks.jsx`, to the QR code's white ground, or to any token value.
32
+
33
+ ## Tier · precondition / gate
34
+
35
+ - **Tier 3 · tests: one rendered-style assertion per mode for the info box; the component's existing tests.**
36
+ A change inside shared-core, even at one line (`AGENTS.md` -> Tiering).
37
+ - Precondition: `UCM-THEME-14` landed (3.11.0, confirmed 2026-10-02).
38
+
39
+ ## Risks
40
+
41
+ - The light change is the only light-output change since `UCM-THEME-14`'s regression fixture. If that fixture
42
+ covers this component, it needs this one entry updated, named, and nothing else.
43
+
44
+ ## Required tests to WRITE (you write them and run YOUR OWN new ones; the Orchestrator's run is the gate)
45
+
46
+ 1. In a light theme from `createAppTheme`, the info box's background resolves to `#F4F5F6`; in a dark theme to
47
+ `#20262C`. Assert against the theme's own `background.subtle`, not a copied hex.
48
+
49
+ Run, do not write: the existing `QrSignupManager` tests and the light regression fixture.
50
+
51
+ ## Parity guardrail
52
+
53
+ No behaviour change. One background, both modes.
54
+
55
+ ---
56
+
57
+ # B. Implementation map, filled by the Orchestrator and ADDRESSED TO THE IMPLEMENTER
58
+
59
+ *Placeholder. The Orchestrator fills the context package, the absolute working directory, the
60
+ progress contract and the preamble block on `git pull`, per `AGENTS.md` -> "Work Order". A one-line change
61
+ may be implemented by the Orchestrator directly; authorship then sits with it and the independent review
62
+ carries independence. Do not dispatch while this placeholder stands.*
63
+
64
+ ---
65
+
66
+ # C. Orchestrator only, NOT ADDRESSED TO THE IMPLEMENTER
67
+
68
+ > **If you are the implementer reading this work order as your own specification: STOP at this line.**
69
+ > Everything below describes what the Orchestrator does AFTER you finish. You do none of it: no
70
+ > reviewers, no verification run, no register edit, no `git add`/`commit`/`push`.
71
+
72
+ - Check `.claude/codex-status.md` first (newest-first). Before `git push`, run `git log origin/main..HEAD` and
73
+ push only if every listed commit is this order's.
74
+ - Review: Tier 3, independent `reviewer` (all configured lenses) and `ui_reviewer`, one batch, before the
75
+ commit.
76
+ - Release: verify the publish through the job log (`npm view` lags for provenance publishes). Row -> `done`
77
+ with the review Notiz and the version.
78
+
79
+ Mini-handover: `Orchestrator: implement work-orders/UCM-THEME-16.md in ui-core-micha (main). git pull first,
80
+ read the WO, then follow orchestrate-codex.`
@@ -0,0 +1,111 @@
1
+ # UCM-THEME-17: Decide a less compressed baseline type scale
2
+
3
+ # A. Envelope, authored by the Expertenchat
4
+
5
+ ## Goal & expected outcome
6
+
7
+ The baseline's heading steps are too small to carry a hierarchy. Page title, card title and section label
8
+ differ by 1 to 3 px, so screens rely on weight alone, and where every level is bold the levels merge. This
9
+ order produces the **decided** type scale as a committed reference sheet that the operator freezes. A
10
+ later implementation order puts it into `src/theme/tokens.js`. The output here is a document, no code.
11
+
12
+ Operator decision (2026-10-04): treat this as a baseline finding, the way dark mode was treated
13
+ (`UCM-THEME-13`), not as per-app overrides.
14
+
15
+ ## Context the operator established
16
+
17
+ - **The baseline scale today** (`src/theme/tokens.js:157-168`): h1 32, h2 28, h3 24, h4 20, h5 18, h6 16,
18
+ subtitle1 15/600, subtitle2 13/500, body1 14, body2 13, button 14/500, caption 12, overline 11 (px).
19
+ - **Measured on rendered screens, 2026-10-04** (computed styles in the browser):
20
+
21
+ | Screen | Page title | Card title | Section | Text |
22
+ |---|---|---|---|---|
23
+ | hram, Research | h4 20/500 | h5 18/500 | subtitle1 15/600 | 14 |
24
+ | jg-ferien, Dashboard | h5 18/600 | h6 16/600 | – | 14, partly 600 |
25
+ | kerzenziehen, Admin | h5 18/600 | – | – | 14 |
26
+ | survey_app site (operator screenshots) | h4 20/800 | h6 16/800 | – | – |
27
+ | for comparison, the MUI scale (spesix, stale local build) | h4 34 | h5 24 | – | 16 |
28
+
29
+ - **Operator feedback:** survey_app editor and sites read "more harmonious" at the old MUI sizes, and on the
30
+ sites the section title and the question labels became indistinguishable. jg-ferien already restored its
31
+ own sizes (`jg-ferien` `JG-DL-7`). Six other apps accepted the baseline scale without comment.
32
+ - **The MUI scale is the other extreme**: 34/24 px titles read heavy in a dense tool.
33
+
34
+ ## Inventory (stage 1, 2026-10-04)
35
+
36
+ From 88 prototypes in `*/work-orders/assets/` (screen selectors hand-checked in nine: KZ-UI-1, RES-14,
37
+ INNO-PLAN-1, JG-MEM-1, UX-10, PRIM-1, FM-8, OBS-10, KIRA-CRUD-6), the app theme overrides and the
38
+ measurements above:
39
+
40
+ | Role | Baseline today | Approved prototypes (typical) | MUI |
41
+ |---|---|---|---|
42
+ | Screen title | h4 20/600, fixed | 24 at 1280, 17-21 at 375 (KZ 24->17, jg 25.6->20, survey 24->21) | 34 |
43
+ | Panel / dialog | h5 18 | 18-20 | 24 |
44
+ | Card title | h6 16 | 15-18 | 20/500 |
45
+ | Section label | subtitle1 15/600 | 12-13 at 600-700 | - |
46
+ | Body | 14 | 14 (20 sheets), 15 (13 sheets) | 16 |
47
+
48
+ - The approved designs had the larger title step (screen title about 1.7x body; baseline 1.43x), and step
49
+ the title down on mobile. Both were lost between prototype and baseline.
50
+ - The section label sits on the wrong side of body: 15 px, one pixel under the card title.
51
+ - jg-ferien rejected larger **body** text (`JG-DL-7`); survey_app misses **heading** steps. The two are
52
+ compatible.
53
+ - Weight no longer carries hierarchy: every heading is 600 and apps override it per level (survey_app 800,
54
+ hram 500).
55
+
56
+ ## Structural decisions (operator, 2026-10-04)
57
+
58
+ 1. **One scale** for every app and page type; no separate reading register. Body stays the tool density.
59
+ 2. **The screen title steps down one size on narrow screens.**
60
+ 3. **Size carries the hierarchy, weight is fixed**: headings share one weight; the section label is small
61
+ and strong. App overrides are for font family, not for per-level weight.
62
+ 4. **The section label (subtitle1) moves below body size**, set apart by weight.
63
+
64
+ The role mapping of the `THEME-1` sheet stands: h4 screen title, h5 panel/dialog, h6 card title.
65
+
66
+ ## Outcome
67
+
68
+ **Frozen 2026-10-04** after two value rounds: candidate B, mobile screen title 23, h1 to h3 36 / 32 / 28. The
69
+ frozen sheet is [`docs/TYPE-SCALE.md`](../docs/TYPE-SCALE.md); the implementation order is `UCM-THEME-18`.
70
+
71
+ ## Scope + non-goals
72
+
73
+ In scope: an inventory of the type sizes the estate actually uses (app overrides, prototypes, the
74
+ `THEME-1` reference sheet's own reasoning); an instrument showing two to three candidate scales next to
75
+ today's baseline and the MUI default, on real screens (hram Research, a survey site, the jg-ferien dashboard,
76
+ a kerzenziehen admin view), at 375 px and 1280 px; value rounds; a frozen sheet with provenance and the
77
+ rejected candidates.
78
+
79
+ Non-goals:
80
+ - No code, no tests (the implementation is a separate order).
81
+ - No change to font families. Apps keep their identity fonts.
82
+ - No per-app decisions. App overrides that exist only to escape the compressed scale (survey_app's planned
83
+ revert, `JG-DL-7`) are reviewed after the freeze, not here.
84
+
85
+ ## Tier · precondition / gate
86
+
87
+ - **Tier 2 · tests: none (document only).** It decides future shared-core content but changes none.
88
+ - Precondition: none.
89
+ - Gate: **the operator freezes the sheet**, with a dated section in it.
90
+
91
+ ## Risks
92
+
93
+ - **Every adopted app moves with the baseline.** A new scale changes the look of ten-plus apps at once; the
94
+ instrument has to show the dense tool screens, not only reading screens.
95
+ - **Bigger steps cost vertical space** on dense screens (hram, cockpit). The candidates must be judged
96
+ there, not only on the survey sites.
97
+ - **Weight and size interact.** The fix may be partly a weight rule (fewer bold levels), not only sizes.
98
+
99
+ ---
100
+
101
+ # B. Implementation map
102
+
103
+ *Not applicable. This is an Expertenchat document order, authored in-session with the operator.*
104
+
105
+ ---
106
+
107
+ # C. Orchestrator only, NOT ADDRESSED TO THE IMPLEMENTER
108
+
109
+ > **If you are the implementer reading this: STOP.** There is no implementer for this order.
110
+
111
+ Register: row -> `done` with the commit of the frozen sheet. Then the implementation order is written.
@@ -0,0 +1,184 @@
1
+ # UCM-THEME-18: Ship the frozen baseline type scale
2
+
3
+ # A. Envelope, authored by the Expertenchat
4
+
5
+ ## Goal & expected outcome
6
+
7
+ `createAppTheme` produces the type scale frozen in [`docs/TYPE-SCALE.md`](../docs/TYPE-SCALE.md) (`UCM-THEME-17`,
8
+ frozen 2026-10-04), in light and dark. The screen title (h4) steps down one size below the baseline's `sm`
9
+ breakpoint. Released as a **minor** version (`3.12.0`), because every adopted app looks different after the bump.
10
+
11
+ ## Decided values (from `docs/TYPE-SCALE.md`, by variant)
12
+
13
+ | Variant | Before | After |
14
+ |---|---|---|
15
+ | h1 / h2 / h3 | 32 / 28 / 24 | **36 / 32 / 28** |
16
+ | h4 | 20 | **24**, and **23 below `sm`** |
17
+ | h5 | 18 | **20** |
18
+ | subtitle1 | 15 | **13** |
19
+
20
+ Unchanged: h6, subtitle2, body1, body2, button, caption, overline; every weight (headings 600, subtitle1 600);
21
+ every line height; `letterSpacing`. If this table and `docs/TYPE-SCALE.md` disagree, the sheet wins.
22
+
23
+ ## Context the operator established
24
+
25
+ - **Typography lives in one block**: `src/theme/tokens.js:223-241`, built with `typeVariant` (`tokens.js:45`).
26
+ `createAppTheme` (`src/theme/createAppTheme.js:379-387`) spreads it unchanged and takes only `fontFamily`
27
+ from the app, so light and dark get the same scale from the same place.
28
+ - **Breakpoints**: `tokens.js:250-252`, `sm: 600`. The mobile step means "below `sm`", the same line MUI's
29
+ `breakpoints.down('sm')` draws.
30
+ - **`assertThemeComplete`** reads `fontSize`, `fontWeight`, `lineHeight` and `letterSpacing` per variant
31
+ (`src/theme/themeCompleteness.js:38`). A nested media-query key inside h4 is new to it.
32
+ - **The light regression fixture** `tests/fixtures/light-theme-baseline.json`, checked by
33
+ `tests/createAppThemeLightGuard.test.js`, contains the typography and changes with this order.
34
+ - **The kit's own screens use the variants too** (h6 about 24 times, h4 twice, h5 once in `src/`), so kit
35
+ screens such as the account pages change with the scale. That is intended.
36
+
37
+ ## Scope + non-goals
38
+
39
+ In scope: the typography values above; the h4 step below `sm`; the fixture's typography entries;
40
+ `CHANGELOG.md` naming the visible change for every adopted app; the minor release.
41
+
42
+ Non-goals:
43
+ - No app repo changes. The per-app follow-up (listed below) is written after the release, one order per app.
44
+ - No font family, weight or line-height change; no new variant; no change to `breakpoints`.
45
+ - No responsive step for any variant other than h4.
46
+
47
+ ## Tier · precondition / gate
48
+
49
+ - **Tier 3 · tests: the typography values per variant and the h4 step, in light and dark; the light
50
+ regression fixture updated in its typography entries only; the existing `createAppTheme` and completeness
51
+ tests.** A change inside shared-core (`AGENTS.md` -> Tiering).
52
+ - Precondition: `UCM-THEME-17` `done` (frozen sheet committed).
53
+ - No prototype gate: the instrument is a decision sheet, not a screen to match.
54
+
55
+ ## Risks
56
+
57
+ - **Every adopted app moves on its next bump.** Intended; the changelog says so in one line an app session can
58
+ act on.
59
+ - **An app that overrides h4's size keeps the baseline's 23 px below `sm`**, because a theme merge keeps the
60
+ nested media key. survey_app sets h4 to `2.125rem` today; on mobile it would fall to 23. The per-app
61
+ follow-up handles it; the changelog names it.
62
+ - **`assertThemeComplete` may misread the nested key** (as a missing or extra surface). It must neither raise
63
+ a finding for the baseline's own media key nor let an app's h4 override go unnoticed.
64
+
65
+ ## Required tests to WRITE (you write them and run YOUR OWN new ones; the Orchestrator's run is the gate)
66
+
67
+ 1. For a light and a dark theme from `createAppTheme`: each variant in the table resolves to its decided
68
+ `fontSize`, read from the theme, compared with the value in the table.
69
+ 2. h4 carries a media-query entry for "below `sm`" with `fontSize` 23px, and that query is derived from
70
+ `breakpoints.values.sm`, not typed a second time. Show the test fails if `sm` changes and the query does not.
71
+ 3. `assertThemeComplete` on the baseline returns no typography finding.
72
+
73
+ Run, do not write: `tests/createAppTheme.test.js`, `tests/createAppThemeLightGuard.test.js` (with the fixture's
74
+ typography entries updated, and only those), the completeness tests.
75
+
76
+ ## Parity guardrail
77
+
78
+ No behaviour change; type sizes only. Palette, spacing, components and exports unchanged.
79
+
80
+ ## Downstream (not this order; one order per app after the release)
81
+
82
+ Measured 2026-10-04 (see `docs/TYPE-SCALE.md` -> "Known consequences"):
83
+
84
+ | App | What the follow-up does |
85
+ |---|---|
86
+ | hram | screen titles on 5 pages from h5 to h4; drop the per-level weight 500 |
87
+ | jg-ferien | screen titles on 3 pages from h5 to h4 (`DashboardPage.jsx:187`) |
88
+ | kerzenziehen | admin screen title from h5 to h4 |
89
+ | spesix | 1 page title from h5 to h4; drop per-level weight overrides |
90
+ | fitness-monitor | 1 page title from h5 to h4 |
91
+ | survey_app | drop the 800/700 weights and the h4 `2.125rem`/400 override; decide the h3 page titles (24 -> 28); closes the held `SVA-THEME-1` typography revert |
92
+ | all other adopted apps | bump only |
93
+
94
+ webshop-guenter (own handoff scale), Kira, Cinevia and Gustav (no MUI heading variants) are unaffected.
95
+
96
+ ---
97
+
98
+ # B. Implementation map, filled by the Orchestrator and ADDRESSED TO THE IMPLEMENTER
99
+
100
+ Work from this package; open only the named files. A value the sheet lacks is `RESULT: BLOCKED <value>`.
101
+
102
+ ## Target working directory (absolute)
103
+
104
+ `C:\Users\biglmi\Documents\webapps\ui-core-micha` (branch `main`). Never the workspace root.
105
+
106
+ ## Context package
107
+
108
+ - **`src/theme/tokens.js`**: `BASELINE_STATIC.typography` (l.~222-241) uses `typeVariant(size, weight, lineHeight, extra)`
109
+ (l.45). Change h1/h2/h3/h4/h5/subtitle1 to the table in Part A; nothing else in that block moves.
110
+ h4 gets the mobile step as a nested media-query key inside the variant (`extra`), `fontSize: '23px'`.
111
+ The query must be **derived from the breakpoint value**, not typed a second time: introduce one
112
+ constant for `sm` (600) in `tokens.js`, use it in `breakpoints.values.sm` (l.~251) and build the key
113
+ from it, in the form MUI's `breakpoints.down('sm')` produces (`@media (max-width:599.95px)`, that is
114
+ `sm - 0.05`). Export the constant or the key builder so the test can reference it.
115
+ - **`src/theme/createAppTheme.js`** (l.~379-387) spreads `BASELINE_STATIC.typography` and takes only
116
+ `fontFamily` from the app; no change expected. Verify the nested media key survives `createTheme`
117
+ into `theme.typography.h4` in both light and dark (read the resolved theme, do not assume).
118
+ - **`src/theme/themeCompleteness.js`** (`TYPOGRAPHY_SURFACES`, l.~38) reads fontSize/fontWeight/lineHeight/
119
+ letterSpacing per variant. Verify the baseline h4 with its media key raises no finding; change this file
120
+ only if it does.
121
+ - **Light regression fixture** `tests/fixtures/light-theme-baseline.json` (checked by
122
+ `tests/createAppThemeLightGuard.test.js`): update ONLY the typography entries that this order changes
123
+ (h1-h5 and subtitle1 `fontSize`, and h4's new media key), in both of its snapshots (`baseline`, `override`).
124
+ Regenerate carefully: the diff of the fixture must contain nothing but those typography lines. Do not
125
+ re-capture the whole file blindly; check `git diff` of the fixture afterwards (use `git diff` to read it,
126
+ do not stage).
127
+ - **Docs / release**: `CHANGELOG.md` entry `3.12.0 - UCM-THEME-18` (newest first, same style as the
128
+ existing entries): the new scale in one table-free sentence; the visible change for every adopted app;
129
+ that an app overriding h4's `fontSize` keeps the baseline's 23px below `sm` (survey_app sets h4
130
+ `2.125rem`); that headings are fixed at weight 600 and apps should not override per level.
131
+ `package.json` version `3.11.2` -> `3.12.0` (no lockfile in this repo).
132
+ - Kit components: no edit expected (they use the variants).
133
+
134
+ **Existing tests to follow** (style): `tests/createAppTheme.test.js`, `tests/createAppThemeDark.test.js`.
135
+ New tests go in `tests/createAppThemeTypography.test.js`.
136
+
137
+ **Pitfalls**: weights, line heights, letterSpacing, h6, subtitle2, body1/2, button, caption, overline are
138
+ unchanged and must stay byte-identical. Do not touch `breakpoints` values or add a second source for `sm`.
139
+
140
+ ## Required tests, restated
141
+
142
+ The three tests of Part A. Test 2 must show it can fail: derive the expected query from
143
+ `breakpoints.values.sm` of the resolved theme (not a literal), and include an assertion that would break if
144
+ the baseline's key were typed independently of that value (for example by building a theme with a different
145
+ `sm` through the same constant, if the constant is the single source, or by asserting the key string equals
146
+ the builder applied to the theme's own `sm`).
147
+
148
+ ## Preamble
149
+
150
+ The text above is the COMPLETE spec: the committed WO file's content, not a plan to refine; there is no
151
+ separate plan file. Read the nearest `AGENTS.md`, the relevant `.codex/skills/<role>/SKILL.md`, and the app
152
+ `MEMORY.md` ONLY for conventions. Stay in scope; do not touch auth/permissions/deps/schema/CI unless the
153
+ spec says so; do not update `MEMORY.md`. **Do NOT edit `WORK_ORDERS.md`: the register row and the review
154
+ verdicts are the orchestrator's alone.** **Your tools are for editing source and test files and for running
155
+ the tests you wrote, nothing else.** Do NOT install dependencies, touch a lockfile, run a package manager,
156
+ or tidy up stray files; if something in the repo state blocks you, stop and report it as
157
+ `RESULT: BLOCKED <reason>` instead of fixing it. Do NOT `git add`/`commit`/`push`: leave every change
158
+ uncommitted in the working tree for the orchestrator's independent review. WRITE the tests the
159
+ `Required tests` section calls for AND **RUN the tests you just wrote** to confirm they execute and pass:
160
+ that is the ONLY test run you do (NOT the affected/full suite, NOT any review). Run them with
161
+ `npx vitest run <your test files>`. The orchestrator re-runs the authoritative set and does the independent
162
+ review after you finish; those are the gate.
163
+
164
+ Narrate continuously: a `PLAN: <step1> | <step2> | ...` line up front, then a single-line
165
+ `PROGRESS: [<n>/<total>] <present-tense action>` before every relevant action (and `... done` on
166
+ completion), spaced so no gap exceeds ~2 min, stdout unbuffered, plus exactly one final
167
+ `RESULT: DONE|BLOCKED <reason>`.
168
+
169
+ ---
170
+
171
+ # C. Orchestrator only, NOT ADDRESSED TO THE IMPLEMENTER
172
+
173
+ > **If you are the implementer reading this work order as your own specification: STOP at this line.**
174
+ > Everything below describes what the Orchestrator does AFTER you finish. You do none of it: no
175
+ > reviewers, no verification run, no register edit, no `git add`/`commit`/`push`.
176
+
177
+ - Check `.claude/codex-status.md` first (newest-first). Before `git push`, run `git log origin/main..HEAD` and
178
+ push only if every listed commit is this order's.
179
+ - Review: Tier 3, independent `reviewer` (all configured lenses) and `ui_reviewer`, one batch, before the commit.
180
+ - Release `3.12.0`: verify the publish through the job log (`npm view` lags for provenance publishes). Row ->
181
+ `done` with the review Notiz and the version. Then the Expertenchat writes the per-app orders above.
182
+
183
+ Mini-handover: `Orchestrator: implement work-orders/UCM-THEME-18.md in ui-core-micha (main). git pull first,
184
+ read the WO, then follow orchestrate-codex.`