feat(localization): expand language support and enhance UI for user settings
All checks were successful
Deploy to production / deploy (push) Successful in 3m0s

- Added support for additional UI locales including Cebuano and Spanish, improving accessibility for a broader user base.
- Updated language selection components in the AppHeader and SettingsWidget to reflect new language options, enhancing user experience.
- Enhanced localization of various UI elements across components, ensuring consistent language representation and improved user engagement.
- Implemented logic to synchronize user language preferences with backend settings, providing a seamless experience when changing languages.
This commit is contained in:
Torsten Schulz (local)
2026-04-02 07:54:44 +02:00
parent ac5d436a36
commit 6d9d69dc10
72 changed files with 1792 additions and 343 deletions

View File

@@ -1,10 +1,10 @@
<template>
<div class="termine-widget">
<h2>📅 Termine</h2>
<div v-if="loading" class="loading">Lade Termine...</div>
<h2>{{ $t('widgets.appointments.title') }}</h2>
<div v-if="loading" class="loading">{{ $t('widgets.appointments.loading') }}</div>
<div v-else-if="error" class="error">{{ error }}</div>
<div v-else-if="termine.length === 0" class="no-termine">
Keine bevorstehenden Termine
{{ $t('widgets.appointments.empty') }}
</div>
<div v-else class="termine-list">
<div v-for="termin in termine" :key="termin.datum + termin.titel" class="termin-item">
@@ -50,7 +50,7 @@ export default {
this.termine = response.data;
} catch (error) {
console.error('Error loading termine:', error);
this.error = 'Termine konnten nicht geladen werden';
this.error = this.$t('widgets.appointments.loadError');
} finally {
this.loading = false;
}
@@ -64,7 +64,16 @@ export default {
month: 'long',
day: 'numeric'
};
return date.toLocaleDateString('de-DE', options);
return date.toLocaleDateString(this.getDateLocale(), options);
},
getDateLocale() {
const locale = this.$i18n?.locale;
return {
de: 'de-DE',
en: 'en-GB',
es: 'es-ES',
ceb: 'fil-PH'
}[locale] || 'de-DE';
}
}
};