fix: keep menus and notifications usable above modals
Cross-platform packages / Validate source (push) Canceled after 0s
Cross-platform packages / Authorize desktop packaging (push) Canceled after 0s
Cross-platform packages / linux arm64 (push) Canceled after 0s
Cross-platform packages / macos arm64 (push) Canceled after 0s
Cross-platform packages / windows arm64 (push) Canceled after 0s
Cross-platform packages / linux x64 (push) Canceled after 0s
Cross-platform packages / macos x64 (push) Canceled after 0s
Cross-platform packages / windows x64 (push) Canceled after 0s
Cross-platform packages / Publish GitHub and OSS release (push) Canceled after 0s
GoodBuddy Agents / Validate Agent source (push) Canceled after 0s
GoodBuddy Agents / Build darwin arm64 Agent (push) Canceled after 0s
GoodBuddy Agents / Build linux arm64 Agent (push) Canceled after 0s
GoodBuddy Agents / Build linux x64 Agent (push) Canceled after 0s

Parsing test menus and application notifications could appear behind modal overlays or become unreachable while the background was inert. Share a stable top-layer portal that belongs to the owning or active modal, preserving notification timers, keyboard navigation and focus restoration.

Add unit and Electron regression coverage for settings, nested parsing results, application center, inference monitoring and native dialogs, with matching UI guidance and validation evidence.

Validation recorded in the preceding implementation: 4,793 tests passed and 67 skipped; typecheck, lint, isolated production build and Electron UI checks passed. Staged diff whitespace checks passed before this commit.

Release note: Menus and notifications remain visible and usable while settings or other dialogs are open, including keyboard navigation and notification dismissal.
This commit is contained in:
mesalogo
2026-09-19 18:11:39 +08:00
parent 6f06fce039
commit ec08109a09
15 changed files with 450 additions and 10 deletions
+19
View File
@@ -44,6 +44,25 @@
**历史**:先前浏览器多实例修正只覆盖了终端关闭确认;2026-09-13 用户在知识库实例
Modal 再次复现,同一检查确认其他应用级 Modal 均缺少处理。
## Modal 内的菜单与通知被遮挡或隔离
**症状**:设置中的“测试解析”菜单落在遮罩后面;设置、应用中心等全局 Modal 打开时,
应用通知被遮挡,关闭按钮也无法点击或聚焦。
**原因**:菜单挂在 `body`,却使用低于 Modal 的层级;通知留在被 Modal 设为 `inert`
的应用壳层内,同时层级也低于 Modal。单独增大 `z-index` 无法解除模态隔离。
**规则**:菜单与通知共用 `FloatingPortal`。稳定的非模态 Popover 宿主挂入所属/当前
Modal,兼顾 top layer 绘制、辅助技术的模态归属及焦点循环;没有 Modal 时才挂在
`body`。保留背景隔离,不在页面各自加层级常量,不因移动通知重置其计时。
**防复发**:`FloatingPortal.test.tsx` 覆盖宿主移动和内容不重挂载;
`overlay-layering.electron.test.ts` 使用真实组件、Portal、鼠标命中及原生键盘,覆盖
解析菜单/二级结果、设置、应用中心、本机推理监控和原生 `dialog`,以及浅深主题和短窗口。
**历史**:2026-09-19 同次检查确认解析测试菜单和应用级通知两处挂载机制错误,后者影响
多个全局 Modal;统一宿主后补完整 App 的真实保存通知与 TXT 解析复验。
## Flex 滚动内容压缩页签和分段控件
**症状**:知识库来源选择被长参数表单压成窄缝,标签和按钮文字被裁掉。