Skip to content

fix(ui): restore the composer model picker dialog - #123090

Merged
steipete merged 5 commits into
mainfrom
steipete/model-picker-dialog-regression-92370e
Aug 13, 2026
Merged

steipete merged 5 commits into
mainfrom
steipete/model-picker-dialog-regression-92370e

Conversation

@steipete

@steipete steipete commented Aug 13, 2026 •

Copy link
Copy Markdown
Contributor

What Problem This Solves

Fixes a default-path UI regression where PR #122964 replaced the chat and new-session composers' rich model-picker dialog with the settings-style select. That split the composer into two plain dropdowns, removed search and provider grouping, and truncated the default model label.

Why This Change Was Made

The composer picker is a distinct product surface: it combines model search, provider grouping, context and capability metadata, CLI-agent targets, and the session-override footer in one dialog. This partial revert restores that shipped composer experience while keeping #122964's channel-picker unification and shared model picker on the settings surfaces where that simpler control fits.

The restored chat-model-picker.ts is byte-identical to the parent of #122964's merge commit (edcf1974838~1). One additional bounded test-only change lets the responsive composer test wait for viewport resizing to settle before reading bounding boxes, removing grouped-run timing flakiness without changing product behavior.

User Impact

Model picking on the default chat and new-session composers returns to a compact single trigger that opens the searchable, provider-grouped dialog. Talk, Memory, Session Observer, Automations, Agents, model defaults, Workboard, and other settings pages keep the unified settings picker. There are no config or protocol changes.

Evidence

Provenance: partial revert of PR #122964 / commit edcf1974838, limited to the composer model-picker regression while retaining its channel and settings unification.

Chat composer

Before: split plain selects After: restored compact picker
Chat composer before Chat composer after
Before: plain model select open After: searchable grouped dialog open
Chat picker open before Chat picker open after

New-session composer

Before: split plain selects After: restored compact picker
New-session composer before New-session composer after
Before: plain model select open After: searchable grouped dialog open
New-session picker open before New-session picker open after

Focused proof:

  • node scripts/run-vitest.mjs ui/src/pages/chat/chat-view.test.ts ui/src/pages/new-session/model-control.test.ts ui/src/components/model-picker.test.ts — 3 files, 277 tests passed.
  • node scripts/run-vitest.mjs ui/src/e2e/chat-flow.models-reasoning.e2e.test.ts ui/src/e2e/chat-only-model.e2e.test.ts ui/src/e2e/new-session-page.places.e2e.test.ts ui/src/e2e/model-alias-display.e2e.test.ts — 4 files, 24 tests passed.
  • node scripts/run-vitest.mjs ui/src/e2e/chat-composer-redesign.e2e.test.ts ui/src/e2e/chat-composer-accessory-focus.e2e.test.ts ui/src/e2e/session-suggestions.e2e.test.ts ui/src/e2e/chat-flow.follow-ups.e2e.test.ts ui/src/e2e/new-session-page.catalog-reconnect.e2e.test.ts ui/src/e2e/new-session-page.workspace-memory.e2e.test.ts ui/src/pages/chat/chat-responsive.browser.test.ts — 6 files, 47 tests passed.
  • Post-rebase: node scripts/run-vitest.mjs ui/src/pages/chat/chat-view.test.ts ui/src/pages/new-session/model-control.test.ts — 2 files, 275 tests passed.
  • Inventory restoration commit 0be822e099c: node scripts/run-vitest.mjs ui/src/components/web-awesome-migration.node.test.ts — 1 file, 3 tests passed.
  • node scripts/check-changed.mjs -- <all changed files> — all selected lanes passed.
  • pnpm ui:i18n:baseline — no diff; the customModel English key remains for the settings picker.
  • Codex autoreview (gpt-5.6-sol, high): clean, no accepted or actionable findings; patch judged correct (0.98).

