Merge branch 'master' into docs

# Conflicts:
#	_config.yml
#	layout/_partial/head.ejs
i18n
xaoxuu 4 years ago
commit 2ad2d877f1
  1. 2
      .github/ISSUE_TEMPLATE/bug-report.md
  2. 2
      .github/ISSUE_TEMPLATE/question-report.md
  3. 22
      README.md
  4. 51
      _config.yml
  5. 2
      layout/_meta/tags.ejs
  6. 37
      layout/_partial/archive.ejs
  7. 2
      layout/_partial/head.ejs
  8. 2
      layout/_partial/header.ejs
  9. 20
      layout/_partial/post.ejs
  10. 125
      source/less/_article.less
  11. 9
      source/less/_color.less
  12. 2
      source/less/_header.less
  13. 21
      source/less/_main.less
  14. 13
      source/less/_normalize.less
  15. 2
      source/less/_side.less

@ -1,7 +1,7 @@
---
name: Bug Report
about: 确认存在并反馈一个BUG
title: "[BUG] "
title: ''
labels: BUG
assignees: ''

@ -1,7 +1,7 @@
---
name: Question Report
about: 主题使用遇到问题(通过阅读文档和查看示例博客源码仍无法解决)
title: "[求助]"
title: ''
labels: 疑问
assignees: ''

