diff --git a/playwright-report/index.html b/playwright-report/index.html index 5a53fdb..3b8cf4a 100644 --- a/playwright-report/index.html +++ b/playwright-report/index.html @@ -82,4 +82,4 @@ Error generating stack: `+n.message+`
- \ No newline at end of file + \ No newline at end of file diff --git a/server/prisma/dev.db b/server/prisma/dev.db index 3fb4f6c..7db0898 100644 Binary files a/server/prisma/dev.db and b/server/prisma/dev.db differ diff --git a/specs/gymflow-test-plan.md b/specs/gymflow-test-plan.md index 935cd99..0029b31 100644 --- a/specs/gymflow-test-plan.md +++ b/specs/gymflow-test-plan.md @@ -542,9 +542,10 @@ Comprehensive test plan for the GymFlow web application, covering authentication 4. Select 'Left' from the Side selector. 5. Click 'Log Set'. 6. Repeat for 'Right' side. + 7. Repeat for 'Alternately' side. **Expected Results:** - - Sets are logged with the correct 'Left'/'Right' indicators visible in the history. + - Sets are logged with the correct 'Left'/'Right'/'Alternately' indicators visible in the history. #### 3.15. C. Active Session - Log Special Type Set diff --git a/specs/requirements.md b/specs/requirements.md index e127559..4fb4db6 100644 --- a/specs/requirements.md +++ b/specs/requirements.md @@ -66,7 +66,7 @@ Users can structure their training via Plans. * `PLYOMETRIC`: Requires **Reps**. * **3.3.2 Custom Exercises** * User can create new exercises. - * **Unilateral Flag**: Boolean flag `isUnilateral`. If true, sets recorded for this exercise can specify a `side` (LEFT/RIGHT). + * **Unilateral Flag**: Boolean flag `isUnilateral`. If true, sets recorded for this exercise can specify a `side` (LEFT/RIGHT/ALTERNATELY). * **Bodyweight %**: For bodyweight-based calculations. ### 3.4. Workout Tracking (The "Tracker") diff --git a/src/components/History.tsx b/src/components/History.tsx index a8b4548..c52a585 100644 --- a/src/components/History.tsx +++ b/src/components/History.tsx @@ -76,7 +76,7 @@ const History: React.FC = ({ lang }) => { } }; - const handleUpdateSet = (setId: string, field: keyof WorkoutSet, value: number) => { + const handleUpdateSet = (setId: string, field: keyof WorkoutSet, value: number | string) => { if (!editingSession) return; const updatedSets = editingSession.sets.map(s => s.id === setId ? { ...s, [field]: value } : s @@ -454,6 +454,26 @@ const History: React.FC = ({ lang }) => { )} + {/* Side Selector - Full width on mobile, 1 col on desktop if space */} + {set.side && ( +
+ +
+ {(['LEFT', 'RIGHT', 'ALTERNATELY'] as const).map((sideOption) => ( + + ))} +
+
+ )} ))} @@ -466,8 +486,9 @@ const History: React.FC = ({ lang }) => { - )} - + ) + } + ); }; diff --git a/src/components/Tracker/SetLogger.tsx b/src/components/Tracker/SetLogger.tsx index 3d80d66..30bb41a 100644 --- a/src/components/Tracker/SetLogger.tsx +++ b/src/components/Tracker/SetLogger.tsx @@ -106,6 +106,13 @@ const SetLogger: React.FC = ({ tracker, lang, onLogSet, isSporad > {t('left', lang)} +