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