hexo-theme-solitude 1.3.1 → 1.4.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 (274) hide show
  1. package/.github/FUNDING.yml +13 -0
  2. package/.github/ISSUE_TEMPLATE/bug_report.yml +107 -0
  3. package/.github/ISSUE_TEMPLATE/config.yml +13 -0
  4. package/.github/ISSUE_TEMPLATE/feature_request.yml +14 -0
  5. package/.github/workflows/npm-publish.yml +21 -0
  6. package/CONTRIBUTING.md +0 -0
  7. package/LICENSE +0 -0
  8. package/README.md +60 -43
  9. package/README_EN.md +60 -42
  10. package/_config.yml +602 -451
  11. package/languages/en-US.yml +4 -24
  12. package/languages/zh-CN.yml +4 -24
  13. package/layout/404.pug +1 -1
  14. package/layout/archive.pug +0 -0
  15. package/layout/category.pug +0 -0
  16. package/layout/includes/body/mode.pug +1 -6
  17. package/layout/includes/console.pug +3 -3
  18. package/layout/includes/footer.pug +16 -15
  19. package/layout/includes/head/config.pug +38 -30
  20. package/layout/includes/head/opengraph.pug +0 -0
  21. package/layout/includes/head/pwa.pug +5 -44
  22. package/layout/includes/head.pug +4 -2
  23. package/layout/includes/header.pug +0 -0
  24. package/layout/includes/inject/body.pug +114 -65
  25. package/layout/includes/inject/head.pug +11 -46
  26. package/layout/includes/layout.pug +1 -2
  27. package/layout/includes/loading.pug +0 -0
  28. package/layout/includes/mixins/articleSort.pug +0 -0
  29. package/layout/includes/mixins/pagination.pug +0 -0
  30. package/layout/includes/nav.pug +1 -1
  31. package/layout/includes/page/about.pug +1 -1
  32. package/layout/includes/page/categories.pug +0 -0
  33. package/layout/includes/page/default.pug +0 -0
  34. package/layout/includes/page/equipment.pug +0 -0
  35. package/layout/includes/page/links.pug +2 -2
  36. package/layout/includes/page/music.pug +0 -0
  37. package/layout/includes/page/not_configured.pug +0 -0
  38. package/layout/includes/page/rss.pug +3 -3
  39. package/layout/includes/page/says.pug +15 -15
  40. package/layout/includes/page/tags.pug +0 -0
  41. package/layout/includes/page/tlink.pug +1 -0
  42. package/layout/includes/recent-posts.pug +0 -0
  43. package/layout/includes/sidebar.pug +0 -0
  44. package/layout/includes/widgets/aside/aside.pug +6 -6
  45. package/layout/includes/widgets/aside/asideAllInfo.pug +0 -0
  46. package/layout/includes/widgets/aside/asideArchive.pug +0 -0
  47. package/layout/includes/widgets/aside/asideCustom.pug +1 -1
  48. package/layout/includes/widgets/aside/asideFlipCard.pug +0 -0
  49. package/layout/includes/widgets/aside/asideInfoCard.pug +3 -3
  50. package/layout/includes/widgets/aside/asideNewestPost.pug +0 -0
  51. package/layout/includes/widgets/aside/asideSwitch.pug +0 -4
  52. package/layout/includes/widgets/aside/asideTag.pug +1 -1
  53. package/layout/includes/widgets/aside/asideToc.pug +0 -0
  54. package/layout/includes/widgets/aside/asideWebInfo.pug +2 -2
  55. package/layout/includes/widgets/home/banner.pug +0 -0
  56. package/layout/includes/widgets/home/bb/json.pug +22 -0
  57. package/layout/includes/widgets/home/bb/local.pug +17 -0
  58. package/layout/includes/widgets/home/bb/memos.pug +25 -0
  59. package/layout/includes/widgets/home/bbTimeList.pug +11 -7
  60. package/layout/includes/widgets/home/categoryBar.pug +0 -0
  61. package/layout/includes/widgets/home/categoryGroup.pug +1 -1
  62. package/layout/includes/widgets/home/hometop.pug +0 -0
  63. package/layout/includes/widgets/home/postList.pug +0 -0
  64. package/layout/includes/widgets/home/topGroup.pug +0 -0
  65. package/layout/includes/widgets/nav/left.pug +0 -0
  66. package/layout/includes/widgets/nav/menu.pug +1 -1
  67. package/layout/includes/widgets/nav/right.pug +6 -5
  68. package/layout/includes/widgets/page/about/authorinfo.pug +10 -9
  69. package/layout/includes/widgets/page/about/award.pug +0 -0
  70. package/layout/includes/widgets/page/about/contentinfo.pug +35 -34
  71. package/layout/includes/widgets/page/about/hobbies.pug +21 -17
  72. package/layout/includes/widgets/page/about/motto.pug +17 -16
  73. package/layout/includes/widgets/page/about/other.pug +16 -16
  74. package/layout/includes/widgets/page/about/personalities.pug +15 -14
  75. package/layout/includes/widgets/page/about/skillsinfo.pug +37 -36
  76. package/layout/includes/widgets/page/about/tenyear.pug +0 -0
  77. package/layout/includes/widgets/page/banner.pug +9 -3
  78. package/layout/includes/widgets/page/equipment/content.pug +0 -0
  79. package/layout/includes/widgets/page/links/banner.pug +14 -12
  80. package/layout/includes/widgets/page/links/linksCard.pug +4 -6
  81. package/layout/includes/widgets/page/links/linksDiscn.pug +8 -0
  82. package/layout/includes/widgets/page/links/linksItem.pug +4 -6
  83. package/layout/includes/widgets/page/says/json.pug +78 -0
  84. package/layout/includes/widgets/page/says/local.pug +44 -0
  85. package/layout/includes/widgets/page/says/memos.pug +107 -0
  86. package/layout/includes/widgets/post/award.pug +0 -0
  87. package/layout/includes/widgets/post/copyright.pug +2 -2
  88. package/layout/includes/widgets/post/post-ai.pug +12 -0
  89. package/layout/includes/widgets/post/postMeta.pug +2 -2
  90. package/layout/includes/widgets/post/postNav.pug +0 -0
  91. package/layout/includes/widgets/post/wave.pug +0 -0
  92. package/layout/includes/widgets/randomlink.pug +1 -1
  93. package/layout/includes/widgets/rightside/index.pug +6 -5
  94. package/layout/includes/widgets/third-party/comments/comment.pug +1 -5
  95. package/layout/includes/widgets/third-party/comments/twikoo.pug +1 -1
  96. package/layout/includes/widgets/third-party/comments/waline.pug +9 -11
  97. package/layout/includes/widgets/third-party/music.pug +1 -1
  98. package/layout/includes/widgets/third-party/news-comment/newest-comment.pug +6 -0
  99. package/layout/includes/widgets/third-party/news-comment/twikoo.pug +70 -0
  100. package/layout/includes/widgets/third-party/news-comment/waline.pug +64 -0
  101. package/layout/includes/widgets/third-party/pjax.pug +0 -0
  102. package/layout/includes/widgets/third-party/search/algolia-search.pug +0 -0
  103. package/layout/includes/widgets/third-party/search/index.pug +8 -7
  104. package/layout/includes/widgets/third-party/search/local-search.pug +0 -0
  105. package/layout/index.pug +3 -3
  106. package/layout/page.pug +0 -4
  107. package/layout/post.pug +2 -2
  108. package/layout/tag.pug +0 -0
  109. package/package.json +18 -9
  110. package/plugins.yml +109 -0
  111. package/scripts/event/cdn.js +129 -0
  112. package/scripts/event/init.js +0 -0
  113. package/scripts/event/page.js +1 -21
  114. package/scripts/event/welcome.js +1 -1
  115. package/scripts/filter/checkThemeConfig.js +0 -0
  116. package/scripts/filter/default.js +0 -0
  117. package/scripts/filter/lazyload.js +1 -1
  118. package/scripts/filter/randomPosts.js +0 -0
  119. package/scripts/helper/cdn.js +0 -0
  120. package/scripts/helper/getArchiveLength.js +0 -0
  121. package/scripts/helper/page.js +0 -0
  122. package/scripts/helper/related_post.js +0 -0
  123. package/scripts/helper/stylus.js +0 -0
  124. package/scripts/tags/button.js +0 -0
  125. package/scripts/tags/bvideo.js +0 -0
  126. package/scripts/tags/card.js +0 -0
  127. package/scripts/tags/checkbox.js +0 -0
  128. package/scripts/tags/fold.js +0 -0
  129. package/scripts/tags/image.js +0 -0
  130. package/scripts/tags/inline-image.js +0 -0
  131. package/scripts/tags/label.js +0 -0
  132. package/scripts/tags/link.js +0 -0
  133. package/scripts/tags/media.js +0 -0
  134. package/scripts/tags/note.js +0 -0
  135. package/scripts/tags/span.js +0 -0
  136. package/scripts/tags/tabs.js +0 -0
  137. package/scripts/tags/timeline.js +0 -0
  138. package/scripts/tags/u.js +0 -0
  139. package/source/css/_global/animation.css +0 -0
  140. package/source/css/_global/function.styl +42 -42
  141. package/source/css/_global/index.styl +1 -1
  142. package/source/css/_global/var.styl +0 -0
  143. package/source/css/_layout/basic.styl +16 -13
  144. package/source/css/_layout/header.styl +7 -2
  145. package/source/css/_layout/index.styl +59 -5
  146. package/source/css/_mode/index.styl +1 -17
  147. package/source/css/_page/_home/category-bar.styl +0 -0
  148. package/source/css/_page/_home/home-top.styl +10 -31
  149. package/source/css/_page/_home/index.styl +0 -0
  150. package/source/css/_page/_home/pagination.styl +3 -0
  151. package/source/css/_page/_home/recent-post.styl +10 -3
  152. package/source/css/_page/about/author.styl +94 -0
  153. package/source/css/_page/about/buff.styl +34 -0
  154. package/source/css/_page/about/careers.styl +27 -0
  155. package/source/css/_page/about/contentinfo.styl +78 -0
  156. package/source/css/_page/about/game.styl +41 -0
  157. package/source/css/_page/about/index.styl +39 -1
  158. package/source/css/_page/about/like.styl +29 -0
  159. package/source/css/_page/about/maxim.styl +23 -0
  160. package/source/css/_page/about/myphoto.styl +34 -0
  161. package/source/css/_page/about/oneself.styl +91 -0
  162. package/source/css/_page/about/personalities.styl +25 -0
  163. package/source/css/_page/about/reward.styl +113 -0
  164. package/source/css/_page/about/skills.styl +75 -0
  165. package/source/css/_page/about/statistic.styl +55 -0
  166. package/source/css/_page/about/tenyear.styl +0 -0
  167. package/source/css/_page/category.styl +0 -0
  168. package/source/css/_page/douban.styl +0 -1
  169. package/source/css/_page/equipment.styl +0 -0
  170. package/source/css/_page/error.styl +0 -0
  171. package/source/css/_page/home.styl +0 -0
  172. package/source/css/_page/index.styl +20 -5
  173. package/source/css/_page/links.styl +84 -49
  174. package/source/css/_page/moment.styl +0 -0
  175. package/source/css/_page/music.styl +0 -0
  176. package/source/css/_page/rss.styl +0 -0
  177. package/source/css/_page/says.styl +10 -0
  178. package/source/css/_page/tag.styl +0 -0
  179. package/source/css/_widgets/_aside/allinfo.styl +34 -0
  180. package/source/css/_widgets/_aside/flip.styl +0 -0
  181. package/source/css/_widgets/_aside/index.styl +1 -7
  182. package/source/css/_widgets/_aside/info.styl +0 -0
  183. package/source/css/_widgets/_aside/newPost.styl +0 -0
  184. package/source/css/_widgets/_aside/toc.styl +0 -0
  185. package/source/css/_widgets/_aside/welcome.styl +0 -0
  186. package/source/css/_widgets/_comment/index.styl +0 -0
  187. package/source/css/_widgets/_comment/twikoo.styl +0 -2
  188. package/source/css/_widgets/_comment/waline.styl +0 -0
  189. package/source/css/_widgets/_extra/console.styl +0 -0
  190. package/source/css/_widgets/_extra/fullpage.styl +0 -0
  191. package/source/css/_widgets/_extra/music.styl +1 -1
  192. package/source/css/_widgets/_extra/pace.styl +0 -0
  193. package/source/css/_widgets/_extra/rightmenu.styl +0 -0
  194. package/source/css/_widgets/_mixins/article-sort.styl +0 -0
  195. package/source/css/_widgets/_mixins/footer.styl +1 -2
  196. package/source/css/_widgets/_mixins/other.styl +0 -4
  197. package/source/css/_widgets/_mixins/sidebar.styl +0 -0
  198. package/source/css/_widgets/_post/_highlight/diff.styl +0 -0
  199. package/source/css/_widgets/_post/_highlight/index.styl +0 -1
  200. package/source/css/_widgets/_post/_highlight/theme/default.styl +0 -0
  201. package/source/css/_widgets/_post/_highlight/theme/mac.styl +0 -0
  202. package/source/css/_widgets/_post/_highlight/theme.styl +0 -0
  203. package/source/css/_widgets/_post/commentBarrage.styl +0 -0
  204. package/source/css/_widgets/_post/content.styl +42 -11
  205. package/source/css/_widgets/_post/copyright.styl +0 -0
  206. package/source/css/_widgets/_post/index.styl +1 -1
  207. package/source/css/_widgets/_post/meta.styl +0 -3
  208. package/source/css/_widgets/_post/pagination.styl +1 -1
  209. package/source/css/_widgets/_post/postAI.styl +0 -0
  210. package/source/css/_widgets/_post/relatedPost.styl +0 -0
  211. package/source/css/_widgets/_post/tools.styl +0 -0
  212. package/source/css/_widgets/_search/algolia-search.styl +0 -0
  213. package/source/css/_widgets/_search/local-search.styl +0 -0
  214. package/source/css/_widgets/_tags/button.styl +0 -0
  215. package/source/css/_widgets/_tags/bvideo.styl +0 -0
  216. package/source/css/_widgets/_tags/card.styl +0 -0
  217. package/source/css/_widgets/_tags/checkbox.styl +0 -0
  218. package/source/css/_widgets/_tags/fold.styl +0 -0
  219. package/source/css/_widgets/_tags/image.styl +0 -0
  220. package/source/css/_widgets/_tags/index.styl +0 -0
  221. package/source/css/_widgets/_tags/inline-image.styl +0 -0
  222. package/source/css/_widgets/_tags/label.styl +0 -0
  223. package/source/css/_widgets/_tags/link.styl +4 -2
  224. package/source/css/_widgets/_tags/note.styl +0 -0
  225. package/source/css/_widgets/_tags/span.styl +0 -0
  226. package/source/css/_widgets/_tags/tabs.styl +0 -0
  227. package/source/css/_widgets/_tags/timeline.styl +0 -1
  228. package/source/css/_widgets/index.styl +4 -4
  229. package/source/css/index.styl +0 -0
  230. package/source/img/avatar.png +0 -0
  231. package/source/img/default.png +0 -0
  232. package/source/img/error_load.png +0 -0
  233. package/source/js/{extend/comment/twikoo/commentBarrage.js → comment/twikoo_commentBarrage.js} +0 -0
  234. package/source/js/{extend/comment/waline/commentBarrage.js → comment/waline_commentBarrage.js} +0 -0
  235. package/source/js/covercolor/api.js +92 -0
  236. package/source/js/covercolor/local.js +85 -0
  237. package/source/js/main.js +28 -235
  238. package/source/js/music.js +0 -0
  239. package/source/js/rightside.js +404 -0
  240. package/source/js/{extend/search/algolia-search.js → search/algolia.js} +10 -0
  241. package/source/js/{extend/search/local-search.js → search/local.js} +24 -2
  242. package/source/js/utils.js +75 -1
  243. package/layout/includes/head/fest.pug +0 -22
  244. package/layout/includes/page/echarts.pug +0 -7
  245. package/layout/includes/page/moments.pug +0 -4
  246. package/layout/includes/widgets/aside/asideHistory.pug +0 -8
  247. package/layout/includes/widgets/aside/asideWelcome.pug +0 -12
  248. package/layout/includes/widgets/page/moments/angle.pug +0 -19
  249. package/layout/includes/widgets/page/moments/index.pug +0 -23
  250. package/layout/includes/widgets/page/says/saysBottom.pug +0 -11
  251. package/layout/includes/widgets/page/says/saysContent.pug +0 -6
  252. package/layout/includes/widgets/page/says/saysFunction.pug +0 -10
  253. package/layout/includes/widgets/page/says/saysMeta.pug +0 -7
  254. package/layout/includes/widgets/third-party/ai/index.pug +0 -12
  255. package/layout/includes/widgets/third-party/comments/gitalk.pug +0 -0
  256. package/layout/includes/widgets/third-party/comments/valine.pug +0 -0
  257. package/scripts/helper/echarts.js +0 -407
  258. package/source/css/_page/about.styl +0 -764
  259. package/source/css/_widgets/_aside/history.styl +0 -42
  260. package/source/js/extend/comment/twikoo/twikoo.js +0 -67
  261. package/source/js/extend/comment/waline/waline.js +0 -60
  262. package/source/lib/bundle.min.js +0 -27
  263. package/source/lib/circle.min.js +0 -1
  264. package/source/lib/cover-color.min.js +0 -7
  265. package/source/lib/friends_post.js +0 -4
  266. package/source/lib/lazyload.min.js +0 -1
  267. package/source/lib/rightside.min.js +0 -1
  268. package/source/lib/snackbar.min.css +0 -1
  269. package/source/lib/snackbar.min.js +0 -9
  270. package/source/lib/txmap.min.js +0 -1
  271. package/source/lib/universe.min.js +0 -1
  272. package/source/lib/view-image.min.js +0 -6
  273. package/source/lib/waterfall.min.js +0 -1
  274. /package/source/{lib → js}/sco-ai.min.js +0 -0
