fosrl.pangolin/src/components/LocaleSwitcher.tsx

24 lines
446 B
TypeScript
Raw Normal View History

2025-05-04 16:35:43 +00:00
import { useLocale } from 'next-intl';
2025-05-04 15:11:42 +00:00
import LocaleSwitcherSelect from './LocaleSwitcherSelect';
export default function LocaleSwitcher() {
const locale = useLocale();
return (
<LocaleSwitcherSelect
defaultValue={locale}
items={[
{
value: 'en-US',
2025-05-04 16:35:43 +00:00
label: 'Englisch'
2025-05-04 15:11:42 +00:00
},
{
value: 'de-DE',
2025-05-04 16:35:43 +00:00
label: 'German'
2025-05-04 15:11:42 +00:00
}
]}
2025-05-04 16:35:43 +00:00
label='Language'
2025-05-04 15:11:42 +00:00
/>
);
}