This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| -- highlight.lua | |
| -- Converts ==highlighted text== to LaTeX \mdhighlight{} command (CJK compatible) | |
| function Span(el) | |
| if el.classes[1] == "mark" then | |
| return pandoc.RawInline('latex', '\\mdhighlight{' .. pandoc.utils.stringify(el.content) .. '}') | |
| end | |
| end | |
| function Str(el) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| -- obsidian-callouts.lua | |
| -- Converts Obsidian callout blocks to LaTeX tcolorbox | |
| -- Callout type to color mapping | |
| local callout_colors = { | |
| note = {bg = "blue!5!white", border = "blue!60!black"}, | |
| info = {bg = "cyan!5!white", border = "cyan!60!black"}, | |
| tip = {bg = "teal!5!white", border = "teal!60!black"}, | |
| warning = {bg = "orange!5!white", border = "orange!80!black"}, | |
| caution = {bg = "orange!5!white", border = "orange!80!black"}, |