@@ -1,53 +1,19 @@
1
- - var cdn = theme.cdn.head
1
+ each item in theme.verify_site || []
2
+ meta(name=item.name, content=item.content)
2
3
 
3
- if theme.verify.baidu
4
- meta(name="baidu-site-verification", content=theme.verify.baidu)
5
-
6
- if theme.verify.google
7
- meta(name="google-site-verification", content=theme.verify.google)
8
-
9
- if theme.verify.sougou
10
- meta(name="sogou_site_verification", content=theme.verify.sougou)
11
-
12
- link(rel="stylesheet", href=cdn.scoicon)
13
- link(rel="stylesheet", href=cdn_url_for("/lib/snackbar.min.css"))
14
-
15
- // comment
16
- if theme.comment.enable
17
- case theme.comment.type
18
- when 'twikoo'
19
- script(src=cdn.twikoojs)
20
- when 'waline'
21
- script(src=cdn.walinejs)
22
- link(rel="stylesheet", href=cdn.walinecss)
23
-
24
- // pace 胶囊加载条(Capsule loading bar)
25
- if theme.loading.pace
26
- script(src=cdn.pacejs)
27
-
28
- // search
29
- if theme.thirdparty.search.enable
30
- if theme.thirdparty.search.type === 'algolia'
31
- script(src=url_for(cdn.instantsearch))
32
- script(src=url_for(cdn.algoliajs))
33
- else if theme.thirdparty.search.type === 'local'
34
- script(src=url_for(cdn.lunrjs))
4
+ link(rel="stylesheet", href=url_for(theme.cdn.scoicon_css))
5
+ link(rel="stylesheet", href=url_for(theme.cdn.snackbar_css))
35
6
 
36
7
  // aplayer
37
- if theme.thirdparty.aplayer.enable || theme.music.enable
38
- link(rel="stylesheet", href=cdn.aplayercss)
8
+ if theme.capsule.enable || theme.music.enable
9
+ link(rel="stylesheet", href=url_for(theme.cdn.aplayer_css))
39
10
 
40
11
  // swiper
41
- if theme.says.home_mini || theme.aside.history.enable
42
- link(rel="stylesheet", href=cdn.swipercss)
43
-
44
- // echarts
45
- if theme.about.echarts.enable && theme.about.enable
46
- script(src=url_for(cdn.echartsjs))
12
+ if theme.says.home_mini
13
+ link(rel="stylesheet", href=url_for(theme.cdn.swiper_css))
47
14
 
48
- // 灰色纪念日(Gray Anniversary)
49
- if theme.fest.enable
50
- include ../head/fest.pug
15
+ if theme.fancybox
16
+ link(rel="stylesheet", href=url_for(theme.cdn.fancyapps_css))
51
17
 
52
18
  // Open Graph
53
19
  include ../head/opengraph.pug
@@ -114,8 +80,7 @@ script.
114
80
  );
115
81
 
116
82
  div
117
- script(src=cdn_url_for("/js/utils.js"))
118
- script(src=cdn_url_for("/js/main.js"))
83
+ script(src=url_for(theme.cdn.utils))
119
84
 
