Skip to content

fix(web): Chinese audit labels and a 主 Bot hint for upgraded workspaces - #224

Merged
yxflc11 merged 4 commits into
mainfrom
codex/claude-audit-labels
Oct 10, 2026
Merged

yxflc11 merged 4 commits into
mainfrom
codex/claude-audit-labels

Conversation

@yxflc11

@yxflc11 yxflc11 commented Oct 10, 2026

Copy link
Copy Markdown
Collaborator

Summary

Two findings from the installed P5 acceptance on the Owner's real workspace:

  • Audit log showed internal codes. Entries read "auth login succeeded", because the Web named only about half of the event types the Server writes. The other 27 types now have Chinese labels: login, logout, password, sessions, preferences, approvals, storage, trash, model services, Bot model and avatar, greetings, routines, attachment cleanup and the browser events. An unknown future type shows its category instead of its code (「登录事件」「其他事件」).
  • Upgraded workspaces never showed the 主 Bot crown. The Server does not elect a 主 Bot during an upgrade, so the sidebar now shows a dismissible hint where the crowned card would be: 「选一个主 Bot · 没有 @ 人的消息会先交给它。右键任意 Bot,选「设为主 Bot」。」.
    • It appears only when the Server reports primaryBotId: null, there is at least one Bot and the Owner can set one.
    • Dismissal is remembered per device.

Checked in the design preview, light and dark, with the preview's 主 Bot temporarily unset.

Checks

  • Web: 698 tests passed. The new tests cover:
    • Chinese labels and the category fallback; one existing test that expected the English fallback is updated.
    • The hint: it shows, dismissal persists, and it is absent for a chosen 主 Bot, for an older Server and when there are no Bots.
  • tsc -p apps/web: passed.
  • Hygiene guards: passed.

🤖 Generated with Claude Code

yxflc11 and others added 2 commits October 10, 2026 23:49
The audit log showed internal codes such as "auth login succeeded" for the 27 event types the Server writes but the Web did not name. They all have labels now, and an unknown type shows its category (登录事件, 其他事件) instead of the code.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A workspace upgraded from before 主 Bot has none, so the crowned card never appears. The sidebar now shows a dismissible hint in its place until the Owner picks one; dismissal is remembered on the device.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@yxflc11
yxflc11 merged commit 8417cc7 into main Oct 10, 2026
16 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant