Arlolra has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/397721 )

Change subject: [WIP] Handle table end following templates in attribute position
......................................................................

[WIP] Handle table end following templates in attribute position

Bug: T126834
Change-Id: I1b83ef52efdafcd96aeac9a06a951235bbb69f5b
---
M lib/wt2html/tt/AttributeExpander.js
1 file changed, 4 insertions(+), 0 deletions(-)


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

diff --git a/lib/wt2html/tt/AttributeExpander.js 
b/lib/wt2html/tt/AttributeExpander.js
index 9a76502..f34cd24 100644
--- a/lib/wt2html/tt/AttributeExpander.js
+++ b/lib/wt2html/tt/AttributeExpander.js
@@ -14,6 +14,7 @@
 // define some constructor shortcuts
 var NlTk = defines.NlTk;
 var TagTk = defines.TagTk;
+var EndTagTk = defines.EndTagTk;
 var SelfclosingTagTk = defines.SelfclosingTagTk;
 
 
@@ -346,6 +347,9 @@
                                                expandedK = updatedK.preNLBuf;
                                                postNLToks = updatedK.postNLBuf;
                                                metaTokens = 
updatedK.metaTokens;
+                                               if 
(postNLToks[postNLToks.length - 1] === '|}') {
+                                                       
postNLToks.splice(postNLToks.length - 1, 1, new EndTagTk('table'));
+                                               }
                                        } else {
                                                // Scenario 2 from the 
documentation comment above.
                                                updatedK = 
stripMetaTags(expandedK, wrapTemplates);

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I1b83ef52efdafcd96aeac9a06a951235bbb69f5b
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/services/parsoid
Gerrit-Branch: master
Gerrit-Owner: Arlolra <abrea...@wikimedia.org>

_______________________________________________
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to