Skip to content

Commit 2dc9679

Browse files
author
Al Manning
committed
Link
1 parent d55fb94 commit 2dc9679

File tree

1 file changed

+13
-3
lines changed

1 file changed

+13
-3
lines changed

src/resources/extensions/quarto/confluence/publish.lua

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,12 +20,22 @@ end
2020

2121
function Writer (doc, opts)
2222
local filter = {
23-
Image = function (img)
23+
Image = function (image)
2424
local renderString = confluence.CaptionedImageConfluence(
25-
img.src, img.title, 'Elephant', img.attr)
26-
dump(renderString, 'renderString')
25+
image.src,
26+
image.title,
27+
pandoc.utils.stringify(image.caption),
28+
image.attr)
2729
return pandoc.RawInline('html', renderString)
2830
end,
31+
Link = function (link)
32+
local renderString = confluence.LinkConfluence(
33+
pandoc.utils.stringify(link.content),
34+
link.target,
35+
link.title,
36+
link.attr)
37+
return pandoc.RawInline('html', renderString)
38+
end
2939
}
3040
return pandoc.write(doc:walk(filter), 'html', opts)
3141
end

0 commit comments

Comments
 (0)