@camstack/addon-osd-manager 0.1.267 → 0.1.269

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.
Files changed (19) hide show
  1. package/dist/{MotionZonesSettings-3OswGeMl.mjs → MotionZonesSettings-BNpjz5g_.mjs} +2 -2
  2. package/dist/{PrivacyMaskSettings-CxN7tOH_.mjs → PrivacyMaskSettings-BUUwi7AA.mjs} +4 -4
  3. package/dist/{SceneMonitorEditor-l9nWTYyI.mjs → SceneMonitorEditor-C8nM8xAb.mjs} +3 -3
  4. package/dist/_stub.js +4155 -4019
  5. package/dist/{_virtual_mf-localSharedImportMap___mfe_internal__addon_osd_manager_page-DXtR0Eje.mjs → _virtual_mf-localSharedImportMap___mfe_internal__addon_osd_manager_page-DyV-DzxR.mjs} +3 -3
  6. package/dist/_virtual_mf___mfe_internal__addon_osd_manager_page__loadShare___mf_0_camstack_mf_1_types__loadShare__.js-CV6YcS56.mjs +26 -0
  7. package/dist/addon-osd-manager.css +1 -1
  8. package/dist/{hostInit-DtrBgAfd.mjs → hostInit-FBoYOEXv.mjs} +2 -2
  9. package/dist/index.js +591 -76
  10. package/dist/index.mjs +591 -76
  11. package/dist/{player-overlays-DeO4qjxv.mjs → player-overlays-CfPa7e9_.mjs} +1 -1
  12. package/dist/remoteEntry.js +1 -1
  13. package/dist/{responsive-BiymurY0.mjs → responsive-C4D8Hc3L.mjs} +1 -1
  14. package/dist/{scene-monitor-copy-CXLDSWeP.mjs → scene-monitor-copy-DKL8iV9N.mjs} +1 -1
  15. package/dist/{square-Vgi9aM6a.mjs → square-C1SY2RoU.mjs} +1 -1
  16. package/dist/{trash-2-Ccc91Gq3.mjs → trash-2-BTuzBHSh.mjs} +1 -1
  17. package/dist/{virtual_mf-REMOTE_ENTRY_ID___mfe_internal__addon_osd_manager_page__remoteEntry_js-BYRSI4Gv.mjs → virtual_mf-REMOTE_ENTRY_ID___mfe_internal__addon_osd_manager_page__remoteEntry_js-BxBkI9w9.mjs} +1 -1
  18. package/package.json +1 -1
  19. package/dist/_virtual_mf___mfe_internal__addon_osd_manager_page__loadShare___mf_0_camstack_mf_1_types__loadShare__.js-BbmRj6OR.mjs +0 -26
package/dist/index.mjs CHANGED
@@ -8733,7 +8733,7 @@ var DeviceRole = /* @__PURE__ */ function(DeviceRole) {
8733
8733
  return DeviceRole;
8734
8734
  }({});
8735
8735
  //#endregion
8736
- //#region ../types/dist/composition-xz-ud5EQ.mjs
8736
+ //#region ../types/dist/composition-BJ8iAZb3.mjs
8737
8737
  /**
8738
8738
  * The ffmpeg build every CamStack node downloads, per platform and arch.
8739
8739
  *
@@ -8793,7 +8793,7 @@ portable("linux64"), portable("linuxarm64"), portable("macarm64"), portable("mac
8793
8793
  * ONE table for everyone who asks "is this device HIGH?": the
8794
8794
  * recorder's `RecordingTriggers.sensorDeviceIds` trigger, the post-analysis
8795
8795
  * sensor markers, the orchestrator's camera-sensors bridge and
8796
- * the sources of a composite doorbell (`doorbellFeatureSources`, D671).
8796
+ * the sources of a pulse (`compilePulseOverride`, D936).
8797
8797
  * A second copy would diverge at the first cap added, and the symptom — "the
8798
8798
  * sensor rings the doorbell but does not record" — is exactly D62.
8799
8799
  *
@@ -15844,6 +15844,13 @@ var ComposerUnreadableBlockSchema = object({
15844
15844
  /** The parse error, in the operator's words. */
15845
15845
  error: string()
15846
15846
  });
