add _extensions

This commit is contained in:
2026-05-21 13:37:53 +08:00
parent 6a9a5fc90e
commit 61bd0bea2f
252 changed files with 33972 additions and 1 deletions
@@ -0,0 +1,15 @@
--- Remove local links but keep the link text as normal citations
--- Reference: https://stackoverflow.com/a/75559075/19418090
--- Copyright: © 2023 Albert Krewinkel, 2024Present Albert Krewinkel, Tom Ben
--- License: MIT License
function Link(link)
if not link.target:match '^https?://' then
local linkstring = pandoc.utils.stringify(link.content)
local citationmd = string.format('[%s]', linkstring)
return pandoc.utils.blocks_to_inlines(
pandoc.read(citationmd, 'markdown').blocks
)
end
end