diff --git a/index.html b/index.html index 866789e..dc00edf 100644 --- a/index.html +++ b/index.html @@ -9,11 +9,13 @@ + + - +
diff --git a/public/manifest.json b/public/manifest.json index f6e0a24..37b4b3d 100644 --- a/public/manifest.json +++ b/public/manifest.json @@ -2,18 +2,32 @@ "name": "IndeedHub - Decentralized Media Streaming", "short_name": "IndeedHub", "description": "Stream films and content on the decentralized web powered by Nostr and Bitcoin", - "start_url": "/", + "start_url": "/?source=pwa", "scope": "/", "display": "standalone", + "orientation": "any", "background_color": "#0a0a0a", "theme_color": "#0a0a0a", + "prefer_related_applications": false, "icons": [ { "src": "/assets/images/app-icon.svg", - "sizes": "any", + "sizes": "192x192", "type": "image/svg+xml", "purpose": "any" }, + { + "src": "/assets/images/app-icon.svg", + "sizes": "512x512", + "type": "image/svg+xml", + "purpose": "any" + }, + { + "src": "/assets/images/app-icon.svg", + "sizes": "192x192", + "type": "image/svg+xml", + "purpose": "maskable" + }, { "src": "/assets/images/app-icon.svg", "sizes": "512x512", @@ -21,5 +35,7 @@ "purpose": "maskable" } ], - "categories": ["entertainment", "video", "streaming"] + "categories": ["entertainment", "video", "streaming"], + "lang": "en-US", + "dir": "ltr" } diff --git a/src/env.d.ts b/src/env.d.ts index 00b7e79..b9b0b9b 100644 --- a/src/env.d.ts +++ b/src/env.d.ts @@ -1,4 +1,5 @@ /// +/// declare module '*.vue' { import type { DefineComponent } from 'vue' diff --git a/src/main.ts b/src/main.ts index 4a4f2bf..f22791c 100644 --- a/src/main.ts +++ b/src/main.ts @@ -10,3 +10,12 @@ app.use(createPinia()) app.use(router) app.mount('#app') + +// Register PWA service worker +if ('serviceWorker' in navigator) { + window.addEventListener('load', () => { + navigator.serviceWorker.register('/sw.js').catch(() => { + // Service worker registration failed, that's okay + }) + }) +}