Skip to content

Add workout pop-up for distance and time tiles#220

Open
NickOldfield wants to merge 2 commits intoJaapvanEkris:0.9.7-(under-construction)from
NickOldfield:workouts
Open

Add workout pop-up for distance and time tiles#220
NickOldfield wants to merge 2 commits intoJaapvanEkris:0.9.7-(under-construction)from
NickOldfield:workouts

Conversation

@NickOldfield
Copy link

Summary
Clicking the Distance or Timer tiles on the dashboard now opens a small popup that lets the user set a workout goal Users can set either:

  • a distance goal (100m / 500m / 1K / 2K)
  • a time goal (1 / 5 / 10 / 20 minutes)

When a goal is confirmed it’s sent to the server over WebSocket using the existing updateIntervalSettings command

Changes

app/client/workout-bar.js
Added the popup component

app/client/store/dashboardMetrics.js
Distance and Timer tiles now fire a workout-open event when clicked

app/client/index.js
Import workout-bar.js so the popup registers when the app loads

Summary
Clicking the Distance or Timer tiles on the dashboard now opens a small popup that lets the user set a workout goal
Users can set either:
 - a distance goal (100m / 500m / 1K / 2K)
 - a time goal (1 / 5 / 10 / 20 minutes)

When a goal is confirmed it’s sent to the server over WebSocket using the existing updateIntervalSettings command

Changes

app/client/workout-bar.js
Added the popup component

app/client/store/dashboardMetrics.js
Distance and Timer tiles now fire a workout-open event when clicked

app/client/index.js
Import workout-bar.js so the popup registers when the app loads
@JaapvanEkris
Copy link
Owner

JaapvanEkris commented Mar 16, 2026

Nick,

Thanks for the PR! Could you be tempted to add the Calories workout type as well? It is an addition in the 0.9.7 branch, and it uses calories as type and uses targetCalories. That would satisfy my desire for completeness 😃

@JaapvanEkris JaapvanEkris added this to the 0.9.7 milestone Mar 16, 2026
@NickOldfield
Copy link
Author

Nick,

Thanks for the PR! Could you be tempted to add the Calories workout type as well? It is an addition in the 0.9.7 branch, and it uses calories as type and uses targetCalories. That would satisfy my desire for completeness 😃

I've added that now. I've not updated it on my rower so can't test however I see no reason it wouldn't work. Thanks

@JaapvanEkris
Copy link
Owner

Nick,
Thanks for the PR! Could you be tempted to add the Calories workout type as well? It is an addition in the 0.9.7 branch, and it uses calories as type and uses targetCalories. That would satisfy my desire for completeness 😃

I've added that now. I've not updated it on my rower so can't test however I see no reason it wouldn't work. Thanks

I'll test it for you. So many thanks for this!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants