@camstack/addon-decoder-ffmpeg 1.2.14 → 1.2.16
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 +148 -17
- package/dist/index.mjs +148 -17
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -13068,11 +13068,33 @@ var NotificationFormatSchema = _enum([
|
|
|
13068
13068
|
* Named by INTENT, never by glyph. "check" would tie the vocabulary to one
|
|
13069
13069
|
* renderer's icon set; "acknowledge" survives an adapter that draws it
|
|
13070
13070
|
* differently.
|
|
13071
|
+
*
|
|
13072
|
+
* ── A TOKEN IS NOT A WIRE VALUE ─────────────────────────────────────
|
|
13073
|
+
*
|
|
13074
|
+
* These names are for US. **No adapter may forward one verbatim.** Each maps
|
|
13075
|
+
* the whole set onto its own renderer's vocabulary through a
|
|
13076
|
+
* `Record<NotificationActionIcon, string>` — a Record, never a lookup with a
|
|
13077
|
+
* fallback, so adding a member here fails every adapter's build until someone
|
|
13078
|
+
* decides its glyph, which is the only place that decision can be made
|
|
13079
|
+
* honestly.
|
|
13080
|
+
*
|
|
13081
|
+
* This paragraph is the bug. Zentik declared `actionIcons: true` and passed
|
|
13082
|
+
* `disarm` straight through; iOS feeds that string to
|
|
13083
|
+
* `UNNotificationActionIcon(systemImageName:)`, `disarm` is not an SF Symbol,
|
|
13084
|
+
* and every snooze and alarm button arrived BLANK. A pass-through is not a
|
|
13085
|
+
* mapping, and "the field is documented" is not "the value renders".
|
|
13086
|
+
*
|
|
13087
|
+
* Adding a member is TRAIN-BOUND. The enum lives in the published
|
|
13088
|
+
* `@camstack/server` closure and the cap seam validates against the HUB's copy,
|
|
13089
|
+
* so an addon that emits a token the running hub does not know does not lose an
|
|
13090
|
+
* icon — its whole `send` fails Zod validation and the notification never
|
|
13091
|
+
* arrives. Never emit a new token from an addon before the train carrying it.
|
|
13071
13092
|
*/
|
|
13072
13093
|
var NotificationActionIconSchema = _enum([
|
|
13073
13094
|
"acknowledge",
|
|
13074
13095
|
"dismiss",
|
|
13075
13096
|
"silence",
|
|
13097
|
+
"snooze",
|
|
13076
13098
|
"view",
|
|
13077
13099
|
"play",
|
|
13078
13100
|
"open",
|
|
@@ -13080,9 +13102,13 @@ var NotificationActionIconSchema = _enum([
|
|
|
13080
13102
|
"lock",
|
|
13081
13103
|
"unlock",
|
|
13082
13104
|
"arm",
|
|
13105
|
+
"arm-home",
|
|
13106
|
+
"arm-away",
|
|
13107
|
+
"arm-night",
|
|
13083
13108
|
"disarm",
|
|
13084
13109
|
"light",
|
|
13085
|
-
"alert"
|
|
13110
|
+
"alert",
|
|
13111
|
+
"camera"
|
|
13086
13112
|
]);
|
|
13087
13113
|
/** A single tap-through action button. */
|
|
13088
13114
|
var NotificationActionSchema = object({
|
|
@@ -13098,7 +13124,23 @@ var NotificationActionSchema = object({
|
|
|
13098
13124
|
* else — see `notification-center/action-token.ts` for what that does and
|
|
13099
13125
|
* does not buy.
|
|
13100
13126
|
*/
|
|
13101
|
-
destructive: boolean().optional()
|
|
13127
|
+
destructive: boolean().optional(),
|
|
13128
|
+
/**
|
|
13129
|
+
* How the tap should REACH the url.
|
|
13130
|
+
*
|
|
13131
|
+
* `navigate` (absent, and every button authored before this field) opens it:
|
|
13132
|
+
* the phone leaves the notification and shows whatever the callback returns.
|
|
13133
|
+
* That is right for a button whose answer the operator wants to read.
|
|
13134
|
+
*
|
|
13135
|
+
* `background` fires it as a POST and stays put. It exists for the buttons
|
|
13136
|
+
* whose whole point is not to interrupt — "silence this for 30 minutes" is
|
|
13137
|
+
* an answer to the notification, and being thrown into a browser tab to
|
|
13138
|
+
* confirm it costs more attention than the notification did. A backend that
|
|
13139
|
+
* cannot do a background call renders it as an ordinary link (the adapters
|
|
13140
|
+
* fall back rather than dropping the button), so this is a preference, never
|
|
13141
|
+
* a requirement.
|
|
13142
|
+
*/
|
|
13143
|
+
mode: _enum(["navigate", "background"]).optional()
|
|
13102
13144
|
});
|
|
13103
13145
|
/**
|
|
13104
13146
|
* The canonical notification. `body` is the only hard field (Apprise model).
|
|
@@ -13266,6 +13308,24 @@ method(object({}), array(TargetKindSchema)), method(object({}), array(TargetSche
|
|
|
13266
13308
|
targetId: string(),
|
|
13267
13309
|
enabled: boolean()
|
|
13268
13310
|
}), _void(), { kind: "mutation" });
|
|
13311
|
+
new Set([
|
|
13312
|
+
{
|
|
13313
|
+
id: "person",
|
|
13314
|
+
name: "Person"
|
|
13315
|
+
},
|
|
13316
|
+
{
|
|
13317
|
+
id: "vehicle",
|
|
13318
|
+
name: "Vehicle"
|
|
13319
|
+
},
|
|
13320
|
+
{
|
|
13321
|
+
id: "animal",
|
|
13322
|
+
name: "Animal"
|
|
13323
|
+
},
|
|
13324
|
+
{
|
|
13325
|
+
id: "package",
|
|
13326
|
+
name: "Package"
|
|
13327
|
+
}
|
|
13328
|
+
].map((l) => l.id));
|
|
13269
13329
|
var COCO_TO_MACRO = {
|
|
13270
13330
|
mapping: {
|
|
13271
13331
|
person: "person",
|
|
@@ -14063,6 +14123,8 @@ var NcSystemEventKindSchema = _enum([
|
|
|
14063
14123
|
"alarm-triggered",
|
|
14064
14124
|
"alarm-armed",
|
|
14065
14125
|
"alarm-disarmed",
|
|
14126
|
+
"alarm-arming",
|
|
14127
|
+
"alarm-arm-refused",
|
|
14066
14128
|
"camera-online",
|
|
14067
14129
|
"camera-offline",
|
|
14068
14130
|
"camera-disabled",
|
|
@@ -14099,6 +14161,9 @@ var NcSystemEventConditionSchema = object({
|
|
|
14099
14161
|
nodeIds: array(string().min(1)).min(1).optional(),
|
|
14100
14162
|
packageNames: array(string().min(1)).min(1).optional()
|
|
14101
14163
|
});
|
|
14164
|
+
/** Hard ceiling on a window (24h). A snooze that could not expire would be an
|
|
14165
|
+
* outage the operator asked for once and forgot. */
|
|
14166
|
+
var NC_SNOOZE_MAX_MINUTES = 1440;
|
|
14102
14167
|
/** Weekly schedule — OR of windows; absence on the rule = always active. */
|
|
14103
14168
|
var NcScheduleSchema = object({
|
|
14104
14169
|
windows: array(object({
|
|
@@ -14475,15 +14540,15 @@ var NcConditionsSchema = object({
|
|
|
14475
14540
|
* (an `immediate` rule naming an `audio-*` class, one notification per
|
|
14476
14541
|
* classified sample) stays exactly as it was for rules that already use it.
|
|
14477
14542
|
*
|
|
14478
|
-
*
|
|
14479
|
-
* rather than an
|
|
14480
|
-
* (`camstack/src/data/notification-center.ts`, guarded by
|
|
14481
|
-
* `scripts/check-viewer-condition-mirror.ts`) and its rule editor
|
|
14543
|
+
* In {@link NC_CONDITION_CATALOG} since P2, and the ORDER it got there is the
|
|
14544
|
+
* rule rather than an accident: the viewer mirrors the descriptor enums BY
|
|
14545
|
+
* HAND (`camstack/src/data/notification-center.ts`, guarded by
|
|
14546
|
+
* `scripts/check-viewer-condition-mirror.ts`) and its rule editor strips the
|
|
14482
14547
|
* condition fields it does not know when a rule is saved from the phone.
|
|
14483
14548
|
* Publishing an editor for a condition the app cannot round-trip is how an
|
|
14484
|
-
* operator loses a rule's conditions by opening it — so the
|
|
14485
|
-
*
|
|
14486
|
-
*
|
|
14549
|
+
* operator loses a rule's conditions by opening it — so the viewer mirror
|
|
14550
|
+
* (P3, shipped) went FIRST, and the descriptor an editor renders from
|
|
14551
|
+
* follows here.
|
|
14487
14552
|
*/
|
|
14488
14553
|
audio: NcAudioConditionSchema.optional()
|
|
14489
14554
|
});
|
|
@@ -14719,6 +14784,30 @@ var NcRuleInputSchema = object({
|
|
|
14719
14784
|
*/
|
|
14720
14785
|
snoozeAllowGlobal: boolean().optional(),
|
|
14721
14786
|
/**
|
|
14787
|
+
* The snooze durations THIS rule's notification offers as buttons, in
|
|
14788
|
+
* minutes.
|
|
14789
|
+
*
|
|
14790
|
+
* Three states, and all three are distinct — which is exactly why this is
|
|
14791
|
+
* `.optional()` and never `.default()`. A Zod default does not run on the
|
|
14792
|
+
* addon cap path (three production failures in one day), so a schema default
|
|
14793
|
+
* would collapse the first two:
|
|
14794
|
+
*
|
|
14795
|
+
* | value | meaning |
|
|
14796
|
+
* | --- | --- |
|
|
14797
|
+
* | absent | the operator never said ⇒ {@link NC_DEFAULT_SNOOZE_MINUTES} |
|
|
14798
|
+
* | `[]` | **no snooze buttons on this rule** — the explicit override |
|
|
14799
|
+
* | a list | these choices, de-duplicated and sorted, at most four |
|
|
14800
|
+
*
|
|
14801
|
+
* `.max(4)` because the notifier's own action budget is small (ntfy allows
|
|
14802
|
+
* three buttons in total) and a rule that spent it all on snooze choices
|
|
14803
|
+
* would push its own tap-through actions off the notification.
|
|
14804
|
+
*
|
|
14805
|
+
* An empty list is NOT an alarm exemption: a rule the alarm is about, or
|
|
14806
|
+
* that arms the panel, is exempt automatically and cannot be silenced by a
|
|
14807
|
+
* window from anywhere (D133).
|
|
14808
|
+
*/
|
|
14809
|
+
snoozeOptions: array(number().int().min(1).max(NC_SNOOZE_MAX_MINUTES)).max(4).optional(),
|
|
14810
|
+
/**
|
|
14722
14811
|
* Devices this rule ACTUATES — arm the alarm, open a gate, turn on a light.
|
|
14723
14812
|
*
|
|
14724
14813
|
* This is what makes the rule set the alarm's trigger set without the alarm
|
|
@@ -14818,6 +14907,7 @@ var NcConditionDescriptorSchema = object({
|
|
|
14818
14907
|
"device",
|
|
14819
14908
|
"package",
|
|
14820
14909
|
"occupancy",
|
|
14910
|
+
"audio",
|
|
14821
14911
|
"system"
|
|
14822
14912
|
]),
|
|
14823
14913
|
label: string(),
|
|
@@ -14836,6 +14926,7 @@ var NcConditionDescriptorSchema = object({
|
|
|
14836
14926
|
"crossingSelect",
|
|
14837
14927
|
"polygonDraw",
|
|
14838
14928
|
"occupancy",
|
|
14929
|
+
"audio",
|
|
14839
14930
|
"deviceState",
|
|
14840
14931
|
"systemEvent"
|
|
14841
14932
|
]),
|
|
@@ -14987,7 +15078,20 @@ var NcSnoozeInputSchema = object({
|
|
|
14987
15078
|
ruleId: string().optional(),
|
|
14988
15079
|
/** Required when `scope: 'device'`. */
|
|
14989
15080
|
deviceId: number().int().optional(),
|
|
14990
|
-
|
|
15081
|
+
/**
|
|
15082
|
+
* Narrow the window to these subject classes — "the cat, not the person".
|
|
15083
|
+
*
|
|
15084
|
+
* ORTHOGONAL to `scope`, deliberately, and absent means EVERY class: that is
|
|
15085
|
+
* what every window authored before this field meant, so no persisted row
|
|
15086
|
+
* changes meaning and no client has to learn anything to keep working.
|
|
15087
|
+
*
|
|
15088
|
+
* It is what makes the window's real key `(deviceId, classes[])` and lets it
|
|
15089
|
+
* cross rules (D133): the operator points at a camera and a kind of thing,
|
|
15090
|
+
* not at whichever of their four rules happened to produce the notification
|
|
15091
|
+
* they are dismissing.
|
|
15092
|
+
*/
|
|
15093
|
+
classes: array(string().min(1)).min(1).optional(),
|
|
15094
|
+
durationMinutes: number().int().min(1).max(NC_SNOOZE_MAX_MINUTES),
|
|
14991
15095
|
/**
|
|
14992
15096
|
* Silence this for EVERY recipient, not just the caller. Permission is
|
|
14993
15097
|
* checked server-side (the rule's `snoozeAllowGlobal`, or admin for the
|
|
@@ -15012,6 +15116,10 @@ var NcSnoozeSchema = object({
|
|
|
15012
15116
|
scope: NcSnoozeScopeSchema,
|
|
15013
15117
|
ruleId: string().optional(),
|
|
15014
15118
|
deviceId: number().int().optional(),
|
|
15119
|
+
/** Subject classes this window covers. ABSENT = every class — see
|
|
15120
|
+
* {@link NcSnoozeInputSchema.shape.classes}. Lives in the JSON blob and has
|
|
15121
|
+
* no SQLite column: nothing queries a window by class. */
|
|
15122
|
+
classes: array(string().min(1)).min(1).optional(),
|
|
15015
15123
|
startedAt: number(),
|
|
15016
15124
|
/** Exclusive: at exactly this instant the snooze is over. Expiry is a
|
|
15017
15125
|
* COMPARISON, not a job — no sweeper can leave the operator silenced. */
|
|
@@ -17249,6 +17357,22 @@ var detectionFpsField = {
|
|
|
17249
17357
|
default: 10,
|
|
17250
17358
|
step: 1
|
|
17251
17359
|
};
|
|
17360
|
+
/**
|
|
17361
|
+
* The occupancy re-check interval. DEFAULT 300 s (2026-08-13 — was 30 s).
|
|
17362
|
+
*
|
|
17363
|
+
* The recheck is now on by default (a parked car is invisible to occupancy
|
|
17364
|
+
* rules until the stationary registry has been rebuilt by motion, which after a
|
|
17365
|
+
* restart may be never on a quiet camera). Each cycle re-subscribes a detection
|
|
17366
|
+
* session — an RTSP re-dial — so the switch is only affordable at a WIDE
|
|
17367
|
+
* interval: 300 s is ~12 re-dials an hour per camera, against 120 at the old
|
|
17368
|
+
* 30 s. A parked car is therefore counted within 5 minutes of a restart.
|
|
17369
|
+
*
|
|
17370
|
+
* Why not wider: `max` is 300 and raising it is TRAIN-BOUND, not addon-bound —
|
|
17371
|
+
* the host validates `attachCamera` against ITS copy of this schema, so a
|
|
17372
|
+
* runner asked for 600 would be rejected by the hub until a `@camstack/server`
|
|
17373
|
+
* carrying the wider bound is installed everywhere. 300 is the widest value
|
|
17374
|
+
* that ships with an addon deploy.
|
|
17375
|
+
*/
|
|
17252
17376
|
var occupancyRecheckSecField = {
|
|
17253
17377
|
min: 0,
|
|
17254
17378
|
max: 300,
|
|
@@ -17450,15 +17574,21 @@ var RunnerCameraConfigSchema = object({
|
|
|
17450
17574
|
*/
|
|
17451
17575
|
onboardMotionDrivesAnalyzer: boolean().default(true),
|
|
17452
17576
|
/**
|
|
17453
|
-
* Master toggle for the occupancy re-check. When `false`
|
|
17454
|
-
*
|
|
17455
|
-
* this is off by default because the recheck re-subscribes a detection session
|
|
17456
|
-
* every N seconds while `watching`, a major source of pull-decoder re-dial
|
|
17457
|
-
* churn (each cycle creates+tears a session → RTSP re-dial → latency). The
|
|
17577
|
+
* Master toggle for the occupancy re-check. When `false` the runner never arms
|
|
17578
|
+
* the periodic recheck timer, regardless of `occupancyRecheckSec`; the
|
|
17458
17579
|
* `occupancyRecheckSec` / `occupancyRecheckFrames` sliders only take effect
|
|
17459
17580
|
* (and only render) when this is enabled.
|
|
17460
|
-
|
|
17461
|
-
|
|
17581
|
+
*
|
|
17582
|
+
* DEFAULT `true` since 2026-08-13 (was `false`). It was off because the
|
|
17583
|
+
* recheck re-subscribes a detection session every N seconds while `watching`
|
|
17584
|
+
* — each cycle creates+tears a session ⇒ an RTSP re-dial ⇒ latency, a major
|
|
17585
|
+
* pull-decoder churn source. What that bought was a blind spot: a STATIONARY
|
|
17586
|
+
* object is counted only while the stationary registry holds it, and the
|
|
17587
|
+
* registry rebuilds from motion, so after a restart a parked car was invisible
|
|
17588
|
+
* to every occupancy rule until something moved in front of it. The churn is
|
|
17589
|
+
* now paid on the interval instead — see `occupancyRecheckSecField`.
|
|
17590
|
+
*/
|
|
17591
|
+
occupancyRecheckEnabled: boolean().default(true),
|
|
17462
17592
|
occupancyRecheckSec: number().min(occupancyRecheckSecField.min).max(occupancyRecheckSecField.max).default(occupancyRecheckSecField.default),
|
|
17463
17593
|
occupancyRecheckFrames: number().min(occupancyRecheckFramesField.min).max(occupancyRecheckFramesField.max).default(occupancyRecheckFramesField.default),
|
|
17464
17594
|
/**
|
|
@@ -30584,6 +30714,7 @@ Object.freeze({
|
|
|
30584
30714
|
"network-access": "ingress",
|
|
30585
30715
|
"smtp-provider": "email"
|
|
30586
30716
|
});
|
|
30717
|
+
new Map(AUDIO_MACRO_LABELS.flatMap((macro) => macro.icon === void 0 ? [] : [[macro.id, macro.icon]]));
|
|
30587
30718
|
new Set(["devices", "classes"]);
|
|
30588
30719
|
/**
|
|
30589
30720
|
* TimelapseRule — the STANDALONE scheduled timelapse producer's rule model.
|
package/dist/index.mjs
CHANGED
|
@@ -13064,11 +13064,33 @@ var NotificationFormatSchema = _enum([
|
|
|
13064
13064
|
* Named by INTENT, never by glyph. "check" would tie the vocabulary to one
|
|
13065
13065
|
* renderer's icon set; "acknowledge" survives an adapter that draws it
|
|
13066
13066
|
* differently.
|
|
13067
|
+
*
|
|
13068
|
+
* ── A TOKEN IS NOT A WIRE VALUE ─────────────────────────────────────
|
|
13069
|
+
*
|
|
13070
|
+
* These names are for US. **No adapter may forward one verbatim.** Each maps
|
|
13071
|
+
* the whole set onto its own renderer's vocabulary through a
|
|
13072
|
+
* `Record<NotificationActionIcon, string>` — a Record, never a lookup with a
|
|
13073
|
+
* fallback, so adding a member here fails every adapter's build until someone
|
|
13074
|
+
* decides its glyph, which is the only place that decision can be made
|
|
13075
|
+
* honestly.
|
|
13076
|
+
*
|
|
13077
|
+
* This paragraph is the bug. Zentik declared `actionIcons: true` and passed
|
|
13078
|
+
* `disarm` straight through; iOS feeds that string to
|
|
13079
|
+
* `UNNotificationActionIcon(systemImageName:)`, `disarm` is not an SF Symbol,
|
|
13080
|
+
* and every snooze and alarm button arrived BLANK. A pass-through is not a
|
|
13081
|
+
* mapping, and "the field is documented" is not "the value renders".
|
|
13082
|
+
*
|
|
13083
|
+
* Adding a member is TRAIN-BOUND. The enum lives in the published
|
|
13084
|
+
* `@camstack/server` closure and the cap seam validates against the HUB's copy,
|
|
13085
|
+
* so an addon that emits a token the running hub does not know does not lose an
|
|
13086
|
+
* icon — its whole `send` fails Zod validation and the notification never
|
|
13087
|
+
* arrives. Never emit a new token from an addon before the train carrying it.
|
|
13067
13088
|
*/
|
|
13068
13089
|
var NotificationActionIconSchema = _enum([
|
|
13069
13090
|
"acknowledge",
|
|
13070
13091
|
"dismiss",
|
|
13071
13092
|
"silence",
|
|
13093
|
+
"snooze",
|
|
13072
13094
|
"view",
|
|
13073
13095
|
"play",
|
|
13074
13096
|
"open",
|
|
@@ -13076,9 +13098,13 @@ var NotificationActionIconSchema = _enum([
|
|
|
13076
13098
|
"lock",
|
|
13077
13099
|
"unlock",
|
|
13078
13100
|
"arm",
|
|
13101
|
+
"arm-home",
|
|
13102
|
+
"arm-away",
|
|
13103
|
+
"arm-night",
|
|
13079
13104
|
"disarm",
|
|
13080
13105
|
"light",
|
|
13081
|
-
"alert"
|
|
13106
|
+
"alert",
|
|
13107
|
+
"camera"
|
|
13082
13108
|
]);
|
|
13083
13109
|
/** A single tap-through action button. */
|
|
13084
13110
|
var NotificationActionSchema = object({
|
|
@@ -13094,7 +13120,23 @@ var NotificationActionSchema = object({
|
|
|
13094
13120
|
* else — see `notification-center/action-token.ts` for what that does and
|
|
13095
13121
|
* does not buy.
|
|
13096
13122
|
*/
|
|
13097
|
-
destructive: boolean().optional()
|
|
13123
|
+
destructive: boolean().optional(),
|
|
13124
|
+
/**
|
|
13125
|
+
* How the tap should REACH the url.
|
|
13126
|
+
*
|
|
13127
|
+
* `navigate` (absent, and every button authored before this field) opens it:
|
|
13128
|
+
* the phone leaves the notification and shows whatever the callback returns.
|
|
13129
|
+
* That is right for a button whose answer the operator wants to read.
|
|
13130
|
+
*
|
|
13131
|
+
* `background` fires it as a POST and stays put. It exists for the buttons
|
|
13132
|
+
* whose whole point is not to interrupt — "silence this for 30 minutes" is
|
|
13133
|
+
* an answer to the notification, and being thrown into a browser tab to
|
|
13134
|
+
* confirm it costs more attention than the notification did. A backend that
|
|
13135
|
+
* cannot do a background call renders it as an ordinary link (the adapters
|
|
13136
|
+
* fall back rather than dropping the button), so this is a preference, never
|
|
13137
|
+
* a requirement.
|
|
13138
|
+
*/
|
|
13139
|
+
mode: _enum(["navigate", "background"]).optional()
|
|
13098
13140
|
});
|
|
13099
13141
|
/**
|
|
13100
13142
|
* The canonical notification. `body` is the only hard field (Apprise model).
|
|
@@ -13262,6 +13304,24 @@ method(object({}), array(TargetKindSchema)), method(object({}), array(TargetSche
|
|
|
13262
13304
|
targetId: string(),
|
|
13263
13305
|
enabled: boolean()
|
|
13264
13306
|
}), _void(), { kind: "mutation" });
|
|
13307
|
+
new Set([
|
|
13308
|
+
{
|
|
13309
|
+
id: "person",
|
|
13310
|
+
name: "Person"
|
|
13311
|
+
},
|
|
13312
|
+
{
|
|
13313
|
+
id: "vehicle",
|
|
13314
|
+
name: "Vehicle"
|
|
13315
|
+
},
|
|
13316
|
+
{
|
|
13317
|
+
id: "animal",
|
|
13318
|
+
name: "Animal"
|
|
13319
|
+
},
|
|
13320
|
+
{
|
|
13321
|
+
id: "package",
|
|
13322
|
+
name: "Package"
|
|
13323
|
+
}
|
|
13324
|
+
].map((l) => l.id));
|
|
13265
13325
|
var COCO_TO_MACRO = {
|
|
13266
13326
|
mapping: {
|
|
13267
13327
|
person: "person",
|
|
@@ -14059,6 +14119,8 @@ var NcSystemEventKindSchema = _enum([
|
|
|
14059
14119
|
"alarm-triggered",
|
|
14060
14120
|
"alarm-armed",
|
|
14061
14121
|
"alarm-disarmed",
|
|
14122
|
+
"alarm-arming",
|
|
14123
|
+
"alarm-arm-refused",
|
|
14062
14124
|
"camera-online",
|
|
14063
14125
|
"camera-offline",
|
|
14064
14126
|
"camera-disabled",
|
|
@@ -14095,6 +14157,9 @@ var NcSystemEventConditionSchema = object({
|
|
|
14095
14157
|
nodeIds: array(string().min(1)).min(1).optional(),
|
|
14096
14158
|
packageNames: array(string().min(1)).min(1).optional()
|
|
14097
14159
|
});
|
|
14160
|
+
/** Hard ceiling on a window (24h). A snooze that could not expire would be an
|
|
14161
|
+
* outage the operator asked for once and forgot. */
|
|
14162
|
+
var NC_SNOOZE_MAX_MINUTES = 1440;
|
|
14098
14163
|
/** Weekly schedule — OR of windows; absence on the rule = always active. */
|
|
14099
14164
|
var NcScheduleSchema = object({
|
|
14100
14165
|
windows: array(object({
|
|
@@ -14471,15 +14536,15 @@ var NcConditionsSchema = object({
|
|
|
14471
14536
|
* (an `immediate` rule naming an `audio-*` class, one notification per
|
|
14472
14537
|
* classified sample) stays exactly as it was for rules that already use it.
|
|
14473
14538
|
*
|
|
14474
|
-
*
|
|
14475
|
-
* rather than an
|
|
14476
|
-
* (`camstack/src/data/notification-center.ts`, guarded by
|
|
14477
|
-
* `scripts/check-viewer-condition-mirror.ts`) and its rule editor
|
|
14539
|
+
* In {@link NC_CONDITION_CATALOG} since P2, and the ORDER it got there is the
|
|
14540
|
+
* rule rather than an accident: the viewer mirrors the descriptor enums BY
|
|
14541
|
+
* HAND (`camstack/src/data/notification-center.ts`, guarded by
|
|
14542
|
+
* `scripts/check-viewer-condition-mirror.ts`) and its rule editor strips the
|
|
14478
14543
|
* condition fields it does not know when a rule is saved from the phone.
|
|
14479
14544
|
* Publishing an editor for a condition the app cannot round-trip is how an
|
|
14480
|
-
* operator loses a rule's conditions by opening it — so the
|
|
14481
|
-
*
|
|
14482
|
-
*
|
|
14545
|
+
* operator loses a rule's conditions by opening it — so the viewer mirror
|
|
14546
|
+
* (P3, shipped) went FIRST, and the descriptor an editor renders from
|
|
14547
|
+
* follows here.
|
|
14483
14548
|
*/
|
|
14484
14549
|
audio: NcAudioConditionSchema.optional()
|
|
14485
14550
|
});
|
|
@@ -14715,6 +14780,30 @@ var NcRuleInputSchema = object({
|
|
|
14715
14780
|
*/
|
|
14716
14781
|
snoozeAllowGlobal: boolean().optional(),
|
|
14717
14782
|
/**
|
|
14783
|
+
* The snooze durations THIS rule's notification offers as buttons, in
|
|
14784
|
+
* minutes.
|
|
14785
|
+
*
|
|
14786
|
+
* Three states, and all three are distinct — which is exactly why this is
|
|
14787
|
+
* `.optional()` and never `.default()`. A Zod default does not run on the
|
|
14788
|
+
* addon cap path (three production failures in one day), so a schema default
|
|
14789
|
+
* would collapse the first two:
|
|
14790
|
+
*
|
|
14791
|
+
* | value | meaning |
|
|
14792
|
+
* | --- | --- |
|
|
14793
|
+
* | absent | the operator never said ⇒ {@link NC_DEFAULT_SNOOZE_MINUTES} |
|
|
14794
|
+
* | `[]` | **no snooze buttons on this rule** — the explicit override |
|
|
14795
|
+
* | a list | these choices, de-duplicated and sorted, at most four |
|
|
14796
|
+
*
|
|
14797
|
+
* `.max(4)` because the notifier's own action budget is small (ntfy allows
|
|
14798
|
+
* three buttons in total) and a rule that spent it all on snooze choices
|
|
14799
|
+
* would push its own tap-through actions off the notification.
|
|
14800
|
+
*
|
|
14801
|
+
* An empty list is NOT an alarm exemption: a rule the alarm is about, or
|
|
14802
|
+
* that arms the panel, is exempt automatically and cannot be silenced by a
|
|
14803
|
+
* window from anywhere (D133).
|
|
14804
|
+
*/
|
|
14805
|
+
snoozeOptions: array(number().int().min(1).max(NC_SNOOZE_MAX_MINUTES)).max(4).optional(),
|
|
14806
|
+
/**
|
|
14718
14807
|
* Devices this rule ACTUATES — arm the alarm, open a gate, turn on a light.
|
|
14719
14808
|
*
|
|
14720
14809
|
* This is what makes the rule set the alarm's trigger set without the alarm
|
|
@@ -14814,6 +14903,7 @@ var NcConditionDescriptorSchema = object({
|
|
|
14814
14903
|
"device",
|
|
14815
14904
|
"package",
|
|
14816
14905
|
"occupancy",
|
|
14906
|
+
"audio",
|
|
14817
14907
|
"system"
|
|
14818
14908
|
]),
|
|
14819
14909
|
label: string(),
|
|
@@ -14832,6 +14922,7 @@ var NcConditionDescriptorSchema = object({
|
|
|
14832
14922
|
"crossingSelect",
|
|
14833
14923
|
"polygonDraw",
|
|
14834
14924
|
"occupancy",
|
|
14925
|
+
"audio",
|
|
14835
14926
|
"deviceState",
|
|
14836
14927
|
"systemEvent"
|
|
14837
14928
|
]),
|
|
@@ -14983,7 +15074,20 @@ var NcSnoozeInputSchema = object({
|
|
|
14983
15074
|
ruleId: string().optional(),
|
|
14984
15075
|
/** Required when `scope: 'device'`. */
|
|
14985
15076
|
deviceId: number().int().optional(),
|
|
14986
|
-
|
|
15077
|
+
/**
|
|
15078
|
+
* Narrow the window to these subject classes — "the cat, not the person".
|
|
15079
|
+
*
|
|
15080
|
+
* ORTHOGONAL to `scope`, deliberately, and absent means EVERY class: that is
|
|
15081
|
+
* what every window authored before this field meant, so no persisted row
|
|
15082
|
+
* changes meaning and no client has to learn anything to keep working.
|
|
15083
|
+
*
|
|
15084
|
+
* It is what makes the window's real key `(deviceId, classes[])` and lets it
|
|
15085
|
+
* cross rules (D133): the operator points at a camera and a kind of thing,
|
|
15086
|
+
* not at whichever of their four rules happened to produce the notification
|
|
15087
|
+
* they are dismissing.
|
|
15088
|
+
*/
|
|
15089
|
+
classes: array(string().min(1)).min(1).optional(),
|
|
15090
|
+
durationMinutes: number().int().min(1).max(NC_SNOOZE_MAX_MINUTES),
|
|
14987
15091
|
/**
|
|
14988
15092
|
* Silence this for EVERY recipient, not just the caller. Permission is
|
|
14989
15093
|
* checked server-side (the rule's `snoozeAllowGlobal`, or admin for the
|
|
@@ -15008,6 +15112,10 @@ var NcSnoozeSchema = object({
|
|
|
15008
15112
|
scope: NcSnoozeScopeSchema,
|
|
15009
15113
|
ruleId: string().optional(),
|
|
15010
15114
|
deviceId: number().int().optional(),
|
|
15115
|
+
/** Subject classes this window covers. ABSENT = every class — see
|
|
15116
|
+
* {@link NcSnoozeInputSchema.shape.classes}. Lives in the JSON blob and has
|
|
15117
|
+
* no SQLite column: nothing queries a window by class. */
|
|
15118
|
+
classes: array(string().min(1)).min(1).optional(),
|
|
15011
15119
|
startedAt: number(),
|
|
15012
15120
|
/** Exclusive: at exactly this instant the snooze is over. Expiry is a
|
|
15013
15121
|
* COMPARISON, not a job — no sweeper can leave the operator silenced. */
|
|
@@ -17245,6 +17353,22 @@ var detectionFpsField = {
|
|
|
17245
17353
|
default: 10,
|
|
17246
17354
|
step: 1
|
|
17247
17355
|
};
|
|
17356
|
+
/**
|
|
17357
|
+
* The occupancy re-check interval. DEFAULT 300 s (2026-08-13 — was 30 s).
|
|
17358
|
+
*
|
|
17359
|
+
* The recheck is now on by default (a parked car is invisible to occupancy
|
|
17360
|
+
* rules until the stationary registry has been rebuilt by motion, which after a
|
|
17361
|
+
* restart may be never on a quiet camera). Each cycle re-subscribes a detection
|
|
17362
|
+
* session — an RTSP re-dial — so the switch is only affordable at a WIDE
|
|
17363
|
+
* interval: 300 s is ~12 re-dials an hour per camera, against 120 at the old
|
|
17364
|
+
* 30 s. A parked car is therefore counted within 5 minutes of a restart.
|
|
17365
|
+
*
|
|
17366
|
+
* Why not wider: `max` is 300 and raising it is TRAIN-BOUND, not addon-bound —
|
|
17367
|
+
* the host validates `attachCamera` against ITS copy of this schema, so a
|
|
17368
|
+
* runner asked for 600 would be rejected by the hub until a `@camstack/server`
|
|
17369
|
+
* carrying the wider bound is installed everywhere. 300 is the widest value
|
|
17370
|
+
* that ships with an addon deploy.
|
|
17371
|
+
*/
|
|
17248
17372
|
var occupancyRecheckSecField = {
|
|
17249
17373
|
min: 0,
|
|
17250
17374
|
max: 300,
|
|
@@ -17446,15 +17570,21 @@ var RunnerCameraConfigSchema = object({
|
|
|
17446
17570
|
*/
|
|
17447
17571
|
onboardMotionDrivesAnalyzer: boolean().default(true),
|
|
17448
17572
|
/**
|
|
17449
|
-
* Master toggle for the occupancy re-check. When `false`
|
|
17450
|
-
*
|
|
17451
|
-
* this is off by default because the recheck re-subscribes a detection session
|
|
17452
|
-
* every N seconds while `watching`, a major source of pull-decoder re-dial
|
|
17453
|
-
* churn (each cycle creates+tears a session → RTSP re-dial → latency). The
|
|
17573
|
+
* Master toggle for the occupancy re-check. When `false` the runner never arms
|
|
17574
|
+
* the periodic recheck timer, regardless of `occupancyRecheckSec`; the
|
|
17454
17575
|
* `occupancyRecheckSec` / `occupancyRecheckFrames` sliders only take effect
|
|
17455
17576
|
* (and only render) when this is enabled.
|
|
17456
|
-
|
|
17457
|
-
|
|
17577
|
+
*
|
|
17578
|
+
* DEFAULT `true` since 2026-08-13 (was `false`). It was off because the
|
|
17579
|
+
* recheck re-subscribes a detection session every N seconds while `watching`
|
|
17580
|
+
* — each cycle creates+tears a session ⇒ an RTSP re-dial ⇒ latency, a major
|
|
17581
|
+
* pull-decoder churn source. What that bought was a blind spot: a STATIONARY
|
|
17582
|
+
* object is counted only while the stationary registry holds it, and the
|
|
17583
|
+
* registry rebuilds from motion, so after a restart a parked car was invisible
|
|
17584
|
+
* to every occupancy rule until something moved in front of it. The churn is
|
|
17585
|
+
* now paid on the interval instead — see `occupancyRecheckSecField`.
|
|
17586
|
+
*/
|
|
17587
|
+
occupancyRecheckEnabled: boolean().default(true),
|
|
17458
17588
|
occupancyRecheckSec: number().min(occupancyRecheckSecField.min).max(occupancyRecheckSecField.max).default(occupancyRecheckSecField.default),
|
|
17459
17589
|
occupancyRecheckFrames: number().min(occupancyRecheckFramesField.min).max(occupancyRecheckFramesField.max).default(occupancyRecheckFramesField.default),
|
|
17460
17590
|
/**
|
|
@@ -30580,6 +30710,7 @@ Object.freeze({
|
|
|
30580
30710
|
"network-access": "ingress",
|
|
30581
30711
|
"smtp-provider": "email"
|
|
30582
30712
|
});
|
|
30713
|
+
new Map(AUDIO_MACRO_LABELS.flatMap((macro) => macro.icon === void 0 ? [] : [[macro.id, macro.icon]]));
|
|
30583
30714
|
new Set(["devices", "classes"]);
|
|
30584
30715
|
/**
|
|
30585
30716
|
* TimelapseRule — the STANDALONE scheduled timelapse producer's rule model.
|