From a9c8b1b6c513257a5fd69cf00992d4fec59d6069 Mon Sep 17 00:00:00 2001 From: Anton Tananaev Date: Sun, 6 Nov 2022 17:00:03 -0800 Subject: Respect 12 hour time --- modern/src/common/components/PositionValue.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'modern/src/common/components/PositionValue.js') diff --git a/modern/src/common/components/PositionValue.js b/modern/src/common/components/PositionValue.js index a851c886..27f793c6 100644 --- a/modern/src/common/components/PositionValue.js +++ b/modern/src/common/components/PositionValue.js @@ -24,13 +24,14 @@ const PositionValue = ({ position, property, attribute }) => { const altitudeUnit = useAttributePreference('altitudeUnit'); const speedUnit = useAttributePreference('speedUnit'); const coordinateFormat = usePreference('coordinateFormat'); + const hours12 = usePreference('twelveHourFormat'); const formatValue = () => { switch (key) { case 'fixTime': case 'deviceTime': case 'serverTime': - return formatTime(value); + return formatTime(value, 'seconds', hours12); case 'latitude': return formatCoordinate('latitude', value, coordinateFormat); case 'longitude': -- cgit v1.2.3