Production LOC is +1110/-269 and tests are +592/-399. The positive production delta restores the 719-line shipped picker deleted by #122964; it is regression restoration rather than a new parallel capability.

AI-assisted: Yes.

CI dialog-leak diagnosis

  • CI run 31685862983 failed only src/components/input-dialog.test.ts (10 tests): a leaked open “Approve DM access” <openclaw-modal-dialog> from ui/src/pages/channels/view.pairing.test.ts poisoned the dialog-owning file in the same worker. Its renderInto helper appended containers to document.body without afterEach cleanup. This was a latent cross-test leak surfaced by the branch's changed test scheduling, not a behavior regression in the PR.
  • Producer-owned fix: view.pairing.test.ts now tracks rendered containers and removes them in afterEach, restoring the repo test-hygiene invariant that global DOM state is cleaned and suites remain safe under --isolate=false.
  • Causality proof in the original serial-worker execution order: OPENCLAW_VITEST_MAX_WORKERS=1 node scripts/run-vitest.mjs ui/src/pages/channels/view.pairing.test.ts ui/src/components/input-dialog.test.ts. Pre-fix: 1 shard failed with the exact CI signature. Post-fix: 2 files, 17/17 tests passed.

Persisted override preservation

  • The restored composer picker now ports improve: one channel picker and one model picker across the Control UI #122964's synthesized-override row in chat-model-controls.ts: when a persisted session override is absent from a non-empty usable catalog, it remains a selectable row. The synthesis stays gated on a usable catalog so the true No models available empty state is preserved.
  • Regression coverage: chat-view.test.ts now proves that a persisted override missing from the catalog is synthesized as a selectable row.
  • Focused proof: node scripts/run-vitest.mjs ui/src/pages/chat/chat-view.test.ts ui/src/pages/new-session/model-control.test.ts — 2 files, 276 tests passed.
  • Fresh Codex autoreview after the override repair: clean, no accepted or actionable findings; patch judged correct (0.96).

#123085 reconciliation

The final branch reconciles #123085 with the restored composer picker. The rebase had merged #123085's wa-select label-width mechanics into this restored dialog surface, removing the old trigger reservation in chat/layout.css and leaving a new-session label-width test block that referenced the unified-picker helper removed by the partial revert. Commit 55f06ec7ca5 restores chat/layout.css and chat-responsive.browser.test.ts to their exact pre-#122964 state and removes that composer-only label-width block from new-session-page.workspace-memory.e2e.test.ts. #123085's shared select-picker.ts fix and new-session.css line remain because the settings picker surfaces still use them.

  • Focused proof: node scripts/run-vitest.mjs ui/src/pages/chat/chat-responsive.browser.test.ts ui/src/e2e/new-session-page.workspace-memory.e2e.test.ts — 2 shards, 13 tests passed.
  • Fresh Codex autoreview of the reconciled branch: clean, no accepted or actionable findings; patch judged correct (0.98).
  • Follow-up: fix: picker option labels collapse to ellipsis at phone widths #123085's label-width E2E coverage lost its composer venue when the shipped dialog was restored; it may be re-homed on a settings picker surface where the unified select still exists.

@clawsweeper

clawsweeper Bot commented Aug 13, 2026

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

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

@steipete
steipete marked this pull request as ready for review August 13, 2026 09:00
@openclaw-barnacle openclaw-barnacle Bot added app: web-ui App: web-ui size: XL maintainer Maintainer-authored PR labels Aug 13, 2026
@clawsweeper clawsweeper Bot added merge-risk: 🚨 compatibility 🚨 May break existing users, config, migrations, defaults, or upgrade paths. P1 High-priority user-facing bug, regression, or broken workflow. proof: 📸 screenshot Contributor real behavior proof includes screenshot evidence. proof: sufficient ClawSweeper judged the real behavior proof convincing. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action. labels Aug 13, 2026
@clawsweeper

