Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Refactor and fixes dropdown bugs #8807

Open
wants to merge 10 commits into
base: main
Choose a base branch
from
Open

Conversation

lucasbordeau
Copy link
Contributor

@lucasbordeau lucasbordeau commented Nov 29, 2024

Capture d’écran du 2024-11-29 15-08-05

No scroll and search container is shrinking

  • Also :

Icon buttons under dropdown are visible without blur :

Capture d’écran du 2024-11-29 15-09-53

  • Also :
image
  • Also :
image
  • Also :

(Not dropdown but let's fix it also)
image

  • Also :
image
  • Button create new without padding

  • Container is expanding

  • Also :

image
  • Also :
image

Font is cut at bottom ?

  • Also :
image

The component should flip and not resize in this situation

  • Also :
image
  • Also :

image

  • Also :

  • Bug with Phones input, the input stays open after value has been persisted, it should close, also bugs when editing, deleting, the value is persisted but in the dropdown the value stays the same.

  • Also :

image

@lucasbordeau lucasbordeau changed the title WIP Refactor and fixes dropdown bugs Nov 29, 2024
Copy link
Contributor

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

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

PR Summary

This PR implements a comprehensive fix for nested dropdown menu issues by adding proper click-outside event handling and dropdown positioning.

  • Added unique listenerId parameters to all useListenClickOutside hooks across components to properly scope click-outside events
  • Set dropdownStrategy="absolute" and usePortal in MenuItemWithOptionDropdown to fix positioning and z-index issues
  • Added debug logging to track click event propagation and dropdown behavior
  • Fixed potential event conflicts in nested dropdown scenarios by properly managing event listeners
  • Improved click-outside handling in RightDrawer by using dynamic listenerId based on drawer page

💡 (4/5) You can add custom instructions or style guidelines for the bot here!

28 file(s) reviewed, 19 comment(s)
Edit PR Review Bot Settings | Greptile

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

Successfully merging this pull request may close these issues.

2 participants