matterbridge 2.1.1-dev.2 → 2.1.1

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.
Files changed (111) hide show
  1. package/CHANGELOG.md +3 -2
  2. package/dist/cli.d.ts +25 -0
  3. package/dist/cli.d.ts.map +1 -0
  4. package/dist/cli.js +26 -0
  5. package/dist/cli.js.map +1 -0
  6. package/dist/cluster/export.d.ts +2 -0
  7. package/dist/cluster/export.d.ts.map +1 -0
  8. package/dist/cluster/export.js +2 -0
  9. package/dist/cluster/export.js.map +1 -0
  10. package/dist/defaultConfigSchema.d.ts +27 -0
  11. package/dist/defaultConfigSchema.d.ts.map +1 -0
  12. package/dist/defaultConfigSchema.js +23 -0
  13. package/dist/defaultConfigSchema.js.map +1 -0
  14. package/dist/deviceManager.d.ts +46 -0
  15. package/dist/deviceManager.d.ts.map +1 -0
  16. package/dist/deviceManager.js +26 -1
  17. package/dist/deviceManager.js.map +1 -0
  18. package/dist/frontend.d.ts +109 -0
  19. package/dist/frontend.d.ts.map +1 -0
  20. package/dist/frontend.js +227 -22
  21. package/dist/frontend.js.map +1 -0
  22. package/dist/index.d.ts +35 -0
  23. package/dist/index.d.ts.map +1 -0
  24. package/dist/index.js +28 -0
  25. package/dist/index.js.map +1 -0
  26. package/dist/logger/export.d.ts +2 -0
  27. package/dist/logger/export.d.ts.map +1 -0
  28. package/dist/logger/export.js +1 -0
  29. package/dist/logger/export.js.map +1 -0
  30. package/dist/matter/behaviors.d.ts +2 -0
  31. package/dist/matter/behaviors.d.ts.map +1 -0
  32. package/dist/matter/behaviors.js +2 -0
  33. package/dist/matter/behaviors.js.map +1 -0
  34. package/dist/matter/clusters.d.ts +2 -0
  35. package/dist/matter/clusters.d.ts.map +1 -0
  36. package/dist/matter/clusters.js +2 -0
  37. package/dist/matter/clusters.js.map +1 -0
  38. package/dist/matter/devices.d.ts +2 -0
  39. package/dist/matter/devices.d.ts.map +1 -0
  40. package/dist/matter/devices.js +2 -0
  41. package/dist/matter/devices.js.map +1 -0
  42. package/dist/matter/endpoints.d.ts +2 -0
  43. package/dist/matter/endpoints.d.ts.map +1 -0
  44. package/dist/matter/endpoints.js +2 -0
  45. package/dist/matter/endpoints.js.map +1 -0
  46. package/dist/matter/export.d.ts +4 -0
  47. package/dist/matter/export.d.ts.map +1 -0
  48. package/dist/matter/export.js +2 -0
  49. package/dist/matter/export.js.map +1 -0
  50. package/dist/matter/types.d.ts +3 -0
  51. package/dist/matter/types.d.ts.map +1 -0
  52. package/dist/matter/types.js +2 -0
  53. package/dist/matter/types.js.map +1 -0
  54. package/dist/matterbridge.d.ts +409 -0
  55. package/dist/matterbridge.d.ts.map +1 -0
  56. package/dist/matterbridge.js +754 -40
  57. package/dist/matterbridge.js.map +1 -0
  58. package/dist/matterbridgeAccessoryPlatform.d.ts +39 -0
  59. package/dist/matterbridgeAccessoryPlatform.d.ts.map +1 -0
  60. package/dist/matterbridgeAccessoryPlatform.js +33 -0
  61. package/dist/matterbridgeAccessoryPlatform.js.map +1 -0
  62. package/dist/matterbridgeBehaviors.d.ts +1056 -0
  63. package/dist/matterbridgeBehaviors.d.ts.map +1 -0
  64. package/dist/matterbridgeBehaviors.js +32 -1
  65. package/dist/matterbridgeBehaviors.js.map +1 -0
  66. package/dist/matterbridgeDeviceTypes.d.ts +177 -0
  67. package/dist/matterbridgeDeviceTypes.d.ts.map +1 -0
  68. package/dist/matterbridgeDeviceTypes.js +112 -11
  69. package/dist/matterbridgeDeviceTypes.js.map +1 -0
  70. package/dist/matterbridgeDynamicPlatform.d.ts +39 -0
  71. package/dist/matterbridgeDynamicPlatform.d.ts.map +1 -0
  72. package/dist/matterbridgeDynamicPlatform.js +33 -0
  73. package/dist/matterbridgeDynamicPlatform.js.map +1 -0
  74. package/dist/matterbridgeEndpoint.d.ts +834 -0
  75. package/dist/matterbridgeEndpoint.d.ts.map +1 -0
  76. package/dist/matterbridgeEndpoint.js +690 -6
  77. package/dist/matterbridgeEndpoint.js.map +1 -0
  78. package/dist/matterbridgeEndpointHelpers.d.ts +2262 -0
  79. package/dist/matterbridgeEndpointHelpers.d.ts.map +1 -0
  80. package/dist/matterbridgeEndpointHelpers.js +96 -0
  81. package/dist/matterbridgeEndpointHelpers.js.map +1 -0
  82. package/dist/matterbridgePlatform.d.ts +164 -0
  83. package/dist/matterbridgePlatform.d.ts.map +1 -0
  84. package/dist/matterbridgePlatform.js +123 -3
  85. package/dist/matterbridgePlatform.js.map +1 -0
  86. package/dist/matterbridgeTypes.d.ts +165 -0
  87. package/dist/matterbridgeTypes.d.ts.map +1 -0
  88. package/dist/matterbridgeTypes.js +24 -0
  89. package/dist/matterbridgeTypes.js.map +1 -0
  90. package/dist/pluginManager.d.ts +238 -0
  91. package/dist/pluginManager.d.ts.map +1 -0
  92. package/dist/pluginManager.js +240 -3
  93. package/dist/pluginManager.js.map +1 -0
  94. package/dist/storage/export.d.ts +2 -0
  95. package/dist/storage/export.d.ts.map +1 -0
  96. package/dist/storage/export.js +1 -0
  97. package/dist/storage/export.js.map +1 -0
  98. package/dist/utils/colorUtils.d.ts +61 -0
  99. package/dist/utils/colorUtils.d.ts.map +1 -0
  100. package/dist/utils/colorUtils.js +205 -2
  101. package/dist/utils/colorUtils.js.map +1 -0
  102. package/dist/utils/export.d.ts +3 -0
  103. package/dist/utils/export.d.ts.map +1 -0
  104. package/dist/utils/export.js +1 -0
  105. package/dist/utils/export.js.map +1 -0
  106. package/dist/utils/utils.d.ts +221 -0
  107. package/dist/utils/utils.d.ts.map +1 -0
  108. package/dist/utils/utils.js +251 -7
  109. package/dist/utils/utils.js.map +1 -0
  110. package/npm-shrinkwrap.json +2 -2
  111. package/package.json +2 -1
@@ -1,23 +1,59 @@
1
+ /**
2
+ * This file contains the class MatterbridgeAccessoryPlatform.
3
+ *
4
+ * @file matterbridgePlatform.ts
5
+ * @author Luca Liguori
6
+ * @date 2024-03-21
7
+ * @version 1.1.0
8
+ *
9
+ * Copyright 2024, 2025, 2026 Luca Liguori.
10
+ *
11
+ * Licensed under the Apache License, Version 2.0 (the "License");
12
+ * you may not use this file except in compliance with the License.
13
+ * You may obtain a copy of the License at
14
+ *
15
+ * http://www.apache.org/licenses/LICENSE-2.0
16
+ *
17
+ * Unless required by applicable law or agreed to in writing, software
18
+ * distributed under the License is distributed on an "AS IS" BASIS,
19
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
20
+ * See the License for the specific language governing permissions and
21
+ * limitations under the License. *
22
+ */
1
23
  import { isValidArray, isValidObject, isValidString } from './utils/utils.js';
24
+ // AnsiLogger module
2
25
  import { CYAN, db, nf, wr } from './logger/export.js';
26
+ // Storage module
3
27
  import { NodeStorageManager } from './storage/export.js';
28
+ // Node.js module
4
29
  import path from 'path';
30
+ /**
31
+ * Represents the base Matterbridge platform.
32
+ *
33
+ */
5
34
  export class MatterbridgePlatform {
6
35
  matterbridge;
7
36
  log;
8
37
  config = {};
9
- name = '';
10
- type = '';
11
- version = '1.0.0';
38
+ name = ''; // Will be set by the loadPlugin() method using the package.json value.
39
+ type = ''; // Will be set by the extending classes.
40
+ version = '1.0.0'; // Will be set by the loadPlugin() method using the package.json value.
12
41
  storage;
13
42
  context;
14
43
  selectDevice = new Map();
15
44
  selectEntity = new Map();
16
45
  registeredEndpoints = new Map();
46
+ /**
47
+ * Creates an instance of the base MatterbridgePlatform.
48
+ * @param {Matterbridge} matterbridge - The Matterbridge instance.
49
+ * @param {AnsiLogger} log - The logger instance.
50
+ * @param {PlatformConfig} config - The platform configuration.
51
+ */
17
52
  constructor(matterbridge, log, config) {
18
53
  this.matterbridge = matterbridge;
19
54
  this.log = log;
20
55
  this.config = config;
56
+ // create the NodeStorageManager for the plugin platform
21
57
  if (!isValidString(this.config.name))
22
58
  return;
23
59
  this.log.debug(`Creating storage for plugin ${this.config.name} in ${path.join(this.matterbridge.matterbridgeDirectory, this.config.name)}`);
@@ -29,36 +65,74 @@ export class MatterbridgePlatform {
29
65
  forgiveParseErrors: true,
30
66
  });
31
67
  }
