RESOLVED DUPLICATE of bug 79734 75294
:empty still matches after content is added to element with display: none
https://bugs.webkit.org/show_bug.cgi?id=75294
Summary :empty still matches after content is added to element with display: none
webkit
Reported 2011-12-28 00:22:00 PST
Compare the following examples (using innerHTML to add content): 1) http://jsfiddle.net/gtXYC/0/ (works) 2) http://jsfiddle.net/gtXYC/1/ (broken) Same problem using appendChild() instead of innerHTML: 3) http://jsfiddle.net/gtXYC/2/ (works) 4) http://jsfiddle.net/gtXYC/3/ (broken) Examples 1/3: The div's background-color changes based on whether the div is empty or not. Examples 2/4: Same situation, except that the visibility of the div should change. The problem is that :empty still matches after content is added to the div.
Attachments
David Barr
Comment 1 2012-04-25 21:43:20 PDT
Verified as fixed with WebKit Nightly Version 5.1.5 (6534.55.3, r115022).
Julien Chaffraix
Comment 2 2012-04-26 07:28:20 PDT
(In reply to comment #1) > Verified as fixed with WebKit Nightly Version 5.1.5 (6534.55.3, r115022). Are we sure the test cases attached on this bug are covered? Shouldn't we land them to prevent a regression?
Alexey Proskuryakov
Comment 3 2012-04-26 10:06:16 PDT
Since we don't know what fixed this, and haven't landed tests, this is WORKSFORME at best. I agree with Julien that we should investigate the need to land tests.
David Barr
Comment 5 2012-04-26 18:48:13 PDT
*** This bug has been marked as a duplicate of bug 79734 ***
Alexey Proskuryakov
Comment 6 2012-04-26 22:37:46 PDT
Thank you for researching when this got fixed!
Note You need to log in before you can comment on or make changes to this bug.