clawsweeper Bot commented Aug 13, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge. Reviewed August 13, 2026, 6:13 AM ET / 10:13 UTC.

ClawSweeper review

What this changes

Restores the searchable, provider-grouped model dialog for chat and new-session composers while retaining the compact shared picker on settings pages.

Regression provenance

Possible regression — suspected (reviewed change). No predecessor PR is attributed.

Merge readiness

⚠️ Ready for maintainer review - 4 items remain

Keep open for maintainer review: current main still uses the compact composer picker, while this PR restores the documented rich workflow and has strong visible proof. The prior persisted-override finding is addressed; the remaining decision is whether the composer is intentionally a separate long-term picker surface.

Priority: P1
Reviewed head: eb50abf31bb1d2a12b5039cd545d1ce590f493cd
Owner decision: Required. See Decision needed.

Review scores

Measure Result What it means
Overall readiness 🐚 platinum hermit (4/6) The patch and real UI evidence are strong; remaining work is a maintainer product-boundary decision rather than an identified code defect.
Proof confidence 🦞 diamond lobster (5/6) ✨ media proof bonus Sufficient (screenshot): Before/after composer screenshots and focused after-fix browser and unit evidence in the PR body directly support the visible restored behavior.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Verification

Check Result Evidence
Real behavior Verified Sufficient (screenshot): Before/after composer screenshots and focused after-fix browser and unit evidence in the PR body directly support the visible restored behavior.
Evidence reviewed 6 items Current-main behavior: Current composer controls render the compact shared model picker rather than the restored composer dialog.
Restored composer boundary: The PR routes chat and new-session controls through the dedicated searchable picker, including model and target selection.
Caller coverage: New-session passes its catalog and CLI-agent targets into the restored composer picker instead of using a separate target select.
Findings None None.
Security None None.

How this fits together

The Control UI turns Gateway model-catalog data and session overrides into composer controls. Selecting a model updates the active chat session or the target of a new session.

flowchart LR
  Catalog[Gateway model catalog] --> Controls[Composer model controls]
  Overrides[Session override or default] --> Controls
  Controls --> Dialog[Composer model dialog]
  Dialog --> Selection[Model or CLI target]
  Selection --> Session[Chat or new-session state]
Loading

Decision needed

Question Recommendation
Should chat and new-session composers retain a dedicated rich picker instead of extending the shared settings picker? Keep the composer-specific picker: Accept the distinct composer workflow and proceed once exact-head checks are green.

Why: This PR deliberately reintroduces a substantial composer-specific surface after a merged picker-unification change; source and screenshots cannot settle the lasting product boundary.

Before merge

  • Resolve merge risk (P1) - Production grows by 868 lines, or 149 excluding the restored 719-line dialog; that is justified only if maintainers accept the composer’s search, grouping, targets, and session footer as a distinct boundary from settings.
  • Resolve merge risk (P1) - Merging restores a separate picker alongside the shared settings picker, so future model-selection behavior can drift unless that ownership boundary is intentional.
  • Complete next step (P2) - The PR is maintainer-labeled and needs an explicit product-boundary choice, not an automated repair.
Agent review details

Security

None.

PR surface

Source +868, Tests +222. Total +1090 across 22 files.

View PR surface stats
Area Files Added Removed Net
Source 7 1127 259 +868
Tests 15 629 407 +222
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 22 1756 666 +1090

Review metrics

Metric Value Why it matters
Production versus test delta production +149 excluding a restored 719-line picker, tests +222 The branch revives a dedicated composer UI, making the permanent ownership boundary more important than raw test churn.

Merge-risk options

Maintainer options:

  1. Keep the composer boundary (recommended)
    Accept the separate picker after confirming that its richer interaction is intentional and exact-head validation completes.
  2. Pause for a shared design
    Do not merge if maintainers want one permanent picker implementation across composer and settings surfaces.

Technical review

Best possible solution:

