title="<The title of the page>"date="2010-01-01"# Publication datelastmod="2020-01-01"# Update datedescription="<The subtitle of the page>"# Will be displayed on the homepagemath=true# Enable support for Katex on this pagetags=["<The tags of the page>"]categories=["<The categories of the page>"]aliases=["some-page-link","AnOtHER_LinK"]# Add other paths for the current pagelicense="CC BY-NC-ND"# Specify the sharing agreement for the current page[menu.main]# Add the entry of the current page to the left menuweight=-90# Used for sortingparams={icon="<The icon of the entry>"}[[links]]# Add an external link block at the bottom of the articletitle="<The title of the external link>"description="<The subtitle of the external link>"website="<The address of the external link>"image="<The square image of the external link, both local and network images are supported>"
TOML
Rendering Examples
Basic Elements
Link:
This is a link Key: Ctrl Phonetic Annotation: 测试 Footnote: There is a footnote here1 Inline Code Block: This is a string of code Multi-line Code Block:
This is
multi-line
code
199
200
201
202
203
This is
with
highlighting,
syntax type
code block
TEXT
Code Block
MD
1
This is a code block generated using the `highlight` shortcode
+++
title = "Stacked Theme Documentation"
date = "2023-01-12"
tags = [ "Hugo", "Shortcode" ]
keywords = [ "hugo", "shortcode" ]
description = "Documentation for the Modified Stack Version"
slug= "stacked-theme-document"
series = "Notes on Building a Website"
+++
> The official documentation can be [found here](https://stack.jimmycai.com/guide/)
This article is fully reprinted from https://zyxin.xyz/blog/tutorial/
## Settings Instructions
### Front-matter Settings
See the following example
```toml
title="<The title of the page>"date="2010-01-01"# Publication datelastmod="2020-01-01"# Update datedescription="<The subtitle of the page>"# Will be displayed on the homepagemath=true# Enable support for Katex on this pagetags=["<The tags of the page>"]categories=["<The categories of the page>"]aliases=["some-page-link","AnOtHER_LinK"]# Add other paths for the current pagelicense="CC BY-NC-ND"# Specify the sharing agreement for the current page[menu.main]# Add the entry of the current page to the left menuweight=-90# Used for sortingparams={icon="<The icon of the entry>"}[[links]]# Add an external link block at the bottom of the articletitle="<The title of the external link>"description="<The subtitle of the external link>"website="<The address of the external link>"image="<The square image of the external link, both local and network images are supported>"```## Rendering Examples
### Basic Elements
Link: [This is a link](#)
Key: <kbd>Ctrl</kbd>Phonetic Annotation: {{<ruby"测(cè)试(shì)">}}
Footnote: There is a footnote here[^basic]
Inline Code Block: `This is a string of code`Multi-line Code Block:
```
This is
multi-line
code
``````text {linenostart=199,hl_lines="2-4"}
This is
with
highlighting,
syntax type
code block
```
{{< highlight title="Code Block" type="md" >}}
This is a code block generated using the `highlight` shortcode
{{< /highlight >}}
{{< code "static/doc/test_code.zh-cn.sh" >}}
[^basic]: The footnote content in the basic elements
### Quotes
> This is a quote block
>
> This is the second paragraph of a quote block
>
> ```
> This is a code block within a quote
> ```
>
> |This is within a quote|The table title|
> |-------------:|:-------|
> |This is within a quote|The table content|
{{< quote author="Jacob" source="Theme Documentation" url="#">}}
This is a quoted block with a source<br/>
{{< /quote >}}
### Lists
Unordered List:
- Nested List
- Second-level list element
- Third-level list element
- Fourth-level list element
- Code Block within List
```
This is a code block
```
- [ ] Checkbox
- [x] Checked Checkbox
- Table within List
|This is within a list|The table title|
|-------------:|:-------|
|This is within a list|The table content|
Ordered List:
1. Nested List
1. Second-level list element
1. Third-level list element
1. Fourth-level list element
1. Fourth-level list element
1. Third-level list element
1. Second-level list element
1. Nested List
### Tables
|This is a|Table Title Generated by Markdown|
|--------------------:|:------|
|This is a|Table Content Generated by Markdown|
<table>
<tr><th colspan="2">Table Generated by HTML Tag</th>
</tr><tr><td>
`This is a piece of inline code`
</td><td>
> This is a quote within the table
</td></tr><tr><td>
```This is a multi-line code
```
</td><td>{{<quoteauthor="Jacob"source="Theme Documentation"url="#">}}
This is a quoted block with a source within the table<br/>{{</quote>}}
</td></tr></table>### Tabs
> Note: Currently, tab pages do not support nesting.
{{<tabs>}}
{{% tab Basic Elements %}}
Link: [This is a link](#)
Key: <kbd>Ctrl</kbd>Phonetic Annotation: {{<ruby"测(cè)试(shì)">}}
Footnote: There is a footnote here[^tab]
Inline Code Block: `This is a string of code`[^tab]: The footnote content in the tab. Due to the limitations of Hugo, currently, footnotes in tabs can only be generated within the tab
{{% /tab %}}
{{% tab Lists %}}
Unordered List:
- Nested List
- Second-level list element
- Third-level list element
- Fourth-level list element
Ordered List
1. Nested List
1. Second-level list element
1. Third-level list element
1. Fourth-level list element
1. Fourth-level list element
1. Third-level list element
1. Second-level list element
1. Nested List
{{% /tab %}}
{{<tab-codeCodeBlockstext>}}
This is
multi-line
code
{{</tab-code>}}
{{% tab Tables %}}
|This is within a tab|The table title|
|---------------:|:-------|
|This is within a tab|The table content|
{{% /tab %}}
{{% tab Quotes %}}
> This is a quote block
>
> This is the second paragraph of a quote block
{{<quoteauthor="Jacob"source="Theme Documentation"url="#">}}
This is a quoted block with a source<br/>{{</quote>}}
{{% /tab %}}
{{</tabs>}}
### Notice Boxes
{{<notice"DefaultStyle">}}
This is a **notice box**{{</notice>}}
{{<noticetitle="Default Style (Folded)"fold=true>}}
This is a default folded **notice box**{{</notice>}}
{{<notice"DefaultStyle(NoContent)"/>}}
{{<notice"Example"example>}}
This is an **example** notice box
{{</notice>}}
{{<noticetitle="Caution"style="note"fold=true>}}
This is a **caution** notice box
{{</notice>}}
{{<noticetitle="Summary"style="abstract"fold=true>}}
This is a **summary** notice box
{{</notice>}}
{{<noticetitle="Information"style="info"fold=true>}}
This is an **information** notice box
{{</notice>}}
{{<noticetitle="Tip"style="tip"fold=true>}}
This is a **tip** notice box
{{</notice>}}
{{<noticetitle="Success"style="success"fold=true>}}
This is a **success** notice box
{{</notice>}}
{{<noticetitle="Question"style="question"fold=true>}}
This is a **question** notice box
{{</notice>}}
{{<noticetitle="Warning"style="warning"fold=true>}}
This is a **warning** notice box
{{</notice>}}
{{<noticetitle="Failure"style="failure"fold=true>}}
This is a **failure** notice box
{{</notice>}}
{{<noticetitle="Bug"style="bug"fold=true>}}
This is a **bug** notice box
{{</notice>}}
{{<noticetitle="Custom"icon="brand-github"style="github">}}
This is a notice box with a custom icon and color
{{</notice>}}
{{<noticetitle="Custom (No Content) — Test Text Test Text Test Text Test Text Test Text Test Text Test Text Test Text Test Text Test Text Test Text"icon="brand-github"style="github"/>}}
## Reference Code
If you want to replicate the style of this website, you can refer to the following CSS styles:
{{<codepath="assets/scss/custom.scss"fold="true">}}
If you want to use the elements of this page, you can refer to the following documentation:
{{<codepath="content/en/notes/devel/params-of-this-site/index.md"fold="true">}}