style(apidocs): fix code blocks

This commit is contained in:
Gregor Kleen 2021-08-19 12:52:52 +02:00
parent 88cf1fa2c3
commit 4e5989bb81
2 changed files with 13 additions and 9 deletions

View File

@ -1444,14 +1444,14 @@ a.breadcrumbs__home
&__label &__label
grid-area: label grid-area: label
code .apidocs
display: block pre
box-shadow: inset 0 0 4px 4px var(--color-grey-light) display: block
white-space: pre-wrap box-shadow: inset 0 0 4px 4px var(--color-grey-light)
font-family: monospace white-space: pre-wrap
overflow-x: auto overflow-x: auto
tab-size: 2 tab-size: 2
padding: 10px padding: 10px
.news__system-messages .news__system-messages
overflow-y: auto overflow-y: auto

View File

@ -18,7 +18,11 @@ getApiDocsR = selectRep $ do
Right html -> provideRep . siteLayoutMsg MsgBreadcrumbApiDocs $ do Right html -> provideRep . siteLayoutMsg MsgBreadcrumbApiDocs $ do
setTitleI MsgBreadcrumbApiDocs setTitleI MsgBreadcrumbApiDocs
toWidget html [whamlet|
$newline never
<div .apidocs>
^{html}
|]
Left _err -> return () Left _err -> return ()
provideRepType "text/markdown" $ return mdDocs provideRepType "text/markdown" $ return mdDocs
where where