Repository navigation
feat(ui): surface queued-outbox counts in composer hint, session rows, and offline footer - #112649
Merged
Merged
Conversation
steipete
marked this pull request as ready for review
July 22, 2026 11:57
…, and offline footer
Follow-up to the offline-state unification: queued sends were mechanically
safe (durable outbox with reconnect replay) but only visible inside the
open session's thread.
- Composer offline hint now includes the visible session's queued count.
- Session rows show a clock badge with the per-scope outbox count,
independent of connection state (covers waiting-idle and failed too),
with alias-safe scope resolution so agent-main never double-counts.
- The offline footer button appends the aggregate ("· N queued"); the
connected state stays completely silent.
- One narrow subscription seam (subscribeStoredChatOutboxChanges) added
in composer-persistence; no send/drain logic touched.
…d module The queued-count feature statically imported composer-persistence from startup modules, hoisting the chat page's persistence machinery into the startup chunk and breaking the Control UI startup JS gzip budget (319.6 KiB > 314.0 KiB limit). Split ownership instead of gaming the budget: a lean read/subscribe module (ui/src/lib/chat/outbox-store.ts + codec/draft-state) serves startup consumers (app-host, sidebar), while writes, migrations, and drain stay in the lazy chat chunk (composer-outbox-store/composer-storage); composer-persistence keeps its export surface for chat callers. Startup is back to 313.8 KiB gzip at 12 requests with no chunking-config changes. Also fixes an autoreview finding in the new summary: legacy bare-main outbox rows now resolve through session defaults (online) or the persisted mainAlias (offline reload) instead of trusting the row's stale embedded agent id, so badge counts key to the same scope the sidebar resolves. The shared footer status renderer is deduplicated into session-row-badges.
The lean outbox read module still cost ~2.8 KiB of startup gzip against 1.5 KiB of budget headroom. Follow the sidebar chrome pattern (lobster-pet/facepile): app-host idle-loads outbox-store, subscribes on arrival, and passes the sidebar a resolver callback instead of letting startup modules import scope resolution. Badges and counts hydrate moments after load; before that the summary is empty by design. Failed chunk loads recover on browser online events and, because chunks are usually served by the gateway itself, on gateway reconnect — the exact moment the offline badges become relevant again. Raise the initial-graph packing ceiling 448->512 KiB: the grown core graph split at the old boundary into an extra chunk, costing ~1.9 KiB of startup gzip to compression-context resets (same documented tradeoff as the earlier 400->448 bump). Startup lands at 313.5 KiB gzip / 9 requests, matching the origin/main baseline, limit 315.0.
steipete
force-pushed
the
claude/offline-queued-badges
branch
from
July 22, 2026 16:26
e57b629 to
b8ff17d
Compare
Contributor
|
ClawSweeper status: review started. I am starting a fresh review of this pull request: feat(ui): surface queued-outbox counts in composer hint, session rows, and offline footer This is item 1/1 in the current shard. Shard 0/1. This placeholder means the worker is alive and reading the current context. I will edit this same comment with the actual review when the claws are done clicking. Crustacean status: shell secured, claws on keyboard, evidence pebbles being sorted. |
Contributor
Author
|
Merged via squash.
|
This was referenced Jul 22, 2026
steipete
added a commit
that referenced
this pull request
Jul 23, 2026
…d baseline (#112880) The startup JS gzip gate was a fixed ceiling that main drifted to within 1-3 KiB of, forcing repeated hand-bumps (315->317 KiB) and failing feature PRs on drift they did not cause (#112649 burned two CI rounds). check-control-ui-performance.mjs now also enforces a committed baseline (config/control-ui-startup-budget-baseline.json) with a 512 B tolerance: regressions beyond baseline+tolerance fail with an actionable message, intentional increases become a reviewed one-line diff via --update-baseline --reason, meaningfully lighter builds print a lower-the-baseline hint, and a malformed/missing baseline fails closed. The fixed ceiling stays as the cumulative-creep backstop. Closes #112743.
github-actions Bot
pushed a commit
to Desicool/openclaw
that referenced
this pull request
Jul 23, 2026
…, and offline footer (openclaw#112649) * feat(ui): surface queued-outbox counts in composer hint, session rows, and offline footer Follow-up to the offline-state unification: queued sends were mechanically safe (durable outbox with reconnect replay) but only visible inside the open session's thread. - Composer offline hint now includes the visible session's queued count. - Session rows show a clock badge with the per-scope outbox count, independent of connection state (covers waiting-idle and failed too), with alias-safe scope resolution so agent-main never double-counts. - The offline footer button appends the aggregate ("· N queued"); the connected state stays completely silent. - One narrow subscription seam (subscribeStoredChatOutboxChanges) added in composer-persistence; no send/drain logic touched. * perf(ui): keep the startup bundle under budget with a lean outbox read module The queued-count feature statically imported composer-persistence from startup modules, hoisting the chat page's persistence machinery into the startup chunk and breaking the Control UI startup JS gzip budget (319.6 KiB > 314.0 KiB limit). Split ownership instead of gaming the budget: a lean read/subscribe module (ui/src/lib/chat/outbox-store.ts + codec/draft-state) serves startup consumers (app-host, sidebar), while writes, migrations, and drain stay in the lazy chat chunk (composer-outbox-store/composer-storage); composer-persistence keeps its export surface for chat callers. Startup is back to 313.8 KiB gzip at 12 requests with no chunking-config changes. Also fixes an autoreview finding in the new summary: legacy bare-main outbox rows now resolve through session defaults (online) or the persisted mainAlias (offline reload) instead of trusting the row's stale embedded agent id, so badge counts key to the same scope the sidebar resolves. The shared footer status renderer is deduplicated into session-row-badges. * fix(ui): correct type-only import and const tuple in outbox split * perf(ui): idle-load the outbox summary so startup carries no outbox code The lean outbox read module still cost ~2.8 KiB of startup gzip against 1.5 KiB of budget headroom. Follow the sidebar chrome pattern (lobster-pet/facepile): app-host idle-loads outbox-store, subscribes on arrival, and passes the sidebar a resolver callback instead of letting startup modules import scope resolution. Badges and counts hydrate moments after load; before that the summary is empty by design. Failed chunk loads recover on browser online events and, because chunks are usually served by the gateway itself, on gateway reconnect — the exact moment the offline badges become relevant again. Raise the initial-graph packing ceiling 448->512 KiB: the grown core graph split at the old boundary into an extra chunk, costing ~1.9 KiB of startup gzip to compression-context resets (same documented tradeoff as the earlier 400->448 bump). Startup lands at 313.5 KiB gzip / 9 requests, matching the origin/main baseline, limit 315.0.
github-actions Bot
pushed a commit
to Desicool/openclaw
that referenced
this pull request
Jul 23, 2026
…d baseline (openclaw#112880) The startup JS gzip gate was a fixed ceiling that main drifted to within 1-3 KiB of, forcing repeated hand-bumps (315->317 KiB) and failing feature PRs on drift they did not cause (openclaw#112649 burned two CI rounds). check-control-ui-performance.mjs now also enforces a committed baseline (config/control-ui-startup-budget-baseline.json) with a 512 B tolerance: regressions beyond baseline+tolerance fail with an actionable message, intentional increases become a reviewed one-line diff via --update-baseline --reason, meaningfully lighter builds print a lower-the-baseline hint, and a malformed/missing baseline fails closed. The fixed ceiling stays as the cumulative-creep backstop. Closes openclaw#112743.
This was referenced Aug 30, 2026
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.
What Problem This Solves
Follow-up to #112600: queued sends are mechanically safe (durable per-session outbox with idempotent reconnect replay) but were only visible inside the open session's transcript. Messages queued in a session you navigated away from, and the overall "how much is waiting" picture, had no indicator anywhere.
Why This Change Was Made
Queued-ness is ambient state, so it surfaces in the three places you already look, and nowhere new:
waiting-idle) or after a failed send, and "this session has undelivered input" matters in all three cases. Alias-safe scope resolution keeps agent-main from double-counting.Plumbing is one narrow seam:
subscribeStoredChatOutboxChangesin composer-persistence notifies on stored-outbox writes; app-host summarizes counts per scope key and passes them down. No send/queue/drain logic touched.User Impact
You can flick airplane mode, keep typing, and see exactly what's parked where: count in the composer, per-session badges in the sidebar, total on the offline pill. On reconnect everything flushes and all indicators clear.
Artifact manifest: https://artifacts.openclaw.ai/pr-offline-queued-badges-20260722/artifact-manifest.json
Evidence
origin/main(incl. resolving the fix(ui): move footer title tooltips onto the shared tooltip component #112639 tooltip-component conversion in the footer button).pnpm ui:i18n:verifyclean; new keyschat.composer.offlineQueuedHint,connection.queuedCount,sessionsView.queuedMessage{,s}.check-changed(Blacksmith Testbox): coreTests + ui lanes green, lint 0/0.gpt-5.6-sol): clean, no accepted findings.setOnline(false), two sends queued live) — no real gateway involved.