git.iko.soy/typeable/pandoc
on master help sign in
LaTeX reader: don't drop contents of \hypertarget.
commitd21c7fee66d6737ae1262cfea01633d041499da2 authorJohn MacFarlane <jgm@berkeley.edu> dateWed 1 Mar 2017, 21:05 (10 years ago) parent39a8359
1 file changed+3
src/Text/Pandoc/Readers/LaTeX.hs+3
src/Text/Pandoc/Readers/LaTeX.hs+3
@@ -375,6 +375,8 @@ blockCommands = M.fromList $
375375 -- includes
376376 , ("lstinputlisting", inputListing)
377377 , ("graphicspath", graphicsPath)
378+ -- hyperlink
379+ , ("hypertarget", braced >> grouped block)
378380 ] ++ map ignoreBlocks
379381 -- these commands will be ignored unless --parse-raw is specified,
380382 -- in which case they will appear as raw latex blocks
@@ -645,6 +647,7 @@ inlineCommands = M.fromList $
645647 <|> citation "citeauthor" AuthorInText False)
646648 , ("nocite", mempty <$ (citation "nocite" NormalCitation False >>=
647649 addMeta "nocite"))
650+ , ("hypertarget", braced >> tok)
648651 ] ++ map ignoreInlines
649652 -- these commands will be ignored unless --parse-raw is specified,
650653 -- in which case they will appear as raw latex blocks: