WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
103681
non HTMLElement documentElement ignores display: none
https://bugs.webkit.org/show_bug.cgi?id=103681
Summary
non HTMLElement documentElement ignores display: none
Elliott Sprehn
Reported
2012-11-29 15:52:45 PST
If you replace the documentElement with a non-html element and then set it to display: none we ignore it. ex. <iframe id="doc"></iframe> <script> var doc = document.getElementById('doc').contentDocument; var root = doc.implementation.createDocument().createElement('not-a-real-element'); doc.replaceChild(root, doc.documentElement); root.appendChild(document.createElement('style')).textContent = 'not-a-real-element { display: none }'; root.appendChild(document.createElement('p')).textContent = 'Should not be visible'; </script>
Attachments
Add attachment
proposed patch, testcase, etc.
Elliott Sprehn
Comment 1
2012-11-29 16:07:40 PST
This is fixed by
Bug 103475
.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug