@camera.ui/server 2.2.7 → 2.3.0

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 (958) hide show
  1. package/LICENSE.md +8 -1
  2. package/dist/interface/assets/404-C0X5UBF4.js +1 -0
  3. package/dist/interface/assets/About-Ctp_u5qK.js +1 -0
  4. package/dist/interface/assets/Assistant-Bj2bAUHD.css +1 -0
  5. package/dist/interface/assets/Assistant-CDrBV_mg.js +1 -0
  6. package/dist/interface/assets/Automation-Dp6V80Iz.js +3 -0
  7. package/dist/interface/assets/Automation-R5o9sXYY.css +1 -0
  8. package/dist/interface/assets/AutomationImport-DKgg7atE.js +2 -0
  9. package/dist/interface/assets/AutomationStore-CU-m5VC8.js +2 -0
  10. package/dist/interface/assets/AutomationStoreDetail-CiyIs8Iu.js +2 -0
  11. package/dist/interface/assets/Automations-Dljh-sWu.js +2 -0
  12. package/dist/interface/assets/Camera-0p0P_mbp.css +1 -0
  13. package/dist/interface/assets/Camera-Bvovab-8.js +2 -0
  14. package/dist/interface/assets/CameraConsole-D_Fv-MAi.js +7 -0
  15. package/dist/interface/assets/Cameras-Cq7Gw-fk.js +651 -0
  16. package/dist/interface/assets/Camview-Bs2VvmUS.css +1 -0
  17. package/dist/interface/assets/Camview-CP6PA20C.js +1 -0
  18. package/dist/interface/assets/CertificateUpload-DjzNMFc3.js +1 -0
  19. package/dist/interface/assets/Config-Dl2TlyFe.js +2 -0
  20. package/dist/interface/assets/ConfigActionAssistant-DCkJ_Iqq.js +1 -0
  21. package/dist/interface/assets/ConfigActionCameraControl-2pzl59gR.js +1 -0
  22. package/dist/interface/assets/ConfigActionDelay-BAp1dr0N.js +1 -0
  23. package/dist/interface/assets/ConfigActionHttp-_kqgEuun.js +1 -0
  24. package/dist/interface/assets/ConfigActionImageInput-BgtACnCm.js +1 -0
  25. package/dist/interface/assets/ConfigActionMqtt-z7UzccW5.js +1 -0
  26. package/dist/interface/assets/ConfigActionNotification-bhbb5AqU.js +1 -0
  27. package/dist/interface/assets/ConfigActionNotificationControl-BbvX8MFu.js +1 -0
  28. package/dist/interface/assets/ConfigActionOutput-DdgSg3FU.js +1 -0
  29. package/dist/interface/assets/ConfigActionPlugin-DGjZd1L0.js +1 -0
  30. package/dist/interface/assets/ConfigActionSensor-DmImWFAo.js +1 -0
  31. package/dist/interface/assets/ConfigActionSnapshot-hVHSfdtS.js +1 -0
  32. package/dist/interface/assets/ConfigActionVariable-BIpruwsx.js +1 -0
  33. package/dist/interface/assets/ConfigConditionIfElse-DRSpsoR4.js +1 -0
  34. package/dist/interface/assets/ConfigConditionSensorState-C2SNARH7.js +1 -0
  35. package/dist/interface/assets/ConfigConditionSwitch-4SbQcU7N.js +1 -0
  36. package/dist/interface/assets/ConfigConditionTime-ESX3shbg.js +1 -0
  37. package/dist/interface/assets/ConfigSensorValueInput-CTUdAA-R.js +1 -0
  38. package/dist/interface/assets/ConfigTriggerDetection-BRr6ixxQ.js +1 -0
  39. package/dist/interface/assets/ConfigTriggerGeofence-D-xRMGrT.js +1 -0
  40. package/dist/interface/assets/ConfigTriggerManual-aXD6k1qa.js +1 -0
  41. package/dist/interface/assets/ConfigTriggerMqtt-pjHW4yOL.js +1 -0
  42. package/dist/interface/assets/ConfigTriggerSchedule-CYOt57qg.js +1 -0
  43. package/dist/interface/assets/ConfigTriggerSensor-BwJ_cAqd.js +1 -0
  44. package/dist/interface/assets/ConfigTriggerSystem-DBXIrjzU.js +1 -0
  45. package/dist/interface/assets/ConfigTriggerWebhook-CccBmMCb.js +1 -0
  46. package/dist/interface/assets/Console-DWAaz1C6.js +1 -0
  47. package/dist/interface/assets/CuiAssistantConversation-B3xEiNNt.js +5 -0
  48. package/dist/interface/assets/CuiAssistantConversation-C5ca1lgX.css +1 -0
  49. package/dist/interface/assets/CuiAutomationRunsDialog-CfylVPLI.js +1 -0
  50. package/dist/interface/assets/CuiBottomSheet-ACN23VLS.js +1 -0
  51. package/dist/interface/assets/CuiBottomSheet-DEVNeDqa.js +1 -0
  52. package/dist/interface/assets/CuiCameraPipCard-TYTCfwXf.css +1 -0
  53. package/dist/interface/assets/CuiCameraPipCard-rR_FW9zq.js +1 -0
  54. package/dist/interface/assets/CuiCameraRecordings-CnorhPhf.js +1 -0
  55. package/dist/interface/assets/CuiCameraShares-BxUgedC_.js +1 -0
  56. package/dist/interface/assets/CuiCameraTable-C3GB4Q2y.js +2 -0
  57. package/dist/interface/assets/CuiCameraTable-MHfnZSyK.js +1 -0
  58. package/dist/interface/assets/CuiChartTable-TAzZgetO.js +1 -0
  59. package/dist/interface/assets/CuiConsole-Cf5lOCE1.js +5 -0
  60. package/dist/interface/assets/CuiDataTable-DfjXa0C1.js +1 -0
  61. package/dist/interface/assets/CuiLightControl-ChK-SvJp.js +1 -0
  62. package/dist/interface/assets/CuiList-C4fxd9lD.js +1 -0
  63. package/dist/interface/assets/CuiMarkdownContent-Do04YgHe.js +1 -0
  64. package/dist/interface/assets/CuiMarkdownContent-qOPm3VEi.js +1 -0
  65. package/dist/interface/assets/CuiPluginCard-DMpANIQj.js +2 -0
  66. package/dist/interface/assets/CuiPluginCategoryChip-BKxJMid7.js +1 -0
  67. package/dist/interface/assets/CuiPluginOAuthButton-DnQ838JJ.js +2 -0
  68. package/dist/interface/assets/CuiPluginTrustBadge-DyYDUWV6.js +1 -0
  69. package/dist/interface/assets/CuiQRCode-S9fPi0_l.js +1 -0
  70. package/dist/interface/assets/CuiSchema-DScmDQsh.js +1 -0
  71. package/dist/interface/assets/CuiTopNavbarItem-CT10aAlO.js +1 -0
  72. package/dist/interface/assets/Faces-Coy-tUVM.js +1 -0
  73. package/dist/interface/assets/FirstSteps-CrMJC049.js +1 -0
  74. package/dist/interface/assets/Floorplan-Bj_mVrxp.js +1 -0
  75. package/dist/interface/assets/Floorplan-CT5TrMSD.css +1 -0
  76. package/dist/interface/assets/Instances-B_mpKAng.js +1 -0
  77. package/dist/interface/assets/Logs-fY1dpQk4.js +6 -0
  78. package/dist/interface/assets/Menu-Bgi-NLdg.js +1 -0
  79. package/dist/interface/assets/Metrics-DnMeIrkf.css +1 -0
  80. package/dist/interface/assets/Metrics-k9KACiwh.js +12 -0
  81. package/dist/interface/assets/OAuthDeviceFlow-xTh83xmc.js +1 -0
  82. package/dist/interface/assets/Plugin-BB7x7UHw.css +1 -0
  83. package/dist/interface/assets/Plugin-VWq7sONB.js +1 -0
  84. package/dist/interface/assets/PluginConsole-LnnDOVBL.js +7 -0
  85. package/dist/interface/assets/PluginDetail-CKD9sbDx.js +2 -0
  86. package/dist/interface/assets/PluginSchema-BnB0_6Sk.js +1 -0
  87. package/dist/interface/assets/PluginSearch-BoBZLLbr.js +1 -0
  88. package/dist/interface/assets/PluginSearch-kGhweU1J.js +2 -0
  89. package/dist/interface/assets/PluginUpdateProgress-DMx0QlgE.js +1 -0
  90. package/dist/interface/assets/Plugins-Ekmr6aVa.js +1 -0
  91. package/dist/interface/assets/RecentEventsFilter-StLJNuks.js +1 -0
  92. package/dist/interface/assets/Recordings-8PqxJOI3.css +1 -0
  93. package/dist/interface/assets/Recordings-Bvkuk_TV.js +1 -0
  94. package/dist/interface/assets/SensorEdit-CAf9Nb01.js +1 -0
  95. package/dist/interface/assets/SensorHistory-il8bDErX.js +1 -0
  96. package/dist/interface/assets/Sensors-sxQ6HLKo.js +2 -0
  97. package/dist/interface/assets/Settings-Bu0G7Ebx.js +1 -0
  98. package/dist/interface/assets/Settings-DtCSaLPb.css +1 -0
  99. package/dist/interface/assets/SettingsAccount-8OZJLQi-.js +1 -0
  100. package/dist/interface/assets/SettingsAccount-bSfFi9YH.js +1 -0
  101. package/dist/interface/assets/SettingsAppearance-CnvN_Tzr.js +1 -0
  102. package/dist/interface/assets/SettingsAppearance-EvPWgF4c.js +1 -0
  103. package/dist/interface/assets/SettingsAssistant-B6s6pHCx.js +1 -0
  104. package/dist/interface/assets/SettingsBackup-Dd2FaUcN.js +1 -0
  105. package/dist/interface/assets/SettingsList-SvCO_gfG.js +1 -0
  106. package/dist/interface/assets/SettingsMqtt-BXBzHX84.js +1 -0
  107. package/dist/interface/assets/SettingsNotifications-CV-jJwFV.js +1 -0
  108. package/dist/interface/assets/SettingsPermissions-GchFaWjz.js +1 -0
  109. package/dist/interface/assets/SettingsRecordings-C4Ch_jmV.js +1 -0
  110. package/dist/interface/assets/SettingsRemote-CsIGx-LU.css +1 -0
  111. package/dist/interface/assets/SettingsRemote-OZHDJKSq.js +2 -0
  112. package/dist/interface/assets/SettingsSystem-BJlHXwVs.js +2 -0
  113. package/dist/interface/assets/SettingsUsers-RGOkOzx0.js +1 -0
  114. package/dist/interface/assets/Terminal-DX-ECC91.js +4 -0
  115. package/dist/interface/assets/Training-B8my7vka.js +1 -0
  116. package/dist/interface/assets/Training-D1DDjCCD.css +1 -0
  117. package/dist/interface/assets/Updates-DmavyhAn.js +2 -0
  118. package/dist/interface/assets/VariableInput-DQJle67Y.js +1 -0
  119. package/dist/interface/assets/VariableSuggestions-D8V739dF.js +1 -0
  120. package/dist/interface/assets/VersionsHandler-B41TJhgY.js +7 -0
  121. package/dist/interface/assets/VirtualSensorCreate-MfLh-LpH.js +1 -0
  122. package/dist/interface/assets/Workers-CafDeRhH.js +2 -0
  123. package/dist/interface/assets/Workers-Dey1snI4.css +1 -0
  124. package/dist/interface/assets/account-DjBQulDn.js +1 -0
  125. package/dist/interface/assets/ace-BPAekgyf.js +1 -0
  126. package/dist/interface/assets/ace.config-CvKE-yp1.js +1 -0
  127. package/dist/interface/assets/alert-circle-B-JCMbb9.js +1 -0
  128. package/dist/interface/assets/alert-outline-B4ZZowEj.js +1 -0
  129. package/dist/interface/assets/api-By0v6EeA.css +2 -0
  130. package/dist/interface/assets/api-D1iULsSy.js +4 -0
  131. package/dist/interface/assets/api-DbUdfXO_.js +1 -0
  132. package/dist/interface/assets/arrow-left-PeaVwpHd.js +1 -0
  133. package/dist/interface/assets/assistant-7hqP6OpA.js +1 -0
  134. package/dist/interface/assets/assistantModels-D3ncWWu0.js +1 -0
  135. package/dist/interface/assets/auth-CDxrn7fe.js +1 -0
  136. package/dist/interface/assets/automations-CTTQlGCW.js +1 -0
  137. package/dist/interface/assets/back-filled-CJoz7Gkl.js +1 -0
  138. package/dist/interface/assets/bell-ring-CBf0Yn3H.js +1 -0
  139. package/dist/interface/assets/brain-uZ03n3LW.js +1 -0
  140. package/dist/interface/assets/cameraSources-MOiE_1-W.js +1 -0
  141. package/dist/interface/assets/cctv-VgKQ-dBV.js +1 -0
  142. package/dist/interface/assets/check-circle-BU-KNgPB.js +1 -0
  143. package/dist/interface/assets/check-circle-outline-BsxzAMed.js +1 -0
  144. package/dist/interface/assets/chevron-down-CxK4Sfjs.js +1 -0
  145. package/dist/interface/assets/chevron-up-DWfNH8va.js +1 -0
  146. package/dist/interface/assets/clock-outline-BtWx4GaF.js +1 -0
  147. package/dist/interface/assets/close-Be7oB7d_.js +1 -0
  148. package/dist/interface/assets/close-circle-D7Jmhp_7.js +1 -0
  149. package/dist/interface/assets/cloud-check-zCGJxpWI.js +1 -0
  150. package/dist/interface/assets/cloudHandoff-CJzFH7CW.js +1 -0
  151. package/dist/interface/assets/config-6EiGxiYm.js +1 -0
  152. package/dist/interface/assets/content-copy-BcYlfuFc.js +1 -0
  153. package/dist/interface/assets/copy-DuY-M96E.js +1 -0
  154. package/dist/interface/assets/cube-scan-Cae03i_N.js +1 -0
  155. package/dist/interface/assets/database-refresh-outline-B3OEQFF7.js +1 -0
  156. package/dist/interface/assets/delete-BWgOAzKl.js +1 -0
  157. package/dist/interface/assets/dist-DmpuuM9s.js +1 -0
  158. package/dist/interface/assets/dots-vertical-Kby1GY8_.js +1 -0
  159. package/dist/interface/assets/download-C291Yq7I.js +1 -0
  160. package/dist/interface/assets/esm-B2TVBF3B.js +1 -0
  161. package/dist/interface/assets/esm-BEntuCG7.js +1 -0
  162. package/dist/interface/assets/esm-BRnyrFH8.js +1 -0
  163. package/dist/interface/assets/esm-CCwXzd_8.js +1 -0
  164. package/dist/interface/assets/esm-CEjwTsuD.js +1 -0
  165. package/dist/interface/assets/esm-CGGV9tC4.js +1 -0
  166. package/dist/interface/assets/esm-CI2tTOc5.js +1 -0
  167. package/dist/interface/assets/esm-CgxZmMYv.js +1 -0
  168. package/dist/interface/assets/esm-Csc6f5Fy.js +1 -0
  169. package/dist/interface/assets/esm-Qzx3d-Ie.js +1 -0
  170. package/dist/interface/assets/esm-a_w7mTdx.js +1 -0
  171. package/dist/interface/assets/esm-iKfsu7-H.js +1 -0
  172. package/dist/interface/assets/esm-ks5kvk_e.js +1 -0
  173. package/dist/interface/assets/esm-nJfTguKF.js +1 -0
  174. package/dist/interface/assets/eventLabels-idFWh3Y_.js +1 -0
  175. package/dist/interface/assets/eye-off-zGCIHKOK.js +1 -0
  176. package/dist/interface/assets/flowSchema-Dp_-p9WA.js +1 -0
  177. package/dist/interface/assets/help-circle-outline-DXFepDAG.js +1 -0
  178. package/dist/interface/assets/history-D-FlZdKD.js +1 -0
  179. package/dist/interface/assets/home-DPdzRxcM.js +1 -0
  180. package/dist/interface/assets/information-outline-ChOM9qgI.js +1 -0
  181. package/dist/interface/assets/intercomService-BQYzjnAi.js +1 -0
  182. package/dist/interface/assets/lan-DvYEO83l.js +1 -0
  183. package/dist/interface/assets/main-0oXl_8v7.js +3 -0
  184. package/dist/interface/assets/main-CdvAniEp.css +1 -0
  185. package/dist/interface/assets/microphone-D-T9xga4.js +1 -0
  186. package/dist/interface/assets/minus-4T4INuO4.js +1 -0
  187. package/dist/interface/assets/mqtt-ChvXxMhR.js +1 -0
  188. package/dist/interface/assets/native-CtfXrwj5.js +1 -0
  189. package/dist/interface/assets/native-JMtkOkIV.js +1 -0
  190. package/dist/interface/assets/nodeDefinitions-Dp8cnne1.js +1 -0
  191. package/dist/interface/assets/notifications-CbL-1oMs.js +1 -0
  192. package/dist/interface/assets/pause-DHqHYA3V.js +1 -0
  193. package/dist/interface/assets/pencil-outline-D-GmPf8M.js +1 -0
  194. package/dist/interface/assets/pencil-vACi-JzY.js +1 -0
  195. package/dist/interface/assets/plugin-Dt5Xetfz.js +1 -0
  196. package/dist/interface/assets/plugins-lsoAntRQ.js +1 -0
  197. package/dist/interface/assets/plus-BBUb8_uL.js +1 -0
  198. package/dist/interface/assets/plus-BJb7U4bN.js +1 -0
  199. package/dist/interface/assets/power-Dm_aNIz-.js +1 -0
  200. package/dist/interface/assets/radar-Dcvdz--e.js +1 -0
  201. package/dist/interface/assets/refresh-CO4F18Je.js +1 -0
  202. package/dist/interface/assets/restore-xRBt3Grb.js +1 -0
  203. package/dist/interface/assets/rooms-P8WrRIco.js +1 -0
  204. package/dist/interface/assets/round-alt-arrow-left-bold-CZHXzGS5.js +1 -0
  205. package/dist/interface/assets/search-D75YW08B.js +1 -0
  206. package/dist/interface/assets/sensorIcons-BRTtoaHX.js +1 -0
  207. package/dist/interface/assets/sensorSlots-BTj-IM7z.js +1 -0
  208. package/dist/interface/assets/sensors-Dxc7HgjZ.js +1 -0
  209. package/dist/interface/assets/server-DlK8gUoE.js +1 -0
  210. package/dist/interface/assets/settings-DDOgc5BX.js +1 -0
  211. package/dist/interface/assets/source-branch-DVHuYlkZ.js +1 -0
  212. package/dist/interface/assets/theme-BOppzzar.js +1 -0
  213. package/dist/interface/assets/trash-2-DDKPtl2x.js +1 -0
  214. package/dist/interface/assets/trash-can-outline-DVH3zgo0.js +1 -0
  215. package/dist/interface/assets/trash-fill-C_IJ4Vu2.js +1 -0
  216. package/dist/interface/assets/trash2-DY0XTaJD.js +1 -0
  217. package/dist/interface/assets/types-CeruGCb8.js +1 -0
  218. package/dist/interface/assets/types-J1Drrxo1.js +1 -0
  219. package/dist/interface/assets/types-U4AuTNLR.js +1 -0
  220. package/dist/interface/assets/undo-YRkBYCnf.js +1 -0
  221. package/dist/interface/assets/ungrouped-ING_JAuK.js +1 -0
  222. package/dist/interface/assets/updates-DtVp84Y0.js +1 -0
  223. package/dist/interface/assets/upload-2WcHRjTq.js +1 -0
  224. package/dist/interface/assets/upload-BiE7VzTj.js +1 -0
  225. package/dist/interface/assets/useAppVersion-BGgCk5GD.js +1 -0
  226. package/dist/interface/assets/useAssistantActions-C13O5EHU.js +1 -0
  227. package/dist/interface/assets/useBackupRestore-vrhmc9i-.js +1 -0
  228. package/dist/interface/assets/useCameraOptions-CI1baRmm.js +1 -0
  229. package/dist/interface/assets/useKeyboardInset-CvgJp091.js +1 -0
  230. package/dist/interface/assets/useLogsSocket-Bf0BI8ET.js +1 -0
  231. package/dist/interface/assets/useNavLayout-6zM1Y-7B.js +1 -0
  232. package/dist/interface/assets/usePermissions-DZitFsBQ.js +1 -0
  233. package/dist/interface/assets/usePluginUpdates-VZdpJ_Ax.js +1 -0
  234. package/dist/interface/assets/usePushRegistration-vcbMrTxZ.js +2 -0
  235. package/dist/interface/assets/useServerRestart-DrpuNbIu.js +1 -0
  236. package/dist/interface/assets/useStreamStatus-l3Pfk1H4.js +1 -0
  237. package/dist/interface/assets/useTabSwipe-BSpi25WV.js +1 -0
  238. package/dist/interface/assets/useUpdateChannel-kAl-5UNY.js +1 -0
  239. package/dist/interface/assets/useUpdatesSocket-CaFz_fEb.js +1 -0
  240. package/dist/interface/assets/useUserOptions-BKteXnmU.js +1 -0
  241. package/dist/interface/assets/variable-Cp8o-q8t.js +1 -0
  242. package/dist/interface/assets/vendor-Df81FCJz.js +29 -0
  243. package/dist/interface/assets/vendor-ace-QSsGUspX.js +1085 -0
  244. package/dist/interface/assets/vendor-cameraui-K1Nw4PvF.js +2326 -0
  245. package/dist/interface/assets/vendor-capacitor-t5EIN1GG.js +2 -0
  246. package/dist/interface/assets/vendor-chart-BiJYkx5_.js +3 -0
  247. package/dist/interface/assets/vendor-core-CJdfpB0I.js +1 -0
  248. package/dist/interface/assets/vendor-dnd-C1kMh9_t.js +2 -0
  249. package/dist/interface/assets/vendor-draggabilly-Cw1oJ6qc.js +1 -0
  250. package/dist/interface/assets/vendor-leaflet-OSZlONe5.js +1 -0
  251. package/dist/interface/assets/vendor-markdown-DTWiWKBj.js +14 -0
  252. package/dist/interface/assets/vendor-primevue-DoA2Rwcb.js +3942 -0
  253. package/dist/interface/assets/vendor-vueflow-DWU_IzGe.js +26 -0
  254. package/dist/interface/assets/walk-B8FNhXuj.js +1 -0
  255. package/dist/interface/assets/web-B98ahwoP.js +1 -0
  256. package/dist/interface/assets/web-BSsSrRZf.js +1 -0
  257. package/dist/interface/assets/web-BiNRDta4.js +1 -0
  258. package/dist/interface/assets/web-BjKL51lK-CZKmYhby.js +1 -0
  259. package/dist/interface/assets/web-BjtOcquy.js +1 -0
  260. package/dist/interface/assets/web-CkTE9nCG.js +1 -0
  261. package/dist/interface/assets/web-Cvogq5S5.js +1 -0
  262. package/dist/interface/assets/web-D-A4EBKj.js +1 -0
  263. package/dist/interface/assets/web-DVGMBduz.js +1 -0
  264. package/dist/interface/assets/web-SpWB7I6X.js +1 -0
  265. package/dist/interface/assets/web-k0ihT_qK.js +1 -0
  266. package/dist/interface/assets/web-ovBpm7Dl.js +1 -0
  267. package/dist/interface/assets/web-z5Xz9tOQ.js +1 -0
  268. package/dist/interface/assets/web-zfhkFevT.js +1 -0
  269. package/dist/interface/assets/webhook-DIjChTrs.js +1 -0
  270. package/dist/interface/assets/workbox-window.prod.es5-DRKojI0e.js +1 -0
  271. package/dist/interface/assets/zoom-in-rMB152Uz.js +1 -0
  272. package/dist/interface/ha/404-RtgPpD9N.js +60 -0
  273. package/dist/interface/ha/About-0PRv9bU0.js +55 -0
  274. package/dist/interface/ha/Assistant-DbwxVfpl.js +9853 -0
  275. package/dist/interface/ha/Automation-D3HomdH7.js +2029 -0
  276. package/dist/interface/ha/AutomationImport-nQUUvZcv.js +206 -0
  277. package/dist/interface/ha/AutomationStore-BXDD92wZ.js +336 -0
  278. package/dist/interface/ha/AutomationStoreDetail-BYeq7FID.js +122 -0
  279. package/dist/interface/ha/Automations-CJlGqmSP.js +424 -0
  280. package/dist/interface/ha/Camera-Ai4BxVh_.js +747 -0
  281. package/dist/interface/ha/CameraConsole-UMNOX3dE.js +52 -0
  282. package/dist/interface/ha/Cameras-BW-AEXYi.js +1971 -0
  283. package/dist/interface/ha/Camview-jikpVEE0.js +1336 -0
  284. package/dist/interface/ha/Config-BOxwBH2D.js +356 -0
  285. package/dist/interface/ha/ConfigActionAssistant--3iWk9sq.js +182 -0
  286. package/dist/interface/ha/ConfigActionCameraControl-DbVXWTeA.js +152 -0
  287. package/dist/interface/ha/ConfigActionHttp-Du3n2Yj0.js +134 -0
  288. package/dist/interface/ha/ConfigActionImageInput-BrJrTZTY.js +171 -0
  289. package/dist/interface/ha/ConfigActionMqtt-DZd1BNUt.js +81 -0
  290. package/dist/interface/ha/ConfigActionNotification-CJWW10gt.js +199 -0
  291. package/dist/interface/ha/ConfigActionNotificationControl-Bl41AVv1.js +111 -0
  292. package/dist/interface/ha/ConfigActionOutput-OTj7Lwgq.js +98 -0
  293. package/dist/interface/ha/ConfigActionPlugin-B790PEk0.js +172 -0
  294. package/dist/interface/ha/ConfigActionSensor-BG3jZxge.js +139 -0
  295. package/dist/interface/ha/ConfigActionSnapshot-fGmLl6jb.js +48 -0
  296. package/dist/interface/ha/ConfigActionVariable-CK3vYDsr.js +88 -0
  297. package/dist/interface/ha/ConfigConditionIfElse-DyFLGg3y.js +124 -0
  298. package/dist/interface/ha/ConfigConditionSensorState-BUTfeFO2.js +192 -0
  299. package/dist/interface/ha/ConfigConditionSwitch-iDG_ubif.js +128 -0
  300. package/dist/interface/ha/ConfigSensorValueInput-BmRIGUKB.js +170 -0
  301. package/dist/interface/ha/ConfigTriggerDetection-DyPQGt9M.js +241 -0
  302. package/dist/interface/ha/ConfigTriggerGeofence-CGE-bH_t.js +4888 -0
  303. package/dist/interface/ha/ConfigTriggerMqtt-CM3KZqBc.js +134 -0
  304. package/dist/interface/ha/ConfigTriggerSensor-DoHMcwP4.js +73 -0
  305. package/dist/interface/ha/ConfigTriggerSystem-BYKbW4Zr.js +192 -0
  306. package/dist/interface/ha/ConfigTriggerWebhook-5PBAadG8.js +94 -0
  307. package/dist/interface/ha/Console-BEXzl4p1.js +348 -0
  308. package/dist/interface/ha/CuiAutomationRunsDialog-DkK_ar5G.js +130 -0
  309. package/dist/interface/ha/CuiBottomSheet-CYNvQV4T.js +270 -0
  310. package/dist/interface/ha/CuiCameraRecordings-DYjecmE_.js +533 -0
  311. package/dist/interface/ha/CuiCameraShares-C0H60nZS.js +121 -0
  312. package/dist/interface/ha/CuiCameraTable-CQNMyBaq.js +169 -0
  313. package/dist/interface/ha/CuiChartTable-Bhv1p9zj.js +6801 -0
  314. package/dist/interface/ha/CuiConsole-DtXorGF5.js +244 -0
  315. package/dist/interface/ha/CuiDataTable-Cy8EjCk9.js +8732 -0
  316. package/dist/interface/ha/CuiList-DnW6Q5m2.js +57 -0
  317. package/dist/interface/ha/CuiPluginCard-B4SCUblV.js +769 -0
  318. package/dist/interface/ha/CuiPluginOAuthButton-BKg9SftQ.js +79 -0
  319. package/dist/interface/ha/CuiPluginTrustBadge-CEtUJhCJ.js +123 -0
  320. package/dist/interface/ha/CuiQRCode-gp-9hqyk.js +86 -0
  321. package/dist/interface/ha/CuiSchema-CYpr_dD7.js +963 -0
  322. package/dist/interface/ha/CuiTopNavbarItem-CM-1oPxf.js +140 -0
  323. package/dist/interface/ha/Faces-pa60ySng.js +1575 -0
  324. package/dist/interface/ha/FirstSteps-D42yZm7R.js +251 -0
  325. package/dist/interface/ha/Floorplan-BvE546pE.js +3657 -0
  326. package/dist/interface/ha/Instances-CAGCyfbB.js +680 -0
  327. package/dist/interface/ha/Logs-RB3Ba8WM.js +418 -0
  328. package/dist/interface/ha/Menu-hAnHu_jq.js +156 -0
  329. package/dist/interface/ha/Metrics-ChYTebkX.js +1448 -0
  330. package/dist/interface/ha/OAuthDeviceFlow-C05pH-9o.js +112 -0
  331. package/dist/interface/ha/Plugin-D7XwcXkW.js +1752 -0
  332. package/dist/interface/ha/PluginConsole-DphEIOlL.js +56 -0
  333. package/dist/interface/ha/PluginDetail-DfMl-yCl.js +805 -0
  334. package/dist/interface/ha/PluginSearch-BPN4Opg5.js +462 -0
  335. package/dist/interface/ha/PluginUpdateProgress-ByJ0R5sW.js +34 -0
  336. package/dist/interface/ha/Plugins-BhKmjjNn.js +692 -0
  337. package/dist/interface/ha/RecentEventsFilter-BkLMlGVJ.js +78 -0
  338. package/dist/interface/ha/Recordings-BaU7M1OW.js +1836 -0
  339. package/dist/interface/ha/SensorEdit-DWxcCJ0F.js +1462 -0
  340. package/dist/interface/ha/SensorHistory-DuA9E9wT.js +54 -0
  341. package/dist/interface/ha/Sensors-CVpIHcgG.js +1402 -0
  342. package/dist/interface/ha/Settings-BO2eBGEn.js +218 -0
  343. package/dist/interface/ha/SettingsAccount-BQZZfoSM.js +971 -0
  344. package/dist/interface/ha/SettingsAppearance-B_yGl89u.js +220 -0
  345. package/dist/interface/ha/SettingsAssistant-kMOixl9g.js +2025 -0
  346. package/dist/interface/ha/SettingsBackup-BpG-W4j-.js +556 -0
  347. package/dist/interface/ha/SettingsList-Btnkzu94.js +40 -0
  348. package/dist/interface/ha/SettingsMqtt-C4DX9cNC.js +526 -0
  349. package/dist/interface/ha/SettingsNotifications-DI6ImggH.js +529 -0
  350. package/dist/interface/ha/SettingsPermissions-BCDyCFcb.js +84 -0
  351. package/dist/interface/ha/SettingsRecordings-Bq5NkJhd.js +152 -0
  352. package/dist/interface/ha/SettingsRemote-CtncaPIA.js +1813 -0
  353. package/dist/interface/ha/SettingsSystem-BJXuA7xA.js +376 -0
  354. package/dist/interface/ha/SettingsUsers-BF0rDluv.js +379 -0
  355. package/dist/interface/ha/Terminal-kTCe2jP3.js +612 -0
  356. package/dist/interface/ha/Training-BM2Xb8Ef.js +1754 -0
  357. package/dist/interface/ha/Updates-Cv1EY_T0.js +343 -0
  358. package/dist/interface/ha/VariableInput-BO2zZu4N.js +52 -0
  359. package/dist/interface/ha/VersionsHandler-CRnT9-K7.js +216 -0
  360. package/dist/interface/ha/VirtualSensorCreate-6dVRxPjw.js +101 -0
  361. package/dist/interface/ha/Workers-MHia86lu.js +814 -0
  362. package/dist/interface/ha/ace-C9MtBQVV.js +13236 -0
  363. package/dist/interface/ha/ace.config-CSXnaIzV.js +1429 -0
  364. package/dist/interface/ha/api-CH_Y8Hee.js +65411 -0
  365. package/dist/interface/ha/api-DylRa66V.js +29 -0
  366. package/dist/interface/ha/assistant-smRQYA6p.js +349 -0
  367. package/dist/interface/ha/auth-BXj5Fm6s.js +271 -0
  368. package/dist/interface/ha/automationBlueprint-DGjftXFC.js +250 -0
  369. package/dist/interface/ha/cameraui-cards.js +1 -1
  370. package/dist/interface/ha/cards-E0zw1UVg.js +13477 -0
  371. package/dist/interface/ha/config-dG_DA6XL.js +116 -0
  372. package/dist/interface/ha/dist-BQf9ANPx.js +3257 -0
  373. package/dist/interface/ha/dist-euRmladF.js +287 -0
  374. package/dist/interface/ha/eventLabels-B5GrM5jO.js +734 -0
  375. package/dist/interface/ha/intercomService-BtJ_zUNd.js +1400 -0
  376. package/dist/interface/ha/mqtt-CP3vVkRJ.js +56 -0
  377. package/dist/interface/ha/notifications-CZNwSXTg.js +159 -0
  378. package/dist/interface/ha/pinia-CVnHHb-s.js +7696 -0
  379. package/dist/interface/ha/plugins--eatOIaI.js +592 -0
  380. package/dist/interface/ha/protocol-BB4jdtUC-BhEwymva.js +789 -0
  381. package/dist/interface/ha/rooms-D5E6K75d.js +45 -0
  382. package/dist/interface/ha/server-D1BqEY7i.js +239 -0
  383. package/dist/interface/ha/types-CWogEoya.js +1073 -0
  384. package/dist/interface/ha/ungrouped-Ch4UX4dy.js +58 -0
  385. package/dist/interface/ha/updates-B48Owi1w.js +341 -0
  386. package/dist/interface/ha/useAppVersion-D95sKTJR.js +22 -0
  387. package/dist/interface/ha/useAssistantActions-kDwiO-u5.js +29 -0
  388. package/dist/interface/ha/useKeyboardInset-C2R51vsC.js +27 -0
  389. package/dist/interface/ha/useLogsSocket-BzNWa2y2.js +59 -0
  390. package/dist/interface/ha/useNavLayout-228cwwqA.js +125 -0
  391. package/dist/interface/ha/usePermissions-CfA5x7Df.js +72 -0
  392. package/dist/interface/ha/useServerRestart-B0c40zs5.js +23 -0
  393. package/dist/interface/ha/useTabSwipe-CfZg5hWj.js +45 -0
  394. package/dist/interface/ha/useUpdateChannel-DQxI7FrD.js +22 -0
  395. package/dist/interface/ha/useUpdatesSocket-B8LqBBd3.js +34 -0
  396. package/dist/interface/ha/useUserOptions-dZf6ejlz.js +15 -0
  397. package/dist/interface/ha/walk-CsSXaeJw.js +33 -0
  398. package/dist/interface/index.html +71 -72
  399. package/dist/interface/sw.js +1 -1
  400. package/dist/interface/workbox-5f52ac45.js +1 -0
  401. package/dist/server/package.json +23 -23
  402. package/dist/server/requirements.txt +2 -2
  403. package/dist/server/src/_camera_ui_tools/camera_ui_sdk/__init__.py +22 -0
  404. package/dist/server/src/_camera_ui_tools/camera_ui_sdk/camera/config.py +12 -0
  405. package/dist/server/src/_camera_ui_tools/camera_ui_sdk/camera/device.py +5 -1
  406. package/dist/server/src/_camera_ui_tools/camera_ui_sdk/internal/camera_config_internal.py +5 -1
  407. package/dist/server/src/_camera_ui_tools/camera_ui_sdk/manager/__init__.py +2 -1
  408. package/dist/server/src/_camera_ui_tools/camera_ui_sdk/plugin/__init__.py +10 -0
  409. package/dist/server/src/_camera_ui_tools/camera_ui_sdk/plugin/contract.py +6 -0
  410. package/dist/server/src/_camera_ui_tools/camera_ui_sdk/plugin/interfaces.py +92 -4
  411. package/dist/server/src/_camera_ui_tools/camera_ui_sdk/sensor/__init__.py +16 -0
  412. package/dist/server/src/_camera_ui_tools/camera_ui_sdk/sensor/base.py +4 -0
  413. package/dist/server/src/_camera_ui_tools/camera_ui_sdk/sensor/face_embedder.py +1 -1
  414. package/dist/server/src/_camera_ui_tools/camera_ui_sdk/sensor/object.py +3 -3
  415. package/dist/server/src/_camera_ui_tools/camera_ui_sdk/sensor/person_embedder.py +65 -0
  416. package/dist/server/src/_camera_ui_tools/camera_ui_sdk/sensor/segmenter.py +81 -0
  417. package/dist/server/src/api/controllers/plugins.controller.js +1 -0
  418. package/dist/server/src/api/controllers/plugins.controller.js.map +1 -1
  419. package/dist/server/src/api/controllers/workers.controller.d.ts +2 -2
  420. package/dist/server/src/api/controllers/workers.controller.js +8 -2
  421. package/dist/server/src/api/controllers/workers.controller.js.map +1 -1
  422. package/dist/server/src/api/database/index.d.ts +2 -1
  423. package/dist/server/src/api/database/index.js +31 -7
  424. package/dist/server/src/api/database/index.js.map +1 -1
  425. package/dist/server/src/api/database/migrations/v2-2-9.d.ts +3 -0
  426. package/dist/server/src/api/database/migrations/v2-2-9.js +28 -0
  427. package/dist/server/src/api/database/migrations/v2-2-9.js.map +1 -0
  428. package/dist/server/src/api/database/record-schemas.d.ts +4 -1
  429. package/dist/server/src/api/database/record-schemas.js +1 -0
  430. package/dist/server/src/api/database/record-schemas.js.map +1 -1
  431. package/dist/server/src/api/database/types.d.ts +21 -1
  432. package/dist/server/src/api/routes/workers.routes.js +4 -4
  433. package/dist/server/src/api/routes/workers.routes.js.map +1 -1
  434. package/dist/server/src/api/schemas/assistant.schema.d.ts +1 -1
  435. package/dist/server/src/api/schemas/cameras.schema.d.ts +178 -76
  436. package/dist/server/src/api/schemas/cameras.schema.js +26 -2
  437. package/dist/server/src/api/schemas/cameras.schema.js.map +1 -1
  438. package/dist/server/src/api/schemas/training.schema.d.ts +15 -3
  439. package/dist/server/src/api/schemas/training.schema.js +4 -1
  440. package/dist/server/src/api/schemas/training.schema.js.map +1 -1
  441. package/dist/server/src/api/schemas/users.schema.d.ts +12 -0
  442. package/dist/server/src/api/schemas/users.schema.js +4 -0
  443. package/dist/server/src/api/schemas/users.schema.js.map +1 -1
  444. package/dist/server/src/api/schemas/workers.schema.d.ts +5 -4
  445. package/dist/server/src/api/schemas/workers.schema.js +6 -3
  446. package/dist/server/src/api/schemas/workers.schema.js.map +1 -1
  447. package/dist/server/src/api/services/cameras.service.d.ts +3 -0
  448. package/dist/server/src/api/services/cameras.service.js +47 -2
  449. package/dist/server/src/api/services/cameras.service.js.map +1 -1
  450. package/dist/server/src/api/services/plugins.service.d.ts +1 -0
  451. package/dist/server/src/api/services/plugins.service.js +5 -1
  452. package/dist/server/src/api/services/plugins.service.js.map +1 -1
  453. package/dist/server/src/api/services/workers.service.d.ts +2 -0
  454. package/dist/server/src/api/services/workers.service.js +15 -0
  455. package/dist/server/src/api/services/workers.service.js.map +1 -1
  456. package/dist/server/src/api/types/index.d.ts +3 -2
  457. package/dist/server/src/api/websocket/nsp/worker-perf.js +2 -0
  458. package/dist/server/src/api/websocket/nsp/worker-perf.js.map +1 -1
  459. package/dist/server/src/api/websocket/types.d.ts +1 -0
  460. package/dist/server/src/assistant/pricing.js +39 -10
  461. package/dist/server/src/assistant/pricing.js.map +1 -1
  462. package/dist/server/src/assistant/providers.js +9 -1
  463. package/dist/server/src/assistant/providers.js.map +1 -1
  464. package/dist/server/src/assistant/search.d.ts +17 -0
  465. package/dist/server/src/assistant/search.js +10 -2
  466. package/dist/server/src/assistant/search.js.map +1 -1
  467. package/dist/server/src/assistant/tools/plugins.js +7 -3
  468. package/dist/server/src/assistant/tools/plugins.js.map +1 -1
  469. package/dist/server/src/assistant/types.d.ts +2 -0
  470. package/dist/server/src/automations/actions/plugin.js +5 -9
  471. package/dist/server/src/automations/actions/plugin.js.map +1 -1
  472. package/dist/server/src/automations/pluginMethodRegistry.d.ts +6 -0
  473. package/dist/server/src/automations/pluginMethodRegistry.js +39 -0
  474. package/dist/server/src/automations/pluginMethodRegistry.js.map +1 -1
  475. package/dist/server/src/automations/segment-picture.d.ts +16 -0
  476. package/dist/server/src/automations/segment-picture.js +152 -0
  477. package/dist/server/src/automations/segment-picture.js.map +1 -0
  478. package/dist/server/src/camera/decoder/detection-coordinator.d.ts +5 -2
  479. package/dist/server/src/camera/decoder/detection-coordinator.js +45 -22
  480. package/dist/server/src/camera/decoder/detection-coordinator.js.map +1 -1
  481. package/dist/server/src/camera/decoder/detection-pipeline.d.ts +30 -2
  482. package/dist/server/src/camera/decoder/detection-pipeline.js +81 -21
  483. package/dist/server/src/camera/decoder/detection-pipeline.js.map +1 -1
  484. package/dist/server/src/camera/decoder/event-manager.d.ts +13 -4
  485. package/dist/server/src/camera/decoder/event-manager.js +108 -128
  486. package/dist/server/src/camera/decoder/event-manager.js.map +1 -1
  487. package/dist/server/src/camera/decoder/event-trace.d.ts +41 -1
  488. package/dist/server/src/camera/decoder/event-trace.js +63 -8
  489. package/dist/server/src/camera/decoder/event-trace.js.map +1 -1
  490. package/dist/server/src/camera/decoder/face-tracks.d.ts +26 -0
  491. package/dist/server/src/camera/decoder/face-tracks.js +199 -0
  492. package/dist/server/src/camera/decoder/face-tracks.js.map +1 -0
  493. package/dist/server/src/camera/decoder/frame-scaler.d.ts +3 -1
  494. package/dist/server/src/camera/decoder/frame-scaler.js +36 -8
  495. package/dist/server/src/camera/decoder/frame-scaler.js.map +1 -1
  496. package/dist/server/src/camera/decoder/nvr-sink.d.ts +6 -0
  497. package/dist/server/src/camera/decoder/nvr-sink.js +1 -1
  498. package/dist/server/src/camera/decoder/nvr-sink.js.map +1 -1
  499. package/dist/server/src/camera/decoder/perf-tracker.d.ts +2 -0
  500. package/dist/server/src/camera/decoder/perf-tracker.js +4 -0
  501. package/dist/server/src/camera/decoder/perf-tracker.js.map +1 -1
  502. package/dist/server/src/camera/decoder/ptz/autotracker.d.ts +6 -1
  503. package/dist/server/src/camera/decoder/ptz/autotracker.js +107 -25
  504. package/dist/server/src/camera/decoder/ptz/autotracker.js.map +1 -1
  505. package/dist/server/src/camera/decoder/secondary-stage.d.ts +10 -8
  506. package/dist/server/src/camera/decoder/secondary-stage.js +145 -125
  507. package/dist/server/src/camera/decoder/secondary-stage.js.map +1 -1
  508. package/dist/server/src/camera/decoder/training-sink.d.ts +5 -2
  509. package/dist/server/src/camera/decoder/training-sink.js +30 -6
  510. package/dist/server/src/camera/decoder/training-sink.js.map +1 -1
  511. package/dist/server/src/camera/decoder/types.d.ts +6 -2
  512. package/dist/server/src/camera/decoder/types.js +4 -2
  513. package/dist/server/src/camera/decoder/types.js.map +1 -1
  514. package/dist/server/src/manager/coreManager.d.ts +2 -1
  515. package/dist/server/src/manager/coreManager.js +9 -2
  516. package/dist/server/src/manager/coreManager.js.map +1 -1
  517. package/dist/server/src/manager/trainingCandidateManager.d.ts +2 -1
  518. package/dist/server/src/manager/trainingCandidateManager.js +25 -3
  519. package/dist/server/src/manager/trainingCandidateManager.js.map +1 -1
  520. package/dist/server/src/manager/trainingSubmission.d.ts +5 -0
  521. package/dist/server/src/manager/trainingSubmission.js +73 -0
  522. package/dist/server/src/manager/trainingSubmission.js.map +1 -0
  523. package/dist/server/src/manager/types.d.ts +8 -2
  524. package/dist/server/src/manager/types.js.map +1 -1
  525. package/dist/server/src/plugins/runtime/node/proxy/coreManager.js +1 -1
  526. package/dist/server/src/plugins/runtime/node/proxy/coreManager.js.map +1 -1
  527. package/dist/server/src/plugins/runtime/python/proxy/camera_device.py +3 -0
  528. package/dist/server/src/plugins/runtime/python/proxy/core_manager.py +1 -1
  529. package/dist/server/src/plugins/runtime/python/proxy/sensor.py +2 -0
  530. package/dist/server/src/plugins/runtime/python/rpc/typings.py +1 -1
  531. package/dist/server/src/remote/api/routes/train.d.ts +44 -3
  532. package/dist/server/src/remote/api/routes/train.js +2 -2
  533. package/dist/server/src/remote/api/routes/train.js.map +1 -1
  534. package/dist/server/src/rpc/interfaces/core.d.ts +7 -3
  535. package/dist/server/src/rpc/interfaces/detection.d.ts +20 -3
  536. package/dist/server/src/rpc/server.d.ts +2 -0
  537. package/dist/server/src/rpc/server.js +8 -5
  538. package/dist/server/src/rpc/server.js.map +1 -1
  539. package/dist/server/src/sensors/registry.d.ts +3 -0
  540. package/dist/server/src/sensors/registry.js +44 -11
  541. package/dist/server/src/sensors/registry.js.map +1 -1
  542. package/dist/server/src/sensors/types.d.ts +1 -0
  543. package/dist/server/src/sensors/types.js +3 -0
  544. package/dist/server/src/sensors/types.js.map +1 -1
  545. package/dist/server/src/services/config/index.d.ts +1 -0
  546. package/dist/server/src/services/config/index.js +2 -0
  547. package/dist/server/src/services/config/index.js.map +1 -1
  548. package/dist/server/src/utils/image.d.ts +6 -0
  549. package/dist/server/src/utils/image.js +58 -22
  550. package/dist/server/src/utils/image.js.map +1 -1
  551. package/dist/server/src/workers/agent.js +2 -0
  552. package/dist/server/src/workers/agent.js.map +1 -1
  553. package/dist/server/src/workers/manager.d.ts +1 -0
  554. package/dist/server/src/workers/manager.js +22 -0
  555. package/dist/server/src/workers/manager.js.map +1 -1
  556. package/dist/server/src/workers/types.d.ts +5 -0
  557. package/dist/server/src/workers/types.js.map +1 -1
  558. package/npm-shrinkwrap.json +212 -171
  559. package/package.json +23 -23
  560. package/dist/interface/assets/404-C8EoOtBl.js +0 -1
  561. package/dist/interface/assets/About-Q7ZmOGgl.js +0 -1
  562. package/dist/interface/assets/Assistant-BQ6Ld-bt.css +0 -1
  563. package/dist/interface/assets/Assistant-DFLgklVe.js +0 -1
  564. package/dist/interface/assets/Automation-BSicfOGF.css +0 -1
  565. package/dist/interface/assets/Automation-D__qvx8c.js +0 -3
  566. package/dist/interface/assets/AutomationImport-CLQSdqg9.js +0 -2
  567. package/dist/interface/assets/AutomationStore-Dt6yTQDb.js +0 -2
  568. package/dist/interface/assets/AutomationStoreDetail-DqBrBhUI.js +0 -2
  569. package/dist/interface/assets/Automations-BH_7lYR7.js +0 -2
  570. package/dist/interface/assets/Camera-BW9ikKqh.css +0 -1
  571. package/dist/interface/assets/Camera-aquPHFwb.js +0 -2
  572. package/dist/interface/assets/CameraConsole-rhle_cfW.js +0 -7
  573. package/dist/interface/assets/Cameras-Bzy3P0xN.js +0 -651
  574. package/dist/interface/assets/Camview-Bri_T7Tq.css +0 -1
  575. package/dist/interface/assets/Camview-CjcQbtTl.js +0 -1
  576. package/dist/interface/assets/CertificateUpload-CWVu_52v.js +0 -1
  577. package/dist/interface/assets/Config-Dc1zKIPq.js +0 -2
  578. package/dist/interface/assets/ConfigActionAssistant-AfQfSqHZ.js +0 -1
  579. package/dist/interface/assets/ConfigActionCameraControl-BKQdHxqe.js +0 -1
  580. package/dist/interface/assets/ConfigActionDelay-B52HeJGb.js +0 -1
  581. package/dist/interface/assets/ConfigActionHttp-BP5gvpQc.js +0 -1
  582. package/dist/interface/assets/ConfigActionImageInput-DE2mSost.js +0 -1
  583. package/dist/interface/assets/ConfigActionMqtt-CYgnZjAE.js +0 -1
  584. package/dist/interface/assets/ConfigActionNotification-C3q53I4n.js +0 -1
  585. package/dist/interface/assets/ConfigActionNotificationControl-eDJ8r5ao.js +0 -1
  586. package/dist/interface/assets/ConfigActionOutput-DgYSYvy-.js +0 -1
  587. package/dist/interface/assets/ConfigActionPlugin-utolgAXk.js +0 -1
  588. package/dist/interface/assets/ConfigActionSensor-CmEKQPqs.js +0 -1
  589. package/dist/interface/assets/ConfigActionSnapshot-D7XucxVV.js +0 -1
  590. package/dist/interface/assets/ConfigActionVariable-C-Mjm3gr.js +0 -1
  591. package/dist/interface/assets/ConfigConditionIfElse-B24Rqb8y.js +0 -1
  592. package/dist/interface/assets/ConfigConditionSensorState-42-yFDmK.js +0 -1
  593. package/dist/interface/assets/ConfigConditionSwitch-DezH_nwm.js +0 -1
  594. package/dist/interface/assets/ConfigConditionTime-Cg2Lwznd.js +0 -1
  595. package/dist/interface/assets/ConfigSensorValueInput-YHBDCTZm.js +0 -1
  596. package/dist/interface/assets/ConfigTriggerDetection-DxEpodjG.js +0 -1
  597. package/dist/interface/assets/ConfigTriggerGeofence-Bye8syxc.js +0 -1
  598. package/dist/interface/assets/ConfigTriggerManual-s_lEDTV9.js +0 -1
  599. package/dist/interface/assets/ConfigTriggerMqtt-DqdZj7TU.js +0 -1
  600. package/dist/interface/assets/ConfigTriggerSchedule-Q559hn6g.js +0 -1
  601. package/dist/interface/assets/ConfigTriggerSensor-DIKkdbTF.js +0 -1
  602. package/dist/interface/assets/ConfigTriggerSystem-CwNZ4xEg.js +0 -1
  603. package/dist/interface/assets/ConfigTriggerWebhook-9ZC6X4mK.js +0 -1
  604. package/dist/interface/assets/Console-BqIDZ5vq.js +0 -1
  605. package/dist/interface/assets/CuiAssistantConversation-BmBhwrNh.css +0 -1
  606. package/dist/interface/assets/CuiAssistantConversation-CM7KdaX2.js +0 -5
  607. package/dist/interface/assets/CuiAutomationRunsDialog-CVjCLiVW.js +0 -1
  608. package/dist/interface/assets/CuiBottomSheet-CFohFiO2.js +0 -1
  609. package/dist/interface/assets/CuiBottomSheet-D75L0Zny.js +0 -1
  610. package/dist/interface/assets/CuiCameraPipCard-BQKk4fxY.css +0 -1
  611. package/dist/interface/assets/CuiCameraPipCard-eiJjYZ5W.js +0 -1
  612. package/dist/interface/assets/CuiCameraRecordings-DdEWkJrO.js +0 -1
  613. package/dist/interface/assets/CuiCameraShares-8mtgFsQ_.js +0 -1
  614. package/dist/interface/assets/CuiCameraTable-CmCT-XQF.js +0 -2
  615. package/dist/interface/assets/CuiCameraTable-DHrKoD9s.js +0 -1
  616. package/dist/interface/assets/CuiChartTable-v8sGY6PD.js +0 -1
  617. package/dist/interface/assets/CuiConsole-DYV-FUE0.js +0 -5
  618. package/dist/interface/assets/CuiDataTable-C0gsYYpg.js +0 -1
  619. package/dist/interface/assets/CuiLightControl-CFIwBj3C.js +0 -1
  620. package/dist/interface/assets/CuiList-9TVV8SB6.js +0 -1
  621. package/dist/interface/assets/CuiMarkdownContent-BYBQX_aF.js +0 -1
  622. package/dist/interface/assets/CuiMarkdownContent-DTAm-EDR.js +0 -1
  623. package/dist/interface/assets/CuiPluginCard-DEfqwUhQ.js +0 -2
  624. package/dist/interface/assets/CuiPluginCategoryChip-DhnIBJHa.js +0 -1
  625. package/dist/interface/assets/CuiPluginOAuthButton-DAuzNRAA.js +0 -2
  626. package/dist/interface/assets/CuiPluginTrustBadge-Bz710WwC.js +0 -1
  627. package/dist/interface/assets/CuiQRCode-B8-4GHSY.js +0 -1
  628. package/dist/interface/assets/CuiSchema-C_CHuKuf.js +0 -1
  629. package/dist/interface/assets/CuiTopNavbarItem-CNEnOPSh.js +0 -1
  630. package/dist/interface/assets/Faces-DRHMrrxh.js +0 -1
  631. package/dist/interface/assets/FirstSteps-Ci2Iqbe2.js +0 -1
  632. package/dist/interface/assets/Floorplan-Ci63Zd8W.css +0 -1
  633. package/dist/interface/assets/Floorplan-CqWIbDbh.js +0 -1
  634. package/dist/interface/assets/Instances-gzKFKB1l.js +0 -1
  635. package/dist/interface/assets/Logs-DL1yw_Pe.js +0 -6
  636. package/dist/interface/assets/Menu-C0GQ63aj.js +0 -1
  637. package/dist/interface/assets/Metrics-BYnnb7M0.js +0 -12
  638. package/dist/interface/assets/Metrics-DsHBab6t.css +0 -1
  639. package/dist/interface/assets/OAuthDeviceFlow-Zd6r9IHU.js +0 -1
  640. package/dist/interface/assets/Plugin-DJIrYUnZ.js +0 -1
  641. package/dist/interface/assets/Plugin-Qr_Q_Qfi.css +0 -1
  642. package/dist/interface/assets/PluginConsole-ag0jPZQ_.js +0 -7
  643. package/dist/interface/assets/PluginDetail-DmElwUuV.js +0 -2
  644. package/dist/interface/assets/PluginSchema-CxUujnVs.js +0 -1
  645. package/dist/interface/assets/PluginSearch-B-2zH2Xy.js +0 -1
  646. package/dist/interface/assets/PluginSearch-BqzngVRL.js +0 -2
  647. package/dist/interface/assets/PluginUpdateProgress-CFut0RAe.js +0 -1
  648. package/dist/interface/assets/Plugins-ZFcB_j6v.js +0 -1
  649. package/dist/interface/assets/RecentEventsFilter-CqeHhECT.js +0 -1
  650. package/dist/interface/assets/Recordings-BEKAn6QK.css +0 -1
  651. package/dist/interface/assets/Recordings-BJrtW9eG.js +0 -1
  652. package/dist/interface/assets/SensorEdit-Bi0gg-CL.js +0 -1
  653. package/dist/interface/assets/SensorHistory-q0UR3qMG.js +0 -1
  654. package/dist/interface/assets/Sensors-C_InhcHA.js +0 -2
  655. package/dist/interface/assets/Settings-Cv38rGWn.js +0 -1
  656. package/dist/interface/assets/Settings-D7495zbV.css +0 -1
  657. package/dist/interface/assets/SettingsAccount-B05739dn.js +0 -1
  658. package/dist/interface/assets/SettingsAccount-gm28wtbl.js +0 -1
  659. package/dist/interface/assets/SettingsAppearance-DdyYUgmV.js +0 -1
  660. package/dist/interface/assets/SettingsAppearance-DwUknDPV.js +0 -1
  661. package/dist/interface/assets/SettingsAssistant-ChHfkUKk.js +0 -1
  662. package/dist/interface/assets/SettingsBackup-DKwlPQhD.js +0 -1
  663. package/dist/interface/assets/SettingsList-D6hqnvUo.js +0 -1
  664. package/dist/interface/assets/SettingsMqtt-C01fgLY0.js +0 -1
  665. package/dist/interface/assets/SettingsNotifications-D47cIquQ.js +0 -1
  666. package/dist/interface/assets/SettingsPermissions-BeTCTrAf.js +0 -1
  667. package/dist/interface/assets/SettingsRecordings-mwL6Dalr.js +0 -1
  668. package/dist/interface/assets/SettingsRemote-CtP6Gz9C.css +0 -1
  669. package/dist/interface/assets/SettingsRemote-MhaShPIf.js +0 -2
  670. package/dist/interface/assets/SettingsSystem-BXnzXgqm.js +0 -2
  671. package/dist/interface/assets/SettingsUsers-D2mVlJin.js +0 -1
  672. package/dist/interface/assets/Terminal-C1UoXDRK.js +0 -4
  673. package/dist/interface/assets/Training-A5ynOv_l.js +0 -1
  674. package/dist/interface/assets/Training-C-ToeAl4.css +0 -1
  675. package/dist/interface/assets/Updates-kS_Tm8HD.js +0 -2
  676. package/dist/interface/assets/VariableInput-D9PfI8Ut.js +0 -1
  677. package/dist/interface/assets/VariableSuggestions-DArWzQuE.js +0 -1
  678. package/dist/interface/assets/VersionsHandler-BZVMpB2v.js +0 -7
  679. package/dist/interface/assets/VirtualSensorCreate-Cz-QFo4R.js +0 -1
  680. package/dist/interface/assets/Workers-2sc4VMi9.js +0 -2
  681. package/dist/interface/assets/Workers-DH59zE1C.css +0 -1
  682. package/dist/interface/assets/account-DwW7pBOb.js +0 -1
  683. package/dist/interface/assets/ace-DzzM-RlW.js +0 -1
  684. package/dist/interface/assets/ace.config-CCyX_Ohk.js +0 -1
  685. package/dist/interface/assets/alert-circle-BdUVAt1B.js +0 -1
  686. package/dist/interface/assets/alert-outline-IRxYbw0j.js +0 -1
  687. package/dist/interface/assets/api-CGfJbsTz.css +0 -2
  688. package/dist/interface/assets/api-CzwdnGAH.js +0 -1
  689. package/dist/interface/assets/api-DOpXVpef.js +0 -4
  690. package/dist/interface/assets/arrow-left-Bk-ZrOVr.js +0 -1
  691. package/dist/interface/assets/assistant-hGCAgv-f.js +0 -1
  692. package/dist/interface/assets/assistantModels-BsSgRsws.js +0 -1
  693. package/dist/interface/assets/auth-By-S-WEr.js +0 -1
  694. package/dist/interface/assets/automations-vwIwb2PQ.js +0 -1
  695. package/dist/interface/assets/back-filled-D-X19YMO.js +0 -1
  696. package/dist/interface/assets/bell-ring-DreEHgoT.js +0 -1
  697. package/dist/interface/assets/brain-DuDAg544.js +0 -1
  698. package/dist/interface/assets/cameraSources-BMhXvtFt.js +0 -1
  699. package/dist/interface/assets/cctv-DM-C_8_6.js +0 -1
  700. package/dist/interface/assets/check-circle-Bevuw8-0.js +0 -1
  701. package/dist/interface/assets/check-circle-outline-aMxkvksr.js +0 -1
  702. package/dist/interface/assets/chevron-down-CCFn9Z56.js +0 -1
  703. package/dist/interface/assets/chevron-up-CSImUM3_.js +0 -1
  704. package/dist/interface/assets/clock-outline-DH3WIEJt.js +0 -1
  705. package/dist/interface/assets/close-CMxyM4v9.js +0 -1
  706. package/dist/interface/assets/close-circle-CfgJCZ9A.js +0 -1
  707. package/dist/interface/assets/cloud-check-CbdFLIdR.js +0 -1
  708. package/dist/interface/assets/cloudHandoff-BnzjCpJ2.js +0 -1
  709. package/dist/interface/assets/config-BQxEwrK6.js +0 -1
  710. package/dist/interface/assets/content-copy-Bz49QPOI.js +0 -1
  711. package/dist/interface/assets/copy-DA6QQHRt.js +0 -1
  712. package/dist/interface/assets/cube-scan-IiH8zwm2.js +0 -1
  713. package/dist/interface/assets/database-refresh-outline-CIUDpcuq.js +0 -1
  714. package/dist/interface/assets/delete-Btu-UVx9.js +0 -1
  715. package/dist/interface/assets/dist-D_qWDAKp.js +0 -1
  716. package/dist/interface/assets/dots-vertical-D496SIss.js +0 -1
  717. package/dist/interface/assets/download-BSC7lwq_.js +0 -1
  718. package/dist/interface/assets/esm-Bn9gXwX4.js +0 -1
  719. package/dist/interface/assets/esm-BzM6y2-F.js +0 -1
  720. package/dist/interface/assets/esm-CP3JWrtj.js +0 -1
  721. package/dist/interface/assets/esm-CjAXkqCf.js +0 -1
  722. package/dist/interface/assets/esm-Cqxk-j1S.js +0 -1
  723. package/dist/interface/assets/esm-DFHd3JNU.js +0 -1
  724. package/dist/interface/assets/esm-DfMLJtug.js +0 -1
  725. package/dist/interface/assets/esm-DhDrpq7a.js +0 -1
  726. package/dist/interface/assets/esm-DvhM-SOd.js +0 -1
  727. package/dist/interface/assets/esm-G63bqygQ.js +0 -1
  728. package/dist/interface/assets/esm-Gn-Y59hU.js +0 -1
  729. package/dist/interface/assets/esm-KJSOz2vj.js +0 -1
  730. package/dist/interface/assets/esm-Ryfc94Tm.js +0 -1
  731. package/dist/interface/assets/esm-rSfI5Poy.js +0 -1
  732. package/dist/interface/assets/eventIcons-UQutPG3p.js +0 -1
  733. package/dist/interface/assets/eventLabels-BsPoPWS9.js +0 -1
  734. package/dist/interface/assets/eye-off-CSU0U8g7.js +0 -1
  735. package/dist/interface/assets/eye-off-outline-DCxLRGo_.js +0 -1
  736. package/dist/interface/assets/flowSchema-BPq6iHks.js +0 -1
  737. package/dist/interface/assets/help-circle-outline-Cr_yNhPi.js +0 -1
  738. package/dist/interface/assets/history-anuCbp1T.js +0 -1
  739. package/dist/interface/assets/home-N3bDR1vX.js +0 -1
  740. package/dist/interface/assets/information-outline-CMWIvLNB.js +0 -1
  741. package/dist/interface/assets/intercomService-CXcjcPa9.js +0 -1
  742. package/dist/interface/assets/lan-CYXjdk7L.js +0 -1
  743. package/dist/interface/assets/main-By4L33Im.js +0 -3
  744. package/dist/interface/assets/main-DVa5U7UB.css +0 -1
  745. package/dist/interface/assets/microphone-BB2pATI_.js +0 -1
  746. package/dist/interface/assets/minus-BCp3ZNKO.js +0 -1
  747. package/dist/interface/assets/mqtt-DE1KQ8Td.js +0 -1
  748. package/dist/interface/assets/native-CZJE8bTs.js +0 -1
  749. package/dist/interface/assets/native-DKZwialB.js +0 -1
  750. package/dist/interface/assets/nodeDefinitions-ByrqsENY.js +0 -1
  751. package/dist/interface/assets/notifications-BCyiD-TP.js +0 -1
  752. package/dist/interface/assets/pause-BQlxwAW2.js +0 -1
  753. package/dist/interface/assets/pencil-CDsNnEXi.js +0 -1
  754. package/dist/interface/assets/pencil-outline-CIQL5Kui.js +0 -1
  755. package/dist/interface/assets/plugin-DSEMkqaK.js +0 -1
  756. package/dist/interface/assets/plugins-BJPCV1YL.js +0 -1
  757. package/dist/interface/assets/plus-Bp4q9G7S.js +0 -1
  758. package/dist/interface/assets/plus-CySoovdr.js +0 -1
  759. package/dist/interface/assets/power-WmBLDR0-.js +0 -1
  760. package/dist/interface/assets/radar-CyYAmume.js +0 -1
  761. package/dist/interface/assets/refresh-CHTA3jVN.js +0 -1
  762. package/dist/interface/assets/restore-C8RNM5yX.js +0 -1
  763. package/dist/interface/assets/rooms-Dr4yiakO.js +0 -1
  764. package/dist/interface/assets/round-alt-arrow-left-bold-Gh5mi_yR.js +0 -1
  765. package/dist/interface/assets/search-BajCVmOI.js +0 -1
  766. package/dist/interface/assets/sensorIcons-DofElQ3w.js +0 -1
  767. package/dist/interface/assets/sensorSlots-D2KJGvPw.js +0 -1
  768. package/dist/interface/assets/sensors-3llrL7s3.js +0 -1
  769. package/dist/interface/assets/server-Dw5DD473.js +0 -1
  770. package/dist/interface/assets/settings-DnksaK7m.js +0 -1
  771. package/dist/interface/assets/source-branch-CzqIPffP.js +0 -1
  772. package/dist/interface/assets/theme-C85LJhOY.js +0 -1
  773. package/dist/interface/assets/trash-2-DJeEhHf4.js +0 -1
  774. package/dist/interface/assets/trash-can-outline-DrT6iw7I.js +0 -1
  775. package/dist/interface/assets/trash-fill-Bb_-UicM.js +0 -1
  776. package/dist/interface/assets/trash2-Dsl8gfxq.js +0 -1
  777. package/dist/interface/assets/types-CPhy0Ovw.js +0 -1
  778. package/dist/interface/assets/types-DYKmSGl4.js +0 -1
  779. package/dist/interface/assets/types-i1kTodPP.js +0 -1
  780. package/dist/interface/assets/undo-DoqJW-k7.js +0 -1
  781. package/dist/interface/assets/ungrouped-BlheTJCh.css +0 -1
  782. package/dist/interface/assets/ungrouped-C2CWO39a.js +0 -1
  783. package/dist/interface/assets/updates-C2LhMkNR.js +0 -1
  784. package/dist/interface/assets/upload-C3w1XH-o.js +0 -1
  785. package/dist/interface/assets/upload-DtIcwiNC.js +0 -1
  786. package/dist/interface/assets/useAppVersion-DkazK9Vu.js +0 -1
  787. package/dist/interface/assets/useAssistantActions-BZP6NL18.js +0 -1
  788. package/dist/interface/assets/useBackupRestore-DMQW_CVC.js +0 -1
  789. package/dist/interface/assets/useCameraOptions-DnI0xLrX.js +0 -1
  790. package/dist/interface/assets/useKeyboardInset-Cr7SxKGN.js +0 -1
  791. package/dist/interface/assets/useLogsSocket-C3Y8S0Ar.js +0 -1
  792. package/dist/interface/assets/useNavLayout-C9pcDuVP.js +0 -1
  793. package/dist/interface/assets/usePermissions-CCTxwXF0.js +0 -1
  794. package/dist/interface/assets/usePluginUpdates-DBhLWAua.js +0 -1
  795. package/dist/interface/assets/usePushRegistration-CPRVdLAx.js +0 -2
  796. package/dist/interface/assets/useServerRestart-bScBLJ9r.js +0 -1
  797. package/dist/interface/assets/useStreamStatus-Bfh-WmLH.js +0 -1
  798. package/dist/interface/assets/useTabSwipe-C_QOrvSW.js +0 -1
  799. package/dist/interface/assets/useUpdateChannel-g0h_4c55.js +0 -1
  800. package/dist/interface/assets/useUpdatesSocket-CxrLRETs.js +0 -1
  801. package/dist/interface/assets/useUserOptions-DN0t3gBr.js +0 -1
  802. package/dist/interface/assets/variable-ywTlRfo5.js +0 -1
  803. package/dist/interface/assets/vendor-ace-CvEoip98.js +0 -1085
  804. package/dist/interface/assets/vendor-cameraui-B28aGJJD.js +0 -2326
  805. package/dist/interface/assets/vendor-capacitor-Bs_WzL0Q.js +0 -2
  806. package/dist/interface/assets/vendor-chart-DBK083Hu.js +0 -3
  807. package/dist/interface/assets/vendor-core-DIa0tPNH.js +0 -1
  808. package/dist/interface/assets/vendor-dnd-DGQLvX6Y.js +0 -2
  809. package/dist/interface/assets/vendor-draggabilly-D8CK6M-y.js +0 -1
  810. package/dist/interface/assets/vendor-gFkr2qsZ.js +0 -23
  811. package/dist/interface/assets/vendor-leaflet-DkAk6mAj.js +0 -1
  812. package/dist/interface/assets/vendor-markdown-qHIinIUE.js +0 -14
  813. package/dist/interface/assets/vendor-primevue-CZKUAkMA.js +0 -3942
  814. package/dist/interface/assets/vendor-vueflow-bSwRZ9X8.js +0 -26
  815. package/dist/interface/assets/web-BDNQnMmA.js +0 -1
  816. package/dist/interface/assets/web-B_9Qyt8E.js +0 -1
  817. package/dist/interface/assets/web-BhJykCtq.js +0 -1
  818. package/dist/interface/assets/web-BjKL51lK-wWFeZlLg.js +0 -1
  819. package/dist/interface/assets/web-C7nJwIOa.js +0 -1
  820. package/dist/interface/assets/web-CGJsJQDb.js +0 -1
  821. package/dist/interface/assets/web-CJwASxrl.js +0 -1
  822. package/dist/interface/assets/web-CLe0L31Y.js +0 -1
  823. package/dist/interface/assets/web-DEv1hAn1.js +0 -1
  824. package/dist/interface/assets/web-DaeQvsXT.js +0 -1
  825. package/dist/interface/assets/web-H3-wNunW.js +0 -1
  826. package/dist/interface/assets/web-LCdyqJq1.js +0 -1
  827. package/dist/interface/assets/web-XZWYTK65.js +0 -1
  828. package/dist/interface/assets/web-rU5hlxxW.js +0 -1
  829. package/dist/interface/assets/webhook-CWKf2Qxu.js +0 -1
  830. package/dist/interface/assets/workbox-window.prod.es5-BEYAF-e-.js +0 -1
  831. package/dist/interface/assets/zoom-in-CHkXAWHy.js +0 -1
  832. package/dist/interface/ha/404-tl2VQ3qy.js +0 -60
  833. package/dist/interface/ha/About-Cn7KOblU.js +0 -55
  834. package/dist/interface/ha/Assistant-DG2GGda0.js +0 -9361
  835. package/dist/interface/ha/Automation-D0_WpXx4.js +0 -2025
  836. package/dist/interface/ha/AutomationImport-DdC3dEaC.js +0 -206
  837. package/dist/interface/ha/AutomationStore-BrLn4oBx.js +0 -336
  838. package/dist/interface/ha/AutomationStoreDetail-DoppNsNc.js +0 -122
  839. package/dist/interface/ha/Automations-BaUJ9pVq.js +0 -424
  840. package/dist/interface/ha/Camera-Cj5ImvZG.js +0 -657
  841. package/dist/interface/ha/CameraConsole-7MhlS2VK.js +0 -52
  842. package/dist/interface/ha/Cameras-vHYz8uSO.js +0 -1969
  843. package/dist/interface/ha/Camview-BEglAx26.js +0 -1331
  844. package/dist/interface/ha/Config-CHiK--zP.js +0 -356
  845. package/dist/interface/ha/ConfigActionAssistant-DynduZYV.js +0 -182
  846. package/dist/interface/ha/ConfigActionCameraControl-BEYePssz.js +0 -152
  847. package/dist/interface/ha/ConfigActionHttp-h0vRWqZ5.js +0 -134
  848. package/dist/interface/ha/ConfigActionImageInput-B9GMZYAR.js +0 -171
  849. package/dist/interface/ha/ConfigActionMqtt-BEQpHBgf.js +0 -81
  850. package/dist/interface/ha/ConfigActionNotification-BYsz8_aS.js +0 -199
  851. package/dist/interface/ha/ConfigActionNotificationControl-BxmIWVE8.js +0 -111
  852. package/dist/interface/ha/ConfigActionOutput-DTOQSa1S.js +0 -98
  853. package/dist/interface/ha/ConfigActionPlugin-NOsUs3QI.js +0 -172
  854. package/dist/interface/ha/ConfigActionSensor-YWnsH_LV.js +0 -139
  855. package/dist/interface/ha/ConfigActionSnapshot-DHJnTvin.js +0 -48
  856. package/dist/interface/ha/ConfigActionVariable-C7UFnvW0.js +0 -88
  857. package/dist/interface/ha/ConfigConditionIfElse-CAHbuhH3.js +0 -124
  858. package/dist/interface/ha/ConfigConditionSensorState-CE6okUeb.js +0 -192
  859. package/dist/interface/ha/ConfigConditionSwitch-D5FULaTy.js +0 -128
  860. package/dist/interface/ha/ConfigSensorValueInput-mo6Gs_aZ.js +0 -170
  861. package/dist/interface/ha/ConfigTriggerDetection-Bt-OhHtM.js +0 -241
  862. package/dist/interface/ha/ConfigTriggerGeofence-Cw3jV5qD.js +0 -4888
  863. package/dist/interface/ha/ConfigTriggerMqtt-BXeV82UG.js +0 -134
  864. package/dist/interface/ha/ConfigTriggerSensor-Baqq--nJ.js +0 -73
  865. package/dist/interface/ha/ConfigTriggerSystem-braUVGzW.js +0 -192
  866. package/dist/interface/ha/ConfigTriggerWebhook-Dm45r-1C.js +0 -94
  867. package/dist/interface/ha/Console-q3TCsxYo.js +0 -348
  868. package/dist/interface/ha/CuiAutomationRunsDialog-DO6h5Tc4.js +0 -130
  869. package/dist/interface/ha/CuiBottomSheet-B7ldz0xi.js +0 -270
  870. package/dist/interface/ha/CuiCameraRecordings-Dq1Vh3qA.js +0 -551
  871. package/dist/interface/ha/CuiCameraShares-DBqcpevG.js +0 -121
  872. package/dist/interface/ha/CuiCameraTable-kL8rK-Uv.js +0 -169
  873. package/dist/interface/ha/CuiChartTable-BrFyiSt_.js +0 -6801
  874. package/dist/interface/ha/CuiConsole-DpeXZmJd.js +0 -244
  875. package/dist/interface/ha/CuiDataTable-BtqzIz0o.js +0 -8732
  876. package/dist/interface/ha/CuiList-CU2NJ1K6.js +0 -57
  877. package/dist/interface/ha/CuiPluginCard-lBLypaN4.js +0 -769
  878. package/dist/interface/ha/CuiPluginOAuthButton-CuGauZJA.js +0 -79
  879. package/dist/interface/ha/CuiPluginTrustBadge-BofBmRYc.js +0 -123
  880. package/dist/interface/ha/CuiQRCode-CdK9bwKb.js +0 -86
  881. package/dist/interface/ha/CuiSchema-DqkCLv9Y.js +0 -963
  882. package/dist/interface/ha/CuiTopNavbarItem-C2VZB7WV.js +0 -140
  883. package/dist/interface/ha/Faces-Crfi-75Z.js +0 -1441
  884. package/dist/interface/ha/FirstSteps-CKVG86pf.js +0 -251
  885. package/dist/interface/ha/Floorplan-CH9_-6hk.js +0 -3657
  886. package/dist/interface/ha/Instances-5gZdPPDA.js +0 -680
  887. package/dist/interface/ha/Logs-BkzEM70F.js +0 -418
  888. package/dist/interface/ha/Menu-BuT3_Ggx.js +0 -156
  889. package/dist/interface/ha/Metrics-BGrzu0bu.js +0 -1447
  890. package/dist/interface/ha/OAuthDeviceFlow-BEJtegqy.js +0 -112
  891. package/dist/interface/ha/Plugin-Bnp2jiC2.js +0 -1544
  892. package/dist/interface/ha/PluginConsole-CmsuPVMz.js +0 -56
  893. package/dist/interface/ha/PluginDetail-BCNx7vHr.js +0 -805
  894. package/dist/interface/ha/PluginSearch-DOdhuxgM.js +0 -462
  895. package/dist/interface/ha/PluginUpdateProgress-CwkKc8Tr.js +0 -34
  896. package/dist/interface/ha/Plugins-BrFowCdC.js +0 -692
  897. package/dist/interface/ha/RecentEventsFilter-9ZkDHD1g.js +0 -79
  898. package/dist/interface/ha/Recordings-BZhf39pJ.js +0 -1539
  899. package/dist/interface/ha/SensorEdit-Ds6WbN4A.js +0 -1462
  900. package/dist/interface/ha/SensorHistory-CoTIYTJx.js +0 -54
  901. package/dist/interface/ha/Sensors-DZ2MKdlh.js +0 -1400
  902. package/dist/interface/ha/Settings-D3JKr430.js +0 -218
  903. package/dist/interface/ha/SettingsAccount-cvtlSKZw.js +0 -971
  904. package/dist/interface/ha/SettingsAppearance-CaKuOHRu.js +0 -220
  905. package/dist/interface/ha/SettingsAssistant-vWVjAUqQ.js +0 -2025
  906. package/dist/interface/ha/SettingsBackup-CvzL_bVf.js +0 -556
  907. package/dist/interface/ha/SettingsList-C0Ec8x-H.js +0 -40
  908. package/dist/interface/ha/SettingsMqtt-COnq-QM5.js +0 -526
  909. package/dist/interface/ha/SettingsNotifications-BZ68bQzO.js +0 -529
  910. package/dist/interface/ha/SettingsPermissions-Jh0FuIF7.js +0 -84
  911. package/dist/interface/ha/SettingsRecordings-BPtNNpDa.js +0 -152
  912. package/dist/interface/ha/SettingsRemote-BXG8IYjf.js +0 -1810
  913. package/dist/interface/ha/SettingsSystem-_jHBUhws.js +0 -376
  914. package/dist/interface/ha/SettingsUsers-CzGj_RJN.js +0 -379
  915. package/dist/interface/ha/Terminal-BP3b8IBP.js +0 -612
  916. package/dist/interface/ha/Training-C2-6DgY0.js +0 -1699
  917. package/dist/interface/ha/Updates-BMZsEhmy.js +0 -343
  918. package/dist/interface/ha/VariableInput-DmI7skCD.js +0 -52
  919. package/dist/interface/ha/VersionsHandler-DJd4NqtD.js +0 -216
  920. package/dist/interface/ha/VirtualSensorCreate-DmtGYvAn.js +0 -101
  921. package/dist/interface/ha/Workers-2HTPHgKV.js +0 -765
  922. package/dist/interface/ha/ace-B3bPzJu9.js +0 -13236
  923. package/dist/interface/ha/ace.config-Dt55Nqby.js +0 -1429
  924. package/dist/interface/ha/api-BelbnLQO.js +0 -62346
  925. package/dist/interface/ha/api-sy4rqV2N.js +0 -29
  926. package/dist/interface/ha/assistant-C6KYXJfi.js +0 -349
  927. package/dist/interface/ha/auth-Da66mVEd.js +0 -271
  928. package/dist/interface/ha/automationBlueprint-hlqqM17r.js +0 -250
  929. package/dist/interface/ha/cards-BFRRfuM7.js +0 -13436
  930. package/dist/interface/ha/config-Cd7JNMpD.js +0 -116
  931. package/dist/interface/ha/dist-BIngHzHx.js +0 -287
  932. package/dist/interface/ha/dist-BybVYMVs.js +0 -3248
  933. package/dist/interface/ha/eventIcons-BFNUgeGr.js +0 -676
  934. package/dist/interface/ha/eventLabels-B4C1_4vT.js +0 -42
  935. package/dist/interface/ha/eye-off-outline-ACbzsGuK.js +0 -19
  936. package/dist/interface/ha/intercomService-B7HkLs6z.js +0 -1414
  937. package/dist/interface/ha/mqtt-UZfptWJl.js +0 -56
  938. package/dist/interface/ha/notifications-DTHM8fS-.js +0 -159
  939. package/dist/interface/ha/pinia-BokSpDzj.js +0 -7656
  940. package/dist/interface/ha/plugins-Bwp_GfaX.js +0 -592
  941. package/dist/interface/ha/protocol-BB4jdtUC-DW3jl2tV.js +0 -708
  942. package/dist/interface/ha/rooms-BvaD0r0q.js +0 -45
  943. package/dist/interface/ha/server-OWdtITVa.js +0 -239
  944. package/dist/interface/ha/types-BFJjyMZe.js +0 -1073
  945. package/dist/interface/ha/ungrouped-x00DHNHO.js +0 -1311
  946. package/dist/interface/ha/updates-C03Qf3Il.js +0 -341
  947. package/dist/interface/ha/useAppVersion-CrMd9CC9.js +0 -22
  948. package/dist/interface/ha/useAssistantActions-S1FrNe9b.js +0 -29
  949. package/dist/interface/ha/useKeyboardInset-DwUQCWHC.js +0 -27
  950. package/dist/interface/ha/useLogsSocket-C6k217mW.js +0 -59
  951. package/dist/interface/ha/useNavLayout-DhuQE024.js +0 -125
  952. package/dist/interface/ha/usePermissions-DaE_wFch.js +0 -72
  953. package/dist/interface/ha/useServerRestart-CYaen2r6.js +0 -23
  954. package/dist/interface/ha/useTabSwipe-DAmCFlgg.js +0 -45
  955. package/dist/interface/ha/useUpdateChannel-Dr1EoU2X.js +0 -22
  956. package/dist/interface/ha/useUpdatesSocket-C8Gmhemh.js +0 -34
  957. package/dist/interface/ha/useUserOptions-BB5wk3Bq.js +0 -15
  958. package/dist/interface/workbox-778a14ff.js +0 -1
@@ -1,4888 +0,0 @@
1
- import { o as e, t } from "./rolldown-runtime-CEFd7nDs.js";
2
- import { G as n, H as r, I as i, Jt as a, _t as o, kt as s, l as c, lt as l, ot as u, p as d, r as f, rt as p, u as m, v as h, x as g, y as _ } from "./runtime-core.esm-bundler-_TfE0DWz.js";
3
- import { t as ee } from "./message-D6dIy_hz.js";
4
- import { Dt as te, Et as ne, Ot as re, Si as ie, ir as ae, r as oe } from "./api-BelbnLQO.js";
5
- import { n as v } from "./vue-i18n-D5EAy78K.js";
6
- import { t as y } from "./button-BouAFgf5.js";
7
- import { t as se } from "./inputtext-C_ygnPrC.js";
8
- import { t as b } from "./select-DV7p2EDj.js";
9
- import { t as ce } from "./inputnumber-DZRwKgXr.js";
10
- import { t as x } from "./multiselect-BOb4ScAZ.js";
11
- import { t as le } from "./useUserOptions-BB5wk3Bq.js";
12
- import { t as S } from "./information-outline-DSSRyysT.js";
13
- import { t as ue } from "./copy-ApwNNqcL.js";
14
- //#region ~icons/mdi/crosshairs-gps
15
- var C = {
16
- viewBox: "0 0 24 24",
17
- width: "1.2em",
18
- height: "1.2em"
19
- };
20
- function w(e, t) {
21
- return r(), d("svg", C, [...t[0] ||= [m("path", {
22
- fill: "currentColor",
23
- d: "M12 8a4 4 0 0 1 4 4a4 4 0 0 1-4 4a4 4 0 0 1-4-4a4 4 0 0 1 4-4m-8.95 5H1v-2h2.05C3.5 6.83 6.83 3.5 11 3.05V1h2v2.05c4.17.45 7.5 3.78 7.95 7.95H23v2h-2.05c-.45 4.17-3.78 7.5-7.95 7.95V23h-2v-2.05C6.83 20.5 3.5 17.17 3.05 13M12 5a7 7 0 0 0-7 7a7 7 0 0 0 7 7a7 7 0 0 0 7-7a7 7 0 0 0-7-7"
24
- }, null, -1)]]);
25
- }
26
- var T = o({
27
- name: "mdi-crosshairs-gps",
28
- render: w
29
- }), E = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
30
- (function(n, r) {
31
- typeof e == "object" && t !== void 0 ? r(e) : typeof define == "function" && define.amd ? define(["exports"], r) : (n = typeof globalThis < "u" ? globalThis : n || self, r(n.leaflet = {}));
32
- })(e, (function(e) {
33
- var t = "1.9.4";
34
- function n(e) {
35
- for (var t, n = 1, r = arguments.length, i; n < r; n++) for (t in i = arguments[n], i) e[t] = i[t];
36
- return e;
37
- }
38
- var r = Object.create || (function() {
39
- function e() {}
40
- return function(t) {
41
- return e.prototype = t, new e();
42
- };
43
- })();
44
- function i(e, t) {
45
- var n = Array.prototype.slice;
46
- if (e.bind) return e.bind.apply(e, n.call(arguments, 1));
47
- var r = n.call(arguments, 2);
48
- return function() {
49
- return e.apply(t, r.length ? r.concat(n.call(arguments)) : arguments);
50
- };
51
- }
52
- var a = 0;
53
- function o(e) {
54
- return "_leaflet_id" in e || (e._leaflet_id = ++a), e._leaflet_id;
55
- }
56
- function s(e, t, n) {
57
- var r, i, a, o = function() {
58
- r = !1, i &&= (a.apply(n, i), !1);
59
- };
60
- return a = function() {
61
- r ? i = arguments : (e.apply(n, arguments), setTimeout(o, t), r = !0);
62
- }, a;
63
- }
64
- function c(e, t, n) {
65
- var r = t[1], i = t[0], a = r - i;
66
- return e === r && n ? e : ((e - i) % a + a) % a + i;
67
- }
68
- function l() {
69
- return !1;
70
- }
71
- function u(e, t) {
72
- if (t === !1) return e;
73
- var n = 10 ** (t === void 0 ? 6 : t);
74
- return Math.round(e * n) / n;
75
- }
76
- function d(e) {
77
- return e.trim ? e.trim() : e.replace(/^\s+|\s+$/g, "");
78
- }
79
- function f(e) {
80
- return d(e).split(/\s+/);
81
- }
82
- function p(e, t) {
83
- for (var n in Object.prototype.hasOwnProperty.call(e, "options") || (e.options = e.options ? r(e.options) : {}), t) e.options[n] = t[n];
84
- return e.options;
85
- }
86
- function m(e, t, n) {
87
- var r = [];
88
- for (var i in e) r.push(encodeURIComponent(n ? i.toUpperCase() : i) + "=" + encodeURIComponent(e[i]));
89
- return (!t || t.indexOf("?") === -1 ? "?" : "&") + r.join("&");
90
- }
91
- var h = /\{ *([\w_ -]+) *\}/g;
92
- function g(e, t) {
93
- return e.replace(h, function(e, n) {
94
- var r = t[n];
95
- if (r === void 0) throw Error("No value provided for variable " + e);
96
- return typeof r == "function" && (r = r(t)), r;
97
- });
98
- }
99
- var _ = Array.isArray || function(e) {
100
- return Object.prototype.toString.call(e) === "[object Array]";
101
- };
102
- function ee(e, t) {
103
- for (var n = 0; n < e.length; n++) if (e[n] === t) return n;
104
- return -1;
105
- }
106
- var te = "data:image/gif;base64,R0lGODlhAQABAAD/ACwAAAAAAQABAAACADs=";
107
- function ne(e) {
108
- return window["webkit" + e] || window["moz" + e] || window["ms" + e];
109
- }
110
- var re = 0;
111
- function ie(e) {
112
- var t = +/* @__PURE__ */ new Date(), n = Math.max(0, 16 - (t - re));
113
- return re = t + n, window.setTimeout(e, n);
114
- }
115
- var ae = window.requestAnimationFrame || ne("RequestAnimationFrame") || ie, oe = window.cancelAnimationFrame || ne("CancelAnimationFrame") || ne("CancelRequestAnimationFrame") || function(e) {
116
- window.clearTimeout(e);
117
- };
118
- function v(e, t, n) {
119
- if (n && ae === ie) e.call(t);
120
- else return ae.call(window, i(e, t));
121
- }
122
- function y(e) {
123
- e && oe.call(window, e);
124
- }
125
- var se = {
126
- __proto__: null,
127
- extend: n,
128
- create: r,
129
- bind: i,
130
- get lastId() {
131
- return a;
132
- },
133
- stamp: o,
134
- throttle: s,
135
- wrapNum: c,
136
- falseFn: l,
137
- formatNum: u,
138
- trim: d,
139
- splitWords: f,
140
- setOptions: p,
141
- getParamString: m,
142
- template: g,
143
- isArray: _,
144
- indexOf: ee,
145
- emptyImageUrl: te,
146
- requestFn: ae,
147
- cancelFn: oe,
148
- requestAnimFrame: v,
149
- cancelAnimFrame: y
150
- };
151
- function b() {}
152
- b.extend = function(e) {
153
- var t = function() {
154
- p(this), this.initialize && this.initialize.apply(this, arguments), this.callInitHooks();
155
- }, i = t.__super__ = this.prototype, a = r(i);
156
- for (var o in a.constructor = t, t.prototype = a, this) Object.prototype.hasOwnProperty.call(this, o) && o !== "prototype" && o !== "__super__" && (t[o] = this[o]);
157
- return e.statics && n(t, e.statics), e.includes && (ce(e.includes), n.apply(null, [a].concat(e.includes))), n(a, e), delete a.statics, delete a.includes, a.options && (a.options = i.options ? r(i.options) : {}, n(a.options, e.options)), a._initHooks = [], a.callInitHooks = function() {
158
- if (!this._initHooksCalled) {
159
- i.callInitHooks && i.callInitHooks.call(this), this._initHooksCalled = !0;
160
- for (var e = 0, t = a._initHooks.length; e < t; e++) a._initHooks[e].call(this);
161
- }
162
- }, t;
163
- }, b.include = function(e) {
164
- var t = this.prototype.options;
165
- return n(this.prototype, e), e.options && (this.prototype.options = t, this.mergeOptions(e.options)), this;
166
- }, b.mergeOptions = function(e) {
167
- return n(this.prototype.options, e), this;
168
- }, b.addInitHook = function(e) {
169
- var t = Array.prototype.slice.call(arguments, 1), n = typeof e == "function" ? e : function() {
170
- this[e].apply(this, t);
171
- };
172
- return this.prototype._initHooks = this.prototype._initHooks || [], this.prototype._initHooks.push(n), this;
173
- };
174
- function ce(e) {
175
- if (!(typeof L > "u" || !L || !L.Mixin)) {
176
- e = _(e) ? e : [e];
177
- for (var t = 0; t < e.length; t++) e[t] === L.Mixin.Events && console.warn("Deprecated include of L.Mixin.Events: this property will be removed in future releases, please inherit from L.Evented instead.", (/* @__PURE__ */ Error()).stack);
178
- }
179
- }
180
- var x = {
181
- on: function(e, t, n) {
182
- if (typeof e == "object") for (var r in e) this._on(r, e[r], t);
183
- else {
184
- e = f(e);
185
- for (var i = 0, a = e.length; i < a; i++) this._on(e[i], t, n);
186
- }
187
- return this;
188
- },
189
- off: function(e, t, n) {
190
- if (!arguments.length) delete this._events;
191
- else if (typeof e == "object") for (var r in e) this._off(r, e[r], t);
192
- else {
193
- e = f(e);
194
- for (var i = arguments.length === 1, a = 0, o = e.length; a < o; a++) i ? this._off(e[a]) : this._off(e[a], t, n);
195
- }
196
- return this;
197
- },
198
- _on: function(e, t, n, r) {
199
- if (typeof t != "function") {
200
- console.warn("wrong listener type: " + typeof t);
201
- return;
202
- }
203
- if (this._listens(e, t, n) === !1) {
204
- n === this && (n = void 0);
205
- var i = {
206
- fn: t,
207
- ctx: n
208
- };
209
- r && (i.once = !0), this._events = this._events || {}, this._events[e] = this._events[e] || [], this._events[e].push(i);
210
- }
211
- },
212
- _off: function(e, t, n) {
213
- var r, i, a;
214
- if (this._events && (r = this._events[e], r)) {
215
- if (arguments.length === 1) {
216
- if (this._firingCount) for (i = 0, a = r.length; i < a; i++) r[i].fn = l;
217
- delete this._events[e];
218
- return;
219
- }
220
- if (typeof t != "function") {
221
- console.warn("wrong listener type: " + typeof t);
222
- return;
223
- }
224
- var o = this._listens(e, t, n);
225
- if (o !== !1) {
226
- var s = r[o];
227
- this._firingCount && (s.fn = l, this._events[e] = r = r.slice()), r.splice(o, 1);
228
- }
229
- }
230
- },
231
- fire: function(e, t, r) {
232
- if (!this.listens(e, r)) return this;
233
- var i = n({}, t, {
234
- type: e,
235
- target: this,
236
- sourceTarget: t && t.sourceTarget || this
237
- });
238
- if (this._events) {
239
- var a = this._events[e];
240
- if (a) {
241
- this._firingCount = this._firingCount + 1 || 1;
242
- for (var o = 0, s = a.length; o < s; o++) {
243
- var c = a[o], l = c.fn;
244
- c.once && this.off(e, l, c.ctx), l.call(c.ctx || this, i);
245
- }
246
- this._firingCount--;
247
- }
248
- }
249
- return r && this._propagateEvent(i), this;
250
- },
251
- listens: function(e, t, n, r) {
252
- typeof e != "string" && console.warn("\"string\" type argument expected");
253
- var i = t;
254
- typeof t != "function" && (r = !!t, i = void 0, n = void 0);
255
- var a = this._events && this._events[e];
256
- if (a && a.length && this._listens(e, i, n) !== !1) return !0;
257
- if (r) {
258
- for (var o in this._eventParents) if (this._eventParents[o].listens(e, t, n, r)) return !0;
259
- }
260
- return !1;
261
- },
262
- _listens: function(e, t, n) {
263
- if (!this._events) return !1;
264
- var r = this._events[e] || [];
265
- if (!t) return !!r.length;
266
- n === this && (n = void 0);
267
- for (var i = 0, a = r.length; i < a; i++) if (r[i].fn === t && r[i].ctx === n) return i;
268
- return !1;
269
- },
270
- once: function(e, t, n) {
271
- if (typeof e == "object") for (var r in e) this._on(r, e[r], t, !0);
272
- else {
273
- e = f(e);
274
- for (var i = 0, a = e.length; i < a; i++) this._on(e[i], t, n, !0);
275
- }
276
- return this;
277
- },
278
- addEventParent: function(e) {
279
- return this._eventParents = this._eventParents || {}, this._eventParents[o(e)] = e, this;
280
- },
281
- removeEventParent: function(e) {
282
- return this._eventParents && delete this._eventParents[o(e)], this;
283
- },
284
- _propagateEvent: function(e) {
285
- for (var t in this._eventParents) this._eventParents[t].fire(e.type, n({
286
- layer: e.target,
287
- propagatedFrom: e.target
288
- }, e), !0);
289
- }
290
- };
291
- x.addEventListener = x.on, x.removeEventListener = x.clearAllEventListeners = x.off, x.addOneTimeEventListener = x.once, x.fireEvent = x.fire, x.hasEventListeners = x.listens;
292
- var le = b.extend(x);
293
- function S(e, t, n) {
294
- this.x = n ? Math.round(e) : e, this.y = n ? Math.round(t) : t;
295
- }
296
- var ue = Math.trunc || function(e) {
297
- return e > 0 ? Math.floor(e) : Math.ceil(e);
298
- };
299
- S.prototype = {
300
- clone: function() {
301
- return new S(this.x, this.y);
302
- },
303
- add: function(e) {
304
- return this.clone()._add(C(e));
305
- },
306
- _add: function(e) {
307
- return this.x += e.x, this.y += e.y, this;
308
- },
309
- subtract: function(e) {
310
- return this.clone()._subtract(C(e));
311
- },
312
- _subtract: function(e) {
313
- return this.x -= e.x, this.y -= e.y, this;
314
- },
315
- divideBy: function(e) {
316
- return this.clone()._divideBy(e);
317
- },
318
- _divideBy: function(e) {
319
- return this.x /= e, this.y /= e, this;
320
- },
321
- multiplyBy: function(e) {
322
- return this.clone()._multiplyBy(e);
323
- },
324
- _multiplyBy: function(e) {
325
- return this.x *= e, this.y *= e, this;
326
- },
327
- scaleBy: function(e) {
328
- return new S(this.x * e.x, this.y * e.y);
329
- },
330
- unscaleBy: function(e) {
331
- return new S(this.x / e.x, this.y / e.y);
332
- },
333
- round: function() {
334
- return this.clone()._round();
335
- },
336
- _round: function() {
337
- return this.x = Math.round(this.x), this.y = Math.round(this.y), this;
338
- },
339
- floor: function() {
340
- return this.clone()._floor();
341
- },
342
- _floor: function() {
343
- return this.x = Math.floor(this.x), this.y = Math.floor(this.y), this;
344
- },
345
- ceil: function() {
346
- return this.clone()._ceil();
347
- },
348
- _ceil: function() {
349
- return this.x = Math.ceil(this.x), this.y = Math.ceil(this.y), this;
350
- },
351
- trunc: function() {
352
- return this.clone()._trunc();
353
- },
354
- _trunc: function() {
355
- return this.x = ue(this.x), this.y = ue(this.y), this;
356
- },
357
- distanceTo: function(e) {
358
- e = C(e);
359
- var t = e.x - this.x, n = e.y - this.y;
360
- return Math.sqrt(t * t + n * n);
361
- },
362
- equals: function(e) {
363
- return e = C(e), e.x === this.x && e.y === this.y;
364
- },
365
- contains: function(e) {
366
- return e = C(e), Math.abs(e.x) <= Math.abs(this.x) && Math.abs(e.y) <= Math.abs(this.y);
367
- },
368
- toString: function() {
369
- return "Point(" + u(this.x) + ", " + u(this.y) + ")";
370
- }
371
- };
372
- function C(e, t, n) {
373
- return e instanceof S ? e : _(e) ? new S(e[0], e[1]) : e == null ? e : typeof e == "object" && "x" in e && "y" in e ? new S(e.x, e.y) : new S(e, t, n);
374
- }
375
- function w(e, t) {
376
- if (e) for (var n = t ? [e, t] : e, r = 0, i = n.length; r < i; r++) this.extend(n[r]);
377
- }
378
- w.prototype = {
379
- extend: function(e) {
380
- var t, n;
381
- if (!e) return this;
382
- if (e instanceof S || typeof e[0] == "number" || "x" in e) t = n = C(e);
383
- else if (e = T(e), t = e.min, n = e.max, !t || !n) return this;
384
- return !this.min && !this.max ? (this.min = t.clone(), this.max = n.clone()) : (this.min.x = Math.min(t.x, this.min.x), this.max.x = Math.max(n.x, this.max.x), this.min.y = Math.min(t.y, this.min.y), this.max.y = Math.max(n.y, this.max.y)), this;
385
- },
386
- getCenter: function(e) {
387
- return C((this.min.x + this.max.x) / 2, (this.min.y + this.max.y) / 2, e);
388
- },
389
- getBottomLeft: function() {
390
- return C(this.min.x, this.max.y);
391
- },
392
- getTopRight: function() {
393
- return C(this.max.x, this.min.y);
394
- },
395
- getTopLeft: function() {
396
- return this.min;
397
- },
398
- getBottomRight: function() {
399
- return this.max;
400
- },
401
- getSize: function() {
402
- return this.max.subtract(this.min);
403
- },
404
- contains: function(e) {
405
- var t, n;
406
- return e = typeof e[0] == "number" || e instanceof S ? C(e) : T(e), e instanceof w ? (t = e.min, n = e.max) : t = n = e, t.x >= this.min.x && n.x <= this.max.x && t.y >= this.min.y && n.y <= this.max.y;
407
- },
408
- intersects: function(e) {
409
- e = T(e);
410
- var t = this.min, n = this.max, r = e.min, i = e.max, a = i.x >= t.x && r.x <= n.x, o = i.y >= t.y && r.y <= n.y;
411
- return a && o;
412
- },
413
- overlaps: function(e) {
414
- e = T(e);
415
- var t = this.min, n = this.max, r = e.min, i = e.max, a = i.x > t.x && r.x < n.x, o = i.y > t.y && r.y < n.y;
416
- return a && o;
417
- },
418
- isValid: function() {
419
- return !!(this.min && this.max);
420
- },
421
- pad: function(e) {
422
- var t = this.min, n = this.max, r = Math.abs(t.x - n.x) * e, i = Math.abs(t.y - n.y) * e;
423
- return T(C(t.x - r, t.y - i), C(n.x + r, n.y + i));
424
- },
425
- equals: function(e) {
426
- return e ? (e = T(e), this.min.equals(e.getTopLeft()) && this.max.equals(e.getBottomRight())) : !1;
427
- }
428
- };
429
- function T(e, t) {
430
- return !e || e instanceof w ? e : new w(e, t);
431
- }
432
- function E(e, t) {
433
- if (e) for (var n = t ? [e, t] : e, r = 0, i = n.length; r < i; r++) this.extend(n[r]);
434
- }
435
- E.prototype = {
436
- extend: function(e) {
437
- var t = this._southWest, n = this._northEast, r, i;
438
- if (e instanceof O) r = e, i = e;
439
- else if (e instanceof E) {
440
- if (r = e._southWest, i = e._northEast, !r || !i) return this;
441
- } else return e ? this.extend(k(e) || D(e)) : this;
442
- return !t && !n ? (this._southWest = new O(r.lat, r.lng), this._northEast = new O(i.lat, i.lng)) : (t.lat = Math.min(r.lat, t.lat), t.lng = Math.min(r.lng, t.lng), n.lat = Math.max(i.lat, n.lat), n.lng = Math.max(i.lng, n.lng)), this;
443
- },
444
- pad: function(e) {
445
- var t = this._southWest, n = this._northEast, r = Math.abs(t.lat - n.lat) * e, i = Math.abs(t.lng - n.lng) * e;
446
- return new E(new O(t.lat - r, t.lng - i), new O(n.lat + r, n.lng + i));
447
- },
448
- getCenter: function() {
449
- return new O((this._southWest.lat + this._northEast.lat) / 2, (this._southWest.lng + this._northEast.lng) / 2);
450
- },
451
- getSouthWest: function() {
452
- return this._southWest;
453
- },
454
- getNorthEast: function() {
455
- return this._northEast;
456
- },
457
- getNorthWest: function() {
458
- return new O(this.getNorth(), this.getWest());
459
- },
460
- getSouthEast: function() {
461
- return new O(this.getSouth(), this.getEast());
462
- },
463
- getWest: function() {
464
- return this._southWest.lng;
465
- },
466
- getSouth: function() {
467
- return this._southWest.lat;
468
- },
469
- getEast: function() {
470
- return this._northEast.lng;
471
- },
472
- getNorth: function() {
473
- return this._northEast.lat;
474
- },
475
- contains: function(e) {
476
- e = typeof e[0] == "number" || e instanceof O || "lat" in e ? k(e) : D(e);
477
- var t = this._southWest, n = this._northEast, r, i;
478
- return e instanceof E ? (r = e.getSouthWest(), i = e.getNorthEast()) : r = i = e, r.lat >= t.lat && i.lat <= n.lat && r.lng >= t.lng && i.lng <= n.lng;
479
- },
480
- intersects: function(e) {
481
- e = D(e);
482
- var t = this._southWest, n = this._northEast, r = e.getSouthWest(), i = e.getNorthEast(), a = i.lat >= t.lat && r.lat <= n.lat, o = i.lng >= t.lng && r.lng <= n.lng;
483
- return a && o;
484
- },
485
- overlaps: function(e) {
486
- e = D(e);
487
- var t = this._southWest, n = this._northEast, r = e.getSouthWest(), i = e.getNorthEast(), a = i.lat > t.lat && r.lat < n.lat, o = i.lng > t.lng && r.lng < n.lng;
488
- return a && o;
489
- },
490
- toBBoxString: function() {
491
- return [
492
- this.getWest(),
493
- this.getSouth(),
494
- this.getEast(),
495
- this.getNorth()
496
- ].join(",");
497
- },
498
- equals: function(e, t) {
499
- return e ? (e = D(e), this._southWest.equals(e.getSouthWest(), t) && this._northEast.equals(e.getNorthEast(), t)) : !1;
500
- },
501
- isValid: function() {
502
- return !!(this._southWest && this._northEast);
503
- }
504
- };
505
- function D(e, t) {
506
- return e instanceof E ? e : new E(e, t);
507
- }
508
- function O(e, t, n) {
509
- if (isNaN(e) || isNaN(t)) throw Error("Invalid LatLng object: (" + e + ", " + t + ")");
510
- this.lat = +e, this.lng = +t, n !== void 0 && (this.alt = +n);
511
- }
512
- O.prototype = {
513
- equals: function(e, t) {
514
- return e ? (e = k(e), Math.max(Math.abs(this.lat - e.lat), Math.abs(this.lng - e.lng)) <= (t === void 0 ? 1e-9 : t)) : !1;
515
- },
516
- toString: function(e) {
517
- return "LatLng(" + u(this.lat, e) + ", " + u(this.lng, e) + ")";
518
- },
519
- distanceTo: function(e) {
520
- return j.distance(this, k(e));
521
- },
522
- wrap: function() {
523
- return j.wrapLatLng(this);
524
- },
525
- toBounds: function(e) {
526
- var t = 180 * e / 40075017, n = t / Math.cos(Math.PI / 180 * this.lat);
527
- return D([this.lat - t, this.lng - n], [this.lat + t, this.lng + n]);
528
- },
529
- clone: function() {
530
- return new O(this.lat, this.lng, this.alt);
531
- }
532
- };
533
- function k(e, t, n) {
534
- return e instanceof O ? e : _(e) && typeof e[0] != "object" ? e.length === 3 ? new O(e[0], e[1], e[2]) : e.length === 2 ? new O(e[0], e[1]) : null : e == null ? e : typeof e == "object" && "lat" in e ? new O(e.lat, "lng" in e ? e.lng : e.lon, e.alt) : t === void 0 ? null : new O(e, t, n);
535
- }
536
- var A = {
537
- latLngToPoint: function(e, t) {
538
- var n = this.projection.project(e), r = this.scale(t);
539
- return this.transformation._transform(n, r);
540
- },
541
- pointToLatLng: function(e, t) {
542
- var n = this.scale(t), r = this.transformation.untransform(e, n);
543
- return this.projection.unproject(r);
544
- },
545
- project: function(e) {
546
- return this.projection.project(e);
547
- },
548
- unproject: function(e) {
549
- return this.projection.unproject(e);
550
- },
551
- scale: function(e) {
552
- return 256 * 2 ** e;
553
- },
554
- zoom: function(e) {
555
- return Math.log(e / 256) / Math.LN2;
556
- },
557
- getProjectedBounds: function(e) {
558
- if (this.infinite) return null;
559
- var t = this.projection.bounds, n = this.scale(e);
560
- return new w(this.transformation.transform(t.min, n), this.transformation.transform(t.max, n));
561
- },
562
- infinite: !1,
563
- wrapLatLng: function(e) {
564
- var t = this.wrapLng ? c(e.lng, this.wrapLng, !0) : e.lng, n = this.wrapLat ? c(e.lat, this.wrapLat, !0) : e.lat, r = e.alt;
565
- return new O(n, t, r);
566
- },
567
- wrapLatLngBounds: function(e) {
568
- var t = e.getCenter(), n = this.wrapLatLng(t), r = t.lat - n.lat, i = t.lng - n.lng;
569
- if (r === 0 && i === 0) return e;
570
- var a = e.getSouthWest(), o = e.getNorthEast();
571
- return new E(new O(a.lat - r, a.lng - i), new O(o.lat - r, o.lng - i));
572
- }
573
- }, j = n({}, A, {
574
- wrapLng: [-180, 180],
575
- R: 6371e3,
576
- distance: function(e, t) {
577
- var n = Math.PI / 180, r = e.lat * n, i = t.lat * n, a = Math.sin((t.lat - e.lat) * n / 2), o = Math.sin((t.lng - e.lng) * n / 2), s = a * a + Math.cos(r) * Math.cos(i) * o * o, c = 2 * Math.atan2(Math.sqrt(s), Math.sqrt(1 - s));
578
- return this.R * c;
579
- }
580
- }), de = 6378137, fe = {
581
- R: de,
582
- MAX_LATITUDE: 85.0511287798,
583
- project: function(e) {
584
- var t = Math.PI / 180, n = this.MAX_LATITUDE, r = Math.max(Math.min(n, e.lat), -n), i = Math.sin(r * t);
585
- return new S(this.R * e.lng * t, this.R * Math.log((1 + i) / (1 - i)) / 2);
586
- },
587
- unproject: function(e) {
588
- var t = 180 / Math.PI;
589
- return new O((2 * Math.atan(Math.exp(e.y / this.R)) - Math.PI / 2) * t, e.x * t / this.R);
590
- },
591
- bounds: (function() {
592
- var e = de * Math.PI;
593
- return new w([-e, -e], [e, e]);
594
- })()
595
- };
596
- function pe(e, t, n, r) {
597
- if (_(e)) {
598
- this._a = e[0], this._b = e[1], this._c = e[2], this._d = e[3];
599
- return;
600
- }
601
- this._a = e, this._b = t, this._c = n, this._d = r;
602
- }
603
- pe.prototype = {
604
- transform: function(e, t) {
605
- return this._transform(e.clone(), t);
606
- },
607
- _transform: function(e, t) {
608
- return t ||= 1, e.x = t * (this._a * e.x + this._b), e.y = t * (this._c * e.y + this._d), e;
609
- },
610
- untransform: function(e, t) {
611
- return t ||= 1, new S((e.x / t - this._b) / this._a, (e.y / t - this._d) / this._c);
612
- }
613
- };
614
- function me(e, t, n, r) {
615
- return new pe(e, t, n, r);
616
- }
617
- var he = n({}, j, {
618
- code: "EPSG:3857",
619
- projection: fe,
620
- transformation: function() {
621
- var e = .5 / (Math.PI * fe.R);
622
- return me(e, .5, -e, .5);
623
- }()
624
- }), ge = n({}, he, { code: "EPSG:900913" });
625
- function _e(e) {
626
- return document.createElementNS("http://www.w3.org/2000/svg", e);
627
- }
628
- function ve(e, t) {
629
- for (var n = "", r = 0, i, a = e.length, o, s, c; r < a; r++) {
630
- for (s = e[r], i = 0, o = s.length; i < o; i++) c = s[i], n += (i ? "L" : "M") + c.x + " " + c.y;
631
- n += t ? P.svg ? "z" : "x" : "";
632
- }
633
- return n || "M0 0";
634
- }
635
- var ye = document.documentElement.style, be = "ActiveXObject" in window, xe = be && !document.addEventListener, Se = "msLaunchUri" in navigator && !("documentMode" in document), Ce = N("webkit"), we = N("android"), Te = N("android 2") || N("android 3"), Ee = parseInt(/WebKit\/([0-9]+)|$/.exec(navigator.userAgent)[1], 10), De = we && N("Google") && Ee < 537 && !("AudioNode" in window), Oe = !!window.opera, ke = !Se && N("chrome"), Ae = N("gecko") && !Ce && !Oe && !be, je = !ke && N("safari"), Me = N("phantom"), Ne = "OTransition" in ye, Pe = navigator.platform.indexOf("Win") === 0, M = be && "transition" in ye, Fe = "WebKitCSSMatrix" in window && "m11" in new window.WebKitCSSMatrix() && !Te, Ie = "MozPerspective" in ye, Le = !window.L_DISABLE_3D && (M || Fe || Ie) && !Ne && !Me, Re = typeof orientation < "u" || N("mobile"), ze = Re && Ce, Be = Re && Fe, Ve = !window.PointerEvent && window.MSPointerEvent, He = !!(window.PointerEvent || Ve), Ue = "ontouchstart" in window || !!window.TouchEvent, We = !window.L_NO_TOUCH && (Ue || He), Ge = Re && Oe, Ke = Re && Ae, qe = (window.devicePixelRatio || window.screen.deviceXDPI / window.screen.logicalXDPI) > 1, Je = function() {
636
- var e = !1;
637
- try {
638
- var t = Object.defineProperty({}, "passive", { get: function() {
639
- e = !0;
640
- } });
641
- window.addEventListener("testPassiveEventSupport", l, t), window.removeEventListener("testPassiveEventSupport", l, t);
642
- } catch {}
643
- return e;
644
- }(), Ye = function() {
645
- return !!document.createElement("canvas").getContext;
646
- }(), Xe = !!(document.createElementNS && _e("svg").createSVGRect), Ze = !!Xe && (function() {
647
- var e = document.createElement("div");
648
- return e.innerHTML = "<svg/>", (e.firstChild && e.firstChild.namespaceURI) === "http://www.w3.org/2000/svg";
649
- })(), Qe = !Xe && function() {
650
- try {
651
- var e = document.createElement("div");
652
- e.innerHTML = "<v:shape adj=\"1\"/>";
653
- var t = e.firstChild;
654
- return t.style.behavior = "url(#default#VML)", t && typeof t.adj == "object";
655
- } catch {
656
- return !1;
657
- }
658
- }(), $e = navigator.platform.indexOf("Mac") === 0, et = navigator.platform.indexOf("Linux") === 0;
659
- function N(e) {
660
- return navigator.userAgent.toLowerCase().indexOf(e) >= 0;
661
- }
662
- var P = {
663
- ie: be,
664
- ielt9: xe,
665
- edge: Se,
666
- webkit: Ce,
667
- android: we,
668
- android23: Te,
669
- androidStock: De,
670
- opera: Oe,
671
- chrome: ke,
672
- gecko: Ae,
673
- safari: je,
674
- phantom: Me,
675
- opera12: Ne,
676
- win: Pe,
677
- ie3d: M,
678
- webkit3d: Fe,
679
- gecko3d: Ie,
680
- any3d: Le,
681
- mobile: Re,
682
- mobileWebkit: ze,
683
- mobileWebkit3d: Be,
684
- msPointer: Ve,
685
- pointer: He,
686
- touch: We,
687
- touchNative: Ue,
688
- mobileOpera: Ge,
689
- mobileGecko: Ke,
690
- retina: qe,
691
- passiveEvents: Je,
692
- canvas: Ye,
693
- svg: Xe,
694
- vml: Qe,
695
- inlineSvg: Ze,
696
- mac: $e,
697
- linux: et
698
- }, tt = P.msPointer ? "MSPointerDown" : "pointerdown", nt = P.msPointer ? "MSPointerMove" : "pointermove", rt = P.msPointer ? "MSPointerUp" : "pointerup", it = P.msPointer ? "MSPointerCancel" : "pointercancel", at = {
699
- touchstart: tt,
700
- touchmove: nt,
701
- touchend: rt,
702
- touchcancel: it
703
- }, ot = {
704
- touchstart: gt,
705
- touchmove: ht,
706
- touchend: ht,
707
- touchcancel: ht
708
- }, st = {}, ct = !1;
709
- function lt(e, t, n) {
710
- return t === "touchstart" && mt(), ot[t] ? (n = ot[t].bind(this, n), e.addEventListener(at[t], n, !1), n) : (console.warn("wrong event specified:", t), l);
711
- }
712
- function ut(e, t, n) {
713
- if (!at[t]) {
714
- console.warn("wrong event specified:", t);
715
- return;
716
- }
717
- e.removeEventListener(at[t], n, !1);
718
- }
719
- function dt(e) {
720
- st[e.pointerId] = e;
721
- }
722
- function ft(e) {
723
- st[e.pointerId] && (st[e.pointerId] = e);
724
- }
725
- function pt(e) {
726
- delete st[e.pointerId];
727
- }
728
- function mt() {
729
- ct ||= (document.addEventListener(tt, dt, !0), document.addEventListener(nt, ft, !0), document.addEventListener(rt, pt, !0), document.addEventListener(it, pt, !0), !0);
730
- }
731
- function ht(e, t) {
732
- if (t.pointerType !== (t.MSPOINTER_TYPE_MOUSE || "mouse")) {
733
- for (var n in t.touches = [], st) t.touches.push(st[n]);
734
- t.changedTouches = [t], e(t);
735
- }
736
- }
737
- function gt(e, t) {
738
- t.MSPOINTER_TYPE_TOUCH && t.pointerType === t.MSPOINTER_TYPE_TOUCH && G(t), ht(e, t);
739
- }
740
- function _t(e) {
741
- var t = {}, n, r;
742
- for (r in e) n = e[r], t[r] = n && n.bind ? n.bind(e) : n;
743
- return e = t, t.type = "dblclick", t.detail = 2, t.isTrusted = !1, t._simulated = !0, t;
744
- }
745
- var vt = 200;
746
- function yt(e, t) {
747
- e.addEventListener("dblclick", t);
748
- var n = 0, r;
749
- function i(e) {
750
- if (e.detail !== 1) {
751
- r = e.detail;
752
- return;
753
- }
754
- if (!(e.pointerType === "mouse" || e.sourceCapabilities && !e.sourceCapabilities.firesTouchEvents)) {
755
- var i = rn(e);
756
- if (!i.some(function(e) {
757
- return e instanceof HTMLLabelElement && e.attributes.for;
758
- }) || i.some(function(e) {
759
- return e instanceof HTMLInputElement || e instanceof HTMLSelectElement;
760
- })) {
761
- var a = Date.now();
762
- a - n <= vt ? (r++, r === 2 && t(_t(e))) : r = 1, n = a;
763
- }
764
- }
765
- }
766
- return e.addEventListener("click", i), {
767
- dblclick: t,
768
- simDblclick: i
769
- };
770
- }
771
- function bt(e, t) {
772
- e.removeEventListener("dblclick", t.dblclick), e.removeEventListener("click", t.simDblclick);
773
- }
774
- var xt = Nt([
775
- "transform",
776
- "webkitTransform",
777
- "OTransform",
778
- "MozTransform",
779
- "msTransform"
780
- ]), St = Nt([
781
- "webkitTransition",
782
- "transition",
783
- "OTransition",
784
- "MozTransition",
785
- "msTransition"
786
- ]), Ct = St === "webkitTransition" || St === "OTransition" ? St + "End" : "transitionend";
787
- function wt(e) {
788
- return typeof e == "string" ? document.getElementById(e) : e;
789
- }
790
- function Tt(e, t) {
791
- var n = e.style[t] || e.currentStyle && e.currentStyle[t];
792
- if ((!n || n === "auto") && document.defaultView) {
793
- var r = document.defaultView.getComputedStyle(e, null);
794
- n = r ? r[t] : null;
795
- }
796
- return n === "auto" ? null : n;
797
- }
798
- function F(e, t, n) {
799
- var r = document.createElement(e);
800
- return r.className = t || "", n && n.appendChild(r), r;
801
- }
802
- function I(e) {
803
- var t = e.parentNode;
804
- t && t.removeChild(e);
805
- }
806
- function Et(e) {
807
- for (; e.firstChild;) e.removeChild(e.firstChild);
808
- }
809
- function Dt(e) {
810
- var t = e.parentNode;
811
- t && t.lastChild !== e && t.appendChild(e);
812
- }
813
- function Ot(e) {
814
- var t = e.parentNode;
815
- t && t.firstChild !== e && t.insertBefore(e, t.firstChild);
816
- }
817
- function kt(e, t) {
818
- if (e.classList !== void 0) return e.classList.contains(t);
819
- var n = jt(e);
820
- return n.length > 0 && RegExp("(^|\\s)" + t + "(\\s|$)").test(n);
821
- }
822
- function R(e, t) {
823
- if (e.classList !== void 0) for (var n = f(t), r = 0, i = n.length; r < i; r++) e.classList.add(n[r]);
824
- else if (!kt(e, t)) {
825
- var a = jt(e);
826
- At(e, (a ? a + " " : "") + t);
827
- }
828
- }
829
- function z(e, t) {
830
- e.classList === void 0 ? At(e, d((" " + jt(e) + " ").replace(" " + t + " ", " "))) : e.classList.remove(t);
831
- }
832
- function At(e, t) {
833
- e.className.baseVal === void 0 ? e.className = t : e.className.baseVal = t;
834
- }
835
- function jt(e) {
836
- return e.correspondingElement && (e = e.correspondingElement), e.className.baseVal === void 0 ? e.className : e.className.baseVal;
837
- }
838
- function B(e, t) {
839
- "opacity" in e.style ? e.style.opacity = t : "filter" in e.style && Mt(e, t);
840
- }
841
- function Mt(e, t) {
842
- var n = !1, r = "DXImageTransform.Microsoft.Alpha";
843
- try {
844
- n = e.filters.item(r);
845
- } catch {
846
- if (t === 1) return;
847
- }
848
- t = Math.round(t * 100), n ? (n.Enabled = t !== 100, n.Opacity = t) : e.style.filter += " progid:" + r + "(opacity=" + t + ")";
849
- }
850
- function Nt(e) {
851
- for (var t = document.documentElement.style, n = 0; n < e.length; n++) if (e[n] in t) return e[n];
852
- return !1;
853
- }
854
- function Pt(e, t, n) {
855
- var r = t || new S(0, 0);
856
- e.style[xt] = (P.ie3d ? "translate(" + r.x + "px," + r.y + "px)" : "translate3d(" + r.x + "px," + r.y + "px,0)") + (n ? " scale(" + n + ")" : "");
857
- }
858
- function V(e, t) {
859
- e._leaflet_pos = t, P.any3d ? Pt(e, t) : (e.style.left = t.x + "px", e.style.top = t.y + "px");
860
- }
861
- function Ft(e) {
862
- return e._leaflet_pos || new S(0, 0);
863
- }
864
- var It, Lt, Rt;
865
- if ("onselectstart" in document) It = function() {
866
- H(window, "selectstart", G);
867
- }, Lt = function() {
868
- W(window, "selectstart", G);
869
- };
870
- else {
871
- var zt = Nt([
872
- "userSelect",
873
- "WebkitUserSelect",
874
- "OUserSelect",
875
- "MozUserSelect",
876
- "msUserSelect"
877
- ]);
878
- It = function() {
879
- if (zt) {
880
- var e = document.documentElement.style;
881
- Rt = e[zt], e[zt] = "none";
882
- }
883
- }, Lt = function() {
884
- zt && (document.documentElement.style[zt] = Rt, Rt = void 0);
885
- };
886
- }
887
- function Bt() {
888
- H(window, "dragstart", G);
889
- }
890
- function Vt() {
891
- W(window, "dragstart", G);
892
- }
893
- var Ht, Ut;
894
- function Wt(e) {
895
- for (; e.tabIndex === -1;) e = e.parentNode;
896
- e.style && (Gt(), Ht = e, Ut = e.style.outlineStyle, e.style.outlineStyle = "none", H(window, "keydown", Gt));
897
- }
898
- function Gt() {
899
- Ht && (Ht.style.outlineStyle = Ut, Ht = void 0, Ut = void 0, W(window, "keydown", Gt));
900
- }
901
- function Kt(e) {
902
- do
903
- e = e.parentNode;
904
- while ((!e.offsetWidth || !e.offsetHeight) && e !== document.body);
905
- return e;
906
- }
907
- function qt(e) {
908
- var t = e.getBoundingClientRect();
909
- return {
910
- x: t.width / e.offsetWidth || 1,
911
- y: t.height / e.offsetHeight || 1,
912
- boundingClientRect: t
913
- };
914
- }
915
- var Jt = {
916
- __proto__: null,
917
- TRANSFORM: xt,
918
- TRANSITION: St,
919
- TRANSITION_END: Ct,
920
- get: wt,
921
- getStyle: Tt,
922
- create: F,
923
- remove: I,
924
- empty: Et,
925
- toFront: Dt,
926
- toBack: Ot,
927
- hasClass: kt,
928
- addClass: R,
929
- removeClass: z,
930
- setClass: At,
931
- getClass: jt,
932
- setOpacity: B,
933
- testProp: Nt,
934
- setTransform: Pt,
935
- setPosition: V,
936
- getPosition: Ft,
937
- get disableTextSelection() {
938
- return It;
939
- },
940
- get enableTextSelection() {
941
- return Lt;
942
- },
943
- disableImageDrag: Bt,
944
- enableImageDrag: Vt,
945
- preventOutline: Wt,
946
- restoreOutline: Gt,
947
- getSizedParentNode: Kt,
948
- getScale: qt
949
- };
950
- function H(e, t, n, r) {
951
- if (t && typeof t == "object") for (var i in t) Zt(e, i, t[i], n);
952
- else {
953
- t = f(t);
954
- for (var a = 0, o = t.length; a < o; a++) Zt(e, t[a], n, r);
955
- }
956
- return this;
957
- }
958
- var U = "_leaflet_events";
959
- function W(e, t, n, r) {
960
- if (arguments.length === 1) Yt(e), delete e[U];
961
- else if (t && typeof t == "object") for (var i in t) Qt(e, i, t[i], n);
962
- else if (t = f(t), arguments.length === 2) Yt(e, function(e) {
963
- return ee(t, e) !== -1;
964
- });
965
- else for (var a = 0, o = t.length; a < o; a++) Qt(e, t[a], n, r);
966
- return this;
967
- }
968
- function Yt(e, t) {
969
- for (var n in e[U]) {
970
- var r = n.split(/\d/)[0];
971
- (!t || t(r)) && Qt(e, r, null, null, n);
972
- }
973
- }
974
- var Xt = {
975
- mouseenter: "mouseover",
976
- mouseleave: "mouseout",
977
- wheel: !("onwheel" in window) && "mousewheel"
978
- };
979
- function Zt(e, t, n, r) {
980
- var i = t + o(n) + (r ? "_" + o(r) : "");
981
- if (e[U] && e[U][i]) return this;
982
- var a = function(t) {
983
- return n.call(r || e, t || window.event);
984
- }, s = a;
985
- !P.touchNative && P.pointer && t.indexOf("touch") === 0 ? a = lt(e, t, a) : P.touch && t === "dblclick" ? a = yt(e, a) : "addEventListener" in e ? t === "touchstart" || t === "touchmove" || t === "wheel" || t === "mousewheel" ? e.addEventListener(Xt[t] || t, a, P.passiveEvents ? { passive: !1 } : !1) : t === "mouseenter" || t === "mouseleave" ? (a = function(t) {
986
- t ||= window.event, cn(e, t) && s(t);
987
- }, e.addEventListener(Xt[t], a, !1)) : e.addEventListener(t, s, !1) : e.attachEvent("on" + t, a), e[U] = e[U] || {}, e[U][i] = a;
988
- }
989
- function Qt(e, t, n, r, i) {
990
- i ||= t + o(n) + (r ? "_" + o(r) : "");
991
- var a = e[U] && e[U][i];
992
- if (!a) return this;
993
- !P.touchNative && P.pointer && t.indexOf("touch") === 0 ? ut(e, t, a) : P.touch && t === "dblclick" ? bt(e, a) : "removeEventListener" in e ? e.removeEventListener(Xt[t] || t, a, !1) : e.detachEvent("on" + t, a), e[U][i] = null;
994
- }
995
- function $t(e) {
996
- return e.stopPropagation ? e.stopPropagation() : e.originalEvent ? e.originalEvent._stopped = !0 : e.cancelBubble = !0, this;
997
- }
998
- function en(e) {
999
- return Zt(e, "wheel", $t), this;
1000
- }
1001
- function tn(e) {
1002
- return H(e, "mousedown touchstart dblclick contextmenu", $t), e._leaflet_disable_click = !0, this;
1003
- }
1004
- function G(e) {
1005
- return e.preventDefault ? e.preventDefault() : e.returnValue = !1, this;
1006
- }
1007
- function nn(e) {
1008
- return G(e), $t(e), this;
1009
- }
1010
- function rn(e) {
1011
- if (e.composedPath) return e.composedPath();
1012
- for (var t = [], n = e.target; n;) t.push(n), n = n.parentNode;
1013
- return t;
1014
- }
1015
- function an(e, t) {
1016
- if (!t) return new S(e.clientX, e.clientY);
1017
- var n = qt(t), r = n.boundingClientRect;
1018
- return new S((e.clientX - r.left) / n.x - t.clientLeft, (e.clientY - r.top) / n.y - t.clientTop);
1019
- }
1020
- var on = P.linux && P.chrome ? window.devicePixelRatio : P.mac ? window.devicePixelRatio * 3 : window.devicePixelRatio > 0 ? 2 * window.devicePixelRatio : 1;
1021
- function sn(e) {
1022
- return P.edge ? e.wheelDeltaY / 2 : e.deltaY && e.deltaMode === 0 ? -e.deltaY / on : e.deltaY && e.deltaMode === 1 ? -e.deltaY * 20 : e.deltaY && e.deltaMode === 2 ? -e.deltaY * 60 : e.deltaX || e.deltaZ ? 0 : e.wheelDelta ? (e.wheelDeltaY || e.wheelDelta) / 2 : e.detail && Math.abs(e.detail) < 32765 ? -e.detail * 20 : e.detail ? e.detail / -32765 * 60 : 0;
1023
- }
1024
- function cn(e, t) {
1025
- var n = t.relatedTarget;
1026
- if (!n) return !0;
1027
- try {
1028
- for (; n && n !== e;) n = n.parentNode;
1029
- } catch {
1030
- return !1;
1031
- }
1032
- return n !== e;
1033
- }
1034
- var ln = {
1035
- __proto__: null,
1036
- on: H,
1037
- off: W,
1038
- stopPropagation: $t,
1039
- disableScrollPropagation: en,
1040
- disableClickPropagation: tn,
1041
- preventDefault: G,
1042
- stop: nn,
1043
- getPropagationPath: rn,
1044
- getMousePosition: an,
1045
- getWheelDelta: sn,
1046
- isExternalTarget: cn,
1047
- addListener: H,
1048
- removeListener: W
1049
- }, un = le.extend({
1050
- run: function(e, t, n, r) {
1051
- this.stop(), this._el = e, this._inProgress = !0, this._duration = n || .25, this._easeOutPower = 1 / Math.max(r || .5, .2), this._startPos = Ft(e), this._offset = t.subtract(this._startPos), this._startTime = +/* @__PURE__ */ new Date(), this.fire("start"), this._animate();
1052
- },
1053
- stop: function() {
1054
- this._inProgress && (this._step(!0), this._complete());
1055
- },
1056
- _animate: function() {
1057
- this._animId = v(this._animate, this), this._step();
1058
- },
1059
- _step: function(e) {
1060
- var t = +/* @__PURE__ */ new Date() - this._startTime, n = this._duration * 1e3;
1061
- t < n ? this._runFrame(this._easeOut(t / n), e) : (this._runFrame(1), this._complete());
1062
- },
1063
- _runFrame: function(e, t) {
1064
- var n = this._startPos.add(this._offset.multiplyBy(e));
1065
- t && n._round(), V(this._el, n), this.fire("step");
1066
- },
1067
- _complete: function() {
1068
- y(this._animId), this._inProgress = !1, this.fire("end");
1069
- },
1070
- _easeOut: function(e) {
1071
- return 1 - (1 - e) ** this._easeOutPower;
1072
- }
1073
- }), K = le.extend({
1074
- options: {
1075
- crs: he,
1076
- center: void 0,
1077
- zoom: void 0,
1078
- minZoom: void 0,
1079
- maxZoom: void 0,
1080
- layers: [],
1081
- maxBounds: void 0,
1082
- renderer: void 0,
1083
- zoomAnimation: !0,
1084
- zoomAnimationThreshold: 4,
1085
- fadeAnimation: !0,
1086
- markerZoomAnimation: !0,
1087
- transform3DLimit: 8388608,
1088
- zoomSnap: 1,
1089
- zoomDelta: 1,
1090
- trackResize: !0
1091
- },
1092
- initialize: function(e, t) {
1093
- t = p(this, t), this._handlers = [], this._layers = {}, this._zoomBoundLayers = {}, this._sizeChanged = !0, this._initContainer(e), this._initLayout(), this._onResize = i(this._onResize, this), this._initEvents(), t.maxBounds && this.setMaxBounds(t.maxBounds), t.zoom !== void 0 && (this._zoom = this._limitZoom(t.zoom)), t.center && t.zoom !== void 0 && this.setView(k(t.center), t.zoom, { reset: !0 }), this.callInitHooks(), this._zoomAnimated = St && P.any3d && !P.mobileOpera && this.options.zoomAnimation, this._zoomAnimated && (this._createAnimProxy(), H(this._proxy, Ct, this._catchTransitionEnd, this)), this._addLayers(this.options.layers);
1094
- },
1095
- setView: function(e, t, r) {
1096
- return t = t === void 0 ? this._zoom : this._limitZoom(t), e = this._limitCenter(k(e), t, this.options.maxBounds), r ||= {}, this._stop(), this._loaded && !r.reset && r !== !0 && (r.animate !== void 0 && (r.zoom = n({ animate: r.animate }, r.zoom), r.pan = n({
1097
- animate: r.animate,
1098
- duration: r.duration
1099
- }, r.pan)), this._zoom === t ? this._tryAnimatedPan(e, r.pan) : this._tryAnimatedZoom && this._tryAnimatedZoom(e, t, r.zoom)) ? (clearTimeout(this._sizeTimer), this) : (this._resetView(e, t, r.pan && r.pan.noMoveStart), this);
1100
- },
1101
- setZoom: function(e, t) {
1102
- return this._loaded ? this.setView(this.getCenter(), e, { zoom: t }) : (this._zoom = e, this);
1103
- },
1104
- zoomIn: function(e, t) {
1105
- return e ||= P.any3d ? this.options.zoomDelta : 1, this.setZoom(this._zoom + e, t);
1106
- },
1107
- zoomOut: function(e, t) {
1108
- return e ||= P.any3d ? this.options.zoomDelta : 1, this.setZoom(this._zoom - e, t);
1109
- },
1110
- setZoomAround: function(e, t, n) {
1111
- var r = this.getZoomScale(t), i = this.getSize().divideBy(2), a = (e instanceof S ? e : this.latLngToContainerPoint(e)).subtract(i).multiplyBy(1 - 1 / r), o = this.containerPointToLatLng(i.add(a));
1112
- return this.setView(o, t, { zoom: n });
1113
- },
1114
- _getBoundsCenterZoom: function(e, t) {
1115
- t ||= {}, e = e.getBounds ? e.getBounds() : D(e);
1116
- var n = C(t.paddingTopLeft || t.padding || [0, 0]), r = C(t.paddingBottomRight || t.padding || [0, 0]), i = this.getBoundsZoom(e, !1, n.add(r));
1117
- if (i = typeof t.maxZoom == "number" ? Math.min(t.maxZoom, i) : i, i === Infinity) return {
1118
- center: e.getCenter(),
1119
- zoom: i
1120
- };
1121
- var a = r.subtract(n).divideBy(2), o = this.project(e.getSouthWest(), i), s = this.project(e.getNorthEast(), i);
1122
- return {
1123
- center: this.unproject(o.add(s).divideBy(2).add(a), i),
1124
- zoom: i
1125
- };
1126
- },
1127
- fitBounds: function(e, t) {
1128
- if (e = D(e), !e.isValid()) throw Error("Bounds are not valid.");
1129
- var n = this._getBoundsCenterZoom(e, t);
1130
- return this.setView(n.center, n.zoom, t);
1131
- },
1132
- fitWorld: function(e) {
1133
- return this.fitBounds([[-90, -180], [90, 180]], e);
1134
- },
1135
- panTo: function(e, t) {
1136
- return this.setView(e, this._zoom, { pan: t });
1137
- },
1138
- panBy: function(e, t) {
1139
- if (e = C(e).round(), t ||= {}, !e.x && !e.y) return this.fire("moveend");
1140
- if (t.animate !== !0 && !this.getSize().contains(e)) return this._resetView(this.unproject(this.project(this.getCenter()).add(e)), this.getZoom()), this;
1141
- if (this._panAnim || (this._panAnim = new un(), this._panAnim.on({
1142
- step: this._onPanTransitionStep,
1143
- end: this._onPanTransitionEnd
1144
- }, this)), t.noMoveStart || this.fire("movestart"), t.animate !== !1) {
1145
- R(this._mapPane, "leaflet-pan-anim");
1146
- var n = this._getMapPanePos().subtract(e).round();
1147
- this._panAnim.run(this._mapPane, n, t.duration || .25, t.easeLinearity);
1148
- } else this._rawPanBy(e), this.fire("move").fire("moveend");
1149
- return this;
1150
- },
1151
- flyTo: function(e, t, n) {
1152
- if (n ||= {}, n.animate === !1 || !P.any3d) return this.setView(e, t, n);
1153
- this._stop();
1154
- var r = this.project(this.getCenter()), i = this.project(e), a = this.getSize(), o = this._zoom;
1155
- e = k(e), t = t === void 0 ? o : t;
1156
- var s = Math.max(a.x, a.y), c = s * this.getZoomScale(o, t), l = i.distanceTo(r) || 1, u = 1.42, d = u * u;
1157
- function f(e) {
1158
- var t = e ? -1 : 1, n = e ? c : s, r = (c * c - s * s + t * d * d * l * l) / (2 * n * d * l), i = Math.sqrt(r * r + 1) - r;
1159
- return i < 1e-9 ? -18 : Math.log(i);
1160
- }
1161
- function p(e) {
1162
- return (Math.exp(e) - Math.exp(-e)) / 2;
1163
- }
1164
- function m(e) {
1165
- return (Math.exp(e) + Math.exp(-e)) / 2;
1166
- }
1167
- function h(e) {
1168
- return p(e) / m(e);
1169
- }
1170
- var g = f(0);
1171
- function _(e) {
1172
- return s * (m(g) / m(g + u * e));
1173
- }
1174
- function ee(e) {
1175
- return s * (m(g) * h(g + u * e) - p(g)) / d;
1176
- }
1177
- function te(e) {
1178
- return 1 - (1 - e) ** 1.5;
1179
- }
1180
- var ne = Date.now(), re = (f(1) - g) / u, ie = n.duration ? 1e3 * n.duration : 1e3 * re * .8;
1181
- function ae() {
1182
- var n = (Date.now() - ne) / ie, a = te(n) * re;
1183
- n <= 1 ? (this._flyToFrame = v(ae, this), this._move(this.unproject(r.add(i.subtract(r).multiplyBy(ee(a) / l)), o), this.getScaleZoom(s / _(a), o), { flyTo: !0 })) : this._move(e, t)._moveEnd(!0);
1184
- }
1185
- return this._moveStart(!0, n.noMoveStart), ae.call(this), this;
1186
- },
1187
- flyToBounds: function(e, t) {
1188
- var n = this._getBoundsCenterZoom(e, t);
1189
- return this.flyTo(n.center, n.zoom, t);
1190
- },
1191
- setMaxBounds: function(e) {
1192
- return e = D(e), this.listens("moveend", this._panInsideMaxBounds) && this.off("moveend", this._panInsideMaxBounds), e.isValid() ? (this.options.maxBounds = e, this._loaded && this._panInsideMaxBounds(), this.on("moveend", this._panInsideMaxBounds)) : (this.options.maxBounds = null, this);
1193
- },
1194
- setMinZoom: function(e) {
1195
- var t = this.options.minZoom;
1196
- return this.options.minZoom = e, this._loaded && t !== e && (this.fire("zoomlevelschange"), this.getZoom() < this.options.minZoom) ? this.setZoom(e) : this;
1197
- },
1198
- setMaxZoom: function(e) {
1199
- var t = this.options.maxZoom;
1200
- return this.options.maxZoom = e, this._loaded && t !== e && (this.fire("zoomlevelschange"), this.getZoom() > this.options.maxZoom) ? this.setZoom(e) : this;
1201
- },
1202
- panInsideBounds: function(e, t) {
1203
- this._enforcingBounds = !0;
1204
- var n = this.getCenter(), r = this._limitCenter(n, this._zoom, D(e));
1205
- return n.equals(r) || this.panTo(r, t), this._enforcingBounds = !1, this;
1206
- },
1207
- panInside: function(e, t) {
1208
- t ||= {};
1209
- var n = C(t.paddingTopLeft || t.padding || [0, 0]), r = C(t.paddingBottomRight || t.padding || [0, 0]), i = this.project(this.getCenter()), a = this.project(e), o = this.getPixelBounds(), s = T([o.min.add(n), o.max.subtract(r)]), c = s.getSize();
1210
- if (!s.contains(a)) {
1211
- this._enforcingBounds = !0;
1212
- var l = a.subtract(s.getCenter()), u = s.extend(a).getSize().subtract(c);
1213
- i.x += l.x < 0 ? -u.x : u.x, i.y += l.y < 0 ? -u.y : u.y, this.panTo(this.unproject(i), t), this._enforcingBounds = !1;
1214
- }
1215
- return this;
1216
- },
1217
- invalidateSize: function(e) {
1218
- if (!this._loaded) return this;
1219
- e = n({
1220
- animate: !1,
1221
- pan: !0
1222
- }, e === !0 ? { animate: !0 } : e);
1223
- var t = this.getSize();
1224
- this._sizeChanged = !0, this._lastCenter = null;
1225
- var r = this.getSize(), a = t.divideBy(2).round(), o = r.divideBy(2).round(), s = a.subtract(o);
1226
- return !s.x && !s.y ? this : (e.animate && e.pan ? this.panBy(s) : (e.pan && this._rawPanBy(s), this.fire("move"), e.debounceMoveend ? (clearTimeout(this._sizeTimer), this._sizeTimer = setTimeout(i(this.fire, this, "moveend"), 200)) : this.fire("moveend")), this.fire("resize", {
1227
- oldSize: t,
1228
- newSize: r
1229
- }));
1230
- },
1231
- stop: function() {
1232
- return this.setZoom(this._limitZoom(this._zoom)), this.options.zoomSnap || this.fire("viewreset"), this._stop();
1233
- },
1234
- locate: function(e) {
1235
- if (e = this._locateOptions = n({
1236
- timeout: 1e4,
1237
- watch: !1
1238
- }, e), !("geolocation" in navigator)) return this._handleGeolocationError({
1239
- code: 0,
1240
- message: "Geolocation not supported."
1241
- }), this;
1242
- var t = i(this._handleGeolocationResponse, this), r = i(this._handleGeolocationError, this);
1243
- return e.watch ? this._locationWatchId = navigator.geolocation.watchPosition(t, r, e) : navigator.geolocation.getCurrentPosition(t, r, e), this;
1244
- },
1245
- stopLocate: function() {
1246
- return navigator.geolocation && navigator.geolocation.clearWatch && navigator.geolocation.clearWatch(this._locationWatchId), this._locateOptions && (this._locateOptions.setView = !1), this;
1247
- },
1248
- _handleGeolocationError: function(e) {
1249
- if (this._container._leaflet_id) {
1250
- var t = e.code, n = e.message || (t === 1 ? "permission denied" : t === 2 ? "position unavailable" : "timeout");
1251
- this._locateOptions.setView && !this._loaded && this.fitWorld(), this.fire("locationerror", {
1252
- code: t,
1253
- message: "Geolocation error: " + n + "."
1254
- });
1255
- }
1256
- },
1257
- _handleGeolocationResponse: function(e) {
1258
- if (this._container._leaflet_id) {
1259
- var t = e.coords.latitude, n = e.coords.longitude, r = new O(t, n), i = r.toBounds(e.coords.accuracy * 2), a = this._locateOptions;
1260
- if (a.setView) {
1261
- var o = this.getBoundsZoom(i);
1262
- this.setView(r, a.maxZoom ? Math.min(o, a.maxZoom) : o);
1263
- }
1264
- var s = {
1265
- latlng: r,
1266
- bounds: i,
1267
- timestamp: e.timestamp
1268
- };
1269
- for (var c in e.coords) typeof e.coords[c] == "number" && (s[c] = e.coords[c]);
1270
- this.fire("locationfound", s);
1271
- }
1272
- },
1273
- addHandler: function(e, t) {
1274
- if (!t) return this;
1275
- var n = this[e] = new t(this);
1276
- return this._handlers.push(n), this.options[e] && n.enable(), this;
1277
- },
1278
- remove: function() {
1279
- if (this._initEvents(!0), this.options.maxBounds && this.off("moveend", this._panInsideMaxBounds), this._containerId !== this._container._leaflet_id) throw Error("Map container is being reused by another instance");
1280
- try {
1281
- delete this._container._leaflet_id, delete this._containerId;
1282
- } catch {
1283
- this._container._leaflet_id = void 0, this._containerId = void 0;
1284
- }
1285
- for (var e in this._locationWatchId !== void 0 && this.stopLocate(), this._stop(), I(this._mapPane), this._clearControlPos && this._clearControlPos(), this._resizeRequest &&= (y(this._resizeRequest), null), this._clearHandlers(), this._loaded && this.fire("unload"), this._layers) this._layers[e].remove();
1286
- for (e in this._panes) I(this._panes[e]);
1287
- return this._layers = [], this._panes = [], delete this._mapPane, delete this._renderer, this;
1288
- },
1289
- createPane: function(e, t) {
1290
- var n = F("div", "leaflet-pane" + (e ? " leaflet-" + e.replace("Pane", "") + "-pane" : ""), t || this._mapPane);
1291
- return e && (this._panes[e] = n), n;
1292
- },
1293
- getCenter: function() {
1294
- return this._checkIfLoaded(), this._lastCenter && !this._moved() ? this._lastCenter.clone() : this.layerPointToLatLng(this._getCenterLayerPoint());
1295
- },
1296
- getZoom: function() {
1297
- return this._zoom;
1298
- },
1299
- getBounds: function() {
1300
- var e = this.getPixelBounds();
1301
- return new E(this.unproject(e.getBottomLeft()), this.unproject(e.getTopRight()));
1302
- },
1303
- getMinZoom: function() {
1304
- return this.options.minZoom === void 0 ? this._layersMinZoom || 0 : this.options.minZoom;
1305
- },
1306
- getMaxZoom: function() {
1307
- return this.options.maxZoom === void 0 ? this._layersMaxZoom === void 0 ? Infinity : this._layersMaxZoom : this.options.maxZoom;
1308
- },
1309
- getBoundsZoom: function(e, t, n) {
1310
- e = D(e), n = C(n || [0, 0]);
1311
- var r = this.getZoom() || 0, i = this.getMinZoom(), a = this.getMaxZoom(), o = e.getNorthWest(), s = e.getSouthEast(), c = this.getSize().subtract(n), l = T(this.project(s, r), this.project(o, r)).getSize(), u = P.any3d ? this.options.zoomSnap : 1, d = c.x / l.x, f = c.y / l.y, p = t ? Math.max(d, f) : Math.min(d, f);
1312
- return r = this.getScaleZoom(p, r), u && (r = Math.round(r / (u / 100)) * (u / 100), r = t ? Math.ceil(r / u) * u : Math.floor(r / u) * u), Math.max(i, Math.min(a, r));
1313
- },
1314
- getSize: function() {
1315
- return (!this._size || this._sizeChanged) && (this._size = new S(this._container.clientWidth || 0, this._container.clientHeight || 0), this._sizeChanged = !1), this._size.clone();
1316
- },
1317
- getPixelBounds: function(e, t) {
1318
- var n = this._getTopLeftPoint(e, t);
1319
- return new w(n, n.add(this.getSize()));
1320
- },
1321
- getPixelOrigin: function() {
1322
- return this._checkIfLoaded(), this._pixelOrigin;
1323
- },
1324
- getPixelWorldBounds: function(e) {
1325
- return this.options.crs.getProjectedBounds(e === void 0 ? this.getZoom() : e);
1326
- },
1327
- getPane: function(e) {
1328
- return typeof e == "string" ? this._panes[e] : e;
1329
- },
1330
- getPanes: function() {
1331
- return this._panes;
1332
- },
1333
- getContainer: function() {
1334
- return this._container;
1335
- },
1336
- getZoomScale: function(e, t) {
1337
- var n = this.options.crs;
1338
- return t = t === void 0 ? this._zoom : t, n.scale(e) / n.scale(t);
1339
- },
1340
- getScaleZoom: function(e, t) {
1341
- var n = this.options.crs;
1342
- t = t === void 0 ? this._zoom : t;
1343
- var r = n.zoom(e * n.scale(t));
1344
- return isNaN(r) ? Infinity : r;
1345
- },
1346
- project: function(e, t) {
1347
- return t = t === void 0 ? this._zoom : t, this.options.crs.latLngToPoint(k(e), t);
1348
- },
1349
- unproject: function(e, t) {
1350
- return t = t === void 0 ? this._zoom : t, this.options.crs.pointToLatLng(C(e), t);
1351
- },
1352
- layerPointToLatLng: function(e) {
1353
- var t = C(e).add(this.getPixelOrigin());
1354
- return this.unproject(t);
1355
- },
1356
- latLngToLayerPoint: function(e) {
1357
- return this.project(k(e))._round()._subtract(this.getPixelOrigin());
1358
- },
1359
- wrapLatLng: function(e) {
1360
- return this.options.crs.wrapLatLng(k(e));
1361
- },
1362
- wrapLatLngBounds: function(e) {
1363
- return this.options.crs.wrapLatLngBounds(D(e));
1364
- },
1365
- distance: function(e, t) {
1366
- return this.options.crs.distance(k(e), k(t));
1367
- },
1368
- containerPointToLayerPoint: function(e) {
1369
- return C(e).subtract(this._getMapPanePos());
1370
- },
1371
- layerPointToContainerPoint: function(e) {
1372
- return C(e).add(this._getMapPanePos());
1373
- },
1374
- containerPointToLatLng: function(e) {
1375
- var t = this.containerPointToLayerPoint(C(e));
1376
- return this.layerPointToLatLng(t);
1377
- },
1378
- latLngToContainerPoint: function(e) {
1379
- return this.layerPointToContainerPoint(this.latLngToLayerPoint(k(e)));
1380
- },
1381
- mouseEventToContainerPoint: function(e) {
1382
- return an(e, this._container);
1383
- },
1384
- mouseEventToLayerPoint: function(e) {
1385
- return this.containerPointToLayerPoint(this.mouseEventToContainerPoint(e));
1386
- },
1387
- mouseEventToLatLng: function(e) {
1388
- return this.layerPointToLatLng(this.mouseEventToLayerPoint(e));
1389
- },
1390
- _initContainer: function(e) {
1391
- var t = this._container = wt(e);
1392
- if (!t) throw Error("Map container not found.");
1393
- if (t._leaflet_id) throw Error("Map container is already initialized.");
1394
- H(t, "scroll", this._onScroll, this), this._containerId = o(t);
1395
- },
1396
- _initLayout: function() {
1397
- var e = this._container;
1398
- this._fadeAnimated = this.options.fadeAnimation && P.any3d, R(e, "leaflet-container" + (P.touch ? " leaflet-touch" : "") + (P.retina ? " leaflet-retina" : "") + (P.ielt9 ? " leaflet-oldie" : "") + (P.safari ? " leaflet-safari" : "") + (this._fadeAnimated ? " leaflet-fade-anim" : ""));
1399
- var t = Tt(e, "position");
1400
- t !== "absolute" && t !== "relative" && t !== "fixed" && t !== "sticky" && (e.style.position = "relative"), this._initPanes(), this._initControlPos && this._initControlPos();
1401
- },
1402
- _initPanes: function() {
1403
- var e = this._panes = {};
1404
- this._paneRenderers = {}, this._mapPane = this.createPane("mapPane", this._container), V(this._mapPane, new S(0, 0)), this.createPane("tilePane"), this.createPane("overlayPane"), this.createPane("shadowPane"), this.createPane("markerPane"), this.createPane("tooltipPane"), this.createPane("popupPane"), this.options.markerZoomAnimation || (R(e.markerPane, "leaflet-zoom-hide"), R(e.shadowPane, "leaflet-zoom-hide"));
1405
- },
1406
- _resetView: function(e, t, n) {
1407
- V(this._mapPane, new S(0, 0));
1408
- var r = !this._loaded;
1409
- this._loaded = !0, t = this._limitZoom(t), this.fire("viewprereset");
1410
- var i = this._zoom !== t;
1411
- this._moveStart(i, n)._move(e, t)._moveEnd(i), this.fire("viewreset"), r && this.fire("load");
1412
- },
1413
- _moveStart: function(e, t) {
1414
- return e && this.fire("zoomstart"), t || this.fire("movestart"), this;
1415
- },
1416
- _move: function(e, t, n, r) {
1417
- t === void 0 && (t = this._zoom);
1418
- var i = this._zoom !== t;
1419
- return this._zoom = t, this._lastCenter = e, this._pixelOrigin = this._getNewPixelOrigin(e), r ? n && n.pinch && this.fire("zoom", n) : ((i || n && n.pinch) && this.fire("zoom", n), this.fire("move", n)), this;
1420
- },
1421
- _moveEnd: function(e) {
1422
- return e && this.fire("zoomend"), this.fire("moveend");
1423
- },
1424
- _stop: function() {
1425
- return y(this._flyToFrame), this._panAnim && this._panAnim.stop(), this;
1426
- },
1427
- _rawPanBy: function(e) {
1428
- V(this._mapPane, this._getMapPanePos().subtract(e));
1429
- },
1430
- _getZoomSpan: function() {
1431
- return this.getMaxZoom() - this.getMinZoom();
1432
- },
1433
- _panInsideMaxBounds: function() {
1434
- this._enforcingBounds || this.panInsideBounds(this.options.maxBounds);
1435
- },
1436
- _checkIfLoaded: function() {
1437
- if (!this._loaded) throw Error("Set map center and zoom first.");
1438
- },
1439
- _initEvents: function(e) {
1440
- this._targets = {}, this._targets[o(this._container)] = this;
1441
- var t = e ? W : H;
1442
- t(this._container, "click dblclick mousedown mouseup mouseover mouseout mousemove contextmenu keypress keydown keyup", this._handleDOMEvent, this), this.options.trackResize && t(window, "resize", this._onResize, this), P.any3d && this.options.transform3DLimit && (e ? this.off : this.on).call(this, "moveend", this._onMoveEnd);
1443
- },
1444
- _onResize: function() {
1445
- y(this._resizeRequest), this._resizeRequest = v(function() {
1446
- this.invalidateSize({ debounceMoveend: !0 });
1447
- }, this);
1448
- },
1449
- _onScroll: function() {
1450
- this._container.scrollTop = 0, this._container.scrollLeft = 0;
1451
- },
1452
- _onMoveEnd: function() {
1453
- var e = this._getMapPanePos();
1454
- Math.max(Math.abs(e.x), Math.abs(e.y)) >= this.options.transform3DLimit && this._resetView(this.getCenter(), this.getZoom());
1455
- },
1456
- _findEventTargets: function(e, t) {
1457
- for (var n = [], r, i = t === "mouseout" || t === "mouseover", a = e.target || e.srcElement, s = !1; a;) {
1458
- if (r = this._targets[o(a)], r && (t === "click" || t === "preclick") && this._draggableMoved(r)) {
1459
- s = !0;
1460
- break;
1461
- }
1462
- if (r && r.listens(t, !0) && (i && !cn(a, e) || (n.push(r), i)) || a === this._container) break;
1463
- a = a.parentNode;
1464
- }
1465
- return !n.length && !s && !i && this.listens(t, !0) && (n = [this]), n;
1466
- },
1467
- _isClickDisabled: function(e) {
1468
- for (; e && e !== this._container;) {
1469
- if (e._leaflet_disable_click) return !0;
1470
- e = e.parentNode;
1471
- }
1472
- },
1473
- _handleDOMEvent: function(e) {
1474
- var t = e.target || e.srcElement;
1475
- if (!(!this._loaded || t._leaflet_disable_events || e.type === "click" && this._isClickDisabled(t))) {
1476
- var n = e.type;
1477
- n === "mousedown" && Wt(t), this._fireDOMEvent(e, n);
1478
- }
1479
- },
1480
- _mouseEvents: [
1481
- "click",
1482
- "dblclick",
1483
- "mouseover",
1484
- "mouseout",
1485
- "contextmenu"
1486
- ],
1487
- _fireDOMEvent: function(e, t, r) {
1488
- if (e.type === "click") {
1489
- var i = n({}, e);
1490
- i.type = "preclick", this._fireDOMEvent(i, i.type, r);
1491
- }
1492
- var a = this._findEventTargets(e, t);
1493
- if (r) {
1494
- for (var o = [], s = 0; s < r.length; s++) r[s].listens(t, !0) && o.push(r[s]);
1495
- a = o.concat(a);
1496
- }
1497
- if (a.length) {
1498
- t === "contextmenu" && G(e);
1499
- var c = a[0], l = { originalEvent: e };
1500
- if (e.type !== "keypress" && e.type !== "keydown" && e.type !== "keyup") {
1501
- var u = c.getLatLng && (!c._radius || c._radius <= 10);
1502
- l.containerPoint = u ? this.latLngToContainerPoint(c.getLatLng()) : this.mouseEventToContainerPoint(e), l.layerPoint = this.containerPointToLayerPoint(l.containerPoint), l.latlng = u ? c.getLatLng() : this.layerPointToLatLng(l.layerPoint);
1503
- }
1504
- for (s = 0; s < a.length; s++) if (a[s].fire(t, l, !0), l.originalEvent._stopped || a[s].options.bubblingMouseEvents === !1 && ee(this._mouseEvents, t) !== -1) return;
1505
- }
1506
- },
1507
- _draggableMoved: function(e) {
1508
- return e = e.dragging && e.dragging.enabled() ? e : this, e.dragging && e.dragging.moved() || this.boxZoom && this.boxZoom.moved();
1509
- },
1510
- _clearHandlers: function() {
1511
- for (var e = 0, t = this._handlers.length; e < t; e++) this._handlers[e].disable();
1512
- },
1513
- whenReady: function(e, t) {
1514
- return this._loaded ? e.call(t || this, { target: this }) : this.on("load", e, t), this;
1515
- },
1516
- _getMapPanePos: function() {
1517
- return Ft(this._mapPane) || new S(0, 0);
1518
- },
1519
- _moved: function() {
1520
- var e = this._getMapPanePos();
1521
- return e && !e.equals([0, 0]);
1522
- },
1523
- _getTopLeftPoint: function(e, t) {
1524
- return (e && t !== void 0 ? this._getNewPixelOrigin(e, t) : this.getPixelOrigin()).subtract(this._getMapPanePos());
1525
- },
1526
- _getNewPixelOrigin: function(e, t) {
1527
- var n = this.getSize()._divideBy(2);
1528
- return this.project(e, t)._subtract(n)._add(this._getMapPanePos())._round();
1529
- },
1530
- _latLngToNewLayerPoint: function(e, t, n) {
1531
- var r = this._getNewPixelOrigin(n, t);
1532
- return this.project(e, t)._subtract(r);
1533
- },
1534
- _latLngBoundsToNewLayerBounds: function(e, t, n) {
1535
- var r = this._getNewPixelOrigin(n, t);
1536
- return T([
1537
- this.project(e.getSouthWest(), t)._subtract(r),
1538
- this.project(e.getNorthWest(), t)._subtract(r),
1539
- this.project(e.getSouthEast(), t)._subtract(r),
1540
- this.project(e.getNorthEast(), t)._subtract(r)
1541
- ]);
1542
- },
1543
- _getCenterLayerPoint: function() {
1544
- return this.containerPointToLayerPoint(this.getSize()._divideBy(2));
1545
- },
1546
- _getCenterOffset: function(e) {
1547
- return this.latLngToLayerPoint(e).subtract(this._getCenterLayerPoint());
1548
- },
1549
- _limitCenter: function(e, t, n) {
1550
- if (!n) return e;
1551
- var r = this.project(e, t), i = this.getSize().divideBy(2), a = new w(r.subtract(i), r.add(i)), o = this._getBoundsOffset(a, n, t);
1552
- return Math.abs(o.x) <= 1 && Math.abs(o.y) <= 1 ? e : this.unproject(r.add(o), t);
1553
- },
1554
- _limitOffset: function(e, t) {
1555
- if (!t) return e;
1556
- var n = this.getPixelBounds(), r = new w(n.min.add(e), n.max.add(e));
1557
- return e.add(this._getBoundsOffset(r, t));
1558
- },
1559
- _getBoundsOffset: function(e, t, n) {
1560
- var r = T(this.project(t.getNorthEast(), n), this.project(t.getSouthWest(), n)), i = r.min.subtract(e.min), a = r.max.subtract(e.max);
1561
- return new S(this._rebound(i.x, -a.x), this._rebound(i.y, -a.y));
1562
- },
1563
- _rebound: function(e, t) {
1564
- return e + t > 0 ? Math.round(e - t) / 2 : Math.max(0, Math.ceil(e)) - Math.max(0, Math.floor(t));
1565
- },
1566
- _limitZoom: function(e) {
1567
- var t = this.getMinZoom(), n = this.getMaxZoom(), r = P.any3d ? this.options.zoomSnap : 1;
1568
- return r && (e = Math.round(e / r) * r), Math.max(t, Math.min(n, e));
1569
- },
1570
- _onPanTransitionStep: function() {
1571
- this.fire("move");
1572
- },
1573
- _onPanTransitionEnd: function() {
1574
- z(this._mapPane, "leaflet-pan-anim"), this.fire("moveend");
1575
- },
1576
- _tryAnimatedPan: function(e, t) {
1577
- var n = this._getCenterOffset(e)._trunc();
1578
- return (t && t.animate) !== !0 && !this.getSize().contains(n) ? !1 : (this.panBy(n, t), !0);
1579
- },
1580
- _createAnimProxy: function() {
1581
- var e = this._proxy = F("div", "leaflet-proxy leaflet-zoom-animated");
1582
- this._panes.mapPane.appendChild(e), this.on("zoomanim", function(e) {
1583
- var t = xt, n = this._proxy.style[t];
1584
- Pt(this._proxy, this.project(e.center, e.zoom), this.getZoomScale(e.zoom, 1)), n === this._proxy.style[t] && this._animatingZoom && this._onZoomTransitionEnd();
1585
- }, this), this.on("load moveend", this._animMoveEnd, this), this._on("unload", this._destroyAnimProxy, this);
1586
- },
1587
- _destroyAnimProxy: function() {
1588
- I(this._proxy), this.off("load moveend", this._animMoveEnd, this), delete this._proxy;
1589
- },
1590
- _animMoveEnd: function() {
1591
- var e = this.getCenter(), t = this.getZoom();
1592
- Pt(this._proxy, this.project(e, t), this.getZoomScale(t, 1));
1593
- },
1594
- _catchTransitionEnd: function(e) {
1595
- this._animatingZoom && e.propertyName.indexOf("transform") >= 0 && this._onZoomTransitionEnd();
1596
- },
1597
- _nothingToAnimate: function() {
1598
- return !this._container.getElementsByClassName("leaflet-zoom-animated").length;
1599
- },
1600
- _tryAnimatedZoom: function(e, t, n) {
1601
- if (this._animatingZoom) return !0;
1602
- if (n ||= {}, !this._zoomAnimated || n.animate === !1 || this._nothingToAnimate() || Math.abs(t - this._zoom) > this.options.zoomAnimationThreshold) return !1;
1603
- var r = this.getZoomScale(t), i = this._getCenterOffset(e)._divideBy(1 - 1 / r);
1604
- return n.animate !== !0 && !this.getSize().contains(i) ? !1 : (v(function() {
1605
- this._moveStart(!0, n.noMoveStart || !1)._animateZoom(e, t, !0);
1606
- }, this), !0);
1607
- },
1608
- _animateZoom: function(e, t, n, r) {
1609
- this._mapPane && (n && (this._animatingZoom = !0, this._animateToCenter = e, this._animateToZoom = t, R(this._mapPane, "leaflet-zoom-anim")), this.fire("zoomanim", {
1610
- center: e,
1611
- zoom: t,
1612
- noUpdate: r
1613
- }), this._tempFireZoomEvent ||= this._zoom !== this._animateToZoom, this._move(this._animateToCenter, this._animateToZoom, void 0, !0), setTimeout(i(this._onZoomTransitionEnd, this), 250));
1614
- },
1615
- _onZoomTransitionEnd: function() {
1616
- this._animatingZoom && (this._mapPane && z(this._mapPane, "leaflet-zoom-anim"), this._animatingZoom = !1, this._move(this._animateToCenter, this._animateToZoom, void 0, !0), this._tempFireZoomEvent && this.fire("zoom"), delete this._tempFireZoomEvent, this.fire("move"), this._moveEnd(!0));
1617
- }
1618
- });
1619
- function dn(e, t) {
1620
- return new K(e, t);
1621
- }
1622
- var q = b.extend({
1623
- options: { position: "topright" },
1624
- initialize: function(e) {
1625
- p(this, e);
1626
- },
1627
- getPosition: function() {
1628
- return this.options.position;
1629
- },
1630
- setPosition: function(e) {
1631
- var t = this._map;
1632
- return t && t.removeControl(this), this.options.position = e, t && t.addControl(this), this;
1633
- },
1634
- getContainer: function() {
1635
- return this._container;
1636
- },
1637
- addTo: function(e) {
1638
- this.remove(), this._map = e;
1639
- var t = this._container = this.onAdd(e), n = this.getPosition(), r = e._controlCorners[n];
1640
- return R(t, "leaflet-control"), n.indexOf("bottom") === -1 ? r.appendChild(t) : r.insertBefore(t, r.firstChild), this._map.on("unload", this.remove, this), this;
1641
- },
1642
- remove: function() {
1643
- return this._map ? (I(this._container), this.onRemove && this.onRemove(this._map), this._map.off("unload", this.remove, this), this._map = null, this) : this;
1644
- },
1645
- _refocusOnMap: function(e) {
1646
- this._map && e && e.screenX > 0 && e.screenY > 0 && this._map.getContainer().focus();
1647
- }
1648
- }), fn = function(e) {
1649
- return new q(e);
1650
- };
1651
- K.include({
1652
- addControl: function(e) {
1653
- return e.addTo(this), this;
1654
- },
1655
- removeControl: function(e) {
1656
- return e.remove(), this;
1657
- },
1658
- _initControlPos: function() {
1659
- var e = this._controlCorners = {}, t = "leaflet-", n = this._controlContainer = F("div", t + "control-container", this._container);
1660
- function r(r, i) {
1661
- var a = t + r + " " + t + i;
1662
- e[r + i] = F("div", a, n);
1663
- }
1664
- r("top", "left"), r("top", "right"), r("bottom", "left"), r("bottom", "right");
1665
- },
1666
- _clearControlPos: function() {
1667
- for (var e in this._controlCorners) I(this._controlCorners[e]);
1668
- I(this._controlContainer), delete this._controlCorners, delete this._controlContainer;
1669
- }
1670
- });
1671
- var pn = q.extend({
1672
- options: {
1673
- collapsed: !0,
1674
- position: "topright",
1675
- autoZIndex: !0,
1676
- hideSingleBase: !1,
1677
- sortLayers: !1,
1678
- sortFunction: function(e, t, n, r) {
1679
- return n < r ? -1 : +(r < n);
1680
- }
1681
- },
1682
- initialize: function(e, t, n) {
1683
- for (var r in p(this, n), this._layerControlInputs = [], this._layers = [], this._lastZIndex = 0, this._handlingClick = !1, this._preventClick = !1, e) this._addLayer(e[r], r);
1684
- for (r in t) this._addLayer(t[r], r, !0);
1685
- },
1686
- onAdd: function(e) {
1687
- this._initLayout(), this._update(), this._map = e, e.on("zoomend", this._checkDisabledLayers, this);
1688
- for (var t = 0; t < this._layers.length; t++) this._layers[t].layer.on("add remove", this._onLayerChange, this);
1689
- return this._container;
1690
- },
1691
- addTo: function(e) {
1692
- return q.prototype.addTo.call(this, e), this._expandIfNotCollapsed();
1693
- },
1694
- onRemove: function() {
1695
- this._map.off("zoomend", this._checkDisabledLayers, this);
1696
- for (var e = 0; e < this._layers.length; e++) this._layers[e].layer.off("add remove", this._onLayerChange, this);
1697
- },
1698
- addBaseLayer: function(e, t) {
1699
- return this._addLayer(e, t), this._map ? this._update() : this;
1700
- },
1701
- addOverlay: function(e, t) {
1702
- return this._addLayer(e, t, !0), this._map ? this._update() : this;
1703
- },
1704
- removeLayer: function(e) {
1705
- e.off("add remove", this._onLayerChange, this);
1706
- var t = this._getLayer(o(e));
1707
- return t && this._layers.splice(this._layers.indexOf(t), 1), this._map ? this._update() : this;
1708
- },
1709
- expand: function() {
1710
- R(this._container, "leaflet-control-layers-expanded"), this._section.style.height = null;
1711
- var e = this._map.getSize().y - (this._container.offsetTop + 50);
1712
- return e < this._section.clientHeight ? (R(this._section, "leaflet-control-layers-scrollbar"), this._section.style.height = e + "px") : z(this._section, "leaflet-control-layers-scrollbar"), this._checkDisabledLayers(), this;
1713
- },
1714
- collapse: function() {
1715
- return z(this._container, "leaflet-control-layers-expanded"), this;
1716
- },
1717
- _initLayout: function() {
1718
- var e = "leaflet-control-layers", t = this._container = F("div", e), n = this.options.collapsed;
1719
- t.setAttribute("aria-haspopup", !0), tn(t), en(t);
1720
- var r = this._section = F("section", e + "-list");
1721
- n && (this._map.on("click", this.collapse, this), H(t, {
1722
- mouseenter: this._expandSafely,
1723
- mouseleave: this.collapse
1724
- }, this));
1725
- var i = this._layersLink = F("a", e + "-toggle", t);
1726
- i.href = "#", i.title = "Layers", i.setAttribute("role", "button"), H(i, {
1727
- keydown: function(e) {
1728
- e.keyCode === 13 && this._expandSafely();
1729
- },
1730
- click: function(e) {
1731
- G(e), this._expandSafely();
1732
- }
1733
- }, this), n || this.expand(), this._baseLayersList = F("div", e + "-base", r), this._separator = F("div", e + "-separator", r), this._overlaysList = F("div", e + "-overlays", r), t.appendChild(r);
1734
- },
1735
- _getLayer: function(e) {
1736
- for (var t = 0; t < this._layers.length; t++) if (this._layers[t] && o(this._layers[t].layer) === e) return this._layers[t];
1737
- },
1738
- _addLayer: function(e, t, n) {
1739
- this._map && e.on("add remove", this._onLayerChange, this), this._layers.push({
1740
- layer: e,
1741
- name: t,
1742
- overlay: n
1743
- }), this.options.sortLayers && this._layers.sort(i(function(e, t) {
1744
- return this.options.sortFunction(e.layer, t.layer, e.name, t.name);
1745
- }, this)), this.options.autoZIndex && e.setZIndex && (this._lastZIndex++, e.setZIndex(this._lastZIndex)), this._expandIfNotCollapsed();
1746
- },
1747
- _update: function() {
1748
- if (!this._container) return this;
1749
- Et(this._baseLayersList), Et(this._overlaysList), this._layerControlInputs = [];
1750
- var e, t, n, r, i = 0;
1751
- for (n = 0; n < this._layers.length; n++) r = this._layers[n], this._addItem(r), t ||= r.overlay, e ||= !r.overlay, i += +!r.overlay;
1752
- return this.options.hideSingleBase && (e &&= i > 1, this._baseLayersList.style.display = e ? "" : "none"), this._separator.style.display = t && e ? "" : "none", this;
1753
- },
1754
- _onLayerChange: function(e) {
1755
- this._handlingClick || this._update();
1756
- var t = this._getLayer(o(e.target)), n = t.overlay ? e.type === "add" ? "overlayadd" : "overlayremove" : e.type === "add" ? "baselayerchange" : null;
1757
- n && this._map.fire(n, t);
1758
- },
1759
- _createRadioElement: function(e, t) {
1760
- var n = "<input type=\"radio\" class=\"leaflet-control-layers-selector\" name=\"" + e + "\"" + (t ? " checked=\"checked\"" : "") + "/>", r = document.createElement("div");
1761
- return r.innerHTML = n, r.firstChild;
1762
- },
1763
- _addItem: function(e) {
1764
- var t = document.createElement("label"), n = this._map.hasLayer(e.layer), r;
1765
- e.overlay ? (r = document.createElement("input"), r.type = "checkbox", r.className = "leaflet-control-layers-selector", r.defaultChecked = n) : r = this._createRadioElement("leaflet-base-layers_" + o(this), n), this._layerControlInputs.push(r), r.layerId = o(e.layer), H(r, "click", this._onInputClick, this);
1766
- var i = document.createElement("span");
1767
- i.innerHTML = " " + e.name;
1768
- var a = document.createElement("span");
1769
- return t.appendChild(a), a.appendChild(r), a.appendChild(i), (e.overlay ? this._overlaysList : this._baseLayersList).appendChild(t), this._checkDisabledLayers(), t;
1770
- },
1771
- _onInputClick: function() {
1772
- if (!this._preventClick) {
1773
- var e = this._layerControlInputs, t, n, r = [], i = [];
1774
- this._handlingClick = !0;
1775
- for (var a = e.length - 1; a >= 0; a--) t = e[a], n = this._getLayer(t.layerId).layer, t.checked ? r.push(n) : t.checked || i.push(n);
1776
- for (a = 0; a < i.length; a++) this._map.hasLayer(i[a]) && this._map.removeLayer(i[a]);
1777
- for (a = 0; a < r.length; a++) this._map.hasLayer(r[a]) || this._map.addLayer(r[a]);
1778
- this._handlingClick = !1, this._refocusOnMap();
1779
- }
1780
- },
1781
- _checkDisabledLayers: function() {
1782
- for (var e = this._layerControlInputs, t, n, r = this._map.getZoom(), i = e.length - 1; i >= 0; i--) t = e[i], n = this._getLayer(t.layerId).layer, t.disabled = n.options.minZoom !== void 0 && r < n.options.minZoom || n.options.maxZoom !== void 0 && r > n.options.maxZoom;
1783
- },
1784
- _expandIfNotCollapsed: function() {
1785
- return this._map && !this.options.collapsed && this.expand(), this;
1786
- },
1787
- _expandSafely: function() {
1788
- var e = this._section;
1789
- this._preventClick = !0, H(e, "click", G), this.expand();
1790
- var t = this;
1791
- setTimeout(function() {
1792
- W(e, "click", G), t._preventClick = !1;
1793
- });
1794
- }
1795
- }), mn = function(e, t, n) {
1796
- return new pn(e, t, n);
1797
- }, hn = q.extend({
1798
- options: {
1799
- position: "topleft",
1800
- zoomInText: "<span aria-hidden=\"true\">+</span>",
1801
- zoomInTitle: "Zoom in",
1802
- zoomOutText: "<span aria-hidden=\"true\">&#x2212;</span>",
1803
- zoomOutTitle: "Zoom out"
1804
- },
1805
- onAdd: function(e) {
1806
- var t = "leaflet-control-zoom", n = F("div", t + " leaflet-bar"), r = this.options;
1807
- return this._zoomInButton = this._createButton(r.zoomInText, r.zoomInTitle, t + "-in", n, this._zoomIn), this._zoomOutButton = this._createButton(r.zoomOutText, r.zoomOutTitle, t + "-out", n, this._zoomOut), this._updateDisabled(), e.on("zoomend zoomlevelschange", this._updateDisabled, this), n;
1808
- },
1809
- onRemove: function(e) {
1810
- e.off("zoomend zoomlevelschange", this._updateDisabled, this);
1811
- },
1812
- disable: function() {
1813
- return this._disabled = !0, this._updateDisabled(), this;
1814
- },
1815
- enable: function() {
1816
- return this._disabled = !1, this._updateDisabled(), this;
1817
- },
1818
- _zoomIn: function(e) {
1819
- !this._disabled && this._map._zoom < this._map.getMaxZoom() && this._map.zoomIn(this._map.options.zoomDelta * (e.shiftKey ? 3 : 1));
1820
- },
1821
- _zoomOut: function(e) {
1822
- !this._disabled && this._map._zoom > this._map.getMinZoom() && this._map.zoomOut(this._map.options.zoomDelta * (e.shiftKey ? 3 : 1));
1823
- },
1824
- _createButton: function(e, t, n, r, i) {
1825
- var a = F("a", n, r);
1826
- return a.innerHTML = e, a.href = "#", a.title = t, a.setAttribute("role", "button"), a.setAttribute("aria-label", t), tn(a), H(a, "click", nn), H(a, "click", i, this), H(a, "click", this._refocusOnMap, this), a;
1827
- },
1828
- _updateDisabled: function() {
1829
- var e = this._map, t = "leaflet-disabled";
1830
- z(this._zoomInButton, t), z(this._zoomOutButton, t), this._zoomInButton.setAttribute("aria-disabled", "false"), this._zoomOutButton.setAttribute("aria-disabled", "false"), (this._disabled || e._zoom === e.getMinZoom()) && (R(this._zoomOutButton, t), this._zoomOutButton.setAttribute("aria-disabled", "true")), (this._disabled || e._zoom === e.getMaxZoom()) && (R(this._zoomInButton, t), this._zoomInButton.setAttribute("aria-disabled", "true"));
1831
- }
1832
- });
1833
- K.mergeOptions({ zoomControl: !0 }), K.addInitHook(function() {
1834
- this.options.zoomControl && (this.zoomControl = new hn(), this.addControl(this.zoomControl));
1835
- });
1836
- var gn = function(e) {
1837
- return new hn(e);
1838
- }, _n = q.extend({
1839
- options: {
1840
- position: "bottomleft",
1841
- maxWidth: 100,
1842
- metric: !0,
1843
- imperial: !0
1844
- },
1845
- onAdd: function(e) {
1846
- var t = "leaflet-control-scale", n = F("div", t), r = this.options;
1847
- return this._addScales(r, t + "-line", n), e.on(r.updateWhenIdle ? "moveend" : "move", this._update, this), e.whenReady(this._update, this), n;
1848
- },
1849
- onRemove: function(e) {
1850
- e.off(this.options.updateWhenIdle ? "moveend" : "move", this._update, this);
1851
- },
1852
- _addScales: function(e, t, n) {
1853
- e.metric && (this._mScale = F("div", t, n)), e.imperial && (this._iScale = F("div", t, n));
1854
- },
1855
- _update: function() {
1856
- var e = this._map, t = e.getSize().y / 2, n = e.distance(e.containerPointToLatLng([0, t]), e.containerPointToLatLng([this.options.maxWidth, t]));
1857
- this._updateScales(n);
1858
- },
1859
- _updateScales: function(e) {
1860
- this.options.metric && e && this._updateMetric(e), this.options.imperial && e && this._updateImperial(e);
1861
- },
1862
- _updateMetric: function(e) {
1863
- var t = this._getRoundNum(e), n = t < 1e3 ? t + " m" : t / 1e3 + " km";
1864
- this._updateScale(this._mScale, n, t / e);
1865
- },
1866
- _updateImperial: function(e) {
1867
- var t = e * 3.2808399, n, r, i;
1868
- t > 5280 ? (n = t / 5280, r = this._getRoundNum(n), this._updateScale(this._iScale, r + " mi", r / n)) : (i = this._getRoundNum(t), this._updateScale(this._iScale, i + " ft", i / t));
1869
- },
1870
- _updateScale: function(e, t, n) {
1871
- e.style.width = Math.round(this.options.maxWidth * n) + "px", e.innerHTML = t;
1872
- },
1873
- _getRoundNum: function(e) {
1874
- var t = 10 ** ((Math.floor(e) + "").length - 1), n = e / t;
1875
- return n = n >= 10 ? 10 : n >= 5 ? 5 : n >= 3 ? 3 : n >= 2 ? 2 : 1, t * n;
1876
- }
1877
- }), vn = function(e) {
1878
- return new _n(e);
1879
- }, yn = q.extend({
1880
- options: {
1881
- position: "bottomright",
1882
- prefix: "<a href=\"https://leafletjs.com\" title=\"A JavaScript library for interactive maps\">" + (P.inlineSvg ? "<svg aria-hidden=\"true\" xmlns=\"http://www.w3.org/2000/svg\" width=\"12\" height=\"8\" viewBox=\"0 0 12 8\" class=\"leaflet-attribution-flag\"><path fill=\"#4C7BE1\" d=\"M0 0h12v4H0z\"/><path fill=\"#FFD500\" d=\"M0 4h12v3H0z\"/><path fill=\"#E0BC00\" d=\"M0 7h12v1H0z\"/></svg> " : "") + "Leaflet</a>"
1883
- },
1884
- initialize: function(e) {
1885
- p(this, e), this._attributions = {};
1886
- },
1887
- onAdd: function(e) {
1888
- for (var t in e.attributionControl = this, this._container = F("div", "leaflet-control-attribution"), tn(this._container), e._layers) e._layers[t].getAttribution && this.addAttribution(e._layers[t].getAttribution());
1889
- return this._update(), e.on("layeradd", this._addAttribution, this), this._container;
1890
- },
1891
- onRemove: function(e) {
1892
- e.off("layeradd", this._addAttribution, this);
1893
- },
1894
- _addAttribution: function(e) {
1895
- e.layer.getAttribution && (this.addAttribution(e.layer.getAttribution()), e.layer.once("remove", function() {
1896
- this.removeAttribution(e.layer.getAttribution());
1897
- }, this));
1898
- },
1899
- setPrefix: function(e) {
1900
- return this.options.prefix = e, this._update(), this;
1901
- },
1902
- addAttribution: function(e) {
1903
- return e ? (this._attributions[e] || (this._attributions[e] = 0), this._attributions[e]++, this._update(), this) : this;
1904
- },
1905
- removeAttribution: function(e) {
1906
- return e && this._attributions[e] && (this._attributions[e]--, this._update()), this;
1907
- },
1908
- _update: function() {
1909
- if (this._map) {
1910
- var e = [];
1911
- for (var t in this._attributions) this._attributions[t] && e.push(t);
1912
- var n = [];
1913
- this.options.prefix && n.push(this.options.prefix), e.length && n.push(e.join(", ")), this._container.innerHTML = n.join(" <span aria-hidden=\"true\">|</span> ");
1914
- }
1915
- }
1916
- });
1917
- K.mergeOptions({ attributionControl: !0 }), K.addInitHook(function() {
1918
- this.options.attributionControl && new yn().addTo(this);
1919
- }), q.Layers = pn, q.Zoom = hn, q.Scale = _n, q.Attribution = yn, fn.layers = mn, fn.zoom = gn, fn.scale = vn, fn.attribution = function(e) {
1920
- return new yn(e);
1921
- };
1922
- var J = b.extend({
1923
- initialize: function(e) {
1924
- this._map = e;
1925
- },
1926
- enable: function() {
1927
- return this._enabled ? this : (this._enabled = !0, this.addHooks(), this);
1928
- },
1929
- disable: function() {
1930
- return this._enabled ? (this._enabled = !1, this.removeHooks(), this) : this;
1931
- },
1932
- enabled: function() {
1933
- return !!this._enabled;
1934
- }
1935
- });
1936
- J.addTo = function(e, t) {
1937
- return e.addHandler(t, this), this;
1938
- };
1939
- var bn = { Events: x }, xn = P.touch ? "touchstart mousedown" : "mousedown", Sn = le.extend({
1940
- options: { clickTolerance: 3 },
1941
- initialize: function(e, t, n, r) {
1942
- p(this, r), this._element = e, this._dragStartTarget = t || e, this._preventOutline = n;
1943
- },
1944
- enable: function() {
1945
- this._enabled ||= (H(this._dragStartTarget, xn, this._onDown, this), !0);
1946
- },
1947
- disable: function() {
1948
- this._enabled && (Sn._dragging === this && this.finishDrag(!0), W(this._dragStartTarget, xn, this._onDown, this), this._enabled = !1, this._moved = !1);
1949
- },
1950
- _onDown: function(e) {
1951
- if (this._enabled && (this._moved = !1, !kt(this._element, "leaflet-zoom-anim"))) {
1952
- if (e.touches && e.touches.length !== 1) {
1953
- Sn._dragging === this && this.finishDrag();
1954
- return;
1955
- }
1956
- if (!(Sn._dragging || e.shiftKey || e.which !== 1 && e.button !== 1 && !e.touches) && (Sn._dragging = this, this._preventOutline && Wt(this._element), Bt(), It(), !this._moving)) {
1957
- this.fire("down");
1958
- var t = e.touches ? e.touches[0] : e, n = Kt(this._element);
1959
- this._startPoint = new S(t.clientX, t.clientY), this._startPos = Ft(this._element), this._parentScale = qt(n);
1960
- var r = e.type === "mousedown";
1961
- H(document, r ? "mousemove" : "touchmove", this._onMove, this), H(document, r ? "mouseup" : "touchend touchcancel", this._onUp, this);
1962
- }
1963
- }
1964
- },
1965
- _onMove: function(e) {
1966
- if (this._enabled) {
1967
- if (e.touches && e.touches.length > 1) {
1968
- this._moved = !0;
1969
- return;
1970
- }
1971
- var t = e.touches && e.touches.length === 1 ? e.touches[0] : e, n = new S(t.clientX, t.clientY)._subtract(this._startPoint);
1972
- (n.x || n.y) && (Math.abs(n.x) + Math.abs(n.y) < this.options.clickTolerance || (n.x /= this._parentScale.x, n.y /= this._parentScale.y, G(e), this._moved || (this.fire("dragstart"), this._moved = !0, R(document.body, "leaflet-dragging"), this._lastTarget = e.target || e.srcElement, window.SVGElementInstance && this._lastTarget instanceof window.SVGElementInstance && (this._lastTarget = this._lastTarget.correspondingUseElement), R(this._lastTarget, "leaflet-drag-target")), this._newPos = this._startPos.add(n), this._moving = !0, this._lastEvent = e, this._updatePosition()));
1973
- }
1974
- },
1975
- _updatePosition: function() {
1976
- var e = { originalEvent: this._lastEvent };
1977
- this.fire("predrag", e), V(this._element, this._newPos), this.fire("drag", e);
1978
- },
1979
- _onUp: function() {
1980
- this._enabled && this.finishDrag();
1981
- },
1982
- finishDrag: function(e) {
1983
- z(document.body, "leaflet-dragging"), this._lastTarget &&= (z(this._lastTarget, "leaflet-drag-target"), null), W(document, "mousemove touchmove", this._onMove, this), W(document, "mouseup touchend touchcancel", this._onUp, this), Vt(), Lt();
1984
- var t = this._moved && this._moving;
1985
- this._moving = !1, Sn._dragging = !1, t && this.fire("dragend", {
1986
- noInertia: e,
1987
- distance: this._newPos.distanceTo(this._startPos)
1988
- });
1989
- }
1990
- });
1991
- function Cn(e, t, n) {
1992
- for (var r, i = [
1993
- 1,
1994
- 4,
1995
- 2,
1996
- 8
1997
- ], a = 0, o, s, c, l, u = e.length, d, f; a < u; a++) e[a]._code = In(e[a], t);
1998
- for (s = 0; s < 4; s++) {
1999
- for (d = i[s], r = [], a = 0, u = e.length, o = u - 1; a < u; o = a++) c = e[a], l = e[o], c._code & d ? l._code & d || (f = Fn(l, c, d, t, n), f._code = In(f, t), r.push(f)) : (l._code & d && (f = Fn(l, c, d, t, n), f._code = In(f, t), r.push(f)), r.push(c));
2000
- e = r;
2001
- }
2002
- return e;
2003
- }
2004
- function wn(e, t) {
2005
- var n, r, i, a, o, s, c, l, u;
2006
- if (!e || e.length === 0) throw Error("latlngs not passed");
2007
- Y(e) || (console.warn("latlngs are not flat! Only the first ring will be used"), e = e[0]);
2008
- var d = k([0, 0]), f = D(e);
2009
- f.getNorthWest().distanceTo(f.getSouthWest()) * f.getNorthEast().distanceTo(f.getNorthWest()) < 1700 && (d = Tn(e));
2010
- var p = e.length, m = [];
2011
- for (n = 0; n < p; n++) {
2012
- var h = k(e[n]);
2013
- m.push(t.project(k([h.lat - d.lat, h.lng - d.lng])));
2014
- }
2015
- for (s = c = l = 0, n = 0, r = p - 1; n < p; r = n++) i = m[n], a = m[r], o = i.y * a.x - a.y * i.x, c += (i.x + a.x) * o, l += (i.y + a.y) * o, s += o * 3;
2016
- u = s === 0 ? m[0] : [c / s, l / s];
2017
- var g = t.unproject(C(u));
2018
- return k([g.lat + d.lat, g.lng + d.lng]);
2019
- }
2020
- function Tn(e) {
2021
- for (var t = 0, n = 0, r = 0, i = 0; i < e.length; i++) {
2022
- var a = k(e[i]);
2023
- t += a.lat, n += a.lng, r++;
2024
- }
2025
- return k([t / r, n / r]);
2026
- }
2027
- var En = {
2028
- __proto__: null,
2029
- clipPolygon: Cn,
2030
- polygonCenter: wn,
2031
- centroid: Tn
2032
- };
2033
- function Dn(e, t) {
2034
- if (!t || !e.length) return e.slice();
2035
- var n = t * t;
2036
- return e = Mn(e, n), e = An(e, n), e;
2037
- }
2038
- function On(e, t, n) {
2039
- return Math.sqrt(Rn(e, t, n, !0));
2040
- }
2041
- function kn(e, t, n) {
2042
- return Rn(e, t, n);
2043
- }
2044
- function An(e, t) {
2045
- var n = e.length, r = new (typeof Uint8Array < "u" ? Uint8Array : Array)(n);
2046
- r[0] = r[n - 1] = 1, jn(e, r, t, 0, n - 1);
2047
- var i, a = [];
2048
- for (i = 0; i < n; i++) r[i] && a.push(e[i]);
2049
- return a;
2050
- }
2051
- function jn(e, t, n, r, i) {
2052
- for (var a = 0, o, s = r + 1, c; s <= i - 1; s++) c = Rn(e[s], e[r], e[i], !0), c > a && (o = s, a = c);
2053
- a > n && (t[o] = 1, jn(e, t, n, r, o), jn(e, t, n, o, i));
2054
- }
2055
- function Mn(e, t) {
2056
- for (var n = [e[0]], r = 1, i = 0, a = e.length; r < a; r++) Ln(e[r], e[i]) > t && (n.push(e[r]), i = r);
2057
- return i < a - 1 && n.push(e[a - 1]), n;
2058
- }
2059
- var Nn;
2060
- function Pn(e, t, n, r, i) {
2061
- var a = r ? Nn : In(e, n), o = In(t, n), s, c, l;
2062
- for (Nn = o;;) {
2063
- if (!(a | o)) return [e, t];
2064
- if (a & o) return !1;
2065
- s = a || o, c = Fn(e, t, s, n, i), l = In(c, n), s === a ? (e = c, a = l) : (t = c, o = l);
2066
- }
2067
- }
2068
- function Fn(e, t, n, r, i) {
2069
- var a = t.x - e.x, o = t.y - e.y, s = r.min, c = r.max, l, u;
2070
- return n & 8 ? (l = e.x + a * (c.y - e.y) / o, u = c.y) : n & 4 ? (l = e.x + a * (s.y - e.y) / o, u = s.y) : n & 2 ? (l = c.x, u = e.y + o * (c.x - e.x) / a) : n & 1 && (l = s.x, u = e.y + o * (s.x - e.x) / a), new S(l, u, i);
2071
- }
2072
- function In(e, t) {
2073
- var n = 0;
2074
- return e.x < t.min.x ? n |= 1 : e.x > t.max.x && (n |= 2), e.y < t.min.y ? n |= 4 : e.y > t.max.y && (n |= 8), n;
2075
- }
2076
- function Ln(e, t) {
2077
- var n = t.x - e.x, r = t.y - e.y;
2078
- return n * n + r * r;
2079
- }
2080
- function Rn(e, t, n, r) {
2081
- var i = t.x, a = t.y, o = n.x - i, s = n.y - a, c = o * o + s * s, l;
2082
- return c > 0 && (l = ((e.x - i) * o + (e.y - a) * s) / c, l > 1 ? (i = n.x, a = n.y) : l > 0 && (i += o * l, a += s * l)), o = e.x - i, s = e.y - a, r ? o * o + s * s : new S(i, a);
2083
- }
2084
- function Y(e) {
2085
- return !_(e[0]) || typeof e[0][0] != "object" && e[0][0] !== void 0;
2086
- }
2087
- function zn(e) {
2088
- return console.warn("Deprecated use of _flat, please use L.LineUtil.isFlat instead."), Y(e);
2089
- }
2090
- function Bn(e, t) {
2091
- var n, r, i, a, o, s, c, l;
2092
- if (!e || e.length === 0) throw Error("latlngs not passed");
2093
- Y(e) || (console.warn("latlngs are not flat! Only the first ring will be used"), e = e[0]);
2094
- var u = k([0, 0]), d = D(e);
2095
- d.getNorthWest().distanceTo(d.getSouthWest()) * d.getNorthEast().distanceTo(d.getNorthWest()) < 1700 && (u = Tn(e));
2096
- var f = e.length, p = [];
2097
- for (n = 0; n < f; n++) {
2098
- var m = k(e[n]);
2099
- p.push(t.project(k([m.lat - u.lat, m.lng - u.lng])));
2100
- }
2101
- for (n = 0, r = 0; n < f - 1; n++) r += p[n].distanceTo(p[n + 1]) / 2;
2102
- if (r === 0) l = p[0];
2103
- else for (n = 0, a = 0; n < f - 1; n++) if (o = p[n], s = p[n + 1], i = o.distanceTo(s), a += i, a > r) {
2104
- c = (a - r) / i, l = [s.x - c * (s.x - o.x), s.y - c * (s.y - o.y)];
2105
- break;
2106
- }
2107
- var h = t.unproject(C(l));
2108
- return k([h.lat + u.lat, h.lng + u.lng]);
2109
- }
2110
- var Vn = {
2111
- __proto__: null,
2112
- simplify: Dn,
2113
- pointToSegmentDistance: On,
2114
- closestPointOnSegment: kn,
2115
- clipSegment: Pn,
2116
- _getEdgeIntersection: Fn,
2117
- _getBitCode: In,
2118
- _sqClosestPointOnSegment: Rn,
2119
- isFlat: Y,
2120
- _flat: zn,
2121
- polylineCenter: Bn
2122
- }, Hn = {
2123
- project: function(e) {
2124
- return new S(e.lng, e.lat);
2125
- },
2126
- unproject: function(e) {
2127
- return new O(e.y, e.x);
2128
- },
2129
- bounds: new w([-180, -90], [180, 90])
2130
- }, Un = {
2131
- R: 6378137,
2132
- R_MINOR: 6356752.314245179,
2133
- bounds: new w([-20037508.34279, -15496570.73972], [20037508.34279, 18764656.23138]),
2134
- project: function(e) {
2135
- var t = Math.PI / 180, n = this.R, r = e.lat * t, i = this.R_MINOR / n, a = Math.sqrt(1 - i * i), o = a * Math.sin(r), s = Math.tan(Math.PI / 4 - r / 2) / ((1 - o) / (1 + o)) ** (a / 2);
2136
- return r = -n * Math.log(Math.max(s, 1e-10)), new S(e.lng * t * n, r);
2137
- },
2138
- unproject: function(e) {
2139
- for (var t = 180 / Math.PI, n = this.R, r = this.R_MINOR / n, i = Math.sqrt(1 - r * r), a = Math.exp(-e.y / n), o = Math.PI / 2 - 2 * Math.atan(a), s = 0, c = .1, l; s < 15 && Math.abs(c) > 1e-7; s++) l = i * Math.sin(o), l = ((1 - l) / (1 + l)) ** (i / 2), c = Math.PI / 2 - 2 * Math.atan(a * l) - o, o += c;
2140
- return new O(o * t, e.x * t / n);
2141
- }
2142
- }, Wn = {
2143
- __proto__: null,
2144
- LonLat: Hn,
2145
- Mercator: Un,
2146
- SphericalMercator: fe
2147
- }, Gn = n({}, j, {
2148
- code: "EPSG:3395",
2149
- projection: Un,
2150
- transformation: function() {
2151
- var e = .5 / (Math.PI * Un.R);
2152
- return me(e, .5, -e, .5);
2153
- }()
2154
- }), Kn = n({}, j, {
2155
- code: "EPSG:4326",
2156
- projection: Hn,
2157
- transformation: me(1 / 180, 1, -1 / 180, .5)
2158
- }), qn = n({}, A, {
2159
- projection: Hn,
2160
- transformation: me(1, 0, -1, 0),
2161
- scale: function(e) {
2162
- return 2 ** e;
2163
- },
2164
- zoom: function(e) {
2165
- return Math.log(e) / Math.LN2;
2166
- },
2167
- distance: function(e, t) {
2168
- var n = t.lng - e.lng, r = t.lat - e.lat;
2169
- return Math.sqrt(n * n + r * r);
2170
- },
2171
- infinite: !0
2172
- });
2173
- A.Earth = j, A.EPSG3395 = Gn, A.EPSG3857 = he, A.EPSG900913 = ge, A.EPSG4326 = Kn, A.Simple = qn;
2174
- var X = le.extend({
2175
- options: {
2176
- pane: "overlayPane",
2177
- attribution: null,
2178
- bubblingMouseEvents: !0
2179
- },
2180
- addTo: function(e) {
2181
- return e.addLayer(this), this;
2182
- },
2183
- remove: function() {
2184
- return this.removeFrom(this._map || this._mapToAdd);
2185
- },
2186
- removeFrom: function(e) {
2187
- return e && e.removeLayer(this), this;
2188
- },
2189
- getPane: function(e) {
2190
- return this._map.getPane(e ? this.options[e] || e : this.options.pane);
2191
- },
2192
- addInteractiveTarget: function(e) {
2193
- return this._map._targets[o(e)] = this, this;
2194
- },
2195
- removeInteractiveTarget: function(e) {
2196
- return delete this._map._targets[o(e)], this;
2197
- },
2198
- getAttribution: function() {
2199
- return this.options.attribution;
2200
- },
2201
- _layerAdd: function(e) {
2202
- var t = e.target;
2203
- if (t.hasLayer(this)) {
2204
- if (this._map = t, this._zoomAnimated = t._zoomAnimated, this.getEvents) {
2205
- var n = this.getEvents();
2206
- t.on(n, this), this.once("remove", function() {
2207
- t.off(n, this);
2208
- }, this);
2209
- }
2210
- this.onAdd(t), this.fire("add"), t.fire("layeradd", { layer: this });
2211
- }
2212
- }
2213
- });
2214
- K.include({
2215
- addLayer: function(e) {
2216
- if (!e._layerAdd) throw Error("The provided object is not a Layer.");
2217
- var t = o(e);
2218
- return this._layers[t] ? this : (this._layers[t] = e, e._mapToAdd = this, e.beforeAdd && e.beforeAdd(this), this.whenReady(e._layerAdd, e), this);
2219
- },
2220
- removeLayer: function(e) {
2221
- var t = o(e);
2222
- return this._layers[t] ? (this._loaded && e.onRemove(this), delete this._layers[t], this._loaded && (this.fire("layerremove", { layer: e }), e.fire("remove")), e._map = e._mapToAdd = null, this) : this;
2223
- },
2224
- hasLayer: function(e) {
2225
- return o(e) in this._layers;
2226
- },
2227
- eachLayer: function(e, t) {
2228
- for (var n in this._layers) e.call(t, this._layers[n]);
2229
- return this;
2230
- },
2231
- _addLayers: function(e) {
2232
- e = e ? _(e) ? e : [e] : [];
2233
- for (var t = 0, n = e.length; t < n; t++) this.addLayer(e[t]);
2234
- },
2235
- _addZoomLimit: function(e) {
2236
- (!isNaN(e.options.maxZoom) || !isNaN(e.options.minZoom)) && (this._zoomBoundLayers[o(e)] = e, this._updateZoomLevels());
2237
- },
2238
- _removeZoomLimit: function(e) {
2239
- var t = o(e);
2240
- this._zoomBoundLayers[t] && (delete this._zoomBoundLayers[t], this._updateZoomLevels());
2241
- },
2242
- _updateZoomLevels: function() {
2243
- var e = Infinity, t = -Infinity, n = this._getZoomSpan();
2244
- for (var r in this._zoomBoundLayers) {
2245
- var i = this._zoomBoundLayers[r].options;
2246
- e = i.minZoom === void 0 ? e : Math.min(e, i.minZoom), t = i.maxZoom === void 0 ? t : Math.max(t, i.maxZoom);
2247
- }
2248
- this._layersMaxZoom = t === -Infinity ? void 0 : t, this._layersMinZoom = e === Infinity ? void 0 : e, n !== this._getZoomSpan() && this.fire("zoomlevelschange"), this.options.maxZoom === void 0 && this._layersMaxZoom && this.getZoom() > this._layersMaxZoom && this.setZoom(this._layersMaxZoom), this.options.minZoom === void 0 && this._layersMinZoom && this.getZoom() < this._layersMinZoom && this.setZoom(this._layersMinZoom);
2249
- }
2250
- });
2251
- var Jn = X.extend({
2252
- initialize: function(e, t) {
2253
- p(this, t), this._layers = {};
2254
- var n, r;
2255
- if (e) for (n = 0, r = e.length; n < r; n++) this.addLayer(e[n]);
2256
- },
2257
- addLayer: function(e) {
2258
- var t = this.getLayerId(e);
2259
- return this._layers[t] = e, this._map && this._map.addLayer(e), this;
2260
- },
2261
- removeLayer: function(e) {
2262
- var t = e in this._layers ? e : this.getLayerId(e);
2263
- return this._map && this._layers[t] && this._map.removeLayer(this._layers[t]), delete this._layers[t], this;
2264
- },
2265
- hasLayer: function(e) {
2266
- return (typeof e == "number" ? e : this.getLayerId(e)) in this._layers;
2267
- },
2268
- clearLayers: function() {
2269
- return this.eachLayer(this.removeLayer, this);
2270
- },
2271
- invoke: function(e) {
2272
- var t = Array.prototype.slice.call(arguments, 1), n, r;
2273
- for (n in this._layers) r = this._layers[n], r[e] && r[e].apply(r, t);
2274
- return this;
2275
- },
2276
- onAdd: function(e) {
2277
- this.eachLayer(e.addLayer, e);
2278
- },
2279
- onRemove: function(e) {
2280
- this.eachLayer(e.removeLayer, e);
2281
- },
2282
- eachLayer: function(e, t) {
2283
- for (var n in this._layers) e.call(t, this._layers[n]);
2284
- return this;
2285
- },
2286
- getLayer: function(e) {
2287
- return this._layers[e];
2288
- },
2289
- getLayers: function() {
2290
- var e = [];
2291
- return this.eachLayer(e.push, e), e;
2292
- },
2293
- setZIndex: function(e) {
2294
- return this.invoke("setZIndex", e);
2295
- },
2296
- getLayerId: function(e) {
2297
- return o(e);
2298
- }
2299
- }), Yn = function(e, t) {
2300
- return new Jn(e, t);
2301
- }, Z = Jn.extend({
2302
- addLayer: function(e) {
2303
- return this.hasLayer(e) ? this : (e.addEventParent(this), Jn.prototype.addLayer.call(this, e), this.fire("layeradd", { layer: e }));
2304
- },
2305
- removeLayer: function(e) {
2306
- return this.hasLayer(e) ? (e in this._layers && (e = this._layers[e]), e.removeEventParent(this), Jn.prototype.removeLayer.call(this, e), this.fire("layerremove", { layer: e })) : this;
2307
- },
2308
- setStyle: function(e) {
2309
- return this.invoke("setStyle", e);
2310
- },
2311
- bringToFront: function() {
2312
- return this.invoke("bringToFront");
2313
- },
2314
- bringToBack: function() {
2315
- return this.invoke("bringToBack");
2316
- },
2317
- getBounds: function() {
2318
- var e = new E();
2319
- for (var t in this._layers) {
2320
- var n = this._layers[t];
2321
- e.extend(n.getBounds ? n.getBounds() : n.getLatLng());
2322
- }
2323
- return e;
2324
- }
2325
- }), Xn = function(e, t) {
2326
- return new Z(e, t);
2327
- }, Zn = b.extend({
2328
- options: {
2329
- popupAnchor: [0, 0],
2330
- tooltipAnchor: [0, 0],
2331
- crossOrigin: !1
2332
- },
2333
- initialize: function(e) {
2334
- p(this, e);
2335
- },
2336
- createIcon: function(e) {
2337
- return this._createIcon("icon", e);
2338
- },
2339
- createShadow: function(e) {
2340
- return this._createIcon("shadow", e);
2341
- },
2342
- _createIcon: function(e, t) {
2343
- var n = this._getIconUrl(e);
2344
- if (!n) {
2345
- if (e === "icon") throw Error("iconUrl not set in Icon options (see the docs).");
2346
- return null;
2347
- }
2348
- var r = this._createImg(n, t && t.tagName === "IMG" ? t : null);
2349
- return this._setIconStyles(r, e), (this.options.crossOrigin || this.options.crossOrigin === "") && (r.crossOrigin = this.options.crossOrigin === !0 ? "" : this.options.crossOrigin), r;
2350
- },
2351
- _setIconStyles: function(e, t) {
2352
- var n = this.options, r = n[t + "Size"];
2353
- typeof r == "number" && (r = [r, r]);
2354
- var i = C(r), a = C(t === "shadow" && n.shadowAnchor || n.iconAnchor || i && i.divideBy(2, !0));
2355
- e.className = "leaflet-marker-" + t + " " + (n.className || ""), a && (e.style.marginLeft = -a.x + "px", e.style.marginTop = -a.y + "px"), i && (e.style.width = i.x + "px", e.style.height = i.y + "px");
2356
- },
2357
- _createImg: function(e, t) {
2358
- return t ||= document.createElement("img"), t.src = e, t;
2359
- },
2360
- _getIconUrl: function(e) {
2361
- return P.retina && this.options[e + "RetinaUrl"] || this.options[e + "Url"];
2362
- }
2363
- });
2364
- function Qn(e) {
2365
- return new Zn(e);
2366
- }
2367
- var $n = Zn.extend({
2368
- options: {
2369
- iconUrl: "marker-icon.png",
2370
- iconRetinaUrl: "marker-icon-2x.png",
2371
- shadowUrl: "marker-shadow.png",
2372
- iconSize: [25, 41],
2373
- iconAnchor: [12, 41],
2374
- popupAnchor: [1, -34],
2375
- tooltipAnchor: [16, -28],
2376
- shadowSize: [41, 41]
2377
- },
2378
- _getIconUrl: function(e) {
2379
- return typeof $n.imagePath != "string" && ($n.imagePath = this._detectIconPath()), (this.options.imagePath || $n.imagePath) + Zn.prototype._getIconUrl.call(this, e);
2380
- },
2381
- _stripUrl: function(e) {
2382
- var t = function(e, t, n) {
2383
- var r = t.exec(e);
2384
- return r && r[n];
2385
- };
2386
- return e = t(e, /^url\((['"])?(.+)\1\)$/, 2), e && t(e, /^(.*)marker-icon\.png$/, 1);
2387
- },
2388
- _detectIconPath: function() {
2389
- var e = F("div", "leaflet-default-icon-path", document.body), t = Tt(e, "background-image") || Tt(e, "backgroundImage");
2390
- if (document.body.removeChild(e), t = this._stripUrl(t), t) return t;
2391
- var n = document.querySelector("link[href$=\"leaflet.css\"]");
2392
- return n ? n.href.substring(0, n.href.length - 11 - 1) : "";
2393
- }
2394
- }), er = J.extend({
2395
- initialize: function(e) {
2396
- this._marker = e;
2397
- },
2398
- addHooks: function() {
2399
- var e = this._marker._icon;
2400
- this._draggable ||= new Sn(e, e, !0), this._draggable.on({
2401
- dragstart: this._onDragStart,
2402
- predrag: this._onPreDrag,
2403
- drag: this._onDrag,
2404
- dragend: this._onDragEnd
2405
- }, this).enable(), R(e, "leaflet-marker-draggable");
2406
- },
2407
- removeHooks: function() {
2408
- this._draggable.off({
2409
- dragstart: this._onDragStart,
2410
- predrag: this._onPreDrag,
2411
- drag: this._onDrag,
2412
- dragend: this._onDragEnd
2413
- }, this).disable(), this._marker._icon && z(this._marker._icon, "leaflet-marker-draggable");
2414
- },
2415
- moved: function() {
2416
- return this._draggable && this._draggable._moved;
2417
- },
2418
- _adjustPan: function(e) {
2419
- var t = this._marker, n = t._map, r = this._marker.options.autoPanSpeed, i = this._marker.options.autoPanPadding, a = Ft(t._icon), o = n.getPixelBounds(), s = n.getPixelOrigin(), c = T(o.min._subtract(s).add(i), o.max._subtract(s).subtract(i));
2420
- if (!c.contains(a)) {
2421
- var l = C((Math.max(c.max.x, a.x) - c.max.x) / (o.max.x - c.max.x) - (Math.min(c.min.x, a.x) - c.min.x) / (o.min.x - c.min.x), (Math.max(c.max.y, a.y) - c.max.y) / (o.max.y - c.max.y) - (Math.min(c.min.y, a.y) - c.min.y) / (o.min.y - c.min.y)).multiplyBy(r);
2422
- n.panBy(l, { animate: !1 }), this._draggable._newPos._add(l), this._draggable._startPos._add(l), V(t._icon, this._draggable._newPos), this._onDrag(e), this._panRequest = v(this._adjustPan.bind(this, e));
2423
- }
2424
- },
2425
- _onDragStart: function() {
2426
- this._oldLatLng = this._marker.getLatLng(), this._marker.closePopup && this._marker.closePopup(), this._marker.fire("movestart").fire("dragstart");
2427
- },
2428
- _onPreDrag: function(e) {
2429
- this._marker.options.autoPan && (y(this._panRequest), this._panRequest = v(this._adjustPan.bind(this, e)));
2430
- },
2431
- _onDrag: function(e) {
2432
- var t = this._marker, n = t._shadow, r = Ft(t._icon), i = t._map.layerPointToLatLng(r);
2433
- n && V(n, r), t._latlng = i, e.latlng = i, e.oldLatLng = this._oldLatLng, t.fire("move", e).fire("drag", e);
2434
- },
2435
- _onDragEnd: function(e) {
2436
- y(this._panRequest), delete this._oldLatLng, this._marker.fire("moveend").fire("dragend", e);
2437
- }
2438
- }), tr = X.extend({
2439
- options: {
2440
- icon: new $n(),
2441
- interactive: !0,
2442
- keyboard: !0,
2443
- title: "",
2444
- alt: "Marker",
2445
- zIndexOffset: 0,
2446
- opacity: 1,
2447
- riseOnHover: !1,
2448
- riseOffset: 250,
2449
- pane: "markerPane",
2450
- shadowPane: "shadowPane",
2451
- bubblingMouseEvents: !1,
2452
- autoPanOnFocus: !0,
2453
- draggable: !1,
2454
- autoPan: !1,
2455
- autoPanPadding: [50, 50],
2456
- autoPanSpeed: 10
2457
- },
2458
- initialize: function(e, t) {
2459
- p(this, t), this._latlng = k(e);
2460
- },
2461
- onAdd: function(e) {
2462
- this._zoomAnimated = this._zoomAnimated && e.options.markerZoomAnimation, this._zoomAnimated && e.on("zoomanim", this._animateZoom, this), this._initIcon(), this.update();
2463
- },
2464
- onRemove: function(e) {
2465
- this.dragging && this.dragging.enabled() && (this.options.draggable = !0, this.dragging.removeHooks()), delete this.dragging, this._zoomAnimated && e.off("zoomanim", this._animateZoom, this), this._removeIcon(), this._removeShadow();
2466
- },
2467
- getEvents: function() {
2468
- return {
2469
- zoom: this.update,
2470
- viewreset: this.update
2471
- };
2472
- },
2473
- getLatLng: function() {
2474
- return this._latlng;
2475
- },
2476
- setLatLng: function(e) {
2477
- var t = this._latlng;
2478
- return this._latlng = k(e), this.update(), this.fire("move", {
2479
- oldLatLng: t,
2480
- latlng: this._latlng
2481
- });
2482
- },
2483
- setZIndexOffset: function(e) {
2484
- return this.options.zIndexOffset = e, this.update();
2485
- },
2486
- getIcon: function() {
2487
- return this.options.icon;
2488
- },
2489
- setIcon: function(e) {
2490
- return this.options.icon = e, this._map && (this._initIcon(), this.update()), this._popup && this.bindPopup(this._popup, this._popup.options), this;
2491
- },
2492
- getElement: function() {
2493
- return this._icon;
2494
- },
2495
- update: function() {
2496
- if (this._icon && this._map) {
2497
- var e = this._map.latLngToLayerPoint(this._latlng).round();
2498
- this._setPos(e);
2499
- }
2500
- return this;
2501
- },
2502
- _initIcon: function() {
2503
- var e = this.options, t = "leaflet-zoom-" + (this._zoomAnimated ? "animated" : "hide"), n = e.icon.createIcon(this._icon), r = !1;
2504
- n !== this._icon && (this._icon && this._removeIcon(), r = !0, e.title && (n.title = e.title), n.tagName === "IMG" && (n.alt = e.alt || "")), R(n, t), e.keyboard && (n.tabIndex = "0", n.setAttribute("role", "button")), this._icon = n, e.riseOnHover && this.on({
2505
- mouseover: this._bringToFront,
2506
- mouseout: this._resetZIndex
2507
- }), this.options.autoPanOnFocus && H(n, "focus", this._panOnFocus, this);
2508
- var i = e.icon.createShadow(this._shadow), a = !1;
2509
- i !== this._shadow && (this._removeShadow(), a = !0), i && (R(i, t), i.alt = ""), this._shadow = i, e.opacity < 1 && this._updateOpacity(), r && this.getPane().appendChild(this._icon), this._initInteraction(), i && a && this.getPane(e.shadowPane).appendChild(this._shadow);
2510
- },
2511
- _removeIcon: function() {
2512
- this.options.riseOnHover && this.off({
2513
- mouseover: this._bringToFront,
2514
- mouseout: this._resetZIndex
2515
- }), this.options.autoPanOnFocus && W(this._icon, "focus", this._panOnFocus, this), I(this._icon), this.removeInteractiveTarget(this._icon), this._icon = null;
2516
- },
2517
- _removeShadow: function() {
2518
- this._shadow && I(this._shadow), this._shadow = null;
2519
- },
2520
- _setPos: function(e) {
2521
- this._icon && V(this._icon, e), this._shadow && V(this._shadow, e), this._zIndex = e.y + this.options.zIndexOffset, this._resetZIndex();
2522
- },
2523
- _updateZIndex: function(e) {
2524
- this._icon && (this._icon.style.zIndex = this._zIndex + e);
2525
- },
2526
- _animateZoom: function(e) {
2527
- var t = this._map._latLngToNewLayerPoint(this._latlng, e.zoom, e.center).round();
2528
- this._setPos(t);
2529
- },
2530
- _initInteraction: function() {
2531
- if (this.options.interactive && (R(this._icon, "leaflet-interactive"), this.addInteractiveTarget(this._icon), er)) {
2532
- var e = this.options.draggable;
2533
- this.dragging && (e = this.dragging.enabled(), this.dragging.disable()), this.dragging = new er(this), e && this.dragging.enable();
2534
- }
2535
- },
2536
- setOpacity: function(e) {
2537
- return this.options.opacity = e, this._map && this._updateOpacity(), this;
2538
- },
2539
- _updateOpacity: function() {
2540
- var e = this.options.opacity;
2541
- this._icon && B(this._icon, e), this._shadow && B(this._shadow, e);
2542
- },
2543
- _bringToFront: function() {
2544
- this._updateZIndex(this.options.riseOffset);
2545
- },
2546
- _resetZIndex: function() {
2547
- this._updateZIndex(0);
2548
- },
2549
- _panOnFocus: function() {
2550
- var e = this._map;
2551
- if (e) {
2552
- var t = this.options.icon.options, n = t.iconSize ? C(t.iconSize) : C(0, 0), r = t.iconAnchor ? C(t.iconAnchor) : C(0, 0);
2553
- e.panInside(this._latlng, {
2554
- paddingTopLeft: r,
2555
- paddingBottomRight: n.subtract(r)
2556
- });
2557
- }
2558
- },
2559
- _getPopupAnchor: function() {
2560
- return this.options.icon.options.popupAnchor;
2561
- },
2562
- _getTooltipAnchor: function() {
2563
- return this.options.icon.options.tooltipAnchor;
2564
- }
2565
- });
2566
- function nr(e, t) {
2567
- return new tr(e, t);
2568
- }
2569
- var rr = X.extend({
2570
- options: {
2571
- stroke: !0,
2572
- color: "#3388ff",
2573
- weight: 3,
2574
- opacity: 1,
2575
- lineCap: "round",
2576
- lineJoin: "round",
2577
- dashArray: null,
2578
- dashOffset: null,
2579
- fill: !1,
2580
- fillColor: null,
2581
- fillOpacity: .2,
2582
- fillRule: "evenodd",
2583
- interactive: !0,
2584
- bubblingMouseEvents: !0
2585
- },
2586
- beforeAdd: function(e) {
2587
- this._renderer = e.getRenderer(this);
2588
- },
2589
- onAdd: function() {
2590
- this._renderer._initPath(this), this._reset(), this._renderer._addPath(this);
2591
- },
2592
- onRemove: function() {
2593
- this._renderer._removePath(this);
2594
- },
2595
- redraw: function() {
2596
- return this._map && this._renderer._updatePath(this), this;
2597
- },
2598
- setStyle: function(e) {
2599
- return p(this, e), this._renderer && (this._renderer._updateStyle(this), this.options.stroke && e && Object.prototype.hasOwnProperty.call(e, "weight") && this._updateBounds()), this;
2600
- },
2601
- bringToFront: function() {
2602
- return this._renderer && this._renderer._bringToFront(this), this;
2603
- },
2604
- bringToBack: function() {
2605
- return this._renderer && this._renderer._bringToBack(this), this;
2606
- },
2607
- getElement: function() {
2608
- return this._path;
2609
- },
2610
- _reset: function() {
2611
- this._project(), this._update();
2612
- },
2613
- _clickTolerance: function() {
2614
- return (this.options.stroke ? this.options.weight / 2 : 0) + (this._renderer.options.tolerance || 0);
2615
- }
2616
- }), ir = rr.extend({
2617
- options: {
2618
- fill: !0,
2619
- radius: 10
2620
- },
2621
- initialize: function(e, t) {
2622
- p(this, t), this._latlng = k(e), this._radius = this.options.radius;
2623
- },
2624
- setLatLng: function(e) {
2625
- var t = this._latlng;
2626
- return this._latlng = k(e), this.redraw(), this.fire("move", {
2627
- oldLatLng: t,
2628
- latlng: this._latlng
2629
- });
2630
- },
2631
- getLatLng: function() {
2632
- return this._latlng;
2633
- },
2634
- setRadius: function(e) {
2635
- return this.options.radius = this._radius = e, this.redraw();
2636
- },
2637
- getRadius: function() {
2638
- return this._radius;
2639
- },
2640
- setStyle: function(e) {
2641
- var t = e && e.radius || this._radius;
2642
- return rr.prototype.setStyle.call(this, e), this.setRadius(t), this;
2643
- },
2644
- _project: function() {
2645
- this._point = this._map.latLngToLayerPoint(this._latlng), this._updateBounds();
2646
- },
2647
- _updateBounds: function() {
2648
- var e = this._radius, t = this._radiusY || e, n = this._clickTolerance(), r = [e + n, t + n];
2649
- this._pxBounds = new w(this._point.subtract(r), this._point.add(r));
2650
- },
2651
- _update: function() {
2652
- this._map && this._updatePath();
2653
- },
2654
- _updatePath: function() {
2655
- this._renderer._updateCircle(this);
2656
- },
2657
- _empty: function() {
2658
- return this._radius && !this._renderer._bounds.intersects(this._pxBounds);
2659
- },
2660
- _containsPoint: function(e) {
2661
- return e.distanceTo(this._point) <= this._radius + this._clickTolerance();
2662
- }
2663
- });
2664
- function ar(e, t) {
2665
- return new ir(e, t);
2666
- }
2667
- var or = ir.extend({
2668
- initialize: function(e, t, r) {
2669
- if (typeof t == "number" && (t = n({}, r, { radius: t })), p(this, t), this._latlng = k(e), isNaN(this.options.radius)) throw Error("Circle radius cannot be NaN");
2670
- this._mRadius = this.options.radius;
2671
- },
2672
- setRadius: function(e) {
2673
- return this._mRadius = e, this.redraw();
2674
- },
2675
- getRadius: function() {
2676
- return this._mRadius;
2677
- },
2678
- getBounds: function() {
2679
- var e = [this._radius, this._radiusY || this._radius];
2680
- return new E(this._map.layerPointToLatLng(this._point.subtract(e)), this._map.layerPointToLatLng(this._point.add(e)));
2681
- },
2682
- setStyle: rr.prototype.setStyle,
2683
- _project: function() {
2684
- var e = this._latlng.lng, t = this._latlng.lat, n = this._map, r = n.options.crs;
2685
- if (r.distance === j.distance) {
2686
- var i = Math.PI / 180, a = this._mRadius / j.R / i, o = n.project([t + a, e]), s = n.project([t - a, e]), c = o.add(s).divideBy(2), l = n.unproject(c).lat, u = Math.acos((Math.cos(a * i) - Math.sin(t * i) * Math.sin(l * i)) / (Math.cos(t * i) * Math.cos(l * i))) / i;
2687
- (isNaN(u) || u === 0) && (u = a / Math.cos(Math.PI / 180 * t)), this._point = c.subtract(n.getPixelOrigin()), this._radius = isNaN(u) ? 0 : c.x - n.project([l, e - u]).x, this._radiusY = c.y - o.y;
2688
- } else {
2689
- var d = r.unproject(r.project(this._latlng).subtract([this._mRadius, 0]));
2690
- this._point = n.latLngToLayerPoint(this._latlng), this._radius = this._point.x - n.latLngToLayerPoint(d).x;
2691
- }
2692
- this._updateBounds();
2693
- }
2694
- });
2695
- function sr(e, t, n) {
2696
- return new or(e, t, n);
2697
- }
2698
- var Q = rr.extend({
2699
- options: {
2700
- smoothFactor: 1,
2701
- noClip: !1
2702
- },
2703
- initialize: function(e, t) {
2704
- p(this, t), this._setLatLngs(e);
2705
- },
2706
- getLatLngs: function() {
2707
- return this._latlngs;
2708
- },
2709
- setLatLngs: function(e) {
2710
- return this._setLatLngs(e), this.redraw();
2711
- },
2712
- isEmpty: function() {
2713
- return !this._latlngs.length;
2714
- },
2715
- closestLayerPoint: function(e) {
2716
- for (var t = Infinity, n = null, r = Rn, i, a, o = 0, s = this._parts.length; o < s; o++) for (var c = this._parts[o], l = 1, u = c.length; l < u; l++) {
2717
- i = c[l - 1], a = c[l];
2718
- var d = r(e, i, a, !0);
2719
- d < t && (t = d, n = r(e, i, a));
2720
- }
2721
- return n && (n.distance = Math.sqrt(t)), n;
2722
- },
2723
- getCenter: function() {
2724
- if (!this._map) throw Error("Must add layer to map before using getCenter()");
2725
- return Bn(this._defaultShape(), this._map.options.crs);
2726
- },
2727
- getBounds: function() {
2728
- return this._bounds;
2729
- },
2730
- addLatLng: function(e, t) {
2731
- return t ||= this._defaultShape(), e = k(e), t.push(e), this._bounds.extend(e), this.redraw();
2732
- },
2733
- _setLatLngs: function(e) {
2734
- this._bounds = new E(), this._latlngs = this._convertLatLngs(e);
2735
- },
2736
- _defaultShape: function() {
2737
- return Y(this._latlngs) ? this._latlngs : this._latlngs[0];
2738
- },
2739
- _convertLatLngs: function(e) {
2740
- for (var t = [], n = Y(e), r = 0, i = e.length; r < i; r++) n ? (t[r] = k(e[r]), this._bounds.extend(t[r])) : t[r] = this._convertLatLngs(e[r]);
2741
- return t;
2742
- },
2743
- _project: function() {
2744
- var e = new w();
2745
- this._rings = [], this._projectLatlngs(this._latlngs, this._rings, e), this._bounds.isValid() && e.isValid() && (this._rawPxBounds = e, this._updateBounds());
2746
- },
2747
- _updateBounds: function() {
2748
- var e = this._clickTolerance(), t = new S(e, e);
2749
- this._rawPxBounds && (this._pxBounds = new w([this._rawPxBounds.min.subtract(t), this._rawPxBounds.max.add(t)]));
2750
- },
2751
- _projectLatlngs: function(e, t, n) {
2752
- var r = e[0] instanceof O, i = e.length, a, o;
2753
- if (r) {
2754
- for (o = [], a = 0; a < i; a++) o[a] = this._map.latLngToLayerPoint(e[a]), n.extend(o[a]);
2755
- t.push(o);
2756
- } else for (a = 0; a < i; a++) this._projectLatlngs(e[a], t, n);
2757
- },
2758
- _clipPoints: function() {
2759
- var e = this._renderer._bounds;
2760
- if (this._parts = [], this._pxBounds && this._pxBounds.intersects(e)) {
2761
- if (this.options.noClip) {
2762
- this._parts = this._rings;
2763
- return;
2764
- }
2765
- for (var t = this._parts, n = 0, r, i = 0, a = this._rings.length, o, s, c; n < a; n++) for (c = this._rings[n], r = 0, o = c.length; r < o - 1; r++) s = Pn(c[r], c[r + 1], e, r, !0), s && (t[i] = t[i] || [], t[i].push(s[0]), (s[1] !== c[r + 1] || r === o - 2) && (t[i].push(s[1]), i++));
2766
- }
2767
- },
2768
- _simplifyPoints: function() {
2769
- for (var e = this._parts, t = this.options.smoothFactor, n = 0, r = e.length; n < r; n++) e[n] = Dn(e[n], t);
2770
- },
2771
- _update: function() {
2772
- this._map && (this._clipPoints(), this._simplifyPoints(), this._updatePath());
2773
- },
2774
- _updatePath: function() {
2775
- this._renderer._updatePoly(this);
2776
- },
2777
- _containsPoint: function(e, t) {
2778
- var n, r, i, a, o, s, c = this._clickTolerance();
2779
- if (!this._pxBounds || !this._pxBounds.contains(e)) return !1;
2780
- for (n = 0, a = this._parts.length; n < a; n++) for (s = this._parts[n], r = 0, o = s.length, i = o - 1; r < o; i = r++) if ((t || r !== 0) && On(e, s[i], s[r]) <= c) return !0;
2781
- return !1;
2782
- }
2783
- });
2784
- function cr(e, t) {
2785
- return new Q(e, t);
2786
- }
2787
- Q._flat = zn;
2788
- var lr = Q.extend({
2789
- options: { fill: !0 },
2790
- isEmpty: function() {
2791
- return !this._latlngs.length || !this._latlngs[0].length;
2792
- },
2793
- getCenter: function() {
2794
- if (!this._map) throw Error("Must add layer to map before using getCenter()");
2795
- return wn(this._defaultShape(), this._map.options.crs);
2796
- },
2797
- _convertLatLngs: function(e) {
2798
- var t = Q.prototype._convertLatLngs.call(this, e), n = t.length;
2799
- return n >= 2 && t[0] instanceof O && t[0].equals(t[n - 1]) && t.pop(), t;
2800
- },
2801
- _setLatLngs: function(e) {
2802
- Q.prototype._setLatLngs.call(this, e), Y(this._latlngs) && (this._latlngs = [this._latlngs]);
2803
- },
2804
- _defaultShape: function() {
2805
- return Y(this._latlngs[0]) ? this._latlngs[0] : this._latlngs[0][0];
2806
- },
2807
- _clipPoints: function() {
2808
- var e = this._renderer._bounds, t = this.options.weight, n = new S(t, t);
2809
- if (e = new w(e.min.subtract(n), e.max.add(n)), this._parts = [], this._pxBounds && this._pxBounds.intersects(e)) {
2810
- if (this.options.noClip) {
2811
- this._parts = this._rings;
2812
- return;
2813
- }
2814
- for (var r = 0, i = this._rings.length, a; r < i; r++) a = Cn(this._rings[r], e, !0), a.length && this._parts.push(a);
2815
- }
2816
- },
2817
- _updatePath: function() {
2818
- this._renderer._updatePoly(this, !0);
2819
- },
2820
- _containsPoint: function(e) {
2821
- var t = !1, n, r, i, a, o, s, c, l;
2822
- if (!this._pxBounds || !this._pxBounds.contains(e)) return !1;
2823
- for (a = 0, c = this._parts.length; a < c; a++) for (n = this._parts[a], o = 0, l = n.length, s = l - 1; o < l; s = o++) r = n[o], i = n[s], r.y > e.y != i.y > e.y && e.x < (i.x - r.x) * (e.y - r.y) / (i.y - r.y) + r.x && (t = !t);
2824
- return t || Q.prototype._containsPoint.call(this, e, !0);
2825
- }
2826
- });
2827
- function ur(e, t) {
2828
- return new lr(e, t);
2829
- }
2830
- var dr = Z.extend({
2831
- initialize: function(e, t) {
2832
- p(this, t), this._layers = {}, e && this.addData(e);
2833
- },
2834
- addData: function(e) {
2835
- var t = _(e) ? e : e.features, n, r, i;
2836
- if (t) {
2837
- for (n = 0, r = t.length; n < r; n++) i = t[n], (i.geometries || i.geometry || i.features || i.coordinates) && this.addData(i);
2838
- return this;
2839
- }
2840
- var a = this.options;
2841
- if (a.filter && !a.filter(e)) return this;
2842
- var o = fr(e, a);
2843
- return o ? (o.feature = yr(e), o.defaultOptions = o.options, this.resetStyle(o), a.onEachFeature && a.onEachFeature(e, o), this.addLayer(o)) : this;
2844
- },
2845
- resetStyle: function(e) {
2846
- return e === void 0 ? this.eachLayer(this.resetStyle, this) : (e.options = n({}, e.defaultOptions), this._setLayerStyle(e, this.options.style), this);
2847
- },
2848
- setStyle: function(e) {
2849
- return this.eachLayer(function(t) {
2850
- this._setLayerStyle(t, e);
2851
- }, this);
2852
- },
2853
- _setLayerStyle: function(e, t) {
2854
- e.setStyle && (typeof t == "function" && (t = t(e.feature)), e.setStyle(t));
2855
- }
2856
- });
2857
- function fr(e, t) {
2858
- var n = e.type === "Feature" ? e.geometry : e, r = n ? n.coordinates : null, i = [], a = t && t.pointToLayer, o = t && t.coordsToLatLng || mr, s, c, l, u;
2859
- if (!r && !n) return null;
2860
- switch (n.type) {
2861
- case "Point": return s = o(r), pr(a, e, s, t);
2862
- case "MultiPoint":
2863
- for (l = 0, u = r.length; l < u; l++) s = o(r[l]), i.push(pr(a, e, s, t));
2864
- return new Z(i);
2865
- case "LineString":
2866
- case "MultiLineString": return c = hr(r, n.type === "LineString" ? 0 : 1, o), new Q(c, t);
2867
- case "Polygon":
2868
- case "MultiPolygon": return c = hr(r, n.type === "Polygon" ? 1 : 2, o), new lr(c, t);
2869
- case "GeometryCollection":
2870
- for (l = 0, u = n.geometries.length; l < u; l++) {
2871
- var d = fr({
2872
- geometry: n.geometries[l],
2873
- type: "Feature",
2874
- properties: e.properties
2875
- }, t);
2876
- d && i.push(d);
2877
- }
2878
- return new Z(i);
2879
- case "FeatureCollection":
2880
- for (l = 0, u = n.features.length; l < u; l++) {
2881
- var f = fr(n.features[l], t);
2882
- f && i.push(f);
2883
- }
2884
- return new Z(i);
2885
- default: throw Error("Invalid GeoJSON object.");
2886
- }
2887
- }
2888
- function pr(e, t, n, r) {
2889
- return e ? e(t, n) : new tr(n, r && r.markersInheritOptions && r);
2890
- }
2891
- function mr(e) {
2892
- return new O(e[1], e[0], e[2]);
2893
- }
2894
- function hr(e, t, n) {
2895
- for (var r = [], i = 0, a = e.length, o; i < a; i++) o = t ? hr(e[i], t - 1, n) : (n || mr)(e[i]), r.push(o);
2896
- return r;
2897
- }
2898
- function gr(e, t) {
2899
- return e = k(e), e.alt === void 0 ? [u(e.lng, t), u(e.lat, t)] : [
2900
- u(e.lng, t),
2901
- u(e.lat, t),
2902
- u(e.alt, t)
2903
- ];
2904
- }
2905
- function _r(e, t, n, r) {
2906
- for (var i = [], a = 0, o = e.length; a < o; a++) i.push(t ? _r(e[a], Y(e[a]) ? 0 : t - 1, n, r) : gr(e[a], r));
2907
- return !t && n && i.length > 0 && i.push(i[0].slice()), i;
2908
- }
2909
- function vr(e, t) {
2910
- return e.feature ? n({}, e.feature, { geometry: t }) : yr(t);
2911
- }
2912
- function yr(e) {
2913
- return e.type === "Feature" || e.type === "FeatureCollection" ? e : {
2914
- type: "Feature",
2915
- properties: {},
2916
- geometry: e
2917
- };
2918
- }
2919
- var br = { toGeoJSON: function(e) {
2920
- return vr(this, {
2921
- type: "Point",
2922
- coordinates: gr(this.getLatLng(), e)
2923
- });
2924
- } };
2925
- tr.include(br), or.include(br), ir.include(br), Q.include({ toGeoJSON: function(e) {
2926
- var t = !Y(this._latlngs), n = _r(this._latlngs, +!!t, !1, e);
2927
- return vr(this, {
2928
- type: (t ? "Multi" : "") + "LineString",
2929
- coordinates: n
2930
- });
2931
- } }), lr.include({ toGeoJSON: function(e) {
2932
- var t = !Y(this._latlngs), n = t && !Y(this._latlngs[0]), r = _r(this._latlngs, n ? 2 : +!!t, !0, e);
2933
- return t || (r = [r]), vr(this, {
2934
- type: (n ? "Multi" : "") + "Polygon",
2935
- coordinates: r
2936
- });
2937
- } }), Jn.include({
2938
- toMultiPoint: function(e) {
2939
- var t = [];
2940
- return this.eachLayer(function(n) {
2941
- t.push(n.toGeoJSON(e).geometry.coordinates);
2942
- }), vr(this, {
2943
- type: "MultiPoint",
2944
- coordinates: t
2945
- });
2946
- },
2947
- toGeoJSON: function(e) {
2948
- var t = this.feature && this.feature.geometry && this.feature.geometry.type;
2949
- if (t === "MultiPoint") return this.toMultiPoint(e);
2950
- var n = t === "GeometryCollection", r = [];
2951
- return this.eachLayer(function(t) {
2952
- if (t.toGeoJSON) {
2953
- var i = t.toGeoJSON(e);
2954
- if (n) r.push(i.geometry);
2955
- else {
2956
- var a = yr(i);
2957
- a.type === "FeatureCollection" ? r.push.apply(r, a.features) : r.push(a);
2958
- }
2959
- }
2960
- }), n ? vr(this, {
2961
- geometries: r,
2962
- type: "GeometryCollection"
2963
- }) : {
2964
- type: "FeatureCollection",
2965
- features: r
2966
- };
2967
- }
2968
- });
2969
- function xr(e, t) {
2970
- return new dr(e, t);
2971
- }
2972
- var Sr = xr, Cr = X.extend({
2973
- options: {
2974
- opacity: 1,
2975
- alt: "",
2976
- interactive: !1,
2977
- crossOrigin: !1,
2978
- errorOverlayUrl: "",
2979
- zIndex: 1,
2980
- className: ""
2981
- },
2982
- initialize: function(e, t, n) {
2983
- this._url = e, this._bounds = D(t), p(this, n);
2984
- },
2985
- onAdd: function() {
2986
- this._image || (this._initImage(), this.options.opacity < 1 && this._updateOpacity()), this.options.interactive && (R(this._image, "leaflet-interactive"), this.addInteractiveTarget(this._image)), this.getPane().appendChild(this._image), this._reset();
2987
- },
2988
- onRemove: function() {
2989
- I(this._image), this.options.interactive && this.removeInteractiveTarget(this._image);
2990
- },
2991
- setOpacity: function(e) {
2992
- return this.options.opacity = e, this._image && this._updateOpacity(), this;
2993
- },
2994
- setStyle: function(e) {
2995
- return e.opacity && this.setOpacity(e.opacity), this;
2996
- },
2997
- bringToFront: function() {
2998
- return this._map && Dt(this._image), this;
2999
- },
3000
- bringToBack: function() {
3001
- return this._map && Ot(this._image), this;
3002
- },
3003
- setUrl: function(e) {
3004
- return this._url = e, this._image && (this._image.src = e), this;
3005
- },
3006
- setBounds: function(e) {
3007
- return this._bounds = D(e), this._map && this._reset(), this;
3008
- },
3009
- getEvents: function() {
3010
- var e = {
3011
- zoom: this._reset,
3012
- viewreset: this._reset
3013
- };
3014
- return this._zoomAnimated && (e.zoomanim = this._animateZoom), e;
3015
- },
3016
- setZIndex: function(e) {
3017
- return this.options.zIndex = e, this._updateZIndex(), this;
3018
- },
3019
- getBounds: function() {
3020
- return this._bounds;
3021
- },
3022
- getElement: function() {
3023
- return this._image;
3024
- },
3025
- _initImage: function() {
3026
- var e = this._url.tagName === "IMG", t = this._image = e ? this._url : F("img");
3027
- if (R(t, "leaflet-image-layer"), this._zoomAnimated && R(t, "leaflet-zoom-animated"), this.options.className && R(t, this.options.className), t.onselectstart = l, t.onmousemove = l, t.onload = i(this.fire, this, "load"), t.onerror = i(this._overlayOnError, this, "error"), (this.options.crossOrigin || this.options.crossOrigin === "") && (t.crossOrigin = this.options.crossOrigin === !0 ? "" : this.options.crossOrigin), this.options.zIndex && this._updateZIndex(), e) {
3028
- this._url = t.src;
3029
- return;
3030
- }
3031
- t.src = this._url, t.alt = this.options.alt;
3032
- },
3033
- _animateZoom: function(e) {
3034
- var t = this._map.getZoomScale(e.zoom), n = this._map._latLngBoundsToNewLayerBounds(this._bounds, e.zoom, e.center).min;
3035
- Pt(this._image, n, t);
3036
- },
3037
- _reset: function() {
3038
- var e = this._image, t = new w(this._map.latLngToLayerPoint(this._bounds.getNorthWest()), this._map.latLngToLayerPoint(this._bounds.getSouthEast())), n = t.getSize();
3039
- V(e, t.min), e.style.width = n.x + "px", e.style.height = n.y + "px";
3040
- },
3041
- _updateOpacity: function() {
3042
- B(this._image, this.options.opacity);
3043
- },
3044
- _updateZIndex: function() {
3045
- this._image && this.options.zIndex !== void 0 && this.options.zIndex !== null && (this._image.style.zIndex = this.options.zIndex);
3046
- },
3047
- _overlayOnError: function() {
3048
- this.fire("error");
3049
- var e = this.options.errorOverlayUrl;
3050
- e && this._url !== e && (this._url = e, this._image.src = e);
3051
- },
3052
- getCenter: function() {
3053
- return this._bounds.getCenter();
3054
- }
3055
- }), wr = function(e, t, n) {
3056
- return new Cr(e, t, n);
3057
- }, Tr = Cr.extend({
3058
- options: {
3059
- autoplay: !0,
3060
- loop: !0,
3061
- keepAspectRatio: !0,
3062
- muted: !1,
3063
- playsInline: !0
3064
- },
3065
- _initImage: function() {
3066
- var e = this._url.tagName === "VIDEO", t = this._image = e ? this._url : F("video");
3067
- if (R(t, "leaflet-image-layer"), this._zoomAnimated && R(t, "leaflet-zoom-animated"), this.options.className && R(t, this.options.className), t.onselectstart = l, t.onmousemove = l, t.onloadeddata = i(this.fire, this, "load"), e) {
3068
- for (var n = t.getElementsByTagName("source"), r = [], a = 0; a < n.length; a++) r.push(n[a].src);
3069
- this._url = n.length > 0 ? r : [t.src];
3070
- return;
3071
- }
3072
- _(this._url) || (this._url = [this._url]), !this.options.keepAspectRatio && Object.prototype.hasOwnProperty.call(t.style, "objectFit") && (t.style.objectFit = "fill"), t.autoplay = !!this.options.autoplay, t.loop = !!this.options.loop, t.muted = !!this.options.muted, t.playsInline = !!this.options.playsInline;
3073
- for (var o = 0; o < this._url.length; o++) {
3074
- var s = F("source");
3075
- s.src = this._url[o], t.appendChild(s);
3076
- }
3077
- }
3078
- });
3079
- function Er(e, t, n) {
3080
- return new Tr(e, t, n);
3081
- }
3082
- var Dr = Cr.extend({ _initImage: function() {
3083
- var e = this._image = this._url;
3084
- R(e, "leaflet-image-layer"), this._zoomAnimated && R(e, "leaflet-zoom-animated"), this.options.className && R(e, this.options.className), e.onselectstart = l, e.onmousemove = l;
3085
- } });
3086
- function Or(e, t, n) {
3087
- return new Dr(e, t, n);
3088
- }
3089
- var $ = X.extend({
3090
- options: {
3091
- interactive: !1,
3092
- offset: [0, 0],
3093
- className: "",
3094
- pane: void 0,
3095
- content: ""
3096
- },
3097
- initialize: function(e, t) {
3098
- e && (e instanceof O || _(e)) ? (this._latlng = k(e), p(this, t)) : (p(this, e), this._source = t), this.options.content && (this._content = this.options.content);
3099
- },
3100
- openOn: function(e) {
3101
- return e = arguments.length ? e : this._source._map, e.hasLayer(this) || e.addLayer(this), this;
3102
- },
3103
- close: function() {
3104
- return this._map && this._map.removeLayer(this), this;
3105
- },
3106
- toggle: function(e) {
3107
- return this._map ? this.close() : (arguments.length ? this._source = e : e = this._source, this._prepareOpen(), this.openOn(e._map)), this;
3108
- },
3109
- onAdd: function(e) {
3110
- this._zoomAnimated = e._zoomAnimated, this._container || this._initLayout(), e._fadeAnimated && B(this._container, 0), clearTimeout(this._removeTimeout), this.getPane().appendChild(this._container), this.update(), e._fadeAnimated && B(this._container, 1), this.bringToFront(), this.options.interactive && (R(this._container, "leaflet-interactive"), this.addInteractiveTarget(this._container));
3111
- },
3112
- onRemove: function(e) {
3113
- e._fadeAnimated ? (B(this._container, 0), this._removeTimeout = setTimeout(i(I, void 0, this._container), 200)) : I(this._container), this.options.interactive && (z(this._container, "leaflet-interactive"), this.removeInteractiveTarget(this._container));
3114
- },
3115
- getLatLng: function() {
3116
- return this._latlng;
3117
- },
3118
- setLatLng: function(e) {
3119
- return this._latlng = k(e), this._map && (this._updatePosition(), this._adjustPan()), this;
3120
- },
3121
- getContent: function() {
3122
- return this._content;
3123
- },
3124
- setContent: function(e) {
3125
- return this._content = e, this.update(), this;
3126
- },
3127
- getElement: function() {
3128
- return this._container;
3129
- },
3130
- update: function() {
3131
- this._map && (this._container.style.visibility = "hidden", this._updateContent(), this._updateLayout(), this._updatePosition(), this._container.style.visibility = "", this._adjustPan());
3132
- },
3133
- getEvents: function() {
3134
- var e = {
3135
- zoom: this._updatePosition,
3136
- viewreset: this._updatePosition
3137
- };
3138
- return this._zoomAnimated && (e.zoomanim = this._animateZoom), e;
3139
- },
3140
- isOpen: function() {
3141
- return !!this._map && this._map.hasLayer(this);
3142
- },
3143
- bringToFront: function() {
3144
- return this._map && Dt(this._container), this;
3145
- },
3146
- bringToBack: function() {
3147
- return this._map && Ot(this._container), this;
3148
- },
3149
- _prepareOpen: function(e) {
3150
- var t = this._source;
3151
- if (!t._map) return !1;
3152
- if (t instanceof Z) {
3153
- t = null;
3154
- var n = this._source._layers;
3155
- for (var r in n) if (n[r]._map) {
3156
- t = n[r];
3157
- break;
3158
- }
3159
- if (!t) return !1;
3160
- this._source = t;
3161
- }
3162
- if (!e) {
3163
- if (t.getCenter) e = t.getCenter();
3164
- else if (t.getLatLng) e = t.getLatLng();
3165
- else if (t.getBounds) e = t.getBounds().getCenter();
3166
- else throw Error("Unable to get source layer LatLng.");
3167
- }
3168
- return this.setLatLng(e), this._map && this.update(), !0;
3169
- },
3170
- _updateContent: function() {
3171
- if (this._content) {
3172
- var e = this._contentNode, t = typeof this._content == "function" ? this._content(this._source || this) : this._content;
3173
- if (typeof t == "string") e.innerHTML = t;
3174
- else {
3175
- for (; e.hasChildNodes();) e.removeChild(e.firstChild);
3176
- e.appendChild(t);
3177
- }
3178
- this.fire("contentupdate");
3179
- }
3180
- },
3181
- _updatePosition: function() {
3182
- if (this._map) {
3183
- var e = this._map.latLngToLayerPoint(this._latlng), t = C(this.options.offset), n = this._getAnchor();
3184
- this._zoomAnimated ? V(this._container, e.add(n)) : t = t.add(e).add(n);
3185
- var r = this._containerBottom = -t.y, i = this._containerLeft = -Math.round(this._containerWidth / 2) + t.x;
3186
- this._container.style.bottom = r + "px", this._container.style.left = i + "px";
3187
- }
3188
- },
3189
- _getAnchor: function() {
3190
- return [0, 0];
3191
- }
3192
- });
3193
- K.include({ _initOverlay: function(e, t, n, r) {
3194
- var i = t;
3195
- return i instanceof e || (i = new e(r).setContent(t)), n && i.setLatLng(n), i;
3196
- } }), X.include({ _initOverlay: function(e, t, n, r) {
3197
- var i = n;
3198
- return i instanceof e ? (p(i, r), i._source = this) : (i = t && !r ? t : new e(r, this), i.setContent(n)), i;
3199
- } });
3200
- var kr = $.extend({
3201
- options: {
3202
- pane: "popupPane",
3203
- offset: [0, 7],
3204
- maxWidth: 300,
3205
- minWidth: 50,
3206
- maxHeight: null,
3207
- autoPan: !0,
3208
- autoPanPaddingTopLeft: null,
3209
- autoPanPaddingBottomRight: null,
3210
- autoPanPadding: [5, 5],
3211
- keepInView: !1,
3212
- closeButton: !0,
3213
- autoClose: !0,
3214
- closeOnEscapeKey: !0,
3215
- className: ""
3216
- },
3217
- openOn: function(e) {
3218
- return e = arguments.length ? e : this._source._map, !e.hasLayer(this) && e._popup && e._popup.options.autoClose && e.removeLayer(e._popup), e._popup = this, $.prototype.openOn.call(this, e);
3219
- },
3220
- onAdd: function(e) {
3221
- $.prototype.onAdd.call(this, e), e.fire("popupopen", { popup: this }), this._source && (this._source.fire("popupopen", { popup: this }, !0), this._source instanceof rr || this._source.on("preclick", $t));
3222
- },
3223
- onRemove: function(e) {
3224
- $.prototype.onRemove.call(this, e), e.fire("popupclose", { popup: this }), this._source && (this._source.fire("popupclose", { popup: this }, !0), this._source instanceof rr || this._source.off("preclick", $t));
3225
- },
3226
- getEvents: function() {
3227
- var e = $.prototype.getEvents.call(this);
3228
- return (this.options.closeOnClick === void 0 ? this._map.options.closePopupOnClick : this.options.closeOnClick) && (e.preclick = this.close), this.options.keepInView && (e.moveend = this._adjustPan), e;
3229
- },
3230
- _initLayout: function() {
3231
- var e = "leaflet-popup", t = this._container = F("div", e + " " + (this.options.className || "") + " leaflet-zoom-animated"), n = this._wrapper = F("div", e + "-content-wrapper", t);
3232
- if (this._contentNode = F("div", e + "-content", n), tn(t), en(this._contentNode), H(t, "contextmenu", $t), this._tipContainer = F("div", e + "-tip-container", t), this._tip = F("div", e + "-tip", this._tipContainer), this.options.closeButton) {
3233
- var r = this._closeButton = F("a", e + "-close-button", t);
3234
- r.setAttribute("role", "button"), r.setAttribute("aria-label", "Close popup"), r.href = "#close", r.innerHTML = "<span aria-hidden=\"true\">&#215;</span>", H(r, "click", function(e) {
3235
- G(e), this.close();
3236
- }, this);
3237
- }
3238
- },
3239
- _updateLayout: function() {
3240
- var e = this._contentNode, t = e.style;
3241
- t.width = "", t.whiteSpace = "nowrap";
3242
- var n = e.offsetWidth;
3243
- n = Math.min(n, this.options.maxWidth), n = Math.max(n, this.options.minWidth), t.width = n + 1 + "px", t.whiteSpace = "", t.height = "";
3244
- var r = e.offsetHeight, i = this.options.maxHeight, a = "leaflet-popup-scrolled";
3245
- i && r > i ? (t.height = i + "px", R(e, a)) : z(e, a), this._containerWidth = this._container.offsetWidth;
3246
- },
3247
- _animateZoom: function(e) {
3248
- var t = this._map._latLngToNewLayerPoint(this._latlng, e.zoom, e.center), n = this._getAnchor();
3249
- V(this._container, t.add(n));
3250
- },
3251
- _adjustPan: function() {
3252
- if (this.options.autoPan) {
3253
- if (this._map._panAnim && this._map._panAnim.stop(), this._autopanning) {
3254
- this._autopanning = !1;
3255
- return;
3256
- }
3257
- var e = this._map, t = parseInt(Tt(this._container, "marginBottom"), 10) || 0, n = this._container.offsetHeight + t, r = this._containerWidth, i = new S(this._containerLeft, -n - this._containerBottom);
3258
- i._add(Ft(this._container));
3259
- var a = e.layerPointToContainerPoint(i), o = C(this.options.autoPanPadding), s = C(this.options.autoPanPaddingTopLeft || o), c = C(this.options.autoPanPaddingBottomRight || o), l = e.getSize(), u = 0, d = 0;
3260
- a.x + r + c.x > l.x && (u = a.x + r - l.x + c.x), a.x - u - s.x < 0 && (u = a.x - s.x), a.y + n + c.y > l.y && (d = a.y + n - l.y + c.y), a.y - d - s.y < 0 && (d = a.y - s.y), (u || d) && (this.options.keepInView && (this._autopanning = !0), e.fire("autopanstart").panBy([u, d]));
3261
- }
3262
- },
3263
- _getAnchor: function() {
3264
- return C(this._source && this._source._getPopupAnchor ? this._source._getPopupAnchor() : [0, 0]);
3265
- }
3266
- }), Ar = function(e, t) {
3267
- return new kr(e, t);
3268
- };
3269
- K.mergeOptions({ closePopupOnClick: !0 }), K.include({
3270
- openPopup: function(e, t, n) {
3271
- return this._initOverlay(kr, e, t, n).openOn(this), this;
3272
- },
3273
- closePopup: function(e) {
3274
- return e = arguments.length ? e : this._popup, e && e.close(), this;
3275
- }
3276
- }), X.include({
3277
- bindPopup: function(e, t) {
3278
- return this._popup = this._initOverlay(kr, this._popup, e, t), this._popupHandlersAdded ||= (this.on({
3279
- click: this._openPopup,
3280
- keypress: this._onKeyPress,
3281
- remove: this.closePopup,
3282
- move: this._movePopup
3283
- }), !0), this;
3284
- },
3285
- unbindPopup: function() {
3286
- return this._popup &&= (this.off({
3287
- click: this._openPopup,
3288
- keypress: this._onKeyPress,
3289
- remove: this.closePopup,
3290
- move: this._movePopup
3291
- }), this._popupHandlersAdded = !1, null), this;
3292
- },
3293
- openPopup: function(e) {
3294
- return this._popup && (this instanceof Z || (this._popup._source = this), this._popup._prepareOpen(e || this._latlng) && this._popup.openOn(this._map)), this;
3295
- },
3296
- closePopup: function() {
3297
- return this._popup && this._popup.close(), this;
3298
- },
3299
- togglePopup: function() {
3300
- return this._popup && this._popup.toggle(this), this;
3301
- },
3302
- isPopupOpen: function() {
3303
- return this._popup ? this._popup.isOpen() : !1;
3304
- },
3305
- setPopupContent: function(e) {
3306
- return this._popup && this._popup.setContent(e), this;
3307
- },
3308
- getPopup: function() {
3309
- return this._popup;
3310
- },
3311
- _openPopup: function(e) {
3312
- if (this._popup && this._map) {
3313
- nn(e);
3314
- var t = e.layer || e.target;
3315
- if (this._popup._source === t && !(t instanceof rr)) {
3316
- this._map.hasLayer(this._popup) ? this.closePopup() : this.openPopup(e.latlng);
3317
- return;
3318
- }
3319
- this._popup._source = t, this.openPopup(e.latlng);
3320
- }
3321
- },
3322
- _movePopup: function(e) {
3323
- this._popup.setLatLng(e.latlng);
3324
- },
3325
- _onKeyPress: function(e) {
3326
- e.originalEvent.keyCode === 13 && this._openPopup(e);
3327
- }
3328
- });
3329
- var jr = $.extend({
3330
- options: {
3331
- pane: "tooltipPane",
3332
- offset: [0, 0],
3333
- direction: "auto",
3334
- permanent: !1,
3335
- sticky: !1,
3336
- opacity: .9
3337
- },
3338
- onAdd: function(e) {
3339
- $.prototype.onAdd.call(this, e), this.setOpacity(this.options.opacity), e.fire("tooltipopen", { tooltip: this }), this._source && (this.addEventParent(this._source), this._source.fire("tooltipopen", { tooltip: this }, !0));
3340
- },
3341
- onRemove: function(e) {
3342
- $.prototype.onRemove.call(this, e), e.fire("tooltipclose", { tooltip: this }), this._source && (this.removeEventParent(this._source), this._source.fire("tooltipclose", { tooltip: this }, !0));
3343
- },
3344
- getEvents: function() {
3345
- var e = $.prototype.getEvents.call(this);
3346
- return this.options.permanent || (e.preclick = this.close), e;
3347
- },
3348
- _initLayout: function() {
3349
- var e = "leaflet-tooltip " + (this.options.className || "") + " leaflet-zoom-" + (this._zoomAnimated ? "animated" : "hide");
3350
- this._contentNode = this._container = F("div", e), this._container.setAttribute("role", "tooltip"), this._container.setAttribute("id", "leaflet-tooltip-" + o(this));
3351
- },
3352
- _updateLayout: function() {},
3353
- _adjustPan: function() {},
3354
- _setPosition: function(e) {
3355
- var t, n, r = this._map, i = this._container, a = r.latLngToContainerPoint(r.getCenter()), o = r.layerPointToContainerPoint(e), s = this.options.direction, c = i.offsetWidth, l = i.offsetHeight, u = C(this.options.offset), d = this._getAnchor();
3356
- s === "top" ? (t = c / 2, n = l) : s === "bottom" ? (t = c / 2, n = 0) : s === "center" ? (t = c / 2, n = l / 2) : s === "right" ? (t = 0, n = l / 2) : s === "left" ? (t = c, n = l / 2) : o.x < a.x ? (s = "right", t = 0, n = l / 2) : (s = "left", t = c + (u.x + d.x) * 2, n = l / 2), e = e.subtract(C(t, n, !0)).add(u).add(d), z(i, "leaflet-tooltip-right"), z(i, "leaflet-tooltip-left"), z(i, "leaflet-tooltip-top"), z(i, "leaflet-tooltip-bottom"), R(i, "leaflet-tooltip-" + s), V(i, e);
3357
- },
3358
- _updatePosition: function() {
3359
- var e = this._map.latLngToLayerPoint(this._latlng);
3360
- this._setPosition(e);
3361
- },
3362
- setOpacity: function(e) {
3363
- this.options.opacity = e, this._container && B(this._container, e);
3364
- },
3365
- _animateZoom: function(e) {
3366
- var t = this._map._latLngToNewLayerPoint(this._latlng, e.zoom, e.center);
3367
- this._setPosition(t);
3368
- },
3369
- _getAnchor: function() {
3370
- return C(this._source && this._source._getTooltipAnchor && !this.options.sticky ? this._source._getTooltipAnchor() : [0, 0]);
3371
- }
3372
- }), Mr = function(e, t) {
3373
- return new jr(e, t);
3374
- };
3375
- K.include({
3376
- openTooltip: function(e, t, n) {
3377
- return this._initOverlay(jr, e, t, n).openOn(this), this;
3378
- },
3379
- closeTooltip: function(e) {
3380
- return e.close(), this;
3381
- }
3382
- }), X.include({
3383
- bindTooltip: function(e, t) {
3384
- return this._tooltip && this.isTooltipOpen() && this.unbindTooltip(), this._tooltip = this._initOverlay(jr, this._tooltip, e, t), this._initTooltipInteractions(), this._tooltip.options.permanent && this._map && this._map.hasLayer(this) && this.openTooltip(), this;
3385
- },
3386
- unbindTooltip: function() {
3387
- return this._tooltip &&= (this._initTooltipInteractions(!0), this.closeTooltip(), null), this;
3388
- },
3389
- _initTooltipInteractions: function(e) {
3390
- if (e || !this._tooltipHandlersAdded) {
3391
- var t = e ? "off" : "on", n = {
3392
- remove: this.closeTooltip,
3393
- move: this._moveTooltip
3394
- };
3395
- this._tooltip.options.permanent ? n.add = this._openTooltip : (n.mouseover = this._openTooltip, n.mouseout = this.closeTooltip, n.click = this._openTooltip, this._map ? this._addFocusListeners() : n.add = this._addFocusListeners), this._tooltip.options.sticky && (n.mousemove = this._moveTooltip), this[t](n), this._tooltipHandlersAdded = !e;
3396
- }
3397
- },
3398
- openTooltip: function(e) {
3399
- return this._tooltip && (this instanceof Z || (this._tooltip._source = this), this._tooltip._prepareOpen(e) && (this._tooltip.openOn(this._map), this.getElement ? this._setAriaDescribedByOnLayer(this) : this.eachLayer && this.eachLayer(this._setAriaDescribedByOnLayer, this))), this;
3400
- },
3401
- closeTooltip: function() {
3402
- if (this._tooltip) return this._tooltip.close();
3403
- },
3404
- toggleTooltip: function() {
3405
- return this._tooltip && this._tooltip.toggle(this), this;
3406
- },
3407
- isTooltipOpen: function() {
3408
- return this._tooltip.isOpen();
3409
- },
3410
- setTooltipContent: function(e) {
3411
- return this._tooltip && this._tooltip.setContent(e), this;
3412
- },
3413
- getTooltip: function() {
3414
- return this._tooltip;
3415
- },
3416
- _addFocusListeners: function() {
3417
- this.getElement ? this._addFocusListenersOnLayer(this) : this.eachLayer && this.eachLayer(this._addFocusListenersOnLayer, this);
3418
- },
3419
- _addFocusListenersOnLayer: function(e) {
3420
- var t = typeof e.getElement == "function" && e.getElement();
3421
- t && (H(t, "focus", function() {
3422
- this._tooltip._source = e, this.openTooltip();
3423
- }, this), H(t, "blur", this.closeTooltip, this));
3424
- },
3425
- _setAriaDescribedByOnLayer: function(e) {
3426
- var t = typeof e.getElement == "function" && e.getElement();
3427
- t && t.setAttribute("aria-describedby", this._tooltip._container.id);
3428
- },
3429
- _openTooltip: function(e) {
3430
- if (this._tooltip && this._map) {
3431
- if (this._map.dragging && this._map.dragging.moving() && !this._openOnceFlag) {
3432
- this._openOnceFlag = !0;
3433
- var t = this;
3434
- this._map.once("moveend", function() {
3435
- t._openOnceFlag = !1, t._openTooltip(e);
3436
- });
3437
- return;
3438
- }
3439
- this._tooltip._source = e.layer || e.target, this.openTooltip(this._tooltip.options.sticky ? e.latlng : void 0);
3440
- }
3441
- },
3442
- _moveTooltip: function(e) {
3443
- var t = e.latlng, n, r;
3444
- this._tooltip.options.sticky && e.originalEvent && (n = this._map.mouseEventToContainerPoint(e.originalEvent), r = this._map.containerPointToLayerPoint(n), t = this._map.layerPointToLatLng(r)), this._tooltip.setLatLng(t);
3445
- }
3446
- });
3447
- var Nr = Zn.extend({
3448
- options: {
3449
- iconSize: [12, 12],
3450
- html: !1,
3451
- bgPos: null,
3452
- className: "leaflet-div-icon"
3453
- },
3454
- createIcon: function(e) {
3455
- var t = e && e.tagName === "DIV" ? e : document.createElement("div"), n = this.options;
3456
- if (n.html instanceof Element ? (Et(t), t.appendChild(n.html)) : t.innerHTML = n.html === !1 ? "" : n.html, n.bgPos) {
3457
- var r = C(n.bgPos);
3458
- t.style.backgroundPosition = -r.x + "px " + -r.y + "px";
3459
- }
3460
- return this._setIconStyles(t, "icon"), t;
3461
- },
3462
- createShadow: function() {
3463
- return null;
3464
- }
3465
- });
3466
- function Pr(e) {
3467
- return new Nr(e);
3468
- }
3469
- Zn.Default = $n;
3470
- var Fr = X.extend({
3471
- options: {
3472
- tileSize: 256,
3473
- opacity: 1,
3474
- updateWhenIdle: P.mobile,
3475
- updateWhenZooming: !0,
3476
- updateInterval: 200,
3477
- zIndex: 1,
3478
- bounds: null,
3479
- minZoom: 0,
3480
- maxZoom: void 0,
3481
- maxNativeZoom: void 0,
3482
- minNativeZoom: void 0,
3483
- noWrap: !1,
3484
- pane: "tilePane",
3485
- className: "",
3486
- keepBuffer: 2
3487
- },
3488
- initialize: function(e) {
3489
- p(this, e);
3490
- },
3491
- onAdd: function() {
3492
- this._initContainer(), this._levels = {}, this._tiles = {}, this._resetView();
3493
- },
3494
- beforeAdd: function(e) {
3495
- e._addZoomLimit(this);
3496
- },
3497
- onRemove: function(e) {
3498
- this._removeAllTiles(), I(this._container), e._removeZoomLimit(this), this._container = null, this._tileZoom = void 0;
3499
- },
3500
- bringToFront: function() {
3501
- return this._map && (Dt(this._container), this._setAutoZIndex(Math.max)), this;
3502
- },
3503
- bringToBack: function() {
3504
- return this._map && (Ot(this._container), this._setAutoZIndex(Math.min)), this;
3505
- },
3506
- getContainer: function() {
3507
- return this._container;
3508
- },
3509
- setOpacity: function(e) {
3510
- return this.options.opacity = e, this._updateOpacity(), this;
3511
- },
3512
- setZIndex: function(e) {
3513
- return this.options.zIndex = e, this._updateZIndex(), this;
3514
- },
3515
- isLoading: function() {
3516
- return this._loading;
3517
- },
3518
- redraw: function() {
3519
- if (this._map) {
3520
- this._removeAllTiles();
3521
- var e = this._clampZoom(this._map.getZoom());
3522
- e !== this._tileZoom && (this._tileZoom = e, this._updateLevels()), this._update();
3523
- }
3524
- return this;
3525
- },
3526
- getEvents: function() {
3527
- var e = {
3528
- viewprereset: this._invalidateAll,
3529
- viewreset: this._resetView,
3530
- zoom: this._resetView,
3531
- moveend: this._onMoveEnd
3532
- };
3533
- return this.options.updateWhenIdle || (this._onMove ||= s(this._onMoveEnd, this.options.updateInterval, this), e.move = this._onMove), this._zoomAnimated && (e.zoomanim = this._animateZoom), e;
3534
- },
3535
- createTile: function() {
3536
- return document.createElement("div");
3537
- },
3538
- getTileSize: function() {
3539
- var e = this.options.tileSize;
3540
- return e instanceof S ? e : new S(e, e);
3541
- },
3542
- _updateZIndex: function() {
3543
- this._container && this.options.zIndex !== void 0 && this.options.zIndex !== null && (this._container.style.zIndex = this.options.zIndex);
3544
- },
3545
- _setAutoZIndex: function(e) {
3546
- for (var t = this.getPane().children, n = -e(-Infinity, Infinity), r = 0, i = t.length, a; r < i; r++) a = t[r].style.zIndex, t[r] !== this._container && a && (n = e(n, +a));
3547
- isFinite(n) && (this.options.zIndex = n + e(-1, 1), this._updateZIndex());
3548
- },
3549
- _updateOpacity: function() {
3550
- if (this._map && !P.ielt9) {
3551
- B(this._container, this.options.opacity);
3552
- var e = +/* @__PURE__ */ new Date(), t = !1, n = !1;
3553
- for (var r in this._tiles) {
3554
- var i = this._tiles[r];
3555
- if (i.current && i.loaded) {
3556
- var a = Math.min(1, (e - i.loaded) / 200);
3557
- B(i.el, a), a < 1 ? t = !0 : (i.active ? n = !0 : this._onOpaqueTile(i), i.active = !0);
3558
- }
3559
- }
3560
- n && !this._noPrune && this._pruneTiles(), t && (y(this._fadeFrame), this._fadeFrame = v(this._updateOpacity, this));
3561
- }
3562
- },
3563
- _onOpaqueTile: l,
3564
- _initContainer: function() {
3565
- this._container || (this._container = F("div", "leaflet-layer " + (this.options.className || "")), this._updateZIndex(), this.options.opacity < 1 && this._updateOpacity(), this.getPane().appendChild(this._container));
3566
- },
3567
- _updateLevels: function() {
3568
- var e = this._tileZoom, t = this.options.maxZoom;
3569
- if (e !== void 0) {
3570
- for (var n in this._levels) n = Number(n), this._levels[n].el.children.length || n === e ? (this._levels[n].el.style.zIndex = t - Math.abs(e - n), this._onUpdateLevel(n)) : (I(this._levels[n].el), this._removeTilesAtZoom(n), this._onRemoveLevel(n), delete this._levels[n]);
3571
- var r = this._levels[e], i = this._map;
3572
- return r || (r = this._levels[e] = {}, r.el = F("div", "leaflet-tile-container leaflet-zoom-animated", this._container), r.el.style.zIndex = t, r.origin = i.project(i.unproject(i.getPixelOrigin()), e).round(), r.zoom = e, this._setZoomTransform(r, i.getCenter(), i.getZoom()), r.el.offsetWidth, this._onCreateLevel(r)), this._level = r, r;
3573
- }
3574
- },
3575
- _onUpdateLevel: l,
3576
- _onRemoveLevel: l,
3577
- _onCreateLevel: l,
3578
- _pruneTiles: function() {
3579
- if (this._map) {
3580
- var e, t, n = this._map.getZoom();
3581
- if (n > this.options.maxZoom || n < this.options.minZoom) {
3582
- this._removeAllTiles();
3583
- return;
3584
- }
3585
- for (e in this._tiles) t = this._tiles[e], t.retain = t.current;
3586
- for (e in this._tiles) if (t = this._tiles[e], t.current && !t.active) {
3587
- var r = t.coords;
3588
- this._retainParent(r.x, r.y, r.z, r.z - 5) || this._retainChildren(r.x, r.y, r.z, r.z + 2);
3589
- }
3590
- for (e in this._tiles) this._tiles[e].retain || this._removeTile(e);
3591
- }
3592
- },
3593
- _removeTilesAtZoom: function(e) {
3594
- for (var t in this._tiles) this._tiles[t].coords.z === e && this._removeTile(t);
3595
- },
3596
- _removeAllTiles: function() {
3597
- for (var e in this._tiles) this._removeTile(e);
3598
- },
3599
- _invalidateAll: function() {
3600
- for (var e in this._levels) I(this._levels[e].el), this._onRemoveLevel(Number(e)), delete this._levels[e];
3601
- this._removeAllTiles(), this._tileZoom = void 0;
3602
- },
3603
- _retainParent: function(e, t, n, r) {
3604
- var i = Math.floor(e / 2), a = Math.floor(t / 2), o = n - 1, s = new S(+i, +a);
3605
- s.z = +o;
3606
- var c = this._tileCoordsToKey(s), l = this._tiles[c];
3607
- return l && l.active ? (l.retain = !0, !0) : (l && l.loaded && (l.retain = !0), o > r && this._retainParent(i, a, o, r));
3608
- },
3609
- _retainChildren: function(e, t, n, r) {
3610
- for (var i = 2 * e; i < 2 * e + 2; i++) for (var a = 2 * t; a < 2 * t + 2; a++) {
3611
- var o = new S(i, a);
3612
- o.z = n + 1;
3613
- var s = this._tileCoordsToKey(o), c = this._tiles[s];
3614
- if (c && c.active) {
3615
- c.retain = !0;
3616
- continue;
3617
- }
3618
- c && c.loaded && (c.retain = !0), n + 1 < r && this._retainChildren(i, a, n + 1, r);
3619
- }
3620
- },
3621
- _resetView: function(e) {
3622
- var t = e && (e.pinch || e.flyTo);
3623
- this._setView(this._map.getCenter(), this._map.getZoom(), t, t);
3624
- },
3625
- _animateZoom: function(e) {
3626
- this._setView(e.center, e.zoom, !0, e.noUpdate);
3627
- },
3628
- _clampZoom: function(e) {
3629
- var t = this.options;
3630
- return t.minNativeZoom !== void 0 && e < t.minNativeZoom ? t.minNativeZoom : t.maxNativeZoom !== void 0 && t.maxNativeZoom < e ? t.maxNativeZoom : e;
3631
- },
3632
- _setView: function(e, t, n, r) {
3633
- var i = Math.round(t);
3634
- i = this.options.maxZoom !== void 0 && i > this.options.maxZoom || this.options.minZoom !== void 0 && i < this.options.minZoom ? void 0 : this._clampZoom(i);
3635
- var a = this.options.updateWhenZooming && i !== this._tileZoom;
3636
- (!r || a) && (this._tileZoom = i, this._abortLoading && this._abortLoading(), this._updateLevels(), this._resetGrid(), i !== void 0 && this._update(e), n || this._pruneTiles(), this._noPrune = !!n), this._setZoomTransforms(e, t);
3637
- },
3638
- _setZoomTransforms: function(e, t) {
3639
- for (var n in this._levels) this._setZoomTransform(this._levels[n], e, t);
3640
- },
3641
- _setZoomTransform: function(e, t, n) {
3642
- var r = this._map.getZoomScale(n, e.zoom), i = e.origin.multiplyBy(r).subtract(this._map._getNewPixelOrigin(t, n)).round();
3643
- P.any3d ? Pt(e.el, i, r) : V(e.el, i);
3644
- },
3645
- _resetGrid: function() {
3646
- var e = this._map, t = e.options.crs, n = this._tileSize = this.getTileSize(), r = this._tileZoom, i = this._map.getPixelWorldBounds(this._tileZoom);
3647
- i && (this._globalTileRange = this._pxBoundsToTileRange(i)), this._wrapX = t.wrapLng && !this.options.noWrap && [Math.floor(e.project([0, t.wrapLng[0]], r).x / n.x), Math.ceil(e.project([0, t.wrapLng[1]], r).x / n.y)], this._wrapY = t.wrapLat && !this.options.noWrap && [Math.floor(e.project([t.wrapLat[0], 0], r).y / n.x), Math.ceil(e.project([t.wrapLat[1], 0], r).y / n.y)];
3648
- },
3649
- _onMoveEnd: function() {
3650
- this._map && !this._map._animatingZoom && this._update();
3651
- },
3652
- _getTiledPixelBounds: function(e) {
3653
- var t = this._map, n = t._animatingZoom ? Math.max(t._animateToZoom, t.getZoom()) : t.getZoom(), r = t.getZoomScale(n, this._tileZoom), i = t.project(e, this._tileZoom).floor(), a = t.getSize().divideBy(r * 2);
3654
- return new w(i.subtract(a), i.add(a));
3655
- },
3656
- _update: function(e) {
3657
- var t = this._map;
3658
- if (t) {
3659
- var n = this._clampZoom(t.getZoom());
3660
- if (e === void 0 && (e = t.getCenter()), this._tileZoom !== void 0) {
3661
- var r = this._getTiledPixelBounds(e), i = this._pxBoundsToTileRange(r), a = i.getCenter(), o = [], s = this.options.keepBuffer, c = new w(i.getBottomLeft().subtract([s, -s]), i.getTopRight().add([s, -s]));
3662
- if (!(isFinite(i.min.x) && isFinite(i.min.y) && isFinite(i.max.x) && isFinite(i.max.y))) throw Error("Attempted to load an infinite number of tiles");
3663
- for (var l in this._tiles) {
3664
- var u = this._tiles[l].coords;
3665
- (u.z !== this._tileZoom || !c.contains(new S(u.x, u.y))) && (this._tiles[l].current = !1);
3666
- }
3667
- if (Math.abs(n - this._tileZoom) > 1) {
3668
- this._setView(e, n);
3669
- return;
3670
- }
3671
- for (var d = i.min.y; d <= i.max.y; d++) for (var f = i.min.x; f <= i.max.x; f++) {
3672
- var p = new S(f, d);
3673
- if (p.z = this._tileZoom, this._isValidTile(p)) {
3674
- var m = this._tiles[this._tileCoordsToKey(p)];
3675
- m ? m.current = !0 : o.push(p);
3676
- }
3677
- }
3678
- if (o.sort(function(e, t) {
3679
- return e.distanceTo(a) - t.distanceTo(a);
3680
- }), o.length !== 0) {
3681
- this._loading || (this._loading = !0, this.fire("loading"));
3682
- var h = document.createDocumentFragment();
3683
- for (f = 0; f < o.length; f++) this._addTile(o[f], h);
3684
- this._level.el.appendChild(h);
3685
- }
3686
- }
3687
- }
3688
- },
3689
- _isValidTile: function(e) {
3690
- var t = this._map.options.crs;
3691
- if (!t.infinite) {
3692
- var n = this._globalTileRange;
3693
- if (!t.wrapLng && (e.x < n.min.x || e.x > n.max.x) || !t.wrapLat && (e.y < n.min.y || e.y > n.max.y)) return !1;
3694
- }
3695
- if (!this.options.bounds) return !0;
3696
- var r = this._tileCoordsToBounds(e);
3697
- return D(this.options.bounds).overlaps(r);
3698
- },
3699
- _keyToBounds: function(e) {
3700
- return this._tileCoordsToBounds(this._keyToTileCoords(e));
3701
- },
3702
- _tileCoordsToNwSe: function(e) {
3703
- var t = this._map, n = this.getTileSize(), r = e.scaleBy(n), i = r.add(n);
3704
- return [t.unproject(r, e.z), t.unproject(i, e.z)];
3705
- },
3706
- _tileCoordsToBounds: function(e) {
3707
- var t = this._tileCoordsToNwSe(e), n = new E(t[0], t[1]);
3708
- return this.options.noWrap || (n = this._map.wrapLatLngBounds(n)), n;
3709
- },
3710
- _tileCoordsToKey: function(e) {
3711
- return e.x + ":" + e.y + ":" + e.z;
3712
- },
3713
- _keyToTileCoords: function(e) {
3714
- var t = e.split(":"), n = new S(+t[0], +t[1]);
3715
- return n.z = +t[2], n;
3716
- },
3717
- _removeTile: function(e) {
3718
- var t = this._tiles[e];
3719
- t && (I(t.el), delete this._tiles[e], this.fire("tileunload", {
3720
- tile: t.el,
3721
- coords: this._keyToTileCoords(e)
3722
- }));
3723
- },
3724
- _initTile: function(e) {
3725
- R(e, "leaflet-tile");
3726
- var t = this.getTileSize();
3727
- e.style.width = t.x + "px", e.style.height = t.y + "px", e.onselectstart = l, e.onmousemove = l, P.ielt9 && this.options.opacity < 1 && B(e, this.options.opacity);
3728
- },
3729
- _addTile: function(e, t) {
3730
- var n = this._getTilePos(e), r = this._tileCoordsToKey(e), a = this.createTile(this._wrapCoords(e), i(this._tileReady, this, e));
3731
- this._initTile(a), this.createTile.length < 2 && v(i(this._tileReady, this, e, null, a)), V(a, n), this._tiles[r] = {
3732
- el: a,
3733
- coords: e,
3734
- current: !0
3735
- }, t.appendChild(a), this.fire("tileloadstart", {
3736
- tile: a,
3737
- coords: e
3738
- });
3739
- },
3740
- _tileReady: function(e, t, n) {
3741
- t && this.fire("tileerror", {
3742
- error: t,
3743
- tile: n,
3744
- coords: e
3745
- });
3746
- var r = this._tileCoordsToKey(e);
3747
- n = this._tiles[r], n && (n.loaded = +/* @__PURE__ */ new Date(), this._map._fadeAnimated ? (B(n.el, 0), y(this._fadeFrame), this._fadeFrame = v(this._updateOpacity, this)) : (n.active = !0, this._pruneTiles()), t || (R(n.el, "leaflet-tile-loaded"), this.fire("tileload", {
3748
- tile: n.el,
3749
- coords: e
3750
- })), this._noTilesToLoad() && (this._loading = !1, this.fire("load"), P.ielt9 || !this._map._fadeAnimated ? v(this._pruneTiles, this) : setTimeout(i(this._pruneTiles, this), 250)));
3751
- },
3752
- _getTilePos: function(e) {
3753
- return e.scaleBy(this.getTileSize()).subtract(this._level.origin);
3754
- },
3755
- _wrapCoords: function(e) {
3756
- var t = new S(this._wrapX ? c(e.x, this._wrapX) : e.x, this._wrapY ? c(e.y, this._wrapY) : e.y);
3757
- return t.z = e.z, t;
3758
- },
3759
- _pxBoundsToTileRange: function(e) {
3760
- var t = this.getTileSize();
3761
- return new w(e.min.unscaleBy(t).floor(), e.max.unscaleBy(t).ceil().subtract([1, 1]));
3762
- },
3763
- _noTilesToLoad: function() {
3764
- for (var e in this._tiles) if (!this._tiles[e].loaded) return !1;
3765
- return !0;
3766
- }
3767
- });
3768
- function Ir(e) {
3769
- return new Fr(e);
3770
- }
3771
- var Lr = Fr.extend({
3772
- options: {
3773
- minZoom: 0,
3774
- maxZoom: 18,
3775
- subdomains: "abc",
3776
- errorTileUrl: "",
3777
- zoomOffset: 0,
3778
- tms: !1,
3779
- zoomReverse: !1,
3780
- detectRetina: !1,
3781
- crossOrigin: !1,
3782
- referrerPolicy: !1
3783
- },
3784
- initialize: function(e, t) {
3785
- this._url = e, t = p(this, t), t.detectRetina && P.retina && t.maxZoom > 0 ? (t.tileSize = Math.floor(t.tileSize / 2), t.zoomReverse ? (t.zoomOffset--, t.minZoom = Math.min(t.maxZoom, t.minZoom + 1)) : (t.zoomOffset++, t.maxZoom = Math.max(t.minZoom, t.maxZoom - 1)), t.minZoom = Math.max(0, t.minZoom)) : t.zoomReverse ? t.minZoom = Math.min(t.maxZoom, t.minZoom) : t.maxZoom = Math.max(t.minZoom, t.maxZoom), typeof t.subdomains == "string" && (t.subdomains = t.subdomains.split("")), this.on("tileunload", this._onTileRemove);
3786
- },
3787
- setUrl: function(e, t) {
3788
- return this._url === e && t === void 0 && (t = !0), this._url = e, t || this.redraw(), this;
3789
- },
3790
- createTile: function(e, t) {
3791
- var n = document.createElement("img");
3792
- return H(n, "load", i(this._tileOnLoad, this, t, n)), H(n, "error", i(this._tileOnError, this, t, n)), (this.options.crossOrigin || this.options.crossOrigin === "") && (n.crossOrigin = this.options.crossOrigin === !0 ? "" : this.options.crossOrigin), typeof this.options.referrerPolicy == "string" && (n.referrerPolicy = this.options.referrerPolicy), n.alt = "", n.src = this.getTileUrl(e), n;
3793
- },
3794
- getTileUrl: function(e) {
3795
- var t = {
3796
- r: P.retina ? "@2x" : "",
3797
- s: this._getSubdomain(e),
3798
- x: e.x,
3799
- y: e.y,
3800
- z: this._getZoomForUrl()
3801
- };
3802
- if (this._map && !this._map.options.crs.infinite) {
3803
- var r = this._globalTileRange.max.y - e.y;
3804
- this.options.tms && (t.y = r), t["-y"] = r;
3805
- }
3806
- return g(this._url, n(t, this.options));
3807
- },
3808
- _tileOnLoad: function(e, t) {
3809
- P.ielt9 ? setTimeout(i(e, this, null, t), 0) : e(null, t);
3810
- },
3811
- _tileOnError: function(e, t, n) {
3812
- var r = this.options.errorTileUrl;
3813
- r && t.getAttribute("src") !== r && (t.src = r), e(n, t);
3814
- },
3815
- _onTileRemove: function(e) {
3816
- e.tile.onload = null;
3817
- },
3818
- _getZoomForUrl: function() {
3819
- var e = this._tileZoom, t = this.options.maxZoom, n = this.options.zoomReverse, r = this.options.zoomOffset;
3820
- return n && (e = t - e), e + r;
3821
- },
3822
- _getSubdomain: function(e) {
3823
- var t = Math.abs(e.x + e.y) % this.options.subdomains.length;
3824
- return this.options.subdomains[t];
3825
- },
3826
- _abortLoading: function() {
3827
- var e, t;
3828
- for (e in this._tiles) if (this._tiles[e].coords.z !== this._tileZoom && (t = this._tiles[e].el, t.onload = l, t.onerror = l, !t.complete)) {
3829
- t.src = te;
3830
- var n = this._tiles[e].coords;
3831
- I(t), delete this._tiles[e], this.fire("tileabort", {
3832
- tile: t,
3833
- coords: n
3834
- });
3835
- }
3836
- },
3837
- _removeTile: function(e) {
3838
- var t = this._tiles[e];
3839
- if (t) return t.el.setAttribute("src", te), Fr.prototype._removeTile.call(this, e);
3840
- },
3841
- _tileReady: function(e, t, n) {
3842
- if (!(!this._map || n && n.getAttribute("src") === te)) return Fr.prototype._tileReady.call(this, e, t, n);
3843
- }
3844
- });
3845
- function Rr(e, t) {
3846
- return new Lr(e, t);
3847
- }
3848
- var zr = Lr.extend({
3849
- defaultWmsParams: {
3850
- service: "WMS",
3851
- request: "GetMap",
3852
- layers: "",
3853
- styles: "",
3854
- format: "image/jpeg",
3855
- transparent: !1,
3856
- version: "1.1.1"
3857
- },
3858
- options: {
3859
- crs: null,
3860
- uppercase: !1
3861
- },
3862
- initialize: function(e, t) {
3863
- this._url = e;
3864
- var r = n({}, this.defaultWmsParams);
3865
- for (var i in t) i in this.options || (r[i] = t[i]);
3866
- t = p(this, t);
3867
- var a = t.detectRetina && P.retina ? 2 : 1, o = this.getTileSize();
3868
- r.width = o.x * a, r.height = o.y * a, this.wmsParams = r;
3869
- },
3870
- onAdd: function(e) {
3871
- this._crs = this.options.crs || e.options.crs, this._wmsVersion = parseFloat(this.wmsParams.version);
3872
- var t = this._wmsVersion >= 1.3 ? "crs" : "srs";
3873
- this.wmsParams[t] = this._crs.code, Lr.prototype.onAdd.call(this, e);
3874
- },
3875
- getTileUrl: function(e) {
3876
- var t = this._tileCoordsToNwSe(e), n = this._crs, r = T(n.project(t[0]), n.project(t[1])), i = r.min, a = r.max, o = (this._wmsVersion >= 1.3 && this._crs === Kn ? [
3877
- i.y,
3878
- i.x,
3879
- a.y,
3880
- a.x
3881
- ] : [
3882
- i.x,
3883
- i.y,
3884
- a.x,
3885
- a.y
3886
- ]).join(","), s = Lr.prototype.getTileUrl.call(this, e);
3887
- return s + m(this.wmsParams, s, this.options.uppercase) + (this.options.uppercase ? "&BBOX=" : "&bbox=") + o;
3888
- },
3889
- setParams: function(e, t) {
3890
- return n(this.wmsParams, e), t || this.redraw(), this;
3891
- }
3892
- });
3893
- function Br(e, t) {
3894
- return new zr(e, t);
3895
- }
3896
- Lr.WMS = zr, Rr.wms = Br;
3897
- var Vr = X.extend({
3898
- options: { padding: .1 },
3899
- initialize: function(e) {
3900
- p(this, e), o(this), this._layers = this._layers || {};
3901
- },
3902
- onAdd: function() {
3903
- this._container || (this._initContainer(), R(this._container, "leaflet-zoom-animated")), this.getPane().appendChild(this._container), this._update(), this.on("update", this._updatePaths, this);
3904
- },
3905
- onRemove: function() {
3906
- this.off("update", this._updatePaths, this), this._destroyContainer();
3907
- },
3908
- getEvents: function() {
3909
- var e = {
3910
- viewreset: this._reset,
3911
- zoom: this._onZoom,
3912
- moveend: this._update,
3913
- zoomend: this._onZoomEnd
3914
- };
3915
- return this._zoomAnimated && (e.zoomanim = this._onAnimZoom), e;
3916
- },
3917
- _onAnimZoom: function(e) {
3918
- this._updateTransform(e.center, e.zoom);
3919
- },
3920
- _onZoom: function() {
3921
- this._updateTransform(this._map.getCenter(), this._map.getZoom());
3922
- },
3923
- _updateTransform: function(e, t) {
3924
- var n = this._map.getZoomScale(t, this._zoom), r = this._map.getSize().multiplyBy(.5 + this.options.padding), i = this._map.project(this._center, t), a = r.multiplyBy(-n).add(i).subtract(this._map._getNewPixelOrigin(e, t));
3925
- P.any3d ? Pt(this._container, a, n) : V(this._container, a);
3926
- },
3927
- _reset: function() {
3928
- for (var e in this._update(), this._updateTransform(this._center, this._zoom), this._layers) this._layers[e]._reset();
3929
- },
3930
- _onZoomEnd: function() {
3931
- for (var e in this._layers) this._layers[e]._project();
3932
- },
3933
- _updatePaths: function() {
3934
- for (var e in this._layers) this._layers[e]._update();
3935
- },
3936
- _update: function() {
3937
- var e = this.options.padding, t = this._map.getSize(), n = this._map.containerPointToLayerPoint(t.multiplyBy(-e)).round();
3938
- this._bounds = new w(n, n.add(t.multiplyBy(1 + e * 2)).round()), this._center = this._map.getCenter(), this._zoom = this._map.getZoom();
3939
- }
3940
- }), Hr = Vr.extend({
3941
- options: { tolerance: 0 },
3942
- getEvents: function() {
3943
- var e = Vr.prototype.getEvents.call(this);
3944
- return e.viewprereset = this._onViewPreReset, e;
3945
- },
3946
- _onViewPreReset: function() {
3947
- this._postponeUpdatePaths = !0;
3948
- },
3949
- onAdd: function() {
3950
- Vr.prototype.onAdd.call(this), this._draw();
3951
- },
3952
- _initContainer: function() {
3953
- var e = this._container = document.createElement("canvas");
3954
- H(e, "mousemove", this._onMouseMove, this), H(e, "click dblclick mousedown mouseup contextmenu", this._onClick, this), H(e, "mouseout", this._handleMouseOut, this), e._leaflet_disable_events = !0, this._ctx = e.getContext("2d");
3955
- },
3956
- _destroyContainer: function() {
3957
- y(this._redrawRequest), delete this._ctx, I(this._container), W(this._container), delete this._container;
3958
- },
3959
- _updatePaths: function() {
3960
- if (!this._postponeUpdatePaths) {
3961
- var e;
3962
- for (var t in this._redrawBounds = null, this._layers) e = this._layers[t], e._update();
3963
- this._redraw();
3964
- }
3965
- },
3966
- _update: function() {
3967
- if (!(this._map._animatingZoom && this._bounds)) {
3968
- Vr.prototype._update.call(this);
3969
- var e = this._bounds, t = this._container, n = e.getSize(), r = P.retina ? 2 : 1;
3970
- V(t, e.min), t.width = r * n.x, t.height = r * n.y, t.style.width = n.x + "px", t.style.height = n.y + "px", P.retina && this._ctx.scale(2, 2), this._ctx.translate(-e.min.x, -e.min.y), this.fire("update");
3971
- }
3972
- },
3973
- _reset: function() {
3974
- Vr.prototype._reset.call(this), this._postponeUpdatePaths && (this._postponeUpdatePaths = !1, this._updatePaths());
3975
- },
3976
- _initPath: function(e) {
3977
- this._updateDashArray(e), this._layers[o(e)] = e;
3978
- var t = e._order = {
3979
- layer: e,
3980
- prev: this._drawLast,
3981
- next: null
3982
- };
3983
- this._drawLast && (this._drawLast.next = t), this._drawLast = t, this._drawFirst = this._drawFirst || this._drawLast;
3984
- },
3985
- _addPath: function(e) {
3986
- this._requestRedraw(e);
3987
- },
3988
- _removePath: function(e) {
3989
- var t = e._order, n = t.next, r = t.prev;
3990
- n ? n.prev = r : this._drawLast = r, r ? r.next = n : this._drawFirst = n, delete e._order, delete this._layers[o(e)], this._requestRedraw(e);
3991
- },
3992
- _updatePath: function(e) {
3993
- this._extendRedrawBounds(e), e._project(), e._update(), this._requestRedraw(e);
3994
- },
3995
- _updateStyle: function(e) {
3996
- this._updateDashArray(e), this._requestRedraw(e);
3997
- },
3998
- _updateDashArray: function(e) {
3999
- if (typeof e.options.dashArray == "string") {
4000
- for (var t = e.options.dashArray.split(/[, ]+/), n = [], r, i = 0; i < t.length; i++) {
4001
- if (r = Number(t[i]), isNaN(r)) return;
4002
- n.push(r);
4003
- }
4004
- e.options._dashArray = n;
4005
- } else e.options._dashArray = e.options.dashArray;
4006
- },
4007
- _requestRedraw: function(e) {
4008
- this._map && (this._extendRedrawBounds(e), this._redrawRequest = this._redrawRequest || v(this._redraw, this));
4009
- },
4010
- _extendRedrawBounds: function(e) {
4011
- if (e._pxBounds) {
4012
- var t = (e.options.weight || 0) + 1;
4013
- this._redrawBounds = this._redrawBounds || new w(), this._redrawBounds.extend(e._pxBounds.min.subtract([t, t])), this._redrawBounds.extend(e._pxBounds.max.add([t, t]));
4014
- }
4015
- },
4016
- _redraw: function() {
4017
- this._redrawRequest = null, this._redrawBounds && (this._redrawBounds.min._floor(), this._redrawBounds.max._ceil()), this._clear(), this._draw(), this._redrawBounds = null;
4018
- },
4019
- _clear: function() {
4020
- var e = this._redrawBounds;
4021
- if (e) {
4022
- var t = e.getSize();
4023
- this._ctx.clearRect(e.min.x, e.min.y, t.x, t.y);
4024
- } else this._ctx.save(), this._ctx.setTransform(1, 0, 0, 1, 0, 0), this._ctx.clearRect(0, 0, this._container.width, this._container.height), this._ctx.restore();
4025
- },
4026
- _draw: function() {
4027
- var e, t = this._redrawBounds;
4028
- if (this._ctx.save(), t) {
4029
- var n = t.getSize();
4030
- this._ctx.beginPath(), this._ctx.rect(t.min.x, t.min.y, n.x, n.y), this._ctx.clip();
4031
- }
4032
- this._drawing = !0;
4033
- for (var r = this._drawFirst; r; r = r.next) e = r.layer, (!t || e._pxBounds && e._pxBounds.intersects(t)) && e._updatePath();
4034
- this._drawing = !1, this._ctx.restore();
4035
- },
4036
- _updatePoly: function(e, t) {
4037
- if (this._drawing) {
4038
- var n, r, i, a, o = e._parts, s = o.length, c = this._ctx;
4039
- if (s) {
4040
- for (c.beginPath(), n = 0; n < s; n++) {
4041
- for (r = 0, i = o[n].length; r < i; r++) a = o[n][r], c[r ? "lineTo" : "moveTo"](a.x, a.y);
4042
- t && c.closePath();
4043
- }
4044
- this._fillStroke(c, e);
4045
- }
4046
- }
4047
- },
4048
- _updateCircle: function(e) {
4049
- if (this._drawing && !e._empty()) {
4050
- var t = e._point, n = this._ctx, r = Math.max(Math.round(e._radius), 1), i = (Math.max(Math.round(e._radiusY), 1) || r) / r;
4051
- i !== 1 && (n.save(), n.scale(1, i)), n.beginPath(), n.arc(t.x, t.y / i, r, 0, Math.PI * 2, !1), i !== 1 && n.restore(), this._fillStroke(n, e);
4052
- }
4053
- },
4054
- _fillStroke: function(e, t) {
4055
- var n = t.options;
4056
- n.fill && (e.globalAlpha = n.fillOpacity, e.fillStyle = n.fillColor || n.color, e.fill(n.fillRule || "evenodd")), n.stroke && n.weight !== 0 && (e.setLineDash && e.setLineDash(t.options && t.options._dashArray || []), e.globalAlpha = n.opacity, e.lineWidth = n.weight, e.strokeStyle = n.color, e.lineCap = n.lineCap, e.lineJoin = n.lineJoin, e.stroke());
4057
- },
4058
- _onClick: function(e) {
4059
- for (var t = this._map.mouseEventToLayerPoint(e), n, r, i = this._drawFirst; i; i = i.next) n = i.layer, n.options.interactive && n._containsPoint(t) && (e.type !== "click" && e.type !== "preclick" || !this._map._draggableMoved(n)) && (r = n);
4060
- this._fireEvent(r ? [r] : !1, e);
4061
- },
4062
- _onMouseMove: function(e) {
4063
- if (!(!this._map || this._map.dragging.moving() || this._map._animatingZoom)) {
4064
- var t = this._map.mouseEventToLayerPoint(e);
4065
- this._handleMouseHover(e, t);
4066
- }
4067
- },
4068
- _handleMouseOut: function(e) {
4069
- var t = this._hoveredLayer;
4070
- t && (z(this._container, "leaflet-interactive"), this._fireEvent([t], e, "mouseout"), this._hoveredLayer = null, this._mouseHoverThrottled = !1);
4071
- },
4072
- _handleMouseHover: function(e, t) {
4073
- if (!this._mouseHoverThrottled) {
4074
- for (var n, r, a = this._drawFirst; a; a = a.next) n = a.layer, n.options.interactive && n._containsPoint(t) && (r = n);
4075
- r !== this._hoveredLayer && (this._handleMouseOut(e), r && (R(this._container, "leaflet-interactive"), this._fireEvent([r], e, "mouseover"), this._hoveredLayer = r)), this._fireEvent(this._hoveredLayer ? [this._hoveredLayer] : !1, e), this._mouseHoverThrottled = !0, setTimeout(i(function() {
4076
- this._mouseHoverThrottled = !1;
4077
- }, this), 32);
4078
- }
4079
- },
4080
- _fireEvent: function(e, t, n) {
4081
- this._map._fireDOMEvent(t, n || t.type, e);
4082
- },
4083
- _bringToFront: function(e) {
4084
- var t = e._order;
4085
- if (t) {
4086
- var n = t.next, r = t.prev;
4087
- if (n) n.prev = r;
4088
- else return;
4089
- r ? r.next = n : n && (this._drawFirst = n), t.prev = this._drawLast, this._drawLast.next = t, t.next = null, this._drawLast = t, this._requestRedraw(e);
4090
- }
4091
- },
4092
- _bringToBack: function(e) {
4093
- var t = e._order;
4094
- if (t) {
4095
- var n = t.next, r = t.prev;
4096
- if (r) r.next = n;
4097
- else return;
4098
- n ? n.prev = r : r && (this._drawLast = r), t.prev = null, t.next = this._drawFirst, this._drawFirst.prev = t, this._drawFirst = t, this._requestRedraw(e);
4099
- }
4100
- }
4101
- });
4102
- function Ur(e) {
4103
- return P.canvas ? new Hr(e) : null;
4104
- }
4105
- var Wr = (function() {
4106
- try {
4107
- return document.namespaces.add("lvml", "urn:schemas-microsoft-com:vml"), function(e) {
4108
- return document.createElement("<lvml:" + e + " class=\"lvml\">");
4109
- };
4110
- } catch {}
4111
- return function(e) {
4112
- return document.createElement("<" + e + " xmlns=\"urn:schemas-microsoft.com:vml\" class=\"lvml\">");
4113
- };
4114
- })(), Gr = {
4115
- _initContainer: function() {
4116
- this._container = F("div", "leaflet-vml-container");
4117
- },
4118
- _update: function() {
4119
- this._map._animatingZoom || (Vr.prototype._update.call(this), this.fire("update"));
4120
- },
4121
- _initPath: function(e) {
4122
- var t = e._container = Wr("shape");
4123
- R(t, "leaflet-vml-shape " + (this.options.className || "")), t.coordsize = "1 1", e._path = Wr("path"), t.appendChild(e._path), this._updateStyle(e), this._layers[o(e)] = e;
4124
- },
4125
- _addPath: function(e) {
4126
- var t = e._container;
4127
- this._container.appendChild(t), e.options.interactive && e.addInteractiveTarget(t);
4128
- },
4129
- _removePath: function(e) {
4130
- var t = e._container;
4131
- I(t), e.removeInteractiveTarget(t), delete this._layers[o(e)];
4132
- },
4133
- _updateStyle: function(e) {
4134
- var t = e._stroke, n = e._fill, r = e.options, i = e._container;
4135
- i.stroked = !!r.stroke, i.filled = !!r.fill, r.stroke ? (t ||= e._stroke = Wr("stroke"), i.appendChild(t), t.weight = r.weight + "px", t.color = r.color, t.opacity = r.opacity, r.dashArray ? t.dashStyle = _(r.dashArray) ? r.dashArray.join(" ") : r.dashArray.replace(/( *, *)/g, " ") : t.dashStyle = "", t.endcap = r.lineCap.replace("butt", "flat"), t.joinstyle = r.lineJoin) : t && (i.removeChild(t), e._stroke = null), r.fill ? (n ||= e._fill = Wr("fill"), i.appendChild(n), n.color = r.fillColor || r.color, n.opacity = r.fillOpacity) : n && (i.removeChild(n), e._fill = null);
4136
- },
4137
- _updateCircle: function(e) {
4138
- var t = e._point.round(), n = Math.round(e._radius), r = Math.round(e._radiusY || n);
4139
- this._setPath(e, e._empty() ? "M0 0" : "AL " + t.x + "," + t.y + " " + n + "," + r + " 0,23592600");
4140
- },
4141
- _setPath: function(e, t) {
4142
- e._path.v = t;
4143
- },
4144
- _bringToFront: function(e) {
4145
- Dt(e._container);
4146
- },
4147
- _bringToBack: function(e) {
4148
- Ot(e._container);
4149
- }
4150
- }, Kr = P.vml ? Wr : _e, qr = Vr.extend({
4151
- _initContainer: function() {
4152
- this._container = Kr("svg"), this._container.setAttribute("pointer-events", "none"), this._rootGroup = Kr("g"), this._container.appendChild(this._rootGroup);
4153
- },
4154
- _destroyContainer: function() {
4155
- I(this._container), W(this._container), delete this._container, delete this._rootGroup, delete this._svgSize;
4156
- },
4157
- _update: function() {
4158
- if (!(this._map._animatingZoom && this._bounds)) {
4159
- Vr.prototype._update.call(this);
4160
- var e = this._bounds, t = e.getSize(), n = this._container;
4161
- (!this._svgSize || !this._svgSize.equals(t)) && (this._svgSize = t, n.setAttribute("width", t.x), n.setAttribute("height", t.y)), V(n, e.min), n.setAttribute("viewBox", [
4162
- e.min.x,
4163
- e.min.y,
4164
- t.x,
4165
- t.y
4166
- ].join(" ")), this.fire("update");
4167
- }
4168
- },
4169
- _initPath: function(e) {
4170
- var t = e._path = Kr("path");
4171
- e.options.className && R(t, e.options.className), e.options.interactive && R(t, "leaflet-interactive"), this._updateStyle(e), this._layers[o(e)] = e;
4172
- },
4173
- _addPath: function(e) {
4174
- this._rootGroup || this._initContainer(), this._rootGroup.appendChild(e._path), e.addInteractiveTarget(e._path);
4175
- },
4176
- _removePath: function(e) {
4177
- I(e._path), e.removeInteractiveTarget(e._path), delete this._layers[o(e)];
4178
- },
4179
- _updatePath: function(e) {
4180
- e._project(), e._update();
4181
- },
4182
- _updateStyle: function(e) {
4183
- var t = e._path, n = e.options;
4184
- t && (n.stroke ? (t.setAttribute("stroke", n.color), t.setAttribute("stroke-opacity", n.opacity), t.setAttribute("stroke-width", n.weight), t.setAttribute("stroke-linecap", n.lineCap), t.setAttribute("stroke-linejoin", n.lineJoin), n.dashArray ? t.setAttribute("stroke-dasharray", n.dashArray) : t.removeAttribute("stroke-dasharray"), n.dashOffset ? t.setAttribute("stroke-dashoffset", n.dashOffset) : t.removeAttribute("stroke-dashoffset")) : t.setAttribute("stroke", "none"), n.fill ? (t.setAttribute("fill", n.fillColor || n.color), t.setAttribute("fill-opacity", n.fillOpacity), t.setAttribute("fill-rule", n.fillRule || "evenodd")) : t.setAttribute("fill", "none"));
4185
- },
4186
- _updatePoly: function(e, t) {
4187
- this._setPath(e, ve(e._parts, t));
4188
- },
4189
- _updateCircle: function(e) {
4190
- var t = e._point, n = Math.max(Math.round(e._radius), 1), r = Math.max(Math.round(e._radiusY), 1) || n, i = "a" + n + "," + r + " 0 1,0 ", a = e._empty() ? "M0 0" : "M" + (t.x - n) + "," + t.y + i + n * 2 + ",0 " + i + -n * 2 + ",0 ";
4191
- this._setPath(e, a);
4192
- },
4193
- _setPath: function(e, t) {
4194
- e._path.setAttribute("d", t);
4195
- },
4196
- _bringToFront: function(e) {
4197
- Dt(e._path);
4198
- },
4199
- _bringToBack: function(e) {
4200
- Ot(e._path);
4201
- }
4202
- });
4203
- P.vml && qr.include(Gr);
4204
- function Jr(e) {
4205
- return P.svg || P.vml ? new qr(e) : null;
4206
- }
4207
- K.include({
4208
- getRenderer: function(e) {
4209
- var t = e.options.renderer || this._getPaneRenderer(e.options.pane) || this.options.renderer || this._renderer;
4210
- return t ||= this._renderer = this._createRenderer(), this.hasLayer(t) || this.addLayer(t), t;
4211
- },
4212
- _getPaneRenderer: function(e) {
4213
- if (e === "overlayPane" || e === void 0) return !1;
4214
- var t = this._paneRenderers[e];
4215
- return t === void 0 && (t = this._createRenderer({ pane: e }), this._paneRenderers[e] = t), t;
4216
- },
4217
- _createRenderer: function(e) {
4218
- return this.options.preferCanvas && Ur(e) || Jr(e);
4219
- }
4220
- });
4221
- var Yr = lr.extend({
4222
- initialize: function(e, t) {
4223
- lr.prototype.initialize.call(this, this._boundsToLatLngs(e), t);
4224
- },
4225
- setBounds: function(e) {
4226
- return this.setLatLngs(this._boundsToLatLngs(e));
4227
- },
4228
- _boundsToLatLngs: function(e) {
4229
- return e = D(e), [
4230
- e.getSouthWest(),
4231
- e.getNorthWest(),
4232
- e.getNorthEast(),
4233
- e.getSouthEast()
4234
- ];
4235
- }
4236
- });
4237
- function Xr(e, t) {
4238
- return new Yr(e, t);
4239
- }
4240
- qr.create = Kr, qr.pointsToPath = ve, dr.geometryToLayer = fr, dr.coordsToLatLng = mr, dr.coordsToLatLngs = hr, dr.latLngToCoords = gr, dr.latLngsToCoords = _r, dr.getFeature = vr, dr.asFeature = yr, K.mergeOptions({ boxZoom: !0 });
4241
- var Zr = J.extend({
4242
- initialize: function(e) {
4243
- this._map = e, this._container = e._container, this._pane = e._panes.overlayPane, this._resetStateTimeout = 0, e.on("unload", this._destroy, this);
4244
- },
4245
- addHooks: function() {
4246
- H(this._container, "mousedown", this._onMouseDown, this);
4247
- },
4248
- removeHooks: function() {
4249
- W(this._container, "mousedown", this._onMouseDown, this);
4250
- },
4251
- moved: function() {
4252
- return this._moved;
4253
- },
4254
- _destroy: function() {
4255
- I(this._pane), delete this._pane;
4256
- },
4257
- _resetState: function() {
4258
- this._resetStateTimeout = 0, this._moved = !1;
4259
- },
4260
- _clearDeferredResetState: function() {
4261
- this._resetStateTimeout !== 0 && (clearTimeout(this._resetStateTimeout), this._resetStateTimeout = 0);
4262
- },
4263
- _onMouseDown: function(e) {
4264
- if (!e.shiftKey || e.which !== 1 && e.button !== 1) return !1;
4265
- this._clearDeferredResetState(), this._resetState(), It(), Bt(), this._startPoint = this._map.mouseEventToContainerPoint(e), H(document, {
4266
- contextmenu: nn,
4267
- mousemove: this._onMouseMove,
4268
- mouseup: this._onMouseUp,
4269
- keydown: this._onKeyDown
4270
- }, this);
4271
- },
4272
- _onMouseMove: function(e) {
4273
- this._moved || (this._moved = !0, this._box = F("div", "leaflet-zoom-box", this._container), R(this._container, "leaflet-crosshair"), this._map.fire("boxzoomstart")), this._point = this._map.mouseEventToContainerPoint(e);
4274
- var t = new w(this._point, this._startPoint), n = t.getSize();
4275
- V(this._box, t.min), this._box.style.width = n.x + "px", this._box.style.height = n.y + "px";
4276
- },
4277
- _finish: function() {
4278
- this._moved && (I(this._box), z(this._container, "leaflet-crosshair")), Lt(), Vt(), W(document, {
4279
- contextmenu: nn,
4280
- mousemove: this._onMouseMove,
4281
- mouseup: this._onMouseUp,
4282
- keydown: this._onKeyDown
4283
- }, this);
4284
- },
4285
- _onMouseUp: function(e) {
4286
- if ((e.which === 1 || e.button === 1) && (this._finish(), this._moved)) {
4287
- this._clearDeferredResetState(), this._resetStateTimeout = setTimeout(i(this._resetState, this), 0);
4288
- var t = new E(this._map.containerPointToLatLng(this._startPoint), this._map.containerPointToLatLng(this._point));
4289
- this._map.fitBounds(t).fire("boxzoomend", { boxZoomBounds: t });
4290
- }
4291
- },
4292
- _onKeyDown: function(e) {
4293
- e.keyCode === 27 && (this._finish(), this._clearDeferredResetState(), this._resetState());
4294
- }
4295
- });
4296
- K.addInitHook("addHandler", "boxZoom", Zr), K.mergeOptions({ doubleClickZoom: !0 });
4297
- var Qr = J.extend({
4298
- addHooks: function() {
4299
- this._map.on("dblclick", this._onDoubleClick, this);
4300
- },
4301
- removeHooks: function() {
4302
- this._map.off("dblclick", this._onDoubleClick, this);
4303
- },
4304
- _onDoubleClick: function(e) {
4305
- var t = this._map, n = t.getZoom(), r = t.options.zoomDelta, i = e.originalEvent.shiftKey ? n - r : n + r;
4306
- t.options.doubleClickZoom === "center" ? t.setZoom(i) : t.setZoomAround(e.containerPoint, i);
4307
- }
4308
- });
4309
- K.addInitHook("addHandler", "doubleClickZoom", Qr), K.mergeOptions({
4310
- dragging: !0,
4311
- inertia: !0,
4312
- inertiaDeceleration: 3400,
4313
- inertiaMaxSpeed: Infinity,
4314
- easeLinearity: .2,
4315
- worldCopyJump: !1,
4316
- maxBoundsViscosity: 0
4317
- });
4318
- var $r = J.extend({
4319
- addHooks: function() {
4320
- if (!this._draggable) {
4321
- var e = this._map;
4322
- this._draggable = new Sn(e._mapPane, e._container), this._draggable.on({
4323
- dragstart: this._onDragStart,
4324
- drag: this._onDrag,
4325
- dragend: this._onDragEnd
4326
- }, this), this._draggable.on("predrag", this._onPreDragLimit, this), e.options.worldCopyJump && (this._draggable.on("predrag", this._onPreDragWrap, this), e.on("zoomend", this._onZoomEnd, this), e.whenReady(this._onZoomEnd, this));
4327
- }
4328
- R(this._map._container, "leaflet-grab leaflet-touch-drag"), this._draggable.enable(), this._positions = [], this._times = [];
4329
- },
4330
- removeHooks: function() {
4331
- z(this._map._container, "leaflet-grab"), z(this._map._container, "leaflet-touch-drag"), this._draggable.disable();
4332
- },
4333
- moved: function() {
4334
- return this._draggable && this._draggable._moved;
4335
- },
4336
- moving: function() {
4337
- return this._draggable && this._draggable._moving;
4338
- },
4339
- _onDragStart: function() {
4340
- var e = this._map;
4341
- if (e._stop(), this._map.options.maxBounds && this._map.options.maxBoundsViscosity) {
4342
- var t = D(this._map.options.maxBounds);
4343
- this._offsetLimit = T(this._map.latLngToContainerPoint(t.getNorthWest()).multiplyBy(-1), this._map.latLngToContainerPoint(t.getSouthEast()).multiplyBy(-1).add(this._map.getSize())), this._viscosity = Math.min(1, Math.max(0, this._map.options.maxBoundsViscosity));
4344
- } else this._offsetLimit = null;
4345
- e.fire("movestart").fire("dragstart"), e.options.inertia && (this._positions = [], this._times = []);
4346
- },
4347
- _onDrag: function(e) {
4348
- if (this._map.options.inertia) {
4349
- var t = this._lastTime = +/* @__PURE__ */ new Date(), n = this._lastPos = this._draggable._absPos || this._draggable._newPos;
4350
- this._positions.push(n), this._times.push(t), this._prunePositions(t);
4351
- }
4352
- this._map.fire("move", e).fire("drag", e);
4353
- },
4354
- _prunePositions: function(e) {
4355
- for (; this._positions.length > 1 && e - this._times[0] > 50;) this._positions.shift(), this._times.shift();
4356
- },
4357
- _onZoomEnd: function() {
4358
- var e = this._map.getSize().divideBy(2), t = this._map.latLngToLayerPoint([0, 0]);
4359
- this._initialWorldOffset = t.subtract(e).x, this._worldWidth = this._map.getPixelWorldBounds().getSize().x;
4360
- },
4361
- _viscousLimit: function(e, t) {
4362
- return e - (e - t) * this._viscosity;
4363
- },
4364
- _onPreDragLimit: function() {
4365
- if (this._viscosity && this._offsetLimit) {
4366
- var e = this._draggable._newPos.subtract(this._draggable._startPos), t = this._offsetLimit;
4367
- e.x < t.min.x && (e.x = this._viscousLimit(e.x, t.min.x)), e.y < t.min.y && (e.y = this._viscousLimit(e.y, t.min.y)), e.x > t.max.x && (e.x = this._viscousLimit(e.x, t.max.x)), e.y > t.max.y && (e.y = this._viscousLimit(e.y, t.max.y)), this._draggable._newPos = this._draggable._startPos.add(e);
4368
- }
4369
- },
4370
- _onPreDragWrap: function() {
4371
- var e = this._worldWidth, t = Math.round(e / 2), n = this._initialWorldOffset, r = this._draggable._newPos.x, i = (r - t + n) % e + t - n, a = (r + t + n) % e - t - n, o = Math.abs(i + n) < Math.abs(a + n) ? i : a;
4372
- this._draggable._absPos = this._draggable._newPos.clone(), this._draggable._newPos.x = o;
4373
- },
4374
- _onDragEnd: function(e) {
4375
- var t = this._map, n = t.options, r = !n.inertia || e.noInertia || this._times.length < 2;
4376
- if (t.fire("dragend", e), r) t.fire("moveend");
4377
- else {
4378
- this._prunePositions(+/* @__PURE__ */ new Date());
4379
- var i = this._lastPos.subtract(this._positions[0]), a = (this._lastTime - this._times[0]) / 1e3, o = n.easeLinearity, s = i.multiplyBy(o / a), c = s.distanceTo([0, 0]), l = Math.min(n.inertiaMaxSpeed, c), u = s.multiplyBy(l / c), d = l / (n.inertiaDeceleration * o), f = u.multiplyBy(-d / 2).round();
4380
- !f.x && !f.y ? t.fire("moveend") : (f = t._limitOffset(f, t.options.maxBounds), v(function() {
4381
- t.panBy(f, {
4382
- duration: d,
4383
- easeLinearity: o,
4384
- noMoveStart: !0,
4385
- animate: !0
4386
- });
4387
- }));
4388
- }
4389
- }
4390
- });
4391
- K.addInitHook("addHandler", "dragging", $r), K.mergeOptions({
4392
- keyboard: !0,
4393
- keyboardPanDelta: 80
4394
- });
4395
- var ei = J.extend({
4396
- keyCodes: {
4397
- left: [37],
4398
- right: [39],
4399
- down: [40],
4400
- up: [38],
4401
- zoomIn: [
4402
- 187,
4403
- 107,
4404
- 61,
4405
- 171
4406
- ],
4407
- zoomOut: [
4408
- 189,
4409
- 109,
4410
- 54,
4411
- 173
4412
- ]
4413
- },
4414
- initialize: function(e) {
4415
- this._map = e, this._setPanDelta(e.options.keyboardPanDelta), this._setZoomDelta(e.options.zoomDelta);
4416
- },
4417
- addHooks: function() {
4418
- var e = this._map._container;
4419
- e.tabIndex <= 0 && (e.tabIndex = "0"), H(e, {
4420
- focus: this._onFocus,
4421
- blur: this._onBlur,
4422
- mousedown: this._onMouseDown
4423
- }, this), this._map.on({
4424
- focus: this._addHooks,
4425
- blur: this._removeHooks
4426
- }, this);
4427
- },
4428
- removeHooks: function() {
4429
- this._removeHooks(), W(this._map._container, {
4430
- focus: this._onFocus,
4431
- blur: this._onBlur,
4432
- mousedown: this._onMouseDown
4433
- }, this), this._map.off({
4434
- focus: this._addHooks,
4435
- blur: this._removeHooks
4436
- }, this);
4437
- },
4438
- _onMouseDown: function() {
4439
- if (!this._focused) {
4440
- var e = document.body, t = document.documentElement, n = e.scrollTop || t.scrollTop, r = e.scrollLeft || t.scrollLeft;
4441
- this._map._container.focus(), window.scrollTo(r, n);
4442
- }
4443
- },
4444
- _onFocus: function() {
4445
- this._focused = !0, this._map.fire("focus");
4446
- },
4447
- _onBlur: function() {
4448
- this._focused = !1, this._map.fire("blur");
4449
- },
4450
- _setPanDelta: function(e) {
4451
- for (var t = this._panKeys = {}, n = this.keyCodes, r = 0, i = n.left.length; r < i; r++) t[n.left[r]] = [-1 * e, 0];
4452
- for (r = 0, i = n.right.length; r < i; r++) t[n.right[r]] = [e, 0];
4453
- for (r = 0, i = n.down.length; r < i; r++) t[n.down[r]] = [0, e];
4454
- for (r = 0, i = n.up.length; r < i; r++) t[n.up[r]] = [0, -1 * e];
4455
- },
4456
- _setZoomDelta: function(e) {
4457
- for (var t = this._zoomKeys = {}, n = this.keyCodes, r = 0, i = n.zoomIn.length; r < i; r++) t[n.zoomIn[r]] = e;
4458
- for (r = 0, i = n.zoomOut.length; r < i; r++) t[n.zoomOut[r]] = -e;
4459
- },
4460
- _addHooks: function() {
4461
- H(document, "keydown", this._onKeyDown, this);
4462
- },
4463
- _removeHooks: function() {
4464
- W(document, "keydown", this._onKeyDown, this);
4465
- },
4466
- _onKeyDown: function(e) {
4467
- if (!(e.altKey || e.ctrlKey || e.metaKey)) {
4468
- var t = e.keyCode, n = this._map, r;
4469
- if (t in this._panKeys) {
4470
- if (!n._panAnim || !n._panAnim._inProgress) {
4471
- if (r = this._panKeys[t], e.shiftKey && (r = C(r).multiplyBy(3)), n.options.maxBounds && (r = n._limitOffset(C(r), n.options.maxBounds)), n.options.worldCopyJump) {
4472
- var i = n.wrapLatLng(n.unproject(n.project(n.getCenter()).add(r)));
4473
- n.panTo(i);
4474
- } else n.panBy(r);
4475
- }
4476
- } else if (t in this._zoomKeys) n.setZoom(n.getZoom() + (e.shiftKey ? 3 : 1) * this._zoomKeys[t]);
4477
- else if (t === 27 && n._popup && n._popup.options.closeOnEscapeKey) n.closePopup();
4478
- else return;
4479
- nn(e);
4480
- }
4481
- }
4482
- });
4483
- K.addInitHook("addHandler", "keyboard", ei), K.mergeOptions({
4484
- scrollWheelZoom: !0,
4485
- wheelDebounceTime: 40,
4486
- wheelPxPerZoomLevel: 60
4487
- });
4488
- var ti = J.extend({
4489
- addHooks: function() {
4490
- H(this._map._container, "wheel", this._onWheelScroll, this), this._delta = 0;
4491
- },
4492
- removeHooks: function() {
4493
- W(this._map._container, "wheel", this._onWheelScroll, this);
4494
- },
4495
- _onWheelScroll: function(e) {
4496
- var t = sn(e), n = this._map.options.wheelDebounceTime;
4497
- this._delta += t, this._lastMousePos = this._map.mouseEventToContainerPoint(e), this._startTime ||= +/* @__PURE__ */ new Date();
4498
- var r = Math.max(n - (+/* @__PURE__ */ new Date() - this._startTime), 0);
4499
- clearTimeout(this._timer), this._timer = setTimeout(i(this._performZoom, this), r), nn(e);
4500
- },
4501
- _performZoom: function() {
4502
- var e = this._map, t = e.getZoom(), n = this._map.options.zoomSnap || 0;
4503
- e._stop();
4504
- var r = this._delta / (this._map.options.wheelPxPerZoomLevel * 4), i = 4 * Math.log(2 / (1 + Math.exp(-Math.abs(r)))) / Math.LN2, a = n ? Math.ceil(i / n) * n : i, o = e._limitZoom(t + (this._delta > 0 ? a : -a)) - t;
4505
- this._delta = 0, this._startTime = null, o && (e.options.scrollWheelZoom === "center" ? e.setZoom(t + o) : e.setZoomAround(this._lastMousePos, t + o));
4506
- }
4507
- });
4508
- K.addInitHook("addHandler", "scrollWheelZoom", ti);
4509
- var ni = 600;
4510
- K.mergeOptions({
4511
- tapHold: P.touchNative && P.safari && P.mobile,
4512
- tapTolerance: 15
4513
- });
4514
- var ri = J.extend({
4515
- addHooks: function() {
4516
- H(this._map._container, "touchstart", this._onDown, this);
4517
- },
4518
- removeHooks: function() {
4519
- W(this._map._container, "touchstart", this._onDown, this);
4520
- },
4521
- _onDown: function(e) {
4522
- if (clearTimeout(this._holdTimeout), e.touches.length === 1) {
4523
- var t = e.touches[0];
4524
- this._startPos = this._newPos = new S(t.clientX, t.clientY), this._holdTimeout = setTimeout(i(function() {
4525
- this._cancel(), this._isTapValid() && (H(document, "touchend", G), H(document, "touchend touchcancel", this._cancelClickPrevent), this._simulateEvent("contextmenu", t));
4526
- }, this), ni), H(document, "touchend touchcancel contextmenu", this._cancel, this), H(document, "touchmove", this._onMove, this);
4527
- }
4528
- },
4529
- _cancelClickPrevent: function e() {
4530
- W(document, "touchend", G), W(document, "touchend touchcancel", e);
4531
- },
4532
- _cancel: function() {
4533
- clearTimeout(this._holdTimeout), W(document, "touchend touchcancel contextmenu", this._cancel, this), W(document, "touchmove", this._onMove, this);
4534
- },
4535
- _onMove: function(e) {
4536
- var t = e.touches[0];
4537
- this._newPos = new S(t.clientX, t.clientY);
4538
- },
4539
- _isTapValid: function() {
4540
- return this._newPos.distanceTo(this._startPos) <= this._map.options.tapTolerance;
4541
- },
4542
- _simulateEvent: function(e, t) {
4543
- var n = new MouseEvent(e, {
4544
- bubbles: !0,
4545
- cancelable: !0,
4546
- view: window,
4547
- screenX: t.screenX,
4548
- screenY: t.screenY,
4549
- clientX: t.clientX,
4550
- clientY: t.clientY
4551
- });
4552
- n._simulated = !0, t.target.dispatchEvent(n);
4553
- }
4554
- });
4555
- K.addInitHook("addHandler", "tapHold", ri), K.mergeOptions({
4556
- touchZoom: P.touch,
4557
- bounceAtZoomLimits: !0
4558
- });
4559
- var ii = J.extend({
4560
- addHooks: function() {
4561
- R(this._map._container, "leaflet-touch-zoom"), H(this._map._container, "touchstart", this._onTouchStart, this);
4562
- },
4563
- removeHooks: function() {
4564
- z(this._map._container, "leaflet-touch-zoom"), W(this._map._container, "touchstart", this._onTouchStart, this);
4565
- },
4566
- _onTouchStart: function(e) {
4567
- var t = this._map;
4568
- if (!(!e.touches || e.touches.length !== 2 || t._animatingZoom || this._zooming)) {
4569
- var n = t.mouseEventToContainerPoint(e.touches[0]), r = t.mouseEventToContainerPoint(e.touches[1]);
4570
- this._centerPoint = t.getSize()._divideBy(2), this._startLatLng = t.containerPointToLatLng(this._centerPoint), t.options.touchZoom !== "center" && (this._pinchStartLatLng = t.containerPointToLatLng(n.add(r)._divideBy(2))), this._startDist = n.distanceTo(r), this._startZoom = t.getZoom(), this._moved = !1, this._zooming = !0, t._stop(), H(document, "touchmove", this._onTouchMove, this), H(document, "touchend touchcancel", this._onTouchEnd, this), G(e);
4571
- }
4572
- },
4573
- _onTouchMove: function(e) {
4574
- if (e.touches && e.touches.length === 2 && this._zooming) {
4575
- var t = this._map, n = t.mouseEventToContainerPoint(e.touches[0]), r = t.mouseEventToContainerPoint(e.touches[1]), a = n.distanceTo(r) / this._startDist;
4576
- if (this._zoom = t.getScaleZoom(a, this._startZoom), !t.options.bounceAtZoomLimits && (this._zoom < t.getMinZoom() && a < 1 || this._zoom > t.getMaxZoom() && a > 1) && (this._zoom = t._limitZoom(this._zoom)), t.options.touchZoom === "center") {
4577
- if (this._center = this._startLatLng, a === 1) return;
4578
- } else {
4579
- var o = n._add(r)._divideBy(2)._subtract(this._centerPoint);
4580
- if (a === 1 && o.x === 0 && o.y === 0) return;
4581
- this._center = t.unproject(t.project(this._pinchStartLatLng, this._zoom).subtract(o), this._zoom);
4582
- }
4583
- this._moved ||= (t._moveStart(!0, !1), !0), y(this._animRequest);
4584
- var s = i(t._move, t, this._center, this._zoom, {
4585
- pinch: !0,
4586
- round: !1
4587
- }, void 0);
4588
- this._animRequest = v(s, this, !0), G(e);
4589
- }
4590
- },
4591
- _onTouchEnd: function() {
4592
- if (!this._moved || !this._zooming) {
4593
- this._zooming = !1;
4594
- return;
4595
- }
4596
- this._zooming = !1, y(this._animRequest), W(document, "touchmove", this._onTouchMove, this), W(document, "touchend touchcancel", this._onTouchEnd, this), this._map.options.zoomAnimation ? this._map._animateZoom(this._center, this._map._limitZoom(this._zoom), !0, this._map.options.zoomSnap) : this._map._resetView(this._center, this._map._limitZoom(this._zoom));
4597
- }
4598
- });
4599
- K.addInitHook("addHandler", "touchZoom", ii), K.BoxZoom = Zr, K.DoubleClickZoom = Qr, K.Drag = $r, K.Keyboard = ei, K.ScrollWheelZoom = ti, K.TapHold = ri, K.TouchZoom = ii, e.Bounds = w, e.Browser = P, e.CRS = A, e.Canvas = Hr, e.Circle = or, e.CircleMarker = ir, e.Class = b, e.Control = q, e.DivIcon = Nr, e.DivOverlay = $, e.DomEvent = ln, e.DomUtil = Jt, e.Draggable = Sn, e.Evented = le, e.FeatureGroup = Z, e.GeoJSON = dr, e.GridLayer = Fr, e.Handler = J, e.Icon = Zn, e.ImageOverlay = Cr, e.LatLng = O, e.LatLngBounds = E, e.Layer = X, e.LayerGroup = Jn, e.LineUtil = Vn, e.Map = K, e.Marker = tr, e.Mixin = bn, e.Path = rr, e.Point = S, e.PolyUtil = En, e.Polygon = lr, e.Polyline = Q, e.Popup = kr, e.PosAnimation = un, e.Projection = Wn, e.Rectangle = Yr, e.Renderer = Vr, e.SVG = qr, e.SVGOverlay = Dr, e.TileLayer = Lr, e.Tooltip = jr, e.Transformation = pe, e.Util = se, e.VideoOverlay = Tr, e.bind = i, e.bounds = T, e.canvas = Ur, e.circle = sr, e.circleMarker = ar, e.control = fn, e.divIcon = Pr, e.extend = n, e.featureGroup = Xn, e.geoJSON = xr, e.geoJson = Sr, e.gridLayer = Ir, e.icon = Qn, e.imageOverlay = wr, e.latLng = k, e.latLngBounds = D, e.layerGroup = Yn, e.map = dn, e.marker = nr, e.point = C, e.polygon = ur, e.polyline = cr, e.popup = Ar, e.rectangle = Xr, e.setOptions = p, e.stamp = o, e.svg = Jr, e.svgOverlay = Or, e.tileLayer = Rr, e.tooltip = Mr, e.transformation = me, e.version = t, e.videoOverlay = Er;
4600
- var ai = window.L;
4601
- e.noConflict = function() {
4602
- return window.L = ai, this;
4603
- }, window.L = e;
4604
- }));
4605
- })))(), 1), D = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADIAAABSCAMAAAAhFXfZAAAC91BMVEVMaXEzeak2f7I4g7g3g7cua5gzeKg8hJo3grY4g7c3grU0gLI2frE0daAubJc2gbQwd6QzeKk2gLMtd5sxdKIua5g1frA2f7IydaM0e6w2fq41fK01eqo3grgubJgta5cxdKI1f7AydaQydaMxc6EubJgvbJkwcZ4ubZkwcJwubZgubJcydqUydKIxapgubJctbJcubZcubJcvbJYubJcvbZkubJctbJctbZcubJg2f7AubJcrbZcubJcubJcua5g3grY0fq8ubJcubJdEkdEwhsw6i88vhswuhcsuhMtBjMgthMsrg8srgss6is8qgcs8i9A9iMYtg8spgcoogMo7hcMngMonf8olfso4gr8kfck5iM8jfMk4iM8he8k1fro7itAgesk2hs8eecgzfLcofssdeMg0hc4cd8g2hcsxeLQbdsgZdcgxeLImfcszhM0vda4xgckzhM4xg84wf8Yxgs4udKsvfcQucqhUndROmdM1fK0wcZ8vb5w0eqpQm9MzeKhXoNVcpdYydKNWn9VZotVKltJFjsIwcJ1Rms9OlslLmtH///8+kc9epdYzd6dbo9VHkMM2f7FHmNBClM8ydqVcpNY9hro3gLM9hLczealQmcw3fa46f7A8gLMxc6I3eagyc6FIldJMl9JSnNRSntNNl9JPnNJFi75UnM9ZodVKksg8kM45jc09e6ZHltFBk883gbRBh7pDk9EwcaBzn784g7dKkcY2i81Om9M7j85Llc81is09g7Q4grY/j9A0eqxKmdFFltBEjcXf6fFImdBCiLxJl9FGlNFBi78yiMxVndEvbpo6js74+vx+psPP3+o/ks5HkcpGmNCjwdZCkNDM3ehYoNJEls+lxNkxh8xHks0+jdC1zd5Lg6r+/v/H2ufz9/o3jM3t8/edvdM/k89Th61OiLBSjbZklbaTt9BfptdjmL1AicBHj8hGk9FAgK1dkLNTjLRekrdClc/k7fM0icy0y9tgp9c4jc2NtM9Dlc8zicxeXZn3AAAAQ3RSTlMAHDdTb4yPA+LtnEQmC4L2EmHqB7XA0d0sr478x4/Yd5i1zOfyPkf1sLVq4Nh3FvjxopQ2/STNuFzUwFIwxKaejILpIBEV9wAABhVJREFUeF6s1NdyFEcYBeBeoQIhRAkLlRDGrhIgY3BJL8CVeKzuyXFzzjkn5ZxzzuScg3PO8cKzu70JkO0LfxdTU//pM9vTu7Xgf6KqOVTb9X7toRrVEfBf1HTVjZccrT/2by1VV928Yty9ZbVuucdz90frG8DBjl9pVApbOstvmMuvVgaNXSfAAd6pGxpy6yxf5ph43pS/4f3uoaGm2rdu72S9xzOvMymkZFq/ptDrk90mhW7e4zl7HLzhxGWPR20xmSxJ/VqldG5m9XhaVOA1DadsNh3Pu5L2N6QtPO/32JpqQBVVk20oy/Pi2s23WEvyfHbe1thadVQttvm7Llf65gGmXK67XtupyoM7HQhmXdLS8oGWJNeOJ3C5fG5XCEJnkez3/oFdsvgJ4l2ANZwhrJKk/7OSXa+3Vw2WJMlKnGkobouYk6T0TyX30klOUnTD9HJ5qpckL3EW/w4XF3Xd0FGywXUrstrclVsqz5Pd/sXFYyDnPdrLcQODmGOK47IZb4CmibmMn+MYRzFZ5jg33ZL/EJrWcszHmANy3ARBK/IXtciJy8VsitPSdE3uuHxzougojcUdr8/32atnz/ev3f/K5wtpxUTpcaI45zusVDpYtZi+jg0oU9b3x74h7+n9ABvYEZeKaVq0sh0AtLKsFtqNBdeT0MrSzwwlq9+x6xAO4tgOtSzbCjrNQQiNvQUbUEubvzBUeGw26yDCsRHCoLkTHDa7IdOLIThs/gHvChszh2CimE8peRs47cxANI0lYNB5y1DljpOF0IhzBDPOZnDOqYYbeGKECbPzWnXludPphw5c2YBq5zlwXphIbO4VDCZ0gnPfUO1TwZoYwAs2ExPCedAu9DAjfQUjzITQb3jNj0KG2Sgt6BHaQUdYzWz+XmBktOHwanXjaSTcwwziBcuMOtwBmqPrTOxFQR/DRKKPqyur0aiW6cULYsx6tBm0jXpR/AUWR6HRq9WVW6MRhIq5jLyjbaCTDCijyYJNpCajdyobP/eTw0iexBAKkJ3gA5KcQb2zBXsIBckn+xVv8jkZSaEFHE+jFEleAEfayRU0MouNoBmB/L50Ai/HSLIHxcrpCvnhSQAuakKp2C/YbCylJjXRVy/z3+Kv/RrNcCo+WUzlVEhzKffnTQnxeN9fWF88fiNCUdSTsaufaChKWInHeysygfpIqagoakW+vV20J8uyl6TyNKEZWV4oRSPyCkWpgOLSbkCObT8o2r6tlG58HQquf6O0v50tB7JM7F4EORd2dx/K0w/KHsVkLPaoYrwgP/y7krr3SSMA4zj+OBgmjYkxcdIJQyQRKgg2viX9Hddi9UBb29LrKR7CVVEEEXWojUkXNyfTNDE14W9gbHJNuhjDettN3ZvbOvdOqCD3Jp/9l+/wJE+9PkYGjx/fqkys3S2rMozM/o2106rfMUINo6hVqz+eu/hd1c4xTg0TAfy5kV+4UG6+IthHTU9woWmxuKNbTfuCSfovBCxq7EtHqvYL4Sm6F8GVxsSXHMQ07TOi1DKtZxjWaaIyi4CXWjxPccUw8WVbMYY5wxC1mzEyXMJWkllpRloi+Kkoq69sxBTlElF6aAxYUbjXNlhlDZilDnM4U5SlN5biRsRHnbx3mbeWjEh4mEyiuJDl5XcWVmX5GvNkFgLWZM5qwsop4/AWfLhU1cR7k1VVvcYCWRkOI6Xy5gmnphCYIkvzuNYzHzosq2oNk2RtSs8khfUOfHIDgR6ysYBaMpl4uEgk2U/oJTs9AaTSwma7dT69geAE2ZpEjUsn2ieJNHeKfrI3EcAGJ2ZaNgVuC8EBctCLc57P5u5led6IOBkIYkuQMrmmjChs4VkfOerHqSBkPzZlhe06RslZ3zMjk2sscqKwY0RcjKK+LWbzd7KiHhkncs/siFJ+V5eXxD34B8nVuJEpGJNmxN2gH3vSvp7J70tF+D1Ej8qUJD1TkErAND2GZwTFg/LubvmgiBG3SOvdlsqFQrkEzJCL1rstlnVFROixZoDDSuXQFHESwVGlcuQcMb/b42NgjLowh5MTDFE3vNB5qStRIErdCQEh6pLPR92anSUb/wAIhldAaDMpGgAAAABJRU5ErkJggg==", O = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABkAAAApCAYAAADAk4LOAAAFgUlEQVR4Aa1XA5BjWRTN2oW17d3YaZtr2962HUzbDNpjszW24mRt28p47v7zq/bXZtrp/lWnXr337j3nPCe85NcypgSFdugCpW5YoDAMRaIMqRi6aKq5E3YqDQO3qAwjVWrD8Ncq/RBpykd8oZUb/kaJutow8r1aP9II0WmLKLIsJyv1w/kqw9Ch2MYdB++12Onxee/QMwvf4/Dk/Lfp/i4nxTXtOoQ4pW5Aj7wpici1A9erdAN2OH64x8OSP9j3Ft3b7aWkTg/Fm91siTra0f9on5sQr9INejH6CUUUpavjFNq1B+Oadhxmnfa8RfEmN8VNAsQhPqF55xHkMzz3jSmChWU6f7/XZKNH+9+hBLOHYozuKQPxyMPUKkrX/K0uWnfFaJGS1QPRtZsOPtr3NsW0uyh6NNCOkU3Yz+bXbT3I8G3xE5EXLXtCXbbqwCO9zPQYPRTZ5vIDXD7U+w7rFDEoUUf7ibHIR4y6bLVPXrz8JVZEql13trxwue/uDivd3fkWRbS6/IA2bID4uk0UpF1N8qLlbBlXs4Ee7HLTfV1j54APvODnSfOWBqtKVvjgLKzF5YdEk5ewRkGlK0i33Eofffc7HT56jD7/6U+qH3Cx7SBLNntH5YIPvODnyfIXZYRVDPqgHtLs5ABHD3YzLuespb7t79FY34DjMwrVrcTuwlT55YMPvOBnRrJ4VXTdNnYug5ucHLBjEpt30701A3Ts+HEa73u6dT3FNWwflY86eMHPk+Yu+i6pzUpRrW7SNDg5JHR4KapmM5Wv2E8Tfcb1HoqqHMHU+uWDD7zg54mz5/2BSnizi9T1Dg4QQXLToGNCkb6tb1NU+QAlGr1++eADrzhn/u8Q2YZhQVlZ5+CAOtqfbhmaUCS1ezNFVm2imDbPmPng5wmz+gwh+oHDce0eUtQ6OGDIyR0uUhUsoO3vfDmmgOezH0mZN59x7MBi++WDL1g/eEiU3avlidO671bkLfwbw5XV2P8Pzo0ydy4t2/0eu33xYSOMOD8hTf4CrBtGMSoXfPLchX+J0ruSePw3LZeK0juPJbYzrhkH0io7B3k164hiGvawhOKMLkrQLyVpZg8rHFW7E2uHOL888IBPlNZ1FPzstSJM694fWr6RwpvcJK60+0HCILTBzZLFNdtAzJaohze60T8qBzyh5ZuOg5e7uwQppofEmf2++DYvmySqGBuKaicF1blQjhuHdvCIMvp8whTTfZzI7RldpwtSzL+F1+wkdZ2TBOW2gIF88PBTzD/gpeREAMEbxnJcaJHNHrpzji0gQCS6hdkEeYt9DF/2qPcEC8RM28Hwmr3sdNyht00byAut2k3gufWNtgtOEOFGUwcXWNDbdNbpgBGxEvKkOQsxivJx33iow0Vw5S6SVTrpVq11ysA2Rp7gTfPfktc6zhtXBBC+adRLshf6sG2RfHPZ5EAc4sVZ83yCN00Fk/4kggu40ZTvIEm5g24qtU4KjBrx/BTTH8ifVASAG7gKrnWxJDcU7x8X6Ecczhm3o6YicvsLXWfh3Ch1W0k8x0nXF+0fFxgt4phz8QvypiwCCFKMqXCnqXExjq10beH+UUA7+nG6mdG/Pu0f3LgFcGrl2s0kNNjpmoJ9o4B29CMO8dMT4Q5ox8uitF6fqsrJOr8qnwNbRzv6hSnG5wP+64C7h9lp30hKNtKdWjtdkbuPA19nJ7Tz3zR/ibgARbhb4AlhavcBebmTHcFl2fvYEnW0ox9xMxKBS8btJ+KiEbq9zA4RthQXDhPa0T9TEe69gWupwc6uBUphquXgf+/FrIjweHQS4/pduMe5ERUMHUd9xv8ZR98CxkS4F2n3EUrUZ10EYNw7BWm9x1GiPssi3GgiGRDKWRYZfXlON+dfNbM+GgIwYdwAAAAASUVORK5CYII=", k = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACkAAAApCAQAAAACach9AAACMUlEQVR4Ae3ShY7jQBAE0Aoz/f9/HTMzhg1zrdKUrJbdx+Kd2nD8VNudfsL/Th///dyQN2TH6f3y/BGpC379rV+S+qqetBOxImNQXL8JCAr2V4iMQXHGNJxeCfZXhSRBcQMfvkOWUdtfzlLgAENmZDcmo2TVmt8OSM2eXxBp3DjHSMFutqS7SbmemzBiR+xpKCNUIRkdkkYxhAkyGoBvyQFEJEefwSmmvBfJuJ6aKqKWnAkvGZOaZXTUgFqYULWNSHUckZuR1HIIimUExutRxwzOLROIG4vKmCKQt364mIlhSyzAf1m9lHZHJZrlAOMMztRRiKimp/rpdJDc9Awry5xTZCte7FHtuS8wJgeYGrex28xNTd086Dik7vUMscQOa8y4DoGtCCSkAKlNwpgNtphjrC6MIHUkR6YWxxs6Sc5xqn222mmCRFzIt8lEdKx+ikCtg91qS2WpwVfBelJCiQJwvzixfI9cxZQWgiSJelKnwBElKYtDOb2MFbhmUigbReQBV0Cg4+qMXSxXSyGUn4UbF8l+7qdSGnTC0XLCmahIgUHLhLOhpVCtw4CzYXvLQWQbJNmxoCsOKAxSgBJno75avolkRw8iIAFcsdc02e9iyCd8tHwmeSSoKTowIgvscSGZUOA7PuCN5b2BX9mQM7S0wYhMNU74zgsPBj3HU7wguAfnxxjFQGBE6pwN+GjME9zHY7zGp8wVxMShYX9NXvEWD3HbwJf4giO4CFIQxXScH1/TM+04kkBiAAAAAElFTkSuQmCC";
4606
- //#endregion
4607
- //#region src/composables/useDeviceLocation.ts
4608
- function A() {
4609
- return { getCurrentPosition: async () => new Promise((e, t) => {
4610
- if (!navigator.geolocation) {
4611
- t(/* @__PURE__ */ Error("geolocation unavailable"));
4612
- return;
4613
- }
4614
- navigator.geolocation.getCurrentPosition((t) => e({
4615
- latitude: t.coords.latitude,
4616
- longitude: t.coords.longitude
4617
- }), (e) => t(e), {
4618
- enableHighAccuracy: !0,
4619
- timeout: 1e4
4620
- });
4621
- }) };
4622
- }
4623
- //#endregion
4624
- //#region src/components/CuiAutomation/config/ConfigTriggerGeofence.vue?vue&type=script&setup=true&lang.ts
4625
- var j = { class: "flex flex-col gap-4" }, de = { class: "flex flex-col field-gap" }, fe = { class: "cui-label" }, pe = { class: "flex flex-col field-gap" }, me = { class: "cui-label" }, he = { class: "flex flex-col field-gap" }, ge = { class: "cui-label" }, _e = { class: "flex flex-col field-gap" }, ve = { class: "cui-label" }, ye = { class: "flex flex-col gap-3" }, be = { class: "cui-label" }, xe = { class: "flex flex-col field-gap" }, Se = { class: "cui-label" }, Ce = { class: "flex flex-col field-gap" }, we = { class: "cui-label" }, Te = { class: "flex flex-col field-gap" }, Ee = { class: "cui-label" }, De = {
4626
- key: 0,
4627
- class: "flex flex-col field-gap"
4628
- }, Oe = { class: "cui-label" }, ke = { class: "text-xs text-muted font-medium" }, Ae = {
4629
- key: 1,
4630
- class: "cui-banner cui-banner-warn"
4631
- }, je = /* @__PURE__ */ g({
4632
- __name: "ConfigTriggerGeofence",
4633
- props: { data: {} },
4634
- emits: ["update:data"],
4635
- setup(e, { emit: t }) {
4636
- let o = e, g = t, { t: C } = v(), w = ie(), { userOptions: je } = le(), { getCurrentPosition: Me } = A(), Ne = [
4637
- {
4638
- label: C("components.automation_nodes.geofence_event_enter"),
4639
- value: "enter"
4640
- },
4641
- {
4642
- label: C("components.automation_nodes.geofence_event_leave"),
4643
- value: "leave"
4644
- },
4645
- {
4646
- label: C("components.automation_nodes.geofence_event_both"),
4647
- value: "both"
4648
- }
4649
- ], Pe = p("mapContainerRef"), M = null, Fe = null, Ie = null, Le = c(() => `${window.location.origin}/api/automations/location/${o.data.geofenceId || "..."}`), Re = c(() => Object.entries(o.data.geofenceUserSecrets ?? {}));
4650
- function ze() {
4651
- if (!Pe.value) return;
4652
- let e = o.data.latitude || 51.505, t = o.data.longitude || -.09;
4653
- M = E.map(Pe.value).setView([e, t], 15), E.tileLayer("https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png", { attribution: "&copy; OpenStreetMap" }).addTo(M);
4654
- let n = E.icon({
4655
- iconRetinaUrl: D,
4656
- iconUrl: O,
4657
- shadowUrl: k,
4658
- iconSize: [25, 41],
4659
- iconAnchor: [12, 41],
4660
- popupAnchor: [1, -34],
4661
- shadowSize: [41, 41]
4662
- });
4663
- Fe = E.marker([e, t], {
4664
- draggable: !0,
4665
- icon: n
4666
- }).addTo(M), Ie = E.circle([e, t], {
4667
- radius: o.data.radius || 200,
4668
- color: "#3b82f6",
4669
- fillOpacity: .15,
4670
- weight: 2
4671
- }).addTo(M), Fe.on("dragend", () => {
4672
- let e = Fe.getLatLng();
4673
- g("update:data", {
4674
- latitude: e.lat,
4675
- longitude: e.lng
4676
- }), Ie.setLatLng(e);
4677
- });
4678
- }
4679
- function Be(e, t, n) {
4680
- M && (M.setView([e, t], n ?? M.getZoom()), Fe?.setLatLng([e, t]), Ie?.setLatLng([e, t]));
4681
- }
4682
- function Ve(e) {
4683
- e != null && (g("update:data", { latitude: e }), Be(e, o.data.longitude));
4684
- }
4685
- function He(e) {
4686
- e != null && (g("update:data", { longitude: e }), Be(o.data.latitude, e));
4687
- }
4688
- function Ue(e) {
4689
- e != null && (qe("radius", e), Ie?.setRadius(e));
4690
- }
4691
- function We() {
4692
- w.add({
4693
- severity: "error",
4694
- summary: C("components.toast.title_error"),
4695
- detail: C("components.automation_nodes.geofence_location_error"),
4696
- life: 4e3
4697
- });
4698
- }
4699
- async function Ge() {
4700
- try {
4701
- let { latitude: e, longitude: t } = await Me();
4702
- g("update:data", {
4703
- latitude: e,
4704
- longitude: t
4705
- }), Be(e, t, 16);
4706
- } catch {
4707
- We();
4708
- }
4709
- }
4710
- function Ke(e) {
4711
- oe(e);
4712
- }
4713
- function qe(e, t) {
4714
- g("update:data", { [e]: t });
4715
- }
4716
- return u(Pe, (e) => {
4717
- e && !M && ze();
4718
- }), i(() => {
4719
- M?.remove(), M = null, Fe = null, Ie = null;
4720
- }), (t, i) => {
4721
- let o = se, c = T, u = y, p = ce, g = ae, ie = b, oe = x, v = ee, le = ne, w = te, E = re, D = S;
4722
- return r(), d("div", j, [
4723
- m("div", de, [m("label", fe, a(s(C)("components.automation_nodes.geofence_zone_name")), 1), _(o, {
4724
- "model-value": e.data.zoneName,
4725
- placeholder: s(C)("components.automation_nodes.geofence_zone_name_placeholder"),
4726
- class: "w-full",
4727
- "onUpdate:modelValue": i[0] ||= (e) => qe("zoneName", e)
4728
- }, null, 8, ["model-value", "placeholder"])]),
4729
- m("div", pe, [
4730
- m("label", me, a(s(C)("components.automation_nodes.geofence_map_hint")), 1),
4731
- m("div", {
4732
- ref_key: "mapContainerRef",
4733
- ref: Pe,
4734
- class: "rounded-lg overflow-hidden border-[1px] border-color",
4735
- style: { height: "220px" }
4736
- }, null, 512),
4737
- _(u, {
4738
- severity: "secondary",
4739
- outlined: "",
4740
- label: s(C)("components.automation_nodes.geofence_use_my_location"),
4741
- class: "cui-button-small w-full",
4742
- onClick: Ge
4743
- }, {
4744
- icon: l(() => [_(c, { class: "w-4 h-4" })]),
4745
- _: 1
4746
- }, 8, ["label"])
4747
- ]),
4748
- m("div", he, [m("label", ge, a(s(C)("components.automation_nodes.geofence_latitude")), 1), _(p, {
4749
- "model-value": e.data.latitude,
4750
- "min-fraction-digits": 4,
4751
- "max-fraction-digits": 6,
4752
- class: "w-full",
4753
- "onUpdate:modelValue": Ve
4754
- }, null, 8, ["model-value"])]),
4755
- m("div", _e, [m("label", ve, a(s(C)("components.automation_nodes.geofence_longitude")), 1), _(p, {
4756
- "model-value": e.data.longitude,
4757
- "min-fraction-digits": 4,
4758
- "max-fraction-digits": 6,
4759
- class: "w-full",
4760
- "onUpdate:modelValue": He
4761
- }, null, 8, ["model-value"])]),
4762
- m("div", ye, [
4763
- m("label", be, a(s(C)("components.automation_nodes.geofence_radius")), 1),
4764
- _(g, {
4765
- "model-value": e.data.radius || 200,
4766
- min: 50,
4767
- max: 5e3,
4768
- step: 50,
4769
- class: "w-full",
4770
- "onUpdate:modelValue": i[1] ||= (e) => Ue(Array.isArray(e) ? e[0] : e)
4771
- }, null, 8, ["model-value"]),
4772
- _(p, {
4773
- "model-value": e.data.radius || 200,
4774
- min: 50,
4775
- max: 5e3,
4776
- suffix: " m",
4777
- class: "w-full",
4778
- "onUpdate:modelValue": Ue
4779
- }, null, 8, ["model-value"])
4780
- ]),
4781
- m("div", xe, [m("label", Se, a(s(C)("components.automation_nodes.geofence_event")), 1), _(ie, {
4782
- "model-value": e.data.event || "both",
4783
- options: Ne,
4784
- "option-label": "label",
4785
- "option-value": "value",
4786
- class: "w-full",
4787
- "onUpdate:modelValue": i[2] ||= (e) => qe("event", e)
4788
- }, null, 8, ["model-value"])]),
4789
- m("div", Ce, [
4790
- m("label", we, a(s(C)("components.automation_nodes.geofence_users")), 1),
4791
- _(oe, {
4792
- "model-value": e.data.users,
4793
- options: s(je),
4794
- "option-label": "label",
4795
- "option-value": "value",
4796
- placeholder: s(C)("components.automation_nodes.geofence_users_placeholder"),
4797
- class: "w-full",
4798
- "onUpdate:modelValue": i[3] ||= (e) => qe("users", e)
4799
- }, null, 8, [
4800
- "model-value",
4801
- "options",
4802
- "placeholder"
4803
- ]),
4804
- _(v, {
4805
- severity: "secondary",
4806
- variant: "simple",
4807
- size: "small",
4808
- class: "cui-input-hint"
4809
- }, {
4810
- default: l(() => [h(a(s(C)("components.automation_nodes.geofence_users_hint")), 1)]),
4811
- _: 1
4812
- })
4813
- ]),
4814
- m("div", Te, [
4815
- m("label", Ee, a(s(C)("components.automation_nodes.geofence_url")), 1),
4816
- _(E, null, {
4817
- default: l(() => [_(o, {
4818
- "model-value": s(Le),
4819
- readonly: "",
4820
- class: "font-mono text-xs"
4821
- }, null, 8, ["model-value"]), _(w, null, {
4822
- default: l(() => [_(le, {
4823
- "action-text": s(C)("components.automation_nodes.webhook_secret_copied"),
4824
- icon: s(ue),
4825
- "button-props": {
4826
- severity: "secondary",
4827
- text: !0
4828
- },
4829
- onAction: i[4] ||= (e) => Ke(s(Le))
4830
- }, null, 8, ["action-text", "icon"])]),
4831
- _: 1
4832
- })]),
4833
- _: 1
4834
- }),
4835
- _(v, {
4836
- severity: "secondary",
4837
- variant: "simple",
4838
- size: "small",
4839
- class: "cui-input-hint"
4840
- }, {
4841
- default: l(() => [h(a(s(C)("components.automation_nodes.geofence_url_hint")), 1)]),
4842
- _: 1
4843
- })
4844
- ]),
4845
- s(Re).length ? (r(), d("div", De, [
4846
- m("label", Oe, a(s(C)("components.automation_nodes.geofence_secret")), 1),
4847
- (r(!0), d(f, null, n(s(Re), ([e, t]) => (r(), d("div", {
4848
- key: e,
4849
- class: "flex flex-col gap-1"
4850
- }, [m("span", ke, a(e), 1), _(E, null, {
4851
- default: l(() => [_(o, {
4852
- "model-value": t,
4853
- readonly: "",
4854
- class: "font-mono text-xs"
4855
- }, null, 8, ["model-value"]), _(w, null, {
4856
- default: l(() => [_(le, {
4857
- "action-text": s(C)("components.automation_nodes.webhook_secret_copied"),
4858
- icon: s(ue),
4859
- "button-props": {
4860
- severity: "secondary",
4861
- text: !0
4862
- },
4863
- onAction: (e) => Ke(t)
4864
- }, null, 8, [
4865
- "action-text",
4866
- "icon",
4867
- "onAction"
4868
- ])]),
4869
- _: 2
4870
- }, 1024)]),
4871
- _: 2
4872
- }, 1024)]))), 128)),
4873
- _(v, {
4874
- severity: "secondary",
4875
- variant: "simple",
4876
- size: "small",
4877
- class: "cui-input-hint"
4878
- }, {
4879
- default: l(() => [h(a(s(C)("components.automation_nodes.geofence_secret_hint")), 1)]),
4880
- _: 1
4881
- })
4882
- ])) : (r(), d("div", Ae, [_(D, { class: "w-5 h-5 shrink-0" }), m("span", null, a(s(C)("components.automation_nodes.geofence_secret_save_hint")), 1)]))
4883
- ]);
4884
- };
4885
- }
4886
- });
4887
- //#endregion
4888
- export { je as default };