@camstack/addon-decoder-nodeav 1.2.75 → 1.2.76
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/index.js +47 -34
- package/dist/index.mjs +47 -34
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -7849,17 +7849,29 @@ var HHMM = /^([01]\d|2[0-3]):[0-5]\d$/;
|
|
|
7849
7849
|
/**
|
|
7850
7850
|
* DERIVED per-camera storage summary — the single field cheap consumers read
|
|
7851
7851
|
* (the viewer's status dot, the camera list) instead of walking `bands`:
|
|
7852
|
-
* - `off`
|
|
7853
|
-
* - `events`
|
|
7854
|
-
* - `continuous`
|
|
7855
|
-
*
|
|
7856
|
-
*
|
|
7857
|
-
*
|
|
7852
|
+
* - `off` — no band covers the camera (or it is disabled).
|
|
7853
|
+
* - `events` — every band records around triggers only.
|
|
7854
|
+
* - `continuous` — at least one band records continuously.
|
|
7855
|
+
* - `on-device-decision`— the DEVICE decides: recording runs for as long as the
|
|
7856
|
+
* camera raises its own `recording-signal` level (a robot that cleans). There
|
|
7857
|
+
* is no schedule to author, because there is no hour to program — see
|
|
7858
|
+
* {@link RecordingConfigSchema}`.deviceDecision`.
|
|
7859
|
+
*
|
|
7860
|
+
* NEVER authored: the recorder stamps it from the authoritative intent
|
|
7861
|
+
* (`bands` + `deviceDecision`) on every save (`activeModeForConfig`). Writing it
|
|
7862
|
+
* has no effect.
|
|
7863
|
+
*
|
|
7864
|
+
* `on-device-decision` is named for WHO decides, not for how the recording is
|
|
7865
|
+
* requested. `on-demand` was rejected: in this repo's vocabulary a "demand" is
|
|
7866
|
+
* something the operator makes (the live gate is the recorder's own "demand
|
|
7867
|
+
* window"), and a knob whose name suggests the operator starts it while the
|
|
7868
|
+
* device actually does is the D62 shape — a control nobody can predict.
|
|
7858
7869
|
*/
|
|
7859
7870
|
var RecordingStorageModeSchema = _enum([
|
|
7860
7871
|
"off",
|
|
7861
7872
|
"events",
|
|
7862
|
-
"continuous"
|
|
7873
|
+
"continuous",
|
|
7874
|
+
"on-device-decision"
|
|
7863
7875
|
]);
|
|
7864
7876
|
/**
|
|
7865
7877
|
* Le macro classi che possono aprire una finestra di registrazione — le stesse
|
|
@@ -7909,22 +7921,7 @@ var RecordingTriggersSchema = object({
|
|
|
7909
7921
|
* il livello: un contatto trovato già aperto al riavvio del runner non fa
|
|
7910
7922
|
* registrare.
|
|
7911
7923
|
*/
|
|
7912
|
-
sensorDeviceIds: array(number().int().positive()).min(1).max(16).refine(noDuplicates, { message: "sensorDeviceIds must not repeat a device" }).optional()
|
|
7913
|
-
/**
|
|
7914
|
-
* La camera registra per tutta la durata del SEGNALE che lei stessa
|
|
7915
|
-
* pubblica — la cap `recording-signal` (`active: true` mentre il device è in
|
|
7916
|
-
* funzione: un robot che pulisce). È un LIVELLO, non un fronte: la finestra
|
|
7917
|
-
* resta aperta finché il segnale è alto e si chiude `postBufferSec` dopo la
|
|
7918
|
-
* caduta, così una pulizia di quaranta minuti è UNA clip.
|
|
7919
|
-
*
|
|
7920
|
-
* Non nomina un device: il segnale è della camera stessa, tenuto fresco dal
|
|
7921
|
-
* suo provider (D224); il recorder lo ascolta su `DeviceStateChanged` e lo
|
|
7922
|
-
* riconcilia leggendo la slice via RPC, con un tetto oltre il quale un
|
|
7923
|
-
* segnale mai abbassato (un evento perso) non può tenere aperta una
|
|
7924
|
-
* registrazione (D11). Vedi `recorder/addon/band-decision.ts`
|
|
7925
|
-
* (`holdTrigger` / `releaseTrigger`).
|
|
7926
|
-
*/
|
|
7927
|
-
deviceSignal: boolean().optional()
|
|
7924
|
+
sensorDeviceIds: array(number().int().positive()).min(1).max(16).refine(noDuplicates, { message: "sensorDeviceIds must not repeat a device" }).optional()
|
|
7928
7925
|
});
|
|
7929
7926
|
/**
|
|
7930
7927
|
* Mode of a single recording band — the recorder per-band vocabulary.
|
|
@@ -8008,8 +8005,29 @@ var RecordingConfigSchema = object({
|
|
|
8008
8005
|
* "off" is the absence of a covering band, never a band value.
|
|
8009
8006
|
*/
|
|
8010
8007
|
bands: array(RecordingBandSchema).default([]),
|
|
8008
|
+
/**
|
|
8009
|
+
* THE device-decided intent: record for as long as the camera itself raises
|
|
8010
|
+
* `recording-signal` (`active: true` while the device is in function — a
|
|
8011
|
+
* robot that cleans). AUTHORED, unlike `mode`, and the only authored
|
|
8012
|
+
* recording intent that is not a band.
|
|
8013
|
+
*
|
|
8014
|
+
* It carries NO schedule on purpose. A band is an HOUR, and this feature has
|
|
8015
|
+
* no hour to program: the device decides. What it costs the operator is one
|
|
8016
|
+
* flag — "this camera can record on its own" — and what it buys is the same
|
|
8017
|
+
* hold/release the recorder already implements (D371, `holdTrigger` /
|
|
8018
|
+
* `releaseTrigger`): the window opens on the rise, stays open for the whole
|
|
8019
|
+
* job however long it is, and closes one pad after the fall.
|
|
8020
|
+
*
|
|
8021
|
+
* EXCLUSIVE with `bands` (below): two authorities deciding when the same
|
|
8022
|
+
* camera records is the D62 failure. `off` remains `enabled: false`, so an
|
|
8023
|
+
* operator switching this camera off is REPORTED off, never as broken.
|
|
8024
|
+
*/
|
|
8025
|
+
deviceDecision: boolean().optional(),
|
|
8011
8026
|
retention: RecordingRetentionSchema.optional()
|
|
8012
|
-
}).strict()
|
|
8027
|
+
}).strict().refine((config) => config.deviceDecision !== true || config.bands.length === 0, {
|
|
8028
|
+
message: "deviceDecision is a whole-config mode and carries no schedule: it cannot be combined with bands",
|
|
8029
|
+
path: ["bands"]
|
|
8030
|
+
});
|
|
8013
8031
|
/**
|
|
8014
8032
|
* Entity-relocation job state (storage entity-routing spec, Phase 4).
|
|
8015
8033
|
*
|
|
@@ -20787,11 +20805,7 @@ var CameraAudioStatusSchema = object({
|
|
|
20787
20805
|
});
|
|
20788
20806
|
/** Recording block — null when no recording cap is active for this device. */
|
|
20789
20807
|
var CameraRecordingStatusSchema = object({
|
|
20790
|
-
mode:
|
|
20791
|
-
"off",
|
|
20792
|
-
"continuous",
|
|
20793
|
-
"events"
|
|
20794
|
-
]),
|
|
20808
|
+
mode: RecordingStorageModeSchema,
|
|
20795
20809
|
active: boolean(),
|
|
20796
20810
|
storageBytes: number()
|
|
20797
20811
|
});
|
|
@@ -27197,11 +27211,10 @@ DeviceType.Camera, DeviceType.Sensor, DeviceType.Switch, method(object({ deviceI
|
|
|
27197
27211
|
var RecordingStatusSchema = object({
|
|
27198
27212
|
deviceId: number(),
|
|
27199
27213
|
enabled: boolean(),
|
|
27200
|
-
|
|
27201
|
-
|
|
27202
|
-
|
|
27203
|
-
|
|
27204
|
-
]),
|
|
27214
|
+
/** THE derived storage mode, from the one definition
|
|
27215
|
+
* (`deriveRecordingMode`) — never a second enum. A duplicated list is how
|
|
27216
|
+
* `on-device-decision` could have reached the recorder and not the status. */
|
|
27217
|
+
activeMode: RecordingStorageModeSchema,
|
|
27205
27218
|
nodeId: string(),
|
|
27206
27219
|
storageBytes: number()
|
|
27207
27220
|
});
|
package/dist/index.mjs
CHANGED
|
@@ -7845,17 +7845,29 @@ var HHMM = /^([01]\d|2[0-3]):[0-5]\d$/;
|
|
|
7845
7845
|
/**
|
|
7846
7846
|
* DERIVED per-camera storage summary — the single field cheap consumers read
|
|
7847
7847
|
* (the viewer's status dot, the camera list) instead of walking `bands`:
|
|
7848
|
-
* - `off`
|
|
7849
|
-
* - `events`
|
|
7850
|
-
* - `continuous`
|
|
7851
|
-
*
|
|
7852
|
-
*
|
|
7853
|
-
*
|
|
7848
|
+
* - `off` — no band covers the camera (or it is disabled).
|
|
7849
|
+
* - `events` — every band records around triggers only.
|
|
7850
|
+
* - `continuous` — at least one band records continuously.
|
|
7851
|
+
* - `on-device-decision`— the DEVICE decides: recording runs for as long as the
|
|
7852
|
+
* camera raises its own `recording-signal` level (a robot that cleans). There
|
|
7853
|
+
* is no schedule to author, because there is no hour to program — see
|
|
7854
|
+
* {@link RecordingConfigSchema}`.deviceDecision`.
|
|
7855
|
+
*
|
|
7856
|
+
* NEVER authored: the recorder stamps it from the authoritative intent
|
|
7857
|
+
* (`bands` + `deviceDecision`) on every save (`activeModeForConfig`). Writing it
|
|
7858
|
+
* has no effect.
|
|
7859
|
+
*
|
|
7860
|
+
* `on-device-decision` is named for WHO decides, not for how the recording is
|
|
7861
|
+
* requested. `on-demand` was rejected: in this repo's vocabulary a "demand" is
|
|
7862
|
+
* something the operator makes (the live gate is the recorder's own "demand
|
|
7863
|
+
* window"), and a knob whose name suggests the operator starts it while the
|
|
7864
|
+
* device actually does is the D62 shape — a control nobody can predict.
|
|
7854
7865
|
*/
|
|
7855
7866
|
var RecordingStorageModeSchema = _enum([
|
|
7856
7867
|
"off",
|
|
7857
7868
|
"events",
|
|
7858
|
-
"continuous"
|
|
7869
|
+
"continuous",
|
|
7870
|
+
"on-device-decision"
|
|
7859
7871
|
]);
|
|
7860
7872
|
/**
|
|
7861
7873
|
* Le macro classi che possono aprire una finestra di registrazione — le stesse
|
|
@@ -7905,22 +7917,7 @@ var RecordingTriggersSchema = object({
|
|
|
7905
7917
|
* il livello: un contatto trovato già aperto al riavvio del runner non fa
|
|
7906
7918
|
* registrare.
|
|
7907
7919
|
*/
|
|
7908
|
-
sensorDeviceIds: array(number().int().positive()).min(1).max(16).refine(noDuplicates, { message: "sensorDeviceIds must not repeat a device" }).optional()
|
|
7909
|
-
/**
|
|
7910
|
-
* La camera registra per tutta la durata del SEGNALE che lei stessa
|
|
7911
|
-
* pubblica — la cap `recording-signal` (`active: true` mentre il device è in
|
|
7912
|
-
* funzione: un robot che pulisce). È un LIVELLO, non un fronte: la finestra
|
|
7913
|
-
* resta aperta finché il segnale è alto e si chiude `postBufferSec` dopo la
|
|
7914
|
-
* caduta, così una pulizia di quaranta minuti è UNA clip.
|
|
7915
|
-
*
|
|
7916
|
-
* Non nomina un device: il segnale è della camera stessa, tenuto fresco dal
|
|
7917
|
-
* suo provider (D224); il recorder lo ascolta su `DeviceStateChanged` e lo
|
|
7918
|
-
* riconcilia leggendo la slice via RPC, con un tetto oltre il quale un
|
|
7919
|
-
* segnale mai abbassato (un evento perso) non può tenere aperta una
|
|
7920
|
-
* registrazione (D11). Vedi `recorder/addon/band-decision.ts`
|
|
7921
|
-
* (`holdTrigger` / `releaseTrigger`).
|
|
7922
|
-
*/
|
|
7923
|
-
deviceSignal: boolean().optional()
|
|
7920
|
+
sensorDeviceIds: array(number().int().positive()).min(1).max(16).refine(noDuplicates, { message: "sensorDeviceIds must not repeat a device" }).optional()
|
|
7924
7921
|
});
|
|
7925
7922
|
/**
|
|
7926
7923
|
* Mode of a single recording band — the recorder per-band vocabulary.
|
|
@@ -8004,8 +8001,29 @@ var RecordingConfigSchema = object({
|
|
|
8004
8001
|
* "off" is the absence of a covering band, never a band value.
|
|
8005
8002
|
*/
|
|
8006
8003
|
bands: array(RecordingBandSchema).default([]),
|
|
8004
|
+
/**
|
|
8005
|
+
* THE device-decided intent: record for as long as the camera itself raises
|
|
8006
|
+
* `recording-signal` (`active: true` while the device is in function — a
|
|
8007
|
+
* robot that cleans). AUTHORED, unlike `mode`, and the only authored
|
|
8008
|
+
* recording intent that is not a band.
|
|
8009
|
+
*
|
|
8010
|
+
* It carries NO schedule on purpose. A band is an HOUR, and this feature has
|
|
8011
|
+
* no hour to program: the device decides. What it costs the operator is one
|
|
8012
|
+
* flag — "this camera can record on its own" — and what it buys is the same
|
|
8013
|
+
* hold/release the recorder already implements (D371, `holdTrigger` /
|
|
8014
|
+
* `releaseTrigger`): the window opens on the rise, stays open for the whole
|
|
8015
|
+
* job however long it is, and closes one pad after the fall.
|
|
8016
|
+
*
|
|
8017
|
+
* EXCLUSIVE with `bands` (below): two authorities deciding when the same
|
|
8018
|
+
* camera records is the D62 failure. `off` remains `enabled: false`, so an
|
|
8019
|
+
* operator switching this camera off is REPORTED off, never as broken.
|
|
8020
|
+
*/
|
|
8021
|
+
deviceDecision: boolean().optional(),
|
|
8007
8022
|
retention: RecordingRetentionSchema.optional()
|
|
8008
|
-
}).strict()
|
|
8023
|
+
}).strict().refine((config) => config.deviceDecision !== true || config.bands.length === 0, {
|
|
8024
|
+
message: "deviceDecision is a whole-config mode and carries no schedule: it cannot be combined with bands",
|
|
8025
|
+
path: ["bands"]
|
|
8026
|
+
});
|
|
8009
8027
|
/**
|
|
8010
8028
|
* Entity-relocation job state (storage entity-routing spec, Phase 4).
|
|
8011
8029
|
*
|
|
@@ -20783,11 +20801,7 @@ var CameraAudioStatusSchema = object({
|
|
|
20783
20801
|
});
|
|
20784
20802
|
/** Recording block — null when no recording cap is active for this device. */
|
|
20785
20803
|
var CameraRecordingStatusSchema = object({
|
|
20786
|
-
mode:
|
|
20787
|
-
"off",
|
|
20788
|
-
"continuous",
|
|
20789
|
-
"events"
|
|
20790
|
-
]),
|
|
20804
|
+
mode: RecordingStorageModeSchema,
|
|
20791
20805
|
active: boolean(),
|
|
20792
20806
|
storageBytes: number()
|
|
20793
20807
|
});
|
|
@@ -27193,11 +27207,10 @@ DeviceType.Camera, DeviceType.Sensor, DeviceType.Switch, method(object({ deviceI
|
|
|
27193
27207
|
var RecordingStatusSchema = object({
|
|
27194
27208
|
deviceId: number(),
|
|
27195
27209
|
enabled: boolean(),
|
|
27196
|
-
|
|
27197
|
-
|
|
27198
|
-
|
|
27199
|
-
|
|
27200
|
-
]),
|
|
27210
|
+
/** THE derived storage mode, from the one definition
|
|
27211
|
+
* (`deriveRecordingMode`) — never a second enum. A duplicated list is how
|
|
27212
|
+
* `on-device-decision` could have reached the recorder and not the status. */
|
|
27213
|
+
activeMode: RecordingStorageModeSchema,
|
|
27201
27214
|
nodeId: string(),
|
|
27202
27215
|
storageBytes: number()
|
|
27203
27216
|
});
|