Subramanya Sastry has uploaded a new change for review. https://gerrit.wikimedia.org/r/325059
Change subject: Lebab: Convert bin/ to use obj-method ES6 syntax ...................................................................... Lebab: Convert bin/ to use obj-method ES6 syntax Change-Id: I462bc1c8be13e49f6e06e904319f635d01118296 --- M bin/parserTests.js 1 file changed, 10 insertions(+), 10 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/services/parsoid refs/changes/59/325059/1 diff --git a/bin/parserTests.js b/bin/parserTests.js index c0e1fe1..60537f5 100755 --- a/bin/parserTests.js +++ b/bin/parserTests.js @@ -748,7 +748,7 @@ // on the results of the selector in the first argument, which is // a good way to get at the text and comment nodes const jquery = { - after: function(html) { + after(html) { let div, tbl; if (this.parentNode.nodeName === 'TBODY') { tbl = this.ownerDocument.createElement('table'); @@ -766,10 +766,10 @@ DU.migrateChildren(div, this.parentNode, this.nextSibling); } }, - attr: function(name, val) { + attr(name, val) { this.setAttribute(name, val); }, - before: function(html) { + before(html) { let div, tbl; if (this.parentNode.nodeName === 'TBODY') { tbl = this.ownerDocument.createElement('table'); @@ -787,22 +787,22 @@ DU.migrateChildren(div, this.parentNode, this); } }, - removeAttr: function(name) { + removeAttr(name) { this.removeAttribute(name); }, - removeClass: function(c) { + removeClass(c) { this.classList.remove(c); }, - addClass: function(c) { + addClass(c) { this.classList.add(c); }, - text: function(t) { + text(t) { this.textContent = t; }, - html: function(h) { + html(h) { this.innerHTML = h; }, - remove: function(optSelector) { + remove(optSelector) { // jquery lets us specify an optional selector to further // restrict the removed elements. // text nodes don't have the "querySelectorAll" method, so @@ -815,7 +815,7 @@ if (node.parentNode) { node.parentNode.removeChild(node); } }); }, - empty: function() { + empty() { while (this.firstChild) { this.removeChild(this.firstChild); } -- To view, visit https://gerrit.wikimedia.org/r/325059 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I462bc1c8be13e49f6e06e904319f635d01118296 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/services/parsoid Gerrit-Branch: master Gerrit-Owner: Subramanya Sastry <ssas...@wikimedia.org> _______________________________________________ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits