mirror of
https://github.com/blakeblackshear/frigate.git
synced 2026-08-12 13:51:12 +03:00
Fixes (#18877)
* Object labels with spaces should use correct i18n keys * Add Hungarian * Ensure onvif move request has a valid speed before removing When autotracking zooming is set to `disabled` (or is left out of the config), move_request["Speed"] may not exist, depending on the camera * Add another frame cache debug log
This commit is contained in:
@@ -1,7 +1,13 @@
|
||||
import i18n from "i18next";
|
||||
import i18n, { t } from "i18next";
|
||||
import { initReactI18next } from "react-i18next";
|
||||
import HttpBackend from "i18next-http-backend";
|
||||
|
||||
export const getTranslatedLabel = (label: string) => {
|
||||
if (!label) return "";
|
||||
|
||||
return t(`${label.replace(/\s+/g, "_").toLowerCase()}`, { ns: "objects" });
|
||||
};
|
||||
|
||||
i18n
|
||||
.use(initReactI18next)
|
||||
.use(HttpBackend)
|
||||
|
||||
Reference in New Issue
Block a user