diff --git a/frontend/apple-touch-icon.png b/frontend/apple-touch-icon.png new file mode 100644 index 0000000..a5ea0e4 Binary files /dev/null and b/frontend/apple-touch-icon.png differ diff --git a/frontend/icon-192.png b/frontend/icon-192.png new file mode 100644 index 0000000..b23b3c7 Binary files /dev/null and b/frontend/icon-192.png differ diff --git a/frontend/icon-512.png b/frontend/icon-512.png new file mode 100644 index 0000000..2905528 Binary files /dev/null and b/frontend/icon-512.png differ diff --git a/frontend/index.html b/frontend/index.html index 907ddcd..85feebd 100644 --- a/frontend/index.html +++ b/frontend/index.html @@ -4,6 +4,11 @@ + + + + + Antigravity Agent Dashboard diff --git a/frontend/manifest.json b/frontend/manifest.json new file mode 100644 index 0000000..5978a0c --- /dev/null +++ b/frontend/manifest.json @@ -0,0 +1,21 @@ +{ + "name": "Antigravity Agency Dashboard", + "short_name": "Agency", + "description": "Autonomous AI Agent Dashboard", + "start_url": "/", + "display": "standalone", + "background_color": "#0a0a0c", + "theme_color": "#5d5dff", + "icons": [ + { + "src": "icon-192.png", + "sizes": "192x192", + "type": "image/png" + }, + { + "src": "icon-512.png", + "sizes": "512x512", + "type": "image/png" + } + ] +} \ No newline at end of file diff --git a/frontend/src/main.js b/frontend/src/main.js index edf3959..53bcf50 100644 --- a/frontend/src/main.js +++ b/frontend/src/main.js @@ -797,3 +797,12 @@ if (window.location.pathname === '/callback' || window.location.search.includes( } else { initializeApp(); } + +// Register Service Worker for PWA +if ('serviceWorker' in navigator) { + window.addEventListener('load', () => { + navigator.serviceWorker.register('/sw.js') + .then(reg => console.log('SW registered', reg)) + .catch(err => console.error('SW registration failed', err)); + }); +} diff --git a/frontend/sw.js b/frontend/sw.js new file mode 100644 index 0000000..c58b0f7 --- /dev/null +++ b/frontend/sw.js @@ -0,0 +1,26 @@ +const CACHE_NAME = 'agency-cache-v1'; +const ASSETS = [ + '/', + '/index.html', + '/src/main.js', + '/src/style.css', + '/manifest.json', + '/icon-192.png', + '/icon-512.png' +]; + +self.addEventListener('install', (event) => { + event.waitUntil( + caches.open(CACHE_NAME).then((cache) => { + return cache.addAll(ASSETS); + }) + ); +}); + +self.addEventListener('fetch', (event) => { + event.respondWith( + caches.match(event.request).then((response) => { + return response || fetch(event.request); + }) + ); +});