Repository navigation
ui: split the repository header into a status strip and facts - #813
Conversation
HugoXK-bot
left a comment
There was a problem hiding this comment.
Verdict: PASS at f3988de
Written-by: HugoXK-bot
Posted-by: HugoXK-bot
A pure view refactor of the repo page header, and the parts other code depends on are kept.
- The status strip is new markup (
src/views/pages.ts:1349-1352) butdata-next-runanddata-next-sourcestill sit on the Next cell, and the two tests that read them still match (test/nextScheduledRun.test.ts:72,:78) with no change to the pattern. - The target-branch line keeps its text and its position in the head block (
src/views/pages.ts:1348), andtest/pages.test.ts:383still finds it in its Chinese form. - The new CSS is scoped under
.repo-pageand uses the existing colour and spacing tokens, so no other page inherits it.
Non-blocking: no new test pins the strip's structure itself, so a later shuffle of the three spans would pass silently. The attributes are covered; the layout is not.
Ran at f3988de:
npm run check— pass, 1988/1988 tests, typecheck and build includednode scripts/risk-gate.mjs --base 46e686047bc0a6210a006943975f61ea11ee5e3e --head HEAD—risk-tier: T2; basis: src/views/pages.tsnode scripts/pr-lint.mjs --pr 813—pr-lint: ok (#813, T2, 4 files)node scripts/changelog.mjs check— 41 fragments oknode scripts/version.mjs check— 0.3.6 oknode scripts/secret-scan.mjs— no suspected value
Not run: a real browser at 375px and 1440px, so I did not see the wrap myself; the CSS is scoped and uses existing tokens, and the existing page tests pass.
Conclusion: PASS. Presentation-only change, no route, id, attribute or string removed.
Merge live main. docs/architecture.md had main's recent-auth preflight sentence in the same paragraph this branch rewrote, so the resolution keeps both. Written-by: Fledge Platform Dev-3
HugoXK-bot
left a comment
There was a problem hiding this comment.
Verdict: PASS at a78f814
Written-by: HugoXK-bot
Posted-by: HugoXK-bot
Read the tip a78f814c5728ecb3db9a4e9a18b4a96543373216 (4 files +31/−6, T2; src/views/pages.ts blob f069a983 matches the contents API). This supersedes my PASS at f3988de4 only because the forward merge moved the tip.
Findings, none blocking:
src/views/pages.ts:1463-1491— the header keepsrepo-head-main, and every fact that moved into the strip reads a value already in scope (repo.auto_iterate,intervalLabel,scheduledNext/nextRunText,flybotAvailable,instance,credentialOk,repo.last_status). No new query, route or store call.src/views/pages.ts:1472—data-next-run/data-next-sourcesurvive verbatim inside the strip, so the existing script hook that updates the next-run cell still matches.src/views/pages.ts:1475-1477— FlyBot reusesbadge(t, instance.status)and keeps the old未创建/未启用branches;:1476usescredentialOk, computed at:1416, so the chip and the run gating cannot disagree.src/views/pages.ts:1478— the upstream/fork/permission/role/reviewer facts line is unchanged in content and escaping.public/app.css:517-530—.repo-statusis scoped, the 680px band puts two per row, and only the schedule link gets the hover border; no barespan/arule leaks.docs/architecture.md:306-315— the paragraph describes exactly this split, and no other doc owns the header.
Ran (exact tip tree; blob hash above verified):
npm run check— lint 11 baseline warnings, typecheck clean, 2182/2182 tests, build oknode scripts/pr-lint.mjs --pr 813— ok (#813, T2, 4 files)node scripts/changelog.mjs check— 63 fragments oknode scripts/version.mjs check— 0.3.6 oknode scripts/secret-scan.mjs— no suspected value in the tracked files
Not run: browser click-through, Docker, the visual matrix locally.
CI at this tip: everything green except review-gate failure 12:21:36Z, which is the pre-verdict state this review replaces.
HugoXK-bot
left a comment
There was a problem hiding this comment.
Verdict: PASS at 9d2232f
Written-by: HugoXK-bot
Posted-by: HugoXK-bot
Read the tip 9d2232fcfc5396a5e535e7ecbdf3f2d0c100c4f5 (merge of a78f814c + live main 9f2ef3aa; 4 files, +31/−6, T2). This supersedes my PASS at a78f814c5728ecb3db9a4e9a18b4a96543373216 only because the forward merge moved the tip.
Faithful rebase: all 714 blobs of tree 9563b8441eb668691183739b5be9d77ad8d75ef2 match the API tree object, and the PR's added/deleted line sets are identical to the tip I passed — the merge added nothing of its own.
The one conflict resolution is correct in both halves:
public/app.csskeepsmain's.work-summaryrules and their 680px media query (:517-525) and adds the PR's.repo-status*block after them (:529-535), so neither side overwrote the other.docs/architecture.mdkeepsmain's recent-auth preflight sentence and the PR's new header paragraph in the same paragraph, as described.
The code itself is unchanged from the tip I passed: src/views/pages.ts:1499-1510 splits title, .repo-status-strip (:1503) and the facts line, every value read is one already in scope (flybotAvailable, instance, credentialOk), and data-next-run/data-next-source survive inside the strip at :1506, so the existing script hook still matches.
Non-blocking, for the record before squash: the body's closing line still says "Published tip … a78f814c…" and its Ran: cites f3988de's 1988/1988; the head that will land is 9d2232fc / tree 9563b844, 2192/2192. Also no test pins the new strip — test/ is untouched, so the visual matrix is the only guard on this markup.
Ran (exact tip tree; every blob hash-checked against the API):
npm run check— lint 11 baseline warnings, typecheck clean, 2192/2192 tests, build oknode scripts/pr-lint.mjs --pr 813— ok (#813, T2, 4 files)node scripts/changelog.mjs check— 66 fragments oknode scripts/version.mjs check— 0.3.6 oknode scripts/secret-scan.mjs— no suspected value in the tracked files
Not run: browser click-through, Docker, the visual matrix locally.
Written-by: HugoXK
Fixes #811
risk-tier: T2; basis: src/views/pages.ts
What changed
src/views/pages.ts: the repository header is split into:public/app.css: scoped.repo-head,.repo-head-main,.repo-status-stripand.repo-statusstyles using existing tokens; the strip wraps to two columns on phones.docs/architecture.mdandchangelog.d/811-repo-header.changed.md.Every existing anchor and route is unchanged; the Work page, tabs and danger zone are untouched.
Why
The header was one long sentence carrying the version, cadence, next run, schedule link, status, upstream, fork, permission, role and reviewer. It wrapped on phones and had no visual starting point on desktop. The new structure keeps the same facts but gives the eye a title, a status strip and a facts line.
Ran:
npm cinpm run checkatf3988de— lint 0, typecheck clean, 1988/1988 tests, build cleannode scripts/version.mjs check— 0.3.6 oknode scripts/changelog.mjs check— 41 fragments oknode scripts/risk-gate.mjs --base origin/main—risk-tier: T2; basis: src/views/pages.tsNot run:
Risk and rollback
Risk: the header now has a wrapping status strip; on narrow widths it becomes two columns rather than one sentence. All existing strings (
Auto-iteration on,Auto every,Next,Schedule console) and actions stay, so tests and deep links are unaffected. Rollback: revert the commit; the previous paragraph returns.Relationship to #804
#804 covers the Work page inside the repository; this PR only changes the header above the tabs. There is no functional overlap.
Docs
docs/architecture.mdnow describes the title, status strip and facts line.Published tip (2026-11-15):
a78f814c5728ecb3db9a4e9a18b4a96543373216, treedc68f4a3f727f297086318a74a5a60e3c9aab1e7, parentsf3988de4+7d1e3ef1, 4 files+31/−6. The conflict was one file:docs/architecture.md, where main's recent-auth preflight sentence sits in the same paragraph this branch rewrote, so both are kept.