feat(version): bump to 0.8.106 and enhance combination exercise features
Deploy Development / deploy (push) Successful in 38s
Test Suite / pytest-backend (push) Successful in 35s
Test Suite / lint-backend (push) Successful in 0s
Test Suite / build-frontend (push) Successful in 11s
Test Suite / playwright-tests (push) Successful in 55s

- Updated app version to 0.8.106, reflecting recent improvements in combination exercise handling.
- Introduced `advance_mode` for slot profiles, allowing for flexible timing options (timed, repetitions, manual) in the CombinationMethodProfileEditor.
- Enhanced the CombinationCoachSlots component to display timing summaries based on the selected advance mode.
- Updated ExerciseFormPage to manage combination slots with new validation and user feedback for exercise selection.
- Documented changes in the changelog for better tracking of feature enhancements.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
LarsandClaude Sonnet 4.6 committed 2026-05-13 08:19:46 +02:00
1 parent ce63d46cf4
commit 38d84ecdf6
7 files changed
+306 -80

No files matched your search

@@ -10,9 +10,28 @@ import {
combinationArchetypeLabel,
sortCombinationSlotsForDisplay,
} from '../constants/combinationArchetypes'
import { readSlotProfilesV1 } from '../utils/combinationMethodProfileUi'
function summarizeSlotProfilesRow(r) {
if (!r) return null
const adv = r.advance_mode || 'timed'
const bits = []
if (adv === 'timed') {
bits.push('Zeit')
if (r.load_sec != null) bits.push(`${r.load_sec}s Arbeit`)
} else if (adv === 'rep') {
bits.push('Ziel‑Wdh.')
if (r.consecutive_reps != null) bits.push(`${r.consecutive_reps}×`)
} else {
bits.push('Coach')
if (r.consecutive_reps != null) bits.push(`Richtwert ${r.consecutive_reps}×`)
}
if (r.intra_rep_rest_sec != null) bits.push(`Pause ${r.intra_rep_rest_sec}s`)
if (r.transition_after_sec != null) bits.push(`Wechsel ${r.transition_after_sec}s`)
return bits.join(' · ')
}
export default function CombinationCoachSlots({ combinationSlots, methodArchetype, methodProfile }) {
const slots = useMemo(() => sortCombinationSlotsForDisplay(combinationSlots), [combinationSlots])
const candidateIds = useMemo(() => {
const set = new Set()
@@ -76,6 +95,23 @@ export default function CombinationCoachSlots({ combinationSlots, methodArchetyp
const archeKey = methodArchetype != null ? String(methodArchetype).trim() : ''
const archDisplay = archeKey ? combinationArchetypeLabel(archeKey) : null
const slotTimingByIx = useMemo(() => {
if (!methodProfile || typeof methodProfile !== 'object' || Array.isArray(methodProfile)) return new Map()
const rows = readSlotProfilesV1(methodProfile)
const m = new Map()
for (const r of rows) {
m.set(Number(r.slot_index), r)
}
return m
}, [methodProfile])
const methodProfileKvSansSlots = useMemo(() => {
if (!methodProfile || typeof methodProfile !== 'object' || Array.isArray(methodProfile)) return []
return Object.entries(methodProfile)
.filter(([k]) => k !== 'slot_profiles_v1')
.sort(([a], [b]) => a.localeCompare(b, 'de'))
}, [methodProfile])
return (
<section
className="card"
@@ -124,10 +160,13 @@ export default function CombinationCoachSlots({ combinationSlots, methodArchetyp
<div style={{ fontSize: '0.7rem', fontWeight: 700, color: 'var(--text3)', textTransform: 'uppercase', marginBottom: '6px' }}>
Geplantes Ablaufprofil (Katalog)
</div>
<dl style={{ margin: 0, fontSize: '0.82rem', lineHeight: 1.45 }}>
{Object.entries(methodProfile)
.sort(([a], [b]) => a.localeCompare(b, 'de'))
.map(([k, val]) => (
{methodProfileKvSansSlots.length === 0 ? (
<p style={{ margin: 0, fontSize: '0.82rem', color: 'var(--text3)', lineHeight: 1.42 }}>
Nur stationsbezogene Daten (Zeiten/Zähl‑Steuerung) — siehe je Station unter der Überschrift „Plan:“.
</p>
) : (
<dl style={{ margin: 0, fontSize: '0.82rem', lineHeight: 1.45 }}>
{methodProfileKvSansSlots.map(([k, val]) => (
<div key={k} style={{ marginBottom: '4px', display: 'grid', gridTemplateColumns: 'minmax(72px,1fr) minmax(0,2fr)', gap: '6px 10px' }}>
<dt style={{ margin: 0, fontWeight: 600, color: 'var(--text3)', wordBreak: 'break-all' }}>{k}</dt>
<dd style={{ margin: 0, color: 'var(--text1)' }}>
@@ -143,7 +182,8 @@ export default function CombinationCoachSlots({ combinationSlots, methodArchetyp
</dd>
</div>
))}
</dl>
</dl>
)}
</div>
) : null}
@@ -162,11 +202,19 @@ export default function CombinationCoachSlots({ combinationSlots, methodArchetyp
(candIds.length <= 1 && slot.candidates?.[0]?.title) ||
`Station ${slot.slot_index != null ? Number(slot.slot_index) + 1 : si + 1}`
const ix = slot.slot_index != null ? Number(slot.slot_index) : si
const timingSummary = summarizeSlotProfilesRow(slotTimingByIx.get(ix))
return (
<li key={`${slot.slot_index ?? si}-${slotTitle}`} style={{ lineHeight: 1.45 }}>
<div style={{ fontWeight: 700, fontSize: '0.92rem', marginBottom: candIds.length > 1 ? '6px' : '8px' }}>
<div style={{ fontWeight: 700, fontSize: '0.92rem', marginBottom: timingSummary ? '4px' : candIds.length > 1 ? '6px' : '8px' }}>
{slotTitle}
</div>
{timingSummary ? (
<p style={{ margin: '0 0 8px', fontSize: '0.78rem', color: 'var(--text2)', lineHeight: 1.42 }}>
Plan: <span style={{ color: 'var(--text1)', fontWeight: 600 }}>{timingSummary}</span>
</p>
) : null}
{candIds.length === 0 ? (
<p style={{ margin: 0, color: 'var(--text3)', fontSize: '0.86rem' }}>Keine Übung zugeordnet.</p>
) : (