@totalpave/cordova-plugin-insets 0.1.9 → 0.1.10

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@totalpave/cordova-plugin-insets",
3
- "version": "0.1.9",
3
+ "version": "0.1.10",
4
4
  "description": "Cordova Android Plugin to receive native information regarding the unsafe area insets.",
5
5
  "main": "www/insets.js",
6
6
  "types": "www/api.d.ts",
@@ -25,19 +25,19 @@
25
25
  },
26
26
  "homepage": "https://github.com/totalpaveinc/cordova-plugin-insets#readme",
27
27
  "devDependencies": {
28
- "@babel/core": "7.22.8",
29
- "@babel/preset-env": "7.22.7",
30
- "@babel/preset-typescript": "7.22.5",
31
- "@babel/register": "7.22.5",
28
+ "@babel/core": "7.23.2",
29
+ "@babel/preset-env": "7.23.2",
30
+ "@babel/preset-typescript": "7.23.2",
31
+ "@babel/register": "7.22.15",
32
32
  "@rollup/plugin-babel": "6.0.3",
33
33
  "@rollup/plugin-commonjs": "25.0.2",
34
34
  "@rollup/plugin-node-resolve": "15.1.0",
35
- "@types/cordova": "11.0.0",
35
+ "@types/cordova": "11.0.2",
36
36
  "rollup": "3.26.2",
37
37
  "rollup-plugin-progress": "1.1.2",
38
38
  "rollup-plugin-typescript2": "0.35.0",
39
39
  "ts-node": "10.9.1",
40
- "typescript": "5.1.6"
40
+ "typescript": "5.2.2"
41
41
  },
42
42
  "engines": {
43
43
  "cordovaDependencies": {
@@ -47,6 +47,6 @@
47
47
  }
48
48
  },
49
49
  "dependencies": {
50
- "tslib": "2.6.0"
50
+ "tslib": "2.6.2"
51
51
  }
52
52
  }
@@ -43,7 +43,8 @@ public class Insets extends CordovaPlugin {
43
43
  float density = this.cordova.getActivity().getResources().getDisplayMetrics().density;
44
44
 
45
45
  // Ideally, we'd import this, but it shares the same name as our plugin
46
- androidx.core.graphics.Insets insets = insetProvider.getInsets(WindowInsetsCompat.Type.systemBars());
46
+ int insetTypes = WindowInsetsCompat.Type.displayCutout() | WindowInsetsCompat.Type.systemBars();
47
+ androidx.core.graphics.Insets insets = insetProvider.getInsets(insetTypes);
47
48
 
48
49
  result.put("top", insets.top / density);
49
50
  result.put("right", insets.right / density);