capacitor-community / photoviewer

⚡ Capacitor plugin to view table images with fullscreen and sharing capabilities.
MIT License
52 stars 25 forks source link

Compatibility with Capacitor 5 #41

Closed adnbrownie closed 1 year ago

adnbrownie commented 1 year ago

Describe the bug The plugin has configured source & target compatibility with JDK 11 (https://github.com/capacitor-community/photoviewer/blob/main/android/build.gradle#L45) as well as kotlinOptions with jvmTarget 17 (https://github.com/capacitor-community/photoviewer/blob/main/android/build.gradle#L49). Capacitor 5 requires AGP 8, which has JDK 17 as a prerequisite.

To Reproduce Install the plugin in an app with capacitor 5 (or upgrade an existing project with the plugin to capacitor 5).

Expected behavior Installation should work as expected. Either by no longer specifying the source & target compatibility within the plugin or by changing to JDK 17.

Additional context Additionally, the package name should be moved from the AndroidManifest.xml file to build.gradle in the android DSL with namespace (though some capacitor 5 auto-magically does this with a migration script for plugins which have not already done it themselves). This is a breaking change with AGP 8. And the peer dependencies should be updated to signal compatibility with capacitor 5.

adnbrownie commented 1 year ago

additional info can be found here: https://capacitorjs.com/docs/updating/5-0#upgrade-android-studio https://capacitorjs.com/docs/updating/5-0#move-package-to-buildgradle

jepiqueau commented 1 year ago

@adnbrownie it has not been converted yet to Capacitor5

anthonyplews commented 1 year ago

When is the conversion to Capacitor 5 scheduled to happen?

jepiqueau commented 1 year ago

@anthonyplews @adnbrownie You have a beta version published under the tag next can you please test it and revert to me in case of issues or success.

anthonyplews commented 1 year ago

@jepiqueau I can confirm that it works on both Android and iOS, thanks for the quick response.

jepiqueau commented 1 year ago

@anthonyplews thanks for your feedback i will publish it soon as the latest release

jcesarmobile commented 1 year ago

closing since version 3.0.0 of the plugin was released with Capacitor 5 support