Convert units for distance data in WorkoutChart
This commit is contained in:
parent
dd40fd7154
commit
7f3cf4f4b7
@ -36,7 +36,9 @@ export const getDatasets = (
|
|||||||
const coordinates: TCoordinates[] = []
|
const coordinates: TCoordinates[] = []
|
||||||
|
|
||||||
chartData.map((data) => {
|
chartData.map((data) => {
|
||||||
distance_labels.push(data.distance)
|
distance_labels.push(
|
||||||
|
convertStatsDistance('km', data.distance, useImperialUnits)
|
||||||
|
)
|
||||||
duration_labels.push(data.duration)
|
duration_labels.push(data.duration)
|
||||||
datasets.speed.data.push(
|
datasets.speed.data.push(
|
||||||
convertStatsDistance('km', data.speed, useImperialUnits)
|
convertStatsDistance('km', data.speed, useImperialUnits)
|
||||||
|
Loading…
Reference in New Issue
Block a user