Keep the dedicated composer dialog if maintainers confirm it is a distinct workflow; otherwise design a shared primitive that supports composer needs without changing settings behavior.

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

Yes, from source: current main routes composers through the compact shared picker, while the PR restores the searchable grouped dialog; no live run was executed during this read-only review.

Is this the best way to solve the issue?

Unclear: the restoration has focused proof and preserves the prior override invariant, but maintainers must choose whether a separate composer picker is the intended long-term design.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning high; reviewed against 2278ca6952ea.

Labels

Label changes:

  • add proof: sufficient: Contributor real behavior proof is sufficient. Before/after composer screenshots and focused after-fix browser and unit evidence in the PR body directly support the visible restored behavior.
  • add rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🦞 diamond lobster and patch quality is 🐚 platinum hermit.
  • add status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Sufficient (screenshot): Before/after composer screenshots and focused after-fix browser and unit evidence in the PR body directly support the visible restored behavior.
  • remove rating: 🦐 gold shrimp: Current PR rating is rating: 🐚 platinum hermit, so this older rating label is no longer current.
  • remove status: ⏳ waiting on author: Current PR status label is status: 👀 ready for maintainer look.

Label justifications:

  • P1: The PR repairs the default chat and new-session model-selection workflow.
  • merge-risk: 🚨 compatibility: Existing session overrides and model catalog selections move back to a different picker implementation.
  • rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🦞 diamond lobster and patch quality is 🐚 platinum hermit.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Sufficient (screenshot): Before/after composer screenshots and focused after-fix browser and unit evidence in the PR body directly support the visible restored behavior.
  • proof: sufficient: Contributor real behavior proof is sufficient. Before/after composer screenshots and focused after-fix browser and unit evidence in the PR body directly support the visible restored behavior.
  • proof: 📸 screenshot: Contributor real behavior proof includes screenshot evidence. Before/after composer screenshots and focused after-fix browser and unit evidence in the PR body directly support the visible restored behavior.

Evidence

What I checked:

Likely related people:

  • joshavant: Introduced the current composer control flow and default/selection handling. (role: feature introducer; confidence: high; commits: 0901efe3ddf6; files: ui/src/pages/chat/components/chat-model-controls.ts)
  • steipete: Authored both the merged picker unification and this targeted composer restoration. (role: recent area contributor; confidence: high; commits: edcf19748381, eb50abf31bb1; files: ui/src/pages/chat/components/chat-model-picker.ts, ui/src/pages/chat/components/chat-model-controls.ts)

Rank-up moves

Optional improvements that raise the rating; they are not merge blockers.

  • Confirm the composer-versus-settings picker boundary and wait for exact-head checks to finish green.

Rating scale

Score Internal tier Crab rank Meaning
6/6 S 🦀 challenger crab Exceptional readiness
5/6 A 🦞 diamond lobster Very strong readiness
4/6 B 🐚 platinum hermit Good normal PR; ordinary maintainer review
3/6 C 🦐 gold shrimp Useful, but confidence is limited
2/6 D 🦪 silver shellfish Proof or implementation needs work
1/6 F 🧂 unranked krab Not merge-ready
N/A NA 🌊 off-meta tidepool Rating does not apply

Overall follows the weaker of proof and patch quality.
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics.

Workflow

  • ClawSweeper keeps one durable marker-backed review comment per issue or PR.
  • Re-runs edit this comment so the latest verdict, findings, and automation markers stay together instead of adding duplicate bot comments.
  • A fresh review can be triggered by eligible @clawsweeper re-review comments, exact-item GitHub events, scheduled/background review runs, or manual workflow dispatch.
  • PR/issue authors and users with repository write access can comment @clawsweeper re-review or @clawsweeper re-run on an open PR or issue to request a fresh review only.
  • Maintainers can also comment @clawsweeper review to request a fresh review only.
  • Fresh-review commands do not start repair, autofix, rebase, CI repair, or automerge.
  • Maintainer-only repair and merge flows require explicit commands such as @clawsweeper autofix, @clawsweeper automerge, @clawsweeper fix ci, or @clawsweeper address review.
  • Maintainers can comment @clawsweeper explain to ask for more context, or @clawsweeper stop to stop active automation.

