-
-
Notifications
You must be signed in to change notification settings - Fork 5.3k
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
Fix SelectInput / SelectArrayInput onChange handler #7519
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I approve the changes, but I have a few questions:
- Are
SelectArrayInput
andSelectInput
the only components affected by this? What aboutTextInput
and the others for example? - Why do we need to do a difference with what we send to the
onChange
callback when we add an item vs when we select another? Is it documented somewhere?
Also, it seems the accepted |
The only other inputs that do not pass the event object are
As of this PR, my intention was just to maintain the functionality of I don't think all of this behavior is properly documented. |
Ok, so, to be clear, do you want me to use this PR to change the onChange event handlers of these inputs to always pass the event object? |
fa1176a
to
793b943
Compare
Fixes #7518
SelectInput / SelectArrayInput change event handler should receive the event object unless the change was fired due to the creation of a new item, in that case it should receive the new value