120
85
  // custom inject
121
86
  if theme.extends.head
@@ -5,7 +5,6 @@ html(lang=config.language, data-theme="light")
5
5
  head
6
6
  include ./head.pug
7
7
  body#body(data-type=page.type)
8
- canvas#universe
9
8
  // loading
10
9
  if theme.loading.fullpage
11
10
  include ./loading.pug
@@ -35,5 +34,5 @@ html(lang=config.language, data-theme="light")
35
34
  include ./widgets/third-party/search/index.pug
36
35
 
37
36
  // music
38
- if theme.thirdparty.aplayer.enable
37
+ if theme.capsule.enable
39
38
  include ./widgets/third-party/music.pug
File without changes
File without changes
File without changes
@@ -11,7 +11,7 @@ nav#nav.show
11
11
  else if theme.site.name.class === 'img'
12
12
  img(src=theme.site.name.custom, alt=config.title)
13
13
  else if theme.site.name.class === 'text'
14
- span.scoicon= theme.site.name.custom
14
+ span.title= theme.site.name.custom
15
15
  #page-name-mask
16
16
  #page-name
17
17
  a#page-name-text(onclick="sco.toTop()")= title || config.title
@@ -1,4 +1,4 @@
1
- if theme.about.enable && site.data.about
1
+ if site.data.about
2
2
  #about-page