History

Review history (2 earlier review cycles)
  • reviewed 2026-08-13T09:06:19.933Z sha 9d914aa :: found issues before merge. :: [P1] Preserve unavailable current model overrides
  • reviewed 2026-08-13T09:22:49.422Z sha 0be822e :: needs changes before merge. :: [P1] Preserve unavailable current model overrides

@clawsweeper clawsweeper Bot removed the proof: sufficient ClawSweeper judged the real behavior proof convincing. label Aug 13, 2026
Partial revert of #122964: the chat/new-session composer returns to the
rich searchable model picker dialog (provider groups, CLI-agent targets
folded inside). Settings pages keep the shared unified picker.
…ntory

The restored composer picker legitimately owns its details-menu and ARIA
combobox usage; #122964 had removed it from both expected lists.
view.pairing.test.ts mounted containers (including an open
openclaw-modal-dialog from the approve-prompt tests) into document.body
without cleanup, poisoning later dialog-owning test files in the same
worker. Surfaced by this branch's changed test scheduling in checks-ui;
input-dialog.test.ts then saw the leaked 'Approve DM access' dialog.
…drops it

Port #122964's synthesized-override row into the restored composer
picker: a session pinned to a retired/unavailable model gets its row in
the dialog so the selection stays visible and escapable. An entirely
empty catalog keeps its no-models state.
@steipete
steipete force-pushed the steipete/model-picker-dialog-regression-92370e branch from 3dbe421 to eb50abf Compare August 13, 2026 10:05
@clawsweeper clawsweeper Bot added proof: sufficient ClawSweeper judged the real behavior proof convincing. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. and removed rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action. labels Aug 13, 2026
The rebase merged #123085's wa-select label-width mechanics into the
restored dialog picker: its chat/layout.css hunks dropped the old
trigger reservation while its tests asserted the new geometry, and its
new-session e2e block targeted a wa-select that no longer exists there.
Restore the pre-#122964 chat layout CSS and responsive test, and drop
the unified-picker label block from the new-session e2e. #123085's
shared select-picker fix stays for the settings surfaces that use it.
@steipete steipete self-assigned this Aug 13, 2026
@steipete

Copy link
Copy Markdown
Contributor Author

Addressing the P1 and rank-up moves from #123090 (comment):

  • The persisted session-override row is fixed in eb50abf31bb. The restored composer now synthesizes an override missing from a non-empty usable catalog, and the regression test proves it remains selectable while preserving the true empty-catalog state. The focused 276-test unit run is green.
  • Maintainer product-boundary decision: keep the composer-specific dialog. The production growth restores the shipped 719-line searchable, provider-grouped composer dialog deleted by improve: one channel picker and one model picker across the Control UI #122964; it is a revert-restoration of the richer composer workflow, not a new parallel capability. Settings surfaces continue to own the shared select picker.
  • Exact-head CI is green for 55f06ec7ca5: run 31691209127.

@steipete

Copy link
Copy Markdown
Contributor Author

Land-ready proof for exact head 55f06ec7ca5:

  • Exact-head CI: run 31691209127 — terminal green.
  • Focused unit proof: 277 tests passed for the restored picker surface; 276 tests passed for the synthesized persisted-override repair.
  • Focused E2E/browser proof: 24 + 47 + 13 tests passed across composer model flows, follow-ups, reconnect/workspace behavior, and final fix: picker option labels collapse to ellipsis at phone widths #123085 reconciliation.
  • Inventory restoration: 3 tests passed.
  • Dialog leak causality pair: 17 tests passed in the original serial-worker order after producer-owned cleanup.
  • Changed-file gates: all selected check-changed lanes passed.
  • Fresh Codex autoreview: clean, no accepted or actionable findings; patch judged correct (0.98).
  • Classified LOC: production approximately +1130/-269 (revert-restoration plus override port); tests approximately +640/-430. The production growth restores the shipped 719-line dialog rather than adding a new capability.
  • Before/after screenshots for both chat and new-session composers, including open-dialog states, are already in the PR body.