68
+ /**
69
+ * This method must be overridden in the extended class.
70
+ * It is called when the platform is started.
71
+ * Use this method to create the MatterbridgeDevice and call this.registerDevice().
72
+ * @param {string} [reason] - The reason for starting.
73
+ * @throws {Error} - Throws an error if the method is not overridden.
74
+ */
32
75
  async onStart(reason) {
33
76
  this.log.error('Plugins must override onStart.', reason);
34
77
  throw new Error('Plugins must override onStart.');
35
78
  }
79
+ /**
80
+ * This method can be overridden in the extended class.
81
+ * It is called after the platform has been commissioned.
82
+ * Use this method to perform any configuration of your devices.
83
+ */
36
84
  async onConfigure() {
37
85
  this.log.debug(`Configuring platform ${this.name}`);
38
86
  await this.checkEndpointNumbers();
39
87
  }
88
+ /**
89
+ * This method can be overridden in the extended class.
90
+ * It is called when the platform is shutting down.
91
+ * Use this method to clean up any resources.
92
+ * @param {string} [reason] - The reason for shutting down.
93
+ */
40
94
  async onShutdown(reason) {
41
95
  this.log.debug(`Shutting down platform ${this.name}`, reason);
42
96
  await this.checkEndpointNumbers();
43
97
  }
98
+ /**
99
+ * Sets the logger level and logs a debug message indicating that the plugin doesn't override this method.
100
+ * @param {LogLevel} logLevel The new logger level.
101
+ */
44
102
  async onChangeLoggerLevel(logLevel) {
45
103
  this.log.debug(`The plugin doesn't override onChangeLoggerLevel. Logger level set to: ${logLevel}`);
46
104
  }
105
+ /**
106
+ * Registers a device with the Matterbridge platform.
107
+ * @param {MatterbridgeEndpoint} device - The device to register.
108
+ */
47
109
  async registerDevice(device) {
48
110
  device.plugin = this.name;
49
111
  await this.matterbridge.addBridgedEndpoint(this.name, device);
50
112
  if (device.uniqueId)
51
113
  this.registeredEndpoints.set(device.uniqueId, device);
52
114
  }
