first commit

This commit is contained in:
Tomas Dvorak
2026-04-10 12:04:09 +02:00
commit 3cb40adb23
203 changed files with 40226 additions and 0 deletions
Binary file not shown.

After

Width:  |  Height:  |  Size: 664 B

+17
View File
@@ -0,0 +1,17 @@
{
"name": "Productier",
"short_name": "Productier",
"description": "Calm planning, boards, notes, and focus sessions in a lightweight PWA.",
"start_url": "/",
"display": "standalone",
"background_color": "#f4efe8",
"theme_color": "#e57d7d",
"icons": [
{
"src": "/favicon.ico",
"sizes": "48x48",
"type": "image/x-icon"
}
]
}
+37
View File
@@ -0,0 +1,37 @@
const CACHE_NAME = "productier-v1";
const PRECACHE = ["/", "/manifest.json", "/favicon.ico"];
self.addEventListener("install", event => {
event.waitUntil(caches.open(CACHE_NAME).then(cache => cache.addAll(PRECACHE)));
});
self.addEventListener("activate", event => {
event.waitUntil(
caches.keys().then(keys =>
Promise.all(keys.filter(key => key !== CACHE_NAME).map(key => caches.delete(key))),
),
);
});
self.addEventListener("fetch", event => {
if (event.request.method !== "GET") {
return;
}
event.respondWith(
caches.match(event.request).then(cached => {
if (cached) {
return cached;
}
return fetch(event.request)
.then(response => {
const copy = response.clone();
caches.open(CACHE_NAME).then(cache => cache.put(event.request, copy));
return response;
})
.catch(() => caches.match("/"));
}),
);
});