2.7 KiB
2.7 KiB
Task 12 report
Mapping
- Source editor save workflow → pending/success announcements, fresh per-command idempotency keys, retry after request failure, and revision-conflict state without replacing the local draft.
- Source guarded Studio links/provider/dialog → all internal Studio anchors use the guarded
<a>DOM; dirty navigation offers stay, discard, and save-then-navigate with modal focus/trigger restoration and nativebeforeunloadprotection. - Source validation report/screen → saved-version validation gates, current/stale freshness copy, error-before-warning issue order, exact JSON-pointer editor anchors, retry/not-found surfaces, and abortable route reads.
- Source Public Preview screen → missing/current/stale/expired states, exact next-action labels, idempotent preview creation, retry/not-found surfaces, and the shared typed
PublicRecordRenderer. - Route pages → existing route-input codecs supply the validation/preview document ID; no publish/history/snapshot behavior was pulled forward.
- Task 10/11 seam → provider gained only dirty-navigation/time state, editor gained the save callback, and existing Studio links were switched to the newly available source guarded-link component.
TDD evidence
- RED:
corepack pnpm exec vitest run tests/features/tech-log/studio-save-navigation.test.tsx tests/features/tech-log/studio-validation-preview.test.tsxexited 1 before collection at the intentionally missingguarded-studio-link.tsxandpublic-preview-screen.tsximports (2 failed files, 0 tests). - GREEN: the two workflow suites plus
tests/features/tech-log/mock-studio-gateway.test.tspassed 3 files / 22 tests. - Focused seam regression: those three files plus the existing Studio shell, screen, and editor suites passed 6 files / 35 tests.
- Scope check:
git diff --checkpassed.
Files
- Added guarded link, unsaved dialog, beforeunload hook, validation report/screen, Public Preview screen, and validation/preview route pages under
src/features/tech-log/presentation/studio/. - Extended the Task 10 provider/context and Task 11 editor/status rail; updated existing Studio internal link consumers to use the source guard.
- Added
studio-save-navigation.test.tsxandstudio-validation-preview.test.tsx.
SHA
- Base:
59332659752ee17c095471d06e7f0fc8b00c89b4. - Implementation: the commit containing this report, titled
feat: port TechLog Studio validation workflow(final SHA recorded in the Task 12 handoff).
Deferred
- Publish, republish, unpublish, publication history, warning acknowledgement, and immutable publication snapshots remain deferred to Task 13.
- Broad browser-security, app/test types, lint, build, architecture, visual, and full-suite gates remain deferred to integrated Task 14 by user direction.