mirror of
https://github.com/laurent22/joplin.git
synced 2024-11-27 08:21:03 +02:00
All: Fixed Markdown rendering when code highlighting is disabled
This commit is contained in:
parent
1dd6c7dde5
commit
62c67cb09f
@ -409,10 +409,16 @@ export default class MdToHtml {
|
||||
outputCodeHtml = markdownIt.utils.escapeHtml(trimmedStr);
|
||||
}
|
||||
|
||||
return {
|
||||
wrapCode: false,
|
||||
html: `<div class="joplin-editable">${sourceBlockHtml}<pre class="hljs"><code>${outputCodeHtml}</code></pre></div>`,
|
||||
};
|
||||
const html = `<div class="joplin-editable">${sourceBlockHtml}<pre class="hljs"><code>${outputCodeHtml}</code></pre></div>`;
|
||||
|
||||
if (rules.fence) {
|
||||
return {
|
||||
wrapCode: false,
|
||||
html: html,
|
||||
};
|
||||
} else {
|
||||
return html;
|
||||
}
|
||||
},
|
||||
});
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user