Skip to content

fix: improve agent detail modal layout and fallback chain display#701

Open
Fail-Safe wants to merge 1 commit intoRightNow-AI:mainfrom
Fail-Safe:fix/agent-modal-ui
Open

fix: improve agent detail modal layout and fallback chain display#701
Fail-Safe wants to merge 1 commit intoRightNow-AI:mainfrom
Fail-Safe:fix/agent-modal-ui

Conversation

@Fail-Safe
Copy link
Contributor

Problem

The agent detail modal had two visual issues in the Info tab's Fallbacks section:

  1. Long provider/model strings in fallback badges overflowed the right edge of the modal — the badge would extend beyond the modal boundary rather than wrapping.
  2. The "FALLBACKS" label and the "None — add a fallback chain" text (or the fallback list) appeared on the same visual line with no separation. This was caused by .detail-row using justify-content: space-between, which only creates spacing between items when they don't have flex-grow. The content div had flex:1, which caused it to start flush against the label's right edge rather than being pushed to the opposite side.

Changes

index_body.html (Info tab, Fallbacks section only):

  • Widen agent detail modal from max-width:600px to max-width:700px to better accommodate longer model names and the fallback editor
  • Add display:flex; flex-direction:column; gap:6px; margin-left:16px to the Fallbacks content div — creates a clear column between label and content, and stacks the fallback list / "None" text / "+ Add" button vertically with consistent spacing
  • Add word-break:break-all; white-space:normal to fallback badge spans so long provider/model strings wrap instead of overflowing
  • Add flex-shrink:0 to the × delete button so it is never squashed by a long badge
  • Wrap the "+ Add" button in a <div> to prevent column-flex from stretching it to full width
  • Replace margin-top and mt-1 with gap-based spacing (the parent gap handles vertical rhythm)

Before / After

Before: FALLBACKSNone — add a fallback chain — label and value on the same visual line; long model names clip the modal edge.

After: Label sits in its own column; content stacks below with consistent spacing; long names wrap within the badge.

- Widen agent detail modal from 600px to 700px to better accommodate
  longer model names and the fallback chain editor
- Restructure the Fallbacks section in the Info tab: content div is now
  a column flex container (gap:6px) with margin-left:16px to create a
  clear visual column between the label and its content
- Prevent long provider/model badge strings from overflowing the right
  edge of the modal (word-break:break-all; white-space:normal on badge)
- Add flex-shrink:0 to the × delete button so it never gets squashed
  when a badge is long
- Wrap the "+ Add" button in a div so it stays left-aligned (column
  flex would otherwise stretch a bare button to full width)
- Replace margin-top with gap-based spacing on the fallback edit form

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant