feat: installable PWA (manifest, icons, minimal service worker)

- public/manifest.webmanifest with any + maskable icons (192/512)
- generated inbox-glyph icons in app palette, apple-touch-icon
- minimal no-cache service worker for installability; registered via client plugin
- head: manifest/icon links, mobile-web-app-capable

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
2026-06-11 08:00:22 +00:00
parent d4c734737b
commit 02adfd0dbe
10 changed files with 34 additions and 0 deletions

1
.gitignore vendored
View File

@@ -9,4 +9,5 @@ node_modules/
.DS_Store
.playwright-mcp/
*.png
!public/icons/*.png
.claude/

View File

@@ -0,0 +1,6 @@
export default defineNuxtPlugin(() => {
if (!("serviceWorker" in navigator)) return;
window.addEventListener("load", () => {
navigator.serviceWorker.register("/sw.js").catch(() => {});
});
});

View File

@@ -23,11 +23,15 @@ export default defineNuxtConfig({
{ name: "color-scheme", content: "light dark" },
{ name: "theme-color", media: "(prefers-color-scheme: light)", content: "#f4f1ea" },
{ name: "theme-color", media: "(prefers-color-scheme: dark)", content: "#181410" },
{ name: "mobile-web-app-capable", content: "yes" },
{ name: "apple-mobile-web-app-capable", content: "yes" },
{ name: "apple-mobile-web-app-status-bar-style", content: "default" },
{ name: "apple-mobile-web-app-title", content: "ClaudeDo" },
],
link: [
{ rel: "manifest", href: "/manifest.webmanifest" },
{ rel: "apple-touch-icon", href: "/icons/apple-touch-icon.png" },
{ rel: "icon", type: "image/png", sizes: "192x192", href: "/icons/icon-192.png" },
{ rel: "preconnect", href: "https://fonts.googleapis.com" },
{ rel: "preconnect", href: "https://fonts.gstatic.com", crossorigin: "" },
{

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.8 KiB

BIN
public/icons/icon-192.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.1 KiB

BIN
public/icons/icon-512.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.1 KiB

View File

@@ -0,0 +1,17 @@
{
"id": "/",
"name": "ClaudeDo Inbox",
"short_name": "ClaudeDo",
"description": "Task inbox for the ClaudeDo backlog",
"start_url": "/",
"scope": "/",
"display": "standalone",
"background_color": "#181410",
"theme_color": "#181410",
"icons": [
{ "src": "/icons/icon-192.png", "sizes": "192x192", "type": "image/png", "purpose": "any" },
{ "src": "/icons/icon-512.png", "sizes": "512x512", "type": "image/png", "purpose": "any" },
{ "src": "/icons/icon-maskable-192.png", "sizes": "192x192", "type": "image/png", "purpose": "maskable" },
{ "src": "/icons/icon-maskable-512.png", "sizes": "512x512", "type": "image/png", "purpose": "maskable" }
]
}

6
public/sw.js Normal file
View File

@@ -0,0 +1,6 @@
// Minimal service worker: enables PWA installability across browsers.
// Intentionally no caching — the app is a private, auth-gated SPA and stale
// assets after a deploy are worse than requiring a connection.
self.addEventListener("install", () => self.skipWaiting());
self.addEventListener("activate", (event) => event.waitUntil(self.clients.claim()));
self.addEventListener("fetch", () => {});