fix: remove hardcoded locales from UI formatting
All checks were successful
CI / build (push) Successful in 1m21s
CI / cleanup-branch (push) Has been skipped
CI / docker (push) Successful in 52s
CI / deploy (push) Successful in 37s
CI / deploy-feature (push) Has been skipped

Use browser default locale instead of hardcoded 'en-US' and 'en-GB'
for number and time formatting.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
hsiegeln
2026-03-23 21:44:16 +01:00
parent ea56bcf2d7
commit 6b750df1c4
2 changed files with 5 additions and 5 deletions

View File

@@ -114,7 +114,7 @@ export default function Dashboard() {
<div className={styles.healthStrip}>
<StatCard
label="Exchanges"
value={totalCount.toLocaleString('en-US')}
value={totalCount.toLocaleString()}
detail={`${successRate.toFixed(1)}% success rate`}
trend={exchangeTrend > 0 ? 'up' : exchangeTrend < 0 ? 'down' : 'neutral'}
trendValue={exchangeTrend > 0 ? `+${exchangeTrend.toFixed(0)}%` : `${exchangeTrend.toFixed(0)}%`}
@@ -124,7 +124,7 @@ export default function Dashboard() {
<StatCard
label="Success Rate"
value={`${successRate.toFixed(1)}%`}
detail={`${(totalCount - failedCount).toLocaleString('en-US')} ok / ${failedCount} error`}
detail={`${(totalCount - failedCount).toLocaleString()} ok / ${failedCount} error`}
trend={successRateDelta >= 0 ? 'up' : 'down'}
trendValue={`${successRateDelta >= 0 ? '+' : ''}${successRateDelta.toFixed(1)}%`}
accent="success"
@@ -147,8 +147,8 @@ export default function Dashboard() {
/>
<StatCard
label="Latency p99"
value={(stats?.p99LatencyMs ?? 0).toLocaleString('en-US')}
detail={`${(stats?.p99LatencyMs ?? 0).toLocaleString('en-US')}ms`}
value={(stats?.p99LatencyMs ?? 0).toLocaleString()}
detail={`${(stats?.p99LatencyMs ?? 0).toLocaleString()}ms`}
sparkline={sparkLatency}
accent="warning"
/>

View File

@@ -131,7 +131,7 @@ export default function ExchangeDetail() {
<div className={styles.headerStat}>
<div className={styles.headerStatLabel}>Started</div>
<div className={styles.headerStatValue}>
{detail.startTime ? new Date(detail.startTime).toLocaleTimeString('en-GB', { hour: '2-digit', minute: '2-digit', second: '2-digit' }) : '—'}
{detail.startTime ? new Date(detail.startTime).toLocaleTimeString([], { hour: '2-digit', minute: '2-digit', second: '2-digit' }) : '—'}
</div>
</div>
<div className={styles.headerStat}>