0
1
Fork 0

feat: langs button

This commit is contained in:
Javier Segarra 2024-07-26 22:05:01 +02:00
parent 34a0d93ece
commit e067f5f7bd
2 changed files with 32 additions and 3 deletions

View File

@ -12,6 +12,15 @@ export default {
today: 'Hoy',
yesterday: 'Ayer',
tomorrow: 'Mañana',
language: 'Idioma',
langs: {
en: 'Inglés',
es: 'Español',
ca: 'Catalán',
fr: 'Francés',
mn: 'Ruso',
pt: 'Portugés'
},
date: {
days: [
'Domingo',

View File

@ -15,6 +15,7 @@ const password = ref(null);
const remember = ref(false);
const showPwd = ref(false);
const langs = ['en', 'es', 'ca', 'fr', 'mn', 'pt'];
onMounted(() => {
if (route.query.emailConfirmed !== undefined) {
notify({
@ -56,12 +57,31 @@ async function onLogin() {
/>
</template>
</QInput>
<QCheckbox
<div class=" text-center"> <QCheckbox
v-model="remember"
:label="$t('remindMe')"
class="remember"
dense
/>
/> <QBtn
id="switchLanguage"
:label="$t('language')"
icon="translate"
color="primary"
size="sm"
flat
rounded
>
<QMenu auto-close>
<QList dense v-for="lang in langs" :key="lang">
<QItem
disabled
v-ripple
clickable
>
{{ $t(`langs.${lang}`) }}
</QItem>
</QList>
</QMenu>
</QBtn></div>
</div>
<div class="justify-center">
<QBtn