@camstack/addon-agent-ui 1.2.110 → 1.2.112
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 +189 -1
- package/package.json +1 -1
package/dist/addon.js
CHANGED
|
@@ -13244,6 +13244,107 @@ var ExposeInputSchema = object({
|
|
|
13244
13244
|
});
|
|
13245
13245
|
var UnexposeInputSchema = object({ deviceId: string() });
|
|
13246
13246
|
method(_void(), DeviceExportStatusSchema), method(_void(), array(DeviceKindSchema)), method(_void(), array(ExposedDeviceSchema)), method(ExposeInputSchema, _void(), { kind: "mutation" }), method(UnexposeInputSchema, _void(), { kind: "mutation" });
|
|
13247
|
+
/** Wire/storage schema for one icon id. */
|
|
13248
|
+
var LocationIconIdSchema = _enum([
|
|
13249
|
+
"map-pin",
|
|
13250
|
+
"house",
|
|
13251
|
+
"door-open",
|
|
13252
|
+
"sofa",
|
|
13253
|
+
"utensils",
|
|
13254
|
+
"bed-double",
|
|
13255
|
+
"bath",
|
|
13256
|
+
"briefcase",
|
|
13257
|
+
"car",
|
|
13258
|
+
"circle-parking",
|
|
13259
|
+
"route",
|
|
13260
|
+
"trees",
|
|
13261
|
+
"umbrella",
|
|
13262
|
+
"waves-ladder",
|
|
13263
|
+
"fence",
|
|
13264
|
+
"package",
|
|
13265
|
+
"warehouse",
|
|
13266
|
+
"store",
|
|
13267
|
+
"sun",
|
|
13268
|
+
"radar"
|
|
13269
|
+
]);
|
|
13270
|
+
/**
|
|
13271
|
+
* One (location, icon) assignment as it travels.
|
|
13272
|
+
*
|
|
13273
|
+
* `locationKey` is ALWAYS {@link locationIconKey} of the label — never the
|
|
13274
|
+
* operator's casing. The registry matches labels trimmed + case-insensitively
|
|
13275
|
+
* everywhere (`addLocation`, `removeLocation`, `renameLocation`), and a
|
|
13276
|
+
* case-only rename (`cucina` → `Cucina`) is a real edit this repo supports; a
|
|
13277
|
+
* map keyed on the displayed casing would orphan its entry on exactly that
|
|
13278
|
+
* edit. Consumers join by keying their own label through `locationIconKey`.
|
|
13279
|
+
*/
|
|
13280
|
+
var LocationIconAssignmentSchema = object({
|
|
13281
|
+
locationKey: string(),
|
|
13282
|
+
icon: LocationIconIdSchema
|
|
13283
|
+
});
|
|
13284
|
+
/**
|
|
13285
|
+
* One (location, description) assignment as it travels.
|
|
13286
|
+
*
|
|
13287
|
+
* Same key discipline as {@link LocationIconAssignmentSchema}, and for the same
|
|
13288
|
+
* reason: this lived for a while in the post-analysis addon's own settings,
|
|
13289
|
+
* keyed by a HAND-TYPED label matched exactly and case-sensitively. A rename in
|
|
13290
|
+
* the Locations page carried the icon and silently orphaned the description —
|
|
13291
|
+
* two authorities for one thing, joined by two different rules. Now both hang
|
|
13292
|
+
* off the location itself, on `locationIconKey`.
|
|
13293
|
+
*/
|
|
13294
|
+
var LocationDescriptionAssignmentSchema = object({
|
|
13295
|
+
locationKey: string(),
|
|
13296
|
+
description: string()
|
|
13297
|
+
});
|
|
13298
|
+
/**
|
|
13299
|
+
* A SITE ZONE — a named part of the property that several locations belong to.
|
|
13300
|
+
*
|
|
13301
|
+
* "Zona notte" holds every bedroom; "Zona giorno" the living room and the
|
|
13302
|
+
* kitchen. A camera belongs to exactly one location, and a location to at most
|
|
13303
|
+
* one zone, so a camera's zone is derived and never stored on the device: the
|
|
13304
|
+
* whole point of this entity is that grouping rooms touches no device row.
|
|
13305
|
+
*
|
|
13306
|
+
* ## Why not `zone`
|
|
13307
|
+
*
|
|
13308
|
+
* Because `zone` is already the most loaded word in this product: 612 source
|
|
13309
|
+
* files and 24 Italian strings where it means a DETECTION zone drawn on a
|
|
13310
|
+
* camera. The two are unrelated — one is a polygon in a frame, the other is a
|
|
13311
|
+
* set of rooms — and a reader who confuses them will look for a camera's
|
|
13312
|
+
* bedrooms. So the code says `siteZone` everywhere, and the UI frees the plain
|
|
13313
|
+
* word by calling the drawn one what it actually is: a detection zone.
|
|
13314
|
+
*
|
|
13315
|
+
* ## The key
|
|
13316
|
+
*
|
|
13317
|
+
* `siteZoneKey(label)` — trimmed, lower-cased, the SAME derivation locations
|
|
13318
|
+
* use (`locationIconKey`). Membership and the icon both hang off it, so a
|
|
13319
|
+
* case-only rename keeps them, which is exactly the orphaning that cost us a
|
|
13320
|
+
* silently-dropped location description.
|
|
13321
|
+
*
|
|
13322
|
+
* The icon vocabulary is the location one, unchanged: a zone is drawn on the
|
|
13323
|
+
* same two surfaces by the same glyph map, so a second vocabulary would be a
|
|
13324
|
+
* second thing to keep drawable (`scripts/check-location-icons-drawable.ts`).
|
|
13325
|
+
*/
|
|
13326
|
+
/**
|
|
13327
|
+
* One zone as it travels: its key, the label the operator typed, its icon and
|
|
13328
|
+
* the locations inside it.
|
|
13329
|
+
*
|
|
13330
|
+
* The LABEL is carried alongside the key because the key is lossy on purpose —
|
|
13331
|
+
* a surface must show "Zona notte", not "zona notte". Locations are carried
|
|
13332
|
+
* here, rather than left to a second call, because every consumer wants both
|
|
13333
|
+
* at once and a viewer that asked twice could render a zone whose membership
|
|
13334
|
+
* it has not fetched yet.
|
|
13335
|
+
*
|
|
13336
|
+
* `icon: null` means nobody chose one, which is NOT the fallback pin: only one
|
|
13337
|
+
* of those two is a choice, and a picker has to draw them differently.
|
|
13338
|
+
*/
|
|
13339
|
+
var SiteZoneSchema = object({
|
|
13340
|
+
zoneKey: string(),
|
|
13341
|
+
label: string(),
|
|
13342
|
+
icon: LocationIconIdSchema.nullable(),
|
|
13343
|
+
/** Folded location keys, sorted. A location listed here need not be
|
|
13344
|
+
* REGISTERED — devices carry labels nobody registered, and those rooms are
|
|
13345
|
+
* the ones that most want grouping. */
|
|
13346
|
+
locationKeys: array(string())
|
|
13347
|
+
});
|
|
13247
13348
|
var ProviderStatusSchema = object({
|
|
13248
13349
|
connected: boolean(),
|
|
13249
13350
|
deviceCount: number(),
|
|
@@ -13755,6 +13856,39 @@ method(object({
|
|
|
13755
13856
|
}), object({ moved: number() }), {
|
|
13756
13857
|
kind: "mutation",
|
|
13757
13858
|
auth: "admin"
|
|
13859
|
+
}), method(_void(), array(LocationIconAssignmentSchema)), method(object({
|
|
13860
|
+
location: string(),
|
|
13861
|
+
icon: LocationIconIdSchema.nullable()
|
|
13862
|
+
}), _void(), {
|
|
13863
|
+
kind: "mutation",
|
|
13864
|
+
auth: "admin"
|
|
13865
|
+
}), method(_void(), array(LocationDescriptionAssignmentSchema)), method(object({
|
|
13866
|
+
location: string(),
|
|
13867
|
+
description: string().max(400).nullable()
|
|
13868
|
+
}), _void(), {
|
|
13869
|
+
kind: "mutation",
|
|
13870
|
+
auth: "admin"
|
|
13871
|
+
}), method(_void(), array(SiteZoneSchema)), method(object({
|
|
13872
|
+
name: string(),
|
|
13873
|
+
icon: LocationIconIdSchema.nullable().optional()
|
|
13874
|
+
}), _void(), {
|
|
13875
|
+
kind: "mutation",
|
|
13876
|
+
auth: "admin"
|
|
13877
|
+
}), method(object({ name: string() }), _void(), {
|
|
13878
|
+
kind: "mutation",
|
|
13879
|
+
auth: "admin"
|
|
13880
|
+
}), method(object({
|
|
13881
|
+
from: string(),
|
|
13882
|
+
to: string()
|
|
13883
|
+
}), _void(), {
|
|
13884
|
+
kind: "mutation",
|
|
13885
|
+
auth: "admin"
|
|
13886
|
+
}), method(object({
|
|
13887
|
+
location: string(),
|
|
13888
|
+
zone: string().nullable()
|
|
13889
|
+
}), _void(), {
|
|
13890
|
+
kind: "mutation",
|
|
13891
|
+
auth: "admin"
|
|
13758
13892
|
}), method(object({
|
|
13759
13893
|
deviceId: number(),
|
|
13760
13894
|
disabled: boolean()
|
|
@@ -32578,6 +32712,18 @@ Object.freeze({
|
|
|
32578
32712
|
addonId: null,
|
|
32579
32713
|
access: "view"
|
|
32580
32714
|
},
|
|
32715
|
+
"deviceManager.listLocationDescriptions": {
|
|
32716
|
+
capName: "device-manager",
|
|
32717
|
+
capScope: "system",
|
|
32718
|
+
addonId: null,
|
|
32719
|
+
access: "view"
|
|
32720
|
+
},
|
|
32721
|
+
"deviceManager.listLocationIcons": {
|
|
32722
|
+
capName: "device-manager",
|
|
32723
|
+
capScope: "system",
|
|
32724
|
+
addonId: null,
|
|
32725
|
+
access: "view"
|
|
32726
|
+
},
|
|
32581
32727
|
"deviceManager.listLocations": {
|
|
32582
32728
|
capName: "device-manager",
|
|
32583
32729
|
capScope: "system",
|
|
@@ -32590,6 +32736,12 @@ Object.freeze({
|
|
|
32590
32736
|
addonId: null,
|
|
32591
32737
|
access: "view"
|
|
32592
32738
|
},
|
|
32739
|
+
"deviceManager.listSiteZones": {
|
|
32740
|
+
capName: "device-manager",
|
|
32741
|
+
capScope: "system",
|
|
32742
|
+
addonId: null,
|
|
32743
|
+
access: "view"
|
|
32744
|
+
},
|
|
32593
32745
|
"deviceManager.listWrappersForCap": {
|
|
32594
32746
|
capName: "device-manager",
|
|
32595
32747
|
capScope: "system",
|
|
@@ -32674,12 +32826,24 @@ Object.freeze({
|
|
|
32674
32826
|
addonId: null,
|
|
32675
32827
|
access: "delete"
|
|
32676
32828
|
},
|
|
32829
|
+
"deviceManager.removeSiteZone": {
|
|
32830
|
+
capName: "device-manager",
|
|
32831
|
+
capScope: "system",
|
|
32832
|
+
addonId: null,
|
|
32833
|
+
access: "delete"
|
|
32834
|
+
},
|
|
32677
32835
|
"deviceManager.renameLocation": {
|
|
32678
32836
|
capName: "device-manager",
|
|
32679
32837
|
capScope: "system",
|
|
32680
32838
|
addonId: null,
|
|
32681
32839
|
access: "create"
|
|
32682
32840
|
},
|
|
32841
|
+
"deviceManager.renameSiteZone": {
|
|
32842
|
+
capName: "device-manager",
|
|
32843
|
+
capScope: "system",
|
|
32844
|
+
addonId: null,
|
|
32845
|
+
access: "create"
|
|
32846
|
+
},
|
|
32683
32847
|
"deviceManager.runDeviceAction": {
|
|
32684
32848
|
capName: "device-manager",
|
|
32685
32849
|
capScope: "system",
|
|
@@ -32722,6 +32886,24 @@ Object.freeze({
|
|
|
32722
32886
|
addonId: null,
|
|
32723
32887
|
access: "create"
|
|
32724
32888
|
},
|
|
32889
|
+
"deviceManager.setLocationDescription": {
|
|
32890
|
+
capName: "device-manager",
|
|
32891
|
+
capScope: "system",
|
|
32892
|
+
addonId: null,
|
|
32893
|
+
access: "create"
|
|
32894
|
+
},
|
|
32895
|
+
"deviceManager.setLocationIcon": {
|
|
32896
|
+
capName: "device-manager",
|
|
32897
|
+
capScope: "system",
|
|
32898
|
+
addonId: null,
|
|
32899
|
+
access: "create"
|
|
32900
|
+
},
|
|
32901
|
+
"deviceManager.setLocationZone": {
|
|
32902
|
+
capName: "device-manager",
|
|
32903
|
+
capScope: "system",
|
|
32904
|
+
addonId: null,
|
|
32905
|
+
access: "create"
|
|
32906
|
+
},
|
|
32725
32907
|
"deviceManager.setMetadata": {
|
|
32726
32908
|
capName: "device-manager",
|
|
32727
32909
|
capScope: "system",
|
|
@@ -32752,6 +32934,12 @@ Object.freeze({
|
|
|
32752
32934
|
addonId: null,
|
|
32753
32935
|
access: "create"
|
|
32754
32936
|
},
|
|
32937
|
+
"deviceManager.setSiteZone": {
|
|
32938
|
+
capName: "device-manager",
|
|
32939
|
+
capScope: "system",
|
|
32940
|
+
addonId: null,
|
|
32941
|
+
access: "create"
|
|
32942
|
+
},
|
|
32755
32943
|
"deviceManager.setStreamProfileMap": {
|
|
32756
32944
|
capName: "device-manager",
|
|
32757
32945
|
capScope: "system",
|
|
@@ -39840,7 +40028,7 @@ var AgentUIAddon = class extends BaseAddon {
|
|
|
39840
40028
|
capability: adminUiCapability,
|
|
39841
40029
|
provider: {
|
|
39842
40030
|
getStaticDir: async () => ({ staticDir: path.resolve(__dirname) }),
|
|
39843
|
-
getVersion: async () => ({ version: "1.2.
|
|
40031
|
+
getVersion: async () => ({ version: "1.2.112" })
|
|
39844
40032
|
}
|
|
39845
40033
|
}];
|
|
39846
40034
|
}
|