Skip to content

fix(ui): Increase dropdown z-index to appear above sidebar#116139

Merged
jameskeane merged 1 commit into
masterfrom
jameskeane/fix-dropdown-zindex-34ad
May 25, 2026
Merged

fix(ui): Increase dropdown z-index to appear above sidebar#116139
jameskeane merged 1 commit into
masterfrom
jameskeane/fix-dropdown-zindex-34ad

Conversation

@jameskeane
Copy link
Copy Markdown
Contributor

@jameskeane jameskeane commented May 25, 2026

Fixes DAIN-1690

Problem

Widget context menus (triggered by clicking the '...' buttons on dashboard widgets) were appearing behind the dashboard navigation sidebar because theme.zIndex.dropdown (1001) was lower than theme.zIndex.sidebarPanel (1019).

Before
Screenshot 2026-05-25 at 1 06 18 PM
After
Monosnap General Template copy 35 — sentry — Sentry 2026-05-25 13-53-18

Solution

Updated theme.zIndex.dropdown from 1001 to 1020 (sidebarPanel + 1) in the theme definition. This ensures all dropdown menus across the application appear above the sidebar panel.

Linear Issue: DAIN-1690

- Set theme.zIndex.dropdown to 1020 (sidebarPanel + 1)
- Fixes widget context menu appearing behind dashboard navigation
- Reordered dropdown after sidebarPanel to maintain sorted zIndex list

Co-authored-by: James Keane <james.keane.github@gmail.com>
@linear-code
Copy link
Copy Markdown

linear-code Bot commented May 25, 2026

DAIN-1690

@github-actions github-actions Bot added the Scope: Frontend Automatically applied to PRs that change frontend components label May 25, 2026
@github-actions
Copy link
Copy Markdown
Contributor

📊 Type Coverage Diff

✅ No new type safety issues introduced. Coverage: 93.58%

@jameskeane jameskeane marked this pull request as ready for review May 25, 2026 18:13
@jameskeane jameskeane requested a review from a team as a code owner May 25, 2026 18:13
Copy link
Copy Markdown
Contributor

@cursor cursor Bot left a comment

Choose a reason for hiding this comment

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

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 3b8bcf8. Configure here.

widgetBuilderDrawer: 1016,

sidebarPanel: 1019,
dropdown: 1020,
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Dropdown z-index equals sidebar causing potential overlap

Medium Severity

dropdown is now set to 1020, which is identical to sidebar (also 1020). Since dropdown menus are not portaled by default (usePortal = false), they render inline within the content area, which typically precedes the navigation in DOM order. When two positioned elements share the same z-index, the one later in the DOM wins. This means the mobile navigation bar (which uses theme.zIndex.sidebar) can still appear above non-portaled dropdowns depending on DOM structure—the same class of bug this PR aims to fix.

Fix in Cursor Fix in Web

Reviewed by Cursor Bugbot for commit 3b8bcf8. Configure here.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Seems valid

@jameskeane jameskeane requested a review from DominikB2014 May 25, 2026 18:20
Copy link
Copy Markdown
Contributor

@DominikB2014 DominikB2014 left a comment

Choose a reason for hiding this comment

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

I think the cursor comment is probably valid, but the changes should still address the issue that we're trying to fix

@jameskeane jameskeane merged commit 8c618b2 into master May 25, 2026
74 checks passed
@jameskeane jameskeane deleted the jameskeane/fix-dropdown-zindex-34ad branch May 25, 2026 19:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Scope: Frontend Automatically applied to PRs that change frontend components

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants