Bug 91488
Summary: | AuthorShadowDOM for keygen element | ||
---|---|---|---|
Product: | WebKit | Reporter: | Shinya Kawanaka <shinyak> |
Component: | DOM | Assignee: | Dominic Cooney <dominicc> |
Status: | RESOLVED INVALID | ||
Severity: | Normal | CC: | dominicc |
Priority: | P2 | ||
Version: | 528+ (Nightly build) | ||
Hardware: | Unspecified | ||
OS: | Unspecified | ||
Bug Depends on: | |||
Bug Blocks: | 82313 |
Shinya Kawanaka
When we add an AuthorShadowDOM to keygen element, it should be rendered correctly.
Attachments | ||
---|---|---|
Add attachment proposed patch, testcase, etc. |
Dominic Cooney
I will take a look at this.
Dominic Cooney
*** Bug 91491 has been marked as a duplicate of this bug. ***
Dominic Cooney
I tried attaching an author ShadowRoot to a keygen element and the rendering looks fine to me. The shadow element produces the select element used in the UA ShadowRoot.
Shinya Kawanaka
Actually it's not working
Shinya Kawanaka
Repro:
http://jsfiddle.net/vctmc/
In this case, the keygen selector should disappear.
Shinya Kawanaka
Repro:
http://jsfiddle.net/XNNZw/
In this case, the keygen selector should have 10px margins for each direction.
Shinya Kawanaka
Attaching Shadow DOM to <keygen> works, but the problem is that rendering is not correctly.
The replaced element should behave like having its contents in UserAgentShadowRoot.
Please see my design doc...
Dominic Cooney
(In reply to comment #5)
> Repro:
> http://jsfiddle.net/vctmc/
>
> In this case, the keygen selector should disappear.
No it shouldn’t; the repro has this code;
var sr = new WebKitShadowDOM(host);
console.log(sr);
sr.innerHTML = "<div style='10px 10px 10px 10px'></div>"
but WebKitShadowDOM is not defined. Hence no ShadowRoot is created and the rendering shouldn’t change. Also the inline style is not valid – there is no property name, for example.
(In reply to comment #6)
> Repro:
> http://jsfiddle.net/XNNZw/
>
> In this case, the keygen selector should have 10px margins for each direction.
This repro has the same problems: it writes WebKitShadowDOM which is undefined, and the inline style is invalid.
If I fix these problems:
var sr = new WebKitShadowRoot(host);
sr.innerHTML = "<div style='margin: 10px 10px 10px 10px'><shadow></shadow></div>"
then the div has 10px margins as expected.
I’m going to close this again, I think this is working fine, the repros are invalid.
Shinya Kawanaka
It's my failure that I wrongly typed "new WebKitShadowDOM" instead of "new WebKitShadowRoot".
Sorry for that.
Shinya Kawanaka
By the way, can you provide a layout test?
Shinya Kawanaka
OK... <keygen> does not provide any host special renderer... Great. In that case it's very easy to AuthorShadowDOM-ready. Then there is basically nothing to work for it.