Skip to content

[Bug] Dropdown reopens fail due to modal context blocking #650

@Dhavanesh24cs412

Description

@Dhavanesh24cs412

Title:
[Bug] Framework/Library Dropdown Can Only Be Opened Once Per Search Session

Description:

Problem

The framework and library dropdown menus in the search modal can only be opened once per search session. After the first open-close cycle, subsequent attempts to open the dropdown fail until the search modal is closed and reopened.

Image

Steps to Reproduce

  1. Open the search modal (Cmd+K or Ctrl+K)
  2. Click the "Library" or "Framework" dropdown
  3. Dropdown opens ✓
  4. Click it again
  5. Dropdown closes ✓
  6. Click it a third time
  7. Dropdown does NOT open ✗ (BUG)
  8. Only way to make it work again is to close and reopen the entire search modal

Root Cause

The modal={true} prop in the Radix Dropdown component creates a modal context that:

  • Blocks all interactions with elements outside the dropdown
  • Prevents proper state management for re-opens
  • Creates focus trapping that interferes with subsequent opens

Expected Behavior

The dropdown should open and close repeatedly without needing to close the entire search modal.

Environment

  • Framework: React 18+
  • Radix UI: @radix-ui/react-dropdown-menu
  • Browser: [Any modern browser]

Severity

Medium - Affects user experience when filtering search results multiple times

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions