8000 fix(web): give account names their own line beside long plan badges for 0.10.1 by InfinityPacer · Pull Request #42 · InfinityPacer/meterleaf · GitHub
[go: up one dir, main page]

Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,13 @@

## [未发布]

## [0.10.1] - 2026-10-21

- 桌面账户列表把套餐徽标移到名称下一行,Team Premium 这类较长的套餐名不再把账户名挤成省略号。
- 有套餐徽标的订阅账户不再重复显示「订阅账户」,API 接入和未识别套餐的账户仍显示类型。
- 5h 额度等待新周期数据时,费用位置显示「—」,和其他额度窗口一样排成金额与说明两行。
- 数据库结构未变,升级无需先备份。

## [0.10.0] - 2026-10-20

- 新版 Claude Code 不再把套餐写进 `~/.claude.json`,采集器改为从登录凭据只读套餐字段,重新识别 Pro、Max 5x、Max 20x 和 Team Premium,Team 席位还能从席位档位识别。令牌不解析、不上传,也不运行 Claude Code 命令。
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "meterleaf",
"version": "0.10.0",
"version": "0.10.1",
"private": true,
"type": "module",
"license": "Apache-2.0",
Expand Down
12 changes: 9 additions & 3 deletions src/web/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -413,16 +413,22 @@ function AccountRow({
{accountInitial(account.name)}
</span>
<span className="account-name">
{/*
套餐徽标放在第二行,名称独占首行,Team Premium 这类长徽标不挤压名称。
有徽标的订阅账户不再写“订阅账户”;API、未知类型和缺少套餐的订阅仍显示类型。
*/}
<span className="account-name-line">
<strong title={account.name}>{account.name}</strong>
</span>
<small>
{plan && (
<span className="plan-chip" data-tier={plan.tier ?? undefined}>
{plan.label}
</span>
)}
</span>
<small>
<span>{accountKind}</span>
{!(plan && account.kind === "subscription") && (
<span>{accountKind}</span>
)}
</small>
{archived && (
<span className="desktop-account-status" data-archived={archived}>
Expand Down
4 changes: 4 additions & 0 deletions src/web/components/QuotaWindow.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,11 @@ export function QuotaWindow({
{/* 等待期间只显示空轨道;不设宽度的填充块会撑满,看起来像已用尽。 */}
<span style={{ width: 0 }} />
</span>
{/* 费用未知不补零,用破折号占住费用位,与其他窗口保持“金额 + 说明”两行。 */}
<span className="quota-window-foot">
<span className="quota-window-amount">
<strong aria-label={`${label}费用等待更新`}>—</strong>
</span>
<span className="quota-window-volume">新周期数据到达后显示</span>
</span>
</span>
Expand Down
5 changes: 2 additions & 3 deletions src/web/components/quota-window.css
Original file line number Diff line number Diff line change
Expand Up @@ -120,9 +120,8 @@
font-style: normal;
}

.quota-window[data-waiting="true"] .quota-window-volume {
margin-left: 0;
white-space: normal;
.quota-window[data-waiting="true"] .quota-window-foot strong {
color: var(--muted);
}

.quota-window-amount {
Expand Down
2 changes: 1 addition & 1 deletion src/web/demo/ledger.ts
Original file line number Diff line number Diff line change
Expand Up @@ -238,7 +238,7 @@ export function createDemoLedger(usdBasis: UsdBasis = "subscription"): LedgerSna
{
id: "claude",
name: "Claude Code",
plan: "max-5x",
plan: "team-premium",
platform: "anthropic",
kind: "subscription",
sampledAt: asOf,
Expand Down
7 changes: 0 additions & 7 deletions src/web/desktop.css
Original file line number Diff line number Diff line change
Expand Up @@ -743,13 +743,6 @@
margin-left: 0;
text-align: right;
}
.app-shell
.account-windows
.quota-window[data-waiting="true"]
.quota-window-volume {
grid-row: 1 / 3;
white-space: normal;
}
.app-shell .account-windows .quota-window-estimate {
display: none;
}
Expand Down
Loading
0