diff --git a/docs/CURRENT_STATE.md b/docs/CURRENT_STATE.md index 900a666..e532b4c 100644 --- a/docs/CURRENT_STATE.md +++ b/docs/CURRENT_STATE.md @@ -9,6 +9,16 @@ Code/configuration take precedence over this summary. +## Accepted TASK-005 integration — 2026-11-11 + +Captain engaged Frontend UI Design → Webapp Feature for the briefed remaining TASK-005 scope. Captain explicitly accepted TASK-005 with “task complete” on 2026-11-11. Status: Complete. Captain subsequently explicitly authorized commit/local codex merge. Implementation is preserved in persistent `.task-worktrees/task-005`, branch `task/005-notes-bodyweight`, base `be0ff2b`. TASK-005 is integrated into local codex under Captain’s subsequent “commit and merge” instruction; verify resulting commit/refs with Git. No push/deploy authorized. + +Candidate adds optional session notes by date/period, exercise notes by date/period/exercise and one daily positive decimal kg body-weight value shared across periods. Explicit independent Save; Clear changes only the draft and Save removes the saved value. Plain text max 4000 characters, read/error/retry states, saved/unsaved feedback, context-isolated async read/save behavior. No performance completion or previous-session changes. Optional disclosures preserve dark/compact/responsive conventions, including empty stretch sessions. + +TASK-005 storage is IndexedDB v4, adding workoutDetails while retaining all old records. Backup exports v4 and imports v1–v4 atomically; old-format replacement preserves observations absent from old files. Previous app builds cannot open v4 databases/read v4 backups; no downgrade path claimed. Details/design/decision are in candidate SPEC, TASK-005_UI.md and ADR-022. Integrated home schema is now v4; JSON exports use envelope v4 with v1–v4 imports. + +Fresh validation: 206/206 tests across 18 files with one worker, lint/final build, source preflight 005, context/whitespace and base diff review pass. No independent browser/visual/keyboard pass or runner/browser/server/manual snapshot launch claimed. Captain acceptance is now recorded; no further acceptance gate remains for this candidate. Captain subsequently explicitly instructed “commit and merge”; acceptance alone was not treated as Git authority. Test command and prior evidence remain in HANDOFF. + ## Accepted TASK-019 reconstruction — 2026-11-11 Captain requested finishing TASK-019. New implementation is in persistent `.task-worktrees/task-019`, branch `task/019-previous-availability-rebuild`, based on codex `6ea3f7b`. Status: Complete following Captain acceptance and explicit commit/local codex merge authorization. The original `/tmp` source remains missing; this is a rebuild, not recovery. Captain authorized integration of the candidate into local codex; verify resulting commit/refs with Git. @@ -78,3 +88,8 @@ All available completed application work is integrated in local codex. Every exi ## TASK-019 completion integration — 2026-11-11 Captain explicitly accepted TASK-019 and authorized its commit/local codex merge. The current persistent source contains the validated replacement for the lost implementation. All available completed task application/tooling work is integrated after this merge; no uncommitted candidate work remains. Three safety stashes preserve only duplicate/older tooling/context from earlier integrations, including home's pre-acceptance 019 context. Missing original `/tmp` registrations and all persistent implementation worktrees remain untouched. Earlier audit notes that TASK-019 was missing/rebuild-required are historical and superseded by this accepted reconstruction. Future implementation remains limited to explicitly accepted tasks. + + +## TASK-005 local integration — 2026-11-11 + +Captain authorized committing/merging the accepted TASK-005 candidate. Base be0ff2b; source task/005-notes-bodyweight in persistent .task-worktrees/task-005. All available completed task work is integrated after this merge, with clean source/home expected (verify Git). The pre-merge duplicate home task/current-state/handoff copies are preserved in a fourth named safety stash; no unique implementation is left only in stashes. All original missing /tmp registrations and persistent worktrees remain untouched. No push, deployment or Captain-session cleanup. diff --git a/docs/DECISIONS.md b/docs/DECISIONS.md index b52fd90..56dfd1d 100644 --- a/docs/DECISIONS.md +++ b/docs/DECISIONS.md @@ -374,3 +374,10 @@ For exercises with per-side reps or durations, show one measurement input per se ### Compatibility Retain the current left/right storage fields and historical semantics. Explicit edits to the shared input set both values; browsing and untouched Save preserve unequal or partial historical values, displayed as read-only text rather than choosing one silently. No migration or fabricated historical values. + + +## ADR-022: Optional dated notes and daily body weight + +- Status: Accepted through Captain's engagement of the briefed TASK-005 scope, 2026-11-11. + +Session notes belong to date/period, exercise notes to date/period/exercise, and body weight to the date shared across both periods. These are optional actual observations, stored separately from performance and from permanent exercise-library guidance. Saving them does not complete sets, copy prescription targets or change load/volume. Use explicit Save; Clear edits the draft and Save confirms removal. Notes are plain text (4000-character limit); body weight is finite positive decimal kilograms. Preserve prior records via additive storage and old backup readers. Technical schema/version and exact UI are specified in TASK-005_UI.md. diff --git a/docs/HANDOFF.md b/docs/HANDOFF.md index e1fbb17..fb365f4 100644 --- a/docs/HANDOFF.md +++ b/docs/HANDOFF.md @@ -3,26 +3,24 @@ > Replaceable snapshot; repository code and maintained context take precedence. - Updated: 2026-11-11. -- TASK-019: Complete. Captain explicitly stated “task-019 complete. commit and merge”, accepting the reconstruction and authorizing local integration. -- Source: `.task-worktrees/task-019`, branch `task/019-previous-availability-rebuild`, base codex `6ea3f7b`; target local `codex`. Verify final commit/refs with Git. +- TASK-005: Complete. Captain explicitly accepted (“task complete”), then separately authorized “commit and merge”. +- Source: `.task-worktrees/task-005`, branch `task/005-notes-bodyweight`, base codex `be0ff2b`; target local `codex`. Verify final commit/refs with Git. - All available completed task implementation is integrated after this merge. No push/deployment or worktree/session cleanup authorized. ## Delivered and validated -Previous-session action is offered only for compatible earlier completed data, across regular reps/holds/hang, aggregate EMOM and original minute-history editors. Unknown, empty or failed lookups stay hidden. Shared keyed/cancellable results use the loaded saved definition/format and owning parent context; separate failure/retry preserves typed values. Existing compatibility, explicit click, Save/completion, zero/blank/draft handling, populated-entry protection and historical isolation remain unchanged. +Optional date/period session notes, dated exercise observations and one daily positive decimal kg body-weight value shared across periods. Compact disclosures/forms retain the dark UI and existing workout hierarchy. Independent explicit Save; Clear edits only the draft, Save confirms removal. Notes are plain text with a 4000-character limit. Read failures prevent overwriting and offer retry; failed saves retain drafts; keyed forms isolate late reads/save feedback. Navigation follows existing discard-of-unsaved-draft behavior. Notes/body weight never complete or modify performance or previous-session suggestions. -180/180 tests across 15 files pass with `npm test -- --maxWorkers=1`; lint/build, no-launch source preflight, context validation (0 warnings), whitespace and diff review against `6ea3f7b` pass. Includes real IndexedDB read-only/eligibility/data-preservation cases and controlled asynchronous race/retry/parent-context checks. Captain acceptance is recorded without claiming an independent agent browser/console/network review. Application implementation is unchanged during acceptance/commit preparation, so tests are not rerun solely for completion text. +IndexedDB v4 adds workoutDetails and leaves original goal/legacy/detailed records intact. JSON v4 exports and v1–v4 imports validate and transact atomically. Old-format replacement preserves new observations absent from old envelopes; v4 replacement covers all four stores. Older app builds cannot open v4 DBs/read v4 backups; no downgrade claimed. No dependencies, programme, timers, history/routine editor/backup interface or reviewed content/illustrations added. -No storage/schema, compatibility-policy, seed/programme, layout/theme or dependency changes. This is a reconstruction, not byte-identical recovery of the missing original source. +206/206 tests across 18 files pass with `npm test -- --maxWorkers=1`. Lint/final build, source preflight, context validation (0 warnings), whitespace and diff review against `be0ff2b` pass. Coverage includes upgrades from v1/v2/v3, blocked upgrades, original record preservation, backup round trips/old imports/rollback, input validation, save/clear/reload, empty sessions, date/period/exercise isolation, failures and async read/save races. No independent agent browser/console/network/desktop/mobile/keyboard review claimed; Captain acceptance is recorded. Application implementation unchanged during acceptance/integration preparation, so checks are not rerun solely for completion documentation. + +Design: docs/TASK-005_UI.md. Scope decision: ADR-022. Storage/backup contract: TASK-005 section in docs/SPEC.md. PROJECT_OVERVIEW describes the integrated v4 architecture. ## Git state and retained evidence -TASK-016 dark theme and reconstructed TASK-018 compact inputs were integrated in `0cf0515`; TASK-020 completion in `6ea3f7b`. TASK-019 completion is integrated from its persistent dedicated branch. Home and all persistent task worktrees should be clean; verify Git before new work. - -Three named safety stashes retain duplicate/older context/tooling: home before TASK-016 integration, old TASK-020 worktree copies before reconciliation, and home's pre-acceptance TASK-019 context. They contain no unique pending application changes. Applying them wholesale would reintroduce stale documentation; retain pending Captain cleanup authority. - -Original missing `/tmp` registrations remain prunable evidence. No branches, worktrees, stashes or snapshots are removed, and no Captain testing sessions are stopped. No remote push or deployment. +All completed available implementation is integrated after TASK-005 merge; no unique uncommitted application work remains. Home and persistent task worktrees should be clean; verify before new work. Four named safety stashes preserve duplicate/older context/tooling from prior integrations, including home's pre-merge TASK-005 context. Applying them wholesale would restore stale documentation; retain pending Captain cleanup authority. Missing original `/tmp` registrations remain prunable evidence, not unmerged candidate code. No branches/worktrees/stashes/snapshots deleted and no Captain sessions stopped. ## Testtask -Captain alone runs/stops real sessions. From project home, `./scripts/testtask.sh 019` selects the persistent 019 source and Node automatically. `--check 019` validates without launch. Snapshots are exact-state test evidence under the source's `.test-worktrees`, never editing sources; completion documentation may require the supported runner to refresh on Captain's next launch. +Captain alone runs/stops real sessions. From home, `./scripts/testtask.sh 005` still selects the persistent source and Node automatically; `--check 005` validates without launch. Snapshots remain separate under source `.test-worktrees` and must not be edited. Completion documentation may require the supported runner to refresh on Captain's next launch. No runner/browser/server/snapshot launched for integration. diff --git a/docs/PROJECT_OVERVIEW.md b/docs/PROJECT_OVERVIEW.md index 5c5bd12..1ecd820 100644 --- a/docs/PROJECT_OVERVIEW.md +++ b/docs/PROJECT_OVERVIEW.md @@ -8,11 +8,11 @@ This is a newly initialized repository. The user calls the planned product "Work Workout Tracker is a personal local workout app with actual-date navigation, exclusive Morning/Afternoon views, a persistent local-time clock and no workout timers. Seed v8 contains 30 versioned exercise definitions with equipment/measurement metadata. Reusable logging shows only relevant reps, durations and equipment-specific loads, with one shared measurement input for per-side work, supports completed rows, partial drafts and explicit previous-session suggestions offered only when compatible earlier completed data exists, and records EMOM with one weight and one total-reps input. Earlier minute records remain separately accessible. Daily hangs have an editable continuous target, independent attempts, longest continuous and cumulative totals. Monday/Friday stretch routines have headings but no invented exercises. Dog walks remain excluded; their latest classification is bodyweight-only reference context. -Exercise definition, workout prescription and dated performance are independent. New performance retains definition/prescription snapshots, while original aggregate, rep-set and weight-only history stays readable separately. Exercise details expose available notes and placeholders; reviewed technique/muscle content and local illustrations remain future work. The application uses a single dark green theme with coordinated Bootstrap/native controls and compact numeric inputs. History/progress screens, routine editing, backup interface and offline reload remain separate tasks. SPEC defines behavior and WORKOUT_ROUTINE the authoritative initial programme. +Exercise definition, workout prescription and dated performance are independent. New performance retains definition/prescription snapshots, while original aggregate, rep-set and weight-only history stays readable separately. Optional dated session/exercise notes and one daily body-weight entry in kg use independent Save actions; body weight is shared across both periods. Exercise details expose available programme notes and placeholders; reviewed technique/muscle content and local illustrations remain future work. The application uses a single dark green theme with coordinated Bootstrap/native controls and compact numeric inputs. History/progress screens, routine editing, backup interface and offline reload remain separate tasks. SPEC defines behavior and WORKOUT_ROUTINE the authoritative initial programme. ## Technology and architecture -The application foundation now uses React, Vite, and React-Bootstrap. IndexedDB v3 stores the hanging-goal override, legacy strength records and new detailed performance in separate stores behind adapters. JSON backup/import is implemented at adapter level with version validation and atomic transactions; TASK-009 owns its UI. Native IndexedDB is used at runtime; fake-indexeddb is a test-only dependency. The application has no backend, authentication, or cloud dependency. +The application foundation now uses React, Vite, and React-Bootstrap. IndexedDB v4 preserves the hanging-goal override, legacy strength records and detailed performance stores, adding independent workoutDetails records for optional dated notes and body weight behind a storage adapter. JSON backup/import is implemented at adapter level with v4 exports, v1/v2/v3/v4 validation/read compatibility and atomic transactions; TASK-009 owns its UI. Native IndexedDB is used at runtime; fake-indexeddb is a test-only dependency. The application has no backend, authentication, or cloud dependency. The design keeps routine templates, exercise definitions, historical workout records, and UI state separate. The initial routine is bundled as versioned seed data; subsequent user edits are local data and must not be overwritten by updates. A storage adapter separates React components from IndexedDB. A service worker and locally bundled assets are required for offline reload in the release scope. diff --git a/docs/SPEC.md b/docs/SPEC.md index c27a408..32c3bbf 100644 --- a/docs/SPEC.md +++ b/docs/SPEC.md @@ -354,3 +354,15 @@ Adapter exports now use JSON envelope v3 and continue importing v1/v2 as well as ### TASK-017 side-input correction Every per-side exercise, including Single-arm preacher curls over a chair, uses one Reps (each side) or Seconds (each side) input per set. Entering or clearing the input changes both stored side values together. Equipment inputs and prescription guidance remain unchanged. Existing unequal/partial side values are shown as read-only text with a blank shared replacement input; browsing or untouched Save does not choose a side or rewrite either value. Storage shapes, snapshots and per-side volume semantics remain unchanged. + + +## TASK-005 dated observations contract — 2026-11-11 + +This current contract supersedes earlier database/backup version descriptions for the TASK-005 candidate. Existing performance schemaVersion 1 and all original storage semantics remain unchanged. + +- Session notes are optional plain text by local date and Morning/Afternoon period. Exercise notes are optional plain text by date/period/exercise ID, independent of aggregate/minute/legacy representation. These are dated observations, not permanent exercise-library instructions, per-set/minute notes or automatic previous-session suggestions. Limit 4000 characters; preserve entered text, treating blank/whitespace-only Save as removal. +- Body weight is an optional finite positive decimal kg measurement once per local date, shared across both periods; blank Save removes it. It does not contribute external-load volume and is never copied from targets or previous sessions. +- Each field has an independent explicit Save. Clear edits only its draft; Save confirms removal. Saving observations never saves/completes sets. Navigation follows existing discard-of-unsaved-draft behavior; late reads/save feedback cannot enter another date/period/exercise editor. Read failures disable overwriting and offer retry; write failures preserve drafts. +- IndexedDB v4 adds `workoutDetails`, preserving all prior stores/records. Keys: `date:period:session-note`, `date:period:exerciseId:exercise-note`, `date:body-weight`. Values have `schemaVersion: 1`, `kind`, `date`, applicable `period`/`exerciseId` and either `text` or `weightKg`. Validate identity, record fields, values and key consistency. +- JSON exports use envelope v4 with `workoutDetails`; imports accept v1/v2/v3/v4. Older envelopes contain no observation store; even an explicit old-format replacement preserves existing observations rather than inferring their deletion. V4 replacement covers all four stores atomically. Validate all records before mutation; duplicate/non-replacing import failures roll back all stores. Older app builds cannot open a v4 database or read v4 backups; retain this app version for restoring new data. No downgrade/rewrite of historical records and no backup UI in this task. +- UI composition and state/accessibility/responsive specification: `TASK-005_UI.md`. Existing programme notes remain distinct from personal observations. History charts remain TASK-008; backup interface remains TASK-009. diff --git a/docs/TASK-005_UI.md b/docs/TASK-005_UI.md new file mode 100644 index 0000000..6325598 --- /dev/null +++ b/docs/TASK-005_UI.md @@ -0,0 +1,23 @@ +# TASK-005 design and implementation brief + +2026-11-11. Extend the approved dark theme, typography, compact input widths, date/period navigation and workout editors. Captain invoked Frontend UI Design → Webapp Feature and engaged the previously briefed scope: session notes, dated exercise notes, optional daily body weight. + +## Composition + +Routine heading/guidance → collapsed **Session notes and body weight** → existing exercise list. The disclosure remains available on empty stretch sessions. Its contents use existing Bootstrap Form/Button semantics: a labelled optional session-note textarea, and an optional Body weight (kg) field. Desktop/tablet >=768px groups them in two bounded columns; narrow widths stack them with wrapping labels/help/errors. Body weight retains compact 5.25rem numeric sizing. Textareas fill available width, resize vertically and have no horizontal overflow. + +Each exercise card retains current performance editor, goal and exercise-details content. Add a separate collapsed **Your notes** disclosure with a textarea labelled using the exercise name. Notes are dated exercise-session observations, not permanent exercise-library instructions or per-set/minute notes. A single exercise note applies to that date/period/exercise independently of legacy/detailed performance representations. No notes copied by previous-session suggestions. + +## Actions and states + +Each field has its own explicit Save and secondary Clear action. Clear changes only the draft; Save confirms removal. No confirmation modal for editing a single optional field. Plain text, max 4000 characters. Body weight accepts a finite positive decimal number in kg; blank means no measurement, never assumed zero. One body-weight record per date, shared across Morning/Afternoon, no volume contribution. Session notes are separate per date/period; exercise notes additionally by exercise ID. + +Loading disables controls; unavailable/invalid saved data disables Save and offers Retry loading. Validation/write failure retains input and surfaces an associated alert; successful Save announces saved/removed status in that form. Edits announce unsaved changes. Date/period/identity changes remount the owning form to prevent late reads/writes displaying in another context. Navigation follows the existing discard-of-unsaved-draft convention; browsing never writes. Saving notes/body weight never completes or modifies performance records. Persistent controls use visible labels, unique IDs, help/error associations, semantic forms/details/summary, 44px actions, dark native controls and offset keyboard focus. No hover-only actions. + +## Storage and backup handoff + +Add one independent workoutDetails store via additive IndexedDB v4 upgrade; leave all three original stores/records untouched. Records are schemaVersion 1 with explicit kind/date and applicable period/exercise identity; validated keys distinguish session-note, exercise-note and body-weight. Save empty text/weight deletes only that matching optional record. Backup envelope v4 includes this store and continues reading v1/v2/v3. Older envelopes omit it and must not erase it during an old-format replacement. New v4 replacements cover all stores atomically. No import/export UI (TASK-009). + +## Verification + +Automated migration from prior versions, literal old-data preservation, backup round trips/rollback/old imports, input validation, explicit clear/save, save/reload/date/period isolation, empty sessions, read/write failures and late read/save context changes. Full tests (one worker), lint/build, context, whitespace/base-diff and no-launch testtask preflight. Captain alone runs `./scripts/testtask.sh 005` for desktop/320px, keyboard/focus, disclosures and save/reload acceptance. No independent browser pass claimed. diff --git a/docs/TASKS.md b/docs/TASKS.md index 313fe52..92d1cc5 100644 --- a/docs/TASKS.md +++ b/docs/TASKS.md @@ -4,7 +4,7 @@ This file holds accepted, scoped implementation work. It is not a speculative ba ## Proposed implementation sequence -Reconciled with `docs/SPEC.md` and `docs/WORKOUT_ROUTINE.md`. TASK-001–003, TASK-012–018 and TASK-020 are Complete. TASK-006 is Superseded; TASK-005 and TASK-008 are Accepted. TASK-019 is Complete following Captain acceptance on 2026-11-11; its persistent reconstruction is integrated, while the original `/tmp` source remains missing. Remaining tasks are Proposed. Completed application work is integrated in local codex, including reconstructed TASK-018 compact inputs within TASK-016. Implement one task per isolated branch/worktree under `docs/WORKFLOW.md`. Preserve the authoritative programme and historical storage semantics. +Reconciled with `docs/SPEC.md` and `docs/WORKOUT_ROUTINE.md`. TASK-001–003, TASK-012–018 and TASK-020 are Complete. TASK-006 is Superseded; TASK-008 is Accepted; TASK-005 is Complete following Captain acceptance and explicit commit/local codex merge authorization. TASK-019 is Complete following Captain acceptance on 2026-11-11; its persistent reconstruction is integrated, while the original `/tmp` source remains missing. Remaining tasks are Proposed. Completed application work is integrated in local codex, including reconstructed TASK-018 compact inputs within TASK-016. Implement one task per isolated branch/worktree under `docs/WORKFLOW.md`. Preserve the authoritative programme and historical storage semantics. ### TASK-001: Application foundation and responsive shell @@ -52,7 +52,7 @@ Reconciled with `docs/SPEC.md` and `docs/WORKOUT_ROUTINE.md`. TASK-001–003, TA ### TASK-005: Extended workout recording -- Status: Accepted +- Status: Complete — Captain explicitly stated “task complete” on 2026-11-11, satisfying the acceptance gate. Source `.task-worktrees/task-005`, branch `task/005-notes-bodyweight`, base codex `be0ff2b`. Captain subsequently explicitly authorized “commit and merge”; local codex integration includes the accepted notes/body-weight scope and documentation. - Objective: Extend the initial dated rep/weight records from TASK-014 with other requested performance details while preserving partial and historical records. - Scope: Storage migrations building on the existing hang-goal override and TASK-014 strength entries; additional load variants or counts when needed beyond TASK-014's exercise-specific strength fields; hangs, untimed hold checkoffs, notes, optional body weight, previous-session suggestions, and error states. No timer-derived workout or break duration, per-round EMOM logging, or volume-per-minute rate. - Acceptance criteria: Additional performance details and hang attempts survive reload and remain distinguishable from prescribed targets; multiple hang attempts are distinct; edits/reseeding do not rewrite history; browsing alone writes no workout; storage failures are surfaced. TASK-014's EMOM total, regular per-set reps/weight, and legacy total-weight records remain available. @@ -61,6 +61,8 @@ Reconciled with `docs/SPEC.md` and `docs/WORKOUT_ROUTINE.md`. TASK-001–003, TA - Non-goals: Progress charts, routine editor, backup UI. - Dependencies or blockers: TASK-014 and TASK-015. TASK-015 now owns metadata-driven load/count/side/duration/hang recording, completion and previous-session suggestions. TASK-005 retains notes, optional body weight and other extended recording without duplicating TASK-015. +- Engaged remaining scope: session notes by date/period, dated exercise notes by date/period/exercise and optional body weight once per date (kg, shared across periods). Separate explicit Save/Clear draft actions, additive storage and backup compatibility. Existing recording capabilities are preserved, not rebuilt. UI/contract brief: `docs/TASK-005_UI.md`. + ### TASK-006: Timers during and between exercises - Status: Superseded by TASK-014 @@ -370,3 +372,16 @@ Reconciled with `docs/SPEC.md` and `docs/WORKOUT_ROUTINE.md`. TASK-001–003, TA - TASK-019 completion (2026-11-11): Captain explicitly stated “task-019 complete. commit and merge”, satisfying the acceptance gate and authorizing commit/local codex integration of the validated persistent reconstruction. Existing 180/180 tests across 15 files with one worker, lint/build, source preflight and base diff review remain valid; completion changes only context. No independent agent browser review claimed. All completed available task work is integrated after this merge. Home's duplicate pre-acceptance context is saved in a safety stash rather than overwritten. No push/deploy, worktree/branch/stash removal, registration pruning or Captain-session cleanup authorized. + + +#### TASK-005 implementation evidence — 2026-11-11 + +- Delivered remaining accepted scope: optional date/period session notes, dated exercise observations and optional date-only positive decimal kg body weight shared across periods. Separate optional disclosures/forms reuse the existing dark theme and compact numeric width; explicit Save, Clear-draft/Save removal, unsaved/saved/error/retry states. No note/body-weight action modifies or completes performance. Existing navigation discards unsaved drafts; keyed forms/cancelled reads prevent stale-date/period feedback. +- Additive IndexedDB v4 adds workoutDetails without rewriting goal, legacy or detailed stores. Strict schemaVersion 1 observation validation; JSON v4 export and v1–v4 import. Old-format replacement preserves new observations absent from old files; v4 replacement/import atomicity and rollback tested. Old app builds cannot open the upgraded database/read new backups; no downgrade claimed. No new dependencies. +- UI/design and contract are recorded in TASK-005_UI.md, SPEC's TASK-005 contract and ADR-022. Existing measurement/load/hang/Save/suggestion behavior retained; no history/plan/backup UI, illustration work, timers, programme changes or unrelated refactor. +- Validation: 206/206 tests across 18 files with `npm test -- --maxWorkers=1`, lint, final build, no-launch home `--check 005`, context validation (0 warnings), whitespace and base diff review against `be0ff2b` pass. New tests cover upgrades from older DBs and blocked connections, literal history preservation, valid/invalid input, backup round trips/old imports/rollback, save/clear/reload, isolation, empty sessions, read/write failures and async read/save races. Original storage tests retain preservation checks with v4 expectations. +- Captain alone runs `./scripts/testtask.sh 005`. Desktop/320px, keyboard/focus, disclosures, decimal/native controls, save/reload and period/date isolation require Captain acceptance before Complete. No independent agent browser/console/network pass, runner/server/browser/manual snapshot launch or session cleanup claimed. No task commit/merge/push/deploy authorized. + +- TASK-005 completion evidence (2026-11-11): Captain explicitly confirmed “task complete”, accepting the delivered notes/body-weight scope. Agent validation remains 206/206 tests across 18 files with one worker, lint/build, source preflight, context/whitespace and base diff review. No independent agent visual pass claimed. No application changes after acceptance. Commit/merge/push/deploy and session/worktree cleanup remain unauthorized; accepted implementation is preserved in its persistent source. + +- TASK-005 integration authorization (2026-11-11): After explicit acceptance, Captain instructed “commit and merge”. Commit the validated candidate on task/005-notes-bodyweight and fast-forward local codex from be0ff2b. No application changes since acceptance; prior 206-test/lint/build evidence remains valid. Preserve duplicate home context in a safety stash before merging. No push/deploy, source/snapshot/worktree/stash removal or testing-session cleanup authorized. diff --git a/src/App.jsx b/src/App.jsx index 5eb28ce..40b7169 100644 --- a/src/App.jsx +++ b/src/App.jsx @@ -4,6 +4,7 @@ import { exerciseDefinitions, initialRoutine } from './data/index.js' import { addCalendarDays, localCalendarDate, localDateKey, prescriptionLabel, restLabel, routineForDate, startOfWeek } from './routineView.js' import HangGoalEditor from './HangGoalEditor.jsx' import PerformanceEditor from './PerformanceEditor.jsx' +import WorkoutDetailEditor from './WorkoutDetailEditor.jsx' import { equipmentLabels } from './performanceModel.js' import { readDailyHangGoal, writeDailyHangGoal } from './hangGoalStorage.js' @@ -59,6 +60,9 @@ function ExerciseList({ exercises, dateKey, period, hangGoalSeconds, hangGoalLoa
Target: {prescriptionLabel(target).replace(/^Goal: /, '')}{isHang ? ' continuous' : ''}
{definition.equipment.map((equipment) => equipmentLabels[equipment]).join(' + ')}{rest ? ` · ${restLabel(rest)}` : ''}
{notes}
} @@ -137,6 +141,12 @@ function RoutineView({ selectedDate, setSelectedDate, period, setPeriod, setActi {session.exercises.length > 0 && {session.exercises.length} exercises} {session.targetEffortRpe &&Target effort: RPE {session.targetEffortRpe.min}–{session.targetEffortRpe.max} · One round to start; a second round only if recovery remains good.
} +{help} Clear, then Save to remove a saved value.
+{loading ? `Loading ${label.toLowerCase()}…` : notice}
+ {error &&{error}
} + +} + +export default function WorkoutDetailEditor(props) { + // Every identity has independent draft/read/save state, including during navigation. + return