@capgo/capacitor-mute 6.0.2 → 7.1.3

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.
@@ -15,7 +15,7 @@ Pod::Spec.new do |s|
15
15
  'Mute' => ['ios/Plugin/Assets/*.aiff']
16
16
  }
17
17
  s.pod_target_xcconfig = { 'CODE_SIGNING_ALLOWED' => 'NO' }
18
- s.ios.deployment_target = '13.0'
18
+ s.ios.deployment_target = '14.0'
19
19
  s.dependency 'Capacitor'
20
20
  s.frameworks = 'Foundation', 'AudioToolbox'
21
21
  s.swift_version = '5.1'
package/README.md CHANGED
@@ -2,9 +2,11 @@
2
2
  <a href="https://capgo.app/"><img src='https://raw.githubusercontent.com/Cap-go/capgo/main/assets/capgo_banner.png' alt='Capgo - Instant updates for capacitor'/></a>
3
3
 
4
4
  <div align="center">
5
- <h2><a href="https://capgo.app/">Check out: Capgo Instant updates for capacitor</a></h2>
5
+ <h2><a href="https://capgo.app/?ref=plugin"> ➡️ Get Instant updates for your App with Capgo 🚀</a></h2>
6
+ <h2><a href="https://capgo.app/consulting/?ref=plugin"> Fix your annoying bug now, Hire a Capacitor expert 💪</a></h2>
6
7
  </div>
7
8
 
9
+
8
10
  Detect if the mute switch is enabled/disabled on a device
9
11
 
10
12
  ## Install
@@ -60,12 +62,12 @@ If no answer I will add the code directly to capacitor-mute
60
62
  ### isMuted()
61
63
 
62
64
  ```typescript
63
- isMuted() => any
65
+ isMuted() => Promise<MuteResponse>
64
66
  ```
65
67
 
66
68
  check if the device is muted
67
69
 
68
- **Returns:** <code>any</code>
70
+ **Returns:** <code>Promise&lt;<a href="#muteresponse">MuteResponse</a>&gt;</code>
69
71
 
70
72
  --------------------
71
73
 
@@ -1,8 +1,8 @@
1
1
  ext {
2
2
  junitVersion = project.hasProperty('junitVersion') ? rootProject.ext.junitVersion : '4.13.2'
3
- androidxJunitVersion = project.hasProperty('androidxJunitVersion') ? rootProject.ext.androidxJunitVersion : '1.1.5'
4
- androidxEspressoCoreVersion = project.hasProperty('androidxEspressoCoreVersion') ? rootProject.ext.androidxEspressoCoreVersion : '3.5.1'
5
- androidxAppCompatVersion = project.hasProperty('androidxAppCompatVersion') ? rootProject.ext.androidxAppCompatVersion : '1.6.1'
3
+ androidxJunitVersion = project.hasProperty('androidxJunitVersion') ? rootProject.ext.androidxJunitVersion : '1.2.1'
4
+ androidxEspressoCoreVersion = project.hasProperty('androidxEspressoCoreVersion') ? rootProject.ext.androidxEspressoCoreVersion : '3.6.1'
5
+ androidxAppCompatVersion = project.hasProperty('androidxAppCompatVersion') ? rootProject.ext.androidxAppCompatVersion : '1.7.0'
6
6
  }
7
7
 
8
8
  buildscript {
@@ -11,7 +11,7 @@ buildscript {
11
11
  google()
12
12
  }
13
13
  dependencies {
14
- classpath 'com.android.tools.build:gradle:8.2.1'
14
+ classpath 'com.android.tools.build:gradle:8.7.2'
15
15
  }
16
16
  }
17
17
 
@@ -19,10 +19,10 @@ apply plugin: 'com.android.library'
19
19
 
