@camstack/addon-provider-homematic 1.2.106 → 1.2.108

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/dist/addon.js CHANGED
@@ -13554,6 +13554,107 @@ var ExposeInputSchema = object({
13554
13554
  });
13555
13555
  var UnexposeInputSchema = object({ deviceId: string() });
13556
13556
  method(_void(), DeviceExportStatusSchema), method(_void(), array(DeviceKindSchema)), method(_void(), array(ExposedDeviceSchema)), method(ExposeInputSchema, _void(), { kind: "mutation" }), method(UnexposeInputSchema, _void(), { kind: "mutation" });
13557
+ /** Wire/storage schema for one icon id. */
13558
+ var LocationIconIdSchema = _enum([
13559
+ "map-pin",
13560
+ "house",
13561
+ "door-open",
13562
+ "sofa",
13563
+ "utensils",
13564
+ "bed-double",
13565
+ "bath",
13566
+ "briefcase",
13567
+ "car",
13568
+ "circle-parking",
13569
+ "route",
13570
+ "trees",
13571
+ "umbrella",
13572
+ "waves-ladder",
13573
+ "fence",
13574
+ "package",
13575
+ "warehouse",
13576
+ "store",
13577
+ "sun",
13578
+ "radar"
13579
+ ]);
13580
+ /**
13581
+ * One (location, icon) assignment as it travels.
13582
+ *
13583
+ * `locationKey` is ALWAYS {@link locationIconKey} of the label — never the
13584
+ * operator's casing. The registry matches labels trimmed + case-insensitively
13585
+ * everywhere (`addLocation`, `removeLocation`, `renameLocation`), and a
13586
+ * case-only rename (`cucina` → `Cucina`) is a real edit this repo supports; a
13587
+ * map keyed on the displayed casing would orphan its entry on exactly that
13588
+ * edit. Consumers join by keying their own label through `locationIconKey`.
13589
+ */
13590
+ var LocationIconAssignmentSchema = object({
13591
+ locationKey: string(),
13592
+ icon: LocationIconIdSchema
13593
+ });
13594
+ /**
13595
+ * One (location, description) assignment as it travels.
13596
+ *
13597
+ * Same key discipline as {@link LocationIconAssignmentSchema}, and for the same
13598
+ * reason: this lived for a while in the post-analysis addon's own settings,
13599
+ * keyed by a HAND-TYPED label matched exactly and case-sensitively. A rename in
13600
+ * the Locations page carried the icon and silently orphaned the description —
13601
+ * two authorities for one thing, joined by two different rules. Now both hang
13602
+ * off the location itself, on `locationIconKey`.
13603
+ */
13604
+ var LocationDescriptionAssignmentSchema = object({
13605
+ locationKey: string(),
13606
+ description: string()
13607
+ });
13608
+ /**
13609
+ * A SITE ZONE — a named part of the property that several locations belong to.
13610
+ *
13611
+ * "Zona notte" holds every bedroom; "Zona giorno" the living room and the
13612
+ * kitchen. A camera belongs to exactly one location, and a location to at most
13613
+ * one zone, so a camera's zone is derived and never stored on the device: the
13614
+ * whole point of this entity is that grouping rooms touches no device row.
13615
+ *
13616
+ * ## Why not `zone`
13617
+ *
13618
+ * Because `zone` is already the most loaded word in this product: 612 source
13619
+ * files and 24 Italian strings where it means a DETECTION zone drawn on a
13620
+ * camera. The two are unrelated — one is a polygon in a frame, the other is a
13621
+ * set of rooms — and a reader who confuses them will look for a camera's
13622
+ * bedrooms. So the code says `siteZone` everywhere, and the UI frees the plain
13623
+ * word by calling the drawn one what it actually is: a detection zone.
13624
+ *
13625
+ * ## The key
13626
+ *
13627
+ * `siteZoneKey(label)` — trimmed, lower-cased, the SAME derivation locations
13628
+ * use (`locationIconKey`). Membership and the icon both hang off it, so a
13629
+ * case-only rename keeps them, which is exactly the orphaning that cost us a
13630
+ * silently-dropped location description.
13631
+ *
13632
+ * The icon vocabulary is the location one, unchanged: a zone is drawn on the
13633
+ * same two surfaces by the same glyph map, so a second vocabulary would be a
13634
+ * second thing to keep drawable (`scripts/check-location-icons-drawable.ts`).
13635
+ */
13636
+ /**
13637
+ * One zone as it travels: its key, the label the operator typed, its icon and
13638
+ * the locations inside it.
13639
+ *
13640
+ * The LABEL is carried alongside the key because the key is lossy on purpose —
13641
+ * a surface must show "Zona notte", not "zona notte". Locations are carried
13642
+ * here, rather than left to a second call, because every consumer wants both
13643
+ * at once and a viewer that asked twice could render a zone whose membership
13644
+ * it has not fetched yet.
13645
+ *
13646
+ * `icon: null` means nobody chose one, which is NOT the fallback pin: only one
13647
+ * of those two is a choice, and a picker has to draw them differently.
13648
+ */
13649
+ var SiteZoneSchema = object({
13650
+ zoneKey: string(),
13651
+ label: string(),
13652
+ icon: LocationIconIdSchema.nullable(),
13653
+ /** Folded location keys, sorted. A location listed here need not be
13654
+ * REGISTERED — devices carry labels nobody registered, and those rooms are
13655
+ * the ones that most want grouping. */
13656
+ locationKeys: array(string())
13657
+ });
13557
13658
  var ProviderStatusSchema = object({
13558
13659
  connected: boolean(),
13559
13660
  deviceCount: number(),
@@ -14146,6 +14247,39 @@ method(object({
14146
14247
  }), object({ moved: number() }), {
14147
14248
  kind: "mutation",
14148
14249
  auth: "admin"
14250
+ }), method(_void(), array(LocationIconAssignmentSchema)), method(object({
14251
+ location: string(),
14252
+ icon: LocationIconIdSchema.nullable()
14253
+ }), _void(), {
14254
+ kind: "mutation",
14255
+ auth: "admin"
14256
+ }), method(_void(), array(LocationDescriptionAssignmentSchema)), method(object({
14257
+ location: string(),
14258
+ description: string().max(400).nullable()
14259
+ }), _void(), {
14260
+ kind: "mutation",
14261
+ auth: "admin"
14262
+ }), method(_void(), array(SiteZoneSchema)), method(object({
14263
+ name: string(),
14264
+ icon: LocationIconIdSchema.nullable().optional()
14265
+ }), _void(), {
14266
+ kind: "mutation",
14267
+ auth: "admin"
14268
+ }), method(object({ name: string() }), _void(), {
14269
+ kind: "mutation",
14270
+ auth: "admin"
14271
+ }), method(object({
14272
+ from: string(),
14273
+ to: string()
14274
+ }), _void(), {
14275
+ kind: "mutation",
14276
+ auth: "admin"
14277
+ }), method(object({
14278
+ location: string(),
14279
+ zone: string().nullable()
14280
+ }), _void(), {
14281
+ kind: "mutation",
14282
+ auth: "admin"
14149
14283
  }), method(object({
14150
14284
  deviceId: number(),
14151
14285
  disabled: boolean()
@@ -37056,6 +37190,18 @@ Object.freeze({
37056
37190
  addonId: null,
37057
37191
  access: "view"
37058
37192
  },
37193
+ "deviceManager.listLocationDescriptions": {
37194
+ capName: "device-manager",
37195
+ capScope: "system",
37196
+ addonId: null,
37197
+ access: "view"
37198
+ },
37199
+ "deviceManager.listLocationIcons": {
37200
+ capName: "device-manager",
37201
+ capScope: "system",
37202
+ addonId: null,
37203
+ access: "view"
37204
+ },
37059
37205
  "deviceManager.listLocations": {
37060
37206
  capName: "device-manager",
37061
37207
  capScope: "system",
@@ -37068,6 +37214,12 @@ Object.freeze({
37068
37214
  addonId: null,
37069
37215
  access: "view"
37070
37216
  },
37217
+ "deviceManager.listSiteZones": {
37218
+ capName: "device-manager",
37219
+ capScope: "system",
37220
+ addonId: null,
37221
+ access: "view"
37222
+ },
37071
37223
  "deviceManager.listWrappersForCap": {
37072
37224
  capName: "device-manager",
37073
37225
  capScope: "system",
@@ -37152,12 +37304,24 @@ Object.freeze({
37152
37304
  addonId: null,
37153
37305
  access: "delete"
37154
37306
  },
37307
+ "deviceManager.removeSiteZone": {
37308
+ capName: "device-manager",
37309
+ capScope: "system",
37310
+ addonId: null,
37311
+ access: "delete"
37312
+ },
37155
37313
  "deviceManager.renameLocation": {
37156
37314
  capName: "device-manager",
37157
37315
  capScope: "system",
37158
37316
  addonId: null,
37159
37317
  access: "create"
37160
37318
  },
37319
+ "deviceManager.renameSiteZone": {
37320
+ capName: "device-manager",
37321
+ capScope: "system",
37322
+ addonId: null,
37323
+ access: "create"
37324
+ },
37161
37325
  "deviceManager.runDeviceAction": {
37162
37326
  capName: "device-manager",
37163
37327
  capScope: "system",
@@ -37200,6 +37364,24 @@ Object.freeze({
37200
37364
  addonId: null,
37201
37365
  access: "create"
37202
37366
  },
37367
+ "deviceManager.setLocationDescription": {
37368
+ capName: "device-manager",
37369
+ capScope: "system",
37370
+ addonId: null,
37371
+ access: "create"
37372
+ },
37373
+ "deviceManager.setLocationIcon": {
37374
+ capName: "device-manager",
37375
+ capScope: "system",
37376
+ addonId: null,
37377
+ access: "create"
37378
+ },
37379
+ "deviceManager.setLocationZone": {
37380
+ capName: "device-manager",
37381
+ capScope: "system",
37382
+ addonId: null,
37383
+ access: "create"
37384
+ },
37203
37385
  "deviceManager.setMetadata": {
37204
37386
  capName: "device-manager",
37205
37387
  capScope: "system",
@@ -37230,6 +37412,12 @@ Object.freeze({
37230
37412
  addonId: null,
37231
37413
  access: "create"
37232
37414
  },
37415
+ "deviceManager.setSiteZone": {
37416
+ capName: "device-manager",
37417
+ capScope: "system",
37418
+ addonId: null,
37419
+ access: "create"
37420
+ },
37233
37421
  "deviceManager.setStreamProfileMap": {
37234
37422
  capName: "device-manager",
37235
37423
  capScope: "system",
package/dist/addon.mjs CHANGED
@@ -13555,6 +13555,107 @@ var ExposeInputSchema = object({
13555
13555
  });
13556
13556
  var UnexposeInputSchema = object({ deviceId: string() });
13557
13557
  method(_void(), DeviceExportStatusSchema), method(_void(), array(DeviceKindSchema)), method(_void(), array(ExposedDeviceSchema)), method(ExposeInputSchema, _void(), { kind: "mutation" }), method(UnexposeInputSchema, _void(), { kind: "mutation" });
13558
+ /** Wire/storage schema for one icon id. */
13559
+ var LocationIconIdSchema = _enum([
13560
+ "map-pin",
13561
+ "house",
13562
+ "door-open",
13563
+ "sofa",
13564
+ "utensils",
13565
+ "bed-double",
13566
+ "bath",
13567
+ "briefcase",
13568
+ "car",
13569
+ "circle-parking",
13570
+ "route",
13571
+ "trees",
13572
+ "umbrella",
13573
+ "waves-ladder",
13574
+ "fence",
13575
+ "package",
13576
+ "warehouse",
13577
+ "store",
13578
+ "sun",
13579
+ "radar"
13580
+ ]);
13581
+ /**
13582
+ * One (location, icon) assignment as it travels.
13583
+ *
13584
+ * `locationKey` is ALWAYS {@link locationIconKey} of the label — never the
13585
+ * operator's casing. The registry matches labels trimmed + case-insensitively
13586
+ * everywhere (`addLocation`, `removeLocation`, `renameLocation`), and a
13587
+ * case-only rename (`cucina` → `Cucina`) is a real edit this repo supports; a
13588
+ * map keyed on the displayed casing would orphan its entry on exactly that
13589
+ * edit. Consumers join by keying their own label through `locationIconKey`.
13590
+ */
13591
+ var LocationIconAssignmentSchema = object({
13592
+ locationKey: string(),
13593
+ icon: LocationIconIdSchema
13594
+ });
13595
+ /**
13596
+ * One (location, description) assignment as it travels.
13597
+ *
13598
+ * Same key discipline as {@link LocationIconAssignmentSchema}, and for the same
13599
+ * reason: this lived for a while in the post-analysis addon's own settings,
13600
+ * keyed by a HAND-TYPED label matched exactly and case-sensitively. A rename in
13601
+ * the Locations page carried the icon and silently orphaned the description —
13602
+ * two authorities for one thing, joined by two different rules. Now both hang
13603
+ * off the location itself, on `locationIconKey`.
13604
+ */
13605
+ var LocationDescriptionAssignmentSchema = object({
13606
+ locationKey: string(),
13607
+ description: string()
13608
+ });
13609
+ /**
13610
+ * A SITE ZONE — a named part of the property that several locations belong to.
13611
+ *
13612
+ * "Zona notte" holds every bedroom; "Zona giorno" the living room and the
13613
+ * kitchen. A camera belongs to exactly one location, and a location to at most
13614
+ * one zone, so a camera's zone is derived and never stored on the device: the
13615
+ * whole point of this entity is that grouping rooms touches no device row.
13616
+ *
13617
+ * ## Why not `zone`
13618
+ *
13619
+ * Because `zone` is already the most loaded word in this product: 612 source
13620
+ * files and 24 Italian strings where it means a DETECTION zone drawn on a
13621
+ * camera. The two are unrelated — one is a polygon in a frame, the other is a
13622
+ * set of rooms — and a reader who confuses them will look for a camera's
13623
+ * bedrooms. So the code says `siteZone` everywhere, and the UI frees the plain
13624
+ * word by calling the drawn one what it actually is: a detection zone.
13625
+ *
13626
+ * ## The key
13627
+ *
13628
+ * `siteZoneKey(label)` — trimmed, lower-cased, the SAME derivation locations
13629
+ * use (`locationIconKey`). Membership and the icon both hang off it, so a
13630
+ * case-only rename keeps them, which is exactly the orphaning that cost us a
13631
+ * silently-dropped location description.
13632
+ *
13633
+ * The icon vocabulary is the location one, unchanged: a zone is drawn on the
13634
+ * same two surfaces by the same glyph map, so a second vocabulary would be a
13635
+ * second thing to keep drawable (`scripts/check-location-icons-drawable.ts`).
13636
+ */
13637
+ /**
13638
+ * One zone as it travels: its key, the label the operator typed, its icon and
13639
+ * the locations inside it.
13640
+ *
13641
+ * The LABEL is carried alongside the key because the key is lossy on purpose —
13642
+ * a surface must show "Zona notte", not "zona notte". Locations are carried
13643
+ * here, rather than left to a second call, because every consumer wants both
13644
+ * at once and a viewer that asked twice could render a zone whose membership
13645
+ * it has not fetched yet.
13646
+ *
13647
+ * `icon: null` means nobody chose one, which is NOT the fallback pin: only one
13648
+ * of those two is a choice, and a picker has to draw them differently.
13649
+ */
13650
+ var SiteZoneSchema = object({
13651
+ zoneKey: string(),
13652
+ label: string(),
13653
+ icon: LocationIconIdSchema.nullable(),
13654
+ /** Folded location keys, sorted. A location listed here need not be
13655
+ * REGISTERED — devices carry labels nobody registered, and those rooms are
13656
+ * the ones that most want grouping. */
13657
+ locationKeys: array(string())
13658
+ });
13558
13659
  var ProviderStatusSchema = object({
13559
13660
  connected: boolean(),
13560
13661
  deviceCount: number(),
@@ -14147,6 +14248,39 @@ method(object({
14147
14248
  }), object({ moved: number() }), {
14148
14249
  kind: "mutation",
14149
14250
  auth: "admin"
14251
+ }), method(_void(), array(LocationIconAssignmentSchema)), method(object({
14252
+ location: string(),
14253
+ icon: LocationIconIdSchema.nullable()
14254
+ }), _void(), {
14255
+ kind: "mutation",
14256
+ auth: "admin"
14257
+ }), method(_void(), array(LocationDescriptionAssignmentSchema)), method(object({
14258
+ location: string(),
14259
+ description: string().max(400).nullable()
14260
+ }), _void(), {
14261
+ kind: "mutation",
14262
+ auth: "admin"
14263
+ }), method(_void(), array(SiteZoneSchema)), method(object({
14264
+ name: string(),
14265
+ icon: LocationIconIdSchema.nullable().optional()
14266
+ }), _void(), {
14267
+ kind: "mutation",
14268
+ auth: "admin"
14269
+ }), method(object({ name: string() }), _void(), {
14270
+ kind: "mutation",
14271
+ auth: "admin"
14272
+ }), method(object({
14273
+ from: string(),
14274
+ to: string()
14275
+ }), _void(), {
14276
+ kind: "mutation",
14277
+ auth: "admin"
14278
+ }), method(object({
14279
+ location: string(),
14280
+ zone: string().nullable()
14281
+ }), _void(), {
14282
+ kind: "mutation",
14283
+ auth: "admin"
14150
14284
  }), method(object({
14151
14285
  deviceId: number(),
14152
14286
  disabled: boolean()
@@ -37057,6 +37191,18 @@ Object.freeze({
37057
37191
  addonId: null,
37058
37192
  access: "view"
37059
37193
  },
37194
+ "deviceManager.listLocationDescriptions": {
37195
+ capName: "device-manager",
37196
+ capScope: "system",
37197
+ addonId: null,
37198
+ access: "view"
37199
+ },
37200
+ "deviceManager.listLocationIcons": {
37201
+ capName: "device-manager",
37202
+ capScope: "system",
37203
+ addonId: null,
37204
+ access: "view"
37205
+ },
37060
37206
  "deviceManager.listLocations": {
37061
37207
  capName: "device-manager",
37062
37208
  capScope: "system",
@@ -37069,6 +37215,12 @@ Object.freeze({
37069
37215
  addonId: null,
37070
37216
  access: "view"
37071
37217
  },
37218
+ "deviceManager.listSiteZones": {
37219
+ capName: "device-manager",
37220
+ capScope: "system",
37221
+ addonId: null,
37222
+ access: "view"
37223
+ },
37072
37224
  "deviceManager.listWrappersForCap": {
37073
37225
  capName: "device-manager",
37074
37226
  capScope: "system",
@@ -37153,12 +37305,24 @@ Object.freeze({
37153
37305
  addonId: null,
37154
37306
  access: "delete"
37155
37307
  },
37308
+ "deviceManager.removeSiteZone": {
37309
+ capName: "device-manager",
37310
+ capScope: "system",
37311
+ addonId: null,
37312
+ access: "delete"
37313
+ },
37156
37314
  "deviceManager.renameLocation": {
37157
37315
  capName: "device-manager",
37158
37316
  capScope: "system",
37159
37317
  addonId: null,
37160
37318
  access: "create"
37161
37319
  },
37320
+ "deviceManager.renameSiteZone": {
37321
+ capName: "device-manager",
37322
+ capScope: "system",
37323
+ addonId: null,
37324
+ access: "create"
37325
+ },
37162
37326
  "deviceManager.runDeviceAction": {
37163
37327
  capName: "device-manager",
37164
37328
  capScope: "system",
@@ -37201,6 +37365,24 @@ Object.freeze({
37201
37365
  addonId: null,
37202
37366
  access: "create"
37203
37367
  },
37368
+ "deviceManager.setLocationDescription": {
37369
+ capName: "device-manager",
37370
+ capScope: "system",
37371
+ addonId: null,
37372
+ access: "create"
37373
+ },
37374
+ "deviceManager.setLocationIcon": {
37375
+ capName: "device-manager",
37376
+ capScope: "system",
37377
+ addonId: null,
37378
+ access: "create"
37379
+ },
37380
+ "deviceManager.setLocationZone": {
37381
+ capName: "device-manager",
37382
+ capScope: "system",
37383
+ addonId: null,
37384
+ access: "create"
37385
+ },
37204
37386
  "deviceManager.setMetadata": {
37205
37387
  capName: "device-manager",
37206
37388
  capScope: "system",
@@ -37231,6 +37413,12 @@ Object.freeze({
37231
37413
  addonId: null,
37232
37414
  access: "create"
37233
37415
  },
37416
+ "deviceManager.setSiteZone": {
37417
+ capName: "device-manager",
37418
+ capScope: "system",
37419
+ addonId: null,
37420
+ access: "create"
37421
+ },
37234
37422
  "deviceManager.setStreamProfileMap": {
37235
37423
  capName: "device-manager",
37236
37424
  capScope: "system",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@camstack/addon-provider-homematic",
3
- "version": "1.2.106",
3
+ "version": "1.2.108",
4
4
  "description": "Homematic / HomematicIP (CCU3 / RaspberryMatic) device-provider addon for CamStack — wraps the nodehomematic library",
5
5
  "keywords": [
6
6
  "camstack",