pushh
All checks were successful
/ upload (release) Successful in 31s

This commit is contained in:
pavel 2026-02-12 01:45:26 +01:00
commit e7d1dbe849
5 changed files with 0 additions and 0 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 30 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 33 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 27 KiB

View file

@ -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"
}
]
}

51
frontend/public/sw.js Normal file
View file

@ -0,0 +1,51 @@
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);
})
);
});
self.addEventListener('push', (event) => {
const data = event.data ? event.data.json() : { title: 'Notification', body: 'New update from Agency' };
const options = {
body: data.body,
icon: '/icon-192.png',
badge: '/icon-192.png',
vibrate: [100, 50, 100],
data: {
dateOfArrival: Date.now(),
primaryKey: '1'
}
};
event.waitUntil(
self.registration.showNotification(data.title, options)
);
});
self.addEventListener('notificationclick', (event) => {
event.notification.close();
event.waitUntil(
clients.openWindow('/')
);
});