Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(19)

Issue 1085843002: Implement DOM: prepend, append, before, after & replaceWith (Closed)

Created:
5 years, 8 months ago by Paritosh Kumar
Modified:
5 years, 5 months ago
Reviewers:
haraken, tkent, philipj_slow
CC:
blink-reviews
Base URL:
https://chromium.googlesource.com/chromium/blink.git@master
Target Ref:
refs/heads/master
Project:
blink
Visibility:
Public.

Description

Implement DOM: prepend, append, before, after & replaceWith As per https://dom.spec.whatwg.org/#childnode ChildNode interface should contain before(), after() and replaceWith() API. As per https://dom.spec.whatwg.org/#parentnode ParentNode interface should contain prepend(), append() API. Intent to Implement and ship link: https://groups.google.com/a/chromium.org/forum/#!searchin/blink-dev/paritosh/blink-dev/efUPtYm1PP8/MGoTi17AYpcJ BUG=255482 Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=198629

Patch Set 1 : #

Patch Set 2 : #

Patch Set 3 #

Total comments: 21

Patch Set 4 : #

Patch Set 5 #

Total comments: 1

Patch Set 6 : #

Patch Set 7 : #

Total comments: 10

Patch Set 8 : #

Total comments: 10

Patch Set 9 : #

Total comments: 14

Patch Set 10 : #

Patch Set 11 : #

Total comments: 6

Patch Set 12 : #

Patch Set 13 : #

Total comments: 15

Patch Set 14 : #

Patch Set 15 : #

Total comments: 16

Patch Set 16 : #

Total comments: 3

Patch Set 17 #

Total comments: 4

Patch Set 18 : #

Patch Set 19 : #

Patch Set 20 : #

Patch Set 21 : #

Patch Set 22 : Last Reviewed #

Total comments: 2

Patch Set 23 : #

Unified diffs Side-by-side diffs Delta from patch set Stats (+789 lines, -7 lines) Patch
A LayoutTests/fast/dom/ChildNode/after.html View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 1 chunk +135 lines, -0 lines 0 comments Download
A LayoutTests/fast/dom/ChildNode/before.html View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 1 chunk +135 lines, -0 lines 0 comments Download
A LayoutTests/fast/dom/ChildNode/replace-with.html View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 1 chunk +120 lines, -0 lines 0 comments Download
A LayoutTests/fast/dom/ParentNode/append.html View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 1 chunk +73 lines, -0 lines 0 comments Download
A LayoutTests/fast/dom/ParentNode/append-on-document.html View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 1 chunk +50 lines, -0 lines 0 comments Download
A LayoutTests/fast/dom/ParentNode/prepend.html View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 1 chunk +73 lines, -0 lines 0 comments Download
A LayoutTests/fast/dom/ParentNode/prepend-on-document.html View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 1 chunk +50 lines, -0 lines 0 comments Download
M LayoutTests/webexposed/element-instance-property-listing-expected.txt View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 6 chunks +10 lines, -0 lines 0 comments Download
M LayoutTests/webexposed/global-interface-listing-expected.txt View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 6 chunks +15 lines, -0 lines 0 comments Download
M Source/core/dom/ChildNode.h View 1 2 3 1 chunk +15 lines, -0 lines 0 comments Download
M Source/core/dom/ChildNode.idl View 1 2 3 4 5 6 7 1 chunk +4 lines, -5 lines 0 comments Download
M Source/core/dom/Node.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 2 chunks +6 lines, -0 lines 0 comments Download
M Source/core/dom/Node.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 1 chunk +90 lines, -0 lines 0 comments Download
M Source/core/dom/ParentNode.h View 1 2 3 1 chunk +10 lines, -0 lines 0 comments Download
M Source/core/dom/ParentNode.idl View 1 2 3 4 1 chunk +2 lines, -2 lines 0 comments Download
M Source/platform/RuntimeEnabledFeatures.in View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 1 chunk +1 line, -0 lines 0 comments Download

Messages

