Skip to content

fix(dashboard): align terminal-dialog close X with compact header - #9816

Merged
brennanb2025 merged 1 commit into
mainfrom
brennanb2025/fix-agent-dashboard-close
Jul 22, 2026
Merged

brennanb2025 merged 1 commit into
mainfrom
brennanb2025/fix-agent-dashboard-close

Conversation

@brennanb2025

Copy link
Copy Markdown
Contributor

Problem

In the agent dashboard popout, the terminal dialog's close X is misaligned: it floats below the header row instead of sitting on the title line.

The default DialogContent close button is absolutely positioned at top-4 right-4, which is tuned for the standard p-6 dialog. This dialog uses p-0 with a compact py-2 header (#9686 switched it from a footer Close button to the corner X), so the default position lands the X below the header's centerline.

Fix

Suppress the built-in close button (showCloseButton={false}) and render the DialogClose X inside the header row with ml-auto, so it vertically centers with the title and shares the header's horizontal padding. Same visual treatment as the default X (size-4 icon, 70% → 100% opacity on hover, sr-only label).

Adds the dashboardPopout.terminal.close locale key (English text in non-en locales, matching the existing keys in that section).

QA (live Electron, CDP)

Verified in the dev app via the popout QA rig (synthetic snapshot → open dialog):

  • X center is exactly on the title's centerline (both measured at the same y), inset to match the header padding.
  • Clicking the X still closes the dialog.

dialog X aligned

The default DialogContent close button is absolutely positioned at
top-4/right-4 for standard p-6 dialogs; the agent terminal dialog uses
p-0 with a compact py-2 header, so the X floated below the title line.
Render the close control inside the header row instead so it centers
with the title and matches the header's horizontal padding.
@coderabbitai

coderabbitai Bot commented Jul 22, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro

Run ID: 1cfe3442-efc4-46f9-b076-fafade58d025

📥 Commits

Reviewing files that changed from the base of the PR and between 1fef1e1 and 5d93740.

📒 Files selected for processing (6)
  • src/renderer/src/components/dashboard-popout/AgentTerminalDialog.tsx
  • src/renderer/src/i18n/locales/en.json
  • src/renderer/src/i18n/locales/es.json
  • src/renderer/src/i18n/locales/ja.json
  • src/renderer/src/i18n/locales/ko.json
  • src/renderer/src/i18n/locales/zh.json

📝 Walkthrough

Walkthrough

The agent terminal dialog now uses a custom header close button with an X icon and localized screen-reader label, while disabling the default dialog close button. Existing dialog open and close wiring remains unchanged. English, Spanish, Japanese, Korean, and Chinese locale bundles now include a terminal close label.

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Description check ⚠️ Warning The description covers the problem, fix, and QA, but it omits required template sections like Summary, Testing, AI Review Report, Security Audit, and Notes. Add the missing template sections with a Summary, full Testing checklist, AI Review Report, Security Audit, and Notes; keep Screenshots explicit if visuals changed.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title accurately describes the main change: moving the terminal dialog close X into the compact header.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@brennanb2025

Copy link
Copy Markdown
Contributor Author

Live-terminal QA (requested): same rig but with a real PTY attached to the dialog (pty.spawn → snapshot ptyId), so the AgentTerminalPreview is mounted and streaming.

Measured in the popout: the X's vertical center sits exactly on the title centerline, and its right edge aligns with the footer button's gutter. Clicking the X closes the dialog.

Note for reviewers: an earlier re-test appeared to still show the misaligned X — that was a stale QA window from a previous dev instance (its vite port had been reclaimed by another worktree's server); the fresh instance below runs this branch.

dialog X aligned, live terminal

@brennanb2025
brennanb2025 merged commit 5187378 into main Jul 22, 2026
2 checks passed
enrick-dev pushed a commit to enrick-dev/orca that referenced this pull request Oct 15, 2026
…ablyai#9816)

The default DialogContent close button is absolutely positioned at
top-4/right-4 for standard p-6 dialogs; the agent terminal dialog uses
p-0 with a compact py-2 header, so the X floated below the title line.
Render the close control inside the header row instead so it centers
with the title and matches the header's horizontal padding.
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