Skip to content

[Desktop/Web] Model selector should scale to the available screen size (fixed ~284px popover feels cramped) #48789

Closed as not planned

Description

@infucv7

Description

When I open the model selector ("Choose model") in OpenCode Desktop, it renders as a very small, compressed popover. I'm on a large monitor with plenty of free space, yet the list only shows a handful of rows before scrolling and long model names get truncated. It feels cramped for no reason.

Current behavior

  • The popover has a fixed, narrow width. In packages/app/src/components/dialog-select-model.tsx the content is rendered with class="w-[284px] overflow-hidden ...".
  • The list keeps a short visible height (with a sticky provider group label), so only a few models are visible at a time.
  • Long model names (e.g. claude-sonnet-4-..., gpt-...) are truncated even inside the dropdown, where there is clearly room.

Expected behavior

  • The selector should scale with the window/viewport: a taller list (more visible rows) and a wider popover when the screen allows it, instead of a fixed tiny box.
  • Keep a sensible upper bound (e.g. max-h/max-w relative to viewport) and stay scrollable on small screens.
  • Show full model names in the list (no ellipsis) when there is available space.
  • Preserve the current compact behavior on small windows/mobile.

Why this matters

  • Users with large screens waste space and scroll unnecessarily to find a model.
  • The number of models is large (OpenCode Zen alone lists ~79), so seeing only a handful of rows makes browsing painful.

Related

Environment

  • UI: OpenCode Desktop (also affects Web)
  • OS: Windows

Activity

  1. par4987 commented on Sep 23, 2026

    @par4987

    I validated a fix for this by patching my local Desktop install (byte-identical in-place edit of the shipped assets, since I can't rebuild the app) — the behavior matches what's described under "Expected behavior" below. Concrete source changes that resolve it, all in packages/app:

    1. Selector popover — src/components/dialog-select-model.tsx (ModelSelectorPopoverV2View)

    • MenuV2.Content is class="w-[284px] ..." → make it viewport-relative, e.g. w-[min(90vw,560px)].
    • ScrollView data-slot="model-selector-scroll" is class="max-h-[220px] min-h-0" → max-h-[60vh].

    The list stays scrollable on small screens either way, so this only changes how much is visible at once (~3x more rows on a normal monitor).

    2. "Manage models" dialog — src/components/dialog-manage-models.tsx (DialogManageModelsV2)

    • <DialogV2 size="large" ...> → size="x-large".

    x-large already exists in dialog-v2 (width: min(100vw - 32px, 980px); height: min(100vh - 92px, 600px)), so it needs no new styles and degrades gracefully on small windows. large is a fixed 640×480, which is tight even for stock providers — with several custom providers (I'm at 1000+ models) it's unusable without scrolling constantly.

    3. Scrollbar visibility — .settings-v2-panel in settings-v2/settings-v2.css

    • The panel scrolls but hides the scrollbar completely (scrollbar-width: none + ::-webkit-scrollbar { display: none }), so there is no affordance that more models are below — wheel/trackpad works, but it reads as a cut-off list.

    Suggest scrollbar-width: thin plus a visible ::-webkit-scrollbar thumb for these scroll areas (the ScrollView component follows the same pattern with its custom thumb at opacity: 0, which only flashes while actively scrolling).

    4. Model names

    • SettingsRowV2 title={item.name} (and the truncate span in the popover items) ellipsizes even when the dialog has plenty of horizontal room. In an x-large dialog, wrapping (white-space: normal) or dropping truncate when space allows would satisfy the "no ellipsis when there is available space" expectation from this issue.

    The local patch I tested used exactly these values (560px wide popover, 60vh list, x-large manage dialog, visible scrollbars, wrapping titles) and the result feels like the intended fix rather than a workaround. Happy to open a PR against dev with the source-level changes if that's useful.

  2. par4987 commented on Oct 23, 2026

    @par4987

    Following up on my earlier comment validating this fix locally — the patch is still working against the current build and addresses all four points raised in the issue.

    I put together a written-up version of the patch (concrete source changes, values, and validation notes) as a gist:

    https://gist.github.com/par4987/da9c9b6b7657078aee90fa4238fb752d

    Summary of the changes (full details in the gist):

    1. Selector popover (packages/app/src/components/dialog-select-model.tsx) — w-[284px] -> w-[min(90vw,560px)], max-h-[220px] -> max-h-[60vh] (~3x more rows on a normal monitor).
    2. "Manage models" dialog (packages/app/src/components/dialog-manage-models.tsx) — size="large" (640x480) -> size="x-large" (already defined, degrades gracefully on small windows).
    3. Scrollbar visibility (.settings-v2-panel in settings-v2/settings-v2.css) — scrollbar-width: none -> hin + visible ::-webkit-scrollbar thumb (the panel scrolls but hides the scrollbar, so it reads as a cut-off list).
    4. Model names — drop runcate/white-space when space allows so full names show in the wider dialog.

    Happy to open a PR against dev with the source-level changes if that's useful — just let me know the preferred values/structure and I'll adapt them.

  3. opencodejr commented on Oct 28, 2026

    @opencodejr
    Contributor

    Thanks for the detailed write-up!

    The code you point to (packages/app/src/components/dialog-select-model.tsx and its fixed w-[284px] popover) is from OpenCode v1 (versions 0.x/1.x). v1 now only gets fixes for critical bugs, such as data loss, security problems or crashes with no workaround. A layout change like resizing the model picker is unlikely to happen there.

    Please try upgrading to v2 (@opencode/cli, 2.x). The v2 desktop/web app has a reworked model picker that opens as a dialog up to 480px wide, sized to the window, instead of a fixed 284px popover.

    Related issues, most relevant first:

    If you see the same problem on v2, or think this is critical, please reply here with your opencode --version and a screenshot.

  4. schittli commented on Oct 28, 2026

    @schittli

    Hello!

    This is a very important feature because models change every week.
    That’s why every single developer must figure it out for themselves: Which model should I choose today???

    😍 That’s why our models have additional info-texts:

    so that OpenCode users can intuitively choose the right one from the latest models at any time. For example:
    (The first element is the context window size; the second is the cost.)

    • 900k 0.5: GPT 6 Luna — fast; simple tasks and subagents
    • 1M 0.5: Claude Haiku 5.5 — fast; simple tasks
    • 1M 1.5+5: Mistral Large 4 — EU-hosted; confidential data
    • 1M 1.5+5: GLM 5.3 — EU-hosted; confidential data
    • 1M 2+10: Claude Sonnet 5.5 — MCP/tools; dialogue and main coding agent
    • 900k 2+10: GPT 6.1 Sol — complex analysis; with reasoning
    • 1M 4+20: Claude Opus 5.5 — complex analysis; final review
    • 1M 10+50: GPT 6 Astra — top model, use only if you really need it
    • 1M 1+5: GPT 6.1 Terra — MCP/tools; main coding agent
    • 1M 10+50: Claude Fable 5.1 — top model, use only if you really need it

    So please, please, make use of the screen width while it’s available and don’t cut off text.
    Or, at least, please allow us to adjust the width in the settings. 😊

    Thanks a lot for your great work! 🙏
    kind regards,
    Thomas

  5. opencodejr commented on Oct 29, 2026

    @opencodejr
    Contributor

    Closing this as not planned. The fixed 284px model popover described here is in OpenCode v1, which only gets critical fixes, and we haven't heard that the problem also happens on v2. In v2, the desktop/web model picker is a wider dialog (up to 480px) that fits the window.

    If you still find the picker too cramped on v2, please open a new issue with your opencode --version and a screenshot. Thanks for the detailed report!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions