fix(deps): update dependency typescript-eslint to v8 (#896)

* fix(deps): update dependency typescript-eslint to v8

* fix: lint issues

* fix: more lint issues

---------

Co-authored-by: homarr-renovate[bot] <158783068+homarr-renovate[bot]@users.noreply.github.com>
Co-authored-by: Meier Lukas <meierschlumpf@gmail.com>
This commit is contained in:
homarr-renovate[bot]
2024-08-01 10:13:12 +02:00
committed by GitHub
parent 1811e1de79
commit a9a46024e2
12 changed files with 124 additions and 99 deletions

View File

@@ -1,15 +1,16 @@
import { supportedLanguages } from ".";
const enTranslations = () => import("./lang/en");
const _enTranslations = () => import("./lang/en");
type EnTranslation = typeof _enTranslations;
export const languageMapping = () => {
const mapping: Record<string, unknown> = {};
for (const language of supportedLanguages) {
mapping[language] = () => import(`./lang/${language}`) as ReturnType<typeof enTranslations>;
mapping[language] = () => import(`./lang/${language}`) as ReturnType<EnTranslation>;
}
return mapping as Record<(typeof supportedLanguages)[number], () => ReturnType<typeof enTranslations>>;
return mapping as Record<(typeof supportedLanguages)[number], () => ReturnType<EnTranslation>>;
};
type NestedKeyOf<ObjectType extends object> = {
@@ -18,4 +19,4 @@ type NestedKeyOf<ObjectType extends object> = {
: `${Key}`;
}[keyof ObjectType & (string | number)];
export type TranslationKeys = NestedKeyOf<typeof enTranslations>;
export type TranslationKeys = NestedKeyOf<EnTranslation>;

View File

@@ -506,6 +506,7 @@ export default {
symbols: {
colon: ": ",
},
error: "Error",
action: {
add: "Add",
apply: "Apply",