Changed the trim of the distance

Changed the trimming (switching between meters and kilometers) of the distance from 10K to 100K, similar to the PM5 and convention of other rowing machines.
This commit is contained in:
Jaap van Ekris 2023-04-19 23:42:51 +02:00 committed by GitHub
parent 78f6275846
commit d852ef8439
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -41,7 +41,7 @@ export function secondsToPace (seconds) {
* @param {number} value The distance in meters.
*/
export function formatDistance (value) {
return value >= 10000
return value >= 99999.5
? { distance: formatNumber((value / 1000), 2), unit: 'km' }
: { distance: formatNumber(value), unit: 'm' }
}