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
MultiSelect tagInputProps: How to avoid input focus when onRemove triggered? #3310
Comments
I think what MichaelLonin is maybe getting at here is that there seems to be no way currently to stop the select popover from opening when the tag X is clicked: I definitely think that functionality should be optional. Unfortunately the onRemove handler signature looks like this:
So we can't manually stop event propagation/prevent default ourselves. Thoughts @giladgray @adidahiya ? |
Removing the tags should not open the popover. The intent is not to select new options when removing. |
@adidahiya I can think of two ways of fixing this:
I'm more than happy to implement any of those solutions, or any other solution that you may suggest. |
@adidahiya ok I implemented solution 1 since it's the most straight forward and doesn't require API changes. Please take a look and let me know if you want any changes. |
Moving my comments from #4034 here, this might be the right place to continue the conversation @adidahiya what about this?
Something else we could try is handling the event propagation in What do you think? |
@grancalavera I would still like to avoid "ignoring" clicks or stopping event propagation. Can you implement a new prop on |
Cool, I'll start looking into it. |
Environment
Question
Is it possible to prevent input focus when onRemove triggered? Thanks in advance!
The text was updated successfully, but these errors were encountered: