q78kgblog 0.0.0-1720168649694 → 0.0.0-1720429643771

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 (84) hide show
  1. package/.github/workflows/HexoSeoAutoPush.yml +8 -12
  2. package/404.html +4 -4
  3. package/about/index.html +6 -6
  4. package/archives/2023/02/index.html +5 -5
  5. package/archives/2023/04/index.html +5 -5
  6. package/archives/2023/05/index.html +5 -5
  7. package/archives/2023/08/index.html +5 -5
  8. package/archives/2023/09/index.html +5 -5
  9. package/archives/2023/index.html +5 -5
  10. package/archives/2024/01/index.html +5 -5
  11. package/archives/2024/02/index.html +5 -5
  12. package/archives/2024/index.html +5 -5
  13. package/archives/index.html +5 -5
  14. package/atom.xml +9 -9
  15. package/baidusitemap.xml +8 -8
  16. package/bangumis/index.html +6 -7
  17. package/bigpie/index.html +4 -4
  18. package/categories/Hexo/index.html +5 -5
  19. package/categories/index.html +4 -4
  20. package/categories//345/271/264/347/273/210/346/200/273/347/273/223/index.html +5 -5
  21. package/categories//347/264/240/346/235/220/index.html +5 -5
  22. package/categories//351/227/262/350/201/212/346/235/202/350/260/210/index.html +5 -5
  23. package/content.json +1 -1
  24. package/css/ariasakablog.css +0 -6669
  25. package/css/danmaku.css +0 -2
  26. package/fcircle/index.html +4 -4
  27. package/fontawesome/index.html +4 -4
  28. package/index.html +12 -12
  29. package/js/commentBarrage.js +201 -201
  30. package/js/day.js +110 -110
  31. package/js/dianzan.js +5 -5
  32. package/js/dis.js +242 -241
  33. package/js/fps.js +55 -54
  34. package/js/gitalker.js +1 -1
  35. package/js/heimu.js +16 -15
  36. package/js/hide.show.js +5 -5
  37. package/js/languages.js +510 -510
  38. package/js/lunar.js +517 -517
  39. package/js/main.js +8 -8
  40. package/js/resizeTop.js +31 -31
  41. package/js/settings.js +303 -302
  42. package/js/sitetime.js +11 -11
  43. package/js/welcomeconsole.js +9 -8
  44. package/links/index.html +4 -4
  45. package/othersite/index.html +4 -4
  46. package/package.json +1 -1
  47. package/posts/164ef646/index.html +7 -7
  48. package/posts/228c2ef8/index.html +7 -7
  49. package/posts/a9a6c1fb/index.html +7 -7
  50. package/posts/c262e439/index.html +7 -7
  51. package/posts/c81531cf/index.html +7 -7
  52. package/posts/ccdf7cfc/index.html +7 -7
  53. package/posts/de1f83f4/index.html +7 -7
  54. package/posts/e54f7476/index.html +7 -7
  55. package/random.html +2 -2
  56. package/sitemap.txt +2 -2
  57. package/sitemap.xml +55 -55
  58. package/tags/AI/index.html +6 -6
  59. package/tags/Butterfly/index.html +6 -6
  60. package/tags/Cloudflare/index.html +6 -6
  61. package/tags/DiffSinger/index.html +6 -6
  62. package/tags/Hexo/index.html +6 -6
  63. package/tags/Next/index.html +6 -6
  64. package/tags/RAID/index.html +6 -6
  65. package/tags/Vercel/index.html +6 -6
  66. package/tags/Workers/index.html +6 -6
  67. package/tags/index.html +4 -4
  68. package/tags//344/270/273/351/242/230/index.html +6 -6
  69. package/tags//345/206/231/344/275/234/index.html +6 -6
  70. package/tags//345/245/263/346/200/247/346/204/217/350/257/206/index.html +6 -6
  71. package/tags//345/255/246/344/271/240/index.html +6 -6
  72. package/tags//345/256/266/351/207/214/344/272/221/index.html +6 -6
  73. package/tags//345/271/264/347/273/210/346/200/273/347/273/223/index.html +6 -6
  74. package/tags//346/212/230/350/205/276/index.html +6 -6
  75. package/tags//346/227/245/345/270/270/index.html +6 -6
  76. package/tags//346/234/215/345/212/241/345/231/250/index.html +6 -6
  77. package/tags//346/265/252/346/275/256/index.html +6 -6
  78. package/tags//347/256/200/347/210/261/index.html +6 -6
  79. package/tags//350/207/252/345/212/250/346/240/207/346/263/250/index.html +6 -6
  80. package/tags//350/256/272/346/226/207/index.html +6 -6
  81. package/tags//350/260/267/346/255/214/347/277/273/350/257/221/index.html +6 -6
  82. package/tags//350/264/237/350/275/275/345/235/207/350/241/241/index.html +6 -6
  83. package/tags//351/207/221/345/217/245/index.html +6 -6
  84. package/tags//351/255/224/346/224/271/index.html +6 -6
