diff --git a/public/apple-touch-icon.png b/public/apple-touch-icon.png new file mode 100644 index 0000000..387d88f Binary files /dev/null and b/public/apple-touch-icon.png differ diff --git a/public/manifest.webmanifest b/public/manifest.webmanifest new file mode 100644 index 0000000..6f20f1d --- /dev/null +++ b/public/manifest.webmanifest @@ -0,0 +1,30 @@ +{ + "name": "PokeShare", + "short_name": "PokeShare", + "description": "Gérez et partagez votre collection de cartes Pokémon TCG.", + "start_url": "/", + "scope": "/", + "display": "standalone", + "background_color": "#0a0a0a", + "theme_color": "#ee1515", + "icons": [ + { + "src": "/pwa-192.png", + "sizes": "192x192", + "type": "image/png", + "purpose": "any" + }, + { + "src": "/pwa-512.png", + "sizes": "512x512", + "type": "image/png", + "purpose": "any" + }, + { + "src": "/pwa-maskable-512.png", + "sizes": "512x512", + "type": "image/png", + "purpose": "maskable" + } + ] +} diff --git a/public/pwa-192.png b/public/pwa-192.png new file mode 100644 index 0000000..2935071 Binary files /dev/null and b/public/pwa-192.png differ diff --git a/public/pwa-512.png b/public/pwa-512.png new file mode 100644 index 0000000..c536cf0 Binary files /dev/null and b/public/pwa-512.png differ diff --git a/public/pwa-maskable-512.png b/public/pwa-maskable-512.png new file mode 100644 index 0000000..f7f2bd6 Binary files /dev/null and b/public/pwa-maskable-512.png differ diff --git a/public/sw.js b/public/sw.js new file mode 100644 index 0000000..1e992ca --- /dev/null +++ b/public/sw.js @@ -0,0 +1,16 @@ +/** + * Minimal service worker — network pass-through. + * Its only job is to make the app installable (browsers require a service + * worker to offer "Install app"); no offline caching for now. + */ +self.addEventListener("install", (event) => { + self.skipWaiting(); +}); + +self.addEventListener("activate", (event) => { + event.waitUntil(clients.claim()); +}); + +self.addEventListener("fetch", (event) => { + event.respondWith(fetch(event.request)); +}); diff --git a/src/layouts/BaseLayout.astro b/src/layouts/BaseLayout.astro index 82fbb20..d6aa556 100644 --- a/src/layouts/BaseLayout.astro +++ b/src/layouts/BaseLayout.astro @@ -26,6 +26,16 @@ if (themePreference === "Dark") { + + + + + + +