@camera.ui/server 2.2.6 → 2.2.8

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 (560) hide show
  1. package/dist/interface/assets/{404-BLVuKvLk.js → 404-BYV0u5qE.js} +1 -1
  2. package/dist/interface/assets/{About-C-AJ0jfI.js → About-DBOS1rfw.js} +1 -1
  3. package/dist/interface/assets/Assistant-BRcHj8hq.js +1 -0
  4. package/dist/interface/assets/Automation-C0Emde7z.js +3 -0
  5. package/dist/interface/assets/{AutomationImport-C8VYjDzf.js → AutomationImport-Iu-K82Os.js} +2 -2
  6. package/dist/interface/assets/{AutomationStore-CE4PKRGd.js → AutomationStore-C2G0Bk8c.js} +2 -2
  7. package/dist/interface/assets/{AutomationStoreDetail-DavWfjLv.js → AutomationStoreDetail-BbvLRJ5u.js} +2 -2
  8. package/dist/interface/assets/Automations-D-vfqRnZ.js +2 -0
  9. package/dist/interface/assets/Camera-BpurrgAr.js +2 -0
  10. package/dist/interface/assets/Camera-D0B7yyVD.css +1 -0
  11. package/dist/interface/assets/{CameraConsole-C4AmtcrM.js → CameraConsole-JBD3ZmJ6.js} +2 -2
  12. package/dist/interface/assets/{Cameras-DR577Bno.js → Cameras-R5mJGMK9.js} +2 -2
  13. package/dist/interface/assets/{Camview-Bri_T7Tq.css → Camview-DH6_8CxH.css} +1 -1
  14. package/dist/interface/assets/Camview-IbOVRx20.js +1 -0
  15. package/dist/interface/assets/{CertificateUpload-BYFKZCP9.js → CertificateUpload-B9S4EOQs.js} +1 -1
  16. package/dist/interface/assets/Config-CbFl5Wcp.js +2 -0
  17. package/dist/interface/assets/{ConfigActionAssistant-YtCVI8LZ.js → ConfigActionAssistant-DIOh6-np.js} +1 -1
  18. package/dist/interface/assets/{ConfigActionCameraControl-Dg_1zOYt.js → ConfigActionCameraControl-Bw_egtpP.js} +1 -1
  19. package/dist/interface/assets/{ConfigActionDelay-_EqbfWgo.js → ConfigActionDelay-B9i4YZjy.js} +1 -1
  20. package/dist/interface/assets/{ConfigActionHttp-BzwLv2tn.js → ConfigActionHttp-DFtxAa3U.js} +1 -1
  21. package/dist/interface/assets/{ConfigActionImageInput-CLdY2sV4.js → ConfigActionImageInput-CuTH4Nw2.js} +1 -1
  22. package/dist/interface/assets/{ConfigActionMqtt-lGqYshl3.js → ConfigActionMqtt-B9SfWP-G.js} +1 -1
  23. package/dist/interface/assets/{ConfigActionNotification-D5Dj3EoU.js → ConfigActionNotification-BGMIByJT.js} +1 -1
  24. package/dist/interface/assets/{ConfigActionNotificationControl-Dy5fKamr.js → ConfigActionNotificationControl-Cz72szMd.js} +1 -1
  25. package/dist/interface/assets/{ConfigActionOutput-DzsQ31L0.js → ConfigActionOutput-BG6DoIRe.js} +1 -1
  26. package/dist/interface/assets/{ConfigActionPlugin-BFrBcXvL.js → ConfigActionPlugin-B5oRSE9n.js} +1 -1
  27. package/dist/interface/assets/{ConfigActionSensor-CX8ePlan.js → ConfigActionSensor-BErRRYfl.js} +1 -1
  28. package/dist/interface/assets/{ConfigActionSnapshot-BATLRmh6.js → ConfigActionSnapshot-Di-uxMrg.js} +1 -1
  29. package/dist/interface/assets/{ConfigActionVariable-Dgn5jvaR.js → ConfigActionVariable-BBpUti5A.js} +1 -1
  30. package/dist/interface/assets/{ConfigConditionIfElse-D5IIBjyk.js → ConfigConditionIfElse-DjOKPXQw.js} +1 -1
  31. package/dist/interface/assets/{ConfigConditionSensorState-C0JxBWdG.js → ConfigConditionSensorState-BzvvZvD0.js} +1 -1
  32. package/dist/interface/assets/{ConfigConditionSwitch-Brlgd0XP.js → ConfigConditionSwitch-DQvdfUxR.js} +1 -1
  33. package/dist/interface/assets/{ConfigConditionTime-CM4bSMyU.js → ConfigConditionTime-BqOElX5C.js} +1 -1
  34. package/dist/interface/assets/{ConfigSensorValueInput-CtuH8dCa.js → ConfigSensorValueInput-BT-0LhSH.js} +1 -1
  35. package/dist/interface/assets/{ConfigTriggerDetection-DsL7lLQl.js → ConfigTriggerDetection-1OkudUah.js} +1 -1
  36. package/dist/interface/assets/{ConfigTriggerGeofence-CAGIk1_W.js → ConfigTriggerGeofence-HGatk3C5.js} +1 -1
  37. package/dist/interface/assets/{ConfigTriggerManual-DgkR-GWy.js → ConfigTriggerManual-DpRr_vVq.js} +1 -1
  38. package/dist/interface/assets/{ConfigTriggerMqtt-B_iFalAQ.js → ConfigTriggerMqtt-C_MId3BY.js} +1 -1
  39. package/dist/interface/assets/{ConfigTriggerSchedule-E_QWfNKy.js → ConfigTriggerSchedule-BmwDqd6N.js} +1 -1
  40. package/dist/interface/assets/{ConfigTriggerSensor-hYNbLXUu.js → ConfigTriggerSensor-Rgx8q4g8.js} +1 -1
  41. package/dist/interface/assets/{ConfigTriggerSystem-DR1EFpE9.js → ConfigTriggerSystem-4VsHPmbn.js} +1 -1
  42. package/dist/interface/assets/{ConfigTriggerWebhook-C-B5GGFH.js → ConfigTriggerWebhook-Bs7zEfY0.js} +1 -1
  43. package/dist/interface/assets/Console-oCuuVKET.js +1 -0
  44. package/dist/interface/assets/{CuiAssistantConversation-BmshW6Vc.css → CuiAssistantConversation-BmBhwrNh.css} +1 -1
  45. package/dist/interface/assets/CuiAssistantConversation-Bsyxau9v.js +5 -0
  46. package/dist/interface/assets/CuiAutomationRunsDialog-sRh_K6JI.js +1 -0
  47. package/dist/interface/assets/CuiBottomSheet-DWoSHzC7.js +1 -0
  48. package/dist/interface/assets/{CuiBottomSheet-C2sM2E3M.js → CuiBottomSheet-Dd3uOtnC.js} +1 -1
  49. package/dist/interface/assets/CuiCameraPipCard-D6REm8uT.js +1 -0
  50. package/dist/interface/assets/CuiCameraPipCard-TYTCfwXf.css +1 -0
  51. package/dist/interface/assets/CuiCameraRecordings-C2tvrbbw.js +1 -0
  52. package/dist/interface/assets/{CuiCameraShares-B6jdUBVm.js → CuiCameraShares-jrrUEHoZ.js} +1 -1
  53. package/dist/interface/assets/CuiCameraTable-BOzTWLwd.js +1 -0
  54. package/dist/interface/assets/{CuiCameraTable-CpBo25Qc.js → CuiCameraTable-C7WLZ2pA.js} +2 -2
  55. package/dist/interface/assets/CuiChartTable-BYrIX7LV.js +1 -0
  56. package/dist/interface/assets/CuiChartTable-DCr_AsSw.css +1 -0
  57. package/dist/interface/assets/{CuiConsole-BGptpT6r.js → CuiConsole-CkZML0iY.js} +2 -2
  58. package/dist/interface/assets/CuiDataTable-BFIhx1D3.js +1 -0
  59. package/dist/interface/assets/{CuiLightControl-wbZi3fA1.js → CuiLightControl-DitIWqUr.js} +1 -1
  60. package/dist/interface/assets/{CuiList-Dsu5m0TA.js → CuiList-BewTNr2X.js} +1 -1
  61. package/dist/interface/assets/CuiMarkdownContent-Do04YgHe.js +1 -0
  62. package/dist/interface/assets/{CuiMarkdownContent-BYBQX_aF.js → CuiMarkdownContent-qOPm3VEi.js} +1 -1
  63. package/dist/interface/assets/CuiPluginCard-Bd2HFduI.js +2 -0
  64. package/dist/interface/assets/{CuiPluginCategoryChip-BtJ_6_gN.js → CuiPluginCategoryChip-DlzOwRgc.js} +1 -1
  65. package/dist/interface/assets/{CuiPluginOAuthButton-Duf35I8K.js → CuiPluginOAuthButton-BQZkTcgo.js} +2 -2
  66. package/dist/interface/assets/{CuiPluginTrustBadge-jxXeRTH2.js → CuiPluginTrustBadge-DbqdfdaL.js} +1 -1
  67. package/dist/interface/assets/{CuiQRCode-BNchrpoB.js → CuiQRCode-2WsWJQFi.js} +1 -1
  68. package/dist/interface/assets/{CuiSchema-DGTMkVSe.js → CuiSchema-BL0QZmP2.js} +1 -1
  69. package/dist/interface/assets/{CuiTopNavbarItem-CHtLvn53.js → CuiTopNavbarItem-Ti2TueU1.js} +1 -1
  70. package/dist/interface/assets/Faces-DARrGLXf.js +1 -0
  71. package/dist/interface/assets/{FirstSteps-HzaBMDbH.js → FirstSteps-DBYPBvGr.js} +1 -1
  72. package/dist/interface/assets/Floorplan-BaZvzoyv.js +1 -0
  73. package/dist/interface/assets/{Instances-Dl-6rL5O.js → Instances-r0xReURi.js} +1 -1
  74. package/dist/interface/assets/{Logs-DsJkuQFq.js → Logs-DMehPk0t.js} +2 -2
  75. package/dist/interface/assets/{Menu-D_woMkjL.js → Menu-C34RRyLd.js} +1 -1
  76. package/dist/interface/assets/Metrics-BjoC71_O.js +12 -0
  77. package/dist/interface/assets/Metrics-DsHBab6t.css +1 -0
  78. package/dist/interface/assets/{OAuthDeviceFlow-CXfILAE1.js → OAuthDeviceFlow-CdZxelf2.js} +1 -1
  79. package/dist/interface/assets/Plugin-npx7CnwV.js +1 -0
  80. package/dist/interface/assets/{PluginConsole-C96m5zKy.js → PluginConsole-D1BRQCO9.js} +2 -2
  81. package/dist/interface/assets/PluginDetail-nwTrJmO6.js +2 -0
  82. package/dist/interface/assets/{PluginSchema-u1bqXU29.js → PluginSchema-B9VsBHOU.js} +1 -1
  83. package/dist/interface/assets/PluginSearch-CP2kQWKf.js +1 -0
  84. package/dist/interface/assets/PluginSearch-WEvbKMRs.js +2 -0
  85. package/dist/interface/assets/{PluginUpdateProgress-BT4lN9HT.js → PluginUpdateProgress-uj0XPV-_.js} +1 -1
  86. package/dist/interface/assets/Plugins-CPx9Hszm.js +1 -0
  87. package/dist/interface/assets/{RecentEventsFilter-Kp_lTOuG.js → RecentEventsFilter-D5VSH2K1.js} +1 -1
  88. package/dist/interface/assets/Recordings-De6Zcv0M.js +1 -0
  89. package/dist/interface/assets/SensorEdit-SD_oHBRo.js +1 -0
  90. package/dist/interface/assets/{SensorHistory-Cet35_RO.js → SensorHistory-SxiLOloa.js} +1 -1
  91. package/dist/interface/assets/Sensors-Djl64M-W.js +2 -0
  92. package/dist/interface/assets/{Settings-C-LCDIbK.js → Settings-CAf2reGs.js} +1 -1
  93. package/dist/interface/assets/SettingsAccount-BGj5Ni91.js +1 -0
  94. package/dist/interface/assets/SettingsAccount-Dy6WC8ql.js +1 -0
  95. package/dist/interface/assets/SettingsAppearance-BGFhMlRk.js +1 -0
  96. package/dist/interface/assets/{SettingsAppearance-BS4EQNjH.js → SettingsAppearance-DQzQmVzE.js} +1 -1
  97. package/dist/interface/assets/SettingsAssistant-BwYVyuN3.js +1 -0
  98. package/dist/interface/assets/{SettingsBackup-DBlV1gej.js → SettingsBackup-CVExGnOo.js} +1 -1
  99. package/dist/interface/assets/{SettingsList-D8eSwbBY.js → SettingsList-vo7sz_MY.js} +1 -1
  100. package/dist/interface/assets/SettingsMqtt-B1CuOcML.js +1 -0
  101. package/dist/interface/assets/SettingsNotifications-CCQ6eiq8.js +1 -0
  102. package/dist/interface/assets/{SettingsPermissions-CJiz0Z7B.js → SettingsPermissions-BlOf6HEy.js} +1 -1
  103. package/dist/interface/assets/{SettingsRecordings-CLz9Zp47.js → SettingsRecordings-7tTBg6m1.js} +1 -1
  104. package/dist/interface/assets/SettingsRemote-CsIGx-LU.css +1 -0
  105. package/dist/interface/assets/SettingsRemote-DBgKmIdv.js +2 -0
  106. package/dist/interface/assets/{SettingsSystem-txTFGomQ.js → SettingsSystem-DaFMsZpN.js} +2 -2
  107. package/dist/interface/assets/{SettingsUsers-CUp6vQPc.js → SettingsUsers-DXACwVPi.js} +1 -1
  108. package/dist/interface/assets/Terminal-DtGqlHbk.js +4 -0
  109. package/dist/interface/assets/{Training-Bkn52mPJ.css → Training-C-ToeAl4.css} +1 -1
  110. package/dist/interface/assets/Training-Ca11D1Vj.js +1 -0
  111. package/dist/interface/assets/Updates-yenwuqnD.js +2 -0
  112. package/dist/interface/assets/{VariableInput-183LygmK.js → VariableInput-CcILik4M.js} +1 -1
  113. package/dist/interface/assets/{VariableSuggestions-DwLtlzVz.js → VariableSuggestions-Bj0HdrYW.js} +1 -1
  114. package/dist/interface/assets/{VersionsHandler-DkbkcypK.js → VersionsHandler-BA8Lcysg.js} +1 -1
  115. package/dist/interface/assets/{VirtualSensorCreate-Bn4tgdxA.js → VirtualSensorCreate-DvHyw7I2.js} +1 -1
  116. package/dist/interface/assets/{Workers-DH59zE1C.css → Workers-Dey1snI4.css} +1 -1
  117. package/dist/interface/assets/Workers-Dyo44zxe.js +2 -0
  118. package/dist/interface/assets/{account-DwW7pBOb.js → account-DjBQulDn.js} +1 -1
  119. package/dist/interface/assets/ace-BPAekgyf.js +1 -0
  120. package/dist/interface/assets/{ace.config-CCyX_Ohk.js → ace.config-CvKE-yp1.js} +1 -1
  121. package/dist/interface/assets/{alert-circle-BdUVAt1B.js → alert-circle-B-JCMbb9.js} +1 -1
  122. package/dist/interface/assets/{alert-outline-IRxYbw0j.js → alert-outline-B4ZZowEj.js} +1 -1
  123. package/dist/interface/assets/api-CHQlxVtZ.css +2 -0
  124. package/dist/interface/assets/{api-h4HRB3ef.js → api-CKbL5jC7.js} +1 -1
  125. package/dist/interface/assets/api-CLazgL-g.js +4 -0
  126. package/dist/interface/assets/{arrow-left-Bk-ZrOVr.js → arrow-left-PeaVwpHd.js} +1 -1
  127. package/dist/interface/assets/{assistant-4hYyIu6D.js → assistant-CwmHp5bB.js} +1 -1
  128. package/dist/interface/assets/{assistantModels-BsSgRsws.js → assistantModels-D3ncWWu0.js} +1 -1
  129. package/dist/interface/assets/{auth-DFesRtwI.js → auth-AfZrkJ2f.js} +1 -1
  130. package/dist/interface/assets/{automations-D2bnX8uw.js → automations-DOCG0q8-.js} +1 -1
  131. package/dist/interface/assets/{back-filled-D-X19YMO.js → back-filled-CJoz7Gkl.js} +1 -1
  132. package/dist/interface/assets/{bell-ring-DreEHgoT.js → bell-ring-CBf0Yn3H.js} +1 -1
  133. package/dist/interface/assets/{brain-DuDAg544.js → brain-uZ03n3LW.js} +1 -1
  134. package/dist/interface/assets/cameraSources-mHEz9ROa.js +1 -0
  135. package/dist/interface/assets/{cctv-DM-C_8_6.js → cctv-VgKQ-dBV.js} +1 -1
  136. package/dist/interface/assets/{check-circle-Bevuw8-0.js → check-circle-BU-KNgPB.js} +1 -1
  137. package/dist/interface/assets/{check-circle-outline-aMxkvksr.js → check-circle-outline-BsxzAMed.js} +1 -1
  138. package/dist/interface/assets/{chevron-down-CCFn9Z56.js → chevron-down-CxK4Sfjs.js} +1 -1
  139. package/dist/interface/assets/{chevron-up-CSImUM3_.js → chevron-up-DWfNH8va.js} +1 -1
  140. package/dist/interface/assets/{clock-outline-DH3WIEJt.js → clock-outline-BtWx4GaF.js} +1 -1
  141. package/dist/interface/assets/{close-CMxyM4v9.js → close-Be7oB7d_.js} +1 -1
  142. package/dist/interface/assets/{close-circle-CfgJCZ9A.js → close-circle-D7Jmhp_7.js} +1 -1
  143. package/dist/interface/assets/{cloud-check-CbdFLIdR.js → cloud-check-zCGJxpWI.js} +1 -1
  144. package/dist/interface/assets/cloudHandoff-zJCrDmwk.js +1 -0
  145. package/dist/interface/assets/{config-DDaCrMSU.js → config-AG0SnOiY.js} +1 -1
  146. package/dist/interface/assets/{content-copy-Bz49QPOI.js → content-copy-BcYlfuFc.js} +1 -1
  147. package/dist/interface/assets/{copy-DA6QQHRt.js → copy-DuY-M96E.js} +1 -1
  148. package/dist/interface/assets/{cube-scan-IiH8zwm2.js → cube-scan-Cae03i_N.js} +1 -1
  149. package/dist/interface/assets/{database-refresh-outline-CIUDpcuq.js → database-refresh-outline-B3OEQFF7.js} +1 -1
  150. package/dist/interface/assets/{delete-Btu-UVx9.js → delete-BWgOAzKl.js} +1 -1
  151. package/dist/interface/assets/{dist-D_qWDAKp.js → dist-DmpuuM9s.js} +1 -1
  152. package/dist/interface/assets/{dots-vertical-D496SIss.js → dots-vertical-Kby1GY8_.js} +1 -1
  153. package/dist/interface/assets/{download-BSC7lwq_.js → download-C291Yq7I.js} +1 -1
  154. package/dist/interface/assets/esm-B2TVBF3B.js +1 -0
  155. package/dist/interface/assets/esm-BEntuCG7.js +1 -0
  156. package/dist/interface/assets/esm-BRnyrFH8.js +1 -0
  157. package/dist/interface/assets/esm-CCwXzd_8.js +1 -0
  158. package/dist/interface/assets/esm-CEjwTsuD.js +1 -0
  159. package/dist/interface/assets/esm-CGGV9tC4.js +1 -0
  160. package/dist/interface/assets/esm-CI2tTOc5.js +1 -0
  161. package/dist/interface/assets/esm-CgxZmMYv.js +1 -0
  162. package/dist/interface/assets/esm-Csc6f5Fy.js +1 -0
  163. package/dist/interface/assets/esm-Qzx3d-Ie.js +1 -0
  164. package/dist/interface/assets/esm-a_w7mTdx.js +1 -0
  165. package/dist/interface/assets/esm-iKfsu7-H.js +1 -0
  166. package/dist/interface/assets/esm-ks5kvk_e.js +1 -0
  167. package/dist/interface/assets/esm-nJfTguKF.js +1 -0
  168. package/dist/interface/assets/{eventIcons-UQutPG3p.js → eventIcons-C3JWChgS.js} +1 -1
  169. package/dist/interface/assets/{eye-off-CSU0U8g7.js → eye-off-zGCIHKOK.js} +1 -1
  170. package/dist/interface/assets/{flowSchema-YJtAu9gB.js → flowSchema-B0d3VjU7.js} +1 -1
  171. package/dist/interface/assets/{help-circle-outline-Cr_yNhPi.js → help-circle-outline-DXFepDAG.js} +1 -1
  172. package/dist/interface/assets/{history-anuCbp1T.js → history-D-FlZdKD.js} +1 -1
  173. package/dist/interface/assets/{home-N3bDR1vX.js → home-DPdzRxcM.js} +1 -1
  174. package/dist/interface/assets/{information-outline-CMWIvLNB.js → information-outline-ChOM9qgI.js} +1 -1
  175. package/dist/interface/assets/{intercomService-CjoJaOZ7.js → intercomService-DG3EeZ6s.js} +1 -1
  176. package/dist/interface/assets/{lan-CYXjdk7L.js → lan-DvYEO83l.js} +1 -1
  177. package/dist/interface/assets/{main-DVa5U7UB.css → main-CGY9cVyi.css} +1 -1
  178. package/dist/interface/assets/main-DkHV6YgB.js +3 -0
  179. package/dist/interface/assets/{microphone-BB2pATI_.js → microphone-D-T9xga4.js} +1 -1
  180. package/dist/interface/assets/{minus-BCp3ZNKO.js → minus-4T4INuO4.js} +1 -1
  181. package/dist/interface/assets/mqtt-DE2VbNdt.js +1 -0
  182. package/dist/interface/assets/native-CtfXrwj5.js +1 -0
  183. package/dist/interface/assets/native-JMtkOkIV.js +1 -0
  184. package/dist/interface/assets/{nodeDefinitions-ByrqsENY.js → nodeDefinitions-Dp8cnne1.js} +1 -1
  185. package/dist/interface/assets/{notifications-5yeK345h.js → notifications-8FH4ApEz.js} +1 -1
  186. package/dist/interface/assets/{pause-BQlxwAW2.js → pause-DHqHYA3V.js} +1 -1
  187. package/dist/interface/assets/{pencil-outline-CIQL5Kui.js → pencil-outline-D-GmPf8M.js} +1 -1
  188. package/dist/interface/assets/{pencil-CDsNnEXi.js → pencil-vACi-JzY.js} +1 -1
  189. package/dist/interface/assets/plugin-Dt5Xetfz.js +1 -0
  190. package/dist/interface/assets/{plugins-BTOdE_zv.js → plugins-2JLUEMYc.js} +1 -1
  191. package/dist/interface/assets/{plus-Bp4q9G7S.js → plus-BBUb8_uL.js} +1 -1
  192. package/dist/interface/assets/{plus-CySoovdr.js → plus-BJb7U4bN.js} +1 -1
  193. package/dist/interface/assets/{power-WmBLDR0-.js → power-Dm_aNIz-.js} +1 -1
  194. package/dist/interface/assets/{radar-CyYAmume.js → radar-Dcvdz--e.js} +1 -1
  195. package/dist/interface/assets/{refresh-CHTA3jVN.js → refresh-CO4F18Je.js} +1 -1
  196. package/dist/interface/assets/{restore-C8RNM5yX.js → restore-xRBt3Grb.js} +1 -1
  197. package/dist/interface/assets/{rooms-BCdm6IAx.js → rooms-DoAfzA8W.js} +1 -1
  198. package/dist/interface/assets/{round-alt-arrow-left-bold-Gh5mi_yR.js → round-alt-arrow-left-bold-CZHXzGS5.js} +1 -1
  199. package/dist/interface/assets/{search-BajCVmOI.js → search-D75YW08B.js} +1 -1
  200. package/dist/interface/assets/{sensorIcons-5Ynqwo3e.js → sensorIcons-BntiOPX7.js} +1 -1
  201. package/dist/interface/assets/{sensorSlots-BF70tpV7.js → sensorSlots-biaL-O8E.js} +1 -1
  202. package/dist/interface/assets/{sensors-CeFEEz8r.js → sensors-DyAMdS-H.js} +1 -1
  203. package/dist/interface/assets/server-BDRUGj61.js +1 -0
  204. package/dist/interface/assets/{settings-DnksaK7m.js → settings-DDOgc5BX.js} +1 -1
  205. package/dist/interface/assets/{source-branch-CzqIPffP.js → source-branch-DVHuYlkZ.js} +1 -1
  206. package/dist/interface/assets/{theme-DF_XA58O.js → theme-CLxrnR60.js} +1 -1
  207. package/dist/interface/assets/{trash-2-DJeEhHf4.js → trash-2-DDKPtl2x.js} +1 -1
  208. package/dist/interface/assets/{trash-can-outline-DrT6iw7I.js → trash-can-outline-DVH3zgo0.js} +1 -1
  209. package/dist/interface/assets/{trash-fill-Bb_-UicM.js → trash-fill-C_IJ4Vu2.js} +1 -1
  210. package/dist/interface/assets/{trash2-Dsl8gfxq.js → trash2-DY0XTaJD.js} +1 -1
  211. package/dist/interface/assets/{types-CklFkUXk.js → types-8JXzkoC8.js} +1 -1
  212. package/dist/interface/assets/{types-ArGM5-5O.js → types-B4LLKzDW.js} +1 -1
  213. package/dist/interface/assets/types-a7Nw-P-m.js +1 -0
  214. package/dist/interface/assets/{undo-DoqJW-k7.js → undo-YRkBYCnf.js} +1 -1
  215. package/dist/interface/assets/ungrouped-BoAbb9w3.js +1 -0
  216. package/dist/interface/assets/ungrouped-ChmBvcXp.css +1 -0
  217. package/dist/interface/assets/updates-F-veEP1I.js +1 -0
  218. package/dist/interface/assets/{upload-DtIcwiNC.js → upload-2WcHRjTq.js} +1 -1
  219. package/dist/interface/assets/{upload-C3w1XH-o.js → upload-BiE7VzTj.js} +1 -1
  220. package/dist/interface/assets/{useAppVersion-Dcvu95bZ.js → useAppVersion-BjUQmB7M.js} +1 -1
  221. package/dist/interface/assets/{useAssistantActions-Cc_O6M9_.js → useAssistantActions-CNEJol4o.js} +1 -1
  222. package/dist/interface/assets/useBackupRestore-Biqn_lhh.js +1 -0
  223. package/dist/interface/assets/{useCameraOptions-8I4MTDgj.js → useCameraOptions-D_oduve2.js} +1 -1
  224. package/dist/interface/assets/useKeyboardInset-CPWSVYlA.js +1 -0
  225. package/dist/interface/assets/{useLogsSocket-bpOiLgWT.js → useLogsSocket-B_jXUqv8.js} +1 -1
  226. package/dist/interface/assets/{useNavLayout-Cjf6Da2u.js → useNavLayout-DEngIIeU.js} +1 -1
  227. package/dist/interface/assets/{usePermissions-BXTw4tII.js → usePermissions-DAO92InI.js} +1 -1
  228. package/dist/interface/assets/{usePluginUpdates-bOMj-IvL.js → usePluginUpdates-CJi8Y_wl.js} +1 -1
  229. package/dist/interface/assets/{usePushRegistration-HOvLuUVP.js → usePushRegistration-j9WCeFbv.js} +2 -2
  230. package/dist/interface/assets/{useServerRestart-CQN4cdHJ.js → useServerRestart-BVks5tuC.js} +1 -1
  231. package/dist/interface/assets/{useStreamStatus-Da7c2Wme.js → useStreamStatus-DQ0NSyU8.js} +1 -1
  232. package/dist/interface/assets/{useTabSwipe-fFuyJJBQ.js → useTabSwipe-CVq7EcIY.js} +1 -1
  233. package/dist/interface/assets/{useUpdateChannel-Ca1RX32u.js → useUpdateChannel-C0fjDvNP.js} +1 -1
  234. package/dist/interface/assets/{useUpdatesSocket-DHZNpLQX.js → useUpdatesSocket-DXKF9hzc.js} +1 -1
  235. package/dist/interface/assets/useUserOptions-UjMeAL5n.js +1 -0
  236. package/dist/interface/assets/{variable-ywTlRfo5.js → variable-Cp8o-q8t.js} +1 -1
  237. package/dist/interface/assets/vendor-Df81FCJz.js +29 -0
  238. package/dist/interface/assets/{vendor-ace-CvEoip98.js → vendor-ace-QSsGUspX.js} +1 -1
  239. package/dist/interface/assets/{vendor-cameraui-CK4yHsJi.js → vendor-cameraui-GmMRyJ2R.js} +45 -45
  240. package/dist/interface/assets/{vendor-capacitor-Bs_WzL0Q.js → vendor-capacitor-t5EIN1GG.js} +2 -2
  241. package/dist/interface/assets/{vendor-chart-DBK083Hu.js → vendor-chart-BiJYkx5_.js} +1 -1
  242. package/dist/interface/assets/{vendor-core-B-Q4es-f.js → vendor-core-BeAannbA.js} +1 -1
  243. package/dist/interface/assets/{vendor-dnd-DGQLvX6Y.js → vendor-dnd-C1kMh9_t.js} +1 -1
  244. package/dist/interface/assets/{vendor-draggabilly-D8CK6M-y.js → vendor-draggabilly-Cw1oJ6qc.js} +1 -1
  245. package/dist/interface/assets/vendor-leaflet-OSZlONe5.js +1 -0
  246. package/dist/interface/assets/{vendor-markdown-qHIinIUE.js → vendor-markdown-DTWiWKBj.js} +1 -1
  247. package/dist/interface/assets/{vendor-primevue-Cmp3VjIC.js → vendor-primevue-Zx6t06A4.js} +77 -77
  248. package/dist/interface/assets/{vendor-vueflow-bSwRZ9X8.js → vendor-vueflow-DWU_IzGe.js} +1 -1
  249. package/dist/interface/assets/web-B98ahwoP.js +1 -0
  250. package/dist/interface/assets/web-BSsSrRZf.js +1 -0
  251. package/dist/interface/assets/web-BiNRDta4.js +1 -0
  252. package/dist/interface/assets/web-BjKL51lK-CZKmYhby.js +1 -0
  253. package/dist/interface/assets/web-BjtOcquy.js +1 -0
  254. package/dist/interface/assets/web-CkTE9nCG.js +1 -0
  255. package/dist/interface/assets/web-Cvogq5S5.js +1 -0
  256. package/dist/interface/assets/web-D-A4EBKj.js +1 -0
  257. package/dist/interface/assets/web-DVGMBduz.js +1 -0
  258. package/dist/interface/assets/web-SpWB7I6X.js +1 -0
  259. package/dist/interface/assets/web-k0ihT_qK.js +1 -0
  260. package/dist/interface/assets/web-ovBpm7Dl.js +1 -0
  261. package/dist/interface/assets/web-z5Xz9tOQ.js +1 -0
  262. package/dist/interface/assets/web-zfhkFevT.js +1 -0
  263. package/dist/interface/assets/{webhook-CWKf2Qxu.js → webhook-DIjChTrs.js} +1 -1
  264. package/dist/interface/assets/workbox-window.prod.es5-DRKojI0e.js +1 -0
  265. package/dist/interface/assets/{zoom-in-CHkXAWHy.js → zoom-in-rMB152Uz.js} +1 -1
  266. package/dist/interface/ha/{404-C0mWQGWl.js → 404-D5gfy0Cd.js} +1 -1
  267. package/dist/interface/ha/{About-ByE7XErJ.js → About-JzlpCzBN.js} +3 -3
  268. package/dist/interface/ha/{Assistant-Z3FTR868.js → Assistant-DgOfGesf.js} +2239 -1725
  269. package/dist/interface/ha/{Automation-COQqTFNw.js → Automation-BDaWYiBu.js} +146 -146
  270. package/dist/interface/ha/{AutomationImport-ueWqMBX9.js → AutomationImport-BNB_PJ9R.js} +6 -6
  271. package/dist/interface/ha/{AutomationStore-DBO4aZqy.js → AutomationStore-_TeOt1wz.js} +73 -73
  272. package/dist/interface/ha/{AutomationStoreDetail-DMnYu7hf.js → AutomationStoreDetail-jjIEZoRi.js} +20 -20
  273. package/dist/interface/ha/{Automations-CMdbidc0.js → Automations-DM6FEVOw.js} +110 -110
  274. package/dist/interface/ha/Camera-sH9fRv18.js +670 -0
  275. package/dist/interface/ha/{CameraConsole-oMNZfKE6.js → CameraConsole-BoVql05l.js} +4 -4
  276. package/dist/interface/ha/{Cameras-CsqrLx97.js → Cameras-cQBGvXq7.js} +349 -347
  277. package/dist/interface/ha/{Camview-Br0LUakz.js → Camview-mkG5FXZM.js} +323 -319
  278. package/dist/interface/ha/{Config-Y5eUNSW7.js → Config-BNPDzo_h.js} +11 -11
  279. package/dist/interface/ha/{ConfigActionAssistant-hl-6ZACj.js → ConfigActionAssistant-C-8P3DYz.js} +4 -4
  280. package/dist/interface/ha/{ConfigActionCameraControl-DnXlVFWD.js → ConfigActionCameraControl-x1ksGL7m.js} +3 -3
  281. package/dist/interface/ha/{ConfigActionHttp-BkpkMmRd.js → ConfigActionHttp-DzCJp85z.js} +2 -2
  282. package/dist/interface/ha/{ConfigActionImageInput-Dp78_QS_.js → ConfigActionImageInput-C5C5U_2z.js} +1 -1
  283. package/dist/interface/ha/{ConfigActionMqtt-DA_UWb5j.js → ConfigActionMqtt-T29xb75r.js} +4 -4
  284. package/dist/interface/ha/{ConfigActionNotification-CQ4Ses3a.js → ConfigActionNotification-BcnyilF9.js} +3 -3
  285. package/dist/interface/ha/{ConfigActionNotificationControl-Cb5PNGz-.js → ConfigActionNotificationControl-D3wIVKuU.js} +2 -2
  286. package/dist/interface/ha/{ConfigActionOutput-DLuNHwRb.js → ConfigActionOutput-hD-yVczw.js} +1 -1
  287. package/dist/interface/ha/{ConfigActionPlugin-ChKFCNaj.js → ConfigActionPlugin-Bz1O-O4Q.js} +5 -5
  288. package/dist/interface/ha/{ConfigActionSensor-DOutFalW.js → ConfigActionSensor-FOz-PYl_.js} +5 -5
  289. package/dist/interface/ha/{ConfigActionSnapshot-GWgY6YIN.js → ConfigActionSnapshot-CmxEOuK1.js} +2 -2
  290. package/dist/interface/ha/{ConfigActionVariable-bu-9VYTG.js → ConfigActionVariable-BCvkrdCh.js} +1 -1
  291. package/dist/interface/ha/{ConfigConditionIfElse-iNp8tlZV.js → ConfigConditionIfElse-icfTG9OA.js} +3 -3
  292. package/dist/interface/ha/{ConfigConditionSensorState-Dn7kcHpJ.js → ConfigConditionSensorState-ClUAsm0d.js} +4 -4
  293. package/dist/interface/ha/{ConfigConditionSwitch-DaUlDgo0.js → ConfigConditionSwitch-C8AMCkn6.js} +5 -5
  294. package/dist/interface/ha/{ConfigSensorValueInput-D6m6suqJ.js → ConfigSensorValueInput-ChvDQzGd.js} +4 -4
  295. package/dist/interface/ha/{ConfigTriggerDetection-C5B_DC_L.js → ConfigTriggerDetection-aUSyaClu.js} +2 -2
  296. package/dist/interface/ha/{ConfigTriggerGeofence-B4WVNcK5.js → ConfigTriggerGeofence-DsJeJWP4.js} +7 -7
  297. package/dist/interface/ha/{ConfigTriggerMqtt-wnMfk_Un.js → ConfigTriggerMqtt-CsAxA7QZ.js} +1 -1
  298. package/dist/interface/ha/{ConfigTriggerSensor-xFpI5KPu.js → ConfigTriggerSensor-CTxr9cfU.js} +1 -1
  299. package/dist/interface/ha/{ConfigTriggerSystem-YI9WYYVM.js → ConfigTriggerSystem-C8UEfpfs.js} +2 -2
  300. package/dist/interface/ha/{ConfigTriggerWebhook-58c2KgUe.js → ConfigTriggerWebhook-frEE-SCB.js} +1 -1
  301. package/dist/interface/ha/{Console-Coiqh32K.js → Console-A3VtbsLg.js} +12 -12
  302. package/dist/interface/ha/{CuiAutomationRunsDialog-CJ2MGfEY.js → CuiAutomationRunsDialog-BlJvhBiX.js} +2 -2
  303. package/dist/interface/ha/{CuiBottomSheet-BlG9Pl9j.js → CuiBottomSheet-Cu-t3H0Z.js} +1 -1
  304. package/dist/interface/ha/{CuiCameraRecordings-DLXEB4Q7.js → CuiCameraRecordings-R5ArEmqJ.js} +10 -10
  305. package/dist/interface/ha/{CuiCameraShares-BCIeaM6u.js → CuiCameraShares-B9pfRkM4.js} +5 -5
  306. package/dist/interface/ha/{CuiCameraTable-PYYC7sOu.js → CuiCameraTable-CKjGKaMC.js} +9 -9
  307. package/dist/interface/ha/{CuiChartTable-FQ2iR5Hd.js → CuiChartTable-BxWjRe-k.js} +89 -74
  308. package/dist/interface/ha/{CuiConsole-C77k5q_-.js → CuiConsole-C5fzsR7t.js} +4 -4
  309. package/dist/interface/ha/{CuiDataTable-CIKQLseG.js → CuiDataTable-BOdQDY8J.js} +5 -5
  310. package/dist/interface/ha/{CuiPluginCard-DZNXKP_P.js → CuiPluginCard-BT71RRAD.js} +33 -33
  311. package/dist/interface/ha/{CuiPluginOAuthButton-DVf52_Zc.js → CuiPluginOAuthButton-moh9uS7G.js} +7 -7
  312. package/dist/interface/ha/{CuiPluginTrustBadge-CPljYiM8.js → CuiPluginTrustBadge-F_pVWkPJ.js} +1 -1
  313. package/dist/interface/ha/{CuiQRCode-oe8PLnLj.js → CuiQRCode-BNuj-nJ4.js} +6 -6
  314. package/dist/interface/ha/{CuiSchema-CQy94ZTs.js → CuiSchema-Cb_8Ks-I.js} +125 -125
  315. package/dist/interface/ha/{CuiTopNavbarItem-D6OHZLQY.js → CuiTopNavbarItem-BGzrrTls.js} +1 -1
  316. package/dist/interface/ha/{Faces-DxAPvemO.js → Faces-CsM5VO8Q.js} +247 -247
  317. package/dist/interface/ha/{FirstSteps-ZINTSaeL.js → FirstSteps-BFX0-EEi.js} +12 -12
  318. package/dist/interface/ha/{Floorplan-DkbL8ppT.js → Floorplan-D6MGqSJT.js} +198 -199
  319. package/dist/interface/ha/{Instances-totWtqd7.js → Instances-CHzIUyyA.js} +72 -72
  320. package/dist/interface/ha/{Logs-CzabIFja.js → Logs-DZKM3dWv.js} +10 -10
  321. package/dist/interface/ha/{Menu-DcVBOQfw.js → Menu-BQz4dfQi.js} +8 -8
  322. package/dist/interface/ha/{Metrics-B_SN5hbp.js → Metrics-CdpWJ1mm.js} +310 -308
  323. package/dist/interface/ha/{OAuthDeviceFlow-B28TPsTQ.js → OAuthDeviceFlow-DUELtx3X.js} +9 -9
  324. package/dist/interface/ha/{Plugin-B2PbbB8d.js → Plugin-5bbTF0Rv.js} +92 -92
  325. package/dist/interface/ha/{PluginConsole-_KeG4FvO.js → PluginConsole-C__0lzsS.js} +4 -4
  326. package/dist/interface/ha/{PluginDetail-GK_Fx14e.js → PluginDetail-Blrktk9W.js} +9 -9
  327. package/dist/interface/ha/{PluginSearch-qSy4aqAW.js → PluginSearch-BKbdwHQ1.js} +121 -121
  328. package/dist/interface/ha/{PluginUpdateProgress-C4Q2j6VO.js → PluginUpdateProgress-IsNiecu3.js} +3 -3
  329. package/dist/interface/ha/{Plugins-D0tvZHie.js → Plugins-CC2Dwlx5.js} +53 -53
  330. package/dist/interface/ha/{Recordings-CpxJYaAa.js → Recordings-B1XsJrzs.js} +303 -301
  331. package/dist/interface/ha/{SensorEdit-8KtqLXEu.js → SensorEdit-Bi2Yx_ji.js} +46 -46
  332. package/dist/interface/ha/{SensorHistory-CPTTsdjM.js → SensorHistory-sqG_6eav.js} +2 -2
  333. package/dist/interface/ha/{Sensors-DJt_Hnn2.js → Sensors-DLtOh1p4.js} +509 -510
  334. package/dist/interface/ha/{Settings-B-OdG5pG.js → Settings-DI3_zenm.js} +38 -38
  335. package/dist/interface/ha/{SettingsAccount-Ba2-2Lbi.js → SettingsAccount-pS86Qyr-.js} +251 -251
  336. package/dist/interface/ha/{SettingsAppearance-D56HjSuQ.js → SettingsAppearance-tS3bubKQ.js} +4 -4
  337. package/dist/interface/ha/{SettingsAssistant-DglU0auc.js → SettingsAssistant-LejCRXsF.js} +501 -501
  338. package/dist/interface/ha/{SettingsBackup-DZx4McDz.js → SettingsBackup-CkhD1Kze.js} +23 -23
  339. package/dist/interface/ha/{SettingsList-D9nIGkbE.js → SettingsList-bibwvPSM.js} +2 -2
  340. package/dist/interface/ha/{SettingsMqtt-BOszh--k.js → SettingsMqtt-DSt0B4Qg.js} +18 -18
  341. package/dist/interface/ha/{SettingsNotifications-DBVpZfp0.js → SettingsNotifications-BF7ajNwE.js} +118 -118
  342. package/dist/interface/ha/{SettingsRecordings-D3oJnizu.js → SettingsRecordings-BTIdncxg.js} +9 -9
  343. package/dist/interface/ha/{SettingsRemote-BOotvcOT.js → SettingsRemote-Cba4P1-O.js} +347 -344
  344. package/dist/interface/ha/{SettingsSystem-Bg11qoQX.js → SettingsSystem-_Nnh2ZF5.js} +9 -9
  345. package/dist/interface/ha/{SettingsUsers-KpLs9Jnh.js → SettingsUsers-BfHFoxJi.js} +83 -83
  346. package/dist/interface/ha/{Terminal-D6opTHYI.js → Terminal-Dv_7oWmS.js} +11 -11
  347. package/dist/interface/ha/Training-CaSFA5oH.js +1699 -0
  348. package/dist/interface/ha/{Updates-C_OvXJjd.js → Updates-BHl5H7zE.js} +15 -15
  349. package/dist/interface/ha/{VariableInput-CfaDp67S.js → VariableInput-DtLo7-Nw.js} +1 -1
  350. package/dist/interface/ha/{VersionsHandler-D1FVeYUZ.js → VersionsHandler-CF0DSeol.js} +10 -10
  351. package/dist/interface/ha/{VirtualSensorCreate-DJIgMVrt.js → VirtualSensorCreate-C907EgIz.js} +2 -2
  352. package/dist/interface/ha/Workers-Dz1d9gEQ.js +814 -0
  353. package/dist/interface/ha/{ace-B3bPzJu9.js → ace-C9MtBQVV.js} +1 -1
  354. package/dist/interface/ha/{ace.config-Dt55Nqby.js → ace.config-CSXnaIzV.js} +1 -1
  355. package/dist/interface/ha/{api-D2VzV4is.js → api-DUqpDJ2N.js} +14361 -14070
  356. package/dist/interface/ha/{api-CDawdL4p.js → api-gId1nlMj.js} +4 -4
  357. package/dist/interface/ha/{assistant-BmDAfChm.js → assistant-BaR65gIY.js} +50 -50
  358. package/dist/interface/ha/{auth-CvLz9C4w.js → auth-Btsz_KxO.js} +38 -38
  359. package/dist/interface/ha/{automationBlueprint-BhNaeOZ1.js → automationBlueprint-CuO3iOiM.js} +3 -3
  360. package/dist/interface/ha/cameraui-cards.js +1 -1
  361. package/dist/interface/ha/{cards-MQrnU0T8.js → cards-DWhezIPP.js} +1447 -1407
  362. package/dist/interface/ha/{config-t_oAKFkJ.js → config-BKStpoEQ.js} +12 -12
  363. package/dist/interface/ha/{dist-oFWkn6pD.js → dist-CM7R4_Gj.js} +34 -25
  364. package/dist/interface/ha/{mqtt-C20h1uze.js → mqtt-ajcSmTB-.js} +14 -14
  365. package/dist/interface/ha/{notifications-Cy9DKiEn.js → notifications-Cf9dXHEO.js} +18 -18
  366. package/dist/interface/ha/{pinia-BokSpDzj.js → pinia-DIKO5lnE.js} +267 -259
  367. package/dist/interface/ha/{plugins-jozYyBhV.js → plugins-ml823dJV.js} +61 -61
  368. package/dist/interface/ha/{rooms-DyfT3cXp.js → rooms-C5gUErBi.js} +9 -9
  369. package/dist/interface/ha/{server-hCCjQjZE.js → server-dArenpJI.js} +26 -26
  370. package/dist/interface/ha/{types-RG0SckNR.js → types-DYymuACA.js} +25 -25
  371. package/dist/interface/ha/{ungrouped-BbyfoCQp.js → ungrouped-BHLAySWP.js} +237 -213
  372. package/dist/interface/ha/{updates-hUgVDgoD.js → updates-D5sFzGtC.js} +33 -33
  373. package/dist/interface/ha/{useAppVersion-wNhZDuvR.js → useAppVersion-C5x3Ap4_.js} +1 -1
  374. package/dist/interface/ha/{useKeyboardInset-Cmbvb_W3.js → useKeyboardInset-Cj0T2AFX.js} +1 -1
  375. package/dist/interface/ha/{useLogsSocket-y9Aex3tJ.js → useLogsSocket-DtvfQlPh.js} +1 -1
  376. package/dist/interface/ha/{useNavLayout-Ehb0t34k.js → useNavLayout-HSFBA4JV.js} +13 -13
  377. package/dist/interface/ha/{useServerRestart-CRSVcz3z.js → useServerRestart-Ci0SppGW.js} +1 -1
  378. package/dist/interface/ha/{useTabSwipe-B_bseZkI.js → useTabSwipe-CPKkRmaH.js} +1 -1
  379. package/dist/interface/ha/{useUpdateChannel-C_GU6lj6.js → useUpdateChannel-CXHHovK3.js} +2 -2
  380. package/dist/interface/ha/{useUpdatesSocket-CYgHb7UX.js → useUpdatesSocket-DVST2YXV.js} +1 -1
  381. package/dist/interface/ha/{useUserOptions-pVYr-s3O.js → useUserOptions-BYcYI6QA.js} +1 -1
  382. package/dist/interface/index.html +70 -70
  383. package/dist/interface/sw.js +1 -1
  384. package/dist/server/package.json +16 -16
  385. package/dist/server/requirements.txt +2 -2
  386. package/dist/server/src/_camera_ui_tools/camera_ui_sdk/camera/config.py +8 -0
  387. package/dist/server/src/_camera_ui_tools/camera_ui_sdk/camera/device.py +5 -1
  388. package/dist/server/src/_camera_ui_tools/camera_ui_sdk/internal/camera_config_internal.py +5 -1
  389. package/dist/server/src/_camera_ui_tools/camera_ui_sdk/manager/__init__.py +2 -1
  390. package/dist/server/src/api/controllers/api.controller.js +1 -1
  391. package/dist/server/src/api/controllers/api.controller.js.map +1 -1
  392. package/dist/server/src/api/controllers/plugins.controller.js +1 -0
  393. package/dist/server/src/api/controllers/plugins.controller.js.map +1 -1
  394. package/dist/server/src/api/controllers/workers.controller.d.ts +2 -2
  395. package/dist/server/src/api/controllers/workers.controller.js +8 -2
  396. package/dist/server/src/api/controllers/workers.controller.js.map +1 -1
  397. package/dist/server/src/api/database/record-schemas.d.ts +3 -0
  398. package/dist/server/src/api/database/record-schemas.js +1 -0
  399. package/dist/server/src/api/database/record-schemas.js.map +1 -1
  400. package/dist/server/src/api/database/types.d.ts +4 -0
  401. package/dist/server/src/api/routes/workers.routes.js +4 -4
  402. package/dist/server/src/api/routes/workers.routes.js.map +1 -1
  403. package/dist/server/src/api/schemas/cameras.schema.d.ts +38 -0
  404. package/dist/server/src/api/schemas/cameras.schema.js +22 -0
  405. package/dist/server/src/api/schemas/cameras.schema.js.map +1 -1
  406. package/dist/server/src/api/schemas/users.schema.d.ts +12 -0
  407. package/dist/server/src/api/schemas/users.schema.js +4 -0
  408. package/dist/server/src/api/schemas/users.schema.js.map +1 -1
  409. package/dist/server/src/api/schemas/workers.schema.d.ts +5 -4
  410. package/dist/server/src/api/schemas/workers.schema.js +6 -3
  411. package/dist/server/src/api/schemas/workers.schema.js.map +1 -1
  412. package/dist/server/src/api/services/cameras.service.d.ts +3 -0
  413. package/dist/server/src/api/services/cameras.service.js +47 -2
  414. package/dist/server/src/api/services/cameras.service.js.map +1 -1
  415. package/dist/server/src/api/services/plugins.service.d.ts +1 -0
  416. package/dist/server/src/api/services/plugins.service.js +5 -1
  417. package/dist/server/src/api/services/plugins.service.js.map +1 -1
  418. package/dist/server/src/api/services/workers.service.d.ts +2 -0
  419. package/dist/server/src/api/services/workers.service.js +15 -0
  420. package/dist/server/src/api/services/workers.service.js.map +1 -1
  421. package/dist/server/src/api/types/index.d.ts +3 -2
  422. package/dist/server/src/api/websocket/nsp/notifications.d.ts +1 -0
  423. package/dist/server/src/api/websocket/nsp/notifications.js +7 -0
  424. package/dist/server/src/api/websocket/nsp/notifications.js.map +1 -1
  425. package/dist/server/src/assistant/automation-catalog.js +12 -2
  426. package/dist/server/src/assistant/automation-catalog.js.map +1 -1
  427. package/dist/server/src/assistant/pricing.js +39 -10
  428. package/dist/server/src/assistant/pricing.js.map +1 -1
  429. package/dist/server/src/assistant/providers.js +9 -1
  430. package/dist/server/src/assistant/providers.js.map +1 -1
  431. package/dist/server/src/camera/decoder/event-manager.d.ts +1 -2
  432. package/dist/server/src/camera/decoder/event-manager.js +37 -59
  433. package/dist/server/src/camera/decoder/event-manager.js.map +1 -1
  434. package/dist/server/src/manager/coreManager.d.ts +2 -1
  435. package/dist/server/src/manager/coreManager.js +9 -2
  436. package/dist/server/src/manager/coreManager.js.map +1 -1
  437. package/dist/server/src/manager/notificationManager.d.ts +1 -0
  438. package/dist/server/src/manager/notificationManager.js +11 -0
  439. package/dist/server/src/manager/notificationManager.js.map +1 -1
  440. package/dist/server/src/plugins/runtime/node/proxy/coreManager.js +1 -1
  441. package/dist/server/src/plugins/runtime/node/proxy/coreManager.js.map +1 -1
  442. package/dist/server/src/plugins/runtime/python/proxy/camera_device.py +3 -0
  443. package/dist/server/src/plugins/runtime/python/proxy/core_manager.py +1 -1
  444. package/dist/server/src/plugins/runtime/python/rpc/typings.py +1 -1
  445. package/dist/server/src/rpc/interfaces/core.d.ts +1 -1
  446. package/dist/server/src/sensors/registry.d.ts +2 -0
  447. package/dist/server/src/sensors/registry.js +24 -0
  448. package/dist/server/src/sensors/registry.js.map +1 -1
  449. package/dist/server/src/services/config/index.d.ts +1 -0
  450. package/dist/server/src/services/config/index.js +12 -1
  451. package/dist/server/src/services/config/index.js.map +1 -1
  452. package/dist/server/src/utils/ipc.js +23 -17
  453. package/dist/server/src/utils/ipc.js.map +1 -1
  454. package/dist/server/src/workers/agent.js +2 -0
  455. package/dist/server/src/workers/agent.js.map +1 -1
  456. package/dist/server/src/workers/manager.d.ts +1 -0
  457. package/dist/server/src/workers/manager.js +22 -0
  458. package/dist/server/src/workers/manager.js.map +1 -1
  459. package/dist/server/src/workers/types.d.ts +5 -0
  460. package/dist/server/src/workers/types.js.map +1 -1
  461. package/npm-shrinkwrap.json +111 -111
  462. package/package.json +16 -16
  463. package/dist/interface/assets/Assistant-BJKGIvVo.js +0 -1
  464. package/dist/interface/assets/Automation-C95DzuZb.js +0 -3
  465. package/dist/interface/assets/Automations-BOP_17Ri.js +0 -2
  466. package/dist/interface/assets/Camera-BW9ikKqh.css +0 -1
  467. package/dist/interface/assets/Camera-C5S7eI9a.js +0 -2
  468. package/dist/interface/assets/Camview-CHxKB41T.js +0 -1
  469. package/dist/interface/assets/Config-BrDDGWpr.js +0 -2
  470. package/dist/interface/assets/Console-cIr6lYux.js +0 -1
  471. package/dist/interface/assets/CuiAssistantConversation-Bigl43Ph.js +0 -5
  472. package/dist/interface/assets/CuiAutomationRunsDialog-Ci7SWAml.js +0 -1
  473. package/dist/interface/assets/CuiBottomSheet-ViBOgklN.js +0 -1
  474. package/dist/interface/assets/CuiCameraPipCard-BQKk4fxY.css +0 -1
  475. package/dist/interface/assets/CuiCameraPipCard-wdK7xir-.js +0 -1
  476. package/dist/interface/assets/CuiCameraRecordings-BB7bF67B.js +0 -1
  477. package/dist/interface/assets/CuiCameraTable-CHnQFkce.js +0 -1
  478. package/dist/interface/assets/CuiChartTable-DXY7rY3O.css +0 -1
  479. package/dist/interface/assets/CuiChartTable-dIcxGtfl.js +0 -1
  480. package/dist/interface/assets/CuiDataTable-CQmp5mAy.js +0 -1
  481. package/dist/interface/assets/CuiMarkdownContent-DTAm-EDR.js +0 -1
  482. package/dist/interface/assets/CuiPluginCard-BjIc7It9.js +0 -2
  483. package/dist/interface/assets/Faces-p18jNfXl.js +0 -1
  484. package/dist/interface/assets/Floorplan-DYyEx7WO.js +0 -1
  485. package/dist/interface/assets/Metrics-ChVnC6f6.css +0 -1
  486. package/dist/interface/assets/Metrics-l3UwykCM.js +0 -12
  487. package/dist/interface/assets/Plugin-Ldj3HygQ.js +0 -1
  488. package/dist/interface/assets/PluginDetail-CnfaI1vh.js +0 -2
  489. package/dist/interface/assets/PluginSearch-BiXG3Xk2.js +0 -2
  490. package/dist/interface/assets/PluginSearch-BuE7we1T.js +0 -1
  491. package/dist/interface/assets/Plugins-Csx6AXaW.js +0 -1
  492. package/dist/interface/assets/Recordings-D0KTY5cI.js +0 -1
  493. package/dist/interface/assets/SensorEdit-zs-f_o1N.js +0 -1
  494. package/dist/interface/assets/Sensors-BLAoalEt.js +0 -2
  495. package/dist/interface/assets/SettingsAccount-BsN7jGmo.js +0 -1
  496. package/dist/interface/assets/SettingsAccount-DuVyCSE-.js +0 -1
  497. package/dist/interface/assets/SettingsAppearance-DQcGbYbV.js +0 -1
  498. package/dist/interface/assets/SettingsAssistant-DViJklFd.js +0 -1
  499. package/dist/interface/assets/SettingsMqtt-JoszJJgV.js +0 -1
  500. package/dist/interface/assets/SettingsNotifications-3veSrxa_.js +0 -1
  501. package/dist/interface/assets/SettingsRemote-CtP6Gz9C.css +0 -1
  502. package/dist/interface/assets/SettingsRemote-DUyl8k7I.js +0 -2
  503. package/dist/interface/assets/Terminal-hln2UuSR.js +0 -4
  504. package/dist/interface/assets/Training-D6lhvUf-.js +0 -1
  505. package/dist/interface/assets/Updates-BwSWt9w7.js +0 -2
  506. package/dist/interface/assets/Workers-B6b15izn.js +0 -2
  507. package/dist/interface/assets/ace-DzzM-RlW.js +0 -1
  508. package/dist/interface/assets/api-C9mnOxie.js +0 -4
  509. package/dist/interface/assets/api-Cj9a6qPu.css +0 -2
  510. package/dist/interface/assets/cameraSources-DmVZWs4-.js +0 -1
  511. package/dist/interface/assets/cloudHandoff-Ba98bzeq.js +0 -1
  512. package/dist/interface/assets/esm-Bn9gXwX4.js +0 -1
  513. package/dist/interface/assets/esm-BzM6y2-F.js +0 -1
  514. package/dist/interface/assets/esm-CP3JWrtj.js +0 -1
  515. package/dist/interface/assets/esm-CjAXkqCf.js +0 -1
  516. package/dist/interface/assets/esm-Cqxk-j1S.js +0 -1
  517. package/dist/interface/assets/esm-DFHd3JNU.js +0 -1
  518. package/dist/interface/assets/esm-DfMLJtug.js +0 -1
  519. package/dist/interface/assets/esm-DhDrpq7a.js +0 -1
  520. package/dist/interface/assets/esm-DvhM-SOd.js +0 -1
  521. package/dist/interface/assets/esm-G63bqygQ.js +0 -1
  522. package/dist/interface/assets/esm-Gn-Y59hU.js +0 -1
  523. package/dist/interface/assets/esm-KJSOz2vj.js +0 -1
  524. package/dist/interface/assets/esm-Ryfc94Tm.js +0 -1
  525. package/dist/interface/assets/esm-rSfI5Poy.js +0 -1
  526. package/dist/interface/assets/eye-off-outline-DCxLRGo_.js +0 -1
  527. package/dist/interface/assets/main-C796FmqQ.js +0 -3
  528. package/dist/interface/assets/mqtt-DGBPptzB.js +0 -1
  529. package/dist/interface/assets/native-CZJE8bTs.js +0 -1
  530. package/dist/interface/assets/native-DKZwialB.js +0 -1
  531. package/dist/interface/assets/plugin-DSEMkqaK.js +0 -1
  532. package/dist/interface/assets/server-bhW2Mw4D.js +0 -1
  533. package/dist/interface/assets/types-BcAxmlqC.js +0 -1
  534. package/dist/interface/assets/ungrouped-BnQIcSQd.css +0 -1
  535. package/dist/interface/assets/ungrouped-CkIlDUwl.js +0 -1
  536. package/dist/interface/assets/updates-D3x_kPMM.js +0 -1
  537. package/dist/interface/assets/useBackupRestore-xp5KhKVn.js +0 -1
  538. package/dist/interface/assets/useKeyboardInset-C0Lp0UcX.js +0 -1
  539. package/dist/interface/assets/useUserOptions-BQdOB-Dp.js +0 -1
  540. package/dist/interface/assets/vendor-gFkr2qsZ.js +0 -23
  541. package/dist/interface/assets/vendor-leaflet-DkAk6mAj.js +0 -1
  542. package/dist/interface/assets/web-BDNQnMmA.js +0 -1
  543. package/dist/interface/assets/web-B_9Qyt8E.js +0 -1
  544. package/dist/interface/assets/web-BhJykCtq.js +0 -1
  545. package/dist/interface/assets/web-BjKL51lK-wWFeZlLg.js +0 -1
  546. package/dist/interface/assets/web-C7nJwIOa.js +0 -1
  547. package/dist/interface/assets/web-CGJsJQDb.js +0 -1
  548. package/dist/interface/assets/web-CJwASxrl.js +0 -1
  549. package/dist/interface/assets/web-CLe0L31Y.js +0 -1
  550. package/dist/interface/assets/web-DEv1hAn1.js +0 -1
  551. package/dist/interface/assets/web-DaeQvsXT.js +0 -1
  552. package/dist/interface/assets/web-H3-wNunW.js +0 -1
  553. package/dist/interface/assets/web-LCdyqJq1.js +0 -1
  554. package/dist/interface/assets/web-XZWYTK65.js +0 -1
  555. package/dist/interface/assets/web-rU5hlxxW.js +0 -1
  556. package/dist/interface/assets/workbox-window.prod.es5-BEYAF-e-.js +0 -1
  557. package/dist/interface/ha/Camera-C28q_3pu.js +0 -657
  558. package/dist/interface/ha/Training-OB2KOQ7L.js +0 -1694
  559. package/dist/interface/ha/Workers-cJMI4mYX.js +0 -765
  560. package/dist/interface/ha/eye-off-outline-ACbzsGuK.js +0 -19
