agent-Specialization/.playwright-mcp
JOJO e2bbd767f7 feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX
This commit consolidates a large set of host-mode security and UX fixes across backend and frontend.

Security / execution model:
- Make permission/execution mode switches apply immediately (no deferred pending-only behavior).
- Keep runtime mode change notices durable and visible via user-message guidance path.
- Add explicit runtime message source taxonomy support and persistence:
  user / presend / guidance / notify / sub_agent / background_command.
- Ensure guidance/notify insertion is batched per tool-cycle so mid-run inserts are committed together.
- Separate notify from guidance semantics for mode-change notices.
- Add direct-mode auto-fallback handling visibility on frontend.

Approval and command gating:
- Align run_command approval pre-check logic with docker behavior for approval/auto_approval modes in host execution paths.
- Keep approval retry flow and final-result semantics intact when permission errors trigger approval.
- Externalize forbidden command keyword list into JSON config:
  config/forbidden_commands.json.
- Update forbidden command rejection message to user-facing wording:
  用户不允许执行包含“... ”的指令.

Prompt/runtime guidance:
- Refine execution-mode runtime rule text to avoid endless workaround loops:
  one safe alternative first, then request switching to direct mode when truly required.

Chat rendering / message UX:
- Prevent injected guidance/notify user-messages from incorrectly triggering assistant work header/timer chain.
- Restore correct visibility after history reload while preserving runtime-source behavior.
- Update user-header icon/label rendering by message source:
  - guidance -> 引导 + navigation icon
  - notify/sub_agent/background_command -> 通知 + bell icon
  - user/presend -> keep normal user header.
- Add new icons: static/icons/navigation.svg, static/icons/bell.svg.

Approval panel UX:
- Convert desktop approval panel from layout-compress sidebar to overlay + blur sheet.
- Fix panel transition behavior (remove unintended vertical motion; use dedicated desktop overlay transition).
- Improve approval result display:
  - decision and reason split lines,
  - green/red status styling,
  - multiline reason rendering,
  - auto-collapse delay adjusted to 3s.

Execution mode TTL feedback:
- When direct mode auto-expires to sandbox, frontend menu state is updated from status snapshot.
- Show non-auto-dismiss warning toast to explicitly notify auto-fallback.

Misc consistency updates:
- Execution mode label text cleanup in composer.
- Runtime notice wording normalization (权限模式修改为..., 执行环境修改为...).

Build/test notes:
- Frontend rebuilt after UI changes.
- Smoke tests passed for server refactor path.
2026-05-12 19:16:38 +08:00
..
page-2026-04-26T16-07-55-639Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-26T16-08-09-134Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-26T16-10-32-525Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-26T16-11-00-908Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-26T16-11-23-074Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-26T16-11-39-120Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-26T17-03-43-039Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-26T17-04-06-150Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-26T17-05-40-728Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-26T17-10-53-838Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T05-25-52-833Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T05-38-09-168Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T05-38-35-545Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T05-38-56-613Z.png feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T05-40-09-391Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T05-41-15-183Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T05-41-45-502Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T05-42-26-226Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T05-43-01-097Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T05-43-39-938Z.png feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T05-45-41-735Z.png feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T05-46-24-876Z.png feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T05-49-37-567Z.png feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T05-51-39-972Z.png feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T05-53-15-457Z.png feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T05-54-49-149Z.png feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T05-55-50-295Z.png feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T08-24-18-790Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T08-24-46-120Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T08-24-57-961Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T08-25-36-197Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T08-25-54-915Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T08-27-12-641Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T08-28-03-008Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T08-28-38-512Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T08-29-05-584Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T08-32-34-757Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T09-03-14-740Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T09-03-36-472Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T09-24-14-955Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T09-24-36-670Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T09-24-48-908Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T09-27-27-482Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T09-27-35-374Z.png feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T09-32-47-373Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T09-34-38-285Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T09-35-26-775Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T09-36-21-560Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T09-39-11-409Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T09-39-49-548Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T09-40-46-670Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T09-51-33-383Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T09-52-31-018Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T09-57-55-989Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T10-09-01-437Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T10-09-16-938Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T10-09-33-096Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T10-09-47-633Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T10-09-53-987Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T10-10-09-152Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T10-10-16-893Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T10-10-51-253Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T10-10-58-754Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T10-11-11-195Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T10-11-23-146Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T10-11-38-764Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T10-11-52-601Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T10-12-34-916Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T10-22-15-444Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T10-22-33-404Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T10-23-36-532Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T10-25-32-142Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T11-40-04-468Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T11-40-17-829Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T11-42-48-182Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T11-43-29-986Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T11-44-01-877Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T11-46-01-851Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T11-47-37-151Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T11-47-52-113Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T11-48-19-489Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T11-48-35-082Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T11-48-38-443Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T11-49-06-067Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T11-49-22-139Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T11-49-42-780Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T11-50-05-256Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T11-50-33-950Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T11-50-51-014Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T12-27-14-418Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T12-27-45-613Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T12-27-58-036Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T12-28-11-197Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T12-28-28-996Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T12-28-38-275Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T12-28-58-075Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T12-29-08-212Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T12-29-26-650Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T12-29-50-912Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T12-30-07-382Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T12-30-26-017Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T12-30-49-089Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T12-30-56-874Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T12-31-06-848Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T12-31-25-997Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T12-31-44-860Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T12-32-33-603Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T12-32-45-558Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T12-33-06-129Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T12-33-19-309Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T12-34-16-584Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T12-34-30-837Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T12-34-39-698Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T12-35-10-404Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-27T12-35-48-712Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-29T13-21-30-517Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00
page-2026-04-29T15-09-01-945Z.yml feat(host-security+ui): unify host execution/approval behavior, runtime notices, and approval overlay UX 2026-05-12 19:16:38 +08:00