15847
+ /** A confirmed release the hub did not accept. `deviceId` is the claim's device. */
15848
+ var UnreleasedClaimSchema = object({
15849
+ deviceId: number().int(),
15850
+ capName: string(),
15851
+ owner: string(),
15852
+ error: string()
15853
+ });
15847
15854
  method(object({
15848
15855
  /** The shared Blocks integration; null until `core-blocks` has reconciled it. */
15849
15856
  integrationId: string().nullable(),
@@ -15853,7 +15860,13 @@ method(object({
15853
15860
  /** Operator restarts: rebuild these runtimes and re-resolve their sources. Stores nothing (D62). */
15854
15861
  restartBlockIds: array(string()),
15855
15862
  /** Composition rows that exist but do not parse: held, never withdrawn, reported failed. */
15856
- unreadableBlocks: array(ComposerUnreadableBlockSchema)
15863
+ unreadableBlocks: array(ComposerUnreadableBlockSchema),
15864
+ /**
15865
+ * Operator-confirmed deletions. Their claims are released on this apply,
15866
+ * before any replacement block claims. A block that merely vanished from the
15867
+ * snapshot is not listed here and still waits for two applies (D49).
15868
+ */
15869
+ retiredBlockIds: array(string()).optional()
15857
15870
  }), object({
15858
15871
  blocks: array(object({
15859
15872
  blockId: string(),
@@ -15865,7 +15878,13 @@ method(object({
15865
15878
  * integration unknown, its own rows unread or read empty once). An empty
15866
15879
  * apply the caller owes is paid off only by one the composer acted on (D49).
15867
15880
  */
15868
- acted: boolean()
15881
+ acted: boolean(),
15882
+ /**
15883
+ * Confirmed releases this apply tried and the hub did not accept. Empty when
15884
+ * every one landed (or there was nothing to hand back). Absent on a result
15885
+ * that never got that far.
15886
+ */
15887
+ unreleasedClaims: array(UnreleasedClaimSchema).optional()
15869
15888
  }), {
15870
15889
  kind: "mutation",
15871
15890
  auth: "admin"
@@ -41773,6 +41792,381 @@ var _macroLookup = /* @__PURE__ */ new Map();
41773
41792
  for (const [k, v] of Object.entries(YAMNET_TO_MACRO.mapping)) _macroLookup.set(k.toLowerCase(), v);
41774
41793
  for (const [k, v] of Object.entries(APPLE_SA_TO_MACRO.mapping)) _macroLookup.set(k.toLowerCase(), v);
41775
41794
  /**
41795
+ * Palette entry ids (D939). Audio is the one gradient; `audio-*` leaves are
41796
+ * not entries. `heatmapScrub` is a mark, not an event kind.
41797
+ */
41798
+ var PALETTE_ENTRY_IDS = [
41799
+ "motion",
41800
+ "audio",
41801
+ "recording",
41802
+ "live",
41803
+ "heatmapScrub",
41804
+ "person",
41805
+ "vehicle",
41806
+ "animal",
41807
+ "package",
41808
+ "sensor",
41809
+ "control",
41810
+ "face",
41811
+ "plate",
41812
+ "car",
41813
+ "truck",
41814
+ "bus",
41815
+ "motorcycle",
41816
+ "bicycle",
41817
+ "airplane",
41818
+ "boat",
41819
+ "train",
41820
+ "bird",
41821
+ "dog",
41822
+ "cat",
41823
+ "horse",
41824
+ "sheep",
41825
+ "cow",
41826
+ "elephant",
41827
+ "bear",
41828
+ "zebra",
41829
+ "giraffe",
41830
+ "package-delivered",
41831
+ "package-picked-up",
41832
+ "suitcase",
41833
+ "backpack",
41834
+ "handbag",
41835
+ "contact",
41836
+ "motion-sensor",
41837
+ "smoke",
41838
+ "flood",
41839
+ "gas",
41840
+ "carbon-monoxide",
41841
+ "vibration",
41842
+ "tamper",
41843
+ "presence",
41844
+ "enum-sensor",
41845
+ "device-event",
41846
+ "lock",
41847
+ "cover",
41848
+ "switch",
41849
+ "siren",
41850
+ "button",
41851
+ "doorbell"
41852
+ ];
41853
+ var AUDIO_ENTRY_ID = "audio";
41854
+ /** Six rungs, quiet → loud. The opaque end is the entry's hex. */
41855
+ var AUDIO_GRADIENT_ALPHAS = [
41856
+ .3,
41857
+ .42,
41858
+ .55,
41859
+ .7,
41860
+ .85,
41861
+ 1
41862
+ ];
41863
+ var PALETTE_PRESET_IDS = [
41864
+ "camstack",
41865
+ "high-contrast",
41866
+ "okabe-ito"
41867
+ ];
41868
+ /** Frozen palette tables (D939). The spec refuses a table that breaks the rule. */
41869
+ var CAMSTACK_HEX = {
41870
+ motion: "#d946ef",
41871
+ audio: "#059eb8",
41872
+ recording: "#ef4444",
41873
+ live: "#8d7a00",
41874
+ heatmapScrub: "#4b32ff",
41875
+ person: "#11a64c",
41876
+ vehicle: "#3b82f6",
41877
+ animal: "#ea6a09",
41878
+ package: "#924667",
41879
+ sensor: "#624bbc",
41880
+ control: "#944d24",
41881
+ face: "#ed4f8d",
41882
+ plate: "#4b7027",
41883
+ car: "#9684cf",
41884
+ truck: "#0f9b89",
41885
+ bus: "#a734a9",
41886
+ motorcycle: "#c1133a",
41887
+ bicycle: "#0e6a9b",
41888
+ airplane: "#7c9928",
41889
+ boat: "#b17933",
41890
+ train: "#ad6ca3",
41891
+ bird: "#0f7c55",
41892
+ dog: "#c82700",
41893
+ cat: "#7268f2",
41894
+ horse: "#cb795e",
41895
+ sheep: "#b8636b",
41896
+ cow: "#cb2969",
41897
+ elephant: "#1158d2",
41898
+ bear: "#8d5e00",
41899
+ zebra: "#0097d6",
41900
+ giraffe: "#8f61bb",
41901
+ "package-delivered": "#cd3f9b",
41902
+ "package-picked-up": "#388a08",
41903
+ suitcase: "#666800",
41904
+ backpack: "#ec5022",
41905
+ handbag: "#a76ef8",
41906
+ contact: "#ab5a49",
41907
+ "motion-sensor": "#b95d1a",
41908
+ smoke: "#dd3858",
41909
+ flood: "#b31e7d",
41910
+ gas: "#5b70b5",
41911
+ "carbon-monoxide": "#7b4e8e",
41912
+ vibration: "#e65bba",
41913
+ tamper: "#98464b",
41914
+ presence: "#3a9468",
41915
+ "enum-sensor": "#7885f8",
41916
+ "device-event": "#8c43c8",
41917
+ lock: "#649653",
41918
+ cover: "#c67597",
41919
+ switch: "#7a812a",
41920
+ siren: "#ac5d7f",
41921
+ button: "#b276cd",
41922
+ doorbell: "#0087ab"
41923
+ };
41924
+ var CAMSTACK_FALLBACK = [
41925
+ "#b34dc7",
41926
+ "#1d7d34",
41927
+ "#db6b6c",
41928
+ "#a43d29",
41929
+ "#0e6ee6",
41930
+ "#29a10b",
41931
+ "#a98731",
41932
+ "#0181c6"
41933
+ ];
41934
+ var HIGH_CONTRAST_HEX = {
41935
+ motion: "#964360",
41936
+ audio: "#23a132",
41937
+ recording: "#2494ca",
41938
+ live: "#bd7e2b",
41939
+ heatmapScrub: "#ad6eea",
41940
+ person: "#62611e",
41941
+ vehicle: "#f4534c",
41942
+ animal: "#1556cd",
41943
+ package: "#9c4415",
41944
+ sensor: "#066c48",
41945
+ control: "#f2479f",
41946
+ face: "#139d8a",
41947
+ plate: "#909024",
41948
+ car: "#8e35ab",
41949
+ truck: "#bd0b2b",
41950
+ bus: "#7a88ca",
41951
+ motorcycle: "#e26725",
41952
+ bicycle: "#a6679b",
41953
+ airplane: "#7c5720",
41954
+ boat: "#467a1b",
41955
+ train: "#6f65a4",
41956
+ bird: "#cb717f",
41957
+ dog: "#c62490",
41958
+ cat: "#b36850",
41959
+ horse: "#1872ac",
41960
+ sheep: "#927939",
41961
+ cow: "#428a5c",
41962
+ elephant: "#d41160",
41963
+ bear: "#799453",
41964
+ zebra: "#a85455",
41965
+ giraffe: "#746be8",
41966
+ "package-delivered": "#824a80",
41967
+ "package-picked-up": "#614ac1",
41968
+ suitcase: "#2f77f3",
41969
+ backpack: "#fa476d",
41970
+ handbag: "#c14cbe",
41971
+ contact: "#c83921",
41972
+ "motion-sensor": "#a07ebd",
41973
+ smoke: "#a25b13",
41974
+ flood: "#526bab",
41975
+ gas: "#924938",
41976
+ "carbon-monoxide": "#bb7e53",
41977
+ vibration: "#b66182",
41978
+ tamper: "#3c6931",
41979
+ presence: "#6c851d",
41980
+ "enum-sensor": "#ad2d48",
41981
+ "device-event": "#5e9b04",
41982
+ lock: "#00a062",
41983
+ cover: "#ad8624",
41984
+ switch: "#d05259",
41985
+ siren: "#cd67b3",
41986
+ button: "#c9746a",
41987
+ doorbell: "#338eeb"
41988
+ };
41989
+ var HIGH_CONTRAST_FALLBACK = [
41990
+ "#817f3b",
41991
+ "#a0733e",
41992
+ "#8658b2",
41993
+ "#956301",
41994
+ "#bc652d",
41995
+ "#647331",
41996
+ "#a14c9e",
41997
+ "#d14e71"
41998
+ ];
41999
+ var OKABE_ITO_HEX = {
42000
+ motion: "#b88128",
42001
+ audio: "#1096c8",
42002
+ recording: "#009e73",
42003
+ live: "#9c8c22",
42004
+ heatmapScrub: "#0072b2",
42005
+ person: "#d55e00",
42006
+ vehicle: "#c0739f",
42007
+ animal: "#226d18",
42008
+ package: "#91446c",
42009
+ sensor: "#217b56",
42010
+ control: "#648647",
42011
+ face: "#c22998",
42012
+ plate: "#fa4575",
42013
+ car: "#956301",
42014
+ truck: "#2f77f3",
42015
+ bus: "#7a4e86",
42016
+ motorcycle: "#f54597",
42017
+ bicycle: "#bb3e75",
42018
+ airplane: "#e054c0",
42019
+ boat: "#457942",
42020
+ train: "#867afa",
42021
+ bird: "#88914c",
42022
+ dog: "#1556cd",
42023
+ cat: "#71702c",
42024
+ horse: "#9b4fa4",
42025
+ sheep: "#c0559d",
42026
+ cow: "#d14f65",
42027
+ elephant: "#98470f",
42028
+ bear: "#595896",
42029
+ zebra: "#96790e",
42030
+ giraffe: "#cb717b",
42031
+ "package-delivered": "#139d8a",
42032
+ "package-picked-up": "#906ead",
42033
+ suitcase: "#d02939",
42034
+ backpack: "#d41160",
42035
+ handbag: "#f64f54",
42036
+ contact: "#7258d2",
42037
+ "motion-sensor": "#b66182",
42038
+ smoke: "#627abb",
42039
+ flood: "#b86ae4",
42040
+ gas: "#a95261",
42041
+ "carbon-monoxide": "#c65d3c",
42042
+ vibration: "#7a40b7",
42043
+ tamper: "#914b34",
42044
+ presence: "#9481c3",
42045
+ "enum-sensor": "#ac6d47",
42046
+ "device-event": "#7b6fce",
42047
+ lock: "#c67662",
42048
+ cover: "#a6564d",
42049
+ switch: "#ad2c4e",
42050
+ siren: "#348e08",
42051
+ button: "#d27303",
42052
+ doorbell: "#55770f"
42053
+ };
42054
+ var OKABE_ITO_FALLBACK = [
42055
+ "#9a3784",
42056
+ "#a7392c",
42057
+ "#409d50",
42058
+ "#6987e7",
42059
+ "#ee5b3d",
42060
+ "#c0430d",
42061
+ "#af79b3",
42062
+ "#4b6628"
42063
+ ];
42064
+ /**
42065
+ * The display palette (D939). One table of colours, three presets, one
42066
+ * validator. Taxonomy colours and every consumer read this — there is no
42067
+ * second hex table.
42068
+ */
42069
+ var paletteHexSchema = string().regex(/^#[0-9a-f]{6}$/);
42070
+ var paletteSwatchSchema = discriminatedUnion("form", [object({
42071
+ form: literal("solid"),
42072
+ hex: paletteHexSchema
42073
+ }), object({
42074
+ form: literal("gradient"),
42075
+ hex: paletteHexSchema,
42076
+ alphas: array(number().gt(0).lte(1)).length(AUDIO_GRADIENT_ALPHAS.length)
42077
+ })]);
42078
+ var paletteReadySchema = object({
42079
+ status: literal("ready"),
42080
+ presetId: _enum(PALETTE_PRESET_IDS),
42081
+ customized: boolean(),
42082
+ source: _enum(["stored", "unconfigured"]),
42083
+ swatches: record(string(), paletteSwatchSchema),
42084
+ fallbacks: array(paletteHexSchema).length(8)
42085
+ });
42086
+ var paletteResultSchema = discriminatedUnion("status", [paletteReadySchema, object({
42087
+ status: literal("unknown"),
42088
+ reason: string()
42089
+ })]);
42090
+ var setPaletteInputSchema = union([object({ presetId: string() }), object({
42091
+ presetId: string(),
42092
+ overrides: record(string(), paletteSwatchSchema)
42093
+ })]);
42094
+ object({
42095
+ presetId: string(),
42096
+ overrides: record(string(), paletteSwatchSchema)
42097
+ });
42098
+ function solid(hex) {
42099
+ return {
42100
+ form: "solid",
42101
+ hex
42102
+ };
42103
+ }
42104
+ function audioGradient(hex) {
42105
+ return {
42106
+ form: "gradient",
42107
+ hex,
42108
+ alphas: [...AUDIO_GRADIENT_ALPHAS]
42109
+ };
42110
+ }
42111
+ function swatchesFrom(hexes) {
42112
+ const out = {};
42113
+ for (const id of PALETTE_ENTRY_IDS) {
42114
+ const hex = hexes[id];
42115
+ if (hex === void 0) throw new Error(`palette table missing ${id}`);
42116
+ out[id] = id === "audio" ? audioGradient(hex) : solid(hex);
42117
+ }
42118
+ return out;
42119
+ }
42120
+ function preset(id, name, hexes, fallbacks) {
42121
+ return {
42122
+ id,
42123
+ name,
42124
+ swatches: swatchesFrom(hexes),
42125
+ fallbacks
42126
+ };
42127
+ }
42128
+ var DISPLAY_PRESETS = [
42129
+ preset("camstack", "CamStack", CAMSTACK_HEX, CAMSTACK_FALLBACK),
42130
+ preset("high-contrast", "High contrast", HIGH_CONTRAST_HEX, HIGH_CONTRAST_FALLBACK),
42131
+ preset("okabe-ito", "Colour-blind safe", OKABE_ITO_HEX, OKABE_ITO_FALLBACK)
42132
+ ];
42133
+ function presetById(id) {
42134
+ return DISPLAY_PRESETS.find((item) => item.id === id);
42135
+ }
42136
+ function bundledCamstack() {
42137
+ const presetRow = presetById("camstack");
42138
+ if (presetRow === void 0) throw new Error("CamStack preset missing");
42139
+ return readyOf(presetRow, "unconfigured", false);
42140
+ }
42141
+ function readyOf(row, source, customized) {
42142
+ return {
42143
+ status: "ready",
42144
+ presetId: row.id,
42145
+ customized,
42146
+ source,
42147
+ swatches: row.swatches,
42148
+ fallbacks: [...row.fallbacks]
42149
+ };
42150
+ }
42151
+ function hashFallback(kind, fallbacks) {
42152
+ let hash = 0;
42153
+ for (let i = 0; i < kind.length; i++) hash = hash * 31 + (kind.codePointAt(i) ?? 0) >>> 0;
42154
+ const hex = fallbacks[hash % fallbacks.length];
42155
+ if (hex === void 0) throw new Error("display palette has no fallback colour");
42156
+ return hex;
42157
+ }
42158
+ /** Colour a kind paints with. Audio leaves share the audio gradient's hex. */
42159
+ function paintHex(swatches, fallbacks, kind) {
42160
+ const key = kind.trim().toLowerCase();
42161
+ if (key.startsWith("audio-")) {
42162
+ const audio = swatches[AUDIO_ENTRY_ID];
42163
+ return audio !== void 0 ? audio.hex : hashFallback(key, fallbacks);
42164
+ }
42165
+ const direct = swatches[key];
42166
+ if (direct !== void 0) return direct.hex;
42167
+ return hashFallback(key, fallbacks);
42168
+ }
42169
+ /**
41776
42170
  * Unified event-kind taxonomy — THE single source of truth for
41777
42171
  * `kind → { parentKind, category, level, color, iconId, labelKey, label,
41778
42172
  * icon }`.
@@ -41786,109 +42180,88 @@ for (const [k, v] of Object.entries(APPLE_SA_TO_MACRO.mapping)) _macroLookup.set
41786
42180
  * - `addon-post-analysis/shared/frame/box-drawer.ts` (DEFAULT_COLOR)
41787
42181
  * - the COCO / audio class maps (macro ↔ sub relationships)
41788
42182
  *
41789
- * The DATA (serializable — color/iconId/labelKey/parentKind) lives here in
41790
- * `@camstack/types`. The UI-side mapping `iconId → lucide component` and
41791
- * `labelKey → t()` lives in `@camstack/ui-library`. UIs never hardcode a
41792
- * color or an icon: they read this dictionary (server descriptors carry the
41793
- * fields inline; the client resolves color/icon/label from `iconId`/`kind`).
42183
+ * The DATA (serializable — parentKind / iconId / labelKey) lives here in
42184
+ * `@camstack/types`. Colour is NOT a second table: each entry's `color` is
42185
+ * the bundled CamStack display palette (D939). The effective cluster palette
42186
+ * is the `display-palette` capability. The UI-side mapping `iconId → lucide
42187
+ * component` and `labelKey → t()` lives in `@camstack/ui-library`.
41794
42188
  *
41795
42189
  * Two levels only (v1 YAGNI): macro → sub. `person` is a leaf macro.
41796
42190
  */
41797
- var TAXONOMY_COLORS = {
41798
- motion: "#f59e0b",
41799
- audio: "#06b6d4",
41800
- person: "#22c55e",
41801
- vehicle: "#3b82f6",
41802
- animal: "#f97316",
41803
- package: "#a855f7",
41804
- sensor: "#8b5cf6",
41805
- control: "#10b981",
41806
- genericDetection: "#64748b"
41807
- };
41808
- var DETECTION_SUB_COLORS = {
41809
- car: "#f59e0b",
41810
- truck: "#d97706",
41811
- bus: "#b45309",
41812
- motorcycle: "#eab308",
41813
- bicycle: "#ca8a04",
41814
- airplane: "#60a5fa",
41815
- boat: "#2563eb",
41816
- train: "#1d4ed8",
41817
- bird: "#14b8a6",
41818
- dog: "#84cc16",
41819
- cat: "#f97316",
41820
- horse: "#a16207",
41821
- sheep: "#a3a3a3",
41822
- cow: "#78716c",
41823
- elephant: "#6b7280",
41824
- bear: "#7c2d12",
41825
- zebra: "#404040",
41826
- giraffe: "#d4a373"
41827
- };
42191
+ var BUNDLED_PALETTE = bundledCamstack();
42192
+ function kindColor(kind) {
42193
+ return paintHex(BUNDLED_PALETTE.swatches, BUNDLED_PALETTE.fallbacks, kind);
42194
+ }
42195
+ function firstFallback(fallbacks) {
42196
+ const hex = fallbacks[0];
42197
+ if (hex === void 0) throw new Error("display palette has no fallback colour");
42198
+ return hex;
42199
+ }
42200
+ firstFallback(BUNDLED_PALETTE.fallbacks);
41828
42201
  function titleCase(id) {
41829
42202
  return id.split(/[-_ ]/).filter((p) => p.length > 0).map((p) => p.charAt(0).toUpperCase() + p.slice(1)).join(" ");
41830
42203
  }
41831
42204
  var entries = /* @__PURE__ */ new Map();
41832
- function macro(kind, category, color, iconId, label) {
42205
+ function macro(kind, category, iconId, label) {
41833
42206
  entries.set(kind, {
41834
42207
  kind,
41835
42208
  parentKind: null,
41836
42209
  level: "macro",
41837
42210
  category,
41838
- color,
42211
+ color: kindColor(kind),
41839
42212
  iconId,
41840
42213
  labelKey: `eventKind.${kind}`,
41841
42214
  label
41842
42215
  });
41843
42216
  }
41844
- function sub(kind, parentKind, category, color, iconId, label) {
42217
+ function sub(kind, parentKind, category, iconId, label) {
41845
42218
  entries.set(kind, {
41846
42219
  kind,
41847
42220
  parentKind,
41848
42221
  level: "sub",
41849
42222
  category,
41850
- color,
42223
+ color: kindColor(kind),
41851
42224
  iconId,
41852
42225
  labelKey: `eventKind.${kind}`,
41853
42226
  label
41854
42227
  });
41855
42228
  }
41856
- macro("motion", "motion", TAXONOMY_COLORS.motion, "motion", "Motion");
41857
- macro("audio", "audio", TAXONOMY_COLORS.audio, "audio", "Audio");
41858
- macro("person", "detection", TAXONOMY_COLORS.person, "person", "Person");
41859
- macro("vehicle", "detection", TAXONOMY_COLORS.vehicle, "vehicle", "Vehicle");
41860
- macro("animal", "detection", TAXONOMY_COLORS.animal, "animal", "Animal");
41861
- macro("package", "package", TAXONOMY_COLORS.package, "package", "Package");
41862
- macro("sensor", "sensor", TAXONOMY_COLORS.sensor, "sensor", "Sensor");
41863
- macro("control", "control", TAXONOMY_COLORS.control, "control", "Control");
42229
+ macro("motion", "motion", "motion", "Motion");
42230
+ macro("audio", "audio", "audio", "Audio");
42231
+ macro("person", "detection", "person", "Person");
42232
+ macro("vehicle", "detection", "vehicle", "Vehicle");
42233
+ macro("animal", "detection", "animal", "Animal");
42234
+ macro("package", "package", "package", "Package");
42235
+ macro("sensor", "sensor", "sensor", "Sensor");
42236
+ macro("control", "control", "control", "Control");
41864
42237
  for (const [cocoClass, macroClass] of Object.entries(COCO_TO_MACRO.mapping)) {
41865
42238
  if (macroClass !== "vehicle" && macroClass !== "animal") continue;
41866
42239
  if (entries.has(cocoClass)) continue;
41867
- sub(cocoClass, macroClass, "detection", DETECTION_SUB_COLORS[cocoClass] ?? TAXONOMY_COLORS.genericDetection, cocoClass, titleCase(cocoClass));
42240
+ sub(cocoClass, macroClass, "detection", cocoClass, titleCase(cocoClass));
41868
42241
  }
41869
- sub("package-delivered", "package", "package", TAXONOMY_COLORS.package, "package", "Package delivered");
41870
- sub("package-picked-up", "package", "package", TAXONOMY_COLORS.package, "package", "Package picked up");
41871
- sub("contact", "sensor", "sensor", "#f59e0b", "door", "Contact");
41872
- sub("motion-sensor", "sensor", "sensor", TAXONOMY_COLORS.sensor, "pir", "Motion sensor");
41873
- sub("smoke", "sensor", "sensor", "#ef4444", "smoke", "Smoke");
41874
- sub("flood", "sensor", "sensor", "#3b82f6", "water", "Water leak");
41875
- sub("gas", "sensor", "sensor", "#ef4444", "gas", "Gas");
41876
- sub("carbon-monoxide", "sensor", "sensor", "#dc2626", "smoke", "Carbon monoxide");
41877
- sub("vibration", "sensor", "sensor", "#eab308", "vibration", "Vibration");
41878
- sub("tamper", "sensor", "sensor", "#f97316", "tamper", "Tamper");
41879
- sub("presence", "sensor", "sensor", "#22c55e", "presence", "Presence");
41880
- sub("enum-sensor", "sensor", "sensor", TAXONOMY_COLORS.sensor, "generic", "Sensor state");
41881
- sub("device-event", "sensor", "sensor", "#10b981", "button", "Device event");
41882
- sub("lock", "control", "control", "#0ea5e9", "lock", "Lock");
41883
- sub("cover", "control", "control", "#0ea5e9", "door", "Cover");
41884
- sub("switch", "control", "control", TAXONOMY_COLORS.control, "switch", "Switch");
41885
- sub("siren", "control", "control", "#dc2626", "siren", "Siren");
41886
- sub("button", "control", "control", "#10b981", "button", "Button");
41887
- sub("doorbell", "control", "control", "#a855f7", "doorbell", "Doorbell");
42242
+ sub("package-delivered", "package", "package", "package", "Package delivered");
42243
+ sub("package-picked-up", "package", "package", "package", "Package picked up");
42244
+ sub("contact", "sensor", "sensor", "door", "Contact");
42245
+ sub("motion-sensor", "sensor", "sensor", "pir", "Motion sensor");
42246
+ sub("smoke", "sensor", "sensor", "smoke", "Smoke");
42247
+ sub("flood", "sensor", "sensor", "water", "Water leak");
42248
+ sub("gas", "sensor", "sensor", "gas", "Gas");
42249
+ sub("carbon-monoxide", "sensor", "sensor", "smoke", "Carbon monoxide");
42250
+ sub("vibration", "sensor", "sensor", "vibration", "Vibration");
42251
+ sub("tamper", "sensor", "sensor", "tamper", "Tamper");
42252
+ sub("presence", "sensor", "sensor", "presence", "Presence");
42253
+ sub("enum-sensor", "sensor", "sensor", "generic", "Sensor state");
42254
+ sub("device-event", "sensor", "sensor", "button", "Device event");
42255
+ sub("lock", "control", "control", "lock", "Lock");
42256
+ sub("cover", "control", "control", "door", "Cover");
42257
+ sub("switch", "control", "control", "switch", "Switch");
42258
+ sub("siren", "control", "control", "siren", "Siren");
42259
+ sub("button", "control", "control", "button", "Button");
42260
+ sub("doorbell", "control", "control", "doorbell", "Doorbell");
41888
42261
  for (const l of AUDIO_MACRO_LABELS) {
41889
42262
  const kind = `audio-${l.id}`;
41890
42263
  if (entries.has(kind)) continue;
41891
- sub(kind, "audio", "audio", TAXONOMY_COLORS.audio, kind, l.name);
42264
+ sub(kind, "audio", "audio", kind, l.name);
41892
42265
  }
41893
42266
  /** The complete taxonomy dictionary, keyed by kind. */
41894
42267
  var EVENT_TAXONOMY = Object.freeze(Object.fromEntries(entries));
@@ -54287,7 +54660,8 @@ var BatteryStatusSchema = object({
54287
54660
  */
54288
54661
  binary: boolean().optional()
54289
54662
  });
54290
- DeviceType.Camera, DeviceType.Sensor, DeviceType.Button, DeviceType.Switch, DeviceType.PetFeeder, DeviceType.Container, DeviceType.Thermostat, method(object({
54663
+ DeviceType.Camera, DeviceType.Sensor, DeviceType.Button, DeviceType.Switch, DeviceType.PetFeeder, DeviceType.Container, DeviceType.Thermostat;
54664
+ method(object({
54291
54665
  deviceId: number(),
54292
54666
  /** Bound on the wait. Sensible range 3000–10000ms. */
54293
54667
  timeoutMs: number().int().min(500).max(3e4).default(8e3)
@@ -54996,6 +55370,7 @@ var ConsumablesStatusSchema = object({
54996
55370
  })),
54997
55371
  lastChangedAt: number()
54998
55372
  });
55373
+ Object.values(DeviceType), [...ConsumableRemainingUnitSchema.options], [...ConsumableStatusSchema.options], [...ConsumableKindSchema.options], [...ConsumableFormSchema.options];
54999
55374
  Object.values(DeviceType), method(object({
55000
55375
  deviceId: number().int().nonnegative(),
55001
55376
  key: string().min(1)
@@ -55188,6 +55563,30 @@ DeviceType.Camera, method(object({ deviceId: number() }), DayNightOptionsSchema)
55188
55563
  auth: "admin"
55189
55564
  });
55190
55565
  /**
55566
+ * display-palette — the cluster's one colour table (D939).
55567
+ *
55568
+ * Hub singleton. `getPalette` reports `unknown` when the settings store
55569
+ * cannot be read; it does not pretend the bundled preset was stored.
55570
+ * `setPalette` refuses a palette that fails the ΔE / contrast rule and names
55571
+ * the pairs.
55572
+ */
55573
+ var presetSummarySchema = object({
55574
+ id: string(),
55575
+ name: string(),
55576
+ swatches: record(string(), paletteSwatchSchema),
55577
+ fallbacks: array(string())
55578
+ });
55579
+ method(_void(), paletteResultSchema, {
55580
+ auth: "protected",
55581
+ role: "viewer"
55582
+ }), method(_void(), array(presetSummarySchema).readonly(), {
55583
+ auth: "protected",
55584
+ role: "viewer"
55585
+ }), method(setPaletteInputSchema, paletteReadySchema, {
55586
+ kind: "mutation",
55587
+ auth: "admin"
55588
+ });
55589
+ /**
55191
55590
  * Generic device-level status snapshot. Auto-registered by `BaseDevice`
55192
55591
  * for every device, regardless of provider — the kernel needs a uniform
55193
55592
  * cap-keyed slice for the basic device flags every consumer expects to
@@ -55467,6 +55866,7 @@ DeviceType.Dishwasher, method(object({
55467
55866
  kind: "mutation",
55468
55867
  auth: "protected"
55469
55868
  }), method(object({ deviceId: DeviceIdSchema }), DishwasherOptionsSchema, { auth: "protected" });
55869
+ DeviceType.Camera;
55470
55870
  object({
55471
55871
  /** Ms epoch of the last press. null = never observed since this provider started. */
55472
55872
  lastPressedAt: number().nullable(),
@@ -57259,6 +57659,7 @@ authKey: string().optional() }), object({
57259
57659
  /** Human-readable error when `ok: false`. */
57260
57660
  error: string().optional()
57261
57661
  }), { kind: "mutation" });
57662
+ DeviceType.Camera;
57262
57663
  object({
57263
57664
  detected: boolean(),
57264
57665
  /** Ms epoch of the last detected-true observation. Null if never detected. */
@@ -59392,7 +59793,8 @@ object({
59392
59793
  since: number().nullable(),
59393
59794
  source: RunningStateSourceSchema,
59394
59795
  phase: string().nullable(),
59395
- lastFetchedAt: number()
59796
+ /** null until a reading has been published (D393). */
59797
+ lastFetchedAt: number().nullable()
59396
59798
  });
59397
59799
  object({
59398
59800
  deviceId: number(),
@@ -59400,6 +59802,7 @@ object({
59400
59802
  phase: string().nullable()
59401
59803
  });
59402
59804
  Object.values(DeviceType);
59805
+ DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.MediaPlayer, DeviceType.WaterHeater, DeviceType.Humidifier, DeviceType.Fan, DeviceType.Climate, DeviceType.Thermostat, DeviceType.PetFeeder;
59403
59806
  DeviceType.Camera, DeviceType.Sensor, DeviceType.Switch, method(object({ deviceId: number().int().nonnegative() }), object({ success: literal(true) }), {
59404
59807
  kind: "mutation",
59405
59808
  auth: "admin"
@@ -66460,6 +66863,27 @@ Object.freeze({
66460
66863
  access: "create",
66461
66864
  role: "viewer"
66462
66865
  },
66866
+ "displayPalette.getPalette": {
66867
+ capName: "display-palette",
66868
+ capScope: "system",
66869
+ addonId: null,
66870
+ access: "view",
66871
+ role: "viewer"
66872
+ },
66873
+ "displayPalette.listPresets": {
66874
+ capName: "display-palette",
66875
+ capScope: "system",
66876
+ addonId: null,
66877
+ access: "view",
66878
+ role: "viewer"
66879
+ },
66880
+ "displayPalette.setPalette": {
66881
+ capName: "display-palette",
66882
+ capScope: "system",
66883
+ addonId: null,
66884
+ access: "create",
66885
+ role: "admin"
66886
+ },
66463
66887
  "doorbell.getStatus": {
66464
66888
  capName: "doorbell",
66465
66889
  capScope: "device",
@@ -76916,6 +77340,7 @@ var SYSTEM_CAP_VOCABULARY = {
76916
77340
  "device-provider": system(INTERNAL),
76917
77341
  "device-removal-hook": system(INTERNAL),
76918
77342
  "device-state": system("the runtime-state mirror every trigger already reads through"),
77343
+ "display-palette": system("the cluster display palette — one colour table for every client, not a device action"),
76919
77344
  "embedding-encoder": system(ML),
76920
77345
  "face-gallery": system("the face gallery — curated on its own page"),
76921
77346
  "failure-contribution": system(INTERNAL),
@@ -79800,6 +80225,96 @@ Object.freeze({
79800
80225
  "smtp-provider": "email"
79801
80226
  });
79802
80227
  DeviceType.Camera;
80228
+ DeviceType.Camera, DeviceType.Sensor, DeviceType.Button, DeviceType.Switch, DeviceType.PetFeeder, DeviceType.Container, DeviceType.Thermostat, DeviceType.Camera, DeviceType.Hub, DeviceType.Light, DeviceType.Siren, DeviceType.Switch, DeviceType.Sensor, DeviceType.Thermostat, DeviceType.Climate, DeviceType.Button, DeviceType.EventEmitter, DeviceType.Update, DeviceType.Generic, DeviceType.Notifier, DeviceType.Script, DeviceType.Automation, DeviceType.Lock, DeviceType.Cover, DeviceType.Valve, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.Fan, DeviceType.MediaPlayer, DeviceType.AlarmPanel, DeviceType.Control, DeviceType.Presence, DeviceType.Weather, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.Container, DeviceType.Image, DeviceType.PetFeeder, DeviceType.Dishwasher, DeviceType.Camera, DeviceType.Camera, DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.MediaPlayer, DeviceType.WaterHeater, DeviceType.Humidifier, DeviceType.Fan, DeviceType.Climate, DeviceType.Thermostat, DeviceType.PetFeeder;
80229
+ /**
80230
+ * A saved Customize assignment (D936). The schema is the type: callers use
80231
+ * `z.infer`, they do not restate the shape.
80232
+ */
80233
+ var OverrideSourceSchema = object({
80234
+ addonId: string().min(1),
80235
+ stableId: string().min(1),
80236
+ cap: string().min(1),
80237
+ fieldPath: string().min(1)
80238
+ });
80239
+ var CustomizeTransformDraftSchema = discriminatedUnion("kind", [
80240
+ object({ kind: literal("identity") }),
80241
+ object({ kind: literal("invert") }),
80242
+ object({
80243
+ kind: literal("threshold"),
80244
+ comparison: _enum(["gte", "lte"]),
80245
+ threshold: number(),
80246
+ startDwellMs: number().nonnegative(),
80247
+ stopDwellMs: number().nonnegative()
80248
+ }),
80249
+ object({
80250
+ kind: literal("linear"),
80251
+ scale: number(),
80252
+ offset: number(),
80253
+ clampMin: number().optional(),
80254
+ clampMax: number().optional()
80255
+ }),
80256
+ object({
80257
+ kind: literal("enum-map"),
80258
+ mapping: record(string(), string().nullable())
80259
+ }),
80260
+ object({ kind: literal("number") })
80261
+ ]);
80262
+ var ScalarOverrideDraftSchema = object({
80263
+ kind: literal("scalar"),
80264
+ cap: string().min(1),
80265
+ targetId: string().min(1),
80266
+ source: OverrideSourceSchema,
80267
+ transform: CustomizeTransformDraftSchema
80268
+ });
80269
+ var KeyedArrayOverrideDraftSchema = object({
80270
+ kind: literal("keyedArray"),
80271
+ cap: string().min(1),
80272
+ targetId: string().min(1),
80273
+ key: string().min(1),
80274
+ label: string().min(1),
80275
+ fieldPath: string().min(1),
80276
+ source: OverrideSourceSchema,
80277
+ transform: CustomizeTransformDraftSchema
80278
+ });
80279
+ var PulseOverrideDraftSchema = object({
80280
+ kind: literal("pulse"),
80281
+ cap: string().min(1),
80282
+ targetId: string().min(1),
80283
+ enabled: boolean(),
80284
+ debounceMs: number().nonnegative(),
80285
+ sources: array(OverrideSourceSchema).min(1)
80286
+ });
80287
+ var SpanSourceDraftSchema = OverrideSourceSchema.extend({ mode: _enum([
80288
+ "in-addition",
80289
+ "confirm",
80290
+ "replace"
80291
+ ]).optional() });
80292
+ discriminatedUnion("kind", [
80293
+ ScalarOverrideDraftSchema,
80294
+ KeyedArrayOverrideDraftSchema,
80295
+ PulseOverrideDraftSchema,
80296
+ object({
80297
+ kind: literal("span"),
80298
+ cap: string().min(1),
80299
+ targetId: string().min(1),
80300
+ timeoutMs: number().nonnegative(),
80301
+ cooldownMs: number().nonnegative().optional(),
80302
+ sources: array(SpanSourceDraftSchema)
80303
+ })
80304
+ ]);
80305
+ object({
80306
+ targetId: string().min(1),
80307
+ configured: boolean(),
80308
+ source: _enum(["native", "assigned"]),
80309
+ state: _enum([
80310
+ "active",
80311
+ "stale",
80312
+ "released",
80313
+ "unavailable"
80314
+ ]),
80315
+ reason: string().nullable()
80316
+ });
80317
+ String.raw`rose\(active(\d+), changed(\d+), (\d+(?:\.\d+)?)\)`;
79803
80318
  var G711_SCALE_CORRECTION_DB = {
79804
80319
  PCMU: 20 * Math.log10(4),
79805
80320
  PCMA: 20 * Math.log10(8)
@@ -84650,7 +85165,7 @@ var OsdManagerAddon = class extends BaseAddon {
84650
85165
  * collection cap. Mirrors the manifest `pages[]` entry — admin-ui's
84651
85166
  * `<AddonPageLoader>` loads `addon_osd_manager_page/page` from
84652
85167
  * `/api/addon-pages/osd-manager/remoteEntry.js`. Modeled directly on
84653
- * `addon-benchmark` / `addon-model-studio` (docs/roadmap.md 4d).
85168
+ * `addon-benchmark` / `addon-model-studio` (former roadmap item 4d).
84654
85169
  */
84655
85170
  pages = [{
84656
85171
  id: "osd-manager",