mirror of
https://github.com/marktext/marktext.git
synced 2025-05-03 04:51:28 +08:00
fix: render error when render front icon (#806)
This commit is contained in:
parent
ef2b12603b
commit
c6def5a726
@ -28,6 +28,7 @@ export default function renderIcon (block) {
|
||||
const { type, functionType, listType } = block
|
||||
const selector = `a.ag-front-icon`
|
||||
let icon = null
|
||||
|
||||
switch (type) {
|
||||
case 'p': {
|
||||
icon = paragraphIcon
|
||||
@ -44,7 +45,7 @@ export default function renderIcon (block) {
|
||||
break
|
||||
}
|
||||
case 'pre': {
|
||||
if (functionType === 'fencecode') {
|
||||
if (functionType === 'fencecode' || functionType === 'indentcode') {
|
||||
icon = codeIcon
|
||||
} else if (functionType === 'frontmatter') {
|
||||
icon = frontMatterIcon
|
||||
|
Loading…
Reference in New Issue
Block a user