git.iko.soy/typeable/pandoc
on master help sign in
Org reader: convert markup at beginning of footnotes

Closes: #3576

commit56dddcc3f556217a3354aff2e887b0ba4714f369 authorAlbert Krewinkel <albert@zeitkraut.de> dateSun 16 Apr 2017, 17:22 (10 years ago) parente6a536b
2 files changed+11−1
src/Text/Pandoc/Readers/Org/Blocks.hs+1−1 test/Tests/Readers/Org.hs+10
src/Text/Pandoc/Readers/Org/Blocks.hs+1−1
@@ -869,7 +869,7 @@ latexEnd envName = try $
869869--
870870noteBlock :: PandocMonad m => OrgParser m (F Blocks)
871871noteBlock = try $ do
872− ref <- noteMarker <* skipSpaces
872+ ref <- noteMarker <* skipSpaces <* updateLastPreCharPos
873873 content <- mconcat <$> blocksTillHeaderOrNote
874874 addToNotesTable (ref, content)
875875 return mempty
test/Tests/Readers/Org.hs+10
@@ -1028,6 +1028,16 @@ tests =
10281028 , note $ para ("Second" <> space <> "note.")
10291029 ])
10301030
1031+ , "Footnote that starts with emphasized text" =:
1032+ unlines [ "text[fn:1]"
1033+ , ""
1034+ , "[fn:1] /emphasized/"
1035+ ] =?>
1036+ para (mconcat
1037+ [ "text"
1038+ , note . para $ emph "emphasized"
1039+ ])
1040+
10311041 , "Footnote followed by header" =:
10321042 unlines [ "Another note[fn:yay]"
10331043 , ""