diff --git a/CLAUDE.md b/CLAUDE.md index 2da26b7f..ac85fbf3 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -255,7 +255,7 @@ faunosteo/ │ │ ├─ animals/{AnimalForm,ArchiveAnimalDialog,AnimalNotFound}.tsx │ │ ├─ relations/{AnimalRelations,RelationPanel,RelationActionDialog,RelationDialogs,RecordPicker,Pickers}.tsx ← in-page link panel, end / dates / void confirmations │ │ ├─ admin/{ActivateSpeciesDialog,GrantList,GrantPanel,RevokeGrantDialog,SheetBadges,SpeciesDialog,WorkingCopyAction}.tsx ← V1-2.5 rights, species and sheet pieces -│ │ ├─ editor/references/{ReferenceTiles,ReferenceTile,ReferenceFacts,ReferenceToolbar,NoResult,CitersList,CitationsPanel,CitationsSheet,ReferenceDialog,ReferenceForm}.tsx + use{ReferenceView,ReferenceLibrary,TileState,CitationsPanel}.ts ← V1-2.6 R2 and finish: read-only tiles, toolbar with the finding filter chip, the citations modal side sheet opened from a finding, the reference dialog and its form, their view and tile state hooks +│ │ ├─ editor/references/{ReferenceTiles,ReferenceTile,ReferenceFacts,ReferenceToolbar,NoResult,CitersList,CitationsPanel,CitationsDialog,CitationsEditForm,CitationsDraftList,ReferenceDialog,ReferenceForm}.tsx + use{ReferenceView,ReferenceLibrary,TileState,CitationsPanel}.ts ← V1-2.6 R2 and finish: read-only tiles, toolbar with the finding filter chip, the references dialog stacked over a finding (view and edit modes), the reference dialog and its form, their view and tile state hooks │ │ ├─ editor/findings/{FindingDialog,FindingView,FindingEditForm,FindingCreateForm,FindingActions,FindingCitations,DiscardConfirm,ReadOnlyNotice,useDirtyGuard}.tsx ← R2 finish: the finding dialog (view and transactional edit modes, creation), discard confirmation, dirty guard │ │ ├─ editor/useMoreMenu.ts ← R2 finish: « Plus » overlay state, dismiss (Escape, outside press) and the CloseWatcher back request │ │ ├─ ui/afterModalsClosed.ts ← R2 finish: runs a callback once no `dialog[open]` remains (focus landings, queued announcements) diff --git a/docs/design/README.md b/docs/design/README.md index 83cdbbb9..ad79c957 100644 --- a/docs/design/README.md +++ b/docs/design/README.md @@ -158,15 +158,27 @@ these screens is now the code plus `docs/development/V1-2-6_U1_CORRECTIONS.md` approved changes: 1. Transactional forms in the finding and reference dialogs: one undoable operation per save (BDR-050 re-planned). 2. The citations panel becomes a modal side sheet over the finding dialog, still opened from a finding only (D2, boards 24 - and 25, P16 and P17); its section geometry and the landscape cramped exception are gone. + and 25, P16 and P17); its section geometry and the landscape cramped exception are gone. Superseded 2026-11-15 + (note below): a references dialog replaces the side sheet. 3. The editor's view layers (tab, section, finding dialog, sheet, reference dialog, filter) live in the browser history, navigation state only, never typed data, personal searches or drafts (A2). 4. « Tout afficher dans l'onglet Références » filters the tab by the finding, with a removable chip (A3). 5. « Plus » opens as an overlay dropdown (board 27 A), closed first by the Android Back request where the browser - offers it. + offers it. Superseded 2026-11-15 (note below): a vertical list. 6. No new mockups for such changes: the owner brief and the gate stand as validation. Not changed: the clients and animals list searches are not kept in browser history (BDR-078 stands). +2026-11-15: R2 follow-up (owner brief after the `db:trial` check, `docs/development/V1-2-6_U1_CORRECTIONS.md` §R2, +« Owner follow-up 2026-11-15 »). No new mockup, the brief stands as validation. Two changes to the ratified screens: +1. Board 25 (the citations side sheet) is replaced by a references dialog stacked over the finding dialog, opened + from « X références ». View mode reads; its own « Modifier » cites, removes, creates a reference or opens a + reference's dialog. The finding dialog keeps only « Références citées » and the « X références » button. Families + get the same dialog. +2. Board 05, phone split (owner decision, 2026-11-15): one tab order everywhere (Général, Annotations, Constats, + Références, Vérification); below 640 px Général and Annotations are shown and the other three sit under « Plus », + in that order, a vertical list of rows of 48 px at least. The earlier phone split (Annotations and Vérification + shown) and the horizontal « Plus » overlay of board 27 A are replaced. Board 05's read-only mode below 1 024 px is unchanged. + 2026-11-14: U2 orientation (owner brief, `docs/development/V1-2-6_UX_PLAN.md` §U2, « Orientation 2026-11-14 »). Under `v1-2-6/`, boards 02 to 06 and 13 show a properties side panel next to the drawing. They are to be redrawn at the U2 planning: the properties panel becomes a dialog opened over the drawing, and the trace strip gains the point-size diff --git a/docs/development/BROWSER_TESTS.md b/docs/development/BROWSER_TESTS.md index c77d70e4..e917e603 100644 --- a/docs/development/BROWSER_TESTS.md +++ b/docs/development/BROWSER_TESTS.md @@ -10,7 +10,7 @@ engines are installed. The suites live in `apps/app/e2e`. | Command | Backend | Dev server | Content | |---|---|---|---| | `pnpm e2e:ui` | none | Vite on `127.0.0.1:5191` | `e2e/ui/dialog.spec.ts`: the D13 contract of the shared Dialog on a test page; `e2e/ui/working-copy.spec.ts`: the real `WorkingCopyAction` and its dialog on a test page (axe, layout, keyboard, fr and en, desktop and 375 px); `e2e/ui/local-tool.spec.ts`: the disclaimer, edit and replace dialogs on the real local-tool routes | -| `pnpm e2e:shell` | the isolated stack of `pnpm db:sandbox` | Vite on `127.0.0.1:5192` | `e2e/shell/shell.spec.ts`: sign-in, dashboard, the account photo confirmation, the phone drawer; `e2e/shell/clients.spec.ts`: the client journeys (V1-1.5); `e2e/shell/animals.spec.ts`: the animal and relation journeys (V1-1.6, contract §11.8); `e2e/shell/responsive.spec.ts`: no sideways scroll on nine shell pages, the archive confirmations and the drawer at 320, 360, 375, 390 and 430 px (phone project) and 1280 px, long values, the dashboard e-mail shown whole (RESP-01); `e2e/shell/admin.spec.ts` (V1-2.5): A0 the owner's bootstrap (two TOTP factors from Sécurité, the step-up at `/app/admin` and inside a factor action, no second factor from `aal1`, refresh keeping `aal1` and `aal2`, rights granted and revoked with their reason), A1 a sheet created by an editor on a new inactive species, S1 a species created inactive then activated by the owner, the creation page when the own-grants read fails (« Impossible de vérifier vos autorisations » and « Réessayer », never the form; Retry brings the form back), access per right (a reviewer-only account refused on the creation page), axe and no sideways scroll on every admin page; `e2e/shell/catalogue.spec.ts` (V1-2.5): P1 a reader searches, opens a sheet, picks a zone, reads a retired version, drafts and archived sheets never listed, the same refusal for an existing and an unknown sheet without access, 320, 375 and 430 px with the whole drawing in the box at opening; at 320 and 375 px the zone panel's live region present before a pick and naming the picked zone, the « Références » card starting at or below the drawing's bottom; `e2e/shell/editor-*.spec.ts` (V1-2.6, the draft editor level 1, contract C16 to C34): `editor-drawings` (A2: a hostile file refused with no cleaning box, an Inkscape export cleaned after its preview, a valid file attached, a detail view by crop, the same bytes attached twice), `editor-annotations` (A3: points, zones and links by clicks and by keyboard only, move by drag, a click with jitter never moves, numeric edits, undo and redo, review and delete), `editor-geometry` (a click near a frame edge with the corrected position confirmed and cancelled, an inherited out-of-frame point repaired through the geometry group, a crop change refused when it would invalidate a point, an unmeasured view with its tools disabled, touch-action and a touch drag in real Chromium), `editor-structures` (A4: categories, references, regions, findings tree, reorder, mark reviewed, delete with dependents; since the finish findings and references go through their dialogs, the delete dialog stacked over the finding dialog), `editor-references` (R2 and finish: read-only tiles, the reference dialog from « Modifier » and « Ajouter » with axe, its draft and its read-only flip, a tile edited out of the search keeping its place), `editor-journey` (the steps of `V1-2-6_OWNER_TRIAL.md` §4 with two editor accounts, a finding created through its dialog and the dialog closed before the next add: creation, drawing, findings, annotations, save, reload with the beforeunload dialog and the recovery offer, conflict, submission, the round read back in SQL), `editor-recovery` (two sessions, an older local copy restored then saved over a newer revision, a pending offer blocking edits, an unreadable copy kept until « Ignorer », Escape on the conflict read, the editor grant revoked, the admin role removed and the grant expired under an open session), `editor-access` (the finding dialog and the citations sheet scanned by axe at the widths; a reviewer-only account read-only, the not-found screen for an editor without the admin role and for an admin without a capability, 320, 375 and 800 px read-only, 1 024 px editing, axe on every tab edit and read-only), `editor-deselect` (R1, D5 and D6b: « Désélectionner » with its live region, the focus on the list row and the document unchanged; Escape over the canvas, a field, the delete dialog, the citations sheet over the finding dialog (Escape closes the sheet, a second one the dialog, a third deselects) and a tracing; mouse clicks on empty parts deselecting, on annotations selecting; zoom, pan, marker drag and Ctrl+wheel keeping the selection; a typed value applied by the deselecting click; at 1 280 px with `hasTouch` and CDP touch taps near annotations and the canvas bottom deselecting once, drags, two-finger taps and pinch keeping the selection, with the pointer events counted by a recorder; the read-only twin at 375 px and Escape closing « Plus » before deselecting; the drawing's top unchanged when a point, a zone and a link are selected then deselected, on desktop and on the read-only twin at 375 px, with the selection tag out of the visual flow), `editor-equine` (the sheet and the finding dialog closed between visits since the finish; the historical equine sheet opened as a working copy, a copy left active by an earlier run set aside and put back; commit latency on it and on a synthetic document near 2 MiB, printed as `LATENCY` lines and kept as test annotations, budget 500 ms per commit on the equine copy; one empty click on a bone of the horse drawing deselects, D6b). U1 shell (V1-2.6 U1, the tabbed shell): `editor-shell` (the Références tab keeping its search; kept-mounted places, focus on a named element, the open panel leaving the header and the tab row clickable at 1 024 and 1 280 px, the sidebar from 1 280 px and the drawer, canvas widths), `editor-shell-journeys` (a finding opening in its dialog in view mode, the row holding the focus once closed; five tabs, cross-tab undo, typed text then the header undo, a refused field kept through a real Shift+Tab to « Défaire », Ctrl+Z outside and inside a field, « Aller à » for each issue kind, the save line from the count to « Enregistrement… » to the time and revision), `editor-shell-crossing` (the findings creation form kept in its dialog while narrow, draft, focus and a notice kept; every edit-only part typed, a 1 024 px crossing, no edit control and the focus on the shown tab, widening with the values back; the section and the panel open; unsaved work and the recovery copy kept; a drag across the crossing commits nothing; delete and discard confirmations closing; a decision withheld under the panel waiting for « Reprendre »), `editor-shell-layout` (since the finish the citations sheet replaces the panel: its width, no document size change, the Tab order kept inside the sheet, the whole screen at 667 × 375 through a rotation, the cramped-landscape and swipe-reach cases gone; before: 667 × 375 reached by touch, and the worst case placed by script; no sideways scroll at 1 024, 1 180, 1 279 and 1 280 px on the five tabs, the sections and the citations panel, and at 320, 375 and 768 px read-only; axe from the top on every place; the canvas width without and with the panel as `canvas-width` and `canvas-width-panel` annotations; the keyboard order header, tab list, « Défaire », « Refaire », the panel when open, then tools, canvas and side column); the equine spec also times commit to paint with every place visited. `editor-history` (finish, R2F-1: tabs, an Annotations section, « Retour au dessin », arrow-key walks as one entry, the scroll offset, a reload, a DeleteDialog open at Back), `editor-finding-dialog` (finish, R2F-3: click, Enter and Space opening it, a pristine and a changed « Enregistrer », « Abandonner » and a width flip keeping the draft, a dirty Escape and Back asking, deletion landing on the nearest row, creation as a layer, a vanished element, Back and Forward walking the layers, and since 2026-11-14 a deletion followed by one « Défaire » restoring the row selected and focused, then Back moving), `editor-reference-journey` (finish, R2F-5 and R2F-6: the owner's eight steps at 1280 and 375 px, every Back, a reload keeping the filtered tab and chip but no form, the chip × removing the filter by replace, a double click and a held Escape popping one entry, a dirty reference dialog kept across Back), `editor-more-menu` (finish, R2F-7: the « Plus » overlay at several widths with axe, closing on a choice, an outside tap and Escape; Enter on an entry at 375 px putting the focus on that tab's panel, 2026-11-14; the sidebar fixed at 1280 and 1024 px and scrolling alone at 1280 × 500) and `editor-leave-confirm` (2026-11-14, criterion 23: a history jump of several entries made through the DevTools protocol on the pinned Chromium, from a dirty finding dialog or a dirty reference dialog, is cancelled and asks « Abandonner les modifications ? », the URL and the draft kept, « Continuer la saisie » keeping both, « Abandonner » landing on the overview with no left-draft flag and no notice; a dirty reference over the sheet of a dirty finding asking twice, the sheet closed before the second question, which has the focus on « Continuer la saisie »; the history entry holding a 32-hex `tag` and no `userId`). Editor accounts, drafts and drawings are prepared by `e2e/support/editor.ts` (a drawing in its stored form, written by the core); `e2e/support/warm-up.ts` is the suite's global setup (the dev server reloads the page once when a route first loads a dependency, so one throwaway session visits the editor routes before the tests). Editing needs 1 024 px: these specs skip the 375 px project | +| `pnpm e2e:shell` | the isolated stack of `pnpm db:sandbox` | Vite on `127.0.0.1:5192` | `e2e/shell/shell.spec.ts`: sign-in, dashboard, the account photo confirmation, the phone drawer; `e2e/shell/clients.spec.ts`: the client journeys (V1-1.5); `e2e/shell/animals.spec.ts`: the animal and relation journeys (V1-1.6, contract §11.8); `e2e/shell/responsive.spec.ts`: no sideways scroll on nine shell pages, the archive confirmations and the drawer at 320, 360, 375, 390 and 430 px (phone project) and 1280 px, long values, the dashboard e-mail shown whole (RESP-01); `e2e/shell/admin.spec.ts` (V1-2.5): A0 the owner's bootstrap (two TOTP factors from Sécurité, the step-up at `/app/admin` and inside a factor action, no second factor from `aal1`, refresh keeping `aal1` and `aal2`, rights granted and revoked with their reason), A1 a sheet created by an editor on a new inactive species, S1 a species created inactive then activated by the owner, the creation page when the own-grants read fails (« Impossible de vérifier vos autorisations » and « Réessayer », never the form; Retry brings the form back), access per right (a reviewer-only account refused on the creation page), axe and no sideways scroll on every admin page; `e2e/shell/catalogue.spec.ts` (V1-2.5): P1 a reader searches, opens a sheet, picks a zone, reads a retired version, drafts and archived sheets never listed, the same refusal for an existing and an unknown sheet without access, 320, 375 and 430 px with the whole drawing in the box at opening; at 320 and 375 px the zone panel's live region present before a pick and naming the picked zone, the « Références » card starting at or below the drawing's bottom; `e2e/shell/editor-*.spec.ts` (V1-2.6, the draft editor level 1, contract C16 to C34): `editor-drawings` (A2: a hostile file refused with no cleaning box, an Inkscape export cleaned after its preview, a valid file attached, a detail view by crop, the same bytes attached twice), `editor-annotations` (A3: points, zones and links by clicks and by keyboard only, move by drag, a click with jitter never moves, numeric edits, undo and redo, review and delete), `editor-geometry` (a click near a frame edge with the corrected position confirmed and cancelled, an inherited out-of-frame point repaired through the geometry group, a crop change refused when it would invalidate a point, an unmeasured view with its tools disabled, touch-action and a touch drag in real Chromium), `editor-structures` (A4: categories, references, regions, findings tree, reorder, mark reviewed, delete with dependents; since the finish findings and references go through their dialogs, the delete dialog stacked over the finding dialog), `editor-references` (R2 and finish: read-only tiles, the reference dialog from « Modifier » and « Ajouter » with axe, its draft and its read-only flip, a tile edited out of the search keeping its place), `editor-journey` (the steps of `V1-2-6_OWNER_TRIAL.md` §4 with two editor accounts, a finding created through its dialog and the dialog closed before the next add: creation, drawing, findings, annotations, save, reload with the beforeunload dialog and the recovery offer, conflict, submission, the round read back in SQL), `editor-recovery` (two sessions, an older local copy restored then saved over a newer revision, a pending offer blocking edits, an unreadable copy kept until « Ignorer », Escape on the conflict read, the editor grant revoked, the admin role removed and the grant expired under an open session), `editor-access` (the finding dialog and the references dialog scanned by axe at the widths; a reviewer-only account read-only, the not-found screen for an editor without the admin role and for an admin without a capability, 320, 375 and 800 px read-only, 1 024 px editing, axe on every tab edit and read-only), `editor-deselect` (R1, D5 and D6b: « Désélectionner » with its live region, the focus on the list row and the document unchanged; Escape over the canvas, a field, the delete dialog, the references dialog over the finding dialog (Escape closes the references dialog, a second one the finding dialog, a third deselects) and a tracing; mouse clicks on empty parts deselecting, on annotations selecting; zoom, pan, marker drag and Ctrl+wheel keeping the selection; a typed value applied by the deselecting click; at 1 280 px with `hasTouch` and CDP touch taps near annotations and the canvas bottom deselecting once, drags, two-finger taps and pinch keeping the selection, with the pointer events counted by a recorder; the read-only twin at 375 px and Escape closing « Plus » before deselecting; the drawing's top unchanged when a point, a zone and a link are selected then deselected, on desktop and on the read-only twin at 375 px, with the selection tag out of the visual flow), `editor-equine` (the sheet and the finding dialog closed between visits since the finish; the historical equine sheet opened as a working copy, a copy left active by an earlier run set aside and put back; commit latency on it and on a synthetic document near 2 MiB, printed as `LATENCY` lines and kept as test annotations, budget 500 ms per commit on the equine copy; one empty click on a bone of the horse drawing deselects, D6b). U1 shell (V1-2.6 U1, the tabbed shell): `editor-shell` (the Références tab keeping its search; kept-mounted places, focus on a named element, the open panel leaving the header and the tab row clickable at 1 024 and 1 280 px, the sidebar from 1 280 px and the drawer, canvas widths), `editor-shell-journeys` (a finding opening in its dialog in view mode, the row holding the focus once closed; five tabs, cross-tab undo, typed text then the header undo, a refused field kept through a real Shift+Tab to « Défaire », Ctrl+Z outside and inside a field, « Aller à » for each issue kind, the save line from the count to « Enregistrement… » to the time and revision), `editor-shell-crossing` (the findings creation form kept in its dialog while narrow, draft, focus and a notice kept; every edit-only part typed, a 1 024 px crossing, no edit control and the focus on the shown tab, widening with the values back; the section and the panel open; unsaved work and the recovery copy kept; a drag across the crossing commits nothing; delete and discard confirmations closing; a decision withheld under the panel waiting for « Reprendre »), `editor-shell-layout` (since the finish a citations dialog replaces the panel, since 2026-11-15 the references dialog replaces the side sheet: inside the viewport with the focus inside, no document size change, the Tab order kept inside it, inside the screen at 667 × 375 through a rotation, the cramped-landscape and swipe-reach cases gone; before: 667 × 375 reached by touch, and the worst case placed by script; no sideways scroll at 1 024, 1 180, 1 279 and 1 280 px on the five tabs, the sections and the references dialog, and at 320, 375 and 768 px read-only; axe from the top on every place; the canvas width without and with the panel as `canvas-width` and `canvas-width-panel` annotations; the keyboard order header, tab list, « Défaire », « Refaire », the panel when open, then tools, canvas and side column); the equine spec also times commit to paint with every place visited. `editor-history` (finish, R2F-1: tabs, an Annotations section, « Retour au dessin », arrow-key walks as one entry, the scroll offset, a reload, a DeleteDialog open at Back), `editor-finding-dialog` (finish, R2F-3: click, Enter and Space opening it, a pristine and a changed « Enregistrer », « Abandonner » and a width flip keeping the draft, a dirty Escape and Back asking, deletion landing on the nearest row, creation as a layer, a vanished element, Back and Forward walking the layers, and since 2026-11-14 a deletion followed by one « Défaire » restoring the row selected and focused, then Back moving), `editor-reference-journey` (finish, R2F-5 and R2F-6: the owner's eight steps at 1280 and 375 px, ending on finding A with the references dialog open (2026-11-15), every Back, a reload keeping the filtered tab and chip but no form, the chip × removing the filter by replace, a double click and a held Escape popping one entry, a dirty reference dialog kept across Back), `editor-more-menu` (finish, R2F-7: the « Plus » overlay at several widths with axe, closing on a choice, an outside tap and Escape; since 2026-11-15 at 375 and 320 px the tab row shows Général and Annotations then « Plus », its entries stack in tab order (Constats, Références, Vérification), each at least 44 px high and inside the viewport, axe with an active row, « Plus » found without an exact name because it may carry the error count; Enter on an entry at 375 px putting the focus on that tab's panel, 2026-11-14; the sidebar fixed at 1280 and 1024 px and scrolling alone at 1280 × 500) and `editor-leave-confirm` (2026-11-14, criterion 23: a history jump of several entries made through the DevTools protocol on the pinned Chromium, from a dirty finding dialog or a dirty reference dialog, is cancelled and asks « Abandonner les modifications ? », the URL and the draft kept, « Continuer la saisie » keeping both, « Abandonner » landing on the overview with no left-draft flag and no notice; a dirty reference over the references dialog of a dirty finding asking twice, the dialog closed before the second question, which has the focus on « Continuer la saisie »; since 2026-11-15 a dirty references draft asking before the jump goes; the history entry holding a 32-hex `tag` and no `userId`). Editor accounts, drafts and drawings are prepared by `e2e/support/editor.ts` (a drawing in its stored form, written by the core); `e2e/support/warm-up.ts` is the suite's global setup (the dev server reloads the page once when a route first loads a dependency, so one throwaway session visits the editor routes before the tests). Editing needs 1 024 px: these specs skip the 375 px project | Each suite runs on two Chromium projects: `chromium-desktop` (1280 × 800) and `chromium-375` (375 × 667, mobile viewport, touch). A test tagged `@phone` @@ -76,19 +76,20 @@ move buttons with the server document never changing; adding a reference, saving edited tile keeping its place under a sort and a search. Read-only at 375 px: « Plus » lists Références, tiles keep DOI, URL and « Aller à », no edit control. -`e2e/shell/editor-citations.spec.ts` covers the citations of a finding, a modal side sheet over its dialog since the R2 -finish (2026-11-13; the cramped and geometry cases of the panel are gone). Editing: the sheet opens over the finding -dialog and is read-only (no « Retirer de ce constat », no cite; since 2026-11-14 a citation is removed from the finding's -edit form, then « Enregistrer » and one « Défaire », the saved status); a long list scrolls inside the sheet and -the page never moves; a form that drops every citation loses the trigger and its count, and nothing is written before -« Enregistrer »; -« Tout afficher » closes both layers, clears the search, keeps the sort and the open tiles, and Back returns to the -sheet; « Modifier » opens the reference dialog over the sheet and « Enregistrer » closes it only, with one undo; a dirty -reference dialog keeps its draft on ✕ and on Back; the exiting sheet is inert and a second close finds nothing; -keyboard (Enter opens, Tab in order, Escape closes only the sheet); each close path (✕, Escape, the scrim, Back, -« Tout afficher », « Aller à ») checks where the focus lands, and the slide happens only when motion is allowed. -Read-only at 375 px: full width through « Plus » then Constats, no edit control, axe; by touch, taps act on the -sheet only. +`e2e/shell/editor-citations.spec.ts` covers the citations of a finding: a modal side sheet over its dialog at the R2 +finish (2026-11-13), a references dialog stacked over it since the owner follow-up (2026-11-15). View mode: the dialog +opens over the finding dialog and only reads (no « Modifier » on its tiles; the finding's edit form cites nothing and +its save keeps the citations); a family opens the same dialog with its own citations, and « Tout afficher » from it +filters the library by the family, Back returning to the dialog; a long list scrolls inside the dialog and « 0 référence » +opens the empty one; « Tout afficher » closes both layers, clears the search, keeps the sort and the open tiles, and Back +returns to the dialog; the exiting dialog is inert and a second close finds nothing; keyboard (Enter opens, Tab in +order, Escape closes only it); each close path (✕, Escape, the backdrop, Back, « Tout afficher », « Aller à ») checks +where the focus lands, and the dialog scales in only when motion is allowed. Edit mode (2026-11-15, editing needs +1 024 px): cite and remove, « Enregistrer », one header « Défaire » restores, axe on the edit mode; a dirty draft makes +✕ and Back ask, and « Abandonner » writes nothing; « Modifier la référence » stacks the reference dialog and, closed, +the draft is back; « Nouvelle référence » is created over the dialog and cited by the save. Read-only at 375 px: the +dialog inside the viewport through « Plus » then Constats, no edit control, axe; by touch, taps act on the references +dialog only and the finding dialog under it stays. Layout additions in `e2e/shell/editor-shell-layout.spec.ts`: five tabs everywhere the four were checked (no sideways scroll from 1 024 to 1 280 px, axe from the top, read-only at 320, 375 and 768 px); the open panel at most @@ -237,7 +238,7 @@ suite needs Docker in the runner for the sandbox. scrollY unchanged. B is programmatic because a touch swipe under about 60 px scrolls nothing (slop) and the gain varies under load, so a pixel-exact touch landing is not reproducible (an earlier calibrated version oscillated by 55 px in the full sweep). The remaining exception (the - rotation to 667 × 375 with the panel open at scroll 0) is gone with the finish: the panel is a modal side sheet. + rotation to 667 × 375 with the panel open at scroll 0) is gone with the finish: the panel became a modal side sheet, then (2026-11-15) the references dialog. - A control placed below a field whose blur-commit is refused can lose its first click, because the error line moves the layout between mouse down and click. An editor-wide pattern found while writing the Références specs (« Terminer » got a `mousedown` guard); the general cure is not done. diff --git a/docs/development/V1-2-6_OWNER_TRIAL.md b/docs/development/V1-2-6_OWNER_TRIAL.md index 324a4ab0..a626f627 100644 --- a/docs/development/V1-2-6_OWNER_TRIAL.md +++ b/docs/development/V1-2-6_OWNER_TRIAL.md @@ -260,23 +260,25 @@ vous avez créée dans l'interface. À chaque sélection et désélection, le dessin reste à sa place : aucune étiquette « Sélection : … » ne s'affiche au-dessus. 4. Références : remplacé par 4.10. Le bouton « Références » de l'en-tête n'existe plus ; les références ont leur - onglet, et le panneau latéral s'ouvre depuis un constat seulement. + onglet, et le panneau latéral s'ouvre depuis un constat seulement (depuis le 2026-11-15 c'est un dialogue des + références : voir 4.13). 5. Dans « Annotations », la carte « Vues » propose « Gérer les vues », la carte « Catégories » « Modifier les catégories », et une entrée « Régions vertébrales (n régions) » est toujours là. Chacun ouvre sa section pleine largeur avec « Retour au dessin » en tête. Une saisie commencée dans une section reste là quand vous revenez au dessin puis rouvrez la section. 6. Redimensionnez la fenêtre à 1 180 px de large. Attendu : le menu latéral de l'application disparaît dans l'éditeur (il revient dès 1 280 px) et s'ouvre en un geste par « Ouvrir le menu » ; le dessin gagne la place - libérée. Sous 1 024 px l'éditeur passe en lecture seule (voir les limites) ; en dessous de 640 px, deux - onglets restent visibles et « Plus » ouvre les deux autres. + libérée. Sous 1 024 px l'éditeur passe en lecture seule (voir les limites) ; en dessous de 640 px, « Général » et + « Annotations » restent visibles et « Plus » ouvre les trois autres, dans l'ordre (depuis le 2026-11-15, voir 4.13). ### 4.10 Démonstration R2 : l'onglet Références À dérouler sur la fiche de 4.9, qui porte au moins un constat citant une référence et une référence non citée (ajoutez-la à l'étape 8 sinon). Libellés : `V1-2-6_R2_LABELS.md`. Rien dans ce parcours n'est lancé par Claude : la -pile d'essai et les vérifications sont les vôtres. Chaque étape donne l'action, puis l'attendu. +pile d'essai et les vérifications sont les vôtres. Chaque étape donne l'action, puis l'attendu. Depuis le 2026-11-15, le +panneau latéral de ce parcours est un dialogue des références et « Plus » une liste verticale : 4.13 fait foi. 1. Onglets. Action : ouvrez la fiche à 1 280 px, puis réduisez la fenêtre sous 640 px. Attendu : cinq onglets - « Général », « Annotations », « Constats », « Références », « Vérification » ; sous 640 px deux onglets restent - visibles et « Plus » ouvre les autres, « Références » compris. Plus de bouton « Références » dans l'en-tête. + « Général », « Annotations », « Constats », « Références », « Vérification » ; sous 640 px « Général » et + « Annotations » restent visibles et « Plus » ouvre les autres, « Références » compris. Plus de bouton « Références » dans l'en-tête. 2. Tuiles. Action : ouvrez « Références ». Attendu : une tuile fermée montre la citation, son type et « Citée n fois » (ou « Non citée »). Ouvrez-en une (clic, Entrée ou Espace sur l'en-tête) : DOI, URL, liste des citants avec « Aller à », et pour un citant une pastille « famille » ou « ce constat ». « Modifier » passe la tuile en @@ -347,30 +349,31 @@ pile d'essai et les vérifications sont les vôtres. Chaque étape donne l'actio ### 4.11 Finition R2 À dérouler sur la fiche de 4.9 et 4.10, qui porte un constat A citant au moins deux références. Cette finition remplace l'édition en ligne des tuiles et le panneau de 4.10 : là où 4.10 et 4.11 diffèrent, 4.11 fait foi (les étapes -9 et 10 de 4.10 ne tiennent plus : le volet ne retire plus de citation, voir les étapes 1 et 3 ci-dessous). Libellés : +9 et 10 de 4.10 ne tiennent plus : le volet ne retire plus de citation, voir les étapes 1 et 3 ci-dessous ; depuis le +2026-11-15 le volet est un dialogue des références, 4.13 fait foi là où il diffère). Libellés : `V1-2-6_R2_LABELS.md` §5 à §7. Rien dans ce parcours n'est lancé par Claude. Chaque étape donne l'action, puis l'attendu. Les étapes 1 à 11 se font à 1 280 px, les étapes 12 à 14 sur téléphone, sauf 14a (bureau ou tablette à 1 024 px ou plus). 1. Le parcours en huit temps. Action : onglet « Constats » ; ouvrez le constat A ; cliquez « 2 références » ; dans le - volet, cliquez « Tout afficher dans l'onglet Références » ; regardez l'onglet ; appuyez sur Précédent du navigateur. - Attendu : le volet des références citées s'ouvre à droite ; l'onglet « Références » n'affiche que les deux + dialogue des références, cliquez « Tout afficher dans l'onglet Références » ; regardez l'onglet ; appuyez sur + Précédent du navigateur. Attendu : le dialogue des références s'ouvre au-dessus du constat ; l'onglet « Références » n'affiche que les deux références du constat A, sous la pastille « Références du constat : A » avec son « × » ; Précédent ramène au constat - A, volet ouvert, dans l'état où vous l'aviez quitté. Un second Précédent ferme le volet, un troisième ferme le - constat, sans quitter l'éditeur. Suivant refait le chemin. Le volet est en lecture seule : « Modifier » et « Aller - à » y sont, pas « Retirer de ce constat », et la fiche du constat en lecture n'offre ni « Citer » ni « Retirer ». + A, dialogue des références ouvert, dans l'état où vous l'aviez quitté. Un second Précédent ferme ce dialogue, un + troisième ferme le constat, sans quitter l'éditeur. Suivant refait le chemin. Le dialogue lit les références : + « Aller à » sur les tuiles, son propre « Modifier » (voir 4.13), pas de « Retirer de ce constat » ; la fiche du + constat n'offre ni « Citer » ni « Retirer ». 2. Ajouter un constat. Action : « Constats », bouton d'ajout, remplissez les noms, « Créer ». Attendu : la fiche du nouvel élément s'ouvre en lecture dans la boîte de dialogue ; Précédent revient à l'arbre. -3. Modifier un constat. Action : ouvrez un constat, « Modifier », changez un nom et une description ; dans le même - formulaire, retirez une référence citée (« Retirer » sur la liste) puis ajoutez-en une (« Citer une référence »). - Attendu : on ne cite et on ne retire une référence que dans ce formulaire, jamais en lecture ; rien n'est écrit - tant que vous n'avez pas cliqué « Enregistrer » ; « Défaire » (en haut) est hors d'atteinte pendant que la boîte - est ouverte ; pendant la modification, le volet des références liste la saisie en cours. +3. Modifier un constat. Action : ouvrez un constat, « Modifier », changez un nom et une description. Attendu : le + formulaire ne montre que « Références citées » et « X références », sans liste, sans « Citer » ni « Retirer » (les + citations se modifient dans le dialogue des références, voir 4.13) ; rien n'est écrit tant que vous n'avez pas + cliqué « Enregistrer » ; « Défaire » (en haut) est hors d'atteinte pendant que la boîte est ouverte. 4. Annuler avec une modification. Action : même formulaire, changez un champ, cliquez « Annuler » (puis refaites avec Échap, puis avec Précédent). Attendu : « Abandonner les modifications ? » avec « Continuer la saisie » (focalisé) et « Abandonner » ; « Continuer la saisie » garde votre texte ; « Abandonner » revient à la lecture sans rien écrire. Sans modification, « Annuler » revient directement. 5. Enregistrer puis défaire. Action : changez deux champs, « Enregistrer », fermez la boîte, cliquez « Défaire ». Attendu : « Modifications enregistrées » après l'enregistrement ; un seul « Défaire » rend les deux champs - ensemble (une opération par enregistrement, citations comprises) ; « Refaire » les remet. + ensemble (une opération par enregistrement ; celui du constat ne touche pas aux citations) ; « Refaire » les remet. 6. Ajouter une référence. Action : onglet « Références », « Ajouter une référence », type et citation, « Ajouter la référence ». Attendu : une boîte de dialogue ; un champ obligatoire vide est refusé sur le champ ; une adresse hors http(s) aussi ; la liste ne bouge pas, recherche et tri restent tels quels ; la ligne « Référence ajoutée : … » @@ -382,15 +385,16 @@ l'attendu. Les étapes 1 à 11 se font à 1 280 px, les étapes 12 à 14 sur té tri, cliquez le « × » de la pastille. Attendu : recherche et tri restent utilisables dans le filtre ; « × » rend toutes les références ; « Revenir au constat » rouvre le constat A tant que le filtre est posé. 9. Recharger. Action : sur l'onglet filtré, rechargez la page (F5). Attendu : l'onglet et la pastille sont gardés ; ni - formulaire ouvert ni texte de recherche ; Précédent ramène alors au volet. + formulaire ouvert ni texte de recherche ; Précédent ramène alors au dialogue des références. 10. Historique et comptes. Action : ouvrez le constat A, changez de fiche (ou déconnectez-vous puis connectez un autre compte), puis appuyez sur Précédent. Attendu : aucune boîte ni aucun filtre d'une autre fiche ou d'un autre compte ne revient : l'historique repart de zéro. L'historique ne porte plus l'identifiant du compte, seulement une étiquette de session aléatoire. 11. Menu latéral. Action : à 1 280 px, défilez une page longue (Constats avec beaucoup de lignes). Attendu : le menu de gauche reste en place ; fenêtre basse (500 px), il défile seul sans dépasser. -12. « Plus » sur téléphone. Action : sous 640 px, touchez « Plus ». Attendu : une liste se déroule sous la rangée - d'onglets sur toute la largeur, sans rien décaler, avec un fondu léger ; choisir une entrée la ferme, ouvre +12. « Plus » sur téléphone. Action : sous 640 px, touchez « Plus ». Attendu : une liste verticale (Constats, + Références, Vérification, voir 4.13) se déroule sous la rangée d'onglets sur toute la largeur, sans rien décaler, + avec un fondu léger ; choisir une entrée la ferme, ouvre l'onglet et met le focus sur le panneau de cet onglet (au clavier comme au toucher). 13. Fermer « Plus ». Action : ouvrez « Plus », puis (a) touchez hors du menu, (b) rouvrez et utilisez le geste ou le bouton Retour d'Android. Attendu : (a) le menu se ferme et la page ne reçoit pas ce toucher ; (b) Retour ferme le @@ -421,9 +425,10 @@ vérification donne l'action, puis l'attendu. navigateur sait annuler le saut), soit un départ sans question puis, au retour sur la fiche, l'avis « Une saisie non enregistrée a été abandonnée en quittant l'éditeur » une fois. Jamais une perte sans l'un ou l'autre. Dites lequel vous observez : ces navigateurs ne sont pas vérifiés. -4. Citer et retirer en modification. Action : « Modifier » sur le constat A, retirez une référence et citez-en une - autre, « Enregistrer », fermez, puis un seul « Défaire ». Attendu : après « Défaire », les citations d'avant - reviennent ensemble ; en lecture, rien ne permet de citer ni de retirer. +4. Citer et retirer en modification. Action : sur le constat A, « X références », « Modifier » du dialogue, retirez + une référence et citez-en une autre, « Enregistrer », fermez, puis un seul « Défaire ». Attendu : après + « Défaire », les citations d'avant reviennent ensemble ; en lecture, rien ne permet de citer ni de retirer ; la + fiche du constat ne porte aucun contrôle de citation (voir 4.13). 5. Suppression puis « Défaire ». Action : supprimez un constat depuis son dialogue, puis un seul « Défaire ». Attendu : « Constats » s'ouvre avec le constat rendu, sa ligne sélectionnée et focalisée. 6. « Plus » au clavier sur tablette ou sur bureau à largeur étroite. Action : sous 640 px, Tab jusqu'à « Plus », @@ -439,6 +444,44 @@ vérification donne l'action, puis l'attendu. onglet et rouvrez la fiche. Attendu : l'avis « Une saisie non enregistrée a été abandonnée en quittant l'éditeur » une fois, jamais le texte tapé ; rouvrir encore la fiche ne le montre plus. +### 4.13 Vérification des deux ajustements (2026-11-15) +À faire sur la pile d'essai (`db:trial`), sur la fiche de 4.11 : un constat A qui cite au moins deux références, une +famille (catégorie) de « Constats ». Libellés : `V1-2-6_R2_LABELS.md` §10. Les étapes 1 à 8 se font à 1 280 px (la +modification demande 1 024 px), l'étape 9 sur téléphone ou fenêtre sous 640 px. Rien dans ce parcours n'est lancé par +Claude. Chaque étape donne l'action, puis l'attendu. +1. Dialogue en lecture. Action : ouvrez le constat A, cliquez « 2 références ». Attendu : un dialogue « Références du + constat » s'ouvre au-dessus du constat (plus de volet à droite) ; les références se lisent en tuiles, avec + « Aller à », « Tout afficher dans l'onglet Références » et son propre « Modifier » ; aucun « Retirer ». +2. Fermer. Action : fermez par ✕, puis rouvrez et fermez par Échap. Attendu : retour au constat A, focus sur + « 2 références ». +3. « Modifier » du constat. Action : « Modifier » dans le constat A. Attendu : le formulaire ne montre que « Références + citées » et « X références », sans liste de références, sans « Citer » ni « Retirer » ; « Enregistrer » n'y change + pas les citations. +4. Modifier les références. Action : « 2 références », puis « Modifier » du dialogue ; citez une référence existante + (« Citer une référence »), retirez-en une (« Retirer »), « Enregistrer ». Attendu : retour en lecture avec + « Modifications enregistrées » et le focus sur « Modifier » ; après avoir fermé les dialogues, un seul « Défaire » + rend les citations d'avant ; « Refaire » les remet. +5. « Nouvelle référence » et « Modifier la référence ». Action : « Modifier », « Nouvelle référence », renseignez, + « Créer » ; puis « Modifier la référence » sur une rangée, changez la citation, « Enregistrer » dans ce dialogue. + Attendu : la référence créée est citée dans le brouillon, rien n'est écrit dans le document tant que vous n'avez + pas cliqué « Enregistrer » du dialogue des références ; le dialogue de la référence s'ouvre au-dessus, et une fois + fermé le brouillon est là. Si vous abandonnez après avoir créé une référence, elle reste dans l'onglet Références, + non citée, et un « Défaire » la retire (opération à part : limite 10 de §5). +6. Annuler. Action : dans la modification, changez une citation, « Annuler » (puis refaites avec ✕ et Échap). + Attendu : « Abandonner les modifications ? » avec « Continuer la saisie » (focalisé) ; « Abandonner » n'écrit + rien. Sans modification, « Annuler » revient directement à la lecture. +7. Précédent. Action : avec une citation modifiée et non enregistrée, appuyez sur Précédent du navigateur. Attendu : + la même question ; « Continuer la saisie » garde le brouillon. +8. Une famille. Action : dans « Constats », ouvrez une famille, cliquez « X références » (même à 0), refaites les + étapes 1 à 7. Attendu : le même dialogue, les mêmes comportements ; une famille sans référence ouvre le dialogue + avec « Ce constat ne cite aucune référence. ». +9. Téléphone (ou fenêtre sous 640 px). Action : ouvrez l'éditeur, regardez la rangée d'onglets, touchez « Plus ». + Attendu : « Général » et « Annotations » sont visibles, puis « Plus » ; la liste est verticale, dans l'ordre + Constats, Références, Vérification, chaque rangée d'au moins 48 px, l'entrée active teintée avec une coche ; tant + que Vérification est dans « Plus », le nombre d'erreurs bloquantes s'affiche sur « Plus » ; choisir une entrée ferme + la liste et ouvre l'onglet ; le Retour d'Android (ou Échap, ou un toucher hors de la liste) la ferme. Sous 1 024 px + le dialogue des références reste en lecture, sans « Modifier ». + ## 5. Limites à connaître - Risque résiduel RR-12 : les opérations du catalogue lisent la mention `aal2` du jeton, pas la session vivante. Un jeton émis à `aal2` reste accepté après la suppression du facteur, jusqu'à son expiration (une heure). @@ -479,13 +522,13 @@ vérification donne l'action, puis l'attendu. une modification non enregistrée, comme au niveau 1. - La fenêtre de réparation des annotations garde les géométries saisies au passage sous 1 024 px, mais pas le message de refus d'une application ni une saisie illisible encore en cours dans un groupe de géométrie. -- Tant que le panneau des citations est ouvert (ou se ferme), la page est inerte sous le voile : on parcourt - d'abord le panneau. Il ne s'ouvre que depuis un constat, dans « Constats », et se ferme à tout changement - d'onglet (voir 4.10 et les limites de R2). +- Tant que le dialogue des références est ouvert (ou se ferme), la page est inerte sous le voile : on parcourt + d'abord le dialogue. Il ne s'ouvre que depuis un constat ou une famille, dans « Constats » (un panneau latéral + jusqu'au 2026-11-14 : voir 4.10, 4.13 et les limites de R2). - « Gérer les vues », « Modifier les catégories » et « Régions vertébrales » ouvrent les éditeurs existants en section pleine largeur ; U3, U4 et U6 les remplacent. - Largeur du dessin (choix 2.6) : 538 px à 1 024 px et à 1 280 px (la barre latérale revient à 1 280 px), 694 px - à 1 180 px, 793 px à 1 279 px ; la largeur est la même avant l'ouverture du panneau des citations et après sa fermeture. + à 1 180 px, 793 px à 1 279 px ; la largeur est la même avant l'ouverture du dialogue des références (panneau des citations jusqu'au 2026-11-14) et après sa fermeture. - Le parcours automatique sur un second appareil du réseau local (`e2e/lan/trial-lan.spec.ts`) n'a pas été exécuté : il demande cette pile d'essai. Votre essai depuis un autre appareil (section 3) en est la première vérification. @@ -501,14 +544,16 @@ La finition du 2026-11-13 (§4.11) retire trois limites : le panneau ouvert en h et la saisie en attente perdue par « Défaire » ou « Refaire » (plus de saisie en ligne : les formulaires sont des boîtes de dialogue transactionnelles, hors d'atteinte de « Défaire » tant qu'elles sont ouvertes). Votre essai du 2026-11-14 a validé les parcours principaux de R2 et demandé des retouches, construites : on ne cite -une référence qu'en modification d'un constat (le volet est en lecture seule), un seul « Défaire » après une +une référence qu'en modification d'un constat (le volet est en lecture seule ; remplacé le 2026-11-15 : les citations +se modifient dans le dialogue des références, §4.13), un seul « Défaire » après une suppression rend le constat, un seul Retour après une suppression remonte l'historique, le choix d'une entrée de « Plus » met le focus sur le panneau, l'historique porte une étiquette de session aléatoire et non l'identifiant du compte, et un départ de plusieurs entrées avec un dialogue modifié est confirmé là où le navigateur peut l'annuler. -La revue finale du 2026-11-14 a ajouté trois corrections. Un Retour qui ne ferme que le volet des références, ou un +La revue finale du 2026-11-14 a ajouté trois corrections. Un Retour qui ne ferme que le volet des références (un dialogue depuis le 2026-11-15), ou un dialogue de référence sans modification, le ferme sans rien demander, même au-dessus d'un constat modifié. Quand un Retour ou un départ doit faire demander le constat, ce qui le couvre (le volet, un dialogue de référence sans -modification) se ferme d'abord : la question est visible et prend le focus. Une déconnexion, ou une fin de session, +modification) se ferme d'abord : la question est visible et prend le focus (depuis le 2026-11-15 un brouillon de +citations non enregistré est demandé comme celui du constat). Une déconnexion, ou une fin de session, pendant qu'un dialogue garde une saisie non enregistrée laisse un repère sans aucun texte : à la prochaine connexion du même compte dans cet onglet, l'avis « Une saisie non enregistrée a été abandonnée en quittant l'éditeur » s'affiche une fois sur la fiche ; un autre compte ne le voit jamais. @@ -524,8 +569,9 @@ Limites apparues pendant ces retouches, à confirmer par vous lors des vérifica toujours. À vérifier par vous sur un téléphone (§4.12). 6. Départ de plusieurs entrées avec deux dialogues modifiés : l'éditeur demande de haut en bas. « Continuer la saisie » sur un dialogue du dessous garde ce brouillon ; un brouillon déjà abandonné au-dessus reste abandonné - (votre choix). Le volet des références et un dialogue de référence sans modification ouverts au-dessus du constat - se ferment avant sa question, pour qu'elle soit visible ; un Retour rouvre ensuite le volet. + (votre choix). Le dialogue des références (un volet jusqu'au 2026-11-15) et un dialogue de référence sans + modification ouverts au-dessus du constat se ferment avant sa question, pour qu'elle soit visible ; un Retour + rouvre ensuite le dialogue des références. 7. La confirmation avant ce départ est vérifiée sur Chromium de bureau seulement (saut dans l'historique par le protocole de débogage, un dialogue puis deux empilés). Non vérifiée : Firefox, Safari, un clic dans le vrai menu d'historique de la barre d'outils. Quand le navigateur ne peut pas annuler le saut, ou n'offre pas @@ -537,6 +583,15 @@ Limites apparues pendant ces retouches, à confirmer par vous lors des vérifica RR-13). Il ne s'observe pas dans cet essai manuel. Levées par ces retouches : le Retour sans effet après la suppression d'un constat, et le focus qui allait au corps de la page après un choix dans « Plus ». +Retouches du 2026-11-15 (construites, à vérifier au §4.13) : le dialogue des références remplace le volet, avec sa +propre modification (citer, retirer, créer, ouvrir une référence, un seul « Défaire » par enregistrement) ; un seul +ordre d'onglets, « Plus » est une liste verticale. Limites de cette retouche, à confirmer par vous au §4.13 : +10. Une référence créée depuis « Nouvelle référence » puis un brouillon abandonné : la référence reste dans la + bibliothèque, non citée, comme une opération à part (un « Défaire » la retire). +11. Dans « Plus », pas de flèches du clavier : Tab parcourt les entrées, sortir par Tab ferme la liste. +12. L'aide d'une référence citée (« Pour supprimer cette référence, retirez d'abord chacune de ses citations… ») + renvoie encore à « Modifier » et « Retirer » dans le constat ; ils sont maintenant dans le dialogue des + références (texte non changé, à trancher). Quitter l'éditeur par un Retour de plusieurs entrées ne peut pas toujours être refusé (BDR-078, voir 7 ci-dessus) et le texte saisi n'est jamais gardé. Limites de R2 qui subsistent : diff --git a/docs/development/V1-2-6_R2_LABELS.md b/docs/development/V1-2-6_R2_LABELS.md index 07cab46d..baa789eb 100644 --- a/docs/development/V1-2-6_R2_LABELS.md +++ b/docs/development/V1-2-6_R2_LABELS.md @@ -14,7 +14,7 @@ Règles de lecture : « Ce constat ne cite plus aucune référence. », « Référence introuvable » et « Saisie non appliquée : … ». Ils sont marqués « provisoire, accepté 2026-11-12 » dans la colonne Statut. - Tous les libellés anglais sont une base de travail. Aucun n'a été ratifié un par un (décision du propriétaire). -- Les clés `editor.references.close` (« Fermer les références ») et `editor.references.search` (« Rechercher une +- Les clés `editor.references.close` (« Fermer les références », retirée le 2026-11-15, §10) et `editor.references.search` (« Rechercher une référence ») et `editor.findings.references_open_*` (déclencheur « n référence(s) ») sont inchangées. ## 1. Clés nouvelles et modifiées @@ -213,3 +213,30 @@ modifiée (revue finale rev 4). 18 + 2 clés nouvelles, 7 retirées, une modifiée (`editor.references.delete_hint`). - Le §3, ambiguïté 2, parle de « Retirer de ce constat » comme du bouton de la tuile dans le panneau : ce bouton n'existe plus, il ne reste que « Retirer » dans le formulaire de modification. + +## 10. Suivi du 2026-11-15 : dialogue des références et « Plus » vertical + +Source : `git diff b41c24b..HEAD -- apps/app/src/i18n` (`fr.ts` et `en.ts`) : 5 clés nouvelles, 2 retirées, une modifiée. +Les libellés EN sont provisoires. La liste « Plus » et l'ordre des onglets n'ont pas de clé nouvelle. + +| Clé | FR | EN (provisoire) | Où | Statut | +| ------------------------------------ | ------------------------------------------ | ---------------------------------------- | ------------------------------------------------------------------------------------------- | ------ | +| `editor.references.dialog_title` | Références du constat | References of the finding | Dialogue des références, titre en lecture | nouveau | +| `editor.citations.edit` | Modifier | Edit | Dialogue des références, bouton qui ouvre la modification | nouveau | +| `editor.citations.edit_title` | Modifier les références du constat | Edit the references of the finding | Dialogue des références, titre en modification | nouveau | +| `editor.citations.edit_reference` | Modifier la référence | Edit the reference | Dialogue des références en modification, bouton d'une rangée : ouvre le dialogue de la référence | nouveau | +| `editor.citations.new_reference` | Nouvelle référence | New reference | Dialogue des références en modification, crée une référence citée dans le brouillon | nouveau | +| `editor.references.panel_empty` | Ce constat ne cite aucune référence. | This finding cites no reference. | Dialogue des références, état à zéro | modifié : « ne cite plus aucune » ne convient plus, le dialogue s'ouvre aussi à zéro ; libellé FR à confirmer par le propriétaire | +| `editor.references.panel_title` | Références citées | Cited references | Ancien en-tête du panneau, remplacé par `dialog_title` | retiré | +| `editor.references.close` | Fermer les références | Close the references | Ancien bouton de fermeture du panneau, le dialogue a son ✕ (`common.close`) | retiré | + +- Réutilisées sans changement : `editor.findings.reference_add` (« Citer une référence »), `editor.findings.references_none` + (« Aucune référence citée. »), `editor.findings.saved` (« Modifications enregistrées »), `editor.action.remove` + (« Retirer »), `editor.references.missing` (« Référence introuvable »), `editor.references.panel_show_all`, + `editor.findings.discard_ask` et ses deux boutons. +- Le titre « Références citées » reste visible dans la fiche du constat (clé existante du bloc des citations). +- Solde du suivi : +5 clés nouvelles, 2 retirées, soit +3 par dictionnaire. Pour R2 depuis `36c6eb3` : 25 clés + nouvelles, 9 retirées, 2 modifiées (`editor.references.delete_hint`, `editor.references.panel_empty`). +- Point ouvert : `editor.references.delete_hint` renvoie encore à « Modifier » et « Retirer » dans le constat ou la + famille. Depuis le suivi, la fiche du constat ne porte plus de citation : on retire par « Modifier » du dialogue des + références. Texte inchangé dans le code, à trancher. diff --git a/docs/development/V1-2-6_U1_CORRECTIONS.md b/docs/development/V1-2-6_U1_CORRECTIONS.md index a5cf77b6..5797ec05 100644 --- a/docs/development/V1-2-6_U1_CORRECTIONS.md +++ b/docs/development/V1-2-6_U1_CORRECTIONS.md @@ -171,6 +171,9 @@ The criteria below are the contract as written. ### R2 — The Références tab (D1 to D4) +Status (2026-11-15): built, awaiting the owner's `db:trial` check of two last adjustments (« Owner follow-up +2026-11-15 » below, `V1-2-6_OWNER_TRIAL.md` §4.13), then R2 closure. Several lines below describe the side sheet, the +citations in the finding's edit form or the phone tabs Annotations + Vérification: each is marked as superseded. Status (2026-11-14): R2 validated by the owner's trial, closed pending the final manual checks (« Owner trial and closure 2026-11-14 » below, `V1-2-6_OWNER_TRIAL.md` §4.12). Status (2026-11-13): corrected, still awaiting the owner's validation (corrections below). @@ -182,14 +185,17 @@ nothing deployed). Commits: `65a8fd3` (plan, rev 4 after the owner's GO), `fc3fe Labels: `V1-2-6_R2_LABELS.md`. Decision record: BDR-114. What the build settled against the text below: - The panel opens from a finding only (owner, 2026-11-12). The family's former trigger is removed; a family keeps - its inline list and « Retirer ». + its inline list and « Retirer ». Superseded 2026-11-15: a family opens the references dialog like a finding, and + neither holds an inline list. - « Retirer de ce constat » removes that one citation (the reference stays in the document) and marks the finding « À confirmer » (core rule, `edit.rs`); one « Défaire » restores the citation and the status together. Superseded 2026-11-14: the sheet no longer removes a citation (read-only, « Modifier » and « Aller à » only, key `editor.references.remove_citation` deleted); a citation is removed from the finding's edit form (see « Owner trial - and closure 2026-11-14 »). + and closure 2026-11-14 »). Superseded 2026-11-15: the finding's edit form holds no citation; the references dialog's + own « Modifier » cites and removes (see « Owner follow-up 2026-11-15 »). - Zero state: when the last citation is gone the panel stays open with « Ce constat ne cite plus aucune - référence. » and closes on a tab change. + référence. » and closes on a tab change. Superseded 2026-11-15: the references dialog also opens at 0 reference, and + the line reads « Ce constat ne cite aucune référence. ». - Selecting a tab closes the panel. Every close (✕, Escape outside a field, scrim, tab, « Aller à », « Tout afficher », element gone) records one pending move applied after the exit: the focus goes back to the trigger, else to the active tab button. @@ -293,7 +299,8 @@ Behaviour: are read-only (disclosure, « Modifier », « Supprimer » or the cited hint). Focus returns to the opener. - Side sheet. The citations panel is a modal sheet at the right edge (34 rem at most) stacked over the finding dialog, usable by keyboard and touch. Content: read tiles, « Modifier », « Aller à », « Tout afficher » (« Retirer de ce - constat » was removed from it on 2026-11-14). + constat » was removed from it on 2026-11-14). Superseded 2026-11-15: a modal references dialog stacked over the + finding dialog replaces the sheet (no sheet, no slide); its read tiles have no « Modifier ». - History. Tab, Annotations section, finding dialog, finding creation, sheet, reference dialog, filter are browser history entries (`apps/app/src/editor/history`). Back and Forward restore the view and the scroll; a reload keeps tab and filter, never a form. Entries carry the sheet id and a random session tag (2026-11-14: no longer the account id) and hold @@ -301,9 +308,10 @@ Behaviour: - Filter. « Tout afficher dans l'onglet Références » shows only the references the finding cites, with the chip « Références du constat : » and its « × », plus « Revenir au constat ». Search and sort stay usable. The owner's eight steps (finding A, « 2 références », sheet, « Tout afficher », filtered tab, Back, back on A with the - sheet open) are proved at 1280 and 375 px. + sheet open) are proved at 1280 and 375 px (since 2026-11-15 the sheet of these steps is the references dialog). - « Plus ». The menu is an overlay under the tab row (no layout shift, light fade), closed by a choice, an outside - press, Escape, a tab change and, where the browser offers `CloseWatcher`, the Android Back request. + press, Escape, a tab change and, where the browser offers `CloseWatcher`, the Android Back request. Superseded + 2026-11-15: a vertical list of full-width rows (see « Owner follow-up 2026-11-15 »). - Sidebar. The left menu stays in place while the page scrolls (own scroll when taller than the window). Owner decisions (gate 2026-11-13): R2F-9 items 1 to 6 approved. Item 7: the clients and animals list searches are NOT @@ -316,7 +324,7 @@ Stated limits: 1. Deleting a finding replaces its dialog entry, so the next Back press does nothing visible once (R2F-3). Lifted 2026-11-14: the deletion pops the dialog entry, the first Back moves. 2. Lifted by the final review: « Aller à » a finding or a zone opens its dialog in the same move, one history entry; - Back returns to the place left, sheet included. + Back returns to the place left, references dialog included (the sheet until 2026-11-15). 3. A move made in the same instant as a pending Back can be swallowed (not reachable at human speed). 4. « Aller à » a finding opens its dialog in view mode (accepted again by the owner, 2026-11-14). 5. The search of the References tab is not in the history: a plain tab change keeps it, « Tout afficher » clears it; @@ -358,6 +366,8 @@ Adjustments: une référence »; the one « Enregistrer » writes the citations with the other fields as one undoable operation. The citations sheet is read-only for the finding (no « Retirer de ce constat »); while the form is open it lists the draft's references. The key `editor.references.remove_citation` is deleted (`V1-2-6_R2_LABELS.md` §9). + Superseded 2026-11-15: the finding's edit form no longer holds citations (the references dialog's own edit mode + does), and the sheet is a dialog. - Deletion and Back (`085c568`, `4018344`): the deletion closes its dialog by popping the entry, so the first Back moves; the first « Défaire » after a deletion restores the finding at once (Constats opens, the row is selected and focused). Choosing « Plus » entry puts the focus on the new tab's panel (the panels take `tabIndex=-1` and show a @@ -372,11 +382,12 @@ Adjustments: cancelable, a jump of several entries out of the editor with a dirty finding or reference dialog is cancelled and the top dirty dialog asks « Abandonner les modifications ? ». « Abandonner » runs the jump again with `traverseTo`, leaving no flag and no notice. With two dirty dialogs the question cascades from the top. Before - the finding asks, the citations sheet and a clean reference dialog over it close, so its question is never hidden - under them. Without the API or when the event is not cancelable, the earlier flag and notice stay. + the finding asks, the citations dialog (a sheet until 2026-11-15) and a clean reference dialog over it close, so its + question is never hidden under them. Without the API or when the event is not cancelable, the earlier flag and notice stay. - Notice after the loss elsewhere: unchanged text, now keyed by the session tag. - Final review, rev 4 (2026-11-14): a Back asks only the layers it removes. A Back that closes only the citations - sheet, or a clean reference dialog over it, closes it and asks nothing, even over a dirty finding form. A Back or a + sheet, or a clean reference dialog over it, closes it and asks nothing, even over a dirty finding form (since + 2026-11-15 a dirty citations draft is asked like the finding form). A Back or a jump that removes the dirty finding dialog first closes the clean layers over it, so its question is visible and focused. A sign-out, or a session ending, while a dialog holds unsaved text leaves one flag with no text, keyed by the sheet id and by a fingerprint of the account salted with a random value stored in the flag: the same account's @@ -396,8 +407,8 @@ Accepted limits (owner, 2026-11-14): Limits found during these adjustments, to be confirmed by the owner at the final checks (`V1-2-6_OWNER_TRIAL.md` §4.12): 5. In the leave cascade, « Continuer la saisie » on a lower dialog keeps that draft; a draft already abandoned above - stays dropped (the user's choice). The sheet and a clean reference dialog over the finding close before its - question; one Back then reopens the citations sheet. + stays dropped (the user's choice). The references dialog (a sheet until 2026-11-15) and a clean reference dialog + over the finding close before its question; one Back then reopens the references dialog. 6. Android Back closing « Plus » relies on `CloseWatcher` and is proved by a stub test only. 7. BLK-015 and `admin.spec.ts`: tracked apart (RR-13), unchanged. @@ -408,6 +419,53 @@ leave is confirmed where the browser can cancel it. Status: R2 validated, closed pending the final manual checks (`V1-2-6_OWNER_TRIAL.md` §4.12). The owner still has to check Android Back on a real phone. +#### Owner follow-up 2026-11-15 + +Status: built on `feature/v1-2-anatomical-sheets` on top of `b41c24b` (plan « Rev 5 », +`.claude/tasks/plans/2026-11-13-r2-ux-finish-1624.md`, contract criteria 26 to 31), awaiting the owner's `db:trial` +check (`V1-2-6_OWNER_TRIAL.md` §4.13), then R2 closure. Nothing merged, nothing deployed. + +The trial validated the finding dialogs and « Défaire » / « Refaire ». Two adjustments were asked. + +Requests (owner brief 2026-11-15): +1. References apart from the finding. The finding dialog keeps « Références citées » and « X références » in view and + in edit mode. The button opens a references dialog stacked over it, which replaces the side sheet. View mode only + reads. Its own « Modifier » cites an existing reference, removes one, creates one (cited in the draft), opens a + reference's dialog, saves (one « Défaire ») or cancels. Families get it too. +2. One tab order: Général, Annotations, Constats, Références, Vérification. On phones Général and Annotations are + shown and the rest sits under « Plus », in that order. « Plus » is a vertical list: rows of 48 px at least, the + active entry tinted with a check mark, light motion, the error count on « Plus » while Vérification is under it. + +Built, by task: +- Task 10, one tab order and the vertical « Plus » list: `ff21b03`, `da755f9` (hover tint, axe on an active row, line + limits). `tabs.ts` shows the first two tabs on phones; `initialTab` lost its tier parameter. The active row carries + `aria-current="true"` besides the tint and the check mark. +- Task 11, the references dialog in view mode: `abc781d`, `2c4c771`, then `d9dbcf1` with the review minors. The trigger + « X références » is a dialog trigger (`aria-haspopup="dialog"`). `CitationsSheet`, its motion, `FindingEditCitations` + and the shortcut store `citationDraft.ts` are gone. The finding's edit form no longer carries `reference_ids`: its + save never rewrites citations. +- Task 12, the dialog's edit mode: `3dc5820`, `2579d4c`. Draft held as adds and removes, applied to the element's + current list at save, so a reload or a change made elsewhere is never overwritten silently. « Enregistrer » writes + one `update` of `reference_ids` (none when pristine), then back to view mode with « Modifications enregistrées » and + the focus on « Modifier ». A new guarded layer `citations` sits between `finding` and `reference`: a dirty draft + refuses ✕, Escape, backdrop, Back and the leave cascade like the finding form. +- Task 13, this documentation. + +Controller rulings (autonomous mandate, reported to the owner): +- Families (categories) get the same dialog as findings; both hold citations. +- View mode is read only: no « Modifier » on its tiles; « Modifier la référence » lives on the edit form's rows. +- « Nouvelle référence » creates a reference and cites it in the draft. +- On phones the visible tabs are the first two of the order; no arrow-key navigation in « Plus » (Tab moves, Tab out + closes). +- A reference created from the dialog, then the draft abandoned, stays in the library uncited. The creation is its own + undo step, tested and documented. + +Labels: `V1-2-6_R2_LABELS.md` §10. Browser proofs: `BROWSER_TESTS.md`. Gates at the last Task 12 commit: typecheck and +lint 0, `test:run` 1683, `e2e:ui` 251, the touched `e2e:shell` specs green with the full-row guard clean. The full +`e2e:shell` sweep is not rerun for Rev 5 (BLK-015 `admin.spec.ts` unchanged). + +Status: awaiting the owner's `db:trial` check (`V1-2-6_OWNER_TRIAL.md` §4.13), then R2 closure. + Original plan text: - Tab model: `EDITOR_TABS` gains `references` between `findings` and `verification` (`apps/app/src/editor/tabs.ts:6-11`),