Skip to content

Commit

Permalink
#425 improve lang dispaly
Browse files Browse the repository at this point in the history
  • Loading branch information
ab-smith committed May 14, 2024
1 parent 319266c commit 05ba27e
Showing 1 changed file with 10 additions and 3 deletions.
13 changes: 10 additions & 3 deletions frontend/src/lib/components/SideBar/SideBarFooter.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,13 @@
const modalStore = getModalStore();
const defaultLangLabels = {
fr: 'Français',
en: 'English',
ar: 'العربية',
pt: 'Português'
};
let value = languageTag();
async function handleLocaleChange(event: Event) {
Expand Down Expand Up @@ -85,9 +92,9 @@
data-testid="language-select"
>
{#each availableLanguageTags as lang}
<option value={lang} selected={lang === languageTag()}
>{LOCALE_MAP[lang].flag} {language[LOCALE_MAP[lang].name]}</option
>
<option value={lang} selected={lang === languageTag()}>
{defaultLangLabels[lang]} ({language[LOCALE_MAP[lang].name]})
</option>
{/each}
</select>
<button
Expand Down

0 comments on commit 05ba27e

Please sign in to comment.