chore(memory): BDR-113, LRN-128..130, R1 accepted technically
This commit is contained in:
1 parent
9852e4e5bc
commit
17c21a62cc
3 files changed
+36
-1
No files matched your search
@@ -918,3 +918,13 @@ Owner brief « R0 — Autorisation des trois dernières corrections graphiques
|
||||
**Where**: scripts/db-trial.sh grant_platform_role `local need=1` (owner branch need=2 dropped), harness 375/0 (0 factors refused, 1 granted, 2 granted, tx recount 0 refused); SUPABASE.md §5.2; V1-2 §5.7.1 step 2 dated note + §5.6 pointer. Commit 45d7453; contract .claude/tasks/contracts/2026-11-11-trial-owner-one-factor-2050.md; verifier CONFORME 7/7, security PASS, 3-lens challenge folded.
|
||||
**Alternatives**: keep 2 for owner (rejected by owner: trial friction); change SQL/production rule (forbidden without study).
|
||||
**Trade-off**: one-factor owner losing device → no second path; recovery = V1-2 §5.7.7 by hand at trial db, or new account via `grant` (SUPABASE.md §5.2).
|
||||
|
||||
## BDR-113 — R1 editor deselection paths and Escape priority (D6b press-based rule; editor only) (2026-11-12)
|
||||
- **Status**: accepted (owner 2026-11-12; R1 editor only; manual db:trial check pending)
|
||||
**Decision** (owner GO 2026-11-12 « GO R1 COMPLET + D6b », gates G1/G2): R1 sheet editor only: deselect paths = « Désélectionner » button, Escape, empty press on drawing (D6b). Scope: editor AnnotationCanvas + its read-only twin (CatalogueCanvas `onEmpty`, editor-only). NOT a general rule for other components; catalogue reader (SheetRoute) unchanged (BDR-099 item 5).
|
||||
**D6b rule**: verdict from the PRESS (`src/catalogue/useEmptyTap.ts`): pointerdown target without `[data-anno-id]`, primary, button 0, no second pointer anywhere (document capture listener), no contextmenu, accumulated move ≤ 4 px. Mouse → act at pointerup, swallow next click. Touch + pen → act in tap's own click, only if click target has no `[data-anno-id]` (pen = controller ruling after code review; cost: rare second tap after field blur-rebuild).
|
||||
**Escape order** (A5, validated, must hold): dialog > « Plus » menu > references panel > tracing > selection. Text field keeps Escape. Only SHOWN annotation body acts (`usePlaceVisible`), via document keydown listener while selection resolved, no tracing, no references open, no `dialog[open]`; target body or inside `[data-editor-workspace]`.
|
||||
**Focus** (G1, owner): button → A6 (row else drawing box); Escape from properties panel → A6; Escape elsewhere and drawing press → focus stays / canvas box. Announcement « Aucune annotation sélectionnée. ». G2: « Supprimer » style unchanged.
|
||||
**Alternatives rejected**: decide from click target (pointer capture retargets click of selected marker press; blur-commit rebuild drops click); deselect at pointerup for all pointers (touch click lands on shifted layout); Escape registry in workspace (hidden kept body cannot hold focus → per-body listener simpler).
|
||||
**Refs**: contract .claude/tasks/contracts/2026-11-12-r1-history-deselect-1141.md; plan rev 3 .claude/tasks/plans/2026-11-12-r1-history-deselect-1141.md; commits 7dda61d, bbb1668, bbdfd27, a1ee194, 132756e, 6ed90ef; docs V1-2-6_U1_CORRECTIONS.md R1 « Behaviour and limits », ANNOTATION-RENDERING.md D6b. Supersedes D6 line « empty-canvas click left to U2 » (BDR-107).
|
||||
**Validation**: technical (verifier 15/15, security PASS x2, code review fixes landed, e2e:shell 197/4/99 = baseline fails only); owner manual check on db:trial PENDING.
|
||||
@@ -886,3 +886,28 @@ Limit: wording of this client version only.
|
||||
**Not closed** (named, owner scope): failing init statement still logged (`log_min_error_statement = error`); migrate.sh puts password on psql argv during init; db-sandbox.sh same DB_INIT without flag; DEV CLI stack likely same log line.
|
||||
**Remediation of exposed value**: one-off TR_PW rotation 2026-11-11 (owner): 5 roles one tx (local logging off), secrets.env, auth/storage/rest recreated by `pnpm db:trial start`; old pw refused on scram path (container network IP; 127.0.0.1 is trust, proves nothing), new ok ×5; db container frozen env keeps dead old value.
|
||||
**Future application**: any self-hosted Postgres image with init scripts → set logging GUCs on server command line, never in init SQL; mandatory pre-production check in DEPLOY.md security prerequisites. Password probe must use non-trust pg_hba path + control with wrong password.
|
||||
|
||||
## LRN-128 — Click-time hit tests lie: pointer capture, blur-rebuild and touch click synthesis; decide taps from the press (2026-11-12)
|
||||
**Context**: R1 D6b (deselect on empty drawing press), sheet editor, Chromium. Found by plan challenge + code review, confirmed by e2e recorder.
|
||||
**Observed mechanisms** (facts):
|
||||
- Pointer capture retargets: `setPointerCapture` on the box at pointerdown (move gesture) → mouseup/click delivered to capture target (box), not the pressed marker → `closest('[data-anno-id]')` on click target = null.
|
||||
- Blur commit at mousedown: focusable box takes focus → field blur commits → store version bump → canvas `replaceChildren` rebuild before mouseup → pressed node detached → click can be dropped (Blink).
|
||||
- Touch: Chromium builds the tap's click after touchend, hit-tests the layout as it is then (after any pointerup state change shifting it), and applies touch adjustment toward `cursor:pointer` targets near the finger (~6-10 px).
|
||||
- happy-dom reproduces none of these (no capture retarget, no focus on pointerdown, no layout).
|
||||
**Implementation recommendations** (choices, not facts):
|
||||
- Decide a "tap on empty" from the press (pointerdown target, movement, pointer count), not from the click target.
|
||||
- Apply mouse verdict at pointerup and swallow the following click; apply touch/pen verdict in the tap's own click and re-check its target.
|
||||
- Unit tests: simulate capture retarget (`upOn: box`) and mousedown focus explicitly; prove the rest in real Chromium (CDP touch) with an event recorder asserting which guard fired.
|
||||
**Refs**: plan challenge records (.claude/tasks/plans/2026-11-12-r1-history-deselect-1141.md), useEmptyTap.ts, e2e/shell/editor-deselect.spec.ts, BDR-113.
|
||||
|
||||
## LRN-129 — Document-level Escape must re-check dialog and panel layers (body focus skips the React root) (2026-11-12)
|
||||
**Context**: R1 Escape priority in sheet editor (React 19). Code review found body-focused Escape skipping higher layers.
|
||||
**Facts**: keydown with focus on `document.body` (after click on non-focusable text) never traverses the React root → React handlers (ModalDialog, ReferencesPanel, workspace onKeyDown) never run. React synthetic `stopPropagation` does stop native propagation to `document`. A capture listener on document runs before everything, incl. dialogs.
|
||||
**Rule**: a document-level Escape listener must re-check the priority interfaces itself: `dialog[open]` present → skip; references panel open → skip deselect (and close panel for body-targeted Escape); `defaultPrevented`, `isComposing`, text field target → skip; act only on shown body. Keep validated order dialog > « Plus » > references > tracing > selection; every consumer `preventDefault` so later layers skip.
|
||||
**Test**: unit cases with focus on body + dialog open / references open / dialog outside workspace (phone drawer).
|
||||
**Refs**: deselect.ts useEscapeDeselect, EditorWorkspace useBodyEscape, EditorTabs useMoreEscape, commit 132756e, BDR-113.
|
||||
|
||||
## LRN-130 — happy-dom pointer/focus defaults; compressed-output proxy false OOM on piped pnpm lint (2026-11-12)
|
||||
**happy-dom** (20.x, vitest): `PointerEvent` init defaults `isPrimary: false`, `pointerType: ''`, `buttons: 0`; `fireEvent.click` moves no focus; no layout (box size 0), no pointer-capture retarget. → pass `isPrimary: true, button: 0, buttons: 1, pointerType` explicitly; focus explicitly; pan translation assertions impossible (assert zoom / preventDefault instead).
|
||||
**Compressed command output (rtk proxy)**: `pnpm lint | tail` printed `[warn] Linter process terminated abnormally (possibly out of memory)` with rc 254, while `pnpm lint > file 2>&1` gave rc 0 and every package "Done" (2026-11-12, worktree faunosteo-v1-2). Observed once in this context only; the message comes from the proxy wrapping a piped command, NOT proof that eslint never runs out of memory elsewhere. → For gate evidence, redirect to a file and read rc + per-package lines; a real OOM still has to be ruled out from the unproxied log.
|
||||
**Refs**: scratchpad gate logs r1-gates/final*, .superpowers ledger for plan 2026-11-12-r1-history-deselect-1141.
|
||||
Reference in new issue
Block a user