WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED DUPLICATE of
bug 11384
9983
dynamically generated elements do not inherit css properties
https://bugs.webkit.org/show_bug.cgi?id=9983
Summary
dynamically generated elements do not inherit css properties
Michiel Roding
Reported
2006-07-18 04:12:28 PDT
when adding an element to the DOM, some css-properties are not set. See the example; a p + p selector is defined, but not applied. Neither using insertBefore nor appendChild. this applies both to the 420+ nightly and 419.3
Attachments
test case
(444 bytes, text/html)
2006-07-18 04:13 PDT
,
Michiel Roding
no flags
Details
Test case with <script> before <p>
(445 bytes, text/html)
2006-07-18 04:42 PDT
,
David Kilzer (:ddkilzer)
no flags
Details
Test exhibiting issue using insertBefore()
(384 bytes, text/html)
2006-07-18 06:20 PDT
,
David Kilzer (:ddkilzer)
no flags
Details
Better test case (broken results obvious)
(422 bytes, text/html)
2006-07-18 07:19 PDT
,
David Kilzer (:ddkilzer)
no flags
Details
Show Obsolete
(3)
View All
Add attachment
proposed patch, testcase, etc.
Michiel Roding
Comment 1
2006-07-18 04:13:08 PDT
Created
attachment 9545
[details]
test case
David Kilzer (:ddkilzer)
Comment 2
2006-07-18 04:40:08 PDT
Looking at the DOM using the Web Inspector (right-click on page, "Inspect Element" on nightly builds), I'm seeing this on the test page: <p id="p2"> <script> <p> I think the test case may be wrong since running appendChild() on the <body> tag will produce the above results. Also, the current test case looks the same when viewed in Firefox 1.5.0.4.
David Kilzer (:ddkilzer)
Comment 3
2006-07-18 04:42:05 PDT
Created
attachment 9547
[details]
Test case with <script> before <p>
David Kilzer (:ddkilzer)
Comment 4
2006-07-18 04:43:53 PDT
(In reply to
comment #3
)
> Created an attachment (id=9547) [edit] > Test case with <script> before <p>
This test case works fine with a locally-built WebKit
r15500
on Safari 2.0.4 (419.3) on Mac OS X 10.4.7 (8J135/PowerPC), thus I'm closing this bug as RESOLVED/WORKSFORME. Note that if this test case does NOT work with production Safari, there's not much that can be done by the WebKit project itself since the bug is already fixed in this project.
David Kilzer (:ddkilzer)
Comment 5
2006-07-18 04:46:40 PDT
(In reply to
comment #4
)
> Note that if this test case does NOT work with production Safari, there's not > much that can be done by the WebKit project itself since the bug is already > fixed in this project.
This test case works in production Safari 2.0.4 (419.3) as well! :)
Michiel Roding
Comment 6
2006-07-18 04:47:17 PDT
try uncommenting line 16 and commenting line 17; it will insert the element before the existing P. In firefox, in that case (prepending) it doesn't work unless you do: document.body.style.display = 'none'; document.body.style.display = 'block'; which forces ff to 'rerender'; the second P does turn yellow then.
David Kilzer (:ddkilzer)
Comment 7
2006-07-18 06:14:43 PDT
Reopening per
Comment #6
.
David Kilzer (:ddkilzer)
Comment 8
2006-07-18 06:20:28 PDT
Created
attachment 9552
[details]
Test exhibiting issue using insertBefore() This test does exhibit the issue.
David Kilzer (:ddkilzer)
Comment 9
2006-07-18 06:20:59 PDT
Confirmed in locally-built WebKit
r15500
.
David Kilzer (:ddkilzer)
Comment 10
2006-07-18 07:19:48 PDT
Created
attachment 9554
[details]
Better test case (broken results obvious) Interestingly, the Web Inspector shows that the paragraph that should be yellow has the style applied to it!
Dave Hyatt
Comment 11
2006-09-12 23:47:19 PDT
We don't handle dynamic sibling updates at all right now.
Robert Blaut
Comment 12
2008-01-30 14:39:12 PST
Look also at similar
bug 11384
.
Robert Blaut
Comment 13
2008-02-21 22:19:21 PST
*** This bug has been marked as a duplicate of
11384
***
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