Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

workout type golfing added #126

Merged
merged 5 commits into from
Apr 18, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions assets/output.css
Original file line number Diff line number Diff line change
Expand Up @@ -2531,6 +2531,14 @@ table {
content: "\f09b";
}

.icon-golf-ball-tee::before {
content: "\f450";
}

.icon-golf-ball-tee::after {
content: "\f450";
}

.icon-hourglass::before {
content: "\f254";
}
Expand Down
5 changes: 3 additions & 2 deletions pkg/database/workout_type.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,14 +16,15 @@ const (
WorkoutTypeSnowboarding WorkoutType = "snowboarding"
WorkoutTypeSwimming WorkoutType = "swimming"
WorkoutTypeKayaking WorkoutType = "kayaking"
WorkoutTypeGolfing WorkoutType = "golfing"
)

func WorkoutTypes() []WorkoutType {
return []WorkoutType{WorkoutTypeRunning, WorkoutTypeCycling, WorkoutTypeWalking, WorkoutTypeSkiing, WorkoutTypeSnowboarding, WorkoutTypeSwimming, WorkoutTypeKayaking}
return []WorkoutType{WorkoutTypeRunning, WorkoutTypeCycling, WorkoutTypeWalking, WorkoutTypeSkiing, WorkoutTypeSnowboarding, WorkoutTypeSwimming, WorkoutTypeKayaking, WorkoutTypeGolfing}
}

func DistanceWorkoutTypes() []WorkoutType {
jovandeginste marked this conversation as resolved.
Show resolved Hide resolved
return []WorkoutType{WorkoutTypeRunning, WorkoutTypeCycling, WorkoutTypeWalking, WorkoutTypeSkiing, WorkoutTypeSnowboarding, WorkoutTypeSwimming, WorkoutTypeKayaking}
return []WorkoutType{WorkoutTypeRunning, WorkoutTypeCycling, WorkoutTypeWalking, WorkoutTypeSkiing, WorkoutTypeSnowboarding, WorkoutTypeSwimming, WorkoutTypeKayaking, WorkoutTypeGolfing}
}

func (wt WorkoutType) String() string {
Expand Down
2 changes: 2 additions & 0 deletions pkg/database/workouts.go
Original file line number Diff line number Diff line change
Expand Up @@ -124,6 +124,8 @@ func workoutTypeFromGpxTrackType(gpxType string) (WorkoutType, bool) {
return WorkoutTypeSwimming, true
case "kayaking":
return WorkoutTypeKayaking, true
case "golfing":
return WorkoutTypeGolfing, true
default:
return WorkoutTypeAutoDetect, false
}
Expand Down
2 changes: 2 additions & 0 deletions pkg/templatehelpers/icons.go
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,8 @@ func sportIcon(what string) string {
return iconDefaults + " icon-solid icon-person-skiing"
case "snowboarding":
return iconDefaults + " icon-solid icon-person-snowboarding"
case "golfing":
return iconDefaults + " icon-solid icon-golf-ball-tee"
case "kayaking":
return iconDefaults + " icon-solid icon-sailboat"
default:
Expand Down
5 changes: 3 additions & 2 deletions translations/de.json
Original file line number Diff line number Diff line change
Expand Up @@ -96,9 +96,10 @@
"environment variables": "environment variables",
"feet": "feet",
"generate a new API key": "Neuen API-Schlüssel generieren",
"golfing": "Golfen",
"how to use": "Hilfe",
"kilometers": "Kilometer",
"kilometers per hour": "Kilometers pro Stunde",
"kilometers per hour": "Kilometer pro Stunde",
"meters": "Meter",
"miles": "Meilen",
"miles per hour": "Meilen pro Stunde",
Expand All @@ -108,7 +109,7 @@
"show/hide": "Anzeigen/Verbergen",
"skiing": "Skifahren",
"snowboarding": "Snowboarden",
"swimming": "schwimmen",
"swimming": "Schwimmen",
"the configuration file": "Konfigurationsdatei",
"up": "Höhenmeter",
"user": "Benutzer",
Expand Down
1 change: 1 addition & 0 deletions translations/messages.json
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,7 @@
"environment variables": "environment variables",
"feet": "feet",
"generate a new API key": "generate a new API key",
"golfing": "golfing",
"how to use": "how to use",
"kilometers": "kilometers",
"kilometers per hour": "kilometers per hour",
Expand Down
1 change: 1 addition & 0 deletions translations/nl.json
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,7 @@
"environment variables": "omgevingsvariabelen",
"feet": "voet",
"generate a new API key": "maak een nieuwe API-sleutel",
"golfing": "golfing",
"how to use": "hoe te gebruiken",
"kilometers": "kilometers",
"kilometers per hour": "kilometers per uur",
Expand Down
1 change: 1 addition & 0 deletions views/partials/messages.html
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
{{ i18n "sailboat" }}
{{ i18n "skiing" }}
{{ i18n "snowboarding" }}
{{ i18n "golfing" }}
{{ i18n "swimming" }}
{{ i18n "walking" }}
</pre>
Loading