托盘调整
This commit is contained in:
+7
-1
@@ -16,7 +16,7 @@ window.addEventListener('unhandledrejection', (event) => {
|
||||
})
|
||||
|
||||
// ===== OSD 窗口模式检测 =====
|
||||
// 通过 URL hash 识别:#osd-overlay(悬浮窗)/ #clipboard-popup(剪贴板快捷弹窗)
|
||||
// 通过 URL hash 识别:#osd-overlay(悬浮窗)/ #clipboard-popup(剪贴板快捷弹窗)/ #tray-menu(托盘菜单)
|
||||
// 这些窗口是精简的独立 Vue 应用,不加载主应用的 store 和模块
|
||||
const winHash = window.location.hash
|
||||
if (winHash === '#osd-overlay') {
|
||||
@@ -31,6 +31,12 @@ if (winHash === '#osd-overlay') {
|
||||
const app = createApp(ClipboardPopup)
|
||||
app.mount('#app')
|
||||
})
|
||||
} else if (winHash === '#tray-menu') {
|
||||
logger.info(`托盘菜单窗口启动: ${winHash}`)
|
||||
void import('./modules/tray/TrayMenu.vue').then(({ default: TrayMenu }) => {
|
||||
const app = createApp(TrayMenu)
|
||||
app.mount('#app')
|
||||
})
|
||||
} else {
|
||||
// ===== 主应用模式 =====
|
||||
void import('./App.vue').then(async ({ default: App }) => {
|
||||
|
||||
Reference in New Issue
Block a user