@switchbot/homebridge-switchbot 3.5.0-beta.5 → 3.5.0-beta.51
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/CHANGELOG.md +2 -0
- package/config.schema.json +120 -17
- package/dist/device/blindtilt.d.ts +21 -94
- package/dist/device/blindtilt.d.ts.map +1 -1
- package/dist/device/blindtilt.js +352 -757
- package/dist/device/blindtilt.js.map +1 -1
- package/dist/device/bot.d.ts +25 -71
- package/dist/device/bot.d.ts.map +1 -1
- package/dist/device/bot.js +588 -761
- package/dist/device/bot.js.map +1 -1
- package/dist/device/ceilinglight.d.ts +13 -67
- package/dist/device/ceilinglight.d.ts.map +1 -1
- package/dist/device/ceilinglight.js +214 -588
- package/dist/device/ceilinglight.js.map +1 -1
- package/dist/device/colorbulb.d.ts +13 -74
- package/dist/device/colorbulb.d.ts.map +1 -1
- package/dist/device/colorbulb.js +256 -634
- package/dist/device/colorbulb.js.map +1 -1
- package/dist/device/contact.d.ts +14 -65
- package/dist/device/contact.d.ts.map +1 -1
- package/dist/device/contact.js +209 -532
- package/dist/device/contact.js.map +1 -1
- package/dist/device/curtain.d.ts +17 -86
- package/dist/device/curtain.d.ts.map +1 -1
- package/dist/device/curtain.js +340 -787
- package/dist/device/curtain.js.map +1 -1
- package/dist/device/device.d.ts +59 -0
- package/dist/device/device.d.ts.map +1 -0
- package/dist/device/device.js +682 -0
- package/dist/device/device.js.map +1 -0
- package/dist/device/fan.d.ts +51 -0
- package/dist/device/fan.d.ts.map +1 -0
- package/dist/device/fan.js +505 -0
- package/dist/device/fan.js.map +1 -0
- package/dist/device/hub.d.ts +15 -59
- package/dist/device/hub.d.ts.map +1 -1
- package/dist/device/hub.js +247 -597
- package/dist/device/hub.js.map +1 -1
- package/dist/device/humidifier.d.ts +10 -65
- package/dist/device/humidifier.d.ts.map +1 -1
- package/dist/device/humidifier.js +218 -579
- package/dist/device/humidifier.js.map +1 -1
- package/dist/device/iosensor.d.ts +11 -64
- package/dist/device/iosensor.d.ts.map +1 -1
- package/dist/device/iosensor.js +179 -585
- package/dist/device/iosensor.js.map +1 -1
- package/dist/device/lightstrip.d.ts +10 -68
- package/dist/device/lightstrip.d.ts.map +1 -1
- package/dist/device/lightstrip.js +257 -569
- package/dist/device/lightstrip.js.map +1 -1
- package/dist/device/lock.d.ts +15 -62
- package/dist/device/lock.d.ts.map +1 -1
- package/dist/device/lock.js +215 -543
- package/dist/device/lock.js.map +1 -1
- package/dist/device/meter.d.ts +13 -63
- package/dist/device/meter.d.ts.map +1 -1
- package/dist/device/meter.js +175 -578
- package/dist/device/meter.js.map +1 -1
- package/dist/device/meterplus.d.ts +13 -64
- package/dist/device/meterplus.d.ts.map +1 -1
- package/dist/device/meterplus.js +164 -578
- package/dist/device/meterplus.js.map +1 -1
- package/dist/device/motion.d.ts +13 -69
- package/dist/device/motion.d.ts.map +1 -1
- package/dist/device/motion.js +142 -520
- package/dist/device/motion.js.map +1 -1
- package/dist/device/plug.d.ts +9 -57
- package/dist/device/plug.d.ts.map +1 -1
- package/dist/device/plug.js +87 -453
- package/dist/device/plug.js.map +1 -1
- package/dist/device/robotvacuumcleaner.d.ts +11 -62
- package/dist/device/robotvacuumcleaner.d.ts.map +1 -1
- package/dist/device/robotvacuumcleaner.js +145 -452
- package/dist/device/robotvacuumcleaner.js.map +1 -1
- package/dist/device/waterdetector.d.ts +9 -70
- package/dist/device/waterdetector.d.ts.map +1 -1
- package/dist/device/waterdetector.js +126 -665
- package/dist/device/waterdetector.js.map +1 -1
- package/dist/homebridge-ui/public/index.html +2 -2
- package/dist/index.js +1 -1
- package/dist/irdevice/airconditioner.d.ts +8 -48
- package/dist/irdevice/airconditioner.d.ts.map +1 -1
- package/dist/irdevice/airconditioner.js +309 -419
- package/dist/irdevice/airconditioner.js.map +1 -1
- package/dist/irdevice/airpurifier.d.ts +7 -38
- package/dist/irdevice/airpurifier.d.ts.map +1 -1
- package/dist/irdevice/airpurifier.js +72 -304
- package/dist/irdevice/airpurifier.js.map +1 -1
- package/dist/irdevice/camera.d.ts +6 -35
- package/dist/irdevice/camera.d.ts.map +1 -1
- package/dist/irdevice/camera.js +34 -278
- package/dist/irdevice/camera.js.map +1 -1
- package/dist/irdevice/fan.d.ts +6 -39
- package/dist/irdevice/fan.d.ts.map +1 -1
- package/dist/irdevice/fan.js +67 -311
- package/dist/irdevice/fan.js.map +1 -1
- package/dist/irdevice/irdevice.d.ts +40 -0
- package/dist/irdevice/irdevice.d.ts.map +1 -0
- package/dist/irdevice/irdevice.js +512 -0
- package/dist/irdevice/irdevice.js.map +1 -0
- package/dist/irdevice/light.d.ts +6 -34
- package/dist/irdevice/light.d.ts.map +1 -1
- package/dist/irdevice/light.js +23 -272
- package/dist/irdevice/light.js.map +1 -1
- package/dist/irdevice/other.d.ts +18 -47
- package/dist/irdevice/other.d.ts.map +1 -1
- package/dist/irdevice/other.js +352 -546
- package/dist/irdevice/other.js.map +1 -1
- package/dist/irdevice/tv.d.ts +7 -39
- package/dist/irdevice/tv.d.ts.map +1 -1
- package/dist/irdevice/tv.js +82 -321
- package/dist/irdevice/tv.js.map +1 -1
- package/dist/irdevice/vacuumcleaner.d.ts +6 -35
- package/dist/irdevice/vacuumcleaner.d.ts.map +1 -1
- package/dist/irdevice/vacuumcleaner.js +41 -284
- package/dist/irdevice/vacuumcleaner.js.map +1 -1
- package/dist/irdevice/waterheater.d.ts +6 -35
- package/dist/irdevice/waterheater.d.ts.map +1 -1
- package/dist/irdevice/waterheater.js +42 -287
- package/dist/irdevice/waterheater.js.map +1 -1
- package/dist/platform.d.ts +14 -1
- package/dist/platform.d.ts.map +1 -1
- package/dist/platform.js +291 -147
- package/dist/platform.js.map +1 -1
- package/dist/settings.d.ts +41 -11
- package/dist/settings.d.ts.map +1 -1
- package/dist/settings.js +0 -552
- package/dist/settings.js.map +1 -1
- package/dist/utils.d.ts +77 -0
- package/dist/utils.d.ts.map +1 -1
- package/dist/utils.js +638 -1
- package/dist/utils.js.map +1 -1
- package/eslint.config.js +87 -0
- package/package.json +16 -15
- package/src/custom.d.ts +2 -1
- package/src/device/blindtilt.ts +378 -783
- package/src/device/bot.ts +621 -845
- package/src/device/ceilinglight.ts +227 -608
- package/src/device/colorbulb.ts +269 -657
- package/src/device/contact.ts +235 -555
- package/src/device/curtain.ts +360 -811
- package/src/device/device.ts +710 -0
- package/src/device/fan.ts +554 -0
- package/src/device/hub.ts +274 -625
- package/src/device/humidifier.ts +246 -624
- package/src/device/iosensor.ts +205 -611
- package/src/device/lightstrip.ts +278 -597
- package/src/device/lock.ts +252 -583
- package/src/device/meter.ts +200 -601
- package/src/device/meterplus.ts +189 -603
- package/src/device/motion.ts +161 -542
- package/src/device/plug.ts +97 -481
- package/src/device/robotvacuumcleaner.ts +166 -478
- package/src/device/waterdetector.ts +143 -689
- package/src/homebridge-ui/public/index.html +2 -2
- package/src/index.ts +1 -1
- package/src/irdevice/airconditioner.ts +330 -446
- package/src/irdevice/airpurifier.ts +89 -321
- package/src/irdevice/camera.ts +42 -293
- package/src/irdevice/fan.ts +78 -327
- package/src/irdevice/irdevice.ts +528 -0
- package/src/irdevice/light.ts +32 -287
- package/src/irdevice/other.ts +396 -615
- package/src/irdevice/tv.ts +100 -339
- package/src/irdevice/vacuumcleaner.ts +49 -305
- package/src/irdevice/waterheater.ts +50 -310
- package/src/platform.ts +301 -155
- package/src/settings.ts +57 -566
- package/src/utils.ts +642 -1
package/eslint.config.js
ADDED
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
export default [
|
|
2
|
+
{
|
|
3
|
+
"parser": "@typescript-eslint/parser",
|
|
4
|
+
"extends": [
|
|
5
|
+
"eslint:recommended",
|
|
6
|
+
"plugin:@typescript-eslint/eslint-recommended",
|
|
7
|
+
"plugin:@typescript-eslint/recommended" // uses the recommended rules from the @typescript-eslint/eslint-plugin
|
|
8
|
+
],
|
|
9
|
+
"parserOptions": {
|
|
10
|
+
"ecmaVersion": 2021,
|
|
11
|
+
"sourceType": "module"
|
|
12
|
+
},
|
|
13
|
+
"ignorePatterns": [
|
|
14
|
+
"dist"
|
|
15
|
+
],
|
|
16
|
+
"rules": {
|
|
17
|
+
"quotes": [
|
|
18
|
+
"warn",
|
|
19
|
+
"single"
|
|
20
|
+
],
|
|
21
|
+
"indent": [
|
|
22
|
+
"warn",
|
|
23
|
+
2,
|
|
24
|
+
{
|
|
25
|
+
"SwitchCase": 1
|
|
26
|
+
}
|
|
27
|
+
],
|
|
28
|
+
"linebreak-style": [
|
|
29
|
+
"warn",
|
|
30
|
+
"unix"
|
|
31
|
+
],
|
|
32
|
+
"semi": [
|
|
33
|
+
"warn",
|
|
34
|
+
"always"
|
|
35
|
+
],
|
|
36
|
+
"comma-dangle": [
|
|
37
|
+
"warn",
|
|
38
|
+
"always-multiline"
|
|
39
|
+
],
|
|
40
|
+
"dot-notation": "off",
|
|
41
|
+
"eqeqeq": "warn",
|
|
42
|
+
"curly": [
|
|
43
|
+
"warn",
|
|
44
|
+
"all"
|
|
45
|
+
],
|
|
46
|
+
"brace-style": [
|
|
47
|
+
"warn"
|
|
48
|
+
],
|
|
49
|
+
"prefer-arrow-callback": [
|
|
50
|
+
"warn"
|
|
51
|
+
],
|
|
52
|
+
"max-len": [
|
|
53
|
+
"warn",
|
|
54
|
+
150
|
|
55
|
+
],
|
|
56
|
+
"no-console": [
|
|
57
|
+
"warn"
|
|
58
|
+
], // use the provided Homebridge log method instead
|
|
59
|
+
"no-non-null-assertion": [
|
|
60
|
+
"off"
|
|
61
|
+
],
|
|
62
|
+
"comma-spacing": [
|
|
63
|
+
"error"
|
|
64
|
+
],
|
|
65
|
+
"no-multi-spaces": [
|
|
66
|
+
"warn",
|
|
67
|
+
{
|
|
68
|
+
"ignoreEOLComments": true
|
|
69
|
+
}
|
|
70
|
+
],
|
|
71
|
+
"no-trailing-spaces": [
|
|
72
|
+
"warn"
|
|
73
|
+
],
|
|
74
|
+
"lines-between-class-members": [
|
|
75
|
+
"warn",
|
|
76
|
+
"always",
|
|
77
|
+
{
|
|
78
|
+
"exceptAfterSingleLine": true
|
|
79
|
+
}
|
|
80
|
+
],
|
|
81
|
+
"@typescript-eslint/explicit-function-return-type": "off",
|
|
82
|
+
"@typescript-eslint/no-non-null-assertion": "off",
|
|
83
|
+
"@typescript-eslint/explicit-module-boundary-types": "off",
|
|
84
|
+
"@typescript-eslint/no-explicit-any": "off"
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
];
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"displayName": "SwitchBot",
|
|
3
3
|
"name": "@switchbot/homebridge-switchbot",
|
|
4
|
-
"version": "3.5.0-beta.
|
|
4
|
+
"version": "3.5.0-beta.51",
|
|
5
5
|
"description": "The SwitchBot plugin allows you to access your SwitchBot device(s) from HomeKit.",
|
|
6
6
|
"author": {
|
|
7
7
|
"name": "SwitchBot",
|
|
@@ -24,9 +24,10 @@
|
|
|
24
24
|
"bugs": {
|
|
25
25
|
"url": "https://github.com/OpenWonderLabs/homebridge-switchbot/issues"
|
|
26
26
|
},
|
|
27
|
+
"engineStrict": true,
|
|
27
28
|
"engines": {
|
|
28
|
-
"homebridge": "^1.
|
|
29
|
-
"node": "^18 || ^20"
|
|
29
|
+
"homebridge": "^1.8.2",
|
|
30
|
+
"node": "^18 || ^20 || ^22"
|
|
30
31
|
},
|
|
31
32
|
"main": "dist/index.js",
|
|
32
33
|
"scripts": {
|
|
@@ -79,24 +80,24 @@
|
|
|
79
80
|
"@homebridge/plugin-ui-utils": "^1.0.3",
|
|
80
81
|
"async-mqtt": "^2.6.3",
|
|
81
82
|
"fakegato-history": "^0.6.4",
|
|
82
|
-
"homebridge-lib": "^
|
|
83
|
+
"homebridge-lib": "^7.0.1",
|
|
83
84
|
"rxjs": "^7.8.1",
|
|
84
|
-
"undici": "^6.
|
|
85
|
+
"undici": "^6.17.0"
|
|
85
86
|
},
|
|
86
87
|
"optionalDependencies": {
|
|
87
|
-
"node-switchbot": "2.1.0
|
|
88
|
+
"node-switchbot": "2.1.0"
|
|
88
89
|
},
|
|
89
90
|
"devDependencies": {
|
|
90
|
-
"@types/node": "^20.12.
|
|
91
|
-
"@typescript-eslint/eslint-plugin": "^
|
|
92
|
-
"@typescript-eslint/parser": "^
|
|
93
|
-
"eslint": "^
|
|
94
|
-
"homebridge": "^1.
|
|
95
|
-
"homebridge-config-ui-x": "4.56.
|
|
91
|
+
"@types/node": "^20.12.12",
|
|
92
|
+
"@typescript-eslint/eslint-plugin": "^8.0.0-alpha.13",
|
|
93
|
+
"@typescript-eslint/parser": "^8.0.0-alpha.13",
|
|
94
|
+
"eslint": "^9.3.0",
|
|
95
|
+
"homebridge": "^1.8.2",
|
|
96
|
+
"homebridge-config-ui-x": "4.56.2",
|
|
96
97
|
"nodemon": "^3.1.0",
|
|
97
|
-
"npm-check-updates": "^16.14.
|
|
98
|
-
"rimraf": "^5.0.
|
|
98
|
+
"npm-check-updates": "^16.14.20",
|
|
99
|
+
"rimraf": "^5.0.7",
|
|
99
100
|
"ts-node": "^10.9.2",
|
|
100
|
-
"typescript": "^5.4.
|
|
101
|
+
"typescript": "^5.4.5"
|
|
101
102
|
}
|
|
102
103
|
}
|
package/src/custom.d.ts
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
/* Copyright(C) 2017-
|
|
1
|
+
/* Copyright(C) 2017-2024, donavanbecker (https://github.com/donavanbecker). All rights reserved.
|
|
2
2
|
*
|
|
3
3
|
* custom.d.ts: @switchbot/homebridge-switchbot platform class.
|
|
4
4
|
*/
|
|
5
5
|
declare module 'homebridge-lib'
|
|
6
|
+
declare module 'homebridge-lib/EveHomeKitTypes'
|
|
6
7
|
declare module 'fakegato-history'
|