3
3
  include ../widgets/page/about/authorinfo
4
4
  include ../widgets/page/about/contentinfo
File without changes
File without changes
File without changes
@@ -1,7 +1,5 @@
1
1
  .flink#banners
2
2
  include ../widgets/page/links/banner
3
- if theme.thirdparty.circle.angle.enable
4
- include ../widgets/page/moments/angle
5
3
  .flink#article-container
6
4
  each data in site.data.links.links
7
5
  h2= data.class_name + " (" + data.link_list.length + ")"
@@ -11,4 +9,6 @@ if theme.thirdparty.circle.angle.enable
11
9
  include ../widgets/page/links/linksCard
12
10
  when 'item'
13
11
  include ../widgets/page/links/linksItem
12
+ when 'discn'
13
+ include ../widgets/page/links/linksDiscn
14
14
  != page.content
File without changes
File without changes
@@ -1,17 +1,17 @@
1
1
  .rss-plan-list
2
- a.rss-plan-item.rss-plan-wechat(href=theme.footer.rss.wechatOA, title="公众号")
2
+ a.rss-plan-item.rss-plan-wechat(href=page.wechatOA, title="公众号")
3
3
  .rss-plan-description 推送精选文章<br>推送全文
4
4
  .rss-plan-info-group
5
5
  .rss-plan-title 公众号订阅
6
6
  .rss-plan-info 推荐的订阅方式
7
7
  img.rss-plan-icon(src="https://bu.dusays.com/2023/11/01/6541d14a4de78.png", alt="wechat")
8
- a.rss-plan-item.rss-plan-mail(href=theme.footer.rss.emailOA, title="email")
8
+ a.rss-plan-item.rss-plan-mail(href=page.emailOA, title="email")
9
9
  .rss-plan-description 推送全部文章<br>推送封面与简介
10
10
  .rss-plan-info-group
11
11
  .rss-plan-title 邮件订阅
12
12
  .rss-plan-info 推荐的订阅方式
13
13
  img.rss-plan-icon(src="https://bu.dusays.com/2023/11/01/6541d16c3ea22.png", alt="email")
14
- a.rss-plan-item.rss-plan-rss(href=theme.footer.rss.rssOA, title="rss")
14
+ a.rss-plan-item.rss-plan-rss(href=page.rssOA, title="rss")
15
15
  .rss-plan-description 推送全部文章<br>推送简介
16
16
  .rss-plan-info-group
17
17
  .rss-plan-title RSS
@@ -1,19 +1,19 @@
1
+ include ../widgets/page/banner
1
2
  if theme.says.enable
2
- include ../widgets/page/banner
3
3
  #bber
4
4
  section.timeline.page-1
5
5
  ul.list#waterfall
6
- - var limitedList = site.data.essay.essay_list.slice(0, 30)
7
- each item in limitedList
8
- li.item
9
- if theme.says.style === 2
10
- include ../widgets/page/says/saysMeta
11
- include ../widgets/page/says/saysContent
12
- include ../widgets/page/says/saysFunction
13
- if theme.says.style === 1
14
- hr
15
- include ../widgets/page/says/saysBottom
16
- #bber-tips - 只展示最近30条短文 -
17
-
18
- script.
19
- sco.reflashEssayWaterFall()
6
+ case theme.says.mode
7
+ when 'local'
8
+ include ../widgets/page/says/local
9
+ when 'json'
10
+ include ../widgets/page/says/json
11
+ when 'memos'
12
+ include ../widgets/page/says/memos
13
+ #bber-tips
14
+ if theme.says.strip === -1
15
+ | - 已展开所有短文 -
16
+ else
17
+ | - 只展示最近 #{theme.says.strip} 条短文 -
18
+ else
19
+ include ./not_configured.pug
File without changes
@@ -1,3 +1,4 @@
1
+ - var item_suffix = ''
1
2
  include ../widgets/page/banner
2
3
  .flink#article-container
3
4
  each data in site.data.tlink.links
File without changes
File without changes
@@ -2,19 +2,19 @@
2
2
  - var noSticky, Sticky, customNoSticky, customSticky;
3
3
  if(is_home())
4
4
  - noSticky = theme.aside.home.noSticky.split(',')
5
- - Sticky = theme.aside.home.Sticky.split(',')
6
5
  - customNoSticky = site.data.aside?.home?.noSticky
7
6
  - customSticky = site.data.aside?.home?.Sticky
7
+ - Sticky = theme.aside.home.Sticky.split(',')
8
8
  else if(is_post())
9
9
  - noSticky = theme.aside.post.noSticky.split(',')
10
- - Sticky = theme.aside.post.Sticky.split(',')
11
10
  - customNoSticky = site.data.aside?.post?.noSticky
12
11
  - customSticky = site.data.aside?.post?.Sticky
12
+ - Sticky = theme.aside.post.Sticky.split(',')
13
13
  else if(is_page() || is_archive() || is_tag() || is_category())
14
14
  - noSticky = theme.aside.page.noSticky.split(',')
