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

Select component unexpectedly closes popover when clicking between select components #3166

Open
joeetwork opened this issue Oct 2, 2024 · 4 comments

Comments

@joeetwork
Copy link

Bug report

Current Behavior

When clicking between select components it closes the popover.

Example:
https://github.com/user-attachments/assets/8271f90c-4f81-4942-a8ae-630131d5a908

Expected behavior

When clicking on the other select component it should either open the new select component, close the currently open select component while keeping the popover component open.

Or close the current select component while keeping the popover component open.

Reproducible example

CodeSandbox Template

Suggested solution

Additional context

Was working fine for select component v2.1.1

I have tried with popover component v1.1.1 and v1.1.2

I'm also using shadcn

Your environment

Software Name(s) Version
Radix Package(s) @radix-ui/react-select": "2.1.2", @radix-ui/react-popover": "^1.1.2"
React v18.2.0
Browser Chrome
Assistive tech
Node v18.18.0
npm/yarn v10.8.2
Operating System MacOs
@sahanediriweerazoomi
Copy link

I am also getting the error of popover closing. Think its because of the "@radix-ui/react-popover": "^1.1.2" version. I am using "@radix-ui/react-select": "^2.1.1",

I found a temporary solution of setting the dependency to "@radix-ui/react-popover": "1.1.1"

@joeetwork
Copy link
Author

I had no issues with this error when using select 2.1.1 but I needed to upgrade because the event propagation error, unfortunately it seems to have lead to a different bug lol.

@sahanediriweerazoomi
Copy link

sahanediriweerazoomi commented Oct 4, 2024

Yeah. Hope there would be a fix for this

@ereburg
Copy link

ereburg commented Nov 4, 2024

Update all radix packages to the latest versions and use --exact flag.

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

No branches or pull requests

3 participants