diff options
author | alexbiehl <alex.biehl@gmail.com> | 2017-10-31 21:48:55 +0100 |
---|---|---|
committer | alexbiehl <alex.biehl@gmail.com> | 2017-10-31 21:48:55 +0100 |
commit | 08c9e19236770811caf571321f5ece271d1fccff (patch) | |
tree | beb3f6407d14abcab32f9d54811cabd319c356a4 /haddock-api/src/Haddock/Backends/Xhtml/DocMarkup.hs | |
parent | 3896bff411596ef50b5ca2f2be425e89878410aa (diff) | |
parent | e5fe98530d9c70f5197494da9de07f42dd7fe334 (diff) |
Merge remote-tracking branch 'origin/master' into ghc-head
Diffstat (limited to 'haddock-api/src/Haddock/Backends/Xhtml/DocMarkup.hs')
-rw-r--r-- | haddock-api/src/Haddock/Backends/Xhtml/DocMarkup.hs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/haddock-api/src/Haddock/Backends/Xhtml/DocMarkup.hs b/haddock-api/src/Haddock/Backends/Xhtml/DocMarkup.hs index 18c8a0ff..e63667b0 100644 --- a/haddock-api/src/Haddock/Backends/Xhtml/DocMarkup.hs +++ b/haddock-api/src/Haddock/Backends/Xhtml/DocMarkup.hs @@ -165,9 +165,9 @@ hackMarkup fmt' h' = UntouchedDoc d -> (markup fmt $ _doc d, [_meta d]) CollapsingHeader (Header lvl titl) par n nm -> let id_ = makeAnchorId $ "ch:" ++ fromMaybe "noid:" nm ++ show n - expanded = False - col' = collapseControl id_ expanded "caption" - instTable = (thediv ! collapseSection id_ expanded [] <<) + col' = collapseControl id_ "caption" + summary = thesummary ! [ theclass "hide-when-js-enabled" ] << "Expand" + instTable contents = collapseDetails id_ DetailsClosed (summary +++ contents) lvs = zip [1 .. ] [h1, h2, h3, h4, h5, h6] getHeader = fromMaybe caption (lookup lvl lvs) subCaption = getHeader ! col' << markup fmt titl |