add install/uninstall options in the setup menu
This commit is contained in:
parent
ed11fbd82a
commit
783f39bb4e
8 changed files with 41 additions and 10 deletions
|
|
@ -1,11 +1,10 @@
|
|||
// --- configurable ---
|
||||
const CACHE_VERSION = 'boot-001';
|
||||
const BUNDLE_URL = '/boot/bundle.bin';
|
||||
const VERSION_KEY = '/__version__';
|
||||
|
||||
let loaded = 0;
|
||||
let mode = 'cached';
|
||||
let currentVersion = null;
|
||||
let BUNDLE_URL = '/boot/bundle.bin';
|
||||
|
||||
// --- logging ---
|
||||
const log = (...a) => console.log('[SW]', ...a);
|
||||
|
|
@ -30,6 +29,7 @@ self.addEventListener('message', e => {
|
|||
unregister();
|
||||
} else if (version !== undefined) {
|
||||
mode = 'cached';
|
||||
BUNDLE_URL = `/boot/bundle-${version}.bin`;
|
||||
log('version', version);
|
||||
ensureVersion(version);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -229,6 +229,15 @@
|
|||
<label lk="prefs">prefs</label>
|
||||
<span><i class="fa-solid fa-square-check"></i></span>
|
||||
</div>
|
||||
<hr>
|
||||
<div id="install">
|
||||
<label lk="install">install</label>
|
||||
<span><i class="fa-solid fa-plus"></i></span>
|
||||
</div>
|
||||
<div id="uninstall" class="hide">
|
||||
<label lk="uninstall">uninstall</label>
|
||||
<span><i class="fa-solid fa-trash"></i></span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</span>
|
||||
|
|
|
|||
|
|
@ -27,6 +27,7 @@ self.lang['en-us'] = {
|
|||
hide: "hide", // left render pop menu (invisible)
|
||||
home: "home",
|
||||
import: "import",
|
||||
install: "install",
|
||||
language: "language",
|
||||
left: "left",
|
||||
machines: "machines", // device or machine
|
||||
|
|
@ -58,6 +59,7 @@ self.lang['en-us'] = {
|
|||
tools: "tools", // CAM tool menu button
|
||||
top: "top",
|
||||
type: "type", // CAM tool type
|
||||
uninstall: "uninstall",
|
||||
version: "version",
|
||||
view: "view", // left view pop menu
|
||||
wire: "wire", // left render pop menu
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
"name": "Kiri:Moto 4.4.0",
|
||||
"short_name": "Kiri:Moto",
|
||||
"description": "Slicer for 3D printers, CNC mills, laser cutters and more",
|
||||
"start_url": "/kiri/",
|
||||
"start_url": "/boot/",
|
||||
"id": "/kiri/",
|
||||
"display": "standalone",
|
||||
"theme_color": "#7e99b7",
|
||||
|
|
|
|||
Loading…
Reference in a new issue