@ -1,4 +1,4 @@
# Material X
# Volantis
A minimalist card-style Hexo blog theme.
@ -16,7 +16,7 @@ A minimalist card-style Hexo blog theme.
#### Easy to extend
- Use the [import](https://xaoxuu.com/wiki/material-x/config/#import) field to easily import css and js into the theme.
- Use the [import](https://xaoxuu.com/wiki/volantis/config/#import) field to easily import css and js into the theme.
#### Mobile optimization
@ -24,7 +24,7 @@ A minimalist card-style Hexo blog theme.
#### Support for more features
- Supports 4 comment systems: Disqus, Gitalk, La BiLi and Valin comments.
- Support 4 comment systems: Disqus, Gitalk, LiveRe and Valine.
- Provide themed CDN, or customize CDN.
- Use card design elements and interactive animations.
- Use fontawesome 5.6.3 free icon.
@ -44,7 +44,7 @@ A minimalist card-style Hexo blog theme.
| [@xaoxuu](https://xaoxuu.com) | Not open source yet | myblog branch effect |
- **For more examples, please see [#Example Blog](https://github.com/xaoxuu/hexo-theme-material-x/issues/97)**
- **For more examples, please see [#Example Blog](https://github.com/xaoxuu/hexo-theme-volantis/issues/97)**
@ -70,7 +70,7 @@ hexo.sh i x
1. Download theme to `themes /` folder
```bash
git clone https://github.com/xaoxuu/hexo-theme-material-x themes / material-x
git clone https://github.com/xaoxuu/hexo-theme-volantis themes/volantis
```
2. Then install the necessary dependencies
@ -84,14 +84,14 @@ npm i -S hexo-generator-search hexo-generator-json-content hexo-renderer-less
## Documentation
https://xaoxuu.com/wiki/material-x/
https://xaoxuu.com/wiki/volantis/
<br>
<br>
<br>
# Material X
# Volantis
一个简约的卡片式Hexo博客主题。
@ -109,7 +109,7 @@ https://xaoxuu.com/wiki/material-x/
#### 易于扩展
- 使用 [import](https://xaoxuu.com/wiki/material-x/config/#import) 字段方便导入css和js到主题中。
- 使用 [import](https://xaoxuu.com/wiki/volantis/config/#import) 字段方便导入css和js到主题中。
#### 移动端优化
@ -137,7 +137,7 @@ https://xaoxuu.com/wiki/material-x/
| [@xaoxuu](https://xaoxuu.com) | 暂未开源 | myblog分支效果 |
- **更多示例请见 [#示例博客](https://github.com/xaoxuu/hexo-theme-material-x/issues/97)**
- **更多示例请见 [#示例博客](https://github.com/xaoxuu/hexo-theme-volantis/issues/97)**
@ -163,7 +163,7 @@ hexo.sh i x
1. 下载主题到 `themes/` 文件夹
```bash
git clone https://github.com/xaoxuu/hexo-theme-material-x themes/material-x
git clone https://github.com/xaoxuu/hexo-theme-volantis themes/volantis
```
2. 然后安装必要的依赖包
@ -177,4 +177,4 @@ npm i -S hexo-generator-search hexo-generator-json-content hexo-renderer-less
## 文档
https://xaoxuu.com/wiki/material-x/
https://xaoxuu.com/wiki/volantis/

@ -1,17 +1,17 @@
############################### 主题基本信息 ###############################
info:
name: Volantis
version: 1.5
docs: https://xaoxuu.com/wiki/material-x/
version: 1.5.2
docs: https://xaoxuu.com/wiki/volantis/
cdn: # 要使用CDN,请在根目录的config文件中写上 use_cdn: true
css:
style: https://cdn.jsdelivr.net/gh/xaoxuu/cdn-material-x@20.2.22/css/style.css
style: https://cdn.jsdelivr.net/gh/xaoxuu/cdn-volantis@20.2.25/css/style.css
js:
app: https://cdn.jsdelivr.net/gh/xaoxuu/cdn-material-x@20.2/js/app.js
search: https://cdn.jsdelivr.net/gh/xaoxuu/cdn-material-x@20.2/js/search.js
app: https://cdn.jsdelivr.net/gh/xaoxuu/cdn-volantis@20.2.22/js/app.js
search: https://cdn.jsdelivr.net/gh/xaoxuu/cdn-volantis@20.2.22/js/search.js
volantis: https://cdn.jsdelivr.net/gh/xaoxuu/volantis@1.0.6/js/volantis.min.js
backstretch: https://cdn.jsdelivr.net/gh/xaoxuu/cdn-material-x@20.2/js/backstretch.min.js
commentTyping: https://cdn.jsdelivr.net/gh/xaoxuu/cdn-material-x@20.2/js/commentTyping.js
backstretch: https://cdn.jsdelivr.net/gh/xaoxuu/cdn-volantis@20.2.22/js/backstretch.min.js
commentTyping: https://cdn.jsdelivr.net/gh/xaoxuu/cdn-volantis@20.2.22/js/commentTyping.js
############################### 服务开关 ###############################
@ -41,6 +41,8 @@ style:
# 有背景图:开启毛玻璃,关闭卡片阴影
# 无背景图:关闭毛玻璃,开启卡片阴影
# readmore: true
# 幻灯片背景
backstretch:
position: background # cover: 封面背景 background: 整个网页背景
@ -121,13 +123,30 @@ navbar:
target: _self
# 手机端导航菜单(从右上角的按钮点击展开)
on_mobile:
- name: 近期文章
icon: fas fa-clock
url: /
- name: 关于小站
icon: fas fa-info-circle
url: about/
- name: 开始使用
icon: fas fa-download
url: start
rel: nofollow
target: _self
- name: 站点配置
icon: fas fa-cogs
url: site-settings
target: _self
- name: 主题配置
icon: fas fa-palette
url: theme-settings
rel: nofollow
target: _self
- name: 页面配置
icon: fas fa-file-alt
url: page-settings
rel: nofollow
target: _self
- name: 进阶设定
icon: fas fa-flask
url: advanced-settings
rel: nofollow
target: _self
search: 搜索文档 # 搜索框文字
@ -309,9 +328,9 @@ widget:
# fancybox: true # 是否允许点击放大
images:
- https://img.vim-cn.com/4e/3c87a2fd28fd0b9c2f27ce3f83f1e9275d0488.png
# - https://img.vim-cn.com/4e/3c87a2fd28fd0b9c2f27ce3f83f1e9275d0488.png
# - https://img.vim-cn.com/4e/3c87a2fd28fd0b9c2f27ce3f83f1e9275d0488.png
# - https://img.vim-cn.com/4e/3c87a2fd28fd0b9c2f27ce3f83f1e9275d0488.png
- https://img.vim-cn.com/4e/3c87a2fd28fd0b9c2f27ce3f83f1e9275d0488.png
- https://img.vim-cn.com/4e/3c87a2fd28fd0b9c2f27ce3f83f1e9275d0488.png
- https://img.vim-cn.com/4e/3c87a2fd28fd0b9c2f27ce3f83f1e9275d0488.png
# ---------------------------------------
# 自定义组件,仿照如下写法
- id: huan_ying # 唯一标识,自己命名,建议全英文

@ -1,4 +1,4 @@
<% if (!isPostList && post.tags && post.tags.length) { %>
<% if (post.tags && post.tags.length) { %>
<%
var items = [];
post.tags.each(function(item){

@ -35,27 +35,24 @@
<% if (page.total > 1) { %>
<br>
<div class="prev-next">
<div class="prev-next">
<% if (page.prev != 0) { %>
<a class="prev" rel="prev" href="<%= url_for(page.prev_link) %>">
<section class="post prev" >
<i class="fas fa-chevron-left" aria-hidden="true"></i>&nbsp;<%- __('post.prev_page') %>&nbsp;
</section>
</a>
<% } %>
<p class="current">
<%= page.current%> / <%= page.total%>
</p>
<% if (page.next != 0) { %>
<a class="next" rel="next" href="<%= url_for(page.next_link) %>">
<section class="post next">
&nbsp;<%- __('post.next_page') %>&nbsp;<i class="fas fa-chevron-right" aria-hidden="true"></i>
</section>
</a>
<% } %>
</div>
<% 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' : '' %>" >
<i class="fas fa-chevron-left" aria-hidden="true"></i>&nbsp;<%- __('post.prev_page') %>&nbsp;
</section>
</a>
<% } %>
<p class="current">
<%= page.current%> / <%= page.total%>
</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' : '' %>">
&nbsp;<%- __('post.next_page') %>&nbsp;<i class="fas fa-chevron-right" aria-hidden="true"></i>
</section>
</a>
<% } %>
</div>
<% } %>
<!-- 根据主题中的设置决定是否在archive中针对摘要部分的MathJax公式加载mathjax.js文件 -->
<%

@ -1,4 +1,4 @@
<head hexo-theme='Volantis' version='<%- theme.info.version %>' docs='https://xaoxuu.com/wiki/material-x/'>
<head hexo-theme='Volantis' version='<%- theme.info.version %>' docs='https://xaoxuu.com/wiki/volantis/'>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<%

@ -64,7 +64,7 @@
</div>
</div>
</header>
<aside class="menu-phone white-box <%- theme.style.shadow.card ? 'card-shadow' : '' %> <%- theme.style.blur && theme.style.blur.widget ? 'widget-blur' : '' %>">
<aside class="menu-phone white-box">
<header>
<nav class="menu navgation">
<ul>

@ -4,20 +4,24 @@
<div class="article-entry" itemprop="articleBody">
<%- post.excerpt || post.description || post.content %>
<% if ((post.readmore != false) && (post.excerpt || post.description || post.link)) { %>
<div class="button readmore">
<a href="<%- url_for(post.link || post.path) %>" class="flat-box">
<i class="fas fa-book-open fa-fw" aria-hidden="true"></i>
<%- __('post.read_more') %>
</a>
</div>
<% if (theme.readmore) { %>
<div class="button readmore">
<a href="<%- url_for(post.link || post.path) %>" class="flat-box">
<i class="fas fa-book-open fa-fw" aria-hidden="true"></i>
<%- __('post.read_more') %>
</a>
</div>
<% } else { %>
<% } %>
<% } %>
</div>
<% if (post.tags && post.tags.length) { %>
<!-- <% if (post.tags && post.tags.length) { %>
<div class="full-width auto-padding tags">
<% post.tags.each(function(item){ %>
<a href="<%- url_for(item.path) %>" rel="nofollow"><i class="fas fa-tag fa-fw"></i> <%=item.name %></a>
<%})%>
</div>
<% } %>
<% } %> -->
</section>
</article>

@ -43,7 +43,7 @@
margin-bottom: .6em;
// text-align: justify;
strong{
color: @color_text_main;
// color: @color_text_main;
// padding-left: 2px;
// padding-right: 2px;
}
@ -57,7 +57,7 @@
overflow: auto;
.mjx-math{
font-family: @fontfamily_code;
background: fade(@theme_background, 50%);
background: @color_bg_mathjax;
padding: @gap/2;
border-radius: @border_radius_code_block;
}
@ -321,7 +321,7 @@
font-size: @fontsize_small;
line-height: @lineheight_base;
margin-top: @gap;
background: darken(fade(@theme_background, 50%), 5%);
background: fade(darken(@theme_cardbg, 5%), 50%);
&.article-tags {
// padding-top: 2*@gap;
// background: transparent;
@ -381,7 +381,7 @@
width: 100%;
padding: @gap/2;
color: fade(@color_text_main, 70%);
background-color: fade(@theme_background, 50%);
background-color: fade(darken(@theme_cardbg, 5%), 50%);
border-radius: @border_radius;
p{
font-size: @fontsize_base;
@ -438,6 +438,63 @@
}
}
p btn {
a {
background: @color_text_link;
color: @color_text_in_header;
padding: 2px 5px 0px 5px;
margin: 2px;
border-radius: 2px;
.enable-trans();
&:hover {
color: @color_text_in_header;
text-decoration: none;
background: @color_text_highlight;
}
}
&.small {
font-size: @fontsize_base * .9;
a {
padding: 2px 3px 0px 3px;
}
}
}
.large, .huge {
margin: 0;
}
.large {
font-size: 4em;
}
.huge {
font-size: 6em;
}
.bold {
font-weight: bold;
}
.left {
text-align: left;
}
.right {
text-align: right;
}
red, .red {
color: @color_mac_close;
}
green, .green {
color: @color_mac_maximize;
}
yellow, .yellow {
color: @color_mac_minimize;
}
blue, .blue {
color: @color_md_blue;
}
cyan, .cyan {
color: @color_mac_finder;
}
gray, .gray {
color: #AAA;
}
}
@ -453,53 +510,55 @@
font-family:@fontfamily_code;
line-height: @lineheight_base;
border-radius: @border_radius_code_block;
border: 1px solid @color_border_code_block;
border: 1px solid darken(@theme_cardbg, 10%);
.enable-trans();
figcaption{
padding: @gap/4 @gap/2;
background-color: darken(@color_bg_code_block, 3%);
}
table{
table {
td,th{
padding: 0;
border: none;
}
margin: 0;
background-color: transparent;
border: none;
tr{
background-color: transparent;
&:hover{
background-color: transparent;
}
}
}
.gutter{
width: 24px;
padding: 0 12px;
text-align: right;
border-width: 0;
margin-left: 0;
background-color: darken(@color_bg_code_block, 3%);
pre{
color: fade(@color_text_main, 80%);
}
&:hover{
}
}
.code{
padding: @gap;
vertical-align: top;
border: 0px solid darken(@theme_background, 2%);
&:before{
content: "";
position: absolute;
top: 0;
right: 0;
.gutter{
width: 24px;
padding: 0 12px;
text-align: right;
border-width: 0;
margin-left: 0;
background-color: darken(@color_bg_code_block, 3%);
pre{
color: fade(@color_text_main, 80%);
font-size: @fontsize_footnote;
padding: 4px 8px 0;
line-height: @lineheight_base;
}
}
.code{
padding: @gap;
vertical-align: top;
background-color: transparent;
&:before{
content: "";
position: absolute;
top: 0;
right: 0;
color: fade(@color_text_main, 80%);
font-size: @fontsize_footnote;
padding: 4px 8px 0;
line-height: @lineheight_base;
}
}
}
&.html .code:before{
content: "HTML";
}

@ -19,8 +19,9 @@
// 代码的背景色
@color_bg_code: #FFF8F0;
// 代码块的背景色
@color_bg_code_block: darken(@theme_cardbg, 2%);
@color_border_code_block: #ddd;
@color_bg_code_block: fade(darken(@theme_cardbg, 5%), 50%);
// 公式背景颜色
@color_bg_mathjax: #FFF0;
// 引用的颜色
@color_bg_quote: @theme_main;
// 选中部分文字的背景颜色
@ -51,8 +52,8 @@
// 卡片毛玻璃效果
.body-blur,.widget-blur {
background: fade(@theme_cardbg, 75%);
backdrop-filter: blur(50px);
background: fade(@theme_cardbg, 80%);
backdrop-filter: blur(20px);
}
// 卡片阴影

@ -206,7 +206,7 @@
padding-bottom: 8px;
width: 100%;
color: @color_text_main;
background: @theme_background;
background: fade(darken(@theme_cardbg, 5%), 75%);
box-shadow: none;
box-sizing: border-box;
padding-left: @iconW + @iconMargin;

@ -588,7 +588,7 @@
transform: translate(-50%,-50%);
z-index: 99999;
text-align: center;
padding: 24px 36px;
padding: 24px 36px 22px 36px;
border-radius: @border_radius_code_block;
box-shadow: @boxshadow_card_normal;
font-family: @fontfamily_base;
@ -616,3 +616,22 @@
}
}
details {
display: block;
background: @color_bg_code_block;
padding: @gap;
border: 1px solid darken(@theme_cardbg, 10%);
border-radius: @border_radius_code_block;
.enable-trans();
summary {
cursor: pointer;
padding: @gap;
margin: -@gap;
color: fade(@color_text_main, 60%);;
font-weight: bold;
&:hover {
color: @color_text_highlight;
}
}
}

@ -422,20 +422,23 @@ optgroup {
table {
border-collapse: collapse;
width: 100%;
background-color: @theme_cardbg;
border: 2px solid darken(@theme_cardbg, 10%);
margin-top: .7em;
margin-bottom: .7em;
th {
background-color: darken(@theme_cardbg, 5%);
background-color: fade(darken(@theme_cardbg, 12%), 50%);
}
td,
th {
text-align: justify;
padding: 4px 8px;
border: 1px solid @theme_background;
border: 1px solid darken(@theme_cardbg, 10%);
}
tr {
// border-bottom: 2px solid #eee;
background-color: fade(darken(@theme_cardbg, 2%), 50%);
}
tbody>tr {
.enable-trans();
background-color: @theme_cardbg;
&:hover{
background-color: darken(@theme_cardbg, 5%);
}

@ -322,6 +322,8 @@
flex-wrap: wrap;
align-items: center;
justify-content: space-around;
padding-left: @gap/2;
padding-right: @gap/2;
img{
margin-bottom: 4px;
}

Loading…
Cancel
Save