From 8c90b46d8b5a9dfbbff4da8c2999c1b4b5ca4b51 Mon Sep 17 00:00:00 2001 From: John MacFarlane Date: Sun, 10 Dec 2023 11:22:08 -0800 Subject: Typst reader: support sys.version. --- cabal.project | 2 +- src/Text/Pandoc/Readers/Typst.hs | 1 + stack.yaml | 2 +- 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/cabal.project b/cabal.project index fe492142e..07515e51c 100644 --- a/cabal.project +++ b/cabal.project @@ -28,4 +28,4 @@ source-repository-package source-repository-package type: git location: https://github.com/jgm/typst-hs - tag: 982fa627a97942839072ffa3c784870d781f49ac + tag: 94747f802831b05b5c28bba0bd7a7a30217bda8d diff --git a/src/Text/Pandoc/Readers/Typst.hs b/src/Text/Pandoc/Readers/Typst.hs index b450cc3ed..5e20fe9c6 100644 --- a/src/Text/Pandoc/Readers/Typst.hs +++ b/src/Text/Pandoc/Readers/Typst.hs @@ -521,6 +521,7 @@ inlineHandlers = M.fromList alignment <- getField "alignment" fields B.spanWith ("", [], [("align", repr alignment)]) <$> (getField "body" fields >>= pWithContents pInlines)) + ,("sys.version", \_ fields -> pure $ B.text "typst-hs") ,("math.equation", \_ fields -> do body <- getField "body" fields display <- getField "block" fields diff --git a/stack.yaml b/stack.yaml index 6adb9b900..70c3b0f1d 100644 --- a/stack.yaml +++ b/stack.yaml @@ -27,7 +27,7 @@ extra-deps: - tls-1.9.0 - commonmark-0.2.4 - git: https://github.com/jgm/typst-hs - commit: 982fa627a97942839072ffa3c784870d781f49ac + commit: 94747f802831b05b5c28bba0bd7a7a30217bda8d - git: https://github.com/jgm/commonmark-hs subdirs: [commonmark-extensions, commonmark-pandoc] commit: 0c4807c92b94b1b5ac0f0845daac276ab9d3495f -- cgit v1.2.3