Files
jobtrackingapp/docs/redesign/phase-8/p8-01/README.md
T

19 lines
3.3 KiB
Markdown

# P8-01 — Editing and visibility
Implemented an explicit inline editing mode using existing MUI/PageSection/confirmation/toast patterns. All nine existing report sections are configurable. Visibility updates only the draft preview; Save waits for the owner-only API acknowledgement; Cancel confirms a dirty discard and never writes. Every widget may be hidden, with an intentional empty message and the persistent Customise action. Existing onboarding/new-account guidance stays reachable. All new copy is English/Bokmål.
The typed catalogue and persistence hook are one shared prerequisite; visibility/order/size controls are one coherent editor. P8-01 and P8-02 share that frontend source commit rather than manufacture an intermediate editor that cannot represent its saved server contract. Backend storage was implemented first to make the first real Save safe. This is a checkpoint ordering/grouping deviation, not additional scope.
## Fresh evidence
- Original five new editor cases failed against the immediate-menu implementation (`editor-red.log`). Integrated focused run now passes **36 tests / 6 suites** (`dashboard-final.json`): Dashboard presentation, Analytics presentation, daily control loop, catalogue, layout hook and six editor cases. Zero failed/skipped in that run; the full frontend remains a separate final lane.
- Existing exact monthly values, denominators, custom status/company destinations, independent summary/trends errors and period loading remain asserted. Original five-flag immediate local-write test now asserts all nine choices through explicit Save and remount with persisted server readback fixture.
- Catalogue/hook tests exercise corrupted/unknown/duplicate IDs, unsupported sizes, missing new widgets appended hidden, legacy owner-only flags, failed save/retry, unsupported future version, 409/reload and late responses after identity change/unmount. Mocked component API responses are not cross-device HTTP evidence.
- Corrected real browser run passed **10/10**, zero skipped/retried/flaky (`browser-corrected.json`): two retained Dashboard journeys plus eight new Phase 8 cases. Actual SQLite/API/cookies/CSRF verify saved readback, fresh browser login, logout/login, two-session conflict, isolation, reset/cancel, failure/retry and all-hidden recovery. The initial prebuilt bundle targeted port5202 instead of the isolated5302 API; its 10 failures are retained in `browser-focused.json`. Rebuild with `NEXT_PUBLIC_API_BASE_URL=http://localhost:5302/api` corrected the harness without relaxing assertions.
## Review repairs and conditions
Review reproduced pending-save navigation offering an untrue discard promise. A deferred-PUT test failed first, then passed after the guard began holding SPA navigation with a truthful wait status during saving. Aborting a browser request is never represented as a server rollback. A browser unload warning cannot guarantee save cancellation.
Screenshots exposed edit-entry focus scrolling the heading beneath the fixed header. An actual browser geometry regression failed against that bundle; local scroll-margin plus deliberate focus/scroll is now implemented, with the succeeding full browser run pending. New controls preserve the app's focus ring, native selects and 44px pointer controls. Final responsive, axe and human qualification is recorded in P8-04 rather than inferred from unit tests.