15
- - Sticky = theme.aside.page.Sticky.split(',')
16
15
  - customNoSticky = site.data.aside?.page?.noSticky
17
16
  - customSticky = site.data.aside?.page?.Sticky
17
+ - Sticky = theme.aside.page.Sticky.split(',')
18
18
  each item in noSticky
19
19
  include ./asideSwitch.pug
20
20
  if customNoSticky
@@ -23,8 +23,8 @@
23
23
  .sticky_layout
24
24
  if page.toc
25
25
  include ./asideToc.pug
26
- each item in Sticky
27
- include ./asideSwitch.pug
28
26
  if customSticky
29
27
  each item in customSticky
30
- include ./asideCustom.pug
28
+ include ./asideCustom.pug
29
+ each item in Sticky
30
+ include ./asideSwitch.pug
File without changes
File without changes
@@ -2,5 +2,5 @@
2
2
  .item-headline
3
3
  i(class=item.icon)
4
4
  span=item.name
5
- .item-content
5
+ div(class=item.class_content ||'item-content', id=item.id_content, style=item.style_content)
6
6
  != item.html
File without changes
@@ -11,10 +11,10 @@
11
11
  .author-info__description!= theme.aside.card.content
12
12
  .author-info__description2!= theme.aside.card.content2
13
13
  .author-info__bottom-group
14
- a.author-info__bottom-group-left(href=theme.about ? "/about" : "/")
14
+ a.author-info__bottom-group-left(href=theme.about ? "/about/" : "/")
15
15
  .author-info__name= config.author
16
16
  .author-info__desc!= config.subtitle
17
17
  .card-info-social-icons.is-center
18
- each value, key in theme.aside.card.information
18
+ each value, key in theme.aside.card.information || []
19
19
  a.social-icon(href=url_for(value.url), title=key)
20
- i(class=value.icon)
20
+ i.scoicon(class=value.icon)
File without changes
@@ -3,10 +3,6 @@ case item
3
3
  include ./asideInfoCard.pug
4
4
  when 'flip'
5
5
  include ./asideFlipCard.pug
6
- when 'welcome'
7
- include ./asideWelcome.pug
8
- when 'history'
9
- include ./asideHistory.pug
10
6
  when 'newestPost'
11
7
  include ./asideNewestPost.pug
12
8
  when 'allInfo'
@@ -2,7 +2,7 @@
2
2
  each tag in site.tags.find({ parent: { $exists: false } }).data
3
3
  a(href=url_for(tag.path))= tag.name
4
4
  sup= tag.length
5
- if site.tags.length > 50
5
+ if site.tags.length > theme.aside.tags.limit
6
6
  a#more-tags-btn(href="javascript:void(0);", onclick="sco.openAllTags();")= __('aside.tagmore')
7
7
  else
8
8
  style.
File without changes
@@ -5,7 +5,7 @@
5
5
  i.item-icon.scoicon.sco-folder-fill
6
6
  .item-name= __('aside.postcount')
7
7
  .item-count= site.posts.length
8
- if theme.thirdparty.busuanzi
8
+ if theme.busuanzi
9
9
  if theme.aside.siteinfo.pv
10
10
  .webinfo-item
11
11
  .webinfo-item-title
@@ -32,7 +32,7 @@
32
32
  i.item-icon.scoicon.sco-loop-left-fill
33
33
  .item-name= __('aside.updatetime')
34
34
  time.item-count(datetime=new Date())
35
- if theme.thirdparty.wordcount && theme.aside.siteinfo.wordcount
35
+ if theme.wordcount && theme.aside.siteinfo.wordcount
36
36
  .webinfo-item
37
37
  .webinfo-item-title
38
38
  i.item-icon.scoicon.sco-word-fill
