google / physical-web

The Physical Web: walk up and use anything
http://physical-web.org
Apache License 2.0
6k stars 667 forks source link

Don't force users to use chrome-custom-tabs #914

Open BryceEWatson opened 7 years ago

BryceEWatson commented 7 years ago

The recent change to have nearby URLs open in chrome custom tabs takes away functionality that we had when using the default Chrome browser. Web app manifest files are no longer supported, for example.

It seems that the purpose of chrome custom tabs is to help app developers customize their web browse experience when linking out of their app to a web url. This doesn't fit for the nearby notifications flow, where we generally want users to have the full, default, Chrome browser experience. The way it is now, with custom tabs, it is more like we are always within the nearby app "sandbox". I think there is more utility in using Nearby as a gateway to a full Chrome web page, instead of moving towards loading web pages within the Nearby app at all times.

Please allow us to somehow opt out of using chrome custom tabs with Nearby notifications, or (even better) don't use chrome custom tabs at all. I am also open to the idea that custom tabs will keep improving to stay on-par with the default Chrome browser, but the current documentation doesn't suggest that it will.

We've reported a few bugs against chromium:

FCM click_action not working in custom tabs: https://bugs.chromium.org/p/chromium/issues/detail?id=731471 Add to home screen not working in custom tabs: https://bugs.chromium.org/p/chromium/issues/detail?id=731171

BryceEWatson commented 7 years ago

Update: I also discovered that the click_action for FCM notifications does not work properly when using chrome custom tabs. If you go from nearby notification -> chrome custom tabs, and from there you subscribe to an FCM notification, then background the app, the click_action will not re-open chrome custom tabs when you click on the notification. However, if you subscribe using default Chrome it will work, and clicking the notification will open the url in chrome.

I'm not sure if these are bugs with chrome custom tabs, or if nearby is using chrome custom tabs when it shouldn't be, but there are definitely some blocking issues with using custom tabs.