@camstack/addon-osd-manager 0.1.127 → 0.1.128
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/{MotionZonesSettings-k6Zzbfy9.mjs → MotionZonesSettings-DqRYIx3V.mjs} +2 -2
- package/dist/{PrivacyMaskSettings-DwhFoc16.mjs → PrivacyMaskSettings-tONTkkCF.mjs} +4 -4
- package/dist/{SceneMonitorEditor-DAqbVCgr.mjs → SceneMonitorEditor-DMfjQQfD.mjs} +3 -3
- package/dist/_stub.js +10 -10
- package/dist/{_virtual_mf-localSharedImportMap___mfe_internal__addon_osd_manager_page-CyqISXAF.mjs → _virtual_mf-localSharedImportMap___mfe_internal__addon_osd_manager_page-D_49CiBy.mjs} +3 -3
- package/dist/_virtual_mf___mfe_internal__addon_osd_manager_page__loadShare___mf_0_camstack_mf_1_types__loadShare__.js-B9U0FY5V.mjs +26 -0
- package/dist/{cap-error-hton7JwR.mjs → cap-error-Cj2E3c0-.mjs} +1 -1
- package/dist/{hostInit-C6_macGX.mjs → hostInit-CE_Cq0Q6.mjs} +2 -2
- package/dist/index.js +299 -8
- package/dist/index.mjs +299 -8
- package/dist/{player-overlays-CEidmNyu.mjs → player-overlays-B1QNz7_H.mjs} +1 -1
- package/dist/remoteEntry.js +1 -1
- package/dist/{scene-monitor-copy-CLKtgPk1.mjs → scene-monitor-copy-DZan2tbo.mjs} +1 -1
- package/dist/{square-Dq8X76sM.mjs → square-B4Ae4SRW.mjs} +1 -1
- package/dist/{trash-2-BYTSgKQu.mjs → trash-2-DzFAgcKl.mjs} +1 -1
- package/dist/{virtual_mf-REMOTE_ENTRY_ID___mfe_internal__addon_osd_manager_page__remoteEntry_js-BaGg7cne.mjs → virtual_mf-REMOTE_ENTRY_ID___mfe_internal__addon_osd_manager_page__remoteEntry_js-sRuVMTqE.mjs} +1 -1
- package/package.json +1 -1
- package/dist/_virtual_mf___mfe_internal__addon_osd_manager_page__loadShare___mf_0_camstack_mf_1_types__loadShare__.js-Ds-WCEP6.mjs +0 -26
package/dist/index.js
CHANGED
|
@@ -5363,7 +5363,7 @@ var ZodIssueCode = {
|
|
|
5363
5363
|
var ZodFirstPartyTypeKind;
|
|
5364
5364
|
ZodFirstPartyTypeKind || (ZodFirstPartyTypeKind = {});
|
|
5365
5365
|
//#endregion
|
|
5366
|
-
//#region ../types/dist/sleep-
|
|
5366
|
+
//#region ../types/dist/sleep-BVhJDJka.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).
|
|
@@ -6934,6 +6934,18 @@ function systemMethod(input, output, options) {
|
|
|
6934
6934
|
systemOnly: true
|
|
6935
6935
|
};
|
|
6936
6936
|
}
|
|
6937
|
+
/**
|
|
6938
|
+
* A method a SOURCE of a collection cap may legitimately not serve — OPTIONAL
|
|
6939
|
+
* on `InferProvider`. The `providerOptional: true` literal is what
|
|
6940
|
+
* `InferProvider` keys on; see {@link CapabilityMethodSchema.providerOptional}
|
|
6941
|
+
* for when this is the honest answer and when it is a soft stub.
|
|
6942
|
+
*/
|
|
6943
|
+
function optionalMethod(input, output, options) {
|
|
6944
|
+
return {
|
|
6945
|
+
...method(input, output, options),
|
|
6946
|
+
providerOptional: true
|
|
6947
|
+
};
|
|
6948
|
+
}
|
|
6937
6949
|
/** Shorthand to define an event schema */
|
|
6938
6950
|
function event(data) {
|
|
6939
6951
|
return { data };
|
|
@@ -29217,6 +29229,59 @@ var ClipPlaybackSchema = object({
|
|
|
29217
29229
|
* which days it asked for and got nothing — "no clips" would be a lie about a
|
|
29218
29230
|
* card that is full of them.
|
|
29219
29231
|
*/
|
|
29232
|
+
/**
|
|
29233
|
+
* The operator's authorisation to WAKE a sleeping camera for one clip read.
|
|
29234
|
+
*
|
|
29235
|
+
* ONE value, absent by default, and it is a `force`-shaped operator signal in
|
|
29236
|
+
* exactly the sense `snapshot-wake-gate.ts` uses the word: *"`snapshot.getSnapshot`'s
|
|
29237
|
+
* `force` flag, and nothing else… a background caller must never set it…
|
|
29238
|
+
* Stale but honest beats woken"*. A scheduler, a retry, a reconcile and a
|
|
29239
|
+
* prefetch never set it; a surface sets it only behind the same confirm the
|
|
29240
|
+
* "Wake and refresh" gesture uses, and it is refused below 15 % battery
|
|
29241
|
+
* exactly as that gesture is.
|
|
29242
|
+
*
|
|
29243
|
+
* The gate is decided BEFORE `getApi()`, because on UDP the login IS the wake
|
|
29244
|
+
* (D549) — a read that opened a session and then checked would have woken the
|
|
29245
|
+
* camera to find out it was not allowed to.
|
|
29246
|
+
*
|
|
29247
|
+
* **One authorised yes is one wake.** `next-natural` — take the clip the next
|
|
29248
|
+
* time the camera is awake for its own reasons — is deliberately not a member:
|
|
29249
|
+
* it was proposed, it is free on the battery, and the operator declined it on
|
|
29250
|
+
* 2026-09-20 (*"Quando un export viene richiesto si sveglia la camera."*,
|
|
29251
|
+
* D558 "Considered and not taken").
|
|
29252
|
+
*/
|
|
29253
|
+
var ClipWakeSchema = _enum(["authorised"]);
|
|
29254
|
+
/**
|
|
29255
|
+
* A clip's finished bytes, inline — the twin of `recordingExport.readExportBytes`.
|
|
29256
|
+
*
|
|
29257
|
+
* `bytes` is the DECODED length, so nobody infers it from the base64 length,
|
|
29258
|
+
* and `served` says which twin the caller actually got.
|
|
29259
|
+
*/
|
|
29260
|
+
var ClipBytesSchema = object({
|
|
29261
|
+
base64: string(),
|
|
29262
|
+
contentType: string(),
|
|
29263
|
+
/** Suggested filename, extension included. */
|
|
29264
|
+
name: string(),
|
|
29265
|
+
bytes: number().int().nonnegative(),
|
|
29266
|
+
/**
|
|
29267
|
+
* Which twin was actually served — the same contract
|
|
29268
|
+
* {@link ClipPlaybackSchema.served} carries, and REQUIRED here because the
|
|
29269
|
+
* export record persists it: a row read a week later must say the same thing
|
|
29270
|
+
* the panel said at the moment of the tap. A missing main twin is never
|
|
29271
|
+
* served silently as if it were the asked-for quality (D549 15).
|
|
29272
|
+
*/
|
|
29273
|
+
served: CamProfileSchema,
|
|
29274
|
+
/**
|
|
29275
|
+
* The DECODED duration of the delivered file, when the fetch measured one.
|
|
29276
|
+
*
|
|
29277
|
+
* A clip fetch verifies its own completion against the catalog row and
|
|
29278
|
+
* retries a materially short pass (D568); this is that measurement, carried
|
|
29279
|
+
* so a consumer can say the same thing rather than re-deriving it. Absent
|
|
29280
|
+
* when the producer did not measure — never zero, which would say the file
|
|
29281
|
+
* is empty.
|
|
29282
|
+
*/
|
|
29283
|
+
durationMs: number().positive().optional()
|
|
29284
|
+
});
|
|
29220
29285
|
var ClipSourceAvailabilitySchema = object({
|
|
29221
29286
|
state: _enum([
|
|
29222
29287
|
"ok",
|
|
@@ -29388,6 +29453,68 @@ var videoclipsCapability = {
|
|
|
29388
29453
|
}), ClipPlaybackSchema, {
|
|
29389
29454
|
kind: "query",
|
|
29390
29455
|
auth: "protected"
|
|
29456
|
+
}),
|
|
29457
|
+
/**
|
|
29458
|
+
* This clip's BYTES, base64, bounded — the by-handle read a clip EXPORT
|
|
29459
|
+
* pulls once (D558).
|
|
29460
|
+
*
|
|
29461
|
+
* `getClipPlayback` is the right answer for a player: it hands back a URL
|
|
29462
|
+
* on a plane the hub serves `access:'authenticated'`, which a browser and a
|
|
29463
|
+
* viewer session satisfy. It is the wrong answer for another ADDON. There
|
|
29464
|
+
* is no addon→addon byte transport in this framework — `AddonDataPlane`
|
|
29465
|
+
* only lets an addon SERVE, on `127.0.0.1` behind a per-listener secret
|
|
29466
|
+
* only the hub may present — so a recorder that wants a camera's clip
|
|
29467
|
+
* cannot fetch that URL. This method is the one seam that exists for it,
|
|
29468
|
+
* and it is deliberately the same shape (and the same bound) as
|
|
29469
|
+
* `recordingExport.readExportBytes`, which exists for the mirror-image
|
|
29470
|
+
* reason.
|
|
29471
|
+
*
|
|
29472
|
+
* Routing needs no `provider` pin: the id is source-prefixed and
|
|
29473
|
+
* self-contained, so `device-collection-dispatch.ts` rule 3 hands the call
|
|
29474
|
+
* to the source that claims it — and an id nobody claims is REFUSED rather
|
|
29475
|
+
* than answered by another source.
|
|
29476
|
+
*
|
|
29477
|
+
* The producer reuses the fetch path it already has, completion rules
|
|
29478
|
+
* included: a clip is taken by cmd 5 and finished on a short idle window
|
|
29479
|
+
* whose result is PROVED against the catalog row's own span, retried once
|
|
29480
|
+
* when it comes up materially short, and served-and-named when it is still
|
|
29481
|
+
* short (D568). A second fetch with different completion rules is exactly
|
|
29482
|
+
* the second authority D558 refuses to create.
|
|
29483
|
+
*
|
|
29484
|
+
* Every refusal THROWS with its reason and none of them is silent — the
|
|
29485
|
+
* sleep gate (decided before `getApi()`, liftable only by
|
|
29486
|
+
* {@link ClipWakeSchema}), a catalog row nobody claims, a clip with no
|
|
29487
|
+
* bytes behind it, a mux that failed, and the size bound. The caller turns
|
|
29488
|
+
* that reason into an operator-facing one; a truncated file is never an
|
|
29489
|
+
* answer.
|
|
29490
|
+
*/
|
|
29491
|
+
readClipBytes: optionalMethod(object({
|
|
29492
|
+
deviceId: number(),
|
|
29493
|
+
clipId: string().min(1),
|
|
29494
|
+
/**
|
|
29495
|
+
* Which twin to fetch, on the mapping D549 15 already fixed:
|
|
29496
|
+
* `low | mid` → the sub file, `high` → the main twin. `auto` is not
|
|
29497
|
+
* accepted here for the same reason it is not accepted by
|
|
29498
|
+
* `getClipPlayback` — a stored file has no broker session, so the
|
|
29499
|
+
* adaptive tier cannot be resolved for it.
|
|
29500
|
+
*/
|
|
29501
|
+
profile: CamProfileSchema.optional(),
|
|
29502
|
+
/**
|
|
29503
|
+
* The CALLER's byte bound, so an over-size clip is refused before it is
|
|
29504
|
+
* read and encoded rather than after. Capped by
|
|
29505
|
+
* {@link VIDEOCLIPS_MAX_READ_BYTES} whatever is passed; absent means
|
|
29506
|
+
* that ceiling.
|
|
29507
|
+
*/
|
|
29508
|
+
maxBytes: number().int().positive().optional(),
|
|
29509
|
+
/**
|
|
29510
|
+
* The operator's authorisation to wake a sleeping camera for this
|
|
29511
|
+
* read. Absent — the default — means a sleeping standalone battery
|
|
29512
|
+
* camera is REFUSED by name, before any session is opened.
|
|
29513
|
+
*/
|
|
29514
|
+
wake: ClipWakeSchema.optional()
|
|
29515
|
+
}), ClipBytesSchema, {
|
|
29516
|
+
kind: "query",
|
|
29517
|
+
auth: "protected"
|
|
29391
29518
|
})
|
|
29392
29519
|
}
|
|
29393
29520
|
};
|
|
@@ -38324,13 +38451,101 @@ var ExportStateSchema = _enum([
|
|
|
38324
38451
|
"expired",
|
|
38325
38452
|
"deleted"
|
|
38326
38453
|
]);
|
|
38327
|
-
/**
|
|
38454
|
+
/**
|
|
38455
|
+
* WHAT an export is — the authority, as opposed to the four top-level fields
|
|
38456
|
+
* the Library sorts and labels on (D558 § 2.2).
|
|
38457
|
+
*
|
|
38458
|
+
* Read it through {@link exportSubjectOf}, never off the record directly: the
|
|
38459
|
+
* field is optional for the history rows written before it existed, and that
|
|
38460
|
+
* absence has exactly one interpreter.
|
|
38461
|
+
*/
|
|
38462
|
+
var ExportSubjectSchema = discriminatedUnion("kind", [object({
|
|
38463
|
+
kind: literal("footage"),
|
|
38464
|
+
deviceId: number(),
|
|
38465
|
+
profiles: array(string()).min(1),
|
|
38466
|
+
fromMs: number(),
|
|
38467
|
+
toMs: number()
|
|
38468
|
+
}), object({
|
|
38469
|
+
kind: literal("clip"),
|
|
38470
|
+
deviceId: number(),
|
|
38471
|
+
provider: string().min(1),
|
|
38472
|
+
source: string().min(1),
|
|
38473
|
+
sourceLabel: string().min(1),
|
|
38474
|
+
clipId: string().min(1),
|
|
38475
|
+
/**
|
|
38476
|
+
* WHERE IN THE CATALOG to confirm this clip — the day window the surface was
|
|
38477
|
+
* already listing when the operator picked the segment.
|
|
38478
|
+
*
|
|
38479
|
+
* It is **not** a time range control and it never becomes one: the record's
|
|
38480
|
+
* `fromMs`/`toMs` come from the catalog ROW and from nothing a caller
|
|
38481
|
+
* supplied (D558 § 5.4.3), and a window that does not contain the clip is a
|
|
38482
|
+
* `catalog-miss`, not a silently wider search. It exists because
|
|
38483
|
+
* `videoclips.listClips` takes `since`/`until` and has no by-handle twin:
|
|
38484
|
+
* the catalog check D558 asks for is literally that call, and a call needs a
|
|
38485
|
+
* window. The surface has one — `ClipsBrowser`'s `dayWindow`, one local
|
|
38486
|
+
* wall-clock day, which is also the only width measured to be cheap (one
|
|
38487
|
+
* day on 592 lists 171 clips in 712 ms, a busy day 546 in 2.0 s; twenty days
|
|
38488
|
+
* of one child's events took 3.6–5.4 s).
|
|
38489
|
+
*/
|
|
38490
|
+
catalogWindow: object({
|
|
38491
|
+
sinceMs: number(),
|
|
38492
|
+
untilMs: number()
|
|
38493
|
+
}),
|
|
38494
|
+
profile: _enum([
|
|
38495
|
+
"high",
|
|
38496
|
+
"mid",
|
|
38497
|
+
"low"
|
|
38498
|
+
]),
|
|
38499
|
+
/**
|
|
38500
|
+
* The operator's authorisation to wake a sleeping camera for this export.
|
|
38501
|
+
* ONE definition, in the cap that owns the clip read ({@link ClipWakeSchema}),
|
|
38502
|
+
* because the gate that honours it is the clip provider's sleep gate — a
|
|
38503
|
+
* second enum here would be a second contract. Absent by default; never
|
|
38504
|
+
* settable by a scheduler or a retry.
|
|
38505
|
+
*
|
|
38506
|
+
* **One authorised yes is ONE wake.** A failed clip export is retried only by
|
|
38507
|
+
* an operator act that asks again; a queued job that outlived its wake fails
|
|
38508
|
+
* with a reason rather than waking on its turn; and this subject carries
|
|
38509
|
+
* exactly one profile precisely so one tap is never two fetches (D558 § 5.2).
|
|
38510
|
+
*/
|
|
38511
|
+
wake: ClipWakeSchema.optional()
|
|
38512
|
+
})]);
|
|
38513
|
+
/**
|
|
38514
|
+
* One export job / history row.
|
|
38515
|
+
*
|
|
38516
|
+
* **`subject` is the AUTHORITY on what was exported. `deviceId`, `profile`,
|
|
38517
|
+
* `fromMs` and `toMs` are its PROJECTION** — kept top-level because the whole
|
|
38518
|
+
* Library sorts and labels on them (`library-items.ts` orders an export by
|
|
38519
|
+
* `fromMs`; `export-format.ts` draws `rangeLabel` from the pair), and a row
|
|
38520
|
+
* that did not fill them would sort under the epoch and render a blank range.
|
|
38521
|
+
* Write to the subject and read from the projection and the two will disagree;
|
|
38522
|
+
* the projection is derived at creation and never edited afterwards.
|
|
38523
|
+
*
|
|
38524
|
+
* And they mean DIFFERENT FACTS for the two kinds, which is the part a reader
|
|
38525
|
+
* who knows only the recording export will get wrong:
|
|
38526
|
+
*
|
|
38527
|
+
* | field | `kind:'footage'` | `kind:'clip'` |
|
|
38528
|
+
* | --- | --- | --- |
|
|
38529
|
+
* | `fromMs`/`toMs` | the stretch the operator ASKED for | the camera's own boundaries, always `clip.timeRange`, never anything a caller supplied |
|
|
38530
|
+
* | `profile` | the stream rendered | the twin actually SERVED (`subject.profile` is the one asked for) |
|
|
38531
|
+
*
|
|
38532
|
+
* Same type, different fact — the shape this repo keeps getting wrong (D385's
|
|
38533
|
+
* two authorities, D224's second copy).
|
|
38534
|
+
*/
|
|
38328
38535
|
var ExportRecordSchema = object({
|
|
38329
38536
|
id: string(),
|
|
38330
38537
|
deviceId: number(),
|
|
38331
38538
|
profile: string(),
|
|
38332
38539
|
fromMs: number(),
|
|
38333
38540
|
toMs: number(),
|
|
38541
|
+
/**
|
|
38542
|
+
* What this export IS. Optional ONLY for the rows written before D558: the
|
|
38543
|
+
* store parses every row through this schema on every read, so a required
|
|
38544
|
+
* field would make the export AUDIT — which is the whole reason rows survive
|
|
38545
|
+
* file deletion — unreadable in one release. Absence means `footage`, and
|
|
38546
|
+
* {@link exportSubjectOf} is the one place that says so.
|
|
38547
|
+
*/
|
|
38548
|
+
subject: ExportSubjectSchema.optional(),
|
|
38334
38549
|
options: ExportOptionsSchema,
|
|
38335
38550
|
state: ExportStateSchema,
|
|
38336
38551
|
/** 0–100 while rendering; null otherwise. */
|
|
@@ -38347,6 +38562,18 @@ var ExportRecordSchema = object({
|
|
|
38347
38562
|
/** Failure reason when state is 'failed'; null otherwise. */
|
|
38348
38563
|
error: string().nullable()
|
|
38349
38564
|
});
|
|
38565
|
+
_enum([
|
|
38566
|
+
"catalog-miss",
|
|
38567
|
+
"catalog-unreachable",
|
|
38568
|
+
"no-file-for-window",
|
|
38569
|
+
"clip-in-progress",
|
|
38570
|
+
"unsupported-option",
|
|
38571
|
+
"sleeping",
|
|
38572
|
+
"camera-refused",
|
|
38573
|
+
"fetch-failed",
|
|
38574
|
+
"too-large-to-transfer",
|
|
38575
|
+
"wake-expired"
|
|
38576
|
+
]);
|
|
38350
38577
|
/** Candidate download URLs (LAN first, then operator extra hosts). */
|
|
38351
38578
|
var ExportDownloadSchema = object({
|
|
38352
38579
|
url: string(),
|
|
@@ -38365,24 +38592,77 @@ var ExportBytesSchema = object({
|
|
|
38365
38592
|
name: string(),
|
|
38366
38593
|
bytes: number().int().nonnegative()
|
|
38367
38594
|
});
|
|
38595
|
+
/** Canonical `profiles[]`, falling back to the legacy singular `profile`. */
|
|
38596
|
+
function resolveExportProfiles(input) {
|
|
38597
|
+
if (input.profiles !== void 0 && input.profiles.length > 0) return [...input.profiles];
|
|
38598
|
+
if (typeof input.profile === "string" && input.profile.length > 0) return [input.profile];
|
|
38599
|
+
return [];
|
|
38600
|
+
}
|
|
38368
38601
|
var recordingExportCapability = {
|
|
38369
38602
|
name: "recording-export",
|
|
38370
38603
|
scope: "system",
|
|
38371
38604
|
mode: "singleton",
|
|
38372
38605
|
methods: {
|
|
38373
|
-
/**
|
|
38374
|
-
*
|
|
38375
|
-
*
|
|
38606
|
+
/**
|
|
38607
|
+
* Queue an export of {@link ExportSubjectSchema}.
|
|
38608
|
+
*
|
|
38609
|
+
* `kind:'footage'` — a render of `[fromMs,toMs)` for `deviceId`/`profiles`
|
|
38610
|
+
* (legacy flat input, singular `profile` included, still accepted and
|
|
38611
|
+
* rewritten). Fails fast when no footage covers the range. One job per
|
|
38612
|
+
* profile; **returns the first queued record and the others are reachable
|
|
38613
|
+
* only through `listExports`** — a defect named in D558 § 6.3 and the
|
|
38614
|
+
* reason a clip subject carries exactly ONE profile.
|
|
38615
|
+
*
|
|
38616
|
+
* `kind:'clip'` — a finished file the camera holds, validated against the
|
|
38617
|
+
* device's clip CATALOG (`videoclips.listClips`, at the subject's
|
|
38618
|
+
* `provider`) instead of the recording index, and fetched once by handle
|
|
38619
|
+
* under a bound. Its `fromMs`/`toMs` come from the catalog row and from
|
|
38620
|
+
* nowhere else; a caller supplying a range is refused.
|
|
38621
|
+
*
|
|
38622
|
+
* A clip export reuses the six {@link ExportStateSchema} members and adds
|
|
38623
|
+
* none: the viewer maps an unknown state string to `failed`, so a seventh
|
|
38624
|
+
* member renders every live export — of both kinds — as FAILED on every
|
|
38625
|
+
* installed app (D558 § 6.1, pinned by `export-state-members.spec.ts`).
|
|
38626
|
+
* `subject.kind` is what tells a surface what `rendering` means.
|
|
38627
|
+
*/
|
|
38376
38628
|
createExport: method(object({
|
|
38377
38629
|
deviceId: number(),
|
|
38378
38630
|
/** @deprecated Prefer `profiles`. Kept so timelapse/notifiers keep working. */
|
|
38379
38631
|
profile: string().optional(),
|
|
38380
38632
|
profiles: array(string()).min(1).optional(),
|
|
38381
|
-
|
|
38382
|
-
|
|
38633
|
+
/** Footage only — a clip's boundaries are the camera's. */
|
|
38634
|
+
fromMs: number().optional(),
|
|
38635
|
+
toMs: number().optional(),
|
|
38636
|
+
/** What to export. Absent means the legacy flat footage request. */
|
|
38637
|
+
subject: ExportSubjectSchema.optional(),
|
|
38383
38638
|
options: ExportOptionsSchema
|
|
38384
38639
|
}).superRefine((v, ctx) => {
|
|
38385
|
-
if (
|
|
38640
|
+
if (v.subject?.kind === "clip") {
|
|
38641
|
+
if (v.subject.deviceId !== v.deviceId) ctx.addIssue({
|
|
38642
|
+
code: ZodIssueCode.custom,
|
|
38643
|
+
message: `subject.deviceId (${v.subject.deviceId}) must equal deviceId (${v.deviceId}) — the top-level field is what per-device scope enforcement reads`,
|
|
38644
|
+
path: ["subject", "deviceId"]
|
|
38645
|
+
});
|
|
38646
|
+
if (v.fromMs !== void 0 || v.toMs !== void 0) ctx.addIssue({
|
|
38647
|
+
code: ZodIssueCode.custom,
|
|
38648
|
+
message: "a clip export asks for no time range: the camera chose the boundaries and they are read from the catalog row",
|
|
38649
|
+
path: ["fromMs"]
|
|
38650
|
+
});
|
|
38651
|
+
return;
|
|
38652
|
+
}
|
|
38653
|
+
if (v.subject?.kind === "footage" && v.subject.deviceId !== v.deviceId) ctx.addIssue({
|
|
38654
|
+
code: ZodIssueCode.custom,
|
|
38655
|
+
message: `subject.deviceId (${v.subject.deviceId}) must equal deviceId (${v.deviceId})`,
|
|
38656
|
+
path: ["subject", "deviceId"]
|
|
38657
|
+
});
|
|
38658
|
+
const fromMs = v.subject?.kind === "footage" ? v.subject.fromMs : v.fromMs;
|
|
38659
|
+
const toMs = v.subject?.kind === "footage" ? v.subject.toMs : v.toMs;
|
|
38660
|
+
if (typeof fromMs !== "number" || typeof toMs !== "number") ctx.addIssue({
|
|
38661
|
+
code: ZodIssueCode.custom,
|
|
38662
|
+
message: "a footage export needs fromMs and toMs",
|
|
38663
|
+
path: ["fromMs"]
|
|
38664
|
+
});
|
|
38665
|
+
if ((v.subject?.kind === "footage" ? [...v.subject.profiles] : resolveExportProfiles(v)).length < 1) ctx.addIssue({
|
|
38386
38666
|
code: ZodIssueCode.custom,
|
|
38387
38667
|
message: "pass profiles[] (min 1) or legacy profile",
|
|
38388
38668
|
path: ["profiles"]
|
|
@@ -47493,6 +47773,12 @@ Object.freeze({
|
|
|
47493
47773
|
addonId: null,
|
|
47494
47774
|
access: "view"
|
|
47495
47775
|
},
|
|
47776
|
+
"videoclips.readClipBytes": {
|
|
47777
|
+
capName: "videoclips",
|
|
47778
|
+
capScope: "device",
|
|
47779
|
+
addonId: null,
|
|
47780
|
+
access: "view"
|
|
47781
|
+
},
|
|
47496
47782
|
"viewerUi.getStaticDir": {
|
|
47497
47783
|
capName: "viewer-ui",
|
|
47498
47784
|
capScope: "system",
|
|
@@ -49511,6 +49797,11 @@ Object.freeze({
|
|
|
49511
49797
|
form: "single",
|
|
49512
49798
|
optional: false
|
|
49513
49799
|
}],
|
|
49800
|
+
"videoclips.readClipBytes": [{
|
|
49801
|
+
name: "deviceId",
|
|
49802
|
+
form: "single",
|
|
49803
|
+
optional: false
|
|
49804
|
+
}],
|
|
49514
49805
|
"waterHeater.setAway": [{
|
|
49515
49806
|
name: "deviceId",
|
|
49516
49807
|
form: "single",
|