feat: 会话通知插件 v1.0.1(系统通知 + 应用内轻弹窗)
会话完成、需要工具授权、需要回答时提醒: - 窗口不在前台走系统通知(Windows / macOS / Linux 同一条渲染进程通知通道,无平台分支),点击回到 DSH 并跳到该会话; - 窗口在前台走应用内轻弹窗(右上角、6 秒自动消失、可悬停暂停、Esc 关闭、点「查看」跳转); - 正在看的那个会话完成时不打扰。 触发与去重:只对「运行中 → 空闲」的转变提醒,同一会话同一轮只报一次,同一待处理请求只报一次; 子智能体会话与空白会话跳过;打开应用时已在运行的会话只建基线不补发; 多个会话同时完成有 1.5 秒节流,完成提醒前有 400ms 确认窗口(那一轮又跑起来就不报)。 设置 → 通用 → 会话通知:权限状态、请求权限、测试通知、完成/授权/提问三个开关, 以及观察器自身的健康状态(收不到会话状态时直接显示,不会静默失效)。 实现形态遵循 DSH 插件规范:dsh.manifestVersion 1、dsh.bundle.patch 声明宿主行、 dsh.client 声明 platform: web 的浏览器半;宿主半为空壳,不注册任何服务与路由。 会话状态只通过 slot 的标准 props(useSessions / useSessionStatus)读取, 只往 settings.general.item 与 shell.overlay 注册,样式只用主题 token,不 import 客户端包。 修复:观察器原先挂在 sidebar.panellist,而该 slot 的宿主会把每个条目的 id 当作一个 左侧面板按钮(label 取 options.label ?? options.id,条目作为图标内联渲染), 导致左侧多出一行空面板并挤坏侧边栏;现改挂通用浮层 shell.overlay。
This commit is contained in:
@@ -0,0 +1,9 @@
|
||||
# Bundle patch layer for @dsh-plugin/session-notify.
|
||||
#
|
||||
# One Host row is enough: the Host half owns no services and no routes, and the
|
||||
# browser half is picked up automatically from this package's `dsh.client`
|
||||
# declaration (`dsh-client-modules` scans enabled Loader entries, serves
|
||||
# `/plugins/@dsh-plugin/session-notify/client.js`, and boots it with the page).
|
||||
- insert:
|
||||
- id: session-notify
|
||||
name: '@dsh-plugin/session-notify'
|
||||
Reference in New Issue
Block a user