cordova-plugin-safariviewcontroller icon indicating copy to clipboard operation
cordova-plugin-safariviewcontroller copied to clipboard

Android 11 package visibility

Open ucsbricks opened this issue 3 years ago • 9 comments

Implemented fix discussed in #179. Tested and is working fine on my devices and emulators.

See https://developer.android.com/training/package-visibility for details.

ucsbricks avatar Jun 18 '21 08:06 ucsbricks

Thanks for sharing this fix. Would be great to get this merged; without it this plugin is broken on Android 11.

ldgfb avatar Aug 18 '21 12:08 ldgfb

As November 2021 deadline is approaching, any possibility to get this merged soon? Thank you very much!

slissner avatar Sep 23 '21 08:09 slissner

Is there any ETA to merge this PR and publish a new version? with the Android 12 coming out a 4th October, this will be a needed fix for any smartphone that uses Google Chrome as default browser.

SrPatinhas avatar Sep 29 '21 10:09 SrPatinhas

@EddyVerbruggen could you please have a look on this PR and merge it? Thanks.

ucsbricks avatar Sep 29 '21 11:09 ucsbricks

Agreed. This fix is great because, it works! I would LOVE for v2.0.1 of this plugin to get pushed out soon too, please! (:

alexneats avatar Nov 10 '21 15:11 alexneats

I have merged this pull request into my forked repository: https://github.com/slissner/cordova-plugin-safariviewcontroller/pull/1

Herewith I can confirm that the changes have worked with a real Pixel 5 Android 12 device.

Update: tried with simulator Pixel 5 Android 11 (API v30) device: It did not work.

slissner avatar Nov 15 '21 11:11 slissner

For those who try to test this pull request in a android simulator device: Make sure you have at least one browser (e.g. chrome) installed on your virtual device that supports the custom tabs functionality.

Background:

As mentioned in my previous comment, the custom tabs did not work on my simulator device. The problem was that by default no browser at all was installed on that device. After installing chromium, it worked well.

Where is Custom Tabs available?

Custom Tabs is a feature supported by browsers on the Android platform. It was originally introduced by Chrome, on version 45. Currently, the protocol is supported by most Android

Source: https://developer.chrome.com/docs/android/custom-tabs/#where-is-custom-tabs-available

How to install chrome on for an android emulator:

  • https://stackoverflow.com/questions/14747312/install-chrome-for-android-in-android-emulator
  • https://paul.kinlan.me/installing-chrome-for-android-on-an-emulator/

slissner avatar Nov 16 '21 14:11 slissner

@slissner

Update: tried with simulator Pixel 5 Android 11 (API v30) device: It did not work.

but it open WebView Modal

image

WuglyakBolgoink avatar Dec 07 '21 15:12 WuglyakBolgoink

as a fallback fix you can use my plugin

https://github.com/WuglyakBolgoink/cordova-plugin-quick-fix-svc

WuglyakBolgoink avatar Dec 07 '21 18:12 WuglyakBolgoink