hexo-theme-solitude 2.0.12 → 2.1.0

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 (55) hide show
  1. package/README.md +2 -2
  2. package/README_zh-Hans.md +2 -3
  3. package/README_zh-Hant.md +2 -2
  4. package/_config.yml +24 -6
  5. package/languages/default.yml +12 -0
  6. package/languages/en.yml +12 -0
  7. package/languages/zh-CN.yml +12 -0
  8. package/languages/zh-TW.yml +34 -22
  9. package/layout/includes/head/config.pug +5 -3
  10. package/layout/includes/inject/body.pug +1 -4
  11. package/layout/includes/inject/head.pug +6 -0
  12. package/layout/includes/layout.pug +4 -0
  13. package/layout/includes/page/says.pug +1 -1
  14. package/layout/includes/rightmenu.pug +3 -3
  15. package/layout/includes/rightside.pug +3 -0
  16. package/layout/includes/sidebar.pug +10 -1
  17. package/layout/includes/widgets/aside/asideNewestPost.pug +8 -11
  18. package/layout/includes/widgets/aside/asideWebInfo.pug +6 -6
  19. package/layout/includes/widgets/page/links/banner.pug +0 -1
  20. package/layout/includes/widgets/post/postInfo.pug +12 -12
  21. package/layout/includes/widgets/rightside/hide.pug +6 -0
  22. package/layout/includes/widgets/rightside/show.pug +12 -0
  23. package/layout/includes/widgets/third-party/comments/comment.pug +3 -3
  24. package/layout/includes/widgets/third-party/pjax.pug +1 -1
  25. package/layout/page.pug +1 -1
  26. package/package.json +4 -4
  27. package/scripts/event/merge_config.js +15 -5
  28. package/scripts/event/page.js +1 -1
  29. package/scripts/filter/checkThemeConfig.js +3 -3
  30. package/scripts/helper/related_post.js +1 -1
  31. package/scripts/tags/article.js +6 -27
  32. package/scripts/tags/tabs.js +1 -3
  33. package/source/css/_comments/comment.styl +4 -4
  34. package/source/css/_comments/twikoo.styl +3 -4
  35. package/source/css/_global/index.styl +3 -3
  36. package/source/css/_layout/aside.styl +44 -28
  37. package/source/css/_layout/capsule.styl +1 -1
  38. package/source/css/_layout/header.styl +1 -0
  39. package/source/css/_layout/recent-post.styl +0 -2
  40. package/source/css/_layout/rightside.styl +34 -0
  41. package/source/css/_page/_about/buff.styl +0 -1
  42. package/source/css/_page/_about/contentinfo.styl +2 -2
  43. package/source/css/_page/_about/game.styl +0 -2
  44. package/source/css/_page/_about/maxim.styl +0 -1
  45. package/source/css/_page/_about/myphoto.styl +0 -1
  46. package/source/css/_page/_about/oneself.styl +1 -1
  47. package/source/css/_page/_about/personalities.styl +1 -1
  48. package/source/css/_page/_about/skills.styl +0 -1
  49. package/source/css/_page/_about/statistic.styl +0 -1
  50. package/source/css/_page/_home/home-top.styl +5 -0
  51. package/source/css/_page/other.styl +2 -1
  52. package/source/js/main.js +36 -0
  53. package/source/js/right_menu.js +10 -0
  54. package/source/js/tw_cn.js +18 -11
  55. /package/layout/includes/{body → head}/mode.pug +0 -0
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "hexo-theme-solitude",
3
- "version": "2.0.12",
3
+ "version": "2.1.0",
4
4
  "description": "A beautiful, powerful, and efficient Hexo theme developed by everfu.",
5
5
  "main": "package.json",
6
6
  "scripts": {
@@ -12,7 +12,7 @@
12
12
  "solitude",
13
13
  "Card UI Design",
14
14
  "everfu",
15
- "一小只托尼",
15
+ "伍十七",
16
16
  "hexo-theme-solitude"
17
17
  ],
18
18
  "repository": {
@@ -25,9 +25,9 @@
25
25
  },
26
26
  "bugs": {
27
27
  "url": "https://github.com/everfu/hexo-theme-solitude/issues",
28
- "email": "o@everfu.org"
28
+ "email": "o@everfu.cn"
29
29
  },
30
30
  "homepage": "https://solitude.js.org",
31
- "author": "Hexo-Theme-Solitude<o@everfu.org>",
31
+ "author": "Hexo-Theme-Solitude<o@everfu.cn>",
32
32
  "license": "MIT"
