Showing preview only (559K chars total). Download the full file or copy to clipboard to get everything.
Repository: getgridea/gridea
Branch: master
Commit: 48e4ab573bfa
Files: 206
Total size: 508.3 KB
Directory structure:
gitextract_69c_nu5k/
├── .browserslistrc
├── .editorconfig
├── .eslintrc.js
├── .github/
│ └── ISSUE_TEMPLATE/
│ ├── bug_report.md
│ ├── feature_request.md
│ └── question.md
├── .gitignore
├── .npmrc
├── CHANGELOG.md
├── LICENSE
├── README-ru.md
├── README-zh_CN.md
├── README-zh_TW.md
├── README.md
├── babel.config.js
├── package.json
├── postcss.config.js
├── public/
│ ├── app-icons/
│ │ └── gridea.icns
│ ├── default-files/
│ │ ├── config/
│ │ │ ├── posts.json
│ │ │ ├── setting.json
│ │ │ └── theme.json
│ │ ├── post-images/
│ │ │ └── .gitkeep
│ │ ├── posts/
│ │ │ ├── about.md
│ │ │ └── hello-gridea.md
│ │ ├── static/
│ │ │ └── 404.html
│ │ └── themes/
│ │ ├── fly/
│ │ │ ├── assets/
│ │ │ │ └── styles/
│ │ │ │ ├── _blocks/
│ │ │ │ │ ├── archives.less
│ │ │ │ │ ├── fonts.less
│ │ │ │ │ ├── footer.less
│ │ │ │ │ ├── header.less
│ │ │ │ │ ├── link.less
│ │ │ │ │ ├── list.less
│ │ │ │ │ ├── pagination.less
│ │ │ │ │ ├── post.less
│ │ │ │ │ ├── tag.less
│ │ │ │ │ └── tags.less
│ │ │ │ ├── _core/
│ │ │ │ │ ├── base.less
│ │ │ │ │ ├── colors.less
│ │ │ │ │ └── github.less
│ │ │ │ └── main.less
│ │ │ ├── config.json
│ │ │ ├── style-override.js
│ │ │ └── templates/
│ │ │ ├── archives.ejs
│ │ │ ├── includes/
│ │ │ │ ├── footer.ejs
│ │ │ │ ├── head.ejs
│ │ │ │ ├── header.ejs
│ │ │ │ ├── post-list-archives.ejs
│ │ │ │ ├── post-list.ejs
│ │ │ │ └── scripts.ejs
│ │ │ ├── index.ejs
│ │ │ ├── post.ejs
│ │ │ ├── tag.ejs
│ │ │ └── tags.ejs
│ │ ├── notes/
│ │ │ ├── assets/
│ │ │ │ └── styles/
│ │ │ │ ├── abstracts/
│ │ │ │ │ └── varibles.less
│ │ │ │ ├── components/
│ │ │ │ │ ├── about.less
│ │ │ │ │ ├── archives.less
│ │ │ │ │ ├── footer.less
│ │ │ │ │ ├── header.less
│ │ │ │ │ ├── home.less
│ │ │ │ │ ├── post.less
│ │ │ │ │ ├── tag.less
│ │ │ │ │ └── tags.less
│ │ │ │ ├── lib/
│ │ │ │ │ ├── colors.less
│ │ │ │ │ ├── github.less
│ │ │ │ │ └── modern-normalize.less
│ │ │ │ └── main.less
│ │ │ ├── config.json
│ │ │ ├── style-override.js
│ │ │ └── templates/
│ │ │ ├── archives.ejs
│ │ │ ├── includes/
│ │ │ │ ├── disqus.ejs
│ │ │ │ ├── footer.ejs
│ │ │ │ ├── gitalk.ejs
│ │ │ │ ├── head.ejs
│ │ │ │ ├── header.ejs
│ │ │ │ ├── pagination.ejs
│ │ │ │ ├── post-list-archives.ejs
│ │ │ │ └── post-list.ejs
│ │ │ ├── index.ejs
│ │ │ ├── post.ejs
│ │ │ ├── tag.ejs
│ │ │ └── tags.ejs
│ │ ├── paper/
│ │ │ ├── assets/
│ │ │ │ └── styles/
│ │ │ │ ├── _core/
│ │ │ │ │ ├── base.less
│ │ │ │ │ ├── colors.less
│ │ │ │ │ └── github.less
│ │ │ │ └── main.less
│ │ │ ├── config.json
│ │ │ ├── style-override.js
│ │ │ └── templates/
│ │ │ ├── _blocks/
│ │ │ │ ├── head.ejs
│ │ │ │ ├── header.ejs
│ │ │ │ ├── pagination.ejs
│ │ │ │ ├── post-list.ejs
│ │ │ │ ├── scripts.ejs
│ │ │ │ └── sidebar.ejs
│ │ │ ├── archives.ejs
│ │ │ ├── index.ejs
│ │ │ ├── post.ejs
│ │ │ ├── tag.ejs
│ │ │ └── tags.ejs
│ │ └── simple/
│ │ ├── assets/
│ │ │ └── styles/
│ │ │ ├── _core/
│ │ │ │ ├── a11y-dark.less
│ │ │ │ ├── atom-one-dark.less
│ │ │ │ ├── base.less
│ │ │ │ ├── colors.less
│ │ │ │ └── github.less
│ │ │ └── main.less
│ │ ├── config.json
│ │ ├── style-override.js
│ │ └── templates/
│ │ ├── _blocks/
│ │ │ ├── head.ejs
│ │ │ ├── pagination.ejs
│ │ │ ├── scripts.ejs
│ │ │ └── sidebar.ejs
│ │ ├── archives.ejs
│ │ ├── index.ejs
│ │ ├── post.ejs
│ │ ├── tag.ejs
│ │ └── tags.ejs
│ └── index.html
├── src/
│ ├── App.vue
│ ├── assets/
│ │ ├── locales-menu.ts
│ │ ├── locales.ts
│ │ └── styles/
│ │ ├── custom.less
│ │ ├── main.less
│ │ ├── tailwind.css
│ │ ├── var.less
│ │ └── zwicon.less
│ ├── background.ts
│ ├── components/
│ │ ├── AppSystem/
│ │ │ ├── Index.vue
│ │ │ └── includes/
│ │ │ ├── LanguageSetting.vue
│ │ │ ├── SourceFolderSetting.vue
│ │ │ └── Version.vue
│ │ ├── ColorCard/
│ │ │ └── Index.vue
│ │ ├── EmojiCard/
│ │ │ └── Index.vue
│ │ ├── FooterBox/
│ │ │ └── Index.vue
│ │ ├── Main.vue
│ │ ├── MonacoMarkdownEditor/
│ │ │ ├── Index.vue
│ │ │ └── theme.js
│ │ └── PostsCard/
│ │ └── Index.vue
│ ├── helpers/
│ │ ├── analytics.ts
│ │ ├── constants.ts
│ │ ├── content-helper.ts
│ │ ├── enums.ts
│ │ ├── shortcut-keys.ts
│ │ ├── slug.ts
│ │ ├── utils.ts
│ │ ├── vee-validate.ts
│ │ └── words-count.ts
│ ├── interfaces/
│ │ ├── menu.ts
│ │ ├── post.ts
│ │ ├── setting.ts
│ │ ├── snackbar.ts
│ │ ├── tag.ts
│ │ └── theme.ts
│ ├── main.ts
│ ├── router.ts
│ ├── server/
│ │ ├── app.ts
│ │ ├── deploy.ts
│ │ ├── events/
│ │ │ ├── deploy.ts
│ │ │ ├── index.ts
│ │ │ ├── menu.ts
│ │ │ ├── post.ts
│ │ │ ├── renderer.ts
│ │ │ ├── setting.ts
│ │ │ ├── site.ts
│ │ │ ├── tag.ts
│ │ │ └── theme.ts
│ │ ├── interfaces/
│ │ │ ├── application.ts
│ │ │ ├── menu.ts
│ │ │ ├── post.ts
│ │ │ ├── renderer.ts
│ │ │ ├── setting.ts
│ │ │ ├── tag.ts
│ │ │ └── theme.ts
│ │ ├── menus.ts
│ │ ├── model.ts
│ │ ├── plugins/
│ │ │ ├── deploys/
│ │ │ │ ├── gitproxy.ts
│ │ │ │ ├── netlify.ts
│ │ │ │ └── sftp.ts
│ │ │ └── markdown.ts
│ │ ├── posts.ts
│ │ ├── renderer.ts
│ │ ├── setting.ts
│ │ ├── tags.ts
│ │ └── theme.ts
│ ├── server.ts
│ ├── shims-tsx.d.ts
│ ├── shims-vue.d.ts
│ ├── shims.d.ts
│ ├── store/
│ │ ├── index.ts
│ │ └── modules/
│ │ └── site.ts
│ ├── views/
│ │ ├── article/
│ │ │ ├── ArticleUpdate.vue
│ │ │ └── Articles.vue
│ │ ├── loading/
│ │ │ └── Index.vue
│ │ ├── menu/
│ │ │ └── Index.vue
│ │ ├── setting/
│ │ │ ├── Index.vue
│ │ │ └── includes/
│ │ │ ├── BasicSetting.vue
│ │ │ ├── CommentSetting.vue
│ │ │ ├── DisqusSetting.vue
│ │ │ └── GitalkSetting.vue
│ │ ├── tags/
│ │ │ └── Index.vue
│ │ └── theme/
│ │ ├── Index.vue
│ │ └── includes/
│ │ ├── AvatarSetting.vue
│ │ ├── BasicSetting.vue
│ │ ├── CustomSetting.vue
│ │ └── FaviconSetting.vue
│ └── vue-bus.ts
├── tailwind.config.js
├── tsconfig.json
└── vue.config.js
================================================
FILE CONTENTS
================================================
================================================
FILE: .browserslistrc
================================================
> 1%
last 2 versions
not ie <= 8
================================================
FILE: .editorconfig
================================================
# EditorConfig is awesome: https://EditorConfig.org
# top-most EditorConfig file
root = true
# Unix-style newlines with a newline ending every file
[*]
end_of_line = lf
insert_final_newline = true
# Matches multiple files with brace expansion notation
# Set default charset
[*.{js,py}]
charset = utf-8
# Tab indentation (no size specified)
[Makefile]
indent_style = tab
# Indentation override for all JS under lib directory
[*.{js,ts}]
indent_style = space
indent_size = 2
# Matches the exact files either package.json or .travis.yml
[{package.json,.travis.yml}]
indent_style = space
indent_size = 2
================================================
FILE: .eslintrc.js
================================================
module.exports = {
root: true,
env: {
node: true,
},
extends: ['plugin:vue/essential', '@vue/airbnb', '@vue/typescript'],
rules: {
// js 和 ts 不需要检查 import 的文件后缀
'import/extensions': [
'error',
'always',
{
js: 'never',
ts: 'never',
},
],
'no-restricted-syntax': [
'error',
'WithStatement',
'BinaryExpression[operator=\'in\']',
],
// 可以 debugger
'no-debugger': process.env.NODE_ENV === 'production' ? 2 : 0,
// 不要分号
semi: [2, 'never'],
// 全部单引号
quotes: [2, 'single'],
// 对象缩写
'object-shorthand': 0,
// 可以使用 console
'no-console': 0,
// 允许使用匿名函数
'func-names': 0,
// 允许属性的 key 值加引号
'quote-props': 0,
// 允许对函数的参数赋值
'no-param-reassign': 0,
// 函数的参数可以不使用
'no-unused-vars': 0,
// 不用强制 export default
'import/prefer-default-export': 0,
// 不禁止箭头函数直接return对象
'arrow-body-style': 0,
// 允许空行
'no-trailing-spaces': ['error', { skipBlankLines: true }],
// 允许short circuit evaluations
'no-unused-expressions': [
'error',
{ allowShortCircuit: true, allowTernary: true },
],
// 最长字符
'max-len': ['error', { code: 1500 }],
'vue/no-parsing-error': [
2,
{
'invalid-first-character-of-tag-name': false,
},
],
// no-plusplus
'no-plusplus': 0,
'class-methods-use-this': 0,
'no-irregular-whitespace': 0,
'consistent-return': 0,
'import/no-extraneous-dependencies': 0,
'global-require': 0,
'no-continue': 0,
'linebreak-style': 0,
},
parserOptions: {
parser: '@typescript-eslint/parser',
},
}
================================================
FILE: .github/ISSUE_TEMPLATE/bug_report.md
================================================
---
name: Bug Report
about: 事情不像预期的那样工作吗?
title: ''
labels: 'bug'
assignees: ''
---
<!--
你好!感谢你正在考虑为 Gridea 提交一个 bug。请花一点点时间尽量详细地回答以下基础问题。
如果你不确定这是一个 Gridea 的 bug,请加入我们的用户群去讨论。
谢谢!
-->
<!--
请确认你已经做了下面这些事情,若 bug 还是显而易见的,尽可详细地描述你的问题。
- 我已经安装了最新版的 Gridea
- 我已经搜索了已有的 Issues列表
- 我已经阅读了 Gridea 的 FAQ:https://gridea.dev/docs/faq.html
- 我已经查看了上手教程(视频或文字):https://gridea.dev/docs
-->
## 我的环境
| 名称 | 值 |
| ------- | ---- |
| 操作系统 | |
| 软件版本 | |
| 主题名称 | |
---
## 期望行为
<!--
你期望会发生什么?
-->
## 当前行为
<!--
描述 bug 细节,确认出现此问题的复现步骤,例如点击了哪里,发生了什么情况?
你可以粘贴截图或附件。
-->
================================================
FILE: .github/ISSUE_TEMPLATE/feature_request.md
================================================
---
name: Feature Request
about: 想让我们为 Gridea 增加什么功能吗?
title: 'feat: '
labels: 'Feature Request'
assignees: ''
---
<!--
你好!感谢你愿意考虑希望 Gridea 增加某个新功能。请花一点点时间尽量详细地回答以下基础问题。
谢谢!
-->
## 概述
<!--
对这个新功能的一段描述
-->
## 动机
<!--
为什么你希望在 Gridea 中使用这个功能?
-->
## 详细解释
<!--
详细描述这个新功能。
如果这是一个小功能,你可以忽略这部分。
-->
================================================
FILE: .github/ISSUE_TEMPLATE/question.md
================================================
---
name: Question
about: 对 Gridea 有任何问题吗?
title: ''
labels: 'question'
assignees: ''
---
<!--
如果你有任何问题也可以通过此渠道来向我们反馈。不过,通常我们建议你可以加入我们的群组获得更及时的解答。
谢谢!
-->
================================================
FILE: .gitignore
================================================
.DS_Store
node_modules
/dist
# local env files
.env.local
.env.*.local
# Log files
npm-debug.log*
yarn-debug.log*
yarn-error.log*
# Editor directories and files
.idea
.vscode
*.suo
*.ntvs*
*.njsproj
*.sln
*.sw*
#Electron-builder output
/dist_electron
================================================
FILE: .npmrc
================================================
registry=https://registry.npmjs.org
================================================
FILE: CHANGELOG.md
================================================
## v0.9.1
`2020-01-01`
- 修复首次安装使用 Gridea,无法预览 BUG
## v0.9.0
`2019-12-28`
**注意:若你之前有手动放置文件或文件夹到构建后文件夹(output 文件夹)本次升级有非兼容升级,请看下升级说明,若没有,可直接升级啦**
升级说明:
需手动复制到博客源文件夹的 static 文件夹(若无此文件夹可新建一个,新版使用时会自动生成,有静态文件需求的可放在此文件夹,构建时会直接复制到 output 文件夹)
## 新增
- 新增 SFTP 部署
- 新增文章置顶功能
- 自定义配置支持图片类型和数组类型,增加文章数据卡片类型
- 自定义归档路径前缀
- 文章页与标签页支持精简 URL 与默认 URL
- 新增菜单拖动排序
- 支持自定义模板渲染,具体可见[Gridea 文档](https://gridea.dev/docs)
## 修复
- 修复更改文章 URL 大小写会删除文章的 bug
- 修复编辑器超出一屏后回车不会滚动的 bug
- 修复 Linux(Ubuntu)初始化配置时,检测远程链接失败的 BUG
## 优化
- 文章内图片支持懒加载(基于 chrome 的lazy loading)
- 升级 Electron 至 7.x
- 标签页支持渲染列表隐藏文章(break change)
- 增加预览唤出快捷键(Ctrl + P)
- 优化编辑器 Windows 下字体显示
- 增加渲染过程错误日志弹窗
- 增加应用内通知系统
## v0.8.3
`2019-09-23`
「全新体验,助你妙笔生花」
## 新增
- 全新的内置编辑器,全新的编辑体验与快捷键
- 增加 Emoji 输入面板与文章信息统计
- 增加 `isHomepage`字段,赋予主题开发更多可能性
- Markdown 渲染支持 `Emoji` 与 `implict-figures`
- 增加 GA 统计,为了更好的优化产品
- 新上架一款主题 「Tech」
<img src="https://user-images.githubusercontent.com/17328747/65395740-9b01ca80-ddd1-11e9-8bee-c55ae6a41ef3.png" alt="Tech" width="100%" />
## 修复
- 修复文章编辑页返回未保存提示,内容不丢失
- 修复创建文章时报 URL 冲突 BUG
## 优化
- 升级 Electron 版本到 6.0+,更快了
- 更改本地预览为 Server 模式
- 提升了阅读时间的准确度
- 更多细节优化,等你发现
## v0.8.2
`2019-07-15`
## 新增
- 文章编辑页增加 `Command/Ctrl + S` 快捷键,快速保存文章
- 增加繁体中文显示 (thanks @joinmouse )
- Makrdown 渲染支持 `Mark`、`Sup`、`Abbr`、`Footnote`
- 侧边栏新增直达站点按钮
- 增加上一篇文章渲染字段支持 `post.prevPost`
- 文章增加 Reading Time(阅读时间,例如 `9 min read`) 字段 `post.stats`
- Markdown 渲染支持设置图片大小,例如:``
## 优化
- 更新 Electron 版本到 5.0.6,提升应用内菜单切换流畅性,更快了
- 优化编辑器**编辑体验**与应用内预览样式(**强烈推荐**)
- 新增文章编辑时可新建标签
- 提升编辑器的安全性
- Notes 主题显示优化与增加目录显示(**需手动更新主题**)
- 应用菜单多语言支持与优化
## v0.8.1
`2019-05-26`
### 新增
- 增加 **Linux 版**
- 增加 RSS 支持,并在默认主题中增加链接(⚠️**需手动更新主题**,或在原主题中添加链接为 `href="<%= themeConfig.domain %>/atom.xml"`)
- 增加 **Task lists** 渲染支持
- 增加**编辑器粘贴剪切板中图片**功能
- 增加 [主题市场](https://gridea.dev/themes/) 与 [主题开发样板](https://github.com/getgridea/gridea-theme-starter),欢迎参与主题开发
### 修复
- 修复文章标题包含特殊字符时渲染 BUG
- 修复 KaTeX 公式渲染 BUG(⚠️**需手动更新主题**,若不更新主题,文章内使用 KaTeX 可能会造成文章公式显示异常)
- 修复文章详情页 `site.posts` 包含隐藏文章 BUG
- 修复应用内预览文章,点击链接为应用内打开 BUG
- 修复编辑文章时,更改文章标题,文章 URL 自动变化 bug
### 优化
- 编辑器菜单栏置顶优化
- 优化安装包体积,减小 **25%**
> **提示:**
> 手动更新主题,需将`源文件夹/themes` 文件夹里的旧主题删除,重启应用即可
> (源文件夹默认为:`~/Documents/Gridea`,也可在应用内:**系统 -> 源文件夹** 进行查看)
## v0.8.0
`2019-04-14`
### 新增
- 全新品牌名 **Gridea**,更易读!
- 全新 LOGO,更好记!thanks @Leohuaji
- 全新视觉,更简约!
- 新增主题自定义配置功能,你可以使用主题提供的社交、谷歌统计、自定义样式...等自定义配置,当然你也可以开发新的主题,提供更有趣的自定义配置,尽情发挥你的想象(⚠️**需手动更新主题**)
- 新增一款主题 「Paper」,英文手写体风格,欢迎体验
- 封面图支持外链
- 文章支持 `@[toc]` 显示文章目录,同时增加 `post.toc` 字段供主题显示
- [**KaTeX**](https://katex.org/) 公式支持
- 全新项目主页,欢迎 [访问](https://gridea.dev)
### 修复
- 修复基本配置未填写时,点击检测远程链接导致后续操作失效 BUG
- 修复文章 URL 中含有 `/` 导致新建文章保存失败 BUG #29
- 修复 Favicon 和 Avatar 图片缓存问题 #24
- 修复更改源文件夹,新文件夹为空时 BUG
### 优化
- 固定文章编辑页附属信息栏,长文章编辑体验增强
- 内置主题细节优化,适配主题自定义配置功能
> **提示:**
> 若您是老用户,安装新版之后,需将 `源文件夹/themes` 文件夹里的旧主题删除,重启应用,方可使用内置主题的自定义配置功能
> (源文件夹默认为:旧:`~/Documents/hve-notes`,新:`~/Documents/Gridea`)
## v0.7.7
`2019-03-01`
- 🛠 修复了应用中非第一页文章删除时 BUG
## v0.7.6
`2019-02-27`
### 新增
- 🔥 Windows 安装支持**自定义安装路径**
- 🔥 增加**远程连接检测**功能
- 🔥 新增一款主题: **Simple**
- 🔥 增加**自定义源文件夹**,可利用 OneDrive、百度网盘、iCloud、Dropbox 等进行多设备同步
- 🧩 增加文章目录(TOC)能力(数据支持,还需主题支持)
### 修复
- 🛠 文章时间渲染错误
- 🛠 所有文章隐藏渲染错误
- 🛠 部署除 master 分支外分支不成功问题
- 🛠 标签带空格使用时渲染错误
- 🛠 文章编辑全屏时无法点击输入菜单栏的 BUG
- 🛠 文章快捷输入链接菜单BUG
### 优化
- 🌟 摘要分隔符判断逻辑 <!-- more --> 单独行为摘要渲染分割符
- 🌟 调整应用部分 UI
- 🌟 增加应用退出快捷键
- 🌟 增加同步和检测远程连接时开发者工具控制台错误信息显示,更精准的定位同步问题
## v0.7.5 - 🎈 新春快乐 🏮 🧨 🧧
`2019-01-30`
- 🌈 重写应用 UI
- 🔥 增加**归档页**渲染支持和**每页归档数**自定义功能
- 🔥 增加**标签页**渲染支持
- 🔥 增加文章 Link 和标签 Link 设置**默认生成方式**和**自定义**支持
- 🔥 增加**列表隐藏文章**功能,用于创建特殊页面使用(例如,**关于**页)
- 🔥 增加**显示日期格式自定义**功能
- 🌟 优化默认主题「notes、fly」,支持归档页和标签页显示(️️⚡️ 需手动更新)
- 🌟 更新文档
> 注:
> - 更新主题,需将 `~/Documents/hve-notes/themes` 文件夹中主题删除,重新启动应用即可
## v0.7.0
`2019-01-20`
- 🔥 增加多语言支持:English、简体中文(默认)
- 🔥 增加多平台部署支持:Github Pages、Coding Pages
- 🔥 增加多评论系统支持:Gitalk、DisqusJS(不兼容更新 ⚡️)
- 🌟 全新的文章编辑页,专注写作
- 🌟 优化多处交互体验
- 🌟 完善文档,更强大的主题开发能力
- 🌟 优化默认主题「notes、fly」:多评论支持及 UI 优化
> 注:
> - 更新主题,需将 `~/Documents/hve-notes/themes` 文件夹中对应主题删除,重新启动应用即可
> - ⚡️ 若之前有设置过 Gitalk 配置,此版本更新后需重新设置一下(原 Gitalk 配置信息可见`~/Documents/hve-notes/config/setting.json`)
## v0.6.4
- 新增一款主题:「fly」,优化默认主题UI:「notes」 (若想更新 notes 主题,已安装旧版本用户需将旧版本应用文件夹 `~/Documents/hve-notes` 删除,安装新版应用即可(记得备份文件哦!))
- 新增头像设置功能
- 调整多处 UI
- 完善主题开发文档
## v0.6.3
- 🐛 更改构建配置,修复了应用初始化文件夹的 BUG(使用前,需要手动删除文档(Documents)目录下的 hve-notes 文件夹,然后打开应用即可正常初始化)
- 修复 material icons load bug,感谢 @rosuH
- 简单优化 favicon 页面 UI
- 添加发布前配置简单校验
- 🙏 感谢支持
## v0.6.2
- 优化默认主题 title、link 等
- 新增版本更新提醒
- 新增 CNAME 配置
- 新增 favicon 配置
- 新增 Gitalk 配置
- 修复 Windows 下文章更新 bug
## v0.6.1
- 增加文章删除功能
- 更新 footer 信息
- 更改顶部窗口控制方式
- 更改默认打开窗口大小
- windows版 和 mac 版同步发布 ✌
================================================
FILE: LICENSE
================================================
MIT License
Copyright (c) 2019 EryouHao
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
================================================
FILE: README-ru.md
================================================
<div align="center">
<a href="https://gridea.dev">
<img src="public/app-icons/gridea.png" width="80px" height="80px">
</a>
<h1 align="center">
Gridea
</h1>
<h3 align="center">
Клиент для ведения блога
</h3>
[Загрузить](https://github.com/getgridea/gridea/releases) | [Официальная страница](https://gridea.dev/)
<a href="https://github.com/getgridea/gridea/releases/latest">
<img src="https://img.shields.io/github/release/getgridea/gridea.svg?style=flat-square" alt="">
</a>
<a href="https://github.com/getgridea/gridea/blob/master/LICENSE">
<img src="https://img.shields.io/github/license/getgridea/gridea.svg?style=flat-square" alt="">
</a>
<a href="https://github.com/getgridea/gridea/releases/latest">
<img alt="GitHub All Releases" src="https://img.shields.io/github/downloads/getgridea/gridea/total.svg?color=%2312b886&style=flat-square">
</a>
</div>
<div align="center">
<img src="gridea-app-en.png">
</div>
[English](https://github.com/getgridea/gridea/blob/master/README.md) | Русский | [简体中文](https://github.com/getgridea/gridea/blob/master/README-zh_CN.md) | [繁體中文](https://github.com/getgridea/gridea/blob/master/README-zh_TW.md)
**[CHANGELOG](https://github.com/getgridea/gridea/blob/master/CHANGELOG.md)**
👏 Спасибо, что используете **Gridea**!
✍️ **Gridea** это статичный клиент для ведения блога. Вы можете использовать его для записи событий своей жизни, заметок о настроении, полученых знаний, эссе и идей...
## Возможности👇
📝 Используйте самый крутой редактор **Markdown** для быстрого создания и редактирования материалов
🌉 Вставляйте изображения и диаграммы для обложки материала или вставляйте их в любое место статьи
🏷️ Создавайте рубрики и группируйте материалы
📋 Редактируйте меню и добавляйте туда любые ссылки
💻 Используйте статичный клиент для **Windows** или **MacOS** или даже **Linux**
🌎 Используйте **Github Pages** или **Coding Pages** чтобы поделиться материалами (в следующих версиях будет поддерживаться ещё больше платформ)
💬 Запросто настройте и получите доступ с системам комментирования [Gitalk](https://github.com/gitalk/gitalk) или [DisqusJS](https://github.com/SukkaW/DisqusJS)
🗺️ Наш клиент мультиязычен и имеет **упрощённый Китайский**、**традиционный Китайский**、 **Английский**、 **Русский**、 **Французский**、 **Японский** языки
🌁 Используйте любую тему по умолчанию прямо в клиенте или подключите любую стороннюю тему, почуствуйте свободу при настройке тем
🖥 Настройте папку для хранения материалов и синхронизируйте несколько устройств с помощью OneDrive, iCloud, Dropbox и т.д.
🌱 Конечно, **Gridea** ещё очень молода и имеет немного недостатков, но, поверьте, она продолжает двигаться вперед и развиваться 🏃
Надеемся, этот клиент станет вашим неразлучным партнером в творчестве
Дайте полную волю своим талантам!
😘 Наслаждайтесь использованием~
## Разработка
Если вы хотите внести свой вклад в код, пожалуйста, проверьте [Contribution Guide (он правда на китайском)](https://github.com/getgridea/gridea/wiki/%E8%B4%A1%E7%8C%AE%E6%8C%87%E5%8D%97) на всякий случай.
``` shell
$ # Node version > v10.0.0 is requied
$ git clone https://github.com/getgridea/gridea.git
$ cd gridea
$ yarn
$ yarn electron:serve
$ yarn electron:build
```
## Контакты и обратная связь
[Канал в Telegram](https://t.me/joinchat/AAAAAEj82_lma0Y1wmyqUQ) | [Группа в Telegram](https://t.me/joinchat/IDY0ahRqb8NPodv95BNpBg) | QQ 1 Group: 970332209 | QQ 2 Group: 923131213 | Author Twitter: @EryouHao
## Примеры в скриншотах
<div align="center">
<img src="./files/themes.png">
</div>
## Участие в разработке
Мы приветствуем все идеи и улучшения. Вы можете отправлять любые идеи в виде [pull requests](https://github.com/getgridea/gridea/pulls) или как GitHub [issues](https://github.com/getgridea/gridea/issues).
## Пожертвования разработчикам
<div>
<img src="./files/wechat.png" width="240px">
</div>
## Сайт переводчика на Русский язык
[Заглянуть ко мне на сайт](https://paul.bid/) там есть и другие интересные проекты 😉
## Лицензия
[MIT](https://github.com/getgridea/gridea/blob/master/LICENSE). Copyright (c) 2020-2023 EryouHao
================================================
FILE: README-zh_CN.md
================================================
<div align="center">
<a href="https://gridea.dev">
<img src="public/app-icons/gridea.png" width="80px" height="80px">
</a>
<h1 align="center">
Gridea
</h1>
<h3 align="center">
一个静态博客写作客户端
</h3>
[下 载](https://github.com/getgridea/gridea/releases) | [主 页](https://gridea.dev/)
<a href="https://github.com/getgridea/gridea/releases/latest">
<img src="https://img.shields.io/github/release/getgridea/gridea.svg?style=flat-square" alt="">
</a>
<a href="https://github.com/getgridea/gridea/blob/master/LICENSE">
<img src="https://img.shields.io/github/license/getgridea/gridea.svg?style=flat-square" alt="">
</a>
<a href="https://github.com/getgridea/gridea/releases/latest">
<img alt="GitHub All Releases" src="https://img.shields.io/github/downloads/getgridea/gridea/total.svg?color=%2312b886&style=flat-square">
</a>
</div>
<div align="center">
<img src="gridea-app.png">
</div>
[English](https://github.com/getgridea/gridea/blob/master/README.md) | 简体中文 | [繁體中文](https://github.com/getgridea/gridea/blob/master/README-zh_TW.md)
**[更新日志](https://github.com/getgridea/gridea/blob/master/CHANGELOG.md)**
👏 欢迎使用 **Gridea** !
✍️ **Gridea** 一个静态博客写作客户端。你可以用它来记录你的生活、心情、知识、笔记、创意... ...
## 特性👇
📝 你可以使用最酷的 **Markdown** 语法,进行快速创作
🌉 你可以给文章配上精美的封面图和在文章任意位置插入图片
🏷️ 你可以对文章进行标签分组
📋 你可以自定义菜单,甚至可以创建外部链接菜单
💻 你可以在 **𝖶𝗂𝗇𝖽𝗈𝗐𝗌** 或 **𝖬𝖺𝖼𝖮𝖲** 或 **Linux** 设备上使用此客户端
🌎 你可以使用 **𝖦𝗂𝗍𝗁𝗎𝖻 𝖯𝖺𝗀𝖾𝗌** 或 **Coding Pages** 向世界展示,未来将支持更多平台
💬 你可以进行简单的配置,接入 [Gitalk](https://github.com/gitalk/gitalk) 或 [DisqusJS](https://github.com/SukkaW/DisqusJS) 评论系统
🇬🇧 你可以使用**中文简体**、**中文繁体**、**英语**
🌁 你可以任意使用应用内默认主题或任意第三方主题,强大的主题自定义能力
🖥 你可以自定义源文件夹,利用 OneDrive、百度网盘、iCloud、Dropbox 等进行多设备同步
🌱 当然 **Gridea** 还很年轻,有很多不足,但请相信,它会不停向前🏃
未来,它一定会成为你离不开的伙伴
尽情发挥你的才华吧!
😘 Enjoy~
## 开发
如果你想贡献代码,请提前参阅[贡献指南](https://github.com/getgridea/gridea/wiki/%E8%B4%A1%E7%8C%AE%E6%8C%87%E5%8D%97)
``` shell
$ # Node version > v10.0.0 is requied
$ git clone https://github.com/getgridea/gridea.git
$ cd gridea
$ yarn
$ yarn electron:serve
$ yarn electron:build
```
## 联系
[Telegram 频道](https://t.me/joinchat/AAAAAEj82_lma0Y1wmyqUQ) | [Telegram 群组](https://t.me/joinchat/IDY0ahRqb8NPodv95BNpBg) | QQ 1 群: 970332209(已满)| QQ 2 群: 923131213 | 作者推特: @EryouHao
## 示例截图
<div align="center">
<img src="./files/themes.png">
</div>
## 贡献
我们欢迎任何形式的贡献。你可以用 [pull requests](https://github.com/getgridea/gridea/pulls) 或 [issues](https://github.com/getgridea/gridea/issues) 的方式提交任何想法。
## 支持
<div>
<img src="./files/wechat.png" width="240px">
</div>
## License
[MIT](https://github.com/getgridea/gridea/blob/master/LICENSE). Copyright (c) 2020 EryouHao
================================================
FILE: README-zh_TW.md
================================================
<div align="center">
<a href="https://gridea.dev">
<img src="public/app-icons/gridea.png" width="80px" height="80px">
</a>
<h1 align="center">
Gridea
</h1>
<h3 align="center">
一個靜態博客寫作客戶端
</h3>
[下 載](https://github.com/getgridea/gridea/releases) | [主 頁](https://gridea.dev/)
<a href="https://github.com/getgridea/gridea/releases/latest">
<img src="https://img.shields.io/github/release/getgridea/gridea.svg?style=flat-square" alt="">
</a>
<a href="https://github.com/getgridea/gridea/blob/master/LICENSE">
<img src="https://img.shields.io/github/license/getgridea/gridea.svg?style=flat-square" alt="">
</a>
<a href="https://github.com/getgridea/gridea/releases/latest">
<img alt="GitHub All Releases" src="https://img.shields.io/github/downloads/getgridea/gridea/total.svg?color=%2312b886&style=flat-square">
</a>
</div>
<div align="center">
<img src="gridea-app.png">
</div>
[English](https://github.com/getgridea/gridea/blob/master/README.md) | [简体中文](https://github.com/getgridea/gridea/blob/master/README-zh_CN.md) | 繁體中文
**[更新日誌](https://github.com/getgridea/gridea/blob/master/CHANGELOG.md)**
👏 歡迎使用 **Gridea** !
✍️ **Gridea** 一個靜態博客寫作客戶端。你可以用它來記錄你的生活、心情、知識、筆記、創意... ...
## 特性👇
📝 你可以使用最酷的 **Markdown** 語法,進行快速創作
🌉 你可以給文章配上精美的封面圖和在文章任意位置插入圖片
🏷️ 你可以對文章進行標籤分組
📋 你可以自定義菜單,甚至可以創建外部鏈接菜單
💻 你可以在 **𝖶𝗂𝗇𝖽𝗈𝗐𝗌** 或 **𝖬𝖺𝖼𝖮𝖲** 設備上使用此客戶端
🌎 你可以使用 **𝖦𝗂𝗍𝗁𝗎𝖻 𝖯𝖺𝗀𝖾𝗌** 或 **Coding Pages** 向世界展示,未來將支持更多平台
💬 你可以進行簡單的配置,接入 [Gitalk](https://github.com/gitalk/gitalk) 或 [DisqusJS](https://github.com/SukkaW/DisqusJS) 評論系統
🇬🇧 你可以使用**中文簡體**、**中文繁體**、**英語**
🌁 你可以任意使用應用內默認主題或任意第三方主題,強大的主題自定義能力
🖥 你可以自定義源文件夾,利用 OneDrive、百度網盤、iCloud、Dropbox 等進行多設備同步
🌱 當然 **Gridea** 還很年輕,有很多不足,但請相信,它會不停向前🏃
未來,它一定會成為你離不開的伙伴
盡情發揮你的才華吧!
😘 Enjoy~
## 開發
如果你想貢獻代碼,請提前參閱[貢獻指南](https://github.com/getgridea/gridea/wiki/%E8%B4%A1%E7%8C%AE%E6%8C%87%E5%8D%97)
``` shell
$ # Node version > v10.0.0 is requied
$ git clone https://github.com/getgridea/gridea.git
$ cd gridea
$ yarn
$ yarn electron:serve
$ yarn electron:build
```
## 聯繫
[Telegram 頻道](https://t.me/joinchat/AAAAAEj82_lma0Y1wmyqUQ) | [Telegram 群組](https://t.me/joinchat/IDY0ahRqb8NPodv95BNpBg) | QQ 1 群: 970332209(已满)| QQ 2 群: 923131213 | 作者推特: @EryouHao
## 示例截圖
<div align="center">
<img src="./files/themes.png">
</div>
## 貢獻
我們歡迎任何形式的貢獻。你可以用 [pull requests](https://github.com/getgridea/gridea/pulls) 或 [issues](https://github.com/getgridea/gridea/issues) 的方式提交任何想法。
## 支持
<div>
<img src="./files/wechat.png" width="240px">
</div>
## License
[MIT](https://github.com/getgridea/gridea/blob/master/LICENSE). Copyright (c) 2020 EryouHao
================================================
FILE: README.md
================================================
<div align="center">
<a href="https://gridea.dev">
<img src="public/app-icons/gridea.png" width="80px" height="80px">
</a>
<h1 align="center">
Gridea
</h1>
<h3 align="center">
A static blog writing client
</h3>
[Download](https://github.com/getgridea/gridea/releases) | [Homepage](https://gridea.dev/)
<a href="https://github.com/getgridea/gridea/releases/latest">
<img src="https://img.shields.io/github/release/getgridea/gridea.svg?style=flat-square" alt="">
</a>
<a href="https://github.com/getgridea/gridea/blob/master/LICENSE">
<img src="https://img.shields.io/github/license/getgridea/gridea.svg?style=flat-square" alt="">
</a>
<a href="https://github.com/getgridea/gridea/releases/latest">
<img alt="GitHub All Releases" src="https://img.shields.io/github/downloads/getgridea/gridea/total.svg?color=%2312b886&style=flat-square">
</a>
</div>
<div align="center">
<img src="gridea-app-en.png">
</div>
English | [Русский](https://github.com/getgridea/gridea/blob/master/README-ru.md) | [简体中文](https://github.com/getgridea/gridea/blob/master/README-zh_CN.md) | [繁體中文](https://github.com/getgridea/gridea/blob/master/README-zh_TW.md)
**[CHANGELOG](https://github.com/getgridea/gridea/blob/master/CHANGELOG.md)**
👏 Welcome to use **Gridea**!
✍️ **Gridea** A static blog writing client. You can use it to record your life, mood, knowledge, notes and ideas...
## Features👇
📝 Use the coolest **Markdown** editor to create quickly
🌉 Insert pictures and article cover charts anywhere in the article
🏷️ Label and group articles
📋 Customize menus and even create external link menus
💻 Use this client on **Windows** or **MacOS** or **Linux**
🌎 Use **Github Pages** or **Coding Pages** to show the world that more platforms will be supported in the future
💬 Simply configure and access the [Gitalk](https://github.com/gitalk/gitalk) or [DisqusJS](https://github.com/SukkaW/DisqusJS) comment system
🗺️ Use **simplified Chinese**、**traditional Chinese**、 **English**、 **Russian**、 **French**
🌁 Use any default theme within the application or any third-party theme, free theme customization
🖥 Customize the source folder and synchronize multiple devices using OneDrive, iCloud, Dropbox, etc.
🌱 Of course **Gridea** is still very young and has many shortcomings, but please believe it will keep moving forward 🏃
In the future, it will surely become your inseparable partner
Give full play to your talents!
😘 Enjoy~
## Development
If you want to contribute code, please check the [Contribution Guide](https://github.com/getgridea/gridea/wiki/%E8%B4%A1%E7%8C%AE%E6%8C%87%E5%8D%97) in advance.
``` shell
$ # Node version > v10.0.0 is requied
$ git clone https://github.com/getgridea/gridea.git
$ cd gridea
$ yarn
$ yarn electron:serve
$ yarn electron:build
```
## Contact
[Telegram Channel](https://t.me/joinchat/AAAAAEj82_lma0Y1wmyqUQ) | [Telegram Group](https://t.me/joinchat/IDY0ahRqb8NPodv95BNpBg) | QQ 1 Group: 970332209 | QQ 2 Group: 923131213 | Author Twitter: @EryouHao
## Example Screenshots
<div align="center">
<img src="./files/themes.png">
</div>
## Contributions
We welcome all contributions. You can submit any ideas as [pull requests](https://github.com/getgridea/gridea/pulls) or as GitHub [issues](https://github.com/getgridea/gridea/issues).
## Donation
<div>
<img src="./files/wechat.png" width="240px">
</div>
## License
[MIT](https://github.com/getgridea/gridea/blob/master/LICENSE). Copyright (c) 2020-2023 EryouHao
================================================
FILE: babel.config.js
================================================
module.exports = {
presets: [
'@vue/app',
],
plugins: [
['prismjs', {
'languages': ['javascript', 'css', 'markup', 'json', 'bash', 'sass', 'python', 'typescript', 'java', 'less', 'php', 'pug', 'jsx', 'c', 'ruby', 'rust', 'dart', 'stylus', 'swift', 'yaml', 'sql'],
'plugins': ['line-numbers'],
'theme': 'default',
'css': true,
}],
],
}
================================================
FILE: package.json
================================================
{
"name": "gridea",
"version": "0.9.3",
"private": true,
"description": "A static blog writing client. You can use it to record your life, mood, knowledge, notes and ideas...",
"keywords": [
"gridea",
"static-site",
"static-site-generator"
],
"homepage": "https://gridea.dev",
"license": "MIT",
"author": {
"name": "EryouHao",
"email": "eryouhao@gmail.com"
},
"repository": "https://github.com/getgridea/gridea",
"scripts": {
"electron:build": "vue-cli-service electron:build",
"electron:serve": "vue-cli-service electron:serve",
"postinstall": "electron-builder install-app-deps",
"lint": "vue-cli-service lint"
},
"dependencies": {
"@fontsource/noto-serif": "^4.5.9",
"@iktakahiro/markdown-it-katex": "^3.1.0",
"@sentry/electron": "^1.2.0",
"ant-design-vue": "^1.3.5",
"axios": "^0.27.2",
"bluebird": "^3.5.3",
"ejs": "^2.6.1",
"electron-google-analytics": "^0.1.0",
"electron-updater": "^4.2.0",
"feed": "^2.0.4",
"fs-extra": "^7.0.1",
"gray-matter": "^4.0.1",
"hpagent": "^1.0.0",
"isomorphic-git": "1.17.1",
"junk": "^3.1.0",
"katex": "0.12.0",
"less": "^3.9.0",
"lowdb": "^1.0.0",
"macaddress": "^0.2.9",
"markdown-it": "^13.0.1",
"markdown-it-abbr": "^1.0.4",
"markdown-it-emoji": "^2.0.2",
"markdown-it-footnote": "^3.0.3",
"markdown-it-image-lazy-loading": "^1.2.0",
"markdown-it-implicit-figures": "^0.9.0",
"markdown-it-imsize": "^2.0.1",
"markdown-it-mark": "^2.0.0",
"markdown-it-sub": "^1.0.0",
"markdown-it-sup": "^1.0.0",
"markdown-it-toc-and-anchor": "^4.2.0",
"moment": "^2.24.0",
"monaco-markdown": "^0.0.6",
"node-ssh": "^6.0.0",
"normalize-path": "^3.0.0",
"prismjs": "^1.16.0",
"remixicon": "2.3.0",
"shortid": "^2.2.14",
"simple-get": "^4.0.1",
"slug": "^0.9.3",
"ssh2-sftp-client": "^4.2.4",
"striptags": "^3.1.1",
"transliteration": "^1.6.6",
"url-join": "^4.0.1",
"uuid": "^3.3.3",
"v-emoji-picker": "^1.1.6",
"vee-validate": "^3.1.3",
"vue": "^2.6.10",
"vue-class-component": "^6.0.0",
"vue-i18n": "^8.7.0",
"vue-property-decorator": "^7.3.0",
"vue-router": "^3.0.1",
"vue-shortkey": "^3.1.7",
"vue2-transitions": "^0.2.3",
"vuedraggable": "^2.23.2",
"vuex": "^3.0.1",
"vuex-class": "^0.3.1"
},
"devDependencies": {
"@types/bluebird": "^3.5.26",
"@types/ejs": "^2.6.3",
"@types/express": "^4.17.0",
"@types/fs-extra": "^5.0.5",
"@types/less": "^3.0.0",
"@types/lowdb": "^1.0.7",
"@types/markdown-it": "0.0.7",
"@types/marked": "^0.6.5",
"@types/normalize-path": "^3.0.0",
"@types/prismjs": "^1.16.0",
"@types/shortid": "0.0.29",
"@types/slug": "^0.9.1",
"@types/ssh2-sftp-client": "^4.1.1",
"@types/url-join": "^4.0.0",
"@types/uuid": "^3.4.5",
"@vue/cli-plugin-babel": "^3.6.0",
"@vue/cli-plugin-eslint": "^3.6.0",
"@vue/cli-plugin-typescript": "^3.6.0",
"@vue/cli-service": "^3.6.0",
"@vue/eslint-config-airbnb": "^4.0.0",
"@vue/eslint-config-typescript": "^4.0.0",
"babel-eslint": "^10.0.1",
"babel-plugin-prismjs": "^1.0.2",
"electron": "^7.3.3",
"eslint": "^5.16.0",
"eslint-plugin-vue": "^5.2.2",
"husky": "^1.3.1",
"less-loader": "^4.1.0",
"lint-staged": "^8.1.5",
"markdown-it-task-lists": "^2.1.1",
"postcss-import": "^12.0.1",
"tailwindcss": "^1.1.4",
"typescript": "^3.0.0",
"vue-cli-plugin-electron-builder": "2.0.0-beta.2",
"vue-template-compiler": "^2.6.10"
},
"main": "background.js",
"engines": {
"node": ">=10.0.0"
},
"husky": {
"hooks": {
"pre-commit": "lint-staged"
}
},
"lint-staged": {
"*.{js,ts,tsx,vue}": [
"vue-cli-service lint",
"git add"
]
},
"__npminstall_done": false
}
================================================
FILE: postcss.config.js
================================================
module.exports = {
plugins: [
require('postcss-import'),
require('tailwindcss'),
require('autoprefixer'),
],
}
================================================
FILE: public/default-files/config/posts.json
================================================
{
"posts": [],
"tags": [],
"menus": [
{
"link": "/",
"name": "首页",
"openType": "Internal"
},
{
"link": "/archives",
"name": "归档",
"openType": "Internal"
},
{
"link": "/tags",
"name": "标签",
"openType": "Internal"
},
{
"link": "/post/about",
"name": "关于",
"openType": "Internal"
}
]
}
================================================
FILE: public/default-files/config/setting.json
================================================
{
"config": {
"platform": "github",
"domain": "",
"repository": "",
"branch": "",
"username": "",
"email": "",
"token": ""
},
"comment": {
"commentPlatform": "gitalk",
"disqusSetting": {
"api": "",
"apikey": "",
"shortname": ""
},
"gitalkSetting": {
"clientId": "",
"clientSecret": "",
"owner": "",
"repository": ""
},
"showComment": false
}
}
================================================
FILE: public/default-files/config/theme.json
================================================
{
"config": {
"footerInfo": "Powered by <a href=\"https://github.com/getgridea/gridea\" target=\"_blank\">Gridea</a>",
"postPageSize": 10,
"archivesPageSize": 50,
"showFeatureImage": true,
"siteDescription": "温故而知新",
"siteName": "Gridea",
"themeName": "notes",
"dateFormat": "YYYY-MM-DD",
"postUrlFormat": "SLUG",
"tagUrlFormat": "SHORT_ID",
"feedCount": 10,
"feedFullText": true
},
"customConfig": {}
}
================================================
FILE: public/default-files/post-images/.gitkeep
================================================
================================================
FILE: public/default-files/posts/about.md
================================================
---
title: 关于
date: 2019-01-25 19:09:48
tags:
published: true
hideInList: true
feature:
---
> 欢迎来到我的小站呀,很高兴遇见你!🤝
## 🏠 关于本站
## 👨💻 博主是谁
## ⛹ 兴趣爱好
## 📬 联系我呀
================================================
FILE: public/default-files/posts/hello-gridea.md
================================================
---
title: Hello Gridea
date: 2018-12-12
tags: [Gridea]
published: true
hideInList: false
feature: /post-images/hello-gridea.png
---
👏 欢迎使用 **Gridea** !
✍️ **Gridea** 一个静态博客写作客户端。你可以用它来记录你的生活、心情、知识、笔记、创意... ...
<!-- more -->
[Github](https://github.com/getgridea/gridea)
[Gridea 主页](https://gridea.dev/)
[示例网站](https://fehey.com/)
## 特性👇
📝 你可以使用最酷的 **Markdown** 语法,进行快速创作
🌉 你可以给文章配上精美的封面图和在文章任意位置插入图片
🏷️ 你可以对文章进行标签分组
📋 你可以自定义菜单,甚至可以创建外部链接菜单
💻 你可以在 **Windows**,**MacOS** 或 **Linux** 设备上使用此客户端
🌎 你可以使用 **𝖦𝗂𝗍𝗁𝗎𝖻 𝖯𝖺𝗀𝖾𝗌** 或 **Coding Pages** 向世界展示,未来将支持更多平台
💬 你可以进行简单的配置,接入 [Gitalk](https://github.com/gitalk/gitalk) 或 [DisqusJS](https://github.com/SukkaW/DisqusJS) 评论系统
🇬🇧 你可以使用**中文简体**或**英语**
🌁 你可以任意使用应用内默认主题或任意第三方主题,强大的主题自定义能力
🖥 你可以自定义源文件夹,利用 OneDrive、百度网盘、iCloud、Dropbox 等进行多设备同步
🌱 当然 **Gridea** 还很年轻,有很多不足,但请相信,它会不停向前 🏃
未来,它一定会成为你离不开的伙伴
尽情发挥你的才华吧!
😘 Enjoy~
================================================
FILE: public/default-files/static/404.html
================================================
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<title>Page Not Found</title>
<style>
* {
margin: 0;
padding: 0;
}
body {
display: flex;
flex-direction: column;
height: 100vh;
text-align: center;
}
.box {
flex: 1;
display: flex;
justify-content: center;
flex-direction: column;
}
.number {
font-size: 80px;
color: #666;
font-weight: bold;
}
.text {
font-size: 14px;
margin: 24px;
color: #333;
}
.btn-container {
display: flex;
justify-content: center;
}
.btn {
padding: 8px 24px;
display: inline-block;
text-decoration: none;
background: #fff;
border: 2px solid #efefef;
color: #333;
margin: 24px;
border-radius: 20px;
cursor: pointer;
display: flex;
align-items: center;
}
.footer {
padding: 16px;
border-top: 1px solid #efefef;
color: #777;
font-weight: lighter;
}
.footer a {
text-decoration: none;
font-weight: bold;
color: #000;
}
</style>
</head>
<body>
<div class="box">
<div class="number">4 0 4</div>
<div class="text">
Page not found
</div>
<div class="btn-container">
<a class="btn" id="back">
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="16" height="16" style="margin-right: 8px;">
<path fill="none" d="M0 0h24v24H0z"/>
<path d="M5.828 7l2.536 2.536L6.95 10.95 2 6l4.95-4.95 1.414 1.414L5.828 5H13a8 8 0 1 1 0 16H4v-2h9a6 6 0 1 0 0-12H5.828z"/>
</svg>
Back
</a>
</div>
</div>
<footer class="footer">
Powered by <a href="https://gridea.dev" target="_blank">Gridea</a>
</footer>
<script>
var back = document.getElementById('back')
back.onclick = function() { console.log('run...'); history.back() }
</script>
</body>
</html>
================================================
FILE: public/default-files/themes/fly/assets/styles/_blocks/archives.less
================================================
.archives-container {
padding: 32px 0;
.year {
font-size: 24px;
margin: 24px 0;
color: var(--c-base-purple);
}
.post {
margin-bottom: 32px;
.post-title {
font-size: 18px;
font-weight: normal;
position: relative;
transition: all 0.382s;
&:before {
content: '';
display: block;
width: 6px;
height: 6px;
border-radius: 50%;
background: var(--c-base-purple);
position: absolute;
left: 0px;
top: 50%;
transform: translateY(-50%);
opacity: 0;
transition: all 0.382s;
}
&:hover {
transform: translateX(8px);
&:before {
left: -8px;
opacity: 1;
}
}
}
}
}
================================================
FILE: public/default-files/themes/fly/assets/styles/_blocks/fonts.less
================================================
@font-face {
font-family: 'icomoon';
src: url('../media/fonts/icomoon.eot?pjaj8c');
src: url('../media/fonts/icomoon.eot?pjaj8c#iefix') format('embedded-opentype'),
url('../media/fonts/icomoon.ttf?pjaj8c') format('truetype'),
url('../media/fonts/icomoon.woff?pjaj8c') format('woff'),
url('../media/fonts/icomoon.svg?pjaj8c#icomoon') format('svg');
font-weight: normal;
font-style: normal;
}
[class^="icon-"], [class*=" icon-"] {
/* use !important to prevent issues with browser extensions that change fonts */
font-family: 'icomoon' !important;
speak: none;
font-style: normal;
font-weight: normal;
font-variant: normal;
text-transform: none;
line-height: 1;
/* Better Font Rendering =========== */
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
}
.icon-activity-outline:before {
content: "\e900";
}
.icon-alert-circle-outline:before {
content: "\e901";
}
.icon-alert-triangle-outline:before {
content: "\e902";
}
.icon-archive-outline:before {
content: "\e903";
}
.icon-arrow-back-outline:before {
content: "\e904";
}
.icon-arrow-circle-down-outline:before {
content: "\e905";
}
.icon-arrow-circle-left-outline:before {
content: "\e906";
}
.icon-arrow-circle-right-outline:before {
content: "\e907";
}
.icon-arrow-circle-up-outline:before {
content: "\e908";
}
.icon-arrow-down-outline:before {
content: "\e909";
}
.icon-arrow-downward-outline:before {
content: "\e90a";
}
.icon-arrow-forward-outline:before {
content: "\e90b";
}
.icon-arrow-ios-back-outline:before {
content: "\e90c";
}
.icon-arrow-ios-downward-outline:before {
content: "\e90d";
}
.icon-arrow-ios-forward-outline:before {
content: "\e90e";
}
.icon-arrow-ios-upward-outline:before {
content: "\e90f";
}
.icon-arrow-left-outline:before {
content: "\e910";
}
.icon-arrow-right-outline:before {
content: "\e911";
}
.icon-arrow-up-outline:before {
content: "\e912";
}
.icon-arrow-upward-outline:before {
content: "\e913";
}
.icon-arrowhead-down-outline:before {
content: "\e914";
}
.icon-arrowhead-left-outline:before {
content: "\e915";
}
.icon-arrowhead-right-outline:before {
content: "\e916";
}
.icon-arrowhead-up-outline:before {
content: "\e917";
}
.icon-at-outline:before {
content: "\e918";
}
.icon-attach-2-outline:before {
content: "\e919";
}
.icon-attach-outline:before {
content: "\e91a";
}
.icon-award-outline:before {
content: "\e91b";
}
.icon-backspace-outline:before {
content: "\e91c";
}
.icon-bar-chart-2-outline:before {
content: "\e91d";
}
.icon-bar-chart-outline:before {
content: "\e91e";
}
.icon-battery-outline:before {
content: "\e91f";
}
.icon-behance-outline:before {
content: "\e920";
}
.icon-bell-off-outline:before {
content: "\e921";
}
.icon-bell-outline:before {
content: "\e922";
}
.icon-bluetooth-outline:before {
content: "\e923";
}
.icon-book-open-outline:before {
content: "\e924";
}
.icon-book-outline:before {
content: "\e925";
}
.icon-bookmark-outline:before {
content: "\e926";
}
.icon-briefcase-outline:before {
content: "\e927";
}
.icon-browser-outline:before {
content: "\e928";
}
.icon-brush-outline:before {
content: "\e929";
}
.icon-bulb-outline:before {
content: "\e92a";
}
.icon-calendar-outline:before {
content: "\e92b";
}
.icon-camera-outline:before {
content: "\e92c";
}
.icon-car-outline:before {
content: "\e92d";
}
.icon-cast-outline:before {
content: "\e92e";
}
.icon-charging-outline:before {
content: "\e92f";
}
.icon-checkmark-circle-2-outline:before {
content: "\e930";
}
.icon-checkmark-circle-outline:before {
content: "\e931";
}
.icon-checkmark-outline:before {
content: "\e932";
}
.icon-checkmark-square-2-outline:before {
content: "\e933";
}
.icon-checkmark-square-outline:before {
content: "\e934";
}
.icon-chevron-down-outline:before {
content: "\e935";
}
.icon-chevron-left-outline:before {
content: "\e936";
}
.icon-chevron-right-outline:before {
content: "\e937";
}
.icon-chevron-up-outline:before {
content: "\e938";
}
.icon-clipboard-outline:before {
content: "\e939";
}
.icon-clock-outline:before {
content: "\e93a";
}
.icon-close-circle-outline:before {
content: "\e93b";
}
.icon-close-outline:before {
content: "\e93c";
}
.icon-close-square-outline:before {
content: "\e93d";
}
.icon-cloud-download-outline:before {
content: "\e93e";
}
.icon-cloud-upload-outline:before {
content: "\e93f";
}
.icon-code-download-outline:before {
content: "\e940";
}
.icon-code-outline:before {
content: "\e941";
}
.icon-collapse-outline:before {
content: "\e942";
}
.icon-color-palette-outline:before {
content: "\e943";
}
.icon-color-picker-outline:before {
content: "\e944";
}
.icon-compass-outline:before {
content: "\e945";
}
.icon-copy-outline:before {
content: "\e946";
}
.icon-corner-down-left-outline:before {
content: "\e947";
}
.icon-corner-down-right-outline:before {
content: "\e948";
}
.icon-corner-left-down-outline:before {
content: "\e949";
}
.icon-corner-left-up-outline:before {
content: "\e94a";
}
.icon-corner-right-down-outline:before {
content: "\e94b";
}
.icon-corner-right-up-outline:before {
content: "\e94c";
}
.icon-corner-up-left-outline:before {
content: "\e94d";
}
.icon-corner-up-right-outline:before {
content: "\e94e";
}
.icon-credit-card-outline:before {
content: "\e94f";
}
.icon-crop-outline:before {
content: "\e950";
}
.icon-cube-outline:before {
content: "\e951";
}
.icon-diagonal-arrow-left-down-outline:before {
content: "\e952";
}
.icon-diagonal-arrow-left-up-outline:before {
content: "\e953";
}
.icon-diagonal-arrow-right-down-outline:before {
content: "\e954";
}
.icon-diagonal-arrow-right-up-outline:before {
content: "\e955";
}
.icon-done-all-outline:before {
content: "\e956";
}
.icon-download-outline:before {
content: "\e957";
}
.icon-droplet-off-outline:before {
content: "\e958";
}
.icon-droplet-outline:before {
content: "\e959";
}
.icon-edit-2-outline:before {
content: "\e95a";
}
.icon-edit-outline:before {
content: "\e95b";
}
.icon-email-outline:before {
content: "\e95c";
}
.icon-expand-outline:before {
content: "\e95d";
}
.icon-external-link-outline:before {
content: "\e95e";
}
.icon-eye-off-2-outline:before {
content: "\e95f";
}
.icon-eye-off-outline:before {
content: "\e960";
}
.icon-eye-outline:before {
content: "\e961";
}
.icon-facebook-outline:before {
content: "\e962";
}
.icon-file-add-outline:before {
content: "\e963";
}
.icon-file-outline:before {
content: "\e964";
}
.icon-file-remove-outline:before {
content: "\e965";
}
.icon-file-text-outline:before {
content: "\e966";
}
.icon-film-outline:before {
content: "\e967";
}
.icon-flag-outline:before {
content: "\e968";
}
.icon-flash-off-outline:before {
content: "\e969";
}
.icon-flash-outline:before {
content: "\e96a";
}
.icon-flip-2-outline:before {
content: "\e96b";
}
.icon-flip-outline:before {
content: "\e96c";
}
.icon-folder-add-outline:before {
content: "\e96d";
}
.icon-folder-outline:before {
content: "\e96e";
}
.icon-folder-remove-outline:before {
content: "\e96f";
}
.icon-funnel-outline:before {
content: "\e970";
}
.icon-gift-outline:before {
content: "\e971";
}
.icon-github-outline:before {
content: "\e972";
}
.icon-globe-2-outline:before {
content: "\e973";
}
.icon-globe-outline:before {
content: "\e974";
}
.icon-google-outline:before {
content: "\e975";
}
.icon-grid-outline:before {
content: "\e976";
}
.icon-hard-drive-outline:before {
content: "\e977";
}
.icon-hash-outline:before {
content: "\e978";
}
.icon-headphones-outline:before {
content: "\e979";
}
.icon-heart-outline:before {
content: "\e97a";
}
.icon-home-outline:before {
content: "\e97b";
}
.icon-image-outline:before {
content: "\e97c";
}
.icon-inbox-outline:before {
content: "\e97d";
}
.icon-info-outline:before {
content: "\e97e";
}
.icon-keypad-outline:before {
content: "\e97f";
}
.icon-layers-outline:before {
content: "\e980";
}
.icon-layout-outline:before {
content: "\e981";
}
.icon-link-2-outline:before {
content: "\e982";
}
.icon-link-outline:before {
content: "\e983";
}
.icon-linkedin-outline:before {
content: "\e984";
}
.icon-list-outline:before {
content: "\e985";
}
.icon-loader-outline:before {
content: "\e986";
}
.icon-lock-outline:before {
content: "\e987";
}
.icon-log-in-outline:before {
content: "\e988";
}
.icon-log-out-outline:before {
content: "\e989";
}
.icon-map-outline:before {
content: "\e98a";
}
.icon-maximize-outline:before {
content: "\e98b";
}
.icon-menu-2-outline:before {
content: "\e98c";
}
.icon-menu-arrow-outline:before {
content: "\e98d";
}
.icon-menu-outline:before {
content: "\e98e";
}
.icon-message-circle-outline:before {
content: "\e98f";
}
.icon-message-square-outline:before {
content: "\e990";
}
.icon-mic-off-outline:before {
content: "\e991";
}
.icon-mic-outline:before {
content: "\e992";
}
.icon-minimize-outline:before {
content: "\e993";
}
.icon-minus-circle-outline:before {
content: "\e994";
}
.icon-minus-outline:before {
content: "\e995";
}
.icon-minus-square-outline:before {
content: "\e996";
}
.icon-monitor-outline:before {
content: "\e997";
}
.icon-moon-outline:before {
content: "\e998";
}
.icon-more-horizontal-outline:before {
content: "\e999";
}
.icon-more-vertical-outline:before {
content: "\e99a";
}
.icon-move-outline:before {
content: "\e99b";
}
.icon-music-outline:before {
content: "\e99c";
}
.icon-navigation-2-outline:before {
content: "\e99d";
}
.icon-navigation-outline:before {
content: "\e99e";
}
.icon-npm-outline:before {
content: "\e99f";
}
.icon-options-2-outline:before {
content: "\e9a0";
}
.icon-options-outline:before {
content: "\e9a1";
}
.icon-pantone-outline:before {
content: "\e9a2";
}
.icon-paper-plane-outline:before {
content: "\e9a3";
}
.icon-pause-circle-outline:before {
content: "\e9a4";
}
.icon-people-outline:before {
content: "\e9a5";
}
.icon-percent-outline:before {
content: "\e9a6";
}
.icon-person-add-outline:before {
content: "\e9a7";
}
.icon-person-delete-outline:before {
content: "\e9a8";
}
.icon-person-done-outline:before {
content: "\e9a9";
}
.icon-person-outline:before {
content: "\e9aa";
}
.icon-person-remove-outline:before {
content: "\e9ab";
}
.icon-phone-call-outline:before {
content: "\e9ac";
}
.icon-phone-missed-outline:before {
content: "\e9ad";
}
.icon-phone-off-outline:before {
content: "\e9ae";
}
.icon-phone-outline:before {
content: "\e9af";
}
.icon-pie-chart-outline:before {
content: "\e9b0";
}
.icon-pin-outline:before {
content: "\e9b1";
}
.icon-play-circle-outline:before {
content: "\e9b2";
}
.icon-plus-circle-outline:before {
content: "\e9b3";
}
.icon-plus-outline:before {
content: "\e9b4";
}
.icon-plus-square-outline:before {
content: "\e9b5";
}
.icon-power-outline:before {
content: "\e9b6";
}
.icon-pricetags-outline:before {
content: "\e9b7";
}
.icon-printer-outline:before {
content: "\e9b8";
}
.icon-question-mark-circle-outline:before {
content: "\e9b9";
}
.icon-question-mark-outline:before {
content: "\e9ba";
}
.icon-radio-button-off-outline:before {
content: "\e9bb";
}
.icon-radio-button-on-outline:before {
content: "\e9bc";
}
.icon-radio-outline:before {
content: "\e9bd";
}
.icon-recording-outline:before {
content: "\e9be";
}
.icon-refresh-outline:before {
content: "\e9bf";
}
.icon-repeat-outline:before {
content: "\e9c0";
}
.icon-rewind-left-outline:before {
content: "\e9c1";
}
.icon-rewind-right-outline:before {
content: "\e9c2";
}
.icon-save-outline:before {
content: "\e9c3";
}
.icon-scissors-outline:before {
content: "\e9c4";
}
.icon-search-outline:before {
content: "\e9c5";
}
.icon-settings-2-outline:before {
content: "\e9c6";
}
.icon-settings-outline:before {
content: "\e9c7";
}
.icon-shake-outline:before {
content: "\e9c8";
}
.icon-share-outline:before {
content: "\e9c9";
}
.icon-shield-off-outline:before {
content: "\e9ca";
}
.icon-shield-outline:before {
content: "\e9cb";
}
.icon-shopping-bag-outline:before {
content: "\e9cc";
}
.icon-shopping-cart-outline:before {
content: "\e9cd";
}
.icon-shuffle-2-outline:before {
content: "\e9ce";
}
.icon-shuffle-outline:before {
content: "\e9cf";
}
.icon-skip-back-outline:before {
content: "\e9d0";
}
.icon-skip-forward-outline:before {
content: "\e9d1";
}
.icon-slash-outline:before {
content: "\e9d2";
}
.icon-smartphone-outline:before {
content: "\e9d3";
}
.icon-speaker-outline:before {
content: "\e9d4";
}
.icon-square-outline:before {
content: "\e9d5";
}
.icon-star-outline:before {
content: "\e9d6";
}
.icon-stop-circle-outline:before {
content: "\e9d7";
}
.icon-sun-outline:before {
content: "\e9d8";
}
.icon-swap-outline:before {
content: "\e9d9";
}
.icon-sync-outline:before {
content: "\e9da";
}
.icon-text-outline:before {
content: "\e9db";
}
.icon-thermometer-minus-outline:before {
content: "\e9dc";
}
.icon-thermometer-outline:before {
content: "\e9dd";
}
.icon-thermometer-plus-outline:before {
content: "\e9de";
}
.icon-toggle-left-outline:before {
content: "\e9df";
}
.icon-toggle-right-outline:before {
content: "\e9e0";
}
.icon-trash-2-outline:before {
content: "\e9e1";
}
.icon-trash-outline:before {
content: "\e9e2";
}
.icon-trending-down-outline:before {
content: "\e9e3";
}
.icon-trending-up-outline:before {
content: "\e9e4";
}
.icon-tv-outline:before {
content: "\e9e5";
}
.icon-twitter-outline:before {
content: "\e9e6";
}
.icon-umbrella-outline:before {
content: "\e9e7";
}
.icon-undo-outline:before {
content: "\e9e8";
}
.icon-unlock-outline:before {
content: "\e9e9";
}
.icon-upload-outline:before {
content: "\e9ea";
}
.icon-video-off-outline:before {
content: "\e9eb";
}
.icon-video-outline:before {
content: "\e9ec";
}
.icon-volume-down-outline:before {
content: "\e9ed";
}
.icon-volume-mute-outline:before {
content: "\e9ee";
}
.icon-volume-off-outline:before {
content: "\e9ef";
}
.icon-volume-up-outline:before {
content: "\e9f0";
}
.icon-wifi-off-outline:before {
content: "\e9f1";
}
.icon-wifi-outline:before {
content: "\e9f2";
}
================================================
FILE: public/default-files/themes/fly/assets/styles/_blocks/footer.less
================================================
.site-footer {
text-align: center;
font-size: 12px;
padding: 32px 16px;
.slogan {
margin-bottom: 24px;
}
.social-container {
margin-bottom: 24px;
font-size: 16px;
a {
margin: 0 8px;
}
}
}
================================================
FILE: public/default-files/themes/fly/assets/styles/_blocks/header.less
================================================
.site-header-container {
position: fixed;
right: 0;
left: 0;
z-index: 1024;
background: #fff;
height: 56px;
}
.site-header {
height: 56px;
padding: 0 16px;
display: flex;
align-items: center;
justify-content: space-between;
max-width: 768px;
margin: 0 auto;
box-shadow: inset 0px -1px 0px #fafafa;
.left {
display: flex;
.avatar {
border-radius: 50%;
}
.site-title {
margin: 0 16px;
font-size: 24px;
line-height: 32px;
}
}
.right {
.icon {
font-size: 24px;
cursor: pointer;
}
}
}
.menu-container {
display: none;
position: fixed;
top: 56px;
left: 0;
right: 0;
bottom: 0;
background: #fff;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
z-index: 1024;
.menu-list {
display: inline-flex;
flex-direction: column;
align-items: center;
justify-content: center;
margin-top: -40px;
}
.menu {
display: inline-block;
padding: 2px 8px;
font-size: 22px;
margin: 16px 0;
font-weight: bold;
}
}
.fade-enter-active, .fade-leave-active {
transition: opacity .5s;
}
.fade-enter, .fade-leave-to /* .fade-leave-active below version 2.1.8 */ {
opacity: 0;
}
================================================
FILE: public/default-files/themes/fly/assets/styles/_blocks/link.less
================================================
a,
.link {
color: var(--c-base-black);
text-decoration: none;
cursor: pointer;
background: transparent 0 0;
&:hover,
&:focus {
// text-decoration: underline;
}
&:hover,
&:focus,
&:active {
outline: 0;
}
}
a.purple-link {
position: relative;
background: linear-gradient(180deg,transparent 70%,rgba(101,125,225,.4) 0);
}
================================================
FILE: public/default-files/themes/fly/assets/styles/_blocks/list.less
================================================
.main {
max-width: 768px;
margin: 0 auto;
display: flex;
min-height: 100vh;
flex-direction: column;
}
.content-container {
flex: 1;
padding: 48px 16px 32px;
}
.post-item {
display: flex;
justify-content: space-between;
padding: 32px 0;
max-height: 200px;
.content {
flex: 1;
// display: flex;
// flex-direction: column;
.post-title {
font-size: 22px;
color: #0C1E29;
display: inline-block;
}
.post-abstract {
font-size: 14px;
margin: 16px 0 8px;
flex: 1;
color: #4E616C;
overflow:hidden;
line-height: 24px;
position: relative;
display: -webkit-box;
overflow: hidden;
-webkit-line-clamp: 3;
-webkit-box-orient: vertical;
// &:after {
// content: '';
// position: absolute;
// bottom: 0;
// right: 0;
// width: 120px;
// height: 32px;
// /* "transparent" only works here because == rgba(0,0,0,0) */
// background-image: linear-gradient(to right, transparent, white);
// }
strong {
font-weight: bolder;
}
a {
font-weight: 600;
background: linear-gradient(180deg,transparent 70%,rgba(101,125,225,.4) 0);
}
code {
padding: 0 3px;
margin: 0 2px;
background: rgba(195,195,195,0.41);
font-size: 0.9em;
border-radius: 2px;
}
}
}
.feature-container {
margin-left: 16px;
flex-shrink: 0;
width: 240px;
height: 135px;
position: relative;
overflow: hidden;
background-size: cover;
background-position: center;
}
}
.post-info {
color: var(--c-base-purple);
font-size: 12px;
span {
margin-right: 16px;
}
.icon {
font-size: 12px;
margin-right: 4px;
}
a {
color: var(--c-base-purple);
}
}
@media (max-width: 600px) {
.post-item {
flex-direction: column;
height: auto;
padding: 24px 0;
max-height: none;
.content {
order: 2;
display: block;
.post-title {
margin-top: 16px;
font-size: 18px;
}
}
.feature-container {
margin-left: 0;
order: 1;
height: 0;
width: 100%;
padding-top: 56%;
position: relative;
background-size: cover;
background-position: center;
// .feature {
// width: 100%;
// height: 100%;
// position: absolute;
// top: 0;
// left: 0;
// right: 0;
// bottom: 0;
// }
}
}
}
================================================
FILE: public/default-files/themes/fly/assets/styles/_blocks/pagination.less
================================================
.pagination-container {
padding: 24px 0;
overflow: hidden;
.prev, .next {
display: flex;
align-items: center;
padding: 2px 8px;
background: linear-gradient(180deg,transparent 70%,rgba(101,125,225,.4) 0);
}
.prev {
float: left;
}
.next {
float: right;
}
}
================================================
FILE: public/default-files/themes/fly/assets/styles/_blocks/post.less
================================================
.post-detail {
padding: 32px 0;
.post-title {
font-size: 32px;
margin: 24px 0;
color: var(--c-base-black);
}
.post-detail-info {
padding: 0 0 32px;
}
.feature-container {
padding-top: 56.25%;
background-size: cover;
background-position: center;
border-radius: 2px;
box-shadow: 0 0 30px #eee;
}
}
.next-post {
text-align: center;
.post-title {
display: inline-block;
font-size: 22px;
}
}
.post-content {
h1, h2, h3, h4, h5, h6 {
padding: 16px 0;
color: #0C1E29;
}
a {
font-weight: 600;
background: linear-gradient(180deg,transparent 70%,rgba(101,125,225,.4) 0);
}
img {
display: block;
box-shadow: 0 0 30px #eee;
max-width: 100%;
border-radius: 2px;
margin: 16px auto;
}
p {
line-height: 1.725;
margin-bottom: 16px;
color: var(--c-base-blacklight);
code {
padding: 0 3px;
margin: 0 2px;
background: rgba(195,195,195,0.41);
font-size: 0.9em;
border-radius: 2px;
display: inline-block;
}
}
code {
color: #476582;
padding: .25rem .5rem;
margin: 0;
font-size: .85em;
background-color: rgba(27,31,35,.05);
border-radius: 3px;
display: inline-block;
}
blockquote {
background: #f3f5f7;
padding: 16px;
border-left: 2px solid var(--c-base-purple);
margin-bottom: 16px;
p {
margin-bottom: 0;
}
}
pre {
margin-bottom: 16px;
code {
font-size: 14px;
font-family: 'Source Code Pro', Consolas, Menlo, Monaco, 'Courier New', monospace;
padding: 2em 1em 1em;
border-radius: 5px;
line-height: 1.375;
position: relative;
background: #fafafa;
display: block;
&:after {
content: 'CODE';
display: block;
position: absolute;
left: 8px;
top: 4px;
font-size: 14px;
font-weight: bold;
color: #ccc;
}
}
}
table {
border-collapse: collapse;
margin: 1rem 0;
display: block;
overflow-x: auto;
}
tr {
border-top: 1px solid #dfe2e5;
}
td, th {
border: 1px solid #dfe2e5;
padding: .6em 1em;
}
ul, ol {
color: var(--c-base-blacklight);
padding-left: 24px;
line-height: 1.725;
margin-bottom: 16px;
}
strong {
font-weight: bolder;
}
}
================================================
FILE: public/default-files/themes/fly/assets/styles/_blocks/tag.less
================================================
.current-tag-container {
padding-top: 32px;
color: var(--c-base-purple);
}
================================================
FILE: public/default-files/themes/fly/assets/styles/_blocks/tags.less
================================================
.tags-container {
padding: 32px 0;
.tag {
color: var(--c-base-purple);
padding: 4px 8px;
display: inline-block;
border: 2px solid var(--c-base-purple);
margin: 0 16px 16px 0;
border-radius: 16px;
}
}
================================================
FILE: public/default-files/themes/fly/assets/styles/_core/base.less
================================================
/*! modern-normalize | MIT License | https://github.com/sindresorhus/modern-normalize */
/* Document
========================================================================== */
/**
* Use a better box model (opinionated).
*/
html {
box-sizing: border-box;
}
*,
*::before,
*::after {
box-sizing: inherit;
margin: 0;
padding: 0;
}
/**
* Use a more readable tab size (opinionated).
*/
:root {
-moz-tab-size: 4;
tab-size: 4;
}
/**
* 1. Correct the line height in all browsers.
* 2. Prevent adjustments of font size after orientation changes in iOS.
*/
html {
line-height: 1.15; /* 1 */
-webkit-text-size-adjust: 100%; /* 2 */
}
/* Sections
========================================================================== */
/**
* Remove the margin in all browsers.
*/
body {
margin: 0;
font-size: 16px;
}
/**
* Improve consistency of default fonts in all browsers. (https://github.com/sindresorhus/modern-normalize/issues/3)
*/
body {
font-family:
-apple-system,
BlinkMacSystemFont,
'Segoe UI',
Roboto,
"PingFang SC",
"Hiragino Sans GB",
"Microsoft YaHei",
Helvetica,
Arial,
sans-serif,
'Apple Color Emoji',
'Segoe UI Emoji',
'Segoe UI Symbol';
}
/* Grouping content
========================================================================== */
/**
* Add the correct height in Firefox.
*/
hr {
height: 0;
}
/* Text-level semantics
========================================================================== */
/**
* Add the correct text decoration in Chrome, Edge, and Safari.
*/
abbr[title] {
text-decoration: underline dotted;
}
/**
* Add the correct font weight in Chrome, Edge, and Safari.
*/
b,
strong {
font-weight: bolder;
}
/**
* 1. Improve consistency of default fonts in all browsers. (https://github.com/sindresorhus/modern-normalize/issues/3)
* 2. Correct the odd `em` font sizing in all browsers.
*/
code,
kbd,
samp,
pre {
font-family: SFMono-Regular, Consolas, 'Liberation Mono', Menlo, Courier, monospace; /* 1 */
font-size: 1em; /* 2 */
}
/**
* Add the correct font size in all browsers.
*/
small {
font-size: 80%;
}
/**
* Prevent `sub` and `sup` elements from affecting the line height in all browsers.
*/
sub,
sup {
font-size: 75%;
line-height: 0;
position: relative;
vertical-align: baseline;
}
sub {
bottom: -0.25em;
}
sup {
top: -0.5em;
}
/* Forms
========================================================================== */
/**
* 1. Change the font styles in all browsers.
* 2. Remove the margin in Firefox and Safari.
*/
button,
input,
optgroup,
select,
textarea {
font-family: inherit; /* 1 */
font-size: 100%; /* 1 */
line-height: 1.15; /* 1 */
margin: 0; /* 2 */
}
/**
* Remove the inheritance of text transform in Edge and Firefox.
* 1. Remove the inheritance of text transform in Firefox.
*/
button,
select { /* 1 */
text-transform: none;
}
/**
* Correct the inability to style clickable types in iOS and Safari.
*/
button,
[type='button'],
[type='reset'],
[type='submit'] {
-webkit-appearance: button;
}
/**
* Remove the inner border and padding in Firefox.
*/
button::-moz-focus-inner,
[type='button']::-moz-focus-inner,
[type='reset']::-moz-focus-inner,
[type='submit']::-moz-focus-inner {
border-style: none;
padding: 0;
}
/**
* Restore the focus styles unset by the previous rule.
*/
button:-moz-focusring,
[type='button']:-moz-focusring,
[type='reset']:-moz-focusring,
[type='submit']:-moz-focusring {
outline: 1px dotted ButtonText;
}
/**
* Correct the padding in Firefox.
*/
fieldset {
padding: 0.35em 0.75em 0.625em;
}
/**
* Remove the padding so developers are not caught out when they zero out `fieldset` elements in all browsers.
*/
legend {
padding: 0;
}
/**
* Add the correct vertical alignment in Chrome and Firefox.
*/
progress {
vertical-align: baseline;
}
/**
* Correct the cursor style of increment and decrement buttons in Safari.
*/
[type='number']::-webkit-inner-spin-button,
[type='number']::-webkit-outer-spin-button {
height: auto;
}
/**
* 1. Correct the odd appearance in Chrome and Safari.
* 2. Correct the outline style in Safari.
*/
[type='search'] {
-webkit-appearance: textfield; /* 1 */
outline-offset: -2px; /* 2 */
}
/**
* Remove the inner padding in Chrome and Safari on macOS.
*/
[type='search']::-webkit-search-decoration {
-webkit-appearance: none;
}
/**
* 1. Correct the inability to style clickable types in iOS and Safari.
* 2. Change font properties to `inherit` in Safari.
*/
::-webkit-file-upload-button {
-webkit-appearance: button; /* 1 */
font: inherit; /* 2 */
}
/* Interactive
========================================================================== */
/*
* Add the correct display in Chrome and Safari.
*/
summary {
display: list-item;
}
================================================
FILE: public/default-files/themes/fly/assets/styles/_core/colors.less
================================================
:root {
--c-base-black: #0C1E29;
--c-base-blacklight: #4E616C;
--c-base-purple: #5978F3;
--c-base-purplelight: #C2CCF2;
--c-base-bluelight: hwb(199, 1%, 4%);
--c-base-blue: hwb(209, 0%, 35%);
--c-base-green: hwb(123, 40%, 27%);
--c-base-graylight: hwb(0, 80%, 20%);
--c-base-gray: hwb(0, 60%, 40%);
--c-base-orange: hwb(22, 21%, 5%);
--c-base-red: hwb(5, 24%, 9%);
--c-base-white: hwb(0, 95%, 5%);
--c-base-yellow: hwb(48, 6%, 5%);
}
================================================
FILE: public/default-files/themes/fly/assets/styles/_core/github.less
================================================
.hljs {
display: block;
overflow-x: auto;
padding: 0.5em;
color: #333;
background: #f8f8f8;
}
.hljs-comment,
.hljs-quote {
color: #998;
font-style: italic;
}
.hljs-keyword,
.hljs-selector-tag,
.hljs-subst {
color: #333;
font-weight: bold;
}
.hljs-number,
.hljs-literal,
.hljs-variable,
.hljs-template-variable,
.hljs-tag .hljs-attr {
color: #008080;
}
.hljs-string,
.hljs-doctag {
color: #d14;
}
.hljs-title,
.hljs-section,
.hljs-selector-id {
color: #900;
font-weight: bold;
}
.hljs-subst {
font-weight: normal;
}
.hljs-type,
.hljs-class .hljs-title {
color: #458;
font-weight: bold;
}
.hljs-tag,
.hljs-name,
.hljs-attribute {
color: #000080;
font-weight: normal;
}
.hljs-regexp,
.hljs-link {
color: #009926;
}
.hljs-symbol,
.hljs-bullet {
color: #990073;
}
.hljs-built_in,
.hljs-builtin-name {
color: #0086b3;
}
.hljs-meta {
color: #999;
font-weight: bold;
}
.hljs-deletion {
background: #fdd;
}
.hljs-addition {
background: #dfd;
}
.hljs-emphasis {
font-style: italic;
}
.hljs-strong {
font-weight: bold;
}
================================================
FILE: public/default-files/themes/fly/assets/styles/main.less
================================================
@import "_core/colors";
@import "_core/base";
@import "_core/github";
@import "_blocks/fonts";
@import "_blocks/footer";
@import "_blocks/header";
@import "_blocks/link";
@import "_blocks/list";
@import "_blocks/pagination";
@import "_blocks/post";
@import "_blocks/tag";
@import "_blocks/archives";
@import "_blocks/tags";
================================================
FILE: public/default-files/themes/fly/config.json
================================================
{
"name": "Fly",
"version": "1.0.0",
"author": "EryouHao",
"repository": "https://github.com/getgridea/gridea-theme-fly",
"customConfig": [
{
"name": "skin",
"label": "皮肤",
"group": "皮肤",
"value": "white",
"type": "select",
"options": [
{
"label": "简约白",
"value": "white"
},
{
"label": "低调黑",
"value": "black"
}
]
},
{
"name": "contentMaxWidth",
"label": "内容区最大宽度",
"group": "布局",
"value": "800px",
"type": "input",
"note": "可填像素类型(如:320px)或百分比类型(如:38.2%)"
},
{
"name": "textSize",
"label": "正文内容文字大小",
"group": "布局",
"value": "16px",
"type": "input",
"note": "px 或 rem(如 16px 或 1rem)"
},
{
"name": "github",
"label": "Github",
"group": "社交",
"value": "",
"type": "input",
"note": "链接地址"
},
{
"name": "twitter",
"label": "Twitter",
"group": "社交",
"value": "",
"type": "input",
"note": "链接地址"
},
{
"name": "weibo",
"label": "微博",
"group": "社交",
"value": "",
"type": "input",
"note": "链接地址"
},
{
"name": "zhihu",
"label": "知乎",
"group": "社交",
"value": "",
"type": "input",
"note": "链接地址"
},
{
"name": "facebook",
"label": "Facebook",
"group": "社交",
"value": "",
"type": "input",
"note": "链接地址"
},
{
"name": "customCss",
"label": "自定义CSS",
"group": "自定义样式",
"value": "",
"type": "textarea",
"note": ""
},
{
"name": "ga",
"label": "跟踪 ID",
"group": "谷歌统计",
"value": "",
"type": "input",
"note": "UA-xxxxxxxxx-x"
}
]
}
================================================
FILE: public/default-files/themes/fly/style-override.js
================================================
const generateOverride = (params = {}) => {
let result = ''
// 暗黑皮肤
if (params.skin && params.skin !== 'white') {
result += `
body {
color: #dee2e6;
}
body, .site-header-container, .menu-container {
background: #212529;
}
a, .link {
color: #e9ecef;
}
.site-header {
box-shadow: inset 0px -1px 0px #495057;
}
.post-item .content .post-title {
color: #e9ecef;
}
.post-item .content .post-abstract {
color: #868e96;
}
.post-info {
color: #495057;
}
.post-info a {
color: #5978f3;
}
a.purple-link, .post-content a {
background: linear-gradient(180deg, transparent 70%, #5978f3 0);
}
.post-detail .post-title {
color: #e9ecef;
}
.post-content p, .post-content table, .post-content ul, .post-content ol {
color: #dee2e6;
}
.post-content h1, .post-content h2, .post-content h3, .post-content h4, .post-content h5, .post-content h6 {
color: #e9ecef;
}
.post-detail .feature-container, .post-content img {
box-shadow: none;
}
.post-content blockquote {
background: #343a40;
border-left: 2px solid #5978f3;
}
.post-content code {
color: #e9ecef;
}
.post-content p code {
background: #495057;
}
.post-content pre code {
background: #000000;
}
.post-content pre code:after {
color: #495057;
}
.hljs-keyword, .hljs-selector-tag, .hljs-subst {
color: #d4bdbd;
}
.post-content tr {
border-top: 1px solid #495057;
}
.post-content td, .post-content th {
border: 1px solid #495057;
}
`
}
// 内容区最大宽度 - contentMaxWidth
if (params.contentMaxWidth && params.contentMaxWidth !== '800px') {
result += `
.main {
max-width: ${params.contentMaxWidth};
}
`
}
// 正文内容文字大小 - textSize
if (params.textSize && params.textSize !== '16px') {
result += `
body {
font-size: ${params.textSize};
}
`
}
if (params.customCss) {
result += `
${params.customCss}
`
}
console.log('result', result)
return result
}
module.exports = generateOverride
================================================
FILE: public/default-files/themes/fly/templates/archives.ejs
================================================
<html>
<head>
<%- include('./includes/head', { siteTitle: themeConfig.siteName }) %>
</head>
<body>
<div id="app" class="main">
<%- include('./includes/header') %>
<div class="content-container">
<%- include('./includes/post-list-archives') %>
</div>
<%- include('./includes/footer') %>
</div>
<%- include('./includes/scripts') %>
</div>
</body>
</html>
================================================
FILE: public/default-files/themes/fly/templates/includes/footer.ejs
================================================
<div class="site-footer">
<div class="slogan"><%- themeConfig.siteDescription %></div>
<div class="social-container">
<% ['github', 'twitter', 'weibo', 'zhihu', 'facebook'].forEach((item) => { %>
<% if (site.customConfig[item]) { %>
<a href="<%= site.customConfig[item] %>" target="_blank">
<i class="fab fa-<%= item %>"></i>
</a>
<% } %>
<% }) %>
</div>
<%- themeConfig.footerInfo %> | <a class="rss" href="<%= themeConfig.domain %>/atom.xml" target="_blank">RSS</a>
</div>
================================================
FILE: public/default-files/themes/fly/templates/includes/head.ejs
================================================
<meta charset="utf-8" >
<title><%= siteTitle %></title>
<meta name="description" content="<%= themeConfig.siteDescription %>">
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/animate.css/3.7.0/animate.min.css">
<link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.7.2/css/all.css" integrity="sha384-fnmOCqbTlWIlj8LyTjo7mOUStjsKC4pOpQbqyi7RrhN7udi9RwhKkMHpvLbHG9Sr" crossorigin="anonymous">
<link rel="shortcut icon" href="<%= themeConfig.domain %>/favicon.ico?v=<%= site.utils.now %>">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/KaTeX/0.10.0/katex.min.css">
<link rel="stylesheet" href="<%= themeConfig.domain %>/styles/main.css">
<% if (typeof commentSetting !== 'undefined' && commentSetting.showComment) { %>
<% if (commentSetting.commentPlatform === 'gitalk') { %>
<link rel="stylesheet" href="https://unpkg.com/gitalk/dist/gitalk.css" />
<% } %>
<% if (commentSetting.commentPlatform === 'disqus') { %>
<link rel="stylesheet" href="https://unpkg.com/disqusjs@1.1/dist/disqusjs.css" />
<% } %>
<% } %>
<script src="https://cdn.jsdelivr.net/npm/vue/dist/vue.js"></script>
<script src="//cdn.jsdelivr.net/gh/highlightjs/cdn-release@11.5.1/build/highlight.min.js"></script>
<% if (site.customConfig.ga) { %>
<script async src="https://www.googletagmanager.com/gtag/js?id=<%= site.customConfig.ga %>"></script>
<script>
window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);}
gtag('js', new Date());
gtag('config', '<%= site.customConfig.ga %>');
</script>
<% } %>
================================================
FILE: public/default-files/themes/fly/templates/includes/header.ejs
================================================
<div class="site-header-container">
<div class="site-header">
<div class="left">
<a href="<%= themeConfig.domain %>">
<img class="avatar" src="<%= themeConfig.domain %>/images/avatar.png?v=<%= site.utils.now %>" alt="" width="32px" height="32px">
</a>
<a href="<%= themeConfig.domain %>">
<h1 class="site-title"><%= themeConfig.siteName %></h1>
</a>
</div>
<div class="right">
<transition name="fade">
<i class="icon" :class="{ 'icon-close-outline': menuVisible, 'icon-menu-outline': !menuVisible }" @click="menuVisible = !menuVisible"></i>
</transition>
</div>
</div>
</div>
<transition name="fade">
<div class="menu-container" style="display: none;" v-show="menuVisible">
<div class="menu-list">
<% menus.forEach(function(menu) { %>
<% if (menu.openType === 'External') { %>
<a class="menu purple-link" href="<%= menu.link %>" class="menu" target="_blank">
<%= menu.name %>
</a>
<% } else { %>
<a href="<%= menu.link %>" class="menu purple-link">
<%= menu.name %>
</a>
<% } %>
<% }); %>
</div>
</div>
</transition>
================================================
FILE: public/default-files/themes/fly/templates/includes/post-list-archives.ejs
================================================
<% let years = []; posts.forEach((item) => { const year = item.date.substring(0, 4); if (!years.includes(year)) { years.push(year); } }); %>
<div class="archives-container">
<% years.forEach(function(year) { %>
<h2 class="year"><%- year %></h2>
<% posts.forEach(function(post) { %>
<%if (post.date.indexOf(year) !== -1) { %>
<article class="post">
<a href="<%= post.link %>">
<h2 class="post-title">
<%= post.title %>
<small><%= post.dateFormat %></small>
</h2>
</a>
</article>
<% } %>
<% }); %>
<% }); %>
</div>
================================================
FILE: public/default-files/themes/fly/templates/includes/post-list.ejs
================================================
<% posts.forEach(function(post) { %>
<section class="post-item">
<div class="content">
<a href="<%= post.link %>">
<h2 class="post-title"><%= post.title %></h2>
</a>
<div class="post-abstract">
<%- post.abstract %>
</div>
<div class="post-info">
<span><i class="icon icon-calendar-outline"></i> <%= post.dateFormat %></span>
<% if (post.tags.length > 0) { %>
<span>
<i class="icon icon-pricetags-outline"></i>
<% post.tags.forEach(function(tag, index) { %>
<a href="<%= tag.link %>">
<%= tag.name %>
<% if (index !== post.tags.length - 1) { %>
,
<% } %>
</a>
<% }); %>
</span>
<% } %>
</div>
</div>
<% if (themeConfig.showFeatureImage && post.feature) { %>
<a href="<%= post.link %>">
<div class="feature-container" style="background-image: url('<%= post.feature %>')">
</div>
</a>
<% } %>
</section>
<% }); %>
<div class="pagination-container">
<% if (pagination.prev) { %>
<a href="<%= pagination.prev %>" class="prev"><i class="icon-arrow-ios-back-outline"></i> 上一页</a>
<% } %>
<% if (pagination.next) { %>
<a href="<%= pagination.next %>" class="next">下一页 <i class="icon-arrow-ios-forward-outline"></i></a>
<% } %>
</div>
================================================
FILE: public/default-files/themes/fly/templates/includes/scripts.ejs
================================================
<script type="application/javascript">
hljs.initHighlightingOnLoad()
var app = new Vue({
el: '#app',
data: {
menuVisible: false,
},
})
</script>
<% if (typeof commentSetting !== 'undefined' && commentSetting.showComment) { %>
<% if (commentSetting.commentPlatform === 'gitalk') { %>
<script src="https://unpkg.com/gitalk/dist/gitalk.min.js"></script>
<script>
var gitalk = new Gitalk({
clientID: '<%= commentSetting.gitalkSetting.clientId %>',
clientSecret: '<%= commentSetting.gitalkSetting.clientSecret %>',
repo: '<%= commentSetting.gitalkSetting.repository %>',
owner: '<%= commentSetting.gitalkSetting.owner %>',
admin: ['<%= commentSetting.gitalkSetting.owner %>'],
id: (location.pathname).substring(0, 49), // Ensure uniqueness and length less than 50
distractionFreeMode: false // Facebook-like distraction free mode
})
gitalk.render('gitalk-container')
</script>
<% } %>
<% if (commentSetting.commentPlatform === 'disqus') { %>
<script src="https://unpkg.com/disqusjs@1.1/dist/disqus.js"></script>
<script>
var options = {
shortname: '<%= commentSetting.disqusSetting.shortname %>',
apikey: '<%= commentSetting.disqusSetting.apikey %>',
}
if ('<%= commentSetting.disqusSetting.api %>') {
options.api = '<%= commentSetting.disqusSetting.api %>'
}
var dsqjs = new DisqusJS(options)
</script>
<% } %>
<% } %>
================================================
FILE: public/default-files/themes/fly/templates/index.ejs
================================================
<html>
<head>
<%- include('./includes/head', { siteTitle: themeConfig.siteName }) %>
</head>
<body>
<div id="app" class="main">
<%- include('./includes/header') %>
<div class="content-container">
<%- include('./includes/post-list') %>
</div>
<%- include('./includes/footer') %>
</div>
<%- include('./includes/scripts') %>
</body>
</html>
================================================
FILE: public/default-files/themes/fly/templates/post.ejs
================================================
<!DOCTYPE html>
<html>
<head>
<%- include('./includes/head', { siteTitle: `${post.title} | ${themeConfig.siteName}` }) %>
</head>
<body>
<div id="app" class="main">
<%- include('./includes/header') %>
<div class="content-container">
<div class="post-detail">
<% if (themeConfig.showFeatureImage && post.feature) { %>
<div class="feature-container" style="background-image: url('<%= post.feature %>')">
</div>
<% } %>
<h2 class="post-title"><%= post.title %></h2>
<div class="post-info post-detail-info">
<span><i class="icon-calendar-outline"></i> <%= post.dateFormat %></span>
<% if (post.tags.length > 0) { %>
<span>
<i class="icon-pricetags-outline"></i>
<% post.tags.forEach(function(tag, index) { %>
<a href="<%= tag.link %>">
<%= tag.name %>
<% if (index !== post.tags.length - 1) { %>
,
<% } %>
</a>
<% }); %>
</span>
<% } %>
</div>
<div class="post-content" v-pre>
<%- post.content %>
</div>
</div>
<% if (post.nextPost && !post.hideInList) { %>
<div class="next-post">
<a class="purple-link" href="<%= post.nextPost.link %>">
<h3 class="post-title">
下一篇:<%= post.nextPost.title %>
</h3>
</a>
</div>
<% } %>
</div>
<% if (typeof commentSetting !== 'undefined' && commentSetting.showComment) { %>
<% if (commentSetting.commentPlatform === 'gitalk') { %>
<div id="gitalk-container"></div>
<% } %>
<% if (commentSetting.commentPlatform === 'disqus') { %>
<div id="disqus_thread"></div>
<% } %>
<% } %>
<%- include('./includes/footer') %>
</div>
<%- include('./includes/scripts') %>
</body>
</html>
================================================
FILE: public/default-files/themes/fly/templates/tag.ejs
================================================
<!DOCTYPE html>
<html>
<head>
<%- include('./includes/head', { siteTitle: `${tag.name} | ${themeConfig.siteName}` }) %>
</head>
<body>
<div id="app" class="main">
<%- include('./includes/header') %>
<div class="content-container">
<div class="current-tag-container">
<h2 class="title">
<i class="icon icon-pricetags-outline"></i> <%= tag.name %>
</h2>
</div>
<%- include('./includes/post-list') %>
</div>
<%- include('./includes/footer') %>
</div>
<%- include('./includes/scripts') %>
</body>
</html>
================================================
FILE: public/default-files/themes/fly/templates/tags.ejs
================================================
<html>
<head>
<%- include('./includes/head', { siteTitle: themeConfig.siteName }) %>
</head>
<body>
<div id="app" class="main">
<%- include('./includes/header') %>
<div class="content-container">
<div class="tags-container">
<% tags.forEach((tag) => { %>
<a class="tag" href="<%= tag.link %>"><%= tag.name %></a>
<% }); %>
</div>
</div>
<%- include('./includes/footer') %>
</div>
<%- include('./includes/scripts') %>
</div>
</body>
</html>
================================================
FILE: public/default-files/themes/notes/assets/styles/abstracts/varibles.less
================================================
@darker-main-color: #004cb3;
@dark-main-color: #0061e6;
@main-color: #006CFF;
@light-main-color: #006cff21;
@black: #000000;
@white: #FFFFFF;
@dark-gray: #5E5E5E;
@default-gray: #CCCCCC;
@light-gray: #E6E6E6;
@lighter-gray: #F3F3F3;
@darker-red: #af0900;
@dark-red: #e20c00;
@default-red: #FB0D00;
@default-green: #11B711;
@default-yellow: #FAAD14;
@default-green-blue: #788F9A;
@dark-text-color: #2b2b2b;
@default-text-color: #444444;
@light-text-color: #6a6a6a;
================================================
FILE: public/default-files/themes/notes/assets/styles/components/about.less
================================================
.about-page {
padding: 24px 32px;
}
================================================
FILE: public/default-files/themes/notes/assets/styles/components/archives.less
================================================
.archives-container {
padding: 32px;
flex: 1;
.year {
font-size: 1.375rem;
font-weight: bold;
margin: 24px 0 16px;
color: @oc-gray-6;
padding: 0 24px;
}
.post {
padding: 16px 24px;
display: block;
.post-title {
font-size: 16px;
font-weight: 900;
letter-spacing: .02em;
}
.time {
font-size: 0.75rem;
margin-top: 8px;
color: @oc-gray-4;
}
}
}
@media (max-width: 600px) {
.archives-container {
padding: 16px;
}
}
================================================
FILE: public/default-files/themes/notes/assets/styles/components/footer.less
================================================
.site-footer {
font-size: 12px;
text-align: center;
padding: 40px 24px;
color: @oc-gray-6;
display: flex;
justify-content: center;
align-items: center;
}
.rss {
display: inline-flex;
align-items: center;
margin-left: 24px;
}
================================================
FILE: public/default-files/themes/notes/assets/styles/components/header.less
================================================
.site-header {
padding: 48px 0;
text-align: center;
.site-title {
font-size: 32px;
font-weight: bold;
}
.site-description {
font-size: 16px;
padding: 24px;
color: @oc-gray-7;
font-weight: lighter;
}
.menu-container {
display: flex;
justify-content: center;
flex-wrap: wrap;
a.menu {
font-size: 16px;
padding: 8px 16px;
flex-shrink: 0;
font-weight: 600;
}
}
.avatar {
margin-bottom: 24px;
border-radius: 50%;
width: 120px;
height: 120px;
}
.social-container {
padding: 16px;
font-size: 18px;
a {
margin: 4px 8px;
color: #868e96;
}
}
}
@media (max-width: 600px) {
.site-header {
padding: 24px 0 0;
.avatar {
width: 80px;
height: 80px;
}
}
}
================================================
FILE: public/default-files/themes/notes/assets/styles/components/home.less
================================================
.post-container {
flex: 1;
.post {
padding-bottom: 32px;
.post-title {
font-size: 28px;
text-align: center;
padding: 24px 0;
font-weight: 900;
letter-spacing: .02em;
}
.post-info {
text-align: center;
font-size: 12px;
padding-bottom: 24px;
> span {
color: @dark-gray;
&:not(:first-child) {
&:before {
content: "/ ";
font-size: 10px;
color: rgba(0,0,0,.1);
margin: 0 4px;
}
}
}
.post-tag {
padding: 8px 8px;
}
}
.post-feature-image {
display: block;
width: 100%;
padding-top: 32.6%;
border-radius: 2px;
overflow: hidden;
background-size: cover;
background-position: center;
transition: all 0.3s;
img {
width: 100%;
// height: 100%
}
&:hover {
transform: scale(1.0082);
}
}
.post-abstract {
padding: 24px 0;
line-height: 1.5;
font-size: 16px;
strong {
font-weight: bolder;
}
a {
color: @main-color;
transition: all 0.3s;
&:hover {
color: @dark-main-color;
border-bottom: 1px dotted @dark-main-color;
}
}
code {
font-family: monospace;
font-size: inherit;
background-color: rgba(0,0,0,.06);
padding: 0 2px;
border: 1px solid rgba(0,0,0,.08);
border-radius: 2px 2px;
line-height: initial;
word-wrap: break-word;
text-indent: 0;
}
}
}
}
.pagination-container {
padding: 32px 16px;
overflow: hidden;
.prev-page {
float: left;
}
.next-page {
float: right;
}
.prev-page,
.next-page {
padding: 6px 12px;
font-weight: bold;
border-bottom: 2px solid transparent;
&:hover {
border-bottom: 2px solid;
}
}
}
@media (max-width: 600px) {
.post-container {
.post {
padding: 16px 16px;
.post-title {
padding: 16px 0;
font-size: 24px;
}
.post-abstract {
padding: 16px 0;
}
.post-feature-image {
padding-top: 56.25%;
}
}
}
}
================================================
FILE: public/default-files/themes/notes/assets/styles/components/post.less
================================================
.post-detail {
flex: 1;
.post {
padding: 24px 32px;
.post-feature-image {
width: 100%;
height: auto;
margin-bottom: 24px;
border-radius: 2px;
}
.post-title {
font-size: 32px;
text-align: center;
padding: 24px 0;
font-weight: 900;
letter-spacing: 0.02em;
}
.post-info {
text-align: center;
font-size: 12px;
padding-bottom: 24px;
> span {
color: @dark-gray;
&:not(:first-child) {
&:before {
content: "/ ";
font-size: 10px;
color: rgba(0,0,0,.1);
margin: 0 4px;
}
}
}
.post-tag {
padding: 8px 8px;
}
}
.post-content-wrapper {
display: flex;
}
.post-content {
width: 100%;
flex-shrink: 0;
font-family: "Noto Serif","PingFang SC","Hiragino Sans GB","Droid Sans Fallback","Microsoft YaHei",sans-serif;
a {
color: rgba(0,0,0,.98);
word-wrap: break-word;
text-decoration: none;
border-bottom: 1px solid rgba(0,0,0,.26);
&:hover {
color: @dark-main-color;
border-bottom: 1px solid @dark-main-color;
}
}
img {
display: block;
box-shadow: 0 0 30px #eee;
max-width: 100%;
border-radius: 2px;
margin: 24px auto;
}
p {
line-height: 1.62;
margin-bottom: 1.12em;
font-size: 16px;
letter-spacing: .05em;
hyphens: auto;
}
p, li {
code {
font-family: 'Source Code Pro', Consolas, Menlo, Monaco, 'Courier New', monospace;
line-height: initial;
word-wrap: break-word;
border-radius: 0;
background-color: #fff5f5;
color: #c53030;
padding: .2em .33333333em;
margin-left: .125em;
margin-right: .125em;
}
}
pre {
margin-bottom: 1.5rem;
padding: 0;
position: relative;
code {
font-size: 0.96em;
font-family: 'Source Code Pro', Consolas, Menlo, Monaco, 'Courier New', monospace;
padding: 1em;
border-radius: 5px;
line-height: 1.5;
}
}
blockquote {
color: #9a9a9a;
position: relative;
padding: .4em 0 0 2.2em;
font-size: .96em;
&:before {
position: absolute;
top: -4px;
left: 0;
content: "\201c";
font: 700 62px/1 serif;
color: rgba(0,0,0,.1);
}
}
table {
border-collapse: collapse;
margin: 1rem 0;
display: block;
overflow-x: auto;
}
tr {
border-top: 1px solid #dfe2e5;
}
td, th {
border: 1px solid #dfe2e5;
padding: .6em 1em;
}
ul, ol {
padding-left: 35px;
line-height: 1.725;
margin-bottom: 16px;
}
ul {
list-style-type: square;
}
h1, h2, h3, h4, h5, h6 {
margin: 16px 0;
font-weight: 700;
padding-top: 16px;
}
h1 {
font-size: 1.8em;
}
h2 {
font-size: 1.42em;
}
h3 {
font-size: 1.17em;
}
h4 {
font-size: 1em;
}
h5 {
font-size: 1em;
}
h6 {
font-size: 1em;
font-weight: 500;
}
hr {
display: block;
border: 0;
margin: 2.24em auto 2.86em;
&:before {
color: rgba(0,0,0,.2);
font-size: 1.1em;
display: block;
content: "* * *";
text-align: center;
}
}
mark {
background: #faf089;
color: #744210;
padding: .2em;
}
.footnotes {
margin-left: auto;
margin-right: auto;
max-width: 760px;
padding-left: 18px;
padding-right: 18px;
&:before {
content: "";
display: block;
border-top: 4px solid rgba(0,0,0,.1);
width: 50%;
max-width: 100px;
margin: 40px 0 20px;
}
}
.contains-task-list {
list-style-type: none;
padding-left: 30px;
}
.task-list-item {
position: relative;
}
.task-list-item-checkbox {
position: absolute;
cursor: pointer;
width: 16px;
height: 16px;
margin: 4px 0 0;
top: -1px;
left: -22px;
transform-origin: center;
transform: rotate(-90deg);
transition: all .2s ease;
&:checked {
transform: rotate(0);
&:before {
border: transparent;
background-color: @oc-green-5;
}
&:after {
transform: rotate(-45deg) scale(1);
}
+ .task-list-item-label {
color: #a0a0a0;
text-decoration: line-through;
}
}
&:before {
content: "";
width: 16px;
height: 16px;
box-sizing: border-box;
display: inline-block;
border: 1px solid #9ae6b4;
border-radius: 2px;
background-color: #fff;
position: absolute;
top: 0;
left: 0;
transition: all .2s ease;
}
&:after {
content: "";
transform: rotate(-45deg) scale(0);
width: 9px;
height: 5px;
border: 1px solid #fff;
border-top: none;
border-right: none;
position: absolute;
display: inline-block;
top: 4px;
left: 4px;
transition: all .2s ease;
}
}
}
}
}
.next-post {
text-align: center;
padding: 24px 32px;
.next {
margin-bottom: 24px;
color: @oc-gray-8;
font-weight: lighter;
}
.post-title {
font-size: 20px;
font-weight: bold;
letter-spacing: .02em;
}
}
#gitalk-container, #disqus_thread {
padding: 24px 32px;
}
.toc-container {
.markdownIt-TOC {
position: sticky;
top: 32px;
width: 200px;
font-size: 12px;
list-style: none;
padding-left: 0;
padding: 16px 8px;
&:before {
content: "";
position: absolute;
top: 0;
left: 8px;
bottom: 0;
width: 1px;
background-color: #ebedef;
opacity: .5;
}
}
ul {
list-style: none;
}
li {
padding-left: 16px;
a {
color: @oc-gray-6;
padding: 4px;
display: block;
transition: all 0.3s;
&:hover {
background: #fafafa;
}
&.current {
color: @main-color;
background: #fafafa;
}
}
}
}
@media (max-width: 600px) {
.post-detail {
.post {
padding: 16px;
.post-title {
font-size: 24px;
padding: 16px 0;
}
}
}
}
@media (max-width: 1150px) {
.toc-container {
display: none;
}
}
================================================
FILE: public/default-files/themes/notes/assets/styles/components/tag.less
================================================
.current-tag-container {
.title {
text-align: center;
font-size: 18px;
margin-bottom: 24px;
}
}
================================================
FILE: public/default-files/themes/notes/assets/styles/components/tags.less
================================================
.tags-container {
padding: 32px 32px;
flex: 1;
text-align: center;
.tag {
display: inline-block;
padding: 8px 16px;
margin: 8px;
background: @oc-gray-0;
color: @oc-gray-7;
border-radius: 2px;
font-size: 14px;
&:hover {
background: @oc-gray-2;
color: @oc-gray-9;
}
}
}
================================================
FILE: public/default-files/themes/notes/assets/styles/lib/colors.less
================================================
//
//
// 𝗖 𝗢 𝗟 𝗢 𝗥
// v 1.6.3
//
// ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
// General
// ───────────────────────────────────
@oc-white: #ffffff;
@oc-black: #000000;
// Gray
// ───────────────────────────────────
@oc-gray-list: #f8f9fa, #f1f3f5, #e9ecef, #dee2e6, #ced4da, #adb5bd, #868e96, #495057, #343a40, #212529;
@oc-gray-0: extract(@oc-gray-list, 1);
@oc-gray-1: extract(@oc-gray-list, 2);
@oc-gray-2: extract(@oc-gray-list, 3);
@oc-gray-3: extract(@oc-gray-list, 4);
@oc-gray-4: extract(@oc-gray-list, 5);
@oc-gray-5: extract(@oc-gray-list, 6);
@oc-gray-6: extract(@oc-gray-list, 7);
@oc-gray-7: extract(@oc-gray-list, 8);
@oc-gray-8: extract(@oc-gray-list, 9);
@oc-gray-9: extract(@oc-gray-list, 10);
// Red
// ───────────────────────────────────
@oc-red-list: #fff5f5, #ffe3e3, #ffc9c9, #ffa8a8, #ff8787, #ff6b6b, #fa5252, #f03e3e, #e03131, #c92a2a;
@oc-red-0: extract(@oc-red-list, 1);
@oc-red-1: extract(@oc-red-list, 2);
@oc-red-2: extract(@oc-red-list, 3);
@oc-red-3: extract(@oc-red-list, 4);
@oc-red-4: extract(@oc-red-list, 5);
@oc-red-5: extract(@oc-red-list, 6);
@oc-red-6: extract(@oc-red-list, 7);
@oc-red-7: extract(@oc-red-list, 8);
@oc-red-8: extract(@oc-red-list, 9);
@oc-red-9: extract(@oc-red-list, 10);
// Pink
// ───────────────────────────────────
@oc-pink-list: #fff0f6, #ffdeeb, #fcc2d7, #faa2c1, #f783ac, #f06595, #e64980, #d6336c, #c2255c, #a61e4d;
@oc-pink-0: extract(@oc-pink-list, 1);
@oc-pink-1: extract(@oc-pink-list, 2);
@oc-pink-2: extract(@oc-pink-list, 3);
@oc-pink-3: extract(@oc-pink-list, 4);
@oc-pink-4: extract(@oc-pink-list, 5);
@oc-pink-5: extract(@oc-pink-list, 6);
@oc-pink-6: extract(@oc-pink-list, 7);
@oc-pink-7: extract(@oc-pink-list, 8);
@oc-pink-8: extract(@oc-pink-list, 9);
@oc-pink-9: extract(@oc-pink-list, 10);
// Grape
// ───────────────────────────────────
@oc-grape-list: #f8f0fc, #f3d9fa, #eebefa, #e599f7, #da77f2, #cc5de8, #be4bdb, #ae3ec9, #9c36b5, #862e9c;
@oc-grape-0: extract(@oc-grape-list, 1);
@oc-grape-1: extract(@oc-grape-list, 2);
@oc-grape-2: extract(@oc-grape-list, 3);
@oc-grape-3: extract(@oc-grape-list, 4);
@oc-grape-4: extract(@oc-grape-list, 5);
@oc-grape-5: extract(@oc-grape-list, 6);
@oc-grape-6: extract(@oc-grape-list, 7);
@oc-grape-7: extract(@oc-grape-list, 8);
@oc-grape-8: extract(@oc-grape-list, 9);
@oc-grape-9: extract(@oc-grape-list, 10);
// Violet
// ───────────────────────────────────
@oc-violet-list: #f3f0ff, #e5dbff, #d0bfff, #b197fc, #9775fa, #845ef7, #7950f2, #7048e8, #6741d9, #5f3dc4;
@oc-violet-0: extract(@oc-violet-list, 1);
@oc-violet-1: extract(@oc-violet-list, 2);
@oc-violet-2: extract(@oc-violet-list, 3);
@oc-violet-3: extract(@oc-violet-list, 4);
@oc-violet-4: extract(@oc-violet-list, 5);
@oc-violet-5: extract(@oc-violet-list, 6);
@oc-violet-6: extract(@oc-violet-list, 7);
@oc-violet-7: extract(@oc-violet-list, 8);
@oc-violet-8: extract(@oc-violet-list, 9);
@oc-violet-9: extract(@oc-violet-list, 10);
// Indigo
// ───────────────────────────────────
@oc-indigo-list: #edf2ff, #dbe4ff, #bac8ff, #91a7ff, #748ffc, #5c7cfa, #4c6ef5, #4263eb, #3b5bdb, #364fc7;
@oc-indigo-0: extract(@oc-indigo-list, 1);
@oc-indigo-1: extract(@oc-indigo-list, 2);
@oc-indigo-2: extract(@oc-indigo-list, 3);
@oc-indigo-3: extract(@oc-indigo-list, 4);
@oc-indigo-4: extract(@oc-indigo-list, 5);
@oc-indigo-5: extract(@oc-indigo-list, 6);
@oc-indigo-6: extract(@oc-indigo-list, 7);
@oc-indigo-7: extract(@oc-indigo-list, 8);
@oc-indigo-8: extract(@oc-indigo-list, 9);
@oc-indigo-9: extract(@oc-indigo-list, 10);
// Blue
// ───────────────────────────────────
@oc-blue-list: #e7f5ff, #d0ebff, #a5d8ff, #74c0fc, #4dabf7, #339af0, #228be6, #1c7ed6, #1971c2, #1864ab;
@oc-blue-0: extract(@oc-blue-list, 1);
@oc-blue-1: extract(@oc-blue-list, 2);
@oc-blue-2: extract(@oc-blue-list, 3);
@oc-blue-3: extract(@oc-blue-list, 4);
@oc-blue-4: extract(@oc-blue-list, 5);
@oc-blue-5: extract(@oc-blue-list, 6);
@oc-blue-6: extract(@oc-blue-list, 7);
@oc-blue-7: extract(@oc-blue-list, 8);
@oc-blue-8: extract(@oc-blue-list, 9);
@oc-blue-9: extract(@oc-blue-list, 10);
// Cyan
// ───────────────────────────────────
@oc-cyan-list: #e3fafc, #c5f6fa, #99e9f2, #66d9e8, #3bc9db, #22b8cf, #15aabf, #1098ad, #0c8599, #0b7285;
@oc-cyan-0: extract(@oc-cyan-list, 1);
@oc-cyan-1: extract(@oc-cyan-list, 2);
@oc-cyan-2: extract(@oc-cyan-list, 3);
@oc-cyan-3: extract(@oc-cyan-list, 4);
@oc-cyan-4: extract(@oc-cyan-list, 5);
@oc-cyan-5: extract(@oc-cyan-list, 6);
@oc-cyan-6: extract(@oc-cyan-list, 7);
@oc-cyan-7: extract(@oc-cyan-list, 8);
@oc-cyan-8: extract(@oc-cyan-list, 9);
@oc-cyan-9: extract(@oc-cyan-list, 10);
// Teal
// ───────────────────────────────────
@oc-teal-list: #e6fcf5, #c3fae8, #96f2d7, #63e6be, #38d9a9, #20c997, #12b886, #0ca678, #099268, #087f5b;
@oc-teal-0: extract(@oc-teal-list, 1);
@oc-teal-1: extract(@oc-teal-list, 2);
@oc-teal-2: extract(@oc-teal-list, 3);
@oc-teal-3: extract(@oc-teal-list, 4);
@oc-teal-4: extract(@oc-teal-list, 5);
@oc-teal-5: extract(@oc-teal-list, 6);
@oc-teal-6: extract(@oc-teal-list, 7);
@oc-teal-7: extract(@oc-teal-list, 8);
@oc-teal-8: extract(@oc-teal-list, 9);
@oc-teal-9: extract(@oc-teal-list, 10);
// Green
// ───────────────────────────────────
@oc-green-list: #ebfbee, #d3f9d8, #b2f2bb, #8ce99a, #69db7c, #51cf66, #40c057, #37b24d, #2f9e44, #2b8a3e;
@oc-green-0: extract(@oc-green-list, 1);
@oc-green-1: extract(@oc-green-list, 2);
@oc-green-2: extract(@oc-green-list, 3);
@oc-green-3: extract(@oc-green-list, 4);
@oc-green-4: extract(@oc-green-list, 5);
@oc-green-5: extract(@oc-green-list, 6);
@oc-green-6: extract(@oc-green-list, 7);
@oc-green-7: extract(@oc-green-list, 8);
@oc-green-8: extract(@oc-green-list, 9);
@oc-green-9: extract(@oc-green-list, 10);
// Lime
// ───────────────────────────────────
@oc-lime-list: #f4fce3, #e9fac8, #d8f5a2, #c0eb75, #a9e34b, #94d82d, #82c91e, #74b816, #66a80f, #5c940d;
@oc-lime-0: extract(@oc-lime-list, 1);
@oc-lime-1: extract(@oc-lime-list, 2);
@oc-lime-2: extract(@oc-lime-list, 3);
@oc-lime-3: extract(@oc-lime-list, 4);
@oc-lime-4: extract(@oc-lime-list, 5);
@oc-lime-5: extract(@oc-lime-list, 6);
@oc-lime-6: extract(@oc-lime-list, 7);
@oc-lime-7: extract(@oc-lime-list, 8);
@oc-lime-8: extract(@oc-lime-list, 9);
@oc-lime-9: extract(@oc-lime-list, 10);
// Yellow
// ───────────────────────────────────
@oc-yellow-list: #fff9db, #fff3bf, #ffec99, #ffe066, #ffd43b, #fcc419, #fab005, #f59f00, #f08c00, #e67700;
@oc-yellow-0: extract(@oc-yellow-list, 1);
@oc-yellow-1: extract(@oc-yellow-list, 2);
@oc-yellow-2: extract(@oc-yellow-list, 3);
@oc-yellow-3: extract(@oc-yellow-list, 4);
@oc-yellow-4: extract(@oc-yellow-list, 5);
@oc-yellow-5: extract(@oc-yellow-list, 6);
@oc-yellow-6: extract(@oc-yellow-list, 7);
@oc-yellow-7: extract(@oc-yellow-list, 8);
@oc-yellow-8: extract(@oc-yellow-list, 9);
@oc-yellow-9: extract(@oc-yellow-list, 10);
// Orange
// ───────────────────────────────────
@oc-orange-list: #fff4e6, #ffe8cc, #ffd8a8, #ffc078, #ffa94d, #ff922b, #fd7e14, #f76707, #e8590c, #d9480f;
@oc-orange-0: extract(@oc-orange-list, 1);
@oc-orange-1: extract(@oc-orange-list, 2);
@oc-orange-2: extract(@oc-orange-list, 3);
@oc-orange-3: extract(@oc-orange-list, 4);
@oc-orange-4: extract(@oc-orange-list, 5);
@oc-orange-5: extract(@oc-orange-list, 6);
@oc-orange-6: extract(@oc-orange-list, 7);
@oc-orange-7: extract(@oc-orange-list, 8);
@oc-orange-8: extract(@oc-orange-list, 9);
@oc-orange-9: extract(@oc-orange-list, 10);
================================================
FILE: public/default-files/themes/notes/assets/styles/lib/github.less
================================================
.hljs {
display: block;
overflow-x: auto;
padding: 0.5em;
color: #333;
background: #f9f7f3;
}
.hljs-comment,
.hljs-quote {
color: #998;
font-style: italic;
}
.hljs-keyword,
.hljs-selector-tag,
.hljs-subst {
color: #333;
font-weight: bold;
}
.hljs-number,
.hljs-literal,
.hljs-variable,
.hljs-template-variable,
.hljs-tag .hljs-attr {
color: #008080;
}
.hljs-string,
.hljs-doctag {
color: #d14;
}
.hljs-title,
.hljs-section,
.hljs-selector-id {
color: #900;
font-weight: bold;
}
.hljs-subst {
font-weight: normal;
}
.hljs-type,
.hljs-class .hljs-title {
color: #458;
font-weight: bold;
}
.hljs-tag,
.hljs-name,
.hljs-attribute {
color: #000080;
font-weight: normal;
}
.hljs-regexp,
.hljs-link {
color: #009926;
}
.hljs-symbol,
.hljs-bullet {
color: #990073;
}
.hljs-built_in,
.hljs-builtin-name {
color: #0086b3;
}
.hljs-meta {
color: #999;
font-weight: bold;
}
.hljs-deletion {
background: #fdd;
}
.hljs-addition {
background: #dfd;
}
.hljs-emphasis {
font-style: italic;
}
.hljs-strong {
font-weight: bold;
}
================================================
FILE: public/default-files/themes/notes/assets/styles/lib/modern-normalize.less
================================================
/*! modern-normalize | MIT License | https://github.com/sindresorhus/modern-normalize */
/* Document
========================================================================== */
/**
* Use a better box model (opinionated).
*/
html {
box-sizing: border-box;
}
*,
*::before,
*::after {
box-sizing: inherit;
}
/**
* Use a more readable tab size (opinionated).
*/
:root {
-moz-tab-size: 4;
tab-size: 4;
}
/**
* 1. Correct the line height in all browsers.
* 2. Prevent adjustments of font size after orientation changes in iOS.
*/
html {
line-height: 1.15; /* 1 */
-webkit-text-size-adjust: 100%; /* 2 */
}
/* Sections
========================================================================== */
/**
* Remove the margin in all browsers.
*/
body {
margin: 0;
}
/**
* Improve consistency of default fonts in all browsers. (https://github.com/sindresorhus/modern-normalize/issues/3)
*/
body {
font-family:
-apple-system,
BlinkMacSystemFont,
'Segoe UI',
Roboto,
Helvetica,
Arial,
sans-serif,
'Apple Color Emoji',
'Segoe UI Emoji',
'Segoe UI Symbol';
}
/* Grouping content
========================================================================== */
/* Text-level semantics
========================================================================== */
/**
* Add the correct text decoration in Chrome, Edge, and Safari.
*/
abbr[title] {
text-decoration: underline dotted;
}
/**
* Add the correct font weight in Chrome, Edge, and Safari.
*/
b,
strong {
font-weight: bolder;
}
/**
* 1. Improve consistency of default fonts in all browsers. (https://github.com/sindresorhus/modern-normalize/issues/3)
* 2. Correct the odd `em` font sizing in all browsers.
*/
code,
kbd,
samp,
pre {
font-family: SFMono-Regular, Consolas, 'Liberation Mono', Menlo, Courier, monospace; /* 1 */
font-size: 1em; /* 2 */
}
/**
* Add the correct font size in all browsers.
*/
small {
font-size: 80%;
}
/**
* Prevent `sub` and `sup` elements from affecting the line height in all browsers.
*/
sub,
sup {
font-size: 75%;
line-height: 0;
position: relative;
vertical-align: baseline;
}
sub {
bottom: -0.25em;
}
sup {
top: -0.5em;
}
/* Forms
========================================================================== */
/**
* 1. Change the font styles in all browsers.
* 2. Remove the margin in Firefox and Safari.
*/
button,
input,
optgroup,
select,
textarea {
font-family: inherit; /* 1 */
font-size: 100%; /* 1 */
line-height: 1.15; /* 1 */
margin: 0; /* 2 */
}
/**
* Remove the inheritance of text transform in Edge and Firefox.
* 1. Remove the inheritance of text transform in Firefox.
*/
button,
select { /* 1 */
text-transform: none;
}
/**
* Correct the inability to style clickable types in iOS and Safari.
*/
button,
[type='button'],
[type='reset'],
[type='submit'] {
-webkit-appearance: button;
}
/**
* Remove the inner border and padding in Firefox.
*/
button::-moz-focus-inner,
[type='button']::-moz-focus-inner,
[type='reset']::-moz-focus-inner,
[type='submit']::-moz-focus-inner {
border-style: none;
padding: 0;
}
/**
* Restore the focus styles unset by the previous rule.
*/
button:-moz-focusring,
[type='button']:-moz-focusring,
[type='reset']:-moz-focusring,
[type='submit']:-moz-focusring {
outline: 1px dotted ButtonText;
}
/**
* Correct the padding in Firefox.
*/
fieldset {
padding: 0.35em 0.75em 0.625em;
}
/**
* Remove the padding so developers are not caught out when they zero out `fieldset` elements in all browsers.
*/
legend {
padding: 0;
}
/**
* Add the correct vertical alignment in Chrome and Firefox.
*/
progress {
vertical-align: baseline;
}
/**
* Correct the cursor style of increment and decrement buttons in Safari.
*/
[type='number']::-webkit-inner-spin-button,
[type='number']::-webkit-outer-spin-button {
height: auto;
}
/**
* 1. Correct the odd appearance in Chrome and Safari.
* 2. Correct the outline style in Safari.
*/
[type='search'] {
-webkit-appearance: textfield; /* 1 */
outline-offset: -2px; /* 2 */
}
/**
* Remove the inner padding in Chrome and Safari on macOS.
*/
[type='search']::-webkit-search-decoration {
-webkit-appearance: none;
}
/**
* 1. Correct the inability to style clickable types in iOS and Safari.
* 2. Change font properties to `inherit` in Safari.
*/
::-webkit-file-upload-button {
-webkit-appearance: button; /* 1 */
font: inherit; /* 2 */
}
/* Interactive
========================================================================== */
/*
* Add the correct display in Chrome and Safari.
*/
summary {
display: list-item;
}
================================================
FILE: public/default-files/themes/notes/assets/styles/main.less
================================================
@import './lib/modern-normalize';
@import './lib/colors';
@import './abstracts/varibles';
*,
*:before,
*:after {
margin: 0;
padding: 0;
}
html, body, div, span, applet, object, iframe, h1, h2, h3, h4, h5, h6, p, blockquote, pre, a, abbr, acronym, address, big, cite, code, del, dfn, em, img, ins, kbd, q, s, samp, small, strike, strong, sub, sup, tt, var, b, u, i, center, dl, dt, dd, ol, ul, li, fieldset, form, label, legend, table, caption, tbody, tfoot, thead, tr, th, td, article, aside, canvas, details, embed, figure, figcaption, footer, header, hgroup, menu, nav, output, ruby, section, summary, time, mark, audio, video {
border: 0;
vertical-align: baseline;
}
html {
font-size: 58%;
}
body {
color: rgba(0,0,0,.86);
font: 400 16px/1.42 -apple-system,BlinkMacSystemFont,"Helvetica Neue","PingFang SC","Hiragino Sans GB","Droid Sans Fallback","Microsoft YaHei",sans-serif;
letter-spacing: .05em;
}
a {
color: rgba(0,0,0,.98);
text-decoration: none;
transition: all 0.3s;
&:hover {
color: @main-color;
}
}
body, div, a, p, ul, li, ol, h1, h2, h3, h4, h5, h6, table, tr, td {
box-sizing: border-box;
margin: 0;
padding: 0;
}
.main {
max-width: 800px;
min-height: 100vh;
margin: 0 auto;
background: #fff;
.main-content {
flex: 1;
display: flex;
min-height: 100vh;
flex-direction: column;
padding: 0 24px;
}
}
@import "./components/header.less";
@import "./components/home.less";
@import "./components/post.less";
@import "./components/archives.less";
@import "./components/tags.less";
@import "./components/tag.less";
@import "./components/about.less";
@import "./components/footer.less";
@import "./lib/github.less";
================================================
FILE: public/default-files/themes/notes/config.json
================================================
{
"name": "Notes",
"version": "1.2.0",
"author": "EryouHao",
"repository": "https://github.com/getgridea/gridea-theme-notes",
"customConfig": [
{
"name": "contentMaxWidth",
"label": "内容区最大宽度",
"group": "布局",
"value": "800px",
"type": "input",
"note": "可填像素类型(如:320px)或百分比类型(如:38.2%)"
},
{
"name": "textSize",
"label": "正文内容文字大小",
"group": "布局",
"value": "16px",
"type": "input",
"note": "px 或 rem(如 16px 或 1rem)"
},
{
"name": "titleAlign",
"label": "标题对齐",
"group": "布局",
"value": "center",
"type": "radio",
"options": [
{
"label": "居中对齐",
"value": "center"
},
{
"label": "左对齐",
"value": "left"
},
{
"label": "右对齐",
"value": "right"
}
],
"note": "包含标题及日期、标签等信息部分"
},
{
"name": "siteFont",
"label": "网站字体",
"group": "布局",
"value": "-apple-system,BlinkMacSystemFont,'Helvetica Neue','PingFang SC','Hiragino Sans GB','Droid Sans Fallback','Microsoft YaHei',sans-serif",
"type": "select",
"options": [
{
"label": "-apple-system,BlinkMacSystemFont,'Helvetica Neue','PingFang SC','Hiragino Sans GB','Droid Sans Fallback','Microsoft YaHei',sans-serif",
"value": "-apple-system,BlinkMacSystemFont,'Helvetica Neue','PingFang SC','Hiragino Sans GB','Droid Sans Fallback','Microsoft YaHei',sans-serif"
},
{
"label": "Georgia, serif",
"value": "Georgia, serif"
}
],
"note": ""
},
{
"name": "openPostToc",
"label": "是否显示文章目录",
"group": "布局",
"value": true,
"type": "switch",
"note": "仅在宽屏时生效"
},
{
"name": "contentBgColor",
"label": "内容区背景色",
"group": "颜色",
"value": "#ffffff",
"type": "input",
"card": "color",
"note": "颜色字符串:(如:#EEEEEE、rgba(255, 255, 255, 0.9))"
},
{
"name": "pageBgColor",
"label": "网页背景色",
"group": "颜色",
"value": "#ffffff",
"type": "input",
"card": "color",
"note": "颜色字符串:(如:#EEEEEE、rgba(255, 255, 255, 0.9))"
},
{
"name": "textColor",
"label": "文字颜色",
"group": "颜色",
"value": "rgba(0, 0, 0, 0.86)",
"type": "input",
"card": "color",
"note": "颜色字符串:(如:#EEEEEE、rgba(255, 255, 255, 0.9))"
},
{
"name": "linkColor",
"label": "链接颜色",
"group": "颜色",
"value": "rgba(0,0,0,.98)",
"type": "input",
"card": "color",
"note": "颜色字符串:(如:#EEEEEE、rgba(255, 255, 255, 0.9))"
},
{
"name": "linkHoverColor",
"label": "链接 Hover 颜色",
"group": "颜色",
"value": "#006CFF",
"type": "input",
"card": "color",
"note": "颜色字符串:(如:#EEEEEE、rgba(255, 255, 255, 0.9))"
},
{
"name": "github",
"label": "Github",
"group": "社交",
"value": "",
"type": "input",
"note": "链接地址"
},
{
"name": "twitter",
"label": "Twitter",
"group": "社交",
"value": "",
"type": "input",
"note": "链接地址"
},
{
"name": "weibo",
"label": "微博",
"group": "社交",
"value": "",
"type": "input",
"note": "链接地址"
},
{
"name": "zhihu",
"label": "知乎",
"group": "社交",
"value": "",
"type": "input",
"note": "链接地址"
},
{
"name": "facebook",
"label": "Facebook",
"group": "社交",
"value": "",
"type": "input",
"note": "链接地址"
},
{
"name": "customCss",
"label": "自定义CSS",
"group": "自定义样式",
"value": "",
"type": "textarea",
"note": ""
},
{
"name": "ga",
"label": "跟踪 ID",
"group": "谷歌统计",
"value": "",
"type": "input",
"note": "UA-xxxxxxxxx-x"
},
{
"name": "metaDescription",
"label": "Meta Description",
"group": "SEO",
"value": "",
"type": "input"
}
]
}
================================================
FILE: public/default-files/themes/notes/style-override.js
================================================
const generateOverride = (params = {}) => {
let result = ''
// 内容区最大宽度 - contentMaxWidth
if (params.contentMaxWidth && params.contentMaxWidth !== '800px') {
result += `
.main {
max-width: ${params.contentMaxWidth};
}
`
}
// 正文内容文字大小 - textSize
if (params.textSize && params.textSize !== '16px') {
result += `
.post-detail .post .post-content p {
font-size: ${params.textSize};
}
`
}
// 标题对齐 - titleAlign: center(默认)、left、right
if (params.titleAlign) {
result += `
.post-container .post .post-title {
text-align: ${params.titleAlign};
}
.post-container .post .post-info {
text-align: ${params.titleAlign};
}
.post-detail .post .post-title {
text-align: ${params.titleAlign};
}
.post-detail .post .post-info {
text-align: ${params.titleAlign};
}
`
}
// 网站字体
if (params.siteFont) {
result += `
body {
font-family: ${params.siteFont};
}
`
}
// 是否显示文章目录
if (typeof params.openPostToc !== 'undefined' && !params.openPostToc) {
result += `
.toc-container {
display: none;
}
`
}
// 内容区背景色 - contentBgColor
if (params.contentBgColor && params.contentBgColor !== '#ffffff') {
result += `
.main {
background: ${params.contentBgColor};
}
`
}
// 网页背景色 - pageBgColor
if (params.pageBgColor && params.pageBgColor !== '#ffffff') {
result += `
body {
background: ${params.pageBgColor};
}
`
}
// 文字颜色 - textColor
if (params.textColor && params.textColor !== 'rgba(0, 0, 0, 0.86)') {
result += `
body {
color: ${params.textColor};
}
`
}
// 链接颜色 - linkColor
if (params.linkColor && params.linkColor !== 'rgba(0,0,0,.98)') {
result += `
a {
color: ${params.linkColor};
}
`
}
// 链接 Hover 颜色 - linkHoverColor
if (params.linkHoverColor && params.linkHoverColor !== '#006CFF') {
result += `
a:hover {
color: ${params.linkHoverColor};
}
`
}
if (params.customCss) {
result += `
${params.customCss}
`
}
console.log('result', result)
return result
}
module.exports = generateOverride
================================================
FILE: public/default-files/themes/notes/templates/archives.ejs
================================================
<html>
<head>
<%- include('./includes/head', { siteTitle: themeConfig.siteName }) %>
<meta name="description" content="<%- site.customConfig.metaDescription || themeConfig.siteDescription %>" />
</head>
<body>
<div class="main">
<div class="main-content">
<%- include('./includes/header') %>
<%- include('./includes/post-list-archives') %>
<%- include('./includes/pagination') %>
<%- include('./includes/footer') %>
</div>
</div>
</body>
</html>
================================================
FILE: public/default-files/themes/notes/templates/includes/disqus.ejs
================================================
<link rel="stylesheet" href="https://unpkg.com/disqusjs@1.1/dist/disqusjs.css">
<script src="https://unpkg.com/disqusjs@1.1/dist/disqus.js"></script>
<div id="disqus_thread"></div>
<script>
var options = {
shortname: '<%= commentSetting.disqusSetting.shortname %>',
apikey: '<%= commentSetting.disqusSetting.apikey %>',
}
if ('<%= commentSetting.disqusSetting.api %>') {
options.api = '<%= commentSetting.disqusSetting.api %>'
}
var dsqjs = new DisqusJS(options)
</script>
================================================
FILE: public/default-files/themes/notes/templates/includes/footer.ejs
================================================
<div class="site-footer">
<%- themeConfig.footerInfo %>
<a class="rss" href="<%= themeConfig.domain %>/atom.xml" target="_blank">
<i class="ri-rss-line"></i> RSS
</a>
</div>
================================================
FILE: public/default-files/themes/notes/templates/includes/gitalk.ejs
================================================
<link rel="stylesheet" href="https://unpkg.com/gitalk/dist/gitalk.css">
<script src="https://unpkg.com/gitalk/dist/gitalk.min.js"></script>
<div id="gitalk-container"></div>
<script>
var gitalk = new Gitalk({
clientID: '<%= commentSetting.gitalkSetting.clientId %>',
clientSecret: '<%= commentSetting.gitalkSetting.clientSecret %>',
repo: '<%= commentSetting.gitalkSetting.repository %>',
owner: '<%= commentSetting.gitalkSetting.owner %>',
admin: ['<%= commentSetting.gitalkSetting.owner %>'],
id: (location.pathname).substring(0, 49), // Ensure uniqueness and length less than 50
distractionFreeMode: false // Facebook-like distraction free mode
})
gitalk.render('gitalk-container')
</script>
================================================
FILE: public/default-files/themes/notes/templates/includes/head.ejs
================================================
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<title><%= siteTitle %></title>
<link rel="shortcut icon" href="<%= themeConfig.domain %>/favicon.ico?v=<%= site.utils.now %>">
<link href="https://cdn.jsdelivr.net/npm/remixicon@2.3.0/fonts/remixicon.css" rel="stylesheet">
<link rel="stylesheet" href="<%= themeConfig.domain %>/styles/main.css">
<link rel="alternate" type="application/atom+xml" title="<%= siteTitle %> - Atom Feed" href="<%= themeConfig.domain %>/atom.xml">
<link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Droid+Serif:400,700">
<% if (site.customConfig.ga) { %>
<script async src="https://www.googletagmanager.com/gtag/js?id=<%= site.customConfig.ga %>"></script>
<script>
window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);}
gtag('js', new Date());
gtag('config', '<%= site.customConfig.ga %>');
</script>
<% } %>
================================================
FILE: public/default-files/themes/notes/templates/includes/header.ejs
================================================
<div class="site-header">
<a href="<%= themeConfig.domain %>">
<img class="avatar" src="<%= themeConfig.domain %>/images/avatar.png?v=<%= site.utils.now %>" alt="">
</a>
<h1 class="site-title">
<%= themeConfig.siteName %>
</h1>
<p class="site-description">
<%- themeConfig.siteDescription %>
</p>
<div class="menu-container">
<% menus.forEach(function(menu) { %>
<% if (menu.openType === 'External') { %>
<a href="<%= menu.link %>" class="menu" target="_blank">
<%= menu.name %>
</a>
<% } else { %>
<a href="<%= menu.link %>" class="menu">
<%= menu.name %>
</a>
<% } %>
<% }); %>
</div>
<div class="social-container">
<% ['github', 'twitter', 'weibo', 'zhihu', 'facebook'].forEach((item) => { %>
<% if (site.customConfig[item]) { %>
<a href="<%= site.customConfig[item] %>" target="_blank">
<i class="ri-<%= item %>-line"></i>
</a>
<% } %>
<% }) %>
</div>
</div>
================================================
FILE: public/default-files/themes/notes/templates/includes/pagination.ejs
================================================
<div class="pagination-container">
<% if (pagination.prev) { %>
<a href="<%= pagination.prev %>" class="prev-page">上一页</a>
<% } %>
<% if (pagination.next) { %>
<a href="<%= pagination.next %>" class="next-page">下一页</a>
<% } %>
</div>
================================================
FILE: public/default-files/themes/notes/templates/includes/post-list-archives.ejs
================================================
<% let years = []; posts.forEach((item) => { const year = item.date.substring(0, 4); if (!years.includes(year)) { years.push(year); } }); %>
<div class="archives-container">
<% years.forEach(function(year) { %>
<h2 class="year"><%- year %></h2>
<% posts.forEach(function(post) { %>
<%if (post.date.indexOf(year) !== -1) { %>
<a href="<%= post.link %>" class="post">
<h2 class="post-title">
<%= post.title %>
</h2>
<div class="time"><%= post.dateFormat %></div>
</a>
<% } %>
<% }); %>
<% }); %>
</div>
================================================
FILE: public/default-files/themes/notes/templates/includes/post-list.ejs
================================================
<div class="post-container">
<% posts.forEach(function(post) { %>
<article class="post">
<a href="<%= post.link %>">
<h2 class="post-title"><%= post.title %></h2>
</a>
<div class="post-info">
<span>
<%= post.dateFormat %>
</span>
<span>
<%= post.stats.text %>
</span>
<% post.tags.forEach(function(tag) { %>
<a href="<%= tag.link %>" class="post-tag">
# <%= tag.name %>
</a>
<% }); %>
</div>
<% if (themeConfig.showFeatureImage && post.feature) { %>
<a href="<%= post.link %>" class="post-feature-image" style="background-image: url('<%= post.feature %>')">
</a>
<% } %>
<div class="post-abstract">
<%- post.abstract %>
</div>
</article>
<% }); %>
</div>
================================================
FILE: public/default-files/themes/notes/templates/index.ejs
================================================
<html>
<head>
<%- include('./includes/head', { siteTitle: themeConfig.siteName }) %>
<meta name="description" content="<%- site.customConfig.metaDescription || themeConfig.siteDescription %>" />
</head>
<body>
<div class="main">
<div class="main-content">
<%- include('./includes/header') %>
<%- include('./includes/post-list') %>
<%- include('./includes/pagination') %>
<%- include('./includes/footer') %>
</div>
</div>
</body>
</html>
================================================
FILE: public/default-files/themes/notes/templates/post.ejs
================================================
<html>
<head>
<%- include('./includes/head', { siteTitle: `${post.title} | ${themeConfig.siteName}` }) %>
<meta name="description" content="<%- post.description %>" />
<meta name="keywords" content="<%- post.tags.map(tag => tag.name).join(',') %>" />
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/KaTeX/0.10.0/katex.min.css">
<script src="//cdn.jsdelivr.net/gh/highlightjs/cdn-release@11.5.1/build/highlight.min.js"></script>
</head>
<body>
<div class="main">
<div class="main-content">
<%- include('./includes/header') %>
<div class="post-detail">
<article class="post">
<h2 class="post-title">
<%= post.title %>
</h2>
<div class="post-info">
<span>
<%= post.dateFormat %>
</span>
<span>
<%= post.stats.text %>
</span>
<% post.tags.forEach(function(tag) { %>
<a href="<%= tag.link %>" class="post-tag">
# <%= tag.name %>
</a>
<% }); %>
</div>
<% if (themeConfig.showFeatureImage && post.feature) { %>
<img class="post-feature-image" src="<%= post.feature %>" alt="">
<% } %>
<div class="post-content-wrapper">
<div class="post-content" v-pre>
<%- post.content %>
</div>
<div class="toc-container">
<%- post.toc %>
</div>
</div>
</article>
</div>
<% if (post.nextPost && !post.hideInList) { %>
<div class="next-post">
<div class="next">下一篇</div>
<a href="<%= post.nextPost.link %>">
<h3 class="post-title">
<%= post.nextPost.title %>
</h3>
</a>
</div>
<% } %>
<% if (typeof commentSetting !== 'undefined' && commentSetting.showComment) { %>
<% if (commentSetting.commentPlatform === 'gitalk') { %>
<%- include('./includes/gitalk') %>
<% } %>
<% if (commentSetting.commentPlatform === 'disqus') { %>
<%- include('./includes/disqus') %>
<% } %>
<% } %>
<%- include('./includes/footer') %>
</div>
</div>
<script>
hljs.initHighlightingOnLoad()
let mainNavLinks = document.querySelectorAll(".markdownIt-TOC a");
// This should probably be throttled.
// Especially because it triggers during smooth scrolling.
// https://lodash.com/docs/4.17.10#throttle
// You could do like...
// window.addEventListener("scroll", () => {
// _.throttle(doThatStuff, 100);
// });
// Only not doing it here to keep this Pen dependency-free.
window.addEventListener("scroll", event => {
let fromTop = window.scrollY;
mainNavLinks.forEach((link, index) => {
let section = document.getElementById(decodeURI(link.hash).substring(1));
let nextSection = null
if (mainNavLinks[index + 1]) {
nextSection = document.getElementById(decodeURI(mainNavLinks[index + 1].hash).substring(1));
}
if (section.offsetTop <= fromTop) {
if (nextSection) {
if (nextSection.offsetTop > fromTop) {
link.classList.add("current");
} else {
link.classList.remove("current");
}
} else {
link.classList.add("current");
}
} else {
link.classList.remove("current");
}
});
});
</script>
</body>
</html>
================================================
FILE: public/default-files/themes/notes/templates/tag.ejs
================================================
<html>
<head>
<%- include('./includes/head', { siteTitle: `${tag.name} | ${themeConfig.siteName}` }) %>
<meta name="description" content="<%- site.customConfig.metaDescription || themeConfig.siteDescription %>" />
</head>
<body>
<div class="main">
<div class="main-content">
<%- include('./includes/header') %>
<div class="current-tag-container">
<h2 class="title">
标签:# <%= tag.name %>
</h2>
</div>
<%- include('./includes/post-list') %>
<%- include('./includes/pagination') %>
<%- include('./includes/footer') %>
</div>
</div>
</body>
</html>
================================================
FILE: public/default-files/themes/notes/templates/tags.ejs
================================================
<html>
<head>
<%- include('./includes/head', { siteTitle: themeConfig.siteName }) %>
<meta name="description" content="<%- site.customConfig.metaDescription || themeConfig.siteDescription %>" />
</head>
<body>
<div class="main">
<div class="main-content">
<%- include('./includes/header') %>
<div class="tags-container">
<% tags.forEach((tag) => { %>
<a class="tag" href="<%= tag.link %>"><%= tag.name %></a>
<% }); %>
</div>
<%- include('./includes/footer') %>
</div>
</div>
</body>
</html>
================================================
FILE: public/default-files/themes/paper/assets/styles/_core/base.less
================================================
/*! modern-normalize | MIT License | https://github.com/sindresorhus/modern-normalize */
/* Document
========================================================================== */
/**
* Use a better box model (opinionated).
*/
html {
box-sizing: border-box;
}
*,
*::before,
*::after {
box-sizing: inherit;
margin: 0;
padding: 0;
}
/**
* Use a more readable tab size (opinionated).
*/
:root {
-moz-tab-size: 4;
tab-size: 4;
}
/**
* 1. Correct the line height in all browsers.
* 2. Prevent adjustments of font size after orientation changes in iOS.
*/
html {
line-height: 1.15; /* 1 */
-webkit-text-size-adjust: 100%; /* 2 */
}
/* Sections
========================================================================== */
/**
* Remove the margin in all browsers.
*/
body {
margin: 0;
font-size: 14px;
}
/**
* Improve consistency of default fonts in all browsers. (https://github.com/sindresorhus/modern-normalize/issues/3)
*/
body {
font-family:
-apple-system,
BlinkMacSystemFont,
'Segoe UI',
Roboto,
"PingFang SC",
"Hiragino Sans GB",
"Microsoft YaHei",
Helvetica,
Arial,
sans-serif,
'Apple Color Emoji',
'Segoe UI Emoji',
'Segoe UI Symbol';
}
/* Grouping content
========================================================================== */
/**
* Add the correct height in Firefox.
*/
hr {
height: 0;
}
/* Text-level semantics
========================================================================== */
/**
* Add the correct text decoration in Chrome, Edge, and Safari.
*/
abbr[title] {
text-decoration: underline dotted;
}
/**
* Add the correct font weight in Chrome, Edge, and Safari.
*/
b,
strong {
font-weight: bolder;
}
/**
* 1. Improve consistency of default fonts in all browsers. (https://github.com/sindresorhus/modern-normalize/issues/3)
* 2. Correct the odd `em` font sizing in all browsers.
*/
code,
kbd,
samp,
pre {
font-family: SFMono-Regular, Consolas, 'Liberation Mono', Menlo, Courier, monospace; /* 1 */
font-size: 1em; /* 2 */
}
/**
* Add the correct font size in all browsers.
*/
small {
font-size: 80%;
}
/**
* Prevent `sub` and `sup` elements from affecting the line height in all browsers.
*/
sub,
sup {
font-size: 75%;
line-height: 0;
position: relative;
vertical-align: baseline;
}
sub {
bottom: -0.25em;
}
sup {
top: -0.5em;
}
/* Forms
========================================================================== */
/**
* 1. Change the font styles in all browsers.
* 2. Remove the margin in Firefox and Safari.
*/
button,
input,
optgroup,
select,
textarea {
font-family: inherit; /* 1 */
font-size: 100%; /* 1 */
line-height: 1.15; /* 1 */
margin: 0; /* 2 */
}
/**
* Remove the inheritance of text transform in Edge and Firefox.
* 1. Remove the inheritance of text transform in Firefox.
*/
button,
select { /* 1 */
text-transform: none;
}
/**
* Correct the inability to style clickable types in iOS and Safari.
*/
button,
[type='button'],
[type='reset'],
[type='submit'] {
-webkit-appearance: button;
}
/**
* Remove the inner border and padding in Firefox.
*/
button::-moz-focus-inner,
[type='button']::-moz-focus-inner,
[type='reset']::-moz-focus-inner,
[type='submit']::-moz-focus-inner {
border-style: none;
padding: 0;
}
/**
* Restore the focus styles unset by the previous rule.
*/
button:-moz-focusring,
[type='button']:-moz-focusring,
[type='reset']:-moz-focusring,
[type='submit']:-moz-focusring {
outline: 1px dotted ButtonText;
}
/**
* Correct the padding in Firefox.
*/
fieldset {
padding: 0.35em 0.75em 0.625em;
}
/**
* Remove the padding so developers are not caught out when they zero out `fieldset` elements in all browsers.
*/
legend {
padding: 0;
}
/**
* Add the correct vertical alignment in Chrome and Firefox.
*/
progress {
vertical-align: baseline;
}
/**
* Correct the cursor style of increment and decrement buttons in Safari.
*/
[type='number']::-webkit-inner-spin-button,
[type='number']::-webkit-outer-spin-button {
height: auto;
}
/**
* 1. Correct the odd appearance in Chrome and Safari.
* 2. Correct the outline style in Safari.
*/
[type='search'] {
-webkit-appearance: textfield; /* 1 */
outline-offset: -2px; /* 2 */
}
/**
* Remove the inner padding in Chrome and Safari on macOS.
*/
[type='search']::-webkit-search-decoration {
-webkit-appearance: none;
}
/**
* 1. Correct the inability to style clickable types in iOS and Safari.
* 2. Change font properties to `inherit` in Safari.
*/
::-webkit-file-upload-button {
-webkit-appearance: button; /* 1 */
font: inherit; /* 2 */
}
/* Interactive
========================================================================== */
/*
* Add the correct display in Chrome and Safari.
*/
summary {
display: list-item;
}
================================================
FILE: public/default-files/themes/paper/assets/styles/_core/colors.less
================================================
//
//
// 𝗖 𝗢 𝗟 𝗢 𝗥
// v 1.6.3
//
// ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
// General
// ───────────────────────────────────
@oc-white: #ffffff;
@oc-black: #000000;
// Gray
// ───────────────────────────────────
@oc-gray-list: #f8f9fa, #f1f3f5, #e9ecef, #dee2e6, #ced4da, #adb5bd, #868e96, #495057, #343a40, #212529;
@oc-gray-0: extract(@oc-gray-list, 1);
@oc-gray-1: extract(@oc-gray-list, 2);
@oc-gray-2: extract(@oc-gray-list, 3);
@oc-gray-3: extract(@oc-gray-list, 4);
@oc-gray-4: extract(@oc-gray-list, 5);
@oc-gray-5: extract(@oc-gray-list, 6);
@oc-gray-6: extract(@oc-gray-list, 7);
@oc-gray-7: extract(@oc-gray-list, 8);
@oc-gray-8: extract(@oc-gray-list, 9);
@oc-gray-9: extract(@oc-gray-list, 10);
// Red
// ───────────────────────────────────
@oc-red-list: #fff5f5, #ffe3e3, #ffc9c9, #ffa8a8, #ff8787, #ff6b6b, #fa5252, #f03e3e, #e03131, #c92a2a;
@oc-red-0: extract(@oc-red-list, 1);
@oc-red-1: extract(@oc-red-list, 2);
@oc-red-2: extract(@oc-red-list, 3);
@oc-red-3: extract(@oc-red-list, 4);
@oc-red-4: extract(@oc-red-list, 5);
@oc-red-5: extract(@oc-red-list, 6);
@oc-red-6: extract(@oc-red-list, 7);
@oc-red-7: extract(@oc-red-list, 8);
@oc-red-8: extract(@oc-red-list, 9);
@oc-red-9: extract(@oc-red-list, 10);
// Pink
// ───────────────────────────────────
@oc-pink-list: #fff0f6, #ffdeeb, #fcc2d7, #faa2c1, #f783ac, #f06595, #e64980, #d6336c, #c2255c, #a61e4d;
@oc-pink-0: extract(@oc-pink-list, 1);
@oc-pink-1: extract(@oc-pink-list, 2);
@oc-pink-2: extract(@oc-pink-list, 3);
@oc-pink-3: extract(@oc-pink-list, 4);
@oc-pink-4: extract(@oc-pink-list, 5);
@oc-pink-5: extract(@oc-pink-list, 6);
@oc-pink-6: extract(@oc-pink-list, 7);
@oc-pink-7: extract(@oc-pink-list, 8);
@oc-pink-8: extract(@oc-pink-list, 9);
@oc-pink-9: extract(@oc-pink-list, 10);
// Grape
// ───────────────────────────────────
@oc-grape-list: #f8f0fc, #f3d9fa, #eebefa, #e599f7, #da77f2, #cc5de8, #be4bdb, #ae3ec9, #9c36b5, #862e9c;
@oc-grape-0: extract(@oc-grape-list, 1);
@oc-grape-1: extract(@oc-grape-list, 2);
@oc-grape-2: extract(@oc-grape-list, 3);
@oc-grape-3: extract(@oc-grape-list, 4);
@oc-grape-4: extract(@oc-grape-list, 5);
@oc-grape-5: extract(@oc-grape-list, 6);
@oc-grape-6: extract(@oc-grape-list, 7);
@oc-grape-7: extract(@oc-grape-list, 8);
@oc-grape-8: extract(@oc-grape-list, 9);
@oc-grape-9: extract(@oc-grape-list, 10);
// Violet
// ───────────────────────────────────
@oc-violet-list: #f3f0ff, #e5dbff, #d0bfff, #b197fc, #9775fa, #845ef7, #7950f2, #7048e8, #6741d9, #5f3dc4;
@oc-violet-0: extract(@oc-violet-list, 1);
@oc-violet-1: extract(@oc-violet-list, 2);
@oc-violet-2: extract(@oc-violet-list, 3);
@oc-violet-3: extract(@oc-violet-list, 4);
@oc-violet-4: extract(@oc-violet-list, 5);
@oc-violet-5: extract(@oc-violet-list, 6);
@oc-violet-6: extract(@oc-violet-list, 7);
@oc-violet-7: extract(@oc-violet-list, 8);
@oc-violet-8: extract(@oc-violet-list, 9);
@oc-violet-9: extract(@oc-violet-list, 10);
// Indigo
// ───────────────────────────────────
@oc-indigo-list: #edf2ff, #dbe4ff, #bac8ff, #91a7ff, #748ffc, #5c7cfa, #4c6ef5, #4263eb, #3b5bdb, #364fc7;
@oc-indigo-0: extract(@oc-indigo-list, 1);
@oc-indigo-1: extract(@oc-indigo-list, 2);
@oc-indigo-2: extract(@oc-indigo-list, 3);
@oc-indigo-3: extract(@oc-indigo-list, 4);
@oc-indigo-4: extract(@oc-indigo-list, 5);
@oc-indigo-5: extract(@oc-indigo-list, 6);
@oc-indigo-6: extract(@oc-indigo-list, 7);
@oc-indigo-7: extract(@oc-indigo-list, 8);
@oc-indigo-8: extract(@oc-indigo-list, 9);
@oc-indigo-9: extract(@oc-indigo-list, 10);
// Blue
// ───────────────────────────────────
@oc-blue-list: #e7f5ff, #d0ebff, #a5d8ff, #74c0fc, #4dabf7, #339af0, #228be6, #1c7ed6, #1971c2, #1864ab;
@oc-blue-0: extract(@oc-blue-list, 1);
@oc-blue-1: extract(@oc-blue-list, 2);
@oc-blue-2: extract(@oc-blue-list, 3);
@oc-blue-3: extract(@oc-blue-list, 4);
@oc-blue-4: extract(@oc-blue-list, 5);
@oc-blue-5: extract(@oc-blue-list, 6);
@oc-blue-6: extract(@oc-blue-list, 7);
@oc-blue-7: extract(@oc-blue-list, 8);
@oc-blue-8: extract(@oc-blue-list, 9);
@oc-blue-9: extract(@oc-blue-list, 10);
// Cyan
// ───────────────────────────────────
@oc-cyan-list: #e3fafc, #c5f6fa, #99e9f2, #66d9e8, #3bc9db, #22b8cf, #15aabf, #1098ad, #0c8599, #0b7285;
@oc-cyan-0: extract(@oc-cyan-list, 1);
@oc-cyan-1: extract(@oc-cyan-list, 2);
@oc-cyan-2: extract(@oc-cyan-list, 3);
@oc-cyan-3: extract(@oc-cyan-list, 4);
@oc-cyan-4: extract(@oc-cyan-list, 5);
@oc-cyan-5: extract(@oc-cyan-list, 6);
@oc-cyan-6: extract(@oc-cyan-list, 7);
@oc-cyan-7: extract(@oc-cyan-list, 8);
@oc-cyan-8: extract(@oc-cyan-list, 9);
@oc-cyan-9: extract(@oc-cyan-list, 10);
// Teal
// ───────────────────────────────────
@oc-teal-list: #e6fcf5, #c3fae8, #96f2d7, #63e6be, #38d9a9, #20c997, #12b886, #0ca678, #099268, #087f5b;
@oc-teal-0: extract(@oc-teal-list, 1);
@oc-teal-1: extract(@oc-teal-list, 2);
@oc-teal-2: extract(@oc-teal-list, 3);
@oc-teal-3: extract(@oc-teal-list, 4);
@oc-teal-4: extract(@oc-teal-list, 5);
@oc-teal-5: extract(@oc-teal-list, 6);
@oc-teal-6: extract(@oc-teal-list, 7);
@oc-teal-7: extract(@oc-teal-list, 8);
@oc-teal-8: extract(@oc-teal-list, 9);
@oc-teal-9: extract(@oc-teal-list, 10);
// Green
// ───────────────────────────────────
@oc-green-list: #ebfbee, #d3f9d8, #b2f2bb, #8ce99a, #69db7c, #51cf66, #40c057, #37b24d, #2f9e44, #2b8a3e;
@oc-green-0: extract(@oc-green-list, 1);
@oc-green-1: extract(@oc-green-list, 2);
@oc-green-2: extract(@oc-green-list, 3);
@oc-green-3: extract(@oc-green-list, 4);
@oc-green-4: extract(@oc-green-list, 5);
@oc-green-5: extract(@oc-green-list, 6);
@oc-green-6: extract(@oc-green-list, 7);
@oc-green-7: extract(@oc-green-list, 8);
@oc-green-8: extract(@oc-green-list, 9);
@oc-green-9: extract(@oc-green-list, 10);
// Lime
// ───────────────────────────────────
@oc-lime-list: #f4fce3, #e9fac8, #d8f5a2, #c0eb75, #a9e34b, #94d82d, #82c91e, #74b816, #66a80f, #5c940d;
@oc-lime-0: extract(@oc-lime-list, 1);
@oc-lime-1: extract(@oc-lime-list, 2);
@oc-lime-2: extract(@oc-lime-list, 3);
@oc-lime-3: extract(@oc-lime-list, 4);
@oc-lime-4: extract(@oc-lime-list, 5);
@oc-lime-5: extract(@oc-lime-list, 6);
@oc-lime-6: extract(@oc-lime-list, 7);
@oc-lime-7: extract(@oc-lime-list, 8);
@oc-lime-8: extract(@oc-lime-list, 9);
@oc-lime-9: extract(@oc-lime-list, 10);
// Yellow
// ───────────────────────────────────
@oc-yellow-list: #fff9db, #fff3bf, #ffec99, #ffe066, #ffd43b, #fcc419, #fab005, #f59f00, #f08c00, #e67700;
@oc-yellow-0: extract(@oc-yellow-list, 1);
@oc-yellow-1: extract(@oc-yellow-list, 2);
@oc-yellow-2: extract(@oc-yellow-list, 3);
@oc-yellow-3: extract(@oc-yellow-list, 4);
@oc-yellow-4: extract(@oc-yellow-list, 5);
@oc-yellow-5: extract(@oc-yellow-list, 6);
@oc-yellow-6: extract(@oc-yellow-list, 7);
@oc-yellow-7: extract(@oc-yellow-list, 8);
@oc-yellow-8: extract(@oc-yellow-list, 9);
@oc-yellow-9: extract(@oc-yellow-list, 10);
// Orange
// ───────────────────────────────────
@oc-orange-list: #fff4e6, #ffe8cc, #ffd8a8, #ffc078, #ffa94d, #ff922b, #fd7e14, #f76707, #e8590c, #d9480f;
@oc-orange-0: extract(@oc-orange-list, 1);
@oc-orange-1: extract(@oc-orange-list, 2);
@oc-orange-2: extract(@oc-orange-list, 3);
@oc-orange-3: extract(@oc-orange-list, 4);
@oc-orange-4: extract(@oc-orange-list, 5);
@oc-orange-5: extract(@oc-orange-list, 6);
@oc-orange-6: extract(@oc-orange-list, 7);
@oc-orange-7: extract(@oc-orange-list, 8);
@oc-orange-8: extract(@oc-orange-list, 9);
@oc-orange-9: extract(@oc-orange-list, 10);
================================================
FILE: public/default-files/themes/paper/assets/styles/_core/github.less
================================================
.hljs {
display: block;
overflow-x: auto;
padding: 0.5em;
color: #333;
background: #f8f8f8;
}
.hljs-comment,
.hljs-quote {
color: #998;
font-style: italic;
}
.hljs-keyword,
.hljs-selector-tag,
.hljs-subst {
color: #333;
font-weight: bold;
}
.hljs-number,
.hljs-literal,
.hljs-variable,
.hljs-template-variable,
.hljs-tag .hljs-attr {
color: #008080;
}
.hljs-string,
.hljs-doctag {
color: #d14;
}
.hljs-title,
.hljs-section,
.hljs-selector-id {
color: #900;
font-weight: bold;
}
.hljs-subst {
font-weight: normal;
}
.hljs-type,
.hljs-class .hljs-title {
color: #458;
font-weight: bold;
}
.hljs-tag,
.hljs-name,
.hljs-attribute {
color: #000080;
font-weight: normal;
}
.hljs-regexp,
.hljs-link {
color: #009926;
}
.hljs-symbol,
.hljs-bullet {
color: #990073;
}
.hljs-built_in,
.hljs-builtin-name {
color: #0086b3;
}
.hljs-meta {
color: #999;
font-weight: bold;
}
.hljs-deletion {
background: #fdd;
}
.hljs-addition {
background: #dfd;
}
.hljs-emphasis {
font-style: italic;
}
.hljs-strong {
font-weight: bold;
}
================================================
FILE: public/default-files/themes/paper/assets/styles/main.less
================================================
@import "_core/colors";
@import "_core/github";
body {
background-image: url('../media/images/geometry2.png');
}
#top {
max-width: 1440px;
margin-top: 3rem;
}
article .article-meta a {
color: #ffffff;
}
.sidebar {
.sidebar-title {
margin-bottom: 24px;
}
ul {
padding-left: 0px;
}
li {
margin-bottom: 16px;
}
a.badge {
background-image: none;
margin: 4px;
color: #ffffff;
}
}
.info-container {
text-align: center;
.avatar {
width: 120px;
height: 120px;
border-top-left-radius: 185px 160px;
border-top-right-radius: 200px 195px;
border-bottom-right-radius: 160px 195px;
border-bottom-left-radius: 185px 190px;
margin-bottom: 24px;
}
}
.social-container {
margin-top: 24px;
a {
background-image: none;
margin: 4px;
}
}
.tags-container {
a {
margin: 8px;
background-image: none;
color: #ffffff;
}
}
.readmore-link {
background-image: none;
}
h1 {
font-size: 3.5rem;
}
article .article-title, h2 {
font-size: 2.5rem;
}
nav ul.inline li a {
display: block;
}
================================================
FILE: public/default-files/themes/paper/config.json
================================================
{
"name": "Paper",
"version": "1.0.0",
"author": "EryouHao",
"repository": "https://github.com/getgridea/gridea-theme-paper",
"customConfig": [
{
"name": "readMoreText",
"label": "Read More",
"group": "文案",
"value": "Read More",
"type": "input",
"note": "Read More"
},
{
"name": "nextArticleText",
"label": "下一篇",
"group": "文案",
"value": "下一篇",
"type": "input",
"note": "下一篇"
},
{
"name": "prevPageText",
"label": "上一页",
"group": "文案",
"value": "上一页",
"type": "input",
"note": "上一页"
},
{
"name": "nextPageText",
"label": "下一页",
"group": "文案",
"value": "下一页",
"type": "input",
"note": "下一页"
},
{
"name": "latestArticleText",
"label": "最新文章",
"group": "文案",
"value": "最新文章",
"type": "input",
"note": "最新文章"
},
{
"name": "tagListText",
"label": "标签列表",
"group": "文案",
"value": "标签列表",
"type": "input",
"note": "标签列表"
},
{
"name": "contentBgColor",
"label": "内容区背景色",
"group": "颜色",
"value": "#ffffff",
"type": "input",
"card": "color",
"note": "颜色字符串:(如:#EEEEEE、rgba(255, 255, 255, 0.9))"
},
{
"name": "navBgColor",
"label": "导航栏背景色",
"group": "颜色",
"value": "#ffffff",
"type": "input",
"card": "color",
"note": "颜色字符串:(如:#EEEEEE、rgba(255, 255, 255, 0.9))"
},
{
"name": "github",
"label": "Github",
"group": "社交",
"value": "",
"type": "input",
"note": "链接地址"
},
{
"name": "twitter",
"label": "Twitter",
"group": "社交",
"value": "",
"type": "input",
"note": "链接地址"
},
{
"name": "weibo",
"label": "微博",
"group": "社交",
"value": "",
"type": "input",
"note": "链接地址"
},
{
"name": "zhihu",
"label": "知乎",
"group": "社交",
"value": "",
"type": "input",
"note": "链接地址"
},
{
"name": "facebook",
"label": "Facebook",
"group": "社交",
"value": "",
"type": "input",
"note": "链接地址"
},
{
"name": "customCss",
"label": "自定义CSS",
"group": "自定义样式",
"value": "",
"type": "textarea",
"note": ""
},
{
"name": "ga",
"label": "跟踪 ID",
"group": "谷歌统计",
"value": "",
"type": "input",
"note": "UA-xxxxxxxxx-x"
}
]
}
================================================
FILE: public/default-files/themes/paper/style-override.js
================================================
const generateOverride = (params = {}) => {
let result = ''
// 内容区背景色 - contentBgColor
if (params.contentBgColor && params.contentBgColor !== '#ffffff') {
result += `
.paper {
background: ${params.contentBgColor};
}
`
}
// 导航栏背景色 - contentBgColor
if (params.navBgColor && params.navBgColor !== '#ffffff') {
result += `
.navbar {
background: ${params.navBgColor};
}
`
}
if (params.customCss) {
result += `
${params.customCss}
`
}
console.log('result', result)
return result
}
module.exports = generateOverride
================================================
FILE: public/default-files/themes/paper/templates/_blocks/head.ejs
================================================
<meta charset="utf-8" >
<title><%= siteTitle %></title>
<meta name="description" content="<%= themeConfig.siteDescription %>">
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
<link rel="shortcut icon" href="<%= themeConfig.domain %>/favicon.ico?v=<%= site.utils.now %>">
<link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.7.2/css/all.css" integrity="sha384-fnmOCqbTlWIlj8LyTjo7mOUStjsKC4pOpQbqyi7RrhN7udi9RwhKkMHpvLbHG9Sr" crossorigin="anonymous">
<link rel="stylesheet" href="https://unpkg.com/papercss@1.6.1/dist/paper.min.css" />
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/KaTeX/0.10.0/katex.min.css">
<link rel="stylesheet" href="<%= themeConfig.domain %>/styles/main.css">
<% if (typeof commentSetting !== 'undefined' && commentSetting.showComment) { %>
<% if (commentSetting.commentPlatform === 'gitalk') { %>
<link rel="stylesheet" href="https://unpkg.com/gitalk/dist/gitalk.css" />
<% } %>
<% if (commentSetting.commentPlatform === 'disqus') { %>
<link rel="stylesheet" href="https://unpkg.com/disqusjs@1.1/dist/disqusjs.css" />
<% } %>
<% } %>
<script src="//cdn.jsdelivr.net/gh/highlightjs/cdn-release@11.5.1/build/highlight.min.js"></script>
<link rel="stylesheet" href="https://unpkg.com/aos@next/dist/aos.css" />
<% if (site.customConfig.ga) { %>
<script async src="https://www.googletagmanager.com/gtag/js?id=<%= site.customConfig.ga %>"></script>
<script>
window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);}
gtag('js', new Date());
gtag('config', '<%= site.customConfig.ga %>');
</script>
<% } %>
================================================
FILE: public/default-files/themes/paper/templates/_blocks/header.ejs
================================================
<nav class="navbar border fixed split-nav">
<div class="nav-brand">
<h3><a href="<%= themeConfig.domain %>"><%= themeConfig.siteName %></a></h3>
</div>
<div class="collapsible">
<input id="collapsible1" type="checkbox" name="collapsible1">
<button>
<label for="collapsible1">
<div class="bar1"></div>
<div class="bar2"></div>
<div class="bar3"></div>
</label>
</button>
<div class="collapsible-body">
<ul class="inline">
<% menus.forEach(function(menu) { %>
<li>
<% if (menu.openType === 'External') { %>
<a href="<%= menu.link %>" class="menu" target="_blank">
<%= menu.name %>
</a>
<% } else { %>
<a href="<%= menu.link %>" class="menu">
<%= menu.name %>
</a>
<% } %>
</li>
<% }); %>
</ul>
</div>
</div>
</nav>
================================================
FILE: public/default-files/themes/paper/templates/_blocks/pagination.ejs
================================================
<div class="row flex-edges">
<% if (pagination.prev) { %>
<a href="<%= pagination.prev %>" class="paper-btn">
<%= site.customConfig.prevPageText || '上一页' %>
</a>
<% } %>
<% if (pagination.next) { %>
<a href="<%= pagination.next %>" class="paper-btn">
<%= site.customConfig.nextPageText || '下一页' %>
</a>
<% } %>
</div>
================================================
FILE: public/default-files/themes/paper/templates/_blocks/post-list.ejs
================================================
<% posts.forEach(function(post) { %>
<article class="article">
<h2 class="article-title">
<a href="<%= post.link %>"><%= post.title %></a>
</h2>
<p class="article-meta">
<%= post.dateFormat %>
<% post.tags.forEach(function(tag, tagIndex) { %>
<a href="<%= tag.link %>" class="badge <%= ['', 'secondary', 'success', 'warning', 'secondary'][Math.floor(Math.random()*5)] %>">
<%= tag.name %>
</a>
<% }); %>
</p>
<p class="text-lead">
<%- post.abstract %>
</p>
<div class="row">
<a href="<%= post.link %>" class="readmore-link">
<button>
<%= site.customConfig.readMoreText || 'Read More' %>
</button>
</a>
</div>
</article>
<% }); %>
================================================
FILE: public/default-files/themes/paper/templates/_blocks/scripts.ejs
================================================
<script src="https://unpkg.com/aos@next/dist/aos.js"></script>
<script type="application/javascript">
AOS.init();
hljs.initHighlightingOnLoad()
</script>
<% if (typeof commentSetting !== 'undefined' && commentSetting.showComment) { %>
<% if (commentSetting.commentPlatform === 'gitalk') { %>
<script src="https://unpkg.com/gitalk/dist/gitalk.min.js"></script>
<script>
var gitalk = new Gitalk({
clientID: '<%= commentSetting.gitalkSetting.clientId %>',
clientSecret: '<%= commentSetting.gitalkSetting.clientSecret %>',
repo: '<%= commentSetting.gitalkSetting.repository %>',
owner: '<%= commentSetting.gitalkSetting.owner %>',
admin: ['<%= commentSetting.gitalkSetting.owner %>'],
id: (location.pathname).substring(0, 49), // Ensure uniqueness and length less than 50
distractionFreeMode: false // Facebook-like distraction free mode
})
gitalk.render('gitalk-container')
</script>
<% } %>
<% if (commentSetting.commentPlatform === 'disqus') { %>
<script src="https://unpkg.com/disqusjs@1.1/dist/disqus.js"></script>
<script>
var options = {
shortname: '<%= commentSetting.disqusSetting.shortname %>',
apikey: '<%= commentSetting.disqusSetting.apikey %>',
}
if ('<%= commentSetting.disqusSetting.api %>') {
options.api = '<%= commentSetting.disqusSetting.api %>'
}
var dsqjs = new DisqusJS(options)
</script>
<% } %>
<% } %>
================================================
FILE: public/default-files/themes/paper/templates/_blocks/sidebar.ejs
================================================
<div class="sm-12 md-4 col sidebar">
<div class="paper info-container">
<img src="<%= themeConfig.domain %>/images/avatar.png?v=<%= site.utils.now %>" class="no-responsive avatar">
<div class="text-muted"><%- themeConfig.siteDescription %></div>
<div class="social-container">
<% ['github', 'twitter', 'weibo', 'zhihu', 'facebook'].forEach((item) => { %>
<% if (site.customConfig[item]) { %>
<a href="<%= site.customConfig[item] %>" target="_blank">
<i class="fab fa-<%= item %>"></i>
</a>
<% } %>
<% }) %>
</div>
</div>
<div class="paper">
<div class="sidebar-title">
<%= site.customConfig.latestArticleText || '最新文章' %>
</div>
<div class="row">
<ul>
<% site.posts.forEach(function(post, index) { %>
<% if (index < 10) { %>
<li>
<a href="<%= post.link %>"><%= post.title %></a>
</li>
<% } %>
<% }); %>
</ul>
</div>
</div>
<div class="paper">
<div class="sidebar-title">
<%= site.customConfig.tagListText || '标签列表' %>
</div>
<div class="row">
<% site.tags.forEach(function(tag, tagIndex) { %>
<a href="<%= tag.link %>" class="badge <%= ['', 'secondary', 'success', 'warning', 'secondary'][Math.floor(Math.random()*5)] %>">
<%= tag.name %>
</a>
<% }); %>
</div>
</div>
<div class="paper">
<%- themeConfig.footerInfo %> | <a class="rss" href="<%= themeConfig.domain %>/atom.xml" target="_blank">RSS</a>
</div>
</div>
================================================
FILE: public/default-files/themes/paper/templates/archives.ejs
================================================
<!DOCTYPE html>
<html>
<head>
<%- include('./_blocks/head', { siteTitle: `文章归档 | ${themeConfig.siteName}` }) %>
</head>
<body>
<%- include('./_blocks/header') %>
<div id="top" class="row site">
<div class="sm-12 md-8 col">
<div class="paper">
<% let years = []; posts.forEach((item) => { const year = item.date.substring(0, 4); if (!years.includes(year)) { years.push(year); } }); %>
<h2 class="archives-title">文章归档</h2>
<div class="archives-container">
<% years.forEach(function(year) { %>
<h3 class="year" data-aos-delay="500"><%- year %></h3>
<% posts.forEach(function(post) { %>
<%if (post.date.indexOf(year) !== -1) { %>
<article class="post">
<a href="<%= post.link %>">
<h4 class="post-title">
<%= post.title %>
</h4>
</a>
</article>
<% } %>
<% }); %>
<% }); %>
</div>
</div>
<%- include('./_blocks/pagination') %>
</div>
<%- include('./_blocks/sidebar') %>
<%- include('./_blocks/scripts') %>
</body>
</html>
================================================
FILE: public/default-files/themes/paper/templates/index.ejs
================================================
<!DOCTYPE html>
<html>
<head>
<%- include('./_blocks/head', { siteTitle: themeConfig.siteName }) %>
</head>
<body>
<%- include('./_blocks/header') %>
<div id="top" class="row site">
<div class="sm-12 md-8 col">
<div class="paper">
<%- include('./_blocks/post-list') %>
</div>
<%- include('./_blocks/pagination') %>
</div>
<%- include('./_blocks/sidebar') %>
</div>
<%- include('./_blocks/scripts') %>
</body>
</html>
================================================
FILE: public/default-files/themes/paper/templates/post.ejs
================================================
<!DOCTYPE html>
<html>
<head>
<%- include('./_blocks/head', { siteTitle: `${post.title} | ${themeConfig.siteName}` }) %>
</head>
<body>
<%- include('./_blocks/header') %>
<div id="top" class="row site">
<div class="sm-12 md-8 col">
<div class="paper">
<article class="article">
<h1><%= post.title %></h1>
<p class="article-meta">
<%= post.dateFormat %>
<% post.tags.forEach(function(tag, tagIndex) { %>
<a href="<%= tag.link %>" class="badge <%= ['', 'secondary', 'success', 'warning', 'secondary'][Math.floor(Math.random()*5)] %>">
<%= tag.name %>
</a>
<% }); %>
</p>
<% if (post.feature) { %>
<img src="<%= post.feature %>" alt="<%= post.title %>">
<% } %>
<div class="post-content" v-pre>
<%- post.content %>
</div>
</article>
</div>
<div class="paper" data-aos="fade-in">
<% if (post.nextPost && !post.hideInList) { %>
<div class="next-post">
<div class="next">
<%= site.customConfig.nextArticleText || '下一篇' %>
</div>
<a href="<%= post.nextPost.link %>">
<h3 class="post-title">
<%= post.nextPost.title %>
</h3>
</a>
</div>
<% } %>
</div>
<% if (typeof commentSetting !== 'undefined' && commentSetting.showComment) { %>
<% if (commentSetting.commentPlatform === 'gitalk') { %>
<div class="paper" data-aos="fade-in">
<div id="gitalk-container"></div>
</div>
<% } %>
<% if (commentSetting.commentPlatform === 'disqus') { %>
<div class="paper" data-aos="fade-in">
<div id="disqus_thread"></div>
</div>
<% } %>
<% } %>
</div>
<%- include('./_blocks/sidebar') %>
</div>
<%- include('./_blocks/scripts') %>
</body>
</html>
================================================
FILE: public/default-files/themes/paper/templates/tag.ejs
================================================
<!DOCTYPE html>
<html>
<head>
<%- include('./_blocks/head', { siteTitle: `${tag.name} | ${themeConfig.siteName}` }) %>
</head>
<body>
<%- include('./_blocks/header') %>
<div id="top" class="row site">
<div class="sm-12 md-8 col">
<div class="paper">
<h2 class="current-tag">标签: <%= tag.name %></h2>
<%- include('./_blocks/post-list') %>
</div>
<%- include('./_blocks/pagination') %>
</div>
<%- include('./_blocks/sidebar') %>
</div>
<%- include('./_blocks/scripts') %>
</body>
</html>
================================================
FILE: public/default-files/themes/paper/templates/tags.ejs
================================================
<!DOCTYPE html>
<html>
<head>
<%- include('./_blocks/head', { siteTitle: `标签列表 | ${themeConfig.siteName}` }) %>
</head>
<body>
<%- include('./_blocks/header') %>
<div id="top" class="row site">
<div class="sm-12 md-8 col">
<div class="paper">
<h2 class="tag-list-title">标签列表</h2>
<div class="row tags-container">
<% tags.forEach(function(tag, tagIndex) { %>
<a href="<%= tag.link %>" class="badge <%= ['', 'secondary', 'success', 'warning', 'secondary'][Math.floor(Math.random()*5)] %>">
<%= tag.name %>
</a>
<% }); %>
</div>
</div>
</div>
<%- include('./_blocks/sidebar') %>
</div>
<%- include('./_blocks/scripts') %>
</body>
</html>
================================================
FILE: public/default-files/themes/simple/assets/styles/_core/a11y-dark.less
================================================
/* a11y-dark theme */
/* Based on the Tomorrow Night Eighties theme: https://github.com/isagalaev/highlight.js/blob/master/src/styles/tomorrow-night-eighties.css */
/* @author: ericwbailey */
/* Comment */
.hljs-comment,
.hljs-quote {
color: #d4d0ab;
}
/* Red */
.hljs-variable,
.hljs-template-variable,
.hljs-tag,
.hljs-name,
.hljs-selector-id,
.hljs-selector-class,
.hljs-regexp,
.hljs-deletion {
color: #ffa07a;
}
/* Orange */
.hljs-number,
.hljs-built_in,
.hljs-builtin-name,
.hljs-literal,
.hljs-type,
.hljs-params,
.hljs-meta,
.hljs-link {
color: #f5ab35;
}
/* Yellow */
.hljs-attribute {
color: #ffd700;
}
/* Green */
.hljs-string,
.hljs-symbol,
.hljs-bullet,
.hljs-addition {
color: #abe338;
}
/* Blue */
.hljs-title,
.hljs-section {
color: #00e0e0;
}
/* Purple */
.hljs-keyword,
.hljs-selector-tag {
color: #dcc6e0;
}
.hljs {
display: block;
overflow-x: auto;
background: #2b2b2b;
color: #f8f8f2;
padding: 0.5em;
}
.hljs-emphasis {
font-style: italic;
}
.hljs-strong {
font-weight: bold;
}
@media screen and (-ms-high-contrast: active) {
.hljs-addition,
.hljs-attribute,
.hljs-built_in,
.hljs-builtin-name,
.hljs-bullet,
.hljs-comment,
.hljs-link,
.hljs-literal,
.hljs-meta,
.hljs-number,
.hljs-params,
.hljs-string,
.hljs-symbol,
.hljs-type,
.hljs-quote {
color: highlight;
}
.hljs-keyword,
.hljs-selector-tag {
font-weight: bold;
}
}
================================================
FILE: public/default-files/themes/simple/assets/styles/_core/atom-one-dark.less
================================================
/*
Atom One Dark by Daniel Gamage
Original One Dark Syntax theme from https://github.com/atom/one-dark-syntax
base: #282c34
mono-1: #abb2bf
mono-2: #818896
mono-3: #5c6370
hue-1: #56b6c2
hue-2: #61aeee
hue-3: #c678dd
hue-4: #98c379
hue-5: #e06c75
hue-5-2: #be5046
hue-6: #d19a66
hue-6-2: #e6c07b
*/
.hljs {
display: block;
overflow-x: auto;
padding: 0.5em;
color: #abb2bf;
background: #282c34;
}
.hljs-comment,
.hljs-quote {
color: #5c6370;
font-style: italic;
}
.hljs-doctag,
.hljs-keyword,
.hljs-formula {
color: #c678dd;
}
.hljs-section,
.hljs-name,
.hljs-selector-tag,
.hljs-deletion,
.hljs-subst {
color: #e06c75;
}
.hljs-literal {
color: #56b6c2;
}
.hljs-string,
.hljs-regexp,
.hljs-addition,
.hljs-attribute,
.hljs-meta-string {
color: #98c379;
}
.hljs-built_in,
.hljs-class .hljs-title {
color: #e6c07b;
}
.hljs-attr,
.hljs-variable,
.hljs-template-variable,
.hljs-type,
.hljs-selector-class,
.hljs-selector-attr,
.hljs-selector-pseudo,
.hljs-number {
color: #d19a66;
}
.hljs-symbol,
.hljs-bullet,
.hljs-link,
.hljs-meta,
.hljs-selector-id,
.hljs-title {
color: #61aeee;
}
.hljs-emphasis {
font-style: italic;
}
.hljs-strong {
font-weight: bold;
}
.hljs-link {
text-decoration: underline;
}
================================================
FILE: public/default-files/themes/simple/assets/styles/_core/base.less
================================================
/*! modern-normalize | MIT License | https://github.com/sindresorhus/modern-normalize */
/* Document
========================================================================== */
/**
* Use a better box model (opinionated).
*/
html {
box-sizing: border-box;
}
*,
*::before,
*::after {
box-sizing: inherit;
margin: 0;
padding: 0;
}
/**
* Use a more readable tab size (opinionated).
*/
:root {
-moz-tab-size: 4;
tab-size: 4;
}
/**
* 1. Correct the line height in all browsers.
* 2. Prevent adjustments of font size after orientation changes in iOS.
*/
html {
line-height: 1.15; /* 1 */
-webkit-text-size-adjust: 100%; /* 2 */
}
/* Sections
========================================================================== */
/**
* Remove the margin in all browsers.
*/
body {
margin: 0;
font-size: 14px;
}
/**
* Improve consistency of default fonts in all browsers. (https://github.com/sindresorhus/modern-normalize/issues/3)
*/
body {
font-family:
-apple-system,
BlinkMacSystemFont,
'Segoe UI',
Roboto,
"PingFang SC",
"Hiragino Sans GB",
"Microsoft YaHei",
Helvetica,
Arial,
sans-serif,
'Apple Color Emoji',
'Segoe UI Emoji',
'Segoe UI Symbol';
}
/* Grouping content
========================================================================== */
/**
* Add the correct height in Firefox.
*/
hr {
height: 0;
}
/* Text-level semantics
========================================================================== */
/**
* Add the correct text decoration in Chrome, Edge, and Safari.
*/
abbr[title] {
text-decoration: underline dotted;
}
/**
* Add the correct font weight in Chrome, Edge, and Safari.
*/
b,
strong {
font-weight: bolder;
}
/**
* 1. Improve consistency of default fonts in all browsers. (https://github.com/sindresorhus/modern-normalize/issues/3)
* 2. Correct the odd `em` font sizing in all browsers.
*/
code,
kbd,
samp,
pre {
font-family: SFMono-Regular, Consolas, 'Liberation Mono', Menlo, Courier, monospace; /* 1 */
font-size: 1em; /* 2 */
}
/**
* Add the correct font size in all browsers.
*/
small {
font-size: 80%;
}
/**
* Prevent `sub` and `sup` elements from affecting the line height in all browsers.
*/
sub,
sup {
font-size: 75%;
line-height: 0;
position: relative;
vertical-align: baseline;
}
sub {
bottom: -0.25em;
}
sup {
top: -0.5em;
}
/* Forms
========================================================================== */
/**
* 1. Change the font styles in all browsers.
* 2. Remove the margin in Firefox and Safari.
*/
button,
input,
optgroup,
select,
textarea {
font-family: inherit; /* 1 */
font-size: 100%; /* 1 */
line-height: 1.15; /* 1 */
margin: 0; /* 2 */
}
/**
* Remove the inheritance of text transform in Edge and Firefox.
* 1. Remove the inheritance of text transform in Firefox.
*/
button,
select { /* 1 */
text-transform: none;
}
/**
* Correct the inability to style clickable types in iOS and Safari.
*/
button,
[type='button'],
[type='reset'],
[type='submit'] {
-webkit-appearance: button;
}
/**
* Remove the inner border and padding in Firefox.
*/
button::-moz-focus-inner,
[type='button']::-moz-focus-inner,
[type='reset']::-moz-focus-inner,
[type='submit']::-moz-focus-inner {
border-style: none;
padding: 0;
}
/**
* Restore the focus styles unset by the previous rule.
*/
button:-moz-focusring,
[type='button']:-moz-focusring,
[type='reset']:-moz-focusring,
[type='submit']:-moz-focusring {
outline: 1px dotted ButtonText;
}
/**
* Correct the padding in Firefox.
*/
fieldset {
padding: 0.35em 0.75em 0.625em;
}
/**
* Remove the padding so developers are not caught out when they zero out `fieldset` elements in all browsers.
*/
legend {
padding: 0;
}
/**
* Add the correct vertical alignment in Chrome and Firefox.
*/
progress {
vertical-align: baseline;
}
/**
* Correct the cursor style of increment and decrement buttons in Safari.
*/
[type='number']::-webkit-inner-spin-button,
[type='number']::-webkit-outer-spin-button {
height: auto;
}
/**
* 1. Correct the odd appearance in Chrome and Safari.
* 2. Correct the outline style in Safari.
*/
[type='search'] {
-webkit-appearance: textfield; /* 1 */
outline-offset: -2px; /* 2 */
}
/**
* Remove the inner padding in Chrome and Safari on macOS.
*/
[type='search']::-webkit-search-decoration {
-webkit-appearance: none;
}
/**
* 1. Correct the inability to style clickable types in iOS and Safari.
* 2. Change font properties to `inherit` in Safari.
*/
::-webkit-file-upload-button {
-webkit-appearance: button; /* 1 */
font: inherit; /* 2 */
}
/* Interactive
========================================================================== */
/*
* Add the correct display in Chrome and Safari.
*/
summary {
display: list-item;
}
================================================
FILE: public/default-files/themes/simple/assets/styles/_core/colors.less
================================================
//
//
// 𝗖 𝗢 𝗟 𝗢 𝗥
// v 1.6.3
//
// ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
// General
// ───────────────────────────────────
@oc-white: #ffffff;
@oc-black: #000000;
// Gray
// ───────────────────────────────────
@oc-gray-list: #f8f9fa, #f1f3f5, #e9ecef, #dee2e6, #ced4da, #adb5bd, #868e96, #495057, #343a40, #212529;
@oc-gray-0: extract(@oc-gray-list, 1);
@oc-gray-1: extract(@oc-gray-list, 2);
@oc-gray-2: extract(@oc-gray-list, 3);
@oc-gray-3: extract(@oc-gray-list, 4);
@oc-gray-4: extract(@oc-gray-list, 5);
@oc-gray-5: extract(@oc-gray-list, 6);
@oc-gray-6: extract(@oc-gray-list, 7);
@oc-gray-7: extract(@oc-gray-list, 8);
@oc-gray-8: extract(@oc-gray-list, 9);
@oc-gray-9: extract(@oc-gray-list, 10);
// Red
// ───────────────────────────────────
@oc-red-list: #fff5f5, #ffe3e3, #ffc9c9, #ffa8a8, #ff8787, #ff6b6b, #fa5252, #f03e3e, #e03131, #c92a2a;
@oc-red-0: extract(@oc-red-list, 1);
@oc-red-1: extract(@oc-red-list, 2);
@oc-red-2: extract(@oc-red-list, 3);
@oc-red-3: extract(@oc-red-list, 4);
@oc-red-4: extract(@oc-red-list, 5);
@oc-red-5: extract(@oc-red-list, 6);
@oc-red-6: extract(@oc-red-list, 7);
@oc-red-7: extract(@oc-red-list, 8);
@oc-red-8: extract(@oc-red-list, 9);
@oc-red-9: extract(@oc-red-list, 10);
// Pink
// ───────────────────────────────────
@oc-pink-list: #fff0f6, #ffdeeb, #fcc2d7, #faa2c1, #f783ac, #f06595, #e64980, #d6336c, #c2255c, #a61e4d;
@oc-pink-0: extract(@oc-pink-list, 1);
@oc-pink-1: extract(@oc-pink-list, 2);
@oc-pink-2: extract(@oc-pink-list, 3);
@oc-pink-3: extract(@oc-pink-list, 4);
@oc-pink-4: extract(@oc-pink-list, 5);
@oc-pink-5: extract(@oc-pink-list, 6);
@oc-pink-6: extract(@oc-pink-list, 7);
@oc-pink-7: extract(@oc-pink-list, 8);
@oc-pink-8: extract(@oc-pink-list, 9);
@oc-pink-9: extract(@oc-pink-list, 10);
// Grape
// ───────────────────────────────────
@oc-grape-list: #f8f0fc, #f3d9fa, #eebefa, #e599f7, #da77f2, #cc5de8, #be4bdb, #ae3ec9, #9c36b5, #862e9c;
@oc-grape-0: extract(@oc-grape-list, 1);
@oc-grape-1: extract(@oc-grape-list, 2);
@oc-grape-2: extract(@oc-grape-list, 3);
@oc-grape-3: extract(@oc-grape-list, 4);
@oc-grape-4: extract(@oc-grape-list, 5);
@oc-grape-5: extract(@oc-grape-list, 6);
@oc-grape-6: extract(@oc-grape-list, 7);
@oc-grape-7: extract(@oc-grape-list, 8);
@oc-grape-8: extract(@oc-grape-list, 9);
@oc-grape-9: extract(@oc-grape-list, 10);
// Violet
// ───────────────────────────────────
@oc-violet-list: #f3f0ff, #e5dbff, #d0bfff, #b197fc, #9775fa, #845ef7, #7950f2, #7048e8, #6741d9, #5f3dc4;
@oc-violet-0: extract(@oc-violet-list, 1);
@oc-violet-1: extract(@oc-violet-list, 2);
@oc-violet-2: extract(@oc-violet-list, 3);
@oc-violet-3: extract(@oc-violet-list, 4);
@oc-violet-4: extract(@oc-violet-list, 5);
@oc-violet-5: extract(@oc-violet-list, 6);
@oc-violet-6: extract(@oc-violet-list, 7);
@oc-violet-7: extract(@oc-violet-list, 8);
@oc-violet-8: extract(@oc-violet-list, 9);
@oc-violet-9: extract(@oc-violet-list, 10);
// Indigo
// ───────────────────────────────────
@oc-indigo-list: #edf2ff, #dbe4ff, #bac8ff, #91a7ff, #748ffc, #5c7cfa, #4c6ef5, #4263eb, #3b5bdb, #364fc7;
@oc-indigo-0: extract(@oc-indigo-list, 1);
@oc-indigo-1: extract(@oc-indigo-list, 2);
@oc-indigo-2: extract(@oc-indigo-list, 3);
@oc-indigo-3: extract(@oc-indigo-list, 4);
@oc-indigo-4: extract(@oc-indigo-list, 5);
@oc-indigo-5: extract(@oc-indigo-list, 6);
@oc-indigo-6: extract(@oc-indigo-list, 7);
@oc-indigo-7: extract(@oc-indigo-list, 8);
@oc-indigo-8: extract(@oc-indigo-list, 9);
@oc-indigo-9: extract(@oc-indigo-list, 10);
// Blue
// ───────────────────────────────────
@oc-blue-list: #e7f5ff, #d0ebff, #a5d8ff, #74c0fc, #4dabf7, #339af0, #228be6, #1c7ed6, #1971c2, #1864ab;
@oc-blue-0: extract(@oc-blue-list, 1);
@oc-blue-1: extract(@oc-blue-list, 2);
@oc-blue-2: extract(@oc-blue-list, 3);
@oc-blue-3: extract(@oc-blue-list, 4);
@oc-blue-4: extract(@oc-blue-list, 5);
@oc-blue-5: extract(@oc-blue-list, 6);
@oc-blue-6: extract(@oc-blue-list, 7);
@oc-blue-7: extract(@oc-blue-list, 8);
@oc-blue-8: extract(@oc-blue-list, 9);
@oc-blue-9: extract(@oc-blue-list, 10);
// Cyan
// ───────────────────────────────────
@oc-cyan-list: #e3fafc, #c5f6fa, #99e9f2, #66d9e8, #3bc9db, #22b8cf, #15aabf, #1098ad, #0c8599, #0b7285;
@oc-cyan-0: extract(@oc-cyan-list, 1);
@oc-cyan-1: extract(@oc-cyan-list, 2);
@oc-cyan-2: extract(@oc-cyan-list, 3);
@oc-cyan-3: extract(@oc-cyan-list, 4);
@oc-cyan-4: extract(@oc-cyan-list, 5);
@oc-cyan-5: extract(@oc-cyan-list, 6);
@oc-cyan-6: extract(@oc-cyan-list, 7);
@oc-cyan-7: extract(@oc-cyan-list, 8);
@oc-cyan-8: extract(@oc-cyan-list, 9);
@oc-cyan-9: extract(@oc-cyan-list, 10);
// Teal
// ───────────────────────────────────
@oc-teal-list: #e6fcf5, #c3fae8, #96f2d7, #63e6be, #38d9a9, #20c997, #12b886, #0ca678, #099268, #087f5b;
@oc-teal-0: extract(@oc-teal-list, 1);
@oc-teal-1: extract(@oc-teal-list, 2);
@oc-teal-2: extract(@oc-teal-list, 3);
@oc-teal-3: extract(@oc-teal-list, 4);
@oc-teal-4: extract(@oc-teal-list, 5);
@oc-teal-5: extract(@oc-teal-list, 6);
@oc-teal-6: extract(@oc-teal-list, 7);
@oc-teal-7: extract(@oc-teal-list, 8);
@oc-teal-8: extract(@oc-teal-list, 9);
@oc-teal-9: extract(@oc-teal-list, 10);
// Green
// ───────────────────────────────────
@oc-green-list: #ebfbee, #d3f9d8, #b2f2bb, #8ce99a, #69db7c, #51cf66, #40c057, #37b24d, #2f9e44, #2b8a3e;
@oc-green-0: extract(@oc-green-list, 1);
@oc-green-1: extract(@oc-green-list, 2);
@oc-green-2: extract(@oc-green-list, 3);
@oc-green-3: extract(@oc-green-list, 4);
@oc-green-4: extract(@oc-green-list, 5);
@oc-green-5: extract(@oc-green-list, 6);
@oc-green-6: extract(@oc-green-list, 7);
@oc-green-7: extract(@oc-green-list, 8);
@oc-green-8: extract(@oc-green-list, 9);
@oc-green-9: extract(@oc-green-list, 10);
// Lime
// ───────────────────────────────────
@oc-lime-list: #f4fce3, #e9fac8, #d8f5a2, #c0eb75, #a9e34b, #94d82d, #82c91e, #74b816, #66a80f, #5c940d;
@oc-lime-0: extract(@oc-lime-list, 1);
@oc-lime-1: extract(@oc-lime-list, 2);
@oc-lime-2: extract(@oc-lime-list, 3);
@oc-lime-3: extract(@oc-lime-list, 4);
@oc-lime-4: extract(@oc-lime-list, 5);
@oc-lime-5: extract(@oc-lime-list, 6);
@oc-lime-6: extract(@oc-lime-list, 7);
@oc-lime-7: extract(@oc-lime-list, 8);
@oc-lime-8: extract(@oc-lime-list, 9);
@oc-lime-9: extract(@oc-lime-list, 10);
// Yellow
// ───────────────────────────────────
@oc-yellow-list: #fff9db, #fff3bf, #ffec99, #ffe066, #ffd43b, #fcc419, #fab005, #f59f00, #f08c00, #e67700;
@oc-yellow-0: extract(@oc-yellow-list, 1);
@oc-yellow-1: extract(@oc-yellow-list, 2);
@oc-yellow-2: extract(@oc-yellow-list, 3);
@oc-yellow-3: extract(@oc-yellow-list, 4);
@oc-yellow-4: extract(@oc-yellow-list, 5);
@oc-yellow-5: extract(@oc-yellow-list, 6);
@oc-yellow-6: extract(@oc-yellow-list, 7);
@oc-yellow-7: extract(@oc-yellow-list, 8);
@oc-yellow-8: extract(@oc-yellow-list, 9);
@oc-yellow-9: extract(@oc-yellow-list, 10);
// Orange
// ───────────────────────────────────
@oc-orange-list: #fff4e6, #ffe8cc, #ffd8a8, #ffc078, #ffa94d, #ff922b, #fd7e14, #f76707, #e8590c, #d9480f;
@oc-orange-0: extract(@oc-orange-list, 1);
@oc-orange-1: extract(@oc-orange-list, 2);
@oc-orange-2: extract(@oc-orange-list, 3);
@oc-orange-3: extract(@oc-orange-list, 4);
@oc-orange-4: extract(@oc-orange-list, 5);
@oc-orange-5: extract(@oc-orange-list, 6);
@oc-orange-6: extract(@oc-orange-list, 7);
@oc-orange-7: extract(@oc-orange-list, 8);
@oc-orange-8: extract(@oc-orange-list, 9);
@oc-orange-9: extract(@oc-orange-list, 10);
================================================
FILE: public/default-files/themes/simple/assets/styles/_core/github.less
================================================
.hljs {
display: block;
overflow-x: auto;
padding: 0.5em;
color: #333;
background: #f8f8f8;
}
.hljs-comment,
.hljs-quote {
color: #998;
font-style: italic;
}
.hljs-keyword,
.hljs-selector-tag,
.hljs-subst {
color: #333;
font-weight: bold;
}
.hljs-number,
.hljs-literal,
.hljs-variable,
.hljs-template-variable,
.hljs-tag .hljs-attr {
color: #008080;
}
.hljs-string,
.hljs-doctag {
color: #d14;
}
.hljs-title,
.hljs-section,
.hljs-selector-id {
color: #900;
font-weight: bold;
}
.hljs-subst {
font-weight: normal;
}
.hljs-type,
.hljs-class .hljs-title {
color: #458;
font-weight: bold;
}
.hljs-tag,
.hljs-name,
.hljs-attribute {
color: #000080;
font-weight: normal;
}
.hljs-regexp,
.hljs-link {
color: #009926;
}
.hljs-symbol,
.hljs-bullet {
color: #990073;
}
.hljs-built_in,
.hljs-builtin-name {
color: #0086b3;
}
.hljs-meta {
color: #999;
font-weight: bold;
}
.hljs-deletion {
background: #fdd;
}
.hljs-addition {
background: #dfd;
}
.hljs-emphasis {
font-style: italic;
}
.hljs-strong {
font-weight: bold;
}
================================================
FILE: public/default-files/themes/simple/assets/styles/main.less
================================================
@import "_core/colors";
@import "_core/base";
@import "_core/a11y-dark";
body {
background: @oc-gray-0;
color: @oc-gray-7;
font-size: 16px;
}
a {
text-decoration: none;
color: @oc-gray-7;
}
.sidebar {
width: 320px;
position: fixed;
left: 0;
top: 0;
bottom: 0;
background-color: #7c8280;
background-size: cover;
background-position: center;
background-image: url('../media/images/sidebar-bg.jpg');
display: flex;
flex-direction: column;
overflow-y: scroll;
.menu-btn {
display: none;
}
.top-container {
text-align: center;
padding: 48px 16px;
flex: 1;
.site-logo {
width: 80px;
height: 80px;
border-radius: 50%;
border: 2px solid #F1F3F5;
box-shadow: 0 3px 6px rgba(0, 0, 0, 0.16);
}
.site-title {
font-size: 24px;
padding: 32px 0;
color: @oc-gray-3;
}
.site-nav {
display: block;
padding: 8px 16px;
margin: 16px 0;
color: @oc-gray-3;
transition: all 0.3s;
&:hover {
color: @oc-gray-0;
}
}
}
.bottom-container {
padding: 24px 16px;
color: @oc-gray-3;
font-size: 12px;
.site-description {
padding: 16px 0;
}
a {
color: #fff;
}
}
}
.main-container {
margin-left: 320px;
}
.content-container {
max-width: 1064px;
margin: 0 auto;
padding: 48px 32px;
}
.post-item {
display: flex;
padding-bottom: 32px;
margin-bottom: 32px;
border-bottom: 1px solid @oc-gray-4;
&:last-of-type {
border-bottom: none;
}
.left {
flex: 1;
.post-title {
font-size: 24px;
transition: all 0.3s;
&:hover {
color: @oc-gray-9;
}
}
.post-date {
font-size: 18px;
padding: 24px 0;
color: @oc-gray-5;
}
.post-abstract {
line-height: 24px;
font-size: 18px;
color: @oc-gray-6;
}
}
.right {
flex-shrink: 0;
margin-left: 24px;
width: 38.2%;
.feature-container {
padding-top: 56.25%;
background-size: cover;
background-position: center;
border-radius: 3px;
box-shadow: 0 2px 5px rgba(0,0,25,0.1), 0 5px 75px 1px rgba(0,0,50,0.2);
}
}
}
.pagination-container {
display: flex;
justify-content: space-between;
.prev, .next {
display: inline-block;
padding: 8px 16px;
background: #fff;
border: 1px solid @oc-gray-1;
border-radius: 2px;
transition: all 0.3s;
&:hover {
transform: translateY(-3px);
border: 1px solid @oc-gray-3;
}
}
}
.post-detail {
max-width: 720px;
margin: 0 auto;
.feature-container {
padding-top: 56.25%;
background-size: cover;
background-position: center;
border-radius: 3px;
box-shadow: 0 2px 5px rgba(0,0,25,0.1), 0 5px 75px 1px rgba(0,0,50,0.2);
margin-bottom: 24px;
}
.post-title {
font-size: 40px;
}
.post-date {
font-size: 18px;
padding: 24px 0;
color: @oc-gray-5;
}
.post-content {
h1, h2, h3, h4, h5, h6 {
margin: 16px 0;
color: @oc-gray-8;
}
a {
color: @oc-indigo-6;
border-bottom: 1px dotted @oc-indigo-6;
transition: all 0.3s;
&:hover {
color: @oc-indigo-8;
border-bottom: 1px dotted @oc-indigo-8;
}
}
img {
display: block;
box-shadow: 0 2px 5px rgba(0,0,25,0.1), 0 5px 75px 1px rgba(0,0,50,0.2);
max-width: 100%;
border-radius: 2px;
margin: 24px auto;
}
p {
line-height: 1.725;
margin-bottom: 24px;
font-size: 18px;
color: @oc-gray-7;
}
p, ul, ol {
code {
padding: 0 3px;
margin: 0 2px;
// background: rgba(195,195,195,0.41);
background: @oc-gray-2;
font-size: 0.9em;
border-radius: 2px;
border: 1px solid @oc-gray-3;
display: inline-block;
line-height: 1.5;
color: @oc-gray-6;
}
}
blockquote {
background: @oc-gray-2;
padding: 16px;
border-left: 3px solid @oc-violet-7;
border-radius: 2px;
margin-bottom: 16px;
p {
color: @oc-gray-6;
margin-bottom: 0;
}
}
pre {
margin-bottom: 16px;
code {
font-size: 14px;
font-family: 'Source Code Pro', Consolas, Menlo, Monaco, 'Courier New', monospace;
padding: 2em 1em 1em;
border-radius: 5px;
line-height: 1.375;
position: relative;
background: @oc-gray-8;
color: @oc-gray-1;
display: block;
&:after {
content: 'CODE';
display: block;
position: absolute;
left: 8px;
top: 4px;
font-size: 14px;
font-weight: bold;
color: @oc-gray-7;
}
}
}
table {
border-collapse: collapse;
margin: 1rem 0;
display: block;
overflow-x: auto;
}
tr {
border-top: 1px solid #dfe2e5;
}
td, th {
border: 1px solid #dfe2e5;
padding: .6em 1em;
}
ul, ol {
color: var(--c-base-blacklight);
padding-left: 24px;
line-height: 1.725;
margin-bottom: 16px;
}
strong {
font-weight: bolder;
}
em {
color: @oc-gray-6;
}
hr {
height: 0;
border: 2px solid #efefef;
margin-bottom: 24px;
}
}
}
.tag {
display: inline-block;
font-size: 14px;
padding: 8px 16px;
border-radius: 16px;
background: @oc-gray-2;
color: @oc-gray-6;
margin: 16px 16px 16px 0;
transition: all 0.3s;
&:hover {
background: @oc-gray-3;
color: @oc-gray-7;
transform: translateY(-3px);
}
}
.next-post {
border-top: 1px solid @oc-gray-4;
border-bottom: 1px solid @oc-gray-4;
padding: 24px 0;
margin: 32px 0;
.post-title {
font-size: 24px;
}
.next {
color: @oc-gray-4;
margin-bottom: 16px;
}
}
.archives-title, .tag-list-title, .current-tag {
color: @oc-gray-7;
padding-bottom: 48px;
font-size: 32px;
}
.archives-container {
padding-bottom: 32px;
.year {
font-size: 16px;
padding-bottom: 16px;
border-bottom: 1px solid @oc-gray-4;
margin: 16px 0;
color: @oc-gray-6;
}
.post {
padding-bottom: 16px;
.post-title {
font-size: 18px;
transition: all 0.3s;
&:hover {
color: @oc-gray-9;
}
}
}
}
// Mobile ----------------------- //
@media (max-width: 800px) {
.sidebar {
position: relative;
width: 100% !important;
height: 80px;
overflow: hidden;
transition: height 0.382s ease-in-out;
&.full-height {
height: 100vh;
}
.sidebar-content {
position: absolute;
top: 0;
bottom: 0;
left: 0;
right: 0;
}
.top-header-container {
display: flex;
justify-content: space-between;
margin-top: 16px;
.menu-btn {
display: block;
position: relative;
width: 48px;
height: 48px;
.line {
width: 32px;
height: 2px;
background: @oc-gray-2;
border-radius: 2px;
position: absolute;
right: 0;
top: 23px;
}
&:before, &:after {
content: '';
display: block;
width: 32px;
height: 2px;
background: @oc-gray-2;
border-radius: 2px;
position: absolute;
right: 0;
}
&:before {
top: 12px;
}
&:after {
bottom: 12px;
}
}
}
.top-container {
text-align: left;
padding: 0 16px;
.site-title-container {
display: flex;
align-items: center;
}
.site-logo {
width: 48px;
height: 48px;
}
.site-title {
display: inline;
padding: 0 8px;
font-size: 18px;
}
}
}
.main-container {
margin-left: 0 !important;;
}
.content-container {
padding: 32px 16px;
}
.post-item {
flex-direction: column-reverse;
padding-bottom: 16px;
margin-bottom: 16x;
.right {
width: 100%;
margin-left: 0;
margin-bottom: 16px;
}
.left {
.post-date {
font-size: 16px;
padding: 16px 0;
}
.post-abstract {
font-size: 16px;
}
}
}
.pagination-container {
.prev, .next {
&:hover {
transform: translateY(0px);
}
}
}
.post-detail {
.post-title {
font-size: 28px;
}
.post-date {
font-size: 16px;
padding: 16px 0;
}
.feature-container {
margin-bottom: 16px;
}
.post-content {
p {
font-size: 16px;
}
}
}
.next-post {
margin: 24px 0;
padding: 16px 0;
}
.archives-title, .tag-list-title, .current-tag {
font-size: 28px;
padding-bottom: 32px;
}
.tag {
margin: 8px 8px 8px 0;
&:hover {
transform: translateY(0px);
}
}
}
.social-container {
.social-link {
color: #dee2e6;
font-size: 16px;
margin: 4px 8px;
}
}
================================================
FILE: public/default-files/themes/simple/config.json
================================================
{
"name": "Simple",
"version": "1.1.0",
"author": "EryouHao",
"customConfig": [
{
"name": "sidebarWidth",
"label": "菜单栏宽度",
"group": "布局",
"value": "320px",
"type": "input",
"note": "可填像素类型(如:320px)或百分比类型(如:38.2%)"
},
{
"name": "featureBorderRadius",
"label": "封面图圆角",
"group": "布局",
"value": "3px",
"type": "input",
"note": "像素类型(如:3px)"
},
{
"name": "menuColor",
"label": "菜单颜色",
"group": "颜色",
"value": "#dee2e6",
"type": "input",
"card": "color",
"note": "颜色字符串:(如:#EEEEEE、rgba(255, 255, 255, 0.9))"
},
{
"name": "contentBgColor",
"label": "内容区背景色",
"group": "颜色",
"value": "#f8f9fa",
"type": "input",
"card": "color",
"note": "颜色字符串:(如:#EEEEEE、rgba(255, 255, 255, 0.9))"
},
{
"name": "renderKaTeX",
"label": "是否渲染 KaTeX 公式",
"group": "渲染",
"value": false,
"type": "switch"
},
{
"name": "renderCode",
"label": "是否渲染代码高亮",
"group": "渲染",
"value": false,
"type": "switch"
},
{
"name": "github",
"label": "Github",
"group": "社交",
"value": "",
"type": "input",
"note": "链接地址"
},
{
"name": "twitter",
"label": "Twitter",
"group": "社交",
"value": "",
"type": "input",
"note": "链接地址"
},
{
"name": "weibo",
"label": "微博",
"group": "社交",
"value": "",
"type": "input",
"note": "链接地址"
},
{
"name": "zhihu",
"label": "知乎",
"group": "社交",
"value": "",
"type": "input",
"note": "链接地址"
},
{
"name": "facebook",
"label": "Facebook",
"group": "社交",
"value": "",
"type": "input",
"note": "链接地址"
},
{
"name": "customCss",
"label": "自定义CSS",
"group": "自定义样式",
"value": "",
"type": "textarea",
"note": ""
},
{
"name": "ga",
"label": "跟踪 ID",
"group": "谷歌统计",
"value": "",
"type": "input",
"note": "UA-xxxxxxxxx-x"
}
]
}
================================================
FILE: public/default-files/themes/simple/style-override.js
================================================
const generateOverride = (params = {}) => {
let result = ''
// 侧边栏宽度 - sidebarWidth
if (params.sidebarWidth && params.sidebarWidth !== '320px') {
result += `
.sidebar {
width: ${params.sidebarWidth};
}
.main-container {
margin-left: ${params.sidebarWidth};
}
`
}
// 菜单颜色 - menuColor
if (params.menuColor && params.menuColor !== '#dee2e6') {
result += `
.sidebar .top-container .site-nav {
color: ${params.menuColor};
}
`
}
// 封面图圆角 - featureBorderRadius
if (params.featureBorderRadius && params.featureBorderRadius !== '3px') {
result += `
.post-item .right .feature-container {
border-radius: ${params.featureBorderRadius};
}
`
}
// 内容区背景色 - contentBgColor
if (params.contentBgColor && params.contentBgColor !== '#f8f9fa') {
result += `
body {
background: ${params.contentBgColor};
}
`
}
if (params.customCss) {
result += `
${params.customCss}
`
}
console.log('result', result)
return result
}
module.exports = generateOverride
================================================
FILE: public/default-files/themes/simple/templates/_blocks/head.ejs
================================================
<meta charset="utf-8" >
<title><%= siteTitle %></title>
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
<link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.7.2/css/all.css" integrity="sha384-fnmOCqbTlWIlj8LyTjo7mOUStjsKC4pOpQbqyi7RrhN7udi9RwhKkMHpvLbHG9Sr" crossorigin="anonymous">
<link rel="shortcut icon" href="<%= themeConfig.domain %>/favicon.ico?v=<%= site.utils.now %>">
<link rel="stylesheet" href="<%= themeConfig.domain %>/styles/main.css">
<% if (typeof commentSetting !== 'undefined' && commentSetting.showComment) { %>
<% if (commentSetting.commentPlatform === 'gitalk') { %>
<link rel="stylesheet" href="https://unpkg.com/gitalk/dist/gitalk.css" />
<% } %>
<% if (commentSetting.commentPlatform === 'disqus') { %>
<link rel="stylesheet" href="https://unpkg.com/disqusjs@1.1/dist/disqusjs.css" />
<% } %>
<% } %>
<link rel="stylesheet" href="https://unpkg.com/aos@next/dist/aos.css" />
<script src="https://cdn.jsdelivr.net/npm/vue/dist/vue.js"></script>
<% if (site.customConfig.ga) { %>
<script async src="https://www.googletagmanager.com/gtag/js?id=<%= site.customConfig.ga %>"></script>
<script>
window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);}
gtag('js', new Date());
gtag('config', '<%= site.customConfig.ga %>');
</script>
<% } %>
================================================
FILE: public/default-files/themes/simple/templates/_blocks/pagination.ejs
================================================
<div class="pagination-container">
<% if (pagination.prev) { %>
<a href="<%= pagination.prev %>" class="prev"><i class="icon-arrow-ios-back-outline"></i> 上一页</a>
<% } %>
<% if (pagination.next) { %>
<a href="<%= pagination.next %>" class="next">下一页 <i class="icon-arrow-ios-forward-outline"></i></a>
<% } %>
</div>
================================================
FILE: public/default-files/themes/simple/templates/_blocks/scripts.ejs
================================================
<script src="https://unpkg.com/aos@next/dist/aos.js"></script>
<script type="application/javascript">
AOS.init();
var app = new Vue({
el: '#app',
data: {
menuVisible: false,
},
})
</script>
<% if (site.customConfig.renderCode) { %>
<script src="//cdn.jsdelivr.net/gh/highlightjs/cdn-release@11.5.1/build/highlight.min.js"></script>
<script>
hljs.initHighlightingOnLoad()
</script>
<% } %>
<% if (typeof commentSetting !== 'undefined' && commentSetting.showComment) { %>
<% if (commentSetting.commentPlatform === 'gitalk') { %>
<script src="https://unpkg.com/gitalk/dist/gitalk.min.js"></script>
<script>
var gitalk = new Gitalk({
clientID: '<%= commentSetting.gitalkSetting.clientId %>',
clientSecret: '<%= commentSetting.gitalkSetting.clientSecret %>',
repo: '<%= commentSetting.gitalkSetting.repository %>',
owner: '<%= commentSetting.gitalkSetting.owner %>',
admin: ['<%= commentSetting.gitalkSetting.owner %>'],
id: (location.pathname).substring(0, 49), // Ensure uniqueness and length less than 50
distractionFreeMode: false // Facebook-like distraction free mode
})
gitalk.render('gitalk-container')
</script>
<% } %>
<% if (commentSetting.commentPlatform === 'disqus') { %>
<script src="https://unpkg.com/disqusjs@1.1/dist/disqus.js"></script>
<script>
var options = {
shortname: '<%= commentSetting.disqusSetting.shortname %>',
apikey: '<%= commentSetting.disqusSetting.apikey %>',
}
if ('<%= commentSetting.disqusSetting.api %>') {
options.api = '<%= commentSetting.disqusSetting.api %>'
}
var dsqjs = new DisqusJS(options)
</script>
<% } %>
<% } %>
================================================
FILE: public/default-files/themes/simple/templates/_blocks/sidebar.ejs
================================================
<div class="sidebar" :class="{ 'full-height': menuVisible }">
<div class="top-container" data-aos="fade-right">
<div class="top-header-container">
<a class="site-title-container" href="<%= themeConfig.domain %>">
<img src="<%= themeConfig.domain %>/images/avatar.png?v=<%= site.utils.now %>" class="site-logo">
<h1 class="site-title"><%= themeConfig.siteName %></h1>
</a>
<div class="menu-btn" @click="menuVisible = !menuVisible">
<div class="line"></div>
</div>
</div>
<div>
<% menus.forEach(function(menu) { %>
<% if (menu.openType === 'External') { %>
<a href="<%= menu.link %>" class="site-nav" target="_blank">
<%= menu.name %>
</a>
<% } else { %>
<a href="<%= menu.link %>" class="site-nav">
<%= menu.name %>
</a>
<% } %>
<% }); %>
</div>
</div>
<div class="bottom-container" data-aos="flip-up" da
gitextract_69c_nu5k/ ├── .browserslistrc ├── .editorconfig ├── .eslintrc.js ├── .github/ │ └── ISSUE_TEMPLATE/ │ ├── bug_report.md │ ├── feature_request.md │ └── question.md ├── .gitignore ├── .npmrc ├── CHANGELOG.md ├── LICENSE ├── README-ru.md ├── README-zh_CN.md ├── README-zh_TW.md ├── README.md ├── babel.config.js ├── package.json ├── postcss.config.js ├── public/ │ ├── app-icons/ │ │ └── gridea.icns │ ├── default-files/ │ │ ├── config/ │ │ │ ├── posts.json │ │ │ ├── setting.json │ │ │ └── theme.json │ │ ├── post-images/ │ │ │ └── .gitkeep │ │ ├── posts/ │ │ │ ├── about.md │ │ │ └── hello-gridea.md │ │ ├── static/ │ │ │ └── 404.html │ │ └── themes/ │ │ ├── fly/ │ │ │ ├── assets/ │ │ │ │ └── styles/ │ │ │ │ ├── _blocks/ │ │ │ │ │ ├── archives.less │ │ │ │ │ ├── fonts.less │ │ │ │ │ ├── footer.less │ │ │ │ │ ├── header.less │ │ │ │ │ ├── link.less │ │ │ │ │ ├── list.less │ │ │ │ │ ├── pagination.less │ │ │ │ │ ├── post.less │ │ │ │ │ ├── tag.less │ │ │ │ │ └── tags.less │ │ │ │ ├── _core/ │ │ │ │ │ ├── base.less │ │ │ │ │ ├── colors.less │ │ │ │ │ └── github.less │ │ │ │ └── main.less │ │ │ ├── config.json │ │ │ ├── style-override.js │ │ │ └── templates/ │ │ │ ├── archives.ejs │ │ │ ├── includes/ │ │ │ │ ├── footer.ejs │ │ │ │ ├── head.ejs │ │ │ │ ├── header.ejs │ │ │ │ ├── post-list-archives.ejs │ │ │ │ ├── post-list.ejs │ │ │ │ └── scripts.ejs │ │ │ ├── index.ejs │ │ │ ├── post.ejs │ │ │ ├── tag.ejs │ │ │ └── tags.ejs │ │ ├── notes/ │ │ │ ├── assets/ │ │ │ │ └── styles/ │ │ │ │ ├── abstracts/ │ │ │ │ │ └── varibles.less │ │ │ │ ├── components/ │ │ │ │ │ ├── about.less │ │ │ │ │ ├── archives.less │ │ │ │ │ ├── footer.less │ │ │ │ │ ├── header.less │ │ │ │ │ ├── home.less │ │ │ │ │ ├── post.less │ │ │ │ │ ├── tag.less │ │ │ │ │ └── tags.less │ │ │ │ ├── lib/ │ │ │ │ │ ├── colors.less │ │ │ │ │ ├── github.less │ │ │ │ │ └── modern-normalize.less │ │ │ │ └── main.less │ │ │ ├── config.json │ │ │ ├── style-override.js │ │ │ └── templates/ │ │ │ ├── archives.ejs │ │ │ ├── includes/ │ │ │ │ ├── disqus.ejs │ │ │ │ ├── footer.ejs │ │ │ │ ├── gitalk.ejs │ │ │ │ ├── head.ejs │ │ │ │ ├── header.ejs │ │ │ │ ├── pagination.ejs │ │ │ │ ├── post-list-archives.ejs │ │ │ │ └── post-list.ejs │ │ │ ├── index.ejs │ │ │ ├── post.ejs │ │ │ ├── tag.ejs │ │ │ └── tags.ejs │ │ ├── paper/ │ │ │ ├── assets/ │ │ │ │ └── styles/ │ │ │ │ ├── _core/ │ │ │ │ │ ├── base.less │ │ │ │ │ ├── colors.less │ │ │ │ │ └── github.less │ │ │ │ └── main.less │ │ │ ├── config.json │ │ │ ├── style-override.js │ │ │ └── templates/ │ │ │ ├── _blocks/ │ │ │ │ ├── head.ejs │ │ │ │ ├── header.ejs │ │ │ │ ├── pagination.ejs │ │ │ │ ├── post-list.ejs │ │ │ │ ├── scripts.ejs │ │ │ │ └── sidebar.ejs │ │ │ ├── archives.ejs │ │ │ ├── index.ejs │ │ │ ├── post.ejs │ │ │ ├── tag.ejs │ │ │ └── tags.ejs │ │ └── simple/ │ │ ├── assets/ │ │ │ └── styles/ │ │ │ ├── _core/ │ │ │ │ ├── a11y-dark.less │ │ │ │ ├── atom-one-dark.less │ │ │ │ ├── base.less │ │ │ │ ├── colors.less │ │ │ │ └── github.less │ │ │ └── main.less │ │ ├── config.json │ │ ├── style-override.js │ │ └── templates/ │ │ ├── _blocks/ │ │ │ ├── head.ejs │ │ │ ├── pagination.ejs │ │ │ ├── scripts.ejs │ │ │ └── sidebar.ejs │ │ ├── archives.ejs │ │ ├── index.ejs │ │ ├── post.ejs │ │ ├── tag.ejs │ │ └── tags.ejs │ └── index.html ├── src/ │ ├── App.vue │ ├── assets/ │ │ ├── locales-menu.ts │ │ ├── locales.ts │ │ └── styles/ │ │ ├── custom.less │ │ ├── main.less │ │ ├── tailwind.css │ │ ├── var.less │ │ └── zwicon.less │ ├── background.ts │ ├── components/ │ │ ├── AppSystem/ │ │ │ ├── Index.vue │ │ │ └── includes/ │ │ │ ├── LanguageSetting.vue │ │ │ ├── SourceFolderSetting.vue │ │ │ └── Version.vue │ │ ├── ColorCard/ │ │ │ └── Index.vue │ │ ├── EmojiCard/ │ │ │ └── Index.vue │ │ ├── FooterBox/ │ │ │ └── Index.vue │ │ ├── Main.vue │ │ ├── MonacoMarkdownEditor/ │ │ │ ├── Index.vue │ │ │ └── theme.js │ │ └── PostsCard/ │ │ └── Index.vue │ ├── helpers/ │ │ ├── analytics.ts │ │ ├── constants.ts │ │ ├── content-helper.ts │ │ ├── enums.ts │ │ ├── shortcut-keys.ts │ │ ├── slug.ts │ │ ├── utils.ts │ │ ├── vee-validate.ts │ │ └── words-count.ts │ ├── interfaces/ │ │ ├── menu.ts │ │ ├── post.ts │ │ ├── setting.ts │ │ ├── snackbar.ts │ │ ├── tag.ts │ │ └── theme.ts │ ├── main.ts │ ├── router.ts │ ├── server/ │ │ ├── app.ts │ │ ├── deploy.ts │ │ ├── events/ │ │ │ ├── deploy.ts │ │ │ ├── index.ts │ │ │ ├── menu.ts │ │ │ ├── post.ts │ │ │ ├── renderer.ts │ │ │ ├── setting.ts │ │ │ ├── site.ts │ │ │ ├── tag.ts │ │ │ └── theme.ts │ │ ├── interfaces/ │ │ │ ├── application.ts │ │ │ ├── menu.ts │ │ │ ├── post.ts │ │ │ ├── renderer.ts │ │ │ ├── setting.ts │ │ │ ├── tag.ts │ │ │ └── theme.ts │ │ ├── menus.ts │ │ ├── model.ts │ │ ├── plugins/ │ │ │ ├── deploys/ │ │ │ │ ├── gitproxy.ts │ │ │ │ ├── netlify.ts │ │ │ │ └── sftp.ts │ │ │ └── markdown.ts │ │ ├── posts.ts │ │ ├── renderer.ts │ │ ├── setting.ts │ │ ├── tags.ts │ │ └── theme.ts │ ├── server.ts │ ├── shims-tsx.d.ts │ ├── shims-vue.d.ts │ ├── shims.d.ts │ ├── store/ │ │ ├── index.ts │ │ └── modules/ │ │ └── site.ts │ ├── views/ │ │ ├── article/ │ │ │ ├── ArticleUpdate.vue │ │ │ └── Articles.vue │ │ ├── loading/ │ │ │ └── Index.vue │ │ ├── menu/ │ │ │ └── Index.vue │ │ ├── setting/ │ │ │ ├── Index.vue │ │ │ └── includes/ │ │ │ ├── BasicSetting.vue │ │ │ ├── CommentSetting.vue │ │ │ ├── DisqusSetting.vue │ │ │ └── GitalkSetting.vue │ │ ├── tags/ │ │ │ └── Index.vue │ │ └── theme/ │ │ ├── Index.vue │ │ └── includes/ │ │ ├── AvatarSetting.vue │ │ ├── BasicSetting.vue │ │ ├── CustomSetting.vue │ │ └── FaviconSetting.vue │ └── vue-bus.ts ├── tailwind.config.js ├── tsconfig.json └── vue.config.js
SYMBOL INDEX (184 symbols across 50 files)
FILE: src/background.ts
function createWindow (line 25) | function createWindow() {
FILE: src/helpers/analytics.ts
type EvOptions (line 7) | interface EvOptions {
class Analytics (line 14) | class Analytics {
method constructor (line 19) | constructor() {
method getClientId (line 25) | public getClientId(callback: any) {
method pageView (line 35) | public async pageView(url: string, title?: string) {
method event (line 45) | public async event(evCategory: string, evAction: string, options: EvOp...
method exception (line 58) | public async exception(exDesc: string, exFatal: any) {
FILE: src/helpers/constants.ts
constant DEFAULT_POST_PAGE_SIZE (line 12) | const DEFAULT_POST_PAGE_SIZE = 10
constant DEFAULT_ARCHIVES_PAGE_SIZE (line 13) | const DEFAULT_ARCHIVES_PAGE_SIZE = 50
constant DEFAULT_FEED_COUNT (line 14) | const DEFAULT_FEED_COUNT = 10
constant DEFAULT_ARCHIVES_PATH (line 15) | const DEFAULT_ARCHIVES_PATH = 'archives'
constant DEFAULT_POST_PATH (line 16) | const DEFAULT_POST_PATH = 'post'
constant DEFAULT_TAG_PATH (line 17) | const DEFAULT_TAG_PATH = 'tag'
FILE: src/helpers/content-helper.ts
class ContentHelper (line 1) | class ContentHelper {
method constructor (line 10) | constructor() {
method changeImageUrlLocalToDomain (line 22) | changeImageUrlLocalToDomain(content: string, domainPath: string) {
method changeImageUrlDomainToLocal (line 32) | changeImageUrlDomainToLocal(content: string, localPath: string) {
method changeFeatureImageUrlDomainToLocal (line 40) | changeFeatureImageUrlDomainToLocal(content: string, localPath: string) {
method changeFeatureImageUrlLocalToDomain (line 47) | changeFeatureImageUrlLocalToDomain(content: string, domainPath: string) {
FILE: src/helpers/enums.ts
type MenuTypes (line 1) | enum MenuTypes {
type UrlFormats (line 6) | enum UrlFormats {
FILE: src/helpers/slug.ts
function createSlug (line 41) | function createSlug(textToSlugify: any, filenameMode = false, saveLowerC...
FILE: src/helpers/utils.ts
function formatYamlString (line 7) | function formatYamlString(string: any) {
FILE: src/helpers/words-count.ts
constant CN_PATTERN (line 3) | const CN_PATTERN = /[\u4E00-\u9FA5]/g
constant EN_PATTERN (line 4) | const EN_PATTERN = /[a-zA-Z0-9_\u0392-\u03c9\u0400-\u04FF]+|[\u4E00-\u9F...
function countContent (line 6) | function countContent(content: any): [number, number] {
function wordCount (line 20) | function wordCount(content?: any, transformFn?: (count: number) => any):...
type TimeConfig (line 29) | interface TimeConfig {
function timeCalc (line 34) | function timeCalc(content?: any, { cn = 300, en = 160 }: TimeConfig = {}...
FILE: src/interfaces/menu.ts
type IMenu (line 1) | interface IMenu {
FILE: src/interfaces/post.ts
type IPostData (line 1) | interface IPostData {
type IPost (line 11) | interface IPost {
FILE: src/interfaces/setting.ts
type ISetting (line 1) | interface ISetting {
type IDisqusSetting (line 24) | interface IDisqusSetting {
type IGitalkSetting (line 29) | interface IGitalkSetting {
type ICommentSetting (line 36) | interface ICommentSetting {
FILE: src/interfaces/snackbar.ts
type ISnackbar (line 1) | interface ISnackbar {
FILE: src/interfaces/tag.ts
type ITag (line 1) | interface ITag {
FILE: src/interfaces/theme.ts
type ITheme (line 1) | interface ITheme {
FILE: src/main.ts
method mounted (line 55) | mounted() {
FILE: src/server.ts
function initServer (line 3) | function initServer() {
FILE: src/server/app.ts
class App (line 21) | class App {
method constructor (line 36) | constructor(setting: IApplicationSetting) {
method loadSite (line 113) | public async loadSite() {
method renderHtml (line 156) | public renderHtml() {
method saveSourceFolderSetting (line 162) | public async saveSourceFolderSetting(sourceFolderPath: string = '') {
method checkDir (line 185) | private async checkDir() {
method checkTheme (line 269) | private checkTheme(themeName: string): void {
method updateStaticServer (line 279) | private updateStaticServer(): void {
method initEvents (line 295) | private initEvents(): void {
FILE: src/server/deploy.ts
class Deploy (line 9) | class Deploy extends Model {
method constructor (line 18) | constructor(appInstance: any) {
method remoteDetect (line 39) | async remoteDetect() {
method publish (line 93) | async publish() {
method commonPush (line 116) | async commonPush() {
method checkCurrentBranch (line 168) | async checkCurrentBranch() {
FILE: src/server/events/deploy.ts
class DeployEvents (line 7) | class DeployEvents {
method constructor (line 8) | constructor(appInstance: any) {
FILE: src/server/events/menu.ts
class MenuEvents (line 5) | class MenuEvents {
method constructor (line 6) | constructor(appInstance: any) {
FILE: src/server/events/post.ts
class PostEvents (line 5) | class PostEvents {
method constructor (line 6) | constructor(appInstance: any) {
FILE: src/server/events/renderer.ts
class RendererEvents (line 4) | class RendererEvents {
method constructor (line 5) | constructor(appInstance: any) {
FILE: src/server/events/setting.ts
class SettingEvents (line 6) | class SettingEvents {
method constructor (line 7) | constructor(appInstance: any) {
FILE: src/server/events/site.ts
class SiteEvents (line 3) | class SiteEvents {
method constructor (line 4) | constructor(appInstance: any) {
FILE: src/server/events/tag.ts
class TagEvents (line 5) | class TagEvents {
method constructor (line 6) | constructor(appInstance: any) {
FILE: src/server/events/theme.ts
class ThemeEvents (line 5) | class ThemeEvents {
method constructor (line 6) | constructor(appInstance: any) {
FILE: src/server/interfaces/application.ts
type IApplicationSetting (line 9) | interface IApplicationSetting {
type IApplicationDb (line 16) | interface IApplicationDb {
type IApplication (line 28) | interface IApplication {
FILE: src/server/interfaces/menu.ts
type IMenu (line 1) | interface IMenu {
FILE: src/server/interfaces/post.ts
type IPost (line 3) | interface IPost {
type IPostData (line 22) | interface IPostData {
type IPostDb (line 32) | interface IPostDb {
type ITagRenderData (line 42) | interface ITagRenderData extends ITag {
type ISiteTagsData (line 46) | interface ISiteTagsData extends ITagRenderData {
type IStats (line 50) | interface IStats {
type IPostRenderData (line 57) | interface IPostRenderData {
FILE: src/server/interfaces/renderer.ts
type IPagination (line 1) | interface IPagination {
FILE: src/server/interfaces/setting.ts
type IDisqusSetting (line 1) | interface IDisqusSetting {
type IGitalkSetting (line 6) | interface IGitalkSetting {
type ICommentSetting (line 13) | interface ICommentSetting {
FILE: src/server/interfaces/tag.ts
type ITag (line 1) | interface ITag {
FILE: src/server/interfaces/theme.ts
type ITheme (line 1) | interface ITheme {
FILE: src/server/menus.ts
class Menus (line 4) | class Menus extends Model {
method list (line 5) | list() {
method saveMenu (line 10) | public async saveMenu(menu: IMenu) {
method saveMenus (line 25) | public async saveMenus(menus: IMenu[]) {
method deleteMenu (line 30) | public async deleteMenu(menuValue: string) {
FILE: src/server/model.ts
class Model (line 7) | class Model {
method constructor (line 22) | constructor(appInstance: IApplication) {
method initDataStore (line 31) | private initDataStore(): void {
FILE: src/server/plugins/deploys/gitproxy.ts
class GitProxy (line 6) | class GitProxy {
method constructor (line 9) | constructor(appInstance: any) {
method request (line 14) | public async request({
method mergeBuffers (line 48) | private async mergeBuffers(data: any[] | Uint8Array) {
method transformResponse (line 66) | private async transformResponse(res: {
FILE: src/server/plugins/deploys/netlify.ts
class NetlifyApi (line 12) | class NetlifyApi extends Model {
method constructor (line 21) | constructor(appInstance: IApplication) {
method request (line 29) | async request(method: 'GET' | 'PUT' | 'POST', endpoint: string, data?:...
method remoteDetect (line 51) | async remoteDetect() {
method publish (line 73) | async publish() {
method prepareLocalFilesList (line 118) | async prepareLocalFilesList() {
method readDirRecursiveSync (line 136) | readDirRecursiveSync(dir: string, fileList?: any) {
method fileIsDirectory (line 154) | fileIsDirectory(dir: string, file: string) {
method fileIsNotExcluded (line 158) | fileIsNotExcluded(file: string) {
method getFilePath (line 162) | getFilePath(dir: string, file: string, includeInputDir = false) {
method getFileHash (line 170) | getFileHash(fileName: string) {
method getFilesToUpload (line 184) | getFilesToUpload(filesList: any, hashesToUpload: any) {
method uploadFile (line 201) | async uploadFile(filePath: any, deployID: any) {
FILE: src/server/plugins/deploys/sftp.ts
type sftpConnectConfig (line 9) | type sftpConnectConfig = {
class SftpDeploy (line 18) | class SftpDeploy extends Model {
method constructor (line 20) | constructor(appInstance: any) {
method remoteDetect (line 26) | async remoteDetect() {
method publish (line 88) | async publish() {
FILE: src/server/plugins/markdown.ts
constant BAD_PROTO_RE (line 20) | const BAD_PROTO_RE = /^(vbscript|javascript|data):/
constant GOOD_DATA_RE (line 21) | const GOOD_DATA_RE = /^data:image\/(gif|png|jpeg|webp);/
FILE: src/server/posts.ts
class Posts (line 15) | class Posts extends Model {
method constructor (line 20) | constructor(appInstance: any) {
method savePosts (line 26) | public async savePosts() {
method list (line 139) | async list() {
method savePostToFile (line 160) | async savePostToFile(post: IPost): Promise<IPost | null> {
method deletePost (line 206) | async deletePost(post: IPostDb) {
method uploadImages (line 235) | async uploadImages(files: any[]) {
FILE: src/server/renderer.ts
class Renderer (line 25) | class Renderer extends Model {
method constructor (line 42) | constructor(appInstance: any) {
method preview (line 51) | async preview() {
method renderAll (line 56) | async renderAll() {
method loadConfig (line 85) | async loadConfig() {
method formatDataForRender (line 94) | public formatDataForRender(): any {
method renderPostList (line 193) | public async renderPostList(archivePath: string) {
method renderPostDetail (line 286) | async renderPostDetail() {
method renderTags (line 336) | async renderTags() {
method renderTagDetail (line 367) | async renderTagDetail() {
method renderCustomPage (line 441) | async renderCustomPage() {
method buildCss (line 502) | async buildCss() {
method buildCname (line 541) | async buildCname() {
method buildFeed (line 554) | async buildFeed() {
method copyFiles (line 596) | async copyFiles() {
method clearOutputFolder (line 628) | async clearOutputFolder() {
FILE: src/server/setting.ts
class Setting (line 7) | class Setting extends Model {
method getSetting (line 8) | getSetting() {
method getGitalkSetting (line 13) | getGitalkSetting() {
method getCommentSetting (line 18) | getCommentSetting() {
method saveSetting (line 23) | public async saveSetting(setting: ISetting) {
method saveCommentSetting (line 28) | public async saveCommentSetting(setting: ICommentSetting) {
method uploadFavicon (line 33) | async uploadFavicon(filePath: string) {
method uploadAvatar (line 38) | async uploadAvatar(filePath: string) {
FILE: src/server/tags.ts
class Tags (line 7) | class Tags extends Model {
method saveTags (line 8) | public async saveTags() {
method list (line 61) | async list() {
method saveTag (line 67) | public async saveTag(tag: ITag) {
method deleteTag (line 78) | public async deleteTag(tagValue: string) {
FILE: src/server/theme.ts
class Theme (line 7) | class Theme extends Model {
method constructor (line 16) | constructor(appInstance: any) {
method getThemeList (line 26) | async getThemeList() {
method getThemeConfig (line 54) | async getThemeConfig() {
method saveThemeConfig (line 63) | public async saveThemeConfig(themeConfig: ITheme) {
method saveThemeCustomConfig (line 81) | public async saveThemeCustomConfig(config: any) {
method getThemeCustomConfig (line 185) | public async getThemeCustomConfig() {
method getCurrentThemeCustomConfig (line 193) | public async getCurrentThemeCustomConfig() {
FILE: src/shims-tsx.d.ts
type Element (line 6) | interface Element extends VNode {}
type ElementClass (line 8) | interface ElementClass extends Vue {}
type IntrinsicElements (line 9) | interface IntrinsicElements {
FILE: src/shims-vue.d.ts
type DraggedContext (line 35) | interface DraggedContext<T> {
type DropContext (line 41) | interface DropContext<T> {
type Rectangle (line 47) | interface Rectangle {
type MoveEvent (line 56) | interface MoveEvent<T> {
FILE: src/shims.d.ts
type Vue (line 4) | interface Vue {
FILE: src/store/modules/site.ts
type Site (line 11) | interface Site {
method updateSite (line 89) | updateSite(state, siteData: Site) {
method updatePosts (line 110) | updatePosts(state, posts: IPost[]) {
method updatePosts (line 116) | updatePosts({ commit }, posts: IPost[]) {
method updateSite (line 119) | updateSite({ commit }, siteData: Site) {
FILE: src/vue-bus.ts
type Vue (line 4) | interface Vue {
class VueBus (line 8) | class VueBus {
method install (line 9) | static install(Vue: any, options: any) {
FILE: vue.config.js
function resolve (line 3) | function resolve(dir) {
Condensed preview — 206 files, each showing path, character count, and a content snippet. Download the .json file or copy for the full structured content (565K chars).
[
{
"path": ".browserslistrc",
"chars": 33,
"preview": "> 1%\nlast 2 versions\nnot ie <= 8\n"
},
{
"path": ".editorconfig",
"chars": 605,
"preview": "# EditorConfig is awesome: https://EditorConfig.org\n\n# top-most EditorConfig file\nroot = true\n\n# Unix-style newlines wit"
},
{
"path": ".eslintrc.js",
"chars": 1664,
"preview": "module.exports = {\n root: true,\n env: {\n node: true,\n },\n extends: ['plugin:vue/essential', '@vue/airbnb', '@vue/"
},
{
"path": ".github/ISSUE_TEMPLATE/bug_report.md",
"chars": 605,
"preview": "---\nname: Bug Report\nabout: 事情不像预期的那样工作吗?\ntitle: ''\nlabels: 'bug'\nassignees: ''\n\n---\n\n<!--\n 你好!感谢你正在考虑为 Gridea 提交一个 bug"
},
{
"path": ".github/ISSUE_TEMPLATE/feature_request.md",
"chars": 315,
"preview": "---\nname: Feature Request\nabout: 想让我们为 Gridea 增加什么功能吗?\ntitle: 'feat: '\nlabels: 'Feature Request'\nassignees: ''\n\n---\n\n<!-"
},
{
"path": ".github/ISSUE_TEMPLATE/question.md",
"chars": 161,
"preview": "---\nname: Question\nabout: 对 Gridea 有任何问题吗?\ntitle: ''\nlabels: 'question'\nassignees: ''\n\n---\n\n<!--\n 如果你有任何问题也可以通过此渠道来向我们反"
},
{
"path": ".gitignore",
"chars": 254,
"preview": ".DS_Store\nnode_modules\n/dist\n\n# local env files\n.env.local\n.env.*.local\n\n# Log files\nnpm-debug.log*\nyarn-debug.log*\nyarn"
},
{
"path": ".npmrc",
"chars": 35,
"preview": "registry=https://registry.npmjs.org"
},
{
"path": "CHANGELOG.md",
"chars": 4758,
"preview": "## v0.9.1\n\n`2020-01-01` \n\n- 修复首次安装使用 Gridea,无法预览 BUG\n\n## v0.9.0\n\n`2019-12-28` \n\n**注意:若你之前有手动放置文件或文件夹到构建后文件夹(output 文件夹"
},
{
"path": "LICENSE",
"chars": 1065,
"preview": "MIT License\n\nCopyright (c) 2019 EryouHao\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\no"
},
{
"path": "README-ru.md",
"chars": 4168,
"preview": "<div align=\"center\">\n <a href=\"https://gridea.dev\">\n <img src=\"public/app-icons/gridea.png\" width=\"80px\" height=\"80"
},
{
"path": "README-zh_CN.md",
"chars": 2684,
"preview": "<div align=\"center\">\n <a href=\"https://gridea.dev\">\n <img src=\"public/app-icons/gridea.png\" width=\"80px\" height=\"80"
},
{
"path": "README-zh_TW.md",
"chars": 2654,
"preview": "<div align=\"center\">\n <a href=\"https://gridea.dev\">\n <img src=\"public/app-icons/gridea.png\" width=\"80px\" height=\"80"
},
{
"path": "README.md",
"chars": 3546,
"preview": "<div align=\"center\">\n <a href=\"https://gridea.dev\">\n <img src=\"public/app-icons/gridea.png\" width=\"80px\" height=\"80"
},
{
"path": "babel.config.js",
"chars": 379,
"preview": "module.exports = {\n presets: [\n '@vue/app',\n ],\n plugins: [\n ['prismjs', {\n 'languages': ['javascript', 'c"
},
{
"path": "package.json",
"chars": 3913,
"preview": "{\n \"name\": \"gridea\",\n \"version\": \"0.9.3\",\n \"private\": true,\n \"description\": \"A static blog writing client. You can u"
},
{
"path": "postcss.config.js",
"chars": 127,
"preview": "module.exports = {\n plugins: [\n require('postcss-import'),\n require('tailwindcss'),\n require('autoprefixer'),\n"
},
{
"path": "public/default-files/config/posts.json",
"chars": 395,
"preview": "{\n \"posts\": [],\n \"tags\": [],\n \"menus\": [\n {\n \"link\": \"/\",\n \"name\": \"首页\",\n \"openType\": \"Internal\"\n "
},
{
"path": "public/default-files/config/setting.json",
"chars": 446,
"preview": "{\n \"config\": {\n \"platform\": \"github\",\n \"domain\": \"\",\n \"repository\": \"\",\n \"branch\": \"\",\n \"username\": \"\",\n"
},
{
"path": "public/default-files/config/theme.json",
"chars": 458,
"preview": "{\n \"config\": {\n \"footerInfo\": \"Powered by <a href=\\\"https://github.com/getgridea/gridea\\\" target=\\\"_blank\\\">Gridea</"
},
{
"path": "public/default-files/post-images/.gitkeep",
"chars": 0,
"preview": ""
},
{
"path": "public/default-files/posts/about.md",
"chars": 161,
"preview": "---\ntitle: 关于\ndate: 2019-01-25 19:09:48\ntags: \npublished: true\nhideInList: true\nfeature: \n---\n> 欢迎来到我的小站呀,很高兴遇见你!🤝\n\n## 🏠"
},
{
"path": "public/default-files/posts/hello-gridea.md",
"chars": 912,
"preview": "---\ntitle: Hello Gridea\ndate: 2018-12-12\ntags: [Gridea]\npublished: true\nhideInList: false\nfeature: /post-images/hello-gr"
},
{
"path": "public/default-files/static/404.html",
"chars": 2102,
"preview": "<!DOCTYPE html>\n<html lang=\"en\">\n<head>\n <meta charset=\"UTF-8\">\n <meta name=\"viewport\" content=\"width=device-width, in"
},
{
"path": "public/default-files/themes/fly/assets/styles/_blocks/archives.less",
"chars": 767,
"preview": ".archives-container {\n padding: 32px 0;\n .year {\n font-size: 24px;\n margin: 24px 0;\n color: var(--c-base-purp"
},
{
"path": "public/default-files/themes/fly/assets/styles/_blocks/fonts.less",
"chars": 14200,
"preview": "@font-face {\n font-family: 'icomoon';\n src: url('../media/fonts/icomoon.eot?pjaj8c');\n src: url('../media/fonts/ico"
},
{
"path": "public/default-files/themes/fly/assets/styles/_blocks/footer.less",
"chars": 228,
"preview": ".site-footer {\n text-align: center;\n font-size: 12px;\n padding: 32px 16px;\n .slogan {\n margin-bottom: 24px;\n }\n "
},
{
"path": "public/default-files/themes/fly/assets/styles/_blocks/header.less",
"chars": 1256,
"preview": ".site-header-container {\n position: fixed;\n right: 0;\n left: 0;\n z-index: 1024;\n background: #fff;\n height: 56px;\n"
},
{
"path": "public/default-files/themes/fly/assets/styles/_blocks/link.less",
"chars": 357,
"preview": "\na,\n.link {\n color: var(--c-base-black);\n text-decoration: none;\n cursor: pointer;\n background: transparent 0 0;\n\n "
},
{
"path": "public/default-files/themes/fly/assets/styles/_blocks/list.less",
"chars": 2564,
"preview": ".main {\n max-width: 768px;\n margin: 0 auto;\n display: flex;\n min-height: 100vh;\n flex-direction: column;\n}\n\n.conten"
},
{
"path": "public/default-files/themes/fly/assets/styles/_blocks/pagination.less",
"chars": 295,
"preview": ".pagination-container {\n padding: 24px 0;\n overflow: hidden;\n .prev, .next {\n display: flex;\n align-items: cent"
},
{
"path": "public/default-files/themes/fly/assets/styles/_blocks/post.less",
"chars": 2357,
"preview": ".post-detail {\n padding: 32px 0;\n .post-title {\n font-size: 32px;\n margin: 24px 0;\n color: var(--c-base-black"
},
{
"path": "public/default-files/themes/fly/assets/styles/_blocks/tag.less",
"chars": 79,
"preview": ".current-tag-container {\n padding-top: 32px;\n color: var(--c-base-purple);\n}\n"
},
{
"path": "public/default-files/themes/fly/assets/styles/_blocks/tags.less",
"chars": 229,
"preview": ".tags-container {\n padding: 32px 0;\n .tag {\n color: var(--c-base-purple);\n padding: 4px 8px;\n display: inline"
},
{
"path": "public/default-files/themes/fly/assets/styles/_core/base.less",
"chars": 4812,
"preview": "/*! modern-normalize | MIT License | https://github.com/sindresorhus/modern-normalize */\n\n/* Document\n ==============="
},
{
"path": "public/default-files/themes/fly/assets/styles/_core/colors.less",
"chars": 461,
"preview": "\n:root {\n --c-base-black: #0C1E29;\n --c-base-blacklight: #4E616C;\n --c-base-purple: #5978F3;\n --c-base-purplelight: "
},
{
"path": "public/default-files/themes/fly/assets/styles/_core/github.less",
"chars": 1080,
"preview": ".hljs {\n display: block;\n overflow-x: auto;\n padding: 0.5em;\n color: #333;\n background: #f8f8f8;\n}\n\n.hljs-comment,\n"
},
{
"path": "public/default-files/themes/fly/assets/styles/main.less",
"chars": 325,
"preview": "@import \"_core/colors\";\n@import \"_core/base\";\n@import \"_core/github\";\n\n@import \"_blocks/fonts\";\n@import \"_blocks/footer\""
},
{
"path": "public/default-files/themes/fly/config.json",
"chars": 1844,
"preview": "{\n \"name\": \"Fly\",\n \"version\": \"1.0.0\",\n \"author\": \"EryouHao\",\n \"repository\": \"https://github.com/getgridea/gridea-th"
},
{
"path": "public/default-files/themes/fly/style-override.js",
"chars": 2344,
"preview": "const generateOverride = (params = {}) => {\n let result = ''\n\n // 暗黑皮肤\n if (params.skin && params.skin !== 'white') {"
},
{
"path": "public/default-files/themes/fly/templates/archives.ejs",
"chars": 441,
"preview": "<html>\n <head>\n <%- include('./includes/head', { siteTitle: themeConfig.siteName }) %>\n </head>\n <body>\n <div i"
},
{
"path": "public/default-files/themes/fly/templates/includes/footer.ejs",
"chars": 529,
"preview": "<div class=\"site-footer\">\n <div class=\"slogan\"><%- themeConfig.siteDescription %></div>\n <div class=\"social-container\""
},
{
"path": "public/default-files/themes/fly/templates/includes/head.ejs",
"chars": 1731,
"preview": "\r\n<meta charset=\"utf-8\" >\r\n\r\n<title><%= siteTitle %></title>\r\n<meta name=\"description\" content=\"<%= themeConfig.siteDesc"
},
{
"path": "public/default-files/themes/fly/templates/includes/header.ejs",
"chars": 1210,
"preview": "<div class=\"site-header-container\">\n <div class=\"site-header\">\n <div class=\"left\">\n <a href=\"<%= themeConfig.do"
},
{
"path": "public/default-files/themes/fly/templates/includes/post-list-archives.ejs",
"chars": 630,
"preview": "<% let years = []; posts.forEach((item) => { const year = item.date.substring(0, 4); if (!years.includes(year)) { years."
},
{
"path": "public/default-files/themes/fly/templates/includes/post-list.ejs",
"chars": 1415,
"preview": "<% posts.forEach(function(post) { %>\n<section class=\"post-item\">\n <div class=\"content\">\n <a href=\"<%= post.link "
},
{
"path": "public/default-files/themes/fly/templates/includes/scripts.ejs",
"chars": 1488,
"preview": "<script type=\"application/javascript\">\n\nhljs.initHighlightingOnLoad()\n\nvar app = new Vue({\n el: '#app',\n data: {\n m"
},
{
"path": "public/default-files/themes/fly/templates/index.ejs",
"chars": 408,
"preview": "\n<html>\n <head>\n <%- include('./includes/head', { siteTitle: themeConfig.siteName }) %>\n </head>\n <body>\n <div "
},
{
"path": "public/default-files/themes/fly/templates/post.ejs",
"chars": 2080,
"preview": "\n<!DOCTYPE html>\n<html>\n <head>\n <%- include('./includes/head', { siteTitle: `${post.title} | ${themeConfig.siteName"
},
{
"path": "public/default-files/themes/fly/templates/tag.ejs",
"chars": 613,
"preview": "\n<!DOCTYPE html>\n<html>\n <head>\n <%- include('./includes/head', { siteTitle: `${tag.name} | ${themeConfig.siteName}`"
},
{
"path": "public/default-files/themes/fly/templates/tags.ejs",
"chars": 575,
"preview": "<html>\n <head>\n <%- include('./includes/head', { siteTitle: themeConfig.siteName }) %>\n </head>\n <body>\n <div i"
},
{
"path": "public/default-files/themes/notes/assets/styles/abstracts/varibles.less",
"chars": 471,
"preview": "@darker-main-color: #004cb3;\n@dark-main-color: #0061e6;\n@main-color: #006CFF;\n@light-main-color: #006cff21;\n\n@black: #00"
},
{
"path": "public/default-files/themes/notes/assets/styles/components/about.less",
"chars": 38,
"preview": ".about-page {\n padding: 24px 32px;\n}\n"
},
{
"path": "public/default-files/themes/notes/assets/styles/components/archives.less",
"chars": 510,
"preview": ".archives-container {\n padding: 32px;\n flex: 1;\n .year {\n font-size: 1.375rem;\n font-weight: bold;\n margin: "
},
{
"path": "public/default-files/themes/notes/assets/styles/components/footer.less",
"chars": 245,
"preview": ".site-footer {\n font-size: 12px;\n text-align: center;\n padding: 40px 24px;\n color: @oc-gray-6;\n display: flex;\n ju"
},
{
"path": "public/default-files/themes/notes/assets/styles/components/header.less",
"chars": 811,
"preview": ".site-header {\n padding: 48px 0;\n text-align: center;\n\n .site-title {\n font-size: 32px;\n font-weight: bold;\n }"
},
{
"path": "public/default-files/themes/notes/assets/styles/components/home.less",
"chars": 2245,
"preview": ".post-container {\n flex: 1;\n .post {\n padding-bottom: 32px;\n\n .post-title {\n font-size: 28px;\n text-al"
},
{
"path": "public/default-files/themes/notes/assets/styles/components/post.less",
"chars": 7027,
"preview": ".post-detail {\n flex: 1;\n .post {\n padding: 24px 32px;\n .post-feature-image {\n width: 100%;\n height: a"
},
{
"path": "public/default-files/themes/notes/assets/styles/components/tag.less",
"chars": 113,
"preview": ".current-tag-container {\n .title {\n text-align: center;\n font-size: 18px;\n margin-bottom: 24px;\n }\n}\n\n"
},
{
"path": "public/default-files/themes/notes/assets/styles/components/tags.less",
"chars": 326,
"preview": ".tags-container {\n padding: 32px 32px;\n flex: 1;\n text-align: center;\n .tag {\n display: inline-block;\n padding"
},
{
"path": "public/default-files/themes/notes/assets/styles/lib/colors.less",
"chars": 7521,
"preview": "//\n//\n// 𝗖 𝗢 𝗟 𝗢 𝗥\n// v 1.6.3\n//\n// ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\n\n\n// General\n// ───────────────────────────"
},
{
"path": "public/default-files/themes/notes/assets/styles/lib/github.less",
"chars": 1080,
"preview": ".hljs {\n display: block;\n overflow-x: auto;\n padding: 0.5em;\n color: #333;\n background: #f9f7f3;\n}\n\n.hljs-comment,\n"
},
{
"path": "public/default-files/themes/notes/assets/styles/lib/modern-normalize.less",
"chars": 4638,
"preview": "/*! modern-normalize | MIT License | https://github.com/sindresorhus/modern-normalize */\n\n/* Document\n ==============="
},
{
"path": "public/default-files/themes/notes/assets/styles/main.less",
"chars": 1696,
"preview": "@import './lib/modern-normalize';\n@import './lib/colors';\n@import './abstracts/varibles';\n\n*,\n*:before,\n*:after {\n marg"
},
{
"path": "public/default-files/themes/notes/config.json",
"chars": 4113,
"preview": "{\n \"name\": \"Notes\",\n \"version\": \"1.2.0\",\n \"author\": \"EryouHao\",\n \"repository\": \"https://github.com/getgridea/gridea-"
},
{
"path": "public/default-files/themes/notes/style-override.js",
"chars": 2298,
"preview": "const generateOverride = (params = {}) => {\n let result = ''\n\n // 内容区最大宽度 - contentMaxWidth\n if (params.contentMaxWid"
},
{
"path": "public/default-files/themes/notes/templates/archives.ejs",
"chars": 529,
"preview": "<html>\n <head>\n <%- include('./includes/head', { siteTitle: themeConfig.siteName }) %>\n <meta name=\"description\" "
},
{
"path": "public/default-files/themes/notes/templates/includes/disqus.ejs",
"chars": 483,
"preview": "<link rel=\"stylesheet\" href=\"https://unpkg.com/disqusjs@1.1/dist/disqusjs.css\">\n<script src=\"https://unpkg.com/disqusjs@"
},
{
"path": "public/default-files/themes/notes/templates/includes/footer.ejs",
"chars": 184,
"preview": "<div class=\"site-footer\">\n <%- themeConfig.footerInfo %>\n <a class=\"rss\" href=\"<%= themeConfig.domain %>/atom.xml\" tar"
},
{
"path": "public/default-files/themes/notes/templates/includes/gitalk.ejs",
"chars": 740,
"preview": "<link rel=\"stylesheet\" href=\"https://unpkg.com/gitalk/dist/gitalk.css\">\n<script src=\"https://unpkg.com/gitalk/dist/gital"
},
{
"path": "public/default-files/themes/notes/templates/includes/head.ejs",
"chars": 945,
"preview": "<meta charset=\"utf-8\" />\n<meta name=\"viewport\" content=\"width=device-width, initial-scale=1\" />\n<title><%= siteTitle %><"
},
{
"path": "public/default-files/themes/notes/templates/includes/header.ejs",
"chars": 1017,
"preview": "<div class=\"site-header\">\n <a href=\"<%= themeConfig.domain %>\">\n <img class=\"avatar\" src=\"<%= themeConfig.domain %>/im"
},
{
"path": "public/default-files/themes/notes/templates/includes/pagination.ejs",
"chars": 250,
"preview": "<div class=\"pagination-container\">\n <% if (pagination.prev) { %>\n <a href=\"<%= pagination.prev %>\" class=\"prev-page\""
},
{
"path": "public/default-files/themes/notes/templates/includes/post-list-archives.ejs",
"chars": 588,
"preview": "<% let years = []; posts.forEach((item) => { const year = item.date.substring(0, 4); if (!years.includes(year)) { years."
},
{
"path": "public/default-files/themes/notes/templates/includes/post-list.ejs",
"chars": 847,
"preview": "<div class=\"post-container\">\n <% posts.forEach(function(post) { %>\n <article class=\"post\">\n <a href=\"<%= post.l"
},
{
"path": "public/default-files/themes/notes/templates/index.ejs",
"chars": 520,
"preview": "<html>\n <head>\n <%- include('./includes/head', { siteTitle: themeConfig.siteName }) %>\n <meta name=\"description\" "
},
{
"path": "public/default-files/themes/notes/templates/post.ejs",
"chars": 3781,
"preview": "<html>\n <head>\n <%- include('./includes/head', { siteTitle: `${post.title} | ${themeConfig.siteName}` }) %>\n <met"
},
{
"path": "public/default-files/themes/notes/templates/tag.ejs",
"chars": 666,
"preview": "<html>\n <head>\n <%- include('./includes/head', { siteTitle: `${tag.name} | ${themeConfig.siteName}` }) %>\n <meta name"
},
{
"path": "public/default-files/themes/notes/templates/tags.ejs",
"chars": 590,
"preview": "<html>\n <head>\n <%- include('./includes/head', { siteTitle: themeConfig.siteName }) %>\n <meta name=\"description\" cont"
},
{
"path": "public/default-files/themes/paper/assets/styles/_core/base.less",
"chars": 4812,
"preview": "/*! modern-normalize | MIT License | https://github.com/sindresorhus/modern-normalize */\n\n/* Document\n ==============="
},
{
"path": "public/default-files/themes/paper/assets/styles/_core/colors.less",
"chars": 7521,
"preview": "//\n//\n// 𝗖 𝗢 𝗟 𝗢 𝗥\n// v 1.6.3\n//\n// ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\n\n\n// General\n// ───────────────────────────"
},
{
"path": "public/default-files/themes/paper/assets/styles/_core/github.less",
"chars": 1080,
"preview": ".hljs {\n display: block;\n overflow-x: auto;\n padding: 0.5em;\n color: #333;\n background: #f8f8f8;\n}\n\n.hljs-comment,\n"
},
{
"path": "public/default-files/themes/paper/assets/styles/main.less",
"chars": 1083,
"preview": "@import \"_core/colors\";\n@import \"_core/github\";\n\nbody {\n background-image: url('../media/images/geometry2.png');\n}\n\n#to"
},
{
"path": "public/default-files/themes/paper/config.json",
"chars": 2566,
"preview": "{\n \"name\": \"Paper\",\n \"version\": \"1.0.0\",\n \"author\": \"EryouHao\",\n \"repository\": \"https://github.com/getgridea/gridea-"
},
{
"path": "public/default-files/themes/paper/style-override.js",
"chars": 608,
"preview": "const generateOverride = (params = {}) => {\n let result = ''\n\n // 内容区背景色 - contentBgColor\n if (params.contentBgColor "
},
{
"path": "public/default-files/themes/paper/templates/_blocks/head.ejs",
"chars": 1714,
"preview": "<meta charset=\"utf-8\" >\r\n\r\n<title><%= siteTitle %></title>\r\n<meta name=\"description\" content=\"<%= themeConfig.siteDescri"
},
{
"path": "public/default-files/themes/paper/templates/_blocks/header.ejs",
"chars": 953,
"preview": "<nav class=\"navbar border fixed split-nav\">\n <div class=\"nav-brand\">\n <h3><a href=\"<%= themeConfig.domain %>\"><%= th"
},
{
"path": "public/default-files/themes/paper/templates/_blocks/pagination.ejs",
"chars": 354,
"preview": "<div class=\"row flex-edges\">\n <% if (pagination.prev) { %>\n <a href=\"<%= pagination.prev %>\" class=\"paper-btn\">\n "
},
{
"path": "public/default-files/themes/paper/templates/_blocks/post-list.ejs",
"chars": 760,
"preview": "<% posts.forEach(function(post) { %>\n <article class=\"article\">\n <h2 class=\"article-title\">\n <a href=\"<%= post."
},
{
"path": "public/default-files/themes/paper/templates/_blocks/scripts.ejs",
"chars": 1488,
"preview": "<script src=\"https://unpkg.com/aos@next/dist/aos.js\"></script>\n\n<script type=\"application/javascript\">\n\nAOS.init();\n\nhlj"
},
{
"path": "public/default-files/themes/paper/templates/_blocks/sidebar.ejs",
"chars": 1579,
"preview": "<div class=\"sm-12 md-4 col sidebar\">\n <div class=\"paper info-container\">\n <img src=\"<%= themeConfig.domain %>/images"
},
{
"path": "public/default-files/themes/paper/templates/archives.ejs",
"chars": 1272,
"preview": "<!DOCTYPE html>\n<html>\n <head>\n <%- include('./_blocks/head', { siteTitle: `文章归档 | ${themeConfig.siteName}` }) %>\n "
},
{
"path": "public/default-files/themes/paper/templates/index.ejs",
"chars": 514,
"preview": "<!DOCTYPE html>\n<html>\n <head>\n <%- include('./_blocks/head', { siteTitle: themeConfig.siteName }) %>\n </head>\n <b"
},
{
"path": "public/default-files/themes/paper/templates/post.ejs",
"chars": 2129,
"preview": "<!DOCTYPE html>\n<html>\n <head>\n <%- include('./_blocks/head', { siteTitle: `${post.title} | ${themeConfig.siteName}`"
},
{
"path": "public/default-files/themes/paper/templates/tag.ejs",
"chars": 576,
"preview": "<!DOCTYPE html>\n<html>\n <head>\n <%- include('./_blocks/head', { siteTitle: `${tag.name} | ${themeConfig.siteName}` }"
},
{
"path": "public/default-files/themes/paper/templates/tags.ejs",
"chars": 798,
"preview": "<!DOCTYPE html>\n<html>\n <head>\n <%- include('./_blocks/head', { siteTitle: `标签列表 | ${themeConfig.siteName}` }) %>\n "
},
{
"path": "public/default-files/themes/simple/assets/styles/_core/a11y-dark.less",
"chars": 1447,
"preview": "/* a11y-dark theme */\n/* Based on the Tomorrow Night Eighties theme: https://github.com/isagalaev/highlight.js/blob/mast"
},
{
"path": "public/default-files/themes/simple/assets/styles/_core/atom-one-dark.less",
"chars": 1266,
"preview": "/*\n\nAtom One Dark by Daniel Gamage\nOriginal One Dark Syntax theme from https://github.com/atom/one-dark-syntax\n\nbase: "
},
{
"path": "public/default-files/themes/simple/assets/styles/_core/base.less",
"chars": 4812,
"preview": "/*! modern-normalize | MIT License | https://github.com/sindresorhus/modern-normalize */\n\n/* Document\n ==============="
},
{
"path": "public/default-files/themes/simple/assets/styles/_core/colors.less",
"chars": 7521,
"preview": "//\n//\n// 𝗖 𝗢 𝗟 𝗢 𝗥\n// v 1.6.3\n//\n// ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\n\n\n// General\n// ───────────────────────────"
},
{
"path": "public/default-files/themes/simple/assets/styles/_core/github.less",
"chars": 1080,
"preview": ".hljs {\n display: block;\n overflow-x: auto;\n padding: 0.5em;\n color: #333;\n background: #f8f8f8;\n}\n\n.hljs-comment,\n"
},
{
"path": "public/default-files/themes/simple/assets/styles/main.less",
"chars": 9078,
"preview": "@import \"_core/colors\";\n@import \"_core/base\";\n@import \"_core/a11y-dark\";\n\nbody {\n background: @oc-gray-0;\n color: @oc-"
},
{
"path": "public/default-files/themes/simple/config.json",
"chars": 2184,
"preview": "{\n \"name\": \"Simple\",\n \"version\": \"1.1.0\",\n \"author\": \"EryouHao\",\n \"customConfig\": [\n {\n \"name\": \"sidebarWidt"
},
{
"path": "public/default-files/themes/simple/style-override.js",
"chars": 1118,
"preview": "const generateOverride = (params = {}) => {\n let result = ''\n\n // 侧边栏宽度 - sidebarWidth\n if (params.sidebarWidth && pa"
},
{
"path": "public/default-files/themes/simple/templates/_blocks/head.ejs",
"chars": 1394,
"preview": "<meta charset=\"utf-8\" >\n\n<title><%= siteTitle %></title>\n\n<meta name=\"viewport\" content=\"width=device-width, initial-sca"
},
{
"path": "public/default-files/themes/simple/templates/_blocks/pagination.ejs",
"chars": 331,
"preview": "<div class=\"pagination-container\">\n <% if (pagination.prev) { %>\n <a href=\"<%= pagination.prev %>\" class=\"prev\"><i c"
},
{
"path": "public/default-files/themes/simple/templates/_blocks/scripts.ejs",
"chars": 1743,
"preview": "<script src=\"https://unpkg.com/aos@next/dist/aos.js\"></script>\n<script type=\"application/javascript\">\n\nAOS.init();\n\nvar "
},
{
"path": "public/default-files/themes/simple/templates/_blocks/sidebar.ejs",
"chars": 1611,
"preview": "<div class=\"sidebar\" :class=\"{ 'full-height': menuVisible }\">\n <div class=\"top-container\" data-aos=\"fade-right\">\n <d"
},
{
"path": "public/default-files/themes/simple/templates/archives.ejs",
"chars": 1365,
"preview": "<!DOCTYPE html>\n<html>\n <head>\n <%- include('./_blocks/head', { siteTitle: `文章归档 | ${themeConfig.siteName}` }) %>\n "
},
{
"path": "public/default-files/themes/simple/templates/index.ejs",
"chars": 1504,
"preview": "<!DOCTYPE html>\n<html>\n <head>\n <%- include('./_blocks/head', { siteTitle: themeConfig.siteName }) %>\n <meta name"
},
{
"path": "public/default-files/themes/simple/templates/post.ejs",
"chars": 2159,
"preview": "<!DOCTYPE html>\n<html>\n <head>\n <%- include('./_blocks/head', { siteTitle: `${post.title} | ${themeConfig.siteName}`"
},
{
"path": "public/default-files/themes/simple/templates/tag.ejs",
"chars": 1420,
"preview": "<!DOCTYPE html>\n<html>\n <head>\n <%- include('./_blocks/head', { siteTitle: `${tag.name} | ${themeConfig.siteName}` }"
},
{
"path": "public/default-files/themes/simple/templates/tags.ejs",
"chars": 719,
"preview": "<!DOCTYPE html>\n<html>\n <head>\n <%- include('./_blocks/head', { siteTitle: `标签列表 | ${themeConfig.siteName}` }) %>\n "
},
{
"path": "public/index.html",
"chars": 7130,
"preview": "<!DOCTYPE html>\n<html lang=\"en\">\n <head>\n <meta charset=\"utf-8\">\n <meta http-equiv=\"X-UA-Compatible\" content=\"IE="
},
{
"path": "src/App.vue",
"chars": 1381,
"preview": "<template>\n <div id=\"app\">\n <router-view />\n </div>\n</template>\n\n<script lang=\"ts\">\nimport { shell } from 'electron"
},
{
"path": "src/assets/locales-menu.ts",
"chars": 1783,
"preview": "const messages: any = {\n 'zh-CN': {\n edit: '编辑',\n help: '帮助',\n save: '保存',\n undo: '撤销',\n redo: '重做',\n "
},
{
"path": "src/assets/locales.ts",
"chars": 27024,
"preview": "const message = {\n zhHans: {\n preview: '预 览',\n syncSite: '同 步',\n newVersion: '有新版本',\n article: '文 章',\n m"
},
{
"path": "src/assets/styles/custom.less",
"chars": 6415,
"preview": ".ant-table {\n background: #fff;\n color: #555;\n}\n.ant-table-tbody {\n .ant-table-row:nth-of-type(2n) {\n background: "
},
{
"path": "src/assets/styles/main.less",
"chars": 142,
"preview": "// @import \"./custom.less\";\n@import \"~ant-design-vue/dist/antd.less\";\n@import \"./var.less\";\n@import \"./custom.less\";\n@im"
},
{
"path": "src/assets/styles/tailwind.css",
"chars": 285,
"preview": "@tailwind base;\n@tailwind components;\n@tailwind utilities;\n\n.transition {\n transition: all .1s ease-in !important;\n}\n\n@"
},
{
"path": "src/assets/styles/var.less",
"chars": 351,
"preview": "@primary-color: #1b1b18;\r\n@primary-bg: #f7f6f6;\r\n@danger-color: #fa5252;\r\n\r\n@border-radius-base : 6px;\r\n@link-color: #1a"
},
{
"path": "src/assets/styles/zwicon.less",
"chars": 28944,
"preview": "@font-face {\n font-family: 'zwicon';\n src: url('../fonts/zwicon.eot?k483k8');\n src: url('../fonts/zwicon.eot?k483k8"
},
{
"path": "src/background.ts",
"chars": 5634,
"preview": "import {\n app, protocol, BrowserWindow, Menu, shell,\n} from 'electron'\nimport {\n createProtocol,\n} from 'vue-cli-plugi"
},
{
"path": "src/components/AppSystem/Index.vue",
"chars": 598,
"preview": "<template>\n <div>\n <language-setting></language-setting>\n <source-folder-setting></source-folder-setting>\n <ve"
},
{
"path": "src/components/AppSystem/includes/LanguageSetting.vue",
"chars": 1376,
"preview": "<template>\n <div class=\"mb-4 py-4 border-b border-gray-200\">\n <div class=\"text-base font-medium mb-4\">{{ $t('languag"
},
{
"path": "src/components/AppSystem/includes/SourceFolderSetting.vue",
"chars": 1905,
"preview": "<template>\n <div class=\"mb-4 py-4 border-b border-gray-200\">\n <div class=\"text-base font-medium mb-4\">{{ $t('sourceF"
},
{
"path": "src/components/AppSystem/includes/Version.vue",
"chars": 859,
"preview": "<template>\n <div class=\"mb-4 py-4 border-b border-gray-200\">\n <div class=\"text-base font-medium mb-4\">{{ $t('version"
},
{
"path": "src/components/ColorCard/Index.vue",
"chars": 2282,
"preview": "<template>\n <div class=\"color-card\">\n <div class=\"item-container\" v-for=\"(item, index) in colorList\" :key=\"index\">\n "
},
{
"path": "src/components/EmojiCard/Index.vue",
"chars": 1386,
"preview": "<template>\n <div class=\"emoji-card\">\n <VEmojiPicker :pack=\"pack\" :showSearch=\"false\" :emojisByRow=\"8\" @select=\"handl"
},
{
"path": "src/components/FooterBox/Index.vue",
"chars": 421,
"preview": "<template>\n <div class=\"footer-box bg-white py-2 px-4\">\n <slot />\n </div>\n</template>\n\n<script lang=\"ts\">\nimport {\n"
},
{
"path": "src/components/Main.vue",
"chars": 14170,
"preview": "<template>\n <a-layout>\n <a-layout-sider\n class=\"sider\"\n :style=\"{ overflow: 'auto', height: '100vh', posit"
},
{
"path": "src/components/MonacoMarkdownEditor/Index.vue",
"chars": 4637,
"preview": "<template>\n <div id=\"monaco-markdown-editor\" style=\"max-width: 728px; min-height: calc(100vh - 176px); margin: 0 auto;\""
},
{
"path": "src/components/MonacoMarkdownEditor/theme.js",
"chars": 4916,
"preview": "export default {\n 'base': 'vs',\n 'inherit': true,\n 'rules': [\n {\n 'foreground': '999999',\n 'token': 'com"
},
{
"path": "src/components/PostsCard/Index.vue",
"chars": 795,
"preview": "<template>\r\n <div class=\"post-card\" v-if=\"posts && posts.length > 0\">\r\n <div class=\"item-container\" v-for=\"(post, in"
},
{
"path": "src/helpers/analytics.ts",
"chars": 1534,
"preview": "import GA from 'electron-google-analytics'\nimport macaddress from 'macaddress'\nimport * as pkg from '../../package.json'"
},
{
"path": "src/helpers/constants.ts",
"chars": 380,
"preview": "export const UrlFormats = [\n {\n text: 'Slug',\n value: 'SLUG',\n },\n {\n text: 'Short ID',\n value: 'SHORT_ID"
},
{
"path": "src/helpers/content-helper.ts",
"chars": 1377,
"preview": "export default class ContentHelper {\n localReg: RegExp\n\n domainReg: RegExp\n\n featureDomainReg: RegExp\n\n featureLocal"
},
{
"path": "src/helpers/enums.ts",
"chars": 145,
"preview": "export enum MenuTypes {\n Internal = 'Internal',\n External = 'External',\n}\n\nexport enum UrlFormats {\n Slug = 'SLUG',\n "
},
{
"path": "src/helpers/shortcut-keys.ts",
"chars": 1192,
"preview": "export default [\n {\n name: '编辑',\n list: [\n {\n title: '保存文章',\n keyboard: ['⌘', 'S'],\n },\n "
},
{
"path": "src/helpers/slug.ts",
"chars": 1903,
"preview": "/* tslint:disable */\nconst { transliterate } = require('transliteration')\nconst slug = require('slug')\n\n/*\n * Custom mod"
},
{
"path": "src/helpers/utils.ts",
"chars": 1457,
"preview": "import markdown from '../server/plugins/markdown'\n\n/**\n * Add single-quoted to string type field, in order to be compati"
},
{
"path": "src/helpers/vee-validate.ts",
"chars": 150,
"preview": "import { required } from 'vee-validate/dist/rules'\nimport { extend } from 'vee-validate'\n\nextend('required', {\n ...requ"
},
{
"path": "src/helpers/words-count.ts",
"chars": 1286,
"preview": "import striptags from 'striptags'\n\nconst CN_PATTERN = /[\\u4E00-\\u9FA5]/g\nconst EN_PATTERN = /[a-zA-Z0-9_\\u0392-\\u03c9\\u0"
},
{
"path": "src/interfaces/menu.ts",
"chars": 76,
"preview": "export interface IMenu {\n name: string\n openType: string\n link: string\n}\n"
},
{
"path": "src/interfaces/post.ts",
"chars": 237,
"preview": "export interface IPostData {\n title: string\n date: string\n published: boolean\n hideInList: boolean\n tags?: []\n fea"
},
{
"path": "src/interfaces/setting.ts",
"chars": 840,
"preview": "export interface ISetting {\n platform: 'github' | 'coding' | 'sftp' | 'gitee' | 'netlify'\n domain: string\n repository"
},
{
"path": "src/interfaces/snackbar.ts",
"chars": 186,
"preview": "export default interface ISnackbar {\n /**\n * 通知颜色:success, info, error 或其他颜色\n * default: success\n */\n color?: st"
},
{
"path": "src/interfaces/tag.ts",
"chars": 73,
"preview": "export interface ITag {\n name: string\n used: boolean\n slug?: string\n}\n"
},
{
"path": "src/interfaces/theme.ts",
"chars": 364,
"preview": "export interface ITheme {\n themeName: string\n postPageSize: number\n archivesPageSize: number\n siteName: string\n sit"
},
{
"path": "src/main.ts",
"chars": 1370,
"preview": "import Vue from 'vue'\nimport moment from 'moment'\nimport Antd from 'ant-design-vue'\nimport 'remixicon/fonts/remixicon.cs"
},
{
"path": "src/router.ts",
"chars": 1491,
"preview": "import Vue from 'vue'\nimport Router from 'vue-router'\nimport macaddress from 'macaddress'\nimport Main from './components"
},
{
"path": "src/server/app.ts",
"chars": 9469,
"preview": "import { BrowserWindow, app } from 'electron'\nimport * as fse from 'fs-extra'\nimport * as path from 'path'\nimport expres"
},
{
"path": "src/server/deploy.ts",
"chars": 4751,
"preview": "import fs from 'fs'\nimport moment from 'moment'\n// @ts-ignore\nimport Model from './model'\nimport GitProxy from './plugin"
},
{
"path": "src/server/events/deploy.ts",
"chars": 1630,
"preview": "import { ipcMain, IpcMainEvent } from 'electron'\nimport Deploy from '../deploy'\nimport Renderer from '../renderer'\nimpor"
},
{
"path": "src/server/events/index.ts",
"chars": 415,
"preview": "import SiteEvents from './site'\nimport PostEvents from './post'\nimport TagEvents from './tag'\nimport MenuEvents from './"
},
{
"path": "src/server/events/menu.ts",
"chars": 1053,
"preview": "import { ipcMain, IpcMainEvent } from 'electron'\nimport Menus from '../menus'\nimport { IMenu } from '../interfaces/menu'"
},
{
"path": "src/server/events/post.ts",
"chars": 1523,
"preview": "import { ipcMain, IpcMainEvent } from 'electron'\nimport { IPost, IPostDb } from '../interfaces/post'\nimport Posts from '"
},
{
"path": "src/server/events/renderer.ts",
"chars": 524,
"preview": "import { ipcMain, IpcMainEvent } from 'electron'\nimport Renderer from '../renderer'\n\nexport default class RendererEvents"
},
{
"path": "src/server/events/setting.ts",
"chars": 1645,
"preview": "import { ipcMain, IpcMainEvent } from 'electron'\nimport Setting from '../setting'\nimport { ICommentSetting } from '../in"
},
{
"path": "src/server/events/site.ts",
"chars": 1158,
"preview": "import { ipcMain, IpcMainEvent } from 'electron'\n\nexport default class SiteEvents {\n constructor(appInstance: any) {\n "
},
{
"path": "src/server/events/tag.ts",
"chars": 755,
"preview": "import { ipcMain, IpcMainEvent } from 'electron'\nimport Tags from '../tags'\nimport { ITag } from '../interfaces/tag'\n\nex"
},
{
"path": "src/server/events/theme.ts",
"chars": 872,
"preview": "import { ipcMain, IpcMainEvent } from 'electron'\nimport { ITheme } from '../interfaces/theme'\nimport Theme from '../them"
},
{
"path": "src/server/interfaces/application.ts",
"chars": 765,
"preview": "import { BrowserWindow } from 'electron'\nimport { IPostDb } from './post'\nimport { ITag } from './tag'\nimport { ITheme }"
},
{
"path": "src/server/interfaces/menu.ts",
"chars": 93,
"preview": "export interface IMenu {\n name: string\n index?: number\n openType: string\n link: string\n}\n"
},
{
"path": "src/server/interfaces/post.ts",
"chars": 1194,
"preview": "import { ITag } from './tag'\n\nexport interface IPost {\n title: string\n fileName: string\n tags: string[]\n date: strin"
},
{
"path": "src/server/interfaces/renderer.ts",
"chars": 65,
"preview": "export interface IPagination {\n prev: string,\n next: string,\n}\n"
},
{
"path": "src/server/interfaces/setting.ts",
"chars": 353,
"preview": "export interface IDisqusSetting {\n api: string\n apikey: string\n shortname: string\n}\nexport interface IGitalkSetting {"
},
{
"path": "src/server/interfaces/tag.ts",
"chars": 90,
"preview": "export interface ITag {\n name: string\n used: boolean\n slug?: string\n index?: number\n}\n"
},
{
"path": "src/server/interfaces/theme.ts",
"chars": 381,
"preview": "export interface ITheme {\n themeName: string\n postPageSize: number\n archivesPageSize: number\n siteName: string\n sit"
},
{
"path": "src/server/menus.ts",
"chars": 822,
"preview": "import Model from './model'\nimport { IMenu } from './interfaces/menu'\n\nexport default class Menus extends Model {\n list"
},
{
"path": "src/server/model.ts",
"chars": 1083,
"preview": "import path from 'path'\nimport low from 'lowdb'\nimport FileSync from 'lowdb/adapters/FileSync'\nimport { BrowserWindow } "
},
{
"path": "src/server/plugins/deploys/gitproxy.ts",
"chars": 2011,
"preview": "import { IApplicationDb } from '../../interfaces/application'\n\nconst { HttpProxyAgent, HttpsProxyAgent } = require('hpag"
},
{
"path": "src/server/plugins/deploys/netlify.ts",
"chars": 5859,
"preview": "import fs from 'fs'\nimport path from 'path'\nimport axios from 'axios'\nimport normalizePath from 'normalize-path'\nimport "
},
{
"path": "src/server/plugins/deploys/sftp.ts",
"chars": 3861,
"preview": "import * as fse from 'fs-extra'\n// import * as fs from 'fs'\nimport path from 'path'\nimport SftpClient from 'ssh2-sftp-cl"
},
{
"path": "src/server/plugins/markdown.ts",
"chars": 1818,
"preview": "import MarkdownIt from 'markdown-it'\nimport MarkdownItKatex from '@iktakahiro/markdown-it-katex'\nimport markdownItTocAnd"
},
{
"path": "src/server/posts.ts",
"chars": 7587,
"preview": "import * as fs from 'fs'\nimport * as fse from 'fs-extra'\nimport * as path from 'path'\nimport matter from 'gray-matter'\ni"
},
{
"path": "src/server/renderer.ts",
"chars": 19818,
"preview": "import * as fs from 'fs'\nimport urlJoin from 'url-join'\nimport Bluebird from 'bluebird'\nimport * as fse from 'fs-extra'\n"
},
{
"path": "src/server/setting.ts",
"chars": 1109,
"preview": "import * as fse from 'fs-extra'\nimport * as path from 'path'\nimport Model from './model'\nimport { ICommentSetting } from"
},
{
"path": "src/server/tags.ts",
"chars": 2389,
"preview": "import shortid from 'shortid'\nimport Model from './model'\nimport { ITag } from './interfaces/tag'\nimport slug from '../h"
},
{
"path": "src/server/theme.ts",
"chars": 7413,
"preview": "import * as path from 'path'\nimport * as fse from 'fs-extra'\nimport junk from 'junk'\nimport Model from './model'\nimport "
},
{
"path": "src/server.ts",
"chars": 890,
"preview": "import express from 'express'\n\nexport default function initServer() {\n const app = express()\n let server: any = null\n\n"
},
{
"path": "src/shims-tsx.d.ts",
"chars": 304,
"preview": "import Vue, { VNode } from 'vue'\n\ndeclare global {\n namespace JSX {\n // tslint:disable no-empty-interface\n interf"
},
{
"path": "src/shims-vue.d.ts",
"chars": 1656,
"preview": "declare module '*.vue' {\n import { ComponentOptions } from 'vue'\n\n export default Vue\n}\ndeclare module '*.json' {\n co"
},
{
"path": "src/shims.d.ts",
"chars": 149,
"preview": "import { AllElectron } from 'electron'\n\ndeclare module 'vue/types/vue' {\n interface Vue {\n readonly $electron: AllEl"
},
{
"path": "src/store/index.ts",
"chars": 208,
"preview": "import Vue from 'vue'\nimport Vuex from 'vuex'\nimport site from './modules/site'\n\nVue.use(Vuex)\n\nexport default new Vuex."
},
{
"path": "src/store/modules/site.ts",
"chars": 3753,
"preview": "import { ActionTree, Module, MutationTree } from 'vuex'\nimport { IPost } from '../../interfaces/post'\nimport { ITag } fr"
},
{
"path": "src/views/article/ArticleUpdate.vue",
"chars": 30666,
"preview": "<template>\n <div class=\"article-update-page\" :class=\"{ 'is-entering': entering }\" v-if=\"visible\" @mousemove=\"handlePage"
},
{
"path": "src/views/article/Articles.vue",
"chars": 8279,
"preview": "<template>\r\n <div class=\"articles-page\">\r\n <div class=\"flex justify-between tool-container\">\r\n <div class=\"flex"
},
{
"path": "src/views/loading/Index.vue",
"chars": 664,
"preview": "<template>\n <div class=\"loading-page\">\n <img class=\"img\" src=\"@/assets/images/developing_code.svg\" width=\"160px\">\n "
},
{
"path": "src/views/menu/Index.vue",
"chars": 6945,
"preview": "<template>\n <div class=\"\">\n <a-row type=\"flex\" justify=\"end\" class=\"tool-container\">\n <a-tooltip placement=\"bot"
},
{
"path": "src/views/setting/Index.vue",
"chars": 815,
"preview": "<template>\n <div class=\"\">\n <a-tabs class=\"menu-tab\" defaultActiveKey=\"1\" :animated=\"false\">\n <a-tab-pane :tab="
},
{
"path": "src/views/setting/includes/BasicSetting.vue",
"chars": 11315,
"preview": "<template>\n <div>\n <a-form :form=\"form\" style=\"padding-bottom: 48px;\">\n <a-form-item :label=\"$t('platform')\" :l"
},
{
"path": "src/views/setting/includes/CommentSetting.vue",
"chars": 2591,
"preview": "<template>\n <div>\n <a-form :form=\"form\" style=\"padding-bottom: 48px;\">\n <a-form-item :label=\"$t('platform')\" :l"
},
{
"path": "src/views/setting/includes/DisqusSetting.vue",
"chars": 1571,
"preview": "<template>\n <div>\n <a-form-item label=\" \" :labelCol=\"formLayout.label\" :wrapperCol=\"formLayout.wrapper\" :colon=\"fals"
},
{
"path": "src/views/setting/includes/GitalkSetting.vue",
"chars": 1804,
"preview": "<template>\n <div>\n <a-form-item label=\" \" :labelCol=\"formLayout.label\" :wrapperCol=\"formLayout.wrapper\" :colon=\"fals"
},
{
"path": "src/views/tags/Index.vue",
"chars": 5735,
"preview": "<template>\n <div class=\"\">\n <a-row type=\"flex\" justify=\"end\" class=\"tool-container\">\n <a-tooltip placement=\"bot"
},
{
"path": "src/views/theme/Index.vue",
"chars": 1368,
"preview": "<template>\n <div class=\"\">\n <a-tabs class=\"menu-tab\" defaultActiveKey=\"basic\" v-model=\"currentTab\" forceRender :anim"
},
{
"path": "src/views/theme/includes/AvatarSetting.vue",
"chars": 2047,
"preview": "<template>\n <div>\n <a-upload\n action=\"\"\n listType=\"picture-card\"\n class=\"feature-uploader\"\n :sho"
},
{
"path": "src/views/theme/includes/BasicSetting.vue",
"chars": 9545,
"preview": "<template>\n <div>\n <ValidationObserver ref=\"observer\" v-slot=\"{ invalid }\">\n <a-form :form=\"form\" style=\"paddin"
},
{
"path": "src/views/theme/includes/CustomSetting.vue",
"chars": 16579,
"preview": "<template>\n <div>\n <div v-if=\"currentThemeConfig.length > 0\" style=\"padding-bottom: 48px;\">\n <a-tabs tabPositio"
}
]
// ... and 6 more files (download for full content)
About this extraction
This page contains the full source code of the getgridea/gridea GitHub repository, extracted and formatted as plain text for AI agents and large language models (LLMs). The extraction includes 206 files (508.3 KB), approximately 158.0k tokens, and a symbol index with 184 extracted functions, classes, methods, constants, and types. Use this with OpenClaw, Claude, ChatGPT, Cursor, Windsurf, or any other AI tool that accepts text input. You can copy the full output to your clipboard or download it as a .txt file.
Extracted by GitExtract — free GitHub repo to text converter for AI. Built by Nikandr Surkov.