-
Notifications
You must be signed in to change notification settings - Fork 66
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(App.vue): update locale select options to display language names…
… instead of locale codes feat(language.ts): add sortedLocales function to sort locales alphabetically
- Loading branch information
Showing
3 changed files
with
73 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
const languageMap: Record<string, string> = { | ||
bg: 'Bulgarian', | ||
cs: 'Czech', | ||
da: 'Danish', | ||
de: 'German', | ||
el: 'Greek', | ||
en: 'English', | ||
es: 'Spanish', | ||
et: 'Estonian', | ||
fi: 'Finnish', | ||
fr: 'French', | ||
hu: 'Hungarian', | ||
id: 'Indonesian', | ||
it: 'Italian', | ||
ja: 'Japanese', | ||
ko: 'Korean', | ||
lt: 'Lithuanian', | ||
lv: 'Latvian', | ||
nb: 'Norwegian Bokmål', | ||
nl: 'Dutch', | ||
pl: 'Polish', | ||
ptBR: 'Portuguese (Brazil)', | ||
ptPT: 'Portuguese (Portugal)', | ||
ro: 'Romanian', | ||
ru: 'Russian', | ||
sk: 'Slovak', | ||
sl: 'Slovenian', | ||
sv: 'Swedish', | ||
tr: 'Turkish', | ||
uk: 'Ukrainian', | ||
zh: 'Chinese' | ||
} | ||
export const sortedLocales = Object.keys(languageMap).sort((a, b) => { | ||
return languageMap[a].localeCompare(languageMap[b]); | ||
}); |