@capgo/capacitor-screen-recorder 1.2.53 → 3.0.0

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.
@@ -1,19 +1,19 @@
1
1
  buildscript {
2
2
  ext {
3
- junitVersion = project.hasProperty('junitVersion') ? rootProject.ext.junitVersion : '4.13.2'
4
- androidxJunitVersion = project.hasProperty('androidxJunitVersion') ? rootProject.ext.androidxJunitVersion : '1.1.4'
5
- androidxEspressoCoreVersion = project.hasProperty('androidxEspressoCoreVersion') ? rootProject.ext.androidxEspressoCoreVersion : '3.5.0'
6
- androidxAppCompatVersion = project.hasProperty('androidxAppCompatVersion') ? rootProject.ext.androidxAppCompatVersion : '1.4.2'
7
- androidxCoreVersion = project.hasProperty('androidxCoreVersion') ? rootProject.ext.androidxCoreVersion : '1.8.0'
8
- kotlinVersion = project.hasProperty('kotlinVersion') ? rootProject.ext.kotlinVersion : '1.7.21'
3
+ junitVersion = project.hasProperty('junitVersion') ? rootProject.ext.junitVersion : '4.13.2'
4
+ androidxJunitVersion = project.hasProperty('androidxJunitVersion') ? rootProject.ext.androidxJunitVersion : '1.1.5'
5
+ androidxEspressoCoreVersion = project.hasProperty('androidxEspressoCoreVersion') ? rootProject.ext.androidxEspressoCoreVersion : '3.5.1'
6
+ androidxAppCompatVersion = project.hasProperty('androidxAppCompatVersion') ? rootProject.ext.androidxAppCompatVersion : '1.6.1'
7
+ androidxCoreVersion = project.hasProperty('androidxCoreVersion') ? rootProject.ext.androidxCoreVersion : '1.10.0'
8
+ kotlin_version = project.hasProperty('kotlin_version') ? rootProject.ext.kotlin_version : '1.7.21'
9
9
  }
10
10
  repositories {
11
11
  google()
12
12
  mavenCentral()
13
13
  }
14
14
  dependencies {
15
- classpath 'com.android.tools.build:gradle:7.3.1'
16
- classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlinVersion"
15
+ classpath 'com.android.tools.build:gradle:8.0.0'
16
+ classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
17
17
  }
18
18
  }
19
19
 
@@ -22,10 +22,10 @@ apply plugin: 'kotlin-android'
22
22
 
