@camstack/ui-library 1.2.257 → 1.2.258

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 (375) hide show
  1. package/dist/composites/accelerator-label.d.ts +9 -9
  2. package/dist/composites/adaptive-downlink.d.ts +141 -143
  3. package/dist/composites/addon-global-settings-form.d.ts +73 -60
  4. package/dist/composites/addon-page-props.d.ts +34 -10
  5. package/dist/composites/agent-step-editor.d.ts +48 -47
  6. package/dist/composites/app-shell/app-shell.d.ts +17 -17
  7. package/dist/composites/app-shell/index.d.ts +3 -3
  8. package/dist/composites/app-shell/sidebar-item.d.ts +9 -8
  9. package/dist/composites/app-shell/sidebar.d.ts +10 -10
  10. package/dist/composites/audio-classification-list.d.ts +16 -15
  11. package/dist/composites/audio-level-waveform.d.ts +31 -30
  12. package/dist/composites/audio-waveform.d.ts +18 -17
  13. package/dist/composites/battery-badge.d.ts +27 -13
  14. package/dist/composites/breadcrumb.d.ts +21 -21
  15. package/dist/composites/camera-stream-player.d.ts +309 -309
  16. package/dist/composites/cap-settings/AutotrackSection.d.ts +19 -2
  17. package/dist/composites/cap-settings/CameraGridLayoutEditor.d.ts +24 -2
  18. package/dist/composites/cap-settings/ConsumablesPanel.d.ts +21 -2
  19. package/dist/composites/cap-settings/CoverageTrack.d.ts +21 -20
  20. package/dist/composites/cap-settings/EventBucketStrip.d.ts +21 -20
  21. package/dist/composites/cap-settings/EventHeatmap.d.ts +8 -7
  22. package/dist/composites/cap-settings/HomePresetPicker.d.ts +2 -2
  23. package/dist/composites/cap-settings/MaskShapeCanvas.d.ts +143 -41
  24. package/dist/composites/cap-settings/MotionZonesSettings.d.ts +41 -2
  25. package/dist/composites/cap-settings/NavigationPanel.d.ts +14 -2
  26. package/dist/composites/cap-settings/PrivacyMaskSettings.d.ts +3 -2
  27. package/dist/composites/cap-settings/PtzPanel.d.ts +15 -2
  28. package/dist/composites/cap-settings/RecordingBandsEditor.d.ts +33 -32
  29. package/dist/composites/cap-settings/RecordingPanel.d.ts +3 -2
  30. package/dist/composites/cap-settings/RecordingSettings.d.ts +11 -10
  31. package/dist/composites/cap-settings/RecordingTimeline.d.ts +3 -2
  32. package/dist/composites/cap-settings/SceneMonitorEditor.d.ts +3 -51
  33. package/dist/composites/cap-settings/SceneReferenceGallery.d.ts +62 -23
  34. package/dist/composites/cap-settings/SceneSettingsForm.d.ts +52 -16
  35. package/dist/composites/cap-settings/TimelineControls.d.ts +21 -20
  36. package/dist/composites/cap-settings/camera-grid-layout.d.ts +95 -95
  37. package/dist/composites/cap-settings/event-thumb.d.ts +9 -8
  38. package/dist/composites/cap-settings/index.d.ts +20 -20
  39. package/dist/composites/cap-settings/privacy-mask-audio.d.ts +47 -47
  40. package/dist/composites/cap-settings/recording-config-form.d.ts +25 -25
  41. package/dist/composites/cap-settings/recording-spans.d.ts +14 -14
  42. package/dist/composites/cap-settings/recording-timeline-model.d.ts +57 -57
  43. package/dist/composites/cap-settings/scene-monitor-copy.d.ts +58 -49
  44. package/dist/composites/client-network-sample.d.ts +41 -41
  45. package/dist/composites/clips/ClipBandBar.d.ts +44 -14
  46. package/dist/composites/clips/ClipPanel.d.ts +30 -6
  47. package/dist/composites/clips/ClipTile.d.ts +26 -5
  48. package/dist/composites/clips/ClipsSection.d.ts +107 -2
  49. package/dist/composites/clips/clip-band.d.ts +72 -38
  50. package/dist/composites/clips/clip-day-window.d.ts +7 -30
  51. package/dist/composites/clips/clip-source-state.d.ts +55 -26
  52. package/dist/composites/clips/clip-still-retry.d.ts +39 -39
  53. package/dist/composites/clips/clip-thumbnail-fetch.d.ts +9 -9
  54. package/dist/composites/clips/clip-tile-media.d.ts +64 -32
  55. package/dist/composites/clips/clip-view-state.d.ts +76 -46
  56. package/dist/composites/code-block.d.ts +5 -4
  57. package/dist/composites/config-form-builder.d.ts +14 -13
  58. package/dist/composites/config-form-field.d.ts +63 -62
  59. package/dist/composites/config-icon-field.d.ts +10 -9
  60. package/dist/composites/config-secret-field.d.ts +51 -27
  61. package/dist/composites/confirm-action-button.d.ts +52 -39
  62. package/dist/composites/confirm-dialog.d.ts +110 -48
  63. package/dist/composites/copy-button.d.ts +25 -19
  64. package/dist/composites/data-table/data-table-header.d.ts +8 -7
  65. package/dist/composites/data-table/data-table-pagination.d.ts +7 -6
  66. package/dist/composites/data-table/data-table-row.d.ts +8 -7
  67. package/dist/composites/data-table/data-table.d.ts +3 -2
  68. package/dist/composites/data-table/index.d.ts +2 -2
  69. package/dist/composites/data-table/types.d.ts +29 -29
  70. package/dist/composites/data-table-filter-bar.d.ts +30 -29
  71. package/dist/composites/data-table-filter.d.ts +34 -34
  72. package/dist/composites/data-table-layout.d.ts +24 -24
  73. package/dist/composites/data-table-pager.d.ts +5 -5
  74. package/dist/composites/data-table-pagination.d.ts +23 -23
  75. package/dist/composites/data-table-selection.d.ts +10 -10
  76. package/dist/composites/data-table.d.ts +167 -118
  77. package/dist/composites/detection-canvas.d.ts +34 -25
  78. package/dist/composites/detection-colors.d.ts +9 -9
  79. package/dist/composites/detection-overlay.d.ts +33 -32
  80. package/dist/composites/detection-result-tree.d.ts +22 -9
  81. package/dist/composites/dev-shell.d.ts +15 -14
  82. package/dist/composites/device-activity-panel.d.ts +37 -31
  83. package/dist/composites/device-card.d.ts +32 -32
  84. package/dist/composites/device-controls/ac-panel.d.ts +2 -2
  85. package/dist/composites/device-controls/alarm-hero-card.d.ts +42 -42
  86. package/dist/composites/device-controls/atoms.d.ts +50 -50
  87. package/dist/composites/device-controls/brightness-panel.d.ts +3 -3
  88. package/dist/composites/device-controls/button-control.d.ts +14 -14
  89. package/dist/composites/device-controls/climate-panel.d.ts +12 -12
  90. package/dist/composites/device-controls/container-primary-hero.d.ts +33 -16
  91. package/dist/composites/device-controls/container-primary.d.ts +68 -39
  92. package/dist/composites/device-controls/control-panel.d.ts +4 -4
  93. package/dist/composites/device-controls/control-registry.d.ts +81 -70
  94. package/dist/composites/device-controls/cover-hero-card.d.ts +26 -26
  95. package/dist/composites/device-controls/cover-inline.d.ts +20 -20
  96. package/dist/composites/device-controls/cover-panel.d.ts +2 -2
  97. package/dist/composites/device-controls/dummy-hero-card.d.ts +2 -2
  98. package/dist/composites/device-controls/fan-hero-card.d.ts +20 -20
  99. package/dist/composites/device-controls/fan-panel.d.ts +3 -3
  100. package/dist/composites/device-controls/humidifier-control.d.ts +46 -29
  101. package/dist/composites/device-controls/image-control.d.ts +41 -27
  102. package/dist/composites/device-controls/index.d.ts +34 -34
  103. package/dist/composites/device-controls/lawn-mower-control.d.ts +30 -16
  104. package/dist/composites/device-controls/light-hero-card.d.ts +15 -15
  105. package/dist/composites/device-controls/lock-hero-card.d.ts +14 -14
  106. package/dist/composites/device-controls/lock-panel.d.ts +3 -3
  107. package/dist/composites/device-controls/media-player-hero-card.d.ts +16 -16
  108. package/dist/composites/device-controls/media-player-panel.d.ts +7 -7
  109. package/dist/composites/device-controls/offline-badge.d.ts +23 -8
  110. package/dist/composites/device-controls/panel-controls.d.ts +39 -20
  111. package/dist/composites/device-controls/pet-feeder-panel.d.ts +27 -9
  112. package/dist/composites/device-controls/popover-row-action.d.ts +18 -6
  113. package/dist/composites/device-controls/primary-child-picker.d.ts +31 -15
  114. package/dist/composites/device-controls/primary-child.d.ts +14 -25
  115. package/dist/composites/device-controls/radial-gauge.d.ts +17 -17
  116. package/dist/composites/device-controls/script-automation-controls.d.ts +9 -9
  117. package/dist/composites/device-controls/sensor-hero-card.d.ts +26 -8
  118. package/dist/composites/device-controls/sensor-inline-control.d.ts +21 -9
  119. package/dist/composites/device-controls/sensor-value-atom.d.ts +97 -76
  120. package/dist/composites/device-controls/switch-hero-card.d.ts +11 -11
  121. package/dist/composites/device-controls/switch-panel.d.ts +2 -2
  122. package/dist/composites/device-controls/tap-toggle.d.ts +13 -13
  123. package/dist/composites/device-controls/thermostat-hero-card.d.ts +16 -16
  124. package/dist/composites/device-controls/types.d.ts +11 -11
  125. package/dist/composites/device-controls/update-control.d.ts +20 -7
  126. package/dist/composites/device-controls/vacuum-control.d.ts +41 -25
  127. package/dist/composites/device-controls/valve-control.d.ts +51 -35
  128. package/dist/composites/device-controls/water-heater-control.d.ts +48 -31
  129. package/dist/composites/device-controls/weather-control.d.ts +46 -28
  130. package/dist/composites/device-export-panel.d.ts +34 -34
  131. package/dist/composites/device-grid.d.ts +10 -10
  132. package/dist/composites/device-item/actions.d.ts +40 -18
  133. package/dist/composites/device-item/admin-link-quick-action.d.ts +66 -26
  134. package/dist/composites/device-item/child-layout.d.ts +43 -26
  135. package/dist/composites/device-item/child-section-accordion.d.ts +20 -6
  136. package/dist/composites/device-item/children-accordion.d.ts +11 -11
  137. package/dist/composites/device-item/container-children-context.d.ts +28 -11
  138. package/dist/composites/device-item/device-delete-action.d.ts +23 -5
  139. package/dist/composites/device-item/features.d.ts +33 -15
  140. package/dist/composites/device-item/header.d.ts +53 -31
  141. package/dist/composites/device-item/helpers.d.ts +291 -274
  142. package/dist/composites/device-item/index.d.ts +18 -9
  143. package/dist/composites/device-item/preview.d.ts +41 -21
  144. package/dist/composites/device-item/quick-detail-action.d.ts +4 -4
  145. package/dist/composites/device-item/reboot-quick-action.d.ts +28 -7
  146. package/dist/composites/device-item/role-display-defaults-context.d.ts +28 -12
  147. package/dist/composites/device-item/status-dot.d.ts +24 -6
  148. package/dist/composites/device-list/batch-actions-bar.d.ts +23 -12
  149. package/dist/composites/device-list/batch-toolbar.d.ts +13 -13
  150. package/dist/composites/device-list/columns.d.ts +108 -108
  151. package/dist/composites/device-list/device-integration.d.ts +48 -58
  152. package/dist/composites/device-list/device-mode.d.ts +121 -121
  153. package/dist/composites/device-list/empty-state.d.ts +14 -3
  154. package/dist/composites/device-list/filter-chips.d.ts +42 -29
  155. package/dist/composites/device-list/fuzzy-match.d.ts +22 -22
  156. package/dist/composites/device-list/generic-mode.d.ts +88 -88
  157. package/dist/composites/device-list/group.d.ts +62 -35
  158. package/dist/composites/device-list/hardware-cell.d.ts +14 -3
  159. package/dist/composites/device-list/hardware.d.ts +29 -11
  160. package/dist/composites/device-list/icon-action.d.ts +27 -15
  161. package/dist/composites/device-list/index.d.ts +46 -23
  162. package/dist/composites/device-list/multi-select.d.ts +17 -17
  163. package/dist/composites/device-list/page-size-select.d.ts +13 -7
  164. package/dist/composites/device-list/pagination.d.ts +19 -12
  165. package/dist/composites/device-list/sort.d.ts +28 -15
  166. package/dist/composites/device-list/sortable-header.d.ts +20 -7
  167. package/dist/composites/device-list/table-layout.d.ts +44 -44
  168. package/dist/composites/device-list/type-filter.d.ts +16 -16
  169. package/dist/composites/device-list/url-state.d.ts +35 -35
  170. package/dist/composites/device-meta.d.ts +43 -43
  171. package/dist/composites/device-picker/DevicePicker.d.ts +72 -33
  172. package/dist/composites/device-picker/SelectedChip.d.ts +10 -9
  173. package/dist/composites/device-picker/device-filter-bar.d.ts +19 -18
  174. package/dist/composites/device-picker/device-fleet-view.d.ts +11 -3
  175. package/dist/composites/device-picker/device-parent.d.ts +27 -27
  176. package/dist/composites/device-picker/device-picker-grouping.d.ts +3 -3
  177. package/dist/composites/device-picker/device-picker-model.d.ts +140 -140
  178. package/dist/composites/device-picker/device-selection-rows.d.ts +31 -24
  179. package/dist/composites/device-picker/device-selection.d.ts +43 -43
  180. package/dist/composites/device-picker/index.d.ts +9 -9
  181. package/dist/composites/device-select-field.d.ts +17 -16
  182. package/dist/composites/device-select-filter.d.ts +78 -78
  183. package/dist/composites/device-selector-picker.d.ts +25 -25
  184. package/dist/composites/device-step-matrix.d.ts +54 -28
  185. package/dist/composites/discovery-panel.d.ts +22 -22
  186. package/dist/composites/doorbell-recent-panel.d.ts +9 -8
  187. package/dist/composites/empty-state.d.ts +8 -8
  188. package/dist/composites/error-box.d.ts +32 -17
  189. package/dist/composites/event-kind-visuals.d.ts +29 -18
  190. package/dist/composites/event-stream.d.ts +59 -42
  191. package/dist/composites/extensions/AssociationSlotCard.d.ts +45 -24
  192. package/dist/composites/extensions/ExtensionsPanel.d.ts +41 -18
  193. package/dist/composites/extensions/extensions-view-state.d.ts +71 -53
  194. package/dist/composites/filter-bar.d.ts +22 -21
  195. package/dist/composites/form-field.d.ts +9 -9
  196. package/dist/composites/format-state-value.d.ts +23 -51
  197. package/dist/composites/grouped-model-selector.d.ts +7 -6
  198. package/dist/composites/hls-quality.d.ts +26 -26
  199. package/dist/composites/hls-video.d.ts +62 -39
  200. package/dist/composites/hover-zoom-image.d.ts +35 -16
  201. package/dist/composites/icon-picker.d.ts +86 -50
  202. package/dist/composites/image-selector.d.ts +21 -20
  203. package/dist/composites/index.d.ts +204 -204
  204. package/dist/composites/inference-config-selector.d.ts +36 -35
  205. package/dist/composites/kebab-menu.d.ts +53 -35
  206. package/dist/composites/key-value-list.d.ts +14 -14
  207. package/dist/composites/log-stream-scroll.d.ts +24 -24
  208. package/dist/composites/log-stream.d.ts +81 -70
  209. package/dist/composites/login-form.d.ts +7 -6
  210. package/dist/composites/model-bound-slider.d.ts +46 -26
  211. package/dist/composites/model-picker.d.ts +20 -19
  212. package/dist/composites/mount-addon-page.d.ts +12 -12
  213. package/dist/composites/network-link-badge.d.ts +7 -6
  214. package/dist/composites/node-picker.d.ts +14 -13
  215. package/dist/composites/notification-targets-field.d.ts +76 -58
  216. package/dist/composites/notification-targets-options.d.ts +9 -6
  217. package/dist/composites/option-select/OptionSelect.d.ts +23 -22
  218. package/dist/composites/option-select/index.d.ts +4 -4
  219. package/dist/composites/option-select/option-select-model.d.ts +35 -35
  220. package/dist/composites/page-header.d.ts +6 -6
  221. package/dist/composites/peer-connection-config.d.ts +9 -9
  222. package/dist/composites/phase-icon.d.ts +10 -3
  223. package/dist/composites/pipeline-builder.d.ts +21 -13
  224. package/dist/composites/pipeline-matrix-shared.d.ts +159 -150
  225. package/dist/composites/pipeline-runtime-selector.d.ts +12 -11
  226. package/dist/composites/pipeline-step.d.ts +39 -31
  227. package/dist/composites/placeholder-field/PlaceholderChipField.d.ts +23 -22
  228. package/dist/composites/placeholder-field/index.d.ts +1 -1
  229. package/dist/composites/provider-badge.d.ts +6 -5
  230. package/dist/composites/ptz-overlay.d.ts +38 -18
  231. package/dist/composites/qr-code.d.ts +24 -10
  232. package/dist/composites/reconnect-schedule.d.ts +22 -22
  233. package/dist/composites/resolve-step-default-model.d.ts +94 -94
  234. package/dist/composites/response-log.d.ts +7 -6
  235. package/dist/composites/root-model-source.d.ts +21 -10
  236. package/dist/composites/scope-picker.d.ts +49 -25
  237. package/dist/composites/section-card.d.ts +19 -11
  238. package/dist/composites/setting-row.d.ts +39 -21
  239. package/dist/composites/snapshot-button.d.ts +23 -19
  240. package/dist/composites/sort-header-button.d.ts +25 -8
  241. package/dist/composites/stat-card.d.ts +20 -8
  242. package/dist/composites/state-values-stream.d.ts +49 -24
  243. package/dist/composites/status-badge.d.ts +10 -8
  244. package/dist/composites/step-inspector/gate-control.d.ts +13 -12
  245. package/dist/composites/step-inspector/index.d.ts +8 -8
  246. package/dist/composites/step-inspector/layered-settings-form.d.ts +41 -30
  247. package/dist/composites/step-inspector/segmented-choice.d.ts +8 -7
  248. package/dist/composites/step-inspector/setting-values.d.ts +13 -8
  249. package/dist/composites/step-inspector/step-detail-dock.d.ts +39 -23
  250. package/dist/composites/step-inspector/step-inspector-panel.d.ts +34 -28
  251. package/dist/composites/step-inspector/step-model-row.d.ts +29 -24
  252. package/dist/composites/step-inspector/step-search.d.ts +11 -11
  253. package/dist/composites/step-timings.d.ts +7 -6
  254. package/dist/composites/step-tree.d.ts +17 -12
  255. package/dist/composites/stream-broker-selector.d.ts +29 -8
  256. package/dist/composites/stream-debug/stream-debug-overlay.d.ts +40 -40
  257. package/dist/composites/stream-debug/webrtc-debug-stats.d.ts +144 -129
  258. package/dist/composites/stream-panel.d.ts +212 -201
  259. package/dist/composites/table-sort.d.ts +61 -61
  260. package/dist/composites/timezone-selector.d.ts +15 -13
  261. package/dist/composites/training/send-frame-to-training.d.ts +5 -4
  262. package/dist/composites/training/training-collection-picker.d.ts +4 -3
  263. package/dist/composites/training/training-refusal-text.d.ts +6 -6
  264. package/dist/composites/unit-picker/UnitPicker.d.ts +19 -14
  265. package/dist/composites/unit-picker/index.d.ts +1 -1
  266. package/dist/composites/use-data-table-filter.d.ts +19 -19
  267. package/dist/composites/version-badge.d.ts +19 -18
  268. package/dist/composites/webrtc-diagnostics/EndpointTestCard.d.ts +7 -7
  269. package/dist/composites/webrtc-diagnostics/HubSessionTestCard.d.ts +14 -14
  270. package/dist/composites/webrtc-diagnostics/RunReport.d.ts +10 -5
  271. package/dist/composites/webrtc-diagnostics/endpoint-probe.d.ts +41 -21
  272. package/dist/composites/webrtc-diagnostics/endpoint-test.d.ts +37 -32
  273. package/dist/composites/webrtc-diagnostics/format.d.ts +3 -3
  274. package/dist/composites/webrtc-diagnostics/ice-candidates.d.ts +49 -49
  275. package/dist/composites/webrtc-diagnostics/nat-mapping.d.ts +36 -36
  276. package/dist/composites/webrtc-diagnostics/session-run.d.ts +108 -95
  277. package/dist/composites/webrtc-diagnostics/session-verdict.d.ts +29 -20
  278. package/dist/composites/widget-panel.d.ts +23 -23
  279. package/dist/composites/widget-slot.d.ts +35 -17
  280. package/dist/contexts/custom-field-renderers.d.ts +53 -17
  281. package/dist/contexts/device-context.d.ts +32 -12
  282. package/dist/contexts/device-quick-detail.d.ts +13 -4
  283. package/dist/contexts/player-overlays.d.ts +82 -42
  284. package/dist/contexts/recorded-playback.d.ts +40 -18
  285. package/dist/contexts/system-context.d.ts +28 -13
  286. package/dist/contexts/vod-playback.d.ts +39 -22
  287. package/dist/contexts/widget-registry.d.ts +139 -102
  288. package/dist/contexts/zone-editing.d.ts +69 -46
  289. package/dist/generated/system-hooks.d.ts +17 -1
  290. package/dist/hooks/index.d.ts +43 -43
  291. package/dist/hooks/turn-server-cache.d.ts +69 -69
  292. package/dist/hooks/use-capability-presence.d.ts +65 -28
  293. package/dist/hooks/use-cluster-nodes.d.ts +54 -27
  294. package/dist/hooks/use-device-autotrack.d.ts +7 -7
  295. package/dist/hooks/use-device-battery.d.ts +24 -11
  296. package/dist/hooks/use-device-cap-slice.d.ts +15 -15
  297. package/dist/hooks/use-device-capability.d.ts +61 -27
  298. package/dist/hooks/use-device-detections.d.ts +32 -32
  299. package/dist/hooks/use-device-features.d.ts +18 -18
  300. package/dist/hooks/use-device-list-page-size.d.ts +19 -6
  301. package/dist/hooks/use-device-network-link.d.ts +15 -7
  302. package/dist/hooks/use-device-proxy.d.ts +98 -92
  303. package/dist/hooks/use-device-snapshot.d.ts +23 -23
  304. package/dist/hooks/use-device-webrtc.d.ts +211 -205
  305. package/dist/hooks/use-devices.d.ts +9 -9
  306. package/dist/hooks/use-doorbell-events.d.ts +13 -13
  307. package/dist/hooks/use-event-stream.d.ts +6 -3
  308. package/dist/hooks/use-is-mobile.d.ts +5 -5
  309. package/dist/hooks/use-live-buffer.d.ts +5 -5
  310. package/dist/hooks/use-live-event.d.ts +1 -1
  311. package/dist/hooks/use-navigation.d.ts +20 -20
  312. package/dist/hooks/use-optimistic-slice.d.ts +13 -13
  313. package/dist/hooks/use-persisted-page-size.d.ts +10 -10
  314. package/dist/hooks/use-ptz.d.ts +108 -108
  315. package/dist/hooks/use-stationary-overlay.d.ts +37 -37
  316. package/dist/hooks/use-system-query.d.ts +33 -10
  317. package/dist/hooks/use-url-query.d.ts +3 -3
  318. package/dist/icons/index.d.ts +2 -2
  319. package/dist/icons/provider-icons.d.ts +2 -2
  320. package/dist/icons/status-icons.d.ts +2 -2
  321. package/dist/index.cjs +123 -69
  322. package/dist/index.d.ts +31 -27
  323. package/dist/index.js +123 -69
  324. package/dist/lib/cap-error.d.ts +18 -39
  325. package/dist/lib/cn.d.ts +1 -1
  326. package/dist/lib/fleet-query-defaults.d.ts +68 -34
  327. package/dist/lib/format-control-datetime.d.ts +16 -16
  328. package/dist/lib/format-duration.d.ts +12 -12
  329. package/dist/lib/format-last-seen.d.ts +5 -18
  330. package/dist/lib/format-numeric.d.ts +7 -7
  331. package/dist/lib/hub-mount.d.ts +8 -42
  332. package/dist/lib/index.d.ts +21 -21
  333. package/dist/lib/phase-config.d.ts +24 -11
  334. package/dist/lib/pipeline-mirror.d.ts +16 -16
  335. package/dist/lib/recorded-control-protocol.d.ts +41 -43
  336. package/dist/lib/resolve-sensor-display.d.ts +36 -20
  337. package/dist/lib/responsive.d.ts +54 -54
  338. package/dist/lib/scrub-controller.d.ts +75 -78
  339. package/dist/lib/shared-context.d.ts +27 -2
  340. package/dist/lib/tailwind-variants.d.ts +20 -20
  341. package/dist/primitives/badge.d.ts +5 -10
  342. package/dist/primitives/bottom-sheet.d.ts +7 -7
  343. package/dist/primitives/button.d.ts +5 -9
  344. package/dist/primitives/card.d.ts +4 -8
  345. package/dist/primitives/checkbox.d.ts +3 -4
  346. package/dist/primitives/collapsible-card.d.ts +23 -13
  347. package/dist/primitives/dialog.d.ts +33 -59
  348. package/dist/primitives/dropdown.d.ts +13 -13
  349. package/dist/primitives/floating-panel.d.ts +41 -20
  350. package/dist/primitives/icon-button.d.ts +8 -12
  351. package/dist/primitives/index.d.ts +22 -22
  352. package/dist/primitives/input.d.ts +6 -16
  353. package/dist/primitives/label.d.ts +3 -4
  354. package/dist/primitives/mobile-drawer.d.ts +8 -8
  355. package/dist/primitives/password-input.d.ts +18 -18
  356. package/dist/primitives/popover.d.ts +7 -7
  357. package/dist/primitives/scroll-area.d.ts +3 -4
  358. package/dist/primitives/select.d.ts +20 -20
  359. package/dist/primitives/separator.d.ts +4 -8
  360. package/dist/primitives/skeleton.d.ts +3 -4
  361. package/dist/primitives/switch.d.ts +6 -6
  362. package/dist/primitives/tabs.d.ts +26 -26
  363. package/dist/primitives/tooltip.d.ts +12 -12
  364. package/dist/theme/create-theme.d.ts +1 -1
  365. package/dist/theme/defaults.d.ts +1 -1
  366. package/dist/theme/index.d.ts +6 -6
  367. package/dist/theme/theme-provider.d.ts +8 -7
  368. package/dist/theme/theme-to-css.d.ts +1 -1
  369. package/dist/theme/types.d.ts +98 -100
  370. package/dist/theme/use-theme-mode.d.ts +1 -1
  371. package/dist/trpc-react.d.ts +23 -3
  372. package/dist/widgets/host-widgets.d.ts +4 -4
  373. package/package.json +8 -4
  374. package/src/tailwind/camstack-theme.css +11 -0
  375. package/dist/composites/unit-picker/UnitPicker.spec.d.ts +0 -1
