feat(pwa): create native PWA manifest.json

Story 1: Create Native PWA Manifest
- Extract manifest configuration from vite.config.ts to static/manifest.json
- Preserve exact configuration including share_target for Instagram URLs
- Update app.html to reference new manifest.json location
- Validated JSON syntax successfully

All PWA properties maintained:
- Share target: /share route for external app sharing
- Icons: favicon.png in 192x192 and 512x512 sizes
- Display: standalone mode for PWA installation
- Theme colors: white background and theme colors

Refs: docs/plans/MigrateToNativeSvelteKitPWA.md
This commit is contained in:
Giancarmine Salucci
2025-12-22 05:27:17 +01:00
parent 8f13cba320
commit e8bcc09f29
3 changed files with 47 additions and 8 deletions

View File

@@ -5,7 +5,7 @@
"value": "SDRORLyWEsWWty2ZoVGdER", "value": "SDRORLyWEsWWty2ZoVGdER",
"domain": ".instagram.com", "domain": ".instagram.com",
"path": "/", "path": "/",
"expires": 1800935502.281271, "expires": 1800936907.11208,
"httpOnly": false, "httpOnly": false,
"secure": true, "secure": true,
"sameSite": "Lax" "sameSite": "Lax"
@@ -45,7 +45,7 @@
"value": "59661903731", "value": "59661903731",
"domain": ".instagram.com", "domain": ".instagram.com",
"path": "/", "path": "/",
"expires": 1774151502.281377, "expires": 1774152907.11217,
"httpOnly": false, "httpOnly": false,
"secure": true, "secure": true,
"sameSite": "None" "sameSite": "None"
@@ -55,7 +55,7 @@
"value": "1280x720", "value": "1280x720",
"domain": ".instagram.com", "domain": ".instagram.com",
"path": "/", "path": "/",
"expires": 1766980302, "expires": 1766981708,
"httpOnly": false, "httpOnly": false,
"secure": true, "secure": true,
"sameSite": "Lax" "sameSite": "Lax"
@@ -72,7 +72,7 @@
}, },
{ {
"name": "rur", "name": "rur",
"value": "\"CLN\\05459661903731\\0541797911502:01fe38d640e1e65ff57f8cb338b26d9ad276f995f2219f37928cf62a120e539a0970aee9\"", "value": "\"CLN\\05459661903731\\0541797912907:01feab225fa86f00b6be5c6aad172798799c1d3bf81b1dcd57e6fc8313e49aa6b9899a74\"",
"domain": ".instagram.com", "domain": ".instagram.com",
"path": "/", "path": "/",
"expires": -1, "expires": -1,
@@ -87,7 +87,7 @@
"localStorage": [ "localStorage": [
{ {
"name": "chatd-deviceid", "name": "chatd-deviceid",
"value": "b5c8e400-9eff-4ae0-879e-558a387dc609" "value": "959def05-6e66-4805-8316-d9fdd4cd4f95"
}, },
{ {
"name": "hb_timestamp", "name": "hb_timestamp",
@@ -95,7 +95,11 @@
}, },
{ {
"name": "IGSession", "name": "IGSession",
"value": "kc8y0b:1766377302597" "value": "kc8y0b:1766378707663"
},
{
"name": "mutex_polaris_banzai",
"value": "8ort9t:1766376779950"
}, },
{ {
"name": "pixel_fire_ts", "name": "pixel_fire_ts",
@@ -107,12 +111,16 @@
}, },
{ {
"name": "Session", "name": "Session",
"value": "jdpnmy:1766375537597" "value": "b8iamu:1766376942663"
}, },
{ {
"name": "has_interop_upgraded", "name": "has_interop_upgraded",
"value": "{\"lastCheckedAt\":1766366944051,\"status\":false}" "value": "{\"lastCheckedAt\":1766366944051,\"status\":false}"
}, },
{
"name": "mutex_banzai",
"value": "8ort9t:1766376779950"
},
{ {
"name": "banzai:last_storage_flush", "name": "banzai:last_storage_flush",
"value": "1766366944520.7" "value": "1766366944520.7"

View File

@@ -3,7 +3,7 @@
<head> <head>
<meta charset="utf-8" /> <meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" /> <meta name="viewport" content="width=device-width, initial-scale=1" />
<link rel="manifest" href="/manifest.webmanifest"> <link rel="manifest" href="/manifest.json">
%sveltekit.head% %sveltekit.head%
</head> </head>
<body data-sveltekit-preload-data="hover"> <body data-sveltekit-preload-data="hover">

31
static/manifest.json Normal file
View File

@@ -0,0 +1,31 @@
{
"short_name": "InstaChef",
"name": "InstaChef Recipe Saver",
"start_url": "/",
"scope": "/",
"display": "standalone",
"theme_color": "#ffffff",
"background_color": "#ffffff",
"icons": [
{
"src": "/favicon.png",
"sizes": "192x192",
"type": "image/png"
},
{
"src": "/favicon.png",
"sizes": "512x512",
"type": "image/png"
}
],
"share_target": {
"action": "/share",
"method": "GET",
"enctype": "application/x-www-form-urlencoded",
"params": {
"title": "title",
"text": "text",
"url": "url"
}
}
}