docs(ui): name the operator card the way the code names it - #319
Merged
Merged
Conversation
`ui/README.md`'s "设置 / 管理 / 运营布局约定(v1.22)" section still calls the operator overview's key card "上游 key 健康" and lists its three pills as "健康 / N 个异常 / 全部失败". That was true when `7d9b56e` (PR #174) wrote the line; C2158 (#269, `e5ee178`) then renamed the card and rewrote the pills, because the data has no health signal at all — `/api/ops/runtime` only returns `total` / `on` / `off`. #269 updated only the section it added itself further down this same file (`:1080`, which says the opposite), leaving this line behind, and its edit sheet (4 files / 7 edits) never listed it. Correct the wording to what the code ships: the title is `ops.keys.title` ("上游 key 状态") and the pills are `ops.keys.allOn` / `someOff` / `allOff` ("全部启用 / N 个停用 / 全部停用"). No gate: this is prose restating an implementation name, and the repo's standing decision for that axis is to fix the data, not to guard the prose (see PRs #309, #310, #312–#315). Verified on the branch tree: `cargo test` 417 passed / 0 failed (unchanged baseline), `cargo fmt --check` and `cargo clippy --all-targets -D warnings` both clean. The other claims on the same line were re-checked and are still true (`version` ← `env!("CARGO_PKG_VERSION")`, the five `uptime_*` fields, `split_uptime`, `fmtUptime`'s top-two-nonzero units, `ops.uptime.*`, `today_hours` zero-filled 0–23). The one remaining occurrence of the old wording (`:1084`) is the C2158 section quoting it as history and is left untouched.
Owner
Author
|
✅ LGTM (self-review — What I checked:
|
This was referenced Sep 29, 2026
Merged
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
ui/README.md's "设置 / 管理 / 运营布局约定(v1.22)" section still describes theoperator overview's key card with the wording C2158 replaced:
That sentence was true when it was written (
7d9b56e, PR #174). C2158 (PR #269,squash
e5ee178) then renamed the card上游 key 健康→上游 key 状态and rewrote thethree pills
健康 / {n} 个异常 / 全部失败→全部启用 / {n} 个停用 / 全部停用, because thedata carries no health signal at all —
/api/ops/runtimeonly returnstotal/on/off(
off = total − on), so a user pausing their own key (a normal action) was being rendered as ared failure state.
#269 changed the key names, both language packs, the static fallback in
ui/index.htmland therender site in
ui/js/app.js— and added a new section to this very file that says the opposite(
:1080, "后端不产出任何健康信号"). It left this line untouched, and its edit sheet(4 files / 7 edits) never listed it. So today the document contradicts itself: the old section
promises a card the code no longer ships.
Changes
ui/README.md: in the operator-layout bullet, the card is named 上游 key 状态 and itsthree pills are 全部启用 / N 个停用 / 全部停用, with a pointer to the C2158 section below.
One line (
+1 / −1). The other claims on that same bullet were re-checked and are still true:version←env!("CARGO_PKG_VERSION"), the fiveuptime_*fields,split_uptime,fmtUptime's top-two-nonzero units,ops.uptime.{days,hours,minutes,seconds}, andtoday_hourszero-filled 0–23.The single remaining occurrence of the old wording (
ui/README.md:1084) is the C2158 sectionquoting it as history ("这张卡曾把「停用」渲染成…") and is deliberately left untouched —
editing it would erase the record of the defect. Hence a whole-line replacement rather than a
token-level one.
No gate. This is prose restating an implementation name, and the repository's standing
decision on that axis is to fix the data, not to guard the prose (precedents: PRs #309, #310,
#312–#315). No cache-bust token:
ui/README.mdis not a served asset.Related Issue
Tests
cargo test— 417 passed / 0 failed (unchanged baseline; the change touches no tested byte)cargo fmt --check— cleancargo clippy --all-targets -- -D warnings— cleanops.keys.titlezh ("上游 key 状态") andops.keys.allOn/allOffzh values, and no longercarries any of the three old pill words.
ui/README.mdis part of the corpus consumed byi18n_pack::every_pack_key_reaches_a_consumer, and that test still passes — the new wordingintroduces no i18n key token.
Checklist
docs/)