package/dist/index.js CHANGED
@@ -10693,7 +10693,10 @@ var IconButton = forwardRef(({ className, variant, size, icon: Icon, ...props },
10693
10693
  size
10694
10694
  }), className),
10695
10695
  ...props,
10696
- children: /* @__PURE__ */ jsx(Icon, { className: "h-4 w-4" })
10696
+ children: /* @__PURE__ */ jsx(Icon, {
10697
+ className: "h-4 w-4",
10698
+ "aria-hidden": "true"
10699
+ })
10697
10700
  });
10698
10701
  });
10699
10702
  IconButton.displayName = "IconButton";
@@ -10714,19 +10717,19 @@ var inputVariants = cva("h-7 w-full px-2.5 text-xs bg-surface border rounded-md
10714
10717
  });
10715
10718
  var Input = forwardRef(({ className, state, leftSlot, rightSlot, ...props }, ref) => {
10716
10719
  if (leftSlot || rightSlot) return /* @__PURE__ */ jsxs("div", {
10717
- className: "relative flex items-center w-full",
10720
+ className: cn("relative flex items-center", className),
10718
10721
  children: [
10719
10722
  leftSlot && /* @__PURE__ */ jsx("div", {
10720
- className: "absolute left-2.5 flex items-center pointer-events-none",
10723
+ className: "absolute left-2.5 flex items-center text-foreground-subtle pointer-events-none",
10721
10724
  children: leftSlot
10722
10725
  }),
10723
10726
  /* @__PURE__ */ jsx("input", {
10724
10727
  ref,
10725
- className: cn(inputVariants({ state }), leftSlot ? "pl-7" : "", rightSlot ? "pr-7" : "", className),
10728
+ className: cn(inputVariants({ state }), leftSlot && "pl-8", rightSlot && "pr-8", className),
10726
10729
  ...props
10727
10730
  }),
10728
10731
  rightSlot && /* @__PURE__ */ jsx("div", {
10729
- className: "absolute right-2.5 flex items-center pointer-events-none",
10732
+ className: "absolute right-2.5 flex items-center text-foreground-subtle",
10730
10733
  children: rightSlot
10731
10734
  })
10732
10735
  ]
@@ -30702,16 +30705,6 @@ function resolveEffectiveStepModel(input) {
30702
30705
  }
30703
30706
  //#endregion
30704
30707
  //#region src/composites/root-model-source.tsx
30705
- /**
30706
- * "Use the root model" — the step editor's control for a step the camera's
30707
- * ROOT detection model can supply (D730).
30708
- *
30709
- * The flag (`useRootModel`, in the step's own settings) is an operator INTENT
30710
- * kept beside the step's model: checking it never changes the model, and a
30711
- * root that cannot supply the step leaves the step running its own model while
30712
- * the flag waits, inactive, for a root that can. Whether it is in force is
30713
- * `resolveRootSupply` — the same function the runner decides with.
30714
- */
30715
30708
  /** The editor's view of the flag for one step, or `null` for a step no root can supply. */
30716
30709
  function rootSourceState(stepId, settings, rootModel) {
30717
30710
  if (!isRootSuppliableStepId(stepId)) return null;
@@ -31663,6 +31656,7 @@ var Separator = forwardRef(({ className, orientation, ...props }, ref) => {
31663
31656
  return /* @__PURE__ */ jsx("div", {
31664
31657
  ref,
31665
31658
  role: "separator",
31659
+ "aria-orientation": orientation ?? "horizontal",
31666
31660
  className: cn(separatorVariants({ orientation }), className),
31667
31661
  ...props
31668
31662
  });
@@ -31964,15 +31958,27 @@ var ScrollArea = forwardRef(({ className, ...props }, ref) => {
31964
31958
  ScrollArea.displayName = "ScrollArea";
31965
31959
  //#endregion
31966
31960
  //#region src/primitives/floating-panel.tsx
31967
- function FloatingPanel({ title, onClose, children, defaultWidth = 360, defaultHeight = 280, minWidth = 280, minHeight = 160, offsetIndex = 0, className }) {
31968
- const [pos, setPos] = useState({
31961
+ function FloatingPanel({ title, icon: Icon, position, onPositionChange, size: controlledSize, onSizeChange, onClose, children, defaultWidth = 360, defaultHeight = 280, minWidth = 280, minHeight = 160, offsetIndex = 0, className }) {
31962
+ const [ownPos, setOwnPos] = useState({
31969
31963
  x: 80 + offsetIndex * 30,
31970
31964
  y: 80 + offsetIndex * 30
31971
31965
  });
31972
- const [size, setSize] = useState({
31966
+ const [ownSize, setOwnSize] = useState({
31973
31967
  w: defaultWidth,
31974
31968
  h: defaultHeight
31975
31969
  });
31970
+ const pos = position ?? ownPos;
31971
+ const size = controlledSize ?? ownSize;
31972
+ const latest = useRef({
31973
+ size,
31974
+ onPositionChange,
31975
+ onSizeChange
31976
+ });
31977
+ latest.current = {
31978
+ size,
31979
+ onPositionChange,
31980
+ onSizeChange
31981
+ };
31976
31982
  const [minimized, setMinimized] = useState(false);
31977
31983
  const dragging = useRef(false);
31978
31984
  const resizing = useRef(false);
@@ -32000,10 +32006,14 @@ function FloatingPanel({ title, onClose, children, defaultWidth = 360, defaultHe
32000
32006
  }, []);
32001
32007
  useEffect(() => {
32002
32008
  const onMouseMove = (e) => {
32003
- if (dragging.current) setPos({
32004
- x: e.clientX - offset.current.x,
32005
- y: e.clientY - offset.current.y
32006
- });
32009
+ if (dragging.current) {
32010
+ const next = {
32011
+ x: e.clientX - offset.current.x,
32012
+ y: e.clientY - offset.current.y
32013
+ };
32014
+ setOwnPos(next);
32015
+ latest.current.onPositionChange?.(next);
32016
+ }
32007
32017
  if (resizing.current) {
32008
32018
  const dx = e.clientX - offset.current.x;
32009
32019
  const dy = e.clientY - offset.current.y;
@@ -32011,10 +32021,17 @@ function FloatingPanel({ title, onClose, children, defaultWidth = 360, defaultHe
32011
32021
  x: e.clientX,
32012
32022
  y: e.clientY
32013
32023
  };
32014
- setSize((prev) => ({
32024
+ const prev = latest.current.size;
32025
+ const next = {
32015
32026
  w: Math.max(minWidth, prev.w + dx),
32016
32027
  h: Math.max(minHeight, prev.h + dy)
32017
- }));
32028
+ };
32029
+ latest.current = {
32030
+ ...latest.current,
32031
+ size: next
32032
+ };
32033
+ setOwnSize(next);
32034
+ latest.current.onSizeChange?.(next);
32018
32035
  }
32019
32036
  };
32020
32037
  const onMouseUp = () => {
@@ -32033,9 +32050,15 @@ function FloatingPanel({ title, onClose, children, defaultWidth = 360, defaultHe
32033
32050
  style: { maxHeight: "60dvh" },
32034
32051
  children: [/* @__PURE__ */ jsxs("div", {
32035
32052
  className: "flex items-center justify-between gap-2 px-3 py-2 border-b border-border shrink-0 bg-surface",
32036
- children: [/* @__PURE__ */ jsx("span", {
32037
- className: "text-[11px] font-medium truncate",
32038
- children: title
32053
+ children: [/* @__PURE__ */ jsxs("div", {
32054
+ className: "flex items-center gap-2 min-w-0",
32055
+ children: [Icon && /* @__PURE__ */ jsx(Icon, {
32056
+ size: 12,
32057
+ className: "text-primary shrink-0"
32058
+ }), /* @__PURE__ */ jsx("span", {
32059
+ className: "text-[11px] font-medium truncate",
32060
+ children: title
32061
+ })]
32039
32062
  }), /* @__PURE__ */ jsxs("div", {
32040
32063
  className: "flex items-center gap-1 shrink-0",
32041
32064
  children: [/* @__PURE__ */ jsx("button", {
@@ -32066,13 +32089,20 @@ function FloatingPanel({ title, onClose, children, defaultWidth = 360, defaultHe
32066
32089
  className: "flex items-center justify-between gap-2 px-3 py-2 border-b border-border cursor-move select-none shrink-0 bg-surface",
32067
32090
  children: [/* @__PURE__ */ jsxs("div", {
32068
32091
  className: "flex items-center gap-2 min-w-0",
32069
- children: [/* @__PURE__ */ jsx(GripHorizontal, {
32070
- size: 12,
32071
- className: "text-foreground-subtle shrink-0"
32072
- }), /* @__PURE__ */ jsx("span", {
32073
- className: "text-[11px] font-medium truncate",
32074
- children: title
32075
- })]
32092
+ children: [
32093
+ /* @__PURE__ */ jsx(GripHorizontal, {
32094
+ size: 12,
32095
+ className: "text-foreground-subtle shrink-0"
32096
+ }),
32097
+ Icon && /* @__PURE__ */ jsx(Icon, {
32098
+ size: 12,
32099
+ className: "text-primary shrink-0"
32100
+ }),
32101
+ /* @__PURE__ */ jsx("span", {
32102
+ className: "text-[11px] font-medium truncate",
32103
+ children: title
32104
+ })
32105
+ ]
32076
32106
  }), /* @__PURE__ */ jsxs("div", {
32077
32107
  className: "flex items-center gap-1 shrink-0",
32078
32108
  children: [/* @__PURE__ */ jsx("button", {
@@ -32549,19 +32579,6 @@ function AudioWaveform({ samples, sampleRate = 16e3, height = 96, className = ""
32549
32579
  }
32550
32580
  //#endregion
32551
32581
  //#region src/composites/battery-badge.tsx
32552
- /**
32553
- * BatteryBadge — compact battery indicator for camera tiles + headers.
32554
- *
32555
- * Renders a battery icon with the percentage, a charging glyph when the
32556
- * device is on DC/solar, and a moon when the camera is sleeping (so
32557
- * operators don't blame the platform for low fps on a sleeping cam).
32558
- *
32559
- * Self-contained on data: the caller passes a `status` snapshot from
32560
- * `trpc.battery.getStatus.useQuery` or the `battery.onStatusChanged`
32561
- * event subscription. Returns `null` when status is missing so the
32562
- * call-site can drop the badge in unconditionally — non-battery
32563
- * cameras simply produce no badge.
32564
- */
32565
32582
  /** A binary battery is "low" below this stand-in percentage (normal maps to
32566
32583
  * 100, low to a sub-threshold value). Keep in sync with the HA container. */
32567
32584
  var BINARY_LOW_THRESHOLD = 50;
@@ -58578,26 +58595,39 @@ function SnapshotButton({ trpc, deviceId, deviceName, size = "sm", className })
58578
58595
  }
58579
58596
  //#endregion
58580
58597
  //#region src/composites/stat-card.tsx
58581
- function StatCard({ value, label, trend, className }) {
58582
- return /* @__PURE__ */ jsxs(Card, {
58583
- className: cn("flex flex-col gap-1", className),
58584
- children: [/* @__PURE__ */ jsxs("div", {
58585
- className: "flex items-baseline gap-2",
58586
- children: [/* @__PURE__ */ jsx("span", {
58587
- className: "text-2xl font-semibold text-foreground",
58588
- children: value
58589
- }), trend && /* @__PURE__ */ jsxs("span", {
58590
- className: cn("inline-flex items-center gap-0.5 text-xs font-medium", trend.direction === "up" ? "text-success" : "text-danger"),
58591
- children: [
58592
- trend.direction === "up" ? /* @__PURE__ */ jsx(TrendingUp, { className: "h-3 w-3" }) : /* @__PURE__ */ jsx(TrendingDown, { className: "h-3 w-3" }),
58593
- trend.value,
58594
- "%"
58595
- ]
58596
- })]
58597
- }), /* @__PURE__ */ jsx("span", {
58598
- className: "text-xs text-foreground-muted",
58599
- children: label
58600
- })]
58598
+ function StatCard({ value, label, icon: Icon, subtext, valueClassName, trend, className }) {
58599
+ return /* @__PURE__ */ jsxs("div", {
58600
+ className: cn("rounded-lg border border-border bg-surface p-2 sm:p-2.5 min-w-0", className),
58601
+ children: [
58602
+ /* @__PURE__ */ jsxs("div", {
58603
+ className: "flex items-center gap-1.5 mb-0.5 min-w-0",
58604
+ children: [Icon && /* @__PURE__ */ jsx(Icon, { className: "h-3 w-3 text-foreground-subtle flex-shrink-0" }), /* @__PURE__ */ jsx("span", {
58605
+ className: "text-[10px] text-foreground-subtle uppercase tracking-wider whitespace-nowrap overflow-hidden text-ellipsis min-w-0",
58606
+ title: label,
58607
+ children: label
58608
+ })]
58609
+ }),
58610
+ /* @__PURE__ */ jsxs("div", {
58611
+ className: "flex items-baseline gap-2 min-w-0",
58612
+ children: [/* @__PURE__ */ jsx("p", {
58613
+ className: cn("text-lg font-semibold leading-tight whitespace-nowrap overflow-hidden text-ellipsis min-w-0", valueClassName ?? "text-foreground"),
58614
+ title: String(value),
58615
+ children: value
58616
+ }), trend && /* @__PURE__ */ jsxs("span", {
58617
+ className: cn("inline-flex items-center gap-0.5 text-xs font-medium shrink-0", trend.direction === "up" ? "text-success" : "text-danger"),
58618
+ children: [
58619
+ trend.direction === "up" ? /* @__PURE__ */ jsx(TrendingUp, { className: "h-3 w-3" }) : /* @__PURE__ */ jsx(TrendingDown, { className: "h-3 w-3" }),
58620
+ trend.value,
58621
+ "%"
58622
+ ]
58623
+ })]
58624
+ }),
58625
+ subtext && /* @__PURE__ */ jsx("p", {
58626
+ className: "text-[10px] text-foreground-subtle mt-0.5 truncate",
58627
+ title: subtext,
58628
+ children: subtext
58629
+ })
58630
+ ]
58601
58631
  });
58602
58632
  }
58603
58633
  //#endregion
@@ -58618,9 +58648,33 @@ var statusConfig = {
58618
58648
  unknown: {
58619
58649
  colorClass: "bg-foreground-subtle",
58620
58650
  label: "Unknown"
58651
+ },
58652
+ running: {
58653
+ colorClass: "bg-success",
58654
+ label: "Running"
58655
+ },
58656
+ stopped: {
58657
+ colorClass: "bg-foreground-subtle",
58658
+ label: "Stopped"
58659
+ },
58660
+ error: {
58661
+ colorClass: "bg-danger",
58662
+ label: "Error"
58663
+ },
58664
+ idle: {
58665
+ colorClass: "bg-info",
58666
+ label: "Idle"
58667
+ },
58668
+ enabled: {
58669
+ colorClass: "bg-success",
58670
+ label: "Enabled"
58671
+ },
58672
+ disabled: {
58673
+ colorClass: "bg-warning",
58674
+ label: "Disabled"
58621
58675
  }
58622
58676
  };
58623
- function StatusBadge({ status, showDot = true, showLabel = true, size = "sm", className }) {
58677
+ function StatusBadge({ status, label, showDot = true, showLabel = true, size = "sm", className }) {
58624
58678
  const config = statusConfig[status];
58625
58679
  return /* @__PURE__ */ jsxs("span", {
58626
58680
  className: cn("inline-flex items-center gap-1.5", size === "sm" ? "text-xs" : "text-sm", className),
@@ -58629,7 +58683,7 @@ function StatusBadge({ status, showDot = true, showLabel = true, size = "sm", cl
58629
58683
  "aria-hidden": "true"
58630
58684
  }), showLabel && /* @__PURE__ */ jsx("span", {
58631
58685
  className: "text-foreground",
58632
- children: config.label
58686
+ children: label ?? config.label
58633
58687
  })]
58634
58688
  });
58635
58689
  }
@@ -1,41 +1,20 @@
1
1
  /**
2
- * Shared capability-error utilities for the admin UI.
3
- *
4
- * The primary export `isAbsentProvider` lets UI components distinguish
5
- * "this device doesn't have this cap" (expected — hide the widget) from
6
- * "something went wrong while calling a present cap" (unexpected — surface
7
- * the error to the operator).
8
- *
9
- * Detection strategy (two-tier):
10
- *
11
- * 1. **Typed reason** (preferred): tRPC's errorFormatter augments the
12
- * error shape with `data.capRouteReason` when the server throws a
13
- * CapRouteError. Read it from `err.data?.capRouteReason` to avoid
14
- * brittle string matching.
15
- *
16
- * 2. **Substring fallback** (transitional safety): older error paths
17
- * that don't carry a typed reason still emit the human-readable
18
- * message "provider not available". The fallback is ONLY engaged
19
- * when `capRouteReason` is absent — future clean-up can drop it
20
- * once every throw site has been migrated.
21
- */
22
- /**
23
- * Returns `true` when `err` indicates that the requested capability has
24
- * no provider bound for the device — i.e. the device legitimately does
25
- * not expose this cap and the UI should stay hidden / show a friendly
26
- * "not supported" message.
27
- *
28
- * Returns `false` for real dispatch errors (`transport-failed`) — those
29
- * should be surfaced to the operator as unexpected failures.
30
- *
31
- * ## Absent-provider reasons
32
- * - `'no-provider'` — no provider is registered for this cap/device pair.
33
- * - `'node-offline'` — the node that hosts the cap is not reachable; the
34
- * device is effectively unavailable so we treat it as absent.
35
- *
36
- * ## Not-absent reasons
37
- * - `'transport-failed'` — a provider exists but the call failed in transit.
38
- * - `'cap-unknown'` — the cap name isn't registered at all; treat as
39
- * a real error (likely a programming mistake or version skew).
40
- */
2
+ * Returns `true` when `err` indicates that the requested capability has
3
+ * no provider bound for the device — i.e. the device legitimately does
4
+ * not expose this cap and the UI should stay hidden / show a friendly
5
+ * "not supported" message.
6
+ *
7
+ * Returns `false` for real dispatch errors (`transport-failed`) — those
8
+ * should be surfaced to the operator as unexpected failures.
9
+ *
10
+ * ## Absent-provider reasons
11
+ * - `'no-provider'` — no provider is registered for this cap/device pair.
12
+ * - `'node-offline'` — the node that hosts the cap is not reachable; the
13
+ * device is effectively unavailable so we treat it as absent.
14
+ *
15
+ * ## Not-absent reasons
16
+ * - `'transport-failed'` — a provider exists but the call failed in transit.
17
+ * - `'cap-unknown'` — the cap name isn't registered at all; treat as
18
+ * a real error (likely a programming mistake or version skew).
19
+ */
41
20
  export declare function isAbsentProvider(err: unknown): boolean;
package/dist/lib/cn.d.ts CHANGED
@@ -1,2 +1,2 @@
1
- import { ClassValue } from 'clsx';
1
+ import { type ClassValue } from "clsx";
2
2
  export declare function cn(...inputs: ClassValue[]): string;
@@ -1,41 +1,75 @@
1
- import { QueryClient, QueryKey } from '@tanstack/react-query';
2
1
  /**
3
- * The tRPC query-key PREFIX shared by every `deviceManager.listAll` observer.
4
- * tRPC v11 builds `[[path], { input, type }]`, and `partialMatchKey` treats a
5
- * shorter key as a prefix — so this matches all inputs, and only this method.
6
- */
2
+ * Fleet-list query defaults — the ONE owner of the `deviceManager.listAll`
3
+ * caching window (D274).
4
+ *
5
+ * ── The bug class this prevents ────────────────────────────────────────────
6
+ * `staleTime` is a per-OBSERVER setting in React Query, not a property of the
7
+ * cache entry. `defaultQueryOptions` resolves it once per mounted observer as
8
+ *
9
+ * { ...defaultOptions.queries, ...getQueryDefaults(queryKey), ...callSite }
10
+ *
11
+ * so a single observer that leaves `staleTime` at the app-wide default of `0`
12
+ * re-triggers a fetch of the shared key on mount, no matter what its ~40
13
+ * siblings passed. The admin UI mounts the fleet list from the sidebar, the
14
+ * Devices page, Integrations, Recordings, Scenes, Retrain, the detection
15
+ * sections and four ui-library pickers at once — on a hub with 1017 devices
16
+ * that is one `deviceManager.listAll` round-trip per forgetful call site, at
17
+ * every boot.
18
+ *
19
+ * The previous attempt fixed this by hand at the call site, 25 times. It had
20
+ * already drifted before this file existed: every ui-library composite was
21
+ * missed, and those are the ones asking for the UNPROJECTED fleet.
22
+ *
23
+ * ── Why the query client and not the call site ─────────────────────────────
24
+ * `setQueryDefaults` keys off a query-key PREFIX, so one registration covers
25
+ * every `input` variant of the method — `{}`, `{ projection: 'slim' }`,
26
+ * `{ isCamera: true, projection: 'slim' }`, and whatever call site 44 invents.
27
+ * It sits ABOVE the call site in the merge order, so it cannot be forgotten;
28
+ * it sits BELOW an explicit option, so a call site that genuinely needs
29
+ * something else (a `refetchInterval`) still gets it.
30
+ *
31
+ * `scripts/check-fleet-query-defaults.ts` keeps both halves honest: every
32
+ * `QueryClient` in the admin UI and ui-library must run through here, and no
33
+ * call site may re-declare the window locally.
34
+ */
35
+ import type { QueryClient, QueryKey } from "@tanstack/react-query";
36
+ /**
37
+ * The tRPC query-key PREFIX shared by every `deviceManager.listAll` observer.
38
+ * tRPC v11 builds `[[path], { input, type }]`, and `partialMatchKey` treats a
39
+ * shorter key as a prefix — so this matches all inputs, and only this method.
40
+ */
7
41
  export declare const FLEET_LIST_QUERY_KEY: QueryKey;
8
42
  /**
9
- * 30 s, matching the window `GlobalSearch` established and the 21 call sites
10
- * that copied it — this registration replaces them rather than competing with
11
- * them.
12
- *
13
- * It is not longer for one reason: device mutations invalidate
14
- * `[['deviceManager']]` (~20 call sites do, and the prefix covers `listAll`
15
- * under every input), so an operator EDIT is never the thing this window makes
16
- * stale. What it does bound is the change no client mutation announces — a
17
- * provider discovering a camera, a device going offline, a scan adding rows.
18
- * Nothing invalidates those, so the window is the only thing that picks them
19
- * up, and 30 s is the cost an operator will tolerate for a row that appeared
20
- * on its own.
21
- */
22
- export declare const FLEET_LIST_STALE_TIME_MS = 30000;
43
+ * 30 s, matching the window `GlobalSearch` established and the 21 call sites
44
+ * that copied it — this registration replaces them rather than competing with
45
+ * them.
46
+ *
47
+ * It is not longer for one reason: device mutations invalidate
48
+ * `[['deviceManager']]` (~20 call sites do, and the prefix covers `listAll`
49
+ * under every input), so an operator EDIT is never the thing this window makes
50
+ * stale. What it does bound is the change no client mutation announces — a
51
+ * provider discovering a camera, a device going offline, a scan adding rows.
52
+ * Nothing invalidates those, so the window is the only thing that picks them
53
+ * up, and 30 s is the cost an operator will tolerate for a row that appeared
54
+ * on its own.
55
+ */
56
+ export declare const FLEET_LIST_STALE_TIME_MS = 3e4;
23
57
  /**
24
- * 5 min. The app-wide default is `gcTime: 0` (a deliberate "no cross-navigation
25
- * cache" choice), which drops the entry the instant its last observer
26
- * unmounts — and that would make the `staleTime` above inert for every key
27
- * without a permanently-mounted reader. `{ projection: 'slim' }` has one (the
28
- * sidebar search); `{ isCamera: true, … }` and `{}` do not, so leaving `gcTime`
29
- * at 0 would refetch the whole fleet on every return to Recordings or Scenes.
30
- *
31
- * Scoped to this one key: the fleet list is the largest and most re-read
32
- * response in the UI, and it is comprehensively invalidated. The global
33
- * default is untouched.
34
- */
58
+ * 5 min. The app-wide default is `gcTime: 0` (a deliberate "no cross-navigation
59
+ * cache" choice), which drops the entry the instant its last observer
60
+ * unmounts — and that would make the `staleTime` above inert for every key
61
+ * without a permanently-mounted reader. `{ projection: 'slim' }` has one (the
62
+ * sidebar search); `{ isCamera: true, … }` and `{}` do not, so leaving `gcTime`
63
+ * at 0 would refetch the whole fleet on every return to Recordings or Scenes.
64
+ *
65
+ * Scoped to this one key: the fleet list is the largest and most re-read
66
+ * response in the UI, and it is comprehensively invalidated. The global
67
+ * default is untouched.
68
+ */
35
69
  export declare const FLEET_LIST_GC_TIME_MS: number;
36
70
  /**
37
- * Register the fleet-list window on a query client. Call this on EVERY
38
- * `QueryClient` that can mount a fleet consumer, immediately after
39
- * construction — the guard enforces it.
40
- */
71
+ * Register the fleet-list window on a query client. Call this on EVERY
72
+ * `QueryClient` that can mount a fleet consumer, immediately after
73
+ * construction — the guard enforces it.
74
+ */
41
75
  export declare function applyFleetQueryDefaults(queryClient: QueryClient): void;
@@ -1,18 +1,18 @@
1
1
  /**
2
- * Format an HA-native datetime control value in the user's locale.
3
- *
4
- * The `control` cap keeps the value verbatim in one of three HA-native shapes:
5
- * - date → 'YYYY-MM-DD'
6
- * - time → 'HH:MM' or 'HH:MM:SS'
7
- * - datetime → full ISO timestamp ('YYYY-MM-DDTHH:MM[:SS]' or space-separated)
8
- *
9
- * This helper renders that value for the READ-ONLY (at-a-glance) context:
10
- * - 'date' → locale date (e.g. en-US '6/7/2026')
11
- * - 'time' → locale time (e.g. en-US '07:30 AM')
12
- * - 'datetime' → locale date+time (medium date + short time)
13
- *
14
- * It NEVER throws: any value it cannot parse is returned unchanged (graceful
15
- * fallback). `locale` is optional and defaults to the runtime/browser locale.
16
- */
17
- export type ControlDateTimeFormat = 'date' | 'time' | 'datetime';
2
+ * Format an HA-native datetime control value in the user's locale.
3
+ *
4
+ * The `control` cap keeps the value verbatim in one of three HA-native shapes:
5
+ * - date → 'YYYY-MM-DD'
6
+ * - time → 'HH:MM' or 'HH:MM:SS'
7
+ * - datetime → full ISO timestamp ('YYYY-MM-DDTHH:MM[:SS]' or space-separated)
8
+ *
9
+ * This helper renders that value for the READ-ONLY (at-a-glance) context:
10
+ * - 'date' → locale date (e.g. en-US '6/7/2026')
11
+ * - 'time' → locale time (e.g. en-US '07:30 AM')
12
+ * - 'datetime' → locale date+time (medium date + short time)
13
+ *
14
+ * It NEVER throws: any value it cannot parse is returned unchanged (graceful
15
+ * fallback). `locale` is optional and defaults to the runtime/browser locale.
16
+ */
17
+ export type ControlDateTimeFormat = "date" | "time" | "datetime";
18
18
  export declare function formatControlDateTime(value: string, format: ControlDateTimeFormat, locale?: string): string;
@@ -1,14 +1,14 @@
1
1
  /**
2
- * How long something lasted, the way this product says it.
3
- *
4
- * Promoted verbatim from `composites/cap-settings/RecordingPanel.tsx`, which
5
- * had been the only place answering this question about MEDIA. It is now the
6
- * only place, so a clip's length and a recording's retention read the same.
7
- *
8
- * Two other private formatters stay where they are, on purpose:
9
- * `config-form-field.tsx` formats a config VALUE (sub-second `ms`, `—` for a
10
- * value that is not a number), and `scene-monitor-copy.ts`'s `humanDuration`
11
- * is deliberately single-unit and coarse for a sentence. Neither is a media
12
- * length, and folding them in here would change what they say.
13
- */
2
+ * How long something lasted, the way this product says it.
3
+ *
4
+ * Promoted verbatim from `composites/cap-settings/RecordingPanel.tsx`, which
5
+ * had been the only place answering this question about MEDIA. It is now the
6
+ * only place, so a clip's length and a recording's retention read the same.
7
+ *
8
+ * Two other private formatters stay where they are, on purpose:
9
+ * `config-form-field.tsx` formats a config VALUE (sub-second `ms`, `—` for a
10
+ * value that is not a number), and `scene-monitor-copy.ts`'s `humanDuration`
11
+ * is deliberately single-unit and coarse for a sentence. Neither is a media
12
+ * length, and folding them in here would change what they say.
13
+ */
14
14
  export declare function formatDurationMs(ms: number): string;
@@ -1,21 +1,8 @@
1
1
  /**
2
- * Relative "last seen" formatter for the offline affordance.
3
- *
4
- * Renders a short relative-time label from a millisecond epoch:
5
- * "just now", "5m ago", "3h ago", "2d ago". Returns `null` for missing
6
- * inputs, or inputs below {@link MIN_PLAUSIBLE_TIMESTAMP_MS} (a
7
- * placeholder or a seeded "known value, unknown change time" stamp), so
8
- * callers can render nothing rather than a misleading "—", "NaN ago", or
9
- * (for a seeded `1`) "20000 days ago".
10
- *
11
- * Future timestamps (clock skew between the device and the browser)
12
- * collapse to "just now" instead of a negative duration.
13
- */
14
- /**
15
- * The earliest timestamp a real "last seen" could plausibly carry. Below
16
- * this, a value is a placeholder or a seeded "known value, unknown change
17
- * time" stamp (e.g. Homematic's `HM_SEEDED_CHANGED_AT = 1`) — never a real
18
- * instant. Year 2000 predates every device this renders.
19
- */
2
+ * The earliest timestamp a real "last seen" could plausibly carry. Below
3
+ * this, a value is a placeholder or a seeded "known value, unknown change
4
+ * time" stamp (e.g. Homematic's `HM_SEEDED_CHANGED_AT = 1`) — never a real
5
+ * instant. Year 2000 predates every device this renders.
6
+ */
20
7
  export declare const MIN_PLAUSIBLE_TIMESTAMP_MS: number;
21
8
  export declare function formatLastSeen(timestampMs: number | null | undefined): string | null;
@@ -1,9 +1,9 @@
1
1
  /**
2
- * Format a numeric sensor / control value with optional display precision.
3
- *
4
- * When `precision` is provided, delegates to `value.toFixed(precision)` which
5
- * matches the HA `suggested_display_precision` contract.
6
- * When absent, falls back to auto-formatting: integers render without a
7
- * decimal point; non-integers use one decimal place.
8
- */
2
+ * Format a numeric sensor / control value with optional display precision.
3
+ *
4
+ * When `precision` is provided, delegates to `value.toFixed(precision)` which
5
+ * matches the HA `suggested_display_precision` contract.
6
+ * When absent, falls back to auto-formatting: integers render without a
7
+ * decimal point; non-integers use one decimal place.
8
+ */
9
9
  export declare function formatNumeric(value: number, precision: number | undefined): string;
@@ -1,50 +1,16 @@
1
1
  /**
2
- * Where the hub is, from inside a page the hub served.
3
- *
4
- * The admin UI is not always at the hub's root. The Home Assistant component
5
- * frames it through a same-origin relay — `https://<ha>/api/camstack/p/<grant>/…`
6
- * → `https://<hub>:4443/…` — so the browser never has to trust the hub's
7
- * local certificate. The relay sends `X-Forwarded-Prefix` and the hub
8
- * injects two things into the shell it serves for that request:
9
- *
10
- * <base href="<prefix>/">
11
- * <meta name="camstack-mount" content="<prefix>/">
12
- *
13
- * This module is the ONE reader of that fact. Every URL the page composes
14
- * toward the hub — tRPC HTTP and WS, `/api/webrtc`, `/addon/…` data planes,
15
- * `/api/addon-assets`, MF remote entries, `<img src>` — goes through it:
16
- *
17
- * - `hubPath('/api/x')` → `/api/x` at the root, `/<prefix>/api/x` under one.
18
- * A same-origin path; the default for fetch, `<img>`, links.
19
- * - `hubOrigin()` → `https://host` or `https://host/<prefix>`; the
20
- * `serverUrl` handed to the SDK and the players (they append `/trpc`,
21
- * `/api/webrtc`, `/adaptive-probe` themselves).
22
- * - `hubUrl()` / `hubWsUrl()` — absolute http(s) / ws(s) forms.
23
- * - `routerBasename()` → `''` or `/<prefix>`, for `<BrowserRouter>`.
24
- *
25
- * Why not `window.location.origin` + a literal: `<base>` does not apply to a
26
- * root-absolute path, so `'/api/x'` leaves the relay and lands on HA's own
27
- * `/api/x`. And why not `document.baseURI` alone: without a `<base>` it is
28
- * the DOCUMENT's URL, so `/devices/5` would read as a mount of `/devices/`.
29
- * The meta is the authority; a `<base>` element is accepted on its own for a
30
- * host that injects only that.
31
- *
32
- * `scripts/check-hub-paths-through-mount.ts` keeps every other module from
33
- * spelling a hub path directly.
34
- */
35
- /**
36
- * The path the app is mounted at, with a trailing slash: `/` or `/<prefix>/`.
37
- * Resolved once — the shell is the only thing that can say where it lives,
38
- * and it says so before any script runs.
39
- */
2
+ * The path the app is mounted at, with a trailing slash: `/` or `/<prefix>/`.
3
+ * Resolved once — the shell is the only thing that can say where it lives,
4
+ * and it says so before any script runs.
5
+ */
40
6
  export declare function mountPath(): string;
41
7
  /** `<BrowserRouter basename>`: the mount without its trailing slash. */
42
8
  export declare function routerBasename(): string;
43
9
  /**
44
- * A same-origin path under the mount. Absolute URLs and paths already under
45
- * the mount pass through unchanged, so a server-stamped `bundleUrl` can be
46
- * wrapped without knowing whether it was.
47
- */
10
+ * A same-origin path under the mount. Absolute URLs and paths already under
11
+ * the mount pass through unchanged, so a server-stamped `bundleUrl` can be
12
+ * wrapped without knowing whether it was.
13
+ */
48
14
  export declare function hubPath(pathname: string): string;
49
15
  /** The absolute hub base with no trailing slash — the SDK's `serverUrl`. */
50
16
  export declare function hubOrigin(): string;