23
23
  android {
24
24
  namespace "ee.forgr.plugin.screenrecorder"
25
- compileSdkVersion project.hasProperty('compileSdkVersion') ? rootProject.ext.compileSdkVersion : 32
25
+ compileSdkVersion project.hasProperty('compileSdkVersion') ? rootProject.ext.compileSdkVersion : 33
26
26
  defaultConfig {
27
27
  minSdkVersion project.hasProperty('minSdkVersion') ? rootProject.ext.minSdkVersion : 23
28
- targetSdkVersion project.hasProperty('targetSdkVersion') ? rootProject.ext.targetSdkVersion : 32
28
+ targetSdkVersion project.hasProperty('targetSdkVersion') ? rootProject.ext.targetSdkVersion : 33
29
29
  versionCode 1
30
30
  versionName "1.0"
31
31
  testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
@@ -40,8 +40,8 @@ android {
40
40
  abortOnError false
41
41
  }
42
42
  compileOptions {
43
- sourceCompatibility JavaVersion.VERSION_11
44
- targetCompatibility JavaVersion.VERSION_11
43
+ sourceCompatibility JavaVersion.VERSION_17
44
+ targetCompatibility JavaVersion.VERSION_17
45
45
  }
46
46
  kotlinOptions {
47
47
  jvmTarget = '11'
@@ -61,6 +61,6 @@ dependencies {
61
61
  androidTestImplementation "androidx.test.ext:junit:$androidxJunitVersion"
62
62
  androidTestImplementation "androidx.test.espresso:espresso-core:$androidxEspressoCoreVersion"
63
63
  implementation "androidx.core:core-ktx:$androidxCoreVersion"
64
- implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlinVersion"
64
+ implementation "org.jetbrains.kotlin:kotlin-stdlib:$kotlin_version"
65
65
  implementation ("dev.bmcreations:scrcast:0.3.0")
66
66
  }
@@ -10,24 +10,24 @@ import dev.bmcreations.scrcast.config.Options;
10
10
  @CapacitorPlugin(name = "ScreenRecorder")
11
11
  public class ScreenRecorderPlugin extends Plugin {
12
12
 
13
- private ScrCast recorder;
13
+ private ScrCast recorder;
14
14
 
15
- @Override
16
- public void load() {
17
- recorder = ScrCast.use(this.bridge.getActivity());
18
- Options options = new Options();
19
- recorder.updateOptions(options);
20
- }
15
+ @Override
16
+ public void load() {
17
+ recorder = ScrCast.use(this.bridge.getActivity());
18
+ Options options = new Options();
19
+ recorder.updateOptions(options);
20
+ }
21
21
 
22
- @PluginMethod
23
- public void start(PluginCall call) {
24
- recorder.record();
25
- call.resolve();
26
- }
22
+ @PluginMethod
23
+ public void start(PluginCall call) {
24
+ recorder.record();
25
+ call.resolve();
26
+ }
27
27
 
28
- @PluginMethod
29
- public void stop(PluginCall call) {
30
- recorder.stopRecording();
31
- call.resolve();
32
- }
28
+ @PluginMethod
29
+ public void stop(PluginCall call) {
30
+ recorder.stopRecording();
31
+ call.resolve();
32
+ }
33
33
  }
@@ -1,4 +1,4 @@
1
- import type { ScreenRecorderPlugin } from './definitions';
1
+ import type { ScreenRecorderPlugin } from "./definitions";
2
2
  declare const ScreenRecorder: ScreenRecorderPlugin;
3
- export * from './definitions';
3
+ export * from "./definitions";
4
4
  export { ScreenRecorder };
package/dist/esm/index.js CHANGED
@@ -1,7 +1,7 @@
1
- import { registerPlugin } from '@capacitor/core';
2
- const ScreenRecorder = registerPlugin('ScreenRecorder', {
3
- web: () => import('./web').then((m) => new m.ScreenRecorderWeb()),
1
+ import { registerPlugin } from "@capacitor/core";
2
+ const ScreenRecorder = registerPlugin("ScreenRecorder", {
3
+ web: () => import("./web").then((m) => new m.ScreenRecorderWeb()),
4
4
  });
5
- export * from './definitions';
5
+ export * from "./definitions";
6
6
  export { ScreenRecorder };
7
7
  //# sourceMappingURL=index.js.map
package/dist/esm/web.d.ts CHANGED
@@ -1,5 +1,5 @@
1
- import { WebPlugin } from '@capacitor/core';
2
- import type { ScreenRecorderPlugin } from './definitions';
1
+ import { WebPlugin } from "@capacitor/core";
2
+ import type { ScreenRecorderPlugin } from "./definitions";
3
3
  export declare class ScreenRecorderWeb extends WebPlugin implements ScreenRecorderPlugin {
4
4
  start(): Promise<void>;
5
5
  stop(): Promise<void>;
package/dist/esm/web.js CHANGED
@@ -1,10 +1,10 @@
1
- import { WebPlugin } from '@capacitor/core';
1
+ import { WebPlugin } from "@capacitor/core";
2
2
  export class ScreenRecorderWeb extends WebPlugin {
3
3
  async start() {
4
- throw new Error('Method not implemented.');
4
+ throw new Error("Method not implemented.");
5
5
  }
6
6
  async stop() {
7
- throw new Error('Method not implemented.');
7
+ throw new Error("Method not implemented.");
8
8
  }
9
9
  }
10
10
  //# sourceMappingURL=web.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"web.js","sourceRoot":"","sources":["../../src/web.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAI5C,MAAM,OAAO,iBAAkB,SAAQ,SAAS;IAC9C,KAAK,CAAC,KAAK;QACT,MAAM,IAAI,KAAK,CAAC,yBAAyB,CAAC,CAAC;IAC7C,CAAC;IACD,KAAK,CAAC,IAAI;QACR,MAAM,IAAI,KAAK,CAAC,yBAAyB,CAAC,CAAC;IAC7C,CAAC;CACF"}
1
+ {"version":3,"file":"web.js","sourceRoot":"","sources":["../../src/web.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAI5C,MAAM,OAAO,iBACX,SAAQ,SAAS;IAGjB,KAAK,CAAC,KAAK;QACT,MAAM,IAAI,KAAK,CAAC,yBAAyB,CAAC,CAAC;IAC7C,CAAC;IACD,KAAK,CAAC,IAAI;QACR,MAAM,IAAI,KAAK,CAAC,yBAAyB,CAAC,CAAC;IAC7C,CAAC;CACF"}
@@ -2,16 +2,16 @@
2
2
 
3
3
  var core = require('@capacitor/core');
4
4
 
5
- const ScreenRecorder = core.registerPlugin('ScreenRecorder', {
5
+ const ScreenRecorder = core.registerPlugin("ScreenRecorder", {
6
6
  web: () => Promise.resolve().then(function () { return web; }).then((m) => new m.ScreenRecorderWeb()),
7
7
  });
8
8
 
9
9
  class ScreenRecorderWeb extends core.WebPlugin {
10
10
  async start() {
11
- throw new Error('Method not implemented.');
11
+ throw new Error("Method not implemented.");
12
12
  }
13
13
  async stop() {
14
- throw new Error('Method not implemented.');
14
+ throw new Error("Method not implemented.");
15
15
  }
16
16
  }
17
17
 
@@ -1 +1 @@
1
- {"version":3,"file":"plugin.cjs.js","sources":["esm/index.js","esm/web.js"],"sourcesContent":["import { registerPlugin } from '@capacitor/core';\nconst ScreenRecorder = registerPlugin('ScreenRecorder', {\n web: () => import('./web').then((m) => new m.ScreenRecorderWeb()),\n});\nexport * from './definitions';\nexport { ScreenRecorder };\n//# sourceMappingURL=index.js.map","import { WebPlugin } from '@capacitor/core';\nexport class ScreenRecorderWeb extends WebPlugin {\n async start() {\n throw new Error('Method not implemented.');\n }\n async stop() {\n throw new Error('Method not implemented.');\n }\n}\n//# sourceMappingURL=web.js.map"],"names":["registerPlugin","WebPlugin"],"mappings":";;;;AACK,MAAC,cAAc,GAAGA,mBAAc,CAAC,gBAAgB,EAAE;AACxD,IAAI,GAAG,EAAE,MAAM,mDAAe,CAAC,IAAI,CAAC,CAAC,CAAC,KAAK,IAAI,CAAC,CAAC,iBAAiB,EAAE,CAAC;AACrE,CAAC;;ACFM,MAAM,iBAAiB,SAASC,cAAS,CAAC;AACjD,IAAI,MAAM,KAAK,GAAG;AAClB,QAAQ,MAAM,IAAI,KAAK,CAAC,yBAAyB,CAAC,CAAC;AACnD,KAAK;AACL,IAAI,MAAM,IAAI,GAAG;AACjB,QAAQ,MAAM,IAAI,KAAK,CAAC,yBAAyB,CAAC,CAAC;AACnD,KAAK;AACL;;;;;;;;;"}
1
+ {"version":3,"file":"plugin.cjs.js","sources":["esm/index.js","esm/web.js"],"sourcesContent":["import { registerPlugin } from \"@capacitor/core\";\nconst ScreenRecorder = registerPlugin(\"ScreenRecorder\", {\n web: () => import(\"./web\").then((m) => new m.ScreenRecorderWeb()),\n});\nexport * from \"./definitions\";\nexport { ScreenRecorder };\n//# sourceMappingURL=index.js.map","import { WebPlugin } from \"@capacitor/core\";\nexport class ScreenRecorderWeb extends WebPlugin {\n async start() {\n throw new Error(\"Method not implemented.\");\n }\n async stop() {\n throw new Error(\"Method not implemented.\");\n }\n}\n//# sourceMappingURL=web.js.map"],"names":["registerPlugin","WebPlugin"],"mappings":";;;;AACK,MAAC,cAAc,GAAGA,mBAAc,CAAC,gBAAgB,EAAE;AACxD,IAAI,GAAG,EAAE,MAAM,mDAAe,CAAC,IAAI,CAAC,CAAC,CAAC,KAAK,IAAI,CAAC,CAAC,iBAAiB,EAAE,CAAC;AACrE,CAAC;;ACFM,MAAM,iBAAiB,SAASC,cAAS,CAAC;AACjD,IAAI,MAAM,KAAK,GAAG;AAClB,QAAQ,MAAM,IAAI,KAAK,CAAC,yBAAyB,CAAC,CAAC;AACnD,KAAK;AACL,IAAI,MAAM,IAAI,GAAG;AACjB,QAAQ,MAAM,IAAI,KAAK,CAAC,yBAAyB,CAAC,CAAC;AACnD,KAAK;AACL;;;;;;;;;"}
package/dist/plugin.js CHANGED
@@ -1,16 +1,16 @@
1
1
  var capacitorScreenRecorder = (function (exports, core) {
2
2
  'use strict';
3
3
 
4
- const ScreenRecorder = core.registerPlugin('ScreenRecorder', {
4
+ const ScreenRecorder = core.registerPlugin("ScreenRecorder", {
5
5
  web: () => Promise.resolve().then(function () { return web; }).then((m) => new m.ScreenRecorderWeb()),
6
6
  });
7
7
 
8
8
  class ScreenRecorderWeb extends core.WebPlugin {
9
9
  async start() {
10
- throw new Error('Method not implemented.');
10
+ throw new Error("Method not implemented.");
11
11
  }
12
12
  async stop() {
13
- throw new Error('Method not implemented.');
13
+ throw new Error("Method not implemented.");
14
14
  }
15
15
  }
16
16
 
@@ -1 +1 @@
1
- {"version":3,"file":"plugin.js","sources":["esm/index.js","esm/web.js"],"sourcesContent":["import { registerPlugin } from '@capacitor/core';\nconst ScreenRecorder = registerPlugin('ScreenRecorder', {\n web: () => import('./web').then((m) => new m.ScreenRecorderWeb()),\n});\nexport * from './definitions';\nexport { ScreenRecorder };\n//# sourceMappingURL=index.js.map","import { WebPlugin } from '@capacitor/core';\nexport class ScreenRecorderWeb extends WebPlugin {\n async start() {\n throw new Error('Method not implemented.');\n }\n async stop() {\n throw new Error('Method not implemented.');\n }\n}\n//# sourceMappingURL=web.js.map"],"names":["registerPlugin","WebPlugin"],"mappings":";;;AACK,UAAC,cAAc,GAAGA,mBAAc,CAAC,gBAAgB,EAAE;IACxD,IAAI,GAAG,EAAE,MAAM,mDAAe,CAAC,IAAI,CAAC,CAAC,CAAC,KAAK,IAAI,CAAC,CAAC,iBAAiB,EAAE,CAAC;IACrE,CAAC;;ICFM,MAAM,iBAAiB,SAASC,cAAS,CAAC;IACjD,IAAI,MAAM,KAAK,GAAG;IAClB,QAAQ,MAAM,IAAI,KAAK,CAAC,yBAAyB,CAAC,CAAC;IACnD,KAAK;IACL,IAAI,MAAM,IAAI,GAAG;IACjB,QAAQ,MAAM,IAAI,KAAK,CAAC,yBAAyB,CAAC,CAAC;IACnD,KAAK;IACL;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"plugin.js","sources":["esm/index.js","esm/web.js"],"sourcesContent":["import { registerPlugin } from \"@capacitor/core\";\nconst ScreenRecorder = registerPlugin(\"ScreenRecorder\", {\n web: () => import(\"./web\").then((m) => new m.ScreenRecorderWeb()),\n});\nexport * from \"./definitions\";\nexport { ScreenRecorder };\n//# sourceMappingURL=index.js.map","import { WebPlugin } from \"@capacitor/core\";\nexport class ScreenRecorderWeb extends WebPlugin {\n async start() {\n throw new Error(\"Method not implemented.\");\n }\n async stop() {\n throw new Error(\"Method not implemented.\");\n }\n}\n//# sourceMappingURL=web.js.map"],"names":["registerPlugin","WebPlugin"],"mappings":";;;AACK,UAAC,cAAc,GAAGA,mBAAc,CAAC,gBAAgB,EAAE;IACxD,IAAI,GAAG,EAAE,MAAM,mDAAe,CAAC,IAAI,CAAC,CAAC,CAAC,KAAK,IAAI,CAAC,CAAC,iBAAiB,EAAE,CAAC;IACrE,CAAC;;ICFM,MAAM,iBAAiB,SAASC,cAAS,CAAC;IACjD,IAAI,MAAM,KAAK,GAAG;IAClB,QAAQ,MAAM,IAAI,KAAK,CAAC,yBAAyB,CAAC,CAAC;IACnD,KAAK;IACL,IAAI,MAAM,IAAI,GAAG;IACjB,QAAQ,MAAM,IAAI,KAAK,CAAC,yBAAyB,CAAC,CAAC;IACnD,KAAK;IACL;;;;;;;;;;;;;;;"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@capgo/capacitor-screen-recorder",
3
- "version": "1.2.53",
3
+ "version": "3.0.0",
4
4
  "description": "Record device's screen",
5
5
  "main": "dist/plugin.cjs.js",
6
6
  "module": "dist/esm/index.js",
@@ -33,9 +33,9 @@
33
33
  "verify:android": "cd android && ./gradlew clean build test && cd ..",
34
34
  "verify:web": "npm run build",
35
35
  "lint": "npm run eslint && npm run prettier -- --check && npm run swiftlint -- lint",
36
- "fmt": "npm run eslint -- --fix && npm run prettier -- --write && npm run swiftlint -- --fix --format",
36
+ "fmt": "npm run eslint -- --fix && npm run prettier -- --write && npm run swiftlint -- --autocorrect --format",
37
37
  "eslint": "eslint . --ext ts",
38
- "prettier": "prettier \"**/*.{css,html,ts,js,java}\"",
38
+ "prettier": "prettier --config .prettierrc.js \"**/*.{css,html,ts,js,java}\"",
39
39
  "swiftlint": "node-swiftlint",
40
40
  "docgen": "docgen --api ScreenRecorderPlugin --output-readme README.md --output-json dist/docs.json",
41
41
  "build": "npm run clean && npm run docgen && tsc && rollup -c rollup.config.mjs",
@@ -44,28 +44,28 @@
44
44
  "prepublishOnly": "npm run build"
45
45
  },
46
46
  "devDependencies": {
47
- "@capacitor/android": "^4.4.0",
48
- "@capacitor/cli": "^4.4.0",
49
- "@capacitor/core": "^4.4.0",
50
- "@capacitor/docgen": "^0.2.0",
51
- "@capacitor/ios": "^4.4.0",
47
+ "@capacitor/android": "^5.0.3",
48
+ "@capacitor/cli": "^5.0.3",
49
+ "@capacitor/core": "^5.0.3",
50
+ "@capacitor/docgen": "^0.2.1",
51
+ "@capacitor/ios": "^5.0.3",
52
52
  "@ionic/eslint-config": "^0.3.0",
53
- "@ionic/prettier-config": "^2.0.0",
53
+ "@ionic/prettier-config": "^3.0.0",
54
54
  "@ionic/swiftlint-config": "^1.1.2",
55
- "@typescript-eslint/eslint-plugin": "^5.42.1",
56
- "@typescript-eslint/parser": "^5.42.1",
57
- "eslint": "^8.27.0",
58
- "eslint-plugin-import": "^2.26.0",
59
- "husky": "^8.0.2",
60
- "prettier": "^2.7.1",
61
- "prettier-plugin-java": "^2.0.0",
62
- "rimraf": "^3.0.2",
63
- "rollup": "^3.2.5",
64
- "swiftlint": "^1.0.1",
65
- "typescript": "^4.8.4"
55
+ "@typescript-eslint/eslint-plugin": "^5.59.7",
56
+ "@typescript-eslint/parser": "^5.59.7",
57
+ "eslint": "^8.41.0",
58
+ "eslint-plugin-import": "^2.27.5",
59
+ "husky": "^8.0.3",
60
+ "prettier": "^2.8.8",
61
+ "prettier-plugin-java": "^2.1.0",
62
+ "rimraf": "^5.0.1",
63
+ "rollup": "^3.23.0",
64
+ "swiftlint": "^1.0.2",
65
+ "typescript": "^5.0.4"
66
66
  },
67
67
  "peerDependencies": {
68
- "@capacitor/core": "^4.0.0"
68
+ "@capacitor/core": "^5.0.0"
69
69
  },
70
70
  "prettier": "@ionic/prettier-config",
71
71
  "swiftlint": "@ionic/swiftlint-config",