Skip to content

fix(agents): wrap long names in archive confirmation dialogs - #9129

Open
Frezc wants to merge 1 commit into
multica-ai:mainfrom
Frezc:codex/ADMUL-98-archive-dialog-upstream
Open

Frezc wants to merge 1 commit into
multica-ai:mainfrom
Frezc:codex/ADMUL-98-archive-dialog-upstream

Conversation

@Frezc

@Frezc Frezc commented Oct 8, 2026

Copy link
Copy Markdown

What does this PR do?

Archiving an agent with a long unbroken name can expand the confirmation header and footer past the popup. A 384px popup can end up with a ~456px footer, leaving the Archive button outside its surface; longer names can push the buttons outside the viewport.

Keep the full name visible by wrapping it inside the popup. Constrain the shared AlertDialog grid to one shrinking column, allow long title/description words to wrap, and let the archive text column shrink. Apply explicit name breaking to both row and bulk archive titles so mixed CJK/ASCII names do not leave an orphaned leading character.

Related Issue

Found while testing agent archive confirmation with long names. No matching public issue or fix PR found; #8209 addresses vertical dialog height and does not fix this horizontal overflow.

Type of Change

  • Bug fix (non-breaking change that fixes an issue)

Changes Made

  • packages/ui/components/ui/alert-dialog.tsx: use grid-cols-1 for a minmax(0, 1fr) content track and wrap-anywhere for titles/descriptions.
  • packages/views/agents/components/agent-row-actions.tsx: shrink the archive text column and break long archive titles.
  • packages/views/agents/components/agent-batch-toolbar.tsx: break long names in the bulk archive title.

How to Test

  1. Give an agent an unbroken name such as RELEASE_ACCEPTANCE_AGENT_WITH_A_VERY_LONG_NAME.
  2. Open Archive from its row menu. The complete name should wrap, and the description/footer/buttons should remain inside the popup.
  3. Repeat through bulk archive with one selected agent, at narrow widths, and with English/Chinese UI.

Verified on upstream main at 8db6cfe19 plus this patch:

  • Chromium component layout fixture: 120/120 combinations passed across 1144/375/320px, English/Chinese, light/dark, row/bulk archive, and five name shapes. Checks include full name preservation, bounds/scroll overflow, Cancel dismissal and no page errors.
  • Before-patch upstream fixture: all eight long-name combinations overflowed; four short-name controls passed.
  • pnpm --filter @multica/views exec vitest run agents/components/agent-batch-toolbar.test.tsx agents/components/agent-detail-page.test.tsx --maxWorkers=1: 24 tests passed in exactly two files.
  • UI/Views typecheck, changed-file ESLint and git diff --check passed.

Full verification report

The browser fixture uses the real UI primitives, shared styles, locale copy and archive dialog composition. It does not exercise the full Agents page or archive API. The full root suite, deployed E2E and installed Electron were not run. This CSS-only fix adds no class-string unit tests; real browser geometry checks provide layout verification. Shared AlertDialog word wrapping also affects other callers; short names were included in the matrix.

Checklist

  • I have included a thinking path that traces from project context to this change
  • I have run tests locally and they pass
  • If this change affects the UI, I have included before/after screenshots
  • I have considered and documented any risks above

AI Disclosure

AI tool used: Codex

Prompt / approach: Reproduce the reported archive dialog overflow, check whether upstream already has a matching fix, port the focused CSS change onto current upstream main, and verify with Chromium geometry checks plus existing component tests.

Screenshots

Before (synthetic long name):

Before: archive dialog overflow

After (the complete name wraps inside the popup):

After: archive dialog with wrapped name

@vercel

vercel Bot commented Oct 8, 2026

Copy link
Copy Markdown

@Frezc is attempting to deploy a commit to the IndexLabs Team on Vercel.

A member of the Team first needs to authorize it.

This branch has not been deployed

No deployments
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