humhub / app

22 stars 8 forks source link

Add Scope to Manifest #65

Closed ArchBlood closed 1 year ago

ArchBlood commented 1 year ago

Set start_url to the following while also adding scope, this can possibly help when it comes a few issues that I've noticed while testing the latest release for Android.

{
    "name": "humhub",
    "short_name": "humhub",
    "start_url": "/",
    "scope": ".",
    "display": "standalone",
    "background_color": "#0175C2",
    "theme_color": "#0175C2",
    "description": "HumHub App",
    "orientation": "portrait-primary",
    "prefer_related_applications": false,
    "icons": [
        {
            "src": "icons/Icon-192.png",
            "sizes": "192x192",
            "type": "image/png"
        },
        {
            "src": "icons/Icon-512.png",
            "sizes": "512x512",
            "type": "image/png"
        },
        {
            "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"
        }
    ]
}

https://web.dev/add-manifest/#scope

ArchBlood commented 1 year ago

This could probably fix #63

luke- commented 1 year ago

@ArchBlood Which issues fixes the scope in your tests? Regarding #63, we would need to add mulitple URLs to the scope e.g. http://humhub.example.com, https://github.com/oauth, https://twitter.com/oauth....

ArchBlood commented 1 year ago

I would think something like https://humhub.example.com/*/* would work just fine here, seems to work in PWA, I would have to do a recompile when I get to my office. :thinking:

ArchBlood commented 1 year ago

Here's an example that I've used which does work with a specified domain in the start_url

https://github.com/GreenMeteor/humhub-twa/blob/master/app/src/main/assets/manifest.json