33
33
  }
@@ -383,11 +383,8 @@ hexo.extend.filter.register('before_generate', () => {
383
383
  right_menu: {
384
384
  enable: false,
385
385
  commentBarrage: false,
386
- translate: {
387
- enable: false,
388
- defaultEncoding: 2,
389
- translateDelay: 0,
390
- },
386
+ ctrlOriginalMenu: false,
387
+ translate: false,
391
388
  custom_list: []
392
389
  },
393
390
  lure: {
@@ -408,6 +405,19 @@ hexo.extend.filter.register('before_generate', () => {
408
405
  light: 'https://bu.dusays.com/2023/09/29/651685cc18d39.jpg',
409
406
  opacity: .2,
410
407
  },
408
+ translate: {
409
+ enable: false,
410
+ defaultEncoding: 2,
411
+ translateDelay: 0,
412
+ },
413
+ rightside: {
414
+ enable: false,
415
+ hide: {
416
+ enable: false,
417
+ translate: false,
418
+ mode: false
419
+ }
420
+ },
411
421
  CDN: {
412
422
  internal: 'local',
413
423
  third_party: 'cdnjs',
@@ -30,4 +30,4 @@ hexo.extend.generator.register('categories', function(locals) {
30
30
  comment: false
31
31
  }
32
32
  };
33
- });
33
+ });
@@ -5,12 +5,12 @@ hexo.extend.filter.register('before_post_render', () => {
5
5
  const logger = hexo.log;
6
6
  const theme = hexo.theme.config;
7
7
  if (theme.says.enable && !data.essay) {
8
- logger.error('\n 启用说说的情况下,必须提供 essay 数据文件!\n 请新建 essay.yaml。');
8
+ logger.error('\n 启用即刻短文的情况下,请新建 essay.yaml。');
9
9
  logger.error('\n If says is enabled, essay data must be supplied! \n Please create essay.yaml.');
10
10
  process.exit(-1);
11
11
  }
12
12
  if (theme.footer.randomlink && !data.links){
13
- logger.error('\n 启用随机链接的情况下,必须提供 links 数据!\n 请新建 links.yaml。');
13
+ logger.error('\n 启用随机链接的情况下,请新建 links.yaml。');
14
14
  logger.error('\n If randomlink is enabled, links data must be supplied! \n Please create links.yaml.');
15
15
  process.exit(-1);
16
16
  }
@@ -20,4 +20,4 @@ hexo.extend.filter.register('before_post_render', () => {
20
20
  process.exit(-1);
21
21
  }
22
22
  }
23
- );
23
+ );
@@ -82,4 +82,4 @@ function compare(attr, dateType) {
82
82
  }
83
83
  return val2 - val1
84
84
  }
85
- }
85
+ }
@@ -7,33 +7,12 @@ const article = ([path]) => {
7
7
  }
8
8
  const tags = post.tags.map(tag => `<a class="article-meta__tags fancybox" href="${tag.path}" onclick="event.stopPropagation();"><span class="tags-punctuation"><i class="solitude fa-solid fa-hashtag"></i>${tag.name}</span></a>`).join('');
9
9
  const category = post.categories.data.length > 0 ? `<span class="article-meta sticky-warp"><span class="original">${post.categories.data[0].name}</span></span>` : '';
10
- return `
11
- <div class="recent-post-item" onclick="pjax.loadUrl('${post.path}')">
12
- <div class="post_cover">
13
- <a href="${post.path}" class="fancybox" title="${post.title}">
14
- <img class="post_bg" src="${post.cover}" alt="${post.title}">
15
- </a>
16
- </div>
17
- <div class="recent-post-info">
18
- <div class="recent-post-info-top">
19
- <div class="recent-post-info-top-tips">
20
- ${category}
21
- </div>
22
- <a class="article-title fancybox" href="${post.path}" title="${post.title}">${post.title}</a>
23
- </div>
24
- <div class="content">
25
- ${post.description ? post.description : ''}
26
- </div>
27
- <div class="article-meta-wrap">
28
- <span class="article-meta tags">
29
- ${tags}
30
- </span>
31
- <span class="post-meta-date">
32
- <time datetime="${post.date}" style="display: inline;"></time>
33
- </span>
34
- </div>
35
- </div>
36
- </div>`;
10
+ const postCover = `<div class="post_cover"><a href="${'/' + post.path}" class="fancybox" title="${post.title}"><img class="post_bg" src="${post.cover}" alt="${post.title}"></a></div>`;
11
+ const recentPostInfoTop = `<div class="recent-post-info-top"><div class="recent-post-info-top-tips">${category}</div><a class="article-title fancybox" href="${'/' + post.path}" title="${post.title}">${post.title}</a></div>`;
12
+ const content = `<div class="content">${post.description ? post.description : ''}</div>`;
13
+ const articleMetaWrap = `<div class="article-meta-wrap"><span class="article-meta tags">${tags}</span><span class="post-meta-date"><time datetime="${post.date}" style="display: inline;"></time></span></div>`;
14
+ const recentPostInfo = `<div class="recent-post-info">${recentPostInfoTop + content + articleMetaWrap}</div>`
15
+ return `<div class="recent-post-item" onclick="pjax.loadUrl('${'/' + post.path}')">${postCover + recentPostInfo}</div>`;
37
16
  }
