mirror of
https://github.com/xiaoqidun/ofdgo.git
synced 2026-11-01 00:03:53 +08:00
1 parent
cd191ac679
commit
2abc0b878c
6 files changed
+15
-7
No files matched your search
@@ -30,6 +30,13 @@
|
||||
report(error);
|
||||
});
|
||||
}
|
||||
async function flush() {
|
||||
let current;
|
||||
do {
|
||||
current = pending;
|
||||
await current;
|
||||
} while (current !== pending);
|
||||
}
|
||||
function set(value) {
|
||||
mode = value;
|
||||
apply();
|
||||
@@ -48,7 +55,7 @@
|
||||
mode = ["light", "dark"].includes(event.newValue) ? event.newValue : "system";
|
||||
apply();
|
||||
});
|
||||
window.ofdgoTheme = {set, connect(value, onError) {
|
||||
window.ofdgoTheme = {set, flush, connect(value, onError) {
|
||||
host = value;
|
||||
report = onError;
|
||||
const select = document.querySelector("#titleBarMaterial");
|
||||
|
||||
Reference in new issue
Block a user