Bug 78616

Summary: Consider formulating RenderReplaced as an effect of shadow DOM
Product: WebKit Reporter: Dimitri Glazkov (Google) <dglazkov>
Component: Layout and RenderingAssignee: Web Components Team <webcomponents-bugzilla>
Status: RESOLVED WONTFIX    
Severity: Normal CC: dbates, dominicc, hayato, morrita, rniwa, shinyak
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Bug Depends on:    
Bug Blocks: 82313    

Description Dimitri Glazkov (Google) 2012-02-14 10:03:15 PST
From discussion on bug 50126, Niwa-san suggested a pretty nifty idea: what if we re-describe all elements that currently rely on RenderReplaced for rendering as elements with a shadow DOM (created by UA), that looks like this--taken from Ryosuke's comment:

HTMLCanvasElement -> ShadowRoot -> some-special-element/renderer, inaccessible from ES5
|
v
fallback contents (accessible from DOM, focus, etc... would just work when shown)

This would solve nicely the fallback content issues with focus and possibly allow us to replace RenderReplaced with a better-defined shadow DOM logic.

Also, this dovetails pretty well into https://www.w3.org/Bugs/Public/show_bug.cgi?id=15802.
Comment 1 Ryosuke Niwa 2012-02-14 11:12:18 PST
One drawback of this approach is that we'll double or triple the number of nodes for replaced elements depending on how we implement them. So we might want to add some clever memory-saving mechanism along the way.