@@ -0,0 +1,1699 @@
1
+ import { m as e } from "./ripple-ZDATPc2w.js";
2
+ import { D as t, G as n, H as r, I as i, Jt as a, St as o, Tt as s, Wt as c, Y as l, _t as u, d, f, ft as p, gt as m, kt as h, l as g, lt as _, ot as ee, p as v, qt as y, r as b, rt as x, u as S, ut as te, v as C, wt as w, x as T, xt as E, y as D, yt as O } from "./runtime-core.esm-bundler-_TfE0DWz.js";
3
+ import { t as ne } from "./tooltip-BDrlgLof.js";
4
+ import { t as re } from "./chevron-down-BNj8w2js.js";
5
+ import { t as ie } from "./tag-mchuCAPR.js";
6
+ import { Ar as ae, B as oe, Dn as k, Dr as se, Dt as ce, Hi as le, Jt as ue, L as A, Mr as de, Or as j, Ot as fe, R as pe, Si as me, Ti as M, U as N, c as he, d as ge, dr as _e, et as P, fa as ve, gt as F, hn as ye, kr as be, kt as xe, m as I, mi as L, q as R, st as Se, ta as z, ti as Ce, ur as we, wi as Te, z as Ee } from "./api-DUqpDJ2N.js";
7
+ import { C as De, M as B, S as Oe, _ as ke, b as Ae, i as je, w as Me } from "./intercomService-B7HkLs6z.js";
8
+ import { n as Ne } from "./vue-i18n-D5EAy78K.js";
9
+ import { t as Pe } from "./button-BouAFgf5.js";
10
+ import { n as Fe, t as V } from "./inputicon-1w06U-Jl.js";
11
+ import { t as Ie } from "./inputtext-C_ygnPrC.js";
12
+ import { t as Le } from "./checkbox-CAKzZcqk.js";
13
+ import { t as H } from "./close-CxFbonhd.js";
14
+ import { t as Re } from "./progressbar-CaUaM8Bt.js";
15
+ import { t as ze } from "./information-outline-DSSRyysT.js";
16
+ import { t as Be } from "./search-BViwEHdF.js";
17
+ import { n as Ve, t as He } from "./cloud-check-aaxn1VZr.js";
18
+ import { u as Ue } from "./cards-DWhezIPP.js";
19
+ import { t as We } from "./trash-can-outline-CBwv40Ck.js";
20
+ import { t as Ge } from "./back-filled-CaxrZv0Q.js";
21
+ import { t as Ke } from "./help-circle-outline-BniRuJRv.js";
22
+ import { t as qe } from "./settings-lWJfHaif.js";
23
+ //#region ~icons/mdi/cloud-check-outline
24
+ var Je = {
25
+ viewBox: "0 0 24 24",
26
+ width: "1.2em",
27
+ height: "1.2em"
28
+ };
29
+ function Ye(e, t) {
30
+ return r(), v("svg", Je, [...t[0] ||= [S("path", {
31
+ fill: "currentColor",
32
+ d: "M13 19c0 .34.04.67.09 1H6.5c-1.5 0-2.81-.5-3.89-1.57C1.54 17.38 1 16.09 1 14.58q0-1.95 1.17-3.48C3.34 9.57 4 9.43 5.25 9.15c.42-1.53 1.25-2.77 2.5-3.72S10.42 4 12 4c1.95 0 3.6.68 4.96 2.04S19 9.05 19 11c1.15.13 2.1.63 2.86 1.5c.51.57.84 1.21 1 1.92A5.9 5.9 0 0 0 19 13h-2v-2c0-1.38-.5-2.56-1.46-3.54C14.56 6.5 13.38 6 12 6s-2.56.5-3.54 1.46C7.5 8.44 7 9.62 7 11h-.5c-.97 0-1.79.34-2.47 1.03c-.69.68-1.03 1.5-1.03 2.47s.34 1.79 1.03 2.5c.68.66 1.5 1 2.47 1h6.59c-.05.33-.09.66-.09 1m4.75.43l-1.59-1.59L15 19l2.75 3l4.75-4.75l-1.16-1.41z"
33
+ }, null, -1)]]);
34
+ }
35
+ var Xe = u({
36
+ name: "mdi-cloud-check-outline",
37
+ render: Ye
38
+ }), U = {
39
+ viewBox: "0 0 24 24",
40
+ width: "1.2em",
41
+ height: "1.2em"
42
+ };
43
+ function W(e, t) {
44
+ return r(), v("svg", U, [...t[0] ||= [S("path", {
45
+ fill: "currentColor",
46
+ d: "M6 13h12v-2H6M3 6v2h18V6M10 18h4v-2h-4z"
47
+ }, null, -1)]]);
48
+ }
49
+ var Ze = u({
50
+ name: "mdi-filter-variant",
51
+ render: W
52
+ }), Qe = {
53
+ viewBox: "0 0 24 24",
54
+ width: "1.2em",
55
+ height: "1.2em"
56
+ };
57
+ function $e(e, t) {
58
+ return r(), v("svg", Qe, [...t[0] ||= [S("path", {
59
+ fill: "currentColor",
60
+ d: "M6.5 20q-2.28 0-3.89-1.57Q1 16.85 1 14.58q0-1.95 1.17-3.48q1.18-1.53 3.08-1.95q.63-2.3 2.5-3.72Q9.63 4 12 4q2.93 0 4.96 2.04Q19 8.07 19 11q1.73.2 2.86 1.5q1.14 1.28 1.14 3q0 1.88-1.31 3.19T18.5 20H13q-.82 0-1.41-.59Q11 18.83 11 18v-5.15L9.4 14.4L8 13l4-4l4 4l-1.4 1.4l-1.6-1.55V18h5.5q1.05 0 1.77-.73q.73-.72.73-1.77t-.73-1.77Q19.55 13 18.5 13H17v-2q0-2.07-1.46-3.54Q14.08 6 12 6Q9.93 6 8.46 7.46Q7 8.93 7 11h-.5q-1.45 0-2.47 1.03Q3 13.05 3 14.5T4.03 17q1.02 1 2.47 1H9v2m3-7"
61
+ }, null, -1)]]);
62
+ }
63
+ var et = u({
64
+ name: "mdi-cloud-upload-outline",
65
+ render: $e
66
+ }), tt = 200;
67
+ async function nt(e = {}, { signal: t } = {}) {
68
+ return (await z.get("/training/candidates", {
69
+ params: e,
70
+ signal: t
71
+ })).data;
72
+ }
73
+ async function rt(e, t) {
74
+ return (await z.patch(`/training/candidates/${e}`, t)).data;
75
+ }
76
+ async function G(e) {
77
+ await z.delete(`/training/candidates/${e}`);
78
+ }
79
+ async function K(e) {
80
+ let t = 0;
81
+ for (let n = 0; n < e.length; n += tt) {
82
+ let r = await z.post("/training/candidates/submit", { ids: e.slice(n, n + tt) });
83
+ t += r.data.queued;
84
+ }
85
+ return { queued: t };
86
+ }
87
+ async function it({ cursor: e, signal: t } = {}) {
88
+ return (await z.get("/training/submissions", {
89
+ params: e ? { cursor: e } : void 0,
90
+ signal: t
91
+ })).data;
92
+ }
93
+ async function at(e) {
94
+ await z.delete(`/training/submissions/${e}`);
95
+ }
96
+ async function q({ signal: e } = {}) {
97
+ return (await z.get("/training/settings", { signal: e })).data;
98
+ }
99
+ async function ot(e) {
100
+ return (await z.patch("/training/settings", e)).data;
101
+ }
102
+ var st = class {
103
+ queryClient = le();
104
+ getCandidatesQuery() {
105
+ return me({
106
+ queryKey: ["training-candidates"],
107
+ queryFn: ({ signal: e }) => nt({}, { signal: e }),
108
+ staleTime: 5e3
109
+ });
110
+ }
111
+ getSettingsQuery() {
112
+ return me({
113
+ queryKey: ["training-settings"],
114
+ queryFn: ({ signal: e }) => q({ signal: e }),
115
+ staleTime: 3e4
116
+ });
117
+ }
118
+ patchCandidateMutation() {
119
+ return M({
120
+ mutationFn: ({ id: e, patch: t }) => rt(e, t),
121
+ onSuccess: async () => {
122
+ await this.queryClient.refetchQueries({
123
+ queryKey: ["training-candidates"],
124
+ exact: !0
125
+ });
126
+ }
127
+ });
128
+ }
129
+ deleteCandidateMutation() {
130
+ return M({
131
+ mutationFn: G,
132
+ onSuccess: async () => {
133
+ await this.queryClient.refetchQueries({
134
+ queryKey: ["training-candidates"],
135
+ exact: !0
136
+ });
137
+ }
138
+ });
139
+ }
140
+ deleteSubmissionMutation() {
141
+ return M({ mutationFn: at });
142
+ }
143
+ submitCandidatesMutation() {
144
+ return M({
145
+ mutationFn: K,
146
+ onSuccess: async () => {
147
+ await this.queryClient.refetchQueries({
148
+ queryKey: ["training-candidates"],
149
+ exact: !0
150
+ });
151
+ }
152
+ });
153
+ }
154
+ patchSettingsMutation() {
155
+ return M({
156
+ mutationFn: ot,
157
+ onSuccess: async () => {
158
+ await this.queryClient.refetchQueries({
159
+ queryKey: ["training-settings"],
160
+ exact: !0
161
+ });
162
+ }
163
+ });
164
+ }
165
+ }, ct = {
166
+ viewBox: "0 0 24 24",
167
+ width: "1.2em",
168
+ height: "1.2em"
169
+ };
170
+ function J(e, t) {
171
+ return r(), v("svg", ct, [...t[0] ||= [S("path", {
172
+ fill: "currentColor",
173
+ d: "M17 14h2v3h3v2h-3v3h-2v-3h-3v-2h3zm-6 2L2 9l9-7l9 7zm0 2.54l1-.79V18c0 .71.12 1.39.35 2L11 21.07l-9-7l1.62-1.26z"
174
+ }, null, -1)]]);
175
+ }
176
+ var lt = u({
177
+ name: "mdi-layers-plus",
178
+ render: J
179
+ }), ut = [
180
+ "person",
181
+ "vehicle",
182
+ "animal",
183
+ "package",
184
+ "face",
185
+ "license_plate"
186
+ ], Y = { desktop: {
187
+ maxWidth: "1280px",
188
+ width: "85vw"
189
+ } }, X = O({ progress: null }), dt = null, ft = null, Z = /* @__PURE__ */ new Set(), Q = /* @__PURE__ */ new Set();
190
+ function pt(e, t) {
191
+ for (let n of e) try {
192
+ n(t);
193
+ } catch {}
194
+ }
195
+ async function mt() {
196
+ if (ft?.ready.value) try {
197
+ let e = await ft.request("get-submit-progress");
198
+ e.active ? X.progress = e : X.progress?.active && (X.progress = null);
199
+ } catch {}
200
+ }
201
+ function ht() {
202
+ mt(), pt(Z, {}), pt(Q, void 0);
203
+ }
204
+ function gt() {
205
+ return ft || (dt = p(!0), dt.run(() => {
206
+ let e = L("/training");
207
+ ft = e, e.on("candidates-changed", (e) => pt(Z, e ?? {})), e.on("submit-progress", (e) => {
208
+ X.progress = e, pt(Z, {});
209
+ }), e.onReady(ht);
210
+ }), ft);
211
+ }
212
+ function _t() {
213
+ function e() {
214
+ gt();
215
+ }
216
+ function t(e) {
217
+ return Z.add(e), () => Z.delete(e);
218
+ }
219
+ function n(e) {
220
+ return Q.add(e), () => Q.delete(e);
221
+ }
222
+ function r() {
223
+ X.progress = null;
224
+ }
225
+ return {
226
+ submitProgress: g(() => X.progress),
227
+ connect: e,
228
+ onCandidatesChanged: t,
229
+ onResync: n,
230
+ dismissProgress: r
231
+ };
232
+ }
233
+ //#endregion
234
+ //#region src/components/CuiDialog/templates/TrainingBoxEditor/TrainingBoxEditor.vue?vue&type=script&setup=true&lang.ts
235
+ var vt = { class: "flex items-center justify-between gap-2 text-sm" }, yt = { class: "min-w-0 flex items-center gap-2" }, bt = { class: "font-medium truncate" }, xt = { class: "text-muted shrink-0" }, St = { class: "flex items-center gap-1.5 shrink-0" }, Ct = { class: "text-muted tabular-nums" }, wt = ["data-stage-zoom"], Tt = ["src"], Et = [
236
+ "x",
237
+ "y",
238
+ "width",
239
+ "height",
240
+ "stroke",
241
+ "fill",
242
+ "fill-opacity",
243
+ "stroke-width",
244
+ "onPointerdown"
245
+ ], Dt = ["onPointerdown"], Ot = ["cx", "cy"], kt = [
246
+ "cx",
247
+ "cy",
248
+ "fill"
249
+ ], At = [
250
+ "x",
251
+ "y",
252
+ "width",
253
+ "height",
254
+ "stroke"
255
+ ], jt = [
256
+ "x",
257
+ "y",
258
+ "width",
259
+ "height",
260
+ "stroke",
261
+ "fill"
262
+ ], Mt = ["onClick"], Nt = ["data-box-label", "onPointerdown"], Pt = { class: "bbox-label-text" }, Ft = {
263
+ key: 0,
264
+ class: "bbox-label-confidence"
265
+ }, It = {
266
+ key: 1,
267
+ class: "bbox-label-confidence"
268
+ }, Lt = ["src"], Rt = { class: "absolute inset-0 w-full h-full" }, zt = [
269
+ "x",
270
+ "y",
271
+ "width",
272
+ "height",
273
+ "stroke",
274
+ "fill"
275
+ ], Bt = [
276
+ "x",
277
+ "y",
278
+ "width",
279
+ "height",
280
+ "stroke",
281
+ "fill"
282
+ ], Vt = {
283
+ key: 2,
284
+ class: "absolute left-2 top-1/2 -translate-y-1/2 z-[5] dark-mode"
285
+ }, Ht = {
286
+ key: 3,
287
+ class: "absolute right-2 top-1/2 -translate-y-1/2 z-[5] dark-mode"
288
+ }, Ut = {
289
+ key: 0,
290
+ class: "flex items-center justify-center gap-2"
291
+ }, Wt = {
292
+ class: "text-muted text-sm",
293
+ for: "plate-text"
294
+ }, Gt = { class: "flex flex-col items-center gap-0.5" }, Kt = { class: "flex items-center justify-center gap-1.5" }, qt = { class: "text-muted text-sm text-center" }, Jt = { class: "text-muted text-sm text-center" }, Yt = {
295
+ key: 1,
296
+ class: "grid grid-cols-[auto_1fr] gap-x-3 gap-y-1 justify-center mx-auto text-sm text-muted"
297
+ }, Xt = .01, Zt = 4, Qt = 10, $t = 26, en = 60, tn = 400, nn = 110, rn = 2, an = 80, on = 50, sn = .003, cn = .5, ln = /*#__PURE__*/ j(/* @__PURE__ */ T({
298
+ __name: "TrainingBoxEditor",
299
+ props: {
300
+ candidates: {},
301
+ startId: {},
302
+ cameraName: { type: Function },
303
+ imageUrl: { type: Function },
304
+ onSave: { type: Function },
305
+ onDelete: { type: Function }
306
+ },
307
+ setup(u, { expose: p }) {
308
+ let T = u, re = t("dialogRef"), { t: ae, te: oe } = Ne(), se = Te(), ce = _t(), le = [
309
+ "nw",
310
+ "ne",
311
+ "sw",
312
+ "se"
313
+ ], ue = /* @__PURE__ */ new Map(), A = O(/* @__PURE__ */ new Set()), de = O(/* @__PURE__ */ new Set()), j = o(/* @__PURE__ */ new Map()), fe = 0, pe = Math.max(0, T.candidates.findIndex((e) => e.id === T.startId)), me = I(), M = x("rootRef"), N = x("labelMenuRef"), ge = x("stageRef"), P = x("frameRef"), ve = x("svgRef"), F = E(T.candidates[pe]?.boxes.map((e) => ({ ...e })) ?? []), be = E({
314
+ w: 16,
315
+ h: 9
316
+ }), L = E(null), R = E(null), z = E(-1), Ce = E(!1), Ee = E(!1), De = Me("(any-pointer: fine)"), B = E(null), Oe = null, je = E(-1), Fe = E("person"), V = E(pe), Le = w([]), H = E(!1), { zoom: Re, pan: ze, constraining: Be, minimapStyle: Ve, minimapBoxStyle: He, onZoomPan: Ge, onDoubleClick: qe, onTouchStart: Je, onTouchEnd: Ye, reset: Xe } = Se(ge, P), { height: U } = ke(P), W = g(() => T.candidates[V.value]), Ze = g(() => T.candidates.slice(0, V.value + 1).filter((e) => !A.has(e.id)).length), Qe = g(() => T.candidates.filter((e) => !A.has(e.id)).length), $e = g(() => T.candidates.slice(0, V.value).some((e) => !A.has(e.id))), et = g(() => T.candidates.slice(V.value + 1).some((e) => !A.has(e.id))), tt = g(() => de.has(W.value.id) ? "verified" : W.value.status), nt = g(() => F.value.map((e, t) => ({
317
+ box: e,
318
+ i: t
319
+ })).sort((e, t) => st(e) - st(t))), rt = g(() => new Map(nt.value.map(({ i: e }, t) => [e, t + 1]))), G = g(() => F.value[z.value]), K = g(() => {
320
+ let e = F.value[z.value];
321
+ return e?.label === "license_plate" ? e : null;
322
+ }), it = g(() => H.value ? Le.value.filter((e) => !F.value.some((t) => Z(t, e) >= cn)) : []), at = g(() => [...ut.map((e) => ({
323
+ key: e,
324
+ label: ct(e),
325
+ icon: ye(e).icon,
326
+ iconProps: { style: { color: ye(e).color } },
327
+ active: F.value[je.value]?.label === e,
328
+ onClick: () => Cn(e)
329
+ })), {
330
+ key: "remove",
331
+ label: ae("components.training_editor.remove_box"),
332
+ icon: We,
333
+ iconProps: { class: "text-red-500" },
334
+ labelProps: { class: "text-red-500" },
335
+ onClick: () => Tn(je.value)
336
+ }]), q = g(() => (e) => {
337
+ let t = U.value || 360;
338
+ return e.y * t >= $t ? "above" : t - (e.y + e.height) * t >= $t ? "below" : "inside";
339
+ }), ot = g(() => (e) => e.x > .7);
340
+ function st({ box: e, i: t }) {
341
+ return t === z.value ? 2 ** 53 - 1 : j.get(s(e)) ?? t;
342
+ }
343
+ function ct(e) {
344
+ let t = `components.training_editor.labels.${e}`;
345
+ return oe(t) ? ae(t) : e;
346
+ }
347
+ function J(e) {
348
+ return ye(e);
349
+ }
350
+ function Y(e) {
351
+ return `${e * 100}%`;
352
+ }
353
+ function X(e, t) {
354
+ return Y(t === "nw" || t === "sw" ? e.x : e.x + e.width);
355
+ }
356
+ function dt(e, t) {
357
+ return Y(t === "nw" || t === "ne" ? e.y : e.y + e.height);
358
+ }
359
+ function ft(e) {
360
+ let t = { backgroundColor: J(e.label).color };
361
+ ot.value(e) ? t.right = Y(1 - e.x - e.width) : t.left = Y(e.x);
362
+ let n = q.value(e);
363
+ return t.top = n === "above" ? Y(e.y) : n === "below" ? Y(e.y + e.height) : `calc(${Y(e.y)} + 2px)`, t;
364
+ }
365
+ function Z(e, t) {
366
+ let n = Math.min(e.x + e.width, t.x + t.width) - Math.max(e.x, t.x), r = Math.min(e.y + e.height, t.y + t.height) - Math.max(e.y, t.y);
367
+ if (n <= 0 || r <= 0) return 0;
368
+ let i = n * r;
369
+ return i / (e.width * e.height + t.width * t.height - i);
370
+ }
371
+ function Q(e) {
372
+ return {
373
+ left: Y(e.x + e.width),
374
+ top: Y(e.y + e.height),
375
+ borderColor: J(e.label).color
376
+ };
377
+ }
378
+ function pt(e) {
379
+ F.value.push({
380
+ ...e,
381
+ confidence: 1
382
+ }), z.value = F.value.length - 1;
383
+ }
384
+ function mt() {
385
+ for (let e of it.value) F.value.push({
386
+ ...e,
387
+ confidence: 1
388
+ });
389
+ }
390
+ function ht(e) {
391
+ let t = e.target;
392
+ t.naturalWidth && t.naturalHeight && (be.value = {
393
+ w: t.naturalWidth,
394
+ h: t.naturalHeight
395
+ });
396
+ }
397
+ function gt(e) {
398
+ let t = ve.value?.getBoundingClientRect();
399
+ return !t || t.width === 0 || t.height === 0 ? {
400
+ x: 0,
401
+ y: 0
402
+ } : {
403
+ x: Math.min(1, Math.max(0, (e.clientX - t.left) / t.width)),
404
+ y: Math.min(1, Math.max(0, (e.clientY - t.top) / t.height))
405
+ };
406
+ }
407
+ function ln(e, t) {
408
+ L.value = {
409
+ ...t,
410
+ clientX: e.clientX,
411
+ clientY: e.clientY,
412
+ moved: !1
413
+ }, ve.value?.setPointerCapture(e.pointerId);
414
+ }
415
+ function un(e) {
416
+ if (N.value?.hide(), Re.value > 1 || !e.isPrimary) return;
417
+ let { x: t, y: n } = gt(e);
418
+ ln(e, {
419
+ mode: "draw",
420
+ index: -1,
421
+ startX: t,
422
+ startY: n,
423
+ origin: {
424
+ label: Fe.value,
425
+ confidence: 1,
426
+ x: t,
427
+ y: n,
428
+ width: 0,
429
+ height: 0
430
+ }
431
+ });
432
+ }
433
+ function dn(e, t) {
434
+ if (!t.isPrimary) return;
435
+ let { x: n, y: r } = gt(t);
436
+ z.value = e, ln(t, {
437
+ mode: "move",
438
+ index: e,
439
+ startX: n,
440
+ startY: r,
441
+ origin: { ...F.value[e] }
442
+ });
443
+ }
444
+ function fn(e, t, n) {
445
+ if (!n.isPrimary) return;
446
+ N.value?.hide();
447
+ let { x: r, y: i } = gt(n);
448
+ z.value = e, ln(n, {
449
+ mode: "resize",
450
+ index: e,
451
+ corner: t,
452
+ startX: r,
453
+ startY: i,
454
+ origin: { ...F.value[e] }
455
+ });
456
+ }
457
+ function pn(e) {
458
+ e.touches.length > 1 && L.value && (L.value = null, R.value = null, B.value = null), Je(e);
459
+ }
460
+ function mn(e) {
461
+ let t = L.value;
462
+ if (!t) return;
463
+ let { x: n, y: r } = gt(e), i = e.pointerType === "touch" ? Qt : Zt;
464
+ if (Math.hypot(e.clientX - t.clientX, e.clientY - t.clientY) > i && (t.moved = !0), e.pointerType === "touch" && t.moved && (gn(t) ? _n(e) : B.value = null), t.mode === "draw") {
465
+ if (t.moved) {
466
+ let e = xn(t.startX, t.startY, n, r);
467
+ R.value = e.width >= Xt && e.height >= Xt ? {
468
+ label: Fe.value,
469
+ confidence: 1,
470
+ ...e
471
+ } : null;
472
+ }
473
+ return;
474
+ }
475
+ if (t.mode === "move") {
476
+ if (!t.moved) return;
477
+ let e = F.value[t.index];
478
+ e.x = Math.min(1 - t.origin.width, Math.max(0, t.origin.x + (n - t.startX))), e.y = Math.min(1 - t.origin.height, Math.max(0, t.origin.y + (r - t.startY)));
479
+ return;
480
+ }
481
+ let a = t.corner === "nw" || t.corner === "sw" ? t.origin.x + t.origin.width : t.origin.x, o = t.corner === "nw" || t.corner === "ne" ? t.origin.y + t.origin.height : t.origin.y;
482
+ Object.assign(F.value[t.index], xn(a, o, n, r));
483
+ }
484
+ function hn(e) {
485
+ let t = L.value;
486
+ if (L.value = null, B.value = null, t) {
487
+ if (t.mode === "draw") {
488
+ R.value && R.value.width >= Xt && R.value.height >= Xt ? (F.value.push({ ...R.value }), z.value = F.value.length - 1) : t.moved || (z.value = -1), R.value = null;
489
+ return;
490
+ }
491
+ t.mode === "move" && !t.moved && Sn(t.index, e);
492
+ }
493
+ }
494
+ function gn(e) {
495
+ let t = ve.value?.getBoundingClientRect();
496
+ if (!t || t.width === 0) return !1;
497
+ let n = e.mode === "draw" ? R.value : F.value[e.index];
498
+ return !n || Math.max(n.width * t.width, n.height * t.height) <= on;
499
+ }
500
+ function _n(e) {
501
+ let t = P.value?.getBoundingClientRect(), n = ge.value?.getBoundingClientRect();
502
+ if (!t || !n || t.width === 0 || t.height === 0) {
503
+ B.value = null;
504
+ return;
505
+ }
506
+ let r = nn / 2, i = Math.min(Math.max(e.clientX - n.left, 59), n.width - r - 4), a = e.clientY - n.top - an;
507
+ a - r < 4 && (a = e.clientY - n.top + an), B.value = {
508
+ x: i,
509
+ y: a,
510
+ frameW: t.width,
511
+ frameH: t.height,
512
+ tx: r - (e.clientX - t.left) * rn,
513
+ ty: r - (e.clientY - t.top) * rn
514
+ };
515
+ }
516
+ function vn(e) {
517
+ let t = e instanceof HTMLElement || e instanceof SVGElement ? e : null;
518
+ if (!t || ge.value?.contains(t) || t.closest(".p-dialog-header") || t.closest("button")) return !1;
519
+ let n = M.value?.closest(".p-dialog-content")?.lastElementChild;
520
+ return !(n && n !== M.value && n.contains(t));
521
+ }
522
+ function yn(e) {
523
+ if (Oe = null, e.touches.length !== 1 || !vn(e.target)) return;
524
+ let t = e.touches[0];
525
+ Oe = {
526
+ x: t.clientX,
527
+ y: t.clientY,
528
+ at: Date.now()
529
+ };
530
+ }
531
+ function bn(e) {
532
+ let t = Oe;
533
+ if (Oe = null, !t || e.changedTouches.length !== 1) return;
534
+ let n = e.changedTouches[0], r = n.clientX - t.x, i = n.clientY - t.y;
535
+ Date.now() - t.at <= tn && Math.abs(r) >= en && Math.abs(r) > 2 * Math.abs(i) && $(r < 0 ? 1 : -1);
536
+ }
537
+ function xn(e, t, n, r) {
538
+ return {
539
+ x: Math.min(e, n),
540
+ y: Math.min(t, r),
541
+ width: Math.abs(n - e),
542
+ height: Math.abs(r - t)
543
+ };
544
+ }
545
+ function Sn(e, t) {
546
+ je.value = e;
547
+ let n = P.value?.querySelector(`[data-box-label="${e}"]`), r = { currentTarget: P.value ?? t.currentTarget };
548
+ N.value?.toggleMenu(r, n ?? void 0);
549
+ }
550
+ function Cn(e) {
551
+ let t = F.value[je.value];
552
+ t && (t.label = e, t.confidence = 1, Fe.value = e);
553
+ }
554
+ function wn(e) {
555
+ let t = F.value[z.value];
556
+ t && (t.text = (e ?? "").toUpperCase().replace(/[^A-Z0-9ÄÖÜ\- ]/g, "") || void 0);
557
+ }
558
+ function Tn(e) {
559
+ e < 0 || e >= F.value.length || (F.value.splice(e, 1), z.value = -1, je.value = -1, N.value?.hide());
560
+ }
561
+ function En(e, t = !0) {
562
+ e < 0 || e >= T.candidates.length || (t && ue.set(W.value.id, F.value.map((e) => ({ ...e }))), Le.value = F.value.map((e) => ({ ...e })), V.value = e, F.value = (ue.get(W.value.id) ?? W.value.boxes).map((e) => ({ ...e })), R.value = null, L.value = null, B.value = null, z.value = -1, je.value = -1, j.clear(), N.value?.hide(), Xe());
563
+ }
564
+ async function Dn(e) {
565
+ return await T.onSave(W.value.id, F.value.map((e) => ({ ...e })), e), ue.set(W.value.id, F.value.map((e) => ({ ...e }))), e === "verified" && de.add(W.value.id), $(1, !1) ? null : void 0;
566
+ }
567
+ function $(e, t = !0) {
568
+ let n = V.value + e;
569
+ for (; n >= 0 && n < T.candidates.length && A.has(T.candidates[n].id);) n += e;
570
+ return n < 0 || n >= T.candidates.length ? !1 : (En(n, t), !0);
571
+ }
572
+ async function On() {
573
+ let e = W.value.id;
574
+ A.add(e);
575
+ try {
576
+ await T.onDelete(e);
577
+ } catch (t) {
578
+ throw A.delete(e), t;
579
+ }
580
+ return ue.delete(e), $(1, !1) || $(-1, !1) ? null : void 0;
581
+ }
582
+ function kn(e) {
583
+ let t = !1;
584
+ for (let n of e) !A.has(n) && T.candidates.some((e) => e.id === n) && (A.add(n), ue.delete(n), n === W.value.id && (t = !0));
585
+ t && (se.add({
586
+ severity: "warn",
587
+ detail: ae("components.training_editor.removed_meanwhile"),
588
+ life: 4e3
589
+ }), !$(1, !1) && !$(-1, !1) && re.value.close({ status: "cancel" }));
590
+ }
591
+ function An() {
592
+ for (let e of [1, -1]) {
593
+ let t = V.value + e;
594
+ for (; t >= 0 && t < T.candidates.length && A.has(T.candidates[t].id);) t += e;
595
+ let n = T.candidates[t];
596
+ n && (new Image().src = T.imageUrl(n.id));
597
+ }
598
+ }
599
+ function jn(e) {
600
+ F.value.length && (z.value = (z.value + e + F.value.length) % F.value.length);
601
+ }
602
+ function Mn(e) {
603
+ let t = F.value[z.value];
604
+ if (!t) return;
605
+ let n = ut, r = n[(n.indexOf(t.label) + e + n.length) % n.length];
606
+ t.label = r, t.confidence = 1, Fe.value = r;
607
+ }
608
+ function Nn(e, t, n) {
609
+ let r = F.value[z.value];
610
+ r && (n ? (r.width = Math.min(1 - r.x, Math.max(Xt, r.width + e)), r.height = Math.min(1 - r.y, Math.max(Xt, r.height + t))) : (r.x = Math.min(1 - r.width, Math.max(0, r.x + e)), r.y = Math.min(1 - r.height, Math.max(0, r.y + t))));
611
+ }
612
+ async function Pn() {
613
+ if (!Ee.value) {
614
+ Ee.value = !0;
615
+ try {
616
+ let e = await Dn("verified");
617
+ e !== null && re.value.close({
618
+ status: "confirm",
619
+ data: e
620
+ });
621
+ } finally {
622
+ Ee.value = !1;
623
+ }
624
+ }
625
+ }
626
+ ee(V, An, { immediate: !0 }), ee(G, (e, t) => {
627
+ t && t !== e && F.value.includes(t) && j.set(s(t), --fe);
628
+ }), Ae(window, "keydown", (e) => {
629
+ if (e.target?.closest?.("input, textarea")) return;
630
+ let t = {
631
+ ArrowLeft: [-.003, 0],
632
+ ArrowRight: [sn, 0],
633
+ ArrowUp: [0, -.003],
634
+ ArrowDown: [0, sn]
635
+ };
636
+ if (t[e.key]) {
637
+ if (z.value >= 0) {
638
+ e.preventDefault();
639
+ let [n, r] = t[e.key];
640
+ Nn(n, r, e.shiftKey);
641
+ } else !e.repeat && e.key === "ArrowLeft" ? $(-1) : !e.repeat && e.key === "ArrowRight" && $(1);
642
+ return;
643
+ }
644
+ e.repeat || (e.key === "Tab" ? (e.preventDefault(), jn(e.shiftKey ? -1 : 1)) : e.key === "Escape" ? (z.value = -1, N.value?.hide()) : (e.key === "Delete" || e.key === "Backspace") && z.value >= 0 ? Tn(z.value) : e.key === "v" || e.key === "V" ? e.shiftKey ? mt() : Le.value.length > 0 && (H.value = !H.value) : e.key === "s" || e.key === "S" ? Mn(e.shiftKey ? -1 : 1) : e.key === " " && !N.value?.isOpen && (e.preventDefault(), Pn()));
645
+ }), Ae(() => M.value?.closest(".p-dialog-content") ?? void 0, "touchstart", yn, { passive: !0 }), Ae(() => M.value?.closest(".p-dialog-content") ?? void 0, "touchend", bn, { passive: !0 }), ce.connect();
646
+ let Fn = ce.onCandidatesChanged((e) => {
647
+ e.removed?.length && kn(e.removed);
648
+ });
649
+ return i(() => {
650
+ Fn();
651
+ }), p({
652
+ isLoading: Ee,
653
+ onConfirm: () => Dn("verified"),
654
+ onCancel: () => On()
655
+ }), (t, i) => {
656
+ let o = ie, s = lt, p = Pe, g = Ue, ee = we, x = _e, w = Ie, T = Ke, E = ne;
657
+ return r(), v("div", {
658
+ ref_key: "rootRef",
659
+ ref: M,
660
+ class: "flex flex-col gap-3 h-full min-h-0"
661
+ }, [
662
+ S("div", vt, [S("div", yt, [
663
+ D(o, {
664
+ severity: h(tt) === "verified" ? "success" : "info",
665
+ value: t.$t(`views.training.status_${h(tt)}`),
666
+ class: "shrink-0"
667
+ }, null, 8, ["severity", "value"]),
668
+ S("span", bt, a(u.cameraName(h(W).cameraId)), 1),
669
+ S("span", xt, a(h(he)(h(W).createdAt)), 1)
670
+ ]), S("div", St, [h(Le).length > 0 ? te((r(), d(p, {
671
+ key: 0,
672
+ severity: h(H) ? "primary" : "secondary",
673
+ text: "",
674
+ rounded: "",
675
+ class: "cui-icon-sm",
676
+ onClick: i[0] ||= (e) => H.value = !h(H)
677
+ }, {
678
+ icon: _(() => [D(s, { class: "w-4 h-4" })]),
679
+ _: 1
680
+ }, 8, ["severity"])), [[
681
+ E,
682
+ t.$t("components.training_editor.ghosts_toggle"),
683
+ void 0,
684
+ { bottom: !0 }
685
+ ]]) : f("", !0), S("span", Ct, a(h(Ze)) + " / " + a(h(Qe)), 1)])]),
686
+ S("div", {
687
+ ref_key: "stageRef",
688
+ ref: ge,
689
+ class: "stage relative w-full bg-black rounded-lg shrink-0 overflow-hidden select-none"
690
+ }, [
691
+ D(h(xe), {
692
+ pan: h(ze),
693
+ "onUpdate:pan": i[10] ||= (e) => m(ze) ? ze.value = e : null,
694
+ zoom: h(Re),
695
+ "onUpdate:zoom": i[11] ||= (e) => m(Re) ? Re.value = e : null,
696
+ "pan-enabled": h(Re) > 1 && !h(L),
697
+ "enable-control-button": !1,
698
+ "dbl-click-enabled": !1,
699
+ "min-zoom": 1,
700
+ "max-zoom": h(5),
701
+ selector: `[data-stage-zoom='${h(me)}']`,
702
+ "zoom-origin": "pointer",
703
+ class: c(["absolute inset-0 flex items-center justify-center", { "zoom-constraining": h(Be) }]),
704
+ onPanned: h(Ge),
705
+ onZoom: h(Ge),
706
+ onDblclick: h(qe),
707
+ onTouchstart: pn,
708
+ onTouchend: h(Ye)
709
+ }, {
710
+ default: _(() => [S("div", {
711
+ ref_key: "frameRef",
712
+ ref: P,
713
+ "data-stage-zoom": h(me),
714
+ class: "frame relative",
715
+ style: y({
716
+ "--ar-w": h(be).w,
717
+ "--ar-h": h(be).h
718
+ })
719
+ }, [
720
+ S("img", {
721
+ src: u.imageUrl(h(W).id),
722
+ class: "absolute inset-0 w-full h-full",
723
+ draggable: "false",
724
+ onLoad: ht
725
+ }, null, 40, Tt),
726
+ (r(), v("svg", {
727
+ ref_key: "svgRef",
728
+ ref: ve,
729
+ class: c(["absolute inset-0 w-full h-full touch-none", h(Re) > 1 ? "cursor-grab" : "cursor-crosshair"]),
730
+ onPointerdown: un,
731
+ onPointermove: mn,
732
+ onPointerup: hn,
733
+ onPointercancel: hn
734
+ }, [
735
+ (r(!0), v(b, null, n(h(nt), ({ box: t, i: a }) => (r(), v("g", { key: a }, [S("rect", {
736
+ x: Y(t.x),
737
+ y: Y(t.y),
738
+ width: Y(t.width),
739
+ height: Y(t.height),
740
+ stroke: J(t.label).color,
741
+ fill: J(t.label).color,
742
+ "fill-opacity": a === h(z) ? .22 : .12,
743
+ "stroke-width": a === h(z) ? 3.5 : 2,
744
+ "vector-effect": "non-scaling-stroke",
745
+ class: "cursor-move",
746
+ onPointerdown: e((e) => dn(a, e), ["stop"]),
747
+ onTouchstart: i[1] ||= e(() => {}, ["stop"]),
748
+ onMousedown: i[2] ||= e(() => {}, ["stop"])
749
+ }, null, 40, Et), (r(), v(b, null, n(le, (n) => S("g", {
750
+ key: n,
751
+ class: "cursor-nwse-resize",
752
+ onPointerdown: e((e) => fn(a, n, e), ["stop"]),
753
+ onTouchstart: i[3] ||= e(() => {}, ["stop"]),
754
+ onMousedown: i[4] ||= e(() => {}, ["stop"])
755
+ }, [S("circle", {
756
+ cx: X(t, n),
757
+ cy: dt(t, n),
758
+ r: "14",
759
+ fill: "transparent"
760
+ }, null, 8, Ot), S("circle", {
761
+ cx: X(t, n),
762
+ cy: dt(t, n),
763
+ r: "4.5",
764
+ fill: J(t.label).color
765
+ }, null, 8, kt)], 40, Dt)), 64))]))), 128)),
766
+ (r(!0), v(b, null, n(h(it), (e, t) => (r(), v("rect", {
767
+ key: `ghost-${t}`,
768
+ x: Y(e.x),
769
+ y: Y(e.y),
770
+ width: Y(e.width),
771
+ height: Y(e.height),
772
+ stroke: J(e.label).color,
773
+ fill: "none",
774
+ "stroke-opacity": "0.75",
775
+ "stroke-dasharray": "3 5",
776
+ "stroke-width": "1.5",
777
+ "vector-effect": "non-scaling-stroke",
778
+ class: "pointer-events-none"
779
+ }, null, 8, At))), 128)),
780
+ h(R) ? (r(), v("rect", {
781
+ key: 0,
782
+ x: Y(h(R).x),
783
+ y: Y(h(R).y),
784
+ width: Y(h(R).width),
785
+ height: Y(h(R).height),
786
+ stroke: J(h(R).label).color,
787
+ fill: J(h(R).label).color,
788
+ "fill-opacity": "0.1",
789
+ "stroke-dasharray": "6 4",
790
+ "stroke-width": "2",
791
+ "vector-effect": "non-scaling-stroke"
792
+ }, null, 8, jt)) : f("", !0)
793
+ ], 34)),
794
+ (r(!0), v(b, null, n(h(it), (n, a) => te((r(), v("button", {
795
+ key: `ghost-chip-${a}`,
796
+ type: "button",
797
+ class: "ghost-chip",
798
+ style: y(Q(n)),
799
+ onPointerdown: i[5] ||= e(() => {}, ["stop"]),
800
+ onTouchstart: i[6] ||= e(() => {}, ["stop"]),
801
+ onMousedown: i[7] ||= e(() => {}, ["stop"]),
802
+ onClick: e((e) => pt(n), ["stop"])
803
+ }, [D(g, { class: "w-3.5 h-3.5 shrink-0" }), (r(), d(l(J(n.label).icon), { class: "bbox-label-icon" }))], 44, Mt)), [[
804
+ E,
805
+ t.$t("components.training_editor.ghost_take"),
806
+ void 0,
807
+ { top: !0 }
808
+ ]])), 128)),
809
+ (r(!0), v(b, null, n(h(F), (t, n) => (r(), v("div", {
810
+ key: `label-${n}`,
811
+ class: c(["bbox-label cursor-move", {
812
+ "label-bottom": h(q)(t) === "below",
813
+ "label-inside": h(q)(t) === "inside",
814
+ "label-right": h(ot)(t)
815
+ }]),
816
+ "data-box-label": n,
817
+ onPointerdown: e((e) => dn(n, e), ["stop"]),
818
+ onPointermove: mn,
819
+ onPointerup: hn,
820
+ onPointercancel: hn,
821
+ onTouchstart: i[8] ||= e(() => {}, ["stop"]),
822
+ onMousedown: i[9] ||= e(() => {}, ["stop"]),
823
+ style: y([ft(t), { zIndex: h(rt).get(n) }])
824
+ }, [
825
+ (r(), d(l(J(t.label).icon), { class: "bbox-label-icon" })),
826
+ S("span", Pt, a(ct(t.label)), 1),
827
+ t.text ? (r(), v("span", Ft, a(t.text), 1)) : t.confidence < 1 ? (r(), v("span", It, a(Math.round(t.confidence * 100)) + "%", 1)) : f("", !0)
828
+ ], 46, Nt))), 128))
829
+ ], 12, wt)]),
830
+ _: 1
831
+ }, 8, [
832
+ "pan",
833
+ "zoom",
834
+ "pan-enabled",
835
+ "max-zoom",
836
+ "selector",
837
+ "class",
838
+ "onPanned",
839
+ "onZoom",
840
+ "onDblclick",
841
+ "onTouchend"
842
+ ]),
843
+ h(Ve) ? (r(), v("div", {
844
+ key: 0,
845
+ class: "zoom-minimap",
846
+ style: y(h(He) ?? void 0)
847
+ }, [S("div", {
848
+ class: "zoom-minimap-viewport",
849
+ style: y(h(Ve))
850
+ }, null, 4)], 4)) : f("", !0),
851
+ h(B) ? (r(), v("div", {
852
+ key: 1,
853
+ class: "loupe",
854
+ style: y({
855
+ left: `${h(B).x}px`,
856
+ top: `${h(B).y}px`
857
+ })
858
+ }, [S("div", {
859
+ class: "loupe-content",
860
+ style: y({
861
+ width: `${h(B).frameW}px`,
862
+ height: `${h(B).frameH}px`,
863
+ transform: `translate(${h(B).tx}px, ${h(B).ty}px) scale(${rn})`
864
+ })
865
+ }, [S("img", {
866
+ src: u.imageUrl(h(W).id),
867
+ class: "absolute inset-0 w-full h-full",
868
+ draggable: "false"
869
+ }, null, 8, Lt), (r(), v("svg", Rt, [(r(!0), v(b, null, n(h(F), (e, t) => (r(), v("rect", {
870
+ key: t,
871
+ x: Y(e.x),
872
+ y: Y(e.y),
873
+ width: Y(e.width),
874
+ height: Y(e.height),
875
+ stroke: J(e.label).color,
876
+ fill: J(e.label).color,
877
+ "fill-opacity": "0.1",
878
+ "stroke-width": "1.5"
879
+ }, null, 8, zt))), 128)), h(R) ? (r(), v("rect", {
880
+ key: 0,
881
+ x: Y(h(R).x),
882
+ y: Y(h(R).y),
883
+ width: Y(h(R).width),
884
+ height: Y(h(R).height),
885
+ stroke: J(h(R).label).color,
886
+ fill: J(h(R).label).color,
887
+ "fill-opacity": "0.1",
888
+ "stroke-dasharray": "4 3",
889
+ "stroke-width": "1.5"
890
+ }, null, 8, Bt)) : f("", !0)]))], 4), i[15] ||= S("div", { class: "loupe-crosshair" }, null, -1)], 4)) : f("", !0),
891
+ h($e) ? (r(), v("div", Vt, [D(p, {
892
+ severity: "secondary",
893
+ rounded: "",
894
+ class: "cui-icon-md opacity-60 hover:opacity-100",
895
+ onClick: i[12] ||= e((e) => $(-1), ["stop"])
896
+ }, {
897
+ icon: _(() => [D(ee, {
898
+ width: "100%",
899
+ height: "100%"
900
+ })]),
901
+ _: 1
902
+ })])) : f("", !0),
903
+ h(et) ? (r(), v("div", Ht, [D(p, {
904
+ severity: "secondary",
905
+ rounded: "",
906
+ class: "cui-icon-md opacity-60 hover:opacity-100",
907
+ onClick: i[13] ||= e((e) => $(1), ["stop"])
908
+ }, {
909
+ icon: _(() => [D(x, {
910
+ width: "100%",
911
+ height: "100%"
912
+ })]),
913
+ _: 1
914
+ })])) : f("", !0)
915
+ ], 512),
916
+ h(K) ? (r(), v("div", Ut, [S("label", Wt, a(t.$t("components.training_editor.plate_text")), 1), D(w, {
917
+ id: "plate-text",
918
+ "model-value": h(K).text ?? "",
919
+ size: "small",
920
+ maxlength: "12",
921
+ class: "w-40 uppercase",
922
+ placeholder: "ABC 1234",
923
+ "onUpdate:modelValue": wn
924
+ }, null, 8, ["model-value"])])) : f("", !0),
925
+ S("div", Gt, [S("div", Kt, [S("span", qt, a(t.$t("components.training_editor.hint")), 1), h(De) ? (r(), d(p, {
926
+ key: 0,
927
+ severity: "secondary",
928
+ text: "",
929
+ rounded: "",
930
+ class: "cui-icon-sm shrink-0",
931
+ onClick: i[14] ||= (e) => Ce.value = !h(Ce)
932
+ }, {
933
+ icon: _(() => [D(T, { class: "w-4 h-4" })]),
934
+ _: 1
935
+ })) : f("", !0)]), S("span", Jt, a(t.$t("components.training_editor.hint_wrong")), 1)]),
936
+ h(De) && h(Ce) ? (r(), v("div", Yt, [
937
+ i[16] ||= S("span", null, [S("kbd", null, "Tab")], -1),
938
+ S("span", null, a(t.$t("components.training_editor.sc_select")), 1),
939
+ i[17] ||= C(),
940
+ i[18] ||= S("span", null, [S("kbd", null, "←↑→↓")], -1),
941
+ S("span", null, a(t.$t("components.training_editor.sc_move")), 1),
942
+ i[19] ||= C(),
943
+ i[20] ||= S("span", null, [
944
+ S("kbd", null, "Shift"),
945
+ C(" + "),
946
+ S("kbd", null, "←↑→↓")
947
+ ], -1),
948
+ S("span", null, a(t.$t("components.training_editor.sc_resize")), 1),
949
+ i[21] ||= C(),
950
+ i[22] ||= S("span", null, [S("kbd", null, "S")], -1),
951
+ S("span", null, a(t.$t("components.training_editor.sc_label")), 1),
952
+ i[23] ||= C(),
953
+ i[24] ||= S("span", null, [S("kbd", null, "Del")], -1),
954
+ S("span", null, a(t.$t("components.training_editor.sc_delete")), 1),
955
+ i[25] ||= C(),
956
+ i[26] ||= S("span", null, [S("kbd", null, "V")], -1),
957
+ S("span", null, a(t.$t("components.training_editor.sc_ghosts")), 1),
958
+ i[27] ||= C(),
959
+ i[28] ||= S("span", null, [
960
+ S("kbd", null, "Shift"),
961
+ C(" + "),
962
+ S("kbd", null, "V")
963
+ ], -1),
964
+ S("span", null, a(t.$t("components.training_editor.sc_ghosts_all")), 1),
965
+ i[29] ||= C(),
966
+ i[30] ||= S("span", null, [S("kbd", null, "Esc")], -1),
967
+ S("span", null, a(t.$t("components.training_editor.sc_deselect")), 1),
968
+ i[31] ||= C(),
969
+ i[32] ||= S("span", null, [S("kbd", null, "Space")], -1),
970
+ S("span", null, a(t.$t("components.training_editor.sc_verify")), 1),
971
+ i[33] ||= C(),
972
+ i[34] ||= S("span", null, [
973
+ S("kbd", null, "←"),
974
+ C(" / "),
975
+ S("kbd", null, "→")
976
+ ], -1),
977
+ S("span", null, a(t.$t("components.training_editor.sc_nav")), 1)
978
+ ])) : f("", !0),
979
+ D(k, {
980
+ ref_key: "labelMenuRef",
981
+ ref: N,
982
+ items: h(at),
983
+ popover: { pt: { content: { class: "p-0! rounded-xl! overflow-hidden!" } } }
984
+ }, null, 8, ["items"])
985
+ ], 512);
986
+ };
987
+ }
988
+ }), [["__scopeId", "data-v-25538d2a"]]), un = { class: "flex flex-col gap-3" }, dn = {
989
+ key: 0,
990
+ class: "flex flex-col gap-2"
991
+ }, fn = {
992
+ key: 1,
993
+ class: "flex flex-col items-center gap-3 py-10"
994
+ }, pn = { class: "text-muted text-sm text-center max-w-sm" }, mn = {
995
+ key: 2,
996
+ class: "flex flex-col items-center gap-3 py-10"
997
+ }, hn = { class: "text-muted text-sm text-center max-w-sm" }, gn = { class: "text-muted text-sm" }, _n = { class: "w-24 aspect-video rounded-lg overflow-hidden bg-black/5 dark:bg-black/30 shrink-0" }, vn = { class: "flex-1 min-w-0" }, yn = { class: "flex flex-wrap items-center gap-1" }, bn = { class: "text-xs text-muted mt-1" }, xn = {
998
+ key: 0,
999
+ class: "flex justify-center py-2"
1000
+ }, Sn = /* @__PURE__ */ T({
1001
+ __name: "TrainingSubmissions",
1002
+ setup(e) {
1003
+ let t = new st(), { t: o, te: s } = Ne(), c = Te(), l = _t(), u = t.deleteSubmissionMutation(), p = E(""), m = E([]), g = E(0), C = E(), w = E(!0), T = E(!1), O = E(!1), re = x("loadMoreRef");
1004
+ function ae(e) {
1005
+ let t = {};
1006
+ for (let n of e.labels) t[n.label] = (t[n.label] ?? 0) + 1;
1007
+ return t;
1008
+ }
1009
+ function oe(e) {
1010
+ let t = `components.training_editor.labels.${e}`;
1011
+ return s(t) ? o(t) : e;
1012
+ }
1013
+ async function k() {
1014
+ w.value = m.value.length === 0;
1015
+ try {
1016
+ let e = await it();
1017
+ m.value = e.items, g.value = e.total ?? e.items.length, C.value = e.nextCursor, O.value = !1;
1018
+ } catch {
1019
+ O.value = !0;
1020
+ } finally {
1021
+ w.value = !1;
1022
+ }
1023
+ }
1024
+ async function ce() {
1025
+ let e = C.value;
1026
+ if (e && !T.value) {
1027
+ T.value = !0;
1028
+ try {
1029
+ let t = await it({ cursor: e }), n = new Set(m.value.map((e) => e.id));
1030
+ m.value.push(...t.items.filter((e) => !n.has(e.id))), C.value = t.nextCursor;
1031
+ } catch (e) {
1032
+ c.add({
1033
+ severity: "error",
1034
+ detail: e?.message ?? String(e),
1035
+ life: 5e3
1036
+ });
1037
+ } finally {
1038
+ T.value = !1;
1039
+ }
1040
+ }
1041
+ }
1042
+ async function le(e) {
1043
+ p.value = e;
1044
+ try {
1045
+ await u.mutateAsync(e), m.value = m.value.filter((t) => t.id !== e), g.value = Math.max(0, g.value - 1);
1046
+ } catch (e) {
1047
+ c.add({
1048
+ severity: "error",
1049
+ detail: e?.message ?? String(e),
1050
+ life: 5e3
1051
+ });
1052
+ } finally {
1053
+ p.value = "";
1054
+ }
1055
+ }
1056
+ Oe(re, ([e]) => {
1057
+ e?.isIntersecting && ce();
1058
+ }), ee(() => l.submitProgress.value?.active, (e, t) => {
1059
+ t && !e && k();
1060
+ });
1061
+ let ue = l.onResync(() => {
1062
+ k();
1063
+ });
1064
+ return i(() => {
1065
+ ue();
1066
+ }), k(), (e, t) => {
1067
+ let i = ve, o = Ve, s = A, c = se, l = ie, ee = We, x = Pe, E = P, k = ne;
1068
+ return r(), v("div", un, [h(w) ? (r(), v("div", dn, [(r(), v(b, null, n(4, (e) => D(i, {
1069
+ key: e,
1070
+ height: "72px",
1071
+ "border-radius": "12px"
1072
+ })), 64))])) : h(O) ? (r(), v("div", fn, [D(o, { class: "w-10 h-10 text-muted" }), S("span", pn, a(e.$t("components.training_submissions.load_failed")), 1)])) : h(m).length ? (r(), v(b, { key: 3 }, [
1073
+ S("span", gn, a(e.$t("components.training_submissions.count", h(g))), 1),
1074
+ (r(!0), v(b, null, n(h(m), (t) => (r(), v("div", {
1075
+ key: t.id,
1076
+ class: "cui-card h-auto! shrink-0 p-2 flex items-center gap-3"
1077
+ }, [
1078
+ S("div", _n, [D(c, {
1079
+ src: t.imageUrl,
1080
+ "image-container-class": "w-full h-full",
1081
+ "image-style": { objectFit: "cover" }
1082
+ }, null, 8, ["src"])]),
1083
+ S("div", vn, [S("div", yn, [(r(!0), v(b, null, n(ae(t), (e, t) => (r(), v("span", {
1084
+ key: t,
1085
+ class: "px-1.5 py-0.5 rounded text-xs font-medium text-white",
1086
+ style: y({ backgroundColor: h(ye)(String(t)).color })
1087
+ }, a(oe(String(t))) + " ×" + a(e), 5))), 128))]), S("div", bn, a(h(he)(new Date(t.createdAt).getTime())), 1)]),
1088
+ D(l, {
1089
+ severity: t.usedInWave ? "success" : "info",
1090
+ value: t.usedInWave ? e.$t("components.training_submissions.status_trained") : e.$t("components.training_submissions.status_pool"),
1091
+ class: "shrink-0"
1092
+ }, null, 8, ["severity", "value"]),
1093
+ te((r(), d(x, {
1094
+ severity: "danger",
1095
+ text: "",
1096
+ rounded: "",
1097
+ class: "cui-icon-sm shrink-0",
1098
+ loading: h(u).isPending.value && h(p) === t.id,
1099
+ onClick: (e) => le(t.id)
1100
+ }, {
1101
+ icon: _(() => [D(ee, {
1102
+ width: "100%",
1103
+ height: "100%"
1104
+ })]),
1105
+ _: 1
1106
+ }, 8, ["loading", "onClick"])), [[
1107
+ k,
1108
+ e.$t("components.training_submissions.delete"),
1109
+ void 0,
1110
+ { left: !0 }
1111
+ ]])
1112
+ ]))), 128)),
1113
+ h(T) ? (r(), v("div", xn, [D(E, { class: "w-5 h-5 text-primary" })])) : h(C) ? (r(), v("div", {
1114
+ key: 1,
1115
+ ref_key: "loadMoreRef",
1116
+ ref: re,
1117
+ class: "h-px"
1118
+ }, null, 512)) : f("", !0)
1119
+ ], 64)) : (r(), v("div", mn, [D(s, { class: "w-10 h-10 text-muted" }), S("span", hn, a(e.$t("components.training_submissions.empty")), 1)]))]);
1120
+ };
1121
+ }
1122
+ }), Cn = { desktop: {
1123
+ maxWidth: "720px",
1124
+ width: "90vw"
1125
+ } }, wn = { class: "flex flex-col h-full min-h-0" }, Tn = {
1126
+ key: 0,
1127
+ class: "page-title"
1128
+ }, En = { class: "font-semibold text-xl truncate" }, Dn = { class: "flex gap-2 mb-4" }, $ = {
1129
+ key: 1,
1130
+ class: "cui-card h-auto! shrink-0 px-3 py-2 mb-4 flex items-center gap-3"
1131
+ }, On = { class: "flex-1 min-w-0" }, kn = { class: "text-sm" }, An = { class: "flex-1 text-sm" }, jn = {
1132
+ key: 2,
1133
+ class: "cui-card h-auto! shrink-0 px-3 py-2 mb-4 flex items-center gap-3"
1134
+ }, Mn = { class: "flex-1 text-sm" }, Nn = { class: "p-3" }, Pn = {
1135
+ key: 1,
1136
+ class: "flex h-full flex-col items-center justify-center w-full gap-4 py-16"
1137
+ }, Fn = { class: "text-muted text-sm text-center max-w-md" }, In = { class: "relative flex-1 min-h-0 overflow-hidden bg-black/5 dark:bg-black/30" }, Ln = { class: "absolute top-1.5 left-1.5 flex flex-wrap gap-1" }, Rn = {
1138
+ key: 0,
1139
+ class: "absolute bottom-1.5 left-1.5"
1140
+ }, zn = {
1141
+ key: 1,
1142
+ class: "absolute top-1.5 right-1.5 dark-mode"
1143
+ }, Bn = { class: "flex items-center justify-between gap-2" }, Vn = { class: "flex items-center gap-2 min-w-0" }, Hn = { class: "min-w-0" }, Un = { class: "font-medium truncate" }, Wn = { class: "text-xs text-muted" }, Gn = 40, Kn = /*#__PURE__*/ j(/* @__PURE__ */ T({
1144
+ __name: "Training",
1145
+ setup(t) {
1146
+ let o = new ue(), s = new st(), { t: l, te: u } = Ne(), p = F(), w = Te(), { smBreakpoint: T } = de(), O = s.getCandidatesQuery(), le = s.getSettingsQuery(), A = s.patchCandidateMutation(), j = s.deleteCandidateMutation(), me = s.patchSettingsMutation(), M = s.submitCandidatesMutation(), _e = _t(), { data: xe } = o.getCamerasQuery({
1147
+ page: 1,
1148
+ pageSize: -1
1149
+ }), I = E(""), L = De("cui-training-status-filter", "all"), Se = E(Gn), z = x("statusMenuRef"), we = x("cameraMenuRef"), ke = x("settingsMenuRef"), Ae = x("loadMoreRef"), Me = x("scrollRef"), { y: Ue } = B(Me), Ke = g(() => ({ gridTemplateColumns: `repeat(auto-fill, minmax(${T.value ? "220px" : "260px"}, 1fr))` })), Je = g(() => {
1150
+ let e = [...new Set((O.data.value ?? []).map((e) => Q(e.cameraId)))].sort((e, t) => e.localeCompare(t));
1151
+ return [{
1152
+ key: "all",
1153
+ label: l("views.training.all_cameras"),
1154
+ active: I.value === "",
1155
+ onClick: () => {
1156
+ I.value = "";
1157
+ }
1158
+ }, ...e.map((e) => ({
1159
+ key: e,
1160
+ label: e,
1161
+ active: I.value === e,
1162
+ onClick: () => {
1163
+ I.value = e;
1164
+ }
1165
+ }))];
1166
+ }), Ye = g(() => [{
1167
+ key: "collect",
1168
+ label: l("views.training.collection_enabled"),
1169
+ description: l("views.training.collection_hint"),
1170
+ toggle: !0,
1171
+ toggleState: le.data.value?.enabled ?? !0,
1172
+ onClick: () => {
1173
+ Tt(!(le.data.value?.enabled ?? !0));
1174
+ }
1175
+ }]), U = g(() => {
1176
+ let e = I.value.trim().toLowerCase();
1177
+ return e ? (O.data.value ?? []).filter((t) => Q(t.cameraId).toLowerCase().includes(e)) : O.data.value ?? [];
1178
+ }), W = g(() => L.value === "all" ? U.value : U.value.filter((e) => e.status === L.value)), Qe = g(() => {
1179
+ let e = {
1180
+ all: U.value.length,
1181
+ new: 0,
1182
+ verified: 0
1183
+ };
1184
+ for (let t of U.value) e[t.status]++;
1185
+ return e;
1186
+ }), $e = g(() => [
1187
+ "all",
1188
+ "new",
1189
+ "verified"
1190
+ ].map((e) => ({
1191
+ key: e,
1192
+ label: l(`views.training.status_${e}`),
1193
+ badge: String(Qe.value[e]),
1194
+ active: L.value === e,
1195
+ onClick: () => {
1196
+ L.value = e;
1197
+ }
1198
+ }))), tt = g(() => L.value !== "all" || I.value.trim() !== ""), nt = g(() => W.value.slice(0, Se.value)), rt = g(() => W.value.length > nt.value.length), G = g(() => (O.data.value ?? []).filter((e) => at(e)).length), K = g(() => _e.submitProgress.value ? _e.submitProgress.value : G.value > 0 ? {
1199
+ active: !0,
1200
+ total: G.value,
1201
+ done: 0,
1202
+ failed: 0
1203
+ } : null), it = g(() => W.value.filter((e) => !at(e)));
1204
+ function at(e) {
1205
+ return e.upload === "queued" || e.upload === "uploading";
1206
+ }
1207
+ let { selectionMode: q, selectedIds: ot, allSelected: ct, bulkBusy: J, enterSelectionMode: lt, exitSelectionMode: ut, toggleSelectAll: X, toggleSelection: dt } = pe(it, (e) => e.id), ft = g(() => [...ot.value].filter((e) => O.data.value?.find((t) => t.id === e)?.status === "verified")), Z = g(() => U.value.filter((e) => e.status === "verified" && !at(e)).map((e) => e.id));
1208
+ function Q(e) {
1209
+ return xe.value?.result?.find((t) => t._id === e)?.name ?? e;
1210
+ }
1211
+ function pt(e) {
1212
+ return ge(`/api/training/candidates/${e}/image`) ?? "";
1213
+ }
1214
+ function mt(e) {
1215
+ let t = `components.training_editor.labels.${e}`;
1216
+ return u(t) ? l(t) : e;
1217
+ }
1218
+ function ht(e) {
1219
+ let t = {};
1220
+ for (let n of e.boxes) t[n.label] = (t[n.label] ?? 0) + 1;
1221
+ return t;
1222
+ }
1223
+ function gt(e) {
1224
+ return e === "verified" ? "success" : "info";
1225
+ }
1226
+ function vt() {
1227
+ Se.value += Gn;
1228
+ }
1229
+ function yt(e) {
1230
+ if (!at(e)) {
1231
+ if (q.value) {
1232
+ dt(e.id);
1233
+ return;
1234
+ }
1235
+ bt(e);
1236
+ }
1237
+ }
1238
+ function bt(e) {
1239
+ p.openComponentDialog(ln, {
1240
+ data: {
1241
+ title: l("views.training.title"),
1242
+ cancelText: l("components.form.button.remove"),
1243
+ confirmText: l("components.training_editor.verify"),
1244
+ cancelButtonProps: { severity: "danger" },
1245
+ contentProps: {
1246
+ candidates: W.value.map((e) => ({ ...e })),
1247
+ startId: e.id,
1248
+ cameraName: Q,
1249
+ imageUrl: pt,
1250
+ onSave: async (e, t, n) => {
1251
+ await A.mutateAsync({
1252
+ id: e,
1253
+ patch: {
1254
+ boxes: t,
1255
+ status: n
1256
+ }
1257
+ });
1258
+ },
1259
+ onDelete: async (e) => {
1260
+ await j.mutateAsync(e);
1261
+ }
1262
+ }
1263
+ },
1264
+ dialogSize: Y
1265
+ });
1266
+ }
1267
+ function xt() {
1268
+ p.openComponentDialog(Sn, {
1269
+ data: {
1270
+ title: l("views.training.submissions"),
1271
+ hideConfirmButton: !0,
1272
+ cancelText: l("components.form.button.close"),
1273
+ contentProps: {}
1274
+ },
1275
+ dialogSize: Cn
1276
+ });
1277
+ }
1278
+ function St(e) {
1279
+ e.length && !M.isPending.value && p.openTextDialog({
1280
+ data: {
1281
+ title: l("components.dialog.title.confirm"),
1282
+ contentText: l("views.training.submit_confirm", { count: e.length }),
1283
+ confirmText: l("views.training.submit")
1284
+ },
1285
+ onConfirm: async () => {
1286
+ try {
1287
+ await M.mutateAsync(e), ut();
1288
+ } catch (e) {
1289
+ w.add({
1290
+ severity: "error",
1291
+ detail: e?.message ?? String(e),
1292
+ life: 8e3
1293
+ });
1294
+ }
1295
+ }
1296
+ });
1297
+ }
1298
+ function Ct() {
1299
+ let e = [...ot.value];
1300
+ e.length && !J.value && p.openTextDialog({
1301
+ data: {
1302
+ title: l("components.dialog.title.confirm"),
1303
+ contentText: l("views.training.delete_selected_confirm", { count: e.length }),
1304
+ confirmText: l("components.form.button.remove"),
1305
+ confirmButtonProps: { severity: "danger" }
1306
+ },
1307
+ onConfirm: async () => {
1308
+ J.value = !0;
1309
+ try {
1310
+ for (let t of e) await j.mutateAsync(t);
1311
+ ut(), w.add({
1312
+ severity: "success",
1313
+ detail: l("views.training.delete_selected_done", { count: e.length }),
1314
+ life: 5e3
1315
+ });
1316
+ } catch (e) {
1317
+ w.add({
1318
+ severity: "error",
1319
+ detail: e?.message ?? String(e),
1320
+ life: 5e3
1321
+ });
1322
+ } finally {
1323
+ J.value = !1;
1324
+ }
1325
+ }
1326
+ });
1327
+ }
1328
+ async function wt(e) {
1329
+ await j.mutateAsync(e.id);
1330
+ }
1331
+ async function Tt(e) {
1332
+ await me.mutateAsync({ enabled: e });
1333
+ }
1334
+ ee([I, L], () => {
1335
+ Se.value = Gn;
1336
+ }), Oe(Ae, ([e]) => {
1337
+ e?.isIntersecting && vt();
1338
+ }), _e.connect();
1339
+ let Et = _e.onCandidatesChanged(() => {
1340
+ O.refetch();
1341
+ });
1342
+ return i(() => {
1343
+ Et();
1344
+ }), (t, i) => {
1345
+ let o = Ge, s = Pe, u = R, p = Be, g = V, ee = Ie, x = Fe, w = Ze, E = ce, le = re, ue = fe, A = Xe, de = qe, j = P, pe = Re, me = Ve, ge = He, F = H, xe = ze, Se = ve, Te = Ce, De = se, B = ie, Oe = We, Ne = Le, Qe = je, G = be, it = ae, st = ne;
1346
+ return r(), v("div", wn, [
1347
+ h(T) ? f("", !0) : (r(), v("h1", Tn, a(t.$t("views.training.title")), 1)),
1348
+ D(u, { position: "left" }, {
1349
+ default: _(() => [D(s, {
1350
+ severity: "secondary",
1351
+ text: "",
1352
+ class: "cui-button p-2 text-color non-draggable-region",
1353
+ onClick: i[0] ||= (e) => t.$router.push("/menu")
1354
+ }, {
1355
+ icon: _(() => [D(o, { class: "w-6 h-6" })]),
1356
+ _: 1
1357
+ })]),
1358
+ _: 1
1359
+ }),
1360
+ D(u, { position: "center" }, {
1361
+ default: _(() => [S("span", En, a(t.$t("views.training.title")), 1)]),
1362
+ _: 1
1363
+ }),
1364
+ S("div", Dn, [
1365
+ D(ue, { class: "flex-1" }, {
1366
+ default: _(() => [
1367
+ D(x, { class: "flex-1" }, {
1368
+ default: _(() => [D(g, null, {
1369
+ default: _(() => [D(p, { class: "w-4 h-4" })]),
1370
+ _: 1
1371
+ }), D(ee, {
1372
+ modelValue: h(I),
1373
+ "onUpdate:modelValue": i[1] ||= (e) => m(I) ? I.value = e : null,
1374
+ placeholder: h(l)("views.training.search"),
1375
+ class: "w-full"
1376
+ }, null, 8, ["modelValue", "placeholder"])]),
1377
+ _: 1
1378
+ }),
1379
+ D(E, null, {
1380
+ default: _(() => [D(s, {
1381
+ severity: "secondary",
1382
+ text: "",
1383
+ class: c(h(L) === "all" ? "text-color" : "text-primary"),
1384
+ onClick: i[2] ||= (e) => h(z)?.toggleMenu(e)
1385
+ }, {
1386
+ icon: _(() => [D(w, { class: "w-4 h-4" })]),
1387
+ _: 1
1388
+ }, 8, ["class"])]),
1389
+ _: 1
1390
+ }),
1391
+ D(E, null, {
1392
+ default: _(() => [D(s, {
1393
+ severity: "secondary",
1394
+ text: "",
1395
+ class: "text-color",
1396
+ onClick: i[3] ||= (e) => h(we)?.toggleMenu(e)
1397
+ }, {
1398
+ icon: _(() => [D(le, { class: c(["w-4 h-4 transform transition-transform duration-300", { "rotate-180": h(we)?.isOpen }]) }, null, 8, ["class"])]),
1399
+ _: 1
1400
+ })]),
1401
+ _: 1
1402
+ })
1403
+ ]),
1404
+ _: 1
1405
+ }),
1406
+ te((r(), d(s, {
1407
+ severity: "secondary",
1408
+ outlined: "",
1409
+ class: "cui-button shrink-0",
1410
+ onClick: xt
1411
+ }, {
1412
+ icon: _(() => [D(A, { class: "w-4.5 h-4.5" })]),
1413
+ _: 1
1414
+ })), [[
1415
+ st,
1416
+ { value: t.$t("views.training.submissions") },
1417
+ void 0,
1418
+ { left: !0 }
1419
+ ]]),
1420
+ te((r(), d(s, {
1421
+ severity: "secondary",
1422
+ outlined: "",
1423
+ class: "cui-button shrink-0",
1424
+ onClick: i[4] ||= (e) => h(ke)?.toggleMenu(e)
1425
+ }, {
1426
+ icon: _(() => [D(de, { class: "w-4.5 h-4.5" })]),
1427
+ _: 1
1428
+ })), [[
1429
+ st,
1430
+ { value: t.$t("views.training.collection") },
1431
+ void 0,
1432
+ { left: !0 }
1433
+ ]])
1434
+ ]),
1435
+ h(K) ? (r(), v("div", $, [h(K).active ? (r(), v(b, { key: 0 }, [D(j, { class: "w-4 h-4 text-primary shrink-0" }), S("div", On, [S("div", kn, a(t.$t("views.training.upload_progress", {
1436
+ done: h(K).done + h(K).failed,
1437
+ total: h(K).total
1438
+ })), 1), D(pe, {
1439
+ value: h(K).total ? Math.round((h(K).done + h(K).failed) / h(K).total * 100) : 0,
1440
+ "show-value": !1,
1441
+ style: { height: "6px" },
1442
+ class: "mt-1.5"
1443
+ }, null, 8, ["value"])])], 64)) : (r(), v(b, { key: 1 }, [
1444
+ h(K).failed ? (r(), d(me, {
1445
+ key: 0,
1446
+ class: "w-5 h-5 text-red-500 shrink-0"
1447
+ })) : (r(), d(ge, {
1448
+ key: 1,
1449
+ class: "w-5 h-5 text-green-500 shrink-0"
1450
+ })),
1451
+ S("span", An, [C(a(t.$t("views.training.submit_done", h(K).done)), 1), h(K).failed ? (r(), v(b, { key: 0 }, [C(" · " + a(t.$t("views.training.upload_failed_summary", { count: h(K).failed })), 1)], 64)) : f("", !0)]),
1452
+ D(s, {
1453
+ severity: "secondary",
1454
+ text: "",
1455
+ rounded: "",
1456
+ class: "cui-icon-sm shrink-0",
1457
+ onClick: i[5] ||= (e) => h(_e).dismissProgress()
1458
+ }, {
1459
+ icon: _(() => [D(F, { class: "w-4 h-4" })]),
1460
+ _: 1
1461
+ })
1462
+ ], 64))])) : h(U).length && !h(Z).length ? (r(), v("div", jn, [D(xe, { class: "w-5 h-5 text-primary shrink-0" }), S("span", Mn, a(t.$t("views.training.verify_hint")), 1)])) : f("", !0),
1463
+ S("div", {
1464
+ ref_key: "scrollRef",
1465
+ ref: Me,
1466
+ class: "flex-1 min-h-0 overflow-y-auto overscroll-contain"
1467
+ }, [h(O).isLoading.value && !h(O).data.value ? (r(), v("div", {
1468
+ key: 0,
1469
+ class: "grid w-full gap-3 p-px",
1470
+ style: y(h(Ke))
1471
+ }, [(r(), v(b, null, n(8, (e) => S("div", {
1472
+ key: e,
1473
+ class: "cui-card overflow-hidden"
1474
+ }, [D(Se, {
1475
+ class: "aspect-video",
1476
+ width: "100%",
1477
+ height: "100%"
1478
+ }), S("div", Nn, [D(Se, {
1479
+ height: "14px",
1480
+ width: "70%",
1481
+ class: "mb-1"
1482
+ }), D(Se, {
1483
+ height: "12px",
1484
+ width: "40%"
1485
+ })])])), 64))], 4)) : h(W).length === 0 ? (r(), v("div", Pn, [D(Te, { class: "w-12 h-12 text-muted" }), S("span", Fn, a(t.$t(h(tt) ? "views.training.no_matches" : "views.training.no_candidates")), 1)])) : (r(), v(b, { key: 2 }, [S("div", {
1486
+ class: "grid w-full gap-3 p-px",
1487
+ style: y(h(Ke))
1488
+ }, [(r(!0), v(b, null, n(h(nt), (o) => (r(), d(Qe, {
1489
+ key: o.id,
1490
+ class: "cui-card cui-training-card overflow-hidden transition-shadow cursor-pointer hover:shadow-md aspect-[1.17] flex flex-col",
1491
+ pt: {
1492
+ header: { class: "flex-1 min-h-0 flex" },
1493
+ body: {
1494
+ class: "shrink-0",
1495
+ style: "height: auto"
1496
+ }
1497
+ },
1498
+ onClick: (e) => yt(o)
1499
+ }, {
1500
+ header: _(() => [S("div", In, [
1501
+ D(De, {
1502
+ class: "absolute inset-0",
1503
+ src: pt(o.id),
1504
+ alt: Q(o.cameraId),
1505
+ "image-container-class": "w-full h-full",
1506
+ "image-style": { objectFit: "cover" }
1507
+ }, null, 8, ["src", "alt"]),
1508
+ S("div", Ln, [(r(!0), v(b, null, n(ht(o), (e, t) => (r(), v("span", {
1509
+ key: t,
1510
+ class: "px-1.5 py-0.5 rounded text-xs font-medium text-white",
1511
+ style: y({ backgroundColor: h(ye)(String(t)).color })
1512
+ }, a(mt(String(t))) + " ×" + a(e), 5))), 128))]),
1513
+ o.upload ? (r(), v("div", Rn, [o.upload === "failed" ? te((r(), d(B, {
1514
+ key: 0,
1515
+ severity: "danger",
1516
+ value: t.$t("views.training.upload_failed")
1517
+ }, null, 8, ["value"])), [[
1518
+ st,
1519
+ o.uploadError,
1520
+ void 0,
1521
+ { top: !0 }
1522
+ ]]) : o.upload === "uploading" ? (r(), d(B, {
1523
+ key: 1,
1524
+ severity: "info",
1525
+ value: t.$t("views.training.upload_uploading")
1526
+ }, null, 8, ["value"])) : (r(), d(B, {
1527
+ key: 2,
1528
+ severity: "secondary",
1529
+ value: t.$t("views.training.upload_queued")
1530
+ }, null, 8, ["value"]))])) : f("", !0),
1531
+ !h(q) && !at(o) ? (r(), v("div", zn, [te((r(), d(s, {
1532
+ severity: "secondary",
1533
+ rounded: "",
1534
+ size: "small",
1535
+ class: "cui-icon-sm text-white",
1536
+ onClick: e((e) => wt(o), ["stop"])
1537
+ }, {
1538
+ icon: _(() => [D(Oe, {
1539
+ width: "100%",
1540
+ height: "100%"
1541
+ })]),
1542
+ _: 1
1543
+ }, 8, ["onClick"])), [[
1544
+ st,
1545
+ t.$t("views.training.delete_candidate"),
1546
+ void 0,
1547
+ { top: !0 }
1548
+ ]])])) : f("", !0)
1549
+ ])]),
1550
+ content: _(() => [S("div", Bn, [S("div", Vn, [h(q) && !at(o) ? (r(), d(Ne, {
1551
+ key: 0,
1552
+ "model-value": h(ot).has(o.id),
1553
+ binary: "",
1554
+ size: "small",
1555
+ onClick: i[6] ||= e(() => {}, ["stop"]),
1556
+ "onUpdate:modelValue": (e) => h(dt)(o.id)
1557
+ }, null, 8, ["model-value", "onUpdate:modelValue"])) : f("", !0), S("div", Hn, [S("div", Un, a(Q(o.cameraId)), 1), S("div", Wn, a(h(he)(o.createdAt)), 1)])]), D(B, {
1558
+ severity: gt(o.status),
1559
+ value: t.$t(`views.training.status_${o.status}`)
1560
+ }, null, 8, ["severity", "value"])])]),
1561
+ _: 2
1562
+ }, 1032, ["onClick"]))), 128))], 4), h(rt) ? (r(), v("div", {
1563
+ key: 0,
1564
+ ref_key: "loadMoreRef",
1565
+ ref: Ae,
1566
+ class: "h-px"
1567
+ }, null, 512)) : f("", !0)], 64))], 512),
1568
+ h(W).length || h(q) ? (r(), d(it, {
1569
+ key: 3,
1570
+ "force-visible": h(q),
1571
+ "scroll-y": h(Ue)
1572
+ }, {
1573
+ default: _(() => [h(q) ? (r(), v(b, { key: 1 }, [
1574
+ D(G, {
1575
+ grouped: "",
1576
+ "tooltip-props": { value: t.$t("components.form.tooltip.cancel_selection") },
1577
+ "button-props": { severity: "secondary" },
1578
+ icon: h(H),
1579
+ "icon-props": {
1580
+ width: "100%",
1581
+ height: "100%"
1582
+ },
1583
+ onClick: h(ut)
1584
+ }, null, 8, [
1585
+ "tooltip-props",
1586
+ "icon",
1587
+ "onClick"
1588
+ ]),
1589
+ D(G, {
1590
+ grouped: "",
1591
+ "tooltip-props": { value: h(ct) ? t.$t("views.training.deselect_all") : t.$t("views.training.select_all") },
1592
+ "button-props": { severity: h(ct) ? "primary" : "secondary" },
1593
+ icon: h(N),
1594
+ "icon-props": {
1595
+ width: "100%",
1596
+ height: "100%"
1597
+ },
1598
+ onClick: h(X)
1599
+ }, null, 8, [
1600
+ "tooltip-props",
1601
+ "button-props",
1602
+ "icon",
1603
+ "onClick"
1604
+ ]),
1605
+ D(G, {
1606
+ grouped: "",
1607
+ "tooltip-props": { value: t.$t("views.training.submit_selected") },
1608
+ "button-props": { disabled: !h(ft).length || h(M).isPending.value },
1609
+ icon: h(et),
1610
+ "icon-props": {
1611
+ width: "100%",
1612
+ height: "100%"
1613
+ },
1614
+ onClick: i[8] ||= (e) => St(h(ft))
1615
+ }, null, 8, [
1616
+ "tooltip-props",
1617
+ "button-props",
1618
+ "icon"
1619
+ ]),
1620
+ D(G, {
1621
+ grouped: "",
1622
+ "tooltip-props": { value: t.$t("views.training.delete_selected") },
1623
+ "button-props": {
1624
+ severity: "danger",
1625
+ disabled: !h(ot).size || h(J)
1626
+ },
1627
+ icon: h(oe),
1628
+ "icon-props": {
1629
+ width: "100%",
1630
+ height: "100%"
1631
+ },
1632
+ onClick: Ct
1633
+ }, null, 8, [
1634
+ "tooltip-props",
1635
+ "button-props",
1636
+ "icon"
1637
+ ])
1638
+ ], 64)) : (r(), v(b, { key: 0 }, [D(G, {
1639
+ grouped: "",
1640
+ "tooltip-props": { value: t.$t("views.training.select") },
1641
+ "button-props": { severity: "secondary" },
1642
+ icon: h(Ee),
1643
+ "icon-props": {
1644
+ width: "100%",
1645
+ height: "100%"
1646
+ },
1647
+ onClick: h(lt)
1648
+ }, null, 8, [
1649
+ "tooltip-props",
1650
+ "icon",
1651
+ "onClick"
1652
+ ]), D(G, {
1653
+ grouped: "",
1654
+ "tooltip-props": { value: h(Z).length ? t.$t("views.training.submit_ready", h(Z).length) : t.$t("views.training.submit_disabled") },
1655
+ "button-props": {
1656
+ class: "text-white",
1657
+ disabled: !h(Z).length || h(M).isPending.value
1658
+ },
1659
+ icon: h(et),
1660
+ "icon-props": {
1661
+ width: "26px",
1662
+ height: "26px"
1663
+ },
1664
+ onClick: i[7] ||= (e) => St(h(Z))
1665
+ }, null, 8, [
1666
+ "tooltip-props",
1667
+ "button-props",
1668
+ "icon"
1669
+ ])], 64))]),
1670
+ _: 1
1671
+ }, 8, ["force-visible", "scroll-y"])) : f("", !0),
1672
+ D(k, {
1673
+ ref_key: "statusMenuRef",
1674
+ ref: z,
1675
+ items: h($e),
1676
+ popover: { pt: { content: { class: "p-0! rounded-xl! overflow-hidden!" } } }
1677
+ }, null, 8, ["items"]),
1678
+ D(k, {
1679
+ ref_key: "cameraMenuRef",
1680
+ ref: we,
1681
+ items: h(Je),
1682
+ popover: { pt: { content: { class: "p-0! rounded-xl! overflow-hidden!" } } }
1683
+ }, null, 8, ["items"]),
1684
+ D(k, {
1685
+ ref_key: "settingsMenuRef",
1686
+ ref: ke,
1687
+ items: h(Ye),
1688
+ "auto-hide": !1,
1689
+ popover: { pt: {
1690
+ root: { class: "w-[22rem]" },
1691
+ content: { class: "p-0! rounded-xl! overflow-hidden!" }
1692
+ } }
1693
+ }, null, 8, ["items"])
1694
+ ]);
1695
+ };
1696
+ }
1697
+ }), [["__scopeId", "data-v-5b04f6ed"]]);
1698
+ //#endregion
1699
+ export { Kn as default };