git.iko.soy/typeable/pandoc
on master help sign in
Small improvement to figcaption parsing. #4184.
commitf688086979307bb5c81ffe61ed09493bc72785a5 authorJohn MacFarlane <jgm@berkeley.edu> dateWed 27 Dec 2017, 12:38 (9 years ago) parentacfa846
1 file changed−2
src/Text/Pandoc/Readers/HTML.hs−2
src/Text/Pandoc/Readers/HTML.hs−2
@@ -601,9 +601,7 @@ pFigure = try $ do
601601 let pImg = (\x -> (Just x, Nothing)) <$>
602602 (pOptInTag "p" pImage <* skipMany pBlank)
603603 pCapt = (\x -> (Nothing, Just x)) <$> do
604− skipMany pBlank
605604 bs <- pInTags "figcaption" block
606− skipMany pBlank
607605 return $ blocksToInlines' $ B.toList bs
608606 pSkip = (Nothing, Nothing) <$ pSatisfy (not . matchTagClose "figure")
609607 res <- many (pImg <|> pCapt <|> pSkip)