Commit Graph
130 Commits
Author SHA1 Message Date
bchanot 1deb037fac feat(editor): fixed edit strip and message line without layout shift
U2 Task 3 (A6, A14, R-2). A fixed-height strip over the drawing and the
right column replaces the tool line, the sr-only selection tag of the
edit body and TracingBar: lead (name + status, type + detail), notice
(refusal, first geometry issue + n, unmeasured view with its link, no
category, no child view), commands (Fermer le trace, Retirer le dernier
sommet, Annuler le trace). A fixed-height line under the drawing holds
the add buttons and the gesture message: a kept drop says « Point
deplace » with « Defaire » (same store undo as the header), a refused
drop says « Deplacement refuse : ... » as a red alert. 6 s, held by
mouse hover and focus inside, closed by any commit, undo or redo.
trace_pop and Backspace remove the last vertex. The busy « Aller a »
target is the strip's tracing commands. scrollbar-gutter stable, scoped
to the editor. e2e helper expectNoShift (boxes, scroll height, gutter,
client width, layout-shift sum). DraftHeader untouched: no shift seen.

Rewritten assertions (old -> new):
- tab unit « Sélection : point » on annotation-selection-tag -> strip
  detail « Point »
- tab unit tag sr-only, not live -> strip lead outside any live region
- tab unit « 1 sommet posé. » -> « 1 sommet posé » (board 04 wording)
- tab unit D6b tag present / « zone » -> strip detail « Point » /
  « Zone · 3 sommets »
- keep-alive, sections, escape units: tracing-bar -> tracing-commands
- e2e selectionTag helper -> strip title with data-selection; the
  twin's tag is twinSelectionTag (deselect 375 px describe)
- e2e deselect « tag position absolute » (edit) -> strip height 64 px,
  drawing top unchanged; twin Escape test keeps tag 0, properties 0,
  overview visible
- e2e deselect and journey tracing-bar / annotation-selection-tag ->
  tracing-commands / selectionTag
- e2e historyButton scoped to history-buttons (the message's
  « Défaire » has the same accessible name)
2026-11-17 17:45:41 +01:00
bchanot 08d266c89f refactor(editor): one press machine for clicks, drags and taps on the drawing
press.ts (pure: slop per pointer kind, nearest handle, press target, click
and drag actions, double click, stepPress) is now the editor canvas's only
decider; useCanvasGestures no longer uses clickHandler, useEmptyTap,
swallowClick nor useMoveGesture (deleted), and the box has no onClick.
canPan = dragAction(press target).type === 'pan' at pointer-down; framing
keys only when the box itself is the target. workStore.ts holds the U2
work with stale stamps: dropStale on every documentText change, reset on
a new session (editorStore subscription). The catalogue keeps useFraming
defaults and useEmptyTap, unchanged.

Named change (A13): a finger drag on a selected zone's (or circle link's)
interior moves nothing; the selected point is its own handle and still
moves by any pointer. Second observable change: touch and pen taps are
decided at the pointer-up from the press target, no longer from the
following click (no browser touch adjustment toward a marker).

tests/setup.ts: happy-dom has no elementsFromPoint; a shim answers the
pointerdown target and its ancestors.

Rewritten tests (editor-annotations-tab.test.tsx, D6b):
- "a touch tap deselects in its own click, not at the pointer-up" ->
  "a touch tap deselects at the pointer-up" (deselected after pointerup)
- "a touch tap whose click lands on a marker (adjustment) selects that
  marker" -> "a touch tap is decided by its press: a click adjusted toward
  a marker selects nothing" (deselected, announced, marker b not current)
- "a pen tap deselects in its own click, like a touch tap" -> "a pen tap
  deselects at the pointer-up, like a mouse tap"
- "a pen tap whose click lands on a marker selects that marker" -> "a pen
  tap is decided by its press: a click landing on a marker selects
  nothing"
Added: "a finger drags the selected point (its handle), never a selected
zone (A13)".
Drive-only changes, assertions unchanged: canvas fireEvent.click(x, y)
-> pressAt (pointerdown + pointerup) in the tab suite (C26, tracing,
paths, H3, H6, H8, filter reselect), editor-keep-alive and
editor-sections; drag moves carry buttons: 1 (C34, polygon block move,
H8 lostpointercapture and read-only, editor-no-loss drag in flight),
since a move without a button is a hover.
2026-11-17 16:56:35 +01:00
bchanot 1e5058577f fix(app): failure row fits Réessayer and Consulter side by side
Board 30: in a three-column card at 1280 px the two buttons wrapped by a
few pixels. The failure row narrows their padding only there; the wrap
stays as the fallback. The network e2e now checks both on one row.
2026-11-17 01:04:03 +01:00
bchanot 2930f4919f style(app): wrap R4 lines over 100 columns 2026-11-17 00:59:34 +01:00
bchanot b378cf066f fix(app): card retry keeps focus and voice when no retry is left
A retry ending on a failure with no retry (network to integrity, engine
stopped for good) keeps the polite region and moves focus to Consulter.
Busy look on Réessayer, error tone once the engine stopped, one attempt
for two calls in one tick; tests for the stopped engine, two core cards
and no blob URL after unmount.
2026-11-17 00:59:30 +01:00
bchanot 6ad8d8347c feat(app): catalogue cards say an integrity or load failure (board 30) 2026-11-17 00:14:14 +01:00
bchanot f061111e25 feat(ui): notice warning tone, glyph and non-live option 2026-11-17 00:08:45 +01:00
bchanot 423125c18f feat(app): search, sort, count and date on the official sheet list
Boards 28 and 29 A: name search with clear button and Escape, « Trier
par » (last modification by default, or name), a polite count line,
« Modifiée le … » on each row in a <time>, and the search no-result
block. The detail line moves to labels.ts as sheetDetails.

