allow to return to default color

master
lauzonhomeschool 2022-12-28 21:56:59 -05:00 committed by GitHub
parent a3ad72df89
commit 5c64d5bdf5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 7 additions and 2 deletions

View File

@ -8,7 +8,8 @@
255: /*LANG*/"Cyan",
240: /*LANG*/"Green",
15: /*LANG*/"Blue",
0: /*LANG*/"Black"
0: /*LANG*/"Black",
null: /*LANG*/"Default"
};
const save = () => require('Storage').write('dragboard.json', settings);
@ -19,7 +20,11 @@
menu[label] = {
value: settings[key] == color,
onchange: () => {
settings[key] = color;
if (color) {
settings[key] = color;
} else {
delete settings[key];
}
save();
setTimeout(E.showMenu, 10, appMenu);
}