20
20
  android {
21
21
  namespace "ee.forgr.plugin.mute"
22
- compileSdk project.hasProperty('compileSdkVersion') ? rootProject.ext.compileSdkVersion : 34
22
+ compileSdk project.hasProperty('compileSdkVersion') ? rootProject.ext.compileSdkVersion : 35
23
23
  defaultConfig {
24
- minSdkVersion project.hasProperty('minSdkVersion') ? rootProject.ext.minSdkVersion : 22
25
- targetSdkVersion project.hasProperty('targetSdkVersion') ? rootProject.ext.targetSdkVersion : 34
24
+ minSdkVersion project.hasProperty('minSdkVersion') ? rootProject.ext.minSdkVersion : 23
25
+ targetSdkVersion project.hasProperty('targetSdkVersion') ? rootProject.ext.targetSdkVersion : 35
26
26
  versionCode 1
27
27
  versionName "1.0"
28
28
  testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
@@ -37,8 +37,8 @@ android {
37
37
  abortOnError false
38
38
  }
39
39
  compileOptions {
40
- sourceCompatibility JavaVersion.VERSION_17
41
- targetCompatibility JavaVersion.VERSION_17
40
+ sourceCompatibility JavaVersion.VERSION_21
41
+ targetCompatibility JavaVersion.VERSION_21
42
42
  }
43
43
  }
44
44
 
package/dist/docs.json CHANGED
@@ -7,9 +7,9 @@
7
7
  "methods": [
8
8
  {
9
9
  "name": "isMuted",
10
- "signature": "() => any",
10
+ "signature": "() => Promise<MuteResponse>",
11
11
  "parameters": [],
12
- "returns": "any",
12
+ "returns": "Promise<MuteResponse>",
13
13
  "tags": [],
14
14
  "docs": "check if the device is muted",
15
15
  "complexTypes": [
@@ -1 +1 @@
1
- {"version":3,"file":"definitions.js","sourceRoot":"","sources":["../../src/definitions.ts"],"names":[],"mappings":""}
1
+ {"version":3,"file":"definitions.js","sourceRoot":"","sources":["../../src/definitions.ts"],"names":[],"mappings":"","sourcesContent":["export interface MutePlugin {\n /**\n * check if the device is muted\n *\n */\n isMuted(): Promise<MuteResponse>;\n}\n\nexport interface MuteResponse {\n value: boolean;\n}\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,iBAAiB,CAAC;AAIjD,MAAM,IAAI,GAAG,cAAc,CAAa,MAAM,EAAE;IAC9C,GAAG,EAAE,GAAG,EAAE,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,IAAI,CAAC,CAAC,OAAO,EAAE,CAAC;CACxD,CAAC,CAAC;AAEH,cAAc,eAAe,CAAC;AAC9B,OAAO,EAAE,IAAI,EAAE,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,iBAAiB,CAAC;AAIjD,MAAM,IAAI,GAAG,cAAc,CAAa,MAAM,EAAE;IAC9C,GAAG,EAAE,GAAG,EAAE,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,IAAI,CAAC,CAAC,OAAO,EAAE,CAAC;CACxD,CAAC,CAAC;AAEH,cAAc,eAAe,CAAC;AAC9B,OAAO,EAAE,IAAI,EAAE,CAAC","sourcesContent":["import { registerPlugin } from \"@capacitor/core\";\n\nimport type { MutePlugin } from \"./definitions\";\n\nconst Mute = registerPlugin<MutePlugin>(\"Mute\", {\n web: () => import(\"./web\").then((m) => new m.MuteWeb()),\n});\n\nexport * from \"./definitions\";\nexport { Mute };\n"]}
@@ -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,OAAQ,SAAQ,SAAS;IACpC,KAAK,CAAC,OAAO;QACX,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,OAAQ,SAAQ,SAAS;IACpC,KAAK,CAAC,OAAO;QACX,MAAM,IAAI,KAAK,CAAC,yBAAyB,CAAC,CAAC;IAC7C,CAAC;CACF","sourcesContent":["import { WebPlugin } from \"@capacitor/core\";\n\nimport type { MutePlugin, MuteResponse } from \"./definitions\";\n\nexport class MuteWeb extends WebPlugin implements MutePlugin {\n async isMuted(): Promise<MuteResponse> {\n throw new Error(\"Method not implemented.\");\n }\n}\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"plugin.cjs.js","sources":["esm/index.js","esm/web.js"],"sourcesContent":["import { registerPlugin } from \"@capacitor/core\";\nconst Mute = registerPlugin(\"Mute\", {\n web: () => import(\"./web\").then((m) => new m.MuteWeb()),\n});\nexport * from \"./definitions\";\nexport { Mute };\n//# sourceMappingURL=index.js.map","import { WebPlugin } from \"@capacitor/core\";\nexport class MuteWeb extends WebPlugin {\n async isMuted() {\n throw new Error(\"Method not implemented.\");\n }\n}\n//# sourceMappingURL=web.js.map"],"names":["registerPlugin","WebPlugin"],"mappings":";;;;AACK,MAAC,IAAI,GAAGA,mBAAc,CAAC,MAAM,EAAE;AACpC,IAAI,GAAG,EAAE,MAAM,mDAAe,CAAC,IAAI,CAAC,CAAC,CAAC,KAAK,IAAI,CAAC,CAAC,OAAO,EAAE,CAAC;AAC3D,CAAC;;ACFM,MAAM,OAAO,SAASC,cAAS,CAAC;AACvC,IAAI,MAAM,OAAO,GAAG;AACpB,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 Mute = registerPlugin(\"Mute\", {\n web: () => import(\"./web\").then((m) => new m.MuteWeb()),\n});\nexport * from \"./definitions\";\nexport { Mute };\n//# sourceMappingURL=index.js.map","import { WebPlugin } from \"@capacitor/core\";\nexport class MuteWeb extends WebPlugin {\n async isMuted() {\n throw new Error(\"Method not implemented.\");\n }\n}\n//# sourceMappingURL=web.js.map"],"names":["registerPlugin","WebPlugin"],"mappings":";;;;AACK,MAAC,IAAI,GAAGA,mBAAc,CAAC,MAAM,EAAE;AACpC,IAAI,GAAG,EAAE,MAAM,mDAAe,CAAC,IAAI,CAAC,CAAC,CAAC,KAAK,IAAI,CAAC,CAAC,OAAO,EAAE,CAAC;AAC3D,CAAC;;ACFM,MAAM,OAAO,SAASC,cAAS,CAAC;AACvC,IAAI,MAAM,OAAO,GAAG;AACpB,QAAQ,MAAM,IAAI,KAAK,CAAC,yBAAyB,CAAC;AAClD;AACA;;;;;;;;;"}
@@ -1 +1 @@
1
- {"version":3,"file":"plugin.js","sources":["esm/index.js","esm/web.js"],"sourcesContent":["import { registerPlugin } from \"@capacitor/core\";\nconst Mute = registerPlugin(\"Mute\", {\n web: () => import(\"./web\").then((m) => new m.MuteWeb()),\n});\nexport * from \"./definitions\";\nexport { Mute };\n//# sourceMappingURL=index.js.map","import { WebPlugin } from \"@capacitor/core\";\nexport class MuteWeb extends WebPlugin {\n async isMuted() {\n throw new Error(\"Method not implemented.\");\n }\n}\n//# sourceMappingURL=web.js.map"],"names":["registerPlugin","WebPlugin"],"mappings":";;;AACK,UAAC,IAAI,GAAGA,mBAAc,CAAC,MAAM,EAAE;IACpC,IAAI,GAAG,EAAE,MAAM,mDAAe,CAAC,IAAI,CAAC,CAAC,CAAC,KAAK,IAAI,CAAC,CAAC,OAAO,EAAE,CAAC;IAC3D,CAAC;;ICFM,MAAM,OAAO,SAASC,cAAS,CAAC;IACvC,IAAI,MAAM,OAAO,GAAG;IACpB,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 Mute = registerPlugin(\"Mute\", {\n web: () => import(\"./web\").then((m) => new m.MuteWeb()),\n});\nexport * from \"./definitions\";\nexport { Mute };\n//# sourceMappingURL=index.js.map","import { WebPlugin } from \"@capacitor/core\";\nexport class MuteWeb extends WebPlugin {\n async isMuted() {\n throw new Error(\"Method not implemented.\");\n }\n}\n//# sourceMappingURL=web.js.map"],"names":["registerPlugin","WebPlugin"],"mappings":";;;AACK,UAAC,IAAI,GAAGA,mBAAc,CAAC,MAAM,EAAE;IACpC,IAAI,GAAG,EAAE,MAAM,mDAAe,CAAC,IAAI,CAAC,CAAC,CAAC,KAAK,IAAI,CAAC,CAAC,OAAO,EAAE,CAAC;IAC3D,CAAC;;ICFM,MAAM,OAAO,SAASC,cAAS,CAAC;IACvC,IAAI,MAAM,OAAO,GAAG;IACpB,QAAQ,MAAM,IAAI,KAAK,CAAC,yBAAyB,CAAC;IAClD;IACA;;;;;;;;;;;;;;;"}
@@ -7,6 +7,11 @@ import Capacitor
7
7
  */
8
8
  @objc(MutePlugin)
9
9
  public class MutePlugin: CAPPlugin {
10
+ public let identifier = "MutePlugin"
11
+ public let jsName = "Mute"
12
+ public let pluginMethods: [CAPPluginMethod] = [
13
+ CAPPluginMethod(name: "isMuted", returnType: CAPPluginReturnPromise)
14
+ ]
10
15
  private let implementation = Muted()
11
16
  override public func load() {
12
17
  implementation.initialize()
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@capgo/capacitor-mute",
3
- "version": "6.0.2",
3
+ "version": "7.1.3",
4
4
  "description": "Detect if the mute switch is enabled/disabled on a device",
5
5
  "main": "dist/plugin.cjs.js",
6
6
  "module": "dist/esm/index.js",
@@ -17,10 +17,10 @@
17
17
  "license": "MIT",
18
18
  "repository": {
19
19
  "type": "git",
20
- "url": "git+https://github.com/riderx/capacitor-mute.git"
20
+ "url": "git+https://github.com/Cap-go/capacitor-mute.git"
21
21
  },
22
22
  "bugs": {
23
- "url": "https://github.com/riderx/capacitor-mute/issues"
23
+ "url": "https://github.com/Cap-go/capacitor-mute/issues"
24
24
  },
25
25
  "keywords": [
26
26
  "capacitor",
@@ -34,7 +34,7 @@
34
34
  "verify:android": "cd android && ./gradlew clean build test && cd ..",
35
35
  "verify:web": "npm run build",
36
36
  "lint": "npm run eslint && npm run prettier -- --check && npm run swiftlint -- lint",
37
- "fmt": "npm run eslint -- --fix && npm run prettier -- --write && npm run swiftlint -- --fix --format",
37
+ "fmt": "npm run eslint -- --fix && npm run prettier -- --write && npm run swiftlint -- --autocorrect --format",
38
38
  "eslint": "eslint .",
39
39
  "prettier": "prettier --config .prettierrc.js \"**/*.{css,html,ts,js,java}\"",
40
40
  "swiftlint": "node-swiftlint",
@@ -45,28 +45,30 @@
45
45
  "prepublishOnly": "npm run build"
46
46
  },
47
47
  "devDependencies": {
48
- "@capacitor/android": "^6.0.0",
49
- "@capacitor/cli": "^6.0.0",
50
- "@capacitor/core": "^6.0.0",
51
- "@capacitor/docgen": "^0.2.2",
52
- "@capacitor/ios": "^6.0.0",
53
- "@ionic/eslint-config": "^0.3.0",
48
+ "@capacitor/android": "^7.0.0",
49
+ "@capacitor/cli": "^7.0.0",
50
+ "@capacitor/core": "^7.0.0",
51
+ "@capacitor/docgen": "^0.3.0",
52
+ "@capacitor/ios": "^7.0.0",
53
+ "@ionic/eslint-config": "^0.4.0",
54
54
  "@ionic/prettier-config": "^4.0.0",
55
- "@ionic/swiftlint-config": "^1.1.2",
56
- "@typescript-eslint/eslint-plugin": "^7.8.0",
57
- "@typescript-eslint/parser": "^7.8.0",
58
- "eslint": "^9.1.1",
59
- "eslint-plugin-import": "^2.29.1",
60
- "husky": "^9.0.11",
61
- "prettier": "^3.2.5",
62
- "prettier-plugin-java": "^2.6.0",
63
- "rimraf": "^5.0.5",
64
- "rollup": "^4.17.1",
65
- "swiftlint": "^1.0.2",
66
- "typescript": "^5.4.5"
55
+ "@ionic/swiftlint-config": "^2.0.0",
56
+ "@types/node": "^22.13.1",
57
+ "eslint": "^8.57.0",
58
+ "eslint-plugin-import": "^2.31.0",
59
+ "husky": "^9.1.7",
60
+ "prettier": "^3.4.2",
61
+ "prettier-plugin-java": "^2.6.7",
62
+ "rimraf": "^6.0.1",
63
+ "rollup": "^4.34.6",
64
+ "swiftlint": "^2.0.0",
65
+ "typescript": "^5.7.3"
67
66
  },
68
67
  "peerDependencies": {
69
- "@capacitor/core": "^6.0.0"
68
+ "@capacitor/core": ">=7.0.0"
69
+ },
70
+ "eslintConfig": {
71
+ "extends": "@ionic/eslint-config/recommended"
70
72
  },
71
73
  "prettier": "@ionic/prettier-config",
72
74
  "swiftlint": "@ionic/swiftlint-config",