R-24: no existing assertion removed or rewritten; six tests added.
2026-11-16 17:03:08 +01:00
bchanot 3e94f732c7 fix(editor): citation notices, literal citation text, local limits 2026-11-15 20:50:48 +01:00
bchanot ee7912768c fix(editor): draft notice after the reference dialog, locale list 2026-11-15 20:08:55 +01:00
bchanot 1d119c3684 fix(editor): stale cite choice reset, pending line under the add row 2026-11-15 20:00:28 +01:00
bchanot 70eb2fcbb4 feat(editor): a reference made in the citations draft saves with it 2026-11-15 19:55:41 +01:00
bchanot 8c3fcca0b9 feat(editor): « Citer » button and family labels in references 2026-11-15 19:40:47 +01:00
bchanot 240c2ba0e7 feat(editor): dialog close button is a 44 px touch box 2026-11-15 19:40:46 +01:00
bchanot 5059641c04 fix(editor): edit mode focuses the draft, tile edit call 2026-11-15 17:43:43 +01:00
bchanot 7a5684aace fix(editor): an explicit discard of the citations draft says nothing 2026-11-15 17:04:28 +01:00
bchanot 11c2b0c5ee fix(editor): Task 12 review minors, delete hint and cite label 2026-11-15 16:58:50 +01:00
bchanot 3dc5820e3a feat(editor): edit mode of the references dialog
« Modifier » turns the references dialog into a draft of adds and removes,
saved as one update on the current citations. A new layer, citations,
guards it between the finding and the reference dialogs: close, Back,
POP refusal and the leave cascade ask it. « Modifier la référence » and
« Nouvelle référence » stack the reference dialog over it; a creation it
started joins its draft.
2026-11-15 16:39:43 +01:00
bchanot d9dbcf1609 fix(editor): dialog trigger for references, Task 11 review minors 2026-11-15 16:25:32 +01:00
bchanot da755f9768 fix(editor): Plus rows hover tint, axe on an active row, line limits 2026-11-15 16:21:01 +01:00
bchanot abc781df52 feat(editor): references dialog over the finding, view mode
A modal Dialog replaces the citations side sheet; families open it too
(isCitable). The finding dialog shows only « Références citées » and
« X références », also at zero; its edit form no longer carries
reference_ids. A dirty form refusing « Aller à » or « Tout afficher »
closes the clean references dialog first.
2026-11-15 16:13:57 +01:00
bchanot ff21b0315e feat(editor): one tab order, vertical Plus list with the error count 2026-11-15 15:52:28 +01:00
bchanot bb35e86dbb fix(editor): five locals in stepHistory and MoreTabs, sync tag in tests 2026-11-14 18:52:41 +01:00
bchanot 28e298ac56 fix(editor): a sign-out with a dirty dialog is said at the next sign-in 2026-11-14 18:50:42 +01:00
bchanot 791fc03a0d fix(editor): Task 8 round 2, cascade closes the sheet 2026-11-14 15:13:38 +01:00
bchanot 579d8afff4 fix(editor): Task 8 round 1, sync tag, cascaded leave ask 2026-11-14 15:01:23 +01:00
bchanot 07bebbc855 feat(editor): session tag in history, confirm before leaving 2026-11-14 14:47:43 +01:00
bchanot 4018344ffc fix(editor): Task 7 round 1, reveal reset, forced-colors ring 2026-11-14 14:28:20 +01:00
bchanot 085c56877c fix(editor): deletion undo and Back, Plus focus to the panel 2026-11-14 14:24:06 +01:00
bchanot 270444e2ec fix(editor): Task 6 round 1, draft store tests, dead rescue 2026-11-14 14:15:11 +01:00
bchanot f0e49fd447 feat(editor): cite references from the finding edit form only 2026-11-14 14:11:13 +01:00
bchanot 3a7ffa2f8b fix(editor): Plus Escape focus return, sheet width rounding 2026-11-13 23:58:59 +01:00
bchanot d6e501ef04 fix(editor): final review round, prettier on shell chrome files 2026-11-13 23:42:32 +01:00
bchanot 6bf9290da7 fix(editor): final review round, history, dialogs, Plus and limits
I1 scroll restored at once on a Back into layers; I2 Aller a opens the target dialog in one push; M1-M9, criteria 8 and 17 (left-draft notice), entry caps, no exhaustive-deps disables, locals within 5.
2026-11-13 23:42:32 +01:00
bchanot dfc8965844 fix(editor): Task 4 round 1, swallow release, menu tests 2026-11-13 22:36:23 +01:00
bchanot ca5804a8b7 feat(editor): Plus dropdown overlay with back request, sticky sidebar 2026-11-13 22:32:51 +01:00
bchanot 8a60128311 fix(editor): Task 3 round 2, usePin split, comment wrap 2026-11-13 20:40:52 +01:00
bchanot 3bb3603115 fix(editor): Task 3 round 1, literal journey, pin, limits, notice 2026-11-13 20:38:04 +01:00
bchanot 8031e0078f feat(editor): reference dialog, reading tiles and finding filter in the history
R2F-5 and R2F-6: the reference dialog is a view layer above the References tab or the citations sheet (local draft, one command per changed save, creation entry becomes the reference's own). Tiles only read. « Tout afficher » filters the library by the finding, « Revenir au constat » pops or pushes. Inline tile edit, draft tile and their guards removed.
2026-11-13 20:27:00 +01:00
bchanot af300de04c fix(editor): Task 2 round 3, lint, locals, stale comment 2026-11-13 19:51:03 +01:00
bchanot 20905adf72 refactor(editor): Task 2 round 2, locals and line limits 2026-11-13 19:45:50 +01:00
bchanot b703333b20 fix(editor): Task 2 review round 1, trace calls, form hooks, keyboard proof 2026-11-13 19:39:29 +01:00
bchanot c893dec60b feat(editor): « Aller à » opens the finding dialog, spec races fixed
« Aller à » a finding shows its row and opens its dialog in view mode.
E2e helpers wait for the history to settle after a layer or section
pop; the layout walk waits out the write budget. Label rows for the
nine new keys.
2026-11-13 19:23:48 +01:00
bchanot 4731a3376a feat(editor): sheet landings, history and e2e for the finding layers
« Tout afficher » clears the search and keeps the sort. A landing waits
for the dialogs a move closed and for their focus restore. Helpers and
shell specs move to the dialog and sheet flow; new finding dialog spec
(entries, guards, flip, gone rule, Back and Forward over the layers).
2026-11-13 19:03:21 +01:00
bchanot 18085cecf8 feat(editor): finding dialog and citations side sheet in the history
Constats opens each element in one modal dialog (view, edit with a
local draft, creation) driven by the editor view layer of the browser
history. The citations panel becomes a modal side sheet stacked over
it; its geometry, exit machinery and page inertness are removed.
Back and Forward restore the layers, a dirty form asks first.
2026-11-13 18:51:35 +01:00
bchanot 792394d3b2 feat(editor): browser history for tabs, sections and Aller a
EditorView held by the navigation reducer (restore_view), a history
adapter hook mounted in EditorWorkspace (push, replace, back, mount
rule, ownership, write budget, scroll map, refused POP), a guard stack
by layer, an announcer queue joined after open dialogs.
2026-11-13 17:57:52 +01:00
bchanot 553a0e57b2 feat(ui): harden modal dialogs, add afterModalsClosed
Re-show a natively closed dialog only when its consumer answered
'kept'; returnFocus; ignore a held Escape; Dialog honours reduced
motion; useBeforeUnload extracted; focusRow reports found only when
the row holds focus.
2026-11-13 17:57:47 +01:00
bchanot cb1ad47cb0 fix(editor): announce a draft dropped with its tile
An undo or redo that removes a reference unmounted its tile with the edit view, so the
tile's announce effect never ran. The drop now speaks from onDrop itself; the citations
panel, unmounting after a forced close that already named the fields, stays quiet.
2026-11-13 15:25:22 +01:00
bchanot 94f8a8bf27 fix(editor): focus the first refused field with its own error
A user leave with several refused fields focused the first one while
the last refusal owned the single error slot. The leave now focuses
the first refused field, then re-applies it so its message shows (I1).
The add flow no longer re-pins the tile finish() just ended (M3).
2026-11-13 14:49:17 +01:00
bchanot b1fd8962ff fix(editor): say when a pinned tile is outside the search
A shown tile the search misses carries « Ne correspond pas à la
recherche » under its header (aria-describedby). The no-result notice
now needs no shown tile at all. Flip test watchers are stopped in
afterEach, so a failing assertion never leaves the setters patched.
2026-11-13 13:49:46 +01:00