Skip to content

Commit

Permalink
fit: add golf, swim, pickleball
Browse files Browse the repository at this point in the history
  • Loading branch information
hellos3b committed Jan 5, 2024
1 parent 7e8eaec commit cc2943c
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"editor.codeActionsOnSave": {
"source.fixAll.eslint": true
"source.fixAll.eslint": "explicit"
},
"editor.formatOnSave": false,
"typescript.implementationsCodeLens.enabled": true,
Expand Down
5 changes: 4 additions & 1 deletion bot/src/commands/fit/Activity.ts
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,10 @@ export const type = {
Crossfit: "Crossfit",
VirtualRide: "VirtualRide",
RockClimbing: "RockClimbing",
WeightTraining: "WeightTraining"
WeightTraining: "WeightTraining",
Pickleball: "Pickleball",
Golf: "Golf",
Swim: "Swim"
};

export const heartRate = (a: activity) : heartRate | null =>
Expand Down
9 changes: 9 additions & 0 deletions bot/src/commands/fit/WorkoutEmbed.ts
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,15 @@ const activityText = (activity: Activity.activity): string => {
case type.RockClimbing:
return `went rock climbing for ${elapsed}`;

case type.Golf:
return `walked ${distance} while playing golf`;

case type.Swim:
return `swam ${distance} in ${elapsed}`;

case type.Pickleball:
return `played pickleball for ${elapsed}`;

default:
return `worked out for ${elapsed}`;
}
Expand Down

0 comments on commit cc2943c

Please sign in to comment.