fix(ui): clean status bubble labels
一些检测仍在等待运行
ci / Portable quality checks (push) Waiting to run
ci / Windows Tauri build (push) Waiting to run

这个提交存在于:
YokiiroBW 2026-07-20 15:02:19 +08:00
父节点 e28614ad6a
当前提交 95317d62d8
共有 3 个文件被更改,包括 13 次插入 和 8 次删除

查看文件

@ -87,7 +87,7 @@ remote_username 用于远端聊天身份和会话命名,不作为本机权限
### Q5:状态气泡与托盘整合 ### Q5:状态气泡与托盘整合
- 增加非默认置顶的气泡窗口,显示连接状态、思考中、回复完成、错误和未读数。 - 增加非默认置顶的气泡窗口,显示连接状态、思考中、回复完成、错误和未读数。`n- 已完成:修复气泡状态标签和无障碍名称的乱码,保持默认不置顶和设置导向逻辑不变。
- 允许用户关闭气泡或切换到仅应用 UI 模式。 - 允许用户关闭气泡或切换到仅应用 UI 模式。
- 气泡点击按设置打开主页面或快速聊天;右键菜单提供显示、隐藏、设置和退出。 - 气泡点击按设置打开主页面或快速聊天;右键菜单提供显示、隐藏、设置和退出。
- 明确窗口层级、焦点、点击穿透(如需要)和屏幕边界策略。 - 明确窗口层级、焦点、点击穿透(如需要)和屏幕边界策略。

查看文件

@ -159,3 +159,7 @@ Still not claimed complete: automatic startup activation, real Tauri multi-windo
- Completed: added window bounds, monitor clamping, and database round-trip tests. - Completed: added window bounds, monitor clamping, and database round-trip tests.
- Validation: Rust format, Clippy with warnings denied, and `astrbot-desktop` unit tests pass. - Validation: Rust format, Clippy with warnings denied, and `astrbot-desktop` unit tests pass.
- Next: finish the remaining quick-window/status-bubble acceptance work, then continue with the pet asset and multi-monitor controller foundation. - Next: finish the remaining quick-window/status-bubble acceptance work, then continue with the pet asset and multi-monitor controller foundation.
## 2026-07-20: status bubble text cleanup
- Fixed the remaining mojibake in status-bubble state labels and accessibility text.
- Validation: TypeScript, ESLint, and Vitest (6 tests) pass.

查看文件

@ -1,4 +1,4 @@
import { invoke } from "@tauri-apps/api/core"; import { invoke } from "@tauri-apps/api/core";
import { useEffect, useState } from "react"; import { useEffect, useState } from "react";
import { import {
@ -58,11 +58,12 @@ function stateLabel(
companion: ConnectionRuntimeStatus["companion"]["state"], companion: ConnectionRuntimeStatus["companion"]["state"],
operations: ConnectionRuntimeStatus["operations"]["state"], operations: ConnectionRuntimeStatus["operations"]["state"],
): string { ): string {
if (companion === "connecting" || operations === "connecting") if (companion === "connecting" || operations === "connecting") return "连接中";
return "连接中"; if (companion === "authExpired" || operations === "authExpired") return "需要认证";
if (companion === "authExpired" || operations === "authExpired") if (
return "需认证"; companion === "serverUnavailable" ||
if (companion === "serverUnavailable" || operations === "serverUnavailable") operations === "serverUnavailable"
)
return "服务不可用"; return "服务不可用";
return "离线"; return "离线";
} }