master
xaoxuu 4 years ago
parent dadb0a16ab
commit 0a0b297b3a
  1. 344
      _config.yml
  2. 6
      layout/_cover/docs.ejs
  3. 2
      layout/_meta/counter.ejs
  4. 4
      layout/_partial/archive.ejs
  5. 2
      layout/_partial/article.ejs
  6. 2
      layout/_partial/footer.ejs
  7. 2
      layout/_partial/head.ejs
  8. 2
      layout/_partial/header.ejs
  9. 4
      layout/_partial/post.ejs
  10. 99
      layout/_partial/scripts.ejs
  11. 4
      layout/_third-party/aplayer.ejs
  12. 14
      layout/_third-party/comments.ejs
  13. 4
      layout/_widget/_pre.ejs
  14. 4
      layout/_widget/music.ejs
  15. 4
      layout/archive.ejs
  16. 2
      layout/category.ejs
  17. 2
      layout/links.ejs
  18. 2
      layout/tag.ejs
  19. 6
      source/css/_defines/effect.styl
  20. 31
      source/css/_defines/fonts.styl
  21. 14
      source/css/_defines/layout.styl
  22. 2
      source/css/_highlight/index.styl
  23. 1
      source/css/_layout/navbar.styl
  24. 2
      source/less/_color.less

