fix: ♻️ Manifest (icons, name, orientation)

Closes #10694
This commit is contained in:
ThatOneCalculator 2023-09-01 17:40:57 -07:00
parent 2fb65cdd86
commit 9ea5cc3f5f
No known key found for this signature in database
GPG Key ID: 8703CACD01000000
6 changed files with 2 additions and 3 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 13 KiB

After

Width:  |  Height:  |  Size: 6.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 124 KiB

After

Width:  |  Height:  |  Size: 19 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 17 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 8.8 KiB

After

Width:  |  Height:  |  Size: 8.0 KiB

View File

@ -6,7 +6,7 @@
"display": "standalone", "display": "standalone",
"background_color": "#1f1d2e", "background_color": "#1f1d2e",
"theme_color": "#31748f", "theme_color": "#31748f",
"orientation": "portrait-primary", "orientation": "any",
"icons": [ "icons": [
{ {
"src": "/static-assets/icons/192.png", "src": "/static-assets/icons/192.png",
@ -21,7 +21,7 @@
"purpose": "any" "purpose": "any"
}, },
{ {
"src": "/static-assets/icons/maskable.png", "src": "/static-assets/icons/512.png",
"sizes": "512x512", "sizes": "512x512",
"type": "image/png", "type": "image/png",
"purpose": "maskable" "purpose": "maskable"

View File

@ -11,7 +11,6 @@ export const manifestHandler = async (ctx: Koa.Context) => {
const instance = await fetchMeta(true); const instance = await fetchMeta(true);
res.short_name = instance.name || "Firefish"; res.short_name = instance.name || "Firefish";
res.name = instance.name || "Firefish";
if (instance.themeColor) res.theme_color = instance.themeColor; if (instance.themeColor) res.theme_color = instance.themeColor;
for (const icon of res.icons) { for (const icon of res.icons) {
icon.src = `${icon.src}?v=${config.version.replace(/[^0-9]/g, "")}`; icon.src = `${icon.src}?v=${config.version.replace(/[^0-9]/g, "")}`;