[Feature][供应商额度] 缺少 Claude、Codex 与 xAI 的统一额度视图
- Dominant language
- TypeScript
- Stars
- 2.7k
- Forks
- 395
- Avg merge
- 21h 48m
- Merged PRs (30d)
- 776
Description
## 现象
同时连接 Claude、Codex 和 xAI 后,用户无法在一个区域查看各供应商的额度、剩余量、数据状态和更新时间。
## 复现步骤
1. 分别连接 Claude、Codex 和 xAI。
2. 打开用量与费用相关界面。
3. 查看各供应商额度并尝试进入对应详情页。
## 期望行为
统一区域列出所有已连接供应商,分别展示额度或剩余量、更新时间、数据状态,并提供对应详情入口。
## 实际行为
信息只按当前会话的运行时路由分散在右下角 chip 和 tooltip 中,无法同时查看多个供应商,也无法判断其他已连接供应商的额度状态。
## 源码分析
`TodaySpendChip.tsx` 根据当前会话路由分别进入 Claude、Codex、xAI 或 XD Gateway 分支,并选择单一外部用量页面。仓库中没有聚合全部已连接供应商状态的视图,因此当前组件结构无法满足跨供应商统一展示。
## 验收标准
- [ ] 统一区域列出 Claude、Codex、xAI 及适用的 XD Gateway。
- [ ] 每个供应商独立展示额度、剩余量、更新时间和数据状态。
- [ ] 未连接、无额度和接口失败使用不同提示。
- [ ] 每个供应商可跳转对应的外部用量页面。
- [ ] 多供应商同时连接时不串账号、不串数据。
- [ ] 补充多供应商及 Windows/macOS 回归测试。
Contributor guide
Research direction
Start with TodaySpendChip.tsx and trace its Claude, Codex, xAI, and XD Gateway branches, then inspect the usage and cost interface where the current chip and tooltip appear. Define the unified multi-provider view around the listed acceptance criteria, including connection, missing-data, and failure states. Add multi-provider regression coverage for Windows and macOS, verifying provider data and account separation.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- electron, typescript
- Domain
- desktop, frontend
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Active
- Clarity
- Mostly clear
- Newbie friendliness
- 52/100