@ -1,78 +1,45 @@
############################### 主题基本信息 ###############################
############################### Basic Information ###############################
info:
name: Volantis
version: '2.0-beta3'
docs: https://volantis.js.org/
cdn: # 要使用CDN,请在根目录的config文件中写上 use_cdn: true
cdn: # To use CDN, write 'use_cdn: true' in 'blog/_config.yml'.
css:
# style: https://cdn.jsdelivr.net/gh/xaoxuu/cdn-volantis@1.7.4/css/style.css
js:
app: https://cdn.jsdelivr.net/gh/xaoxuu/cdn-volantis@1.7.4/js/app.js
# search: https://cdn.jsdelivr.net/gh/xaoxuu/cdn-volantis@1.7.4/js/search.js
valine: https://cdn.jsdelivr.net/gh/xaoxuu/cdn-volantis@1.7.4/js/valine.js
############################### 第三方插件 ###############################
# ⚠ 注意:开启过多服务会导致网页加载缓慢、运行卡顿
plugins:
# jquery是很多功能的基础,请勿关闭
jquery: https://cdn.jsdelivr.net/npm/jquery@3.4.1/dist/jquery.min.js
################################################## 提升速度类的服务
# 鼠标放在链接上就提前开始加载了 [站内的url一定要以‘/’结尾]
instant_page: https://cdn.jsdelivr.net/gh/xaoxuu/cdn-volantis@1.7.4/js/instant_page.js
################################################## 优化体验类的服务
# 图片放大预览
fancybox:
css: https://cdn.jsdelivr.net/npm/@fancyapps/fancybox@3.5.7/dist/jquery.fancybox.min.css
js: https://cdn.jsdelivr.net/gh/fancyapps/fancybox@3.5.7/dist/jquery.fancybox.min.js
# 页面滚动显示动画
scrollreveal: #https://cdn.jsdelivr.net/npm/scrollreveal@4.0.5/dist/scrollreveal.min.js
# 代码块复制按钮
clipboard: https://cdn.jsdelivr.net/npm/clipboard@2/dist/clipboard.min.js
################################################## 运维服务
# 访问量统计【加载非常缓慢】
busuanzi: https://cdn.jsdelivr.net/gh/xaoxuu/cdn-busuanzi@2.3/js/busuanzi.pure.mini.js
# 文章字数统计、阅读时长,开启需要安装插件: npm i --save hexo-wordcount
wordcount: #true
################################################## 美化类的服务
# 按钮点击涟漪效果
nodewaves:
css: https://cdn.jsdelivr.net/npm/node-waves@0.7.6/dist/waves.min.css
js: https://cdn.jsdelivr.net/npm/node-waves@0.7.6/dist/waves.min.js
# 文本框打字机特效
comment_typing: https://cdn.jsdelivr.net/gh/xaoxuu/cdn-volantis@1.7.4/js/comment_typing.js
############################### 主题样式 ###############################
# 样式
############################### Style ###############################
style:
# 卡片阴影效果
shadow:
# 导航栏阴影
nav: true
# 卡片阴影和悬浮动画
card: true
# 毛玻璃效果 具体效果调整在: source/less/_color.less
blur:
navbar: true
# widget: true
# body: true
# 建议:
# 有背景图:开启毛玻璃,关闭卡片阴影
# 无背景图:关闭毛玻璃,开启卡片阴影
highlight:
language: false # 是否显示语言
# fontfamily: CourierNew
# align: # left, right, justify, center
# h1: center
# h2: center
# h3: center
# h4: center
# navbar_height: 64px # 导航栏高度
# max_width: 1080px # 最大布局宽度,包含侧边栏
max_width: 1080px # Sum of body width and sidebar width
navbar:
height: 64px
effect: [shadow, blur]
sidebar:
effect: [shadow]
body:
effect: [shadow]
highlight:
language: false # show language of codeblock
text_align: # left, right, justify, center
h1: left
h2: left
h3: left
h4: left
p: justify
fontfamily:
bodyfont:
name: 'Varela Round'
url: https://cdn.jsdelivr.net/gh/xaoxuu/cdn-fonts/VarelaRound/VarelaRound-Regular.ttf
weight: normal
style: normal
# codefont:
# name: 'Monaco'
# url: https://cdn.jsdelivr.net/gh/xaoxuu/cdn-fonts/Monaco/Monaco.ttf
# weight: normal
# style: normal
# color:
# site: '#21232F' # 网页背景颜色
# card: '#444' # 卡片背景
@ -85,37 +52,11 @@ style:
# inlinecode: yellow # 行内代码颜色
# codeblock: '#555' # 代码块背景
# p: '#ccc'
# # h1: # H1标题颜色
# # h2: # H2标题颜色
# # h3: # H3标题颜色
# # h4: # H4标题颜色
# 幻灯片背景
backstretch:
enable: true # 是否启用
js: '//cdn.jsdelivr.net/npm/jquery-backstretch@2.1.18/jquery.backstretch.min.js'
position: cover # cover: 封面背景 fixed: 整个网页背景
duration: 20000 # 持续时间(毫秒)
fade: 2500 # 渐变(毫秒)
is_dark: #true # 图片是否是暗色的(调整文字为白色)
images: # 我上传了一些高清壁纸到CDN中,仅限个人使用,商用后果自负!!!
- https://cdn.jsdelivr.net/gh/xaoxuu/cdn-wallpaper/abstract/41F215B9-261F-48B4-80B5-4E86E165259E.jpeg
# - https://cdn.jsdelivr.net/gh/xaoxuu/cdn-wallpaper/abstract/BBC19066-E176-47C2-9D22-48C81EE5DF6B.jpeg
# - https://cdn.jsdelivr.net/gh/xaoxuu/cdn-wallpaper/abstract/B18FCBB3-67FD-48CC-B4F3-457BA145F17A.jpeg
# - https://cdn.jsdelivr.net/gh/xaoxuu/cdn-wallpaper/abstract/00E0F0ED-9F1C-407A-9AA6-545649D919F4.jpeg
# # 下面这些建议 is_dark: true
# - https://cdn.jsdelivr.net/gh/xaoxuu/cdn-wallpaper/abstract/67239FBB-E15D-4F4F-8EE8-0F1C9F3C4E7C.jpeg
# - https://cdn.jsdelivr.net/gh/xaoxuu/cdn-wallpaper/abstract/B951AE18-D431-417F-B3FE-A382403FF21B.jpeg
# - https://cdn.jsdelivr.net/gh/xaoxuu/cdn-wallpaper/landscape/AEB33F9D-7294-4CF1-B8C5-3020748A9D45.jpeg
# - https://cdn.jsdelivr.net/gh/xaoxuu/cdn-wallpaper/abstract/2884F904-F1F3-479E-AE27-5EBC291B63B0.jpeg
# - https://cdn.jsdelivr.net/gh/xaoxuu/cdn-wallpaper/landscape/10A0FCE5-36A1-4AD0-8CF0-019259A89E03.jpeg
# - https://cdn.jsdelivr.net/gh/xaoxuu/cdn-wallpaper/landscape/250662D4-5A21-4AAA-BB63-CD25CF97CFF1.jpeg
# - https://cdn.jsdelivr.net/gh/xaoxuu/cdn-wallpaper/landscape/298468D7-E388-44A8-8CC5-8213BDC33CED.jpeg
############################### 自定义 ###############################
############################### Layout ###############################
# page的封面
cover:
scheme: docs # docs: 适合文档的封面方案 blog: 适合博客的封面方案
@ -156,7 +97,8 @@ navbar:
# 显示标题
title:
# logo后面的导航菜单
menu: # 下面的内容可以写在 `blog/source/_data/menu.yml` 中
menu:
# The following can be written in `blog/source/_data/menu.yml`
# 在桌面端显示的导航菜单
on_desktop:
- name: 博客
@ -202,7 +144,8 @@ navbar:
# 布局
layout: # 下面的内容可以写在 `blog/source/_data/layout.yml` 中
layout:
# The following can be written in `blog/source/_data/layout.yml`
# 文章列表多列布局
multiple_columns: false # 部分浏览器不兼容,谨慎使用
# 文章列表(主页、自定义的列表)布局
@ -230,7 +173,7 @@ layout: # 下面的内容可以写在 `blog/source/_data/layout.yml` 中
# 其他的页面布局暂时等于 on_list
# meta库配置
# meta library
meta:
# 文章标题
title: # 暂无配置
@ -309,8 +252,9 @@ meta:
title: 反馈
color: '#1BCDFC'
# 组件库配置
widget: # 下面的内容可以写在 `blog/source/_data/widget.yml` 中
# widget library
widget:
# The following can be written in `blog/source/_data/widget.yml`
# ---------------------------------------
# 博主信息小部件配置
blogger:
@ -400,25 +344,8 @@ widget: # 下面的内容可以写在 `blog/source/_data/widget.yml` 中
# 网站页脚
footer:
# 网站页脚布局,默认支持 aplayer/social/license/info/copyright
# layout of footer: [aplayer, social, license, info, copyright]
layout: [aplayer, social, license, info, copyright]
# APlayer配置 https://github.com/metowolf/MetingJS
aplayer:
# 是否启用,注释此项则不加载服务
enable: true
# 必选参数
server: netease # netease, tencent, kugou, xiami, baidu
type: playlist # song, playlist, album, search, artist
id: 3175833810 # song id / playlist id / album id / search keyword
# 可选参数
fixed: false # enable fixed mode
theme: '#1BCDFC' # main color
autoplay: false # audio autoplay
order: list # player play order, values: 'list', 'random'
loop: all # player loop play, values: 'all', 'one', 'none'
volume: 0.7 # default volume, notice that player will remember user setting, default volume will not work after user set volume themselves
list_max_height: 340px # list max height
list_folded: true
# 社交信息配置
social:
- icon: fas fa-rss
@ -434,7 +361,7 @@ footer:
br: '<br>'
############################### SEO ###############################
seo:
# 当文章front-matter中没有keywords时,使用tags作为keywords
use_tags_as_keywords: true
@ -446,71 +373,142 @@ seo:
archive: noindex,follow
category: noindex,follow
tag: noindex,follow
# 其它页面自己在front-matter中写
# robots can be written in front-matter
############################### 需要复制到根目录配置文件中 ###############################
# 请复制到根目录配置文件!
# copyright: '[Copyright © 2017-2020 Mr. X](https://xaoxuu.com)'
############################### Plugins ###############################
plugins:
# Required
jquery: https://cdn.jsdelivr.net/npm/jquery@3.4.1/dist/jquery.min.js
################################################## 提升速度类的服务
# Preload (The menu's url must end with ‘/’)
instant_page: https://cdn.jsdelivr.net/gh/xaoxuu/cdn-volantis@1.7.4/js/instant_page.js
################################################## 优化体验类的服务
# Picture Zoom
fancybox:
css: https://cdn.jsdelivr.net/npm/@fancyapps/fancybox@3.5.7/dist/jquery.fancybox.min.css
js: https://cdn.jsdelivr.net/gh/fancyapps/fancybox@3.5.7/dist/jquery.fancybox.min.js
# Page Scrolling Animation
scrollreveal: #https://cdn.jsdelivr.net/npm/scrollreveal@4.0.5/dist/scrollreveal.min.js
# Codeblock Copy Button
clipboard: https://cdn.jsdelivr.net/npm/clipboard@2/dist/clipboard.min.js
################################################## 运维服务
# 访问量统计【加载非常缓慢】
busuanzi: https://cdn.jsdelivr.net/gh/xaoxuu/cdn-busuanzi@2.3/js/busuanzi.pure.mini.js
# 文章字数统计、阅读时长,开启需要安装插件: npm i --save hexo-wordcount
wordcount: #true
################################################## 美化类的服务
# Button Ripple Effect
nodewaves:
css: https://cdn.jsdelivr.net/npm/node-waves@0.7.6/dist/waves.min.css
js: https://cdn.jsdelivr.net/npm/node-waves@0.7.6/dist/waves.min.js
# Typing Effects
comment_typing: https://cdn.jsdelivr.net/gh/xaoxuu/cdn-volantis@1.7.4/js/comment_typing.js
# Slide Background
backstretch:
enable: true
js: https://cdn.jsdelivr.net/npm/jquery-backstretch@2.1.18/jquery.backstretch.min.js
position: cover # cover: 封面背景 fixed: 整个网页背景
duration: 20000 # 持续时间(毫秒)
fade: 2500 # 渐变(毫秒)
is_dark: #true # 图片是否是暗色的(调整文字为白色)
images: # 我上传了一些高清壁纸到CDN中,仅限个人使用,商用后果自负!!!
- https://cdn.jsdelivr.net/gh/xaoxuu/cdn-wallpaper/abstract/41F215B9-261F-48B4-80B5-4E86E165259E.jpeg
# - https://cdn.jsdelivr.net/gh/xaoxuu/cdn-wallpaper/abstract/BBC19066-E176-47C2-9D22-48C81EE5DF6B.jpeg
# - https://cdn.jsdelivr.net/gh/xaoxuu/cdn-wallpaper/abstract/B18FCBB3-67FD-48CC-B4F3-457BA145F17A.jpeg
# - https://cdn.jsdelivr.net/gh/xaoxuu/cdn-wallpaper/abstract/00E0F0ED-9F1C-407A-9AA6-545649D919F4.jpeg
# # 下面这些建议 is_dark: true
# - https://cdn.jsdelivr.net/gh/xaoxuu/cdn-wallpaper/abstract/67239FBB-E15D-4F4F-8EE8-0F1C9F3C4E7C.jpeg
# - https://cdn.jsdelivr.net/gh/xaoxuu/cdn-wallpaper/abstract/B951AE18-D431-417F-B3FE-A382403FF21B.jpeg
# - https://cdn.jsdelivr.net/gh/xaoxuu/cdn-wallpaper/landscape/AEB33F9D-7294-4CF1-B8C5-3020748A9D45.jpeg
# - https://cdn.jsdelivr.net/gh/xaoxuu/cdn-wallpaper/abstract/2884F904-F1F3-479E-AE27-5EBC291B63B0.jpeg
# - https://cdn.jsdelivr.net/gh/xaoxuu/cdn-wallpaper/landscape/10A0FCE5-36A1-4AD0-8CF0-019259A89E03.jpeg
# - https://cdn.jsdelivr.net/gh/xaoxuu/cdn-wallpaper/landscape/250662D4-5A21-4AAA-BB63-CD25CF97CFF1.jpeg
# - https://cdn.jsdelivr.net/gh/xaoxuu/cdn-wallpaper/landscape/298468D7-E388-44A8-8CC5-8213BDC33CED.jpeg
# APlayer config: https://github.com/metowolf/MetingJS
aplayer:
enable: true
js:
- https://cdn.jsdelivr.net/npm/aplayer@1.10/dist/APlayer.min.js
- https://cdn.jsdelivr.net/npm/meting@2.0/dist/Meting.min.js
# Required
server: netease # netease, tencent, kugou, xiami, baidu
type: playlist # song, playlist, album, search, artist
id: 3175833810 # song id / playlist id / album id / search keyword
# Optional
fixed: false # enable fixed mode
theme: '#1BCDFC' # main color
autoplay: false # audio autoplay
order: list # player play order, values: 'list', 'random'
loop: all # player loop play, values: 'all', 'one', 'none'
volume: 0.7 # default volume, notice that player will remember user setting, default volume will not work after user set volume themselves
list_max_height: 340px # list max height
list_folded: true
############################### 评论系统 ###############################
# disqus_shortname: 要使用哪个请复制到根目录配置文件!
# livere_uid: 要使用哪个请复制到根目录配置文件!
# gitalk: 要使用哪个请复制到根目录配置文件!
# clientID: 你的clientID
# clientSecret: 你的clientSecret
# repo: 你的repo名
# owner: 你的GitHub名
# admin: [] 至少填写你的GitHub名
# leancloud: 要使用哪个请复制到根目录配置文件!
# app_id: 你的appId
# app_key: 你的appKey
############################### 杂项,请勿删除 ###############################
############################### Comments ###############################
comments:
title: <i class='fas fa-comments'></i> 评论
subtitle:
#valine配置
valine:
enable: true # 如果你想用Valine评论系统,请设置enable为true
# 还需要在根目录配置文件中添加下面这三行内容
# leancloud:
# app_id: 你的appId
# app_key: 你的appKey
# valine_path: 全站采用同一个path(共用同一个评论框数据)
guest_info: nick,mail,link #valine comment header info
placeholder: 快来评论吧~ # valine comment input placeholder(like: Please leave your footprints )
avatar: mp # gravatar style https://valine.js.org/avatar
pageSize: 10 # comment list page size
verify: true # valine verify code (true/false)
notify: true # valine mail notify (true/false)
lang: zh-cn
highlight: true
visitor: false # 阅读统计,按照官网文档接入了,但是依然不能用。
# 搜索配置
service: valine # valine, disqus, gitalk, livere
valine:
appId: #你的appId
appKey: #你的appKey
js: https://cdn.jsdelivr.net/gh/xaoxuu/cdn-volantis@1.7.4/js/valine.js
path: # 全站采用同一个path(共用同一个评论框数据)
meta: nick,mail,link #valine comment header info
placeholder: 快来评论吧~ # valine comment input placeholder(like: Please leave your footprints )
avatar: mp # gravatar style https://valine.js.org/avatar
pageSize: 10 # comment list page size
verify: true # valine verify code (true/false)
notify: true # valine mail notify (true/false)
lang: zh-cn
highlight: true
visitor: false # 阅读统计,按照官网文档接入了,但是依然不能用。
disqus:
shortname:
gitalk:
clientID:
clientSecret:
repo:
owner:
admin: # []
livere:
uid:
############################### Search ###############################
search:
enable: true
service: hexo # 类型:google, algolia, azure, baidu 默认 hexo
# 选择你选取的搜索服务后,复制相应的配置到根目录配置文件中
# google:
# apiKey:
# engineId:
# algolia:
# applicationID:
# apiKey:
# indexName:
# azure:
# serviceName:
# indexName:
# queryKey:
# baidu:
# apiId:
# Less渲染
less:
compress: true
service: hexo # hexo, google, algolia, azure, baidu
google:
apiKey:
engineId:
algolia:
applicationID:
apiKey:
indexName:
azure:
serviceName:
indexName:
queryKey:
baidu:
apiId:

