fix giscus and multilingual mode
This commit is contained in:
parent
0784b32a41
commit
1105d5e939
16 changed files with 424 additions and 211 deletions
|
@ -40,9 +40,6 @@ params:
|
|||
greet: Hello :)
|
||||
# subtitle speficies a subtitle displayed right after the site title.
|
||||
subtitle:
|
||||
# comment specifies which comment plugin to be used.
|
||||
# currently available ones: disqus, utterances, giscus.
|
||||
comment: utterances
|
||||
# switch specifies two emojis to be used as the button toggling color themes.
|
||||
switch: ["🌚", "🌝"]
|
||||
# defaultTheme specifies a default theme to be used.
|
||||
|
@ -59,35 +56,6 @@ params:
|
|||
# post pages. If enabled, those you don't want a comment plugin to work on just
|
||||
# set `comment` to false in their front matters.
|
||||
commentOnAllPosts: true
|
||||
|
||||
# disqus specifies the configuration for Disqus.
|
||||
disqus:
|
||||
shortname: hugo-minima
|
||||
|
||||
# utterances specifies the configuration for Utterances.
|
||||
# Check out https://utteranc.es for the following three attributes.
|
||||
utterances:
|
||||
repo: mivinci/hugo-theme-minima
|
||||
issueTerm: pathname
|
||||
label: comment
|
||||
|
||||
# giscus specifies the configuration for Giscus.
|
||||
# Check out https://giscus.app for the following six attributes.
|
||||
giscus:
|
||||
repo: mivinci/hugo-theme-minima
|
||||
repoId: MDEwOlJlcG9zaXRvcnkzODcxMjM2NDU=
|
||||
category: Comments
|
||||
categoryId: DIC_kwDOFxMJvc4CScQm
|
||||
mapping: pathname
|
||||
inputPostion: buttom
|
||||
|
||||
# **DEPRECATED**
|
||||
# ovo(https://ovo.js.org) is a comment plugin written by the author of Minima but
|
||||
# is now deprecated out of security issues.
|
||||
ovo:
|
||||
server: ""
|
||||
placeholder: ""
|
||||
|
||||
# social is an array containing as many as social accounts to be displayed
|
||||
# in the buttom of every page.
|
||||
social:
|
||||
|
@ -100,16 +68,36 @@ params:
|
|||
- name: "rss"
|
||||
url: "/index.xml"
|
||||
|
||||
# comment specifies a comment plugin.
|
||||
comment:
|
||||
provider: giscus
|
||||
# check out https://disqus.com/
|
||||
disqus:
|
||||
shortname: hugo-minima
|
||||
# check out https://utteranc.es
|
||||
utterances:
|
||||
repo: mivinci/hugo-theme-minima
|
||||
issueTerm: pathname
|
||||
label: comment
|
||||
# check out https://giscus.app
|
||||
giscus:
|
||||
repo: mivinci/hugo-theme-minima
|
||||
repoId: MDEwOlJlcG9zaXRvcnkzODcxMjM2NDU=
|
||||
category: Comments
|
||||
categoryId: DIC_kwDOFxMJvc4CScQm
|
||||
mapping: pathname
|
||||
inputPosition: buttom # bottom | top
|
||||
reactions: true
|
||||
metadata: false
|
||||
|
||||
# menu.main is an array containing what is used as the navigator.
|
||||
menu:
|
||||
main:
|
||||
- identifier: tags
|
||||
name: "Tags"
|
||||
url: "/tags"
|
||||
weight: 2
|
||||
- identifier: series
|
||||
name: "Series"
|
||||
url: "/series"
|
||||
weight: 3
|
||||
|
||||
# taxonomies defines ways to classify yout posts. Below are some presets that
|
||||
|
|
|
@ -4,7 +4,8 @@ title: Math Typesetting
|
|||
date: 2021-07-18T10:52:59+08:00
|
||||
description: A brief guide to setup KaTeX.
|
||||
math: true
|
||||
categories: ["Markdown", "KaTeX"]
|
||||
tags:
|
||||
- KaTex
|
||||
---
|
||||
|
||||
Mathematical notation in a Hugo project can be enabled by using third party JavaScript libraries.
|
||||
|
|
263
exampleSite/content/mermaid-diagrams.md
Normal file
263
exampleSite/content/mermaid-diagrams.md
Normal file
|
@ -0,0 +1,263 @@
|
|||
---
|
||||
author: Mermaid Team
|
||||
title: Mermaid Diagrams
|
||||
date: 2021-07-18T10:52:59+08:00
|
||||
description: A brief guide to Mermaid syntax.
|
||||
mermaid: true
|
||||
tags:
|
||||
- markdown
|
||||
- mermaid
|
||||
---
|
||||
|
||||
## Examples
|
||||
|
||||
The following are some examples of the diagrams, charts and graphs that can be made using Mermaid. Click here to jump into the [full syntax](http://mermaid-js.github.io/mermaid/).
|
||||
|
||||
<!-- <Flowchart> -->
|
||||
|
||||
### Flowchart
|
||||
|
||||
```
|
||||
flowchart LR
|
||||
|
||||
A[Hard] -->|Text| B(Round)
|
||||
B --> C{Decision}
|
||||
C -->|One| D[Result 1]
|
||||
C -->|Two| E[Result 2]
|
||||
```
|
||||
|
||||
```mermaid
|
||||
flowchart LR
|
||||
|
||||
A[Hard] -->|Text| B(Round)
|
||||
B --> C{Decision}
|
||||
C -->|One| D[Result 1]
|
||||
C -->|Two| E[Result 2]
|
||||
```
|
||||
|
||||
### Sequence diagram
|
||||
|
||||
```
|
||||
sequenceDiagram
|
||||
Alice->>John: Hello John, how are you?
|
||||
loop Healthcheck
|
||||
John->>John: Fight against hypochondria
|
||||
end
|
||||
Note right of John: Rational thoughts!
|
||||
John-->>Alice: Great!
|
||||
John->>Bob: How about you?
|
||||
Bob-->>John: Jolly good!
|
||||
```
|
||||
|
||||
```mermaid
|
||||
sequenceDiagram
|
||||
Alice->>John: Hello John, how are you?
|
||||
loop Healthcheck
|
||||
John->>John: Fight against hypochondria
|
||||
end
|
||||
Note right of John: Rational thoughts!
|
||||
John-->>Alice: Great!
|
||||
John->>Bob: How about you?
|
||||
Bob-->>John: Jolly good!
|
||||
```
|
||||
|
||||
### Gantt chart
|
||||
|
||||
```
|
||||
gantt
|
||||
section Section
|
||||
Completed :done, des1, 2014-01-06,2014-01-08
|
||||
Active :active, des2, 2014-01-07, 3d
|
||||
Parallel 1 : des3, after des1, 1d
|
||||
Parallel 2 : des4, after des1, 1d
|
||||
Parallel 3 : des5, after des3, 1d
|
||||
Parallel 4 : des6, after des4, 1d
|
||||
```
|
||||
|
||||
```mermaid
|
||||
gantt
|
||||
section Section
|
||||
Completed :done, des1, 2014-01-06,2014-01-08
|
||||
Active :active, des2, 2014-01-07, 3d
|
||||
Parallel 1 : des3, after des1, 1d
|
||||
Parallel 2 : des4, after des1, 1d
|
||||
Parallel 3 : des5, after des3, 1d
|
||||
Parallel 4 : des6, after des4, 1d
|
||||
```
|
||||
|
||||
### Class diagram
|
||||
|
||||
```
|
||||
classDiagram
|
||||
Class01 <|-- AveryLongClass : Cool
|
||||
<<Interface>> Class01
|
||||
Class09 --> C2 : Where am I?
|
||||
Class09 --* C3
|
||||
Class09 --|> Class07
|
||||
Class07 : equals()
|
||||
Class07 : Object[] elementData
|
||||
Class01 : size()
|
||||
Class01 : int chimp
|
||||
Class01 : int gorilla
|
||||
class Class10 {
|
||||
<<service>>
|
||||
int id
|
||||
size()
|
||||
}
|
||||
```
|
||||
|
||||
```mermaid
|
||||
classDiagram
|
||||
Class01 <|-- AveryLongClass : Cool
|
||||
<<Interface>> Class01
|
||||
Class09 --> C2 : Where am I?
|
||||
Class09 --* C3
|
||||
Class09 --|> Class07
|
||||
Class07 : equals()
|
||||
Class07 : Object[] elementData
|
||||
Class01 : size()
|
||||
Class01 : int chimp
|
||||
Class01 : int gorilla
|
||||
class Class10 {
|
||||
<<service>>
|
||||
int id
|
||||
size()
|
||||
}
|
||||
```
|
||||
|
||||
### State diagram
|
||||
|
||||
```
|
||||
stateDiagram-v2
|
||||
[*] --> Still
|
||||
Still --> [*]
|
||||
Still --> Moving
|
||||
Moving --> Still
|
||||
Moving --> Crash
|
||||
Crash --> [*]
|
||||
```
|
||||
|
||||
```mermaid
|
||||
stateDiagram-v2
|
||||
[*] --> Still
|
||||
Still --> [*]
|
||||
Still --> Moving
|
||||
Moving --> Still
|
||||
Moving --> Crash
|
||||
Crash --> [*]
|
||||
```
|
||||
|
||||
### Pie chart
|
||||
|
||||
```
|
||||
pie
|
||||
"Dogs" : 386
|
||||
"Cats" : 85.9
|
||||
"Rats" : 15
|
||||
```
|
||||
|
||||
```mermaid
|
||||
pie
|
||||
"Dogs" : 386
|
||||
"Cats" : 85.9
|
||||
"Rats" : 15
|
||||
```
|
||||
|
||||
|
||||
### User Journey diagram
|
||||
|
||||
```
|
||||
journey
|
||||
title My working day
|
||||
section Go to work
|
||||
Make tea: 5: Me
|
||||
Go upstairs: 3: Me
|
||||
Do work: 1: Me, Cat
|
||||
section Go home
|
||||
Go downstairs: 5: Me
|
||||
Sit down: 3: Me
|
||||
```
|
||||
|
||||
```mermaid
|
||||
journey
|
||||
title My working day
|
||||
section Go to work
|
||||
Make tea: 5: Me
|
||||
Go upstairs: 3: Me
|
||||
Do work: 1: Me, Cat
|
||||
section Go home
|
||||
Go downstairs: 5: Me
|
||||
Sit down: 3: Me
|
||||
```
|
||||
|
||||
### C4 diagram
|
||||
|
||||
```
|
||||
C4Context
|
||||
title System Context diagram for Internet Banking System
|
||||
|
||||
Person(customerA, "Banking Customer A", "A customer of the bank, with personal bank accounts.")
|
||||
Person(customerB, "Banking Customer B")
|
||||
Person_Ext(customerC, "Banking Customer C")
|
||||
System(SystemAA, "Internet Banking System", "Allows customers to view information about their bank accounts, and make payments.")
|
||||
|
||||
Person(customerD, "Banking Customer D", "A customer of the bank, <br/> with personal bank accounts.")
|
||||
|
||||
Enterprise_Boundary(b1, "BankBoundary") {
|
||||
|
||||
SystemDb_Ext(SystemE, "Mainframe Banking System", "Stores all of the core banking information about customers, accounts, transactions, etc.")
|
||||
|
||||
System_Boundary(b2, "BankBoundary2") {
|
||||
System(SystemA, "Banking System A")
|
||||
System(SystemB, "Banking System B", "A system of the bank, with personal bank accounts.")
|
||||
}
|
||||
|
||||
System_Ext(SystemC, "E-mail system", "The internal Microsoft Exchange e-mail system.")
|
||||
SystemDb(SystemD, "Banking System D Database", "A system of the bank, with personal bank accounts.")
|
||||
|
||||
Boundary(b3, "BankBoundary3", "boundary") {
|
||||
SystemQueue(SystemF, "Banking System F Queue", "A system of the bank, with personal bank accounts.")
|
||||
SystemQueue_Ext(SystemG, "Banking System G Queue", "A system of the bank, with personal bank accounts.")
|
||||
}
|
||||
}
|
||||
|
||||
BiRel(customerA, SystemAA, "Uses")
|
||||
BiRel(SystemAA, SystemE, "Uses")
|
||||
Rel(SystemAA, SystemC, "Sends e-mails", "SMTP")
|
||||
Rel(SystemC, customerA, "Sends e-mails to")
|
||||
```
|
||||
|
||||
```mermaid
|
||||
C4Context
|
||||
title System Context diagram for Internet Banking System
|
||||
|
||||
Person(customerA, "Banking Customer A", "A customer of the bank, with personal bank accounts.")
|
||||
Person(customerB, "Banking Customer B")
|
||||
Person_Ext(customerC, "Banking Customer C")
|
||||
System(SystemAA, "Internet Banking System", "Allows customers to view information about their bank accounts, and make payments.")
|
||||
|
||||
Person(customerD, "Banking Customer D", "A customer of the bank, <br/> with personal bank accounts.")
|
||||
|
||||
Enterprise_Boundary(b1, "BankBoundary") {
|
||||
|
||||
SystemDb_Ext(SystemE, "Mainframe Banking System", "Stores all of the core banking information about customers, accounts, transactions, etc.")
|
||||
|
||||
System_Boundary(b2, "BankBoundary2") {
|
||||
System(SystemA, "Banking System A")
|
||||
System(SystemB, "Banking System B", "A system of the bank, with personal bank accounts.")
|
||||
}
|
||||
|
||||
System_Ext(SystemC, "E-mail system", "The internal Microsoft Exchange e-mail system.")
|
||||
SystemDb(SystemD, "Banking System D Database", "A system of the bank, with personal bank accounts.")
|
||||
|
||||
Boundary(b3, "BankBoundary3", "boundary") {
|
||||
SystemQueue(SystemF, "Banking System F Queue", "A system of the bank, with personal bank accounts.")
|
||||
SystemQueue_Ext(SystemG, "Banking System G Queue", "A system of the bank, with personal bank accounts.")
|
||||
}
|
||||
}
|
||||
|
||||
BiRel(customerA, SystemAA, "Uses")
|
||||
BiRel(SystemAA, SystemE, "Uses")
|
||||
Rel(SystemAA, SystemC, "Sends e-mails", "SMTP")
|
||||
Rel(SystemC, customerA, "Sends e-mails to")
|
||||
```
|
|
@ -1,18 +0,0 @@
|
|||
---
|
||||
author: Hugo Authors
|
||||
title: Mermaid Graphs
|
||||
date: 2021-07-18T10:52:59+08:00
|
||||
description: A brief guide to setup Mermaid.
|
||||
mermaid: true
|
||||
draft: false
|
||||
categories: ["Markdown", "Mermaid"]
|
||||
---
|
||||
|
||||
Here's a simple mermaid flowchart.
|
||||
|
||||
{{<mermaid>}}
|
||||
graph LR
|
||||
Start --> Stop
|
||||
{{</mermaid>}}
|
||||
|
||||
For more documentations on Mermaid, check out [mermaid](https://mermaid-js.github.io/mermaid).
|
Loading…
Add table
Add a link
Reference in a new issue