|
@@ -10,7 +10,7 @@ type NavItem = {
|
|
|
key: 'chat' | 'groups' | 'files'
|
|
key: 'chat' | 'groups' | 'files'
|
|
|
label: string
|
|
label: string
|
|
|
path: string
|
|
path: string
|
|
|
- icon: 'chat' | 'groups' | 'files'
|
|
|
|
|
|
|
+ icon: 'bots' | 'groups' | 'files'
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
const SIDEBAR_COLLAPSED_KEY = 'hermes-yaoyao:sidebar-collapsed'
|
|
const SIDEBAR_COLLAPSED_KEY = 'hermes-yaoyao:sidebar-collapsed'
|
|
@@ -61,7 +61,7 @@ const desktopSidebarContext = ref<HTMLElement | null>(null)
|
|
|
const mobileSidebarContext = ref<HTMLElement | null>(null)
|
|
const mobileSidebarContext = ref<HTMLElement | null>(null)
|
|
|
|
|
|
|
|
const navItems: NavItem[] = [
|
|
const navItems: NavItem[] = [
|
|
|
- { key: 'chat', label: '对话', path: '/chat', icon: 'chat' },
|
|
|
|
|
|
|
+ { key: 'chat', label: '对话', path: '/chat', icon: 'bots' },
|
|
|
{ key: 'groups', label: '群聊', path: '/groups', icon: 'groups' },
|
|
{ key: 'groups', label: '群聊', path: '/groups', icon: 'groups' },
|
|
|
{ key: 'files', label: '文件库', path: '/files', icon: 'files' },
|
|
{ key: 'files', label: '文件库', path: '/files', icon: 'files' },
|
|
|
]
|
|
]
|
|
@@ -99,8 +99,8 @@ function toggleSidebar() {
|
|
|
try { localStorage.setItem(SIDEBAR_COLLAPSED_KEY, sidebarCollapsed.value ? '1' : '0') } catch { /* optional persistence */ }
|
|
try { localStorage.setItem(SIDEBAR_COLLAPSED_KEY, sidebarCollapsed.value ? '1' : '0') } catch { /* optional persistence */ }
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
-function navIcon(key: NavItem['key']): 'chat' | 'folder' | 'people' {
|
|
|
|
|
- return key === 'groups' ? 'people' : key === 'files' ? 'folder' : 'chat'
|
|
|
|
|
|
|
+function navIcon(key: NavItem['key']): 'bots' | 'folder' | 'people' {
|
|
|
|
|
+ return key === 'groups' ? 'people' : key === 'files' ? 'folder' : 'bots'
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
async function openSidebarSearch(host: HTMLElement | null) {
|
|
async function openSidebarSearch(host: HTMLElement | null) {
|