@camstack/addon-mqtt-broker 1.2.113 → 1.2.115

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.
@@ -5405,7 +5405,7 @@ var ZodIssueCode = {
5405
5405
  var ZodFirstPartyTypeKind;
5406
5406
  ZodFirstPartyTypeKind || (ZodFirstPartyTypeKind = {});
5407
5407
  //#endregion
5408
- //#region ../types/dist/sleep-Dk-BdnBf.mjs
5408
+ //#region ../types/dist/sleep-GU_us3DG.mjs
5409
5409
  /**
5410
5410
  * The audio chunk plane's byte format, and the ONE expansion from a coded
5411
5411
  * window to float samples (D455).
@@ -11899,6 +11899,24 @@ var GetStreamWithCodecInputSchema = object({
11899
11899
  });
11900
11900
  var RtpSourceSchema = object({
11901
11901
  url: string(),
11902
+ /**
11903
+ * The SENTRY counterpart of {@link url} — the dial that asks for the stream
11904
+ * WITHOUT asking for the camera — or `null` when this camera offers none.
11905
+ *
11906
+ * The broker answers it because the broker is the only thing that can:
11907
+ * eligibility is `sentryEligible` (a BATTERY camera that DECLARES the signals
11908
+ * cap), asked of facts only the broker holds. A consumer re-deriving it from
11909
+ * cap bindings would be a second authority, and two authorities on the same
11910
+ * question is how a composite camera ends up dialling a sleeping camera
11911
+ * because its own copy of the rule was a release behind.
11912
+ *
11913
+ * `null` is a real answer and is never a live url in disguise: a consumer
11914
+ * that silently fell back to {@link url} would perform exactly the wake this
11915
+ * field exists to prevent. Only a PASSTHROUGH acquisition can offer one — a
11916
+ * transcode hands back an egress the broker is feeding itself, which has no
11917
+ * sentry counterpart.
11918
+ */
11919
+ sentryUrl: string().nullable().optional(),
11902
11920
  videoCodec: _enum(["H264", "H265"]),
11903
11921
  audioCodec: string(),
11904
11922
  resolution: object({
@@ -27260,6 +27278,118 @@ DeviceType.Light, DeviceType.Siren, DeviceType.Switch, method(object({
27260
27278
  lastChangedAt: number()
27261
27279
  });
27262
27280
  /**
27281
+ * camera-grid-layout — the geometry of a COMPOSITE camera, on the camera's own
27282
+ * page.
27283
+ *
27284
+ * ## Why this is a capability and not an addon settings schema
27285
+ *
27286
+ * It was one, and it did not render. The addon declared the editor as a
27287
+ * `type: 'widget'` field inside its own `deviceSettingsSchema()`; the hub
27288
+ * returned that section correctly and `ConfigFormField` renders `type:'widget'`
27289
+ * perfectly well — and nothing ever asked camera-grid for it. The Cluster →
27290
+ * Pipeline → Device Overrides page interrogates a HAND-WRITTEN list of four
27291
+ * addons (`PIPELINE_CLUSTER_DEVICE_ADDONS`), whose own comment says an addon
27292
+ * not on it "falls off silently".
27293
+ *
27294
+ * Adding a fifth name to that list would have been the wrong fix twice over:
27295
+ * that page is per-camera DETECTION tuning, and a grid's geometry belongs
27296
+ * beside PTZ and motion zones on the camera itself. The device page is
27297
+ * BINDING-driven (D12), so the way in is a capability bound to the device —
27298
+ * and this cap carries its section the way `recording` does, by RETURNING it
27299
+ * from `getDeviceSettingsContribution`.
27300
+ *
27301
+ * Seven other widgets are still declared the other way, through a
27302
+ * `deviceConfig.ui` block the framework derives a section from. That route
27303
+ * gives the addon no say in where its own panel lands and no way to decline
27304
+ * for a device the panel does not suit, which is why this one does not use it.
27305
+ *
27306
+ * ## Why one addon may implement it
27307
+ *
27308
+ * It is a device-scoped NATIVE cap, registered by the grid camera device
27309
+ * itself. Nothing else declares a composite camera, so nothing else has a
27310
+ * layout — and the device-scoped route means the widget asks THE camera, not
27311
+ * "the camera-grid addon", which is what let the old custom-action pair be
27312
+ * reached only by a caller that already knew the addon id.
27313
+ *
27314
+ * ## The tab
27315
+ *
27316
+ * `streaming`, not a top-tab of its own. A grid's geometry IS what its stream
27317
+ * is, so the Streaming tab is where it belongs; a `grid` top-tab would need an
27318
+ * entry in `WELL_KNOWN_TAB_MAP` or the device page renders the raw id as the
27319
+ * label (measured on the robot camera, 2026-09-06 — a tab called "navigation"
27320
+ * next to "PTZ").
27321
+ */
27322
+ /** A rectangle in normalized [0,1] coordinates of whatever contains it. */
27323
+ var GridNormalizedRectSchema = object({
27324
+ x: number().min(0).max(1),
27325
+ y: number().min(0).max(1),
27326
+ width: number().gt(0).max(1),
27327
+ height: number().gt(0).max(1)
27328
+ });
27329
+ /**
27330
+ * One source camera, the part of its picture taken, and where that part lands.
27331
+ *
27332
+ * Both rectangles are NORMALIZED (D519): a source camera can change resolution
27333
+ * — a profile switch, a firmware update, a substream that comes back different
27334
+ * — and a stored PIXEL rectangle would quietly start cutting the wrong region,
27335
+ * which is the class of bug nobody files.
27336
+ */
27337
+ var GridLayoutCellSchema = object({
27338
+ deviceId: number().int().positive(),
27339
+ /** The part of the SOURCE taken, normalized against the source. */
27340
+ source: GridNormalizedRectSchema,
27341
+ /** Where it lands, normalized against the CANVAS. */
27342
+ cell: GridNormalizedRectSchema
27343
+ });
27344
+ /**
27345
+ * Which profiles this grid can actually compose, and why not.
27346
+ *
27347
+ * A grid's `high` composes its sources' `high` and its `low` their `low`, so a
27348
+ * profile is on offer only when EVERY source can serve it. The refusal NAMES
27349
+ * the sources, because "this grid has no low" is not a finding — "615 has no
27350
+ * low" is, and it is the one an operator can act on.
27351
+ */
27352
+ var GridProfileOfferSchema = object({
27353
+ profile: _enum([
27354
+ "high",
27355
+ "mid",
27356
+ "low"
27357
+ ]),
27358
+ offered: boolean(),
27359
+ /** Sources that cannot serve it. Empty when it is offered, or when there are no cells. */
27360
+ missingSources: array(number().int().positive())
27361
+ });
27362
+ var GridLayoutViewSchema = object({
27363
+ /** The persisted grid row this camera was declared from. */
27364
+ instanceId: string(),
27365
+ deviceId: number().int().nonnegative(),
27366
+ name: string(),
27367
+ /** The canvas the operator laid out — this grid's `high`. mid/low are scaled from it. */
27368
+ width: number().int(),
27369
+ height: number().int(),
27370
+ fps: number().int(),
27371
+ cells: array(GridLayoutCellSchema),
27372
+ /** What the catalog will publish, and what it refuses to. Read-only. */
27373
+ profiles: array(GridProfileOfferSchema)
27374
+ });
27375
+ var GridLayoutPatchSchema = object({
27376
+ deviceId: number().int().nonnegative(),
27377
+ name: string().min(1).max(160).optional(),
27378
+ width: number().int().min(160).max(7680).optional(),
27379
+ height: number().int().min(120).max(4320).optional(),
27380
+ fps: number().int().min(1).max(60).optional(),
27381
+ /**
27382
+ * The whole cell list at once. A per-cell patch would need an ordering the
27383
+ * editor does not have, and a half-applied layout is a picture nobody asked
27384
+ * for.
27385
+ */
27386
+ cells: array(GridLayoutCellSchema).max(16)
27387
+ });
27388
+ DeviceType.Camera, method(object({ deviceId: number().int().nonnegative() }), GridLayoutViewSchema.nullable(), { auth: "admin" }), method(GridLayoutPatchSchema, GridLayoutViewSchema, {
27389
+ kind: "mutation",
27390
+ auth: "admin"
27391
+ });
27392
+ /**
27263
27393
  * Motion-zones share the same MaskShape vocabulary as privacy-mask — the
27264
27394
  * on-camera motion-detection mask is a single `grid` region (a row-major
27265
27395
  * boolean cell lattice the camera's onboard VMD evaluates). Composing it as
@@ -32288,6 +32418,18 @@ Object.freeze({
32288
32418
  addonId: null,
32289
32419
  access: "view"
32290
32420
  },
32421
+ "cameraGridLayout.getLayout": {
32422
+ capName: "camera-grid-layout",
32423
+ capScope: "device",
32424
+ addonId: null,
32425
+ access: "view"
32426
+ },
32427
+ "cameraGridLayout.saveLayout": {
32428
+ capName: "camera-grid-layout",
32429
+ capScope: "device",
32430
+ addonId: null,
32431
+ access: "create"
32432
+ },
32291
32433
  "cameraStreams.getBrokerStreams": {
32292
32434
  capName: "camera-streams",
32293
32435
  capScope: "device",
@@ -37987,6 +38129,21 @@ Object.freeze({
37987
38129
  form: "single",
37988
38130
  optional: false
37989
38131
  }],
38132
+ "cameraGridLayout.getLayout": [{
38133
+ name: "deviceId",
38134
+ form: "single",
38135
+ optional: false
38136
+ }],
38137
+ "cameraGridLayout.saveLayout": [{
38138
+ name: "cells",
38139
+ form: "object-array",
38140
+ optional: false,
38141
+ itemField: "deviceId"
38142
+ }, {
38143
+ name: "deviceId",
38144
+ form: "single",
38145
+ optional: false
38146
+ }],
37990
38147
  "cameraStreams.getBrokerStreams": [{
37991
38148
  name: "deviceId",
37992
38149
  form: "single",
@@ -5400,7 +5400,7 @@ var ZodIssueCode = {
5400
5400
  var ZodFirstPartyTypeKind;
5401
5401
  ZodFirstPartyTypeKind || (ZodFirstPartyTypeKind = {});
5402
5402
  //#endregion
5403
- //#region ../types/dist/sleep-Dk-BdnBf.mjs
5403
+ //#region ../types/dist/sleep-GU_us3DG.mjs
5404
5404
  /**
5405
5405
  * The audio chunk plane's byte format, and the ONE expansion from a coded
5406
5406
  * window to float samples (D455).
@@ -11894,6 +11894,24 @@ var GetStreamWithCodecInputSchema = object({
11894
11894
  });
11895
11895
  var RtpSourceSchema = object({
11896
11896
  url: string(),
11897
+ /**
11898
+ * The SENTRY counterpart of {@link url} — the dial that asks for the stream
11899
+ * WITHOUT asking for the camera — or `null` when this camera offers none.
11900
+ *
11901
+ * The broker answers it because the broker is the only thing that can:
11902
+ * eligibility is `sentryEligible` (a BATTERY camera that DECLARES the signals
11903
+ * cap), asked of facts only the broker holds. A consumer re-deriving it from
11904
+ * cap bindings would be a second authority, and two authorities on the same
11905
+ * question is how a composite camera ends up dialling a sleeping camera
11906
+ * because its own copy of the rule was a release behind.
11907
+ *
11908
+ * `null` is a real answer and is never a live url in disguise: a consumer
11909
+ * that silently fell back to {@link url} would perform exactly the wake this
11910
+ * field exists to prevent. Only a PASSTHROUGH acquisition can offer one — a
11911
+ * transcode hands back an egress the broker is feeding itself, which has no
11912
+ * sentry counterpart.
11913
+ */
11914
+ sentryUrl: string().nullable().optional(),
11897
11915
  videoCodec: _enum(["H264", "H265"]),
11898
11916
  audioCodec: string(),
11899
11917
  resolution: object({
@@ -27255,6 +27273,118 @@ DeviceType.Light, DeviceType.Siren, DeviceType.Switch, method(object({
27255
27273
  lastChangedAt: number()
27256
27274
  });
27257
27275
  /**
27276
+ * camera-grid-layout — the geometry of a COMPOSITE camera, on the camera's own
27277
+ * page.
27278
+ *
27279
+ * ## Why this is a capability and not an addon settings schema
27280
+ *
27281
+ * It was one, and it did not render. The addon declared the editor as a
27282
+ * `type: 'widget'` field inside its own `deviceSettingsSchema()`; the hub
27283
+ * returned that section correctly and `ConfigFormField` renders `type:'widget'`
27284
+ * perfectly well — and nothing ever asked camera-grid for it. The Cluster →
27285
+ * Pipeline → Device Overrides page interrogates a HAND-WRITTEN list of four
27286
+ * addons (`PIPELINE_CLUSTER_DEVICE_ADDONS`), whose own comment says an addon
27287
+ * not on it "falls off silently".
27288
+ *
27289
+ * Adding a fifth name to that list would have been the wrong fix twice over:
27290
+ * that page is per-camera DETECTION tuning, and a grid's geometry belongs
27291
+ * beside PTZ and motion zones on the camera itself. The device page is
27292
+ * BINDING-driven (D12), so the way in is a capability bound to the device —
27293
+ * and this cap carries its section the way `recording` does, by RETURNING it
27294
+ * from `getDeviceSettingsContribution`.
27295
+ *
27296
+ * Seven other widgets are still declared the other way, through a
27297
+ * `deviceConfig.ui` block the framework derives a section from. That route
27298
+ * gives the addon no say in where its own panel lands and no way to decline
27299
+ * for a device the panel does not suit, which is why this one does not use it.
27300
+ *
27301
+ * ## Why one addon may implement it
27302
+ *
27303
+ * It is a device-scoped NATIVE cap, registered by the grid camera device
27304
+ * itself. Nothing else declares a composite camera, so nothing else has a
27305
+ * layout — and the device-scoped route means the widget asks THE camera, not
27306
+ * "the camera-grid addon", which is what let the old custom-action pair be
27307
+ * reached only by a caller that already knew the addon id.
27308
+ *
27309
+ * ## The tab
27310
+ *
27311
+ * `streaming`, not a top-tab of its own. A grid's geometry IS what its stream
27312
+ * is, so the Streaming tab is where it belongs; a `grid` top-tab would need an
27313
+ * entry in `WELL_KNOWN_TAB_MAP` or the device page renders the raw id as the
27314
+ * label (measured on the robot camera, 2026-09-06 — a tab called "navigation"
27315
+ * next to "PTZ").
27316
+ */
27317
+ /** A rectangle in normalized [0,1] coordinates of whatever contains it. */
27318
+ var GridNormalizedRectSchema = object({
27319
+ x: number().min(0).max(1),
27320
+ y: number().min(0).max(1),
27321
+ width: number().gt(0).max(1),
27322
+ height: number().gt(0).max(1)
27323
+ });
27324
+ /**
27325
+ * One source camera, the part of its picture taken, and where that part lands.
27326
+ *
27327
+ * Both rectangles are NORMALIZED (D519): a source camera can change resolution
27328
+ * — a profile switch, a firmware update, a substream that comes back different
27329
+ * — and a stored PIXEL rectangle would quietly start cutting the wrong region,
27330
+ * which is the class of bug nobody files.
27331
+ */
27332
+ var GridLayoutCellSchema = object({
27333
+ deviceId: number().int().positive(),
27334
+ /** The part of the SOURCE taken, normalized against the source. */
27335
+ source: GridNormalizedRectSchema,
27336
+ /** Where it lands, normalized against the CANVAS. */
27337
+ cell: GridNormalizedRectSchema
27338
+ });
27339
+ /**
27340
+ * Which profiles this grid can actually compose, and why not.
27341
+ *
27342
+ * A grid's `high` composes its sources' `high` and its `low` their `low`, so a
27343
+ * profile is on offer only when EVERY source can serve it. The refusal NAMES
27344
+ * the sources, because "this grid has no low" is not a finding — "615 has no
27345
+ * low" is, and it is the one an operator can act on.
27346
+ */
27347
+ var GridProfileOfferSchema = object({
27348
+ profile: _enum([
27349
+ "high",
27350
+ "mid",
27351
+ "low"
27352
+ ]),
27353
+ offered: boolean(),
27354
+ /** Sources that cannot serve it. Empty when it is offered, or when there are no cells. */
27355
+ missingSources: array(number().int().positive())
27356
+ });
27357
+ var GridLayoutViewSchema = object({
27358
+ /** The persisted grid row this camera was declared from. */
27359
+ instanceId: string(),
27360
+ deviceId: number().int().nonnegative(),
27361
+ name: string(),
27362
+ /** The canvas the operator laid out — this grid's `high`. mid/low are scaled from it. */
27363
+ width: number().int(),
27364
+ height: number().int(),
27365
+ fps: number().int(),
27366
+ cells: array(GridLayoutCellSchema),
27367
+ /** What the catalog will publish, and what it refuses to. Read-only. */
27368
+ profiles: array(GridProfileOfferSchema)
27369
+ });
27370
+ var GridLayoutPatchSchema = object({
27371
+ deviceId: number().int().nonnegative(),
27372
+ name: string().min(1).max(160).optional(),
27373
+ width: number().int().min(160).max(7680).optional(),
27374
+ height: number().int().min(120).max(4320).optional(),
27375
+ fps: number().int().min(1).max(60).optional(),
27376
+ /**
27377
+ * The whole cell list at once. A per-cell patch would need an ordering the
27378
+ * editor does not have, and a half-applied layout is a picture nobody asked
27379
+ * for.
27380
+ */
27381
+ cells: array(GridLayoutCellSchema).max(16)
27382
+ });
27383
+ DeviceType.Camera, method(object({ deviceId: number().int().nonnegative() }), GridLayoutViewSchema.nullable(), { auth: "admin" }), method(GridLayoutPatchSchema, GridLayoutViewSchema, {
27384
+ kind: "mutation",
27385
+ auth: "admin"
27386
+ });
27387
+ /**
27258
27388
  * Motion-zones share the same MaskShape vocabulary as privacy-mask — the
27259
27389
  * on-camera motion-detection mask is a single `grid` region (a row-major
27260
27390
  * boolean cell lattice the camera's onboard VMD evaluates). Composing it as
@@ -32283,6 +32413,18 @@ Object.freeze({
32283
32413
  addonId: null,
32284
32414
  access: "view"
32285
32415
  },
32416
+ "cameraGridLayout.getLayout": {
32417
+ capName: "camera-grid-layout",
32418
+ capScope: "device",
32419
+ addonId: null,
32420
+ access: "view"
32421
+ },
32422
+ "cameraGridLayout.saveLayout": {
32423
+ capName: "camera-grid-layout",
32424
+ capScope: "device",
32425
+ addonId: null,
32426
+ access: "create"
32427
+ },
32286
32428
  "cameraStreams.getBrokerStreams": {
32287
32429
  capName: "camera-streams",
32288
32430
  capScope: "device",
@@ -37982,6 +38124,21 @@ Object.freeze({
37982
38124
  form: "single",
37983
38125
  optional: false
37984
38126
  }],
38127
+ "cameraGridLayout.getLayout": [{
38128
+ name: "deviceId",
38129
+ form: "single",
38130
+ optional: false
38131
+ }],
38132
+ "cameraGridLayout.saveLayout": [{
38133
+ name: "cells",
38134
+ form: "object-array",
38135
+ optional: false,
38136
+ itemField: "deviceId"
38137
+ }, {
38138
+ name: "deviceId",
38139
+ form: "single",
38140
+ optional: false
38141
+ }],
37985
38142
  "cameraStreams.getBrokerStreams": [{
37986
38143
  name: "deviceId",
37987
38144
  form: "single",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@camstack/addon-mqtt-broker",
3
- "version": "1.2.113",
3
+ "version": "1.2.115",
4
4
  "description": "MQTT broker registry addon for CamStack — manages external broker entries + an optional embedded aedes broker. Consumers spin up their own `mqtt.js` clients via the `mqtt-broker` cap.",
5
5
  "keywords": [
6
6
  "camstack",