Skip to content

Commit 7d94e1e

Browse files
committed
更新[BoxJs]: 修复上个版本首页加载变慢问题, 优化页面背景色 (跟随 iOS 主题)
1 parent 43c872e commit 7d94e1e

File tree

2 files changed

+11
-3
lines changed

2 files changed

+11
-3
lines changed

box/chavy.boxjs.html

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,14 @@
1616
[v-cloak] {
1717
display: none;
1818
}
19+
body {
20+
background: #fff;
21+
}
22+
@media (prefers-color-scheme: dark) {
23+
body {
24+
background: #121212;
25+
}
26+
}
1927
.text-pre-wrap {
2028
white-space: pre-wrap !important;
2129
}

box/chavy.boxjs.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
const $ = new Env('BoxJs')
22

3-
$.version = '0.7.1'
3+
$.version = '0.7.2'
44
$.versionType = 'beta'
55

66
// 存储`用户偏好`
@@ -21,7 +21,7 @@ $.json = $.name // `接口`类请求的响应体
2121
$.html = $.name // `页面`类请求的响应体
2222

2323
$.web = `https://cdn.jsdelivr.net/gh/chavyleung/scripts@${$.version}/box/chavy.boxjs.html`
24-
$.web = `http://192.168.50.109:8080/box/chavy.boxjs.html?_=${new Date().getTime()}`
24+
// $.web = `http://192.168.50.109:8080/box/chavy.boxjs.html?_=${new Date().getTime()}`
2525
// $.web = `http://192.168.8.112:8080/box/chavy.boxjs.html?_=${new Date().getTime()}`
2626

2727
!(async () => {
@@ -98,7 +98,7 @@ function getDomain(url) {
9898
*/
9999
async function handlePage() {
100100
const cache = $.getjson($.KEY_web_cache, null)
101-
if (cache && cache.version === $.version) {
101+
if (cache && cache.version !== $.version) {
102102
$.html = cache.cache
103103
} else {
104104
await $.http.get($.web).then(

0 commit comments

Comments
 (0)