todo preparado como pwa con branding correcto
@@ -2,9 +2,15 @@
|
||||
<html lang="es">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<link rel="icon" type="image/png" href="/favicon.png?v=2">
|
||||
<link rel="apple-touch-icon" href="/SnatchGame.png?v=2">
|
||||
<link rel="icon" type="image/png" href="/favicon.png?v=3">
|
||||
<link rel="apple-touch-icon" sizes="180x180" href="/pwa_icons/icon-180x180.png">
|
||||
<link rel="apple-touch-icon" sizes="167x167" href="/pwa_icons/icon-167x167.png">
|
||||
<link rel="apple-touch-icon" sizes="152x152" href="/pwa_icons/icon-152x152.png">
|
||||
<link rel="manifest" href="/manifest.webmanifest">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<meta name="theme-color" content="#111111">
|
||||
<meta name="mobile-web-app-capable" content="yes">
|
||||
<meta name="apple-mobile-web-app-status-bar-style" content="black-translucent">
|
||||
<meta name="description" content="SnatchGame - Arena de intercambio social. Juego competitivo de estrategia y negociación.">
|
||||
<meta name="keywords" content="juego, estrategia, competitivo, intercambio, social, tokens">
|
||||
<meta name="author" content="SnatchGame">
|
||||
@@ -27,4 +33,4 @@
|
||||
<div id="app"></div>
|
||||
<script type="module" src="/src/main.ts"></script>
|
||||
</body>
|
||||
</html>
|
||||
</html>
|
||||
|
||||
|
Before Width: | Height: | Size: 2.3 MiB |
26
client/public/manifest.webmanifest
Normal file
@@ -0,0 +1,26 @@
|
||||
{
|
||||
"name": "SnatchGame",
|
||||
"short_name": "SnatchGame",
|
||||
"description": "Arena de intercambio social. Juego competitivo de estrategia y negociación.",
|
||||
"id": "/",
|
||||
"start_url": "/",
|
||||
"scope": "/",
|
||||
"display": "standalone",
|
||||
"background_color": "#111111",
|
||||
"theme_color": "#111111",
|
||||
"icons": [
|
||||
{ "src": "/pwa_icons/icon-192x192.png", "sizes": "192x192", "type": "image/png", "purpose": "any" },
|
||||
{ "src": "/pwa_icons/icon-256x256.png", "sizes": "256x256", "type": "image/png", "purpose": "any" },
|
||||
{ "src": "/pwa_icons/icon-384x384.png", "sizes": "384x384", "type": "image/png", "purpose": "any" },
|
||||
{ "src": "/pwa_icons/icon-512x512.png", "sizes": "512x512", "type": "image/png", "purpose": "any" },
|
||||
{ "src": "/pwa_icons/icon-144x144.png", "sizes": "144x144", "type": "image/png", "purpose": "any" },
|
||||
{ "src": "/pwa_icons/icon-128x128.png", "sizes": "128x128", "type": "image/png", "purpose": "any" },
|
||||
{ "src": "/pwa_icons/icon-96x96.png", "sizes": "96x96", "type": "image/png", "purpose": "any" },
|
||||
{ "src": "/pwa_icons/icon-72x72.png", "sizes": "72x72", "type": "image/png", "purpose": "any" },
|
||||
{ "src": "/pwa_icons/icon-48x48.png", "sizes": "48x48", "type": "image/png", "purpose": "any" }
|
||||
],
|
||||
"screenshots": [
|
||||
{ "src": "/SnatchGame.png", "sizes": "992x1056", "type": "image/png", "form_factor": "wide", "label": "Juego - Escritorio" },
|
||||
{ "src": "/SnatchGame.png", "sizes": "992x1056", "type": "image/png", "label": "Juego - General" }
|
||||
]
|
||||
}
|
||||
BIN
client/public/pwa_icons/icon-128x128.png
Normal file
|
After Width: | Height: | Size: 13 KiB |
BIN
client/public/pwa_icons/icon-144x144.png
Normal file
|
After Width: | Height: | Size: 15 KiB |
BIN
client/public/pwa_icons/icon-152x152.png
Normal file
|
After Width: | Height: | Size: 17 KiB |
BIN
client/public/pwa_icons/icon-167x167.png
Normal file
|
After Width: | Height: | Size: 20 KiB |
BIN
client/public/pwa_icons/icon-180x180.png
Normal file
|
After Width: | Height: | Size: 22 KiB |
BIN
client/public/pwa_icons/icon-192x192.png
Normal file
|
After Width: | Height: | Size: 24 KiB |
BIN
client/public/pwa_icons/icon-256x256.png
Normal file
|
After Width: | Height: | Size: 39 KiB |
BIN
client/public/pwa_icons/icon-384x384.png
Normal file
|
After Width: | Height: | Size: 77 KiB |
BIN
client/public/pwa_icons/icon-48x48.png
Normal file
|
After Width: | Height: | Size: 3.0 KiB |
BIN
client/public/pwa_icons/icon-512x512.png
Normal file
|
After Width: | Height: | Size: 131 KiB |
BIN
client/public/pwa_icons/icon-72x72.png
Normal file
|
After Width: | Height: | Size: 5.5 KiB |
BIN
client/public/pwa_icons/icon-96x96.png
Normal file
|
After Width: | Height: | Size: 8.4 KiB |
15
client/public/sw.js
Normal file
@@ -0,0 +1,15 @@
|
||||
// Minimal service worker to enable PWA installability
|
||||
self.addEventListener("install", () => {
|
||||
// Activate immediately on install
|
||||
self.skipWaiting();
|
||||
});
|
||||
|
||||
self.addEventListener("activate", (event) => {
|
||||
event.waitUntil(self.clients.claim());
|
||||
});
|
||||
|
||||
// Provide a basic fetch handler (required by some browsers for installability)
|
||||
self.addEventListener("fetch", (event) => {
|
||||
event.respondWith(fetch(event.request));
|
||||
});
|
||||
|
||||
@@ -6,4 +6,13 @@ const app = createApp(App);
|
||||
|
||||
app.use(router);
|
||||
|
||||
app.mount('#app');
|
||||
app.mount('#app');
|
||||
|
||||
// Registrar Service Worker en producción para PWA
|
||||
if ('serviceWorker' in navigator && import.meta.env.PROD) {
|
||||
window.addEventListener('load', () => {
|
||||
navigator.serviceWorker.register('/sw.js').catch(() => {
|
||||
// no-op: registro del SW falló
|
||||
});
|
||||
});
|
||||
}
|
||||
|
||||