Skip to content

Cap services list width in the preview drawer - #1237

Merged
nicolasalt merged 2 commits into
mainfrom
shipit/limit-services-list-width-vkqhio
Jun 10, 2026
Merged

Cap services list width in the preview drawer#1237
nicolasalt merged 2 commits into
mainfrom
shipit/limit-services-list-width-vkqhio

Conversation

@nicolasalt

@nicolasalt nicolasalt commented Jun 10, 2026

Copy link
Copy Markdown
Collaborator

Summary

On a wide preview panel, the services list stretched each row edge-to-edge and the bulk action buttons sat far to the right, disconnected from the list below. This caps the list width and left-aligns both the list and the header controls so the panel stays readable and visually consistent regardless of width.

Rationale

ServiceList's container was w-full, inheriting the full width of the (resizable, potentially very wide) preview drawer. Capping at max-w-2xl (672px) comfortably fits a service name, mode/port badges, and the action cluster without wasted whitespace. The list and the header's bulk buttons are then left-aligned (rather than centered / right-pinned) so they line up with each other and with the panel's left edge — a wide panel no longer scatters related controls across its full width.

Changes

  • ServiceList.tsx: container changed from w-full to w-full max-w-2xl — rows cap at 672px and align left.
  • PreviewServicesDrawer.tsx: the bulk-action group (Restart all / Stop all / Start all) dropped ml-auto, so it sits next to the "X of Y running" count on the left instead of pinned to the far-right edge.

Test plan

  • npx vitest run src/client/components/PreviewServicesDrawer.test.tsx — 11 passed.
  • Manual: open the Preview tab, expand the Services drawer, and widen the right panel — service rows stay at a fixed max width aligned to the left, and the bulk buttons stay grouped with the running count instead of drifting to the right edge.

…caps at `max-w-2xl` (672px) and centers with `mx-au
@nicolasalt nicolasalt added the enhancement Improvement to an existing feature label Jun 10, 2026
…t-to-right consistently: capped-width list on the l
@nicolasalt
nicolasalt merged commit 05b2964 into main Jun 10, 2026
3 checks passed
@nicolasalt
nicolasalt deleted the shipit/limit-services-list-width-vkqhio branch June 10, 2026 19:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement Improvement to an existing feature

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant