Skip to content

improve(ui): compact Automations job cards at phone width - #190382

Merged
vyctorbrzezowski merged 6 commits into
mainfrom
brzezowski/mobile-automations-cards
Nov 2, 2026
Merged

vyctorbrzezowski merged 6 commits into
mainfrom
brzezowski/mobile-automations-cards

Conversation

@vyctorbrzezowski

@vyctorbrzezowski vyctorbrzezowski commented Nov 1, 2026 •

Copy link
Copy Markdown
Member

What Problem This Solves

At phone width each Automations job takes about 220px: a label column ("Schedule:", "Next run:", "Last run:") eats the card, values wrap, and the actions sit on their own indented row. New automation loses its label and renders as a second terracotta +, next to the header's new-session +, with a different meaning.

User Impact

On a 390px phone, jobs per screen go from about 1.5 to about 6, and New automation is readable. Desktop and widths above 560px don't change.

  • Toolbar: agent picker and New automation, then search and filter, then tabs and refresh. The agent picker stays in the header on the job detail and create views.
  • Card: status mark, name, run, enable toggle and ... on the first line; schedule, next and last result on one line under it, with no labels.
  • Long names and schedules truncate on one line. The schedule gives way first, so next and last stay readable.
  • Failures stay visible: the status mark, a red last result, and the auto-disabled reason on its own line.
  • Description, agent and time zone leave the phone card and remain on the job detail view.
  • Run history: the search placeholder ends in an ellipsis instead of clipping, entries keep their spacing without hairlines, and View transcript no longer touches the text around it.

Why This Change Was Made

The card keeps the facts people scan for and leaves the rest to the detail view, one tap away. Every action stays reachable. A job with no finished run omits the last-result slot, because a bare "n/a" means nothing without its label.

Evidence

Mock gateway data at 390px, real clicks. These images show today's top bar until the header PR lands.

Before After, Absolutely light
r2-before r2-light
After, Absolutely dark After, CRT (square theme)
r2-dark r2-crt

Real Safari 27 on macOS, in a 390px window, list and row menu after a real mouse click:

List Row menu open
r2-safari-list r2-safari-menu

The ring on "Run if due" is the shared menu's existing focus treatment: opening the menu focuses its first item, and both Safari and Chromium show the ring after a pointer click. This PR doesn't change it.

Checks on this branch:

  • oxfmt, oxlint, stylelint, tsgo:ui and check-control-ui-controllers pass.
  • view.browser.test.ts under the UI browser config: passes.
  • cron-descriptions, cron-search, cron-run-filter-typography, cron-run-feedback and cron-run-completion e2e suites pass on this head; cron-remove and cron-filters passed on the previous CSS pass.
  • src/pages/cron/ unit tests: 188 of 189 pass. The one failure, retires directory failures on delete (published=false) in cron-page.delivery-conversations.test.ts, fails the same way on main without this change.
  • ui:check-performance:base fails only on total CSS, which is already over its ceiling on main: +369 B gzip and +1837 B raw from this change.
  • Desktop at 1280px: element geometry is identical to main in Absolutely light and CRT.

@vyctorbrzezowski vyctorbrzezowski self-assigned this Nov 1, 2026
@clawsweeper

clawsweeper Bot commented Nov 1, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

Pull request received. I will update this pull request when review starts.

ClawSweeper review complete

ClawSweeper finished reviewing this revision. The review result is being finalized.

View the workflow run.

@clawsweeper clawsweeper Bot added clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-repro Preliminary submission classification; full source review pending. P3 Low-priority cleanup, docs, polish, ergonomics, or speculative work. proof: sufficient ClawSweeper judged the real behavior proof convincing. proof: 📸 screenshot Contributor real behavior proof includes screenshot evidence. rating: 🦪 silver shellfish Thin PR readiness signal; proof, validation, or implementation needs work. status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action. and removed clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-repro Preliminary submission classification; full source review pending. labels Nov 1, 2026
@clawsweeper

clawsweeper Bot commented Nov 1, 2026

Copy link
Copy Markdown
Contributor

Codex review: needs changes before merge.

What this changes

This PR compacts phone-width Automations cards and rearranges their toolbar while retaining access to job actions and details.

Example: View six automations on a 390px-wide phone.

  • Before: Tall labeled cards show roughly one and a half jobs, and New automation appears as an unlabeled plus.
  • After: Compact rows show all six jobs in the supplied capture, with a labeled New automation button.

Review scores

Measure Result What it means
Overall readiness 🦪 silver shellfish (2/6) Strong visual evidence supports the improvement, but a forbidden duplicate listener and attributable performance-gate failure prevent a pass.
Proof confidence 🦞 diamond lobster (5/6) ✨ media proof bonus Sufficient (screenshot): Inspected before/after browser screenshots exercise the Cron list renderer and responsive stylesheet at 390px with synthetic Gateway jobs in light, dark, and CRT themes, visibly showing compact cards, labeled creation, truncation, and retained failure indicators; the additional Safari images were not among the prepared local artifacts.
Patch quality 🦪 silver shellfish (2/6) 2 actionable review findings remain.

Product

Kind: Preference · Worth it: Yes · Fix scope: Complete
User problem: Phone users scan very few automations at once and see an ambiguous unlabeled creation button.
Reason: The maintainer-authored direction is approved under the supplied policy, and the inspected screenshots demonstrate a substantial density improvement while preserving visible failure states.

Merge readiness

⛔ Needs changes before merge - 2 items remain

Keep open: this maintainer-authored PR provides useful phone-width improvements, but the duplicated media-query listener and attributable CSS budget failure need repair.

Priority: P3
Reviewed head: 888771e502520115e241783759cee6784823c44a

Before merge

  • Reuse the shared media-query primitive (P1) - The new createPhoneLayout duplicates createMediaQuery in ui/src/lib/reactive/platform.ts, which already handles matchMedia fallback, reactive updates, shared subscriptions, and disposal. Its direct addEventListener call in this TSX file is also explicitly forbidden by the applicable Solid policy and scripts/check-control-ui-controllers.mts, so the changed-file guard rejects this patch. Replace this helper with the existing primitive rather than maintaining a second viewport-subscription implementation.
  • Fit the responsive CSS within the existing growth allowance (P2) - The added phone rules cause the exact-head control-ui-performance check to fail: this PR adds 1,837 raw CSS bytes and 369 gzip bytes while the base already exceeds both caps. In that state the checker permits only 64 bytes of build variance, so the existing base overage does not exempt this additional growth. Consolidate or replace existing Cron rules to bring the change within the enforced allowance without raising budgets or weakening the check.

Findings

  • [P1] Reuse the shared media-query primitive — ui/src/pages/cron/cron-page.tsx:19-26
  • [P2] Fit the responsive CSS within the existing growth allowance — ui/src/styles/cron.css:1133-1137

Tests

  • Missing end-to-end proof: A base-red/head-green execution of the added regression tests is not supplied.
Agent review details

How this fits together

The Control UI presents Gateway-owned automation jobs through the Cron page, list renderer, shared status presentation, and responsive styles; existing callbacks continue to own navigation and mutations.

flowchart LR
  A[Gateway job inventory] --> B[Cron page owner]
  B --> C[Cron page presentation]
  D[Browser viewport] --> C
  C --> E[Toolbar and job rows]
  F[Responsive Cron styles] --> E
  E --> G[Existing job actions and detail view]
Loading

Technical review

Best possible solution:

Keep the compact design, replace the local viewport subscription with createMediaQuery, and consolidate the responsive CSS until its existing performance gate passes.

Do we have a high-confidence way to reproduce the issue?

The original responsive CSS and supplied before screenshot establish the tall-card and unlabeled-create presentation; no target code was executed during this review.

Is this the best way to solve the issue?

The presentation approach fits the existing owners, but its viewport lifecycle should use the shared primitive and its stylesheet must satisfy the existing growth limit.

Full review comments:

  • [P1] Reuse the shared media-query primitive — ui/src/pages/cron/cron-page.tsx:19-26
    The new createPhoneLayout duplicates createMediaQuery in ui/src/lib/reactive/platform.ts, which already handles matchMedia fallback, reactive updates, shared subscriptions, and disposal. Its direct addEventListener call in this TSX file is also explicitly forbidden by the applicable Solid policy and scripts/check-control-ui-controllers.mts, so the changed-file guard rejects this patch. Replace this helper with the existing primitive rather than maintaining a second viewport-subscription implementation.
    Confidence: 0.99
  • [P2] Fit the responsive CSS within the existing growth allowance — ui/src/styles/cron.css:1133-1137
    The added phone rules cause the exact-head control-ui-performance check to fail: this PR adds 1,837 raw CSS bytes and 369 gzip bytes while the base already exceeds both caps. In that state the checker permits only 64 bytes of build variance, so the existing base overage does not exempt this additional growth. Consolidate or replace existing Cron rules to bring the change within the enforced allowance without raising budgets or weakening the check.
    Confidence: 0.99

Overall correctness: patch is incorrect
Overall confidence: 0.97

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning medium; reviewed against 49600b5cf8f3.

