@capgo/inappbrowser 6.9.38 → 7.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -11,7 +11,7 @@ Pod::Spec.new do |s|
11
11
  s.author = package['author']
12
12
  s.source = { :git => package['repository']['url'], :tag => s.version.to_s }
13
13
  s.source_files = 'ios/Plugin/**/*.{swift,h,m,c,cc,mm,cpp}'
14
- s.ios.deployment_target = '13.0'
14
+ s.ios.deployment_target = '14.0'
15
15
  s.dependency 'Capacitor'
16
16
  s.swift_version = '5.1'
17
17
  end
@@ -1,9 +1,9 @@
1
1
  ext {
2
2
  junitVersion = project.hasProperty('junitVersion') ? rootProject.ext.junitVersion : '4.13.2'
3
- androidxAppCompatVersion = project.hasProperty('androidxAppCompatVersion') ? rootProject.ext.androidxAppCompatVersion : '1.6.1'
4
- androidxJunitVersion = project.hasProperty('androidxJunitVersion') ? rootProject.ext.androidxJunitVersion : '1.1.5'
5
- androidxEspressoCoreVersion = project.hasProperty('androidxEspressoCoreVersion') ? rootProject.ext.androidxEspressoCoreVersion : '3.5.1'
6
- androidxBrowserVersion = project.hasProperty('androidxBrowserVersion') ? rootProject.ext.androidxBrowserVersion : '1.7.0'
3
+ androidxAppCompatVersion = project.hasProperty('androidxAppCompatVersion') ? rootProject.ext.androidxAppCompatVersion : '1.7.0'
4
+ androidxJunitVersion = project.hasProperty('androidxJunitVersion') ? rootProject.ext.androidxJunitVersion : '1.2.1'
5
+ androidxEspressoCoreVersion = project.hasProperty('androidxEspressoCoreVersion') ? rootProject.ext.androidxEspressoCoreVersion : '3.6.1'
6
+ androidxBrowserVersion = project.hasProperty('androidxBrowserVersion') ? rootProject.ext.androidxBrowserVersion : '1.8.0'
7
7
  }
8
8
 
9
9
  buildscript {
@@ -20,10 +20,10 @@ apply plugin: 'com.android.library'
20
20
 
21
21
  android {
22
22
  namespace "ee.forgr.capacitor_inappbrowser"
23
- compileSdk project.hasProperty('compileSdkVersion') ? rootProject.ext.compileSdkVersion : 34
23
+ compileSdk project.hasProperty('compileSdkVersion') ? rootProject.ext.compileSdkVersion : 35
24
24
  defaultConfig {
25
- minSdkVersion project.hasProperty('minSdkVersion') ? rootProject.ext.minSdkVersion : 22
26
- targetSdkVersion project.hasProperty('targetSdkVersion') ? rootProject.ext.targetSdkVersion : 34
25
+ minSdkVersion project.hasProperty('minSdkVersion') ? rootProject.ext.minSdkVersion : 23
26
+ targetSdkVersion project.hasProperty('targetSdkVersion') ? rootProject.ext.targetSdkVersion : 35
27
27
  versionCode 1
28
28
  versionName "1.0"
29
29
  testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
@@ -38,8 +38,8 @@ android {
38
38
  abortOnError false
39
39
  }
40
40
  compileOptions {
41
- sourceCompatibility JavaVersion.VERSION_17
42
- targetCompatibility JavaVersion.VERSION_17
41
+ sourceCompatibility JavaVersion.VERSION_21
42
+ targetCompatibility JavaVersion.VERSION_21
43
43
  }
44
44
  }
45
45
 
@@ -7,5 +7,6 @@
7
7
  <data android:scheme="http" />
8
8
  </intent>
9
9
  </queries>
10
+ <uses-permission android:name="android.permission.READ_MEDIA_IMAGES"/>
10
11
  <uses-permission android:name="android.permission.CAMERA"/>
11
12
  </manifest>
@@ -45,6 +45,10 @@ import org.json.JSONObject;
45
45
  alias = "storage",
46
46
  strings = { Manifest.permission.READ_EXTERNAL_STORAGE }
47
47
  ),
48
+ @Permission(
49
+ alias = "storage",
50
+ strings = { Manifest.permission.READ_MEDIA_IMAGES }
51
+ ),
48
52
  },
