| | |
| | | import { currentPage } from '../../lib/stores/app' |
| | | import { t } from '../../lib/i18n' |
| | | import GeneralPage from './GeneralPage.svelte' |
| | | import PermissionsPage from './PermissionsPage.svelte' |
| | | import HistoryPage from './HistoryPage.svelte' |
| | | import UserDictPage from './UserDictPage.svelte' |
| | | import AboutPage from './AboutPage.svelte' |
| | |
| | | const navItems = [ |
| | | { id: 'general', label: () => t('nav.home') }, |
| | | { id: 'userdict', label: () => t('nav.userdict') }, |
| | | { id: 'permissions', label: () => t('nav.permissions') }, |
| | | { id: 'history', label: () => t('nav.history') }, |
| | | { id: 'about', label: () => t('nav.about') }, |
| | | ] |
| | |
| | | <path d="M3 12.5h5"/> |
| | | <path d="M11 11l1.2 1.2L14.5 10"/> |
| | | </svg> |
| | | {:else if item.id === 'permissions'} |
| | | <svg width="16" height="16" viewBox="0 0 16 16" fill="none" stroke="currentColor" stroke-width="1.3" stroke-linecap="round" stroke-linejoin="round"> |
| | | <path d="M8 2L3.5 4v3.2c0 2.9 1.8 5.1 4.5 6.3 2.7-1.2 4.5-3.4 4.5-6.3V4L8 2Z"/> |
| | | <path d="M5.8 7.9l1.4 1.4 3-3.2"/> |
| | | </svg> |
| | | {:else if item.id === 'about'} |
| | | <svg width="16" height="16" viewBox="0 0 16 16" fill="none" stroke="currentColor" stroke-width="1.3" stroke-linecap="round"> |
| | | <circle cx="8" cy="8" r="6"/> |
| | |
| | | <GeneralPage /> |
| | | {:else if page === 'userdict'} |
| | | <UserDictPage /> |
| | | {:else if page === 'permissions'} |
| | | <PermissionsPage /> |
| | | {:else if page === 'history'} |
| | | <HistoryPage /> |
| | | {:else if page === 'about'} |