fix(i18n): Google controls, vessel units and counts follow the UI language

Screens that only open with provider keys showed a few gaps:

- Google Street View's own controls (Map Data, Terms, Report a problem)
  and its addresses were always English: the Maps script now loads with
  the UI language. English adds no parameter, as before.
- The selected-vessel HUD line kept KT and DEG after translated labels.
- Layer counts used a decimal point (12.0K); other languages use their
  own separator (12,0K).
- A collapsed rail title was cut with an ellipsis in Russian; tighter
  tracking fits it whole. English is unchanged.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
This commit is contained in:
German KhokhlovandClaude Opus 5.5 committed 2026-10-13 23:11:37 +04:00
1 parent 7db0abc396
commit 03207ca0fc
8 files changed
+47 -11

No files matched your search

+7 -2
View File
@@ -5,7 +5,7 @@ export { layerFeedState } from '../data/feedState.js';
import { GUIDANCE_STATUSES } from '../loadingFeedback.js';
import { keyGuidanceText, keyRequirementText } from './keyGuidance.js';
import { createWeatherPanel } from './weatherPanel.js';
import { msg, t, translateKnown } from '../i18n/index.js';
import { formatNumber, msg, t, translateKnown } from '../i18n/index.js';
// Feed-state enum VALUES are machine identifiers (layerFeedState contract, QA
// hooks, CSS feed-* classes); only the final label value translates, at this
@@ -891,7 +891,12 @@ export class LayerPanel {
}
_formatCount(n) {
if (n >= 1000) return `${(n / 1000).toFixed(1)}K`;
if (n >= 1000)
return `${formatNumber(n / 1000, {
minimumFractionDigits: 1,
maximumFractionDigits: 1,
useGrouping: false,
})}K`;
return String(n);
}