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

Change subject: Fix RegEx for matching special tags
......................................................................

Fix RegEx for matching special tags

ERM: #2832

Needs cherry-picking to REL1_27 and master

Change-Id: I65b5bf5fa38067a63ae60e39d925f7174742d927
---
M VisualEditor/resources/tiny_mce_plugins/bswikicode/plugin.js
1 file changed, 1 insertion(+), 1 deletion(-)


  git pull 
ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/BlueSpiceExtensions 
refs/changes/19/338719/1

diff --git a/VisualEditor/resources/tiny_mce_plugins/bswikicode/plugin.js 
b/VisualEditor/resources/tiny_mce_plugins/bswikicode/plugin.js
index 3434a24..7a96155 100644
--- a/VisualEditor/resources/tiny_mce_plugins/bswikicode/plugin.js
+++ b/VisualEditor/resources/tiny_mce_plugins/bswikicode/plugin.js
@@ -1793,7 +1793,7 @@
 
                specialTagsList = 
mw.config.get('BsVisualEditorConfigDefault').specialtaglist;
                // Tags without innerHTML need /> as end marker. Maybe this 
should be task of a preprocessor, in order to allow mw style tags without /.
-               regex = '<(' + specialTagsList + 
')[\\S\\s]*?((/>)|(>([\\S\\s]*?<\\/\\1>)))';
+               regex = '<(' + specialTagsList + ')( 
[^>]*)*?((\s\/>)|(\/>)|(>([\S\s]*?<\/\1>)))';
 
                matcher = new RegExp(regex, 'gmi');
                mtext = text;

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I65b5bf5fa38067a63ae60e39d925f7174742d927
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/BlueSpiceExtensions
Gerrit-Branch: REL1_23
Gerrit-Owner: ItSpiderman <[email protected]>

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

Reply via email to