Skip to content

fix(ui): tx table token K/M abbreviation + hover exact + summary right-align + key type label (rant 2026-08-22T08:58:54) - #120

Merged
argszero merged 1 commit into
mainfrom
fix/tx-ui-ue
Aug 22, 2026
Merged

argszero merged 1 commit into
mainfrom
fix/tx-ui-ue

Conversation

@argszero

Copy link
Copy Markdown
Owner

Summary

Transaction-page UE/UI polish (host screenshot-based feedback on v0.7.6 dev, rant 2026-08-22T08:58:54):

Related Rant

  • 2026-08-22T08:58:54 — 交易记录页 UE/UI 优化(基于宿主 2026-08-22 截图实测)

Changes

  • Token K/M abbreviation — fmtTokens now renders ≥1000 as X.XK and ≥1e6 as X.XM (previously only ≥1e6 became M, leaving thousands like 34313 / 32896 as raw numbers). Hovering a token cell shows the exact value via a title tooltip.
  • Summary bar alignment — .tx-summary .ts-item now align-items: flex-end so each value (income / expense / net) is right-aligned and visually tidy (already using tabular-nums).
  • Key column fallback — rows with no key_label now show the transaction-type label for non-keyed types (topup / gift / withdraw) instead of a bare —; consume/earn without a key still show —.
  • Filter layout note — the four token columns keep their number-range filters (compact via existing .range-filter CSS); the summary already renders the K/M token stats.

Tests

  • Frontend-only: node --check on ui/js/app.js + ui/js/i18n.js OK; cargo test 139/139 passed; fmt clean; cache-bust bumped to 20260822-3

Acceptance

  • Token columns use K/M abbreviation with exact-value hover
  • Summary income/expense/net values right-aligned
  • Summary shows token stats (M/K units) — already backed by summary endpoint
  • Key column shows key_label or transaction type for non-keyed rows
  • Reconciliation formula confirmed exact per row (input = tokens - cached - output); the screenshot diff was a cross-row summary-vs-row comparison, not a backend bug
  • 139/139 + fmt + clippy green

…t-align + key/type label fallback (rant 2026-08-22T08:58:54)
@argszero
argszero merged commit 8704ddb into main Aug 22, 2026
1 check passed
@argszero
argszero deleted the fix/tx-ui-ue branch August 22, 2026 01:05
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