X-Git-Url: https://git.plutz.net/?a=blobdiff_plain;f=cgilite%2Fmarkdown.awk;h=540292c5cfbedd31875114e7d9cca073f3d629ff;hb=8250ca8829e0ac4dde2871b445df248e6079411a;hp=4ef76453515c9c1ec0a8ca72db3ac99250ca2b9b;hpb=fc220928ead75918a98d045ba606e871e27eaa4c;p=shellwiki diff --git a/cgilite/markdown.awk b/cgilite/markdown.awk index 4ef7645..540292c 100755 --- a/cgilite/markdown.awk +++ b/cgilite/markdown.awk @@ -337,7 +337,7 @@ function _block( block, LOCAL, st, len, hlvl, htxt, guard, code, indent, attrib } else if ( match( block, /^(~~~+|```+)/ ) ) { guard = substr( block, 1, RLENGTH ); code = gensub(/^[^\n]+\n/, "", 1, block); - attrib = gensub(/^:::+[ \t]*\{?[ \t]*([^\}\n]*)\}?[ \t]*\n.*$/, "\\1", 1, block); + attrib = gensub(/^(~~~+|```+)[ \t]*\{?[ \t]*([^\}\n]*)\}?[ \t]*\n.*$/, "\\2", 1, block); gsub(/[^a-zA-Z0-9_-]+/, " ", attrib); gsub(/(^ | $)/, "", attrib); if ( match(code, "(^|\n)" guard "+(\n|$)" ) ) {