This repository was archived by the owner on Apr 12, 2024. It is now read-only.
ngOptions: always set selected attribute for selected options#14125
Closed
Narretz wants to merge 1 commit into
Closed
ngOptions: always set selected attribute for selected options#14125Narretz wants to merge 1 commit into
Narretz wants to merge 1 commit into
Conversation
ab41f28 to
1167a5e
Compare
We don't set selected property / attribute on options that are already selected. That happens for example if the browser has automatically selected the first option in a select. In that case, the selected property is set automatically, but the selected attribute is not Closes angular#14115
1167a5e to
8beddb9
Compare
Contributor
Author
|
@gkalpak Can you review this? Atm, the test would pass with jqlite without the patch, but it would fail in jquery. I think we can handle the jqlite at a later point, as the issue is quite low impact anyway. |
Member
|
LGTM |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
ngOptions wouldn't set the "selected" attribute, if the option was automatically preselected by the browser.