🎨 Add more article content for demo.

This commit is contained in:
凡梦星尘 2022-06-09 21:55:00 +08:00
parent 836fe1ea10
commit 0beb8d3ca7
10 changed files with 13 additions and 332 deletions

View File

@ -1,15 +1,14 @@
@if $toc_enable { @if $toc_enable {
.post-toc { .post-toc {
font-size: $font-size-small; font-size: $font-size-small;
padding: 0 8px;
ul { ol {
list-style: none; list-style: none;
margin: 0; margin: 0;
padding: 0 2px 5px 10px; padding: 0 2px 5px 10px;
text-align: left; text-align: left;
> li { > ol {
padding-left: 0; padding-left: 0;
} }

View File

@ -1,13 +1,15 @@
#:============================================================== # ===============================================================
# It's recommended to use Alternate Theme Config to configure NexT # It's recommended to use Alternate Theme Config to configure NexT
# Modifying this file may result in merge conflict # Modifying this file may result in merge conflict
# See: https://theme-next.js.org/docs/getting-started/configuration # See: https://theme-next.js.org/docs/getting-started/configuration
#:============================================================== # ===============================================================
baseURL: / baseURL: /
theme: hugo-theme-next theme: hugo-theme-next
paginate: 10
paginate: 8
enableEmoji: true enableEmoji: true
# Make markdown content support HTML syntax # Make markdown content support HTML syntax
@ -15,15 +17,6 @@ markup:
goldmark: goldmark:
renderer: renderer:
unsafe: true unsafe: true
highlight:
codeFences: true
lineNos: true
lineNumbersInTable: true
noClasses: true
tableOfContents:
endLevel: 3
ordered: false
startLevel: 1
defaultContentLanguage: zh-cn defaultContentLanguage: zh-cn
languages: languages:
@ -316,7 +309,7 @@ params:
# The digit in the num of gongan beian. # The digit in the num of gongan beian.
provinceAbbr: provinceAbbr:
# The full num of gongan beian. # The full num of gongan beian.
gonganNum: 31011402009770 gonganNum: 11010102001808
# The icon for gongan beian. See: http://www.beian.gov.cn/portal/download # The icon for gongan beian. See: http://www.beian.gov.cn/portal/download
#gongan_icon_url: #gongan_icon_url:
@ -770,7 +763,7 @@ params:
# AddThis Share. See: https://www.addthis.com # AddThis Share. See: https://www.addthis.com
# Go to https://www.addthis.com/dashboard to customize your tools. # Go to https://www.addthis.com/dashboard to customize your tools.
addThisId: ra-6049e46e9ee22127 addThisId:
# --------------------------------------------------------------- # ---------------------------------------------------------------

View File

@ -1,19 +0,0 @@
---
title: "关于 Hugo NexT 组织"
description: ""
date: 2022-06-09T20:12:52+08:00
lastmod: 2022-06-09T20:12:52+08:00
share: false
followme: false
nav: false
copyright: false
url: about.html
---
`Hugo NexT` 组织是由众多喜爱 `NexT` 主题及风格的世界各地友人共同组建而成,为的就是让这个主题继续在 `Hugo` 引擎中也能得到发扬光大,在此也欢迎你的加入!
# 我们的愿景
延续 `NexT` 经典的黑白调搭配,保持简单的易用性及强大的功能。

View File

@ -1,60 +0,0 @@
---
title: "'Hello World'"
isCJKLanguage: true
author: elkan1788
lastmod: '2022-06-02T11:52:03+08:00'
publishDate: '2022-06-02T11:52:03+08:00'
categories:
- 博客
tags:
- Hugo
- 开始
toc: false
draft: true
url: hello-world2.html
---
The worlds fastest framework for building websites.
[Hugo](https://gohugo.io/) is one of the most popular open-source static site generators. With its amazing speed and flexibility, Hugo makes building websites fun again.
<!--more-->
## Quick Start
### Create a new post
```shell
$ hugo new hello-world.md
```
More info: [Content's Formats](https://gohugo.io/content-management/formats/)
### Run server
```shell
$ hugo server
```
More info: [Hugo Server CLI](https://gohugo.io/commands/hugo_server/)
### Generate static files
```shell
$ hugo
```
More info: [Hugo Build Site](https://gohugo.io/commands/hugo/)
### Deploy to remote sites
```language
$ hugo deploy
```
More info: [Hugo Deployment](https://gohugo.io/commands/hugo_deploy/)
See you will enjoy the Hugo journey and good luck for you!

View File

@ -43,28 +43,10 @@ url: markdown-syntax.html
## 图像 ## 图像
### Markdown 语法
```markdown
![图像说明](图像地址)
```
![hugo-next-primary](//lisenhui.gitee.io/imgs/hugo-next/logo/hugo-next-primary.png) ![hugo-next-primary](//lisenhui.gitee.io/imgs/hugo-next/logo/hugo-next-primary.png)
### HTML IMG 标签
```html
<img src="图像地址" width="宽度" height="高度" />
```
<img src="//lisenhui.gitee.io/imgs/hugo-next/logo/hugo-next-secondary.png" width="150"/> <img src="//lisenhui.gitee.io/imgs/hugo-next/logo/hugo-next-secondary.png" width="150"/>
### SVG 格式
```html
<svg>xxxxxx</svg>
```
<svg class="canon" xmlns="http://www.w3.org/2000/svg" overflow="visible" viewBox="0 0 496 373" height="373" width="496"><g fill="none"><path stroke="#000" stroke-width=".75" d="M.599 372.348L495.263 1.206M.312.633l494.95 370.853M.312 372.633L247.643.92M248.502.92l246.76 370.566M330.828 123.869V1.134M330.396 1.134L165.104 124.515"></path><path stroke="#ED1C24" stroke-width=".75" d="M275.73 41.616h166.224v249.05H275.73zM54.478 41.616h166.225v249.052H54.478z"></path><path stroke="#000" stroke-width=".75" d="M.479.375h495v372h-495zM247.979.875v372"></path><ellipse cx="498.729" cy="177.625" rx=".75" ry="1.25"></ellipse><ellipse cx="247.229" cy="377.375" rx=".75" ry="1.25"></ellipse></g></svg>
## 列表类型 ## 列表类型
### 有序列表 ### 有序列表

View File

@ -1,147 +0,0 @@
---
title: "Hugo 内置的 Chroma 语法高亮"
description: "描述下 Chroma 所支持的各种语法及高亮效果展示"
keywords: "Chroma,语法,高亮"
date: 2022-06-07T19:09:52+08:00
lastmod: 2022-06-07T19:09:52+08:00
categories:
- 示例
tags:
- 语法
- 高亮
- Chroma
url: "syntax-highlighting.html"
---
Hugo 通过 Chroma 提供非常快速的语法高亮显示,现 Hugo 中使用 Chroma 作为代码块高亮支持,它内置在 Go 语言当中,速度是真的非常、非常快,而且最为重要的是它也兼容之前我们使用的 Pygments 方式。
以下通过 Hugo 内置短代码 `highlight``Markdown` 代码块方式分别验证不同语言的代码块渲染效果并能正确高亮显示,有关优化语法突出显示的更多信息,请参阅 [Hugo 文档](https://gohugo.io/getting-started/configuration-markup#highlight)。
<!--more-->
# 编程语言
## GO
{{< highlight go "linenos=table,hl_lines=8 15-17,linenostart=199" >}}
func GetTitleFunc(style string) func(s string) string {
switch strings.ToLower(style) {
case "go":
return strings.Title
case "chicago":
return transform.NewTitleConverter(transform.ChicagoStyle)
default:
return transform.NewTitleConverter(transform.APStyle)
}
}
{{< / highlight >}}
## Java
```java
import javax.swing.JFrame; //Importing class JFrame
import javax.swing.JLabel; //Importing class JLabel
public class HelloWorld {
public static void main(String[] args) {
JFrame frame = new JFrame(); //Creating frame
frame.setTitle("Hi!"); //Setting title frame
frame.add(new JLabel("Hello, world!"));//Adding text to frame
frame.pack(); //Setting size to smallest
frame.setLocationRelativeTo(null); //Centering frame
frame.setVisible(true); //Showing frame
}
}
```
## Python
``` python
print "Hello, world!"
```
## Git 对比
``` diff {hl_lines=[4,"6-7"] linenos=true}
*** /path/to/original ''timestamp''
--- /path/to/new ''timestamp''
***************
*** 1 ****
! This is a line.
--- 1 ---
! This is a replacement line.
It is important to spell
-removed line
+new line
```
```diff {hl_lines=[4,"6-7"], linenos=false}
*** /path/to/original ''timestamp''
--- /path/to/new ''timestamp''
***************
*** 1 ****
! This is a line.
--- 1 ---
! This is a replacement line.
It is important to spell
-removed line
+new line
```
# 文件
## Make 文件
``` makefile {linenos=false}
CC=gcc
CFLAGS=-I.
hellomake: hellomake.o hellofunc.o
$(CC) -o hellomake hellomake.o hellofunc.o -I.
```
## Markdown 文档
``` markdown
**bold**
*italics*
[link](www.example.com)
```
# 数据内容
## JSON 数据
``` json
{"employees":[
{"firstName":"John", "lastName":"Doe"},
]}
```
## XML 内容
``` xml
<employees>
<employee>
<firstName>John</firstName> <lastName>Doe</lastName>
</employee>
</employees>
```
## SQL 查询
{{< highlight sql >}}
SELECT column_name,column_name
FROM
Table
WHERE column_name = "condition"
{{< / highlight >}}
除以上列举的代码高亮显示外还支持诸如C 语言、C++、HTML、CSS、Shell脚本等各主流的代码语言高亮显示可自行测试效果。

View File

@ -1,58 +0,0 @@
---
title: "文章目录导航"
description: "描述下 NexT 主题下的文章目录导航效果。"
keywords: "文章,目录,导航"
date: 2022-06-08T21:12:52+08:00
lastmod: 2022-06-08T21:12:52+08:00
categories:
- 示例
tags:
- 目录
- 导航
- 博客
toc: true
url: "table-of-content.html"
---
巴顿将军说过“衡量一个人是否成功不是看他站到顶峰而是从顶峰跌落之后的反弹力”褚时健的人生便是如此中年发家致富名利双收之后又跌落到谷底等到74岁再创业10年后带着褚橙归来东山再起收获亿万财富他的发展轨迹就是反弹的过程。
<!--more-->
![禇老](https://wfqqreader-1252317822.image.myqcloud.com/cover/568/814568/t6_814568.jpg)
# 早年的故事
## 起始
2014年的春天在云南省华宁县和宜良县的交界处一座名叫矣则的小山村里一处已经有上百年历史的古旧四合院宅子被拆掉。村委会正带领村民们进行“美丽乡村”的建设一年以后旧有村居将再也看不到代之而起的是钢筋混凝土的新式民居。就像10年、20年前中国大小城市的改造一样这个群山围绕的小村子也开始陷入“工地模式”。
### 童年浪花
在江河边长大的孩子几乎都有一个当仁不让的特长:善水。褚时健也不例外,他不仅从小就在南盘江和花鱼塘里扑腾出了上佳的游泳技术,五六岁已经可以一个猛子扎出老远,而且从七八岁就可以在南盘江和河滩上的鱼塘里捉鱼了。
## 少年故事
褚时健在乡村自由自在生活的十多年其实正是中国社会风雨飘摇的十多年。特别是1937年卢沟桥事变后日本人发动全面侵华战争短短两三年间中国的大部分国土相继沦陷
# 激情的青春十年
## 当上了游击队员
1948年夏天褚时健回乡在禄丰车站小学做了一名老师同时也和褚时仁、褚时杰一起继续保持与共产党组织的联系做一些传递情报的工作
### 战火纷飞
因为战斗力相较悬殊,所以游击队只能是靠打一枪换一个地方的办法,专找敌人薄弱的地方攻击,但更多时候,都是在防御和转移阵地。
# 生活的断层
## 跌入生活底层
“反右”运动中被打倒的人在“右派”身份确定后,只有一条路可走:下放到农场。农场名副其实,就是干农活儿的地方,必须过和农民一样的生活。
# 尾声
## 岁月像一条河
2015年是褚时健和马静芬结婚60周年被称为“钻石婚”的纪念年份。这简直是一份人生的奖赏,在中国离婚率愈益升高的当下60年的婚姻几乎就像一个前世之梦。一个甲子的相伴相随褚时健和马静芬共同经历了国家和个人的各种风浪共同面对过生死。他们两人已经不仅是夫妻更是一对战友。尽管马静芬偶尔会对褚时健年轻时候的粗心抱怨上两句但说到最后她会说一句“没有我就没有他没有他也就没有我。”

View File

@ -10,18 +10,11 @@
<div class="post-eof"></div> <div class="post-eof"></div>
{{- else }} {{- else }}
{{ partial "post/footer_meta/tags.html" . }} {{ partial "post/footer_meta/tags.html" . }}
{{- if and (not (isset .Params "share")) (not .Params.share) }}
{{ partial "_thirdparty/share/addthis.html" . }} {{ partial "_thirdparty/share/addthis.html" . }}
{{- end }}
<hr/> <hr/>
{{ partial "post/footer_meta/reward.html" . }} {{ partial "post/footer_meta/reward.html" . }}
{{- if and (not (isset .Params "copyright")) (not .Params.copyright) }}
{{ partial "post/footer_meta/copyright.html" . }} {{ partial "post/footer_meta/copyright.html" . }}
{{- end }}
{{- if and (not (isset .Params "followme")) (not .Params.followme) }}
{{ partial "post/footer_meta/followme.html" . }} {{ partial "post/footer_meta/followme.html" . }}
{{- end }}
{{- if and (not (isset .Params "nav")) (not .Params.nav) }}
<div class="post-nav"> <div class="post-nav">
<div class="post-nav-next post-nav-item"> <div class="post-nav-next post-nav-item">
{{- with .NextInSection }} {{- with .NextInSection }}
@ -40,5 +33,4 @@
</div> </div>
</div> </div>
{{- end }} {{- end }}
{{- end }} {{ end }}
{{- end }}

View File

@ -4,7 +4,7 @@
<span class="toggle-line"></span> <span class="toggle-line"></span>
</div> </div>
<aside class="sidebar"> <aside class="sidebar">
{{- $toc := and (isset .Params "toc") .Params.toc }} {{- $toc := and (isset .Page.Params "toc") .Page.Params.toc }}
<div class="sidebar-inner {{ if $toc }}sidebar-nav-active sidebar-toc-active{{ else }}sidebar-overview-active{{ end }}"> <div class="sidebar-inner {{ if $toc }}sidebar-nav-active sidebar-toc-active{{ else }}sidebar-overview-active{{ end }}">
<ul class="sidebar-nav"> <ul class="sidebar-nav">
<li class="sidebar-nav-toc"> <li class="sidebar-nav-toc">
@ -18,7 +18,7 @@
<!--noindex--> <!--noindex-->
<div class="post-toc-wrap sidebar-panel"> <div class="post-toc-wrap sidebar-panel">
{{- if $toc }} {{- if $toc }}
<div class="post-toc animated">{{ .TableOfContents }}</div> <div class="post-toc animated">{{ .Page.TableOfContents }}</div>
{{- end }} {{- end }}
</div> </div>
<!--/noindex--> <!--/noindex-->

View File

@ -1 +0,0 @@
{{ .TableOfContents }}