Skip to content
This repository has been archived by the owner on Apr 12, 2024. It is now read-only.

fix(select): force visual update in IE #8158

Closed
wants to merge 1 commit into from

Conversation

rodyhaddad
Copy link
Contributor

IE9, IE10 and IE11 would always show the first as
selected when the user moves from a null
to a non-null one in a non-null . Even though the model was being updated correctly, visually, the first always appeared selected. Setting the selected property twice in a row seems to fix it in all the three versions mentioned above. Closes #7692 I doubt we can actually write tests for this, since it's only visual

IE9, IE10 and IE11 would always show the first <option> as
selected when the user moves from a null <option>
to a non-null one in a non-null <select>.
Even though the model was being updated correctly,
visually, the first <option> always appeared selected.

Setting the `selected` property twice in a row
seems to fix it in all the three versions mentioned above.

Closes angular#7692
@mary-poppins
Copy link

You remembered to triage your own PR this time, awesome!

@rodyhaddad rodyhaddad added this to the 1.3.0-beta.16 milestone Jul 11, 2014
rodyhaddad added a commit that referenced this pull request Jul 15, 2014
IE9, IE10 and IE11 would always show the first <option> as
selected when the user moves from a null <option>
to a non-null one in a non-null <select>.
Even though the model was being updated correctly,
visually, the first <option> always appeared selected.

Setting the `selected` property twice in a row
seems to fix it in all the three versions mentioned above.

Closes #7692
Closes #8158
ckknight pushed a commit to ckknight/angular.js that referenced this pull request Jul 16, 2014
IE9, IE10 and IE11 would always show the first <option> as
selected when the user moves from a null <option>
to a non-null one in a non-null <select>.
Even though the model was being updated correctly,
visually, the first <option> always appeared selected.

Setting the `selected` property twice in a row
seems to fix it in all the three versions mentioned above.

Closes angular#7692
Closes angular#8158
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

ng-option doesn't handle first selection properly under IE11
2 participants