@ -1,9 +1,9 @@
<% if (theme.cover.logo) { %>
<img class='logo' src='<%- url_for(theme.cover.logo) %>'/>
<% } else { %>
<p class="title <%- theme.backstretch && theme.backstretch.is_dark ? 'white' : '' %>"><%- theme.cover.title ? theme.cover.title : config.title %></p>
<p class="title <%- theme.plugins.backstretch && theme.plugins.backstretch.is_dark ? 'white' : '' %>"><%- theme.cover.title ? theme.cover.title : config.title %></p>
<% if (theme.cover.subtitle) { %>
<p class="subtitle <%- theme.backstretch && theme.backstretch.is_dark ? 'white' : '' %>"><%- theme.cover.subtitle%></p>
<p class="subtitle <%- theme.plugins.backstretch && theme.plugins.backstretch.is_dark ? 'white' : '' %>"><%- theme.cover.subtitle%></p>
<% } %>
<% } %>
<% if (theme.search.enable === true) { %>
@ -19,7 +19,7 @@
<% if (theme.cover.features) { %>
<% (theme.cover.features || []).forEach(function(value){ %>
<li>
<a class="nav home <%- theme.backstretch && theme.backstretch.is_dark ? 'white' : '' %>"
<a class="nav home <%- theme.plugins.backstretch && theme.plugins.backstretch.is_dark ? 'white' : '' %>"
href="<%= url_for(value.url) %>"
<% if (value.rel) { %>
rel="<%- value.rel %>"

@ -1,5 +1,5 @@
<% if(!isPostList){ %>
<% if (config.leancloud && config.leancloud.app_id && config.leancloud.app_key && theme.valine.visitor) { %>
<% if (theme.comments.valine && theme.comments.valine.appId && theme.comments.valine.visitor) { %>
<div class="new-meta-item browse valine">
<a class='notlink'>
<i class="<%- theme.meta.counter.icon %>" aria-hidden="true"></i>

@ -37,7 +37,7 @@
<div class="prev-next">
<% if (page.prev != 0) { %>
<a class="prev" rel="prev" href="<%= url_for(page.prev_link) %>">
<section class="post prev white-box <%- theme.style.shadow.card ? 'card-shadow' : '' %> <%- theme.style.blur && theme.style.blur.widget ? 'widget-blur' : '' %>" >
<section class="post prev white-box <%- theme.style.body.effect.join(' ') %>" >
<i class="fas fa-chevron-left" aria-hidden="true"></i>&nbsp;<%- __('post.prev_page') %>&nbsp;
</section>
</a>
@ -47,7 +47,7 @@
</p>
<% if (page.next != 0) { %>
<a class="next" rel="next" href="<%= url_for(page.next_link) %>">
<section class="post next white-box <%- theme.style.shadow.card ? 'card-shadow' : '' %> <%- theme.style.blur && theme.style.blur.widget ? 'widget-blur' : '' %>">
<section class="post next white-box <%- theme.style.body.effect.join(' ') %>">
&nbsp;<%- __('post.next_page') %>&nbsp;<i class="fas fa-chevron-right" aria-hidden="true"></i>
</section>
</a>

@ -1,7 +1,7 @@
<% var sections = page.body ? page.body : theme.layout.on_page.body; %>
<% sections.forEach(function(widget_id){ %>
<% if (widget_id == 'article') { %>
<article id="<%= post.layout %>" class="post white-box <%- theme.style.shadow.card ? 'card-shadow' : '' %> <%- theme.style.blur && theme.style.blur.body ? 'body-blur' : '' %> article-type-<%= post.layout %>" itemscope itemprop="blogPost">
<article id="<%= post.layout %>" class="post white-box <%- theme.style.body.effect.join(' ') %> article-type-<%= post.layout %>" itemscope itemprop="blogPost">
<%- partial('meta', {post: post, position: 'header'}) %>
<section class="article typo">
<div class="article-entry" itemprop="articleBody">

@ -5,7 +5,7 @@
layout = config.theme_config.footer.layout;
}
%>
<footer class="clearfix <%- theme.backstretch && theme.backstretch.is_dark ? 'white' : '' %>">
<footer class="clearfix <%- theme.plugins.backstretch && theme.plugins.backstretch.is_dark ? 'white' : '' %>">
<br><br>
<% layout.forEach(function(item){ %>
<% if (item == 'social') { %>

@ -95,7 +95,7 @@
<link rel="shortcut icon" type='image/x-icon' href="<%- url_for(config.favicon) %>">
<% } %>
<% if (theme.footer.aplayer.enable) { %>
<% if (theme.plugins.aplayer.enable) { %>
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/aplayer@1.10/dist/APlayer.min.css">
<% } %>

@ -1,7 +1,7 @@
<div id="loading-bar-wrapper">
<div id="loading-bar"></div>
</div>
<header class="l_header<%- page.sidebar == false ? ' no_sidebar' : '' %> <%- theme.style.blur && theme.style.blur.navbar ? 'nav-blur' : '' %>">
<header class="l_header<%- page.sidebar == false ? ' no_sidebar' : '' %> <%- theme.style.navbar.effect.join(' ') %>">
<div class='wrapper'>
<div class="nav-main container container--flex">
<% if (theme.navbar.logo) { %>

@ -1,4 +1,4 @@
<article class="post white-box <%- theme.style.shadow.card ? 'card-shadow' : '' %> <%- theme.style.blur && theme.style.blur.body ? 'body-blur' : '' %> reveal <%= (post.title) ? "" : "no-title" %>">
<article class="post white-box <%- theme.style.body.effect.join(' ') %> reveal <%= (post.title) ? "" : "no-title" %>">
<%- partial('meta',{post:post, position:'header'}) %>
<section class="article typo">
<div class="article-entry" itemprop="articleBody">
@ -12,7 +12,7 @@
</a>
</div>
<% } else { %>
<% } %>
<% } %>
</div>

@ -2,20 +2,20 @@
<% if (theme.search && theme.search.enable) { %>
<script>
<% if(theme.search.service === 'baidu') { %>
var BAIDU_API_ID = "<%- config.baidu.apiId %>";
var BAIDU_API_ID = "<%- theme.search.baidu.apiId %>";
<%} else if(theme.search.service === 'algolia') { %>
var ALGOLIA_API_KEY = "<%- config.algolia.apiKey %>";
var ALGOLIA_APP_ID = "<%- config.algolia.applicationID %>";
var ALGOLIA_INDEX_NAME = "<%- config.algolia.indexName %>";
var ALGOLIA_API_KEY = "<%- theme.search.algolia.apiKey %>";
var ALGOLIA_APP_ID = "<%- theme.search.algolia.applicationID %>";
var ALGOLIA_INDEX_NAME = "<%- theme.search.algolia.indexName %>";
<%} else if(theme.search.service === 'azure') { %>
var AZURE_QUERY_KEY = "<%- config.azure.queryKey %>";
var AZURE_INDEX_NAME = "<%- config.azure.indexName %>";
var AZURE_SERVICE_NAME = "<%- config.azure.serviceName %>";
var AZURE_QUERY_KEY = "<%- theme.search.azure.queryKey %>";
var AZURE_INDEX_NAME = "<%- theme.search.azure.indexName %>";
var AZURE_SERVICE_NAME = "<%- theme.search.azure.serviceName %>";
<%} else if(theme.search.service === 'google') { %>
var GOOGLE_CUSTOM_SEARCH_API_KEY = "<%- config.google.apiKey %>";
var GOOGLE_CUSTOM_SEARCH_ENGINE_ID = "<%- config.google.engineId %>";
var GOOGLE_CUSTOM_SEARCH_API_KEY = "<%- theme.search.google.apiKey %>";
var GOOGLE_CUSTOM_SEARCH_ENGINE_ID = "<%- theme.search.google.engineId %>";
<%}%>
var SEARCH_SERVICE = "<%- theme.search.service%>" || "hexo";
var SEARCH_SERVICE = "<%- theme.search.service %>" || "hexo";
var ROOT = "<%- config.root %>" || "/";
if (!ROOT.endsWith('/')) ROOT += '/';
</script>
@ -23,10 +23,6 @@
<% if (theme.plugins.instant_page) { %>
<script async src="<%- theme.plugins.instant_page %>" type="module" defer integrity="sha384-OeDn4XE77tdHo8pGtE1apMPmAipjoxUQ++eeJa6EtJCfHlvijigWiJpD7VDPWXV1"></script>
<% } %>
<% if (theme.footer.aplayer.enable) { %>
<script async src="https://cdn.jsdelivr.net/npm/aplayer@1.10/dist/APlayer.min.js"></script>
<script async src="https://cdn.jsdelivr.net/npm/meting@2.0/dist/Meting.min.js"></script>
<% } %>
<% if (theme.plugins.scrollreveal) { %>
<script src="<%- theme.plugins.scrollreveal %>"></script>
<script type="text/javascript">
@ -56,30 +52,30 @@
<script async src="<%- theme.plugins.busuanzi %>"></script>
<% } %>
<% if (theme.backstretch && theme.backstretch.enable && (theme.backstretch.images || page.images)) { %>
<% var imgs = theme.backstretch.images || page.images; %>
<% if (theme.plugins.backstretch && theme.plugins.backstretch.enable && (theme.plugins.backstretch.images || page.images)) { %>
<% var imgs = theme.plugins.backstretch.images || page.images; %>
<% var posi = null;
if (theme.backstretch.position == 'cover') {
if (theme.plugins.backstretch.position == 'cover') {
posi = '.cover';
}
%>
<% if (imgs != undefined && theme.backstretch.position != undefined){ %>
<%- js(theme.backstretch.js) %>
<% if (imgs != undefined && theme.plugins.backstretch.position != undefined){ %>
<%- js(theme.plugins.backstretch.js) %>
<script type="text/javascript">
$(function(){
if ('<%- posi %>') {
$('<%- posi %>').backstretch(
<%- '["' + imgs.join('", "') + '"]' %>,
{
duration: "<%- theme.backstretch.duration %>",
fade: "<%- theme.backstretch.fade %>"
duration: "<%- theme.plugins.backstretch.duration %>",
fade: "<%- theme.plugins.backstretch.fade %>"
});
} else {
$.backstretch(
<%- '["' + imgs.join('", "') + '"]' %>,
{
duration: "<%- theme.backstretch.duration %>",
fade: "<%- theme.backstretch.fade %>"
duration: "<%- theme.plugins.backstretch.duration %>",
fade: "<%- theme.plugins.backstretch.fade %>"
});
}
});
@ -87,30 +83,35 @@
<% } %>
<% } %>
<% if (theme.plugins.aplayer && theme.plugins.aplayer.enable && theme.plugins.aplayer.js) { %>
<% (theme.plugins.aplayer.js||[]).forEach(function(item){ %>
<%- js({src:item,async:true}) %>
<% }) %>
<% } %>
<%
var enableDisqus = false;
var enableLivere = false;
var enableGitalk = false;
var enableValine = false;
if (page && page.comments == true) {
if (config.disqus_shortname) {
if (theme.comments && page && page.comments == true) {
if (theme.comments.disqus && theme.comments.disqus.shortname) {
enableDisqus = true;
}
if (config.livere_uid) {
if (theme.comments.livere && theme.comments.livere.uid) {
enableLivere = true;
}
if (config.gitalk) {
if (theme.comments.gitalk && theme.comments.gitalk.clientID) {
enableGitalk = true;
}
if (theme.valine.enable && config.leancloud) {
if (theme.comments.valine && theme.comments.valine.appId) {
enableValine = true;
}
}
%>
<% if (enableDisqus){ %>
<script>
var disqus_shortname = '<%= config.disqus_shortname %>';
var disqus_shortname = '<%= theme.comments.disqus.shortname %>';
<% if (page.permalink){ %>
var disqus_url = '<%= page.permalink %>';
<% } %>
@ -140,11 +141,11 @@
<script src="https://cdn.jsdelivr.net/npm/gitalk@1/dist/gitalk.min.js"></script>
<script type="text/javascript">
var gitalk = new Gitalk({
clientID: "<%- config.gitalk.clientID %>",
clientSecret: "<%- config.gitalk.clientSecret %>",
repo: "<%- config.gitalk.repo %>",
owner: "<%- config.gitalk.owner %>",
admin: "<%- config.gitalk.admin %>",
clientID: "<%- theme.comments.gitalk.clientID %>",
clientSecret: "<%- theme.comments.gitalk.clientSecret %>",
repo: "<%- theme.comments.gitalk.repo %>",
owner: "<%- theme.comments.gitalk.owner %>",
admin: "<%- theme.comments.gitalk.admin %>",
<% if(page.gitalk && page.gitalk.id) { %>
id: "<%= page.gitalk.id %>",
<% } else { %>
@ -157,18 +158,18 @@
<% } %>
<% if (enableValine){ %>
<% if (config.use_cdn && theme.info && theme.info.cdn && theme.info.cdn.js && theme.info.cdn.js.valine) { %>
<%- js(theme.info.cdn.js.valine) %>
<% if (theme.comments.valine.js) { %>
<%- js(theme.comments.valine.js) %>
<% } else { %>
<%- js(['js/valine.js']) %>
<% } %>
<script>
var GUEST_INFO = ['nick','mail','link'];
var guest_info = '<%= theme.valine.guest_info %>'.split(',').filter(function(item){
var guest_info = '<%= theme.comments.valine.meta %>'.split(',').filter(function(item){
return GUEST_INFO.indexOf(item) > -1
});
var notify = '<%= theme.valine.notify %>' == true;
var verify = '<%= theme.valine.verify %>' == true;
var notify = '<%= theme.comments.valine.notify %>' == true;
var verify = '<%= theme.comments.valine.verify %>' == true;
var valine = new Valine();
valine.init({
el: '#valine_container',
@ -177,17 +178,17 @@
guest_info: guest_info,
<% if (page.valine && page.valine.path) { %>
path: "<%= page.valine.path %>",
<% } else if (config.leancloud.valine_path) { %>
path: "<%= config.leancloud.valine_path %>",
<% } else if (theme.comments.valine.path) { %>
path: "<%= theme.comments.valine.path %>",
<% } %>
appId: "<%= config.leancloud.app_id %>",
appKey: "<%= config.leancloud.app_key %>",
placeholder: "<%= (page.valine && page.valine.placeholder) ? page.valine.placeholder : theme.valine.placeholder %>",
pageSize:'<%= theme.valine.pageSize %>',
avatar:'<%= theme.valine.avatar %>',
lang:'<%= theme.valine.lang %>',
visitor: '<%- theme.valine.visitor %>',
highlight:'<%= theme.valine.highlight %>'
appId: "<%= theme.comments.valine.appId %>",
appKey: "<%= theme.comments.valine.appKey %>",
placeholder: "<%= (page.valine && page.valine.placeholder) ? page.valine.placeholder : theme.comments.valine.placeholder %>",
pageSize:'<%= theme.comments.valine.pageSize %>',
avatar:'<%= theme.comments.valine.avatar %>',
lang:'<%= theme.comments.valine.lang %>',
visitor: '<%- theme.comments.valine.visitor %>',
highlight:'<%= theme.comments.valine.highlight %>'
})
</script>
<% } %>

@ -1,7 +1,7 @@
<%
let aplayer = theme.footer.aplayer;
let aplayer = theme.plugins.aplayer;
%>
<% if (theme.footer.aplayer.enable == true) { %>
<% if (theme.plugins.aplayer.enable == true) { %>
<% if (post && post.music) { %>
<meting-js
mini='true'

@ -4,24 +4,24 @@
var enableLivere = false;
var enableGitalk = false;
var enableValine = false;
if (page && page.comments != false) {
if (config.disqus_shortname) {
if (theme.comments && page && page.comments == true) {
if (theme.comments.disqus && theme.comments.disqus.shortname) {
enableDisqus = true;
}
if (config.livere_uid) {
if (theme.comments.livere && theme.comments.livere.uid) {
enableLivere = true;
}
if (config.gitalk) {
if (theme.comments.gitalk && theme.comments.gitalk.clientID) {
enableGitalk = true;
}
if (theme.valine.enable && config.leancloud) {
if (theme.comments.valine && theme.comments.valine.appId) {
enableValine = true;
}
}
%>
<% if (enableDisqus || enableLivere || enableGitalk || enableValine) { %>
<article class="post white-box comments <%- theme.style.shadow.card ? 'card-shadow' : '' %> <%- theme.style.blur && theme.style.blur.body ? 'body-blur' : '' %>">
<article class="post white-box comments <%- theme.style.body.effect.join(' ') %>">
<section class="article typo">
<p ct><%- theme.comments && theme.comments.title %></p>
<% if (theme.comments && theme.comments.subtitle) { %>
@ -36,7 +36,7 @@
<% } %>
<% if (enableLivere){ %>
<section id="comments">
<div id="lv-container" data-id="city" data-uid="<%= config.livere_uid %>">
<div id="lv-container" data-id="city" data-uid="<%= theme.comments.livere.uid %>">
<noscript><div><i class='fas fa-exclamation-triangle'>&nbsp;<%- __('post.comments_placeholder', 'Livere') %></div></noscript>
</div>
</section>

@ -8,9 +8,9 @@ if (item.display) {
pf = ['desktop', 'mobile'];
}
if (where == 'sidebar') {
page.widget_style = (theme.style.shadow.card ? ' card-shadow' : '') + ((theme.style.blur && theme.style.blur.widget) ? ' widget-blur' : '');
page.widget_style = theme.style.sidebar.effect.join(' ');
} else if (where == 'body') {
page.widget_style = (theme.style.shadow.card ? ' card-shadow' : '') + ((theme.style.blur && theme.style.blur.card) ? ' widget-blur' : '');
page.widget_style = theme.style.body.effect.join(' ');
}
page.widget_platform = pf.join(' ');
%>

@ -1,5 +1,5 @@
<% if (theme.footer.aplayer.enable == true) { %>
<section class='widget <%- theme.style.shadow.card ? 'card-shadow' : '' %> <%- theme.style.blur && theme.style.blur.widget ? 'widget-blur' : '' %> <%- item.class %>'>
<% if (theme.plugins.aplayer.enable == true) { %>
<section class='widget <%- theme.style.sidebar.effect.join(' ') %> <%- item.class %>'>
<%- partial('header', {item: item}) %>
<div class='content'>
<%- partial('../_third-party/aplayer', {post: null, where: 'widget'}) %>

@ -3,7 +3,7 @@
<% if (page.year || page.month) { %>
<%- partial('_partial/archive') %>
<% } else { %>
<article id="archive-page" class="post article white-box <%- theme.style.shadow.card ? 'card-shadow' : '' %> <%- theme.style.blur && theme.style.blur.body ? 'widget-blur' : '' %>">
<article id="archive-page" class="post article white-box <%- theme.style.body.effect.join(' ') %>">
<section class="archive">
<%
var year = -1, postid = -1;
@ -25,7 +25,7 @@
<% } else if (post.date) { %>
<%= date(post.date, config.date_format) %>
<% } %>
<% if(post.music && post.music.enable != false){ %>
<% if(theme.plugins.aplayer && theme.plugins.aplayer.enable && post.music && post.music.enable != false){ %>
&nbsp;<i class="fas fa-headphones-alt music" aria-hidden="true"></i>
<% } %>
<% if (post.icon) { %>

@ -5,7 +5,7 @@
<% if (page.layout == 'category') { %>
<section class="post-list <%- theme.layout.multiple_columns ? 'multiple-columns' : '' %>">
<div class='post-wrapper'>
<article id="archive-page" class="post article white-box <%- theme.style.shadow.card ? 'card-shadow' : '' %> <%- theme.style.blur && theme.style.blur.body ? 'widget-blur' : '' %>">
<article id="archive-page" class="post article white-box <%- theme.style.body.effect.join(' ') %>">
<section class="archive">
<div class="archive-item archive-year mark">
<h2><%- page.title %></h2>

@ -1,6 +1,6 @@
<%- partial('_pre') %>
<div class='l_main<%- page.sidebar == false ? ' no_sidebar' : '' %>'>
<article id="<%= page.layout %>" class="post white-box <%- theme.style.shadow.card ? 'card-shadow' : '' %> <%- theme.style.blur && theme.style.blur.body ? 'body-blur' : '' %> article-type-<%= page.layout %>" itemscope itemprop="blogPost">
<article id="<%= page.layout %>" class="post white-box <%- theme.style.body.effect.join(' ') %> article-type-<%= page.layout %>" itemscope itemprop="blogPost">
<%- partial('_partial/meta',{post:page, position:'header'}) %>
<section class="article typo l_friends">
<%- page.excerpt %>

@ -5,7 +5,7 @@
<% if (page.layout == 'tag') { %>
<section class="post-list <%- theme.layout.multiple_columns ? 'multiple-columns' : '' %>">
<div class='post-wrapper'>
<article id="archive-page" class="post article white-box <%- theme.style.shadow.card ? 'card-shadow' : '' %> <%- theme.style.blur && theme.style.blur.body ? 'widget-blur' : '' %>">
<article id="archive-page" class="post article white-box <%- theme.style.body.effect.join(' ') %>">
<section class="archive">
<div class="archive-item archive-year mark">
<h2><%- page.title %></h2>

@ -15,17 +15,17 @@ $textshadow = 0 1px 2px 0px rgba(0, 0, 0, 0.1)
//
.nav-blur
.blur
background: alpha($color-card, .85) !important
backdrop-filter: blur(20px)
//
.body-blur,.widget-blur
.blur,.widget-blur
background: alpha($color-card, .85) !important
backdrop-filter: blur(20px)
//
.card-shadow
.shadow
trans()
box-shadow: $boxshadow-card
&:hover

@ -1,19 +1,28 @@
// inport font
@font-face
font-family: 'Varela Round'
src: url(https://cdn.jsdelivr.net/gh/xaoxuu/cdn-fonts/VarelaRound/VarelaRound-Regular.ttf)
font-weight: normal
font-style: normal
// body font
$fontfamily = 'Varela Round', "Microsoft YaHei", "Source Sans Pro", "Helvetica Neue", Menlo, Monaco, monospace, "Lucida Console", sans-serif, Helvetica, "Hiragino Sans GB", "Hiragino Sans GB W3", Source Han Sans CN Regular, WenQuanYi Micro Hei, Arial, sans-serif
// logo font
$fontfamily-logo = $fontfamily
$fontfamily = "Microsoft YaHei", "Source Sans Pro", "Helvetica Neue", Menlo, Monaco, monospace, "Lucida Console", sans-serif, Helvetica, "Hiragino Sans GB", "Hiragino Sans GB W3", Source Han Sans CN Regular, WenQuanYi Micro Hei, Arial, sans-serif
// inline code & codeblock font
$fontfamily-code = Menlo, Monaco, courier, monospace, "Lucida Console", 'Source Code Pro', "Microsoft YaHei", Helvetica, Arial, sans-serif, 'Ubuntu'
if hexo-config('style.fontfamily.bodyfont')
@font-face
font-family: hexo-config('style.fontfamily.bodyfont.name')
src: url(hexo-config('style.fontfamily.bodyfont.url'))
font-weight: hexo-config('style.fontfamily.bodyfont.weight')
font-style: hexo-config('style.fontfamily.bodyfont.style')
$fontfamily = hexo-config('style.fontfamily.bodyfont.name'), $fontfamily
if hexo-config('style.fontfamily.codefont')
@font-face
font-family: hexo-config('style.fontfamily.codefont.name')
src: url(hexo-config('style.fontfamily.codefont.url'))
font-weight: hexo-config('style.fontfamily.codefont.weight')
font-style: hexo-config('style.fontfamily.codefont.style')
$fontfamily-code = hexo-config('style.fontfamily.codefont.name'), $fontfamily-code
// logo font
$fontfamily-logo = $fontfamily
// font size
$fontsize = 16px
$fontsize-h1 = 1.625rem // 26px

@ -14,7 +14,7 @@ $layout-width = convert(hexo-config('style.max_width')) || 1080px
$sidebar-s = 240px
$sidebar = 285px
$modal-threshold = 680px
$navbar-height = convert(hexo-config('style.navbar_height')) || 64px
$navbar-height = convert(hexo-config('style.navbar.height')) || 64px
// gap
$gap = convert(hexo-config('style.gap')) || 16px
@ -30,10 +30,10 @@ $borderradius-codeblock = 4px
$borderradius-line = 2px
$borderradius-searchbar = 8px
$borderradius-button = 2px
// align
$textalign-h1 = convert(hexo-config('style.align.h1')) || left
$textalign-h2 = convert(hexo-config('style.align.h2')) || left
$textalign-h3 = convert(hexo-config('style.align.h3')) || left
$textalign-h4 = convert(hexo-config('style.align.h4')) || left
$textalign-p = convert(hexo-config('style.align.p')) || justify
// text align
$textalign-h1 = convert(hexo-config('style.body.text_align.h1')) || left
$textalign-h2 = convert(hexo-config('style.body.text_align.h2')) || left
$textalign-h3 = convert(hexo-config('style.body.text_align.h3')) || left
$textalign-h4 = convert(hexo-config('style.body.text_align.h4')) || left
$textalign-p = convert(hexo-config('style.body.text_align.p')) || justify

@ -67,7 +67,7 @@
font-size: $fontsize-footnote
padding: 4px 8px
if hexo-config('style.highlight.language') == true
if hexo-config('style.body.highlight.language') == true
&.html .code:before
content: "HTML"

@ -152,6 +152,7 @@
height: $height
border-radius: 100px
trans()
color: $color-theme
&:hover
background: bgcolor($color-theme)
@media screen and (max-width: $device-mobile)

@ -57,7 +57,7 @@
}
// 卡片阴影
.card-shadow {
.shadow {
.enable-trans();
box-shadow: @boxshadow_card_normal;
&:hover {

Loading…
Cancel
Save