hexo-theme-volantis 5.0.0-rc.8 → 5.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (64) hide show
  1. package/CHANGELOG.md +29 -0
  2. package/README.md +5 -4
  3. package/_config.yml +73 -60
  4. package/layout/_meta/counter.ejs +27 -5
  5. package/layout/_meta/walinecount.ejs +2 -1
  6. package/layout/_partial/article.ejs +2 -2
  7. package/layout/_partial/head.ejs +29 -28
  8. package/layout/_partial/header.ejs +1 -1
  9. package/layout/_partial/scripts/content-visibility-scroll-fix.ejs +71 -69
  10. package/layout/_partial/scripts/global.ejs +47 -23
  11. package/layout/_partial/scripts/index.ejs +22 -9
  12. package/layout/_partial/scripts/toc.ejs +61 -38
  13. package/layout/_plugins/_page_plugins/indent/index.ejs +1 -1
  14. package/layout/_plugins/_page_plugins/index.ejs +27 -7
  15. package/layout/_plugins/_page_plugins/snackbar/index.ejs +1 -1
  16. package/layout/_plugins/analytics/script.ejs +11 -1
  17. package/layout/_plugins/aplayer/script.ejs +1 -1
  18. package/layout/_plugins/comments/artalk/script.ejs +17 -11
  19. package/layout/_plugins/comments/beaudar/script.ejs +2 -2
  20. package/layout/_plugins/comments/discuss/script.ejs +30 -0
  21. package/layout/_plugins/comments/hashover/script.ejs +2 -2
  22. package/layout/_plugins/comments/index.ejs +4 -4
  23. package/layout/_plugins/comments/twikoo/script.ejs +1 -1
  24. package/layout/_plugins/comments/waline/script.ejs +40 -22
  25. package/layout/_plugins/parallax/script.ejs +1 -1
  26. package/layout/_plugins/pjax/index.ejs +4 -1
  27. package/layout/_plugins/rightmenu/layout.ejs +2 -2
  28. package/layout/_plugins/rightmenus/layout.ejs +17 -17
  29. package/layout/_widget/lastupdate.ejs +27 -27
  30. package/layout/_widget/webinfo.ejs +7 -7
  31. package/layout/layout.ejs +20 -3
  32. package/layout/tag.ejs +1 -1
  33. package/package.json +1 -1
  34. package/scripts/events/index.js +1 -0
  35. package/scripts/events/lib/check-configuration.js +43 -0
  36. package/scripts/events/lib/check-environment.js +74 -0
  37. package/scripts/events/lib/config.js +3 -0
  38. package/scripts/events/lib/render-stylus.js +1 -1
  39. package/scripts/filters/content-visibility.js +2 -2
  40. package/scripts/helpers/custom-files.js +3 -1
  41. package/scripts/helpers/head/generate_seo.js +1 -1
  42. package/scripts/helpers/structured-data/lib/blogposting.js +18 -6
  43. package/scripts/helpers/structured-data/lib/breadcrumblist.js +25 -1
  44. package/scripts/helpers/structured-data/lib/index.js +1 -9
  45. package/scripts/tags/fancybox.js +1 -1
  46. package/scripts/tags/note.js +24 -1
  47. package/scripts/tags/tabs.js +85 -86
  48. package/source/css/_defines/AutoPrefixCSS.styl +16 -16
  49. package/source/css/_first/base_first.styl +6 -0
  50. package/source/css/_first/navbar_first.styl +1 -1
  51. package/source/css/_style/_base/base.styl +1 -1
  52. package/source/css/_style/_layout/toc.styl +2 -2
  53. package/source/css/_style/_plugins/_dark/dark_async.styl +1 -1
  54. package/source/css/_style/_plugins/_dark/dark_plugins.styl +8 -4
  55. package/source/css/_style/_plugins/_rightmenu/reading.styl +2 -2
  56. package/source/css/_style/_plugins/_rightmenu/rightmenu.styl +1 -1
  57. package/source/css/_style/_plugins/fontcolor.styl +1 -1
  58. package/source/css/first.styl +5 -7
  59. package/source/js/app.js +32 -35
  60. package/source/js/plugins/aplayer.js +1 -3
  61. package/source/js/plugins/rightMenu.js +22 -22
  62. package/source/js/plugins/rightMenus.js +115 -78
  63. package/source/js/search/hexo.js +3 -0
  64. package/layout/_partial/scripts/import.ejs +0 -3
