Fix: Cast language selection to Language type

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
Benjamin Admin
2026-04-25 20:30:11 +02:00
parent d4959172a9
commit d87645ffce

View File

@@ -4,6 +4,7 @@ import React, { useState, useEffect } from 'react'
import { useRouter } from 'next/navigation'
import { useTheme } from '@/lib/ThemeContext'
import { useLanguage } from '@/lib/LanguageContext'
import type { Language } from '@/lib/i18n'
interface LangOption {
code: string
@@ -63,7 +64,7 @@ export default function OnboardingPage() {
// Save locally + set UI language
localStorage.setItem(STORAGE_KEY, selected)
setLanguage(selected)
setLanguage(selected as Language)
// Navigate
if (role === 'parent') {