fix: dates follow the UI language, not the browser's

Seven sites formatted with a bare toLocaleString()/toLocaleDateString(), so an
English UI on a Hungarian machine printed Hungarian-shaped dates (and the reverse).
They now go through formatDateTime/formatDate, which take the i18n language.
This commit is contained in:
2026-09-16 00:49:23 +02:00
parent e299c66121
commit 618ef812e6
4 changed files with 21 additions and 9 deletions
+2 -1
View File
@@ -4,13 +4,14 @@ import { useTranslation } from "react-i18next";
import { Info, Sparkles } from "lucide-react";
import { api } from "../lib/api";
import { FRONTEND_VERSION, FRONTEND_SHA, FRONTEND_BUILD_DATE } from "../lib/version";
import { formatDateTime } from "../lib/format";
import { Button } from "./ui/Button";
import Modal from "./ui/Modal";
function fmtDate(d?: string | null): string {
if (!d) return "—";
const t = new Date(d);
return isNaN(t.getTime()) ? d : t.toLocaleString();
return isNaN(t.getTime()) ? d : formatDateTime(d);
}
// About dialog: app + build + schema versions (frontend/backend/database), plus a