'use client' import { sel } from '@nextsparkjs/core/selectors' import { useTranslations } from 'next-intl' import Link from 'next/link' import { useMemo } from 'react' import { getEnabledSettingsPages } from '@nextsparkjs/core/lib/config' import { User, Lock, Shield, Bell, CreditCard, Key, type LucideIcon } from 'lucide-react' import { getTemplateOrDefaultClient } from '@nextsparkjs/registries/template-registry.client' // Icon mapping for settings pages const SETTINGS_ICONS: Record = { profile: User, password: Lock, security: Shield, notifications: Bell, 'api-keys': Key, billing: CreditCard, } function SettingsPage() { const t = useTranslations('settings') // Get enabled settings pages from config const enabledPages = useMemo(() => { return getEnabledSettingsPages() }, []) return (

{t('overview.title')}

{t('overview.description')}

{enabledPages.map((page) => { const Icon = SETTINGS_ICONS[page.key] || User return (

{t(`navigation.${page.key}`)}

{t(`overview.${page.key}Description`)}

) })}
) } export default getTemplateOrDefaultClient('app/dashboard/settings/page.tsx', SettingsPage)