docs(docs): V1-2.5 checkpoint corrections in browser tests, identity, contract

Eight phone skips by design, the unreadable-permissions and live-region checks, species order and Paris expiry restated in contract 7.2 and 4, PermissionsUnavailable in the folder map.
This commit is contained in:
bchanot committed 2026-11-03 00:14:19 +01:00
1 parent f5456f330d
commit 431999e45c
4 files changed
+20 -12

No files matched your search

+1 -1
View File
@@ -252,7 +252,7 @@ faunosteo/
│ │ ├─ 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
│ │ ├─ catalogue/{CatalogueCanvas,CatalogueCard,CatalogueFailureNotice,SheetAside,VersionLine,ZonePanel}.tsx ← V1-2.5 catalogue pieces (boards 01 to 03)
│ │ ├─ shell/{AppLayout,SidebarNav,MobileDrawer,UserBadge,SignOutButton,AccessDenied}.tsx ← AccessDenied: « Accès non autorisé » on the server's refusal (V1-2.5)
│ │ ├─ shell/{AppLayout,SidebarNav,MobileDrawer,UserBadge,SignOutButton,AccessDenied,PermissionsUnavailable}.tsx ← AccessDenied: « Accès non autorisé » on the server's refusal (V1-2.5); PermissionsUnavailable: own grants unreadable, Retry (V1-2.5 checkpoint)
│ │ └─ account/{SectionCard,SaveRow,AvatarSection,PersonalInfoForm,ProfessionalInfoForm,PreferencesForm,SecurityPanel,RoleBadges,MfaFactors,EnrolTotp}.tsx ← MfaFactors + EnrolTotp: TOTP factors in Sécurité (V1-2.5; the secret lives in component state only)
│ ├─ account/avatarTransport.ts ← magic-byte sniff (never SVG), createImageBitmap → canvas ≤ 1024 px → JPEG transport blob
│ ├─ pdf/ ← the app side of the PDF (export on the core's session since R4.6; the import runs in the worker, `core/worker`)
+4 -4
View File
@@ -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/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, access per right, 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 |
| `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 |
Each suite runs on two Chromium projects: `chromium-desktop` (1280 × 800) and
`chromium-375` (375 × 667, mobile viewport, touch). A test tagged `@phone`
@@ -42,9 +42,9 @@ GoTrue, its secret kept in the test's memory); official sheets by
draft-only versions carrying the curated equine draft under names of their
own, the drawing in the private bucket under its content key), each published
or retired version's fingerprint computed in Node by the shipped core module
(`packages/core-wasm/pkg`, `preview.state`), the one the page runs. A0, A1 and
S1 are desktop journeys, skipped on the phone project (6 skips by design); the
admin screens at 375 px have their own test.
(`packages/core-wasm/pkg`, `preview.state`), the one the page runs. A0, A1, S1
and the creation page's unreadable-permissions test are desktop journeys, skipped on the phone
project (8 skips by design); the admin screens at 375 px have their own test.
`pnpm db:sandbox down` removes all of it.
`pnpm db:sandbox e2e-shell <args>` passes its arguments to Playwright: one
spec file, `--project`, `--grep`. Every shell suite removes its routes after
+9 -4
View File
@@ -30,10 +30,15 @@ same-origin path (`safeNextPath`). `/app/*` under the guard renders inside
`RequireCatalog` decides nothing: the pages ask the server and show
« Accès non autorisé » (`AccessDenied`) when it refuses. `RequireAdmin`
renders the admin pages only on an `aal2` session, so no admin data is
requested before the step-up (§4). The « Fiches anatomiques » and
« Administration » entries of the sidebar and drawer follow a hint built from
the caller's own grant rows and roles (`auth/navigationHint.ts`): a hidden
entry protects nothing, every RPC checks the capability and `aal2` itself.
requested before the step-up (§4). When the caller's own grant rows cannot
be read, the sheet creation page and the administration home show
« Impossible de vérifier vos autorisations » with « Réessayer »
(`PermissionsUnavailable`; `authStore.reloadAccess` reads the roles and
grants again), never an absence of right (V1-2 contract §17.11). The
« Fiches anatomiques » and « Administration » entries of the sidebar and
drawer follow a hint built from the caller's own grant rows and roles
(`auth/navigationHint.ts`): a hidden entry protects nothing, every RPC checks
the capability and `aal2` itself.
A deployment without Supabase (`APP_SUPABASE_URL` empty) shows an
"unavailable" notice on the auth screens; `/app` redirects to `/login`; the
+6 -3
View File
@@ -212,7 +212,7 @@ provisional catalogue access of §5.3, one row per grant:
| `reason` | required motive, 1 to 1 000 characters |
| `verification_note` | required for the three capabilities: the qualification declared and what the owner verified, 1 to 1 000 characters (for `sheet_reviewer`, the professional elements the owner checked; never a certification) |
| `granted_by`, `granted_at` | the platform owner, the time |
| `expires_at` | optional end; later than `granted_at` |
| `expires_at` | optional end; later than `granted_at`; the administration form sends the last millisecond of the chosen day in Europe/Paris (§17.11) |
| `revoked_by`, `revoked_at`, `revocation_reason` | set once by a revocation, reason required |
- Writes: `grant_catalog_right(user_id, kind, reason, verification_note,
@@ -1182,8 +1182,11 @@ bind every species.
- `create_species(id, name_fr, name_en, sort_order)`: sheet editor with
`aal2`, audited. Inserts the row with `active = false`. The id follows the
existing CHECK and is never renamed; an existing id gets one answer.
`sort_order` an integer from 0 to 9 999, or null for the default 100;
outside → `invalid_input` (M7, §17.11).
- `update_inactive_species(id, name_fr, name_en, sort_order)`: sheet editor
with `aal2`, inactive rows only, audited.
with `aal2`, inactive rows only, audited. `sort_order` 0 to 9 999, null keeps
the stored order (M7, §17.11).
- `activate_species(id)`: platform owner with `aal2`, audited; the only way a
species becomes active.
- `rename_species(id, name_fr, name_en)`: platform owner with `aal2`, audited;
@@ -1199,7 +1202,7 @@ bind every species.
- Creating an official sheet accepts an active or an inactive species, never
`other`, and never activates a species. Publication refuses an inactive
species and `other` (§6.7).
- A species row holds an id, two names and an order. No vertebral formula,
- A species row holds an id, two names and an order (0 to 9 999). No vertebral formula,
zone, finding or drawing is generated for it.
Amendment of V1-1 N1 and §5.4 (ratified with O9, 2026-10-28): « The list of