Arlolra has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/264120

Change subject: Document this while it's in my head
......................................................................

Document this while it's in my head

Change-Id: Ie3fee1d117d76dcbee746dde16a6c70ec2fdc442
---
M lib/wt2html/pp/wrapTemplates.js
1 file changed, 4 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/services/parsoid 
refs/changes/20/264120/1

diff --git a/lib/wt2html/pp/wrapTemplates.js b/lib/wt2html/pp/wrapTemplates.js
index ee20832..d7d609d 100644
--- a/lib/wt2html/pp/wrapTemplates.js
+++ b/lib/wt2html/pp/wrapTemplates.js
@@ -338,6 +338,10 @@
        var n, r, data, ranges;
        var numRanges = tplRanges.length;
 
+       // The `inSiblingOrder` check here is sufficient to determine overlaps
+       // because the algorithm in `findWrappableTemplateRanges` will put the
+       // start/end elements for intersecting ranges on the same plane and 
prev/
+       // curr are in textual order (which hopefully translates to dom order).
        function rangesOverlap(prev, curr) {
                var prevEnd   = !r.flipped ? prev.end : prev.start;
                var currStart = !r.flipped ? curr.start : curr.end;

-- 
To view, visit https://gerrit.wikimedia.org/r/264120
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ie3fee1d117d76dcbee746dde16a6c70ec2fdc442
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/services/parsoid
Gerrit-Branch: master
Gerrit-Owner: Arlolra <[email protected]>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to