@camstack/server 1.2.915 → 1.2.917
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/CHANGELOG.md +12 -0
- package/package.json +9 -8
- package/system/dist/builtins/addon-pages-aggregator/addon-pages-aggregator.addon.js +1 -1
- package/system/dist/builtins/addon-pages-aggregator/addon-pages-aggregator.addon.mjs +1 -1
- package/system/dist/builtins/addon-widgets-aggregator/addon-widgets-aggregator.addon.js +1 -1
- package/system/dist/builtins/addon-widgets-aggregator/addon-widgets-aggregator.addon.mjs +1 -1
- package/system/dist/builtins/alerts/alerts.addon.js +1 -1
- package/system/dist/builtins/alerts/alerts.addon.mjs +1 -1
- package/system/dist/builtins/autotrack/index.js +1 -1
- package/system/dist/builtins/autotrack/index.mjs +1 -1
- package/system/dist/builtins/backup-orchestrator/backup-orchestrator.addon.js +2 -2
- package/system/dist/builtins/backup-orchestrator/backup-orchestrator.addon.mjs +2 -2
- package/system/dist/builtins/calendars/calendars.addon.js +1 -1
- package/system/dist/builtins/calendars/calendars.addon.mjs +1 -1
- package/system/dist/builtins/camera-grid/grid-blocks.d.ts +14 -3
- package/system/dist/builtins/camera-grid/index.js +35 -7
- package/system/dist/builtins/camera-grid/index.mjs +35 -7
- package/system/dist/builtins/composer/composed-device.d.ts +2 -1
- package/system/dist/builtins/composer/composer.addon.js +13 -7
- package/system/dist/builtins/composer/composer.addon.mjs +13 -7
- package/system/dist/builtins/console-logging/index.js +1 -1
- package/system/dist/builtins/console-logging/index.mjs +1 -1
- package/system/dist/builtins/core-blocks/core-blocks.addon.js +4 -4
- package/system/dist/builtins/core-blocks/core-blocks.addon.mjs +4 -4
- package/system/dist/builtins/device-history/device-history.addon.js +2 -2
- package/system/dist/builtins/device-history/device-history.addon.mjs +2 -2
- package/system/dist/builtins/device-manager/device-manager.addon.js +2 -2
- package/system/dist/builtins/device-manager/device-manager.addon.mjs +2 -2
- package/system/dist/builtins/hub-forwarder/index.js +1 -1
- package/system/dist/builtins/hub-forwarder/index.mjs +1 -1
- package/system/dist/builtins/keychain/index.js +4 -4
- package/system/dist/builtins/keychain/index.mjs +4 -4
- package/system/dist/builtins/liveness-monitor/liveness-monitor.addon.js +1 -1
- package/system/dist/builtins/liveness-monitor/liveness-monitor.addon.mjs +1 -1
- package/system/dist/builtins/local-auth/local-auth.addon.js +2 -2
- package/system/dist/builtins/local-auth/local-auth.addon.mjs +2 -2
- package/system/dist/builtins/local-network/local-network.addon.js +3 -3
- package/system/dist/builtins/local-network/local-network.addon.mjs +3 -3
- package/system/dist/builtins/loki-logging/index.js +1 -1
- package/system/dist/builtins/loki-logging/index.mjs +1 -1
- package/system/dist/builtins/native-metrics/native-metrics.addon.js +1 -1
- package/system/dist/builtins/native-metrics/native-metrics.addon.mjs +1 -1
- package/system/dist/builtins/platform-probe/index.js +1 -1
- package/system/dist/builtins/platform-probe/index.mjs +1 -1
- package/system/dist/builtins/record-entries/index.js +1 -1
- package/system/dist/builtins/record-entries/index.mjs +1 -1
- package/system/dist/builtins/remote-access-orchestrator/remote-access-orchestrator.addon.js +1 -1
- package/system/dist/builtins/remote-access-orchestrator/remote-access-orchestrator.addon.mjs +1 -1
- package/system/dist/builtins/snapshot/index.js +1 -1
- package/system/dist/builtins/snapshot/index.mjs +1 -1
- package/system/dist/builtins/sqlite-storage/filesystem-storage.addon.js +1 -1
- package/system/dist/builtins/sqlite-storage/filesystem-storage.addon.mjs +1 -1
- package/system/dist/builtins/sqlite-storage/index.js +1 -1
- package/system/dist/builtins/sqlite-storage/index.mjs +1 -1
- package/system/dist/builtins/sqlite-storage/sqlite-settings.addon.js +3 -3
- package/system/dist/builtins/sqlite-storage/sqlite-settings.addon.mjs +3 -3
- package/system/dist/builtins/storage-orchestrator/storage-orchestrator.addon.js +1 -1
- package/system/dist/builtins/storage-orchestrator/storage-orchestrator.addon.mjs +1 -1
- package/system/dist/builtins/system-config/system-config.addon.js +3 -3
- package/system/dist/builtins/system-config/system-config.addon.mjs +284 -284
- package/system/dist/builtins/winston-logging/index.js +1 -1
- package/system/dist/builtins/winston-logging/index.mjs +1 -1
- package/system/dist/{capture-engine-DqV_6SjI.mjs → capture-engine-DgO-N5FL.mjs} +1 -1
- package/system/dist/{capture-engine-dVNf2nq-.js → capture-engine-UNTcSBiF.js} +1 -1
- package/system/dist/{composition-sources-DNxi-fAK.mjs → composition-sources-AfSwY0mW.mjs} +1 -1
- package/system/dist/{composition-sources-BQcauNTH.js → composition-sources-Df52Wv0k.js} +1 -1
- package/system/dist/{constants-H2BU7bKi.js → constants-D5nE68R-.js} +1 -1
- package/system/dist/{constants-DtDAChDX.mjs → constants-Z-nqQ-0f.mjs} +1 -1
- package/system/dist/{device-ca-C82s8Xw9.mjs → device-ca-BqqBJ5Ft.mjs} +1 -1
- package/system/dist/{device-ca-QMMiXnOk.js → device-ca-Cn9FRko2.js} +1 -1
- package/system/dist/{dist-CLuvQ9u4.mjs → dist-CftbsT6r.mjs} +21 -5
- package/system/dist/{dist-DOO4m7fK.js → dist-DxBWhuSc.js} +21 -5
- package/system/dist/file-host-worker.js +1 -1
- package/system/dist/file-host-worker.mjs +1 -1
- package/system/dist/{hub-identity-Dau33k9T.mjs → hub-identity-D_lD6udf.mjs} +1 -1
- package/system/dist/{hub-identity-B1vdrP8l.js → hub-identity-Db7fve3f.js} +1 -1
- package/system/dist/{hub-mdns-ciao-Nso1_VSE.js → hub-mdns-ciao-CK1mWOyO.js} +2 -2
- package/system/dist/{hub-mdns-ciao-RwTNfZHU.mjs → hub-mdns-ciao-DX6jDD_d.mjs} +2 -2
- package/system/dist/index.js +8 -8
- package/system/dist/index.mjs +8 -8
- package/system/dist/{legacy-integration-rows-door-Dxd0ZeQK.js → legacy-integration-rows-door-COSfBe0d.js} +1 -1
- package/system/dist/{legacy-integration-rows-door-C9-7B5gC.mjs → legacy-integration-rows-door-CsYIwKtO.mjs} +1 -1
- package/system/dist/{rename-composition-block-YCjuAytZ.js → rename-composition-block-CaZBnU9O.js} +1 -1
- package/system/dist/{rename-composition-block-MfJE4XCv.mjs → rename-composition-block-CcCjR2ZX.mjs} +1 -1
- package/system/dist/{restore-archive-BuQCaCvL.mjs → restore-archive-BRPFibpR.mjs} +82 -82
- package/system/dist/{restore-archive-BbZAaTDV.js → restore-archive-D-0Jq9fY.js} +1 -1
- package/system/dist/{wal-maintenance-BUD6zNQ1.mjs → wal-maintenance-BdNZFRV8.mjs} +0 -0
- package/system/dist/{wal-maintenance-CSOuhN9-.js → wal-maintenance-lUBLKZVQ.js} +0 -0
- package/system/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -7,6 +7,18 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
7
7
|
|
|
8
8
|
## [Unreleased]
|
|
9
9
|
|
|
10
|
+
## [1.2.917] - 2026-11-20
|
|
11
|
+
|
|
12
|
+
### Changed
|
|
13
|
+
|
|
14
|
+
- Rebuilt against updated dependencies.
|
|
15
|
+
|
|
16
|
+
## [1.2.916] - 2026-11-20
|
|
17
|
+
|
|
18
|
+
### Changed
|
|
19
|
+
|
|
20
|
+
- The camera-grid engine hosts crop cameras: a crop is a derived camera showing one section of a source, with the grid's 1:1 profiles and detection mapping.
|
|
21
|
+
|
|
10
22
|
## [1.2.915] - 2026-11-20
|
|
11
23
|
|
|
12
24
|
### Changed
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@camstack/server",
|
|
3
|
-
"version": "1.2.
|
|
3
|
+
"version": "1.2.917",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -66,9 +66,10 @@
|
|
|
66
66
|
],
|
|
67
67
|
"requires": {
|
|
68
68
|
"addons": {
|
|
69
|
-
"@camstack/addon-admin-ui": ">=1.2.
|
|
70
|
-
"@camstack/addon-agent-ui": ">=1.2.
|
|
71
|
-
"@camstack/addon-provider-
|
|
69
|
+
"@camstack/addon-admin-ui": ">=1.2.715",
|
|
70
|
+
"@camstack/addon-agent-ui": ">=1.2.419",
|
|
71
|
+
"@camstack/addon-provider-homeassistant": ">=1.2.698",
|
|
72
|
+
"@camstack/addon-provider-reolink": ">=1.2.250"
|
|
72
73
|
},
|
|
73
74
|
"wrapper": {
|
|
74
75
|
"desktop": ">=0.0.1",
|
|
@@ -77,8 +78,8 @@
|
|
|
77
78
|
}
|
|
78
79
|
},
|
|
79
80
|
"dependencies": {
|
|
80
|
-
"@camstack/addon-admin-ui": "1.2.
|
|
81
|
-
"@camstack/addon-agent-ui": "1.2.
|
|
81
|
+
"@camstack/addon-admin-ui": "1.2.715",
|
|
82
|
+
"@camstack/addon-agent-ui": "1.2.419",
|
|
82
83
|
"@camstack/addon-auth": "1.2.182",
|
|
83
84
|
"@camstack/addon-benchmark": "1.2.313",
|
|
84
85
|
"@camstack/addon-decoder-nodeav": "1.2.149",
|
|
@@ -88,8 +89,8 @@
|
|
|
88
89
|
"@camstack/addon-post-analysis": "1.2.718",
|
|
89
90
|
"@camstack/develop": "0.1.55",
|
|
90
91
|
"@camstack/sdk": "1.2.159",
|
|
91
|
-
"@camstack/types": "1.2.
|
|
92
|
-
"@camstack/ui-library": "1.2.
|
|
92
|
+
"@camstack/types": "1.2.607",
|
|
93
|
+
"@camstack/ui-library": "1.2.481",
|
|
93
94
|
"@fastify/compress": "^9.0.0",
|
|
94
95
|
"@fastify/cookie": "^11.0.2",
|
|
95
96
|
"@fastify/cors": "^11.2.0",
|
|
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
|
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
5
|
const require_chunk = require("../../chunk-Cek0wNdY.js");
|
|
6
|
-
const require_dist = require("../../dist-
|
|
6
|
+
const require_dist = require("../../dist-DxBWhuSc.js");
|
|
7
7
|
const require_settle_sources = require("../../settle-sources-Bhsy57y-.js");
|
|
8
8
|
let node_crypto = require("node:crypto");
|
|
9
9
|
let node_fs = require("node:fs");
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Cc as BaseAddon, Du as errMsg, Rn as addonPagesCapability, ku as EventCategory } from "../../dist-
|
|
1
|
+
import { Cc as BaseAddon, Du as errMsg, Rn as addonPagesCapability, ku as EventCategory } from "../../dist-CftbsT6r.mjs";
|
|
2
2
|
import { t as settleSourcesWithTimeout } from "../../settle-sources-CDtNC8ub.mjs";
|
|
3
3
|
import { createHash, randomUUID } from "node:crypto";
|
|
4
4
|
import * as fs$1 from "node:fs";
|
|
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
|
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
5
|
const require_chunk = require("../../chunk-Cek0wNdY.js");
|
|
6
|
-
const require_dist = require("../../dist-
|
|
6
|
+
const require_dist = require("../../dist-DxBWhuSc.js");
|
|
7
7
|
const require_settle_sources = require("../../settle-sources-Bhsy57y-.js");
|
|
8
8
|
let node_crypto = require("node:crypto");
|
|
9
9
|
let node_fs = require("node:fs");
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Bn as addonWidgetsCapability, Cc as BaseAddon, Du as errMsg, ku as EventCategory } from "../../dist-
|
|
1
|
+
import { Bn as addonWidgetsCapability, Cc as BaseAddon, Du as errMsg, ku as EventCategory } from "../../dist-CftbsT6r.mjs";
|
|
2
2
|
import { t as settleSourcesWithTimeout } from "../../settle-sources-CDtNC8ub.mjs";
|
|
3
3
|
import { createHash, randomUUID } from "node:crypto";
|
|
4
4
|
import * as fs$1 from "node:fs";
|
|
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
|
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
5
|
const require_chunk = require("../../chunk-Cek0wNdY.js");
|
|
6
|
-
const require_dist = require("../../dist-
|
|
6
|
+
const require_dist = require("../../dist-DxBWhuSc.js");
|
|
7
7
|
const require_read_all_rows$1 = require("../../read-all-rows-CVoO1ONM.js");
|
|
8
8
|
const require_log_redactor = require("../../log-redactor-BhIEMaG9.js");
|
|
9
9
|
let node_fs = require("node:fs");
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Bi as isAlertEpisodeSeverity, Cc as BaseAddon, Du as errMsg, E as CORE_BLOCK_ADDON_PREFIX, Hn as alertEpisodePayload, Tl as defineRecordKinds, Un as alertsCapability, Vn as alertEpisodeId, bl as createEvent, ku as EventCategory, p as AlertSchema, zi as isAlertEpisodeOpen } from "../../dist-
|
|
1
|
+
import { Bi as isAlertEpisodeSeverity, Cc as BaseAddon, Du as errMsg, E as CORE_BLOCK_ADDON_PREFIX, Hn as alertEpisodePayload, Tl as defineRecordKinds, Un as alertsCapability, Vn as alertEpisodeId, bl as createEvent, ku as EventCategory, p as AlertSchema, zi as isAlertEpisodeOpen } from "../../dist-CftbsT6r.mjs";
|
|
2
2
|
import { t as require_read_all_rows } from "../../read-all-rows-TaPqdWNF.mjs";
|
|
3
3
|
import { a as redactLogText } from "../../log-redactor-XLDrPzOi.mjs";
|
|
4
4
|
import * as fs$1 from "node:fs";
|
|
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
|
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
5
|
require("../../chunk-Cek0wNdY.js");
|
|
6
|
-
const require_dist = require("../../dist-
|
|
6
|
+
const require_dist = require("../../dist-DxBWhuSc.js");
|
|
7
7
|
let zod = require("zod");
|
|
8
8
|
//#region src/builtins/autotrack/autotrack-config.ts
|
|
9
9
|
var DEFAULT_AUTOTRACK_LOOP_CONFIG = {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Bl as isEvent, Cc as BaseAddon, Du as errMsg, Yn as bareAddonId, ht as FIRST_LEVEL_MACRO_CLASSES, io as ptzAutotrackCapability, ku as EventCategory } from "../../dist-
|
|
1
|
+
import { Bl as isEvent, Cc as BaseAddon, Du as errMsg, Yn as bareAddonId, ht as FIRST_LEVEL_MACRO_CLASSES, io as ptzAutotrackCapability, ku as EventCategory } from "../../dist-CftbsT6r.mjs";
|
|
2
2
|
import { z } from "zod";
|
|
3
3
|
//#region src/builtins/autotrack/autotrack-config.ts
|
|
4
4
|
var DEFAULT_AUTOTRACK_LOOP_CONFIG = {
|
|
@@ -3,9 +3,9 @@ Object.defineProperties(exports, {
|
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
5
|
const require_chunk = require("../../chunk-Cek0wNdY.js");
|
|
6
|
-
const require_dist = require("../../dist-
|
|
6
|
+
const require_dist = require("../../dist-DxBWhuSc.js");
|
|
7
7
|
const require_read_all_rows$1 = require("../../read-all-rows-CVoO1ONM.js");
|
|
8
|
-
const require_restore_archive = require("../../restore-archive-
|
|
8
|
+
const require_restore_archive = require("../../restore-archive-D-0Jq9fY.js");
|
|
9
9
|
let node_crypto = require("node:crypto");
|
|
10
10
|
let node_fs = require("node:fs");
|
|
11
11
|
node_fs = require_chunk.__toESM(node_fs);
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { Cc as BaseAddon, Jn as backupCapability, Ql as nodePin, gu as toNodeId, ku as EventCategory, ss as storageOccupancyCapability, va as mayWriteToLocation } from "../../dist-
|
|
1
|
+
import { Cc as BaseAddon, Jn as backupCapability, Ql as nodePin, gu as toNodeId, ku as EventCategory, ss as storageOccupancyCapability, va as mayWriteToLocation } from "../../dist-CftbsT6r.mjs";
|
|
2
2
|
import { t as require_read_all_rows } from "../../read-all-rows-TaPqdWNF.mjs";
|
|
3
|
-
import { _ as backupRecordStoresOf, a as BackupSnapshotRefusedError, d as ENCRYPTED_BACKUP_SUFFIX, f as generateBackupKeyPair, g as backupOrchestratorRecordKinds, i as BackupCancelledError, l as BackupKeyFormatError, m as parseBackupSecretKey, n as precheckRestoreKey, o as DEFAULT_BACKUP_DATABASES, p as parseBackupPublicKey, r as prepareRestoreArchive, s as SystemBackupService } from "../../restore-archive-
|
|
3
|
+
import { _ as backupRecordStoresOf, a as BackupSnapshotRefusedError, d as ENCRYPTED_BACKUP_SUFFIX, f as generateBackupKeyPair, g as backupOrchestratorRecordKinds, i as BackupCancelledError, l as BackupKeyFormatError, m as parseBackupSecretKey, n as precheckRestoreKey, o as DEFAULT_BACKUP_DATABASES, p as parseBackupPublicKey, r as prepareRestoreArchive, s as SystemBackupService } from "../../restore-archive-BRPFibpR.mjs";
|
|
4
4
|
import { randomUUID } from "node:crypto";
|
|
5
5
|
import * as fs$1 from "node:fs";
|
|
6
6
|
import * as path$1 from "node:path";
|
|
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
|
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
5
|
require("../../chunk-Cek0wNdY.js");
|
|
6
|
-
const require_dist = require("../../dist-
|
|
6
|
+
const require_dist = require("../../dist-DxBWhuSc.js");
|
|
7
7
|
const require_settle_sources = require("../../settle-sources-Bhsy57y-.js");
|
|
8
8
|
let zod = require("zod");
|
|
9
9
|
//#region src/builtins/calendars/calendar-color.ts
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Cc as BaseAddon, O as CalendarPreferencesSchema, Tl as defineRecordKinds, ir as calendarsCapability } from "../../dist-
|
|
1
|
+
import { Cc as BaseAddon, O as CalendarPreferencesSchema, Tl as defineRecordKinds, ir as calendarsCapability } from "../../dist-CftbsT6r.mjs";
|
|
2
2
|
import { t as settleSourcesWithTimeout } from "../../settle-sources-CDtNC8ub.mjs";
|
|
3
3
|
import { z } from "zod";
|
|
4
4
|
//#region src/builtins/calendars/calendar-color.ts
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* `(addonId, stableId)`; the compositor addresses them by device id, so a pass
|
|
6
6
|
* resolves one into the other here, and a layout save resolves back.
|
|
7
7
|
*/
|
|
8
|
-
import { type Composition, type CompositionSourceRef, type GridHelperSpec, type GridLayoutCell, type GridProfile } from "@camstack/types";
|
|
8
|
+
import { type Composition, type CompositionSourceRef, type CropHelperSpec, type GridHelperSpec, type GridLayoutCell, type GridProfile } from "@camstack/types";
|
|
9
9
|
export type NormalizedRect = {
|
|
10
10
|
readonly x: number;
|
|
11
11
|
readonly y: number;
|
|
@@ -24,6 +24,17 @@ export interface GridComposition {
|
|
|
24
24
|
readonly publishedProfiles: readonly GridProfile[];
|
|
25
25
|
readonly cells: readonly GridCellConfig[];
|
|
26
26
|
}
|
|
27
|
+
/**
|
|
28
|
+
* The block specs this engine serves. A crop (#611) is a ONE-cell grid: the
|
|
29
|
+
* cell covers the whole canvas and its source rectangle is the crop, so the
|
|
30
|
+
* profiles, the derived canvas, the no-upscale rule and the detection mapping
|
|
31
|
+
* are the grid's, unchanged.
|
|
32
|
+
*/
|
|
33
|
+
export type GridBlockSpec = GridHelperSpec | CropHelperSpec;
|
|
34
|
+
/** The cell of a crop: the whole canvas. */
|
|
35
|
+
export declare const CROP_FULL_CELL: NormalizedRect;
|
|
36
|
+
/** Every source a block reads, in cell order. */
|
|
37
|
+
export declare function gridBlockSourceRefs(spec: GridBlockSpec): readonly CompositionSourceRef[];
|
|
27
38
|
export declare function sourceRefKey(ref: CompositionSourceRef): string;
|
|
28
39
|
/** The cells whose source resolved, and the refs that did not. */
|
|
29
40
|
export interface ResolvedGridCells {
|
|
@@ -35,7 +46,7 @@ export interface ResolvedGridCells {
|
|
|
35
46
|
* out of the composition and NAMED: a deleted camera must not keep the grid
|
|
36
47
|
* from composing the cells that remain.
|
|
37
48
|
*/
|
|
38
|
-
export declare function resolveGridCells(spec:
|
|
49
|
+
export declare function resolveGridCells(spec: GridBlockSpec, deviceIdOf: (ref: CompositionSourceRef) => number | null): ResolvedGridCells;
|
|
39
50
|
/** What a layout save writes: the patch, with each source device named by its identity. */
|
|
40
51
|
export interface GridSpecPatch {
|
|
41
52
|
readonly fps?: number | undefined;
|
|
@@ -48,4 +59,4 @@ export interface GridSpecPatch {
|
|
|
48
59
|
*/
|
|
49
60
|
export declare function gridSpecFromPatch(current: GridHelperSpec, patch: GridSpecPatch, refOf: (deviceId: number) => CompositionSourceRef | null): GridHelperSpec;
|
|
50
61
|
/** The composition a grid spec compiles to — the shape a block of this kind stores. */
|
|
51
|
-
export declare function gridComposition(spec:
|
|
62
|
+
export declare function gridComposition(spec: GridBlockSpec): Composition;
|
|
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
|
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
5
|
require("../../chunk-Cek0wNdY.js");
|
|
6
|
-
const require_dist = require("../../dist-
|
|
6
|
+
const require_dist = require("../../dist-DxBWhuSc.js");
|
|
7
7
|
let zod = require("zod");
|
|
8
8
|
let _camstack_types_node = require("@camstack/types/node");
|
|
9
9
|
let node_fs = require("node:fs");
|
|
@@ -171,6 +171,17 @@ async function acquireWithRetry(attempt, deps) {
|
|
|
171
171
|
* `(addonId, stableId)`; the compositor addresses them by device id, so a pass
|
|
172
172
|
* resolves one into the other here, and a layout save resolves back.
|
|
173
173
|
*/
|
|
174
|
+
/** The cell of a crop: the whole canvas. */
|
|
175
|
+
var CROP_FULL_CELL = {
|
|
176
|
+
x: 0,
|
|
177
|
+
y: 0,
|
|
178
|
+
width: 1,
|
|
179
|
+
height: 1
|
|
180
|
+
};
|
|
181
|
+
/** Every source a block reads, in cell order. */
|
|
182
|
+
function gridBlockSourceRefs(spec) {
|
|
183
|
+
return spec.kind === "crop" ? [spec.source] : spec.cells.map((cell) => cell.source);
|
|
184
|
+
}
|
|
174
185
|
function sourceRefKey(ref) {
|
|
175
186
|
return `${ref.addonId}\u0000${ref.stableId}`;
|
|
176
187
|
}
|
|
@@ -180,6 +191,21 @@ function sourceRefKey(ref) {
|
|
|
180
191
|
* from composing the cells that remain.
|
|
181
192
|
*/
|
|
182
193
|
function resolveGridCells(spec, deviceIdOf) {
|
|
194
|
+
if (spec.kind === "crop") {
|
|
195
|
+
const deviceId = deviceIdOf(spec.source);
|
|
196
|
+
if (deviceId === null) return {
|
|
197
|
+
cells: [],
|
|
198
|
+
unresolved: [spec.source]
|
|
199
|
+
};
|
|
200
|
+
return {
|
|
201
|
+
cells: [{
|
|
202
|
+
deviceId,
|
|
203
|
+
source: spec.rect,
|
|
204
|
+
cell: CROP_FULL_CELL
|
|
205
|
+
}],
|
|
206
|
+
unresolved: []
|
|
207
|
+
};
|
|
208
|
+
}
|
|
183
209
|
const cells = [];
|
|
184
210
|
const unresolved = [];
|
|
185
211
|
for (const cell of spec.cells) {
|
|
@@ -2966,12 +2992,13 @@ var CameraGridAddon = class extends require_dist.BaseAddon {
|
|
|
2966
2992
|
this.ctx.logger.warn("camera grid: the grid blocks could not be read - nothing changes", { meta: { error: require_dist.errMsg(error) } });
|
|
2967
2993
|
return;
|
|
2968
2994
|
}
|
|
2969
|
-
const
|
|
2970
|
-
|
|
2971
|
-
|
|
2995
|
+
const grids = require_dist.selectEngineHostedBlocks("grid", compositions, composerRows);
|
|
2996
|
+
const crops = require_dist.selectEngineHostedBlocks("crop", compositions, composerRows);
|
|
2997
|
+
if (grids.kind === "untrusted" || crops.kind === "untrusted") {
|
|
2998
|
+
this.ctx.logger.info("camera grid: the blocks are not loaded yet - nothing changes", { meta: { reason: grids.kind === "untrusted" ? grids.reason : "not loaded" } });
|
|
2972
2999
|
return;
|
|
2973
3000
|
}
|
|
2974
|
-
const wanted =
|
|
3001
|
+
const wanted = [...grids.blocks, ...crops.blocks].filter((block) => block.enabled);
|
|
2975
3002
|
const { withdraw } = this.withdrawalGate.judge(this.grids.keys(), new Set(wanted.map((block) => block.blockId)));
|
|
2976
3003
|
for (const blockId of withdraw) await this.unhost(blockId, "its block is gone or switched off");
|
|
2977
3004
|
const sources = await this.readSources(wanted);
|
|
@@ -3035,7 +3062,7 @@ var CameraGridAddon = class extends require_dist.BaseAddon {
|
|
|
3035
3062
|
* and named.
|
|
3036
3063
|
*/
|
|
3037
3064
|
layoutOf(block, sources, previous) {
|
|
3038
|
-
if (block.spec.
|
|
3065
|
+
if (gridBlockSourceRefs(block.spec).some((ref) => sources.unreadAddons.has(ref.addonId)) && previous !== null) return {
|
|
3039
3066
|
...previous.layout,
|
|
3040
3067
|
fps: block.spec.fps
|
|
3041
3068
|
};
|
|
@@ -3055,7 +3082,7 @@ var CameraGridAddon = class extends require_dist.BaseAddon {
|
|
|
3055
3082
|
}
|
|
3056
3083
|
/** One indexed read per source addon (`listAll({ addonId })`), never the fleet. */
|
|
3057
3084
|
async readSources(blocks) {
|
|
3058
|
-
const addonIds = new Set(blocks.flatMap((b) => b.spec.
|
|
3085
|
+
const addonIds = new Set(blocks.flatMap((b) => gridBlockSourceRefs(b.spec).map((ref) => ref.addonId)));
|
|
3059
3086
|
const ids = /* @__PURE__ */ new Map();
|
|
3060
3087
|
const unreadAddons = /* @__PURE__ */ new Set();
|
|
3061
3088
|
for (const addonId of addonIds) try {
|
|
@@ -3579,6 +3606,7 @@ var CameraGridAddon = class extends require_dist.BaseAddon {
|
|
|
3579
3606
|
return this.serialized(async () => {
|
|
3580
3607
|
const grid = this.gridForDevice(input.deviceId);
|
|
3581
3608
|
if (grid === null) throw new Error(`camera-grid: device ${String(input.deviceId)} is not a grid camera`);
|
|
3609
|
+
if (grid.block.spec.kind !== "grid") throw new Error(`camera-grid: device ${String(input.deviceId)} is a crop camera - its layout is not a grid's to save`);
|
|
3582
3610
|
const refs = await this.sourceRefs(input.cells.map((cell) => cell.deviceId));
|
|
3583
3611
|
const spec = gridSpecFromPatch(grid.block.spec, input, (id) => refs.get(id) ?? null);
|
|
3584
3612
|
const composition = gridComposition(spec);
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Ai as hostEngineDevice, B as DERIVED_CAMERA_SILENCED_CAP_NAMES, Bt as MOTION_CLOSE_AFTER_MS, Cc as BaseAddon, Du as errMsg, Et as HostedWithdrawalGate, Il as hydrateSchema, Ko as selectEngineHostedBlocks, Lr as declarationOwnerNodeId, Rs as COMPOSER_ADDON_ID, Yn as bareAddonId, ar as cameraGridLayoutCapability, bl as createEvent, br as compileHelper, ds as sweepLegacyEngineRows, ka as motionCapability, ku as EventCategory, ls as streamCatalogCapability, oa as legacySweepDone, qs as buildFfmpegArgs, ts as snapshotCapability, v as BaseDevice, wu as DeviceFeature, xa as memoizePinnedFfmpeg } from "../../dist-
|
|
1
|
+
import { Ai as hostEngineDevice, B as DERIVED_CAMERA_SILENCED_CAP_NAMES, Bt as MOTION_CLOSE_AFTER_MS, Cc as BaseAddon, Du as errMsg, Et as HostedWithdrawalGate, Il as hydrateSchema, Ko as selectEngineHostedBlocks, Lr as declarationOwnerNodeId, Rs as COMPOSER_ADDON_ID, Yn as bareAddonId, ar as cameraGridLayoutCapability, bl as createEvent, br as compileHelper, ds as sweepLegacyEngineRows, ka as motionCapability, ku as EventCategory, ls as streamCatalogCapability, oa as legacySweepDone, qs as buildFfmpegArgs, ts as snapshotCapability, v as BaseDevice, wu as DeviceFeature, xa as memoizePinnedFfmpeg } from "../../dist-CftbsT6r.mjs";
|
|
2
2
|
import { z } from "zod";
|
|
3
3
|
import { FfmpegProcess } from "@camstack/types/node";
|
|
4
4
|
import { promises } from "node:fs";
|
|
@@ -166,6 +166,17 @@ async function acquireWithRetry(attempt, deps) {
|
|
|
166
166
|
* `(addonId, stableId)`; the compositor addresses them by device id, so a pass
|
|
167
167
|
* resolves one into the other here, and a layout save resolves back.
|
|
168
168
|
*/
|
|
169
|
+
/** The cell of a crop: the whole canvas. */
|
|
170
|
+
var CROP_FULL_CELL = {
|
|
171
|
+
x: 0,
|
|
172
|
+
y: 0,
|
|
173
|
+
width: 1,
|
|
174
|
+
height: 1
|
|
175
|
+
};
|
|
176
|
+
/** Every source a block reads, in cell order. */
|
|
177
|
+
function gridBlockSourceRefs(spec) {
|
|
178
|
+
return spec.kind === "crop" ? [spec.source] : spec.cells.map((cell) => cell.source);
|
|
179
|
+
}
|
|
169
180
|
function sourceRefKey(ref) {
|
|
170
181
|
return `${ref.addonId}\u0000${ref.stableId}`;
|
|
171
182
|
}
|
|
@@ -175,6 +186,21 @@ function sourceRefKey(ref) {
|
|
|
175
186
|
* from composing the cells that remain.
|
|
176
187
|
*/
|
|
177
188
|
function resolveGridCells(spec, deviceIdOf) {
|
|
189
|
+
if (spec.kind === "crop") {
|
|
190
|
+
const deviceId = deviceIdOf(spec.source);
|
|
191
|
+
if (deviceId === null) return {
|
|
192
|
+
cells: [],
|
|
193
|
+
unresolved: [spec.source]
|
|
194
|
+
};
|
|
195
|
+
return {
|
|
196
|
+
cells: [{
|
|
197
|
+
deviceId,
|
|
198
|
+
source: spec.rect,
|
|
199
|
+
cell: CROP_FULL_CELL
|
|
200
|
+
}],
|
|
201
|
+
unresolved: []
|
|
202
|
+
};
|
|
203
|
+
}
|
|
178
204
|
const cells = [];
|
|
179
205
|
const unresolved = [];
|
|
180
206
|
for (const cell of spec.cells) {
|
|
@@ -2961,12 +2987,13 @@ var CameraGridAddon = class extends BaseAddon {
|
|
|
2961
2987
|
this.ctx.logger.warn("camera grid: the grid blocks could not be read - nothing changes", { meta: { error: errMsg(error) } });
|
|
2962
2988
|
return;
|
|
2963
2989
|
}
|
|
2964
|
-
const
|
|
2965
|
-
|
|
2966
|
-
|
|
2990
|
+
const grids = selectEngineHostedBlocks("grid", compositions, composerRows);
|
|
2991
|
+
const crops = selectEngineHostedBlocks("crop", compositions, composerRows);
|
|
2992
|
+
if (grids.kind === "untrusted" || crops.kind === "untrusted") {
|
|
2993
|
+
this.ctx.logger.info("camera grid: the blocks are not loaded yet - nothing changes", { meta: { reason: grids.kind === "untrusted" ? grids.reason : "not loaded" } });
|
|
2967
2994
|
return;
|
|
2968
2995
|
}
|
|
2969
|
-
const wanted =
|
|
2996
|
+
const wanted = [...grids.blocks, ...crops.blocks].filter((block) => block.enabled);
|
|
2970
2997
|
const { withdraw } = this.withdrawalGate.judge(this.grids.keys(), new Set(wanted.map((block) => block.blockId)));
|
|
2971
2998
|
for (const blockId of withdraw) await this.unhost(blockId, "its block is gone or switched off");
|
|
2972
2999
|
const sources = await this.readSources(wanted);
|
|
@@ -3030,7 +3057,7 @@ var CameraGridAddon = class extends BaseAddon {
|
|
|
3030
3057
|
* and named.
|
|
3031
3058
|
*/
|
|
3032
3059
|
layoutOf(block, sources, previous) {
|
|
3033
|
-
if (block.spec.
|
|
3060
|
+
if (gridBlockSourceRefs(block.spec).some((ref) => sources.unreadAddons.has(ref.addonId)) && previous !== null) return {
|
|
3034
3061
|
...previous.layout,
|
|
3035
3062
|
fps: block.spec.fps
|
|
3036
3063
|
};
|
|
@@ -3050,7 +3077,7 @@ var CameraGridAddon = class extends BaseAddon {
|
|
|
3050
3077
|
}
|
|
3051
3078
|
/** One indexed read per source addon (`listAll({ addonId })`), never the fleet. */
|
|
3052
3079
|
async readSources(blocks) {
|
|
3053
|
-
const addonIds = new Set(blocks.flatMap((b) => b.spec.
|
|
3080
|
+
const addonIds = new Set(blocks.flatMap((b) => gridBlockSourceRefs(b.spec).map((ref) => ref.addonId)));
|
|
3054
3081
|
const ids = /* @__PURE__ */ new Map();
|
|
3055
3082
|
const unreadAddons = /* @__PURE__ */ new Set();
|
|
3056
3083
|
for (const addonId of addonIds) try {
|
|
@@ -3574,6 +3601,7 @@ var CameraGridAddon = class extends BaseAddon {
|
|
|
3574
3601
|
return this.serialized(async () => {
|
|
3575
3602
|
const grid = this.gridForDevice(input.deviceId);
|
|
3576
3603
|
if (grid === null) throw new Error(`camera-grid: device ${String(input.deviceId)} is not a grid camera`);
|
|
3604
|
+
if (grid.block.spec.kind !== "grid") throw new Error(`camera-grid: device ${String(input.deviceId)} is a crop camera - its layout is not a grid's to save`);
|
|
3577
3605
|
const refs = await this.sourceRefs(input.cells.map((cell) => cell.deviceId));
|
|
3578
3606
|
const spec = gridSpecFromPatch(grid.block.spec, input, (id) => refs.get(id) ?? null);
|
|
3579
3607
|
const composition = gridComposition(spec);
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { BaseDevice, type CapabilityDefinition, type DeviceConstructor, type DeviceContext, type DeviceStatusOwnership,
|
|
1
|
+
import { BaseDevice, type CapabilityDefinition, type DeviceConstructor, type DeviceContext, type DeviceStatusOwnership, DeviceFeature, DeviceType, type GroupCommandResult, type IDevice, type ReadingQuantity } from "@camstack/types";
|
|
2
2
|
import { z } from "zod";
|
|
3
3
|
import type { ComposedWriteTarget, WriteOutcome } from "./composition-runtime.js";
|
|
4
4
|
import type { SlicePatch } from "./slice-assembler.js";
|
|
@@ -14,6 +14,7 @@ export interface ComposedDeviceHandle extends ComposedWriteTarget {
|
|
|
14
14
|
}
|
|
15
15
|
export declare class ComposedDevice extends BaseDevice<typeof COMPOSED_DEVICE_CONFIG_SCHEMA> implements ComposedDeviceHandle {
|
|
16
16
|
private sharedFeatures;
|
|
17
|
+
private valvePositionable;
|
|
17
18
|
/** Features of caps bound on the device by others (a wrapper): derived from its bindings, never listed here. */
|
|
18
19
|
private boundFeatures;
|
|
19
20
|
private extraCaps;
|
|
@@ -3,11 +3,11 @@ Object.defineProperties(exports, {
|
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
5
|
require("../../chunk-Cek0wNdY.js");
|
|
6
|
-
const require_dist = require("../../dist-
|
|
7
|
-
const require_capture_engine = require("../../capture-engine-
|
|
8
|
-
const require_composition_sources = require("../../composition-sources-
|
|
6
|
+
const require_dist = require("../../dist-DxBWhuSc.js");
|
|
7
|
+
const require_capture_engine = require("../../capture-engine-UNTcSBiF.js");
|
|
8
|
+
const require_composition_sources = require("../../composition-sources-Df52Wv0k.js");
|
|
9
9
|
const require_retention = require("../../retention-BcOSL6b9.js");
|
|
10
|
-
const require_rename_composition_block = require("../../rename-composition-block-
|
|
10
|
+
const require_rename_composition_block = require("../../rename-composition-block-CaZBnU9O.js");
|
|
11
11
|
let zod = require("zod");
|
|
12
12
|
//#region src/builtins/composer/actuator-invoke.ts
|
|
13
13
|
/**
|
|
@@ -159,6 +159,7 @@ function sliceBoolean(slice, field) {
|
|
|
159
159
|
}
|
|
160
160
|
var ComposedDevice = class extends require_dist.BaseDevice {
|
|
161
161
|
sharedFeatures = [];
|
|
162
|
+
valvePositionable = false;
|
|
162
163
|
/** Features of caps bound on the device by others (a wrapper): derived from its bindings, never listed here. */
|
|
163
164
|
boundFeatures = [];
|
|
164
165
|
extraCaps = /* @__PURE__ */ new Set();
|
|
@@ -232,7 +233,7 @@ var ComposedDevice = class extends require_dist.BaseDevice {
|
|
|
232
233
|
await this.dispatch("color", "setColor", { color: input.color });
|
|
233
234
|
} });
|
|
234
235
|
});
|
|
235
|
-
this.syncTypedCaps(caps);
|
|
236
|
+
this.syncTypedCaps(caps, modes);
|
|
236
237
|
this.sharedFeatures = [...modes];
|
|
237
238
|
this.refreshFeatures();
|
|
238
239
|
}
|
|
@@ -242,7 +243,7 @@ var ComposedDevice = class extends require_dist.BaseDevice {
|
|
|
242
243
|
* keeps serving nothing it did not before. Every method fans out; the group
|
|
243
244
|
* refuses the ones its members do not all share.
|
|
244
245
|
*/
|
|
245
|
-
syncTypedCaps(caps) {
|
|
246
|
+
syncTypedCaps(caps, modes) {
|
|
246
247
|
const call = (cap, method, args) => this.dispatch(cap, method, present(args));
|
|
247
248
|
this.ensureExtra(require_dist.fanControlCapability.name, caps.includes(require_dist.fanControlCapability.name), () => {
|
|
248
249
|
this.ctx.registerNativeCap(require_dist.fanControlCapability, {
|
|
@@ -261,12 +262,17 @@ var ComposedDevice = class extends require_dist.BaseDevice {
|
|
|
261
262
|
setTiltPosition: (input) => call("cover", "setTiltPosition", { tiltPosition: input.tiltPosition })
|
|
262
263
|
});
|
|
263
264
|
});
|
|
265
|
+
const positionable = modes.includes(require_dist.DeviceFeature.ValvePositionable);
|
|
266
|
+
if (positionable !== this.valvePositionable) {
|
|
267
|
+
this.ensureExtra(require_dist.valveCapability.name, false, () => {});
|
|
268
|
+
this.valvePositionable = positionable;
|
|
269
|
+
}
|
|
264
270
|
this.ensureExtra(require_dist.valveCapability.name, caps.includes(require_dist.valveCapability.name), () => {
|
|
265
271
|
this.ctx.registerNativeCap(require_dist.valveCapability, {
|
|
266
272
|
open: () => call("valve", "open", {}),
|
|
267
273
|
close: () => call("valve", "close", {}),
|
|
268
274
|
stop: () => call("valve", "stop", {}),
|
|
269
|
-
setPosition: (input) => call("valve", "setPosition", { position: input.position })
|
|
275
|
+
...positionable ? { setPosition: (input) => call("valve", "setPosition", { position: input.position }) } : {}
|
|
270
276
|
});
|
|
271
277
|
});
|
|
272
278
|
this.ensureExtra(require_dist.lockControlCapability.name, caps.includes(require_dist.lockControlCapability.name), () => {
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { $s as composedDeviceStableId, Ao as resolveMutate, C as COMPOSED_ITEM_FIXED_FIELDS, Cc as BaseAddon, Cr as compositionFieldKey, Di as groupTemplate, Dt as HvacModeSchema, Du as errMsg, Ei as groupCommandsCapability, Er as consumablesCapability, Eu as DeviceType, Hs as HISTORY_FAST_MS, Io as runFanOut, Ka as planComposition, Ks as MINUTE_MS, Mr as coverCapability, Ns as withDefaultRunning, Os as valveCapability, Ou as featuresOfBoundCaps, Qn as buildCapabilityLookup, Qs as composedDeviceRef, Qt as PetFountainStatusSchema, Rr as declaredSeriesKind, Rs as COMPOSER_ADDON_ID, Sr as composerCapability, Ua as petFountainCapability, Ul as isReadingQuantity, Us as HISTORY_SLOW_MS, Va as parseColorInput, Vs as DEFAULT_HISTORY_RETENTION, Wa as petFountainWaterItem, Ws as HOUR_MS, Xn as brightnessCapability, Xo as sharedActuatorMethods, Yo as sharedActuatorFeatures, Zo as sharedColorModes, Zs as cloneStatefulExpressionMemory, _c as openStatistic, _i as featureForwards, _t as FanDirectionSchema, ac as disarmRoseMemory, ai as evaluateCompositionField, ba as mediaPlayerFeaturesOfRoles, bc as statisticCadenceMs, bl as createEvent, da as lockControlCapability, dc as integrateReading, ec as compositionFeatureEnabled, fc as isEngineHostedHelper, fs as switchCapability, gc as openReset, gr as colorCapability, hc as nextLocalMidnight, hi as fanOutTargets, i as ACTUATOR_TEMPLATE_IDS, ic as createStatefulExpressionMemory, j as ConsumableItemSchema, ka as motionCapability, ku as EventCategory, lc as historyRetentionFromSettings, mc as isHistoryHelper, mi as fanControlCapability, nc as compositionSliceKey, oc as evaluateDerivative, pc as isForwardInputRef, pr as climateControlCapability, r as ACTUATOR_METHODS, rc as compositionSourceKey, s as ALL_CAPABILITY_DEFINITIONS, sc as evaluateStatistic, ta as kebabToCamel, tc as compositionItemFieldPath, to as processTimeZoneOr, tt as DeclaredDevices, ui as expressionContainsBuiltinCall, v as BaseDevice, vc as planResetTier, vr as commandedMethods, wa as methodRefusal, xc as toExpressionValue, xt as GroupCommandResultSchema, ya as mediaPlayerCapability, yc as planStatisticTier } from "../../dist-
|
|
2
|
-
import { i as capSeriesKey, m as parseConfirmedStateChanged, p as isRecord$4 } from "../../capture-engine-
|
|
3
|
-
import { n as normalizedNativeOwner } from "../../composition-sources-
|
|
1
|
+
import { $s as composedDeviceStableId, Ao as resolveMutate, C as COMPOSED_ITEM_FIXED_FIELDS, Cc as BaseAddon, Cr as compositionFieldKey, Di as groupTemplate, Dt as HvacModeSchema, Du as errMsg, Ei as groupCommandsCapability, Er as consumablesCapability, Eu as DeviceType, Hs as HISTORY_FAST_MS, Io as runFanOut, Ka as planComposition, Ks as MINUTE_MS, Mr as coverCapability, Ns as withDefaultRunning, Os as valveCapability, Ou as featuresOfBoundCaps, Qn as buildCapabilityLookup, Qs as composedDeviceRef, Qt as PetFountainStatusSchema, Rr as declaredSeriesKind, Rs as COMPOSER_ADDON_ID, Sr as composerCapability, Ua as petFountainCapability, Ul as isReadingQuantity, Us as HISTORY_SLOW_MS, Va as parseColorInput, Vs as DEFAULT_HISTORY_RETENTION, Wa as petFountainWaterItem, Ws as HOUR_MS, Xn as brightnessCapability, Xo as sharedActuatorMethods, Yo as sharedActuatorFeatures, Zo as sharedColorModes, Zs as cloneStatefulExpressionMemory, _c as openStatistic, _i as featureForwards, _t as FanDirectionSchema, ac as disarmRoseMemory, ai as evaluateCompositionField, ba as mediaPlayerFeaturesOfRoles, bc as statisticCadenceMs, bl as createEvent, da as lockControlCapability, dc as integrateReading, ec as compositionFeatureEnabled, fc as isEngineHostedHelper, fs as switchCapability, gc as openReset, gr as colorCapability, hc as nextLocalMidnight, hi as fanOutTargets, i as ACTUATOR_TEMPLATE_IDS, ic as createStatefulExpressionMemory, j as ConsumableItemSchema, ka as motionCapability, ku as EventCategory, lc as historyRetentionFromSettings, mc as isHistoryHelper, mi as fanControlCapability, nc as compositionSliceKey, oc as evaluateDerivative, pc as isForwardInputRef, pr as climateControlCapability, r as ACTUATOR_METHODS, rc as compositionSourceKey, s as ALL_CAPABILITY_DEFINITIONS, sc as evaluateStatistic, ta as kebabToCamel, tc as compositionItemFieldPath, to as processTimeZoneOr, tt as DeclaredDevices, ui as expressionContainsBuiltinCall, v as BaseDevice, vc as planResetTier, vr as commandedMethods, wa as methodRefusal, wu as DeviceFeature, xc as toExpressionValue, xt as GroupCommandResultSchema, ya as mediaPlayerCapability, yc as planStatisticTier } from "../../dist-CftbsT6r.mjs";
|
|
2
|
+
import { i as capSeriesKey, m as parseConfirmedStateChanged, p as isRecord$4 } from "../../capture-engine-DgO-N5FL.mjs";
|
|
3
|
+
import { n as normalizedNativeOwner } from "../../composition-sources-AfSwY0mW.mjs";
|
|
4
4
|
import { i as DAY_MS, t as DEFAULT_RETENTION } from "../../retention-CUOVI1p7.mjs";
|
|
5
|
-
import { n as renameCompositionBlock } from "../../rename-composition-block-
|
|
5
|
+
import { n as renameCompositionBlock } from "../../rename-composition-block-CcCjR2ZX.mjs";
|
|
6
6
|
import { z } from "zod";
|
|
7
7
|
//#region src/builtins/composer/actuator-invoke.ts
|
|
8
8
|
/**
|
|
@@ -154,6 +154,7 @@ function sliceBoolean(slice, field) {
|
|
|
154
154
|
}
|
|
155
155
|
var ComposedDevice = class extends BaseDevice {
|
|
156
156
|
sharedFeatures = [];
|
|
157
|
+
valvePositionable = false;
|
|
157
158
|
/** Features of caps bound on the device by others (a wrapper): derived from its bindings, never listed here. */
|
|
158
159
|
boundFeatures = [];
|
|
159
160
|
extraCaps = /* @__PURE__ */ new Set();
|
|
@@ -227,7 +228,7 @@ var ComposedDevice = class extends BaseDevice {
|
|
|
227
228
|
await this.dispatch("color", "setColor", { color: input.color });
|
|
228
229
|
} });
|
|
229
230
|
});
|
|
230
|
-
this.syncTypedCaps(caps);
|
|
231
|
+
this.syncTypedCaps(caps, modes);
|
|
231
232
|
this.sharedFeatures = [...modes];
|
|
232
233
|
this.refreshFeatures();
|
|
233
234
|
}
|
|
@@ -237,7 +238,7 @@ var ComposedDevice = class extends BaseDevice {
|
|
|
237
238
|
* keeps serving nothing it did not before. Every method fans out; the group
|
|
238
239
|
* refuses the ones its members do not all share.
|
|
239
240
|
*/
|
|
240
|
-
syncTypedCaps(caps) {
|
|
241
|
+
syncTypedCaps(caps, modes) {
|
|
241
242
|
const call = (cap, method, args) => this.dispatch(cap, method, present(args));
|
|
242
243
|
this.ensureExtra(fanControlCapability.name, caps.includes(fanControlCapability.name), () => {
|
|
243
244
|
this.ctx.registerNativeCap(fanControlCapability, {
|
|
@@ -256,12 +257,17 @@ var ComposedDevice = class extends BaseDevice {
|
|
|
256
257
|
setTiltPosition: (input) => call("cover", "setTiltPosition", { tiltPosition: input.tiltPosition })
|
|
257
258
|
});
|
|
258
259
|
});
|
|
260
|
+
const positionable = modes.includes(DeviceFeature.ValvePositionable);
|
|
261
|
+
if (positionable !== this.valvePositionable) {
|
|
262
|
+
this.ensureExtra(valveCapability.name, false, () => {});
|
|
263
|
+
this.valvePositionable = positionable;
|
|
264
|
+
}
|
|
259
265
|
this.ensureExtra(valveCapability.name, caps.includes(valveCapability.name), () => {
|
|
260
266
|
this.ctx.registerNativeCap(valveCapability, {
|
|
261
267
|
open: () => call("valve", "open", {}),
|
|
262
268
|
close: () => call("valve", "close", {}),
|
|
263
269
|
stop: () => call("valve", "stop", {}),
|
|
264
|
-
setPosition: (input) => call("valve", "setPosition", { position: input.position })
|
|
270
|
+
...positionable ? { setPosition: (input) => call("valve", "setPosition", { position: input.position }) } : {}
|
|
265
271
|
});
|
|
266
272
|
});
|
|
267
273
|
this.ensureExtra(lockControlCapability.name, caps.includes(lockControlCapability.name), () => {
|
|
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
|
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
5
|
require("../../chunk-Cek0wNdY.js");
|
|
6
|
-
const require_dist = require("../../dist-
|
|
6
|
+
const require_dist = require("../../dist-DxBWhuSc.js");
|
|
7
7
|
const require_formatter = require("../../formatter-xbxeV4GD.js");
|
|
8
8
|
//#region src/builtins/console-logging/console-destination.ts
|
|
9
9
|
var LEVEL_RANK = {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Cc as BaseAddon, pa as logDestinationCapability } from "../../dist-
|
|
1
|
+
import { Cc as BaseAddon, pa as logDestinationCapability } from "../../dist-CftbsT6r.mjs";
|
|
2
2
|
import { t as formatLogLine } from "../../formatter-DkYZ4LXp.mjs";
|
|
3
3
|
//#region src/builtins/console-logging/console-destination.ts
|
|
4
4
|
var LEVEL_RANK = {
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
2
|
const require_chunk = require("../../chunk-Cek0wNdY.js");
|
|
3
|
-
const require_dist = require("../../dist-
|
|
3
|
+
const require_dist = require("../../dist-DxBWhuSc.js");
|
|
4
4
|
const require_read_all_rows$1 = require("../../read-all-rows-CVoO1ONM.js");
|
|
5
|
-
const require_capture_engine = require("../../capture-engine-
|
|
6
|
-
const require_composition_sources = require("../../composition-sources-
|
|
7
|
-
const require_rename_composition_block = require("../../rename-composition-block-
|
|
5
|
+
const require_capture_engine = require("../../capture-engine-UNTcSBiF.js");
|
|
6
|
+
const require_composition_sources = require("../../composition-sources-Df52Wv0k.js");
|
|
7
|
+
const require_rename_composition_block = require("../../rename-composition-block-CaZBnU9O.js");
|
|
8
8
|
const require_prefix_range = require("../../prefix-range-D_KueXbQ.js");
|
|
9
9
|
const require_prefix_walk = require("../../prefix-walk-Dv6MLZlM.js");
|
|
10
10
|
const require_cap_call_scope = require("../../cap-call-scope-8eiugfLl.js");
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { $a as problemsBlockSave, $o as siteFor, $s as composedDeviceStableId, $t as PowerSourceInfoSchema, A as ConditionMirror, Aa as nextOccurrence, Ar as coreBlockSourceKind, At as INTERNAL_ACTION_PREFIX, Br as defaultTagColorId, Bs as DAY_MS, Ca as mergeScalarTarget, Cc as BaseAddon, Dn as TagsFieldSchema, Dr as coreBlockAddonId, Ds as validateSchedulerInput, Du as errMsg$1, E as CORE_BLOCK_ADDON_PREFIX, En as TagStyleSchema, Eo as resolveHeroLayout, Eu as DeviceType$1, Fi as integrationInstancesCapability, Fn as actionWaitTotalMs, Go as seedInstanceOnce, Gs as HelperMemberSchema, Ii as internalActionId, Il as hydrateSchema, In as actionsCapability, Ja as powerSourceActuatorConflicts, Ji as isInternalActionId, Jl as isSecretRefOwnedBy, Js as canonicalStoredBlockTarget, Ka as planComposition, Kl as isSecretMarker, Kn as assertStepsOffered, Ln as addonIdOfActionId, Lo as runSteps, Ls as zoneOnlySite, M as CoreBlockSchema, Ma as normalizeActionUnits, Mo as resolveRemoteSource, Ms as weekdayOfLocalDate, Na as normalizeCoreBlockWrite, Oi as hasTimeLeaves, On as TemplateKindSchema, Or as coreBlockComposition, Ot as IDENTITY_LINK_KINDS, Pa as normalizeTags, Pi as instanceCodeHash, Pn as actionSourceCapability, Po as resolveStepArgs, Pr as customKeyOfRole, Qa as prepareRecipeUnits, Qn as buildCapabilityLookup, Qs as composedDeviceRef, Ra as occurrenceOn, Rs as COMPOSER_ADDON_ID, Sl as defineAddonMigrations, Ss as toTimings, T as CORE_BLOCKS_ADDON_ID, Tl as defineRecordKinds, Tn as TagNameSchema, To as resolveCoreBlockFiles, Tr as compositionUnionReads, Ts as validateComposition, Tu as DeviceRole, Ui as isBuiltinTemplateId, Ur as describeComposableCaps, Vo as schedulersCapability, Vt as MediaPlayerStatusSchema, Wn as appendTrace, Wt as NcTaggedRuleKindSchema, Xa as powerSourceLinkOfComposition, Ya as powerSourceCapability, Zn as buildActionSteps, _ as BUILTIN_REMOTE_COMPONENTS, _o as renameInTags, _s as timedRunCapability, an as REMOTE_MEDIA_COMMANDS, ao as readRecipeLiteral, bo as resolveActionVariables, bs as timedRunQuickRun, bu as vocabActionIdFor, c as ActionError, ca as localDateOf, cc as helperMembers, cn as RemoteAssumedStateSchema, cr as capUnitResolver, ct as EMPTY_AUTOMATION_STATE, cu as ruleFireOfClaim, d as ActionTargetResolver, do as reexpandAutomationInstance, ec as compositionFeatureEnabled, f as ActionVariableSchema, fa as lockDoorLinkOfComposition, fo as remoteCapability, fr as checkTemplatePayload, ft as FAN_CAPTURE_FIELDS, fu as secretTreeFromSchema, g as BUILTIN_AUTOMATION_TEMPLATES, gi as fanPresetsCapability, gl as collectSecretMarkerRefs, gn as SchedulerSchema, go as removeScalarTarget, gs as templateCapability, gt as FanControlStatusSchema, h as AutomationTemplatePayloadSchema, hn as SchedulerError, ho as removeFromTags, hr as collectWhenMirrorSources, hs as tagsCapability, il as VocabActionError, ja as nextTimeBoundaryInMs, jr as coreBlocksCapability, ki as heroLayoutCapability, kl as entryBody, kr as coreBlockIdFromAddonId, kt as IDLE_ACTION_STATUS, ku as EventCategory$1, l as ActionMinDelaySecSchema, lc as historyRetentionFromSettings, ln as RemoteLayoutPayloadSchema, lt as EMPTY_REMOTE_ASSUMED_STATE, m as AutomationStateDocSchema, mn as SWITCH_DEFAULT_OPTIONS, mo as remoteSourceSteps, mr as collectDeviceTemplates, ms as tagKey, mt as FAN_OSCILLATION_AXIS_SETTABLE, n as ACTION_TARGET_INVALIDATION_EVENTS, no as projectDeviceRow, oi as evaluateStepCondition, ol as actionEffect, oo as readStoredRemoteConfig, pi as fanAxisPath, po as remoteLayoutComponentsCapability, pt as FAN_OSCILLATION_AXES, qc as RecordIntegrationInstances, rc as compositionSourceKey, rn as QuantityUnitError, ro as proposeRunningThreshold, rr as builtinAutomationTemplate, rs as stableIdMapOf, s as ALL_CAPABILITY_DEFINITIONS, si as evaluateWhenTree, sr as canonicalStoredStepTargets, su as resolveSecretMarkers, ta as kebabToCamel, tr as buildHeroModel, tt as DeclaredDevices, u as ActionStepSchema, un as RunningStateStatusSchema, ut as EMPTY_REMOTE_CONFIG, vo as replaceRecipeLiteral, vs as timedRunLimitOf, vt as FanPresetSchema, vu as transformSecretWrite, w as COMPOSER_RUNNER_ID, wi as generateAutomationBlock, wl as defineEntryKind, wo as resolveCoreBlockEntry, wr as compositionSourceRefs, xr as compileScalarOverride, xs as timedRunSeconds, xu as vocabCall, yi as findChannelSource, yl as commandOrigin$1, yn as SetOscillationAxisInputSchema, yo as replacedFieldKeys, ys as timedRunMaxIn, z as DEFAULT_HOLD_OVERRIDE, zs as CompositionSchema } from "../../dist-
|
|
1
|
+
import { $a as problemsBlockSave, $o as siteFor, $s as composedDeviceStableId, $t as PowerSourceInfoSchema, A as ConditionMirror, Aa as nextOccurrence, Ar as coreBlockSourceKind, At as INTERNAL_ACTION_PREFIX, Br as defaultTagColorId, Bs as DAY_MS, Ca as mergeScalarTarget, Cc as BaseAddon, Dn as TagsFieldSchema, Dr as coreBlockAddonId, Ds as validateSchedulerInput, Du as errMsg$1, E as CORE_BLOCK_ADDON_PREFIX, En as TagStyleSchema, Eo as resolveHeroLayout, Eu as DeviceType$1, Fi as integrationInstancesCapability, Fn as actionWaitTotalMs, Go as seedInstanceOnce, Gs as HelperMemberSchema, Ii as internalActionId, Il as hydrateSchema, In as actionsCapability, Ja as powerSourceActuatorConflicts, Ji as isInternalActionId, Jl as isSecretRefOwnedBy, Js as canonicalStoredBlockTarget, Ka as planComposition, Kl as isSecretMarker, Kn as assertStepsOffered, Ln as addonIdOfActionId, Lo as runSteps, Ls as zoneOnlySite, M as CoreBlockSchema, Ma as normalizeActionUnits, Mo as resolveRemoteSource, Ms as weekdayOfLocalDate, Na as normalizeCoreBlockWrite, Oi as hasTimeLeaves, On as TemplateKindSchema, Or as coreBlockComposition, Ot as IDENTITY_LINK_KINDS, Pa as normalizeTags, Pi as instanceCodeHash, Pn as actionSourceCapability, Po as resolveStepArgs, Pr as customKeyOfRole, Qa as prepareRecipeUnits, Qn as buildCapabilityLookup, Qs as composedDeviceRef, Ra as occurrenceOn, Rs as COMPOSER_ADDON_ID, Sl as defineAddonMigrations, Ss as toTimings, T as CORE_BLOCKS_ADDON_ID, Tl as defineRecordKinds, Tn as TagNameSchema, To as resolveCoreBlockFiles, Tr as compositionUnionReads, Ts as validateComposition, Tu as DeviceRole, Ui as isBuiltinTemplateId, Ur as describeComposableCaps, Vo as schedulersCapability, Vt as MediaPlayerStatusSchema, Wn as appendTrace, Wt as NcTaggedRuleKindSchema, Xa as powerSourceLinkOfComposition, Ya as powerSourceCapability, Zn as buildActionSteps, _ as BUILTIN_REMOTE_COMPONENTS, _o as renameInTags, _s as timedRunCapability, an as REMOTE_MEDIA_COMMANDS, ao as readRecipeLiteral, bo as resolveActionVariables, bs as timedRunQuickRun, bu as vocabActionIdFor, c as ActionError, ca as localDateOf, cc as helperMembers, cn as RemoteAssumedStateSchema, cr as capUnitResolver, ct as EMPTY_AUTOMATION_STATE, cu as ruleFireOfClaim, d as ActionTargetResolver, do as reexpandAutomationInstance, ec as compositionFeatureEnabled, f as ActionVariableSchema, fa as lockDoorLinkOfComposition, fo as remoteCapability, fr as checkTemplatePayload, ft as FAN_CAPTURE_FIELDS, fu as secretTreeFromSchema, g as BUILTIN_AUTOMATION_TEMPLATES, gi as fanPresetsCapability, gl as collectSecretMarkerRefs, gn as SchedulerSchema, go as removeScalarTarget, gs as templateCapability, gt as FanControlStatusSchema, h as AutomationTemplatePayloadSchema, hn as SchedulerError, ho as removeFromTags, hr as collectWhenMirrorSources, hs as tagsCapability, il as VocabActionError, ja as nextTimeBoundaryInMs, jr as coreBlocksCapability, ki as heroLayoutCapability, kl as entryBody, kr as coreBlockIdFromAddonId, kt as IDLE_ACTION_STATUS, ku as EventCategory$1, l as ActionMinDelaySecSchema, lc as historyRetentionFromSettings, ln as RemoteLayoutPayloadSchema, lt as EMPTY_REMOTE_ASSUMED_STATE, m as AutomationStateDocSchema, mn as SWITCH_DEFAULT_OPTIONS, mo as remoteSourceSteps, mr as collectDeviceTemplates, ms as tagKey, mt as FAN_OSCILLATION_AXIS_SETTABLE, n as ACTION_TARGET_INVALIDATION_EVENTS, no as projectDeviceRow, oi as evaluateStepCondition, ol as actionEffect, oo as readStoredRemoteConfig, pi as fanAxisPath, po as remoteLayoutComponentsCapability, pt as FAN_OSCILLATION_AXES, qc as RecordIntegrationInstances, rc as compositionSourceKey, rn as QuantityUnitError, ro as proposeRunningThreshold, rr as builtinAutomationTemplate, rs as stableIdMapOf, s as ALL_CAPABILITY_DEFINITIONS, si as evaluateWhenTree, sr as canonicalStoredStepTargets, su as resolveSecretMarkers, ta as kebabToCamel, tr as buildHeroModel, tt as DeclaredDevices, u as ActionStepSchema, un as RunningStateStatusSchema, ut as EMPTY_REMOTE_CONFIG, vo as replaceRecipeLiteral, vs as timedRunLimitOf, vt as FanPresetSchema, vu as transformSecretWrite, w as COMPOSER_RUNNER_ID, wi as generateAutomationBlock, wl as defineEntryKind, wo as resolveCoreBlockEntry, wr as compositionSourceRefs, xr as compileScalarOverride, xs as timedRunSeconds, xu as vocabCall, yi as findChannelSource, yl as commandOrigin$1, yn as SetOscillationAxisInputSchema, yo as replacedFieldKeys, ys as timedRunMaxIn, z as DEFAULT_HOLD_OVERRIDE, zs as CompositionSchema } from "../../dist-CftbsT6r.mjs";
|
|
2
2
|
import { t as require_read_all_rows } from "../../read-all-rows-TaPqdWNF.mjs";
|
|
3
|
-
import { i as capSeriesKey, m as parseConfirmedStateChanged, p as isRecord$1 } from "../../capture-engine-
|
|
4
|
-
import { t as describeCompositionSources } from "../../composition-sources-
|
|
5
|
-
import { t as composedBlockIdOf } from "../../rename-composition-block-
|
|
3
|
+
import { i as capSeriesKey, m as parseConfirmedStateChanged, p as isRecord$1 } from "../../capture-engine-DgO-N5FL.mjs";
|
|
4
|
+
import { t as describeCompositionSources } from "../../composition-sources-AfSwY0mW.mjs";
|
|
5
|
+
import { t as composedBlockIdOf } from "../../rename-composition-block-CcCjR2ZX.mjs";
|
|
6
6
|
import { t as prefixRange } from "../../prefix-range-Dl0znowN.mjs";
|
|
7
7
|
import { n as unwrapStoredValue, t as loadPrefixed } from "../../prefix-walk-DAOBSyH1.mjs";
|
|
8
8
|
import { n as readCurrentCommandOrigin } from "../../cap-call-scope-Bic6Ekfw.mjs";
|
|
@@ -3,8 +3,8 @@ Object.defineProperties(exports, {
|
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
5
|
require("../../chunk-Cek0wNdY.js");
|
|
6
|
-
const require_dist = require("../../dist-
|
|
7
|
-
const require_capture_engine = require("../../capture-engine-
|
|
6
|
+
const require_dist = require("../../dist-DxBWhuSc.js");
|
|
7
|
+
const require_capture_engine = require("../../capture-engine-UNTcSBiF.js");
|
|
8
8
|
const require_retention = require("../../retention-BcOSL6b9.js");
|
|
9
9
|
let node_crypto = require("node:crypto");
|
|
10
10
|
//#region src/builtins/device-history/capture/point-writer.ts
|