File without changes
@@ -0,0 +1,22 @@
1
+ script.
2
+ !async function () {
3
+ const htmlTagRegex = /<[^>]+>/g;
4
+
5
+ await fetch('!{theme.says.mode_link}')
6
+ .then(res => res.json())
7
+ .then(res => {
8
+ let list = res.filter(item => item.content).slice(0, 10);
9
+
10
+ document.querySelector('#bber-talk').innerHTML = list.map(item => {
11
+ let content = item.content ? item.content.replace(htmlTagRegex, '') : '';
12
+ content += item.image ? '<i class="scoicon scp-image-fill"></i>' : '';
13
+ content += item.aplayer ? '<i class="scoicon sco-disc-fill"></i>' : '';
14
+ content += item.video ? '<i class="scoicon sco-video-fill"></i>' : '';
15
+ content += item.bilibili ? '<i class="scoicon sco-bilibili-line"></i>' : '';
16
+ content += item.link ? `<i class="scoicon sco-link"></i>` : '';
17
+ return `<div class="li-style swiper-slide">${content}</div>`;
18
+ }).join('');
19
+
20
+ sco.initbbtalk();
21
+ }).catch(err => console.log('bbtime |', err));
22
+ }();
@@ -0,0 +1,17 @@
1
+ each item, i in site.data.essay.essay_list.slice(0, 10)
2
+ .li-style.swiper-slide
3
+ | #{item.content}
4
+ if item.image
5
+ i.scoicon.sco-image-fill
6
+ if item.aplayer
7
+ i.scoicon.sco-disc-fill
8
+ if item.video
9
+ i.scoicon.sco-video-fill
10
+ if item.bilibili
11
+ i.scoicon.sco-bilibili-line
12
+ if item.link
13
+ i.scoicon.sco-links
14
+ script.
15
+ document.addEventListener('DOMContentLoaded', function () {
16
+ sco.initbbtalk()
17
+ })
@@ -0,0 +1,25 @@
1
+ script.
2
+ !async function () {
3
+ await fetch('!{theme.says.mode_link}')
4
+ .then(response => response.json())
5
+ .then(data => {
6
+ let aplayerRegex = /{aplayer,(.*?),(.*?)}/g;
7
+ let bilibiliRegex = /{bilibili,(.*?)}/g;
8
+ let playerRegex = /{player,(.*?)}/g;
9
+ let linkRegex = /(?<!\!)\[([^\]]*)\]\(([^\)]*)\)/g;
10
+ let imageRegex = /!\[\]\((.*?)\)/g;
11
+ let contentRegex = /#.*?\s([^{\n]*)/g
12
+ const list = data.slice(0, 10)
13
+ document.querySelector('#bber-talk').innerHTML = list.map(item => {
14
+ let content = item.content.match(contentRegex, '$1').map(item => item.replace(contentRegex, '$1'));
15
+ let imageBox = item.content.match(imageRegex) ? '<i class="scoicon sco-image-fill"></i>' : '';
16
+ let aplayer = item.content.match(aplayerRegex) ? '<i class="scoicon sco-disc-fill"></i>' : '';
17
+ let video = item.content.match(playerRegex) ? '<i class="scoicon sco-video-fill"></i>' : item.content.match(bilibiliRegex) ? '<i class="scoicon sco-bilibili-line"></i>' : '';
18
+ let link = item.content.match(linkRegex) ? `<i class="scoicon sco-link"></i>` : '';
19
+
20
+ return `<div class="li-style swiper-slide">${content+aplayer+video+imageBox+link}</div>`
21
+ }).join(' ')
22
+ sco.initbbtalk()
23
+ })
24
+ .catch(error => console.error('bbtime | ', error));
25
+ }()
@@ -1,8 +1,12 @@
1
- .bbTimeList.container#bbTimeList
2
- i.bber-logo.scoicon.sco-bblogo(onclick="pjax.loadUrl('/essay/')")
3
- .swiper-container.swiper-no-swiping.swiper-container-initialized.swiper-container-vertical.swiper-container-pointer-events#bbtalk(tabindex="-1", onclick="pjax.loadUrl('/essay/')")
1
+ .bbTimeList.container#bbTimeList(class=is_home_first_page() ? '' : 'more-page')
2
+ i.bber-logo.scoicon.sco-bblogo(onclick=`pjax.loadUrl('/essay/')`)
3
+ .swiper-container.swiper-no-swiping.swiper-container-initialized.swiper-container-vertical.swiper-container-pointer-events#bbtalk(tabindex="-1" onclick=`pjax.loadUrl('/essay/')`)
4
4
  .swiper-wrapper#bber-talk
5
- each item, i in site.data.essay.essay_list
6
- if i < 10
7
- .li-style.swiper-slide= item.image ? item.content + _p('home.bbtime.image') : item.content
8
- i.bber-gotobb.scoicon.sco-right-btn-fill(title=_p('home.bbtime.text'), onclick="pjax.loadUrl('/essay/')")
5
+ case theme.says.mode
6
+ when 'local'
7
+ include bb/local
8
+ when 'json'
9
+ include bb/json
10
+ when 'memos'
11
+ include bb/memos
12
+ i.bber-gotobb.scoicon.sco-right-btn-fill(title=_p('home.bbtime.text') onclick=`pjax.loadUrl('/essay/')`)
File without changes
@@ -6,4 +6,4 @@ each groupName, index in groupNames
6
6
  .categoryItem(style=`box-shadow: var(${styles[index]});`)
7
7
  a.categoryButton(class=classes[index], href=url_for(theme.hometop.categoryGroup[groupName].url))
8
8
  span.categoryButtonText= theme.hometop.categoryGroup[groupName].name
9
- i(class=theme.hometop.categoryGroup[groupName].icon)
9
+ i.scoicon(class=theme.hometop.categoryGroup[groupName].icon)
File without changes
File without changes
File without changes
File without changes
@@ -9,7 +9,7 @@
9
9
  each childValue, y in value.child
10
10
  li
11
11
  a.site-page.child(href=url_for(childValue.url))
12
- i(class=childValue.icon)
12
+ i.scoicon(class=childValue.icon)
13
13
  span= y
14
14
  else
15
15
  a.site-page.not-child(href=url_for(value.url))
@@ -1,12 +1,13 @@
1
- if theme.nav.right.travellings
2
- .nav-button.only-home#travellings_button
3
- a.site-page(href="https://www.travellings.cn/go.html", title=_p('nav.travellings'), target="_blank")
4
- i.scoicon.sco-train-line
1
+ - var custom = theme.nav.right.custom || []
2
+ each item in custom
3
+ .nav-button(id=item.id)
4
+ a.site-page(href=item.url || 'javascript:void(0);', onclick=item.onclick, title=item.title || '')
5
+ i.scoicon(class=item.icon || '')
5
6
  if theme.nav.right.random
6
7
  .nav-button#randomPost_button
7
8
  a.site-page(onclick="toRandomPost()", title=_p('nav.randompost'), href="javascript:void(0);")
8
9
  i.scoicon.sco-signal-tower-fill
9
- if theme.thirdparty.search.enable
10
+ if theme.search.enable
10
11
  .nav-button#search-button
11
12
  a.site-page.social-icon.search(href="javascript:void(0);", title=_p('nav.search'))
12
13
  i.scoicon.sco-search-line
