feat(budget): configurable currency in settings (#20)

Add household-wide currency preference for the budget section.
Users can select from 13 currencies (EUR, USD, GBP, SEK, NOK, DKK,
CHF, PLN, CZK, HUF, JPY, AUD, CAD) in Settings → Budget.

- preferences API (GET/PUT) now includes currency field
- budget page loads currency from preferences on render
- formatAmount() uses locale-aware Intl.NumberFormat with chosen currency
- settings page gains a Budget section with a currency select
- all three locales (de, en, it) updated with new i18n keys
This commit is contained in:
Ulas
2026-04-05 11:55:38 +02:00
parent 212a8bdb0a
commit 446b9b1388
8 changed files with 98 additions and 17 deletions
+6 -2
View File
@@ -418,7 +418,7 @@
"typeIncome": "Einnahme",
"titleLabel": "Titel *",
"titlePlaceholder": "z.B. REWE Einkauf",
"amountLabel": "Betrag (€) *",
"amountLabel": "Betrag *",
"amountPlaceholder": "0,00",
"categoryLabel": "Kategorie",
"dateLabel": "Datum *",
@@ -518,7 +518,11 @@
"mealTypesLabel": "Sichtbare Mahlzeiten",
"mealTypesHint": "Nur ausgewaehlte Mahlzeit-Typen werden im Essensplan angezeigt.",
"mealTypesSaved": "Essensplan-Einstellungen gespeichert.",
"mealTypesMinOne": "Mindestens ein Mahlzeit-Typ muss aktiv sein."
"mealTypesMinOne": "Mindestens ein Mahlzeit-Typ muss aktiv sein.",
"sectionBudget": "Budget",
"currencyLabel": "Währung",
"currencyHint": "Legt die Währung für den gesamten Budget-Bereich fest.",
"currencySaved": "Währung gespeichert."
},
"login": {
+6 -2
View File
@@ -418,7 +418,7 @@
"typeIncome": "Income",
"titleLabel": "Title *",
"titlePlaceholder": "e.g. Supermarket",
"amountLabel": "Amount (€) *",
"amountLabel": "Amount *",
"amountPlaceholder": "0.00",
"categoryLabel": "Category",
"dateLabel": "Date *",
@@ -518,7 +518,11 @@
"mealTypesLabel": "Visible meals",
"mealTypesHint": "Only selected meal types are shown in the meal planner.",
"mealTypesSaved": "Meal plan settings saved.",
"mealTypesMinOne": "At least one meal type must be active."
"mealTypesMinOne": "At least one meal type must be active.",
"sectionBudget": "Budget",
"currencyLabel": "Currency",
"currencyHint": "Sets the currency used throughout the budget section.",
"currencySaved": "Currency saved."
},
"login": {
+6 -2
View File
@@ -418,7 +418,7 @@
"typeIncome": "Entrata",
"titleLabel": "Titolo *",
"titlePlaceholder": "es. Supermercato",
"amountLabel": "Importo (€) *",
"amountLabel": "Importo *",
"amountPlaceholder": "0,00",
"categoryLabel": "Categoria",
"dateLabel": "Data *",
@@ -518,7 +518,11 @@
"mealTypesLabel": "Pasti visibili",
"mealTypesHint": "Solo i tipi di pasto selezionati vengono mostrati nel piano pasti.",
"mealTypesSaved": "Impostazioni del piano pasti salvate.",
"mealTypesMinOne": "Almeno un tipo di pasto deve essere attivo."
"mealTypesMinOne": "Almeno un tipo di pasto deve essere attivo.",
"sectionBudget": "Bilancio",
"currencyLabel": "Valuta",
"currencyHint": "Imposta la valuta utilizzata in tutta la sezione budget.",
"currencySaved": "Valuta salvata."
},
"login": {