-
Notifications
You must be signed in to change notification settings - Fork 47.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 select default option #24526
Fix select default option #24526
Conversation
Comparing: d20c3af...4e611b3 Critical size changesIncludes critical production bundles, as well as any change greater than 2%:
Significant size changesIncludes any change greater than 0.2%: (No significant changes) |
Could you link the change and maybe find out why the prior behavior was chosen? Verified that this works in https://codesandbox.io/s/react-pr-select-value-with-value-not-matching-option-forked-7xr72e but it would still be nice to add an automated test. |
@eps1lon seems like that was a fix when we got some disabled options. And here we got the unexpected behavior, when we pass I wanted to add the test case for this, but seems like it's already exists
But the weird thing that it passed, but it shouldn't cause it has a different behavior in the browser |
That case is different though since there's no
Maybe @aweary could take a look at the proposed change to verify the new behavior is still correct. |
This pull request has been automatically marked as stale. If this pull request is still relevant, please leave any comment (for example, "bump"), and we'll keep it open. We are sorry that we haven't been able to prioritize reviewing it yet. Your contribution is very much appreciated. |
Closing this pull request after a prolonged period of inactivity. If this issue is still present in the latest release, please ask for this pull request to be reopened. Thank you! |
This is related to #24469
I'm not sure, but this changes from 2016 set default selection for the first non-disabled option, which is lead to inconsistency between pure html and react.
Also there are passed tests which should covered the right logic (we should have unselected options). But the actual browser behavior is the different :(