hexo-theme-solitude 1.12.1 → 1.12.3

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.
@@ -1,7 +1,8 @@
1
1
  # These are supported funding model platforms
2
2
 
3
- github: [everfu] # Replace with up to 4 GitHub Sponsors-enabled usernames e.g., [user1, user2]
3
+ github: # Replace with up to 4 GitHub Sponsors-enabled usernames e.g., [user1, user2]
4
4
  patreon: everfu # Replace with a single Patreon username
5
+ polar: everfu
5
6
  open_collective: # Replace with a single Open Collective username
6
7
  ko_fi: # Replace with a single Ko-fi username
7
8
  tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel
@@ -10,4 +11,4 @@ liberapay: # Replace with a single Liberapay username
10
11
  issuehunt: # Replace with a single IssueHunt username
11
12
  otechie: # Replace with a single Otechie username
12
13
  lfx_crowdfunding: # Replace with a single LFX Crowdfunding project-name e.g., cloud-foundry
13
- custom: ['https://afdian.net/a/everfu', 'https://s3.qjqq.cn/47/66374315ebd08.webp!color', 'https://s3.qjqq.cn/47/663742bac8e52.webp!color'] # Replace with up to 4 custom sponsorship URLs e.g., ['link1', 'link2']
14
+ custom: [https://afdian.net/a/everfu] # Replace with up to 4 custom sponsorship URLs e.g., ['link1', 'link2']
package/README.md CHANGED
@@ -10,6 +10,8 @@
10
10
 
11
11
  主题设计由 [@张洪Heo](https://github.com/zhheo) 全权授权
12
12
 
13
+ <a href="https://polar.sh/everfu"><img src="https://polar.sh/embed/seeks-funding-shield.svg?org=everfu" /></a>
14
+
13
15
  ![npm package](https://img.shields.io/npm/v/hexo-theme-solitude?logo=npm)
14
16
  ![release](https://img.shields.io/github/package-json/v/valor-x/hexo-theme-solitude/master?color=%231ab1ad&label=release)
15
17
  ![license](https://img.shields.io/github/license/valor-x/hexo-theme-solitude?color=FF5531)
@@ -47,7 +49,9 @@
47
49
 
48
50
  ## Todo
49
51
 
50
- - [x] 首页顶部新样式
52
+ - [x] 首页顶部新样式
53
+ - [x] 首页文章列表三列显示
54
+ - [x] btns 外挂标签
51
55
 
52
56
  > 如有问题请提 [issue](https://github.com/everfu/hexo-theme-solitude/issues)
53
57
 
package/README_en-US.md CHANGED
@@ -10,6 +10,8 @@
10
10
 
11
11
  Theme design is fully licensed by [@张洪Heo](https://github.com/zhheo).
12
12
 
13
+ <a href="https://polar.sh/everfu"><img src="https://polar.sh/embed/seeks-funding-shield.svg?org=everfu" /></a>
14
+
13
15
  ![npm package](https://img.shields.io/npm/v/hexo-theme-solitude?logo=npm)
14
16
  ![release](https://img.shields.io/github/package-json/v/valor-x/hexo-theme-solitude/master?color=%231ab1ad&label=release)
15
17
  ![license](https://img.shields.io/github/license/valor-x/hexo-theme-solitude?color=FF5531)
@@ -47,8 +49,8 @@
47
49
 
48
50
  ## Todo
49
51
 
50
- - [x] New style at the top of the home page
51
- - [x] Article sharing button
52
+ - [x] The list of articles is displayed in three columns on the homepage.
53
+ - [x] btns tags plugin.
52
54
 
53
55
  > If you have any questions, please issue an [issue](https://github.com/everfu/hexo-theme-solitude/issues)
54
56
 
package/README_zh-Hant.md CHANGED
@@ -10,6 +10,8 @@
10
10
 
11
11
  主題設計由 [@张洪Heo](https://github.com/zhheo)全權授權
12
12
 
13
+ <a href="https://polar.sh/everfu"><img src="https://polar.sh/embed/seeks-funding-shield.svg?org=everfu" /></a>
14
+
13
15
  ![npm package](https://img.shields.io/npm/v/hexo-theme-solitude?logo=npm)
14
16
  ![release](https://img.shields.io/github/package-json/v/valor-x/hexo-theme-solitude/master?color=%231ab1ad&label=release)
15
17
  ![license](https://img.shields.io/github/license/valor-x/hexo-theme-solitude?color=FF5531)
@@ -47,8 +49,8 @@
47
49
 
48
50
  ## Todo
49
51
 
50
- - [x] 首頁頂部新樣式
51
- - [x] 文章分享按钮
52
+ - [x] 首页文章列表三列显示
53
+ - [x] btns 外挂标签
52
54
 
53
55
  ## 應用
54
56
 
package/_config.yml CHANGED
@@ -308,6 +308,7 @@ aside:
308
308
  # Configure information on the home page
309
309
  index_post_list:
310
310
  direction: column # row / column
311
+ column: 2 #2:2列 3:3列
311
312
  content: false # 1: post.description / 2: 自动获取description或截取内容(Automatically get descriptions or screenshots) / 3: 只使用截取内容(Use only screenshots) / false: 不显示内容(No content is displayed)
312
313
  length: 500 # 截取内容的长度 : The length of the screenshot content
313
314
  cover: both # left: 在左侧 : left / right: 在右侧 : right / both: 两侧 : both
package/layout/404.pug CHANGED
@@ -19,6 +19,6 @@ block content
19
19
  break
20
20
  .aside-list-item
21
21
  a.thumbnail(href=url_for(post.path), title=post.title)
22
- img(src=post.cover, alt=post.title)
22
+ img(src=url_for(post.cover), alt=post.title)
23
23
  .content
24
24
  a.title(href=url_for(post.path), title=post.title)= post.title
@@ -122,6 +122,16 @@
122
122
  }
123
123
  }
124
124
 
125
+ let highlight = false
126
+ if (theme.highlight.enable) {
127
+ highlight = {
128
+ limit: theme.highlight.limit,
129
+ expand: theme.highlight.expand,
130
+ copy: theme.highlight.copy,
131
+ syntax: config.syntax_highlighter
132
+ }
133
+ }
134
+
125
135
  script.
126
136
  const GLOBAL_CONFIG = {
127
137
  root: '!{config.root}',
@@ -133,13 +143,7 @@ script.
133
143
  error: '!{theme.lazyload.errorimg}'
134
144
  },
135
145
  copyright: !{copyright},
136
- highlight: {
137
- enable: !{theme.highlight.enable},
138
- limit: !{theme.highlight.limit},
139
- expand: !{theme.highlight.expand},
140
- copy: !{theme.highlight.copy},
141
- syntax: '!{config.syntax_highlighter}'
142
- },
146
+ highlight: !{highlight ? JSON.stringify(highlight) : false},
143
147
  randomlink: !{theme.footer.randomlink},
144
148
  lang: !{JSON.stringify(lang)},
145
149
  aside: {
@@ -27,12 +27,10 @@ include ../head/opengraph.pug
27
27
  include ../head/pwa.pug
28
28
 
29
29
  script.
30
- console.log(
31
- "%c Program: Hexo %c Theme: Solitude %c Version: v1.12.1",
32
- "border-radius:5px 0 0 5px;padding: 5px 10px;color:white;background:#ff3842;",
33
- "padding: 5px 10px;color:white;background:#3e9f50;",
34
- "padding: 5px 10px;color:white;background:#0084ff;border-radius:0 5px 5px 0",
35
- )
30
+ console.log(' %c Solitude %c ' + '!{packageVersion()}' + ' %c https://github.com/everfu/hexo-theme-solitude',
31
+ 'background:#35495e ; padding: 1px; border-radius: 3px 0 0 3px; color: #fff',
32
+ 'background:#ff9a9a ; padding: 1px; border-radius: 0 3px 3px 0; color: #fff',
33
+ 'background:unset ; padding: 1px; border-radius: 0 3px 3px 0; color: #fff')
36
34
 
37
35
  if theme.memorial.enable
38
36
  script.
@@ -5,7 +5,7 @@ each post in page.posts.find({ parent: { $exists: false } }).data
5
5
  .article-sort-item.year #{year}
6
6
  .article-sort-item
7
7
  a.article-sort-item-img(href=url_for(post.path) title=post.title)
8
- img(src=post.cover alt=post.title)
8
+ img(src=url_for(post.cover) alt=post.title)
9
9
  .article-sort-item-info
10
10
  a.article-sort-item-title(href=url_for(post.path) title=post.title onclick="window.event.cancelBubble=true;") #{post.title}
11
11
  .article-sort-item-tags
@@ -8,7 +8,7 @@
8
8
  if index <= 5
9
9
  .aside-list-item
10
10
  a.thumbnail(href=url_for(post.path) title=post.title)
11
- img(alt=post.title src=post.cover)
11
+ img(alt=post.title src=url_for(post.cover))
12
12
  .content
13
13
  a.title(href=url_for(post.path) title=post.title)= post.title
14
14
  if post.categories.data[0]
@@ -5,7 +5,7 @@
5
5
  .post_cover
6
6
  a(href=url_for(post.path), title=post.title)
7
7
  span.recent-post-top-text= _p('home.recommend')
8
- img.post_bg(alt=post.title, src=post.cover)
8
+ img.post_bg(alt=post.title, src=url_for(post.cover))
9
9
  .recent-post-info
10
10
  a.article-title(href=url_for(post.path), title=post.title)= post.title
11
11
 
@@ -1,82 +1,83 @@
1
1
  - var tj = site.data.about.tj
2
2
  - var oneself = site.data.about.oneself
3
3
 
4
- .author-content
5
- if tj
6
- .about-statistic.author-content-item(style=`background: url(${tj.img});`)
7
- .card-content
8
- .author-content-item-tips=_p('about.other.tj.tip')
9
- span.author-content-item-title=_p('about.other.tj.title')
10
- #statistic
11
- .post-tips
12
- = _p('about.other.tj.post_tip')
13
- case tj.provider
14
- when '51la'
15
- a(href="https://v6.51.la/") 51la网站统计
16
- when 'baidu'
17
- a(href="https://tongji.baidu.com/") 百度统计
18
- if tj.button
19
- .banner-button-group
20
- a.banner-button(href=url_for(tj.button_link))
21
- i.solitude.st-right-btn-fill
22
- span.banner-button-text= tj.button_text
4
+ if tj || oneself
5
+ .author-content
6
+ if tj
7
+ .about-statistic.author-content-item(style=`background: url(${tj.img});`)
8
+ .card-content
9
+ .author-content-item-tips=_p('about.other.tj.tip')
10
+ span.author-content-item-title=_p('about.other.tj.title')
11
+ #statistic
12
+ .post-tips
13
+ = _p('about.other.tj.post_tip')
14
+ case tj.provider
15
+ when '51la'
16
+ a(href="https://v6.51.la/") 51la网站统计
17
+ when 'baidu'
18
+ a(href="https://tongji.baidu.com/") 百度统计
19
+ if tj.button
20
+ .banner-button-group
21
+ a.banner-button(href=url_for(tj.button_link))
22
+ i.solitude.st-right-btn-fill
23
+ span.banner-button-text= tj.button_text
23
24
 
24
- case tj.provider
25
- when '51la'
26
- script.
27
- fetch("#{tj.url}")
28
- .then(res => res.text())
29
- .then(data => {
30
- const title = ["最近活跃", "今日人数", "今日访问", "昨日人数", "昨日访问", "本月访问", "总访问量"];
31
- let num = data.match(/(<\/span><span>).*?(\/span><\/p>)/g);
32
- num = num.map(el => {
33
- let val = el.replace(/(<\/span><span>)/g, "");
34
- return val.replace(/(<\/span><\/p>)/g, "");
25
+ case tj.provider
26
+ when '51la'
27
+ script.
28
+ fetch("#{tj.url}")
29
+ .then(res => res.text())
30
+ .then(data => {
31
+ const title = ["最近活跃", "今日人数", "今日访问", "昨日人数", "昨日访问", "本月访问", "总访问量"];
32
+ let num = data.match(/(<\/span><span>).*?(\/span><\/p>)/g);
33
+ num = num.map(el => {
34
+ let val = el.replace(/(<\/span><span>)/g, "");
35
+ return val.replace(/(<\/span><\/p>)/g, "");
36
+ });
37
+ const s = document.getElementById("statistic");
38
+ let html = '';
39
+ for (let i = 0; i < num.length; i++) {
40
+ if (i === 0 || i === num.length - 1) continue;
41
+ html += `<div><span>${title[i]}</span><span id="${title[i]}">${num[i]}</span></div>`;
42
+ }
43
+ s.innerHTML = html;
35
44
  });
36
- const s = document.getElementById("statistic");
37
- let html = '';
38
- for (let i = 0; i < num.length; i++) {
39
- if (i === 0 || i === num.length - 1) continue;
40
- html += `<div><span>${title[i]}</span><span id="${title[i]}">${num[i]}</span></div>`;
41
- }
42
- s.innerHTML = html;
43
- });
44
- when 'baidu'
45
- script.
46
- fetch("#{tj.url}")
47
- .then(res => res.json())
48
- .then(data => {
49
- const title = {"today_uv": "今日人数", "today_pv": "今日访问", "yesterday_uv": "昨日人数", "yesterday_pv": "昨日访问", "last_month_pv": "最近月访问", "last_year_pv": "最近年访问"};
45
+ when 'baidu'
46
+ script.
47
+ fetch("#{tj.url}")
48
+ .then(res => res.json())
49
+ .then(data => {
50
+ const title = {"today_uv": "今日人数", "today_pv": "今日访问", "yesterday_uv": "昨日人数", "yesterday_pv": "昨日访问", "last_month_pv": "最近月访问", "last_year_pv": "最近年访问"};
50
51
 
51
- let s = document.getElementById("statistic");
52
+ let s = document.getElementById("statistic");
52
53
 
53
- for (let key in data) {
54
- if (data.hasOwnProperty(key) && title[key]) {
55
- s.innerHTML += `<div><span>${title[key]}</span><span id="${key}">${data[key]}</span></div>`;
56
- }
57
- }
58
- });
54
+ for (let key in data) {
55
+ if (data.hasOwnProperty(key) && title[key]) {
56
+ s.innerHTML += `<div><span>${title[key]}</span><span id="${key}">${data[key]}</span></div>`;
57
+ }
58
+ }
59
+ });
59
60
 
60
61
 
61
- if oneself
62
- style.
63
- :root {
64
- --site-about-oneself-map--light: url(#{oneself.map.light});
65
- --site-about-oneself-map--dark: url(#{oneself.map.dark});
66
- }
67
- .author-content-item-group.column.mapAndInfo
68
- .author-content-item.map.single
69
- span.map-title=_p('about.other.oneself.map_title') + oneself.location
70
- .author-content-item.selfInfo.single
71
- div
72
- span.selfInfo-title=_p('about.other.oneself.info_title1')
73
- span.selfInfo-content(style="color: #43a6c6;")= oneself.birthYear
74
- div
75
- span.selfInfo-title= oneself.university
76
- span.selfInfo-content(style="color: #c69043;")= oneself.major
77
- div
78
- span.selfInfo-title=_p('about.other.oneself.info_title2')
79
- span.selfInfo-content(style="color: #b04fe6;")= oneself.occupation
62
+ if oneself
63
+ style.
64
+ :root {
65
+ --site-about-oneself-map--light: url(#{oneself.map.light});
66
+ --site-about-oneself-map--dark: url(#{oneself.map.dark});
67
+ }
68
+ .author-content-item-group.column.mapAndInfo
69
+ .author-content-item.map.single
70
+ span.map-title=_p('about.other.oneself.map_title') + oneself.location
71
+ .author-content-item.selfInfo.single
72
+ div
73
+ span.selfInfo-title=_p('about.other.oneself.info_title1')
74
+ span.selfInfo-content(style="color: #43a6c6;")= oneself.birthYear
75
+ div
76
+ span.selfInfo-title= oneself.university
77
+ span.selfInfo-content(style="color: #c69043;")= oneself.major
78
+ div
79
+ span.selfInfo-title=_p('about.other.oneself.info_title2')
80
+ span.selfInfo-content(style="color: #b04fe6;")= oneself.occupation
80
81
 
81
82
  - var cause = site.data.about.cause
82
83
 
@@ -34,7 +34,7 @@ script().
34
34
  item: '.OwO-items li'
35
35
  })
36
36
 
37
- barrageTwikoo()
37
+ !{commentBarrage} && barrageTwikoo()
38
38
  }
39
39
 
40
40
  const loadTwikoo = () => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "hexo-theme-solitude",
3
- "version": "1.12.1",
3
+ "version": "1.12.3",
4
4
  "description": "A beautiful, powerful, and efficient Hexo theme developed by EverFu.",
5
5
  "main": "package.json",
6
6
  "scripts": {
@@ -24,9 +24,9 @@
24
24
  },
25
25
  "bugs": {
26
26
  "url": "https://github.com/everfu/hexo-theme-solitude/issues",
27
- "email": "o@efu.me"
27
+ "email": "o@everfu.org"
28
28
  },
29
29
  "homepage": "https://www.efu.me/",
30
- "author": "Hexo-Theme-Solitude<o@efu.me>",
30
+ "author": "Hexo-Theme-Solitude<o@everfu.org>",
31
31
  "license": "MIT"
32
32
  }
package/plugins.yml CHANGED
@@ -1,11 +1,11 @@
1
1
  algolia_search:
2
2
  name: algoliasearch
3
3
  file: dist/algoliasearch-lite.umd.js
4
- version: 4.23.3
4
+ version: 4.24.0
5
5
  instantsearch:
6
6
  name: instantsearch.js
7
7
  file: dist/instantsearch.production.min.js
8
- version: 4.70.0
8
+ version: 4.73.0
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.2.1
21
+ version: 3.2.7
22
22
  waline_css:
23
23
  name: '@waline/client'
24
24
  file: dist/waline.css
25
- version: 3.2.1
25
+ version: 3.2.7
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.6
34
+ version: 2.8.7
35
35
  artalk_js:
36
36
  name: artalk
37
37
  file: dist/Artalk.js
38
- version: 2.8.6
38
+ version: 2.8.7
39
39
  katex:
40
40
  name: katex
41
41
  file: dist/katex.min.css
@@ -104,6 +104,7 @@ hexo.extend.filter.register('before_generate', () => {
104
104
  },
105
105
  index_post_list: {
106
106
  direction: 'column',
107
+ column: 2,
107
108
  content: false,
108
109
  length: 500,
109
110
  cover: 'both'
@@ -83,4 +83,9 @@ hexo.extend.helper.register('inject_head_js', function () {
83
83
  }
84
84
  `
85
85
  return `<script>(()=>{${createJS()}})()</script>`
86
+ })
87
+
88
+ hexo.extend.helper.register('packageVersion', function () {
89
+ const {version} = require('../../package.json')
90
+ return version
86
91
  })
@@ -0,0 +1,35 @@
1
+ "use strict";
2
+
3
+ function postBtns(args, content) {
4
+ return `<div class="btns ${args.join(" ")}">
5
+ ${content}
6
+ </div>`;
7
+ }
8
+
9
+ function postCell(args, content) {
10
+ args = args.join(" ").split(",");
11
+ let text = args[0] || "";
12
+ let url = args[1] || "";
13
+ text = text.trim();
14
+ url = url.trim();
15
+ if (url.length > 0) {
16
+ url = "href='" + url + "'";
17
+ }
18
+ let icon = "";
19
+ let img = "https://npm.elemecdn.com/hexo-butterfly-tag-plugins-plus/lib/assets/default.svg";
20
+ if (args.length > 2) {
21
+ if (args[2].indexOf(" solitude") > -1) {
22
+ icon = args[2].trim();
23
+ } else {
24
+ img = args[2].trim();
25
+ }
26
+ }
27
+ if (icon.length > 0) {
28
+ return `<a class="button no-text-decoration" ${url} title='${text}'><i class='${icon}'></i>${text}</a>`;
29
+ } else {
30
+ return `<a class="button no-text-decoration" ${url} title='${text}'><img src='${img}'>${text}</a>`;
31
+ }
32
+ }
33
+
34
+ hexo.extend.tag.register("btns", postBtns, { ends: true });
35
+ hexo.extend.tag.register("cell", postCell);
@@ -148,9 +148,6 @@ hr
148
148
  overflow visible
149
149
  display: none
150
150
 
151
- pre
152
- font-family monospace, monospace
153
-
154
151
  a
155
152
  color var(--efu-fontcolor)
156
153
  text-decoration none
@@ -165,7 +162,7 @@ abbr[title]
165
162
  b, strong
166
163
  font-weight bolder
167
164
 
168
- code, kbd, samp
165
+ code, kbd, samp, pre
169
166
  font-family $code-font-family
170
167
  font-size $code-font-size
171
168
 
@@ -363,6 +360,7 @@ b, strong
363
360
  i.solitude
364
361
  font-size 22px
365
362
  line-height 1
363
+ font-synthesis style
366
364
 
367
365
  .layout
368
366
  display: flex
@@ -1,4 +1,5 @@
1
- @import "diff"
1
+ if hexo-config('highlight.enable')
2
+ @import "diff"
2
3
  figure
3
4
  pre
4
5
  margin 0
@@ -1,6 +1,6 @@
1
- @import "color"
2
-
3
- @import "theme/" + hexo-config('highlight.theme')
1
+ if hexo-config('highlight.enable')
2
+ @import "color"
3
+ @import "theme/" + hexo-config('highlight.theme')
4
4
 
5
5
  if $highlight_enable
6
6
  @require "highlight/index.styl"
@@ -1,6 +1,7 @@
1
1
  @require line-number
2
2
 
3
- @require diff
3
+ if hexo-config('highlight.enable')
4
+ @require diff
4
5
 
5
6
  #article-container
6
7
  pre[class*='language-']
@@ -692,6 +692,7 @@ if hexo-config('nav.group')
692
692
  opacity 0
693
693
  pointer-events none
694
694
  backdrop-filter blur(20px)
695
+ -webkit-backdrop-filter blur(20px)
695
696
 
696
697
  +maxWidth768()
697
698
  left 0
@@ -32,13 +32,6 @@ if hexo-config('index_post_list.direction') == "column"
32
32
  cursor pointer
33
33
  border var(--style-border)
34
34
 
35
- +minWidth1300()
36
- flex-direction column
37
- width 100%
38
- flex 1 1 40%
39
- max-width 50%
40
- box-shadow var(--efu-shadow-border)
41
-
42
35
  +maxWidth1300()
43
36
  margin-bottom .5rem
44
37
 
@@ -238,6 +231,25 @@ if hexo-config('index_post_list.direction') == "column"
238
231
  .sticky
239
232
  color var(--efu-fontcolor)
240
233
 
234
+ if hexo-config('index_post_list.direction') == "column" && hexo-config('index_post_list.column') == 2
235
+ #recent-posts
236
+ > .recent-post-item
237
+ +minWidth1300()
238
+ flex-direction column
239
+ width 100%
240
+ flex 1 1 40%
241
+ max-width 50%
242
+ box-shadow var(--efu-shadow-border)
243
+ else if hexo-config('index_post_list.direction') == "column" && hexo-config('index_post_list.column') == 3
244
+ #recent-posts
245
+ > .recent-post-item
246
+ +minWidth1300()
247
+ flex-direction column
248
+ width 100%
249
+ flex 1 1 33.3%
250
+ max-width 32.6%
251
+ box-shadow var(--efu-shadow-border)
252
+
241
253
  else if hexo-config('index_post_list.direction') == "row"
242
254
  #recent-posts
243
255
  position relative
@@ -79,6 +79,7 @@
79
79
  display flex
80
80
  flex-direction column
81
81
  width calc(100% / 3 - 0.5rem)
82
+ min-width 200px
82
83
  align-items flex-start
83
84
  background var(--efu-card-bg)
84
85
  border-radius 12px
@@ -4,7 +4,14 @@
4
4
  border var(--style-border-always)
5
5
 
6
6
  div:only-child
7
- width 100%!important
7
+ &.next-post, &.prev-post
8
+ width 100%
9
+
10
+ &.next-post a
11
+ border-left 0
12
+
13
+ &.prev-post a
14
+ border-right 0
8
15
 
9
16
  +minWidth1300()
10
17
  position fixed
@@ -113,7 +120,7 @@
113
120
  a
114
121
  +minWidth768()
115
122
  border-right var(--efu-main-op)
116
- border-right-width 1px
123
+ border-right-width .5px
117
124
  border-right-style solid
118
125
 
119
126
  +minWidth1300()
@@ -131,7 +138,7 @@
131
138
  a
132
139
  +minWidth768()
133
140
  border-left var(--efu-main-op)
134
- border-left-width 1px
141
+ border-left-width .5px
135
142
  border-left-style solid
136
143
  display flex
137
144
  align-items flex-start
@@ -0,0 +1,212 @@
1
+ [data-theme="dark"]
2
+ div
3
+ &.btns
4
+ filter brightness(0.7)
5
+ a
6
+ background 0 0
7
+ div
8
+ &.btns
9
+ margin 0 -8px
10
+ display flex
11
+ flex-wrap wrap
12
+ align-items flex-start
13
+ overflow visible
14
+ line-height 1.8
15
+ b
16
+ font-size 0.875rem
17
+ &.wide
18
+ & > a
19
+ padding-left 32px
20
+ padding-right 32px
21
+ &.fill
22
+ & > a
23
+ flex-grow 1
24
+ width auto
25
+ &.around
26
+ justify-content space-around
27
+ &.center
28
+ justify-content center
29
+ &.grid2
30
+ & > a
31
+ width calc(100% / 2 - 16px)
32
+ &.grid3
33
+ & > a
34
+ width calc(100% / 3 - 16px)
35
+ &.grid4
36
+ & > a
37
+ width calc(100% / 4 - 16px)
38
+ &.grid5
39
+ & > a
40
+ width calc(100% / 5 - 16px)
41
+ a
42
+ transition all 0.28s ease
43
+ -moz-transition all 0.28s ease
44
+ -webkit-transition all 0.28s ease
45
+ -o-transition all 0.28s ease
46
+ margin 8px
47
+ margin-top calc(1.25 * 16px + 32px)
48
+ min-width 120px
49
+ font-weight bold
50
+ display flex
51
+ justify-content flex-start
52
+ align-content center
53
+ align-items center
54
+ flex-direction column
55
+ padding 8px
56
+ text-align center
57
+ background #f6f6f6
58
+ border-radius 4px
59
+ border-bottom none!important
60
+ & > i
61
+ background #2196f3!important
62
+ &:first-child
63
+ color #fff
64
+ background #2196f3
65
+ b
66
+ font-weight bold
67
+ line-height 1.3
68
+ img
69
+ margin 0.4em auto !important
70
+ &:not([href])
71
+ cursor default
72
+ color inherit
73
+ a[href]:hover
74
+ background: var(--efu-main)
75
+ color: var(--efu-white) !important
76
+ & > i
77
+ &:first-child
78
+ background: var(--efu-main)
79
+
80
+ div.btns,
81
+ div.btns p,
82
+ div.btns a
83
+ font-size 0.8125rem
84
+ color #555
85
+
86
+ @media screen and (max-width: 1200px)
87
+ div
88
+ &.btns
89
+ &.grid2
90
+ & > a
91
+ width calc(100% / 2 - 16px)
92
+
93
+ @media screen and (max-width: 768px)
94
+ div
95
+ &.btns
96
+ &.grid2
97
+ & > a
98
+ width calc(100% / 2 - 16px)
99
+
100
+ @media screen and (max-width: 500px)
101
+ div
102
+ &.btns
103
+ &.grid2
104
+ & > a
105
+ width calc(100% / 1 - 16px)
106
+
107
+ @media screen and (max-width: 1200px)
108
+ div
109
+ &.btns
110
+ &.grid3
111
+ & > a
112
+ width calc(100% / 3 - 16px)
113
+
114
+ @media screen and (max-width: 768px)
115
+ div
116
+ &.btns
117
+ &.grid3
118
+ & > a
119
+ width calc(100% / 3 - 16px)
120
+
121
+ @media screen and (max-width: 500px)
122
+ div
123
+ &.btns
124
+ &.grid3
125
+ & > a
126
+ width calc(100% / 1 - 16px)
127
+
128
+ @media screen and (max-width: 1200px)
129
+ div
130
+ &.btns
131
+ &.grid4
132
+ & > a
133
+ width calc(100% / 3 - 16px)
134
+
135
+ @media screen and (max-width: 768px)
136
+ div
137
+ &.btns
138
+ &.grid4
139
+ & > a
140
+ width calc(100% / 3 - 16px)
141
+
142
+ @media screen and (max-width: 500px)
143
+ div
144
+ &.btns
145
+ &.grid4
146
+ & > a
147
+ width calc(100% / 2 - 16px)
148
+
149
+ @media screen and (max-width: 1200px)
150
+ div
151
+ &.btns
152
+ &.grid5
153
+ & > a
154
+ width calc(100% / 4 - 16px)
155
+
156
+ @media screen and (max-width: 768px)
157
+ div
158
+ &.btns
159
+ &.grid5
160
+ & > a
161
+ width calc(100% / 3 - 16px)
162
+
163
+ @media screen and (max-width: 500px)
164
+ div
165
+ &.btns
166
+ &.grid5
167
+ & > a
168
+ width calc(100% / 2 - 16px)
169
+
170
+ div.btns a > img:first-child,
171
+ div.btns a > i:first-child
172
+ transition all 0.28s ease
173
+ -moz-transition all 0.28s ease
174
+ -webkit-transition all 0.28s ease
175
+ -o-transition all 0.28s ease
176
+ height 64px
177
+ width 64px
178
+ box-shadow 0 1px 2px 0 rgba(0, 0, 0, 0.1)
179
+ margin 16px 8px 4px 8px
180
+ margin-top calc(-1.25 * 16px - 32px)
181
+ border 2px solid #fff
182
+ background #fff
183
+ line-height 60px
184
+ font-size 28px
185
+
186
+ div.btns a > img:first-child.auto,
187
+ div.btns a > i:first-child.auto
188
+ width auto
189
+
190
+ div.btns a p,
191
+ div.btns a b
192
+ margin 0.25em
193
+ font-weight normal
194
+ line-height 1.25
195
+ word-wrap break-word
196
+
197
+ div.btns a[href]:hover,
198
+ div.btns a[href]:hover b
199
+ color #ff5722
200
+
201
+ div.btns a[href]:hover > img:first-child,
202
+ div.btns a[href]:hover > i:first-child
203
+ transform scale(1.1) translateY(-8px)
204
+ box-shadow 0 4px 8px 0 rgba(0, 0, 0, 0.1)
205
+
206
+ div.btns.circle a > img:first-child,
207
+ div.btns.circle a > i:first-child
208
+ border-radius 32px
209
+
210
+ div.btns.rounded a > img:first-child,
211
+ div.btns.rounded a > i:first-child
212
+ border-radius 16px
@@ -32,6 +32,12 @@
32
32
  opacity 0
33
33
  transition .3s
34
34
 
35
+ #post_chat_button
36
+ display none
37
+
38
+ +maxWidth768()
39
+ display block
40
+
35
41
  #postChat_iframeContainer
36
42
  z-index 1000
37
43
  border var(--style-border-always)
@@ -39,12 +45,21 @@
39
45
  animation to_show_fromLeftBottom .2s ease-out
40
46
  border-radius 12px
41
47
 
48
+ +maxWidth768()
49
+ width 100% !important
50
+ height 100% !important
51
+ bottom 0 !important
52
+ left 0 !important
53
+ max-width 100% !important
54
+ max-height 100% !important
55
+ border-radius 0 !important
56
+
42
57
  #efuTalk.on span.efuTalkTitle, #efuTalk:hover span.efuTalkTitle
43
58
  color var(--efu-card-bg)
44
59
  opacity 1
45
60
 
46
61
  #postChat_button
47
- display none!important
62
+ display none !important
48
63
 
49
64
  #efuTalk i.solitude.efuTalkIcon
50
65
  width 18px
package/source/js/main.js CHANGED
@@ -28,7 +28,6 @@ const sidebarFn = () => {
28
28
  }
29
29
  const scrollFn = () => {
30
30
  const innerHeight = window.innerHeight;
31
- if (document.body.scrollHeight <= innerHeight) return;
32
31
  let initTop = 0;
33
32
  const $header = document.getElementById('page-header');
34
33
  const throttledScroll = utils.throttle((e) => {
@@ -375,7 +374,7 @@ const sco = {
375
374
  }
376
375
  pageText.addEventListener("keydown", (event) => {
377
376
  if (event.keyCode === 13) {
378
- this.toPage();
377
+ sco.toPage();
379
378
  pjax.loadUrl(pageButton.href);
380
379
  }
381
380
  });
@@ -54,7 +54,7 @@ class ScoMusicPlayer {
54
54
  if (musicCover) {
55
55
  loadingElement.style.display = "none";
56
56
  clearInterval(timer);
57
- document.querySelector('meting-js').aplayer.volume(0.8, true);
57
+ document.querySelector('meting-js');
58
58
  this.addEventListenerChangeMusicBg();
59
59
  backgroundElement.style.display = "block";
60
60
  }
@@ -9,12 +9,8 @@ document.onmouseup = document.ondbclick = selectText;
9
9
  const rm = {
10
10
  mask: document.getElementById("rightmenu-mask"),
11
11
  menu: document.getElementById("rightMenu"),
12
- get width() {
13
- return this.menu.offsetWidth;
14
- },
15
- get height() {
16
- return this.menu.offsetHeight;
17
- },
12
+ width: 0,
13
+ height: 0,
18
14
  domhref: "",
19
15
  domsrc: "",
20
16
  globalEvent: null,
@@ -54,8 +50,10 @@ const rm = {
54
50
  rm.mask.style.display = "none";
55
51
  },
56
52
  reLoadSize() {
57
- this.menu.style.display = "block";
58
- this.menu.style.display = "none";
53
+ rm.menu.style.display = "block";
54
+ rm.width = rm.menu.offsetWidth;
55
+ rm.height = rm.menu.offsetHeight;
56
+ rm.menu.style.display = 'none';
59
57
  },
60
58
  copyText(e) {
61
59
  navigator.clipboard && navigator.clipboard.writeText(e);
@@ -101,9 +99,9 @@ const rm = {
101
99
  };
102
100
 
103
101
  function stopMaskScroll() {
104
- utils.addEventListenerPjax(rm.menu, "mousewheel", rm.hideRightMenu);
105
- utils.addEventListenerPjax(rm.mask, "mousewheel", rm.hideRightMenu);
106
- utils.addEventListenerPjax(rm.mask, "click", rm.hideRightMenu);
102
+ utils.addEventListenerPjax(rm.menu, "mousewheel", rm.hideRightMenu, { passive: true });
103
+ utils.addEventListenerPjax(rm.mask, "mousewheel", rm.hideRightMenu, { passive: true });
104
+ utils.addEventListenerPjax(rm.mask, "click", rm.hideRightMenu, { passive: true });
107
105
  }
108
106
 
109
107
  window.oncontextmenu = (ele) => {