hexo-theme-solitude 2.1.3 → 2.1.5

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 (39) hide show
  1. package/README.md +25 -39
  2. package/{README_zh-Hans.md → README_en-US.md} +25 -39
  3. package/README_zh-Hant.md +5 -19
  4. package/_config.yml +28 -28
  5. package/languages/default.yml +2 -0
  6. package/languages/en.yml +2 -0
  7. package/languages/zh-CN.yml +2 -0
  8. package/languages/zh-TW.yml +2 -0
  9. package/layout/includes/footer.pug +30 -29
  10. package/layout/includes/head/config.pug +2 -1
  11. package/layout/includes/keyboard.pug +2 -1
  12. package/layout/includes/widgets/aside/asideInfoCard.pug +2 -2
  13. package/layout/includes/widgets/home/topGroup.pug +15 -13
  14. package/layout/includes/widgets/rightside/hide.pug +4 -1
  15. package/layout/includes/widgets/rightside/show.pug +3 -0
  16. package/layout/includes/widgets/third-party/music.pug +3 -3
  17. package/layout/includes/widgets/third-party/search/algolia-search.pug +3 -0
  18. package/layout/post.pug +2 -1
  19. package/package.json +1 -1
  20. package/plugins.yml +7 -7
  21. package/scripts/event/merge_config.js +1 -0
  22. package/scripts/event/page.js +3 -3
  23. package/scripts/filter/default.js +3 -1
  24. package/scripts/tags/typeit.js +2 -3
  25. package/source/css/_global/function.styl +4 -0
  26. package/source/css/_global/index.styl +8 -0
  27. package/source/css/_layout/aside.styl +2 -2
  28. package/source/css/_layout/capsule.styl +228 -217
  29. package/source/css/_page/_home/category-bar.styl +1 -0
  30. package/source/css/_page/_home/home.styl +5 -0
  31. package/source/css/_page/links.styl +16 -2
  32. package/source/css/_post/pagination.styl +1 -1
  33. package/source/css/_search/algolia-search.styl +23 -16
  34. package/source/css/_search/local-search.styl +11 -11
  35. package/source/css/_tags/gallery.styl +0 -1
  36. package/source/js/main.js +42 -13
  37. package/source/js/right_menu.js +2 -2
  38. package/source/js/search/algolia.js +16 -15
  39. package/source/js/search/local.js +11 -14
package/plugins.yml CHANGED
@@ -1,11 +1,11 @@
1
1
  algolia_search:
2
2
  name: algoliasearch
3
- file: dist/algoliasearch-lite.umd.js
4
- version: 4.24.0
3
+ file: dist/algoliasearch.umd.js
4
+ version: 5.9.1
5
5
  instantsearch:
6
6
  name: instantsearch.js
7
7
  file: dist/instantsearch.production.min.js
8
- version: 4.73.3
8
+ version: 4.74.1
9
9
  pjax:
10
10
  name: pjax
11
11
  file: pjax.min.js
@@ -18,11 +18,11 @@ waline_js:
18
18
  name: '@waline/client'
19
19
  file: dist/waline.js
20
20
  other_name: waline
21
- version: 3.3.0
21
+ version: 3.3.1
22
22
  waline_css:
23
23
  name: '@waline/client'
24
24
  file: dist/waline.css
25
- version: 3.3.0
25
+ version: 3.3.1
26
26
  other_name: waline
27
27
  valine:
28
28
  name: valine
@@ -31,11 +31,11 @@ valine:
31
31
  artalk_css:
32
32
  name: artalk
33
33
  file: dist/Artalk.css
34
- version: 2.8.7
34
+ version: 2.9.0
35
35
  artalk_js:
36
36
  name: artalk
37
37
  file: dist/Artalk.js
38
- version: 2.8.7
38
+ version: 2.9.0
39
39
  katex:
40
40
  name: katex
41
41
  file: dist/katex.min.css
@@ -231,6 +231,7 @@ hexo.extend.filter.register('before_generate', () => {
231
231
  id: '8407304077',
232
232
  server: 'netease',
233
233
  type: 'playlist',
234
+ volume: 0.8,
234
235
  },
235
236
  keyboard: {
236
237
  enable: false,
@@ -5,7 +5,7 @@ hexo.extend.generator.register('404', function (locals) {
5
5
  layout: ['404'],
6
6
  data: {
7
7
  type: '404',
8
- comment: false
8
+ comment: false,
9
9
  }
10
10
  }
11
11
  })
@@ -16,7 +16,7 @@ hexo.extend.generator.register('tags', function(locals) {
16
16
  layout: ['page'],
17
17
  data: {
18
18
  type: 'tags',
19
- comment: false
19
+ comment: false,
20
20
  }
21
21
  };
22
22
  });
