Fix: Parent portal language selector as dropdown instead of onboarding redirect
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -4,6 +4,7 @@ import React, { useState, useEffect } from 'react'
|
||||
import Link from 'next/link'
|
||||
import { useTheme } from '@/lib/ThemeContext'
|
||||
import { useLanguage } from '@/lib/LanguageContext'
|
||||
import type { Language } from '@/lib/i18n'
|
||||
|
||||
interface LearningUnit {
|
||||
id: string
|
||||
@@ -60,9 +61,19 @@ export default function ParentPage() {
|
||||
{t('greeting')}
|
||||
</p>
|
||||
</div>
|
||||
<Link href="/onboarding" className={`text-sm px-3 py-1.5 rounded-lg ${isDark ? 'bg-white/10 text-white/60' : 'bg-slate-100 text-slate-500'}`}>
|
||||
{language.toUpperCase()}
|
||||
</Link>
|
||||
<select
|
||||
value={language}
|
||||
onChange={(e) => setLanguage(e.target.value as Language)}
|
||||
className={`text-sm px-2 py-1.5 rounded-lg border-0 ${isDark ? 'bg-white/10 text-white/60' : 'bg-slate-100 text-slate-500'}`}
|
||||
>
|
||||
<option value="de">DE</option>
|
||||
<option value="tr">TR</option>
|
||||
<option value="ar">AR</option>
|
||||
<option value="uk">UK</option>
|
||||
<option value="ru">RU</option>
|
||||
<option value="pl">PL</option>
|
||||
<option value="en">EN</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user