-
Notifications
You must be signed in to change notification settings - Fork 191
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: define corner case behavior for <selectedoption> #1120
Comments
You mean if the author puts stuff in there? It's well defined - when the next clone happens due to select.value being assigned to or the user chooses a different option, then the contents will be replaced by the browser.
If a selectedoption has an ancestor selectedoption, then it will become disabled. It will also be removed by the browser whenever cloning occurs in the ancestor selectedoption.
If a selectedoption has an ancestor option, then it will become disabled - I haven't implemented this yet, it currently hangs the browser :)
Each select will clone into that selectedoption whenever either one of them decides to do a clone. This seems intuitive to me in the odd case that you decide to do this. |
This patch prevents an infinite loop due to putting a selectedoption inside of an option element. This case was pointed out here: openui/open-ui#1120 Change-Id: I794e49b5c5d28773ce4684fc3a829365667fe138 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5975638 Commit-Queue: Joey Arhar <[email protected]> Reviewed-by: Traian Captan <[email protected]> Cr-Commit-Position: refs/heads/main@{#1375889}
This patch prevents an infinite loop due to putting a selectedoption inside of an option element. This case was pointed out here: openui/open-ui#1120 Change-Id: I794e49b5c5d28773ce4684fc3a829365667fe138 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5975638 Commit-Queue: Joey Arhar <[email protected]> Reviewed-by: Traian Captan <[email protected]> Cr-Commit-Position: refs/heads/main@{#1375889}
This patch prevents an infinite loop due to putting a selectedoption inside of an option element. This case was pointed out here: openui/open-ui#1120 Change-Id: I794e49b5c5d28773ce4684fc3a829365667fe138 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5975638 Commit-Queue: Joey Arhar <[email protected]> Reviewed-by: Traian Captan <[email protected]> Cr-Commit-Position: refs/heads/main@{#1375889}
…testonly Automatic update from web-platform-tests Disable selectedoption inside option This patch prevents an infinite loop due to putting a selectedoption inside of an option element. This case was pointed out here: openui/open-ui#1120 Change-Id: I794e49b5c5d28773ce4684fc3a829365667fe138 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5975638 Commit-Queue: Joey Arhar <[email protected]> Reviewed-by: Traian Captan <[email protected]> Cr-Commit-Position: refs/heads/main@{#1375889} -- wpt-commits: 77665be0abf23117db6596f618be29dc416fdd13 wpt-pr: 48887
…testonly Automatic update from web-platform-tests Disable selectedoption inside option This patch prevents an infinite loop due to putting a selectedoption inside of an option element. This case was pointed out here: openui/open-ui#1120 Change-Id: I794e49b5c5d28773ce4684fc3a829365667fe138 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5975638 Commit-Queue: Joey Arhar <jarharchromium.org> Reviewed-by: Traian Captan <tcaptanchromium.org> Cr-Commit-Position: refs/heads/main{#1375889} -- wpt-commits: 77665be0abf23117db6596f618be29dc416fdd13 wpt-pr: 48887 UltraBlame original commit: 17d95f3373bf1c72fe9c5b5c337c4534f0e6f421
…testonly Automatic update from web-platform-tests Disable selectedoption inside option This patch prevents an infinite loop due to putting a selectedoption inside of an option element. This case was pointed out here: openui/open-ui#1120 Change-Id: I794e49b5c5d28773ce4684fc3a829365667fe138 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5975638 Commit-Queue: Joey Arhar <jarharchromium.org> Reviewed-by: Traian Captan <tcaptanchromium.org> Cr-Commit-Position: refs/heads/main{#1375889} -- wpt-commits: 77665be0abf23117db6596f618be29dc416fdd13 wpt-pr: 48887 UltraBlame original commit: 17d95f3373bf1c72fe9c5b5c337c4534f0e6f421
…testonly Automatic update from web-platform-tests Disable selectedoption inside option This patch prevents an infinite loop due to putting a selectedoption inside of an option element. This case was pointed out here: openui/open-ui#1120 Change-Id: I794e49b5c5d28773ce4684fc3a829365667fe138 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5975638 Commit-Queue: Joey Arhar <jarharchromium.org> Reviewed-by: Traian Captan <tcaptanchromium.org> Cr-Commit-Position: refs/heads/main{#1375889} -- wpt-commits: 77665be0abf23117db6596f618be29dc416fdd13 wpt-pr: 48887 UltraBlame original commit: 17d95f3373bf1c72fe9c5b5c337c4534f0e6f421
…testonly Automatic update from web-platform-tests Disable selectedoption inside option This patch prevents an infinite loop due to putting a selectedoption inside of an option element. This case was pointed out here: openui/open-ui#1120 Change-Id: I794e49b5c5d28773ce4684fc3a829365667fe138 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5975638 Commit-Queue: Joey Arhar <[email protected]> Reviewed-by: Traian Captan <[email protected]> Cr-Commit-Position: refs/heads/main@{#1375889} -- wpt-commits: 77665be0abf23117db6596f618be29dc416fdd13 wpt-pr: 48887
…testonly Automatic update from web-platform-tests Disable selectedoption inside option This patch prevents an infinite loop due to putting a selectedoption inside of an option element. This case was pointed out here: openui/open-ui#1120 Change-Id: I794e49b5c5d28773ce4684fc3a829365667fe138 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5975638 Commit-Queue: Joey Arhar <[email protected]> Reviewed-by: Traian Captan <[email protected]> Cr-Commit-Position: refs/heads/main@{#1375889} -- wpt-commits: 77665be0abf23117db6596f618be29dc416fdd13 wpt-pr: 48887
There are a lot of weird things you can do with the
<selectedoption>
element. These should at least all have well-defined behavior and not produce unexpected errors or hang the browser.Some cases to consider, definitely not an exhaustive list:
select.selectedOption
<option>
or
The text was updated successfully, but these errors were encountered: