[fix] mathjax render (#532)
This commit is contained in:
parent
d0f3ab8d48
commit
85eae414cb
|
@ -22,7 +22,7 @@ module.exports = ctx => function(args, content) {
|
|||
el += '>'
|
||||
// title
|
||||
if (title && title.length > 0) {
|
||||
el += '<div class="title"><strong>' + title + '</strong></div>'
|
||||
el += '<div class="title"><strong>' + ctx.render.renderSync({text: title, engine: 'markdown'}) + '</strong></div>'
|
||||
}
|
||||
// content
|
||||
el += '<div class="body">'
|
||||
|
|
|
@ -39,7 +39,7 @@ module.exports = ctx => function(args, content) {
|
|||
nodes.forEach((node, i) => {
|
||||
el += '<details class="folder" index="' + (i) + '">'
|
||||
// summary
|
||||
el += '<summary><span>' + (node.header || '') + '</span></summary>'
|
||||
el += '<summary>' + ctx.render.renderSync({text: (node.header || ''), engine: 'markdown'}) + '</summary>'
|
||||
// content
|
||||
el += '<div class="body">'
|
||||
el += ctx.render.renderSync({text: (node.body || ''), engine: 'markdown'}).split('\n').join('')
|
||||
|
|
|
@ -20,7 +20,7 @@ module.exports = ctx => function(args, content) {
|
|||
}
|
||||
el += '>'
|
||||
// summary
|
||||
el += '<summary><span>' + (args.title || '') + '</span></summary>'
|
||||
el += '<summary>' + ctx.render.renderSync({text: (args.title || ''), engine: 'markdown'}) + '</summary>'
|
||||
// content
|
||||
el += '<div class="body">'
|
||||
el += ctx.render.renderSync({text: content, engine: 'markdown'}).split('\n').join('')
|
||||
|
|
Loading…
Reference in New Issue