Browse Source

Add pwa support

master
Christian Pauly 1 year ago
parent
commit
b786e2878f
  1. 8
      ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist
  2. 8
      ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings
  3. 8
      ios/Runner.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings
  4. 2
      web/browserconfig.xml
  5. BIN
      web/favicon.png
  6. BIN
      web/icons/Icon-192.png
  7. BIN
      web/icons/Icon-512.png
  8. 28
      web/index.html
  9. 28
      web/manifest.json

8
ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist

@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>IDEDidComputeMac32BitWarning</key>
<true/>
</dict>
</plist>

8
ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings

@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>PreviewsEnabled</key>
<false/>
</dict>
</plist>

8
ios/Runner.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings

@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>PreviewsEnabled</key>
<false/>
</dict>
</plist>

2
web/browserconfig.xml

@ -1,2 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<browserconfig><msapplication><tile><square70x70logo src="/ms-icon-70x70.png"/><square150x150logo src="/ms-icon-150x150.png"/><square310x310logo src="/ms-icon-310x310.png"/><TileColor>#ffffff</TileColor></tile></msapplication></browserconfig>

BIN
web/favicon.png

After

Width: 16  |  Height: 16  |  Size: 1.9 KiB

BIN
web/icons/Icon-192.png

After

Width: 192  |  Height: 192  |  Size: 12 KiB

BIN
web/icons/Icon-512.png

After

Width: 512  |  Height: 512  |  Size: 29 KiB

28
web/index.html

@ -2,14 +2,32 @@
<html>
<head>
<meta charset="UTF-8">
<link rel="manifest" href="manifest.json">
<link rel="shortcut icon" type="image/x-icon" href="assets/assets/favicon.png">
<meta name="msapplication-TileColor" content="#ffffff">
<meta name="msapplication-TileImage" content="/ms-icon-144x144.png">
<meta name="theme-color" content="#ffffff">
<meta content="IE=Edge" http-equiv="X-UA-Compatible">
<meta name="description" content="A new Flutter project.">
<!-- iOS meta tags & icons -->
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="apple-mobile-web-app-status-bar-style" content="black">
<meta name="apple-mobile-web-app-title" content="fluffychat">
<link rel="apple-touch-icon" href="icons/Icon-192.png">
<!-- Favicon -->
<link rel="shortcut icon" type="image/png" href="favicon.png"/>
<title>fluffychat</title>
<link rel="manifest" href="manifest.json">
</head>
<body>
<!-- This script installs service_worker.js to provide PWA functionality to
application. For more information, see:
https://developers.google.com/web/fundamentals/primers/service-workers -->
<script>
if ('serviceWorker' in navigator) {
window.addEventListener('load', function () {
navigator.serviceWorker.register('flutter_service_worker.js');
});
}
</script>
<script src="assets/assets/js/package/olm.js"></script>
<script defer src="sql-wasm.js"></script>
<script src="main.dart.js" type="application/javascript"></script>

28
web/manifest.json

@ -1,17 +1,23 @@
{
"short_name": "FluffyChat",
"name": "FluffyChat",
"description": "Chat with your friends",
"short_name": "FluffyChat",
"start_url": ".",
"display": "standalone",
"background_color": "#0175C2",
"theme_color": "#0175C2",
"description": "The cutest messenger in the Matrix network",
"orientation": "portrait-primary",
"prefer_related_applications": false,
"icons": [
{
"src": "assets/assets/logo.png",
"type": "image/png",
"sizes": "181x182"
"src": "icons/Icon-192.png",
"sizes": "192x192",
"type": "image/png"
},
{
"src": "icons/Icon-512.png",
"sizes": "512x512",
"type": "image/png"
}
],
"start_url": "https://christianpauly.gitlab.io/fluffychat-flutter",
"background_color": "#FFFFFF",
"display": "standalone",
"scope": "/",
"theme_color": "#5625BA"
]
}
Loading…
Cancel
Save