@camstack/addon-provider-gree 0.2.112 → 0.2.113

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
@@ -5363,7 +5363,7 @@ var ZodIssueCode = {
5363
5363
  var ZodFirstPartyTypeKind;
5364
5364
  ZodFirstPartyTypeKind || (ZodFirstPartyTypeKind = {});
5365
5365
  //#endregion
5366
- //#region ../types/dist/sleep-Dk-BdnBf.mjs
5366
+ //#region ../types/dist/sleep-Bs3xPtSh.mjs
5367
5367
  /**
5368
5368
  * The audio chunk plane's byte format, and the ONE expansion from a coded
5369
5369
  * window to float samples (D455).
@@ -11853,6 +11853,24 @@ var GetStreamWithCodecInputSchema = object({
11853
11853
  });
11854
11854
  var RtpSourceSchema = object({
11855
11855
  url: string(),
11856
+ /**
11857
+ * The SENTRY counterpart of {@link url} — the dial that asks for the stream
11858
+ * WITHOUT asking for the camera — or `null` when this camera offers none.
11859
+ *
11860
+ * The broker answers it because the broker is the only thing that can:
11861
+ * eligibility is `sentryEligible` (a BATTERY camera that DECLARES the signals
11862
+ * cap), asked of facts only the broker holds. A consumer re-deriving it from
11863
+ * cap bindings would be a second authority, and two authorities on the same
11864
+ * question is how a composite camera ends up dialling a sleeping camera
11865
+ * because its own copy of the rule was a release behind.
11866
+ *
11867
+ * `null` is a real answer and is never a live url in disguise: a consumer
11868
+ * that silently fell back to {@link url} would perform exactly the wake this
11869
+ * field exists to prevent. Only a PASSTHROUGH acquisition can offer one — a
11870
+ * transcode hands back an egress the broker is feeding itself, which has no
11871
+ * sentry counterpart.
11872
+ */
11873
+ sentryUrl: string().nullable().optional(),
11856
11874
  videoCodec: _enum(["H264", "H265"]),
11857
11875
  audioCodec: string(),
11858
11876
  resolution: object({
@@ -28874,6 +28892,114 @@ var motionTriggerCapability = {
28874
28892
  durability: "session"
28875
28893
  };
28876
28894
  /**
28895
+ * camera-grid-layout — the geometry of a COMPOSITE camera, on the camera's own
28896
+ * page.
28897
+ *
28898
+ * ## Why this is a capability and not an addon settings schema
28899
+ *
28900
+ * It was one, and it did not render. The addon declared the editor as a
28901
+ * `type: 'widget'` field inside its own `deviceSettingsSchema()`; the hub
28902
+ * returned that section correctly and `ConfigFormField` renders `type:'widget'`
28903
+ * perfectly well — and nothing ever asked camera-grid for it. The Cluster →
28904
+ * Pipeline → Device Overrides page interrogates a HAND-WRITTEN list of four
28905
+ * addons (`PIPELINE_CLUSTER_DEVICE_ADDONS`), whose own comment says an addon
28906
+ * not on it "falls off silently".
28907
+ *
28908
+ * Adding a fifth name to that list would have been the wrong fix twice over:
28909
+ * that page is per-camera DETECTION tuning, and a grid's geometry belongs
28910
+ * beside PTZ and motion zones on the camera itself — which is exactly where the
28911
+ * framework already puts a widget, when the widget is declared on a CAPABILITY.
28912
+ * `deviceConfig.ui` is the mechanism (`motion-zones`, `ptz`, `ptz-autotrack`
28913
+ * all use it): the framework emits the structural section and the widget
28914
+ * self-persists through the cap's own mutations.
28915
+ *
28916
+ * ## Why one addon may implement it
28917
+ *
28918
+ * It is a device-scoped NATIVE cap, registered by the grid camera device
28919
+ * itself. Nothing else declares a composite camera, so nothing else has a
28920
+ * layout — and the device-scoped route means the widget asks THE camera, not
28921
+ * "the camera-grid addon", which is what let the old custom-action pair be
28922
+ * reached only by a caller that already knew the addon id.
28923
+ *
28924
+ * ## The tab
28925
+ *
28926
+ * `streaming`, not a top-tab of its own. A grid's geometry IS what its stream
28927
+ * is, so the Streaming tab is where it belongs; a `grid` top-tab would need an
28928
+ * entry in `WELL_KNOWN_TAB_MAP` or the device page renders the raw id as the
28929
+ * label (measured on the robot camera, 2026-09-06 — a tab called "navigation"
28930
+ * next to "PTZ").
28931
+ */
28932
+ /** A rectangle in normalized [0,1] coordinates of whatever contains it. */
28933
+ var GridNormalizedRectSchema = object({
28934
+ x: number().min(0).max(1),
28935
+ y: number().min(0).max(1),
28936
+ width: number().gt(0).max(1),
28937
+ height: number().gt(0).max(1)
28938
+ });
28939
+ /**
28940
+ * One source camera, the part of its picture taken, and where that part lands.
28941
+ *
28942
+ * Both rectangles are NORMALIZED (D519): a source camera can change resolution
28943
+ * — a profile switch, a firmware update, a substream that comes back different
28944
+ * — and a stored PIXEL rectangle would quietly start cutting the wrong region,
28945
+ * which is the class of bug nobody files.
28946
+ */
28947
+ var GridLayoutCellSchema = object({
28948
+ deviceId: number().int().positive(),
28949
+ /** The part of the SOURCE taken, normalized against the source. */
28950
+ source: GridNormalizedRectSchema,
28951
+ /** Where it lands, normalized against the CANVAS. */
28952
+ cell: GridNormalizedRectSchema
28953
+ });
28954
+ /**
28955
+ * Which profiles this grid can actually compose, and why not.
28956
+ *
28957
+ * A grid's `high` composes its sources' `high` and its `low` their `low`, so a
28958
+ * profile is on offer only when EVERY source can serve it. The refusal NAMES
28959
+ * the sources, because "this grid has no low" is not a finding — "615 has no
28960
+ * low" is, and it is the one an operator can act on.
28961
+ */
28962
+ var GridProfileOfferSchema = object({
28963
+ profile: _enum([
28964
+ "high",
28965
+ "mid",
28966
+ "low"
28967
+ ]),
28968
+ offered: boolean(),
28969
+ /** Sources that cannot serve it. Empty when it is offered, or when there are no cells. */
28970
+ missingSources: array(number().int().positive())
28971
+ });
28972
+ var GridLayoutViewSchema = object({
28973
+ /** The persisted grid row this camera was declared from. */
28974
+ instanceId: string(),
28975
+ deviceId: number().int().nonnegative(),
28976
+ name: string(),
28977
+ /** The canvas the operator laid out — this grid's `high`. mid/low are scaled from it. */
28978
+ width: number().int(),
28979
+ height: number().int(),
28980
+ fps: number().int(),
28981
+ cells: array(GridLayoutCellSchema),
28982
+ /** What the catalog will publish, and what it refuses to. Read-only. */
28983
+ profiles: array(GridProfileOfferSchema)
28984
+ });
28985
+ var GridLayoutPatchSchema = object({
28986
+ deviceId: number().int().nonnegative(),
28987
+ name: string().min(1).max(160).optional(),
28988
+ width: number().int().min(160).max(7680).optional(),
28989
+ height: number().int().min(120).max(4320).optional(),
28990
+ fps: number().int().min(1).max(60).optional(),
28991
+ /**
28992
+ * The whole cell list at once. A per-cell patch would need an ordering the
28993
+ * editor does not have, and a half-applied layout is a picture nobody asked
28994
+ * for.
28995
+ */
28996
+ cells: array(GridLayoutCellSchema).max(16)
28997
+ });
28998
+ DeviceType.Camera, method(object({ deviceId: number().int().nonnegative() }), GridLayoutViewSchema.nullable(), { auth: "admin" }), method(GridLayoutPatchSchema, GridLayoutViewSchema, {
28999
+ kind: "mutation",
29000
+ auth: "admin"
29001
+ });
29002
+ /**
28877
29003
  * Motion-zones share the same MaskShape vocabulary as privacy-mask — the
28878
29004
  * on-camera motion-detection mask is a single `grid` region (a row-major
28879
29005
  * boolean cell lattice the camera's onboard VMD evaluates). Composing it as
@@ -36600,6 +36726,18 @@ Object.freeze({
36600
36726
  addonId: null,
36601
36727
  access: "view"
36602
36728
  },
36729
+ "cameraGridLayout.getLayout": {
36730
+ capName: "camera-grid-layout",
36731
+ capScope: "device",
36732
+ addonId: null,
36733
+ access: "view"
36734
+ },
36735
+ "cameraGridLayout.saveLayout": {
36736
+ capName: "camera-grid-layout",
36737
+ capScope: "device",
36738
+ addonId: null,
36739
+ access: "create"
36740
+ },
36603
36741
  "cameraStreams.getBrokerStreams": {
36604
36742
  capName: "camera-streams",
36605
36743
  capScope: "device",
@@ -42299,6 +42437,21 @@ Object.freeze({
42299
42437
  form: "single",
42300
42438
  optional: false
42301
42439
  }],
42440
+ "cameraGridLayout.getLayout": [{
42441
+ name: "deviceId",
42442
+ form: "single",
42443
+ optional: false
42444
+ }],
42445
+ "cameraGridLayout.saveLayout": [{
42446
+ name: "cells",
42447
+ form: "object-array",
42448
+ optional: false,
42449
+ itemField: "deviceId"
42450
+ }, {
42451
+ name: "deviceId",
42452
+ form: "single",
42453
+ optional: false
42454
+ }],
42302
42455
  "cameraStreams.getBrokerStreams": [{
42303
42456
  name: "deviceId",
42304
42457
  form: "single",
package/dist/addon.mjs CHANGED
@@ -5362,7 +5362,7 @@ var ZodIssueCode = {
5362
5362
  var ZodFirstPartyTypeKind;
5363
5363
  ZodFirstPartyTypeKind || (ZodFirstPartyTypeKind = {});
5364
5364
  //#endregion
5365
- //#region ../types/dist/sleep-Dk-BdnBf.mjs
5365
+ //#region ../types/dist/sleep-Bs3xPtSh.mjs
5366
5366
  /**
5367
5367
  * The audio chunk plane's byte format, and the ONE expansion from a coded
5368
5368
  * window to float samples (D455).
@@ -11852,6 +11852,24 @@ var GetStreamWithCodecInputSchema = object({
11852
11852
  });
11853
11853
  var RtpSourceSchema = object({
11854
11854
  url: string(),
11855
+ /**
11856
+ * The SENTRY counterpart of {@link url} — the dial that asks for the stream
11857
+ * WITHOUT asking for the camera — or `null` when this camera offers none.
11858
+ *
11859
+ * The broker answers it because the broker is the only thing that can:
11860
+ * eligibility is `sentryEligible` (a BATTERY camera that DECLARES the signals
11861
+ * cap), asked of facts only the broker holds. A consumer re-deriving it from
11862
+ * cap bindings would be a second authority, and two authorities on the same
11863
+ * question is how a composite camera ends up dialling a sleeping camera
11864
+ * because its own copy of the rule was a release behind.
11865
+ *
11866
+ * `null` is a real answer and is never a live url in disguise: a consumer
11867
+ * that silently fell back to {@link url} would perform exactly the wake this
11868
+ * field exists to prevent. Only a PASSTHROUGH acquisition can offer one — a
11869
+ * transcode hands back an egress the broker is feeding itself, which has no
11870
+ * sentry counterpart.
11871
+ */
11872
+ sentryUrl: string().nullable().optional(),
11855
11873
  videoCodec: _enum(["H264", "H265"]),
11856
11874
  audioCodec: string(),
11857
11875
  resolution: object({
@@ -28873,6 +28891,114 @@ var motionTriggerCapability = {
28873
28891
  durability: "session"
28874
28892
  };
28875
28893
  /**
28894
+ * camera-grid-layout — the geometry of a COMPOSITE camera, on the camera's own
28895
+ * page.
28896
+ *
28897
+ * ## Why this is a capability and not an addon settings schema
28898
+ *
28899
+ * It was one, and it did not render. The addon declared the editor as a
28900
+ * `type: 'widget'` field inside its own `deviceSettingsSchema()`; the hub
28901
+ * returned that section correctly and `ConfigFormField` renders `type:'widget'`
28902
+ * perfectly well — and nothing ever asked camera-grid for it. The Cluster →
28903
+ * Pipeline → Device Overrides page interrogates a HAND-WRITTEN list of four
28904
+ * addons (`PIPELINE_CLUSTER_DEVICE_ADDONS`), whose own comment says an addon
28905
+ * not on it "falls off silently".
28906
+ *
28907
+ * Adding a fifth name to that list would have been the wrong fix twice over:
28908
+ * that page is per-camera DETECTION tuning, and a grid's geometry belongs
28909
+ * beside PTZ and motion zones on the camera itself — which is exactly where the
28910
+ * framework already puts a widget, when the widget is declared on a CAPABILITY.
28911
+ * `deviceConfig.ui` is the mechanism (`motion-zones`, `ptz`, `ptz-autotrack`
28912
+ * all use it): the framework emits the structural section and the widget
28913
+ * self-persists through the cap's own mutations.
28914
+ *
28915
+ * ## Why one addon may implement it
28916
+ *
28917
+ * It is a device-scoped NATIVE cap, registered by the grid camera device
28918
+ * itself. Nothing else declares a composite camera, so nothing else has a
28919
+ * layout — and the device-scoped route means the widget asks THE camera, not
28920
+ * "the camera-grid addon", which is what let the old custom-action pair be
28921
+ * reached only by a caller that already knew the addon id.
28922
+ *
28923
+ * ## The tab
28924
+ *
28925
+ * `streaming`, not a top-tab of its own. A grid's geometry IS what its stream
28926
+ * is, so the Streaming tab is where it belongs; a `grid` top-tab would need an
28927
+ * entry in `WELL_KNOWN_TAB_MAP` or the device page renders the raw id as the
28928
+ * label (measured on the robot camera, 2026-09-06 — a tab called "navigation"
28929
+ * next to "PTZ").
28930
+ */
28931
+ /** A rectangle in normalized [0,1] coordinates of whatever contains it. */
28932
+ var GridNormalizedRectSchema = object({
28933
+ x: number().min(0).max(1),
28934
+ y: number().min(0).max(1),
28935
+ width: number().gt(0).max(1),
28936
+ height: number().gt(0).max(1)
28937
+ });
28938
+ /**
28939
+ * One source camera, the part of its picture taken, and where that part lands.
28940
+ *
28941
+ * Both rectangles are NORMALIZED (D519): a source camera can change resolution
28942
+ * — a profile switch, a firmware update, a substream that comes back different
28943
+ * — and a stored PIXEL rectangle would quietly start cutting the wrong region,
28944
+ * which is the class of bug nobody files.
28945
+ */
28946
+ var GridLayoutCellSchema = object({
28947
+ deviceId: number().int().positive(),
28948
+ /** The part of the SOURCE taken, normalized against the source. */
28949
+ source: GridNormalizedRectSchema,
28950
+ /** Where it lands, normalized against the CANVAS. */
28951
+ cell: GridNormalizedRectSchema
28952
+ });
28953
+ /**
28954
+ * Which profiles this grid can actually compose, and why not.
28955
+ *
28956
+ * A grid's `high` composes its sources' `high` and its `low` their `low`, so a
28957
+ * profile is on offer only when EVERY source can serve it. The refusal NAMES
28958
+ * the sources, because "this grid has no low" is not a finding — "615 has no
28959
+ * low" is, and it is the one an operator can act on.
28960
+ */
28961
+ var GridProfileOfferSchema = object({
28962
+ profile: _enum([
28963
+ "high",
28964
+ "mid",
28965
+ "low"
28966
+ ]),
28967
+ offered: boolean(),
28968
+ /** Sources that cannot serve it. Empty when it is offered, or when there are no cells. */
28969
+ missingSources: array(number().int().positive())
28970
+ });
28971
+ var GridLayoutViewSchema = object({
28972
+ /** The persisted grid row this camera was declared from. */
28973
+ instanceId: string(),
28974
+ deviceId: number().int().nonnegative(),
28975
+ name: string(),
28976
+ /** The canvas the operator laid out — this grid's `high`. mid/low are scaled from it. */
28977
+ width: number().int(),
28978
+ height: number().int(),
28979
+ fps: number().int(),
28980
+ cells: array(GridLayoutCellSchema),
28981
+ /** What the catalog will publish, and what it refuses to. Read-only. */
28982
+ profiles: array(GridProfileOfferSchema)
28983
+ });
28984
+ var GridLayoutPatchSchema = object({
28985
+ deviceId: number().int().nonnegative(),
28986
+ name: string().min(1).max(160).optional(),
28987
+ width: number().int().min(160).max(7680).optional(),
28988
+ height: number().int().min(120).max(4320).optional(),
28989
+ fps: number().int().min(1).max(60).optional(),
28990
+ /**
28991
+ * The whole cell list at once. A per-cell patch would need an ordering the
28992
+ * editor does not have, and a half-applied layout is a picture nobody asked
28993
+ * for.
28994
+ */
28995
+ cells: array(GridLayoutCellSchema).max(16)
28996
+ });
28997
+ DeviceType.Camera, method(object({ deviceId: number().int().nonnegative() }), GridLayoutViewSchema.nullable(), { auth: "admin" }), method(GridLayoutPatchSchema, GridLayoutViewSchema, {
28998
+ kind: "mutation",
28999
+ auth: "admin"
29000
+ });
29001
+ /**
28876
29002
  * Motion-zones share the same MaskShape vocabulary as privacy-mask — the
28877
29003
  * on-camera motion-detection mask is a single `grid` region (a row-major
28878
29004
  * boolean cell lattice the camera's onboard VMD evaluates). Composing it as
@@ -36599,6 +36725,18 @@ Object.freeze({
36599
36725
  addonId: null,
36600
36726
  access: "view"
36601
36727
  },
36728
+ "cameraGridLayout.getLayout": {
36729
+ capName: "camera-grid-layout",
36730
+ capScope: "device",
36731
+ addonId: null,
36732
+ access: "view"
36733
+ },
36734
+ "cameraGridLayout.saveLayout": {
36735
+ capName: "camera-grid-layout",
36736
+ capScope: "device",
36737
+ addonId: null,
36738
+ access: "create"
36739
+ },
36602
36740
  "cameraStreams.getBrokerStreams": {
36603
36741
  capName: "camera-streams",
36604
36742
  capScope: "device",
@@ -42298,6 +42436,21 @@ Object.freeze({
42298
42436
  form: "single",
42299
42437
  optional: false
42300
42438
  }],
42439
+ "cameraGridLayout.getLayout": [{
42440
+ name: "deviceId",
42441
+ form: "single",
42442
+ optional: false
42443
+ }],
42444
+ "cameraGridLayout.saveLayout": [{
42445
+ name: "cells",
42446
+ form: "object-array",
42447
+ optional: false,
42448
+ itemField: "deviceId"
42449
+ }, {
42450
+ name: "deviceId",
42451
+ form: "single",
42452
+ optional: false
42453
+ }],
42301
42454
  "cameraStreams.getBrokerStreams": [{
42302
42455
  name: "deviceId",
42303
42456
  form: "single",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@camstack/addon-provider-gree",
3
- "version": "0.2.112",
3
+ "version": "0.2.113",
4
4
  "description": "Gree air-conditioner device-provider addon for CamStack — wraps the @apocaliss92/nodegree local-UDP client (LAN discovery + AES control), exposing climate-control and fan-control",
5
5
  "keywords": [
6
6
  "camstack",