115
+ /**
116
+ * Unregisters a device registered with the Matterbridge platform.
117
+ * @param {MatterbridgeEndpoint} device - The device to unregister.
118
+ */
53
119
  async unregisterDevice(device) {
54
120
  await this.matterbridge.removeBridgedEndpoint(this.name, device);
55
121
  if (device.uniqueId)
56
122
  this.registeredEndpoints.delete(device.uniqueId);
57
123
  }
124
+ /**
125
+ * Unregisters all devices registered with the Matterbridge platform.
126
+ */
58
127
  async unregisterAllDevices() {
59
128
  await this.matterbridge.removeAllBridgedEndpoints(this.name);
60
129
  this.registeredEndpoints.clear();
61
130
  }
131
+ /**
132
+ * Verifies if the Matterbridge version meets the required version.
133
+ * @param {string} requiredVersion - The required version to compare against.
134
+ * @returns {boolean} True if the Matterbridge version meets or exceeds the required version, false otherwise.
135
+ */
62
136
  verifyMatterbridgeVersion(requiredVersion) {
63
137
  const compareVersions = (matterbridgeVersion, requiredVersion) => {
64
138
  const stripTag = (v) => {
@@ -83,9 +157,27 @@ export class MatterbridgePlatform {
83
157
  return false;
84
158
  return true;
85
159
  }
160
+ /**
161
+ * Validates if a device is allowed based on the whitelist and blacklist configurations.
162
+ * The blacklist has priority over the whitelist.
163
+ *
164
+ * @param {string | string[]} device - The device name(s) to validate.
165
+ * @param {boolean} [log=true] - Whether to log the validation result.
166
+ * @returns {boolean} - Returns true if the device is allowed, false otherwise.
167
+ */
86
168
  validateDevice(device, log = true) {
87
169
  return this.validateDeviceWhiteBlackList(device, log);
88
170
  }
171
+ /**
172
+ * Validates if a device is allowed based on the whitelist and blacklist configurations.
173
+ * The blacklist has priority over the whitelist.
174
+ *
175
+ * @param {string | string[]} device - The device name(s) to validate.
176
+ * @param {boolean} [log=true] - Whether to log the validation result.
177
+ * @returns {boolean} - Returns true if the device is allowed, false otherwise.
178
+ *
179
+ * @deprecated This method is deprecated and will be removed in future versions. Use validateDevice instead.
180
+ */
89
181
  validateDeviceWhiteBlackList(device, log = true) {
90
182
  if (!Array.isArray(device))
91
183
  device = [device];
@@ -115,9 +207,27 @@ export class MatterbridgePlatform {
115
207
  this.log.info(`Skipping device ${CYAN}${device.join(', ')}${nf} because not in whitelist`);
116
208
  return false;
117
209
  }
210
+ /**
211
+ * Validates if an entity is allowed based on the entity whitelist and blacklist and the device-entity blacklist configurations.
212
+ *
213
+ * @param {string} device - The device to which the entity belongs.
214
+ * @param {string} entity - The entity to validate.
215
+ * @param {boolean} [log=true] - Whether to log the validation result.
216
+ * @returns {boolean} - Returns true if the entity is allowed, false otherwise.
217
+ */
118
218
  validateEntity(device, entity, log = true) {
119
219
  return this.validateEntityBlackList(device, entity, log);
120
220
  }
221
+ /**
222
+ * Validates if an entity is allowed based on the entity blacklist and device-entity blacklist configurations.
223
+ *
224
+ * @param {string} device - The device to which the entity belongs.
225
+ * @param {string} entity - The entity to validate.
226
+ * @param {boolean} [log=true] - Whether to log the validation result.
227
+ * @returns {boolean} - Returns true if the entity is allowed, false otherwise.
228
+ *
229
+ * @deprecated This method is deprecated and will be removed in future versions. Use validateEntity instead.
230
+ */
121
231
  validateEntityBlackList(device, entity, log = true) {
122
232
  if (isValidArray(this.config.entityBlackList, 1) && this.config.entityBlackList.find((e) => e === entity)) {
123
233
  if (log)
@@ -136,6 +246,15 @@ export class MatterbridgePlatform {
136
246
  }
137
247
  return true;
138
248
  }
249
+ /**
250
+ * Checks and updates the endpoint numbers for Matterbridge devices.
251
+ *
252
+ * This method retrieves the list of Matterbridge devices and their child endpoints,
253
+ * compares their current endpoint numbers with the stored ones, and updates the storage
254
+ * if there are any changes. It logs the changes and updates the endpoint numbers accordingly.
255
+ *
256
+ * @returns {Promise<number>} The size of the updated endpoint map, or -1 if storage is not available.
257
+ */
139
258
  async checkEndpointNumbers() {
140
259
  if (!this.storage)
141
260
  return -1;
@@ -175,3 +294,4 @@ export class MatterbridgePlatform {
175
294
  return endpointMap.size;
176
295
  }
177
296
  }
297
+ //# sourceMappingURL=matterbridgePlatform.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"matterbridgePlatform.js","sourceRoot":"","sources":["../src/matterbridgePlatform.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AAKH,OAAO,EAAE,YAAY,EAAE,aAAa,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AAE9E,oBAAoB;AACpB,OAAO,EAAc,IAAI,EA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AAC,mCAAmC,CAAC,CAAC;QACpD,OAAO,WAAW,CAAC,IAAI,CAAC;IAC1B,CAAC;CACF"}
@@ -0,0 +1,165 @@
1
+ /**
2
+ * This file contains the types for Matterbridge.
3
+ *
4
+ * @file matterbridgeTypes.ts
5
+ * @author Luca Liguori
6
+ * @date 2024-07-12
7
+ * @version 1.0.2
8
+ *
9
+ * Copyright 2023, 2024, 2025 Luca Liguori.
10
+ *
11
+ * Licensed under the Apache License, Version 2.0 (the "License");
12
+ * you may not use this file except in compliance with the License.
13
+ * You may obtain a copy of the License at
14
+ *
15
+ * http://www.apache.org/licenses/LICENSE-2.0
16
+ *
17
+ * Unless required by applicable law or agreed to in writing, software
18
+ * distributed under the License is distributed on an "AS IS" BASIS,
19
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
20
+ * See the License for the specific language governing permissions and
21
+ * limitations under the License. *
22
+ */
23
+ import { NodeStorage } from './storage/export.js';
24
+ import { LogLevel } from './logger/export.js';
25
+ import { MatterbridgePlatform, PlatformConfig, PlatformSchema } from './matterbridgePlatform.js';
26
+ import { MatterbridgeEndpoint } from './matterbridgeEndpoint.js';
27
+ import { FabricIndex, NodeId, VendorId, StorageContext, ServerNode, EndpointNumber, Endpoint as EndpointNode } from '@matter/main';
28
+ import { ExposedFabricInformation } from '@matter/main/protocol';
29
+ import { AggregatorEndpoint } from '@matter/main/endpoints/aggregator';
30
+ export declare const plg = "\u001B[38;5;33m";
31
+ export declare const dev = "\u001B[38;5;79m";
32
+ export declare const typ = "\u001B[38;5;207m";
33
+ export interface RegisteredPlugin extends BaseRegisteredPlugin {
34
+ nodeContext?: NodeStorage;
35
+ storageContext?: StorageContext;
36
+ serverNode?: ServerNode<ServerNode.RootEndpoint>;
37
+ aggregatorNode?: EndpointNode<AggregatorEndpoint>;
38
+ device?: MatterbridgeEndpoint;
39
+ platform?: MatterbridgePlatform;
40
+ reachabilityTimeout?: NodeJS.Timeout;
41
+ }
42
+ export interface BaseRegisteredPlugin {
43
+ name: string;
44
+ version: string;
45
+ description: string;
46
+ author: string;
47
+ path: string;
48
+ type: string;
49
+ latestVersion?: string;
50
+ locked?: boolean;
51
+ error?: boolean;
52
+ enabled?: boolean;
53
+ loaded?: boolean;
54
+ started?: boolean;
55
+ configured?: boolean;
56
+ paired?: boolean;
57
+ fabricInformations?: SanitizedExposedFabricInformation[];
58
+ sessionInformations?: SanitizedSessionInformation[];
59
+ registeredDevices?: number;
60
+ addedDevices?: number;
61
+ qrPairingCode?: string;
62
+ manualPairingCode?: string;
63
+ configJson?: PlatformConfig;
64
+ schemaJson?: PlatformSchema;
65
+ }
66
+ export interface SystemInformation {
67
+ interfaceName: string;
68
+ macAddress: string;
69
+ ipv4Address: string;
70
+ ipv6Address: string;
71
+ nodeVersion: string;
72
+ hostname: string;
73
+ user: string;
74
+ osType: string;
75
+ osRelease: string;
76
+ osPlatform: string;
77
+ osArch: string;
78
+ totalMemory: string;
79
+ freeMemory: string;
80
+ systemUptime: string;
81
+ }
82
+ export interface MatterbridgeInformation {
83
+ homeDirectory: string;
84
+ rootDirectory: string;
85
+ matterbridgeDirectory: string;
86
+ matterbridgePluginDirectory: string;
87
+ globalModulesDirectory: string;
88
+ matterbridgeVersion: string;
89
+ matterbridgeLatestVersion: string;
90
+ matterbridgeQrPairingCode: string | undefined;
91
+ matterbridgeManualPairingCode: string | undefined;
92
+ matterbridgeFabricInformations: SanitizedExposedFabricInformation[] | undefined;
93
+ matterbridgeSessionInformations: SanitizedSessionInformation[] | undefined;
94
+ matterbridgePaired: boolean | undefined;
95
+ bridgeMode: string;
96
+ restartMode: string;
97
+ readOnly: boolean;
98
+ profile?: string;
99
+ loggerLevel: LogLevel;
100
+ fileLogger: boolean;
101
+ matterLoggerLevel: number;
102
+ matterFileLogger: boolean;
103
+ mattermdnsinterface: string | undefined;
104
+ matteripv4address: string | undefined;
105
+ matteripv6address: string | undefined;
106
+ matterPort: number;
107
+ matterDiscriminator: number | undefined;
108
+ matterPasscode: number | undefined;
109
+ restartRequired: boolean;
110
+ refreshRequired: boolean;
111
+ }
112
+ export interface SanitizedExposedFabricInformation {
113
+ fabricIndex: FabricIndex;
114
+ fabricId: string;
115
+ nodeId: string;
116
+ rootNodeId: string;
117
+ rootVendorId: VendorId;
118
+ rootVendorName: string;
119
+ label: string;
120
+ }
121
+ export interface SessionInformation {
122
+ name: string;
123
+ nodeId: NodeId;
124
+ peerNodeId: NodeId;
125
+ fabric?: ExposedFabricInformation;
126
+ isPeerActive: boolean;
127
+ secure: boolean;
128
+ lastInteractionTimestamp?: number;
129
+ lastActiveTimestamp?: number;
130
+ numberOfActiveSubscriptions: number;
131
+ }
132
+ export interface SanitizedSessionInformation {
133
+ name: string;
134
+ nodeId: string;
135
+ peerNodeId: string;
136
+ fabric?: SanitizedExposedFabricInformation;
137
+ isPeerActive: boolean;
138
+ secure: boolean;
139
+ lastInteractionTimestamp?: string;
140
+ lastActiveTimestamp?: string;
141
+ numberOfActiveSubscriptions: number;
142
+ }
143
+ export interface ApiDevices {
144
+ pluginName: string;
145
+ type: string;
146
+ endpoint: EndpointNumber | undefined;
147
+ name: string;
148
+ serial: string;
149
+ productUrl: string;
150
+ configUrl?: string;
151
+ uniqueId: string;
152
+ cluster: string;
153
+ }
154
+ export interface ApiClusters {
155
+ endpoint: string;
156
+ id: string;
157
+ deviceTypes: number[];
158
+ clusterName: string;
159
+ clusterId: string;
160
+ attributeName: string;
161
+ attributeId: string;
162
+ attributeValue: string;
163
+ attributeLocalValue: unknown;
164
+ }
165
+ //# sourceMappingURL=matterbridgeTypes.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"matterbridgeTypes.d.ts","sourceRoot":"","sources":["../src/matterbridgeTypes.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AAGH,OAAO,EAAE,WAAW,EAAE,MAAM,qBAAqB,CAAC;AAClD,OAAO,EAAE,QAAQ,EAAE,MAAM,oBAAoB,CAAC;AAG9C,OAAO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,CAAC,EAAE,MAAM,CAAC;IAC7B,2BAA2B,EAAE,MAAM,CAAC;CACrC;AAED,MAAM,WAAW,2BAA2B;IAC1C,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,EAAE,MAAM,CAAC;IACf,UAAU,EAAE,MAAM,CAAC;IACnB,MAAM,CAAC,EAAE,iCAAiC,CAAC;IAC3C,YAAY,EAAE,OAAO,CAAC;IACtB,MAAM,EAAE,OAAO,CAAC;IAChB,wBAAwB,CAAC,EAAE,MAAM,CAAC;IAClC,mBAAmB,CAAC,EAAE,MAAM,CAAC;IAC7B,2BAA2B,EAAE,MAAM,CAAC;CACrC;AAED,MAAM,WAAW,UAAU;IACzB,UAAU,EAAE,MAAM,CAAC;IACnB,IAAI,EAAE,MAAM,CAAC;IACb,QAAQ,EAAE,cAAc,GAAG,SAAS,CAAC;IACrC,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,EAAE,MAAM,CAAC;IACf,UAAU,EAAE,MAAM,CAAC;IACnB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,QAAQ,EAAE,MAAM,CAAC;IACjB,OAAO,EAAE,MAAM,CAAC;CACjB;AAED,MAAM,WAAW,WAAW;IAC1B,QAAQ,EAAE,MAAM,CAAC;IACjB,EAAE,EAAE,MAAM,CAAC;IACX,WAAW,EAAE,MAAM,EAAE,CAAC;IACtB,WAAW,EAAE,MAAM,CAAC;IACpB,SAAS,EAAE,MAAM,CAAC;IAClB,aAAa,EAAE,MAAM,CAAC;IACtB,WAAW,EAAE,MAAM,CAAC;IACpB,cAAc,EAAE,MAAM,CAAC;IACvB,mBAAmB,EAAE,OAAO,CAAC;CAC9B"}
@@ -1,3 +1,27 @@
1
+ /**
2
+ * This file contains the types for Matterbridge.
3
+ *
4
+ * @file matterbridgeTypes.ts
5
+ * @author Luca Liguori
6
+ * @date 2024-07-12
7
+ * @version 1.0.2
8
+ *
9
+ * Copyright 2023, 2024, 2025 Luca Liguori.
10
+ *
11
+ * Licensed under the Apache License, Version 2.0 (the "License");
12
+ * you may not use this file except in compliance with the License.
13
+ * You may obtain a copy of the License at
14
+ *
15
+ * http://www.apache.org/licenses/LICENSE-2.0
16
+ *
17
+ * Unless required by applicable law or agreed to in writing, software
18
+ * distributed under the License is distributed on an "AS IS" BASIS,
19
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
20
+ * See the License for the specific language governing permissions and
21
+ * limitations under the License. *
22
+ */
23
+ // Default colors
1
24
  export const plg = '\u001B[38;5;33m';
2
25
  export const dev = '\u001B[38;5;79m';
3
26
  export const typ = '\u001B[38;5;207m';
27
+ //# sourceMappingURL=matterbridgeTypes.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"matterbridgeTypes.js","sourceRoot":"","sources":["../src/matterbridgeTypes.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AAeH,iBAAiB;AACjB,MAAM,CAAC,MAAM,GAAG,GAAG,iBAAiB,CAAC;AACrC,MAAM,CAAC,MAAM,GAAG,GAAG,iBAAiB,CAAC;AACrC,MAAM,CAAC,MAAM,GAAG,GAAG,kBAAkB,CAAC"}