Skip to content

Commit

Permalink
feat: add math shortcode (#144)
Browse files Browse the repository at this point in the history
- add math shortcode
- add documentation for math shortcode
- fix chinese symbols
  • Loading branch information
HEIGE-PCloud committed Jul 18, 2021
1 parent 3b2c5ab commit cb920c9
Show file tree
Hide file tree
Showing 16 changed files with 8,343 additions and 8,275 deletions.
2 changes: 1 addition & 1 deletion assets/js/theme.min.js.map

Large diffs are not rendered by default.

12 changes: 6 additions & 6 deletions exampleSite/config.toml
Expand Up @@ -264,7 +264,7 @@ enableEmoji = true
paginate = 12
# [UA-XXXXXXXX-X] 谷歌分析代号
googleAnalytics = ""
# 版权描述仅仅用于 SEO
# 版权描述, 仅仅用于 SEO
copyright = "This work is licensed under a Creative Commons Attribution-NonCommercial 4.0 International License."
# 菜单配置
[languages.zh-cn.menu]
Expand Down Expand Up @@ -389,7 +389,7 @@ enableEmoji = true
# 主页个人信息
[languages.zh-cn.params.home.profile]
enable = true
# Gravatar 邮箱用于优先在主页显示的头像
# Gravatar 邮箱, 用于优先在主页显示的头像
gravatarEmail = ""
# 主页显示头像的 URL
avatarURL = "/images/avatar.webp"
Expand Down Expand Up @@ -484,7 +484,7 @@ enableEmoji = true
# 网站默认主题 ("light", "dark", "black", "auto")
defaultTheme = "auto"
# public git repo url only then enableGitInfo is true
# 公共 git 仓库路径仅在 enableGitInfo 设为 true 时有效
# 公共 git 仓库路径, 仅在 enableGitInfo 设为 true 时有效
gitRepo = "https://github.com/HEIGE-PCloud/DoIt"
# which hash function used for SRI, when empty, no SRI is used ("sha256", "sha384", "sha512", "md5")
# 哪种哈希函数用来 SRI, 为空时表示不使用 SRI ("sha256", "sha384", "sha512", "md5")
Expand Down Expand Up @@ -549,7 +549,7 @@ enableEmoji = true
# 网站创立年份
since = 2019
# ICP info only in China (HTML format is supported)
# ICP 备案信息仅在中国使用 (支持 HTML 格式)
# ICP 备案信息, 仅在中国使用 (支持 HTML 格式)
icp = ""
# license info (HTML format is supported)
# 许可协议信息 (支持 HTML 格式)
Expand Down Expand Up @@ -717,7 +717,7 @@ enableEmoji = true
[params.page.comment.disqus]
enable = false
# Disqus shortname to use Disqus in posts
# Disqus 的 shortname用来在文章中启用 Disqus 评论系统
# Disqus 的 shortname, 用来在文章中启用 Disqus 评论系统
shortname = ""
# Gitalk comment config (https://github.com/gitalk/gitalk)
# Gitalk 评论系统设置 (https://github.com/gitalk/gitalk)
Expand Down Expand Up @@ -856,7 +856,7 @@ enableEmoji = true
duration = -1

# Site verification code for Google/Bing/Yandex/Pinterest/Baidu
# 网站验证代码用于 Google/Bing/Yandex/Pinterest/Baidu
# 网站验证代码, 用于 Google/Bing/Yandex/Pinterest/Baidu
[params.verification]
google = "MQ8DNu27ayX6B_4ObiEDK09vGr1fdy7kOAnbd09hJk4"
bing = ""
Expand Down
220 changes: 110 additions & 110 deletions exampleSite/content/about/index.zh-cn.md
@@ -1,110 +1,110 @@
---
title: "关于 DoIt"
date: 2019-08-02T11:04:49+08:00
draft: false

lightgallery: true

math:
enable: true
---

> [:(far fa-edit fa-fw): DoIt](https://github.com/HEIGE-PCloud/DoIt) 是一个由 [HEIGE-PCloud](https://github.com/HEIGE-PCloud) 开发的**简洁****优雅****高效**[Hugo](https://gohugo.io/) 博客主题
>
> 它的原型基于 [LoveIt 主题](https://github.com/dillonzq/LoveIt)[LeaveIt 主题](https://github.com/liuzc/LeaveIt)[KeepIt 主题](https://github.com/Fastbyte01/KeepIt)
### 特性

#### 性能和 SEO

* :(fas fa-rocket fa-fw): **性能**优化:在 [Google PageSpeed Insights](https://developers.google.com/speed/pagespeed/insights) [99]/[100] 的移动设备得分和 [100]/[100] 的桌面设备得分
* :(fab fa-searchengin fa-fw): 使用基于 JSON-LD 格式 的 **SEO SCHEMA** 文件进行 SEO 优化
* :(fab fa-google fa-fw): 支持 **[Google Analytics](https://analytics.google.com/analytics)**
* :(far fa-chart-bar fa-fw): 支持 **[Fathom Analytics](https://usefathom.com/)**
* :(fas fa-search fa-fw): 支持搜索引擎的**网站验证** (Google, Bind, Yandex and Baidu)
* :(fas fa-tachometer-alt fa-fw): 支持所有第三方库的 **CDN**
* :(fas fa-cloud-download-alt fa-fw): 基于 [lazysizes](https://github.com/aFarkas/lazysizes) 自动转换图片为**懒加载**

#### 外观和布局

* [:(fas fa-desktop):]/[:(fas fa-mobile):] **响应式**布局
* [:(fas fa-sun):]/[:(fas fa-moon):] **[浅色]/[深色]** 主题模式
* :(fas fa-layer-group fa-fw): 全局一致的**设计语言**
* :(fas fa-ellipsis-h fa-fw): 支持**分页**
* :(far fa-list-alt fa-fw): 易用和自动展开的**文章目录**
* :(fas fa-language fa-fw): 支持**多语言**和国际化
* :(fab fa-css3-alt fa-fw): 美观的 **CSS 动画**

#### 社交和评论系统

* :(far fa-user fa-fw): 支持 **[Gravatar](https://gravatar.com)** 头像
* :(fas fa-user-circle fa-fw): 支持本地**头像**
* :(far fa-id-card fa-fw): 支持多达 **64** 种社交链接
* :(fas fa-share-square fa-fw): 支持多达 **28** 种网站分享
* :(far fa-comment fa-fw): 支持 **[Disqus](https://disqus.com)** 评论系统
* :(far fa-comment-dots fa-fw): 支持 **[Gitalk](https://github.com/gitalk/gitalk)** 评论系统
* :(far fa-comment-alt fa-fw): 支持 **[Valine](https://valine.js.org/)** 评论系统
* :(far fa-comment-alt fa-fw): 支持 **[Waline](https://waline.js.org/)** 评论系统
* :(far fa-comments fa-fw): 支持 **[Facebook](https://developers.facebook.com/docs/plugins/comments/) 评论**系统
* :(fas fa-comment fa-fw): 支持 **[Telegram comments](https://comments.app/) 评论**系统
* :(fas fa-comment-dots fa-fw): 支持 **[Commento](https://commento.io/)** 评论系统
* :(far fa-comment-alt fa-fw): 支持 **[Utterances](https://utteranc.es/)** 评论系统
* :(far fa-comment-alt fa-fw): 支持 **[Twikoo](https://twikoo.js.org/)** 评论系统

#### 扩展功能

* :(fas fa-search fa-fw): 支持基于 [Lunr.js](https://lunrjs.com/)[algolia](https://www.algolia.com/)[Fuse.js](https://fusejs.io/)**搜索**
* :(far fa-grin-tongue-wink fa-fw): 支持 **Twemoji**
* :(fas fa-code fa-fw): 支持**代码高亮**
* :(far fa-copy fa-fw): 一键**复制代码**到剪贴板
* :(far fa-images fa-fw): 支持基于 [lightgallery.js](https://github.com/sachinchoolur/lightgallery.js)**图片画廊**
* :(fab fa-font-awesome fa-fw): 支持 **[Font Awesome](https://fontawesome.com/) 图标**的扩展 Markdown 语法
* :(far fa-sticky-note fa-fw): 支持**上标注释**的扩展 Markdown 语法
* :(fas fa-percentage fa-fw): 支持**分数**的扩展 Markdown 语法
* :(fas fa-square-root-alt fa-fw): 支持基于 [$ \KaTeX $](https://katex.org/)**数学公式**
* :(fas fa-project-diagram fa-fw): 支持基于 [mermaid](https://github.com/knsv/mermaid)**图表** shortcode
* :(fas fa-chart-pie fa-fw): 支持基于 [ECharts](https://echarts.apache.org/)**交互式数据可视化** shortcode
* :(fas fa-map-marked-alt fa-fw): 支持基于 [Mapbox GL JS](https://docs.mapbox.com/mapbox-gl-js)**Mapbox** shortcode
* :(fas fa-music fa-fw): 支持基于 [APlayer](https://github.com/MoePlayer/APlayer)[MetingJS](https://github.com/metowolf/MetingJS)**音乐播放器** shortcode
* :(fas fa-video fa-fw): 支持 **Bilibili 视频** shortcode
* :(far fa-bell fa-fw): 支持多种**注释**的 shortcode
* :(fas fa-align-left fa-fw): 支持**自定义样式**的 shortcode
* :(fab fa-js-square fa-fw): 支持**自定义脚本**的 shortcode
* :(fas fa-i-cursor fa-fw): 支持基于 [TypeIt](https://typeitjs.com/)**打字动画** shortcode
* :(fas fa-cookie-bite fa-fw): 支持基于 [cookieconsent](https://github.com/osano/cookieconsent)**Cookie 许可横幅**
* ...

### 许可协议

DoIt 根据 **MIT** 许可协议授权

更多信息请查看 [LICENSE 文件](https://github.com/HEIGE-PCloud/DoIt/blob/main/LICENSE)

DoIt 主题中用到了以下项目感谢它们的作者:

* [normalize.css](https://github.com/necolas/normalize.css)
* [Font Awesome](https://fontawesome.com/)
* [Simple Icons](https://github.com/simple-icons/simple-icons)
* [Animate.css](https://daneden.github.io/animate.css/)
* [autocomplete.js](https://github.com/algolia/autocomplete.js)
* [Lunr.js](https://lunrjs.com/)
* [algoliasearch](https://github.com/algolia/algoliasearch-client-javascript)
* [Fuse.js](https://fusejs.io/)
* [lazysizes](https://github.com/aFarkas/lazysizes)
* [object-fit-images](https://github.com/fregante/object-fit-images)
* [Twemoji](https://github.com/twitter/twemoji)
* [lightgallery.js](https://github.com/sachinchoolur/lightgallery.js)
* [clipboard.js](https://github.com/zenorocha/clipboard.js)
* [Sharer.js](https://github.com/ellisonleao/sharer.js)
* [TypeIt](https://typeitjs.com/)
* [$ \KaTeX $](https://katex.org/)
* [mermaid](https://github.com/knsv/mermaid)
* [ECharts](https://echarts.apache.org/)
* [Mapbox GL JS](https://docs.mapbox.com/mapbox-gl-js)
* [APlayer](https://github.com/MoePlayer/APlayer)
* [MetingJS](https://github.com/metowolf/MetingJS)
* [Gitalk](https://github.com/gitalk/gitalk)
* [Valine](https://valine.js.org/)
* [Waline](https://waline.js.org/)
* [Twikoo](https://twikoo.js.org/)
* [cookieconsent](https://github.com/osano/cookieconsent)
---
title: "关于 DoIt"
date: 2019-08-02T11:04:49+08:00
draft: false

lightgallery: true

math:
enable: true
---

> [:(far fa-edit fa-fw): DoIt](https://github.com/HEIGE-PCloud/DoIt) 是一个由 [HEIGE-PCloud](https://github.com/HEIGE-PCloud) 开发的**简洁****优雅****高效**[Hugo](https://gohugo.io/) 博客主题.
>
> 它的原型基于 [LoveIt 主题](https://github.com/dillonzq/LoveIt), [LeaveIt 主题](https://github.com/liuzc/LeaveIt)[KeepIt 主题](https://github.com/Fastbyte01/KeepIt).
### 特性

#### 性能和 SEO

* :(fas fa-rocket fa-fw): **性能**优化:在 [Google PageSpeed Insights](https://developers.google.com/speed/pagespeed/insights), [99]/[100] 的移动设备得分和 [100]/[100] 的桌面设备得分
* :(fab fa-searchengin fa-fw): 使用基于 JSON-LD 格式 的 **SEO SCHEMA** 文件进行 SEO 优化
* :(fab fa-google fa-fw): 支持 **[Google Analytics](https://analytics.google.com/analytics)**
* :(far fa-chart-bar fa-fw): 支持 **[Fathom Analytics](https://usefathom.com/)**
* :(fas fa-search fa-fw): 支持搜索引擎的**网站验证** (Google, Bind, Yandex and Baidu)
* :(fas fa-tachometer-alt fa-fw): 支持所有第三方库的 **CDN**
* :(fas fa-cloud-download-alt fa-fw): 基于 [lazysizes](https://github.com/aFarkas/lazysizes) 自动转换图片为**懒加载**

#### 外观和布局

* [:(fas fa-desktop):]/[:(fas fa-mobile):] **响应式**布局
* [:(fas fa-sun):]/[:(fas fa-moon):] **[浅色]/[深色]** 主题模式
* :(fas fa-layer-group fa-fw): 全局一致的**设计语言**
* :(fas fa-ellipsis-h fa-fw): 支持**分页**
* :(far fa-list-alt fa-fw): 易用和自动展开的**文章目录**
* :(fas fa-language fa-fw): 支持**多语言**和国际化
* :(fab fa-css3-alt fa-fw): 美观的 **CSS 动画**

#### 社交和评论系统

* :(far fa-user fa-fw): 支持 **[Gravatar](https://gravatar.com)** 头像
* :(fas fa-user-circle fa-fw): 支持本地**头像**
* :(far fa-id-card fa-fw): 支持多达 **64** 种社交链接
* :(fas fa-share-square fa-fw): 支持多达 **28** 种网站分享
* :(far fa-comment fa-fw): 支持 **[Disqus](https://disqus.com)** 评论系统
* :(far fa-comment-dots fa-fw): 支持 **[Gitalk](https://github.com/gitalk/gitalk)** 评论系统
* :(far fa-comment-alt fa-fw): 支持 **[Valine](https://valine.js.org/)** 评论系统
* :(far fa-comment-alt fa-fw): 支持 **[Waline](https://waline.js.org/)** 评论系统
* :(far fa-comments fa-fw): 支持 **[Facebook](https://developers.facebook.com/docs/plugins/comments/) 评论**系统
* :(fas fa-comment fa-fw): 支持 **[Telegram comments](https://comments.app/) 评论**系统
* :(fas fa-comment-dots fa-fw): 支持 **[Commento](https://commento.io/)** 评论系统
* :(far fa-comment-alt fa-fw): 支持 **[Utterances](https://utteranc.es/)** 评论系统
* :(far fa-comment-alt fa-fw): 支持 **[Twikoo](https://twikoo.js.org/)** 评论系统

#### 扩展功能

* :(fas fa-search fa-fw): 支持基于 [Lunr.js](https://lunrjs.com/)[algolia](https://www.algolia.com/)[Fuse.js](https://fusejs.io/)**搜索**
* :(far fa-grin-tongue-wink fa-fw): 支持 **Twemoji**
* :(fas fa-code fa-fw): 支持**代码高亮**
* :(far fa-copy fa-fw): 一键**复制代码**到剪贴板
* :(far fa-images fa-fw): 支持基于 [lightgallery.js](https://github.com/sachinchoolur/lightgallery.js)**图片画廊**
* :(fab fa-font-awesome fa-fw): 支持 **[Font Awesome](https://fontawesome.com/) 图标**的扩展 Markdown 语法
* :(far fa-sticky-note fa-fw): 支持**上标注释**的扩展 Markdown 语法
* :(fas fa-percentage fa-fw): 支持**分数**的扩展 Markdown 语法
* :(fas fa-square-root-alt fa-fw): 支持基于 [$ \KaTeX $](https://katex.org/)**数学公式**
* :(fas fa-project-diagram fa-fw): 支持基于 [mermaid](https://github.com/knsv/mermaid)**图表** shortcode
* :(fas fa-chart-pie fa-fw): 支持基于 [ECharts](https://echarts.apache.org/)**交互式数据可视化** shortcode
* :(fas fa-map-marked-alt fa-fw): 支持基于 [Mapbox GL JS](https://docs.mapbox.com/mapbox-gl-js)**Mapbox** shortcode
* :(fas fa-music fa-fw): 支持基于 [APlayer](https://github.com/MoePlayer/APlayer)[MetingJS](https://github.com/metowolf/MetingJS)**音乐播放器** shortcode
* :(fas fa-video fa-fw): 支持 **Bilibili 视频** shortcode
* :(far fa-bell fa-fw): 支持多种**注释**的 shortcode
* :(fas fa-align-left fa-fw): 支持**自定义样式**的 shortcode
* :(fab fa-js-square fa-fw): 支持**自定义脚本**的 shortcode
* :(fas fa-i-cursor fa-fw): 支持基于 [TypeIt](https://typeitjs.com/)**打字动画** shortcode
* :(fas fa-cookie-bite fa-fw): 支持基于 [cookieconsent](https://github.com/osano/cookieconsent)**Cookie 许可横幅**
* ...

### 许可协议

DoIt 根据 **MIT** 许可协议授权.

更多信息请查看 [LICENSE 文件](https://github.com/HEIGE-PCloud/DoIt/blob/main/LICENSE).

DoIt 主题中用到了以下项目, 感谢它们的作者:

* [normalize.css](https://github.com/necolas/normalize.css)
* [Font Awesome](https://fontawesome.com/)
* [Simple Icons](https://github.com/simple-icons/simple-icons)
* [Animate.css](https://daneden.github.io/animate.css/)
* [autocomplete.js](https://github.com/algolia/autocomplete.js)
* [Lunr.js](https://lunrjs.com/)
* [algoliasearch](https://github.com/algolia/algoliasearch-client-javascript)
* [Fuse.js](https://fusejs.io/)
* [lazysizes](https://github.com/aFarkas/lazysizes)
* [object-fit-images](https://github.com/fregante/object-fit-images)
* [Twemoji](https://github.com/twitter/twemoji)
* [lightgallery.js](https://github.com/sachinchoolur/lightgallery.js)
* [clipboard.js](https://github.com/zenorocha/clipboard.js)
* [Sharer.js](https://github.com/ellisonleao/sharer.js)
* [TypeIt](https://typeitjs.com/)
* [$ \KaTeX $](https://katex.org/)
* [mermaid](https://github.com/knsv/mermaid)
* [ECharts](https://echarts.apache.org/)
* [Mapbox GL JS](https://docs.mapbox.com/mapbox-gl-js)
* [APlayer](https://github.com/MoePlayer/APlayer)
* [MetingJS](https://github.com/metowolf/MetingJS)
* [Gitalk](https://github.com/gitalk/gitalk)
* [Valine](https://valine.js.org/)
* [Waline](https://waline.js.org/)
* [Twikoo](https://twikoo.js.org/)
* [cookieconsent](https://github.com/osano/cookieconsent)

1 comment on commit cb920c9

@vercel
Copy link

@vercel vercel bot commented on cb920c9 Jul 18, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.