You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Apr 12, 2024. It is now read-only.
Repository navigation
This repository was archived by the owner on Apr 12, 2024. It is now read-only.
fix(select) ... breaks some selects with required attributes on firefox. #7715
we filed an issue about this with Chromium, actually, because it works as expected in firefox, but differently in chrome --- mostly because that section of html is a bit underspecified.
I haven't kept up with the issues though, don't think I added myself to the CC list
Oh, so it's actually correct in Firefox: because the first field is disabled, the second field is automatically selected? But @luismreis says that's broken. So maybe the expectation is that a disabled field can still be preselected (but not user selected), because you don't want to make a selection for the user ... regardless of required state.
the scenario which is broken is sort of hard to explain, it's easiest to just show the fiddle --- it's in one of the issues about this, can't recall OTOH though
@Narretz The scenario is this: you need a select control for something that is required, but you don't want to pre-choose one of the normal options. A way to do this is by having a default value that is disabled, so, the user can choose another one, but not the initial void/empty one.
I prefer the "show disabled option" behaviour, but I understand that it feels a bit broken - maybe I should be using another widget for this.
BTW, I started to have doubts on this being pure browser or angular bejaviour and now there's a new version of the fiddle at (http://jsbin.com/wobod/4). The problem is exactly the same regardless if angular is involved or not.
Activity
fix(select): avoid checking option element selected properties in render
Narretz commentedon Jun 20, 2014
It looks like the optional select is also broken on Chrome, because the select has A selected, whereas 'Choose a choice' should be selected
caitp commentedon Jun 20, 2014
we filed an issue about this with Chromium, actually, because it works as expected in firefox, but differently in chrome --- mostly because that section of html is a bit underspecified.
I haven't kept up with the issues though, don't think I added myself to the CC list
Narretz commentedon Jun 20, 2014
Oh, so it's actually correct in Firefox: because the first field is disabled, the second field is automatically selected? But @luismreis says that's broken. So maybe the expectation is that a disabled field can still be preselected (but not user selected), because you don't want to make a selection for the user ... regardless of required state.
caitp commentedon Jun 20, 2014
the scenario which is broken is sort of hard to explain, it's easiest to just show the fiddle --- it's in one of the issues about this, can't recall OTOH though
luisa-reis commentedon Jun 21, 2014
@Narretz The scenario is this: you need a select control for something that is required, but you don't want to pre-choose one of the normal options. A way to do this is by having a default value that is disabled, so, the user can choose another one, but not the initial void/empty one.
I prefer the "show disabled option" behaviour, but I understand that it feels a bit broken - maybe I should be using another widget for this.
BTW, I started to have doubts on this being pure browser or angular bejaviour and now there's a new version of the fiddle at (http://jsbin.com/wobod/4). The problem is exactly the same regardless if angular is involved or not.
29 remaining items
revert(select): avoid checking option element selected properties in …
test(select): add test cases for selects with blank disabled options
revert(select): avoid checking option element selected properties in …
test(select): add test against updating selected property on digest w…
test(select): add test cases for selects with blank disabled options
revert(select): avoid checking option element selected properties in …
test(select): add test against updating selected property on digest w…
test(select): add test cases for selects with blank disabled options
fix(select): do not update selected property of an option element on …
revert(select): avoid checking option element selected properties in …
test(select): add test against updating selected property on digest w…
test(select): add test cases for selects with blank disabled options
fix(select): do not update selected property of an option element on …