38
17
 
39
18
  hexo.extend.tag.register('article', article)
@@ -14,9 +14,7 @@ function postTabs ([name, active], content) {
14
14
  let tabNav = ''
15
15
  let tabContent = ''
16
16
 
17
- if (typeof active === 'undefined') {
18
- active = 0
19
- }
17
+ active = Number(active) || 0
20
18
 
21
19
  while ((match = tabBlock.exec(content)) !== null) {
22
20
  matches.push(match[1])
@@ -77,7 +77,7 @@
77
77
  font-size .6rem
78
78
  color var(--efu-secondtext)
79
79
  border-radius 8px
80
- if index(hexo-config('comment.use'), ',') || hexo-config('comment.use')[1]
80
+ if hexo-config('comment.use')[1] || ',' in hexo-config('comment.use')
81
81
  &.move
82
82
  if hexo-config('comment.count')
83
83
  .comment-head
@@ -103,7 +103,7 @@
103
103
  margin .5rem 0
104
104
  position relative
105
105
 
106
- if index(hexo-config('comment.use'), ',') || ',' in hexo-config('comment.use')
106
+ if hexo-config('comment.use')[1] || ',' in hexo-config('comment.use')
107
107
  .count span:last-child
108
108
  display none
109
109
 
@@ -139,7 +139,7 @@
139
139
  content ''
140
140
  transition .4s
141
141
 
142
- if ',' in hexo-config('comment.use') || index(hexo-config('comment.use'), ',')
142
+ if hexo-config('comment.use')[1] || index(hexo-config('comment.use'), ',')
143
143
  .comment-wrap
144
144
  > div:last-child
145
145
  display none
@@ -167,4 +167,4 @@ if hexo-config('twikoo.style') && 'Twikoo' in hexo-config('comment.use')
167
167
  @import 'twikoo.styl'
168
168
 
169
169
  if hexo-config('valine.style') && 'Valine' in hexo-config('comment.use')
170
- @import 'valine.styl'
170
+ @import 'valine.styl'
@@ -301,6 +301,9 @@
301
301
  font-size .5rem
302
302
  color var(--efu-secondtext)
303
303
 
304
+ .tk-content
305
+ margin-top 0!important
306
+
304
307
  .tk-meta-input
305
308
  .el-input
306
309
  .el-input-group__prepend
@@ -408,10 +411,6 @@ button.el-button.tk-cancel.el-button--default.el-button--small
408
411
  border-radius 8px !important
409
412
  color var(--efu-fontcolor) !important
410
413
 
411
- .tk-replies .tk-content span:first-child
412
- font-size inherit
413
- color black
414
-
415
414
  .OwO
416
415
  &.OwO-open
417
416
  .OwO-body
@@ -43,8 +43,8 @@
43
43
  --sidebar-bg #f6f8fa
44
44
  --btn-hover-color #ff7242
45
45
  --btn-color #fff
46
- --btn-bg #307af6
47
- --text-bg-hover #307af6
46
+ --btn-bg var(--efu-main)
47
+ --text-bg-hover #f6f8fa
48
48
  --light-grey #eee
49
49
  --text-highlight-color #1f2d3d
50
50
  --blockquote-color #6a737d
@@ -411,7 +411,7 @@ i.solitude
411
411
  span.tags-punctuation
412
412
  i
413
413
  font-weight bold
414
- font-size: 14px
414
+ font-size: 12px
415
415
  transition none
416
416
  margin-right: 2px
417
417
  opacity: .4
@@ -1,5 +1,6 @@
1
1
  #aside-content
2
- width 300px
2
+ +minWidth1200()
3
+ width 300px
3
4
  if hexo-config('aside.position') == 0
4
5
  order 1
5
6
  else
@@ -12,7 +13,8 @@
12
13
  padding-left 15px
13
14
 
14
15
  +maxWidth1200()
15
- display none
16
+ .card-widget:not(#card-toc)
17
+ display: none
16
18
 
17
19
  +minWidth1300()
18
20
  animation slide-in .6s .3s backwards
@@ -62,6 +64,7 @@
62
64
  .sticky_layout
63
65
  top calc(60px + .5rem)
64
66
  position sticky
67
+ z-index 10
65
68
  transition: top .3s ease 0s
66
69
 
67
70
  #author-info__sayhi
@@ -187,6 +190,21 @@
187
190
  right 0
188
191
  padding .5rem
189
192
 
193
+ +maxWidth1200()
194
+ position: fixed
195
+ right: 3rem
196
+ bottom: 2rem
197
+ z-index: 100
198
+ max-width: 380px
199
+ max-height: calc(100% - 60px)
200
+ width: calc(100% - 80px)
201
+ transition: transform .3s
202
+ transform: scale(0)
203
+ transform-origin: right bottom
204
+
205
+ &.open
206
+ transform: scale(1)
207
+
190
208
  .toc-content
191
209
  overflow-y: auto
192
210
  max-height: calc(100vh - 300px)
@@ -744,32 +762,6 @@ if hexo-config('aside.card.style') == 2
744
762
  border var(--style-border-always)
745
763
 
746
764
  #aside-content
747
- .card-webinfo
748
- .webinfo
749
- .webinfo-item-title
750
- display flex
751
-
752
- i
753
- line-height: 2 !important
754
- margin-right: 6px
755
- width: 16px
756
- text-align: center
757
- font-size: 16px !important
758
-
759
- .webinfo-item
760
- display flex
761
- justify-content space-between
762
- white-space nowrap
763
- -webkit-box-align center
764
- align-items center
765
- padding .1rem .5rem 0
766
-
767
- div:first-child
768
- -webkit-box-flex 1
769
- flex 1 1 0
770
- padding-right 1rem
771
-
772
-
773
765
  .card-allinfo
774
766
 
775
767
  hr
@@ -1098,3 +1090,27 @@ if hexo-config('aside.newest_comment.enable')
1098
1090
  font-size 12px
1099
1091
  color var(--efu-secondtext)
1100
1092
  margin-top auto
1093
+
1094
+ .webinfo-item
1095
+ display flex
1096
+ justify-content space-between
1097
+ white-space nowrap
1098
+ -webkit-box-align center
1099
+ align-items center
1100
+ padding .1rem .5rem 0
1101
+
1102
+ div:first-child
1103
+ -webkit-box-flex 1
1104
+ flex 1 1 0
1105
+ padding-right 1rem
1106
+
1107
+ .webinfo
1108
+ .webinfo-item-title
1109
+ display flex
1110
+
1111
+ i
1112
+ line-height: 2
1113
+ margin-right: 6px
1114
+ width: 16px
1115
+ text-align: center
1116
+ font-size: 16px
@@ -2,7 +2,7 @@ if hexo-config('capsule.enable')
2
2
  #nav-music
3
3
  display flex
4
4
  align-items center
5
- z-index 8
5
+ z-index 11
6
6
  position fixed
7
7
  bottom 20px
8
8
  left 20px
@@ -97,6 +97,7 @@
97
97
  top 7rem
98
98
 
99
99
  #nav
100
+ z-index 100
100
101
  box-shadow none
101
102
  transition 0.3s
102
103
  display flex
@@ -128,8 +128,6 @@ if hexo-config('index_post_list.direction') == "column"
128
128
  display -webkit-box
129
129
  overflow hidden
130
130
  -webkit-box-orient vertical
131
- +minWidth1300()
132
- font-size 30px
133
131
 
134
132
  .recent-post-info-top-tips
135
133
  display flex
@@ -0,0 +1,34 @@
1
+ if hexo-config('rightside.enable')
2
+ #rightside
3
+ position: fixed
4
+ right: -2.5rem
5
+ bottom: 2.5rem
6
+ z-index: 1000
7
+ opacity: 0
8
+ transition: all .5s
9
+
10
+ button
11
+ display: block
12
+ margin-bottom: 5px
13
+ width: 1.8rem
14
+ height: 1.8rem
15
+ border-radius: 50%
16
+ background-color: var(--btn-bg)
17
+ color: var(--btn-color)
18
+ text-align: center
19
+ font-size: 16px
20
+
21
+ &.mobile
22
+ display: none
23
+
24
+ +maxWidth900()
25
+ display: block
26
+
27
+ .rs_hide
28
+ transform: translate(45px, 0)
29
+ transition: all .4s
30
+ opacity 0
31
+
32
+ &.show
33
+ opacity .8
34
+ transform: translate(0, 0)
@@ -13,7 +13,6 @@
13
13
  animation gradient 15s ease infinite
14
14
  min-height 200px
15
15
  height fit-content
16
- width calc(60% - (.5rem / 2))
17
16
 
18
17
  .card-content
19
18
  display flex
@@ -7,7 +7,7 @@
7
7
  background linear-gradient(120deg, #5b27ff 0, #00d4ff 100%)
8
8
  background-size 200%
9
9
  animation gradient 15s ease infinite
10
- width calc(60% - .5rem / 2)
10
+ flex 4
11
11
 
12
12
  .title1
13
13
  opacity .8
@@ -28,7 +28,7 @@
28
28
  justify-content center
29
29
  align-items flex-start
30
30
  flex-direction column
31
- width calc(40% - (.5rem / 2))
31
+ flex 3
32
32
 
33
33
  h2
34
34
  margin-right auto
@@ -3,7 +3,6 @@
3
3
  min-height 300px
4
4
  overflow hidden
5
5
  color var(--efu-white)
6
- width 59%
7
6
 
8
7
  &::after
9
8
  box-shadow 0 -69px 203px 11px #04120f inset
@@ -26,7 +25,6 @@
26
25
  padding 1rem 2rem
27
26
 
28
27
  .author-content-item.game-jl
29
- width 39%
30
28
  min-height 300px
31
29
  overflow hidden
32
30
  color var(--efu-white)
@@ -7,7 +7,6 @@
7
7
  align-items flex-start
8
8
  flex-direction column
9
9
  justify-content center
10
- width calc(40% - (.5rem / 2))
11
10
 
12
11
  .maxim-title
13
12
  display flex
@@ -4,7 +4,6 @@
4
4
  min-height 240px
5
5
  position relative
6
6
  overflow hidden
7
- width calc(40% - (.5rem / 2))
8
7
  display flex
9
8
  align-items center
10
9
  justify-content center
@@ -10,7 +10,7 @@
10
10
  width 100% !important
11
11
 
12
12
  &.mapAndInfo
13
- width calc(60% - (.5rem / 2))
13
+ flex 8
14
14
  gap .5rem
15
15
 
16
16
  .author-content-item
@@ -1,7 +1,7 @@
1
1
  .author-content-item.personalities
2
2
  overflow hidden
3
3
  position relative
4
- width calc(60% - (.5rem / 2))
4
+ flex 6
5
5
  +maxWidth768()
6
6
  min-height 360px
7
7
 
@@ -4,7 +4,6 @@
4
4
  justify-content center
5
5
  align-items flex-start
6
6
  flex-direction column
7
- width calc(50% - (.5rem / 2))
8
7
  min-height 450px
9
8
 
10
9
  .tags-group-all
@@ -5,7 +5,6 @@
5
5
 
6
6
  .about-statistic
7
7
  min-height 380px
8
- width calc(40% - (.5rem / 2))
9
8
  background-size cover
10
9
  color var(--efu-white)
11
10
  overflow hidden
@@ -259,6 +259,11 @@
259
259
  flex-wrap wrap
260
260
  height 120px
261
261
 
262
+ +maxWidth1200()
263
+ flex-direction row
264
+ left 2rem
265
+ height 60px
266
+
262
267
  .banners-link-btn
263
268
  display flex
264
269
  flex-direction row
@@ -156,6 +156,7 @@ div#banners
156
156
 
157
157
  +maxWidth768()
158
158
  margin-top 0
159
+ flex-direction column
159
160
 
160
161
  .author-content-item
161
162
  +maxWidth1300()
@@ -172,7 +173,7 @@ div#banners
172
173
  margin-top 0
173
174
 
174
175
  .author-content-item
175
- width 49.5%
176
+ flex 4
176
177
  border-radius 12px
177
178
  background var(--efu-card-bg)
178
179
  border var(--style-border-always)
package/source/js/main.js CHANGED
@@ -26,9 +26,11 @@ const sidebarFn = () => {
26
26
  sco.refreshWaterFall();
27
27
  });
28
28
  }
29
+
29
30
  const scrollFn = () => {
30
31
  let initTop = 0;
31
32
  const $header = document.getElementById('page-header');
33
+ const $rightside = document.getElementById('rightside') || null;
32
34
  const throttledScroll = utils.throttle(() => {
33
35
  initThemeColor();
34
36
  const currentTop = window.scrollY || document.documentElement.scrollTop;
@@ -40,14 +42,17 @@ const scrollFn = () => {
40
42
  if (!$header.classList.contains('nav-visible')) $header.classList.add('nav-visible');
41
43
  }
42
44
  $header.classList.add('nav-fixed');
45
+ $rightside && ($rightside.style.cssText = 'opacity: 0.8; transform: translateX(-58px);');
43
46
  } else {
44
47
  $header.classList.remove('nav-fixed', 'nav-visible');
48
+ $rightside && ($rightside.style.cssText = "opacity: ''; transform: ''");
45
49
  }
46
50
  }, 200);
47
51
  window.addEventListener('scroll', (e) => {
48
52
  throttledScroll(e);
49
53
  if (window.scrollY === 0) {
50
54
  $header.classList.remove('nav-fixed', 'nav-visible');
55
+ $rightside && ($rightside.style.cssText = "opacity: ''; transform: ''");
51
56
  }
52
57
  });
53
58
 
@@ -656,6 +661,35 @@ class tabs {
656
661
  }
657
662
  }
658
663
 
664
+ const scrollFnToDo = () => {
665
+ const { toc } = PAGE_CONFIG;
666
+
667
+ if (toc) {
668
+ const $cardTocLayout = document.getElementById('card-toc')
669
+ $cardToc = $cardTocLayout.querySelector('.toc-content')
670
+ $tocLink = $cardToc.querySelectorAll('.toc-link')
671
+ $tocPercentage = $cardTocLayout.querySelector('.toc-percentage')
672
+ isExpand = $cardToc.classList.contains('is-expand')
673
+
674
+ // toc percentage
675
+ const tocItemClickFn = e => {
676
+ const target = e.target.closest('.toc-link')
677
+ if (!target) return
678
+
679
+ e.preventDefault()
680
+ utils.scrollToDest(utils.getEleTop(document.getElementById(decodeURI(target.getAttribute('href')).replace('#', ''))), 300)
681
+ if (window.innerWidth < 900) {
682
+ $cardTocLayout.classList.remove('open')
683
+ }
684
+ }
685
+ utils.addEventListenerPjax($cardToc, 'click', tocItemClickFn)
686
+ }
687
+ }
688
+
689
+ const forPostFn = () => {
690
+ scrollFnToDo()
691
+ }
692
+
659
693
  window.refreshFn = () => {
660
694
  const {is_home, is_page, page, is_post} = PAGE_CONFIG;
661
695
  const {runtime, lazyload, lightbox, randomlink, covercolor, post_ai, lure, expire} = GLOBAL_CONFIG;
@@ -684,6 +718,8 @@ window.refreshFn = () => {
684
718
  if (covercolor.enable) coverColor();
685
719
  if (PAGE_CONFIG.toc) toc.init();
686
720
  if (lure) tabs.lureAddListener();
721
+
722
+ forPostFn();
687
723
  }
688
724
  document.addEventListener('DOMContentLoaded', () => {
689
725
  [addCopyright, window.refreshFn, asideStatus, () => window.onscroll = percent, sco.initConsoleState].forEach(fn => fn());
@@ -1,4 +1,5 @@
1
1
  let selectTextNow = "";
2
+ let firstShowRightMenu = true;
2
3
  const selectText = () => {
3
4
  selectTextNow = document.selection
4
5
  ? document.selection.createRange().text
@@ -106,6 +107,15 @@ function stopMaskScroll() {
106
107
 
107
108
  window.oncontextmenu = (ele) => {
108
109
  if (document.body.clientWidth <= 768) return;
110
+ if (GLOBAL_CONFIG.right_menu.ctrlOriginalMenu) {
111
+ if (firstShowRightMenu) {
112
+ firstShowRightMenu = false;
113
+ utils.snackbarShow(GLOBAL_CONFIG.right_menu.ctrlOriginalMenu, false, 2000);
114
+ }
115
+ if (ele.ctrlKey) {
116
+ return true;
117
+ }
118
+ }
109
119
  let x = ele.clientX + 10;
110
120
  let y = ele.clientY;
111
121
  Array.from(rm.menuItems.other).forEach((item) => (item.style.display = "flex"));