@@ -1,12 +1,13 @@
1
1
  - const authorinfo = site.data.about.authorinfo
2
2
 
3
- .author-info
4
- .author-tag-left
5
- each tag in authorinfo.leftTags
6
- span.author-tag= tag
7
- .author-img
8
- img(src=authorinfo.image)
9
- .author-tag-right
10
- each tag in authorinfo.rightTags
11
- span.author-tag= tag
3
+ if authorinfo
4
+ .author-info
5
+ .author-tag-left
6
+ each tag in authorinfo.leftTags
7
+ span.author-tag= tag
8
+ .author-img
9
+ img(src=authorinfo.image)
10
+ .author-tag-right
11
+ each tag in authorinfo.rightTags
12
+ span.author-tag= tag
12
13
  .author-title= authorinfo.title
File without changes
@@ -1,38 +1,39 @@
1
1
  - const contentinfo = site.data.about.contentinfo
2
2
 
3
- .author-content
4
- .author-content-item.myInfoAndSayHello
5
- .title1= _p('about.info.title1')
6
- .title2= _p('about.info.title2')
7
- span.inline-word= contentinfo.name
8
- .title1= _p('about.info.title3') + contentinfo.title
9
- .aboutsiteTips.author-content-item
10
- .author-content-item-tips= _p('about.info.tip1')
11
- h2
12
- = _p('about.info.tip2')
13
- br
14
- = _p('about.info.tip3')
15
- span.inline-word= _p('about.info.tip4')
16
- .mask
17
- span.first-tips(data-show='')= contentinfo.product
18
- span= contentinfo.design
19
- span= contentinfo.program
20
- span(data-up='')= contentinfo.user_experience
3
+ if contentinfo
4
+ .author-content
5
+ .author-content-item.myInfoAndSayHello
6
+ .title1= contentinfo.sup
7
+ .title2
8
+ span.inline-word= contentinfo.name
9
+ .title1= contentinfo.title
10
+ .aboutsiteTips.author-content-item
11
+ .author-content-item-tips= contentinfo.tip
12
+ h2
13
+ span.inline-word!= contentinfo.slogan
14
+ .mask
15
+ each item,index in contentinfo.mask
16
+ if index === 0
17
+ span.first-tips(data-show='')= item
18
+ else if index === contentinfo.mask.length - 1
19
+ span(data-up='')= item
20
+ else
21
+ span= item
21
22
 
22
- script.
23
- var pursuitInterval = null;
24
- pursuitInterval = setInterval(function () {
25
- const show = document.querySelector('span[data-show]')
26
- const next = show.nextElementSibling || document.querySelector('.first-tips')
27
- const up = document.querySelector('span[data-up]')
28
- if (up) {
29
- up.removeAttribute('data-up')
30
- }
31
- show.removeAttribute('data-show')
32
- show.setAttribute('data-up', '')
33
- next.setAttribute('data-show', '')
34
- }, 2000)
23
+ script.
24
+ var pursuitInterval = null;
25
+ pursuitInterval = setInterval(function () {
26
+ const show = document.querySelector('span[data-show]')
27
+ const next = show.nextElementSibling || document.querySelector('.first-tips')
28
+ const up = document.querySelector('span[data-up]')
29
+ if (up) {
30
+ up.removeAttribute('data-up')
31
+ }
32
+ show.removeAttribute('data-show')
33
+ show.setAttribute('data-up', '')
34
+ next.setAttribute('data-show', '')
35
+ }, 2000)
35
36
 
36
- document.addEventListener('pjax:send', function(){
37
- clearInterval(pursuitInterval);
38
- });
37
+ document.addEventListener('pjax:send', function () {
38
+ clearInterval(pursuitInterval);
39
+ });
@@ -1,20 +1,24 @@
1
- .author-content
2
- if site.data.about.game1
3
- .author-content-item.game-apex(style=`background: url(${site.data.about.game1.img}) no-repeat top; background-size: cover;`)
4
- .card-content
5
- .author-content-item-tips= site.data.about.game1.title
6
- span.author-content-item-title= site.data.about.game1.subtitle
7
- .content-bottom
8
- .tips= site.data.about.game1.tips_left
9
- .tips= site.data.about.game1.tips_right
10
- if site.data.about.game2
11
- .author-content-item.game-jl(style=`background: url(${site.data.about.game2.img}) no-repeat top; background-size: cover;`)
12
- .card-content
13
- .author-content-item-tips= site.data.about.game2.title
14
- span.author-content-item-title= site.data.about.game2.subtitle
15
- .content-bottom
16
- .tips= site.data.about.game2.tips_left
17
- .tips= site.data.about.game2.tips_right
1
+ - var game1 = game1
2
+ - var game2 = game2
3
+
4
+ if game1 || game2
5
+ .author-content
6
+ if game1
7
+ .author-content-item.game-apex(style=`background: url(${game1.img}) no-repeat top; background-size: cover;`)
8
+ .card-content
9
+ .author-content-item-tips= game1.title
10
+ span.author-content-item-title= game1.subtitle
11
+ .content-bottom
12
+ .tips= game1.tips_left
13
+ .tips= game1.tips_right
14
+ if game2
15
+ .author-content-item.game-jl(style=`background: url(${game2.img}) no-repeat top; background-size: cover;`)
16
+ .card-content
17
+ .author-content-item-tips= game2.title
18
+ span.author-content-item-title= game2.subtitle
19
+ .content-bottom
20
+ .tips= game2.tips_left
21
+ .tips= game2.tips_right
18
22
 
19
23
  if site.data.about.likes
20
24
  - const likes = site.data.about.likes