We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0f2b53a commit 80515b9Copy full SHA for 80515b9
IncludeFilter.hs
@@ -75,8 +75,8 @@ import Control.Error (readMay, fromMaybe)
75
import System.Directory
76
77
import Text.Pandoc
78
+import Text.Pandoc.Shared (uniqueIdent, stringify)
79
import Text.Pandoc.Error
-import Text.Pandoc.Shared
80
import Text.Pandoc.JSON
81
import Text.Pandoc.Walk
82
@@ -89,6 +89,7 @@ stripPandoc changeInHeaderLevel (Right (Pandoc meta blocks)) = maybe id (:) (tit
89
guard $ changeInHeaderLevel > 0
90
Just $ Header changeInHeaderLevel (titleRef inls,["section-title"],[]) inls
91
title _ = Nothing
92
+ -- WARNING titleRef doesn't check that titles are unique; for that try uniqueIdent.
93
titleRef = stringify . fmap (lowerCase . dashFromSpace)
94
dashFromSpace Space = Str "-"
95
dashFromSpace x = x
0 commit comments