mirror of
https://github.com/showdownjs/showdown.git
synced 2024-03-22 13:30:55 +08:00
Merge pull request #698 from systemsthinkinginstitute/fix-space-between-inline-elements
Fix space between inline elements
This commit is contained in:
commit
45fcc8435b
|
@ -393,7 +393,7 @@ showdown.Converter = function (converterOptions) {
|
||||||
for (var n = 0; n < node.childNodes.length; ++n) {
|
for (var n = 0; n < node.childNodes.length; ++n) {
|
||||||
var child = node.childNodes[n];
|
var child = node.childNodes[n];
|
||||||
if (child.nodeType === 3) {
|
if (child.nodeType === 3) {
|
||||||
if (!/\S/.test(child.nodeValue)) {
|
if (!/\S/.test(child.nodeValue) && !/^[ ]+$/.test(child.nodeValue)) {
|
||||||
node.removeChild(child);
|
node.removeChild(child);
|
||||||
--n;
|
--n;
|
||||||
} else {
|
} else {
|
||||||
|
|
|
@ -0,0 +1 @@
|
||||||
|
<p><em>one</em> <em>two</em> <em>three</em></p>
|
|
@ -0,0 +1 @@
|
||||||
|
*one* *two* *three*
|
Loading…
Reference in New Issue
Block a user