Skip to content

fix(compass-components): improve Error details modal UX (COMPASS-10474)#7901

Open
cursor[bot] wants to merge 10 commits intomainfrom
cursor/error-details-modal-ux-8d61
Open

fix(compass-components): improve Error details modal UX (COMPASS-10474)#7901
cursor[bot] wants to merge 10 commits intomainfrom
cursor/error-details-modal-ux-8d61

Conversation

@cursor
Copy link
Copy Markdown
Contributor

@cursor cursor bot commented Mar 24, 2026

From Compass Ticket -
Author : @misbamongo & dev support from @paula-stacho
Screenshot 2026-03-24 at 22 11 20

Summary

Improves the Error details modal UX when displaying long JSON content by adding proper spacing above the JSON and making the JSON area scroll instead of expanding the whole modal.

Changes

1. Header → editor spacing

  • Added 16px (spacing[400]) padding above the JSON Code block.
  • Applied only inside the Error details content, not to any shared modal or other screens.

2. Scrollable JSON area

  • Wrapped the JSON Code block in a container with:
    • paddingTop: spacing[400]
    • maxHeight: '60vh'
    • overflow: 'auto'
  • When the JSON is long, the JSON area now scrolls instead of the entire modal growing.
  • The Back button remains visible in normal window sizes because the scroll is limited to the JSON area.

Implementation approach

  • Single-file, local change in use-error-details.tsx.
  • No changes to use-confirmation.tsx or other shared helpers/components.
  • No new components, providers, or global state.
  • Keeps all layout/styling changes scoped to the Error details content so other modals are unaffected.

Testing

  • All compass-components tests pass (397 passing).
  • Manually verified Error details modal behavior with long JSON on larger and smaller window heights (JSON scrolls; Back button remains visible).
Open in Web Open in Cursor 

- Add 16px (spacing[400]) padding above the JSON code block
- Set modal max-height: 90vh so Back button stays visible
- Make JSON area scroll internally via overflow: auto
- Wire className through showConfirmation for Error details-specific styles
…revert use-confirmation changes

- Revert className changes from shared use-confirmation helper
- Keep padding, overflow, maxHeight only in use-error-details.tsx wrapper
@cursor
Copy link
Copy Markdown
Contributor Author

cursor bot commented Mar 24, 2026

Cursor Agent can help with this pull request. Just @cursor in comments and I'll start working on changes in this branch.
Learn more about Cursor Agents

@cursor cursor bot requested a review from a team as a code owner March 24, 2026 16:57
@cursor cursor bot requested a review from mabaasit March 24, 2026 16:57
@github-actions github-actions bot added the fix label Mar 24, 2026
@misbamongo misbamongo added the no release notes Fix or feature not for release notes label Mar 24, 2026
@misbamongo misbamongo marked this pull request as draft March 24, 2026 17:30
@cursor cursor bot force-pushed the cursor/error-details-modal-ux-8d61 branch from fa6b2d9 to 833dc78 Compare March 24, 2026 18:51
cursoragent and others added 5 commits March 24, 2026 18:57
… stays visible

Restore maxHeight on the description wrapper only (not modal); overflow:auto
needs a bounded height so the JSON scrolls inside and the footer stays on-screen.
…e for footer

Use calc(100vh - 280px) so header + padded modal + footer fit; 180px was too
small on short viewports. Add minHeight:0 for flex overflow behavior.
… - 180px)

Revert to the agreed local-only styling (paddingTop, overflow, maxHeight).
…ll + visible footer

COMPASS-10474: padding above JSON, maxHeight 60vh, overflow auto — local to use-error-details only.
@misbamongo misbamongo marked this pull request as ready for review March 25, 2026 14:49
Copilot AI review requested due to automatic review settings March 25, 2026 14:49
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Improves the Compass Components “Error details” confirmation modal UX for long JSON payloads by adding spacing above the JSON and constraining the JSON area to scroll rather than expanding the modal.

Changes:

  • Added an emotion class that applies top padding, a 60vh max height, and overflow: auto to the Error details content container.
  • Wrapped the JSON <Code> block in a styled <div> so long JSON scrolls within the modal content area.

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

Labels

fix no release notes Fix or feature not for release notes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants