@bbki.ng/site 1.1.8 → 1.1.10
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.
package/CHANGELOG.md
CHANGED
package/package.json
CHANGED
|
@@ -15,43 +15,30 @@ export const ReloadPrompt = () => {
|
|
|
15
15
|
onOfflineReady() {
|
|
16
16
|
console.log("App is offline-ready");
|
|
17
17
|
toast("", {
|
|
18
|
-
description: "
|
|
18
|
+
description: "已支持离线访问",
|
|
19
19
|
position: "bottom-center",
|
|
20
|
-
actionButtonStyle: {
|
|
21
|
-
backgroundColor: "#fff",
|
|
22
|
-
color: "rgb(37,99,235)",
|
|
23
|
-
},
|
|
24
20
|
});
|
|
25
21
|
},
|
|
26
22
|
});
|
|
27
23
|
|
|
28
|
-
// @ts-ignore
|
|
29
|
-
const appVer = GLOBAL_BBKING_VERSION;
|
|
30
|
-
|
|
31
24
|
useEffect(() => {
|
|
32
25
|
if (!needRefresh) {
|
|
33
|
-
console.log("
|
|
26
|
+
console.log("无需更新");
|
|
34
27
|
return;
|
|
35
28
|
}
|
|
36
29
|
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
}
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
setNeedRefresh(false);
|
|
50
|
-
return;
|
|
51
|
-
}
|
|
52
|
-
updateServiceWorker(true);
|
|
53
|
-
},
|
|
54
|
-
},
|
|
30
|
+
updateServiceWorker(true).then(() => {
|
|
31
|
+
// @ts-ignore
|
|
32
|
+
const appVer = GLOBAL_BBKING_VERSION;
|
|
33
|
+
|
|
34
|
+
toast("", {
|
|
35
|
+
description: "已自动更新到 v" + appVer + "。",
|
|
36
|
+
position: "bottom-center",
|
|
37
|
+
});
|
|
38
|
+
|
|
39
|
+
if (!needRefresh) {
|
|
40
|
+
setNeedRefresh(false);
|
|
41
|
+
}
|
|
55
42
|
});
|
|
56
43
|
}, [needRefresh]);
|
|
57
44
|
|