49
53
  requestCodes = { WebViewDialog.FILE_CHOOSER_REQUEST_CODE }
50
54
  )
@@ -300,7 +300,6 @@ open class WKWebViewController: UIViewController, WKScriptMessageHandler {
300
300
  userContentController.add(self, name: "preShowScriptError")
301
301
  userContentController.add(self, name: "preShowScriptSuccess")
302
302
  webConfiguration.userContentController = userContentController
303
- webConfiguration.allowsInlineMediaPlayback = true
304
303
  let webView = WKWebView(frame: .zero, configuration: webConfiguration)
305
304
 
306
305
  if webView.responds(to: Selector(("setInspectable:"))) {
@@ -839,7 +838,14 @@ fileprivate extension WKWebViewController {
839
838
 
840
839
  // MARK: - WKUIDelegate
841
840
  extension WKWebViewController: WKUIDelegate {
842
-
841
+ public func webView(_ webView: WKWebView, runJavaScriptAlertPanelWithMessage message: String, initiatedByFrame frame: WKFrameInfo, completionHandler: @escaping () -> Void) {
842
+ // Ensure UI updates are on the main thread
843
+ DispatchQueue.main.async {
844
+ let alertController = UIAlertController(title: nil, message: message, preferredStyle: .alert)
845
+ self.present(alertController, animated: true, completion: nil)
846
+ }
847
+ completionHandler()
848
+ }
843
849
  }
844
850
 
845
851
  // MARK: - WKNavigationDelegate
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@capgo/inappbrowser",
3
- "version": "6.9.38",
3
+ "version": "7.1.1",
4
4
  "description": "Capacitor plugin in app browser",
5
5
  "main": "dist/plugin.cjs.js",
6
6
  "module": "dist/esm/index.js",
@@ -45,29 +45,29 @@
45
45
  "prepublishOnly": "npm run build"
46
46
  },
47
47
  "devDependencies": {
48
- "@capacitor/android": "^6.1.2",
49
- "@capacitor/cli": "^6.1.2",
50
- "@capacitor/core": "^6.1.2",
48
+ "@capacitor/android": "^7.0.0",
49
+ "@capacitor/cli": "^7.0.0",
50
+ "@capacitor/core": "^7.0.0",
51
51
  "@capacitor/docgen": "^0.3.0",
52
- "@capacitor/ios": "^6.1.2",
52
+ "@capacitor/ios": "^7.0.0",
53
53
  "@ionic/eslint-config": "^0.4.0",
54
54
  "@ionic/prettier-config": "^4.0.0",
55
55
  "@ionic/swiftlint-config": "^2.0.0",
56
56
  "@types/node": "^22.5.1",
57
57
  "@typescript-eslint/eslint-plugin": "^7.8.0",
58
58
  "@typescript-eslint/parser": "^7.8.0",
59
- "eslint": "^9.9.1",
59
+ "eslint": "^8.57.0",
60
60
  "eslint-plugin-import": "^2.29.1",
61
61
  "husky": "^9.1.5",
62
- "prettier": "^3.3.3",
63
- "prettier-plugin-java": "^2.6.5",
62
+ "prettier": "^3.4.2",
63
+ "prettier-plugin-java": "^2.6.6",
64
64
  "rimraf": "^6.0.1",
65
- "rollup": "^4.21.1",
65
+ "rollup": "^4.30.1",
66
66
  "swiftlint": "^2.0.0",
67
67
  "typescript": "^5.5.4"
68
68
  },
69
69
  "peerDependencies": {
70
- "@capacitor/core": "^6.0.0"
70
+ "@capacitor/core": ">=7.0.0"
71
71
  },
72
72
  "prettier": "@ionic/prettier-config",
73
73
  "swiftlint": "@ionic/swiftlint-config",