Commit 33080001 authored by hetech's avatar hetech Committed by GitHub

chore: hide demo description when it's empty (#15014)

parent 5a895bd6
......@@ -11,7 +11,7 @@ module.exports = md => {
const description = m && m.length > 1 ? m[1] : '';
const content = tokens[idx + 1].type === 'fence' ? tokens[idx + 1].content : '';
return `<demo-block>
<div>${md.render(description)}</div>
${description ? `<div>${md.render(description)}</div>` : ''}
<!--element-demo: ${content}:element-demo-->
`;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment