mirror of
https://github.com/blitzkit/blitzkit.git
synced 2026-10-23 03:29:51 +02:00
feat: filter localizations
This commit is contained in:
1 parent
49d0dbe86d
commit
96a9e5b938
6 files changed
+65
-22
No files matched your search
@@ -27,7 +27,7 @@ export function translator(localeRaw: Locale) {
|
||||
console.warn(
|
||||
`Undefined translation at "${pathItem}" in "${path}" for locale "${locale}"; falling back to en-US`,
|
||||
);
|
||||
return translator(Locale.EnglishUS).translate(path);
|
||||
return translator(Locale.EnglishUS).translate(path, literals);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -51,6 +51,8 @@ export function translator(localeRaw: Locale) {
|
||||
if (index !== 0) embeddedString += literals[index - 1];
|
||||
embeddedString += chunk;
|
||||
});
|
||||
|
||||
return embeddedString;
|
||||
}
|
||||
|
||||
return resolvedString;
|
||||
|
||||
Reference in new issue
Block a user