|
Support the essential part of Shadow DOM v1
The essential part which this CL supports are:
- V1 shadow trees can be rendered correctly.
- Slot elements are no longer dummy elements. It works as the Shadow DOM spec says [1].
- Composed Tree Traversal supports both v0 and v1 distribution.
- v0 and v1 shadow trees can co-exist in the same tree of trees
New APIs are:
- NonDocumentTypeChildNode.assignedSlot
- HTMLSlotElement.getAssingedNodes
- HTMLSlotElement.getDistributedNodes
- Element's slot attribute
All new APIs are guarded by `ShadowDOMV1` runtime flag.
The following features are not implemented:
- Event path for v1 shadow trees.
- The unified redistribution across v0 and v1 shadow trees. See [2] for details.
- The fallback contents of slot elements. See [3] for details
- Distribution algorithms for v1 shadow tree are not optimized yet. See TODOs in this CL for details.
- All style related features which are specific to v1, such as `::slotted` pseudo elements.
- Closed shadow trees of v1 are not considered yet.
I'll add these missing features later as separate patches.
[1]: http://w3c.github.io/webcomponents/spec/shadow/
[2]: https://github.com/w3c/webcomponents/blob/gh-pages/proposals/shadow-dom-v1-in-blink.md#user-content-unified-distribution
[3]: https://github.com/w3c/webcomponents/issues/317
BUG= 531990
Committed: https://crrev.com/071137e656e1ad78c5e8ce506346aa5d2eeef5f9
Cr-Commit-Position: refs/heads/master@{#364654}
Total comments: 18
Total comments: 6
Total comments: 20
Total comments: 2
Total comments: 2
|
Unified diffs |
Side-by-side diffs |
Delta from patch set |
Stats (+832 lines, -33 lines) |
Patch |
|
M |
third_party/WebKit/LayoutTests/fast/dom/shadow/resources/shadow-dom.js
|
View
|
1
2
|
1 chunk |
+16 lines, -0 lines |
0 comments
|
Download
|
|
A |
third_party/WebKit/LayoutTests/fast/dom/shadow/v1-default-slots.html
|
View
|
1
2
3
4
5
6
7
8
9
|
1 chunk |
+44 lines, -0 lines |
0 comments
|
Download
|
|
A |
third_party/WebKit/LayoutTests/fast/dom/shadow/v1-slots-1.html
|
View
|
1
2
3
4
|
1 chunk |
+13 lines, -0 lines |
0 comments
|
Download
|
|
A |
third_party/WebKit/LayoutTests/fast/dom/shadow/v1-slots-1-expected.html
|
View
|
1
2
3
4
|
1 chunk |
+6 lines, -0 lines |
0 comments
|
Download
|
|
A |
third_party/WebKit/LayoutTests/fast/dom/shadow/v1-slots-2.html
|
View
|
1
2
3
4
|
1 chunk |
+27 lines, -0 lines |
0 comments
|
Download
|
|
A |
third_party/WebKit/LayoutTests/fast/dom/shadow/v1-slots-2-expected.html
|
View
|
1
2
3
4
|
1 chunk |
+9 lines, -0 lines |
0 comments
|
Download
|
|
A |
third_party/WebKit/LayoutTests/fast/dom/shadow/v1-slots-api-1.html
|
View
|
1
2
3
4
5
6
|
1 chunk |
+45 lines, -0 lines |
0 comments
|
Download
|
|
A |
third_party/WebKit/LayoutTests/fast/dom/shadow/v1-slots-api-2.html
|
View
|
1
2
3
4
5
6
|
1 chunk |
+81 lines, -0 lines |
0 comments
|
Download
|
|
A |
third_party/WebKit/LayoutTests/fast/dom/shadow/v1-slots-dynamic.html
|
View
|
1
2
3
4
5
6
|
1 chunk |
+12 lines, -0 lines |
0 comments
|
Download
|
|
A |
third_party/WebKit/LayoutTests/fast/dom/shadow/v1-slots-dynamic-expected.html
|
View
|
1
2
3
4
|
1 chunk |
+4 lines, -0 lines |
0 comments
|
Download
|
|
A |
third_party/WebKit/LayoutTests/fast/dom/shadow/v1-slots-text-nodes.html
|
View
|
1
2
3
4
5
6
|
1 chunk |
+51 lines, -0 lines |
0 comments
|
Download
|
|
M |
third_party/WebKit/LayoutTests/webexposed/element-instance-property-listing-expected.txt
|
View
|
1
2
3
4
5
6
7
8
9
|
5 chunks |
+6 lines, -0 lines |
0 comments
|
Download
|
|
M |
third_party/WebKit/LayoutTests/webexposed/global-interface-listing-expected.txt
|
View
|
1
2
3
4
5
6
7
8
9
10
11
|
5 chunks |
+6 lines, -0 lines |
0 comments
|
Download
|
|
M |
third_party/WebKit/Source/core/core.gypi
|
View
|
1
2
3
4
5
6
7
8
9
10
11
|
1 chunk |
+2 lines, -0 lines |
0 comments
|
Download
|
|
M |
third_party/WebKit/Source/core/css/resolver/ElementResolveContext.cpp
|
View
|
1
2
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
|
M |
third_party/WebKit/Source/core/dom/Element.h
|
View
|
1
2
3
4
5
6
7
8
9
10
11
|
1 chunk |
+2 lines, -0 lines |
0 comments
|
Download
|
|
M |
third_party/WebKit/Source/core/dom/Element.cpp
|
View
|
1
2
3
4
5
6
7
8
9
10
11
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
|
M |
third_party/WebKit/Source/core/dom/Element.idl
|
View
|
|
1 chunk |
+1 line, -0 lines |
0 comments
|
Download
|
|
M |
third_party/WebKit/Source/core/dom/LayoutTreeBuilder.cpp
|
View
|
1
2
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
|
M |
third_party/WebKit/Source/core/dom/Node.h
|
View
|
1
2
3
4
5
6
7
8
9
10
11
|
3 chunks |
+4 lines, -0 lines |
0 comments
|
Download
|
|
M |
third_party/WebKit/Source/core/dom/Node.cpp
|
View
|
1
2
3
4
5
6
7
|
3 chunks |
+20 lines, -1 line |
0 comments
|
Download
|
|
M |
third_party/WebKit/Source/core/dom/NodeComputedStyle.h
|
View
|
1
2
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
|
M |
third_party/WebKit/Source/core/dom/NonDocumentTypeChildNode.h
|
View
|
1
2
|
1 chunk |
+5 lines, -0 lines |
0 comments
|
Download
|
|
M |
third_party/WebKit/Source/core/dom/NonDocumentTypeChildNode.idl
|
View
|
1
2
|
1 chunk |
+1 line, -0 lines |
0 comments
|
Download
|
|
M |
third_party/WebKit/Source/core/dom/shadow/ComposedTreeTraversal.h
|
View
|
1
2
|
3 chunks |
+9 lines, -0 lines |
0 comments
|
Download
|
|
M |
third_party/WebKit/Source/core/dom/shadow/ComposedTreeTraversal.cpp
|
View
|
1
2
3
4
5
6
7
8
|
5 chunks |
+101 lines, -14 lines |
0 comments
|
Download
|
|
M |
third_party/WebKit/Source/core/dom/shadow/ComposedTreeTraversalTest.cpp
|
View
|
1
2
3
4
5
6
7
8
9
|
4 chunks |
+117 lines, -0 lines |
0 comments
|
Download
|
|
M |
third_party/WebKit/Source/core/dom/shadow/DistributedNodes.cpp
|
View
|
1
2
3
4
5
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
|
M |
third_party/WebKit/Source/core/dom/shadow/ElementShadow.h
|
View
|
1
2
3
4
5
6
7
|
6 chunks |
+26 lines, -2 lines |
0 comments
|
Download
|
|
M |
third_party/WebKit/Source/core/dom/shadow/ElementShadow.cpp
|
View
|
1
2
3
4
5
|
2 chunks |
+7 lines, -1 line |
0 comments
|
Download
|
|
M |
third_party/WebKit/Source/core/dom/shadow/InsertionPoint.h
|
View
|
1
2
3
4
5
6
7
8
9
10
11
|
1 chunk |
+1 line, -0 lines |
0 comments
|
Download
|
|
M |
third_party/WebKit/Source/core/dom/shadow/InsertionPoint.cpp
|
View
|
1
2
3
4
5
6
7
8
9
10
11
|
1 chunk |
+2 lines, -0 lines |
0 comments
|
Download
|
|
M |
third_party/WebKit/Source/core/dom/shadow/ShadowRoot.h
|
View
|
1
2
3
4
5
6
7
8
9
10
11
|
1 chunk |
+1 line, -0 lines |
0 comments
|
Download
|
|
A |
third_party/WebKit/Source/core/dom/shadow/SlotAssignment.h
|
View
|
1
2
3
4
5
6
7
8
9
10
|
1 chunk |
+31 lines, -0 lines |
0 comments
|
Download
|
|
A |
third_party/WebKit/Source/core/dom/shadow/SlotAssignment.cpp
|
View
|
1
2
3
4
5
6
7
8
9
|
1 chunk |
+94 lines, -0 lines |
0 comments
|
Download
|
|
M |
third_party/WebKit/Source/core/editing/Position.cpp
|
View
|
1
2
|
2 chunks |
+2 lines, -2 lines |
0 comments
|
Download
|
|
M |
third_party/WebKit/Source/core/html/HTMLAttributeNames.in
|
View
|
1
2
3
4
5
6
7
8
9
|
1 chunk |
+1 line, -0 lines |
0 comments
|
Download
|
|
M |
third_party/WebKit/Source/core/html/HTMLSlotElement.h
|
View
|
1
2
3
4
5
6
7
8
9
|
1 chunk |
+23 lines, -3 lines |
0 comments
|
Download
|
|
M |
third_party/WebKit/Source/core/html/HTMLSlotElement.cpp
|
View
|
1
2
3
4
5
6
7
8
9
|
1 chunk |
+55 lines, -5 lines |
0 comments
|
Download
|
|
M |
third_party/WebKit/Source/core/html/HTMLSlotElement.idl
|
View
|
|
1 chunk |
+2 lines, -0 lines |
0 comments
|
Download
|
Dependent Patchsets:
Total messages: 100 (49 generated)
|