package/CHANGELOG.md ADDED
@@ -0,0 +1,29 @@
1
+ # Changelog
2
+
3
+ ### [5.1.1](https://github.com/volantis-x/hexo-theme-volantis/compare/v5.1.0...v5.1.1) (2022-05-19)
4
+
5
+
6
+ ### Bug Fixes
7
+
8
+ * **#761:** overflow ([74e0d04](https://github.com/volantis-x/hexo-theme-volantis/commit/74e0d04a47d17c513f0d29ecaceb49b51d63ee18))
9
+
10
+ ## [5.1.0](https://github.com/volantis-x/hexo-theme-volantis/compare/5.0.0...v5.1.0) (2022-05-19)
11
+
12
+
13
+ ### Features
14
+
15
+ * release-please ([97efd35](https://github.com/volantis-x/hexo-theme-volantis/commit/97efd352d3f44d7f12a813db89c07ab0ba56e188))
16
+
17
+
18
+ ### Bug Fixes
19
+
20
+ * 703 ([034d684](https://github.com/volantis-x/hexo-theme-volantis/commit/034d6847050472d7fe89335d65f371112c7449e8))
21
+ * 706 移动端菜单栏异常 ([e1f63b3](https://github.com/volantis-x/hexo-theme-volantis/commit/e1f63b33d47a992c278eb51471e5e2816ebc138f))
22
+ * 713 ([e1233de](https://github.com/volantis-x/hexo-theme-volantis/commit/e1233de457648ea46597a5ec4875efc5011e58b5))
23
+ * 740 ([a845788](https://github.com/volantis-x/hexo-theme-volantis/commit/a845788c9dbc1c251e93ca6e8b557d6e1bfb849e))
24
+ * Discuss 评论系统适配深色模式 ([#752](https://github.com/volantis-x/hexo-theme-volantis/issues/752)) ([86002b6](https://github.com/volantis-x/hexo-theme-volantis/commit/86002b67af0060e21e9ac2514aeee64377e01e69))
25
+ * error friendly ([3bffeab](https://github.com/volantis-x/hexo-theme-volantis/commit/3bffeabc2399cd3dda5816c13b1b56be25d7f95f))
26
+ * no-title ([48c70f8](https://github.com/volantis-x/hexo-theme-volantis/commit/48c70f8c13dd4d6dc7fa1bb5226c5987fde7971f))
27
+ * **twikoo:** 所有页面都说同一个path的bug ([14de40b](https://github.com/volantis-x/hexo-theme-volantis/commit/14de40bbe12e1e1679a60a58e0d501625d0e7ff2))
28
+ * 为 Discuss 添加最低高度 ([#742](https://github.com/volantis-x/hexo-theme-volantis/issues/742)) ([9bf70de](https://github.com/volantis-x/hexo-theme-volantis/commit/9bf70debfb8a38da89a7bf5f7bd7634d504aa457))
29
+ * 修复Discuss评论区表情包在深色模式下,css权重低的bug ([#753](https://github.com/volantis-x/hexo-theme-volantis/issues/753)) ([872baf7](https://github.com/volantis-x/hexo-theme-volantis/commit/872baf7481b1bb6e47381638c5c346fb232a398a))
package/README.md CHANGED
@@ -3,16 +3,17 @@
3
3
  </p>
4
4
 
5
5
  [![](https://img.shields.io/npm/v/hexo-theme-volantis.svg?style=flat-square)](https://www.npmjs.com/package/hexo-theme-volantis)
6
+ [![Conventional Commits](https://img.shields.io/badge/Conventional%20Commits-1.0.0-%23FE5196?logo=conventionalcommits&logoColor=white)](https://www.conventionalcommits.org/zh-hans/v1.0.0/)
6
7
 
7
8
  ## Getting Started
8
9
 
9
10
  Check your environment:
10
11
 
11
12
  ```yaml
12
- Hexo: 4.2 ~ 5.x
13
- hexo-cli: 3.1 ~ 4.x
14
- node.js: 12.16 LTS ~ latest LTS
15
- npm: 6.13 ~ latest LTS
13
+ Hexo: 5.4 ~ 6.x
14
+ hexo-cli: 4.3 ~ latest
15
+ node.js: 16.x LTS ~ latest LTS
16
+ npm: 8.x ~ latest LTS
16
17
  ```
17
18
 
18
19
  Edit your `_config.yml`:
package/_config.yml CHANGED
@@ -1,7 +1,6 @@
1
1
  ############################### Volantis ###############################
2
2
  info:
3
3
  theme_name: Volantis # This is theme's name.
4
- theme_version: '5.0.0-rc.8' # This is theme's version.
5
4
  theme_docs: https://volantis.js.org/ # This is theme's URL.
6
5
  theme_repo: https://github.com/volantis-x/hexo-theme-volantis
7
6
  # Debug 调试模式
@@ -13,9 +12,10 @@ default:
13
12
  cover: volantis-static/media/placeholder/cover/76b86c0226ffd.svg # https://cdn.jsdelivr.net/gh/cdn-x/placeholder@1.0.1/cover/76b86c0226ffd.svg
14
13
  image: volantis-static/media/placeholder/image/2659360.svg # https://cdn.jsdelivr.net/gh/cdn-x/placeholder@1.0.1/image/2659360.svg
15
14
  ############################### CSP ###############################
16
- # 内容安全策略( CSP )
15
+ # 内容安全策略( CSP ) meta 标签 http-equiv="Content-Security-Policy"
17
16
  # https://developer.mozilla.org/zh-CN/docs/Web/HTTP/CSP
18
17
  # https://content-security-policy.com/
18
+ # 也可以设为 false 在 HTTP 标头中设置 https://volantis.js.org/v5/advanced-settings/#设置-HTTP-响应标头
19
19
  csp:
20
20
  enable: true
21
21
  content: "
@@ -53,7 +53,9 @@ cdn:
53
53
  app: /js/app.js
54
54
  css:
55
55
  style: /css/style.css # (异步加载样式)
56
- # 请求静态资源添加版本号 本地文件使用文件内容的hash值作为版本号(app.8c1e7c88.js) 其他为时间戳 (?time=1648684470140)
56
+ # 静态资源版本控制
57
+ # 本地文件使用文件内容的hash值作为版本号(app.8c1e7c88.js) 其他为时间戳 (?time=1648684470140)
58
+ # 建议静态资源设置标头 浏览器缓存一年边缘缓存一个月 cache-control: max-age=86400, s-maxage=31536000 如果有更新记得刷新缓存
57
59
  cdn_version: true
58
60
  # volantis static 静态资源文件 npm 包 CDN 地址 (后面加 "/" )
59
61
  # https://github.com/volantis-x/volantis-static
@@ -62,12 +64,13 @@ volantis_static_cdn: https://unpkg.com/volantis-static@0.0.1649552113628/
62
64
  # 全局页面字符串替换 A => B (可用于临时修改错字等)
63
65
  replace:
64
66
  - https://cdn.jsdelivr.net/npm/ => https://unpkg.com/
65
- - https://unpkg.com/ => https://npm.elemecdn.com/
67
+ - https://cdn.jsdelivr.net/gh/ => https://fastly.jsdelivr.net/gh/
68
+ # - https://unpkg.com/ => https://npm.elemecdn.com/
66
69
 
67
70
  # dns-prefetch preconnect x-dns-prefetch-control
68
71
  dns_prefetch:
69
- # - https://unpkg.com
70
- - https://npm.elemecdn.com
72
+ - https://unpkg.com
73
+ # - https://npm.elemecdn.com
71
74
 
72
75
  # 平滑滚动效果
73
76
  scroll_smooth: true
@@ -276,20 +279,15 @@ comments:
276
279
  # https://artalk.js.org/
277
280
  # https://github.com/ArtalkJS/Artalk
278
281
  artalk:
279
- js: https://unpkg.com/artalk@2.1.3/dist/Artalk.js
280
- css: https://unpkg.com/artalk@2.1.3/dist/Artalk.css
281
- server: http://127.0.0.1:8080/api # 修改为自建的后端服务地址
282
+ js: https://yours-artalk-domain/dist/Artalk.js # or https://unpkg.com/artalk@2.2.8/dist/Artalk.js
283
+ css: https://yours-artalk-domain/dist/Artalk.css # or https://unpkg.com/artalk@2.2.8/dist/Artalk.css
284
+ server: https://yours-artalk-domain # 修改为自建的后端服务地址
282
285
  path: # 全局评论地址
283
- # 更多选项 https://artalk.js.org/guide/frontend/config.htm 按照yml格式继续填写即可
284
- # 除了 [el pageKey pageTitle site] 选项
285
- # 下面是一些例子:
286
- placeholder: 来啊,快活啊 ( ゜- ゜) # 全局评论占位
287
- noComment: 快来成为第一个评论的人吧~ # 评论为空时,评论列表显示字符
288
- pagination:
289
- readMore: true # 加载更多模式
290
- autoLoad: false # 滚动到底部自动加载
291
- pageSize: 10 # 每次请求获取数量
292
-
286
+ placeholder: # 评论占位
287
+ # 更多置项可在 Artalk 后端进行配置,详见 https://artalk.js.org/guide/backend/fe-control.html
288
+ # 也可以在此处继续参考上方例子进行配置,不建议重写配置的字段除上方所述外还有:
289
+ # [el, useBackendConf, pageKey, pageTitle, site, darkMode, pvEl]
290
+
293
291
  # giscus
294
292
  # https://giscus.app
295
293
  # https://github.com/laymonage/giscus
@@ -407,19 +405,31 @@ comments:
407
405
  # Waline
408
406
  # https://waline.js.org/
409
407
  waline:
410
- js: https://npm.elemecdn.com/@waline/client@1.6.0/dist/Waline.min.js
408
+ js: https://unpkg.com/@waline/client@v2/dist/waline.js
409
+ css: https://unpkg.com/@waline/client@v2/dist/waline.css
411
410
  path: # 全局评论地址 目前设置全局评论地址后visitor失效,这是waline的问题
412
- placeholder: 快来评论吧~ # 评论占位提示
413
- # imageHosting: https://7bu.top/api/upload?token=7ffe9d626fe4315c953758efbdb6ee2e # 图床api(默认注释使用base64)
414
- # 其他配置项按照yml格式继续填写即可 除了 [el path placeholder uploadImage] 选项
415
- meta: [nick,mail,link] # waline comment header info
416
- requiredFields: [nick,mail]
417
- serverURL: xxxxxxxxxxxxxxx # Waline 的服务端地址(必填) 测试用地址: https://waline-ruddy.vercel.app
418
- avatar: robohash # gravatar style https://waline.js.org/client/basic.html#avatar
419
- avatarCDN: #https://sdn.geekzu.org/avatar/
420
- pageSize: 10 # 评论每页显示数量
421
- lang: zh-CN
422
- visitor: true
411
+ placeholder: # 评论占位提示
412
+ serverURL: # Waline 的服务端地址(必填) 测试用地址: https://waline.vercel.app
413
+ imageUploader:
414
+ # 以兰空图床为例,下列填写内容为:
415
+ # url: https://xxxxxx/api/v1/upload
416
+ # token: Bearer xxxxxxxxxxxxxx
417
+ # resp: data.links.url
418
+ api: # 图床地址
419
+ token: # 图床验证
420
+ resp: # 图片地址返回值的字段
421
+ pageview: true # 浏览量统计
422
+ comment: true # 评论数统计
423
+ # 其他配置项按照yml格式继续填写即可 除了 [el path imageUploader] 选项
424
+ # 组件属性地址:https://waline.js.org/reference/component.html
425
+ # meta: ['nick', 'mail', 'link']
426
+
427
+ # Discuss
428
+ # https://discuss.js.org
429
+ discuss:
430
+ js: https://cdn.jsdelivr.net/npm/discuss/dist/Discuss.js # 建议锁定版本
431
+ serverURLs: # Discuss server address url
432
+ # https://discuss.js.org/Quick-Start.html#path
423
433
 
424
434
 
425
435
  ############################### Comments ############################### > end
@@ -525,7 +535,6 @@ sidebar:
525
535
  text: '本站总字数:' # 需要启用 wordcount
526
536
  unit: '字'
527
537
  visitcounter:
528
- service: leancloud # busuanzi, leancloud
529
538
  siteuv:
530
539
  enable: true
531
540
  text: '本站访客数:'
@@ -675,7 +684,7 @@ plugins:
675
684
 
676
685
  # https://scrollrevealjs.org/api/reveal.html
677
686
  scrollreveal:
678
- enable: #true
687
+ enable: true
679
688
  js: volantis-static/libs/scrollreveal/dist/scrollreveal.min.js # https://unpkg.com/scrollreveal@4.0.9/dist/scrollreveal.min.js
680
689
  distance: 32px
681
690
  duration: 800 # ms
@@ -862,9 +871,9 @@ plugins:
862
871
  enable: true
863
872
  play: fa-solid fa-play
864
873
  pause: fa-solid fa-pause
865
- rightmenu:
874
+ rightmenu:
866
875
  enable: true # 是否开启右键模块的消息通知
867
- notice: true # 唤醒原右键菜单的通知
876
+ notice: true # 唤醒原右键菜单的通知
868
877
 
869
878
  # 聊天功能
870
879
  chat_service: # tidio or gitter
@@ -878,7 +887,7 @@ plugins:
878
887
  # https://gitter.im
879
888
  gitter:
880
889
  room: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
881
-
890
+
882
891
  # swiper
883
892
  # https://www.swiper.com.cn/
884
893
  swiper:
@@ -895,12 +904,13 @@ rightmenus:
895
904
  enable: true
896
905
  # 右键菜单项及加载顺序
897
906
  # 内容示例:plugins.[组名], menus.[组名], hr(分割线,推荐去线留白), music(音乐控制器)
898
- order:
907
+ order:
899
908
  - plugins.navigation
900
909
  - hr
901
910
  - plugins.inputBox
902
911
  - plugins.seletctText
903
912
  - plugins.elementCheck
913
+ - plugins.elementImage
904
914
  - menus.link
905
915
  - hr
906
916
  - menus.darkMode
@@ -917,7 +927,7 @@ rightmenus:
917
927
  # 注:
918
928
  # 1. link/event 二选一,同时出现时仅处理 link
919
929
  # 2. 内置事件列表: copyText, copyLink, copyPaste, copyAll, copyCut, copyImg, printMode, readMode
920
- # 3. 内置组列表:navigation, inputBox, seletctText, elementCheck, articlePage
930
+ # 3. 内置组列表:navigation, inputBox, seletctText, elementCheck, elementImage, articlePage
921
931
  # 4. plugins 列允许自定义组内项目
922
932
  # 5. menus 列允许自定义组及其内容
923
933
  # 6. 除 navigation 外的内置组,在显示时会隐藏含 link 属性的菜单项
@@ -929,12 +939,12 @@ rightmenus:
929
939
  # 例外,在 articlePage 组显示时(文章页)时依旧显示含 link 属性的菜单项
930
940
  articleShowLink: false
931
941
  # 当设定全局音乐播放器时,是否一直显示音乐控制菜单。false:仅当音乐播放时启用
932
- musicAlwaysShow: true
942
+ musicAlwaysShow: false
933
943
  # 右键内置组,预置实现
934
944
  plugins:
935
945
  # 导航组件
936
946
  # 横向排列,共用一行,仅显示图标 (原则上支持的数量不限)
937
- navigation:
947
+ navigation:
938
948
  - {id: 'left', name: '转到上一页', icon: 'fa-solid fa-arrow-left', event: 'history.back()', group: 'navigation'}
939
949
  - {id: 'right', name: '转到下一页', icon: 'fa-solid fa-arrow-right', event: 'history.forward()', group: 'navigation'}
940
950
  - {id: 'redo', name: '刷新当前页面', icon: 'fa-solid fa-redo', event: 'window.location.reload()', group: 'navigation'}
@@ -947,19 +957,22 @@ rightmenus:
947
957
  - {id: 'copyAll', name: '全选文本', icon: 'fa-solid fa-object-ungroup', event: 'copyAll', group: 'inputBox'}
948
958
  - {id: 'copyCut', name: '剪切文本', icon: 'fa-solid fa-cut', event: 'copyCut', group: 'inputBox'}
949
959
  # 文本选中类组件
950
- # 生效于右键选中文本,__text__ 为选中的文本。
960
+ # 生效于右键选中文本,__text__ 为选中的文本。
951
961
  seletctText:
952
962
  - {id: 'copyText', name: '复制文本', icon: 'fa-solid fa-copy', event: 'copyText', group: 'seletctText'}
953
963
  - {id: 'searchWord', name: '站内搜索', icon: 'fa-solid fa-search', event: 'OpenSearch(__text__)', group: 'seletctText'}
954
964
  - {id: 'bingSearch', name: '必应搜索', icon: 'fa-solid fa-search', event: 'window.open(`https://cn.bing.com/search?q=${__text__}`)', group: 'seletctText'}
955
965
  #- {id: 'googleSearch', name: '谷歌搜索', icon: 'fa-solid fa-search', event: 'window.open(`https://www.google.com/search?q=${__text__}`)', group: 'seletctText'}
956
- # 元素判断组件
957
- # 生效于 a/img 处的右键行为,__link__ 为链接地址
966
+ # 链接判断组件
967
+ # 生效于链接处的右键行为,__link__ 为链接地址
958
968
  elementCheck:
959
969
  - {id: 'openTab', name: '新标签页打开', icon: 'fa-solid fa-external-link-square-alt', event: 'window.open(__link__)', group: 'elementCheck'}
960
970
  - {id: 'copyLink', name: '复制链接地址', icon: 'fa-solid fa-link', event: 'copyLink', group: 'elementCheck'}
961
- # 复制图片文件至剪切板,仅支持 png 格式
962
- - {id: 'copyImg', name: '复制图片文件', icon: 'fa-solid fa-image', event: 'copyImg', group: 'elementCheck'}
971
+ # 图片判断类组件
972
+ # 生效于图片类的右键行为,__link__ 为链接地址
973
+ elementImage:
974
+ - {id: 'copyImg', name: '复制图片', icon: 'fa-solid fa-image', event: 'copyImg', group: 'elementImage'}
975
+ - {id: 'googleImg', name: '谷歌识图', icon: 'fa-solid fa-images', event: 'window.open(`https://www.google.com.hk/searchbyimage?image_url=${__link__}`)', group: 'elementImage'}
963
976
  # 文章页面组件
964
977
  # 生效于 post.article 页面
965
978
  articlePage:
@@ -974,7 +987,7 @@ rightmenus:
974
987
  - hr
975
988
  - {id: 'source_docs', name: '本站源码', icon: 'fa-solid fa-code-branch', link: 'https://github.com/volantis-x/volantis-docs/', group: 'link'}
976
989
  - {id: 'source_theme', name: '主题源码', icon: 'fa-solid fa-code-branch', link: 'https://github.com/volantis-x/hexo-theme-volantis/', group: 'link'}
977
- darkMode:
990
+ darkMode:
978
991
  - {id: 'darkMode', name: '暗黑模式', icon: 'fa-solid fa-moon', event: 'volantis.dark.toggle()', group: 'darkMode'}
979
992
  ###
980
993
 
@@ -1043,7 +1056,7 @@ color_scheme:
1043
1056
  # 主题色
1044
1057
  theme: '#3dd9b6'
1045
1058
  # 链接色
1046
- link: '#1b79c4'
1059
+ link: '#2092ec'
1047
1060
  # 按钮色
1048
1061
  button: '#44D7B6'
1049
1062
  # 鼠标放到交互元素上时的色
@@ -1100,11 +1113,11 @@ color_scheme:
1100
1113
  # 卡片背景色 # Dark Grey 3
1101
1114
  card: '#262626'
1102
1115
  # 网站背景上的文字
1103
- site_inner: '#eee'
1116
+ site_inner: '#eeeeeede'
1104
1117
  # 网站页脚文字
1105
- site_footer: '#aaa'
1118
+ site_footer: '#aaaaaade'
1106
1119
  # 卡片上的普通文字
1107
- text: '#eee'
1120
+ text: '#eeeeeede'
1108
1121
 
1109
1122
  # 区块和代码块背景色 # Dark Grey 4
1110
1123
  block: '#434343'
@@ -1113,21 +1126,21 @@ color_scheme:
1113
1126
  # 行内代码颜色
1114
1127
  inlinecode: '#D56D28'
1115
1128
 
1116
- # 文章部分
1117
- h1: '#f5f5f5' # Dark Grey 8
1118
- h2: '#f5f5f5'
1119
- h3: '#f0f0f0' # Dark Grey 7
1120
- h4: '#f0f0f0'
1121
- h5: '#f0f0f0'
1122
- h6: '#f0f0f0'
1123
- p: '#d9d9d9e6' # Dark Grey 6
1129
+ # 文章部分 高强度文本的不透明度应为87% 中等重点文字适用于60%
1130
+ h1: '#FFFFFFde' # Dark Grey 8
1131
+ h2: '#FFFFFFde'
1132
+ h3: '#FFFFFF99' # Dark Grey 7
1133
+ h4: '#FFFFFF99'
1134
+ h5: '#FFFFFF99'
1135
+ h6: '#FFFFFF99'
1136
+ p: '#d9d9d9de' # Dark Grey 6
1124
1137
 
1125
1138
  # 列表文字 # Dark Grey 6
1126
- list: '#d9d9d9d9'
1139
+ list: '#d9d9d9de'
1127
1140
  # 列表 hover 时的文字
1128
1141
  list_hl: 'mix($color-theme, #fff, 80)'
1129
1142
  # 辅助性文字 # Dark Grey 5
1130
- meta: '#bfbfbf'
1143
+ meta: '#bfbfbfde'
1131
1144
  # 夜间图片亮度
1132
1145
  brightness: 70%
1133
1146
  ############################### Color Scheme ############################### > end
@@ -26,7 +26,7 @@
26
26
  </p>
27
27
  </a>
28
28
  </div>
29
- -<% } else if (theme.comments.service=='waline' && theme.comments.waline.visitor) { %>
29
+ <% } else if (theme.comments.service=='waline' && theme.comments.waline.pageview) { %>
30
30
  <div class="new-meta-item browse">
31
31
  <a class='notlink'>
32
32
  <i class="<%- theme.article.body.meta_library.counter.icon %> fa-fw" aria-hidden="true"></i>
@@ -36,21 +36,43 @@
36
36
  path = path.substring(0, path.length - 10);
37
37
  }
38
38
  %>
39
- <span id="<%- url_for(path) %>" class="leancloud_visitors" data-flag-title="<%- post.title || page.title %>">
39
+ <span data-path="<%- url_for(path) %>" class="waline-pageview-count"></span>
40
+ </a>
41
+ </div>
42
+ <% } else if (theme.comments.service=='twikoo' && !!page.comments) { %>
43
+ <div class="new-meta-item browse">
44
+ <a class='notlink'>
45
+ <i class="<%- theme.article.body.meta_library.counter.icon %> fa-fw" aria-hidden="true"></i>
40
46
  <p>
41
- <span class="leancloud-visitors-count"></span>
47
+ <span id="twikoo_visitors">
48
+ <i class="fa-solid fa-circle-notch fa-spin fa-fw" aria-hidden="true"></i>
49
+ </span>
42
50
  </p>
43
51
  </span>
44
52
  </a>
45
53
  </div>
46
- <% } else if (theme.comments.service=='twikoo' && !!page.comments) { %>
54
+ <% } else if (theme.comments.service=='discuss' && !!page.comments) { %>
47
55
  <div class="new-meta-item browse">
48
56
  <a class='notlink'>
49
57
  <i class="<%- theme.article.body.meta_library.counter.icon %> fa-fw" aria-hidden="true"></i>
50
58
  <p>
51
- <span id="twikoo_visitors"></span>
59
+ <span id="Discuss-Visitors">
60
+ <i class="fa-solid fa-circle-notch fa-spin fa-fw" aria-hidden="true"></i>
61
+ </span>
52
62
  </p>
53
63
  </span>
54
64
  </a>
55
65
  </div>
66
+ <% } else if (theme.comments.service=='artalk' && !!page.comments) { %>
67
+ <div class="new-meta-item browse">
68
+ <a class='notlink'>
69
+ <i class="<%- theme.article.body.meta_library.counter.icon %> fa-fw" aria-hidden="true"></i>
70
+ <p>
71
+ <span id="artalk_visitors">
72
+ <i class="fa-solid fa-circle-notch fa-spin fa-fw" aria-hidden="true"></i>
73
+ </span>
74
+ <%- theme.article.body.meta_library.counter.unit %>
75
+ </p>
76
+ </a>
77
+ </div>
56
78
  <% } %>
@@ -5,10 +5,11 @@
5
5
  if (path.length > 9 && (path.substring(path.length - 10) == 'index.html')) {
6
6
  path = path.substring(0, path.length - 10);
7
7
  }
8
+ if(!!theme.comments.waline.path) path = theme.comments.waline.path
8
9
  %>
9
10
  <a href="<%- url_for(path) %>#comments">
10
11
  <i class="<%- theme.article.body.meta_library.walinecount.icon %> fa-fw"></i>
11
- <span id="<%- url_for(path) %>" class="waline-comment-count"></span>
12
+ <span data-path="<%- url_for(path) %>" class="waline-comment-count"></span>
12
13
  <span class="leancloud-comments-count">&nbsp;<%- theme.article.body.meta_library.walinecount.desc %></span>
13
14
  </a>
14
15
  </div>
@@ -114,13 +114,13 @@
114
114
  <div class="prev-next">
115
115
  <% if (post.prev) { %>
116
116
  <a class='prev' href='<%- url_for(post.prev.path) %>'>
117
- <p class='title'><i class="fa-solid fa-chevron-left" aria-hidden="true"></i><%- post.prev.title || post.prev.seo_title || '' %></p>
117
+ <p class='title'><i class="fa-solid fa-chevron-left" aria-hidden="true"></i><%- post.prev.title || post.prev.seo_title || date(post.date, theme.article.body.meta_library.date.format) %></p>
118
118
  <p class='content'><%- truncate(strip_html(page.prev.content), {length: 100}) %></p>
119
119
  </a>
120
120
  <% } %>
121
121
  <% if (post.next) { %>
122
122
  <a class='next' href='<%- url_for(post.next.path) %>'>
123
- <p class='title'><%- post.next.title || post.next.seo_title || '' %><i class="fa-solid fa-chevron-right" aria-hidden="true"></i></p>
123
+ <p class='title'><%- post.next.title || post.next.seo_title || date(post.date, theme.article.body.meta_library.date.format) %><i class="fa-solid fa-chevron-right" aria-hidden="true"></i></p>
124
124
  <p class='content'><%- truncate(strip_html(page.next.content), {length: 100}) %></p>
125
125
  </a>
126
126
  <% } %>
@@ -1,5 +1,6 @@
1
1
  <head hexo-theme='https://github.com/volantis-x/hexo-theme-volantis/tree/<%- theme.info.theme_version %>'>
2
2
  <%- meta_generator() %>
3
+ <meta name="Volantis" content="<%- theme.info.theme_version %>">
3
4
  <meta charset="utf-8">
4
5
  <!-- SEO相关 -->
5
6
  <%- generate_seo(theme, page) %>
@@ -21,19 +22,23 @@
21
22
  <meta name="HandheldFriendly" content="True" >
22
23
  <meta name="apple-mobile-web-app-capable" content="yes">
23
24
  <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=5">
24
- <meta content="<%=config.title%>" name="application-name">
25
- <meta content="<%=config.title%>" name="apple-mobile-web-app-title">
26
25
  <meta content="black-translucent" name="apple-mobile-web-app-status-bar-style">
27
26
  <meta content="telephone=no" name="format-detection">
27
+ <!-- import head_begin begin -->
28
+ <%_ if (config.import && config.import.head_begin){ _%>
29
+ <%_ ([...config.import.head_begin]).forEach(function(item){ _%>
30
+ <%- item %>
31
+ <%_ }) _%>
32
+ <%_ } _%>
33
+ <!-- import head_begin end -->
34
+ <!-- Custom Files headBegin begin-->
35
+ <%- volantis_inject('headBegin') %>
36
+ <!-- Custom Files headBegin end-->
37
+ <%_ if (config.favicon) { _%>
38
+ <link rel="shortcut icon" type='image/x-icon' href="<%- url_for(config.favicon) %>">
39
+ <%_ } _%>
28
40
  <link rel="preload" href="<%- theme.cdn.map.css.style %>" as="style">
29
41
  <%- generate_preload_fontfamily(theme) %>
30
- <!-- 页面元数据 -->
31
- <pjax>
32
- <%- generate_title(config, theme, page) %>
33
- <%- generate_keywords(config, theme, page) %>
34
- <%- generate_description(config, theme, page) %>
35
- <%- open_graph(theme.open_graph) %>
36
- </pjax>
37
42
  <!-- feed -->
38
43
  <%_ if (config.feed && config.feed.path){ _%>
39
44
  <%_ if (typeof(config.feed.path)=="string"){ _%>
@@ -44,22 +49,11 @@
44
49
  <%_ }) _%>
45
50
  <%_ } _%>
46
51
  <%_ } _%>
47
- <!-- import meta -->
48
- <%_ if (config.import && config.import.meta){ _%>
49
- <%_ (config.import.meta||[]).forEach(function(item){ _%>
50
- <%- item %>
51
- <%_ }) _%>
52
- <%_ } _%>
53
- <!-- link -->
54
- <%_ if (config.favicon) { _%>
55
- <link rel="shortcut icon" type='image/x-icon' href="<%- url_for(config.favicon) %>">
56
- <%_ } _%>
57
- <!-- import link -->
58
- <%_ if (config.import && config.import.link){ _%>
59
- <%_ (config.import.link||[]).forEach(function(item){ _%>
60
- <%- item %>
61
- <%_ }) _%>
62
- <%_ } _%>
52
+ <!-- 页面元数据 -->
53
+ <%- generate_title(config, theme, page) %>
54
+ <%- generate_keywords(config, theme, page) %>
55
+ <%- generate_description(config, theme, page) %>
56
+ <%- open_graph(theme.open_graph) %>
63
57
  <style>
64
58
  /* 首屏样式 */
65
59
  <%- FirstCSS() %>
@@ -76,7 +70,14 @@
76
70
  <%_ } _%>
77
71
  <%- partial('../_plugins/end-of-support/script') %>
78
72
  <%- partial('scripts/global') %>
79
- <!-- Custom Files head begin-->
80
- <%- volantis_inject('head') %>
81
- <!-- Custom Files head end-->
73
+ <!-- import head_end begin -->
74
+ <%_ if (config.import && config.import.head_end){ _%>
75
+ <%_ ([...config.import.head_end]).forEach(function(item){ _%>
76
+ <%- item %>
77
+ <%_ }) _%>
78
+ <%_ } _%>
79
+ <!-- import head_end end -->
80
+ <!-- Custom Files headEnd begin-->
81
+ <%- volantis_inject('headEnd') %>
82
+ <!-- Custom Files headEnd end-->
82
83
  </head>
@@ -61,7 +61,7 @@
61
61
  </li>
62
62
  <% } else { %>
63
63
  <li>
64
- <a class="menuitem flat-box faa-parent animated-hover"
64
+ <a class="menuitem flat-box faa-parent animated-hover"
65
65
  <%- value.url ? `href="` + url_for(value.url) + `" title="` + (value.description || value.name) + `"`
66
66
  : ` href="/" onclick="return false;" title="` + (value.description || value.name) + `"` %>
67
67
  <% if (value.rel) { %>