Add Electron desktop shell
This commit is contained in:
1 parent
42c5f68182
commit
c646f66e8f
9 files changed
+4228
-5
No files matched your search
+1
-1
@@ -22,7 +22,7 @@ app.mount('#app')
|
||||
// In Chrome/Edge, an installed PWA runs in standalone display mode,
|
||||
// which removes the top-edge "exit fullscreen" indicator that tabs
|
||||
// show when the Fullscreen API is active.
|
||||
if ('serviceWorker' in navigator) {
|
||||
if ('serviceWorker' in navigator && !window.ruwioDesktop) {
|
||||
window.addEventListener('load', () => {
|
||||
navigator.serviceWorker.register('/sw.js').catch(() => {
|
||||
/* registration failed — app still works without PWA install */
|
||||
|
||||
Vendored
+14
@@ -0,0 +1,14 @@
|
||||
export {}
|
||||
|
||||
declare global {
|
||||
interface Window {
|
||||
ruwioDesktop?: {
|
||||
platform: 'aix' | 'android' | 'darwin' | 'freebsd' | 'haiku' | 'linux' | 'openbsd' | 'sunos' | 'win32' | 'cygwin' | 'netbsd'
|
||||
versions: {
|
||||
electron?: string
|
||||
chrome?: string
|
||||
node?: string
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user