Add "Duplicate Mesocycle" feature to iterate on existing programs

Open
#73 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
52/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Stale
Tech stack
typescript
Domain
frontend

Research direction

Start at the MesocycleCard menu and mesocycle detail/edit view, the entry points named in the issue. Trace how mesocycles, split days, exercises, IDs, status, and dates are stored locally before deciding where duplication belongs. Done means a distinct offline copy opens in edit mode with copied configuration, reset history/status, a generated name, and an unchanged original.

Written by the indexing model from the issue text.

Description

enhancement good first issue ux

User Story

As a lifter,
I want to copy an existing mesocycle to create a new one,
So that I can keep exercises that work well for me while adjusting only what needs to change.

Background

Experienced lifters often want to iterate on their training programs rather than start from scratch each mesocycle:

  • Keep what works: Certain exercises produce great results and should carry forward
  • Swap what doesn't: Replace exercises that caused issues (joint pain, poor mind-muscle connection)
  • Progressive programming: Slightly modify volume or exercise selection based on previous block's feedback
  • Seasonal adjustments: Make minor tweaks for equipment availability or schedule changes

Currently, creating a new mesocycle requires configuring everything from scratch, even if 80-90% of the program would be identical to the previous one.

Acceptance Criteria

  • Add a "Duplicate" or "Copy" action to existing mesocycles (on MesocycleCard or detail view)
  • Create a new mesocycle with all settings copied:
    • Split type and day names
    • All exercises assigned to each split day
    • Exercise order within each day
  • Open the new mesocycle in edit mode immediately after duplication
  • Auto-generate a name like "{Original Name} (Copy)" or "{Original Name} - Week X"
  • Allow user to edit the name before or after creation
  • The new mesocycle should be in "Not Started" status
  • Original mesocycle remains unchanged
  • Works fully offline

UI/UX Considerations

  • Duplicate action should be accessible from:
    • Mesocycle card menu (three dots / overflow menu)
    • Mesocycle detail/edit view
  • Clear indication that this creates a copy, not modifies the original
  • Consider showing a brief "Copied from {name}" reference in the new mesocycle
  • Toast notification confirming successful duplication

Technical Notes

  • Core (free) feature - local-only operation
  • New mesocycle gets a new unique ID
  • Copy exercise references (exerciseId), not the exercises themselves
  • Reset any workout history - new mesocycle starts fresh
  • Consider whether to copy:
    • ✅ Split configuration and exercises
    • ✅ Mesocycle name (with suffix)
    • ❌ Workout history/logs
    • ❌ Start/end dates (user sets new dates)
    • ❌ Completion status (always starts as not started)

User Flow

  1. User views their mesocycle list or a completed mesocycle
  2. User clicks "Duplicate" action
  3. New mesocycle is created with copied configuration
  4. User is taken to edit view of the new mesocycle
  5. User can:
    • Rename the mesocycle
    • Adjust exercises in any split day
    • Remove/add exercises as needed
  6. User saves when ready

Out of Scope (for this issue)

  • Merging multiple mesocycles
  • Copying only specific split days between mesocycles
  • Sharing/importing mesocycles from other users
  • Version history or diff view between mesocycles

Related

  • #71 - Copy exercises between splits within a mesocycle
  • Mesocycle management workflow
Dominant language
TypeScript
Stars
2
Forks
0
PR merge metrics
No merged PRs in 30d

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Similar issues

More TypeScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.