Provenance checked

  • Mobile row labels and secondary facts changes intended behavior with a stated reason (f94f945: The earlier redesign labeled mobile facts to make stacked values understandable and preserved all list information.)
  • Phone creation-button presentation changes intended behavior with a stated reason (5413688: The native-embed and phone-width work adapted controls and touch targets for narrow layouts; this PR explains restoring the creation label to distinguish its meaning.)
  • Schedule and effective-next-run presentation keeps the original intent (0b1cd5f: Authored schedule and effective runtime deadline are separate facts; the patch retains their existing formatters and next-run owner.)

Testing

Proof path: shipped entry point.

Security

None.

Evidence

Acceptance criteria:

  • pnpm check:control-ui-controllers
  • pnpm lint:ui:styles
  • pnpm tsgo:ui
  • pnpm test ui/src/pages/cron/view.test.ts --maxWorkers=1
  • pnpm ui:check-performance:base

What I checked:

Likely related people:

  • Peter Steinberger: Raw commit 17a533c adds ui/src/styles/cron.css:279 relative to its recorded parents. This identifies author metadata, not feature responsibility or a PR merger. (role: source-line author; confidence: high; commits: 17a533ce2689; files: ui/src/styles/cron.css)
  • Vyctor H. Brzezowski: Raw commit 06a71d7 adds ui/src/styles/cron.css:260 relative to its recorded parents. This identifies author metadata, not feature responsibility or a PR merger. (role: source-line author; confidence: high; commits: 06a71d75b01e; files: ui/src/styles/cron.css)

PR surface

Source +180, Tests +35. Total +215 across 6 files. Added test files: 0.

View PR surface stats
Area Files Added Removed Net
Source 5 229 49 +180
Tests 1 35 0 +35
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 6 264 49 +215

Labels

Label changes:

  • add P3: This is phone-layout polish for an existing usable workflow; the branch repairs do not establish an urgent runtime regression.
  • add proof: sufficient: Contributor real behavior proof is sufficient.
  • add proof: 📸 screenshot: Contributor real behavior proof includes screenshot evidence.
  • add rating: 🦪 silver shellfish: Overall readiness is 🦪 silver shellfish; proof is 🦞 diamond lobster and patch quality is 🦪 silver shellfish.
  • add status: ⏳ waiting on author: ClawSweeper has contributor-facing work open and is waiting for author action.

Label justifications:

  • P3: This is phone-layout polish for an existing usable workflow; the branch repairs do not establish an urgent runtime regression.
  • rating: 🦪 silver shellfish: Overall readiness is 🦪 silver shellfish; proof is 🦞 diamond lobster and patch quality is 🦪 silver shellfish.
  • status: ⏳ waiting on author: ClawSweeper has contributor-facing work open and is waiting for author action.
  • proof: sufficient: Contributor real behavior proof is sufficient.
  • proof: 📸 screenshot: Contributor real behavior proof includes screenshot evidence.

Rating scale

6/6 🦀 challenger crab · 5/6 🦞 diamond lobster · 4/6 🐚 platinum hermit · 3/6 🦐 gold shrimp · 2/6 🦪 silver shellfish · 1/6 🧂 unranked krab. Overall follows the weaker of proof and patch quality; ✨ marks media proof (a screenshot, video, or linked artifact) that directly shows the changed behavior.

Workflow

ClawSweeper edits this one comment on every review. Comment @clawsweeper re-review for a fresh review only. Repair and merge execution lanes are retired.

Reviewed November 1, 2026, 9:50 AM ET / 14:50 UTC.

@vyctorbrzezowski
vyctorbrzezowski merged commit 740334c into main Nov 2, 2026
75 of 77 checks passed
@vyctorbrzezowski
vyctorbrzezowski deleted the brzezowski/mobile-automations-cards branch November 2, 2026 14:14
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Nov 3, 2026
…90382)

Compact phone Automations job cards while preserving scope selection, creation permissions, schedules, run actions, focus and failure visibility. Retain complete schedule text checks and verify the phone creation action. Twelve targeted view tests, typed lint and test typechecking passed.

Maintainer-authorized landing with the performance-budget exception and without waiting for remaining checks.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

app: web-ui App: web-ui P3 Low-priority cleanup, docs, polish, ergonomics, or speculative work. proof: 📸 screenshot Contributor real behavior proof includes screenshot evidence. proof: sufficient ClawSweeper judged the real behavior proof convincing. rating: 🦪 silver shellfish Thin PR readiness signal; proof, validation, or implementation needs work. size: M status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant