This commit is contained in:
amehime
2020-05-06 04:13:59 +08:00
parent db74274bc1
commit beb8efbd5e

View File

@@ -55,7 +55,7 @@ module.exports = function (md, options) {
const {
firstLine = 1,
caption,
caption = '',
mark = false,
command = false
} = getOptions(info.slice(lang.length));
@@ -86,13 +86,11 @@ module.exports = function (md, options) {
}
let result = `<figure class="highlight${langToUse ? ` ${langToUse}` : ''}">`;
if (caption) {
result += `<figcaption><span class="lang">${langShow}</span>${caption}</figcaption>`;
}
result += `<figcaption><span class="lang">${langShow}</span>${caption}</figcaption>`;
result += `<table><tr><td class="gutter"><pre>${numbers}</pre></td>`;
result += `<td class="code"><pre>${content}</pre></td>`;
result += '</tr></table></figure>';