fix(workout): preserve per-side data across progression and session flows
- Apply progression targets to each unfinished side - Convert per-side weights and drops between kg and lb - Preserve partially completed sets when finishing early - Calculate volume from each side's actual completed work - Keep L/R tracking for planned rest-pause sets - Auto-complete the rated side when logging RIR/RPE - Add regression tests for these flows Validation: 1341 frontend tests passed; production build passed.
This commit is contained in:
1 parent
acff80348f
commit
195db73600
10 files changed
+201
-17
No files matched your search
@@ -29,7 +29,7 @@ import { nextPrescription, applyPrescription, policyFor, defaultIncrement, POLIC
|
||||
import { normalizeRepRange } from './lib/rep-range.js'
|
||||
import { MOBILE, shareExport } from './lib/mobile.js'
|
||||
import { buildCompletedWorkout } from './lib/finish-workout.js'
|
||||
import { isWarmupRow } from './lib/workout-model.js'
|
||||
import { isWarmupRow, hasCompletedWork } from './lib/workout-model.js'
|
||||
import { nextUnfinishedUnit } from './lib/supersetFlow.js'
|
||||
import { swapActiveExercise } from './lib/active-exercise-swap.js'
|
||||
import { useSheetKeyboard, useRevealActiveChip, tappable } from './lib/use-sheet-keyboard.js'
|
||||
@@ -1628,7 +1628,7 @@ function WorkoutDetail({ w, close }) {
|
||||
return <div key={i} className="row" style={{ marginBottom: 12, alignItems: 'flex-start' }}>
|
||||
{ex && <Thumb ex={ex} />}
|
||||
<div className="grow"><div className="tt capitalize" style={{ fontWeight: 600 }}>{ex ? exerciseNameFor(ex) : (e.n || e.id)} {w.prs && w.prs.includes(e.id) && <span className="pr"><Icon name="trophy" />PR</span>}</div>
|
||||
<div className="ss">{e.sets.filter(s => s.done).map(s => setLabel(e.id, s, e.target)).join(' · ') || t('no sets')}</div>
|
||||
<div className="ss">{e.sets.filter(hasCompletedWork).map(s => setLabel(e.id, s, e.target)).join(' · ') || t('no sets')}</div>
|
||||
{e.note && <div className="small dim" style={{ marginTop: 3 }}>
|
||||
{e.notePin && <Icon name="flag" style={{ fontSize: 12, marginRight: 4, verticalAlign: '-1px', color: 'var(--yellow)' }} />}{e.note}
|
||||
</div>}</div>
|
||||
|
||||
Reference in new issue
Block a user