From c31c12d698c0ea321e777d3fe8afbb8065ebe651 Mon Sep 17 00:00:00 2001 From: Jeremy Ruston Date: Sun, 23 Dec 2012 10:36:25 +0000 Subject: [PATCH] Fix bug with extraneous dot in classed blocks --- core/modules/parsers/wikiparser/rules/styleblock.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/core/modules/parsers/wikiparser/rules/styleblock.js b/core/modules/parsers/wikiparser/rules/styleblock.js index 2b3cd2e07..c9e27209b 100644 --- a/core/modules/parsers/wikiparser/rules/styleblock.js +++ b/core/modules/parsers/wikiparser/rules/styleblock.js @@ -38,7 +38,7 @@ exports.types = {block: true}; exports.init = function(parser) { this.parser = parser; // Regexp to match - this.matchRegExp = /@@((?:[^\.\r\n\s:]+:[^\r\n;]+;)+)?(\.(?:[^\r\n\s]+))?\r?\n/mg; + this.matchRegExp = /@@((?:[^\.\r\n\s:]+:[^\r\n;]+;)+)?(?:\.([^\r\n\s]+))?\r?\n/mg; }; exports.parse = function() { @@ -50,7 +50,7 @@ exports.parse = function() { styles.push(this.match[1]); } if(this.match[2]) { - classes.push(this.match[2]); + classes.push(this.match[2].split(".").join(" ")); } // Move past the match this.parser.pos = this.matchRegExp.lastIndex;