File tree Expand file tree Collapse file tree 2 files changed +4
-1
lines changed
Expand file tree Collapse file tree 2 files changed +4
-1
lines changed Original file line number Diff line number Diff line change @@ -24,6 +24,9 @@ function asciidocFigure(image)
2424 -- alt text (ok to use HTML entities since alt is expressly for HTML output)
2525 local altText = image .attr .attributes [" alt" ] or image .attr .attributes [kFigAlt ] or " "
2626 altText = altText :gsub (" \" " , " "" )
27+ altText = altText :gsub (" <" , " <" )
28+ altText = altText :gsub (" >" , " >" )
29+ altText = altText :gsub (" &" , " &" )
2730
2831 -- the figure itself
2932 figure :extend ({" image::" .. image .src .. " [\" " .. altText .. " \" ]" })
Original file line number Diff line number Diff line change @@ -27,7 +27,7 @@ function renderAsciidoc()
2727 local identifier = span .identifier
2828 if refType (identifier ) == " sec" then
2929 -- this is a chapter title, tear out the id and make it ourselves
30- local titleContents = pandoc .write (pandoc .Pandoc (span .content ), " asciidoc" )
30+ local titleContents = pandoc .write (pandoc .Pandoc ({ span .content } ), " asciidoc" )
3131 meta [' title' ] = pandoc .RawInline (" asciidoc" , titleContents )
3232 meta [' title-prefix' ] = pandoc .RawInline (" asciidoc" , " [[" .. identifier .. " ]]" )
3333 end
You can’t perform that action at this time.
0 commit comments