From 9c5e6aeedc8fe8653e9e050d5dfefc969f0d8e8c Mon Sep 17 00:00:00 2001 From: John MacFarlane Date: Mon, 18 Dec 2023 09:54:14 -0800 Subject: Docx writer: fix validation error. The elements in pPr in lists were not properly ordered. This doesn't seem to cause problems for Word, but it makes validation fail and may pose problems for other consumers of docx. Closes #9265. --- src/Text/Pandoc/Writers/Docx.hs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/Text') diff --git a/src/Text/Pandoc/Writers/Docx.hs b/src/Text/Pandoc/Writers/Docx.hs index e89ec4801..b0d902403 100644 --- a/src/Text/Pandoc/Writers/Docx.hs +++ b/src/Text/Pandoc/Writers/Docx.hs @@ -1246,7 +1246,7 @@ getParaProps displayMathPara = do let listPr = [mknode "w:numPr" [] [ mknode "w:ilvl" [("w:val",tshow listLevel)] () , mknode "w:numId" [("w:val",tshow numid')] () ] | listLevel >= 0 && not displayMathPara] - return $ case listPr ++ squashProps props of + return $ case squashProps (EnvProps Nothing listPr <> props) of [] -> [] ps -> [mknode "w:pPr" [] ps] -- cgit v1.2.3