Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
84 changes: 42 additions & 42 deletions components/SettingsModal.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -261,7 +261,7 @@ export default function SettingsModal({ visible, onClose, embedded = false }: Se

const renderContent = () => (
<View>
{/* DARSTELLUNG */}
{/* DARSTELLUNG: Design, Sound, Jubelmoment (Issue #336) */}
<Text style={[styles.sectionHeader, { color: colors.text.light }]}>
{t('settings.appearance')}
</Text>
Expand All @@ -278,24 +278,6 @@ export default function SettingsModal({ visible, onClose, embedded = false }: Se
v => handleThemeChange(v as 'light' | 'dark' | 'system'),
),
)}
<View style={[styles.row, styles.languageRow, { borderBottomColor: colors.border }]}>
<Text style={[styles.rowLabel, { color: colors.text.primary, marginBottom: Spacing.xs }]}>
{t('settings.language')}
</Text>
{renderSegment(
[
{ label: 'DE', value: 'de' },
{ label: 'EN', value: 'en' },
{ label: 'ES', value: 'es' },
{ label: 'FR', value: 'fr' },
{ label: 'IT', value: 'it' },
{ label: 'NL', value: 'nl' },
{ label: 'PL', value: 'pl' },
],
currentLang,
v => handleLanguageChange(v as Language),
)}
</View>
{renderRow(
t('settings.sound'),
renderSegment(
Expand All @@ -312,13 +294,46 @@ export default function SettingsModal({ visible, onClose, embedded = false }: Se
},
),
)}
{renderRow(
t('settings.celebration'),
renderSegment(
[
{ label: t('settings.soundOn'), value: 'on' },
{ label: t('settings.soundOff'), value: 'off' },
],
celebrationEnabled ? 'on' : 'off',
async v => {
const enabled = v === 'on';
setCelebrationEnabled(enabled);
await storageManager.setSetting('celebrationEnabled', enabled);
},
),
)}
</View>

