diff options
author | John MacFarlane <jgm@berkeley.edu> | 2019-06-11 16:19:12 -0700 |
---|---|---|
committer | John MacFarlane <jgm@berkeley.edu> | 2019-06-11 16:19:12 -0700 |
commit | f7c0d2fb3f9ba8ac6c20ea03a2dbe0709c0d026f (patch) | |
tree | 4cd7c43138905d9d23d0ac048e41957545ece63c /src/Text/Pandoc | |
parent | bb68c183b38542b9acf1090a1ceaa84455aedc4b (diff) | |
download | pandoc-f7c0d2fb3f9ba8ac6c20ea03a2dbe0709c0d026f.tar.gz |
JATS writer: don't use break element for LineBreak.
It's only allowed in a few special contexts, and not in
p elements.
Diffstat (limited to 'src/Text/Pandoc')
-rw-r--r-- | src/Text/Pandoc/Writers/JATS.hs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/Text/Pandoc/Writers/JATS.hs b/src/Text/Pandoc/Writers/JATS.hs index c5e86956b..07a49ceac 100644 --- a/src/Text/Pandoc/Writers/JATS.hs +++ b/src/Text/Pandoc/Writers/JATS.hs @@ -390,7 +390,8 @@ inlineToJATS _ il@(RawInline f x) | otherwise = do report $ InlineNotRendered il return empty -inlineToJATS _ LineBreak = return $ selfClosingTag "break" [] +inlineToJATS _ LineBreak = return cr -- not allowed as child of p +-- see https://jats.nlm.nih.gov/publishing/tag-library/1.2/element/break.html inlineToJATS _ Space = return space inlineToJATS opts SoftBreak | writerWrapText opts == WrapPreserve = return cr |