Total messages: 65 (12 generated)
Paritosh Kumar
Please have a look.
5 years, 8 months ago (2015-04-14 12:02:15 UTC) #3
tkent
Please send "Intent to implement and Ship:" mail to blink-dev.
5 years, 8 months ago (2015-04-14 12:05:51 UTC) #4
Paritosh Kumar
On 2015/04/14 12:05:51, tkent wrote: > Please send "Intent to implement and Ship:" mail to ...
5 years, 8 months ago (2015-04-14 12:08:22 UTC) #5
tkent
> will We include other ChildNode API, after() and replacewith() > in the same Intent ...
5 years, 8 months ago (2015-04-14 12:10:46 UTC) #6
Paritosh Kumar
On 2015/04/14 12:10:46, tkent wrote: > > will We include other ChildNode API, after() and ...
5 years, 8 months ago (2015-04-15 08:57:32 UTC) #7
Paritosh Kumar
On 2015/04/15 08:57:32, Paritosh Kumar wrote: > On 2015/04/14 12:10:46, tkent wrote: > > > ...
5 years, 8 months ago (2015-04-21 15:49:21 UTC) #9
philipj_slow
Do you intend to add all 5 APIs in this CL? If you're going to ...
5 years, 8 months ago (2015-04-21 22:19:45 UTC) #10
tkent
- The CL subject has [WIP]. So, I assume this CL is not ready for ...
5 years, 8 months ago (2015-04-21 22:40:42 UTC) #11
Paritosh Kumar
Thanks tkent & Philip > Do you intend to add all 5 APIs Updated cl ...
5 years, 8 months ago (2015-04-22 14:23:45 UTC) #12
Paritosh Kumar
@tkent: Need some inputs. When writing tests for this, I'm expecting shouldThrow('test.prepend(null)'); should throw TypeError ...
5 years, 8 months ago (2015-04-24 06:42:08 UTC) #13
tkent
On 2015/04/24 06:42:08, Paritosh Kumar wrote: > shouldThrow('test.prepend(null)'); should throw TypeError Exception.(right?) > > But ...
5 years, 8 months ago (2015-04-24 06:51:01 UTC) #14
philipj_slow
It would be good to write these tests using testharness.js so that they can be ...
5 years, 8 months ago (2015-04-24 08:33:16 UTC) #15
Paritosh Kumar
Thanks tkent & Philip @tkent: > It's an expected behavior. See the specification. > http://heycam.github.io/webidl/#es-union ...
5 years, 8 months ago (2015-04-24 11:43:57 UTC) #16
philipj_slow
Some more feedback, sorry for the delay. https://codereview.chromium.org/1085843002/diff/60001/LayoutTests/fast/dom/Comment/after.html File LayoutTests/fast/dom/Comment/after.html (right): https://codereview.chromium.org/1085843002/diff/60001/LayoutTests/fast/dom/Comment/after.html#newcode4 LayoutTests/fast/dom/Comment/after.html:4: <script src="../script-tests/childnode-after.js"></script> ...
5 years, 7 months ago (2015-04-29 13:16:57 UTC) #17
Paritosh Kumar
On 2015/04/29 13:16:57, philipj_UTC2 wrote: > Some more feedback, sorry for the delay. > > ...
5 years, 7 months ago (2015-05-11 12:28:55 UTC) #18
Paritosh Kumar
Apologize, for too delay in update. Actually, There was some problem in building this after ...
5 years, 7 months ago (2015-05-27 11:25:01 UTC) #19
Paritosh Kumar
Hi Philip and tkent Apologize, After a long time, I'm updating this cl. Please take ...
5 years, 6 months ago (2015-06-08 12:21:24 UTC) #21
philipj_slow
A lot of the tests look similar and ProcessingInstruction is a kind of ChildNode not ...
5 years, 6 months ago (2015-06-08 12:49:20 UTC) #22
Paritosh Kumar
Thanks Philip, > A lot of the tests look similar and ProcessingInstruction is a kind ...
5 years, 6 months ago (2015-06-08 13:05:13 UTC) #23
Paritosh Kumar
@Philip: Updated as per your suggestion, Please have a look.
5 years, 6 months ago (2015-06-09 10:16:38 UTC) #24
philipj_slow
Some comments on LayoutTests/fast/dom/ChildNode/after.html that apply to all tests. I also see some cases not ...
5 years, 6 months ago (2015-06-09 12:48:32 UTC) #25
philipj_slow
The spec just changed in response to the bug you found: https://github.com/whatwg/dom/commit/2ace8fa7dde98eeaf319cc6b1f4cfe16a3264cb4 Can you update ...
5 years, 6 months ago (2015-06-12 14:06:27 UTC) #26
Paritosh Kumar
Thanks Philip for clarification on spec. Updated as per your suggestion. Please take a look. ...
5 years, 6 months ago (2015-06-12 15:55:37 UTC) #27
philipj_slow
https://codereview.chromium.org/1085843002/diff/180001/LayoutTests/fast/dom/ChildNode/after.html File LayoutTests/fast/dom/ChildNode/after.html (right): https://codereview.chromium.org/1085843002/diff/180001/LayoutTests/fast/dom/ChildNode/after.html#newcode8 LayoutTests/fast/dom/ChildNode/after.html:8: var innerHtml; Maybe capitalize as innerHTML to match the ...
5 years, 6 months ago (2015-06-12 16:12:33 UTC) #28
Paritosh Kumar
Thanks Philip Updated as you suggested. Please have a look. https://codereview.chromium.org/1085843002/diff/180001/LayoutTests/fast/dom/ChildNode/after.html File LayoutTests/fast/dom/ChildNode/after.html (right): https://codereview.chromium.org/1085843002/diff/180001/LayoutTests/fast/dom/ChildNode/after.html#newcode8 ...
5 years, 6 months ago (2015-06-15 08:55:23 UTC) #29
philipj_slow
Some more teeny tiny nits, but this looks pretty much done. https://codereview.chromium.org/1085843002/diff/200001/LayoutTests/fast/dom/ChildNode/after.html File LayoutTests/fast/dom/ChildNode/after.html (right): ...
5 years, 6 months ago (2015-06-15 10:06:58 UTC) #30
philipj_slow
On 2015/06/15 10:06:58, philipj wrote: > Some more teeny tiny nits, but this looks pretty ...
5 years, 6 months ago (2015-06-15 10:07:28 UTC) #31
Paritosh Kumar
Thanks Philip for updating about spec change. I tried to implement according to new spec ...
5 years, 6 months ago (2015-06-23 13:32:09 UTC) #32
philipj_slow
https://codereview.chromium.org/1085843002/diff/200001/Source/core/dom/Node.h File Source/core/dom/Node.h (right): https://codereview.chromium.org/1085843002/diff/200001/Source/core/dom/Node.h#newcode216 Source/core/dom/Node.h:216: PassRefPtrWillBeRawPtr<Node> nodeOrStringToNode(const NodeOrString&); On 2015/06/23 13:32:09, Paritosh Kumar wrote: ...
5 years, 6 months ago (2015-06-25 11:05:21 UTC) #33
philipj_slow
Some more comments. When I fiddled with the code around viable siblings I also checked ...
5 years, 6 months ago (2015-06-25 13:13:23 UTC) #34
Paritosh Kumar
Thanks Philip Updated as per your suggestion, Please have a look. https://codereview.chromium.org/1085843002/diff/240001/Source/core/dom/Node.cpp File Source/core/dom/Node.cpp (right): ...
5 years, 6 months ago (2015-06-26 13:14:06 UTC) #35
philipj_slow
Getting better and better. I haven't looked closely at the tests this time, if you ...
5 years, 6 months ago (2015-06-26 14:13:26 UTC) #36
Paritosh Kumar
Thanks Philip Updated the cl as per comments. Please have a look. https://codereview.chromium.org/1085843002/diff/280001/Source/core/dom/Node.cpp File Source/core/dom/Node.cpp ...
5 years, 5 months ago (2015-06-30 10:49:09 UTC) #37
philipj_slow
https://codereview.chromium.org/1085843002/diff/280001/Source/core/dom/Node.cpp File Source/core/dom/Node.cpp (right): https://codereview.chromium.org/1085843002/diff/280001/Source/core/dom/Node.cpp#newcode551 Source/core/dom/Node.cpp:551: this->insertBefore(convertNodesIntoNode(nodes, document()), this->firstChild(), exceptionState); On 2015/06/30 10:49:09, Paritosh Kumar ...
5 years, 5 months ago (2015-07-02 09:20:01 UTC) #38
Paritosh Kumar
Thanks Philip. Updated, Please have a look. On 2015/07/02 09:20:01, philipj wrote: > https://codereview.chromium.org/1085843002/diff/280001/Source/core/dom/Node.cpp > ...
5 years, 5 months ago (2015-07-03 04:59:55 UTC) #39
philipj_slow
Code looks good, just some possible improvements to the tests. https://codereview.chromium.org/1085843002/diff/320001/LayoutTests/fast/dom/ChildNode/after.html File LayoutTests/fast/dom/ChildNode/after.html (right): https://codereview.chromium.org/1085843002/diff/320001/LayoutTests/fast/dom/ChildNode/after.html#newcode33 ...
5 years, 5 months ago (2015-07-03 21:52:06 UTC) #40
Paritosh Kumar
Thanks Philip Updated cl, please have a look. https://codereview.chromium.org/1085843002/diff/320001/LayoutTests/fast/dom/ChildNode/after.html File LayoutTests/fast/dom/ChildNode/after.html (right): https://codereview.chromium.org/1085843002/diff/320001/LayoutTests/fast/dom/ChildNode/after.html#newcode33 LayoutTests/fast/dom/ChildNode/after.html:33: }, ...
5 years, 5 months ago (2015-07-06 09:02:27 UTC) #41
philipj_slow
Looking good. tkent@, I think this is pretty much done now, can you please give ...
5 years, 5 months ago (2015-07-06 12:02:40 UTC) #42
Paritosh Kumar
Thanks Philip Updated append.html and prepend.html, to exclude Document test. Added new files append-on-Document.html and ...
5 years, 5 months ago (2015-07-06 13:59:34 UTC) #43
philipj_slow
LGTM % nits, which also apply to the other new test. https://codereview.chromium.org/1085843002/diff/360001/LayoutTests/fast/dom/ParentNode/append-on-document.html File LayoutTests/fast/dom/ParentNode/append-on-document.html (right): ...
5 years, 5 months ago (2015-07-06 14:21:33 UTC) #44
tkent
I have no additional comments. Please go ahead.
5 years, 5 months ago (2015-07-07 00:25:05 UTC) #45
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1085843002/400001
5 years, 5 months ago (2015-07-07 07:57:13 UTC) #49
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: win_blink_rel on tryserver.blink (JOB_FAILED, http://build.chromium.org/p/tryserver.blink/builders/win_blink_rel/builds/69454) (exceeded global ...
5 years, 5 months ago (2015-07-07 08:57:44 UTC) #51
philipj_slow
The bots are failing because these tests need to be updated: webexposed/global-interface-listing.html webexposed/element-instance-property-listing.html win_blink_rel also ...
5 years, 5 months ago (2015-07-07 09:22:01 UTC) #52
Paritosh Kumar
Thanks Philip for looking into this. I looked into the cause of failure of new ...
5 years, 5 months ago (2015-07-09 14:12:56 UTC) #53
philipj_slow
LGTM, C++ is hard: http://stackoverflow.com/questions/621542/compilers-and-argument-order-of-evaluation-in-c https://codereview.chromium.org/1085843002/diff/480001/Source/core/dom/Node.cpp File Source/core/dom/Node.cpp (right): https://codereview.chromium.org/1085843002/diff/480001/Source/core/dom/Node.cpp#newcode548 Source/core/dom/Node.cpp:548: appendChild(convertNodesIntoNode(nodes, document()), exceptionState); Can ...
5 years, 5 months ago (2015-07-09 14:48:45 UTC) #54
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1085843002/500001
5 years, 5 months ago (2015-07-09 14:57:02 UTC) #57
commit-bot: I haz the power
Dry run: This issue passed the CQ dry run.
5 years, 5 months ago (2015-07-09 17:08:33 UTC) #59
Paritosh Kumar
On 2015/07/09 14:48:45, philipj wrote: > LGTM, C++ is hard: > http://stackoverflow.com/questions/621542/compilers-and-argument-order-of-evaluation-in-c > > https://codereview.chromium.org/1085843002/diff/480001/Source/core/dom/Node.cpp ...
5 years, 5 months ago (2015-07-09 20:18:32 UTC) #60
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1085843002/500001
5 years, 5 months ago (2015-07-09 20:19:12 UTC) #62
commit-bot: I haz the power
Committed patchset #23 (id:500001) as https://src.chromium.org/viewvc/blink?view=rev&revision=198629
5 years, 5 months ago (2015-07-09 20:23:22 UTC) #63
philipj_slow
Yay! If you want to continue to drive this feature to shipping, I think the ...
5 years, 5 months ago (2015-07-09 21:34:32 UTC) #64
dominicc (has gone to gerrit)
5 years, 5 months ago (2015-07-13 05:38:10 UTC) #65
Message was sent while issue was closed.
A revert of this CL (patchset #23 id:500001) has been created in
https://codereview.chromium.org/1234813003/ by dominicc@chromium.org.

The reason for reverting is: I suspect that this caused Issue 509461..

Powered by Google App Engine
This is Rietveld 408576698