{/* PERSONALISIEREN */}
{/* PERSONALISIEREN: Sprache, Altersstufe (Issue #336) */}
<Text style={[styles.sectionHeader, { color: colors.text.light }]}>
{t('settings.personalize')}
</Text>
<View style={[styles.card, { backgroundColor: colors.surface }]}>
<View style={[styles.row, styles.languageRow, { borderBottomColor: colors.border }]}>
<Text style={[styles.rowLabel, { color: colors.text.primary, marginBottom: Spacing.xs }]}>
{t('settings.language')}
</Text>
{renderSegment(
[
{ label: 'DE', value: 'de' },
{ label: 'EN', value: 'en' },
{ label: 'ES', value: 'es' },
{ label: 'FR', value: 'fr' },
{ label: 'IT', value: 'it' },
{ label: 'NL', value: 'nl' },
{ label: 'PL', value: 'pl' },
],
currentLang,
v => handleLanguageChange(v as Language),
)}
</View>
{renderRow(
t('ageGroup.settingsLabel'),
renderSegment(
Expand All @@ -331,41 +346,26 @@ export default function SettingsModal({ visible, onClose, embedded = false }: Se
v => handleAgeGroupChange(v as AgeGroup),
),
)}
{renderRow(
t('settings.celebration'),
renderSegment(
[
{ label: t('settings.soundOn'), value: 'on' },
{ label: t('settings.soundOff'), value: 'off' },
],
celebrationEnabled ? 'on' : 'off',
async v => {
const enabled = v === 'on';
setCelebrationEnabled(enabled);
await storageManager.setSetting('celebrationEnabled', enabled);
},
),
)}
</View>

{/* INFO & SUPPORT + DATEN */}
{/* ELTERNBEREICH: Eltern-Bereich, Trophäen, Feedback, Support, Teilen, Über, Zurücksetzen (Issue #336) */}
<Text style={[styles.sectionHeader, { color: colors.text.light }]}>
{t('settings.aboutSupport')}
{t('settings.parentArea')}
</Text>
<View style={[styles.card, { backgroundColor: colors.surface }]}>
<View style={styles.actionGrid}>
{(
[
{
id: 'trophies',
label: t('achievements.menuLabel'),
onPress: () => setShowBadgesModal(true),
},
{
id: 'parents',
label: t('parentDashboard.menuLabel'),
onPress: openParentDashboard,
},
{
id: 'trophies',
label: t('achievements.menuLabel'),
onPress: () => setShowBadgesModal(true),
},
{
id: 'feedback',
label: t('settings.feedback'),
Expand Down
1 change: 1 addition & 0 deletions locales/de/translations.json
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,7 @@
"browserErrorGeneric": "Browser konnte nicht geöffnet werden.",
"shareMessage": "Schau dir diese coole Gedächtnistraining-App an: Merke und Male! https://github.com/S540d/DrawFromMemory",
"aboutSupport": "Über & Support",
"parentArea": "Elternbereich",
"feedback": "Feedback",
"support": "Support",
"share": "Teilen",
Expand Down
1 change: 1 addition & 0 deletions locales/en/translations.json
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,7 @@
"browserErrorGeneric": "Could not open browser.",
"shareMessage": "Check out this cool memory training app: Remember & Draw! https://github.com/S540d/DrawFromMemory",
"aboutSupport": "About & Support",
"parentArea": "Parent Area",
"feedback": "Feedback",
"support": "Support",
"share": "Share",
Expand Down
1 change: 1 addition & 0 deletions locales/es/translations.json
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,7 @@
"browserErrorGeneric": "No se pudo abrir el navegador.",
"shareMessage": "Prueba esta genial app de entrenamiento de memoria: ¡Recuerda y Dibuja! https://github.com/S540d/DrawFromMemory",
"aboutSupport": "Acerca de y soporte",
"parentArea": "Área de padres",
"feedback": "Comentarios",
"support": "Soporte",
"share": "Compartir",
Expand Down
1 change: 1 addition & 0 deletions locales/fr/translations.json
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,7 @@
"browserErrorGeneric": "Impossible d'ouvrir le navigateur.",
"shareMessage": "Découvre cette super appli d'entraînement de la mémoire : Mémorise et Dessine ! https://github.com/S540d/DrawFromMemory",
"aboutSupport": "À propos et support",
"parentArea": "Espace parents",
"feedback": "Retour",
"support": "Soutien",
"share": "Partager",
Expand Down
1 change: 1 addition & 0 deletions locales/it/translations.json
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,7 @@
"browserErrorGeneric": "Impossibile aprire il browser.",
"shareMessage": "Prova questa fantastica app per allenare la memoria: Ricorda e Disegna! https://github.com/S540d/DrawFromMemory",
"aboutSupport": "Informazioni e supporto",
"parentArea": "Area genitori",
"feedback": "Feedback",
"support": "Supporto",
"share": "Condividi",
Expand Down
1 change: 1 addition & 0 deletions locales/nl/translations.json
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,7 @@
"browserErrorGeneric": "Kon browser niet openen.",
"shareMessage": "Bekijk deze leuke geheugentraining-app: Onthoud en Teken! https://github.com/S540d/DrawFromMemory",
"aboutSupport": "Over & ondersteuning",
"parentArea": "Ouderomgeving",
"feedback": "Feedback",
"support": "Ondersteuning",
"share": "Delen",
Expand Down
1 change: 1 addition & 0 deletions locales/pl/translations.json
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,7 @@
"browserErrorGeneric": "Nie można otworzyć przeglądarki.",
"shareMessage": "Sprawdź tę świetną aplikację do trenowania pamięci: Zapamiętaj i Rysuj! https://github.com/S540d/DrawFromMemory",
"aboutSupport": "O aplikacji i wsparcie",
"parentArea": "Strefa rodzica",
"feedback": "Opinia",
"support": "Wsparcie",
"share": "Udostępnij",
Expand Down
Loading