feat: show local weather warnings on dashboard

This commit is contained in:
zv
2026-06-02 21:15:14 +02:00
parent 99282c5280
commit 7dcfc47375
7 changed files with 165 additions and 4 deletions

View File

@@ -128,6 +128,10 @@ export function normalizeProvinceName(value: string | null | undefined) {
return value ? provinceBySimplifiedName[simplifyProvinceName(value)] ?? null : null;
}
export function getProvinceForSelection(locationProvince: string | null | undefined, stationId: string | null) {
return normalizeProvinceName(locationProvince) ?? getProvinceForStation(stationId);
}
export function formatProvinceName(province: Province, language: Language) {
return provinceLabels[province][language];
}