@@ -27,7 +27,7 @@ hexo.extend.generator.register('categories', function(locals) {
27
27
  layout: ['page'],
28
28
  data: {
29
29
  type: 'categories',
30
- comment: false
30
+ comment: false,
31
31
  }
32
32
  };
33
33
  });
@@ -11,7 +11,8 @@ hexo.extend.filter.register('after_post_render', function (data) {
11
11
  data.cover = data.cover || cover[getRandomInt(0, cover?.length)]
12
12
  data.excerpt = data.description || data.excerpt
13
13
  data.toc = !!(config.aside.toc.post && data.toc !== false)
14
- data.ai = data.ai !== false
14
+ data.ai = data.ai !== false;
15
+ data.aside = data.aside || true;
15
16
  }
16
17
  if (data.layout === 'page') {
17
18
  let {cover} = hexo.theme.config.page.default
@@ -19,6 +20,7 @@ hexo.extend.filter.register('after_post_render', function (data) {
19
20
  data.cover = data.cover || cover[getRandomInt(0, cover?.length)]
20
21
  data.excerpt = data.title
21
22
  data.toc = !!(config.aside.toc.page && data.toc !== false && data.aside);
23
+ data.aside = data.aside || false;
22
24
  }
23
25
  data.comment = !!(config.comment.use && data.comment !== false);
24
26
  return data;
@@ -4,7 +4,7 @@
4
4
 
5
5
  'use strict'
6
6
 
7
- const typeit = ([tag, options], content) => {
7
+ const typeit = ([tag], content) => {
8
8
  const id = Math.random().toString(36).substr(2, 9);
9
9
  tag = tag || 'div';
10
10
  return `
@@ -15,8 +15,7 @@ const typeit = ([tag, options], content) => {
15
15
  const typeit = () => {
16
16
  const ctx = document.getElementById("typeit-${id}");
17
17
  if (!ctx) return;
18
- new TypeIt("#typeit-${id}", ${options})
19
- .type("${content}")
18
+ new TypeIt("#typeit-${id}", {${content}})
20
19
  .go();
21
20
  }
22
21
  document.addEventListener("DOMContentLoaded", typeit);
@@ -54,6 +54,10 @@ maxWidth1024()
54
54
  @media screen and (max-width: 1024px)
55
55
  {block}
56
56
 
57
+ maxWidth1199()
58
+ @media screen and (max-width: 1199px)
59
+ {block}
60
+
57
61
  maxWidth1200()
58
62
  @media screen and (max-width: 1200px)
59
63
  {block}
@@ -362,16 +362,24 @@ i.solitude
362
362
  line-height 1
363
363
  font-synthesis style
364
364
 
365
+ #body-wrap
366
+ display: flex
367
+ flex-direction: column
368
+ min-height: 100vh
369
+ justify-content: space-between
370
+
365
371
  .layout
366
372
  display: flex
367
373
  margin: 0 auto
368
374
  padding: 0 1.5rem
375
+ width 100%
369
376
  max-width: 1200px
370
377
  +maxWidth768()
371
378
  padding 0
372
379
 
373
380
  &#content-inner
374
381
  max-width: 1400px
382
+ flex-grow: 1
375
383
 
376
384
  /.hide-aside.layout
377
385
  max-width: 1400px
@@ -6,13 +6,13 @@
6
6
  else
7
7
  order 2
8
8
 
9
- +minWidth900()
9
+ +minWidth1200()
10
10
  if hexo-config('aside.position') == 0
11
11
  padding-right 15px
12
12
  else
13
13
  padding-left 15px
14
14
 
15
- +maxWidth1200()
15
+ +maxWidth1199()
16
16
  .card-widget:not(#card-toc)
17
17
  display: none
18
18
 
@@ -1,218 +1,229 @@
1
1
  if hexo-config('capsule.enable')
2
- #nav-music
3
- display flex
4
- align-items center
5
- z-index 11
6
- position fixed
7
- bottom 20px
8
- left 20px
9
- cursor pointer
10
- transition .3s
11
- transform-origin left bottom
12
- box-shadow var(--efu-shadow-border)
13
- border-radius 40px
14
- overflow hidden
15
- user-select none
16
-
17
- +maxWidth798()
18
- display none !important
19
-
20
- span
21
- user-select none
22
-
23
- div
24
- user-select none
25
-
26
- &.playing
27
- box-shadow 0 0 12px -3px var(--efu-none)
28
- -webkit-animation playingShadow 5s linear infinite
29
-
30
- .aplayer
31
- background var(--efu-main-op-deep)
32
- border var(--style-border-hover)
33
- backdrop-filter saturate(180%) blur(20px)
34
- -webkit-backdrop-filter blur(20px)
35
- transform translateZ(0)
36
-
37
- &.aplayer-withlrc
38
- .aplayer-pic
39
- box-shadow 0 0 14px #ffffffa6
40
- -webkit-transform rotate(0) scale(1.1)
41
- border-color var(--efu-white)
42
- animation-play-state running
43
-
44
- .aplayer-info
45
- color var(--efu-white)
46
-
47
- .aplayer-lrc
48
- width 200px
49
- margin-bottom 0
50
- opacity 1
51
-
52
- .aplayer-info
53
- .aplayer-controller
54
- .aplayer-bar-wrap
55
- .aplayer-bar
56
- opacity 1
57
-
58
- .aplayer-played
59
- animation-play-state running
60
- height: 100%;
61
- opacity: .1;
62
- background-color: var(--efu-white) !important;
63
- animation: lightBar 5s ease infinite;
64
- animation-play-state: paused;
65
-
66
- #nav-music-hoverTips
67
- opacity 0
68
-
69
- .aplayer
70
- background var(--efu-card-bg)
71
- border-radius 60px
72
- height 41px
73
- display flex
74
- margin 0
75
- pointer-events none
76
- transition .3s
77
- border var(--style-border)
78
- box-shadow none
79
-
80
- &.aplayer-withlrc
81
- .aplayer-pic
82
- height 25px
83
- width 25px
84
- border-radius 40px
85
- z-index 1
86
- transition .3s
87
- -webkit-transform rotate(0) scale(1)
88
- border var(--style-border-always)
89
- -webkit-animation changeright 24s linear infinite
90
- animation-play-state paused
91
-
92
- .aplayer-info
93
- height 100%
94
- color var(--efu-fontcolor)
95
- margin-left 8px
96
- padding 0
97
- display flex
98
- align-items center
99
-
100
- .aplayer-lrc
101
- width 0
102
- opacity 0
103
- transition .3s
104
- margin-left 8px
105
- margin-top -2px
106
-
107
- .aplayer-notice
108
- display none
109
-
110
- .aplayer-miniswitcher
111
- display none
112
-
113
- .aplayer-body
114
- position relative
115
- display flex
116
- align-items center
117
- padding 0 12px 0 8px
118
-
119
- .aplayer-pic
120
- .aplayer-play
121
- opacity 0
122
-
123
- div
124
- display none
125
-
126
- .aplayer-info
127
- .aplayer-music
128
- margin 0
129
- display flex
130
- align-items center
131
- padding 0
132
- z-index 1
133
-
134
- .aplayer-author
135
- display none
136
-
137
- .aplayer-title
138
- cursor pointer
139
- line-height 1
140
- display inline-block
141
- white-space nowrap
142
- max-width 120px
143
- overflow hidden
144
- text-overflow ellipsis
145
- transition .3s
146
-
147
- .aplayer-controller
148
- position absolute
149
- width 100%
150
- height 100%
151
- top 0
152
- left 0
153
-
154
- .aplayer-time
155
- display none
156
-
157
- .aplayer-bar-wrap
158
- margin 0
159
- padding 0
160
-
161
- .aplayer-bar
162
- height 100%
163
- background 0 0
164
- opacity 0
165
-
166
- .aplayer-loaded
167
- display none
168
-
169
- .aplayer-played
170
- height 100%
171
- opacity .1
172
- background-color var(--efu-white) !important
173
- -webkit-animation lightBar 5s ease infinite
174
- animation-play-state paused
175
-
176
- &.aplayer-withlist
177
- .aplayer-info
178
- border none
179
-
180
- .aplayer-lrc
181
- p
182
- color #ffffffb3
183
- filter blur(1px)
184
-
185
- &.aplayer-lrc-current
186
- color var(--efu-white)
187
- border none
188
- filter blur(0)
189
-
190
- #nav-music-hoverTips
191
- color var(--efu-white)
192
- background var(--efu-main)
193
- width 100%
194
- height 100%
195
- position absolute
196
- top 0
197
- left 0
198
- align-items center
199
- justify-content center
200
- display flex
201
- border-radius 40px
202
- opacity 0
203
- font-size 12px
204
- z-index 2
205
- pointer-events none
206
- transition .3s
207
-
208
- &:hover
209
- &:not(.playing)
210
- #nav-music-hoverTips
211
- opacity 1
212
-
213
- .aplayer-list
214
- display none
215
-
216
- #nav-music .aplayer .aplayer-lrc:after,
217
- #nav-music .aplayer .aplayer-lrc:before
218
- display none
2
+ @keyframes changeright
3
+ 0%, 50%, 100%
4
+ transform: rotate(0deg) scale(1.1)
5
+ box-shadow: 0 0 2px #ffffff00
6
+ 25%, 75%
7
+ transform: rotate(90deg) scale(1.1)
8
+ box-shadow: 0 0 14px #ffffff
9
+
10
+ @keyframes playingShadow
11
+ 0%, 100%
12
+ box-shadow: 0 0px 12px -3px var(--efu-none)
13
+ 50%
14
+ box-shadow: 0 0px 12px 0px var(--efu-main)
15
+
16
+ @keyframes lightBar
17
+ 0%, 100%
18
+ opacity: 0.1
19
+ 60%
20
+ opacity: 0.3
21
+
22
+ .aplayer.aplayer-narrow
23
+ .aplayer-body,
24
+ .aplayer-pic
25
+ height: 66px
26
+ width: 66px
27
+
28
+ #nav-music
29
+ display: flex
30
+ align-items: center
31
+ z-index: 12
32
+ position: fixed
33
+ bottom: 20px
34
+ left: 20px
35
+ cursor: pointer
36
+ transition: all 0.5s, left 0s
37
+ transform-origin: left bottom
38
+ box-shadow: var(--efu-shadow-border)
39
+ border-radius: 40px
40
+ overflow: hidden
41
+
42
+ &:active
43
+ transform: scale(0.97)
44
+
45
+ &.playing
46
+ border: var(--style-border)
47
+ box-shadow: 0 0px 12px -3px var(--efu-none)
48
+ animation: playingShadow 5s linear infinite
49
+
50
+ .aplayer.aplayer-withlrc
51
+ .aplayer-pic
52
+ box-shadow: 0 0 14px #ffffffa6
53
+ transform: rotate(0deg) scale(1.1)
54
+ border-color: var(--efu-white)
55
+ animation-play-state: running
56
+
57
+ .aplayer-info
58
+ color: var(--efu-white)
59
+
60
+ #nav-music-hoverTips
61
+ width: 0
62
+
63
+ .aplayer
64
+ background: var(--efu-main)
65
+ border: var(--style-border-hover)
66
+ backdrop-filter: saturate(180%) blur(20px)
67
+ transform: translateZ(0)
68
+
69
+ .aplayer .aplayer-info .aplayer-controller .aplayer-bar-wrap .aplayer-bar .aplayer-played
70
+ animation-play-state: running
71
+
72
+ &:hover:not(.playing) #nav-music-hoverTips
73
+ opacity: 1
74
+
75
+ .aplayer.aplayer-withlrc
76
+ .aplayer-pic
77
+ height: 25px
78
+ width: 25px
79
+ border-radius: 40px
80
+ z-index: 1
81
+ transition: 0.3s
82
+ transform: rotate(0deg) scale(1)
83
+ border: var(--style-border-always)
84
+ animation: changeright 24s linear infinite
85
+ animation-play-state: paused
86
+
87
+ .aplayer-info
88
+ height: 100%
89
+ color: var(--efu-fontcolor)
90
+ margin: 0
91
+ padding: 0
92
+ display: flex
93
+ align-items: center
94
+
95
+ #nav-music-hoverTips
96
+ color: var(--efu-white)
97
+ background: var(--efu-main)
98
+ width: 100%
99
+ height: 100%
100
+ position: absolute
101
+ top: 0
102
+ left: 0
103
+ align-items: center
104
+ justify-content: center
105
+ display: flex
106
+ border-radius: 40px
107
+ opacity: 0
108
+ font-size: 12px
109
+ z-index: 2
110
+ transition: 0.3s
111
+
112
+ .aplayer
113
+ background: var(--efu-card-bg)
114
+ border-radius: 60px
115
+ height: 41px
116
+ display: flex
117
+ margin: 0
118
+ transition: 0.3s
119
+ border: var(--style-border)
120
+ box-shadow: none
121
+
122
+ .aplayer-notice,
123
+ .aplayer-miniswitcher,
124
+ .aplayer-list
125
+ display: none
126
+
127
+ .aplayer-body
128
+ position: relative
129
+ display: flex
130
+ align-items: center
131
+
132
+ .aplayer-info
133
+ .aplayer-music
134
+ margin: 0
135
+ display: flex
136
+ align-items: center
137
+ padding: 0 12px 0 8px
138
+ cursor: pointer
139
+ z-index: 1
140
+ height: 100%
141
+
142
+ .aplayer-title
143
+ cursor: pointer
144
+ line-height: 1
145
+ display: inline-block
146
+ white-space: nowrap
147
+ max-width: 120px
148
+ overflow: hidden
149
+ text-overflow: ellipsis
150
+ transition: 0.3s
151
+ user-select: none
152
+
153
+ .aplayer-controller
154
+ position: absolute
155
+ width: 100%
156
+ height: 100%
157
+ top: 0
158
+ left: 0
159
+
160
+ .aplayer-bar-wrap
161
+ margin: 0
162
+ padding: 0
163
+
164
+ .aplayer-bar
165
+ height: 100%
166
+ background: 0 0
167
+
168
+ .aplayer-loaded
169
+ display: none
170
+
171
+ .aplayer-played
172
+ height: 100%
173
+ opacity: 0.1
174
+ background-color: var(--efu-white) !important
175
+ animation: lightBar 5s ease infinite
176
+ animation-play-state: paused
177
+
178
+ .aplayer-pic
179
+ pointer-events: none
180
+
181
+ .aplayer-button
182
+ bottom: 50%
183
+ right: 50%
184
+ transform: translate(50%, 50%)
185
+ margin: 0
186
+ transition: 0.3s
187
+ pointer-events all
188
+
189
+ &:has(.aplayer-button.aplayer-play)
190
+ animation-play-state: paused
191
+ transform: rotate(0deg) scale(1) !important
192
+
193
+ margin-left: 8px
194
+
195
+ .aplayer-info .aplayer-controller .aplayer-time,
196
+ .aplayer-info .aplayer-music .aplayer-author
197
+ display: none
198
+
199
+ &.aplayer-withlist .aplayer-info
200
+ border: none
201
+
202
+ .aplayer-lrc
203
+ width: 0
204
+ opacity: 0
205
+ transition: 0.3s
206
+ margin-bottom: -15px
207
+
208
+ p.aplayer-lrc-current
209
+ color: var(--efu-white)
210
+ border: none
211
+ min-height: 20px
212
+ filter: none
213
+
214
+ &:after,
215
+ &:before
216
+ display: none
217
+
218
+ p
219
+ color: #ffffffb3
220
+ filter: blur(.8px)
221
+
222
+ &.stretch .aplayer.aplayer-withlrc .aplayer-lrc
223
+ width: 200px
224
+ margin-left: 8px
225
+ opacity: 1
226
+
227
+ .aplayer-thumb
228
+ width: 0!important
229
+ height: 0!important
@@ -66,6 +66,7 @@
66
66
  border-radius 8px
67
67
  align-items center
68
68
  height 30px
69
+ scrollbar-width: none
69
70
  +maxWidth768()
70
71
  height 44px
71
72
  gap 6px
@@ -1,6 +1,7 @@
1
1
  if hexo-config('hometop.enable') || hexo-config('says.enable')
2
2
  #home_top
3
3
  max-width 1400px
4
+ width 100%
4
5
  margin 0 auto
5
6
  padding .5rem 1.5rem
6
7
 
@@ -19,9 +20,13 @@ if hexo-config('carousel')
19
20
  if hexo-config('aside.position') == 0
20
21
  #home
21
22
  order 2
23
+ #page
24
+ order 2
22
25
  else
23
26
  #home
24
27
  order 1
28
+ #page
29
+ order 1
25
30
 
26
31
  if hexo-config('comment.hot_tip.enable')
27
32
  @import "hot-tip.styl"