1
0
Fork 0
mirror of https://github.com/mealie-recipes/mealie.git synced 2025-07-29 18:19:41 +02:00

fix: RTL Settings Ignored (#5762)

This commit is contained in:
Michael Genson 2025-07-21 02:51:28 -05:00 committed by GitHub
parent a1a45078fb
commit 00a03559ff
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
6 changed files with 126 additions and 148 deletions

View file

@ -7,13 +7,14 @@
<v-card-text>
{{ $t("language-dialog.select-description") }}
<v-autocomplete
v-model="locale"
v-model="selectedLocale"
:items="locales"
item-title="name"
item-value="value"
class="my-3"
hide-details
variant="outlined"
offset
@update:model-value="onLocaleSelect"
>
<template #item="{ item, props }">
<div
@ -59,6 +60,14 @@ export default defineNuxtComponent({
});
const { locales: LOCALES, locale, i18n } = useLocales();
const selectedLocale = ref(locale.value);
const onLocaleSelect = (value: string) => {
if (value && locales.some(l => l.value === value)) {
locale.value = value as any;
}
};
watch(locale, () => {
dialog.value = false; // Close dialog when locale changes
});
@ -72,6 +81,8 @@ export default defineNuxtComponent({
i18n,
locales,
locale,
selectedLocale,
onLocaleSelect,
};
},
});