node-red-contrib-homekit-bridged 1.5.0-dev.14 → 1.5.0-dev.15

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.
@@ -2,7 +2,7 @@ import { CharacteristicEventTypes, SerializedAccessory, SerializedService } from
2
2
  import storage, { InitOptions } from 'node-persist';
3
3
  import { SerializedHostType } from './types/storage/SerializedHostType';
4
4
  import { StorageType } from './types/storage/StorageType';
5
- declare type EventCallback = {
5
+ type EventCallback = {
6
6
  event: CharacteristicEventTypes;
7
7
  callback: (value?: any) => void;
8
8
  };
@@ -1,4 +1,4 @@
1
- declare type AccessoryInformationType = {
1
+ type AccessoryInformationType = {
2
2
  UUID: string;
3
3
  name: string;
4
4
  manufacturer: string;
@@ -1,4 +1,4 @@
1
- declare type CameraConfigType = {
1
+ type CameraConfigType = {
2
2
  cameraConfigVideoProcessor: string;
3
3
  cameraConfigSource: string;
4
4
  cameraConfigStillImageSource?: string;
@@ -1,5 +1,5 @@
1
1
  import { CharacteristicProps } from 'hap-nodejs';
2
- declare type CustomCharacteristicType = CharacteristicProps & {
2
+ type CustomCharacteristicType = CharacteristicProps & {
3
3
  UUID?: string;
4
4
  name?: string;
5
5
  };
@@ -2,7 +2,7 @@ declare enum FlowTypeType {
2
2
  Subflow = "subflow",
3
3
  Flow = "flow"
4
4
  }
5
- declare type FlowType = {
5
+ type FlowType = {
6
6
  TYPE: FlowTypeType;
7
7
  path: string;
8
8
  };
@@ -2,7 +2,7 @@ import { MDNSAdvertiser } from 'hap-nodejs';
2
2
  import { NodeDef } from 'node-red';
3
3
  import { SemVer } from 'semver';
4
4
  import HapCategories from './HapCategories';
5
- declare type HAPHostConfigType = NodeDef & {
5
+ type HAPHostConfigType = NodeDef & {
6
6
  bridgeName: string;
7
7
  pinCode: string;
8
8
  port?: number;
@@ -3,7 +3,7 @@ import { Accessory, Categories } from 'hap-nodejs';
3
3
  import HAPHostConfigType from './HAPHostConfigType';
4
4
  import HostType from './HostType';
5
5
  import NodeType from './NodeType';
6
- declare type HAPHostNodeType = NodeType & {
6
+ type HAPHostNodeType = NodeType & {
7
7
  config: HAPHostConfigType;
8
8
  mdnsConfig: MulticastOptions;
9
9
  accessoryCategory: Categories;
@@ -1,6 +1,6 @@
1
1
  import { NodeDef } from 'node-red';
2
2
  import CameraConfigType from './CameraConfigType';
3
- declare type HAPService2ConfigType = NodeDef & {
3
+ type HAPService2ConfigType = NodeDef & {
4
4
  isParent: boolean;
5
5
  hostType: number;
6
6
  bridge: string;
@@ -7,7 +7,7 @@ import HAPService2ConfigType from './HAPService2ConfigType';
7
7
  import HAPServiceNodeType from './HAPServiceNodeType';
8
8
  import NodeType from './NodeType';
9
9
  import PublishTimersType from './PublishTimersType';
10
- declare type HAPService2NodeType = NodeType & {
10
+ type HAPService2NodeType = NodeType & {
11
11
  config: HAPService2ConfigType;
12
12
  RED: NodeAPI;
13
13
  setupDone: boolean;
@@ -1,6 +1,6 @@
1
1
  import { NodeDef } from 'node-red';
2
2
  import CameraConfigType from './CameraConfigType';
3
- declare type HAPServiceConfigType = NodeDef & {
3
+ type HAPServiceConfigType = NodeDef & {
4
4
  isParent: boolean;
5
5
  hostType: number;
6
6
  bridge: string;
@@ -7,7 +7,7 @@ import HAPService2NodeType from './HAPService2NodeType';
7
7
  import HAPServiceConfigType from './HAPServiceConfigType';
8
8
  import NodeType from './NodeType';
9
9
  import PublishTimersType from './PublishTimersType';
10
- declare type HAPServiceNodeType = NodeType & {
10
+ type HAPServiceNodeType = NodeType & {
11
11
  config: HAPServiceConfigType;
12
12
  RED: NodeAPI;
13
13
  setupDone: boolean;
@@ -1,5 +1,5 @@
1
1
  import { NodeDef } from 'node-red';
2
- declare type HAPStatusConfigType = NodeDef & {
2
+ type HAPStatusConfigType = NodeDef & {
3
3
  serviceNodeId: string;
4
4
  };
5
5
  export default HAPStatusConfigType;
@@ -3,7 +3,7 @@ import { NodeStatusUtils } from '../utils/NodeStatusUtils';
3
3
  import HAPServiceNodeType from './HAPServiceNodeType';
4
4
  import HAPStatusConfigType from './HAPStatusConfigType';
5
5
  import NodeType from './NodeType';
6
- declare type HAPStatusNodeType = NodeType & {
6
+ type HAPStatusNodeType = NodeType & {
7
7
  config: HAPStatusConfigType;
8
8
  RED: NodeAPI;
9
9
  serviceNode?: HAPServiceNodeType;
@@ -1,6 +1,6 @@
1
1
  import { Node } from 'node-red';
2
2
  import { FlowType } from './FlowType';
3
- declare type NodeType = Node & {
3
+ type NodeType = Node & {
4
4
  _flow: FlowType;
5
5
  _alias: string;
6
6
  };
@@ -1,5 +1,5 @@
1
1
  /// <reference types="node" />
2
- declare type PublishTimersType = {
2
+ type PublishTimersType = {
3
3
  [key: string]: NodeJS.Timeout;
4
4
  };
5
5
  export default PublishTimersType;
@@ -1,5 +1,5 @@
1
1
  import { SerializedAccessory } from 'hap-nodejs';
2
- declare type SerializedHostType = {
2
+ type SerializedHostType = {
3
3
  _isBridge: boolean;
4
4
  } & SerializedAccessory;
5
5
  export { SerializedHostType };
@@ -1,11 +1,11 @@
1
1
  /// <reference types="node-red__registry" />
2
2
  import { NodeStatus } from '@node-red/registry';
3
3
  import NodeType from '../types/NodeType';
4
- declare type StatusType = 'NO_RESPONSE' | 'MSG';
5
- declare type NodeStatusWithType = NodeStatus & {
4
+ type StatusType = 'NO_RESPONSE' | 'MSG';
5
+ type NodeStatusWithType = NodeStatus & {
6
6
  type?: StatusType;
7
7
  };
8
- declare type Status = string | NodeStatusWithType;
8
+ type Status = string | NodeStatusWithType;
9
9
  export declare class NodeStatusUtils {
10
10
  private node;
11
11
  protected lastStatusId?: number;
@@ -13,6 +13,7 @@
13
13
  <option value="bonjour-hap" selected="selected">BONJOUR</option>
14
14
  <option value="ciao">CIAO</option>
15
15
  <option value="avahi">AVAHI</option>
16
+ <option value="resolved">RESOLVED</option>
16
17
  </select>
17
18
  </div>
18
19
  <div class="form-row">
@@ -99,7 +100,7 @@
99
100
  <ul>
100
101
  <li><strong>Pin Code</strong>: Specify the Pin for the pairing process.</li>
101
102
  <li><strong>Port</strong>: If you are behind a Firewall, you may want to specify a port. Cannot be 1880 as it is reserved for node-red. Otherwise, leave empty.</li>
102
- <li><strong>Advertiser</strong>: Which MDNS advertiser to use <em>ciao</em> (new, improved but not yet proved) or (good old) <em>bonjour</em> or experimental <em>avahi</em>. Default <em>bonjour</em>.</li>
103
+ <li><strong>Advertiser</strong>: Which MDNS advertiser to use <em>ciao</em> (new, improved but not yet proved) or (good old) <em>bonjour</em> or experimental <em>avahi</em> and <em>resolved</em>. Default <em>bonjour</em>.</li>
103
104
  <li><strong>Allow Insecure Request</strong>: Should we allow insecure request? Default false.</li>
104
105
  <li><strong>Manufacturer, Model, Serial Number</strong>: Can be anything you want.</li>
105
106
  <li><strong>Firmware Revision</strong>: Should be a version number string in the form of <em>MAJOR.MINOR.REVISION</em> e.g. <em>1.2.0</em>. Other types of strings are ignored and won't be displayed.</li>
@@ -149,7 +150,7 @@
149
150
  value: 'bonjour-hap',
150
151
  required: false,
151
152
  validate: function (value) {
152
- if (value) return value === 'bonjour-hap' || value === 'ciao' || value === 'avahi'
153
+ if (value) return value === 'bonjour-hap' || value === 'ciao' || value === 'avahi' || value === 'resolved'
153
154
  else return true
154
155
  },
155
156
  },
@@ -21,6 +21,7 @@
21
21
  <option value="bonjour-hap" selected="selected">BONJOUR</option>
22
22
  <option value="ciao">CIAO</option>
23
23
  <option value="avahi">AVAHI</option>
24
+ <option value="resolved">RESOLVED</option>
24
25
  </select>
25
26
  </div>
26
27
  <div class="form-row">
@@ -106,7 +107,7 @@
106
107
  <li><strong>Accessory Category</strong>: What kind of category is this Accessory, default <em>OTHER</em></li>
107
108
  <li><strong>Pin Code</strong>: Specify the Pin for the pairing process.</li>
108
109
  <li><strong>Port</strong>: If you are behind a Firewall, you may want to specify a port. Cannot be 1880 as it is reserved for node-red. Otherwise, leave empty.</li>
109
- <li><strong>Advertiser</strong>: Which MDNS advertiser to use <em>ciao</em> (new, improved but not yet proved) or (good old) <em>bonjour</em> or experimental <em>avahi</em>. Default <em>bonjour</em>.</li>
110
+ <li><strong>Advertiser</strong>: Which MDNS advertiser to use <em>ciao</em> (new, improved but not yet proved) or (good old) <em>bonjour</em> or experimental <em>avahi</em> and <em>resolved</em>. Default <em>bonjour</em>.</li>
110
111
  <li><strong>Allow Insecure Request</strong>: Should we allow insecure request? Default false.</li>
111
112
  <li><strong>Manufacturer, Model, Serial Number</strong>: Can be anything you want.</li>
112
113
  <li><strong>Firmware Revision</strong>: Should be a version number string in the form of <em>MAJOR.MINOR.REVISION</em> e.g. <em>1.2.0</em>. Other types of strings are ignored and won't be displayed.</li>
@@ -158,7 +159,7 @@
158
159
  value: 'bonjour-hap',
159
160
  required: false,
160
161
  validate: function (value) {
161
- if (value) return value === 'bonjour-hap' || value === 'ciao' || value === 'avahi'
162
+ if (value) return value === 'bonjour-hap' || value === 'ciao' || value === 'avahi' || value === 'resolved'
162
163
  else return true
163
164
  },
164
165
  },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "node-red-contrib-homekit-bridged",
3
- "version": "1.5.0-dev.14",
3
+ "version": "1.5.0-dev.15",
4
4
  "description": "Node-RED nodes to simulate Apple HomeKit devices.",
5
5
  "main": "build/nodes/nrchkb.js",
6
6
  "scripts": {
@@ -47,9 +47,9 @@
47
47
  "homepage": "https://github.com/NRCHKB/node-red-contrib-homekit-bridged#readme",
48
48
  "dependencies": {
49
49
  "@nrchkb/logger": "^1.3.3",
50
- "hap-nodejs": "0.10.4",
50
+ "hap-nodejs": "0.11.0",
51
51
  "node-persist": "^3.1.0",
52
- "semver": "^7.3.7",
52
+ "semver": "^7.3.8",
53
53
  "uuid": "^9.0.0"
54
54
  },
55
55
  "devDependencies": {
@@ -60,23 +60,23 @@
60
60
  "@types/node-persist": "^3.1.3",
61
61
  "@types/node-red": "^1.2.1",
62
62
  "@types/node-red-node-test-helper": "^0.2.2",
63
- "@types/semver": "^7.3.12",
63
+ "@types/semver": "^7.3.13",
64
64
  "@types/uuid": "^8.3.4",
65
- "@typescript-eslint/eslint-plugin": "^5.38.1",
66
- "@typescript-eslint/parser": "^5.38.1",
65
+ "@typescript-eslint/eslint-plugin": "^5.43.0",
66
+ "@typescript-eslint/parser": "^5.43.0",
67
67
  "babel-eslint": "^10.1.0",
68
- "eslint": "^8.24.0",
68
+ "eslint": "^8.28.0",
69
69
  "eslint-config-prettier": "^8.5.0",
70
70
  "eslint-plugin-prettier": "^4.2.1",
71
71
  "eslint-plugin-simple-import-sort": "^8.0.0",
72
- "husky": "^8.0.1",
73
- "mocha": "^10.0.0",
72
+ "husky": "^8.0.2",
73
+ "mocha": "^10.1.0",
74
74
  "node-red": "^2.2.3",
75
75
  "node-red-node-test-helper": "^0.3.0",
76
76
  "prettier": "^2.7.1",
77
77
  "rimraf": "^3.0.2",
78
78
  "ts-node": "^10.9.1",
79
- "typescript": "^4.8.4"
79
+ "typescript": "^4.9.3"
80
80
  },
81
81
  "engines": {
82
82
  "node": ">=10.22.1"