theme renderer

This commit is contained in:
menduz 2022-10-03 11:56:09 -03:00
parent da7492ba2c
commit 37b9ae824d
No known key found for this signature in database
GPG Key ID: 78AC067F75AC1B64
7 changed files with 299 additions and 36 deletions

View File

@ -2,7 +2,7 @@
baseURL = 'https://example.com/' baseURL = 'https://example.com/'
title = 'Hugo Book' title = 'Hugo Book'
theme = 'hugo-book' theme = 'documentation-theme'
# Book configuration # Book configuration
disablePathToLower = true disablePathToLower = true
@ -10,8 +10,23 @@ enableGitInfo = true
# Needed for mermaid/katex shortcodes # Needed for mermaid/katex shortcodes
[markup] [markup]
[markup.goldmark]
[markup.goldmark.renderer] [markup.goldmark.renderer]
unsafe = true unsafe = true
[markup.highlight]
anchorLineNos = false
codeFences = true
guessSyntax = false
hl_Lines = ''
hl_inline = false
lineAnchors = ''
lineNoStart = 1
lineNos = false
lineNumbersInTable = true
noClasses = false
noHl = false
style = 'github'
tabWidth = 2
[markup.tableOfContents] [markup.tableOfContents]
startLevel = 1 startLevel = 1
@ -56,7 +71,7 @@ enableGitInfo = true
# (Optional, default true) Controls table of contents visibility on right side of pages. # (Optional, default true) Controls table of contents visibility on right side of pages.
# Start and end levels can be controlled with markup.tableOfContents setting. # Start and end levels can be controlled with markup.tableOfContents setting.
# You can also specify this parameter per page in front matter. # You can also specify this parameter per page in front matter.
BookToC = true BookToC = false
# (Optional, default none) Set the path to a logo for the book. If the logo is # (Optional, default none) Set the path to a logo for the book. If the logo is
# /static/logo.png then the path would be logo.png # /static/logo.png then the path would be logo.png

View File

@ -2,7 +2,7 @@
baseURL: https://example.com/ baseURL: https://example.com/
title: Hugo Book title: Hugo Book
theme: hugo-book theme: documentation-theme
# Book configuration # Book configuration
disablePathToLower: true disablePathToLower: true

View File

@ -3,21 +3,11 @@
KaTeX shortcode let you render math typesetting in markdown document. See [KaTeX](https://katex.org/) KaTeX shortcode let you render math typesetting in markdown document. See [KaTeX](https://katex.org/)
## Example ## Example
{{< columns >}}
```latex
{{</* katex [display] [class="text-center"] */>}}
f(x) = \int_{-\infty}^\infty\hat f(\xi)\,e^{2 \pi i \xi x}\,d\xi
{{</* /katex */>}}
```
<--->
{{< katex display >}} {{< katex display >}}
f(x) = \int_{-\infty}^\infty\hat f(\xi)\,e^{2 \pi i \xi x}\,d\xi f(x) = \int_{-\infty}^\infty\hat f(\xi)\,e^{2 \pi i \xi x}\,d\xi
{{< /katex >}} {{< /katex >}}
{{< /columns >}}
## Display Mode Example ## Display Mode Example

View File

@ -11,22 +11,6 @@ create a `mermaid.json` file in your `assets` folder!
## Example ## Example
{{< columns >}}
```tpl
{{</* mermaid [class="text-center"]*/>}}
stateDiagram-v2
State1: The state with a note
note right of State1
Important information! You can write
notes.
end note
State1 --> State2
note left of State2 : This is the note to the left.
{{</* /mermaid */>}}
```
<--->
{{< mermaid >}} {{< mermaid >}}
stateDiagram-v2 stateDiagram-v2
State1: The state with a note State1: The state with a note
@ -37,5 +21,3 @@ stateDiagram-v2
State1 --> State2 State1 --> State2
note left of State2 : This is the note to the left. note left of State2 : This is the note to the left.
{{< /mermaid >}} {{< /mermaid >}}
{{< /columns >}}

View File

@ -0,0 +1,3 @@
[
{"name": "Docs", "path": "docs", "accent": "#FF2D55"}
]

File diff suppressed because one or more lines are too long

View File

@ -1 +1 @@
{"Target":"book.min.82c5dbd23447cee0b4c2aa3ed08ce0961faa40e1fa370eee4f8c9f02e0d46b5f.css","MediaType":"text/css","Data":{"Integrity":"sha256-gsXb0jRHzuC0wqo+0Izglh+qQOH6Nw7uT4yfAuDUa18="}} {"Target":"book.min.ac322ad916b031cdbbc06969f65f151f2aa7d436ff20c63971985257f5c12e61.css","MediaType":"text/css","Data":{"Integrity":"sha256-rDIq2RawMc27wGlp9l8VHyqn1Db/IMY5cZhSV/XBLmE="}}