merge web app manifests (#708)

Right now here are 2 web app manifests:
- public/favicon/site.webmanifest
- public/manifest.json

But only the 1st one is referred in the html

This commit
- merged them into public/site.webmanifest (according to https://developer.mozilla.org/en-US/docs/Web/Progressive_web_apps/Add_to_home_screen#manifest, it should be in the root, whereas the spec suggests the `.webmanifest` extension
- complete the required fields

It now passes the Lighthouse PWA manifest test in Chrome
This commit is contained in:
proletarius101
2021-10-28 23:36:27 +08:00
committed by GitHub
parent fd6d83655c
commit 76a149c8ee
4 changed files with 41 additions and 27 deletions

View File

@@ -10,7 +10,7 @@
<link href="favicon/apple-touch-icon.png" rel="apple-touch-icon" sizes="180x180"></link>
<link href="favicon/favicon-32x32.png" rel="icon" sizes="32x32" type="image/png"></link>
<link href="favicon/favicon-16x16.png" rel="icon" sizes="16x16" type="image/png"></link>
<link href="favicon/site.webmanifest" rel="manifest"></link>
<link href="manifest.webmanifest" rel="manifest"></link>
<link color="#5bbad5" href="favicon/safari-pinned-tab.svg" rel="mask-icon"></link>
<meta name="theme-color" content="#ffffff">

View File

@@ -15,7 +15,7 @@
</link>
<link href="public/favicon/favicon-16x16.png" rel="icon" sizes="16x16" type="image/png">
</link>
<link href="public/favicon/site.webmanifest" rel="manifest">
<link href="public/manifest.webmanifest" rel="manifest">
</link>
<link color="#5bbad5" href="favicon/safari-pinned-tab.svg" rel="mask-icon">

View File

@@ -1,25 +0,0 @@
{
"app": {
"launch": {
"urls": [
"https://app.standardnotes.com/"
],
"web_url": "https://app.standardnotes.com",
"container": "tab"
}
},
"offline_enabled": true,
"permissions": [],
"requirements": {
"3D": {
"features": []
}
},
"icons": {
"128": "favicon/android-chrome-192x192.png"
},
"name": "Standard Notes",
"description": "A Simple And Private Notes App",
"version": "1.0",
"manifest_version": 2
}

View File

@@ -0,0 +1,39 @@
{
"app": {
"launch": {
"urls": [
"https://app.standardnotes.com/"
],
"web_url": "https://app.standardnotes.com",
"container": "tab"
}
},
"offline_enabled": true,
"permissions": [],
"requirements": {
"3D": {
"features": []
}
},
"icons": [
{
"src": "favicon/android-chrome-192x192.png",
"sizes": "192x192",
"type": "image/png"
},
{
"src": "favicon/android-chrome-512x512.png",
"sizes": "512x512",
"purpose": "any maskable",
"type": "image/png"
}
],
"name": "Standard Notes",
"description": "A Simple And Private Notes App",
"version": "1.0",
"manifest_version": 2,
"theme_color": "#ffffff",
"background_color": "#ffffff",
"display": "standalone",
"start_url": ".."
}