@steipete
steipete merged commit 983af02 into main Aug 13, 2026
105 checks passed
@steipete
steipete deleted the steipete/model-picker-dialog-regression-92370e branch August 13, 2026 10:45
@steipete

Copy link
Copy Markdown
Contributor Author

Merged via squash.

steipete added a commit that referenced this pull request Aug 13, 2026
Repairs main's red check-lint caused by the #123090 restore.
steipete added a commit that referenced this pull request Aug 13, 2026
Repairs main's red check-lint caused by the #123090 restore.
steipete added a commit that referenced this pull request Aug 13, 2026
…23130)

* fix(control-ui): recover auth-cold model pickers

Keep configured auth-cold models visible but disabled in chat and new-session, block submission, and link Model Setup. Fixes #123080.

* fix(control-ui): preserve rebased model picker behavior

* fix(ui): split composer model picker under the lint size cap

Repairs main's red check-lint caused by the #123090 restore.

* fix(ui): align auth-cold picker CI contracts
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Aug 14, 2026
* fix(ui): restore the composer model picker dialog

Partial revert of openclaw#122964: the chat/new-session composer returns to the
rich searchable model picker dialog (provider groups, CLI-agent targets
folded inside). Settings pages keep the shared unified picker.

* test(ui): restore chat-model-picker in the Web Awesome ownership inventory

The restored composer picker legitimately owns its details-menu and ARIA
combobox usage; openclaw#122964 had removed it from both expected lists.

* test(ui): stop leaking pairing-prompt modals into document.body

view.pairing.test.ts mounted containers (including an open
openclaw-modal-dialog from the approve-prompt tests) into document.body
without cleanup, poisoning later dialog-owning test files in the same
worker. Surfaced by this branch's changed test scheduling in checks-ui;
input-dialog.test.ts then saw the leaked 'Approve DM access' dialog.

* fix(ui): keep a persisted model override selectable when the catalog drops it

Port openclaw#122964's synthesized-override row into the restored composer
picker: a session pinned to a retired/unavailable model gets its row in
the dialog so the selection stays visible and escapable. An entirely
empty catalog keeps its no-models state.

* fix(ui): reconcile openclaw#123085 with the restored composer picker

The rebase merged openclaw#123085's wa-select label-width mechanics into the
restored dialog picker: its chat/layout.css hunks dropped the old
trigger reservation while its tests asserted the new geometry, and its
new-session e2e block targeted a wa-select that no longer exists there.
Restore the pre-openclaw#122964 chat layout CSS and responsive test, and drop
the unified-picker label block from the new-session e2e. openclaw#123085's
shared select-picker fix stays for the settings surfaces that use it.
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Aug 14, 2026
…enclaw#123130)

* fix(control-ui): recover auth-cold model pickers

Keep configured auth-cold models visible but disabled in chat and new-session, block submission, and link Model Setup. Fixes openclaw#123080.

* fix(control-ui): preserve rebased model picker behavior

* fix(ui): split composer model picker under the lint size cap

Repairs main's red check-lint caused by the openclaw#123090 restore.

* fix(ui): align auth-cold picker CI contracts
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 maintainer Maintainer-authored PR merge-risk: 🚨 compatibility 🚨 May break existing users, config, migrations, defaults, or upgrade paths. P1 High-priority user-facing bug, regression, or broken workflow. proof: 📸 screenshot Contributor real behavior proof includes screenshot evidence. proof: sufficient ClawSweeper judged the real behavior proof convincing. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. size: XL status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant