mirror of
https://gitcode.com/gh_mirrors/hy/Hydro.git
synced 2026-10-20 01:38:19 +08:00
core: lang: add disabled option
This commit is contained in:
1 parent
2cd89d7258
commit
88461a78cd
3 files changed
+5
-2
No files matched your search
@@ -33,7 +33,8 @@ export function getAvailableLangs(langsList?: string[]) {
|
||||
for (const key in window.LANGS) {
|
||||
if (prefixes.has(key)) continue;
|
||||
if (langsList && langsList.length && langsList.join('') && !langsList.includes(key)) continue;
|
||||
else if (window.LANGS[key].hidden && !langsList?.includes(key)) continue;
|
||||
if (window.LANGS[key].hidden && !langsList?.includes(key)) continue;
|
||||
if (window.LANGS[key].disabled) continue;
|
||||
Langs[key] = window.LANGS[key];
|
||||
}
|
||||
return Langs;
|
||||
|
||||
Reference in new issue
Block a user