From 872afbfd83e4eb3b397fab8d636e6129fecd2c00 Mon Sep 17 00:00:00 2001 From: Andrew Anderson Date: Thu, 29 Oct 2026 18:46:49 -0400 Subject: [PATCH] =?UTF-8?q?=F0=9F=90=9B=20dashboard:=20quieter,=20professi?= =?UTF-8?q?onal=20merged-count=20odometer?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The Merged pill's drum drew 18 px bold monospace digits in per-digit near-black bevelled cells, taller than every other chip in the bar. Owner: "the odometer is too big of font. the animation is perfect though." The roll is untouched; the digits are now the chip's own type size (--fs-xs), semibold, --text, on one shallow inset track with a --line-subtle hairline and faint dividers; the pill is 28 px like its neighbours; the day/week line is --text-muted. The icon is the dashboard's bee glyph in the same 28 px hit area, not a filled hexagon. Fixes #15543 Signed-off-by: Andrew Anderson --- changelog.d/fixed-merged-odometer-quiet.md | 1 + src/docs/dashboard-sections.md | 2 +- src/pkg/dashboard/stage_tracker_cues_test.go | 19 +++-- src/pkg/dashboard/static-src/css/tracker.css | 70 ++++++++++-------- .../dashboard/static-src/html/tracker.html | 2 +- src/pkg/dashboard/static/index.html | 72 ++++++++++--------- 6 files changed, 95 insertions(+), 71 deletions(-) create mode 100644 changelog.d/fixed-merged-odometer-quiet.md diff --git a/changelog.d/fixed-merged-odometer-quiet.md b/changelog.d/fixed-merged-odometer-quiet.md new file mode 100644 index 0000000000..4143120511 --- /dev/null +++ b/changelog.d/fixed-merged-odometer-quiet.md @@ -0,0 +1 @@ +- Dashboard: the Merged pill's odometer is drawn at the chip's own type size on one quiet inset track — no 18 px bevelled drum cells, no glow — so it sits level with the other topbar chips, and the pill's icon is the dashboard's bee glyph rather than a filled hexagon; the roll animation is unchanged (#15543). diff --git a/src/docs/dashboard-sections.md b/src/docs/dashboard-sections.md index 684501a83e..776ad661b3 100644 --- a/src/docs/dashboard-sections.md +++ b/src/docs/dashboard-sections.md @@ -1141,7 +1141,7 @@ Payloads without `drawn_under` draw as before. #### Merged (the chip, the ledger, the flight) -A thin bar at the top of the tracker — it stays pinned under the card header while the list scrolls, with the stage column header strip pinned just below it — carries the hexagon bee (28 px; the pill grows to fit it) with **Merged** and the all-time count drawn as a **mechanical odometer at rest, always** — each digit in its own dark inset drum cell with a roller gradient, inner shadows top and bottom and a hairline between cells, monospace tabular digits at 18 px, no thousands separator — every pull request the hive tracked that reached merged, *all time*, with *N today · N this week* beside it at the bar's usual size. The number is the server's, not the tab's: the hive keeps a **merged ledger** at `/data/merged-ledger.json` (entries for 90 days, an all-time total that only grows, atomic writes, seeded on first boot from the audit log's `pr_merged` history with the PR throughput counter as the floor, then backfilled by the first closed sweep, which on such a boot asks GitHub for every PR closed in the last 30 days — merges by people and other bots the audit log never saw — instead of its usual one day; so the ledger counts every merged PR in a configured repository, and its all-time number is expected to run above the hive-observed PR throughput counter it was seeded from) fed by the audit log's `pr_merged` lines — the hive's own merges on every path and the poller's observations of merges by people or other bots — and by webhook / closed-sweep snapshots of a PR GitHub reports merged, which carry the title and the merger's login within seconds. +A thin bar at the top of the tracker — it stays pinned under the card header while the list scrolls, with the stage column header strip pinned just below it — carries the dashboard's bee glyph (the version card's bee, in a 28 px hit area; the pill is no taller than the chips beside it) with **Merged** and the all-time count drawn as a **quiet odometer at rest, always** — one shallow inset track with a hairline border and faint dividers, a wheel per digit, tabular semibold digits at the chip's own type size, no thousands separator (#15543: the first drum's 18 px bevelled cells were "too big of font … the animation is perfect though" — the roll is unchanged) — every pull request the hive tracked that reached merged, *all time*, with *N today · N this week* beside it at the bar's usual size. The number is the server's, not the tab's: the hive keeps a **merged ledger** at `/data/merged-ledger.json` (entries for 90 days, an all-time total that only grows, atomic writes, seeded on first boot from the audit log's `pr_merged` history with the PR throughput counter as the floor, then backfilled by the first closed sweep, which on such a boot asks GitHub for every PR closed in the last 30 days — merges by people and other bots the audit log never saw — instead of its usual one day; so the ledger counts every merged PR in a configured repository, and its all-time number is expected to run above the hive-observed PR throughput counter it was seeded from) fed by the audit log's `pr_merged` lines — the hive's own merges on every path and the poller's observations of merges by people or other bots — and by webhook / closed-sweep snapshots of a PR GitHub reports merged, which carry the title and the merger's login within seconds. `GET /api/stage-tracker` returns it as `merged{today, total_7d, total_30d, all_time, recent[≤20], tz, day_start}`; "today" rolls at midnight in the spoke's zone (`TZ`, else UTC) and the chip hydrates from it on the first render, so a reload, a new tab or a roll shows the same count (hivecommons/hive#15147 — the operator watched 4 become 0). Within a tab the number never goes down; a merge the tab just watched is added on top until the server's list carries it, and that list is also what settles a vanished row as *merged* rather than closed (alongside `recently_merged`), so a human's merge celebrates too. diff --git a/src/pkg/dashboard/stage_tracker_cues_test.go b/src/pkg/dashboard/stage_tracker_cues_test.go index 0276e12c14..b89c54cfcf 100644 --- a/src/pkg/dashboard/stage_tracker_cues_test.go +++ b/src/pkg/dashboard/stage_tracker_cues_test.go @@ -69,14 +69,21 @@ func TestStageTrackerCuesWiring(t *testing.T) { `:root { --cue-flight-size: var(--fs-3xl); --cue-flight-halo: drop-shadow(`, `.cue-flight { position: fixed; z-index: var(--z-cue-flight); font-size: var(--cue-flight-size); line-height: 1; color: var(--amber); font-weight: var(--fw-semibold); filter: var(--cue-flight-halo);`, `.ham-merged-count .ham-merged-n { font-variant-numeric: tabular-nums;`, - // The pill's own bee is 28 px and the count is a drum at rest - // (hivecommons/hive#15398 follow-up: #15409 sized only the flying - // glyph, and the roll was a 900 ms overlay over plain text). - `:root { --ham-merged-bee: 28px; --ham-odo-digit: 18px; }`, - `.ham-merged-count .ham-merged-ico { flex: 0 0 auto; width: var(--ham-merged-bee); height: var(--ham-merged-bee);`, + // The pill's own bee keeps a 28 px hit area and the count is a drum + // at rest (hivecommons/hive#15398 follow-up: #15409 sized only the + // flying glyph, and the roll was a 900 ms overlay over plain text), + // but the drum is the chip's own type size on one quiet inset track + // — no per-digit cells, bevels or 18 px digits (hivecommons/hive#15543: + // "the odometer is too big of font. the animation is perfect though"). + `:root { --ham-merged-bee: 28px; --ham-odo-digit: var(--fs-xs); --ham-odo-track: color-mix(in srgb, var(--panel) 95%, black); --ham-odo-divider: color-mix(in srgb, var(--text) 10%, transparent); }`, + `.ham-merged-count { position: relative; display: inline-flex; align-items: center; gap: var(--sp-2); min-height: var(--ham-merged-bee); box-sizing: border-box; padding-top: 0; padding-bottom: 0;`, + `.ham-merged-count .ham-merged-ico { flex: 0 0 auto; width: var(--ham-merged-bee); height: calc(var(--ham-merged-bee) - 2 * var(--line-width));`, + `
- + diff --git a/src/pkg/dashboard/static/index.html b/src/pkg/dashboard/static/index.html index b5b8aed762..01c7611b20 100644 --- a/src/pkg/dashboard/static/index.html +++ b/src/pkg/dashboard/static/index.html @@ -1331,9 +1331,9 @@ their own words, so every strip is the same width. An issue parked on a person (045) lights Actionable with the decision word. */ /* The sticky chip bar's height (the header strip sticks beneath it): - the Merged pill (--ham-merged-bee + 2 × --sp-1 tall) plus the bar's - own vertical padding. */ - #activity-monitor-section { --ham-sticky-bar-h: 42px; } + the Merged pill (--ham-merged-bee tall, no taller than its + neighbouring chips) plus the bar's own vertical padding. */ + #activity-monitor-section { --ham-sticky-bar-h: 36px; } /* Layers for the merge flight glyph and the merged-toast stack. Both are appended to document.body, not to #activity-monitor-section, so these must be :root-scoped — scoped to the section they resolved to nothing, the @@ -1779,24 +1779,33 @@ .ham-sticky { position: sticky; top: var(--navbar-sticky-height); z-index: calc(var(--z-sticky) + 1); display: flex; justify-content: flex-end; align-items: center; min-height: var(--ham-sticky-bar-h); box-sizing: border-box; padding: var(--sp-1) var(--sp-2); background: var(--panel); } .ham-sticky-live { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; } /* The Merged pill (hivecommons/hive issue 15398 follow-up — "where is my - odometer look and feel?"): PR 15409 only enlarged the *flying* bee - (.cue-flight) and the roll was a 900 ms overlay over plain text, so - at rest the pill was a 12 px hexagon and a bold number. Now the - hexagon-bee is --ham-merged-bee (28 px) and the pill grows to fit it, - and the all-time count is a drum of wheels at rest, always: each - digit in its own dark inset cell (.ham-merged-n .ham-odo-col) with - a roller gradient, a top/bottom inner shadow and a hairline between - cells, monospace tabular digits at --ham-odo-digit (≥ 18 px). The - day/week line keeps its size and rolls with the same columns, drawn - plain. A wheel that changes (.ham-odo-roll) slides its strip through - the digits it passes (--odo-shift) over --odo-ms; reduced motion - swaps instantly (no transition; the strip is drawn at its end). */ - :root { --ham-merged-bee: 28px; --ham-odo-digit: 18px; } - .ham-merged-count { position: relative; display: inline-flex; align-items: center; gap: var(--sp-2); min-height: calc(var(--ham-merged-bee) + 2 * var(--sp-1)); color: var(--text); cursor: pointer; } + odometer look and feel?"): the all-time count is a drum of wheels at + rest, always — a .ham-odo-col per digit — and a wheel that changes + (.ham-odo-roll) slides its strip through the digits it passes + (--odo-shift) over --odo-ms; reduced motion swaps instantly (no + transition; the strip is drawn at its end). + Owner (2026-10-29, issue 15543): "the odometer is too big of font. + the animation is perfect though." The first drum drew 18 px bold + monospace digits in per-digit near-black cells with bevels and inner + shadows, taller than every other chip in the bar. The roll is + untouched; the drum is now a quiet metric: digits at the chip's own + type size (--fs-xs), semibold, --text, tabular-nums, spaced by + letter-spacing, on ONE shallow inset track (a few per cent of black + over the panel, a --line-subtle hairline, --r corners) with faint + dividers; no glow, no bevel; the pill is the chips' height. The bee + keeps its 28 px hit area (--ham-merged-bee) but draws the dashboard's + bee glyph (the version card's oc-version-bee-* parts) at the chip's + icon weight instead of a filled hexagon. */ + :root { --ham-merged-bee: 28px; --ham-odo-digit: var(--fs-xs); --ham-odo-track: color-mix(in srgb, var(--panel) 95%, black); --ham-odo-divider: color-mix(in srgb, var(--text) 10%, transparent); } + .ham-merged-count { position: relative; display: inline-flex; align-items: center; gap: var(--sp-2); min-height: var(--ham-merged-bee); box-sizing: border-box; padding-top: 0; padding-bottom: 0; color: var(--text); cursor: pointer; } .ham-merged-count:hover { border-color: var(--line-strong); } - .ham-merged-count .ham-merged-ico { flex: 0 0 auto; width: var(--ham-merged-bee); height: var(--ham-merged-bee); color: var(--amber); filter: drop-shadow(0 1px 1px color-mix(in srgb, var(--surface-0) 50%, transparent)); } - .ham-merged-count .ham-merged-n { font-variant-numeric: tabular-nums; font-weight: var(--fw-semibold); font-size: var(--ham-odo-digit); font-family: var(--font-mono); } - .ham-merged-count .ham-merged-sub { color: var(--text-faint, var(--muted)); font-variant-numeric: tabular-nums; padding-left: var(--sp-2); border-left: var(--line-width) solid var(--line-subtle); } + .ham-merged-count .ham-merged-ico { flex: 0 0 auto; width: var(--ham-merged-bee); height: calc(var(--ham-merged-bee) - 2 * var(--line-width)); padding: calc(var(--ham-merged-bee) / 6) calc(var(--ham-merged-bee) / 10); box-sizing: border-box; color: var(--accent); overflow: visible; } + .ham-merged-count .ham-merged-ico .oc-version-bee-body { fill: var(--accent); stroke: var(--panel); } + .ham-merged-count .ham-merged-ico .oc-version-bee-wing { fill: color-mix(in srgb, var(--text) 35%, transparent); stroke: var(--panel); } + .ham-merged-count .ham-merged-ico .oc-version-bee-stripe { stroke: var(--panel); } + .ham-merged-count .ham-merged-ico .oc-version-bee-head { fill: var(--text-muted); } + .ham-merged-count .ham-merged-n { font-variant-numeric: tabular-nums; font-weight: var(--fw-semibold); font-size: var(--ham-odo-digit); color: var(--text); } + .ham-merged-count .ham-merged-sub { color: var(--text-muted); font-variant-numeric: tabular-nums; font-size: var(--fs-xs); padding-left: var(--sp-2); border-left: var(--line-width) solid var(--line-subtle); } .ham-merged-count.cue-tick { animation: cue-count-pop 320ms ease-out; } .ham-merged-count .ham-merged-n, .ham-merged-count .ham-merged-sub { position: relative; display: inline-flex; align-items: center; } /* The drum: one wrap of columns per counter, laid out inline (it is the @@ -1809,17 +1818,16 @@ .ham-odo-strip { display: block; transform: translateY(var(--odo-shift, 0%)); } .ham-odo-run .ham-odo-roll .ham-odo-strip { transition: transform var(--odo-ms, 900ms) cubic-bezier(0.22, 0.61, 0.36, 1); } .ham-odo:not(.ham-odo-run) .ham-odo-roll .ham-odo-strip { transform: translateY(0); } - /* The all-time count's wheels are drum cells: dark inset, a subtle - roller gradient (lighter band through the middle, darker at the lip - and the foot), an inner shadow at top and bottom, a hairline between - digits, the outer corners rounded. Light mode keeps the inset but on - a paler drum. */ - .ham-merged-count .ham-merged-n .ham-odo { gap: 0; border-radius: var(--r-sm); overflow: hidden; border: var(--line-width) solid color-mix(in srgb, var(--surface-0) 70%, var(--line-strong)); box-shadow: 0 1px 0 color-mix(in srgb, var(--text) 10%, transparent); } - .ham-merged-count .ham-merged-n .ham-odo-col { position: relative; min-width: 0.78em; height: 1.35em; line-height: 1.35; padding: 0; color: var(--text); background: linear-gradient(to bottom, color-mix(in srgb, var(--surface-0) 92%, black) 0%, var(--surface-3) 42%, var(--surface-3) 58%, color-mix(in srgb, var(--surface-0) 92%, black) 100%); box-shadow: inset 0 5px 5px -4px color-mix(in srgb, black 75%, transparent), inset 0 -5px 5px -4px color-mix(in srgb, black 75%, transparent); } - .ham-merged-count .ham-merged-n .ham-odo-col + .ham-odo-col { border-left: var(--line-width) solid color-mix(in srgb, var(--surface-0) 80%, black); } - .ham-merged-count .ham-merged-n .ham-odo-col .ham-odo-d { height: 1.35em; line-height: 1.35; } - body.light-mode .ham-merged-count .ham-merged-n .ham-odo-col { color: var(--text); background: linear-gradient(to bottom, color-mix(in srgb, var(--surface-3) 80%, black) 0%, var(--surface-0) 42%, var(--surface-0) 58%, color-mix(in srgb, var(--surface-3) 80%, black) 100%); box-shadow: inset 0 5px 5px -4px color-mix(in srgb, black 35%, transparent), inset 0 -5px 5px -4px color-mix(in srgb, black 35%, transparent); } - body.light-mode .ham-merged-count .ham-merged-n .ham-odo-col + .ham-odo-col { border-left-color: color-mix(in srgb, var(--surface-3) 60%, black); } + /* The all-time count's track: one shallow inset behind every wheel, + a hairline round it, faint dividers between digits, the digits + spaced a little wider than the label's letters. Light mode is the + same rule — the track and divider tokens mix from the theme. */ + .ham-merged-count .ham-merged-n .ham-odo { gap: 0; padding: 0 var(--sp-1); border-radius: var(--r); border: var(--line-width) solid var(--line-subtle); background: var(--ham-odo-track); } + .ham-merged-count .ham-merged-n .ham-odo-col { position: relative; min-width: 0.8em; height: 1.5em; line-height: 1.5; padding: 0 0.04em; letter-spacing: 0; color: var(--text); } + .ham-merged-count .ham-merged-n .ham-odo-col + .ham-odo-col { border-left: var(--line-width) solid var(--ham-odo-divider); } + .ham-merged-count .ham-merged-n .ham-odo-col .ham-odo-d { height: 1.5em; line-height: 1.5; } + body.light-mode .ham-merged-count .ham-merged-n .ham-odo-col { color: var(--text); } + body.light-mode .ham-merged-count .ham-merged-n .ham-odo { --ham-odo-track: color-mix(in srgb, var(--panel) 96%, black); } .ham-merged-pop { position: absolute; right: var(--sp-2); top: calc(var(--full-size) - var(--sp-1)); min-width: 22rem; max-width: 34rem; max-height: 60vh; overflow: auto; padding: var(--sp-4) var(--sp-5); border: var(--line-width) solid var(--line); border-radius: var(--r-lg); background: var(--panel-strong); box-shadow: var(--shadow-raised); font-size: var(--fs-sm); color: var(--text); z-index: var(--z-cue-flight); } .ham-merged-pop-head { display: flex; justify-content: space-between; gap: var(--sp-4); margin-bottom: var(--sp-3); font-weight: var(--fw-semibold); } .ham-merged-pop-head .ham-merged-pop-sum { color: var(--text-faint); font-weight: var(--fw-medium); } @@ -7528,7 +7536,7 @@

Hive activity moni
- +