Refactor: Using English key (#728)

* fix: use english key instead of native

* fix: ukrainian

* fix: web test with new plugins map
This commit is contained in:
nyagami
2024-01-27 09:26:19 +07:00
committed by GitHub
parent 62fc988019
commit 6ff206eab3
5 changed files with 265 additions and 264 deletions
+2 -2
View File
@@ -21,7 +21,7 @@ export const all_plugins = (): PluginList => {
);
if (!fs.existsSync(langPath)) continue;
const plugins = fs.readdirSync(langPath);
res[languageNative] = [];
res[languageEnglish] = [];
plugins.forEach((plugin) => {
if (plugin.startsWith(".")) return;
const requirePath = `@plugins/${languageEnglish.toLowerCase()}/${
@@ -37,7 +37,7 @@ export const all_plugins = (): PluginList => {
requirePath,
icon,
}; // lang: language with native name
res[info.lang].push(info);
res[languageEnglish].push(info);
});
}
return res;