package/js/settings.js CHANGED
@@ -1,353 +1,354 @@
1
1
  document.addEventListener('pjax:complete', tosetting);
2
2
  document.addEventListener('DOMContentLoaded', tosetting);
3
- function tosetting(){
4
- $("#settingWindow").hide();
5
- if(localStorage.getItem("blur")=="false"){
6
- blur=0;
7
- }else{
8
- blur=1;
9
-
10
- }
11
- if(localStorage.getItem("yjjs")=="true"){
12
- yjjs=1;
13
- }else{
14
- yjjs=0;
15
-
16
- }
17
- if(localStorage.getItem("fpson")==undefined){
18
- localStorage.setItem("fpson","1");
19
- }
20
- if(!blur){
21
- document.getElementById("settingStyle").innerText=`
3
+ function tosetting() {
4
+ $("#settingWindow").hide();
5
+ if (localStorage.getItem("blur") == "false") {
6
+ blur = 0;
7
+ } else {
8
+ blur = 1;
9
+
10
+ }
11
+ if (localStorage.getItem("yjjs") == "true") {
12
+ yjjs = 1;
13
+ } else {
14
+ yjjs = 0;
15
+
16
+ }
17
+ if (localStorage.getItem("fpson") == undefined) {
18
+ localStorage.setItem("fpson", "1");
19
+ }
20
+ if (!blur) {
21
+ document.getElementById("settingStyle").innerText = `
22
22
  *,*:not(.card-info)::before,*::after{
23
23
  -webkit-backdrop-filter: none!important;
24
24
  backdrop-filter: none!important;
25
25
  -webkit-filter: none!important;
26
26
  filter: none!important;
27
27
  }`}
28
- else{
29
- document.getElementById("settingStyle").innerText=''
30
- }
31
- setBlur=function(){
32
- blur=!blur;
33
- localStorage.setItem("blur",blur);
34
- if(!blur){
35
- document.getElementById("settingStyle").innerText=`
28
+ else {
29
+ document.getElementById("settingStyle").innerText = ''
30
+ }
31
+ setBlur = function () {
32
+ blur = !blur;
33
+ localStorage.setItem("blur", blur);
34
+ if (!blur) {
35
+ document.getElementById("settingStyle").innerText = `
36
36
  *{
37
37
  -webkit-backdrop-filter: none!important;
38
38
  backdrop-filter: none!important;
39
39
  -webkit-filter: none!important;
40
40
  filter: none!important;
41
41
  }`}
42
- else{
43
- document.getElementById("settingStyle").innerText=''
44
- }
45
- }
46
- // if(yjjs){
47
- // document.getElementById("yjjs").innerText=`
48
- // *:not(#web_bg){
49
- // transform:translateZ(0);
50
- // backface-visibility: hidden
51
- // }`}
52
- // else{
53
- // document.getElementById("yjjs").innerText=``
54
- // }
55
- yjjs1=function(){
56
- yjjs=!yjjs;
57
- localStorage.setItem("yjjs",yjjs)
58
- // if(yjjs){
59
- // document.getElementById("yjjs").innerText=`
60
- // *:not(#web_bg){
61
- // transform:translateZ(0);
62
- // backface-visibility: hidden
63
- // }`}
64
- // else{
65
- // document.getElementById("yjjs").innerText=``
66
- // }
67
- }
68
- if(localStorage.getItem("blogTheme")=="acrylic"){
69
- document.getElementById("css").href="";
70
- }
71
- switchTheme=function(){
72
- if(document.getElementById("css").href==window.location.protocol+"//"+window.location.host+"/css/stylessimple.css"){
73
- document.getElementById("css").href=""
74
- localStorage.setItem("blogTheme","acrylic");
75
- }else{
76
- document.getElementById("css").href="/css/stylessimple.css"
77
- localStorage.setItem("blogTheme","simple");
78
- }
79
- }
80
- setColor=function(c){
81
- document.getElementById("themeColor").innerText=`:root{--lyx-theme:var(--lyx-${c})!important}`;
82
- localStorage.setItem("themeColor",c);
83
-
84
- }
85
- setFont=function(n){
86
- localStorage.setItem("font",n);
87
- if(n=="main"){
88
- var s=document.querySelectorAll("body,.wv-lt-location>a[data-v-4b9dcab4],.wv-lt-location>span[data-v-4b9dcab4],.wv-n-h-now-tmp>span[data-v-5f4c0628],.wv-n-h-now-txt>span[data-v-5f4c0628],.wv-n-h-now-rain>a[data-v-5f4c0628], .wv-n-h-now-rain>span[data-v-5f4c0628],.wv-f-forecast-date>a[data-v-66693262],.wv-f-a,.wv-lt-location>a[data-v-4b9dcab4],.wv-lt-location>span[data-v-4b9dcab4],.wv-n-h-now-tmp>span[data-v-5f4c0628],.wv-n-h-now-txt>span[data-v-5f4c0628],.wv-n-h-now-rain>a[data-v-5f4c0628], .wv-n-h-now-rain>span[data-v-5f4c0628],.wv-f-forecast-date>a[data-v-66693262],.wv-f-a,.aplayer")
89
- for(var i = 0; i <s.length; i++) {
90
- s[i].style.fontFamily="-apple-system, IBM Plex Mono ,monospace,'微软雅黑', sans-serif"
42
+ else {
43
+ document.getElementById("settingStyle").innerText = ''
91
44
  }
92
45
  }
93
- else if(n=="HYPailou"){
94
- var s=document.querySelectorAll("body,.wv-lt-location>a[data-v-4b9dcab4],.wv-lt-location>span[data-v-4b9dcab4],.wv-n-h-now-tmp>span[data-v-5f4c0628],.wv-n-h-now-txt>span[data-v-5f4c0628],.wv-n-h-now-rain>a[data-v-5f4c0628], .wv-n-h-now-rain>span[data-v-5f4c0628],.wv-f-forecast-date>a[data-v-66693262],.wv-f-a,.wv-lt-location>a[data-v-4b9dcab4],.wv-lt-location>span[data-v-4b9dcab4],.wv-n-h-now-tmp>span[data-v-5f4c0628],.wv-n-h-now-txt>span[data-v-5f4c0628],.wv-n-h-now-rain>a[data-v-5f4c0628], .wv-n-h-now-rain>span[data-v-5f4c0628],.wv-f-forecast-date>a[data-v-66693262],.wv-f-a,.aplayer")
95
- for(var i = 0; i <s.length; i++) {
96
- s[i].style.fontFamily="Fredoka,HYPailou,KyoukashoProL,-apple-system, IBM Plex Mono ,monospace,'微软雅黑', sans-serif"
46
+ // if(yjjs){
47
+ // document.getElementById("yjjs").innerText=`
48
+ // *:not(#web_bg){
49
+ // transform:translateZ(0);
50
+ // backface-visibility: hidden
51
+ // }`}
52
+ // else{
53
+ // document.getElementById("yjjs").innerText=``
54
+ // }
55
+ yjjs1 = function () {
56
+ yjjs = !yjjs;
57
+ localStorage.setItem("yjjs", yjjs)
58
+ // if(yjjs){
59
+ // document.getElementById("yjjs").innerText=`
60
+ // *:not(#web_bg){
61
+ // transform:translateZ(0);
62
+ // backface-visibility: hidden
63
+ // }`}
64
+ // else{
65
+ // document.getElementById("yjjs").innerText=``
66
+ // }
67
+ }
68
+ if (localStorage.getItem("blogTheme") == "acrylic") {
69
+ document.getElementById("css").href = "";
70
+ }
71
+ switchTheme = function () {
72
+ if (document.getElementById("css").href == window.location.protocol + "//" + window.location.host + "/css/stylessimple.css") {
73
+ document.getElementById("css").href = ""
74
+ localStorage.setItem("blogTheme", "acrylic");
75
+ } else {
76
+ document.getElementById("css").href = "/css/stylessimple.css"
77
+ localStorage.setItem("blogTheme", "simple");
97
78
  }
98
79
  }
99
- else{
100
- var s=document.querySelectorAll("body,.wv-lt-location>a[data-v-4b9dcab4],.wv-lt-location>span[data-v-4b9dcab4],.wv-n-h-now-tmp>span[data-v-5f4c0628],.wv-n-h-now-txt>span[data-v-5f4c0628],.wv-n-h-now-rain>a[data-v-5f4c0628], .wv-n-h-now-rain>span[data-v-5f4c0628],.wv-f-forecast-date>a[data-v-66693262],.wv-f-a,.wv-lt-location>a[data-v-4b9dcab4],.wv-lt-location>span[data-v-4b9dcab4],.wv-n-h-now-tmp>span[data-v-5f4c0628],.wv-n-h-now-txt>span[data-v-5f4c0628],.wv-n-h-now-rain>a[data-v-5f4c0628], .wv-n-h-now-rain>span[data-v-5f4c0628],.wv-f-forecast-date>a[data-v-66693262],.wv-f-a,.aplayer")
101
- for(var i = 0; i <s.length; i++) {
102
- s[i].style.fontFamily="var(--global-font),KyoukashoProL,-apple-system, IBM Plex Mono ,monosapce,\"微软雅黑\", sans-serif"
80
+ setColor = function (c) {
81
+ document.getElementById("themeColor").innerText = `:root{--lyx-theme:var(--lyx-${c})!important}`;
82
+ localStorage.setItem("themeColor", c);
83
+
84
+ }
85
+ setFont = function (n) {
86
+ localStorage.setItem("font", n);
87
+ if (n == "main") {
88
+ var s = document.querySelectorAll("body,.wv-lt-location>a[data-v-4b9dcab4],.wv-lt-location>span[data-v-4b9dcab4],.wv-n-h-now-tmp>span[data-v-5f4c0628],.wv-n-h-now-txt>span[data-v-5f4c0628],.wv-n-h-now-rain>a[data-v-5f4c0628], .wv-n-h-now-rain>span[data-v-5f4c0628],.wv-f-forecast-date>a[data-v-66693262],.wv-f-a,.wv-lt-location>a[data-v-4b9dcab4],.wv-lt-location>span[data-v-4b9dcab4],.wv-n-h-now-tmp>span[data-v-5f4c0628],.wv-n-h-now-txt>span[data-v-5f4c0628],.wv-n-h-now-rain>a[data-v-5f4c0628], .wv-n-h-now-rain>span[data-v-5f4c0628],.wv-f-forecast-date>a[data-v-66693262],.wv-f-a,.aplayer")
89
+ for (var i = 0; i < s.length; i++) {
90
+ s[i].style.fontFamily = "-apple-system, IBM Plex Mono ,monospace,'微软雅黑', sans-serif"
91
+ }
92
+ }
93
+ else if (n == "HYPailou") {
94
+ var s = document.querySelectorAll("body,.wv-lt-location>a[data-v-4b9dcab4],.wv-lt-location>span[data-v-4b9dcab4],.wv-n-h-now-tmp>span[data-v-5f4c0628],.wv-n-h-now-txt>span[data-v-5f4c0628],.wv-n-h-now-rain>a[data-v-5f4c0628], .wv-n-h-now-rain>span[data-v-5f4c0628],.wv-f-forecast-date>a[data-v-66693262],.wv-f-a,.wv-lt-location>a[data-v-4b9dcab4],.wv-lt-location>span[data-v-4b9dcab4],.wv-n-h-now-tmp>span[data-v-5f4c0628],.wv-n-h-now-txt>span[data-v-5f4c0628],.wv-n-h-now-rain>a[data-v-5f4c0628], .wv-n-h-now-rain>span[data-v-5f4c0628],.wv-f-forecast-date>a[data-v-66693262],.wv-f-a,.aplayer")
95
+ for (var i = 0; i < s.length; i++) {
96
+ s[i].style.fontFamily = "Fredoka,HYPailou,KyoukashoProL,-apple-system, IBM Plex Mono ,monospace,'微软雅黑', sans-serif"
97
+ }
98
+ }
99
+ else {
100
+ var s = document.querySelectorAll("body,.wv-lt-location>a[data-v-4b9dcab4],.wv-lt-location>span[data-v-4b9dcab4],.wv-n-h-now-tmp>span[data-v-5f4c0628],.wv-n-h-now-txt>span[data-v-5f4c0628],.wv-n-h-now-rain>a[data-v-5f4c0628], .wv-n-h-now-rain>span[data-v-5f4c0628],.wv-f-forecast-date>a[data-v-66693262],.wv-f-a,.wv-lt-location>a[data-v-4b9dcab4],.wv-lt-location>span[data-v-4b9dcab4],.wv-n-h-now-tmp>span[data-v-5f4c0628],.wv-n-h-now-txt>span[data-v-5f4c0628],.wv-n-h-now-rain>a[data-v-5f4c0628], .wv-n-h-now-rain>span[data-v-5f4c0628],.wv-f-forecast-date>a[data-v-66693262],.wv-f-a,.aplayer")
101
+ for (var i = 0; i < s.length; i++) {
102
+ s[i].style.fontFamily = "var(--global-font),KyoukashoProL,-apple-system, IBM Plex Mono ,monosapce,\"微软雅黑\", sans-serif"
103
+ }
104
+ document.body.style.fontFamily = "var(--global-font),KyoukashoProL,-apple-system, IBM Plex Mono ,monosapce,'微软雅黑', sans-serif"
105
+ document.documentElement.style.setProperty('--global-font', n)
103
106
  }
104
- document.body.style.fontFamily="var(--global-font),KyoukashoProL,-apple-system, IBM Plex Mono ,monosapce,'微软雅黑', sans-serif"
105
- document.documentElement.style.setProperty('--global-font', n)
106
107
  }
107
- }
108
- if(localStorage.getItem("themeColor")==undefined){
109
- localStorage.setItem("themeColor","pink");
110
- }
108
+ if (localStorage.getItem("themeColor") == undefined) {
109
+ localStorage.setItem("themeColor", "pink");
110
+ }
111
111
 
112
- setColor(localStorage.getItem("themeColor"));
112
+ setColor(localStorage.getItem("themeColor"));
113
113
 
114
114
 
115
115
 
116
- if(localStorage.getItem("hideRightside")==undefined){
117
- localStorage.setItem("hideRightside","0");
118
- }
116
+ if (localStorage.getItem("hideRightside") == undefined) {
117
+ localStorage.setItem("hideRightside", "0");
118
+ }
119
119
 
120
- if(localStorage.getItem("hideRightside")=="1"){
121
- $("#rightside").toggle()
122
- }
123
- toggleRightside=function(){
124
- $("#rightside").toggle();
125
- localStorage.setItem("hideRightside",Math.abs(Number(localStorage.getItem("hideRightside"))-1))
126
- }
127
- if(localStorage.getItem("font")==undefined){
128
- localStorage.setItem("font","HYTMR")
129
- }
130
- setFont(localStorage.getItem("font"))
131
- // 存数据
132
- // name:命名 data:数据
133
- saveData=function(name, data) {
134
- localStorage.setItem(name, JSON.stringify({ 'time': Date.now(), 'data': data }))
135
- }
120
+ if (localStorage.getItem("hideRightside") == "1") {
121
+ $("#rightside").toggle()
122
+ }
123
+ toggleRightside = function () {
124
+ $("#rightside").toggle();
125
+ localStorage.setItem("hideRightside", Math.abs(Number(localStorage.getItem("hideRightside")) - 1))
126
+ }
127
+ if (localStorage.getItem("font") == undefined) {
128
+ localStorage.setItem("font", "HYTMR")
129
+ }
130
+ setFont(localStorage.getItem("font"))
131
+ // 存数据
132
+ // name:命名 data:数据
133
+ saveData = function (name, data) {
134
+ localStorage.setItem(name, JSON.stringify({ 'time': Date.now(), 'data': data }))
135
+ }
136
136
 
137
- // 取数据
138
- // name:命名 time:过期时长,单位分钟,如传入30,即加载数据时如果超出30分钟返回0,否则返回数据
139
- loadData=function(name, time) {
140
- let d = JSON.parse(localStorage.getItem(name));
141
- // 过期或有错误返回 0 否则返回数据
142
- if (d) {
143
- let t = Date.now() - d.time
144
- if (t < (time * 60 * 1000) && t > -1) return d.data;
145
- }
146
- return 0;
147
- }
148
- // 切换背景函数
149
- // 此处的flag是为了每次读取时都重新存储一次,导致过期时间不稳定
150
- // 如果flag为0则存储,即设置背景. 为1则不存储,即每次加载自动读取背景.
151
- changeBg=function(s, flag) {
152
- let bg = document.getElementById('web_bg')
153
- if (s.charAt(0) == '#') {
154
- bg.style.backgroundColor = s
155
- bg.style.backgroundImage = 'none'
156
- } else bg.style.backgroundImage = s
157
- if (!flag) { saveData('blogbg', s) }
158
- }
159
- // 上面两个函数如果你有其他需要存取数据的功能,也可以直接使用
137
+ // 取数据
138
+ // name:命名 time:过期时长,单位分钟,如传入30,即加载数据时如果超出30分钟返回0,否则返回数据
139
+ loadData = function (name, time) {
140
+ let d = JSON.parse(localStorage.getItem(name));
141
+ // 过期或有错误返回 0 否则返回数据
142
+ if (d) {
143
+ let t = Date.now() - d.time
144
+ if (t < (time * 60 * 1000) && t > -1) return d.data;
145
+ }
146
+ return 0;
147
+ }
148
+ // 切换背景函数
149
+ // 此处的flag是为了每次读取时都重新存储一次,导致过期时间不稳定
150
+ // 如果flag为0则存储,即设置背景. 为1则不存储,即每次加载自动读取背景.
151
+ changeBg = function (s, flag) {
152
+ let bg = document.getElementById('web_bg')
153
+ if (s.charAt(0) == '#') {
154
+ bg.style.backgroundColor = s
155
+ bg.style.backgroundImage = 'none'
156
+ } else bg.style.backgroundImage = s
157
+ if (!flag) { saveData('blogbg', s) }
158
+ }
159
+ // 上面两个函数如果你有其他需要存取数据的功能,也可以直接使用
160
160
 
161
- // 读取背景
162
- try {
163
- let data = loadData('blogbg', 1440)
164
- if (data) changeBg(data, 1)
165
- else localStorage.removeItem('blogbg');
166
- } catch (error) { localStorage.removeItem('blogbg'); }
161
+ // 读取背景
162
+ try {
163
+ let data = loadData('blogbg', 1440)
164
+ if (data) changeBg(data, 1)
165
+ else localStorage.removeItem('blogbg');
166
+ } catch (error) { localStorage.removeItem('blogbg'); }
167
+
168
+
169
+
170
+ fpssw = function () {
171
+ if (localStorage.getItem("fpson") == "1") {
172
+ localStorage.setItem("fpson", "0");
173
+ } else {
174
+ localStorage.setItem("fpson", "1");
175
+ }
176
+ }
177
+ $(".asetting").hide();
178
+ $('#backer').hide();
179
+ $("#" + localStorage.getItem("themeColor")).attr("checked", true);
180
+ if (localStorage.getItem("blur") == "false") {
181
+ document.getElementById("blur").checked = true;
182
+ }
183
+ if (localStorage.getItem("yjjs") == "true") {
184
+ document.getElementById("yjjs").checked = true;
185
+ }
186
+ if (localStorage.getItem("fpson") == "1") {
187
+ document.getElementById("fpson").checked = true;
188
+ }
167
189
 
168
190
 
191
+ if (localStorage.getItem("sakurahide") == "false") {
192
+ document.getElementById("hideSakura").checked = true;
193
+ isSakura = 1;
194
+ }
195
+ else if (localStorage.getItem("sakurahide") == null) {
196
+ localStorage.setItem("sakurahide", "false");
197
+ document.getElementById("hideSakura").checked = true;
198
+ isSakura = 1;
199
+ }
200
+ else {
201
+ setTimeout(
202
+ stopp, 1000);
203
+ isSakura = 0;
204
+ }
205
+ if (localStorage.getItem("aplayerhide") == "false") {
206
+ document.getElementById("hideAplayer").checked = true;
207
+ }
208
+ else if (localStorage.getItem("aplayerhide") == null) {
209
+ localStorage.setItem("aplayerhide", "false");
210
+ document.getElementById("hideAplayer").checked = true;
211
+ }
212
+ else {
213
+ doStuff = function () {
214
+ flag = 0;
215
+ try {
216
+ ap = aplayers[0];
217
+ ap.list;
218
+ flag = 1;
219
+ } catch {
220
+ setTimeout(doStuff, 50);
221
+ return;
222
+ }
223
+ if (flag) {
224
+ $(".aplayer-fixed").hide()
225
+ }
226
+ }
227
+ doStuff();
169
228
 
170
- fpssw=function(){
171
- if(localStorage.getItem("fpson")=="1"){
172
- localStorage.setItem("fpson","0");
173
- }else{
174
- localStorage.setItem("fpson","1");
175
- }
176
- }
177
- $(".asetting").hide();
178
- $('#backer').hide();
179
- $("#"+localStorage.getItem("themeColor")).attr("checked", true);
180
- if(localStorage.getItem("blur")=="false"){
181
- document.getElementById("blur").checked=true;
182
- }
183
- if(localStorage.getItem("yjjs")=="true"){
184
- document.getElementById("yjjs").checked=true;
185
- }
186
- if(localStorage.getItem("fpson")=="1"){
187
- document.getElementById("fpson").checked=true;
188
- }
229
+ }
189
230
 
231
+ document.getElementsByClassName("reSettings")[0].onclick = function () {
232
+ localStorage.clear()
233
+ window.location.reload()
234
+ }
190
235
 
191
- if(localStorage.getItem("sakurahide")=="false"){
192
- document.getElementById("hideSakura").checked=true;
193
- isSakura=1;
194
- }
195
- else if(localStorage.getItem("sakurahide")==null){
196
- localStorage.setItem("sakurahide","false");
197
- document.getElementById("hideSakura").checked=true;
198
- isSakura=1;
199
- }
200
- else{
201
- setTimeout(
202
- stopp,1000);
203
- isSakura=0;
204
- }
205
- if(localStorage.getItem("aplayerhide")=="false"){
206
- document.getElementById("hideAplayer").checked=true;
207
- }
208
- else if(localStorage.getItem("aplayerhide")==null){
209
- localStorage.setItem("aplayerhide","false");
210
- document.getElementById("hideAplayer").checked=true;
211
- }
212
- else{
213
- doStuff=function() {
214
- flag=0;
215
- try{
216
- ap=aplayers[0];
217
- ap.list;
218
- flag=1;
219
- }catch{
220
- setTimeout(doStuff, 50);
221
- return;
236
+ toggleWinbox = function () {
237
+ $("#settingWindow").fadeToggle();
238
+ if (document.getElementById("settingWindow").style.display != "none") {
239
+ document.getElementById("settingWindow").style.display = "flex";
240
+ }
241
+ }
242
+ fullScreen = function () {
243
+ if (document.fullscreenElement) document.exitFullscreen()
244
+ else document.documentElement.requestFullscreen();
245
+ }
246
+ toggleAside = function () {
247
+ const $htmlDom = document.documentElement.classList
248
+ $htmlDom.contains('hide-aside')
249
+ ? saveToLocal.set('aside-status', 'show', 2)
250
+ : saveToLocal.set('aside-status', 'hide', 2)
251
+ $htmlDom.toggle('hide-aside')
252
+ }
253
+ toggleAplayer = function () {
254
+ $(".aplayer-fixed").toggle()
255
+ if (localStorage.getItem("aplayerhide") == "true") {
256
+ localStorage.setItem("aplayerhide", false);
222
257
  }
223
- if(flag){
224
- $(".aplayer-fixed").hide()
258
+ else {
259
+ localStorage.setItem("aplayerhide", true);
225
260
  }
226
261
  }
227
- doStuff();
228
-
229
- }
262
+ // position = $(window).scrollTop();
263
+ // $(window).scroll(function () {
230
264
 
231
- document.getElementsByClassName("reSettings")[0].onclick=function(){
232
- localStorage.clear()
233
- window.location.reload()
234
- }
265
+ // scroll = $(window).scrollTop();
235
266
 
236
- toggleWinbox=function(){
237
- $("#settingWindow").fadeToggle();
238
- if(document.getElementById("settingWindow").style.display!="none"){
239
- document.getElementById("settingWindow").style.display="flex";
240
- }
241
- }
242
- fullScreen=function() {
243
- if (document.fullscreenElement) document.exitFullscreen()
244
- else document.documentElement.requestFullscreen();
245
- }
246
- toggleAside=function(){
247
- const $htmlDom = document.documentElement.classList
248
- $htmlDom.contains('hide-aside')
249
- ? saveToLocal.set('aside-status', 'show', 2)
250
- : saveToLocal.set('aside-status', 'hide', 2)
251
- $htmlDom.toggle('hide-aside')
252
- }
253
- toggleAplayer=function(){
254
- $(".aplayer-fixed").toggle()
255
- if(localStorage.getItem("aplayerhide")=="true"){
256
- localStorage.setItem("aplayerhide",false);
257
- }
258
- else{
259
- localStorage.setItem("aplayerhide",true);
260
- }
261
- }
262
- // position = $(window).scrollTop();
263
- // $(window).scroll(function () {
267
+ // if (scroll > position) {
268
+ // document.getElementsByTagName("header")[0].style.transform="translateY(58px)";
269
+ // } else {
264
270
 
265
- // scroll = $(window).scrollTop();
266
-
267
- // if (scroll > position) {
268
- // document.getElementsByTagName("header")[0].style.transform="translateY(58px)";
269
- // } else {
270
-
271
-
272
- // document.getElementsByTagName("header")[0].style.transform="";
273
-
274
- // }
275
-
276
- // position = scroll;
277
- // });
278
- toggleSakuras=function(){
279
- isSakura=!isSakura;
280
- stopp(isSakura);
281
- if(localStorage.getItem("sakurahide")=="true"){
282
- localStorage.setItem("sakurahide",false);
283
- }
284
- else{
285
- localStorage.setItem("sakurahide",true);
286
- }
287
- }
288
- switchAside=function(){
289
- if(left){
290
- document.getElementById("aside-content").classList.add("right");
291
- document.querySelector(".layout > div:first-child").classList.add("left");
292
- localStorage.setItem("leftAside","false");
293
- }
294
- else{
295
- document.getElementById("aside-content").className="aside-content";
296
- document.querySelector(".layout > div:first-child").className="";
297
- try{
298
- document.querySelector("#recent-posts").className="recent-posts";
299
- }catch(err){}localStorage.setItem("leftAside","true");}
300
- left=!left;
301
- }
302
- left=1;
303
- if(localStorage.getItem("leftAside")=="true"||localStorage.getItem("leftAside")==null){
304
-
305
- }else{
306
- switchAside();
307
- }
308
- if(localStorage.getItem("autoTheme")=="true"){
309
- document.getElementById("autoTheme").checked=true;
310
- $("#con-mode,.rightMenu-item:has(.fa-moon)").hide();
311
- var time=new Date();
312
- if(time.getHours()<=7||time.getHours()>=19){
313
- activateDarkMode()
314
- localStorage.removeItem("theme");
271
+
272
+ // document.getElementsByTagName("header")[0].style.transform="";
273
+
274
+ // }
275
+
276
+ // position = scroll;
277
+ // });
278
+ toggleSakuras = function () {
279
+ isSakura = !isSakura;
280
+ stopp(isSakura);
281
+ if (localStorage.getItem("sakurahide") == "true") {
282
+ localStorage.setItem("sakurahide", false);
315
283
  }
316
- else{
317
- activateLightMode()
318
- localStorage.removeItem("theme");
284
+ else {
285
+ localStorage.setItem("sakurahide", true);
319
286
  }
320
- }
321
- if(location.href.indexOf('posts')!=-1){
322
- var xhr = new XMLHttpRequest();
323
- var url = document.querySelector('#page-header').style.backgroundImage.split('url("')[1].split('")')[0];
324
- xhr.open("GET","https://apis.yisous.xyz/api/imageColor?imgurl="+url, true);
325
- xhr.send();
326
- xhr.onreadystatechange = function () {
327
- if (xhr.readyState===4) {
328
- if(xhr.status===200) {
329
- document.getElementById("themeColor").innerText=`:root{--lyx-theme:${xhr.responseText}!important}`;
330
- }
287
+ }
288
+ switchAside = function () {
289
+ if (left) {
290
+ document.getElementById("aside-content").classList.add("right");
291
+ document.querySelector(".layout > div:first-child").classList.add("left");
292
+ localStorage.setItem("leftAside", "false");
331
293
  }
294
+ else {
295
+ document.getElementById("aside-content").className = "aside-content";
296
+ document.querySelector(".layout > div:first-child").className = "";
297
+ try {
298
+ document.querySelector("#recent-posts").className = "recent-posts";
299
+ } catch (err) { } localStorage.setItem("leftAside", "true");
300
+ }
301
+ left = !left;
332
302
  }
333
- }
334
- toggleAutoTheme=()=>{
335
- if(localStorage.getItem("autoTheme")=="true"){
336
- localStorage.setItem("autoTheme","false");
337
- $("#con-mode,.rightMenu-item:has(.fa-moon)").show();
303
+ left = 1;
304
+ if (localStorage.getItem("leftAside") == "true" || localStorage.getItem("leftAside") == null) {
305
+
306
+ } else {
307
+ switchAside();
338
308
  }
339
- else{
340
- localStorage.setItem("autoTheme","true");
341
- var time=new Date();
342
- if(time.getHours()<=7||time.getHours()>=19){
309
+ if (localStorage.getItem("autoTheme") == "true") {
310
+ document.getElementById("autoTheme").checked = true;
311
+ $("#con-mode,.rightMenu-item:has(.fa-moon)").hide();
312
+ var time = new Date();
313
+ if (time.getHours() <= 7 || time.getHours() >= 19) {
343
314
  activateDarkMode()
344
315
  localStorage.removeItem("theme");
345
316
  }
346
- else{
317
+ else {
347
318
  activateLightMode()
348
319
  localStorage.removeItem("theme");
349
320
  }
350
- $("#con-mode,.rightMenu-item:has(.fa-moon)").hide();
351
321
  }
352
- }
322
+ if (location.href.indexOf('posts') != -1) {
323
+ var xhr = new XMLHttpRequest();
324
+ var url = document.querySelector('#page-header').style.backgroundImage.split('url("')[1].split('")')[0];
325
+ xhr.open("GET", "https://apis.yisous.xyz/api/imageColor?imgurl=" + url, true);
326
+ xhr.send();
327
+ xhr.onreadystatechange = function () {
328
+ if (xhr.readyState === 4) {
329
+ if (xhr.status === 200) {
330
+ document.getElementById("themeColor").innerText = `:root{--lyx-theme:${xhr.responseText}!important}`;
331
+ }
332
+ }
333
+ }
334
+ }
335
+ toggleAutoTheme = () => {
336
+ if (localStorage.getItem("autoTheme") == "true") {
337
+ localStorage.setItem("autoTheme", "false");
338
+ $("#con-mode,.rightMenu-item:has(.fa-moon)").show();
339
+ }
340
+ else {
341
+ localStorage.setItem("autoTheme", "true");
342
+ var time = new Date();
343
+ if (time.getHours() <= 7 || time.getHours() >= 19) {
344
+ activateDarkMode()
345
+ localStorage.removeItem("theme");
346
+ }
347
+ else {
348
+ activateLightMode()
349
+ localStorage.removeItem("theme");
350
+ }
351
+ $("#con-mode,.rightMenu-item:has(.fa-moon)").hide();
352
+ }
353
+ }
353
354
  }