aboutsummaryrefslogtreecommitdiffstats
path: root/android/gradle
diff options
context:
space:
mode:
Diffstat (limited to 'android/gradle')
0 files changed, 0 insertions, 0 deletions
ble>
path: root/src/components/LocaleSelector.svelte
blob: a7966977255c455e3dcb4d209a49538a74dfe170 (plain) (tree)
1
2
3
4
5
6
7
8
9
10
11
        

                                                         
 
                 
 




                                               

         
                                                                              


                                                          
         

       




                             
        
<script>
  import { t, locale, locales } from "$lib/translations";
  export let style;

  $: l = $locale;

  const handleChange = ({ currentTarget }) => {
    const { value } = currentTarget;
    document.cookie = `lang=${value}; path=/`;
    $locale = value;
  };
</script>

<select name="language" bind:value={l} class={style} on:change={handleChange}>
  {#each $locales as locale}
    <option value={locale}>{$t(`lang.${locale}`)}</option>
  {/each}
</select>

<style>
  select {
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
  }
</style>