-
Notifications
You must be signed in to change notification settings - Fork 27.4k
ngOptions : regression 1.2.15 && 1.3.0-beta.3 #6828
Comments
I can't reproduce this in FF 28. 1.2.14 / 1.2.15 look the same. Which browser did you test? There was a fix for a Firefox ngOptions render bug, maybe this is related. f40f54c |
Sorry, I forgot to mention this. Chrome 30 : bug |
WFM in Chrome stable |
I just update to Chromium 33 and I still have the issue. |
Do you have all your extensions disabled when testing? |
@caitp Yes, all extensions disabled and with the incognito mode of chrome. My OS is Ubuntu. I also tried with Chrome under W7 (fresh install) and this bug also ! See this screenshot IE11 doesn't bug |
I can't reproduce on OSX 10.9 or Windows 8.1 with Chrome 33. You should investigate it, but it's possibly a browser bug. |
@yappli I am able to reproduce this with Chrome 33 and OSX 10.9 and it does look like a browser bug. |
@lgalfaso : Your workaround works for me, thanks. I don't know if it's a browser bug or not. Probably. |
The reason I couldn't reproduce it is because you posted an example of the working build, not of the broken build. This is bad, don't do this, it's not helpful. Especially on jsfiddle where the UI doesn't make it obvious that you're using the working build! So yes, there is a regression from the fix to break the problem in Firefox. Someone should look into this, PRs welcome, although I suppose there is a workaround to fix this. |
Sorry @caitp, I edited my original post. |
@lgalfaso can you look into this one please? |
Came across this issue, but wasn't able to fix it. Thanks for raising On Mon, Mar 24, 2014 at 11:50 PM, Gabriel Delépine <notifications@github.com
|
@IgorMinar sure |
it looks like the issue is a Chrome specific bug. The issue is that when adding a |
When adding an `<option selected="selected">` into the DOM, put the property `selected` to `true`. This works around an issue present at Chrome where the new `<option>` is selected at the DOM not selected at the UI. Closes angular#6828
The patch at 2011a0d is not nice as it is a workaround a Chrome bug, but does get the work done |
When adding a new <option> element, if the DOM of this option element states that the element is marked as `selected`, then select the new <option> element Closes angular#6828
At Igor's request, bug has been filed on this with Chromium (https://code.google.com/p/chromium/issues/detail?id=381459) I've also discussed this briefly with Ian Hickson / folks present on #whatwg, and it seems like the behaviour is underspecified. If I'm misinterpreting anything from the reproduction, don't hesitate to comment on the bugs and correct me. |
When adding a new <option> element, if the DOM of this option element states that the element is marked as `selected`, then select the new <option> element Closes angular#6828
When adding a new <option> element, if the DOM of this option element states that the element is marked as `selected`, then select the new <option> element Closes angular#6828
When adding a new <option> element, if the DOM of this option element states that the element is marked as `selected`, then select the new <option> element Closes #6828
When adding a new <option> element, if the DOM of this option element states that the element is marked as `selected`, then select the new <option> element Closes angular#6828
Hixie has clarified the spec on this point: http://html5.org/tools/web-apps-tracker?from=8713&to=8714 I'm not sure if the algorithm runs before or after the script's turn, so I'm not totally sure how this would affect the test case on the chromium bug. It seems like this change to the spec might make FF's behaviour "wrong", will have to check. |
Is this issue still happening to anyone? The fiddle in the original post works as expected to me in latest Chrome. I think that the patch that fixed it can be removed... Also, there is a minor bug (I think) in the patch that causes some unexpected behavior, but I hope it can be solved simply by removing the patch. Here's a plunker that demonstrates it: http://plnkr.co/edit/mqu6HbmjJd3QNiavzdlv?p=preview WDYT? |
@shahata What is going on with your example is the following. The value of <option selected="selected">{{default}}</option> to <option value="" selected="selected">{{default}}</option> then the value does not change. I am lean towards thinking that this is undefined behavior. BTW, the same can be said with http://plnkr.co/edit/amnWn3lhLTEwkBkyM65b?p=preview |
Yeah, I know what is happening. I'm just saying it doesn't make sense to check |
In the Chrome issue (https://bugs.chromium.org/p/chromium/issues/detail?id=381459) I noticed that the bug can't be reproduced in Chrome 45 and the issue was closed subsequently. I've also tested again with Chrome 51 and it still works. Related: angular#6828
In the Chrome issue (https://bugs.chromium.org/p/chromium/issues/detail?id=381459) I noticed that the bug can't be reproduced in Chrome 45 and the issue was closed subsequently. I've also tested again with Chrome 51 and it still works. Related: angular#6828
In the Chrome issue (https://bugs.chromium.org/p/chromium/issues/detail?id=381459) I noticed that the bug can't be reproduced in Chrome 45 and the issue was closed subsequently. I've also tested again with Chrome 51 and it still works. Additionally, the Chrome hack was kept in the select code, but wasn't ported to the ngOptions code when the two split in 7fda214, and no regression happened. Nevertheless, a test has been added to guard against a future regression. Related: #6828 PR: #14705
In the Chrome issue (https://bugs.chromium.org/p/chromium/issues/detail?id=381459) I noticed that the bug can't be reproduced in Chrome 45 and the issue was closed subsequently. I've also tested again with Chrome 51 and it still works. Additionally, the Chrome hack was kept in the select code, but wasn't ported to the ngOptions code when the two split in 7fda214, and no regression happened. Nevertheless, a test has been added to guard against a future regression. Related: angular#6828 PR: angular#14705
When the select tag has the required attribute, the default blank option is ignore.
1.2.14 works
1.2.15 doesn't
1.3.0-beta.3 doesn't
See the jsfiddle
The text was updated successfully, but these errors were encountered: