diff options
| author | Volpeon <git@volpeon.ink> | 2023-02-15 22:25:57 +0100 |
|---|---|---|
| committer | Volpeon <git@volpeon.ink> | 2023-02-15 22:25:57 +0100 |
| commit | aa61b6069f9552e765033e67223049bc2156916b (patch) | |
| tree | 9a1f213ce0a21119453ceeac1e61f0722f899900 /filters | |
| parent | Update (diff) | |
| download | volpeon.ink-aa61b6069f9552e765033e67223049bc2156916b.tar.gz volpeon.ink-aa61b6069f9552e765033e67223049bc2156916b.tar.bz2 volpeon.ink-aa61b6069f9552e765033e67223049bc2156916b.zip | |
Fix
Diffstat (limited to 'filters')
| -rw-r--r-- | filters/code.lua | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/filters/code.lua b/filters/code.lua index 2d6e5a5..41da4d7 100644 --- a/filters/code.lua +++ b/filters/code.lua | |||
| @@ -3,12 +3,12 @@ local common = require 'filters.lib.common' | |||
| 3 | function CodeBlock(el) | 3 | function CodeBlock(el) |
| 4 | if el.classes[1] == "plain" then | 4 | if el.classes[1] == "plain" then |
| 5 | el = pandoc.Div({ el }, { class = 's-code' }) | 5 | el = pandoc.Div({ el }, { class = 's-code' }) |
| 6 | elseif el.classes[1] then | 6 | -- elseif el.classes[1] then |
| 7 | local formatted = pandoc.pipe('pygmentize', { | 7 | -- local formatted = pandoc.pipe('pygmentize', { |
| 8 | '-l', el.classes[1], '-f', 'html', '-O', 'cssclass=s-code s-code--highlight', | 8 | -- '-l', el.classes[1], '-f', 'html', '-O', 'cssclass=s-code s-code--highlight', |
| 9 | }, el.text) | 9 | -- }, el.text) |
| 10 | 10 | -- | |
| 11 | if formatted then el = pandoc.RawBlock('html', formatted) end | 11 | -- if formatted then el = pandoc.RawBlock('html', formatted) end |
| 12 | end | 12 | end |
| 13 | 13 | ||
| 14 | return common.wide(el) | 14 | return common.wide(el) |
