@camstack/addon-provider-petkit 0.2.113 → 0.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.
package/dist/addon.js CHANGED
@@ -6462,7 +6462,7 @@ var ZodIssueCode = {
6462
6462
  var ZodFirstPartyTypeKind;
6463
6463
  ZodFirstPartyTypeKind || (ZodFirstPartyTypeKind = {});
6464
6464
  //#endregion
6465
- //#region ../types/dist/sleep-Dk-BdnBf.mjs
6465
+ //#region ../types/dist/sleep-GU_us3DG.mjs
6466
6466
  /**
6467
6467
  * The audio chunk plane's byte format, and the ONE expansion from a coded
6468
6468
  * window to float samples (D455).
@@ -12952,6 +12952,24 @@ var GetStreamWithCodecInputSchema = object({
12952
12952
  });
12953
12953
  var RtpSourceSchema = object({
12954
12954
  url: string(),
12955
+ /**
12956
+ * The SENTRY counterpart of {@link url} — the dial that asks for the stream
12957
+ * WITHOUT asking for the camera — or `null` when this camera offers none.
12958
+ *
12959
+ * The broker answers it because the broker is the only thing that can:
12960
+ * eligibility is `sentryEligible` (a BATTERY camera that DECLARES the signals
12961
+ * cap), asked of facts only the broker holds. A consumer re-deriving it from
12962
+ * cap bindings would be a second authority, and two authorities on the same
12963
+ * question is how a composite camera ends up dialling a sleeping camera
12964
+ * because its own copy of the rule was a release behind.
12965
+ *
12966
+ * `null` is a real answer and is never a live url in disguise: a consumer
12967
+ * that silently fell back to {@link url} would perform exactly the wake this
12968
+ * field exists to prevent. Only a PASSTHROUGH acquisition can offer one — a
12969
+ * transcode hands back an egress the broker is feeding itself, which has no
12970
+ * sentry counterpart.
12971
+ */
12972
+ sentryUrl: string().nullable().optional(),
12955
12973
  videoCodec: _enum(["H264", "H265"]),
12956
12974
  audioCodec: string(),
12957
12975
  resolution: object({
@@ -29998,6 +30016,118 @@ var motionTriggerCapability = {
29998
30016
  durability: "session"
29999
30017
  };
30000
30018
  /**
30019
+ * camera-grid-layout — the geometry of a COMPOSITE camera, on the camera's own
30020
+ * page.
30021
+ *
30022
+ * ## Why this is a capability and not an addon settings schema
30023
+ *
30024
+ * It was one, and it did not render. The addon declared the editor as a
30025
+ * `type: 'widget'` field inside its own `deviceSettingsSchema()`; the hub
30026
+ * returned that section correctly and `ConfigFormField` renders `type:'widget'`
30027
+ * perfectly well — and nothing ever asked camera-grid for it. The Cluster →
30028
+ * Pipeline → Device Overrides page interrogates a HAND-WRITTEN list of four
30029
+ * addons (`PIPELINE_CLUSTER_DEVICE_ADDONS`), whose own comment says an addon
30030
+ * not on it "falls off silently".
30031
+ *
30032
+ * Adding a fifth name to that list would have been the wrong fix twice over:
30033
+ * that page is per-camera DETECTION tuning, and a grid's geometry belongs
30034
+ * beside PTZ and motion zones on the camera itself. The device page is
30035
+ * BINDING-driven (D12), so the way in is a capability bound to the device —
30036
+ * and this cap carries its section the way `recording` does, by RETURNING it
30037
+ * from `getDeviceSettingsContribution`.
30038
+ *
30039
+ * Seven other widgets are still declared the other way, through a
30040
+ * `deviceConfig.ui` block the framework derives a section from. That route
30041
+ * gives the addon no say in where its own panel lands and no way to decline
30042
+ * for a device the panel does not suit, which is why this one does not use it.
30043
+ *
30044
+ * ## Why one addon may implement it
30045
+ *
30046
+ * It is a device-scoped NATIVE cap, registered by the grid camera device
30047
+ * itself. Nothing else declares a composite camera, so nothing else has a
30048
+ * layout — and the device-scoped route means the widget asks THE camera, not
30049
+ * "the camera-grid addon", which is what let the old custom-action pair be
30050
+ * reached only by a caller that already knew the addon id.
30051
+ *
30052
+ * ## The tab
30053
+ *
30054
+ * `streaming`, not a top-tab of its own. A grid's geometry IS what its stream
30055
+ * is, so the Streaming tab is where it belongs; a `grid` top-tab would need an
30056
+ * entry in `WELL_KNOWN_TAB_MAP` or the device page renders the raw id as the
30057
+ * label (measured on the robot camera, 2026-09-06 — a tab called "navigation"
30058
+ * next to "PTZ").
30059
+ */
30060
+ /** A rectangle in normalized [0,1] coordinates of whatever contains it. */
30061
+ var GridNormalizedRectSchema = object({
30062
+ x: number().min(0).max(1),
30063
+ y: number().min(0).max(1),
30064
+ width: number().gt(0).max(1),
30065
+ height: number().gt(0).max(1)
30066
+ });
30067
+ /**
30068
+ * One source camera, the part of its picture taken, and where that part lands.
30069
+ *
30070
+ * Both rectangles are NORMALIZED (D519): a source camera can change resolution
30071
+ * — a profile switch, a firmware update, a substream that comes back different
30072
+ * — and a stored PIXEL rectangle would quietly start cutting the wrong region,
30073
+ * which is the class of bug nobody files.
30074
+ */
30075
+ var GridLayoutCellSchema = object({
30076
+ deviceId: number().int().positive(),
30077
+ /** The part of the SOURCE taken, normalized against the source. */
30078
+ source: GridNormalizedRectSchema,
30079
+ /** Where it lands, normalized against the CANVAS. */
30080
+ cell: GridNormalizedRectSchema
30081
+ });
30082
+ /**
30083
+ * Which profiles this grid can actually compose, and why not.
30084
+ *
30085
+ * A grid's `high` composes its sources' `high` and its `low` their `low`, so a
30086
+ * profile is on offer only when EVERY source can serve it. The refusal NAMES
30087
+ * the sources, because "this grid has no low" is not a finding — "615 has no
30088
+ * low" is, and it is the one an operator can act on.
30089
+ */
30090
+ var GridProfileOfferSchema = object({
30091
+ profile: _enum([
30092
+ "high",
30093
+ "mid",
30094
+ "low"
30095
+ ]),
30096
+ offered: boolean(),
30097
+ /** Sources that cannot serve it. Empty when it is offered, or when there are no cells. */
30098
+ missingSources: array(number().int().positive())
30099
+ });
30100
+ var GridLayoutViewSchema = object({
30101
+ /** The persisted grid row this camera was declared from. */
30102
+ instanceId: string(),
30103
+ deviceId: number().int().nonnegative(),
30104
+ name: string(),
30105
+ /** The canvas the operator laid out — this grid's `high`. mid/low are scaled from it. */
30106
+ width: number().int(),
30107
+ height: number().int(),
30108
+ fps: number().int(),
30109
+ cells: array(GridLayoutCellSchema),
30110
+ /** What the catalog will publish, and what it refuses to. Read-only. */
30111
+ profiles: array(GridProfileOfferSchema)
30112
+ });
30113
+ var GridLayoutPatchSchema = object({
30114
+ deviceId: number().int().nonnegative(),
30115
+ name: string().min(1).max(160).optional(),
30116
+ width: number().int().min(160).max(7680).optional(),
30117
+ height: number().int().min(120).max(4320).optional(),
30118
+ fps: number().int().min(1).max(60).optional(),
30119
+ /**
30120
+ * The whole cell list at once. A per-cell patch would need an ordering the
30121
+ * editor does not have, and a half-applied layout is a picture nobody asked
30122
+ * for.
30123
+ */
30124
+ cells: array(GridLayoutCellSchema).max(16)
30125
+ });
30126
+ DeviceType.Camera, method(object({ deviceId: number().int().nonnegative() }), GridLayoutViewSchema.nullable(), { auth: "admin" }), method(GridLayoutPatchSchema, GridLayoutViewSchema, {
30127
+ kind: "mutation",
30128
+ auth: "admin"
30129
+ });
30130
+ /**
30001
30131
  * Motion-zones share the same MaskShape vocabulary as privacy-mask — the
30002
30132
  * on-camera motion-detection mask is a single `grid` region (a row-major
30003
30133
  * boolean cell lattice the camera's onboard VMD evaluates). Composing it as
@@ -37724,6 +37854,18 @@ Object.freeze({
37724
37854
  addonId: null,
37725
37855
  access: "view"
37726
37856
  },
37857
+ "cameraGridLayout.getLayout": {
37858
+ capName: "camera-grid-layout",
37859
+ capScope: "device",
37860
+ addonId: null,
37861
+ access: "view"
37862
+ },
37863
+ "cameraGridLayout.saveLayout": {
37864
+ capName: "camera-grid-layout",
37865
+ capScope: "device",
37866
+ addonId: null,
37867
+ access: "create"
37868
+ },
37727
37869
  "cameraStreams.getBrokerStreams": {
37728
37870
  capName: "camera-streams",
37729
37871
  capScope: "device",
@@ -43423,6 +43565,21 @@ Object.freeze({
43423
43565
  form: "single",
43424
43566
  optional: false
43425
43567
  }],
43568
+ "cameraGridLayout.getLayout": [{
43569
+ name: "deviceId",
43570
+ form: "single",
43571
+ optional: false
43572
+ }],
43573
+ "cameraGridLayout.saveLayout": [{
43574
+ name: "cells",
43575
+ form: "object-array",
43576
+ optional: false,
43577
+ itemField: "deviceId"
43578
+ }, {
43579
+ name: "deviceId",
43580
+ form: "single",
43581
+ optional: false
43582
+ }],
43426
43583
  "cameraStreams.getBrokerStreams": [{
43427
43584
  name: "deviceId",
43428
43585
  form: "single",
package/dist/addon.mjs CHANGED
@@ -6461,7 +6461,7 @@ var ZodIssueCode = {
6461
6461
  var ZodFirstPartyTypeKind;
6462
6462
  ZodFirstPartyTypeKind || (ZodFirstPartyTypeKind = {});
6463
6463
  //#endregion
6464
- //#region ../types/dist/sleep-Dk-BdnBf.mjs
6464
+ //#region ../types/dist/sleep-GU_us3DG.mjs
6465
6465
  /**
6466
6466
  * The audio chunk plane's byte format, and the ONE expansion from a coded
6467
6467
  * window to float samples (D455).
@@ -12951,6 +12951,24 @@ var GetStreamWithCodecInputSchema = object({
12951
12951
  });
12952
12952
  var RtpSourceSchema = object({
12953
12953
  url: string(),
12954
+ /**
12955
+ * The SENTRY counterpart of {@link url} — the dial that asks for the stream
12956
+ * WITHOUT asking for the camera — or `null` when this camera offers none.
12957
+ *
12958
+ * The broker answers it because the broker is the only thing that can:
12959
+ * eligibility is `sentryEligible` (a BATTERY camera that DECLARES the signals
12960
+ * cap), asked of facts only the broker holds. A consumer re-deriving it from
12961
+ * cap bindings would be a second authority, and two authorities on the same
12962
+ * question is how a composite camera ends up dialling a sleeping camera
12963
+ * because its own copy of the rule was a release behind.
12964
+ *
12965
+ * `null` is a real answer and is never a live url in disguise: a consumer
12966
+ * that silently fell back to {@link url} would perform exactly the wake this
12967
+ * field exists to prevent. Only a PASSTHROUGH acquisition can offer one — a
12968
+ * transcode hands back an egress the broker is feeding itself, which has no
12969
+ * sentry counterpart.
12970
+ */
12971
+ sentryUrl: string().nullable().optional(),
12954
12972
  videoCodec: _enum(["H264", "H265"]),
12955
12973
  audioCodec: string(),
12956
12974
  resolution: object({
@@ -29997,6 +30015,118 @@ var motionTriggerCapability = {
29997
30015
  durability: "session"
29998
30016
  };
29999
30017
  /**
30018
+ * camera-grid-layout — the geometry of a COMPOSITE camera, on the camera's own
30019
+ * page.
30020
+ *
30021
+ * ## Why this is a capability and not an addon settings schema
30022
+ *
30023
+ * It was one, and it did not render. The addon declared the editor as a
30024
+ * `type: 'widget'` field inside its own `deviceSettingsSchema()`; the hub
30025
+ * returned that section correctly and `ConfigFormField` renders `type:'widget'`
30026
+ * perfectly well — and nothing ever asked camera-grid for it. The Cluster →
30027
+ * Pipeline → Device Overrides page interrogates a HAND-WRITTEN list of four
30028
+ * addons (`PIPELINE_CLUSTER_DEVICE_ADDONS`), whose own comment says an addon
30029
+ * not on it "falls off silently".
30030
+ *
30031
+ * Adding a fifth name to that list would have been the wrong fix twice over:
30032
+ * that page is per-camera DETECTION tuning, and a grid's geometry belongs
30033
+ * beside PTZ and motion zones on the camera itself. The device page is
30034
+ * BINDING-driven (D12), so the way in is a capability bound to the device —
30035
+ * and this cap carries its section the way `recording` does, by RETURNING it
30036
+ * from `getDeviceSettingsContribution`.
30037
+ *
30038
+ * Seven other widgets are still declared the other way, through a
30039
+ * `deviceConfig.ui` block the framework derives a section from. That route
30040
+ * gives the addon no say in where its own panel lands and no way to decline
30041
+ * for a device the panel does not suit, which is why this one does not use it.
30042
+ *
30043
+ * ## Why one addon may implement it
30044
+ *
30045
+ * It is a device-scoped NATIVE cap, registered by the grid camera device
30046
+ * itself. Nothing else declares a composite camera, so nothing else has a
30047
+ * layout — and the device-scoped route means the widget asks THE camera, not
30048
+ * "the camera-grid addon", which is what let the old custom-action pair be
30049
+ * reached only by a caller that already knew the addon id.
30050
+ *
30051
+ * ## The tab
30052
+ *
30053
+ * `streaming`, not a top-tab of its own. A grid's geometry IS what its stream
30054
+ * is, so the Streaming tab is where it belongs; a `grid` top-tab would need an
30055
+ * entry in `WELL_KNOWN_TAB_MAP` or the device page renders the raw id as the
30056
+ * label (measured on the robot camera, 2026-09-06 — a tab called "navigation"
30057
+ * next to "PTZ").
30058
+ */
30059
+ /** A rectangle in normalized [0,1] coordinates of whatever contains it. */
30060
+ var GridNormalizedRectSchema = object({
30061
+ x: number().min(0).max(1),
30062
+ y: number().min(0).max(1),
30063
+ width: number().gt(0).max(1),
30064
+ height: number().gt(0).max(1)
30065
+ });
30066
+ /**
30067
+ * One source camera, the part of its picture taken, and where that part lands.
30068
+ *
30069
+ * Both rectangles are NORMALIZED (D519): a source camera can change resolution
30070
+ * — a profile switch, a firmware update, a substream that comes back different
30071
+ * — and a stored PIXEL rectangle would quietly start cutting the wrong region,
30072
+ * which is the class of bug nobody files.
30073
+ */
30074
+ var GridLayoutCellSchema = object({
30075
+ deviceId: number().int().positive(),
30076
+ /** The part of the SOURCE taken, normalized against the source. */
30077
+ source: GridNormalizedRectSchema,
30078
+ /** Where it lands, normalized against the CANVAS. */
30079
+ cell: GridNormalizedRectSchema
30080
+ });
30081
+ /**
30082
+ * Which profiles this grid can actually compose, and why not.
30083
+ *
30084
+ * A grid's `high` composes its sources' `high` and its `low` their `low`, so a
30085
+ * profile is on offer only when EVERY source can serve it. The refusal NAMES
30086
+ * the sources, because "this grid has no low" is not a finding — "615 has no
30087
+ * low" is, and it is the one an operator can act on.
30088
+ */
30089
+ var GridProfileOfferSchema = object({
30090
+ profile: _enum([
30091
+ "high",
30092
+ "mid",
30093
+ "low"
30094
+ ]),
30095
+ offered: boolean(),
30096
+ /** Sources that cannot serve it. Empty when it is offered, or when there are no cells. */
30097
+ missingSources: array(number().int().positive())
30098
+ });
30099
+ var GridLayoutViewSchema = object({
30100
+ /** The persisted grid row this camera was declared from. */
30101
+ instanceId: string(),
30102
+ deviceId: number().int().nonnegative(),
30103
+ name: string(),
30104
+ /** The canvas the operator laid out — this grid's `high`. mid/low are scaled from it. */
30105
+ width: number().int(),
30106
+ height: number().int(),
30107
+ fps: number().int(),
30108
+ cells: array(GridLayoutCellSchema),
30109
+ /** What the catalog will publish, and what it refuses to. Read-only. */
30110
+ profiles: array(GridProfileOfferSchema)
30111
+ });
30112
+ var GridLayoutPatchSchema = object({
30113
+ deviceId: number().int().nonnegative(),
30114
+ name: string().min(1).max(160).optional(),
30115
+ width: number().int().min(160).max(7680).optional(),
30116
+ height: number().int().min(120).max(4320).optional(),
30117
+ fps: number().int().min(1).max(60).optional(),
30118
+ /**
30119
+ * The whole cell list at once. A per-cell patch would need an ordering the
30120
+ * editor does not have, and a half-applied layout is a picture nobody asked
30121
+ * for.
30122
+ */
30123
+ cells: array(GridLayoutCellSchema).max(16)
30124
+ });
30125
+ DeviceType.Camera, method(object({ deviceId: number().int().nonnegative() }), GridLayoutViewSchema.nullable(), { auth: "admin" }), method(GridLayoutPatchSchema, GridLayoutViewSchema, {
30126
+ kind: "mutation",
30127
+ auth: "admin"
30128
+ });
30129
+ /**
30000
30130
  * Motion-zones share the same MaskShape vocabulary as privacy-mask — the
30001
30131
  * on-camera motion-detection mask is a single `grid` region (a row-major
30002
30132
  * boolean cell lattice the camera's onboard VMD evaluates). Composing it as
@@ -37723,6 +37853,18 @@ Object.freeze({
37723
37853
  addonId: null,
37724
37854
  access: "view"
37725
37855
  },
37856
+ "cameraGridLayout.getLayout": {
37857
+ capName: "camera-grid-layout",
37858
+ capScope: "device",
37859
+ addonId: null,
37860
+ access: "view"
37861
+ },
37862
+ "cameraGridLayout.saveLayout": {
37863
+ capName: "camera-grid-layout",
37864
+ capScope: "device",
37865
+ addonId: null,
37866
+ access: "create"
37867
+ },
37726
37868
  "cameraStreams.getBrokerStreams": {
37727
37869
  capName: "camera-streams",
37728
37870
  capScope: "device",
@@ -43422,6 +43564,21 @@ Object.freeze({
43422
43564
  form: "single",
43423
43565
  optional: false
43424
43566
  }],
43567
+ "cameraGridLayout.getLayout": [{
43568
+ name: "deviceId",
43569
+ form: "single",
43570
+ optional: false
43571
+ }],
43572
+ "cameraGridLayout.saveLayout": [{
43573
+ name: "cells",
43574
+ form: "object-array",
43575
+ optional: false,
43576
+ itemField: "deviceId"
43577
+ }, {
43578
+ name: "deviceId",
43579
+ form: "single",
43580
+ optional: false
43581
+ }],
43425
43582
  "cameraStreams.getBrokerStreams": [{
43426
43583
  name: "deviceId",
43427
43584
  form: "single",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@camstack/addon-provider-petkit",
3
- "version": "0.2.113",
3
+ "version": "0.2.115",
4
4
  "description": "PetKit smart-feeder device-provider addon for CamStack — wraps the @apocaliss92/nodepetkit PetKit cloud client",
5
5
  "keywords": [
6
6
  "camstack",