@camera.ui/server 2.1.12 → 2.1.13

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 (627) hide show
  1. package/dist/interface/assets/{404-BDi1TzED.js → 404-CVkDpT0X.js} +1 -1
  2. package/dist/interface/assets/{About-DeHiJp3n.js → About-CUgIR2xi.js} +1 -1
  3. package/dist/interface/assets/Automation-BYRKp0AC.js +3 -0
  4. package/dist/interface/assets/{AutomationImport-B3bCE-yS.js → AutomationImport-L_OzZZgi.js} +2 -2
  5. package/dist/interface/assets/{AutomationStore-BoWd7IW9.js → AutomationStore-DaNQqJoT.js} +2 -2
  6. package/dist/interface/assets/AutomationStoreDetail-Seor4Ohh.js +2 -0
  7. package/dist/interface/assets/Automations-BMQIkpUa.js +2 -0
  8. package/dist/interface/assets/Camera-3umh2Xjc.js +2 -0
  9. package/dist/interface/assets/{CameraConsole-C8XSUr7X.js → CameraConsole-BLlgkKDp.js} +2 -2
  10. package/dist/interface/assets/Cameras-DvK8E1Vk.js +651 -0
  11. package/dist/interface/assets/{Camview-Lp3QU0de.css → Camview-DIEa8IRE.css} +1 -1
  12. package/dist/interface/assets/Camview-DSO2lWxT.js +1 -0
  13. package/dist/interface/assets/{CertificateUpload-Cg89m_cM.js → CertificateUpload-BsnlaxRS.js} +1 -1
  14. package/dist/interface/assets/{Config-BDa4dy1w.js → Config-BXj83-No.js} +1 -1
  15. package/dist/interface/assets/{ConfigActionCameraControl-DNmRpuPG.js → ConfigActionCameraControl-BGfvT6ME.js} +1 -1
  16. package/dist/interface/assets/{ConfigActionDelay-Reg_tEG_.js → ConfigActionDelay-D10_C6yo.js} +1 -1
  17. package/dist/interface/assets/{ConfigActionHttp-CqRBOSa3.js → ConfigActionHttp-DL4jh9Wz.js} +1 -1
  18. package/dist/interface/assets/{ConfigActionImageInput-GWECLY4I.js → ConfigActionImageInput-DVvMUzrT.js} +1 -1
  19. package/dist/interface/assets/{ConfigActionMqtt-Di4ZTig8.js → ConfigActionMqtt-BqK3q4cC.js} +1 -1
  20. package/dist/interface/assets/ConfigActionNotification-D_H5Q68D.js +1 -0
  21. package/dist/interface/assets/{ConfigActionNotificationControl-B_p8dnc4.js → ConfigActionNotificationControl-BnTJl4dr.js} +1 -1
  22. package/dist/interface/assets/{ConfigActionOutput-B31cj20h.js → ConfigActionOutput-udY95_rH.js} +1 -1
  23. package/dist/interface/assets/{ConfigActionPlugin-DCUhDIiJ.js → ConfigActionPlugin-C51LrkZb.js} +1 -1
  24. package/dist/interface/assets/{ConfigActionSensor-De63wYQU.js → ConfigActionSensor-B2tFf8x6.js} +1 -1
  25. package/dist/interface/assets/{ConfigActionSnapshot-DZJDjOMT.js → ConfigActionSnapshot-BzmeByH3.js} +1 -1
  26. package/dist/interface/assets/{ConfigActionVariable-Q3QXVMbR.js → ConfigActionVariable-BagC3lj5.js} +1 -1
  27. package/dist/interface/assets/{ConfigConditionIfElse-DKonPxli.js → ConfigConditionIfElse-CQOZJ19Y.js} +1 -1
  28. package/dist/interface/assets/{ConfigConditionSensorState-C_J6ERzt.js → ConfigConditionSensorState-SGYpkNP5.js} +1 -1
  29. package/dist/interface/assets/ConfigConditionSwitch-BXR6xUN8.js +1 -0
  30. package/dist/interface/assets/{ConfigConditionTime-CRDI58_P.js → ConfigConditionTime-BrEhw1R9.js} +1 -1
  31. package/dist/interface/assets/{ConfigSensorValueInput-C3ep90ds.js → ConfigSensorValueInput-DezTWtbA.js} +1 -1
  32. package/dist/interface/assets/{ConfigTriggerDetection-CbVFlyI8.js → ConfigTriggerDetection-xo0imE_3.js} +1 -1
  33. package/dist/interface/assets/ConfigTriggerGeofence-BmJpP4Ew.js +1 -0
  34. package/dist/interface/assets/{ConfigTriggerManual-7kAukUgk.js → ConfigTriggerManual-CmAdnZQK.js} +1 -1
  35. package/dist/interface/assets/{ConfigTriggerMqtt-DUCZZt2j.js → ConfigTriggerMqtt-F19dhVm1.js} +1 -1
  36. package/dist/interface/assets/{ConfigTriggerSchedule-lAiLdu1W.js → ConfigTriggerSchedule-BGci3Aed.js} +1 -1
  37. package/dist/interface/assets/{ConfigTriggerSensor-DIhCfhcN.js → ConfigTriggerSensor-DSEDGB2X.js} +1 -1
  38. package/dist/interface/assets/{ConfigTriggerSystem-DZu6Fp2j.js → ConfigTriggerSystem-DPy8Zir4.js} +1 -1
  39. package/dist/interface/assets/{ConfigTriggerWebhook-D3a5f6vl.js → ConfigTriggerWebhook-Dv0Kmwg8.js} +1 -1
  40. package/dist/interface/assets/Console-Cuh-Vc4u.js +1 -0
  41. package/dist/interface/assets/{CuiAutomationRunsDialog-CgzW_s6M.js → CuiAutomationRunsDialog-B1UeVC6Q.js} +1 -1
  42. package/dist/interface/assets/{CuiBottomSheet-C7UdIQu1.js → CuiBottomSheet-BjkDE7_9.js} +1 -1
  43. package/dist/interface/assets/CuiBottomSheet-C9G-NoMU.js +1 -0
  44. package/dist/interface/assets/CuiCameraPipCard-nrln9zp-.js +1 -0
  45. package/dist/interface/assets/CuiCameraRecordings-B7BhgPpP.css +1 -0
  46. package/dist/interface/assets/CuiCameraRecordings-HKwhFpea.js +1 -0
  47. package/dist/interface/assets/{CuiCameraShares-D3fAJNWF.js → CuiCameraShares-D-fhJCro.js} +1 -1
  48. package/dist/interface/assets/{CuiCameraTable-ApLSxeO4.js → CuiCameraTable-BTVfK-HY.js} +2 -2
  49. package/dist/interface/assets/CuiCameraTable-DGg4_c_u.js +1 -0
  50. package/dist/interface/assets/{CuiChartTable-BeEij8SL.js → CuiChartTable-DAUYP-EW.js} +1 -1
  51. package/dist/interface/assets/{CuiConsole-CMxpzZ51.js → CuiConsole-C7aZj4wK.js} +2 -2
  52. package/dist/interface/assets/{CuiDataTable-f_QVzRqq.js → CuiDataTable-1B8aaZQO.js} +1 -1
  53. package/dist/interface/assets/CuiLightControl-CSA1PYc8.js +1 -0
  54. package/dist/interface/assets/{CuiList-C3oJKyJC.js → CuiList-D-hOSNou.js} +1 -1
  55. package/dist/interface/assets/CuiPluginCard-D1Hkyiy4.js +2 -0
  56. package/dist/interface/assets/{CuiPluginCategoryChip-EJhup0nM.js → CuiPluginCategoryChip-qnn-HD6g.js} +1 -1
  57. package/dist/interface/assets/{CuiPluginOAuthButton-CbPU8trR.js → CuiPluginOAuthButton-CXextmBv.js} +2 -2
  58. package/dist/interface/assets/{CuiPluginTrustBadge-B4bxBl3A.js → CuiPluginTrustBadge-C-8MN2Qc.js} +1 -1
  59. package/dist/interface/assets/{CuiQRCode-CycvR5wz.js → CuiQRCode-D1qmU4qU.js} +1 -1
  60. package/dist/interface/assets/CuiSchema-DnHOpBg4.js +1 -0
  61. package/dist/interface/assets/{CuiTopNavbarItem-D4qP-WpK.js → CuiTopNavbarItem-Csb3O1-n.js} +1 -1
  62. package/dist/interface/assets/Faces-C0QpQxuF.js +1 -0
  63. package/dist/interface/assets/FirstSteps-BqZQovY7.js +1 -0
  64. package/dist/interface/assets/{Floorplan-Da5gt435.css → Floorplan-Bxhdg4C2.css} +1 -1
  65. package/dist/interface/assets/Floorplan-CW-W5ZkV.js +1 -0
  66. package/dist/interface/assets/Instances-VSkiqKKf.js +1 -0
  67. package/dist/interface/assets/{Logs-BBZMBN6a.js → Logs-DQFS2AUi.js} +2 -2
  68. package/dist/interface/assets/{Menu-CRLIo98F.js → Menu-COvvZ_vz.js} +1 -1
  69. package/dist/interface/assets/Metrics-cvbQzChA.js +9 -0
  70. package/dist/interface/assets/OAuthDeviceFlow-3ZC2QCAs.js +1 -0
  71. package/dist/interface/assets/Plugin-DjQd3Y9J.js +1 -0
  72. package/dist/interface/assets/{PluginConsole-D2SUwFDo.js → PluginConsole-BaUkghQD.js} +2 -2
  73. package/dist/interface/assets/PluginDetail-Ofj1hk2q.js +2 -0
  74. package/dist/interface/assets/{PluginSchema-U4q4c9ak.js → PluginSchema-f-ER7hlx.js} +1 -1
  75. package/dist/interface/assets/PluginSearch-Ce3S1HDv.js +1 -0
  76. package/dist/interface/assets/PluginSearch-D5eQsj5p.js +2 -0
  77. package/dist/interface/assets/{PluginUpdateProgress-DWcs6NlJ.js → PluginUpdateProgress-BfYNLvVX.js} +1 -1
  78. package/dist/interface/assets/Plugins-DtDN9z0k.js +1 -0
  79. package/dist/interface/assets/Recordings-CQGnTZFt.js +1 -0
  80. package/dist/interface/assets/SensorEdit-BZtiJyoI.js +1 -0
  81. package/dist/interface/assets/{SensorHistory-B16b4-Um.js → SensorHistory-BFkT3teu.js} +1 -1
  82. package/dist/interface/assets/{Sensors-BsLHVGqk.css → Sensors-CaKl4PQY.css} +1 -1
  83. package/dist/interface/assets/Sensors-DSR-AUqb.js +2 -0
  84. package/dist/interface/assets/{Settings-BOd4EPix.js → Settings-DV3JZFjc.js} +1 -1
  85. package/dist/interface/assets/SettingsAccount-Cd5JPsv2.js +1 -0
  86. package/dist/interface/assets/SettingsAccount-D4ib7Asi.js +1 -0
  87. package/dist/interface/assets/SettingsAppearance-BYsQmdyo.js +1 -0
  88. package/dist/interface/assets/{SettingsAppearance-DZGa_aiI.js → SettingsAppearance-CC6StMAi.js} +1 -1
  89. package/dist/interface/assets/{SettingsBackup-DyblUiF8.js → SettingsBackup-BcVFCbhB.js} +1 -1
  90. package/dist/interface/assets/{SettingsList-DM0yAFkS.js → SettingsList-04HiM3OT.js} +1 -1
  91. package/dist/interface/assets/SettingsMqtt-XaJdsYPn.js +1 -0
  92. package/dist/interface/assets/SettingsNotifications-CUoYMHwr.js +1 -0
  93. package/dist/interface/assets/{SettingsPermissions-w2ptf4wy.js → SettingsPermissions-gFDNSlTh.js} +1 -1
  94. package/dist/interface/assets/SettingsRecordings-Bw64UZWe.js +1 -0
  95. package/dist/interface/assets/SettingsRemote-BnFW-uT-.js +2 -0
  96. package/dist/interface/assets/{SettingsSystem-BsXkYsRC.js → SettingsSystem-Cdjg5GNY.js} +2 -2
  97. package/dist/interface/assets/{SettingsUsers-BSsmo6T0.js → SettingsUsers-DphPL78H.js} +1 -1
  98. package/dist/interface/assets/{Terminal-cU-8dVL_.js → Terminal-CrNjqzTs.js} +2 -2
  99. package/dist/interface/assets/{Updates-dw0MwgsN.js → Updates-V5B9LSD-.js} +1 -1
  100. package/dist/interface/assets/{VariableInput-JSpyezJa.js → VariableInput-n0TxKRqq.js} +1 -1
  101. package/dist/interface/assets/{VariableSuggestions-DZbWgsck.js → VariableSuggestions-C4LmaCAo.js} +1 -1
  102. package/dist/interface/assets/{VersionsHandler-C_mzsgfj.js → VersionsHandler-BPocJcb0.js} +2 -2
  103. package/dist/interface/assets/{VirtualSensorCreate-3mJ8c6Tl.js → VirtualSensorCreate-BPvbrzGS.js} +1 -1
  104. package/dist/interface/assets/Workers-DEvQNzUi.js +2 -0
  105. package/dist/interface/assets/{lightbulb-outline-BtraGBwO.js → alert-outline-DtiCgufF.js} +1 -1
  106. package/dist/interface/assets/{api-COPnjVh2.js → api-BXmkXIE8.js} +1 -1
  107. package/dist/interface/assets/api-DO5wBndX.css +2 -0
  108. package/dist/interface/assets/api-x8zXlvtm.js +4 -0
  109. package/dist/interface/assets/{auth-owqLfbdn.js → auth-BKJnreuu.js} +1 -1
  110. package/dist/interface/assets/{automations-Bql07EFx.js → automations-CVuIXlAQ.js} +1 -1
  111. package/dist/interface/assets/cameraSources-C3cl6FVD.js +1 -0
  112. package/dist/interface/assets/cloudHandoff-BZvvihwX.js +1 -0
  113. package/dist/interface/assets/{config-soN-D-nC.js → config-Sw94rZxF.js} +1 -1
  114. package/dist/interface/assets/{flowSchema-BFZ6n5Su.js → flowSchema-BOrDqdeG.js} +1 -1
  115. package/dist/interface/assets/{intercomService-Bjn0OsVT.js → intercomService-CfCIMUlA.js} +1 -1
  116. package/dist/interface/assets/main-Jl93jEZK.js +3 -0
  117. package/dist/interface/assets/{main-BF8Mg561.css → main-Qqk3RyYP.css} +1 -1
  118. package/dist/interface/assets/{mqtt-CMdU36uB.js → mqtt-BaCMJJk_.js} +1 -1
  119. package/dist/interface/assets/nodeDefinitions-a8iyp3yk.js +1 -0
  120. package/dist/interface/assets/{notifications-C_CbT9aA.js → notifications-l-x8vA4D.js} +1 -1
  121. package/dist/interface/assets/{plugins-CGDE1O2F.js → plugins-GA9v-eQx.js} +1 -1
  122. package/dist/interface/assets/{rooms-BnJo8QbU.js → rooms-DX7PBdpP.js} +1 -1
  123. package/dist/interface/assets/sensorIcons-BTgouEmX.js +1 -0
  124. package/dist/interface/assets/{sensors-Bshdwbki.js → sensors-LJkBCaMk.js} +1 -1
  125. package/dist/interface/assets/{server-CaRDiFTF.js → server-dOx3q8o1.js} +1 -1
  126. package/dist/interface/assets/theme-DgrclY58.js +1 -0
  127. package/dist/interface/assets/types-CSWXRySW.js +1 -0
  128. package/dist/interface/assets/{types-Dwu7_YVv.js → types-D19FOdYo.js} +1 -1
  129. package/dist/interface/assets/types-Yq0FH8fa.js +1 -0
  130. package/dist/interface/assets/ungrouped-B_u9a5wm.js +1 -0
  131. package/dist/interface/assets/{ungrouped-uv64nr5n.css → ungrouped-DTYy_Pud.css} +1 -1
  132. package/dist/interface/assets/{updates-DelnBMM3.js → updates-BVN6uGXy.js} +1 -1
  133. package/dist/interface/assets/{useAppVersion-DeQeb6UF.js → useAppVersion-BUDIkitU.js} +1 -1
  134. package/dist/interface/assets/useBackupRestore-CnSZNCC8.js +1 -0
  135. package/dist/interface/assets/{useCameraOptions-DgMpN00_.js → useCameraOptions-Cgb4eV2d.js} +1 -1
  136. package/dist/interface/assets/{useLogsSocket-BKPqNCOv.js → useLogsSocket-CGKtL049.js} +1 -1
  137. package/dist/interface/assets/{useNavLayout-BJhl8UVM.js → useNavLayout-Dcngcb73.js} +1 -1
  138. package/dist/interface/assets/{usePermissions-Eyt2t6_8.js → usePermissions-zJF4LCPm.js} +1 -1
  139. package/dist/interface/assets/{usePluginUpdates-wfckuNy_.js → usePluginUpdates-DP--lRxm.js} +1 -1
  140. package/dist/interface/assets/{usePushRegistration-jcfB8ujf.js → usePushRegistration-BhPBp28J.js} +1 -1
  141. package/dist/interface/assets/{useServerRestart-XnqHaTb7.js → useServerRestart-BpCDYbPH.js} +1 -1
  142. package/dist/interface/assets/{useStreamStatus-8bE5h_fQ.js → useStreamStatus-BoVMk6KT.js} +1 -1
  143. package/dist/interface/assets/{useTabSwipe-DxZfseQO.js → useTabSwipe--t-Qqa31.js} +1 -1
  144. package/dist/interface/assets/{useUpdateChannel-CjxdE3h1.js → useUpdateChannel-DAuhU-__.js} +1 -1
  145. package/dist/interface/assets/{useUpdatesSocket-DFt7_yr8.js → useUpdatesSocket-C-j3b3tU.js} +1 -1
  146. package/dist/interface/assets/{useUserOptions-DStio0f5.js → useUserOptions-CcLVC73O.js} +1 -1
  147. package/dist/interface/assets/vendor-cameraui-phsC2Mmi.js +2326 -0
  148. package/dist/interface/assets/vendor-core-C0ZWoGJD.js +1 -0
  149. package/dist/interface/assets/{vendor-primevue-DXXRO7Z5.js → vendor-primevue-nPess0JU.js} +76 -76
  150. package/dist/interface/assets/vendor-zod-CJ7LAMqQ.js +99 -0
  151. package/dist/interface/ha/404-PedrGUiq.js +60 -0
  152. package/dist/interface/ha/About-l5fkBqG7.js +55 -0
  153. package/dist/interface/ha/Automation-CaSlGjT4.js +2015 -0
  154. package/dist/interface/ha/AutomationImport-BNavtjDq.js +206 -0
  155. package/dist/interface/ha/AutomationStore-BVSW8TVt.js +335 -0
  156. package/dist/interface/ha/AutomationStoreDetail-DHZwlpz0.js +122 -0
  157. package/dist/interface/ha/Automations-CZ2jvH6d.js +437 -0
  158. package/dist/interface/ha/Camera-CggUrrPm.js +625 -0
  159. package/dist/interface/ha/CameraConsole-DpzF48TF.js +52 -0
  160. package/dist/interface/ha/Cameras-K-kQF5tG.js +1970 -0
  161. package/dist/interface/ha/Camview-zJVP7JwZ.js +1337 -0
  162. package/dist/interface/ha/CertificateUpload-DbBQ87OT.js +117 -0
  163. package/dist/interface/ha/Config-Bsud2DYI.js +356 -0
  164. package/dist/interface/ha/ConfigActionCameraControl-Czkfw_NO.js +152 -0
  165. package/dist/interface/ha/ConfigActionDelay-BHug57u7.js +61 -0
  166. package/dist/interface/ha/ConfigActionHttp-LfbxbfgG.js +134 -0
  167. package/dist/interface/ha/ConfigActionImageInput-Ce2GJzCm.js +171 -0
  168. package/dist/interface/ha/ConfigActionMqtt-KmCGcNZb.js +81 -0
  169. package/dist/interface/ha/ConfigActionNotification-DUMY_3IT.js +199 -0
  170. package/dist/interface/ha/ConfigActionNotificationControl-B9Z2i5WR.js +111 -0
  171. package/dist/interface/ha/ConfigActionOutput-CX-ZQjcs.js +98 -0
  172. package/dist/interface/ha/ConfigActionPlugin-y5PuPwdk.js +172 -0
  173. package/dist/interface/ha/ConfigActionSensor-CC39Rpxi.js +139 -0
  174. package/dist/interface/ha/ConfigActionSnapshot-CWyhx6rk.js +48 -0
  175. package/dist/interface/ha/ConfigActionVariable-BNRLCthd.js +88 -0
  176. package/dist/interface/ha/ConfigConditionIfElse-BayS5_Dr.js +124 -0
  177. package/dist/interface/ha/ConfigConditionSensorState-DLXNqL-R.js +192 -0
  178. package/dist/interface/ha/ConfigConditionSwitch-BBesQgWi.js +128 -0
  179. package/dist/interface/ha/ConfigConditionTime-aD8mk2aa.js +95 -0
  180. package/dist/interface/ha/ConfigSensorValueInput-5JzesEuD.js +169 -0
  181. package/dist/interface/ha/ConfigTriggerDetection--BcjPuyh.js +241 -0
  182. package/dist/interface/ha/ConfigTriggerGeofence-BZi5a2Yv.js +4896 -0
  183. package/dist/interface/ha/ConfigTriggerManual-ConxhgNx.js +14 -0
  184. package/dist/interface/ha/ConfigTriggerMqtt-B6C9injX.js +134 -0
  185. package/dist/interface/ha/ConfigTriggerSchedule-Vv5iNKL3.js +72 -0
  186. package/dist/interface/ha/ConfigTriggerSensor-beixHfSD.js +73 -0
  187. package/dist/interface/ha/ConfigTriggerSystem-BHDpn485.js +188 -0
  188. package/dist/interface/ha/ConfigTriggerWebhook-D9cuCU_p.js +94 -0
  189. package/dist/interface/ha/Console-CbQnrt6X.js +348 -0
  190. package/dist/interface/ha/CuiAutomationRunsDialog-CckgCRNS.js +130 -0
  191. package/dist/interface/ha/CuiBottomSheet-juhGdTsO.js +270 -0
  192. package/dist/interface/ha/CuiCameraRecordings-CLzZiXhk.js +552 -0
  193. package/dist/interface/ha/CuiCameraShares-Dzx1jZGE.js +121 -0
  194. package/dist/interface/ha/CuiCameraTable-ug0ik9N-.js +153 -0
  195. package/dist/interface/ha/CuiChartTable-7EnAA-WG.js +6784 -0
  196. package/dist/interface/ha/CuiConsole-DOnyBSL7.js +244 -0
  197. package/dist/interface/ha/CuiDataTable-Cx9GBqsV.js +8725 -0
  198. package/dist/interface/ha/CuiList-C45psxFZ.js +57 -0
  199. package/dist/interface/ha/CuiMarkdownContent-D7sCtnNQ.js +4716 -0
  200. package/dist/interface/ha/CuiPluginCard-ChLIfOms.js +769 -0
  201. package/dist/interface/ha/CuiPluginOAuthButton-B6vPOEx2.js +105 -0
  202. package/dist/interface/ha/CuiPluginTrustBadge-BvPV93D0.js +123 -0
  203. package/dist/interface/ha/CuiQRCode-Djr3z54t.js +86 -0
  204. package/dist/interface/ha/CuiSchema-dl7TXv-k.js +963 -0
  205. package/dist/interface/ha/CuiTopNavbarItem-BXoda5eM.js +141 -0
  206. package/dist/interface/ha/Faces-DnqWMGWW.js +1281 -0
  207. package/dist/interface/ha/FirstSteps-CFawb017.js +251 -0
  208. package/dist/interface/ha/Floorplan-Mv-Ootly.js +3677 -0
  209. package/dist/interface/ha/Instances-DJjZ3btI.js +680 -0
  210. package/dist/interface/ha/Logs-CLFhW1xq.js +418 -0
  211. package/dist/interface/ha/Menu-D7QTRqMJ.js +161 -0
  212. package/dist/interface/ha/Metrics-CCvFtezL.js +1330 -0
  213. package/dist/interface/ha/OAuthDeviceFlow-4YupTNsK.js +112 -0
  214. package/dist/interface/ha/Plugin-BHU0yhBa.js +1404 -0
  215. package/dist/interface/ha/PluginConsole-CNrLuFQM.js +56 -0
  216. package/dist/interface/ha/PluginDetail-Bm3X-xN4.js +230 -0
  217. package/dist/interface/ha/PluginSearch-C0be8cYD.js +475 -0
  218. package/dist/interface/ha/PluginUpdateProgress-DVvgYMLG.js +34 -0
  219. package/dist/interface/ha/Plugins-R-uz0Se-.js +705 -0
  220. package/dist/interface/ha/Recordings-DAwbihs8.js +1463 -0
  221. package/dist/interface/ha/SensorEdit-BxE1cRLR.js +1460 -0
  222. package/dist/interface/ha/SensorHistory-DUGlH2pU.js +54 -0
  223. package/dist/interface/ha/Sensors-Cax5RlPH.js +1358 -0
  224. package/dist/interface/ha/Settings-DKtlCoyz.js +218 -0
  225. package/dist/interface/ha/SettingsAccount-2e_Vjpev.js +970 -0
  226. package/dist/interface/ha/SettingsAppearance-DCm60FhX.js +220 -0
  227. package/dist/interface/ha/SettingsBackup-CiM_nNWt.js +556 -0
  228. package/dist/interface/ha/SettingsList-D4D3cmLo.js +40 -0
  229. package/dist/interface/ha/SettingsMqtt-CID4L0PD.js +526 -0
  230. package/dist/interface/ha/SettingsNotifications-DGJkhm8T.js +529 -0
  231. package/dist/interface/ha/SettingsPermissions-Cd0rtgli.js +84 -0
  232. package/dist/interface/ha/SettingsRecordings-pR4L0wgy.js +151 -0
  233. package/dist/interface/ha/SettingsRemote-CYg-LSQK.js +1810 -0
  234. package/dist/interface/ha/SettingsSystem-BeYJN1Ut.js +376 -0
  235. package/dist/interface/ha/SettingsUsers-F4CZggSR.js +379 -0
  236. package/dist/interface/ha/Terminal-iQahUx9P.js +631 -0
  237. package/dist/interface/ha/Updates-ClQ77p-o.js +356 -0
  238. package/dist/interface/ha/VariableInput-BOHBmNff.js +52 -0
  239. package/dist/interface/ha/VariableSuggestions-BE06z6SW.js +201 -0
  240. package/dist/interface/ha/VersionsHandler-Cx9u0oj8.js +211 -0
  241. package/dist/interface/ha/VirtualSensorCreate-CvSzLo4N.js +101 -0
  242. package/dist/interface/ha/Workers-CEJtdSu-.js +765 -0
  243. package/dist/interface/ha/accordion-BT2wHwK8.js +577 -0
  244. package/dist/interface/ha/account-B1xL2wxD.js +19 -0
  245. package/dist/interface/ha/ace-Dh61T4RV.js +13238 -0
  246. package/dist/interface/ha/ace.config-HyzcNHkM.js +1429 -0
  247. package/dist/interface/ha/alert-circle-CLRn5GAd.js +19 -0
  248. package/dist/interface/ha/alert-outline-CGTMAqXf.js +75 -0
  249. package/dist/interface/ha/api-BmNBy1ay.js +29 -0
  250. package/dist/interface/ha/api-CWJkvtnM.js +60866 -0
  251. package/dist/interface/ha/arrow-left-DkvcResi.js +19 -0
  252. package/dist/interface/ha/auth-X6tkVYJs.js +271 -0
  253. package/dist/interface/ha/autocomplete-L_jK3s3m.js +1373 -0
  254. package/dist/interface/ha/automationBlueprint-D1TiCF7R.js +249 -0
  255. package/dist/interface/ha/back-filled-Cxzg5vQg.js +20 -0
  256. package/dist/interface/ha/base-D_LAf3cS.js +26 -0
  257. package/dist/interface/ha/base-c1lsE5TW.js +125 -0
  258. package/dist/interface/ha/bell-ring-xrXdzNHW.js +19 -0
  259. package/dist/interface/ha/brain-DyOOk3m3.js +19 -0
  260. package/dist/interface/ha/browser-Bxx7joo_.js +1227 -0
  261. package/dist/interface/ha/browserconfig.xml +11 -0
  262. package/dist/interface/ha/button-BlYuI0Q7.js +406 -0
  263. package/dist/interface/ha/cameraui-cards.js +190 -0
  264. package/dist/interface/ha/cards-CNOyNWMA.js +13316 -0
  265. package/dist/interface/ha/cctv-Bz6BH0ns.js +19 -0
  266. package/dist/interface/ha/check-circle-D_wDxrLs.js +19 -0
  267. package/dist/interface/ha/chevron-down-P5MtUhJO.js +19 -0
  268. package/dist/interface/ha/chip-DxGABeun.js +149 -0
  269. package/dist/interface/ha/clock-outline-JxApewmA.js +19 -0
  270. package/dist/interface/ha/close-Eq3txTBS.js +19 -0
  271. package/dist/interface/ha/close-circle-C2nTtN_-.js +19 -0
  272. package/dist/interface/ha/config-E4Jkelkr.js +116 -0
  273. package/dist/interface/ha/content-copy-DpPXKtKE.js +19 -0
  274. package/dist/interface/ha/copy-C48Ur26H.js +22 -0
  275. package/dist/interface/ha/datepicker-BuvKhBWJ.js +3236 -0
  276. package/dist/interface/ha/definitions-E-sY7Cxg.js +23 -0
  277. package/dist/interface/ha/delete-D-m8mqly.js +19 -0
  278. package/dist/interface/ha/dist-B7lgvbyI.js +279 -0
  279. package/dist/interface/ha/dist-Ca9_5rzq.js +3457 -0
  280. package/dist/interface/ha/divider-jkWvVbPJ.js +110 -0
  281. package/dist/interface/ha/download-Cnr7IQKX.js +19 -0
  282. package/dist/interface/ha/esm-1sIZN4t7.js +6 -0
  283. package/dist/interface/ha/esm-6hnPZcZr.js +15 -0
  284. package/dist/interface/ha/esm-B72ViJ7F.js +5 -0
  285. package/dist/interface/ha/esm-BGlkcEes.js +156 -0
  286. package/dist/interface/ha/esm-BKPZuThK.js +5 -0
  287. package/dist/interface/ha/esm-BMx7MsZ_.js +15 -0
  288. package/dist/interface/ha/esm-CChFtwcx.js +21 -0
  289. package/dist/interface/ha/esm-CMTmAdHP.js +5 -0
  290. package/dist/interface/ha/esm-CkoEL9YX.js +7 -0
  291. package/dist/interface/ha/esm-CvxDASXR.js +23 -0
  292. package/dist/interface/ha/esm-Demxl4zQ.js +5 -0
  293. package/dist/interface/ha/esm-DiBhi9zp.js +5 -0
  294. package/dist/interface/ha/esm-XFPB9fYb.js +15 -0
  295. package/dist/interface/ha/eventLabels-B4C1_4vT.js +42 -0
  296. package/dist/interface/ha/eye-off-AdumIw0H.js +33 -0
  297. package/dist/interface/ha/eye-off-outline-DO3xfiua.js +19 -0
  298. package/dist/interface/ha/fonts/InterVariable.woff2 +0 -0
  299. package/dist/interface/ha/history-BoZc8mgf.js +19 -0
  300. package/dist/interface/ha/home-am0tRTsk.js +19 -0
  301. package/dist/interface/ha/information-outline-DIdNxPCN.js +19 -0
  302. package/dist/interface/ha/inputicon-6-vaPLbw.js +324 -0
  303. package/dist/interface/ha/inputnumber-B1Buq8Nc.js +1033 -0
  304. package/dist/interface/ha/inputtext-DGIESrd0.js +257 -0
  305. package/dist/interface/ha/intercomService-jB2mTgsn.js +1406 -0
  306. package/dist/interface/ha/message-C8U_kMBA.js +244 -0
  307. package/dist/interface/ha/minus-DKa9TXat.js +19 -0
  308. package/dist/interface/ha/minus-QyTgaT70.js +46 -0
  309. package/dist/interface/ha/mqtt-BmDCmG9h.js +56 -0
  310. package/dist/interface/ha/multiselect-BbgV_fPx.js +1492 -0
  311. package/dist/interface/ha/native-BaNeloQn.js +35 -0
  312. package/dist/interface/ha/native-C8PbNqsJ.js +29 -0
  313. package/dist/interface/ha/notifications-B51yvrGL.js +159 -0
  314. package/dist/interface/ha/og-share.png +0 -0
  315. package/dist/interface/ha/pencil-outline-BqfTDXIh.js +19 -0
  316. package/dist/interface/ha/pinia-3D39Do4a.js +6934 -0
  317. package/dist/interface/ha/platformLabels-C3d1PLg-.js +27 -0
  318. package/dist/interface/ha/plugin-DAGqBiG_.js +38 -0
  319. package/dist/interface/ha/plugins-dkWbXWVM.js +592 -0
  320. package/dist/interface/ha/plus-CNdrByQb.js +46 -0
  321. package/dist/interface/ha/plus-d_caPq5l.js +19 -0
  322. package/dist/interface/ha/progressbar-CIoPoMSe.js +95 -0
  323. package/dist/interface/ha/protocol-BB4jdtUC-K1r3LFCq.js +706 -0
  324. package/dist/interface/ha/pwa/apple-splash-landscape-dark-1136x640.png +0 -0
  325. package/dist/interface/ha/pwa/apple-splash-landscape-dark-1334x750.png +0 -0
  326. package/dist/interface/ha/pwa/apple-splash-landscape-dark-1792x828.png +0 -0
  327. package/dist/interface/ha/pwa/apple-splash-landscape-dark-2048x1536.png +0 -0
  328. package/dist/interface/ha/pwa/apple-splash-landscape-dark-2160x1620.png +0 -0
  329. package/dist/interface/ha/pwa/apple-splash-landscape-dark-2208x1242.png +0 -0
  330. package/dist/interface/ha/pwa/apple-splash-landscape-dark-2224x1668.png +0 -0
  331. package/dist/interface/ha/pwa/apple-splash-landscape-dark-2388x1668.png +0 -0
  332. package/dist/interface/ha/pwa/apple-splash-landscape-dark-2436x1125.png +0 -0
  333. package/dist/interface/ha/pwa/apple-splash-landscape-dark-2532x1170.png +0 -0
  334. package/dist/interface/ha/pwa/apple-splash-landscape-dark-2556x1179.png +0 -0
  335. package/dist/interface/ha/pwa/apple-splash-landscape-dark-2688x1242.png +0 -0
  336. package/dist/interface/ha/pwa/apple-splash-landscape-dark-2732x2048.png +0 -0
  337. package/dist/interface/ha/pwa/apple-splash-landscape-dark-2778x1284.png +0 -0
  338. package/dist/interface/ha/pwa/apple-splash-landscape-dark-2796x1290.png +0 -0
  339. package/dist/interface/ha/pwa/apple-splash-landscape-light-1136x640.png +0 -0
  340. package/dist/interface/ha/pwa/apple-splash-landscape-light-1334x750.png +0 -0
  341. package/dist/interface/ha/pwa/apple-splash-landscape-light-1792x828.png +0 -0
  342. package/dist/interface/ha/pwa/apple-splash-landscape-light-2048x1536.png +0 -0
  343. package/dist/interface/ha/pwa/apple-splash-landscape-light-2160x1620.png +0 -0
  344. package/dist/interface/ha/pwa/apple-splash-landscape-light-2208x1242.png +0 -0
  345. package/dist/interface/ha/pwa/apple-splash-landscape-light-2224x1668.png +0 -0
  346. package/dist/interface/ha/pwa/apple-splash-landscape-light-2388x1668.png +0 -0
  347. package/dist/interface/ha/pwa/apple-splash-landscape-light-2436x1125.png +0 -0
  348. package/dist/interface/ha/pwa/apple-splash-landscape-light-2532x1170.png +0 -0
  349. package/dist/interface/ha/pwa/apple-splash-landscape-light-2556x1179.png +0 -0
  350. package/dist/interface/ha/pwa/apple-splash-landscape-light-2688x1242.png +0 -0
  351. package/dist/interface/ha/pwa/apple-splash-landscape-light-2732x2048.png +0 -0
  352. package/dist/interface/ha/pwa/apple-splash-landscape-light-2778x1284.png +0 -0
  353. package/dist/interface/ha/pwa/apple-splash-landscape-light-2796x1290.png +0 -0
  354. package/dist/interface/ha/pwa/apple-splash-portrait-dark-1125x2436.png +0 -0
  355. package/dist/interface/ha/pwa/apple-splash-portrait-dark-1170x2532.png +0 -0
  356. package/dist/interface/ha/pwa/apple-splash-portrait-dark-1179x2556.png +0 -0
  357. package/dist/interface/ha/pwa/apple-splash-portrait-dark-1242x2208.png +0 -0
  358. package/dist/interface/ha/pwa/apple-splash-portrait-dark-1242x2688.png +0 -0
  359. package/dist/interface/ha/pwa/apple-splash-portrait-dark-1284x2778.png +0 -0
  360. package/dist/interface/ha/pwa/apple-splash-portrait-dark-1290x2796.png +0 -0
  361. package/dist/interface/ha/pwa/apple-splash-portrait-dark-1536x2048.png +0 -0
  362. package/dist/interface/ha/pwa/apple-splash-portrait-dark-1620x2160.png +0 -0
  363. package/dist/interface/ha/pwa/apple-splash-portrait-dark-1668x2224.png +0 -0
  364. package/dist/interface/ha/pwa/apple-splash-portrait-dark-1668x2388.png +0 -0
  365. package/dist/interface/ha/pwa/apple-splash-portrait-dark-2048x2732.png +0 -0
  366. package/dist/interface/ha/pwa/apple-splash-portrait-dark-640x1136.png +0 -0
  367. package/dist/interface/ha/pwa/apple-splash-portrait-dark-750x1334.png +0 -0
  368. package/dist/interface/ha/pwa/apple-splash-portrait-dark-828x1792.png +0 -0
  369. package/dist/interface/ha/pwa/apple-splash-portrait-light-1125x2436.png +0 -0
  370. package/dist/interface/ha/pwa/apple-splash-portrait-light-1170x2532.png +0 -0
  371. package/dist/interface/ha/pwa/apple-splash-portrait-light-1179x2556.png +0 -0
  372. package/dist/interface/ha/pwa/apple-splash-portrait-light-1242x2208.png +0 -0
  373. package/dist/interface/ha/pwa/apple-splash-portrait-light-1242x2688.png +0 -0
  374. package/dist/interface/ha/pwa/apple-splash-portrait-light-1284x2778.png +0 -0
  375. package/dist/interface/ha/pwa/apple-splash-portrait-light-1290x2796.png +0 -0
  376. package/dist/interface/ha/pwa/apple-splash-portrait-light-1536x2048.png +0 -0
  377. package/dist/interface/ha/pwa/apple-splash-portrait-light-1620x2160.png +0 -0
  378. package/dist/interface/ha/pwa/apple-splash-portrait-light-1668x2224.png +0 -0
  379. package/dist/interface/ha/pwa/apple-splash-portrait-light-1668x2388.png +0 -0
  380. package/dist/interface/ha/pwa/apple-splash-portrait-light-2048x2732.png +0 -0
  381. package/dist/interface/ha/pwa/apple-splash-portrait-light-640x1136.png +0 -0
  382. package/dist/interface/ha/pwa/apple-splash-portrait-light-750x1334.png +0 -0
  383. package/dist/interface/ha/pwa/apple-splash-portrait-light-828x1792.png +0 -0
  384. package/dist/interface/ha/pwa/apple-touch-icon-180x180.png +0 -0
  385. package/dist/interface/ha/pwa/favicon-16.ico +0 -0
  386. package/dist/interface/ha/pwa/favicon-32.ico +0 -0
  387. package/dist/interface/ha/pwa/favicon-48.ico +0 -0
  388. package/dist/interface/ha/pwa/favicon-64.ico +0 -0
  389. package/dist/interface/ha/pwa/logo.svg +1 -0
  390. package/dist/interface/ha/pwa/maskable-icon-1240x600.png +0 -0
  391. package/dist/interface/ha/pwa/maskable-icon-512x512.png +0 -0
  392. package/dist/interface/ha/pwa/maskable-icon-620x300.png +0 -0
  393. package/dist/interface/ha/pwa/pwa-1024x1024.png +0 -0
  394. package/dist/interface/ha/pwa/pwa-120x120.png +0 -0
  395. package/dist/interface/ha/pwa/pwa-144x144.png +0 -0
  396. package/dist/interface/ha/pwa/pwa-152x152.png +0 -0
  397. package/dist/interface/ha/pwa/pwa-167x167.png +0 -0
  398. package/dist/interface/ha/pwa/pwa-180x180.png +0 -0
  399. package/dist/interface/ha/pwa/pwa-192x192.png +0 -0
  400. package/dist/interface/ha/pwa/pwa-24x24.png +0 -0
  401. package/dist/interface/ha/pwa/pwa-300x300.png +0 -0
  402. package/dist/interface/ha/pwa/pwa-36x36.png +0 -0
  403. package/dist/interface/ha/pwa/pwa-48x48.png +0 -0
  404. package/dist/interface/ha/pwa/pwa-50x50.png +0 -0
  405. package/dist/interface/ha/pwa/pwa-64x64.png +0 -0
  406. package/dist/interface/ha/pwa/pwa-72x72.png +0 -0
  407. package/dist/interface/ha/pwa/pwa-88x88.png +0 -0
  408. package/dist/interface/ha/pwa/pwa-96x96.png +0 -0
  409. package/dist/interface/ha/radar-C7lI26j4.js +19 -0
  410. package/dist/interface/ha/refresh-BIhepekY.js +19 -0
  411. package/dist/interface/ha/ring-resize-VS4MSeBv.js +16 -0
  412. package/dist/interface/ha/ripple-BilzxWfY.js +2928 -0
  413. package/dist/interface/ha/robots.txt +2 -0
  414. package/dist/interface/ha/rolldown-runtime-CEFd7nDs.js +30 -0
  415. package/dist/interface/ha/rooms-B-FUXQ1p.js +45 -0
  416. package/dist/interface/ha/round-alt-arrow-left-bold-CWEg-ZLF.js +37 -0
  417. package/dist/interface/ha/runtime-core.esm-bundler-D8slQ3BU.js +3295 -0
  418. package/dist/interface/ha/search-CoOsbgeb.js +19 -0
  419. package/dist/interface/ha/select-DjWkRqsI.js +1382 -0
  420. package/dist/interface/ha/server-CKJKoFfg.js +239 -0
  421. package/dist/interface/ha/settings-EKkSQLzv.js +22 -0
  422. package/dist/interface/ha/source-branch-CZwSOrQA.js +19 -0
  423. package/dist/interface/ha/speeddial-Dv9txWte.js +682 -0
  424. package/dist/interface/ha/spinner-D6iUldg9.js +46 -0
  425. package/dist/interface/ha/synapse-CGrlyQDE.js +35 -0
  426. package/dist/interface/ha/tag-CXgC9OZ6.js +95 -0
  427. package/dist/interface/ha/textarea-DvLkfUX7.js +130 -0
  428. package/dist/interface/ha/tooltip-BIrD_hC8.js +277 -0
  429. package/dist/interface/ha/trash-2-C4zSCZfs.js +23 -0
  430. package/dist/interface/ha/trash-can-outline-DCqsCOd2.js +19 -0
  431. package/dist/interface/ha/trash-fill-BPsrwR8X.js +21 -0
  432. package/dist/interface/ha/types-C7MzwoQR.js +28 -0
  433. package/dist/interface/ha/types-J_J0HKlK.js +1032 -0
  434. package/dist/interface/ha/ungrouped-BpaM88Y-.js +1116 -0
  435. package/dist/interface/ha/updates-BdVmkKAa.js +341 -0
  436. package/dist/interface/ha/upload-2xJkVPZE.js +19 -0
  437. package/dist/interface/ha/upload-wQHBRZX_.js +23 -0
  438. package/dist/interface/ha/useAppVersion-DzDaOsKc.js +22 -0
  439. package/dist/interface/ha/useLogsSocket-CWUE-KXV.js +59 -0
  440. package/dist/interface/ha/useNavLayout-BqpyvD2F.js +125 -0
  441. package/dist/interface/ha/usePermissions-BIUeW4ef.js +72 -0
  442. package/dist/interface/ha/useServerRestart-0c4gA1fG.js +23 -0
  443. package/dist/interface/ha/useTabSwipe-C8LdKw23.js +45 -0
  444. package/dist/interface/ha/useUpdateChannel-CHVLthZB.js +22 -0
  445. package/dist/interface/ha/useUpdatesSocket-CaxEs511.js +34 -0
  446. package/dist/interface/ha/useUserOptions-Rk_71WAK.js +15 -0
  447. package/dist/interface/ha/utils-DYtBrGDz.js +7 -0
  448. package/dist/interface/ha/virtualscroller-s_gNqN5p.js +996 -0
  449. package/dist/interface/ha/vue-flow-background-B0Vu4-8M.js +6840 -0
  450. package/dist/interface/ha/vue-i18n-Dcb07o5U.js +2409 -0
  451. package/dist/interface/ha/web-0Kyq65na.js +78 -0
  452. package/dist/interface/ha/web-B7Dt2zZN.js +340 -0
  453. package/dist/interface/ha/web-BNdrPSpb.js +102 -0
  454. package/dist/interface/ha/web-BPBZBCtX.js +8 -0
  455. package/dist/interface/ha/web-BjKL51lK-qwJdIpM1.js +221 -0
  456. package/dist/interface/ha/web-C01i9qI1.js +57 -0
  457. package/dist/interface/ha/web-CH3JeXWa.js +211 -0
  458. package/dist/interface/ha/web-Cpm1-DVe.js +33 -0
  459. package/dist/interface/ha/web-DqRMXrnx.js +31 -0
  460. package/dist/interface/ha/web-DtVT7WYt.js +17 -0
  461. package/dist/interface/ha/web-DxJQZCiR.js +59 -0
  462. package/dist/interface/ha/web-I7Urp4AE.js +46 -0
  463. package/dist/interface/ha/web-aSaPk7kr.js +57 -0
  464. package/dist/interface/ha/web-pMey9p3Y.js +79 -0
  465. package/dist/interface/ha/xterm-B6xA6E5i.js +14833 -0
  466. package/dist/interface/ha/zoom-in-CNVB9H3D.js +41 -0
  467. package/dist/interface/index.html +29 -29
  468. package/dist/interface/sw.js +1 -1
  469. package/dist/server/package.json +8 -8
  470. package/dist/server/requirements.txt +3 -3
  471. package/dist/server/src/_camera_ui_tools/camera_ui_rpc/client.py +9 -6
  472. package/dist/server/src/_camera_ui_tools/camera_ui_rpc/types.py +2 -2
  473. package/dist/server/src/_camera_ui_tools/camera_ui_sdk/__init__.py +4 -2
  474. package/dist/server/src/_camera_ui_tools/camera_ui_sdk/camera/config.py +8 -0
  475. package/dist/server/src/_camera_ui_tools/camera_ui_sdk/camera/device.py +4 -3
  476. package/dist/server/src/_camera_ui_tools/camera_ui_sdk/internal/__init__.py +6 -0
  477. package/dist/server/src/_camera_ui_tools/camera_ui_sdk/internal/sensor_rpc.py +17 -6
  478. package/dist/server/src/_camera_ui_tools/camera_ui_sdk/manager/__init__.py +24 -70
  479. package/dist/server/src/_camera_ui_tools/camera_ui_sdk/plugin/interfaces.py +46 -19
  480. package/dist/server/src/_camera_ui_tools/camera_ui_sdk/sensor/__init__.py +2 -0
  481. package/dist/server/src/_camera_ui_tools/camera_ui_sdk/sensor/base.py +65 -8
  482. package/dist/server/src/api/database/index.d.ts +1 -1
  483. package/dist/server/src/api/database/index.js +4 -32
  484. package/dist/server/src/api/database/index.js.map +1 -1
  485. package/dist/server/src/api/database/migrations/v2-1-18.d.ts +3 -0
  486. package/dist/server/src/api/database/migrations/v2-1-18.js +24 -0
  487. package/dist/server/src/api/database/migrations/v2-1-18.js.map +1 -0
  488. package/dist/server/src/api/database/record-schemas.d.ts +1 -0
  489. package/dist/server/src/api/database/types.d.ts +4 -3
  490. package/dist/server/src/api/schemas/cameras.schema.d.ts +53 -15
  491. package/dist/server/src/api/schemas/cameras.schema.js +5 -1
  492. package/dist/server/src/api/schemas/cameras.schema.js.map +1 -1
  493. package/dist/server/src/api/schemas/users.schema.d.ts +7 -0
  494. package/dist/server/src/api/schemas/users.schema.js +1 -1
  495. package/dist/server/src/api/schemas/users.schema.js.map +1 -1
  496. package/dist/server/src/api/services/cameras.service.js +14 -21
  497. package/dist/server/src/api/services/cameras.service.js.map +1 -1
  498. package/dist/server/src/api/services/sensors.service.d.ts +3 -3
  499. package/dist/server/src/api/services/sensors.service.js +3 -24
  500. package/dist/server/src/api/services/sensors.service.js.map +1 -1
  501. package/dist/server/src/api/utils/regex.d.ts +2 -0
  502. package/dist/server/src/api/utils/regex.js +2 -0
  503. package/dist/server/src/api/utils/regex.js.map +1 -1
  504. package/dist/server/src/api/websocket/nsp/sensors.d.ts +3 -1
  505. package/dist/server/src/api/websocket/nsp/sensors.js +13 -3
  506. package/dist/server/src/api/websocket/nsp/sensors.js.map +1 -1
  507. package/dist/server/src/camera/decoder/debug/detection-record.d.ts +3 -1
  508. package/dist/server/src/camera/decoder/debug/detection-record.js +6 -2
  509. package/dist/server/src/camera/decoder/debug/detection-record.js.map +1 -1
  510. package/dist/server/src/camera/decoder/detection-coordinator.d.ts +2 -0
  511. package/dist/server/src/camera/decoder/detection-coordinator.js +44 -25
  512. package/dist/server/src/camera/decoder/detection-coordinator.js.map +1 -1
  513. package/dist/server/src/camera/decoder/detection-pipeline.d.ts +3 -1
  514. package/dist/server/src/camera/decoder/detection-pipeline.js +3 -22
  515. package/dist/server/src/camera/decoder/detection-pipeline.js.map +1 -1
  516. package/dist/server/src/camera/decoder/event-manager.d.ts +4 -3
  517. package/dist/server/src/camera/decoder/event-manager.js +17 -5
  518. package/dist/server/src/camera/decoder/event-manager.js.map +1 -1
  519. package/dist/server/src/camera/decoder/event-thumbnailer.d.ts +3 -0
  520. package/dist/server/src/camera/decoder/event-thumbnailer.js +13 -8
  521. package/dist/server/src/camera/decoder/event-thumbnailer.js.map +1 -1
  522. package/dist/server/src/camera/decoder/event-trace.d.ts +58 -0
  523. package/dist/server/src/camera/decoder/event-trace.js +118 -0
  524. package/dist/server/src/camera/decoder/event-trace.js.map +1 -0
  525. package/dist/server/src/camera/decoder/nvr-sink.d.ts +2 -0
  526. package/dist/server/src/camera/decoder/nvr-sink.js.map +1 -1
  527. package/dist/server/src/camera/decoder/reconnect-backoff.js +1 -1
  528. package/dist/server/src/camera/decoder/reconnect-backoff.js.map +1 -1
  529. package/dist/server/src/camera/decoder/sources/analysis-source.d.ts +1 -0
  530. package/dist/server/src/camera/decoder/sources/buffered-source.d.ts +7 -1
  531. package/dist/server/src/camera/decoder/sources/buffered-source.js +27 -15
  532. package/dist/server/src/camera/decoder/sources/buffered-source.js.map +1 -1
  533. package/dist/server/src/camera/decoder/sources/frame-handle.d.ts +2 -1
  534. package/dist/server/src/camera/decoder/sources/frame-handle.js +5 -3
  535. package/dist/server/src/camera/decoder/sources/frame-handle.js.map +1 -1
  536. package/dist/server/src/camera/decoder/sources/frame-source.d.ts +1 -0
  537. package/dist/server/src/camera/decoder/sources/frame-source.js +7 -2
  538. package/dist/server/src/camera/decoder/sources/frame-source.js.map +1 -1
  539. package/dist/server/src/camera/decoder/sources/rtp-index.d.ts +9 -0
  540. package/dist/server/src/camera/decoder/sources/rtp-index.js +24 -0
  541. package/dist/server/src/camera/decoder/sources/rtp-index.js.map +1 -0
  542. package/dist/server/src/camera/decoder/worker.js +1 -0
  543. package/dist/server/src/camera/decoder/worker.js.map +1 -1
  544. package/dist/server/src/go2rtc/types.d.ts +1 -1
  545. package/dist/server/src/go2rtc/types.js +1 -1
  546. package/dist/server/src/go2rtc/types.js.map +1 -1
  547. package/dist/server/src/plugins/runtime/node/child.js +1 -0
  548. package/dist/server/src/plugins/runtime/node/child.js.map +1 -1
  549. package/dist/server/src/plugins/runtime/node/proxy/cameraDevice.js +3 -0
  550. package/dist/server/src/plugins/runtime/node/proxy/cameraDevice.js.map +1 -1
  551. package/dist/server/src/plugins/runtime/node/proxy/sensorManager.d.ts +2 -5
  552. package/dist/server/src/plugins/runtime/node/proxy/sensorManager.js +95 -24
  553. package/dist/server/src/plugins/runtime/node/proxy/sensorManager.js.map +1 -1
  554. package/dist/server/src/plugins/runtime/python/child.py +1 -0
  555. package/dist/server/src/plugins/runtime/python/proxy/camera_device.py +9 -0
  556. package/dist/server/src/plugins/runtime/python/proxy/sensor.py +2 -1
  557. package/dist/server/src/plugins/runtime/python/proxy/sensor_manager.py +185 -88
  558. package/dist/server/src/plugins/runtime/python/typings.py +18 -0
  559. package/dist/server/src/rpc/interfaces/sensor.d.ts +19 -4
  560. package/dist/server/src/sensors/discovery.d.ts +1 -1
  561. package/dist/server/src/sensors/discovery.js +10 -19
  562. package/dist/server/src/sensors/discovery.js.map +1 -1
  563. package/dist/server/src/sensors/registry.d.ts +6 -2
  564. package/dist/server/src/sensors/registry.js +75 -6
  565. package/dist/server/src/sensors/registry.js.map +1 -1
  566. package/dist/server/src/utils/camera.d.ts +12 -2
  567. package/dist/server/src/utils/camera.js +27 -1
  568. package/dist/server/src/utils/camera.js.map +1 -1
  569. package/dist/server/src/workers/pairing.js +17 -8
  570. package/dist/server/src/workers/pairing.js.map +1 -1
  571. package/package.json +8 -8
  572. package/dist/interface/assets/Automation-4HPAjq1i.js +0 -3
  573. package/dist/interface/assets/AutomationStoreDetail-C2ntfGP-.js +0 -2
  574. package/dist/interface/assets/Automations-CUUq9dxs.js +0 -2
  575. package/dist/interface/assets/Camera-DmrRrgqQ.js +0 -2
  576. package/dist/interface/assets/Cameras-B-aQUuPk.js +0 -652
  577. package/dist/interface/assets/Camview-B-W5jpCR.js +0 -1
  578. package/dist/interface/assets/ConfigActionNotification-Bq28CjsJ.js +0 -1
  579. package/dist/interface/assets/ConfigConditionSwitch-DYAlj5no.js +0 -1
  580. package/dist/interface/assets/ConfigTriggerGeofence-ClKyzb-x.js +0 -1
  581. package/dist/interface/assets/Console-ctbGFtCH.js +0 -1
  582. package/dist/interface/assets/CuiBottomSheet-Bo1wUyiN.js +0 -1
  583. package/dist/interface/assets/CuiCameraPipCard-BEAE44of.js +0 -1
  584. package/dist/interface/assets/CuiCameraRecordings-BzbwSK8-.css +0 -1
  585. package/dist/interface/assets/CuiCameraRecordings-C1evIMhc.js +0 -1
  586. package/dist/interface/assets/CuiCameraTable-BAjQ8h5H.js +0 -1
  587. package/dist/interface/assets/CuiLightControl-9OhT9YYt.js +0 -1
  588. package/dist/interface/assets/CuiPluginCard-DQgVasi7.js +0 -2
  589. package/dist/interface/assets/CuiSchema-juKEra_J.js +0 -1
  590. package/dist/interface/assets/Faces-Ce3mKYc7.js +0 -1
  591. package/dist/interface/assets/FirstSteps-BBLzX2bl.js +0 -1
  592. package/dist/interface/assets/Floorplan-B7BVj65t.js +0 -1
  593. package/dist/interface/assets/Instances-4VxGT2fm.js +0 -1
  594. package/dist/interface/assets/Metrics-DudHV8Ov.js +0 -9
  595. package/dist/interface/assets/OAuthDeviceFlow-Z3Cesvs9.js +0 -1
  596. package/dist/interface/assets/Plugin-DwadariU.js +0 -1
  597. package/dist/interface/assets/PluginDetail-C_XghvQz.js +0 -2
  598. package/dist/interface/assets/PluginSearch-11dsxfvW.js +0 -1
  599. package/dist/interface/assets/PluginSearch-DgQOryM2.js +0 -2
  600. package/dist/interface/assets/Plugins-QheVcYZB.js +0 -1
  601. package/dist/interface/assets/Recordings-DwPnYsd6.js +0 -1
  602. package/dist/interface/assets/SensorEdit-C9Ejdxaz.js +0 -1
  603. package/dist/interface/assets/Sensors-D4tY50d4.js +0 -2
  604. package/dist/interface/assets/SettingsAccount-DMvvar8D.js +0 -1
  605. package/dist/interface/assets/SettingsAccount-DYCCnjWY.js +0 -1
  606. package/dist/interface/assets/SettingsAppearance-vLBhLEag.js +0 -1
  607. package/dist/interface/assets/SettingsMqtt-Cj9ywnP2.js +0 -1
  608. package/dist/interface/assets/SettingsNotifications-flx3W4Uo.js +0 -1
  609. package/dist/interface/assets/SettingsRecordings-D3b6y2SX.js +0 -1
  610. package/dist/interface/assets/SettingsRemote-o01wgKPR.js +0 -2
  611. package/dist/interface/assets/Workers-CdaYj6Ap.js +0 -2
  612. package/dist/interface/assets/alert-outline-KxFvd3i6.js +0 -1
  613. package/dist/interface/assets/api-2VPaKkqc.js +0 -2
  614. package/dist/interface/assets/api-CEbDxsSY.css +0 -2
  615. package/dist/interface/assets/cameras.schema-CnSdfqqj.js +0 -1
  616. package/dist/interface/assets/cloudHandoff-B1z5dyPD.js +0 -1
  617. package/dist/interface/assets/main-BfL5CDS8.js +0 -3
  618. package/dist/interface/assets/nodeDefinitions-D6zhuw60.js +0 -1
  619. package/dist/interface/assets/sensorIcons-FPxm3pDg.js +0 -1
  620. package/dist/interface/assets/theme-CRQoJiuY.js +0 -1
  621. package/dist/interface/assets/types-BHgaZSm2.js +0 -1
  622. package/dist/interface/assets/types-CQpPteyx.js +0 -1
  623. package/dist/interface/assets/ungrouped-BbOtmmDD.js +0 -1
  624. package/dist/interface/assets/useBackupRestore-CT1PYJDW.js +0 -1
  625. package/dist/interface/assets/vendor-cameraui-ZyqPntQ7.js +0 -2326
  626. package/dist/interface/assets/vendor-core-DN-bpg68.js +0 -1
  627. package/dist/interface/assets/vendor-zod-B0ZFM2Pr.js +0 -127
@@ -0,0 +1,4896 @@
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-D8slQ3BU.js";
3
+ import { t as ee } from "./message-C8U_kMBA.js";
4
+ import { Dt as te, Et as ne, Ot as re, er as ie, gi as ae, r as oe } from "./api-CWJkvtnM.js";
5
+ import { n as v } from "./vue-i18n-Dcb07o5U.js";
6
+ import { t as y } from "./button-BlYuI0Q7.js";
7
+ import { t as se } from "./inputtext-DGIESrd0.js";
8
+ import { t as b } from "./select-DjWkRqsI.js";
9
+ import { t as ce } from "./inputnumber-B1Buq8Nc.js";
10
+ import { t as x } from "./multiselect-BbgV_fPx.js";
11
+ import { t as le } from "./information-outline-DIdNxPCN.js";
12
+ import { t as S } from "./copy-C48Ur26H.js";
13
+ import { t as ue } from "./useUserOptions-Rk_71WAK.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
+ var t, n, r, i;
36
+ for (n = 1, r = arguments.length; n < r; n++) for (t in i = arguments[n], i) e[t] = i[t];
37
+ return e;
38
+ }
39
+ var r = Object.create || (function() {
40
+ function e() {}
41
+ return function(t) {
42
+ return e.prototype = t, new e();
43
+ };
44
+ })();
45
+ function i(e, t) {
46
+ var n = Array.prototype.slice;
47
+ if (e.bind) return e.bind.apply(e, n.call(arguments, 1));
48
+ var r = n.call(arguments, 2);
49
+ return function() {
50
+ return e.apply(t, r.length ? r.concat(n.call(arguments)) : arguments);
51
+ };
52
+ }
53
+ var a = 0;
54
+ function o(e) {
55
+ return "_leaflet_id" in e || (e._leaflet_id = ++a), e._leaflet_id;
56
+ }
57
+ function s(e, t, n) {
58
+ var r, i, a, o = function() {
59
+ r = !1, i &&= (a.apply(n, i), !1);
60
+ };
61
+ return a = function() {
62
+ r ? i = arguments : (e.apply(n, arguments), setTimeout(o, t), r = !0);
63
+ }, a;
64
+ }
65
+ function c(e, t, n) {
66
+ var r = t[1], i = t[0], a = r - i;
67
+ return e === r && n ? e : ((e - i) % a + a) % a + i;
68
+ }
69
+ function l() {
70
+ return !1;
71
+ }
72
+ function u(e, t) {
73
+ if (t === !1) return e;
74
+ var n = 10 ** (t === void 0 ? 6 : t);
75
+ return Math.round(e * n) / n;
76
+ }
77
+ function d(e) {
78
+ return e.trim ? e.trim() : e.replace(/^\s+|\s+$/g, "");
79
+ }
80
+ function f(e) {
81
+ return d(e).split(/\s+/);
82
+ }
83
+ function p(e, t) {
84
+ for (var n in Object.prototype.hasOwnProperty.call(e, "options") || (e.options = e.options ? r(e.options) : {}), t) e.options[n] = t[n];
85
+ return e.options;
86
+ }
87
+ function m(e, t, n) {
88
+ var r = [];
89
+ for (var i in e) r.push(encodeURIComponent(n ? i.toUpperCase() : i) + "=" + encodeURIComponent(e[i]));
90
+ return (!t || t.indexOf("?") === -1 ? "?" : "&") + r.join("&");
91
+ }
92
+ var h = /\{ *([\w_ -]+) *\}/g;
93
+ function g(e, t) {
94
+ return e.replace(h, function(e, n) {
95
+ var r = t[n];
96
+ if (r === void 0) throw Error("No value provided for variable " + e);
97
+ return typeof r == "function" && (r = r(t)), r;
98
+ });
99
+ }
100
+ var _ = Array.isArray || function(e) {
101
+ return Object.prototype.toString.call(e) === "[object Array]";
102
+ };
103
+ function ee(e, t) {
104
+ for (var n = 0; n < e.length; n++) if (e[n] === t) return n;
105
+ return -1;
106
+ }
107
+ var te = "data:image/gif;base64,R0lGODlhAQABAAD/ACwAAAAAAQABAAACADs=";
108
+ function ne(e) {
109
+ return window["webkit" + e] || window["moz" + e] || window["ms" + e];
110
+ }
111
+ var re = 0;
112
+ function ie(e) {
113
+ var t = +/* @__PURE__ */ new Date(), n = Math.max(0, 16 - (t - re));
114
+ return re = t + n, window.setTimeout(e, n);
115
+ }
116
+ var ae = window.requestAnimationFrame || ne("RequestAnimationFrame") || ie, oe = window.cancelAnimationFrame || ne("CancelAnimationFrame") || ne("CancelRequestAnimationFrame") || function(e) {
117
+ window.clearTimeout(e);
118
+ };
119
+ function v(e, t, n) {
120
+ if (n && ae === ie) e.call(t);
121
+ else return ae.call(window, i(e, t));
122
+ }
123
+ function y(e) {
124
+ e && oe.call(window, e);
125
+ }
126
+ var se = {
127
+ __proto__: null,
128
+ extend: n,
129
+ create: r,
130
+ bind: i,
131
+ get lastId() {
132
+ return a;
133
+ },
134
+ stamp: o,
135
+ throttle: s,
136
+ wrapNum: c,
137
+ falseFn: l,
138
+ formatNum: u,
139
+ trim: d,
140
+ splitWords: f,
141
+ setOptions: p,
142
+ getParamString: m,
143
+ template: g,
144
+ isArray: _,
145
+ indexOf: ee,
146
+ emptyImageUrl: te,
147
+ requestFn: ae,
148
+ cancelFn: oe,
149
+ requestAnimFrame: v,
150
+ cancelAnimFrame: y
151
+ };
152
+ function b() {}
153
+ b.extend = function(e) {
154
+ var t = function() {
155
+ p(this), this.initialize && this.initialize.apply(this, arguments), this.callInitHooks();
156
+ }, i = t.__super__ = this.prototype, a = r(i);
157
+ 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]);
158
+ 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() {
159
+ if (!this._initHooksCalled) {
160
+ i.callInitHooks && i.callInitHooks.call(this), this._initHooksCalled = !0;
161
+ for (var e = 0, t = a._initHooks.length; e < t; e++) a._initHooks[e].call(this);
162
+ }
163
+ }, t;
164
+ }, b.include = function(e) {
165
+ var t = this.prototype.options;
166
+ return n(this.prototype, e), e.options && (this.prototype.options = t, this.mergeOptions(e.options)), this;
167
+ }, b.mergeOptions = function(e) {
168
+ return n(this.prototype.options, e), this;
169
+ }, b.addInitHook = function(e) {
170
+ var t = Array.prototype.slice.call(arguments, 1), n = typeof e == "function" ? e : function() {
171
+ this[e].apply(this, t);
172
+ };
173
+ return this.prototype._initHooks = this.prototype._initHooks || [], this.prototype._initHooks.push(n), this;
174
+ };
175
+ function ce(e) {
176
+ if (!(typeof L > "u" || !L || !L.Mixin)) {
177
+ e = _(e) ? e : [e];
178
+ 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);
179
+ }
180
+ }
181
+ var x = {
182
+ on: function(e, t, n) {
183
+ if (typeof e == "object") for (var r in e) this._on(r, e[r], t);
184
+ else {
185
+ e = f(e);
186
+ for (var i = 0, a = e.length; i < a; i++) this._on(e[i], t, n);
187
+ }
188
+ return this;
189
+ },
190
+ off: function(e, t, n) {
191
+ if (!arguments.length) delete this._events;
192
+ else if (typeof e == "object") for (var r in e) this._off(r, e[r], t);
193
+ else {
194
+ e = f(e);
195
+ 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);
196
+ }
197
+ return this;
198
+ },
199
+ _on: function(e, t, n, r) {
200
+ if (typeof t != "function") {
201
+ console.warn("wrong listener type: " + typeof t);
202
+ return;
203
+ }
204
+ if (this._listens(e, t, n) === !1) {
205
+ n === this && (n = void 0);
206
+ var i = {
207
+ fn: t,
208
+ ctx: n
209
+ };
210
+ r && (i.once = !0), this._events = this._events || {}, this._events[e] = this._events[e] || [], this._events[e].push(i);
211
+ }
212
+ },
213
+ _off: function(e, t, n) {
214
+ var r, i, a;
215
+ if (this._events && (r = this._events[e], r)) {
216
+ if (arguments.length === 1) {
217
+ if (this._firingCount) for (i = 0, a = r.length; i < a; i++) r[i].fn = l;
218
+ delete this._events[e];
219
+ return;
220
+ }
221
+ if (typeof t != "function") {
222
+ console.warn("wrong listener type: " + typeof t);
223
+ return;
224
+ }
225
+ var o = this._listens(e, t, n);
226
+ if (o !== !1) {
227
+ var s = r[o];
228
+ this._firingCount && (s.fn = l, this._events[e] = r = r.slice()), r.splice(o, 1);
229
+ }
230
+ }
231
+ },
232
+ fire: function(e, t, r) {
233
+ if (!this.listens(e, r)) return this;
234
+ var i = n({}, t, {
235
+ type: e,
236
+ target: this,
237
+ sourceTarget: t && t.sourceTarget || this
238
+ });
239
+ if (this._events) {
240
+ var a = this._events[e];
241
+ if (a) {
242
+ this._firingCount = this._firingCount + 1 || 1;
243
+ for (var o = 0, s = a.length; o < s; o++) {
244
+ var c = a[o], l = c.fn;
245
+ c.once && this.off(e, l, c.ctx), l.call(c.ctx || this, i);
246
+ }
247
+ this._firingCount--;
248
+ }
249
+ }
250
+ return r && this._propagateEvent(i), this;
251
+ },
252
+ listens: function(e, t, n, r) {
253
+ typeof e != "string" && console.warn("\"string\" type argument expected");
254
+ var i = t;
255
+ typeof t != "function" && (r = !!t, i = void 0, n = void 0);
256
+ var a = this._events && this._events[e];
257
+ if (a && a.length && this._listens(e, i, n) !== !1) return !0;
258
+ if (r) {
259
+ for (var o in this._eventParents) if (this._eventParents[o].listens(e, t, n, r)) return !0;
260
+ }
261
+ return !1;
262
+ },
263
+ _listens: function(e, t, n) {
264
+ if (!this._events) return !1;
265
+ var r = this._events[e] || [];
266
+ if (!t) return !!r.length;
267
+ n === this && (n = void 0);
268
+ for (var i = 0, a = r.length; i < a; i++) if (r[i].fn === t && r[i].ctx === n) return i;
269
+ return !1;
270
+ },
271
+ once: function(e, t, n) {
272
+ if (typeof e == "object") for (var r in e) this._on(r, e[r], t, !0);
273
+ else {
274
+ e = f(e);
275
+ for (var i = 0, a = e.length; i < a; i++) this._on(e[i], t, n, !0);
276
+ }
277
+ return this;
278
+ },
279
+ addEventParent: function(e) {
280
+ return this._eventParents = this._eventParents || {}, this._eventParents[o(e)] = e, this;
281
+ },
282
+ removeEventParent: function(e) {
283
+ return this._eventParents && delete this._eventParents[o(e)], this;
284
+ },
285
+ _propagateEvent: function(e) {
286
+ for (var t in this._eventParents) this._eventParents[t].fire(e.type, n({
287
+ layer: e.target,
288
+ propagatedFrom: e.target
289
+ }, e), !0);
290
+ }
291
+ };
292
+ x.addEventListener = x.on, x.removeEventListener = x.clearAllEventListeners = x.off, x.addOneTimeEventListener = x.once, x.fireEvent = x.fire, x.hasEventListeners = x.listens;
293
+ var le = b.extend(x);
294
+ function S(e, t, n) {
295
+ this.x = n ? Math.round(e) : e, this.y = n ? Math.round(t) : t;
296
+ }
297
+ var ue = Math.trunc || function(e) {
298
+ return e > 0 ? Math.floor(e) : Math.ceil(e);
299
+ };
300
+ S.prototype = {
301
+ clone: function() {
302
+ return new S(this.x, this.y);
303
+ },
304
+ add: function(e) {
305
+ return this.clone()._add(C(e));
306
+ },
307
+ _add: function(e) {
308
+ return this.x += e.x, this.y += e.y, this;
309
+ },
310
+ subtract: function(e) {
311
+ return this.clone()._subtract(C(e));
312
+ },
313
+ _subtract: function(e) {
314
+ return this.x -= e.x, this.y -= e.y, this;
315
+ },
316
+ divideBy: function(e) {
317
+ return this.clone()._divideBy(e);
318
+ },
319
+ _divideBy: function(e) {
320
+ return this.x /= e, this.y /= e, this;
321
+ },
322
+ multiplyBy: function(e) {
323
+ return this.clone()._multiplyBy(e);
324
+ },
325
+ _multiplyBy: function(e) {
326
+ return this.x *= e, this.y *= e, this;
327
+ },
328
+ scaleBy: function(e) {
329
+ return new S(this.x * e.x, this.y * e.y);
330
+ },
331
+ unscaleBy: function(e) {
332
+ return new S(this.x / e.x, this.y / e.y);
333
+ },
334
+ round: function() {
335
+ return this.clone()._round();
336
+ },
337
+ _round: function() {
338
+ return this.x = Math.round(this.x), this.y = Math.round(this.y), this;
339
+ },
340
+ floor: function() {
341
+ return this.clone()._floor();
342
+ },
343
+ _floor: function() {
344
+ return this.x = Math.floor(this.x), this.y = Math.floor(this.y), this;
345
+ },
346
+ ceil: function() {
347
+ return this.clone()._ceil();
348
+ },
349
+ _ceil: function() {
350
+ return this.x = Math.ceil(this.x), this.y = Math.ceil(this.y), this;
351
+ },
352
+ trunc: function() {
353
+ return this.clone()._trunc();
354
+ },
355
+ _trunc: function() {
356
+ return this.x = ue(this.x), this.y = ue(this.y), this;
357
+ },
358
+ distanceTo: function(e) {
359
+ e = C(e);
360
+ var t = e.x - this.x, n = e.y - this.y;
361
+ return Math.sqrt(t * t + n * n);
362
+ },
363
+ equals: function(e) {
364
+ return e = C(e), e.x === this.x && e.y === this.y;
365
+ },
366
+ contains: function(e) {
367
+ return e = C(e), Math.abs(e.x) <= Math.abs(this.x) && Math.abs(e.y) <= Math.abs(this.y);
368
+ },
369
+ toString: function() {
370
+ return "Point(" + u(this.x) + ", " + u(this.y) + ")";
371
+ }
372
+ };
373
+ function C(e, t, n) {
374
+ 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);
375
+ }
376
+ function w(e, t) {
377
+ if (e) for (var n = t ? [e, t] : e, r = 0, i = n.length; r < i; r++) this.extend(n[r]);
378
+ }
379
+ w.prototype = {
380
+ extend: function(e) {
381
+ var t, n;
382
+ if (!e) return this;
383
+ if (e instanceof S || typeof e[0] == "number" || "x" in e) t = n = C(e);
384
+ else if (e = T(e), t = e.min, n = e.max, !t || !n) return this;
385
+ 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;
386
+ },
387
+ getCenter: function(e) {
388
+ return C((this.min.x + this.max.x) / 2, (this.min.y + this.max.y) / 2, e);
389
+ },
390
+ getBottomLeft: function() {
391
+ return C(this.min.x, this.max.y);
392
+ },
393
+ getTopRight: function() {
394
+ return C(this.max.x, this.min.y);
395
+ },
396
+ getTopLeft: function() {
397
+ return this.min;
398
+ },
399
+ getBottomRight: function() {
400
+ return this.max;
401
+ },
402
+ getSize: function() {
403
+ return this.max.subtract(this.min);
404
+ },
405
+ contains: function(e) {
406
+ var t, n;
407
+ 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;
408
+ },
409
+ intersects: function(e) {
410
+ e = T(e);
411
+ 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;
412
+ return a && o;
413
+ },
414
+ overlaps: function(e) {
415
+ e = T(e);
416
+ 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;
417
+ return a && o;
418
+ },
419
+ isValid: function() {
420
+ return !!(this.min && this.max);
421
+ },
422
+ pad: function(e) {
423
+ var t = this.min, n = this.max, r = Math.abs(t.x - n.x) * e, i = Math.abs(t.y - n.y) * e;
424
+ return T(C(t.x - r, t.y - i), C(n.x + r, n.y + i));
425
+ },
426
+ equals: function(e) {
427
+ return e ? (e = T(e), this.min.equals(e.getTopLeft()) && this.max.equals(e.getBottomRight())) : !1;
428
+ }
429
+ };
430
+ function T(e, t) {
431
+ return !e || e instanceof w ? e : new w(e, t);
432
+ }
433
+ function E(e, t) {
434
+ if (e) for (var n = t ? [e, t] : e, r = 0, i = n.length; r < i; r++) this.extend(n[r]);
435
+ }
436
+ E.prototype = {
437
+ extend: function(e) {
438
+ var t = this._southWest, n = this._northEast, r, i;
439
+ if (e instanceof O) r = e, i = e;
440
+ else if (e instanceof E) {
441
+ if (r = e._southWest, i = e._northEast, !r || !i) return this;
442
+ } else return e ? this.extend(k(e) || D(e)) : this;
443
+ 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;
444
+ },
445
+ pad: function(e) {
446
+ var t = this._southWest, n = this._northEast, r = Math.abs(t.lat - n.lat) * e, i = Math.abs(t.lng - n.lng) * e;
447
+ return new E(new O(t.lat - r, t.lng - i), new O(n.lat + r, n.lng + i));
448
+ },
449
+ getCenter: function() {
450
+ return new O((this._southWest.lat + this._northEast.lat) / 2, (this._southWest.lng + this._northEast.lng) / 2);
451
+ },
452
+ getSouthWest: function() {
453
+ return this._southWest;
454
+ },
455
+ getNorthEast: function() {
456
+ return this._northEast;
457
+ },
458
+ getNorthWest: function() {
459
+ return new O(this.getNorth(), this.getWest());
460
+ },
461
+ getSouthEast: function() {
462
+ return new O(this.getSouth(), this.getEast());
463
+ },
464
+ getWest: function() {
465
+ return this._southWest.lng;
466
+ },
467
+ getSouth: function() {
468
+ return this._southWest.lat;
469
+ },
470
+ getEast: function() {
471
+ return this._northEast.lng;
472
+ },
473
+ getNorth: function() {
474
+ return this._northEast.lat;
475
+ },
476
+ contains: function(e) {
477
+ e = typeof e[0] == "number" || e instanceof O || "lat" in e ? k(e) : D(e);
478
+ var t = this._southWest, n = this._northEast, r, i;
479
+ 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;
480
+ },
481
+ intersects: function(e) {
482
+ e = D(e);
483
+ 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;
484
+ return a && o;
485
+ },
486
+ overlaps: function(e) {
487
+ e = D(e);
488
+ 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;
489
+ return a && o;
490
+ },
491
+ toBBoxString: function() {
492
+ return [
493
+ this.getWest(),
494
+ this.getSouth(),
495
+ this.getEast(),
496
+ this.getNorth()
497
+ ].join(",");
498
+ },
499
+ equals: function(e, t) {
500
+ return e ? (e = D(e), this._southWest.equals(e.getSouthWest(), t) && this._northEast.equals(e.getNorthEast(), t)) : !1;
501
+ },
502
+ isValid: function() {
503
+ return !!(this._southWest && this._northEast);
504
+ }
505
+ };
506
+ function D(e, t) {
507
+ return e instanceof E ? e : new E(e, t);
508
+ }
509
+ function O(e, t, n) {
510
+ if (isNaN(e) || isNaN(t)) throw Error("Invalid LatLng object: (" + e + ", " + t + ")");
511
+ this.lat = +e, this.lng = +t, n !== void 0 && (this.alt = +n);
512
+ }
513
+ O.prototype = {
514
+ equals: function(e, t) {
515
+ 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;
516
+ },
517
+ toString: function(e) {
518
+ return "LatLng(" + u(this.lat, e) + ", " + u(this.lng, e) + ")";
519
+ },
520
+ distanceTo: function(e) {
521
+ return j.distance(this, k(e));
522
+ },
523
+ wrap: function() {
524
+ return j.wrapLatLng(this);
525
+ },
526
+ toBounds: function(e) {
527
+ var t = 180 * e / 40075017, n = t / Math.cos(Math.PI / 180 * this.lat);
528
+ return D([this.lat - t, this.lng - n], [this.lat + t, this.lng + n]);
529
+ },
530
+ clone: function() {
531
+ return new O(this.lat, this.lng, this.alt);
532
+ }
533
+ };
534
+ function k(e, t, n) {
535
+ 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);
536
+ }
537
+ var A = {
538
+ latLngToPoint: function(e, t) {
539
+ var n = this.projection.project(e), r = this.scale(t);
540
+ return this.transformation._transform(n, r);
541
+ },
542
+ pointToLatLng: function(e, t) {
543
+ var n = this.scale(t), r = this.transformation.untransform(e, n);
544
+ return this.projection.unproject(r);
545
+ },
546
+ project: function(e) {
547
+ return this.projection.project(e);
548
+ },
549
+ unproject: function(e) {
550
+ return this.projection.unproject(e);
551
+ },
552
+ scale: function(e) {
553
+ return 256 * 2 ** e;
554
+ },
555
+ zoom: function(e) {
556
+ return Math.log(e / 256) / Math.LN2;
557
+ },
558
+ getProjectedBounds: function(e) {
559
+ if (this.infinite) return null;
560
+ var t = this.projection.bounds, n = this.scale(e);
561
+ return new w(this.transformation.transform(t.min, n), this.transformation.transform(t.max, n));
562
+ },
563
+ infinite: !1,
564
+ wrapLatLng: function(e) {
565
+ 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;
566
+ return new O(n, t, r);
567
+ },
568
+ wrapLatLngBounds: function(e) {
569
+ var t = e.getCenter(), n = this.wrapLatLng(t), r = t.lat - n.lat, i = t.lng - n.lng;
570
+ if (r === 0 && i === 0) return e;
571
+ var a = e.getSouthWest(), o = e.getNorthEast();
572
+ return new E(new O(a.lat - r, a.lng - i), new O(o.lat - r, o.lng - i));
573
+ }
574
+ }, j = n({}, A, {
575
+ wrapLng: [-180, 180],
576
+ R: 6371e3,
577
+ distance: function(e, t) {
578
+ 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));
579
+ return this.R * c;
580
+ }
581
+ }), de = 6378137, fe = {
582
+ R: de,
583
+ MAX_LATITUDE: 85.0511287798,
584
+ project: function(e) {
585
+ var t = Math.PI / 180, n = this.MAX_LATITUDE, r = Math.max(Math.min(n, e.lat), -n), i = Math.sin(r * t);
586
+ return new S(this.R * e.lng * t, this.R * Math.log((1 + i) / (1 - i)) / 2);
587
+ },
588
+ unproject: function(e) {
589
+ var t = 180 / Math.PI;
590
+ return new O((2 * Math.atan(Math.exp(e.y / this.R)) - Math.PI / 2) * t, e.x * t / this.R);
591
+ },
592
+ bounds: (function() {
593
+ var e = de * Math.PI;
594
+ return new w([-e, -e], [e, e]);
595
+ })()
596
+ };
597
+ function pe(e, t, n, r) {
598
+ if (_(e)) {
599
+ this._a = e[0], this._b = e[1], this._c = e[2], this._d = e[3];
600
+ return;
601
+ }
602
+ this._a = e, this._b = t, this._c = n, this._d = r;
603
+ }
604
+ pe.prototype = {
605
+ transform: function(e, t) {
606
+ return this._transform(e.clone(), t);
607
+ },
608
+ _transform: function(e, t) {
609
+ return t ||= 1, e.x = t * (this._a * e.x + this._b), e.y = t * (this._c * e.y + this._d), e;
610
+ },
611
+ untransform: function(e, t) {
612
+ return t ||= 1, new S((e.x / t - this._b) / this._a, (e.y / t - this._d) / this._c);
613
+ }
614
+ };
615
+ function me(e, t, n, r) {
616
+ return new pe(e, t, n, r);
617
+ }
618
+ var he = n({}, j, {
619
+ code: "EPSG:3857",
620
+ projection: fe,
621
+ transformation: function() {
622
+ var e = .5 / (Math.PI * fe.R);
623
+ return me(e, .5, -e, .5);
624
+ }()
625
+ }), ge = n({}, he, { code: "EPSG:900913" });
626
+ function _e(e) {
627
+ return document.createElementNS("http://www.w3.org/2000/svg", e);
628
+ }
629
+ function ve(e, t) {
630
+ var n = "", r, i, a, o, s, c;
631
+ for (r = 0, a = e.length; r < a; r++) {
632
+ for (s = e[r], i = 0, o = s.length; i < o; i++) c = s[i], n += (i ? "L" : "M") + c.x + " " + c.y;
633
+ n += t ? P.svg ? "z" : "x" : "";
634
+ }
635
+ return n || "M0 0";
636
+ }
637
+ 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() {
638
+ var e = !1;
639
+ try {
640
+ var t = Object.defineProperty({}, "passive", { get: function() {
641
+ e = !0;
642
+ } });
643
+ window.addEventListener("testPassiveEventSupport", l, t), window.removeEventListener("testPassiveEventSupport", l, t);
644
+ } catch {}
645
+ return e;
646
+ }(), Ye = function() {
647
+ return !!document.createElement("canvas").getContext;
648
+ }(), Xe = !!(document.createElementNS && _e("svg").createSVGRect), Ze = !!Xe && (function() {
649
+ var e = document.createElement("div");
650
+ return e.innerHTML = "<svg/>", (e.firstChild && e.firstChild.namespaceURI) === "http://www.w3.org/2000/svg";
651
+ })(), Qe = !Xe && function() {
652
+ try {
653
+ var e = document.createElement("div");
654
+ e.innerHTML = "<v:shape adj=\"1\"/>";
655
+ var t = e.firstChild;
656
+ return t.style.behavior = "url(#default#VML)", t && typeof t.adj == "object";
657
+ } catch {
658
+ return !1;
659
+ }
660
+ }(), $e = navigator.platform.indexOf("Mac") === 0, et = navigator.platform.indexOf("Linux") === 0;
661
+ function N(e) {
662
+ return navigator.userAgent.toLowerCase().indexOf(e) >= 0;
663
+ }
664
+ var P = {
665
+ ie: be,
666
+ ielt9: xe,
667
+ edge: Se,
668
+ webkit: Ce,
669
+ android: we,
670
+ android23: Te,
671
+ androidStock: De,
672
+ opera: Oe,
673
+ chrome: ke,
674
+ gecko: Ae,
675
+ safari: je,
676
+ phantom: Me,
677
+ opera12: Ne,
678
+ win: Pe,
679
+ ie3d: M,
680
+ webkit3d: Fe,
681
+ gecko3d: Ie,
682
+ any3d: Le,
683
+ mobile: Re,
684
+ mobileWebkit: ze,
685
+ mobileWebkit3d: Be,
686
+ msPointer: Ve,
687
+ pointer: He,
688
+ touch: We,
689
+ touchNative: Ue,
690
+ mobileOpera: Ge,
691
+ mobileGecko: Ke,
692
+ retina: qe,
693
+ passiveEvents: Je,
694
+ canvas: Ye,
695
+ svg: Xe,
696
+ vml: Qe,
697
+ inlineSvg: Ze,
698
+ mac: $e,
699
+ linux: et
700
+ }, tt = P.msPointer ? "MSPointerDown" : "pointerdown", nt = P.msPointer ? "MSPointerMove" : "pointermove", rt = P.msPointer ? "MSPointerUp" : "pointerup", it = P.msPointer ? "MSPointerCancel" : "pointercancel", at = {
701
+ touchstart: tt,
702
+ touchmove: nt,
703
+ touchend: rt,
704
+ touchcancel: it
705
+ }, ot = {
706
+ touchstart: gt,
707
+ touchmove: ht,
708
+ touchend: ht,
709
+ touchcancel: ht
710
+ }, st = {}, ct = !1;
711
+ function lt(e, t, n) {
712
+ 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);
713
+ }
714
+ function ut(e, t, n) {
715
+ if (!at[t]) {
716
+ console.warn("wrong event specified:", t);
717
+ return;
718
+ }
719
+ e.removeEventListener(at[t], n, !1);
720
+ }
721
+ function dt(e) {
722
+ st[e.pointerId] = e;
723
+ }
724
+ function ft(e) {
725
+ st[e.pointerId] && (st[e.pointerId] = e);
726
+ }
727
+ function pt(e) {
728
+ delete st[e.pointerId];
729
+ }
730
+ function mt() {
731
+ ct ||= (document.addEventListener(tt, dt, !0), document.addEventListener(nt, ft, !0), document.addEventListener(rt, pt, !0), document.addEventListener(it, pt, !0), !0);
732
+ }
733
+ function ht(e, t) {
734
+ if (t.pointerType !== (t.MSPOINTER_TYPE_MOUSE || "mouse")) {
735
+ for (var n in t.touches = [], st) t.touches.push(st[n]);
736
+ t.changedTouches = [t], e(t);
737
+ }
738
+ }
739
+ function gt(e, t) {
740
+ t.MSPOINTER_TYPE_TOUCH && t.pointerType === t.MSPOINTER_TYPE_TOUCH && G(t), ht(e, t);
741
+ }
742
+ function _t(e) {
743
+ var t = {}, n, r;
744
+ for (r in e) n = e[r], t[r] = n && n.bind ? n.bind(e) : n;
745
+ return e = t, t.type = "dblclick", t.detail = 2, t.isTrusted = !1, t._simulated = !0, t;
746
+ }
747
+ var vt = 200;
748
+ function yt(e, t) {
749
+ e.addEventListener("dblclick", t);
750
+ var n = 0, r;
751
+ function i(e) {
752
+ if (e.detail !== 1) {
753
+ r = e.detail;
754
+ return;
755
+ }
756
+ if (!(e.pointerType === "mouse" || e.sourceCapabilities && !e.sourceCapabilities.firesTouchEvents)) {
757
+ var i = rn(e);
758
+ if (!(i.some(function(e) {
759
+ return e instanceof HTMLLabelElement && e.attributes.for;
760
+ }) && !i.some(function(e) {
761
+ return e instanceof HTMLInputElement || e instanceof HTMLSelectElement;
762
+ }))) {
763
+ var a = Date.now();
764
+ a - n <= vt ? (r++, r === 2 && t(_t(e))) : r = 1, n = a;
765
+ }
766
+ }
767
+ }
768
+ return e.addEventListener("click", i), {
769
+ dblclick: t,
770
+ simDblclick: i
771
+ };
772
+ }
773
+ function bt(e, t) {
774
+ e.removeEventListener("dblclick", t.dblclick), e.removeEventListener("click", t.simDblclick);
775
+ }
776
+ var xt = Nt([
777
+ "transform",
778
+ "webkitTransform",
779
+ "OTransform",
780
+ "MozTransform",
781
+ "msTransform"
782
+ ]), St = Nt([
783
+ "webkitTransition",
784
+ "transition",
785
+ "OTransition",
786
+ "MozTransition",
787
+ "msTransition"
788
+ ]), Ct = St === "webkitTransition" || St === "OTransition" ? St + "End" : "transitionend";
789
+ function wt(e) {
790
+ return typeof e == "string" ? document.getElementById(e) : e;
791
+ }
792
+ function Tt(e, t) {
793
+ var n = e.style[t] || e.currentStyle && e.currentStyle[t];
794
+ if ((!n || n === "auto") && document.defaultView) {
795
+ var r = document.defaultView.getComputedStyle(e, null);
796
+ n = r ? r[t] : null;
797
+ }
798
+ return n === "auto" ? null : n;
799
+ }
800
+ function F(e, t, n) {
801
+ var r = document.createElement(e);
802
+ return r.className = t || "", n && n.appendChild(r), r;
803
+ }
804
+ function I(e) {
805
+ var t = e.parentNode;
806
+ t && t.removeChild(e);
807
+ }
808
+ function Et(e) {
809
+ for (; e.firstChild;) e.removeChild(e.firstChild);
810
+ }
811
+ function Dt(e) {
812
+ var t = e.parentNode;
813
+ t && t.lastChild !== e && t.appendChild(e);
814
+ }
815
+ function Ot(e) {
816
+ var t = e.parentNode;
817
+ t && t.firstChild !== e && t.insertBefore(e, t.firstChild);
818
+ }
819
+ function kt(e, t) {
820
+ if (e.classList !== void 0) return e.classList.contains(t);
821
+ var n = jt(e);
822
+ return n.length > 0 && RegExp("(^|\\s)" + t + "(\\s|$)").test(n);
823
+ }
824
+ function R(e, t) {
825
+ if (e.classList !== void 0) for (var n = f(t), r = 0, i = n.length; r < i; r++) e.classList.add(n[r]);
826
+ else if (!kt(e, t)) {
827
+ var a = jt(e);
828
+ At(e, (a ? a + " " : "") + t);
829
+ }
830
+ }
831
+ function z(e, t) {
832
+ e.classList === void 0 ? At(e, d((" " + jt(e) + " ").replace(" " + t + " ", " "))) : e.classList.remove(t);
833
+ }
834
+ function At(e, t) {
835
+ e.className.baseVal === void 0 ? e.className = t : e.className.baseVal = t;
836
+ }
837
+ function jt(e) {
838
+ return e.correspondingElement && (e = e.correspondingElement), e.className.baseVal === void 0 ? e.className : e.className.baseVal;
839
+ }
840
+ function B(e, t) {
841
+ "opacity" in e.style ? e.style.opacity = t : "filter" in e.style && Mt(e, t);
842
+ }
843
+ function Mt(e, t) {
844
+ var n = !1, r = "DXImageTransform.Microsoft.Alpha";
845
+ try {
846
+ n = e.filters.item(r);
847
+ } catch {
848
+ if (t === 1) return;
849
+ }
850
+ t = Math.round(t * 100), n ? (n.Enabled = t !== 100, n.Opacity = t) : e.style.filter += " progid:" + r + "(opacity=" + t + ")";
851
+ }
852
+ function Nt(e) {
853
+ for (var t = document.documentElement.style, n = 0; n < e.length; n++) if (e[n] in t) return e[n];
854
+ return !1;
855
+ }
856
+ function Pt(e, t, n) {
857
+ var r = t || new S(0, 0);
858
+ e.style[xt] = (P.ie3d ? "translate(" + r.x + "px," + r.y + "px)" : "translate3d(" + r.x + "px," + r.y + "px,0)") + (n ? " scale(" + n + ")" : "");
859
+ }
860
+ function V(e, t) {
861
+ e._leaflet_pos = t, P.any3d ? Pt(e, t) : (e.style.left = t.x + "px", e.style.top = t.y + "px");
862
+ }
863
+ function Ft(e) {
864
+ return e._leaflet_pos || new S(0, 0);
865
+ }
866
+ var It, Lt, Rt;
867
+ if ("onselectstart" in document) It = function() {
868
+ H(window, "selectstart", G);
869
+ }, Lt = function() {
870
+ W(window, "selectstart", G);
871
+ };
872
+ else {
873
+ var zt = Nt([
874
+ "userSelect",
875
+ "WebkitUserSelect",
876
+ "OUserSelect",
877
+ "MozUserSelect",
878
+ "msUserSelect"
879
+ ]);
880
+ It = function() {
881
+ if (zt) {
882
+ var e = document.documentElement.style;
883
+ Rt = e[zt], e[zt] = "none";
884
+ }
885
+ }, Lt = function() {
886
+ zt && (document.documentElement.style[zt] = Rt, Rt = void 0);
887
+ };
888
+ }
889
+ function Bt() {
890
+ H(window, "dragstart", G);
891
+ }
892
+ function Vt() {
893
+ W(window, "dragstart", G);
894
+ }
895
+ var Ht, Ut;
896
+ function Wt(e) {
897
+ for (; e.tabIndex === -1;) e = e.parentNode;
898
+ e.style && (Gt(), Ht = e, Ut = e.style.outlineStyle, e.style.outlineStyle = "none", H(window, "keydown", Gt));
899
+ }
900
+ function Gt() {
901
+ Ht && (Ht.style.outlineStyle = Ut, Ht = void 0, Ut = void 0, W(window, "keydown", Gt));
902
+ }
903
+ function Kt(e) {
904
+ do
905
+ e = e.parentNode;
906
+ while ((!e.offsetWidth || !e.offsetHeight) && e !== document.body);
907
+ return e;
908
+ }
909
+ function qt(e) {
910
+ var t = e.getBoundingClientRect();
911
+ return {
912
+ x: t.width / e.offsetWidth || 1,
913
+ y: t.height / e.offsetHeight || 1,
914
+ boundingClientRect: t
915
+ };
916
+ }
917
+ var Jt = {
918
+ __proto__: null,
919
+ TRANSFORM: xt,
920
+ TRANSITION: St,
921
+ TRANSITION_END: Ct,
922
+ get: wt,
923
+ getStyle: Tt,
924
+ create: F,
925
+ remove: I,
926
+ empty: Et,
927
+ toFront: Dt,
928
+ toBack: Ot,
929
+ hasClass: kt,
930
+ addClass: R,
931
+ removeClass: z,
932
+ setClass: At,
933
+ getClass: jt,
934
+ setOpacity: B,
935
+ testProp: Nt,
936
+ setTransform: Pt,
937
+ setPosition: V,
938
+ getPosition: Ft,
939
+ get disableTextSelection() {
940
+ return It;
941
+ },
942
+ get enableTextSelection() {
943
+ return Lt;
944
+ },
945
+ disableImageDrag: Bt,
946
+ enableImageDrag: Vt,
947
+ preventOutline: Wt,
948
+ restoreOutline: Gt,
949
+ getSizedParentNode: Kt,
950
+ getScale: qt
951
+ };
952
+ function H(e, t, n, r) {
953
+ if (t && typeof t == "object") for (var i in t) Zt(e, i, t[i], n);
954
+ else {
955
+ t = f(t);
956
+ for (var a = 0, o = t.length; a < o; a++) Zt(e, t[a], n, r);
957
+ }
958
+ return this;
959
+ }
960
+ var U = "_leaflet_events";
961
+ function W(e, t, n, r) {
962
+ if (arguments.length === 1) Yt(e), delete e[U];
963
+ else if (t && typeof t == "object") for (var i in t) Qt(e, i, t[i], n);
964
+ else if (t = f(t), arguments.length === 2) Yt(e, function(e) {
965
+ return ee(t, e) !== -1;
966
+ });
967
+ else for (var a = 0, o = t.length; a < o; a++) Qt(e, t[a], n, r);
968
+ return this;
969
+ }
970
+ function Yt(e, t) {
971
+ for (var n in e[U]) {
972
+ var r = n.split(/\d/)[0];
973
+ (!t || t(r)) && Qt(e, r, null, null, n);
974
+ }
975
+ }
976
+ var Xt = {
977
+ mouseenter: "mouseover",
978
+ mouseleave: "mouseout",
979
+ wheel: !("onwheel" in window) && "mousewheel"
980
+ };
981
+ function Zt(e, t, n, r) {
982
+ var i = t + o(n) + (r ? "_" + o(r) : "");
983
+ if (e[U] && e[U][i]) return this;
984
+ var a = function(t) {
985
+ return n.call(r || e, t || window.event);
986
+ }, s = a;
987
+ !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) {
988
+ t ||= window.event, cn(e, t) && s(t);
989
+ }, e.addEventListener(Xt[t], a, !1)) : e.addEventListener(t, s, !1) : e.attachEvent("on" + t, a), e[U] = e[U] || {}, e[U][i] = a;
990
+ }
991
+ function Qt(e, t, n, r, i) {
992
+ i ||= t + o(n) + (r ? "_" + o(r) : "");
993
+ var a = e[U] && e[U][i];
994
+ if (!a) return this;
995
+ !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;
996
+ }
997
+ function $t(e) {
998
+ return e.stopPropagation ? e.stopPropagation() : e.originalEvent ? e.originalEvent._stopped = !0 : e.cancelBubble = !0, this;
999
+ }
1000
+ function en(e) {
1001
+ return Zt(e, "wheel", $t), this;
1002
+ }
1003
+ function tn(e) {
1004
+ return H(e, "mousedown touchstart dblclick contextmenu", $t), e._leaflet_disable_click = !0, this;
1005
+ }
1006
+ function G(e) {
1007
+ return e.preventDefault ? e.preventDefault() : e.returnValue = !1, this;
1008
+ }
1009
+ function nn(e) {
1010
+ return G(e), $t(e), this;
1011
+ }
1012
+ function rn(e) {
1013
+ if (e.composedPath) return e.composedPath();
1014
+ for (var t = [], n = e.target; n;) t.push(n), n = n.parentNode;
1015
+ return t;
1016
+ }
1017
+ function an(e, t) {
1018
+ if (!t) return new S(e.clientX, e.clientY);
1019
+ var n = qt(t), r = n.boundingClientRect;
1020
+ return new S((e.clientX - r.left) / n.x - t.clientLeft, (e.clientY - r.top) / n.y - t.clientTop);
1021
+ }
1022
+ var on = P.linux && P.chrome ? window.devicePixelRatio : P.mac ? window.devicePixelRatio * 3 : window.devicePixelRatio > 0 ? 2 * window.devicePixelRatio : 1;
1023
+ function sn(e) {
1024
+ 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;
1025
+ }
1026
+ function cn(e, t) {
1027
+ var n = t.relatedTarget;
1028
+ if (!n) return !0;
1029
+ try {
1030
+ for (; n && n !== e;) n = n.parentNode;
1031
+ } catch {
1032
+ return !1;
1033
+ }
1034
+ return n !== e;
1035
+ }
1036
+ var ln = {
1037
+ __proto__: null,
1038
+ on: H,
1039
+ off: W,
1040
+ stopPropagation: $t,
1041
+ disableScrollPropagation: en,
1042
+ disableClickPropagation: tn,
1043
+ preventDefault: G,
1044
+ stop: nn,
1045
+ getPropagationPath: rn,
1046
+ getMousePosition: an,
1047
+ getWheelDelta: sn,
1048
+ isExternalTarget: cn,
1049
+ addListener: H,
1050
+ removeListener: W
1051
+ }, un = le.extend({
1052
+ run: function(e, t, n, r) {
1053
+ 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();
1054
+ },
1055
+ stop: function() {
1056
+ this._inProgress && (this._step(!0), this._complete());
1057
+ },
1058
+ _animate: function() {
1059
+ this._animId = v(this._animate, this), this._step();
1060
+ },
1061
+ _step: function(e) {
1062
+ var t = +/* @__PURE__ */ new Date() - this._startTime, n = this._duration * 1e3;
1063
+ t < n ? this._runFrame(this._easeOut(t / n), e) : (this._runFrame(1), this._complete());
1064
+ },
1065
+ _runFrame: function(e, t) {
1066
+ var n = this._startPos.add(this._offset.multiplyBy(e));
1067
+ t && n._round(), V(this._el, n), this.fire("step");
1068
+ },
1069
+ _complete: function() {
1070
+ y(this._animId), this._inProgress = !1, this.fire("end");
1071
+ },
1072
+ _easeOut: function(e) {
1073
+ return 1 - (1 - e) ** this._easeOutPower;
1074
+ }
1075
+ }), K = le.extend({
1076
+ options: {
1077
+ crs: he,
1078
+ center: void 0,
1079
+ zoom: void 0,
1080
+ minZoom: void 0,
1081
+ maxZoom: void 0,
1082
+ layers: [],
1083
+ maxBounds: void 0,
1084
+ renderer: void 0,
1085
+ zoomAnimation: !0,
1086
+ zoomAnimationThreshold: 4,
1087
+ fadeAnimation: !0,
1088
+ markerZoomAnimation: !0,
1089
+ transform3DLimit: 8388608,
1090
+ zoomSnap: 1,
1091
+ zoomDelta: 1,
1092
+ trackResize: !0
1093
+ },
1094
+ initialize: function(e, t) {
1095
+ 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);
1096
+ },
1097
+ setView: function(e, t, r) {
1098
+ 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({
1099
+ animate: r.animate,
1100
+ duration: r.duration
1101
+ }, 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);
1102
+ },
1103
+ setZoom: function(e, t) {
1104
+ return this._loaded ? this.setView(this.getCenter(), e, { zoom: t }) : (this._zoom = e, this);
1105
+ },
1106
+ zoomIn: function(e, t) {
1107
+ return e ||= P.any3d ? this.options.zoomDelta : 1, this.setZoom(this._zoom + e, t);
1108
+ },
1109
+ zoomOut: function(e, t) {
1110
+ return e ||= P.any3d ? this.options.zoomDelta : 1, this.setZoom(this._zoom - e, t);
1111
+ },
1112
+ setZoomAround: function(e, t, n) {
1113
+ 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));
1114
+ return this.setView(o, t, { zoom: n });
1115
+ },
1116
+ _getBoundsCenterZoom: function(e, t) {
1117
+ t ||= {}, e = e.getBounds ? e.getBounds() : D(e);
1118
+ 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));
1119
+ if (i = typeof t.maxZoom == "number" ? Math.min(t.maxZoom, i) : i, i === Infinity) return {
1120
+ center: e.getCenter(),
1121
+ zoom: i
1122
+ };
1123
+ var a = r.subtract(n).divideBy(2), o = this.project(e.getSouthWest(), i), s = this.project(e.getNorthEast(), i);
1124
+ return {
1125
+ center: this.unproject(o.add(s).divideBy(2).add(a), i),
1126
+ zoom: i
1127
+ };
1128
+ },
1129
+ fitBounds: function(e, t) {
1130
+ if (e = D(e), !e.isValid()) throw Error("Bounds are not valid.");
1131
+ var n = this._getBoundsCenterZoom(e, t);
1132
+ return this.setView(n.center, n.zoom, t);
1133
+ },
1134
+ fitWorld: function(e) {
1135
+ return this.fitBounds([[-90, -180], [90, 180]], e);
1136
+ },
1137
+ panTo: function(e, t) {
1138
+ return this.setView(e, this._zoom, { pan: t });
1139
+ },
1140
+ panBy: function(e, t) {
1141
+ if (e = C(e).round(), t ||= {}, !e.x && !e.y) return this.fire("moveend");
1142
+ if (t.animate !== !0 && !this.getSize().contains(e)) return this._resetView(this.unproject(this.project(this.getCenter()).add(e)), this.getZoom()), this;
1143
+ if (this._panAnim || (this._panAnim = new un(), this._panAnim.on({
1144
+ step: this._onPanTransitionStep,
1145
+ end: this._onPanTransitionEnd
1146
+ }, this)), t.noMoveStart || this.fire("movestart"), t.animate !== !1) {
1147
+ R(this._mapPane, "leaflet-pan-anim");
1148
+ var n = this._getMapPanePos().subtract(e).round();
1149
+ this._panAnim.run(this._mapPane, n, t.duration || .25, t.easeLinearity);
1150
+ } else this._rawPanBy(e), this.fire("move").fire("moveend");
1151
+ return this;
1152
+ },
1153
+ flyTo: function(e, t, n) {
1154
+ if (n ||= {}, n.animate === !1 || !P.any3d) return this.setView(e, t, n);
1155
+ this._stop();
1156
+ var r = this.project(this.getCenter()), i = this.project(e), a = this.getSize(), o = this._zoom;
1157
+ e = k(e), t = t === void 0 ? o : t;
1158
+ 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;
1159
+ function f(e) {
1160
+ 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;
1161
+ return i < 1e-9 ? -18 : Math.log(i);
1162
+ }
1163
+ function p(e) {
1164
+ return (Math.exp(e) - Math.exp(-e)) / 2;
1165
+ }
1166
+ function m(e) {
1167
+ return (Math.exp(e) + Math.exp(-e)) / 2;
1168
+ }
1169
+ function h(e) {
1170
+ return p(e) / m(e);
1171
+ }
1172
+ var g = f(0);
1173
+ function _(e) {
1174
+ return s * (m(g) / m(g + u * e));
1175
+ }
1176
+ function ee(e) {
1177
+ return s * (m(g) * h(g + u * e) - p(g)) / d;
1178
+ }
1179
+ function te(e) {
1180
+ return 1 - (1 - e) ** 1.5;
1181
+ }
1182
+ var ne = Date.now(), re = (f(1) - g) / u, ie = n.duration ? 1e3 * n.duration : 1e3 * re * .8;
1183
+ function ae() {
1184
+ var n = (Date.now() - ne) / ie, a = te(n) * re;
1185
+ 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);
1186
+ }
1187
+ return this._moveStart(!0, n.noMoveStart), ae.call(this), this;
1188
+ },
1189
+ flyToBounds: function(e, t) {
1190
+ var n = this._getBoundsCenterZoom(e, t);
1191
+ return this.flyTo(n.center, n.zoom, t);
1192
+ },
1193
+ setMaxBounds: function(e) {
1194
+ 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);
1195
+ },
1196
+ setMinZoom: function(e) {
1197
+ var t = this.options.minZoom;
1198
+ return this.options.minZoom = e, this._loaded && t !== e && (this.fire("zoomlevelschange"), this.getZoom() < this.options.minZoom) ? this.setZoom(e) : this;
1199
+ },
1200
+ setMaxZoom: function(e) {
1201
+ var t = this.options.maxZoom;
1202
+ return this.options.maxZoom = e, this._loaded && t !== e && (this.fire("zoomlevelschange"), this.getZoom() > this.options.maxZoom) ? this.setZoom(e) : this;
1203
+ },
1204
+ panInsideBounds: function(e, t) {
1205
+ this._enforcingBounds = !0;
1206
+ var n = this.getCenter(), r = this._limitCenter(n, this._zoom, D(e));
1207
+ return n.equals(r) || this.panTo(r, t), this._enforcingBounds = !1, this;
1208
+ },
1209
+ panInside: function(e, t) {
1210
+ t ||= {};
1211
+ 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();
1212
+ if (!s.contains(a)) {
1213
+ this._enforcingBounds = !0;
1214
+ var l = a.subtract(s.getCenter()), u = s.extend(a).getSize().subtract(c);
1215
+ 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;
1216
+ }
1217
+ return this;
1218
+ },
1219
+ invalidateSize: function(e) {
1220
+ if (!this._loaded) return this;
1221
+ e = n({
1222
+ animate: !1,
1223
+ pan: !0
1224
+ }, e === !0 ? { animate: !0 } : e);
1225
+ var t = this.getSize();
1226
+ this._sizeChanged = !0, this._lastCenter = null;
1227
+ var r = this.getSize(), a = t.divideBy(2).round(), o = r.divideBy(2).round(), s = a.subtract(o);
1228
+ 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", {
1229
+ oldSize: t,
1230
+ newSize: r
1231
+ }));
1232
+ },
1233
+ stop: function() {
1234
+ return this.setZoom(this._limitZoom(this._zoom)), this.options.zoomSnap || this.fire("viewreset"), this._stop();
1235
+ },
1236
+ locate: function(e) {
1237
+ if (e = this._locateOptions = n({
1238
+ timeout: 1e4,
1239
+ watch: !1
1240
+ }, e), !("geolocation" in navigator)) return this._handleGeolocationError({
1241
+ code: 0,
1242
+ message: "Geolocation not supported."
1243
+ }), this;
1244
+ var t = i(this._handleGeolocationResponse, this), r = i(this._handleGeolocationError, this);
1245
+ return e.watch ? this._locationWatchId = navigator.geolocation.watchPosition(t, r, e) : navigator.geolocation.getCurrentPosition(t, r, e), this;
1246
+ },
1247
+ stopLocate: function() {
1248
+ return navigator.geolocation && navigator.geolocation.clearWatch && navigator.geolocation.clearWatch(this._locationWatchId), this._locateOptions && (this._locateOptions.setView = !1), this;
1249
+ },
1250
+ _handleGeolocationError: function(e) {
1251
+ if (this._container._leaflet_id) {
1252
+ var t = e.code, n = e.message || (t === 1 ? "permission denied" : t === 2 ? "position unavailable" : "timeout");
1253
+ this._locateOptions.setView && !this._loaded && this.fitWorld(), this.fire("locationerror", {
1254
+ code: t,
1255
+ message: "Geolocation error: " + n + "."
1256
+ });
1257
+ }
1258
+ },
1259
+ _handleGeolocationResponse: function(e) {
1260
+ if (this._container._leaflet_id) {
1261
+ var t = e.coords.latitude, n = e.coords.longitude, r = new O(t, n), i = r.toBounds(e.coords.accuracy * 2), a = this._locateOptions;
1262
+ if (a.setView) {
1263
+ var o = this.getBoundsZoom(i);
1264
+ this.setView(r, a.maxZoom ? Math.min(o, a.maxZoom) : o);
1265
+ }
1266
+ var s = {
1267
+ latlng: r,
1268
+ bounds: i,
1269
+ timestamp: e.timestamp
1270
+ };
1271
+ for (var c in e.coords) typeof e.coords[c] == "number" && (s[c] = e.coords[c]);
1272
+ this.fire("locationfound", s);
1273
+ }
1274
+ },
1275
+ addHandler: function(e, t) {
1276
+ if (!t) return this;
1277
+ var n = this[e] = new t(this);
1278
+ return this._handlers.push(n), this.options[e] && n.enable(), this;
1279
+ },
1280
+ remove: function() {
1281
+ 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");
1282
+ try {
1283
+ delete this._container._leaflet_id, delete this._containerId;
1284
+ } catch {
1285
+ this._container._leaflet_id = void 0, this._containerId = void 0;
1286
+ }
1287
+ 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();
1288
+ for (e in this._panes) I(this._panes[e]);
1289
+ return this._layers = [], this._panes = [], delete this._mapPane, delete this._renderer, this;
1290
+ },
1291
+ createPane: function(e, t) {
1292
+ var n = F("div", "leaflet-pane" + (e ? " leaflet-" + e.replace("Pane", "") + "-pane" : ""), t || this._mapPane);
1293
+ return e && (this._panes[e] = n), n;
1294
+ },
1295
+ getCenter: function() {
1296
+ return this._checkIfLoaded(), this._lastCenter && !this._moved() ? this._lastCenter.clone() : this.layerPointToLatLng(this._getCenterLayerPoint());
1297
+ },
1298
+ getZoom: function() {
1299
+ return this._zoom;
1300
+ },
1301
+ getBounds: function() {
1302
+ var e = this.getPixelBounds();
1303
+ return new E(this.unproject(e.getBottomLeft()), this.unproject(e.getTopRight()));
1304
+ },
1305
+ getMinZoom: function() {
1306
+ return this.options.minZoom === void 0 ? this._layersMinZoom || 0 : this.options.minZoom;
1307
+ },
1308
+ getMaxZoom: function() {
1309
+ return this.options.maxZoom === void 0 ? this._layersMaxZoom === void 0 ? Infinity : this._layersMaxZoom : this.options.maxZoom;
1310
+ },
1311
+ getBoundsZoom: function(e, t, n) {
1312
+ e = D(e), n = C(n || [0, 0]);
1313
+ 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);
1314
+ 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));
1315
+ },
1316
+ getSize: function() {
1317
+ return (!this._size || this._sizeChanged) && (this._size = new S(this._container.clientWidth || 0, this._container.clientHeight || 0), this._sizeChanged = !1), this._size.clone();
1318
+ },
1319
+ getPixelBounds: function(e, t) {
1320
+ var n = this._getTopLeftPoint(e, t);
1321
+ return new w(n, n.add(this.getSize()));
1322
+ },
1323
+ getPixelOrigin: function() {
1324
+ return this._checkIfLoaded(), this._pixelOrigin;
1325
+ },
1326
+ getPixelWorldBounds: function(e) {
1327
+ return this.options.crs.getProjectedBounds(e === void 0 ? this.getZoom() : e);
1328
+ },
1329
+ getPane: function(e) {
1330
+ return typeof e == "string" ? this._panes[e] : e;
1331
+ },
1332
+ getPanes: function() {
1333
+ return this._panes;
1334
+ },
1335
+ getContainer: function() {
1336
+ return this._container;
1337
+ },
1338
+ getZoomScale: function(e, t) {
1339
+ var n = this.options.crs;
1340
+ return t = t === void 0 ? this._zoom : t, n.scale(e) / n.scale(t);
1341
+ },
1342
+ getScaleZoom: function(e, t) {
1343
+ var n = this.options.crs;
1344
+ t = t === void 0 ? this._zoom : t;
1345
+ var r = n.zoom(e * n.scale(t));
1346
+ return isNaN(r) ? Infinity : r;
1347
+ },
1348
+ project: function(e, t) {
1349
+ return t = t === void 0 ? this._zoom : t, this.options.crs.latLngToPoint(k(e), t);
1350
+ },
1351
+ unproject: function(e, t) {
1352
+ return t = t === void 0 ? this._zoom : t, this.options.crs.pointToLatLng(C(e), t);
1353
+ },
1354
+ layerPointToLatLng: function(e) {
1355
+ var t = C(e).add(this.getPixelOrigin());
1356
+ return this.unproject(t);
1357
+ },
1358
+ latLngToLayerPoint: function(e) {
1359
+ return this.project(k(e))._round()._subtract(this.getPixelOrigin());
1360
+ },
1361
+ wrapLatLng: function(e) {
1362
+ return this.options.crs.wrapLatLng(k(e));
1363
+ },
1364
+ wrapLatLngBounds: function(e) {
1365
+ return this.options.crs.wrapLatLngBounds(D(e));
1366
+ },
1367
+ distance: function(e, t) {
1368
+ return this.options.crs.distance(k(e), k(t));
1369
+ },
1370
+ containerPointToLayerPoint: function(e) {
1371
+ return C(e).subtract(this._getMapPanePos());
1372
+ },
1373
+ layerPointToContainerPoint: function(e) {
1374
+ return C(e).add(this._getMapPanePos());
1375
+ },
1376
+ containerPointToLatLng: function(e) {
1377
+ var t = this.containerPointToLayerPoint(C(e));
1378
+ return this.layerPointToLatLng(t);
1379
+ },
1380
+ latLngToContainerPoint: function(e) {
1381
+ return this.layerPointToContainerPoint(this.latLngToLayerPoint(k(e)));
1382
+ },
1383
+ mouseEventToContainerPoint: function(e) {
1384
+ return an(e, this._container);
1385
+ },
1386
+ mouseEventToLayerPoint: function(e) {
1387
+ return this.containerPointToLayerPoint(this.mouseEventToContainerPoint(e));
1388
+ },
1389
+ mouseEventToLatLng: function(e) {
1390
+ return this.layerPointToLatLng(this.mouseEventToLayerPoint(e));
1391
+ },
1392
+ _initContainer: function(e) {
1393
+ var t = this._container = wt(e);
1394
+ if (!t) throw Error("Map container not found.");
1395
+ if (t._leaflet_id) throw Error("Map container is already initialized.");
1396
+ H(t, "scroll", this._onScroll, this), this._containerId = o(t);
1397
+ },
1398
+ _initLayout: function() {
1399
+ var e = this._container;
1400
+ 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" : ""));
1401
+ var t = Tt(e, "position");
1402
+ t !== "absolute" && t !== "relative" && t !== "fixed" && t !== "sticky" && (e.style.position = "relative"), this._initPanes(), this._initControlPos && this._initControlPos();
1403
+ },
1404
+ _initPanes: function() {
1405
+ var e = this._panes = {};
1406
+ 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"));
1407
+ },
1408
+ _resetView: function(e, t, n) {
1409
+ V(this._mapPane, new S(0, 0));
1410
+ var r = !this._loaded;
1411
+ this._loaded = !0, t = this._limitZoom(t), this.fire("viewprereset");
1412
+ var i = this._zoom !== t;
1413
+ this._moveStart(i, n)._move(e, t)._moveEnd(i), this.fire("viewreset"), r && this.fire("load");
1414
+ },
1415
+ _moveStart: function(e, t) {
1416
+ return e && this.fire("zoomstart"), t || this.fire("movestart"), this;
1417
+ },
1418
+ _move: function(e, t, n, r) {
1419
+ t === void 0 && (t = this._zoom);
1420
+ var i = this._zoom !== t;
1421
+ 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;
1422
+ },
1423
+ _moveEnd: function(e) {
1424
+ return e && this.fire("zoomend"), this.fire("moveend");
1425
+ },
1426
+ _stop: function() {
1427
+ return y(this._flyToFrame), this._panAnim && this._panAnim.stop(), this;
1428
+ },
1429
+ _rawPanBy: function(e) {
1430
+ V(this._mapPane, this._getMapPanePos().subtract(e));
1431
+ },
1432
+ _getZoomSpan: function() {
1433
+ return this.getMaxZoom() - this.getMinZoom();
1434
+ },
1435
+ _panInsideMaxBounds: function() {
1436
+ this._enforcingBounds || this.panInsideBounds(this.options.maxBounds);
1437
+ },
1438
+ _checkIfLoaded: function() {
1439
+ if (!this._loaded) throw Error("Set map center and zoom first.");
1440
+ },
1441
+ _initEvents: function(e) {
1442
+ this._targets = {}, this._targets[o(this._container)] = this;
1443
+ var t = e ? W : H;
1444
+ 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);
1445
+ },
1446
+ _onResize: function() {
1447
+ y(this._resizeRequest), this._resizeRequest = v(function() {
1448
+ this.invalidateSize({ debounceMoveend: !0 });
1449
+ }, this);
1450
+ },
1451
+ _onScroll: function() {
1452
+ this._container.scrollTop = 0, this._container.scrollLeft = 0;
1453
+ },
1454
+ _onMoveEnd: function() {
1455
+ var e = this._getMapPanePos();
1456
+ Math.max(Math.abs(e.x), Math.abs(e.y)) >= this.options.transform3DLimit && this._resetView(this.getCenter(), this.getZoom());
1457
+ },
1458
+ _findEventTargets: function(e, t) {
1459
+ for (var n = [], r, i = t === "mouseout" || t === "mouseover", a = e.target || e.srcElement, s = !1; a;) {
1460
+ if (r = this._targets[o(a)], r && (t === "click" || t === "preclick") && this._draggableMoved(r)) {
1461
+ s = !0;
1462
+ break;
1463
+ }
1464
+ if (r && r.listens(t, !0) && (i && !cn(a, e) || (n.push(r), i)) || a === this._container) break;
1465
+ a = a.parentNode;
1466
+ }
1467
+ return !n.length && !s && !i && this.listens(t, !0) && (n = [this]), n;
1468
+ },
1469
+ _isClickDisabled: function(e) {
1470
+ for (; e && e !== this._container;) {
1471
+ if (e._leaflet_disable_click) return !0;
1472
+ e = e.parentNode;
1473
+ }
1474
+ },
1475
+ _handleDOMEvent: function(e) {
1476
+ var t = e.target || e.srcElement;
1477
+ if (!(!this._loaded || t._leaflet_disable_events || e.type === "click" && this._isClickDisabled(t))) {
1478
+ var n = e.type;
1479
+ n === "mousedown" && Wt(t), this._fireDOMEvent(e, n);
1480
+ }
1481
+ },
1482
+ _mouseEvents: [
1483
+ "click",
1484
+ "dblclick",
1485
+ "mouseover",
1486
+ "mouseout",
1487
+ "contextmenu"
1488
+ ],
1489
+ _fireDOMEvent: function(e, t, r) {
1490
+ if (e.type === "click") {
1491
+ var i = n({}, e);
1492
+ i.type = "preclick", this._fireDOMEvent(i, i.type, r);
1493
+ }
1494
+ var a = this._findEventTargets(e, t);
1495
+ if (r) {
1496
+ for (var o = [], s = 0; s < r.length; s++) r[s].listens(t, !0) && o.push(r[s]);
1497
+ a = o.concat(a);
1498
+ }
1499
+ if (a.length) {
1500
+ t === "contextmenu" && G(e);
1501
+ var c = a[0], l = { originalEvent: e };
1502
+ if (e.type !== "keypress" && e.type !== "keydown" && e.type !== "keyup") {
1503
+ var u = c.getLatLng && (!c._radius || c._radius <= 10);
1504
+ 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);
1505
+ }
1506
+ 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;
1507
+ }
1508
+ },
1509
+ _draggableMoved: function(e) {
1510
+ return e = e.dragging && e.dragging.enabled() ? e : this, e.dragging && e.dragging.moved() || this.boxZoom && this.boxZoom.moved();
1511
+ },
1512
+ _clearHandlers: function() {
1513
+ for (var e = 0, t = this._handlers.length; e < t; e++) this._handlers[e].disable();
1514
+ },
1515
+ whenReady: function(e, t) {
1516
+ return this._loaded ? e.call(t || this, { target: this }) : this.on("load", e, t), this;
1517
+ },
1518
+ _getMapPanePos: function() {
1519
+ return Ft(this._mapPane) || new S(0, 0);
1520
+ },
1521
+ _moved: function() {
1522
+ var e = this._getMapPanePos();
1523
+ return e && !e.equals([0, 0]);
1524
+ },
1525
+ _getTopLeftPoint: function(e, t) {
1526
+ return (e && t !== void 0 ? this._getNewPixelOrigin(e, t) : this.getPixelOrigin()).subtract(this._getMapPanePos());
1527
+ },
1528
+ _getNewPixelOrigin: function(e, t) {
1529
+ var n = this.getSize()._divideBy(2);
1530
+ return this.project(e, t)._subtract(n)._add(this._getMapPanePos())._round();
1531
+ },
1532
+ _latLngToNewLayerPoint: function(e, t, n) {
1533
+ var r = this._getNewPixelOrigin(n, t);
1534
+ return this.project(e, t)._subtract(r);
1535
+ },
1536
+ _latLngBoundsToNewLayerBounds: function(e, t, n) {
1537
+ var r = this._getNewPixelOrigin(n, t);
1538
+ return T([
1539
+ this.project(e.getSouthWest(), t)._subtract(r),
1540
+ this.project(e.getNorthWest(), t)._subtract(r),
1541
+ this.project(e.getSouthEast(), t)._subtract(r),
1542
+ this.project(e.getNorthEast(), t)._subtract(r)
1543
+ ]);
1544
+ },
1545
+ _getCenterLayerPoint: function() {
1546
+ return this.containerPointToLayerPoint(this.getSize()._divideBy(2));
1547
+ },
1548
+ _getCenterOffset: function(e) {
1549
+ return this.latLngToLayerPoint(e).subtract(this._getCenterLayerPoint());
1550
+ },
1551
+ _limitCenter: function(e, t, n) {
1552
+ if (!n) return e;
1553
+ 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);
1554
+ return Math.abs(o.x) <= 1 && Math.abs(o.y) <= 1 ? e : this.unproject(r.add(o), t);
1555
+ },
1556
+ _limitOffset: function(e, t) {
1557
+ if (!t) return e;
1558
+ var n = this.getPixelBounds(), r = new w(n.min.add(e), n.max.add(e));
1559
+ return e.add(this._getBoundsOffset(r, t));
1560
+ },
1561
+ _getBoundsOffset: function(e, t, n) {
1562
+ 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);
1563
+ return new S(this._rebound(i.x, -a.x), this._rebound(i.y, -a.y));
1564
+ },
1565
+ _rebound: function(e, t) {
1566
+ return e + t > 0 ? Math.round(e - t) / 2 : Math.max(0, Math.ceil(e)) - Math.max(0, Math.floor(t));
1567
+ },
1568
+ _limitZoom: function(e) {
1569
+ var t = this.getMinZoom(), n = this.getMaxZoom(), r = P.any3d ? this.options.zoomSnap : 1;
1570
+ return r && (e = Math.round(e / r) * r), Math.max(t, Math.min(n, e));
1571
+ },
1572
+ _onPanTransitionStep: function() {
1573
+ this.fire("move");
1574
+ },
1575
+ _onPanTransitionEnd: function() {
1576
+ z(this._mapPane, "leaflet-pan-anim"), this.fire("moveend");
1577
+ },
1578
+ _tryAnimatedPan: function(e, t) {
1579
+ var n = this._getCenterOffset(e)._trunc();
1580
+ return (t && t.animate) !== !0 && !this.getSize().contains(n) ? !1 : (this.panBy(n, t), !0);
1581
+ },
1582
+ _createAnimProxy: function() {
1583
+ var e = this._proxy = F("div", "leaflet-proxy leaflet-zoom-animated");
1584
+ this._panes.mapPane.appendChild(e), this.on("zoomanim", function(e) {
1585
+ var t = xt, n = this._proxy.style[t];
1586
+ Pt(this._proxy, this.project(e.center, e.zoom), this.getZoomScale(e.zoom, 1)), n === this._proxy.style[t] && this._animatingZoom && this._onZoomTransitionEnd();
1587
+ }, this), this.on("load moveend", this._animMoveEnd, this), this._on("unload", this._destroyAnimProxy, this);
1588
+ },
1589
+ _destroyAnimProxy: function() {
1590
+ I(this._proxy), this.off("load moveend", this._animMoveEnd, this), delete this._proxy;
1591
+ },
1592
+ _animMoveEnd: function() {
1593
+ var e = this.getCenter(), t = this.getZoom();
1594
+ Pt(this._proxy, this.project(e, t), this.getZoomScale(t, 1));
1595
+ },
1596
+ _catchTransitionEnd: function(e) {
1597
+ this._animatingZoom && e.propertyName.indexOf("transform") >= 0 && this._onZoomTransitionEnd();
1598
+ },
1599
+ _nothingToAnimate: function() {
1600
+ return !this._container.getElementsByClassName("leaflet-zoom-animated").length;
1601
+ },
1602
+ _tryAnimatedZoom: function(e, t, n) {
1603
+ if (this._animatingZoom) return !0;
1604
+ if (n ||= {}, !this._zoomAnimated || n.animate === !1 || this._nothingToAnimate() || Math.abs(t - this._zoom) > this.options.zoomAnimationThreshold) return !1;
1605
+ var r = this.getZoomScale(t), i = this._getCenterOffset(e)._divideBy(1 - 1 / r);
1606
+ return n.animate !== !0 && !this.getSize().contains(i) ? !1 : (v(function() {
1607
+ this._moveStart(!0, n.noMoveStart || !1)._animateZoom(e, t, !0);
1608
+ }, this), !0);
1609
+ },
1610
+ _animateZoom: function(e, t, n, r) {
1611
+ this._mapPane && (n && (this._animatingZoom = !0, this._animateToCenter = e, this._animateToZoom = t, R(this._mapPane, "leaflet-zoom-anim")), this.fire("zoomanim", {
1612
+ center: e,
1613
+ zoom: t,
1614
+ noUpdate: r
1615
+ }), this._tempFireZoomEvent ||= this._zoom !== this._animateToZoom, this._move(this._animateToCenter, this._animateToZoom, void 0, !0), setTimeout(i(this._onZoomTransitionEnd, this), 250));
1616
+ },
1617
+ _onZoomTransitionEnd: function() {
1618
+ 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));
1619
+ }
1620
+ });
1621
+ function dn(e, t) {
1622
+ return new K(e, t);
1623
+ }
1624
+ var q = b.extend({
1625
+ options: { position: "topright" },
1626
+ initialize: function(e) {
1627
+ p(this, e);
1628
+ },
1629
+ getPosition: function() {
1630
+ return this.options.position;
1631
+ },
1632
+ setPosition: function(e) {
1633
+ var t = this._map;
1634
+ return t && t.removeControl(this), this.options.position = e, t && t.addControl(this), this;
1635
+ },
1636
+ getContainer: function() {
1637
+ return this._container;
1638
+ },
1639
+ addTo: function(e) {
1640
+ this.remove(), this._map = e;
1641
+ var t = this._container = this.onAdd(e), n = this.getPosition(), r = e._controlCorners[n];
1642
+ 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;
1643
+ },
1644
+ remove: function() {
1645
+ return this._map ? (I(this._container), this.onRemove && this.onRemove(this._map), this._map.off("unload", this.remove, this), this._map = null, this) : this;
1646
+ },
1647
+ _refocusOnMap: function(e) {
1648
+ this._map && e && e.screenX > 0 && e.screenY > 0 && this._map.getContainer().focus();
1649
+ }
1650
+ }), fn = function(e) {
1651
+ return new q(e);
1652
+ };
1653
+ K.include({
1654
+ addControl: function(e) {
1655
+ return e.addTo(this), this;
1656
+ },
1657
+ removeControl: function(e) {
1658
+ return e.remove(), this;
1659
+ },
1660
+ _initControlPos: function() {
1661
+ var e = this._controlCorners = {}, t = "leaflet-", n = this._controlContainer = F("div", t + "control-container", this._container);
1662
+ function r(r, i) {
1663
+ var a = t + r + " " + t + i;
1664
+ e[r + i] = F("div", a, n);
1665
+ }
1666
+ r("top", "left"), r("top", "right"), r("bottom", "left"), r("bottom", "right");
1667
+ },
1668
+ _clearControlPos: function() {
1669
+ for (var e in this._controlCorners) I(this._controlCorners[e]);
1670
+ I(this._controlContainer), delete this._controlCorners, delete this._controlContainer;
1671
+ }
1672
+ });
1673
+ var pn = q.extend({
1674
+ options: {
1675
+ collapsed: !0,
1676
+ position: "topright",
1677
+ autoZIndex: !0,
1678
+ hideSingleBase: !1,
1679
+ sortLayers: !1,
1680
+ sortFunction: function(e, t, n, r) {
1681
+ return n < r ? -1 : +(r < n);
1682
+ }
1683
+ },
1684
+ initialize: function(e, t, n) {
1685
+ 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);
1686
+ for (r in t) this._addLayer(t[r], r, !0);
1687
+ },
1688
+ onAdd: function(e) {
1689
+ this._initLayout(), this._update(), this._map = e, e.on("zoomend", this._checkDisabledLayers, this);
1690
+ for (var t = 0; t < this._layers.length; t++) this._layers[t].layer.on("add remove", this._onLayerChange, this);
1691
+ return this._container;
1692
+ },
1693
+ addTo: function(e) {
1694
+ return q.prototype.addTo.call(this, e), this._expandIfNotCollapsed();
1695
+ },
1696
+ onRemove: function() {
1697
+ this._map.off("zoomend", this._checkDisabledLayers, this);
1698
+ for (var e = 0; e < this._layers.length; e++) this._layers[e].layer.off("add remove", this._onLayerChange, this);
1699
+ },
1700
+ addBaseLayer: function(e, t) {
1701
+ return this._addLayer(e, t), this._map ? this._update() : this;
1702
+ },
1703
+ addOverlay: function(e, t) {
1704
+ return this._addLayer(e, t, !0), this._map ? this._update() : this;
1705
+ },
1706
+ removeLayer: function(e) {
1707
+ e.off("add remove", this._onLayerChange, this);
1708
+ var t = this._getLayer(o(e));
1709
+ return t && this._layers.splice(this._layers.indexOf(t), 1), this._map ? this._update() : this;
1710
+ },
1711
+ expand: function() {
1712
+ R(this._container, "leaflet-control-layers-expanded"), this._section.style.height = null;
1713
+ var e = this._map.getSize().y - (this._container.offsetTop + 50);
1714
+ 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;
1715
+ },
1716
+ collapse: function() {
1717
+ return z(this._container, "leaflet-control-layers-expanded"), this;
1718
+ },
1719
+ _initLayout: function() {
1720
+ var e = "leaflet-control-layers", t = this._container = F("div", e), n = this.options.collapsed;
1721
+ t.setAttribute("aria-haspopup", !0), tn(t), en(t);
1722
+ var r = this._section = F("section", e + "-list");
1723
+ n && (this._map.on("click", this.collapse, this), H(t, {
1724
+ mouseenter: this._expandSafely,
1725
+ mouseleave: this.collapse
1726
+ }, this));
1727
+ var i = this._layersLink = F("a", e + "-toggle", t);
1728
+ i.href = "#", i.title = "Layers", i.setAttribute("role", "button"), H(i, {
1729
+ keydown: function(e) {
1730
+ e.keyCode === 13 && this._expandSafely();
1731
+ },
1732
+ click: function(e) {
1733
+ G(e), this._expandSafely();
1734
+ }
1735
+ }, 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);
1736
+ },
1737
+ _getLayer: function(e) {
1738
+ for (var t = 0; t < this._layers.length; t++) if (this._layers[t] && o(this._layers[t].layer) === e) return this._layers[t];
1739
+ },
1740
+ _addLayer: function(e, t, n) {
1741
+ this._map && e.on("add remove", this._onLayerChange, this), this._layers.push({
1742
+ layer: e,
1743
+ name: t,
1744
+ overlay: n
1745
+ }), this.options.sortLayers && this._layers.sort(i(function(e, t) {
1746
+ return this.options.sortFunction(e.layer, t.layer, e.name, t.name);
1747
+ }, this)), this.options.autoZIndex && e.setZIndex && (this._lastZIndex++, e.setZIndex(this._lastZIndex)), this._expandIfNotCollapsed();
1748
+ },
1749
+ _update: function() {
1750
+ if (!this._container) return this;
1751
+ Et(this._baseLayersList), Et(this._overlaysList), this._layerControlInputs = [];
1752
+ var e, t, n, r, i = 0;
1753
+ for (n = 0; n < this._layers.length; n++) r = this._layers[n], this._addItem(r), t ||= r.overlay, e ||= !r.overlay, i += +!r.overlay;
1754
+ return this.options.hideSingleBase && (e &&= i > 1, this._baseLayersList.style.display = e ? "" : "none"), this._separator.style.display = t && e ? "" : "none", this;
1755
+ },
1756
+ _onLayerChange: function(e) {
1757
+ this._handlingClick || this._update();
1758
+ var t = this._getLayer(o(e.target)), n = t.overlay ? e.type === "add" ? "overlayadd" : "overlayremove" : e.type === "add" ? "baselayerchange" : null;
1759
+ n && this._map.fire(n, t);
1760
+ },
1761
+ _createRadioElement: function(e, t) {
1762
+ var n = "<input type=\"radio\" class=\"leaflet-control-layers-selector\" name=\"" + e + "\"" + (t ? " checked=\"checked\"" : "") + "/>", r = document.createElement("div");
1763
+ return r.innerHTML = n, r.firstChild;
1764
+ },
1765
+ _addItem: function(e) {
1766
+ var t = document.createElement("label"), n = this._map.hasLayer(e.layer), r;
1767
+ 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);
1768
+ var i = document.createElement("span");
1769
+ i.innerHTML = " " + e.name;
1770
+ var a = document.createElement("span");
1771
+ return t.appendChild(a), a.appendChild(r), a.appendChild(i), (e.overlay ? this._overlaysList : this._baseLayersList).appendChild(t), this._checkDisabledLayers(), t;
1772
+ },
1773
+ _onInputClick: function() {
1774
+ if (!this._preventClick) {
1775
+ var e = this._layerControlInputs, t, n, r = [], i = [];
1776
+ this._handlingClick = !0;
1777
+ 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);
1778
+ for (a = 0; a < i.length; a++) this._map.hasLayer(i[a]) && this._map.removeLayer(i[a]);
1779
+ for (a = 0; a < r.length; a++) this._map.hasLayer(r[a]) || this._map.addLayer(r[a]);
1780
+ this._handlingClick = !1, this._refocusOnMap();
1781
+ }
1782
+ },
1783
+ _checkDisabledLayers: function() {
1784
+ 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;
1785
+ },
1786
+ _expandIfNotCollapsed: function() {
1787
+ return this._map && !this.options.collapsed && this.expand(), this;
1788
+ },
1789
+ _expandSafely: function() {
1790
+ var e = this._section;
1791
+ this._preventClick = !0, H(e, "click", G), this.expand();
1792
+ var t = this;
1793
+ setTimeout(function() {
1794
+ W(e, "click", G), t._preventClick = !1;
1795
+ });
1796
+ }
1797
+ }), mn = function(e, t, n) {
1798
+ return new pn(e, t, n);
1799
+ }, hn = q.extend({
1800
+ options: {
1801
+ position: "topleft",
1802
+ zoomInText: "<span aria-hidden=\"true\">+</span>",
1803
+ zoomInTitle: "Zoom in",
1804
+ zoomOutText: "<span aria-hidden=\"true\">&#x2212;</span>",
1805
+ zoomOutTitle: "Zoom out"
1806
+ },
1807
+ onAdd: function(e) {
1808
+ var t = "leaflet-control-zoom", n = F("div", t + " leaflet-bar"), r = this.options;
1809
+ 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;
1810
+ },
1811
+ onRemove: function(e) {
1812
+ e.off("zoomend zoomlevelschange", this._updateDisabled, this);
1813
+ },
1814
+ disable: function() {
1815
+ return this._disabled = !0, this._updateDisabled(), this;
1816
+ },
1817
+ enable: function() {
1818
+ return this._disabled = !1, this._updateDisabled(), this;
1819
+ },
1820
+ _zoomIn: function(e) {
1821
+ !this._disabled && this._map._zoom < this._map.getMaxZoom() && this._map.zoomIn(this._map.options.zoomDelta * (e.shiftKey ? 3 : 1));
1822
+ },
1823
+ _zoomOut: function(e) {
1824
+ !this._disabled && this._map._zoom > this._map.getMinZoom() && this._map.zoomOut(this._map.options.zoomDelta * (e.shiftKey ? 3 : 1));
1825
+ },
1826
+ _createButton: function(e, t, n, r, i) {
1827
+ var a = F("a", n, r);
1828
+ 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;
1829
+ },
1830
+ _updateDisabled: function() {
1831
+ var e = this._map, t = "leaflet-disabled";
1832
+ 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"));
1833
+ }
1834
+ });
1835
+ K.mergeOptions({ zoomControl: !0 }), K.addInitHook(function() {
1836
+ this.options.zoomControl && (this.zoomControl = new hn(), this.addControl(this.zoomControl));
1837
+ });
1838
+ var gn = function(e) {
1839
+ return new hn(e);
1840
+ }, _n = q.extend({
1841
+ options: {
1842
+ position: "bottomleft",
1843
+ maxWidth: 100,
1844
+ metric: !0,
1845
+ imperial: !0
1846
+ },
1847
+ onAdd: function(e) {
1848
+ var t = "leaflet-control-scale", n = F("div", t), r = this.options;
1849
+ return this._addScales(r, t + "-line", n), e.on(r.updateWhenIdle ? "moveend" : "move", this._update, this), e.whenReady(this._update, this), n;
1850
+ },
1851
+ onRemove: function(e) {
1852
+ e.off(this.options.updateWhenIdle ? "moveend" : "move", this._update, this);
1853
+ },
1854
+ _addScales: function(e, t, n) {
1855
+ e.metric && (this._mScale = F("div", t, n)), e.imperial && (this._iScale = F("div", t, n));
1856
+ },
1857
+ _update: function() {
1858
+ var e = this._map, t = e.getSize().y / 2, n = e.distance(e.containerPointToLatLng([0, t]), e.containerPointToLatLng([this.options.maxWidth, t]));
1859
+ this._updateScales(n);
1860
+ },
1861
+ _updateScales: function(e) {
1862
+ this.options.metric && e && this._updateMetric(e), this.options.imperial && e && this._updateImperial(e);
1863
+ },
1864
+ _updateMetric: function(e) {
1865
+ var t = this._getRoundNum(e), n = t < 1e3 ? t + " m" : t / 1e3 + " km";
1866
+ this._updateScale(this._mScale, n, t / e);
1867
+ },
1868
+ _updateImperial: function(e) {
1869
+ var t = e * 3.2808399, n, r, i;
1870
+ 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));
1871
+ },
1872
+ _updateScale: function(e, t, n) {
1873
+ e.style.width = Math.round(this.options.maxWidth * n) + "px", e.innerHTML = t;
1874
+ },
1875
+ _getRoundNum: function(e) {
1876
+ var t = 10 ** ((Math.floor(e) + "").length - 1), n = e / t;
1877
+ return n = n >= 10 ? 10 : n >= 5 ? 5 : n >= 3 ? 3 : n >= 2 ? 2 : 1, t * n;
1878
+ }
1879
+ }), vn = function(e) {
1880
+ return new _n(e);
1881
+ }, yn = q.extend({
1882
+ options: {
1883
+ position: "bottomright",
1884
+ 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>"
1885
+ },
1886
+ initialize: function(e) {
1887
+ p(this, e), this._attributions = {};
1888
+ },
1889
+ onAdd: function(e) {
1890
+ 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());
1891
+ return this._update(), e.on("layeradd", this._addAttribution, this), this._container;
1892
+ },
1893
+ onRemove: function(e) {
1894
+ e.off("layeradd", this._addAttribution, this);
1895
+ },
1896
+ _addAttribution: function(e) {
1897
+ e.layer.getAttribution && (this.addAttribution(e.layer.getAttribution()), e.layer.once("remove", function() {
1898
+ this.removeAttribution(e.layer.getAttribution());
1899
+ }, this));
1900
+ },
1901
+ setPrefix: function(e) {
1902
+ return this.options.prefix = e, this._update(), this;
1903
+ },
1904
+ addAttribution: function(e) {
1905
+ return e ? (this._attributions[e] || (this._attributions[e] = 0), this._attributions[e]++, this._update(), this) : this;
1906
+ },
1907
+ removeAttribution: function(e) {
1908
+ return e && this._attributions[e] && (this._attributions[e]--, this._update()), this;
1909
+ },
1910
+ _update: function() {
1911
+ if (this._map) {
1912
+ var e = [];
1913
+ for (var t in this._attributions) this._attributions[t] && e.push(t);
1914
+ var n = [];
1915
+ this.options.prefix && n.push(this.options.prefix), e.length && n.push(e.join(", ")), this._container.innerHTML = n.join(" <span aria-hidden=\"true\">|</span> ");
1916
+ }
1917
+ }
1918
+ });
1919
+ K.mergeOptions({ attributionControl: !0 }), K.addInitHook(function() {
1920
+ this.options.attributionControl && new yn().addTo(this);
1921
+ }), 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) {
1922
+ return new yn(e);
1923
+ };
1924
+ var J = b.extend({
1925
+ initialize: function(e) {
1926
+ this._map = e;
1927
+ },
1928
+ enable: function() {
1929
+ return this._enabled ? this : (this._enabled = !0, this.addHooks(), this);
1930
+ },
1931
+ disable: function() {
1932
+ return this._enabled ? (this._enabled = !1, this.removeHooks(), this) : this;
1933
+ },
1934
+ enabled: function() {
1935
+ return !!this._enabled;
1936
+ }
1937
+ });
1938
+ J.addTo = function(e, t) {
1939
+ return e.addHandler(t, this), this;
1940
+ };
1941
+ var bn = { Events: x }, xn = P.touch ? "touchstart mousedown" : "mousedown", Sn = le.extend({
1942
+ options: { clickTolerance: 3 },
1943
+ initialize: function(e, t, n, r) {
1944
+ p(this, r), this._element = e, this._dragStartTarget = t || e, this._preventOutline = n;
1945
+ },
1946
+ enable: function() {
1947
+ this._enabled ||= (H(this._dragStartTarget, xn, this._onDown, this), !0);
1948
+ },
1949
+ disable: function() {
1950
+ this._enabled && (Sn._dragging === this && this.finishDrag(!0), W(this._dragStartTarget, xn, this._onDown, this), this._enabled = !1, this._moved = !1);
1951
+ },
1952
+ _onDown: function(e) {
1953
+ if (this._enabled && (this._moved = !1, !kt(this._element, "leaflet-zoom-anim"))) {
1954
+ if (e.touches && e.touches.length !== 1) {
1955
+ Sn._dragging === this && this.finishDrag();
1956
+ return;
1957
+ }
1958
+ 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)) {
1959
+ this.fire("down");
1960
+ var t = e.touches ? e.touches[0] : e, n = Kt(this._element);
1961
+ this._startPoint = new S(t.clientX, t.clientY), this._startPos = Ft(this._element), this._parentScale = qt(n);
1962
+ var r = e.type === "mousedown";
1963
+ H(document, r ? "mousemove" : "touchmove", this._onMove, this), H(document, r ? "mouseup" : "touchend touchcancel", this._onUp, this);
1964
+ }
1965
+ }
1966
+ },
1967
+ _onMove: function(e) {
1968
+ if (this._enabled) {
1969
+ if (e.touches && e.touches.length > 1) {
1970
+ this._moved = !0;
1971
+ return;
1972
+ }
1973
+ var t = e.touches && e.touches.length === 1 ? e.touches[0] : e, n = new S(t.clientX, t.clientY)._subtract(this._startPoint);
1974
+ !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());
1975
+ }
1976
+ },
1977
+ _updatePosition: function() {
1978
+ var e = { originalEvent: this._lastEvent };
1979
+ this.fire("predrag", e), V(this._element, this._newPos), this.fire("drag", e);
1980
+ },
1981
+ _onUp: function() {
1982
+ this._enabled && this.finishDrag();
1983
+ },
1984
+ finishDrag: function(e) {
1985
+ 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();
1986
+ var t = this._moved && this._moving;
1987
+ this._moving = !1, Sn._dragging = !1, t && this.fire("dragend", {
1988
+ noInertia: e,
1989
+ distance: this._newPos.distanceTo(this._startPos)
1990
+ });
1991
+ }
1992
+ });
1993
+ function Cn(e, t, n) {
1994
+ var r, i = [
1995
+ 1,
1996
+ 4,
1997
+ 2,
1998
+ 8
1999
+ ], a, o, s, c, l, u, d, f;
2000
+ for (a = 0, u = e.length; a < u; a++) e[a]._code = In(e[a], t);
2001
+ for (s = 0; s < 4; s++) {
2002
+ 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));
2003
+ e = r;
2004
+ }
2005
+ return e;
2006
+ }
2007
+ function wn(e, t) {
2008
+ var n, r, i, a, o, s, c, l, u;
2009
+ if (!e || e.length === 0) throw Error("latlngs not passed");
2010
+ Y(e) || (console.warn("latlngs are not flat! Only the first ring will be used"), e = e[0]);
2011
+ var d = k([0, 0]), f = D(e);
2012
+ f.getNorthWest().distanceTo(f.getSouthWest()) * f.getNorthEast().distanceTo(f.getNorthWest()) < 1700 && (d = Tn(e));
2013
+ var p = e.length, m = [];
2014
+ for (n = 0; n < p; n++) {
2015
+ var h = k(e[n]);
2016
+ m.push(t.project(k([h.lat - d.lat, h.lng - d.lng])));
2017
+ }
2018
+ 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;
2019
+ u = s === 0 ? m[0] : [c / s, l / s];
2020
+ var g = t.unproject(C(u));
2021
+ return k([g.lat + d.lat, g.lng + d.lng]);
2022
+ }
2023
+ function Tn(e) {
2024
+ for (var t = 0, n = 0, r = 0, i = 0; i < e.length; i++) {
2025
+ var a = k(e[i]);
2026
+ t += a.lat, n += a.lng, r++;
2027
+ }
2028
+ return k([t / r, n / r]);
2029
+ }
2030
+ var En = {
2031
+ __proto__: null,
2032
+ clipPolygon: Cn,
2033
+ polygonCenter: wn,
2034
+ centroid: Tn
2035
+ };
2036
+ function Dn(e, t) {
2037
+ if (!t || !e.length) return e.slice();
2038
+ var n = t * t;
2039
+ return e = Mn(e, n), e = An(e, n), e;
2040
+ }
2041
+ function On(e, t, n) {
2042
+ return Math.sqrt(Rn(e, t, n, !0));
2043
+ }
2044
+ function kn(e, t, n) {
2045
+ return Rn(e, t, n);
2046
+ }
2047
+ function An(e, t) {
2048
+ var n = e.length, r = new (typeof Uint8Array < "u" ? Uint8Array : Array)(n);
2049
+ r[0] = r[n - 1] = 1, jn(e, r, t, 0, n - 1);
2050
+ var i, a = [];
2051
+ for (i = 0; i < n; i++) r[i] && a.push(e[i]);
2052
+ return a;
2053
+ }
2054
+ function jn(e, t, n, r, i) {
2055
+ var a = 0, o, s, c;
2056
+ for (s = r + 1; s <= i - 1; s++) c = Rn(e[s], e[r], e[i], !0), c > a && (o = s, a = c);
2057
+ a > n && (t[o] = 1, jn(e, t, n, r, o), jn(e, t, n, o, i));
2058
+ }
2059
+ function Mn(e, t) {
2060
+ 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);
2061
+ return i < a - 1 && n.push(e[a - 1]), n;
2062
+ }
2063
+ var Nn;
2064
+ function Pn(e, t, n, r, i) {
2065
+ var a = r ? Nn : In(e, n), o = In(t, n), s, c, l;
2066
+ for (Nn = o;;) {
2067
+ if (!(a | o)) return [e, t];
2068
+ if (a & o) return !1;
2069
+ s = a || o, c = Fn(e, t, s, n, i), l = In(c, n), s === a ? (e = c, a = l) : (t = c, o = l);
2070
+ }
2071
+ }
2072
+ function Fn(e, t, n, r, i) {
2073
+ var a = t.x - e.x, o = t.y - e.y, s = r.min, c = r.max, l, u;
2074
+ 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);
2075
+ }
2076
+ function In(e, t) {
2077
+ var n = 0;
2078
+ 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;
2079
+ }
2080
+ function Ln(e, t) {
2081
+ var n = t.x - e.x, r = t.y - e.y;
2082
+ return n * n + r * r;
2083
+ }
2084
+ function Rn(e, t, n, r) {
2085
+ var i = t.x, a = t.y, o = n.x - i, s = n.y - a, c = o * o + s * s, l;
2086
+ 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);
2087
+ }
2088
+ function Y(e) {
2089
+ return !_(e[0]) || typeof e[0][0] != "object" && e[0][0] !== void 0;
2090
+ }
2091
+ function zn(e) {
2092
+ return console.warn("Deprecated use of _flat, please use L.LineUtil.isFlat instead."), Y(e);
2093
+ }
2094
+ function Bn(e, t) {
2095
+ var n, r, i, a, o, s, c, l;
2096
+ if (!e || e.length === 0) throw Error("latlngs not passed");
2097
+ Y(e) || (console.warn("latlngs are not flat! Only the first ring will be used"), e = e[0]);
2098
+ var u = k([0, 0]), d = D(e);
2099
+ d.getNorthWest().distanceTo(d.getSouthWest()) * d.getNorthEast().distanceTo(d.getNorthWest()) < 1700 && (u = Tn(e));
2100
+ var f = e.length, p = [];
2101
+ for (n = 0; n < f; n++) {
2102
+ var m = k(e[n]);
2103
+ p.push(t.project(k([m.lat - u.lat, m.lng - u.lng])));
2104
+ }
2105
+ for (n = 0, r = 0; n < f - 1; n++) r += p[n].distanceTo(p[n + 1]) / 2;
2106
+ if (r === 0) l = p[0];
2107
+ 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) {
2108
+ c = (a - r) / i, l = [s.x - c * (s.x - o.x), s.y - c * (s.y - o.y)];
2109
+ break;
2110
+ }
2111
+ var h = t.unproject(C(l));
2112
+ return k([h.lat + u.lat, h.lng + u.lng]);
2113
+ }
2114
+ var Vn = {
2115
+ __proto__: null,
2116
+ simplify: Dn,
2117
+ pointToSegmentDistance: On,
2118
+ closestPointOnSegment: kn,
2119
+ clipSegment: Pn,
2120
+ _getEdgeIntersection: Fn,
2121
+ _getBitCode: In,
2122
+ _sqClosestPointOnSegment: Rn,
2123
+ isFlat: Y,
2124
+ _flat: zn,
2125
+ polylineCenter: Bn
2126
+ }, Hn = {
2127
+ project: function(e) {
2128
+ return new S(e.lng, e.lat);
2129
+ },
2130
+ unproject: function(e) {
2131
+ return new O(e.y, e.x);
2132
+ },
2133
+ bounds: new w([-180, -90], [180, 90])
2134
+ }, Un = {
2135
+ R: 6378137,
2136
+ R_MINOR: 6356752.314245179,
2137
+ bounds: new w([-20037508.34279, -15496570.73972], [20037508.34279, 18764656.23138]),
2138
+ project: function(e) {
2139
+ 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);
2140
+ return r = -n * Math.log(Math.max(s, 1e-10)), new S(e.lng * t * n, r);
2141
+ },
2142
+ unproject: function(e) {
2143
+ 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;
2144
+ return new O(o * t, e.x * t / n);
2145
+ }
2146
+ }, Wn = {
2147
+ __proto__: null,
2148
+ LonLat: Hn,
2149
+ Mercator: Un,
2150
+ SphericalMercator: fe
2151
+ }, Gn = n({}, j, {
2152
+ code: "EPSG:3395",
2153
+ projection: Un,
2154
+ transformation: function() {
2155
+ var e = .5 / (Math.PI * Un.R);
2156
+ return me(e, .5, -e, .5);
2157
+ }()
2158
+ }), Kn = n({}, j, {
2159
+ code: "EPSG:4326",
2160
+ projection: Hn,
2161
+ transformation: me(1 / 180, 1, -1 / 180, .5)
2162
+ }), qn = n({}, A, {
2163
+ projection: Hn,
2164
+ transformation: me(1, 0, -1, 0),
2165
+ scale: function(e) {
2166
+ return 2 ** e;
2167
+ },
2168
+ zoom: function(e) {
2169
+ return Math.log(e) / Math.LN2;
2170
+ },
2171
+ distance: function(e, t) {
2172
+ var n = t.lng - e.lng, r = t.lat - e.lat;
2173
+ return Math.sqrt(n * n + r * r);
2174
+ },
2175
+ infinite: !0
2176
+ });
2177
+ A.Earth = j, A.EPSG3395 = Gn, A.EPSG3857 = he, A.EPSG900913 = ge, A.EPSG4326 = Kn, A.Simple = qn;
2178
+ var X = le.extend({
2179
+ options: {
2180
+ pane: "overlayPane",
2181
+ attribution: null,
2182
+ bubblingMouseEvents: !0
2183
+ },
2184
+ addTo: function(e) {
2185
+ return e.addLayer(this), this;
2186
+ },
2187
+ remove: function() {
2188
+ return this.removeFrom(this._map || this._mapToAdd);
2189
+ },
2190
+ removeFrom: function(e) {
2191
+ return e && e.removeLayer(this), this;
2192
+ },
2193
+ getPane: function(e) {
2194
+ return this._map.getPane(e ? this.options[e] || e : this.options.pane);
2195
+ },
2196
+ addInteractiveTarget: function(e) {
2197
+ return this._map._targets[o(e)] = this, this;
2198
+ },
2199
+ removeInteractiveTarget: function(e) {
2200
+ return delete this._map._targets[o(e)], this;
2201
+ },
2202
+ getAttribution: function() {
2203
+ return this.options.attribution;
2204
+ },
2205
+ _layerAdd: function(e) {
2206
+ var t = e.target;
2207
+ if (t.hasLayer(this)) {
2208
+ if (this._map = t, this._zoomAnimated = t._zoomAnimated, this.getEvents) {
2209
+ var n = this.getEvents();
2210
+ t.on(n, this), this.once("remove", function() {
2211
+ t.off(n, this);
2212
+ }, this);
2213
+ }
2214
+ this.onAdd(t), this.fire("add"), t.fire("layeradd", { layer: this });
2215
+ }
2216
+ }
2217
+ });
2218
+ K.include({
2219
+ addLayer: function(e) {
2220
+ if (!e._layerAdd) throw Error("The provided object is not a Layer.");
2221
+ var t = o(e);
2222
+ return this._layers[t] ? this : (this._layers[t] = e, e._mapToAdd = this, e.beforeAdd && e.beforeAdd(this), this.whenReady(e._layerAdd, e), this);
2223
+ },
2224
+ removeLayer: function(e) {
2225
+ var t = o(e);
2226
+ 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;
2227
+ },
2228
+ hasLayer: function(e) {
2229
+ return o(e) in this._layers;
2230
+ },
2231
+ eachLayer: function(e, t) {
2232
+ for (var n in this._layers) e.call(t, this._layers[n]);
2233
+ return this;
2234
+ },
2235
+ _addLayers: function(e) {
2236
+ e = e ? _(e) ? e : [e] : [];
2237
+ for (var t = 0, n = e.length; t < n; t++) this.addLayer(e[t]);
2238
+ },
2239
+ _addZoomLimit: function(e) {
2240
+ (!isNaN(e.options.maxZoom) || !isNaN(e.options.minZoom)) && (this._zoomBoundLayers[o(e)] = e, this._updateZoomLevels());
2241
+ },
2242
+ _removeZoomLimit: function(e) {
2243
+ var t = o(e);
2244
+ this._zoomBoundLayers[t] && (delete this._zoomBoundLayers[t], this._updateZoomLevels());
2245
+ },
2246
+ _updateZoomLevels: function() {
2247
+ var e = Infinity, t = -Infinity, n = this._getZoomSpan();
2248
+ for (var r in this._zoomBoundLayers) {
2249
+ var i = this._zoomBoundLayers[r].options;
2250
+ e = i.minZoom === void 0 ? e : Math.min(e, i.minZoom), t = i.maxZoom === void 0 ? t : Math.max(t, i.maxZoom);
2251
+ }
2252
+ 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);
2253
+ }
2254
+ });
2255
+ var Jn = X.extend({
2256
+ initialize: function(e, t) {
2257
+ p(this, t), this._layers = {};
2258
+ var n, r;
2259
+ if (e) for (n = 0, r = e.length; n < r; n++) this.addLayer(e[n]);
2260
+ },
2261
+ addLayer: function(e) {
2262
+ var t = this.getLayerId(e);
2263
+ return this._layers[t] = e, this._map && this._map.addLayer(e), this;
2264
+ },
2265
+ removeLayer: function(e) {
2266
+ var t = e in this._layers ? e : this.getLayerId(e);
2267
+ return this._map && this._layers[t] && this._map.removeLayer(this._layers[t]), delete this._layers[t], this;
2268
+ },
2269
+ hasLayer: function(e) {
2270
+ return (typeof e == "number" ? e : this.getLayerId(e)) in this._layers;
2271
+ },
2272
+ clearLayers: function() {
2273
+ return this.eachLayer(this.removeLayer, this);
2274
+ },
2275
+ invoke: function(e) {
2276
+ var t = Array.prototype.slice.call(arguments, 1), n, r;
2277
+ for (n in this._layers) r = this._layers[n], r[e] && r[e].apply(r, t);
2278
+ return this;
2279
+ },
2280
+ onAdd: function(e) {
2281
+ this.eachLayer(e.addLayer, e);
2282
+ },
2283
+ onRemove: function(e) {
2284
+ this.eachLayer(e.removeLayer, e);
2285
+ },
2286
+ eachLayer: function(e, t) {
2287
+ for (var n in this._layers) e.call(t, this._layers[n]);
2288
+ return this;
2289
+ },
2290
+ getLayer: function(e) {
2291
+ return this._layers[e];
2292
+ },
2293
+ getLayers: function() {
2294
+ var e = [];
2295
+ return this.eachLayer(e.push, e), e;
2296
+ },
2297
+ setZIndex: function(e) {
2298
+ return this.invoke("setZIndex", e);
2299
+ },
2300
+ getLayerId: function(e) {
2301
+ return o(e);
2302
+ }
2303
+ }), Yn = function(e, t) {
2304
+ return new Jn(e, t);
2305
+ }, Z = Jn.extend({
2306
+ addLayer: function(e) {
2307
+ return this.hasLayer(e) ? this : (e.addEventParent(this), Jn.prototype.addLayer.call(this, e), this.fire("layeradd", { layer: e }));
2308
+ },
2309
+ removeLayer: function(e) {
2310
+ 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;
2311
+ },
2312
+ setStyle: function(e) {
2313
+ return this.invoke("setStyle", e);
2314
+ },
2315
+ bringToFront: function() {
2316
+ return this.invoke("bringToFront");
2317
+ },
2318
+ bringToBack: function() {
2319
+ return this.invoke("bringToBack");
2320
+ },
2321
+ getBounds: function() {
2322
+ var e = new E();
2323
+ for (var t in this._layers) {
2324
+ var n = this._layers[t];
2325
+ e.extend(n.getBounds ? n.getBounds() : n.getLatLng());
2326
+ }
2327
+ return e;
2328
+ }
2329
+ }), Xn = function(e, t) {
2330
+ return new Z(e, t);
2331
+ }, Zn = b.extend({
2332
+ options: {
2333
+ popupAnchor: [0, 0],
2334
+ tooltipAnchor: [0, 0],
2335
+ crossOrigin: !1
2336
+ },
2337
+ initialize: function(e) {
2338
+ p(this, e);
2339
+ },
2340
+ createIcon: function(e) {
2341
+ return this._createIcon("icon", e);
2342
+ },
2343
+ createShadow: function(e) {
2344
+ return this._createIcon("shadow", e);
2345
+ },
2346
+ _createIcon: function(e, t) {
2347
+ var n = this._getIconUrl(e);
2348
+ if (!n) {
2349
+ if (e === "icon") throw Error("iconUrl not set in Icon options (see the docs).");
2350
+ return null;
2351
+ }
2352
+ var r = this._createImg(n, t && t.tagName === "IMG" ? t : null);
2353
+ return this._setIconStyles(r, e), (this.options.crossOrigin || this.options.crossOrigin === "") && (r.crossOrigin = this.options.crossOrigin === !0 ? "" : this.options.crossOrigin), r;
2354
+ },
2355
+ _setIconStyles: function(e, t) {
2356
+ var n = this.options, r = n[t + "Size"];
2357
+ typeof r == "number" && (r = [r, r]);
2358
+ var i = C(r), a = C(t === "shadow" && n.shadowAnchor || n.iconAnchor || i && i.divideBy(2, !0));
2359
+ 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");
2360
+ },
2361
+ _createImg: function(e, t) {
2362
+ return t ||= document.createElement("img"), t.src = e, t;
2363
+ },
2364
+ _getIconUrl: function(e) {
2365
+ return P.retina && this.options[e + "RetinaUrl"] || this.options[e + "Url"];
2366
+ }
2367
+ });
2368
+ function Qn(e) {
2369
+ return new Zn(e);
2370
+ }
2371
+ var $n = Zn.extend({
2372
+ options: {
2373
+ iconUrl: "marker-icon.png",
2374
+ iconRetinaUrl: "marker-icon-2x.png",
2375
+ shadowUrl: "marker-shadow.png",
2376
+ iconSize: [25, 41],
2377
+ iconAnchor: [12, 41],
2378
+ popupAnchor: [1, -34],
2379
+ tooltipAnchor: [16, -28],
2380
+ shadowSize: [41, 41]
2381
+ },
2382
+ _getIconUrl: function(e) {
2383
+ return typeof $n.imagePath != "string" && ($n.imagePath = this._detectIconPath()), (this.options.imagePath || $n.imagePath) + Zn.prototype._getIconUrl.call(this, e);
2384
+ },
2385
+ _stripUrl: function(e) {
2386
+ var t = function(e, t, n) {
2387
+ var r = t.exec(e);
2388
+ return r && r[n];
2389
+ };
2390
+ return e = t(e, /^url\((['"])?(.+)\1\)$/, 2), e && t(e, /^(.*)marker-icon\.png$/, 1);
2391
+ },
2392
+ _detectIconPath: function() {
2393
+ var e = F("div", "leaflet-default-icon-path", document.body), t = Tt(e, "background-image") || Tt(e, "backgroundImage");
2394
+ if (document.body.removeChild(e), t = this._stripUrl(t), t) return t;
2395
+ var n = document.querySelector("link[href$=\"leaflet.css\"]");
2396
+ return n ? n.href.substring(0, n.href.length - 11 - 1) : "";
2397
+ }
2398
+ }), er = J.extend({
2399
+ initialize: function(e) {
2400
+ this._marker = e;
2401
+ },
2402
+ addHooks: function() {
2403
+ var e = this._marker._icon;
2404
+ this._draggable ||= new Sn(e, e, !0), this._draggable.on({
2405
+ dragstart: this._onDragStart,
2406
+ predrag: this._onPreDrag,
2407
+ drag: this._onDrag,
2408
+ dragend: this._onDragEnd
2409
+ }, this).enable(), R(e, "leaflet-marker-draggable");
2410
+ },
2411
+ removeHooks: function() {
2412
+ this._draggable.off({
2413
+ dragstart: this._onDragStart,
2414
+ predrag: this._onPreDrag,
2415
+ drag: this._onDrag,
2416
+ dragend: this._onDragEnd
2417
+ }, this).disable(), this._marker._icon && z(this._marker._icon, "leaflet-marker-draggable");
2418
+ },
2419
+ moved: function() {
2420
+ return this._draggable && this._draggable._moved;
2421
+ },
2422
+ _adjustPan: function(e) {
2423
+ 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));
2424
+ if (!c.contains(a)) {
2425
+ 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);
2426
+ 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));
2427
+ }
2428
+ },
2429
+ _onDragStart: function() {
2430
+ this._oldLatLng = this._marker.getLatLng(), this._marker.closePopup && this._marker.closePopup(), this._marker.fire("movestart").fire("dragstart");
2431
+ },
2432
+ _onPreDrag: function(e) {
2433
+ this._marker.options.autoPan && (y(this._panRequest), this._panRequest = v(this._adjustPan.bind(this, e)));
2434
+ },
2435
+ _onDrag: function(e) {
2436
+ var t = this._marker, n = t._shadow, r = Ft(t._icon), i = t._map.layerPointToLatLng(r);
2437
+ n && V(n, r), t._latlng = i, e.latlng = i, e.oldLatLng = this._oldLatLng, t.fire("move", e).fire("drag", e);
2438
+ },
2439
+ _onDragEnd: function(e) {
2440
+ y(this._panRequest), delete this._oldLatLng, this._marker.fire("moveend").fire("dragend", e);
2441
+ }
2442
+ }), tr = X.extend({
2443
+ options: {
2444
+ icon: new $n(),
2445
+ interactive: !0,
2446
+ keyboard: !0,
2447
+ title: "",
2448
+ alt: "Marker",
2449
+ zIndexOffset: 0,
2450
+ opacity: 1,
2451
+ riseOnHover: !1,
2452
+ riseOffset: 250,
2453
+ pane: "markerPane",
2454
+ shadowPane: "shadowPane",
2455
+ bubblingMouseEvents: !1,
2456
+ autoPanOnFocus: !0,
2457
+ draggable: !1,
2458
+ autoPan: !1,
2459
+ autoPanPadding: [50, 50],
2460
+ autoPanSpeed: 10
2461
+ },
2462
+ initialize: function(e, t) {
2463
+ p(this, t), this._latlng = k(e);
2464
+ },
2465
+ onAdd: function(e) {
2466
+ this._zoomAnimated = this._zoomAnimated && e.options.markerZoomAnimation, this._zoomAnimated && e.on("zoomanim", this._animateZoom, this), this._initIcon(), this.update();
2467
+ },
2468
+ onRemove: function(e) {
2469
+ 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();
2470
+ },
2471
+ getEvents: function() {
2472
+ return {
2473
+ zoom: this.update,
2474
+ viewreset: this.update
2475
+ };
2476
+ },
2477
+ getLatLng: function() {
2478
+ return this._latlng;
2479
+ },
2480
+ setLatLng: function(e) {
2481
+ var t = this._latlng;
2482
+ return this._latlng = k(e), this.update(), this.fire("move", {
2483
+ oldLatLng: t,
2484
+ latlng: this._latlng
2485
+ });
2486
+ },
2487
+ setZIndexOffset: function(e) {
2488
+ return this.options.zIndexOffset = e, this.update();
2489
+ },
2490
+ getIcon: function() {
2491
+ return this.options.icon;
2492
+ },
2493
+ setIcon: function(e) {
2494
+ return this.options.icon = e, this._map && (this._initIcon(), this.update()), this._popup && this.bindPopup(this._popup, this._popup.options), this;
2495
+ },
2496
+ getElement: function() {
2497
+ return this._icon;
2498
+ },
2499
+ update: function() {
2500
+ if (this._icon && this._map) {
2501
+ var e = this._map.latLngToLayerPoint(this._latlng).round();
2502
+ this._setPos(e);
2503
+ }
2504
+ return this;
2505
+ },
2506
+ _initIcon: function() {
2507
+ var e = this.options, t = "leaflet-zoom-" + (this._zoomAnimated ? "animated" : "hide"), n = e.icon.createIcon(this._icon), r = !1;
2508
+ 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({
2509
+ mouseover: this._bringToFront,
2510
+ mouseout: this._resetZIndex
2511
+ }), this.options.autoPanOnFocus && H(n, "focus", this._panOnFocus, this);
2512
+ var i = e.icon.createShadow(this._shadow), a = !1;
2513
+ 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);
2514
+ },
2515
+ _removeIcon: function() {
2516
+ this.options.riseOnHover && this.off({
2517
+ mouseover: this._bringToFront,
2518
+ mouseout: this._resetZIndex
2519
+ }), this.options.autoPanOnFocus && W(this._icon, "focus", this._panOnFocus, this), I(this._icon), this.removeInteractiveTarget(this._icon), this._icon = null;
2520
+ },
2521
+ _removeShadow: function() {
2522
+ this._shadow && I(this._shadow), this._shadow = null;
2523
+ },
2524
+ _setPos: function(e) {
2525
+ this._icon && V(this._icon, e), this._shadow && V(this._shadow, e), this._zIndex = e.y + this.options.zIndexOffset, this._resetZIndex();
2526
+ },
2527
+ _updateZIndex: function(e) {
2528
+ this._icon && (this._icon.style.zIndex = this._zIndex + e);
2529
+ },
2530
+ _animateZoom: function(e) {
2531
+ var t = this._map._latLngToNewLayerPoint(this._latlng, e.zoom, e.center).round();
2532
+ this._setPos(t);
2533
+ },
2534
+ _initInteraction: function() {
2535
+ if (this.options.interactive && (R(this._icon, "leaflet-interactive"), this.addInteractiveTarget(this._icon), er)) {
2536
+ var e = this.options.draggable;
2537
+ this.dragging && (e = this.dragging.enabled(), this.dragging.disable()), this.dragging = new er(this), e && this.dragging.enable();
2538
+ }
2539
+ },
2540
+ setOpacity: function(e) {
2541
+ return this.options.opacity = e, this._map && this._updateOpacity(), this;
2542
+ },
2543
+ _updateOpacity: function() {
2544
+ var e = this.options.opacity;
2545
+ this._icon && B(this._icon, e), this._shadow && B(this._shadow, e);
2546
+ },
2547
+ _bringToFront: function() {
2548
+ this._updateZIndex(this.options.riseOffset);
2549
+ },
2550
+ _resetZIndex: function() {
2551
+ this._updateZIndex(0);
2552
+ },
2553
+ _panOnFocus: function() {
2554
+ var e = this._map;
2555
+ if (e) {
2556
+ var t = this.options.icon.options, n = t.iconSize ? C(t.iconSize) : C(0, 0), r = t.iconAnchor ? C(t.iconAnchor) : C(0, 0);
2557
+ e.panInside(this._latlng, {
2558
+ paddingTopLeft: r,
2559
+ paddingBottomRight: n.subtract(r)
2560
+ });
2561
+ }
2562
+ },
2563
+ _getPopupAnchor: function() {
2564
+ return this.options.icon.options.popupAnchor;
2565
+ },
2566
+ _getTooltipAnchor: function() {
2567
+ return this.options.icon.options.tooltipAnchor;
2568
+ }
2569
+ });
2570
+ function nr(e, t) {
2571
+ return new tr(e, t);
2572
+ }
2573
+ var rr = X.extend({
2574
+ options: {
2575
+ stroke: !0,
2576
+ color: "#3388ff",
2577
+ weight: 3,
2578
+ opacity: 1,
2579
+ lineCap: "round",
2580
+ lineJoin: "round",
2581
+ dashArray: null,
2582
+ dashOffset: null,
2583
+ fill: !1,
2584
+ fillColor: null,
2585
+ fillOpacity: .2,
2586
+ fillRule: "evenodd",
2587
+ interactive: !0,
2588
+ bubblingMouseEvents: !0
2589
+ },
2590
+ beforeAdd: function(e) {
2591
+ this._renderer = e.getRenderer(this);
2592
+ },
2593
+ onAdd: function() {
2594
+ this._renderer._initPath(this), this._reset(), this._renderer._addPath(this);
2595
+ },
2596
+ onRemove: function() {
2597
+ this._renderer._removePath(this);
2598
+ },
2599
+ redraw: function() {
2600
+ return this._map && this._renderer._updatePath(this), this;
2601
+ },
2602
+ setStyle: function(e) {
2603
+ return p(this, e), this._renderer && (this._renderer._updateStyle(this), this.options.stroke && e && Object.prototype.hasOwnProperty.call(e, "weight") && this._updateBounds()), this;
2604
+ },
2605
+ bringToFront: function() {
2606
+ return this._renderer && this._renderer._bringToFront(this), this;
2607
+ },
2608
+ bringToBack: function() {
2609
+ return this._renderer && this._renderer._bringToBack(this), this;
2610
+ },
2611
+ getElement: function() {
2612
+ return this._path;
2613
+ },
2614
+ _reset: function() {
2615
+ this._project(), this._update();
2616
+ },
2617
+ _clickTolerance: function() {
2618
+ return (this.options.stroke ? this.options.weight / 2 : 0) + (this._renderer.options.tolerance || 0);
2619
+ }
2620
+ }), ir = rr.extend({
2621
+ options: {
2622
+ fill: !0,
2623
+ radius: 10
2624
+ },
2625
+ initialize: function(e, t) {
2626
+ p(this, t), this._latlng = k(e), this._radius = this.options.radius;
2627
+ },
2628
+ setLatLng: function(e) {
2629
+ var t = this._latlng;
2630
+ return this._latlng = k(e), this.redraw(), this.fire("move", {
2631
+ oldLatLng: t,
2632
+ latlng: this._latlng
2633
+ });
2634
+ },
2635
+ getLatLng: function() {
2636
+ return this._latlng;
2637
+ },
2638
+ setRadius: function(e) {
2639
+ return this.options.radius = this._radius = e, this.redraw();
2640
+ },
2641
+ getRadius: function() {
2642
+ return this._radius;
2643
+ },
2644
+ setStyle: function(e) {
2645
+ var t = e && e.radius || this._radius;
2646
+ return rr.prototype.setStyle.call(this, e), this.setRadius(t), this;
2647
+ },
2648
+ _project: function() {
2649
+ this._point = this._map.latLngToLayerPoint(this._latlng), this._updateBounds();
2650
+ },
2651
+ _updateBounds: function() {
2652
+ var e = this._radius, t = this._radiusY || e, n = this._clickTolerance(), r = [e + n, t + n];
2653
+ this._pxBounds = new w(this._point.subtract(r), this._point.add(r));
2654
+ },
2655
+ _update: function() {
2656
+ this._map && this._updatePath();
2657
+ },
2658
+ _updatePath: function() {
2659
+ this._renderer._updateCircle(this);
2660
+ },
2661
+ _empty: function() {
2662
+ return this._radius && !this._renderer._bounds.intersects(this._pxBounds);
2663
+ },
2664
+ _containsPoint: function(e) {
2665
+ return e.distanceTo(this._point) <= this._radius + this._clickTolerance();
2666
+ }
2667
+ });
2668
+ function ar(e, t) {
2669
+ return new ir(e, t);
2670
+ }
2671
+ var or = ir.extend({
2672
+ initialize: function(e, t, r) {
2673
+ 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");
2674
+ this._mRadius = this.options.radius;
2675
+ },
2676
+ setRadius: function(e) {
2677
+ return this._mRadius = e, this.redraw();
2678
+ },
2679
+ getRadius: function() {
2680
+ return this._mRadius;
2681
+ },
2682
+ getBounds: function() {
2683
+ var e = [this._radius, this._radiusY || this._radius];
2684
+ return new E(this._map.layerPointToLatLng(this._point.subtract(e)), this._map.layerPointToLatLng(this._point.add(e)));
2685
+ },
2686
+ setStyle: rr.prototype.setStyle,
2687
+ _project: function() {
2688
+ var e = this._latlng.lng, t = this._latlng.lat, n = this._map, r = n.options.crs;
2689
+ if (r.distance === j.distance) {
2690
+ 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;
2691
+ (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;
2692
+ } else {
2693
+ var d = r.unproject(r.project(this._latlng).subtract([this._mRadius, 0]));
2694
+ this._point = n.latLngToLayerPoint(this._latlng), this._radius = this._point.x - n.latLngToLayerPoint(d).x;
2695
+ }
2696
+ this._updateBounds();
2697
+ }
2698
+ });
2699
+ function sr(e, t, n) {
2700
+ return new or(e, t, n);
2701
+ }
2702
+ var Q = rr.extend({
2703
+ options: {
2704
+ smoothFactor: 1,
2705
+ noClip: !1
2706
+ },
2707
+ initialize: function(e, t) {
2708
+ p(this, t), this._setLatLngs(e);
2709
+ },
2710
+ getLatLngs: function() {
2711
+ return this._latlngs;
2712
+ },
2713
+ setLatLngs: function(e) {
2714
+ return this._setLatLngs(e), this.redraw();
2715
+ },
2716
+ isEmpty: function() {
2717
+ return !this._latlngs.length;
2718
+ },
2719
+ closestLayerPoint: function(e) {
2720
+ 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++) {
2721
+ i = c[l - 1], a = c[l];
2722
+ var d = r(e, i, a, !0);
2723
+ d < t && (t = d, n = r(e, i, a));
2724
+ }
2725
+ return n && (n.distance = Math.sqrt(t)), n;
2726
+ },
2727
+ getCenter: function() {
2728
+ if (!this._map) throw Error("Must add layer to map before using getCenter()");
2729
+ return Bn(this._defaultShape(), this._map.options.crs);
2730
+ },
2731
+ getBounds: function() {
2732
+ return this._bounds;
2733
+ },
2734
+ addLatLng: function(e, t) {
2735
+ return t ||= this._defaultShape(), e = k(e), t.push(e), this._bounds.extend(e), this.redraw();
2736
+ },
2737
+ _setLatLngs: function(e) {
2738
+ this._bounds = new E(), this._latlngs = this._convertLatLngs(e);
2739
+ },
2740
+ _defaultShape: function() {
2741
+ return Y(this._latlngs) ? this._latlngs : this._latlngs[0];
2742
+ },
2743
+ _convertLatLngs: function(e) {
2744
+ 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]);
2745
+ return t;
2746
+ },
2747
+ _project: function() {
2748
+ var e = new w();
2749
+ this._rings = [], this._projectLatlngs(this._latlngs, this._rings, e), this._bounds.isValid() && e.isValid() && (this._rawPxBounds = e, this._updateBounds());
2750
+ },
2751
+ _updateBounds: function() {
2752
+ var e = this._clickTolerance(), t = new S(e, e);
2753
+ this._rawPxBounds && (this._pxBounds = new w([this._rawPxBounds.min.subtract(t), this._rawPxBounds.max.add(t)]));
2754
+ },
2755
+ _projectLatlngs: function(e, t, n) {
2756
+ var r = e[0] instanceof O, i = e.length, a, o;
2757
+ if (r) {
2758
+ for (o = [], a = 0; a < i; a++) o[a] = this._map.latLngToLayerPoint(e[a]), n.extend(o[a]);
2759
+ t.push(o);
2760
+ } else for (a = 0; a < i; a++) this._projectLatlngs(e[a], t, n);
2761
+ },
2762
+ _clipPoints: function() {
2763
+ var e = this._renderer._bounds;
2764
+ if (this._parts = [], !(!this._pxBounds || !this._pxBounds.intersects(e))) {
2765
+ if (this.options.noClip) {
2766
+ this._parts = this._rings;
2767
+ return;
2768
+ }
2769
+ var t = this._parts, n, r, i, a, o, s, c;
2770
+ for (n = 0, i = 0, a = this._rings.length; 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++));
2771
+ }
2772
+ },
2773
+ _simplifyPoints: function() {
2774
+ for (var e = this._parts, t = this.options.smoothFactor, n = 0, r = e.length; n < r; n++) e[n] = Dn(e[n], t);
2775
+ },
2776
+ _update: function() {
2777
+ this._map && (this._clipPoints(), this._simplifyPoints(), this._updatePath());
2778
+ },
2779
+ _updatePath: function() {
2780
+ this._renderer._updatePoly(this);
2781
+ },
2782
+ _containsPoint: function(e, t) {
2783
+ var n, r, i, a, o, s, c = this._clickTolerance();
2784
+ if (!this._pxBounds || !this._pxBounds.contains(e)) return !1;
2785
+ 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;
2786
+ return !1;
2787
+ }
2788
+ });
2789
+ function cr(e, t) {
2790
+ return new Q(e, t);
2791
+ }
2792
+ Q._flat = zn;
2793
+ var lr = Q.extend({
2794
+ options: { fill: !0 },
2795
+ isEmpty: function() {
2796
+ return !this._latlngs.length || !this._latlngs[0].length;
2797
+ },
2798
+ getCenter: function() {
2799
+ if (!this._map) throw Error("Must add layer to map before using getCenter()");
2800
+ return wn(this._defaultShape(), this._map.options.crs);
2801
+ },
2802
+ _convertLatLngs: function(e) {
2803
+ var t = Q.prototype._convertLatLngs.call(this, e), n = t.length;
2804
+ return n >= 2 && t[0] instanceof O && t[0].equals(t[n - 1]) && t.pop(), t;
2805
+ },
2806
+ _setLatLngs: function(e) {
2807
+ Q.prototype._setLatLngs.call(this, e), Y(this._latlngs) && (this._latlngs = [this._latlngs]);
2808
+ },
2809
+ _defaultShape: function() {
2810
+ return Y(this._latlngs[0]) ? this._latlngs[0] : this._latlngs[0][0];
2811
+ },
2812
+ _clipPoints: function() {
2813
+ var e = this._renderer._bounds, t = this.options.weight, n = new S(t, t);
2814
+ if (e = new w(e.min.subtract(n), e.max.add(n)), this._parts = [], !(!this._pxBounds || !this._pxBounds.intersects(e))) {
2815
+ if (this.options.noClip) {
2816
+ this._parts = this._rings;
2817
+ return;
2818
+ }
2819
+ 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);
2820
+ }
2821
+ },
2822
+ _updatePath: function() {
2823
+ this._renderer._updatePoly(this, !0);
2824
+ },
2825
+ _containsPoint: function(e) {
2826
+ var t = !1, n, r, i, a, o, s, c, l;
2827
+ if (!this._pxBounds || !this._pxBounds.contains(e)) return !1;
2828
+ 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);
2829
+ return t || Q.prototype._containsPoint.call(this, e, !0);
2830
+ }
2831
+ });
2832
+ function ur(e, t) {
2833
+ return new lr(e, t);
2834
+ }
2835
+ var dr = Z.extend({
2836
+ initialize: function(e, t) {
2837
+ p(this, t), this._layers = {}, e && this.addData(e);
2838
+ },
2839
+ addData: function(e) {
2840
+ var t = _(e) ? e : e.features, n, r, i;
2841
+ if (t) {
2842
+ for (n = 0, r = t.length; n < r; n++) i = t[n], (i.geometries || i.geometry || i.features || i.coordinates) && this.addData(i);
2843
+ return this;
2844
+ }
2845
+ var a = this.options;
2846
+ if (a.filter && !a.filter(e)) return this;
2847
+ var o = fr(e, a);
2848
+ return o ? (o.feature = yr(e), o.defaultOptions = o.options, this.resetStyle(o), a.onEachFeature && a.onEachFeature(e, o), this.addLayer(o)) : this;
2849
+ },
2850
+ resetStyle: function(e) {
2851
+ return e === void 0 ? this.eachLayer(this.resetStyle, this) : (e.options = n({}, e.defaultOptions), this._setLayerStyle(e, this.options.style), this);
2852
+ },
2853
+ setStyle: function(e) {
2854
+ return this.eachLayer(function(t) {
2855
+ this._setLayerStyle(t, e);
2856
+ }, this);
2857
+ },
2858
+ _setLayerStyle: function(e, t) {
2859
+ e.setStyle && (typeof t == "function" && (t = t(e.feature)), e.setStyle(t));
2860
+ }
2861
+ });
2862
+ function fr(e, t) {
2863
+ 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;
2864
+ if (!r && !n) return null;
2865
+ switch (n.type) {
2866
+ case "Point": return s = o(r), pr(a, e, s, t);
2867
+ case "MultiPoint":
2868
+ for (l = 0, u = r.length; l < u; l++) s = o(r[l]), i.push(pr(a, e, s, t));
2869
+ return new Z(i);
2870
+ case "LineString":
2871
+ case "MultiLineString": return c = hr(r, n.type === "LineString" ? 0 : 1, o), new Q(c, t);
2872
+ case "Polygon":
2873
+ case "MultiPolygon": return c = hr(r, n.type === "Polygon" ? 1 : 2, o), new lr(c, t);
2874
+ case "GeometryCollection":
2875
+ for (l = 0, u = n.geometries.length; l < u; l++) {
2876
+ var d = fr({
2877
+ geometry: n.geometries[l],
2878
+ type: "Feature",
2879
+ properties: e.properties
2880
+ }, t);
2881
+ d && i.push(d);
2882
+ }
2883
+ return new Z(i);
2884
+ case "FeatureCollection":
2885
+ for (l = 0, u = n.features.length; l < u; l++) {
2886
+ var f = fr(n.features[l], t);
2887
+ f && i.push(f);
2888
+ }
2889
+ return new Z(i);
2890
+ default: throw Error("Invalid GeoJSON object.");
2891
+ }
2892
+ }
2893
+ function pr(e, t, n, r) {
2894
+ return e ? e(t, n) : new tr(n, r && r.markersInheritOptions && r);
2895
+ }
2896
+ function mr(e) {
2897
+ return new O(e[1], e[0], e[2]);
2898
+ }
2899
+ function hr(e, t, n) {
2900
+ 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);
2901
+ return r;
2902
+ }
2903
+ function gr(e, t) {
2904
+ return e = k(e), e.alt === void 0 ? [u(e.lng, t), u(e.lat, t)] : [
2905
+ u(e.lng, t),
2906
+ u(e.lat, t),
2907
+ u(e.alt, t)
2908
+ ];
2909
+ }
2910
+ function _r(e, t, n, r) {
2911
+ 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));
2912
+ return !t && n && i.length > 0 && i.push(i[0].slice()), i;
2913
+ }
2914
+ function vr(e, t) {
2915
+ return e.feature ? n({}, e.feature, { geometry: t }) : yr(t);
2916
+ }
2917
+ function yr(e) {
2918
+ return e.type === "Feature" || e.type === "FeatureCollection" ? e : {
2919
+ type: "Feature",
2920
+ properties: {},
2921
+ geometry: e
2922
+ };
2923
+ }
2924
+ var br = { toGeoJSON: function(e) {
2925
+ return vr(this, {
2926
+ type: "Point",
2927
+ coordinates: gr(this.getLatLng(), e)
2928
+ });
2929
+ } };
2930
+ tr.include(br), or.include(br), ir.include(br), Q.include({ toGeoJSON: function(e) {
2931
+ var t = !Y(this._latlngs), n = _r(this._latlngs, +!!t, !1, e);
2932
+ return vr(this, {
2933
+ type: (t ? "Multi" : "") + "LineString",
2934
+ coordinates: n
2935
+ });
2936
+ } }), lr.include({ toGeoJSON: function(e) {
2937
+ var t = !Y(this._latlngs), n = t && !Y(this._latlngs[0]), r = _r(this._latlngs, n ? 2 : +!!t, !0, e);
2938
+ return t || (r = [r]), vr(this, {
2939
+ type: (n ? "Multi" : "") + "Polygon",
2940
+ coordinates: r
2941
+ });
2942
+ } }), Jn.include({
2943
+ toMultiPoint: function(e) {
2944
+ var t = [];
2945
+ return this.eachLayer(function(n) {
2946
+ t.push(n.toGeoJSON(e).geometry.coordinates);
2947
+ }), vr(this, {
2948
+ type: "MultiPoint",
2949
+ coordinates: t
2950
+ });
2951
+ },
2952
+ toGeoJSON: function(e) {
2953
+ var t = this.feature && this.feature.geometry && this.feature.geometry.type;
2954
+ if (t === "MultiPoint") return this.toMultiPoint(e);
2955
+ var n = t === "GeometryCollection", r = [];
2956
+ return this.eachLayer(function(t) {
2957
+ if (t.toGeoJSON) {
2958
+ var i = t.toGeoJSON(e);
2959
+ if (n) r.push(i.geometry);
2960
+ else {
2961
+ var a = yr(i);
2962
+ a.type === "FeatureCollection" ? r.push.apply(r, a.features) : r.push(a);
2963
+ }
2964
+ }
2965
+ }), n ? vr(this, {
2966
+ geometries: r,
2967
+ type: "GeometryCollection"
2968
+ }) : {
2969
+ type: "FeatureCollection",
2970
+ features: r
2971
+ };
2972
+ }
2973
+ });
2974
+ function xr(e, t) {
2975
+ return new dr(e, t);
2976
+ }
2977
+ var Sr = xr, Cr = X.extend({
2978
+ options: {
2979
+ opacity: 1,
2980
+ alt: "",
2981
+ interactive: !1,
2982
+ crossOrigin: !1,
2983
+ errorOverlayUrl: "",
2984
+ zIndex: 1,
2985
+ className: ""
2986
+ },
2987
+ initialize: function(e, t, n) {
2988
+ this._url = e, this._bounds = D(t), p(this, n);
2989
+ },
2990
+ onAdd: function() {
2991
+ 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();
2992
+ },
2993
+ onRemove: function() {
2994
+ I(this._image), this.options.interactive && this.removeInteractiveTarget(this._image);
2995
+ },
2996
+ setOpacity: function(e) {
2997
+ return this.options.opacity = e, this._image && this._updateOpacity(), this;
2998
+ },
2999
+ setStyle: function(e) {
3000
+ return e.opacity && this.setOpacity(e.opacity), this;
3001
+ },
3002
+ bringToFront: function() {
3003
+ return this._map && Dt(this._image), this;
3004
+ },
3005
+ bringToBack: function() {
3006
+ return this._map && Ot(this._image), this;
3007
+ },
3008
+ setUrl: function(e) {
3009
+ return this._url = e, this._image && (this._image.src = e), this;
3010
+ },
3011
+ setBounds: function(e) {
3012
+ return this._bounds = D(e), this._map && this._reset(), this;
3013
+ },
3014
+ getEvents: function() {
3015
+ var e = {
3016
+ zoom: this._reset,
3017
+ viewreset: this._reset
3018
+ };
3019
+ return this._zoomAnimated && (e.zoomanim = this._animateZoom), e;
3020
+ },
3021
+ setZIndex: function(e) {
3022
+ return this.options.zIndex = e, this._updateZIndex(), this;
3023
+ },
3024
+ getBounds: function() {
3025
+ return this._bounds;
3026
+ },
3027
+ getElement: function() {
3028
+ return this._image;
3029
+ },
3030
+ _initImage: function() {
3031
+ var e = this._url.tagName === "IMG", t = this._image = e ? this._url : F("img");
3032
+ 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) {
3033
+ this._url = t.src;
3034
+ return;
3035
+ }
3036
+ t.src = this._url, t.alt = this.options.alt;
3037
+ },
3038
+ _animateZoom: function(e) {
3039
+ var t = this._map.getZoomScale(e.zoom), n = this._map._latLngBoundsToNewLayerBounds(this._bounds, e.zoom, e.center).min;
3040
+ Pt(this._image, n, t);
3041
+ },
3042
+ _reset: function() {
3043
+ var e = this._image, t = new w(this._map.latLngToLayerPoint(this._bounds.getNorthWest()), this._map.latLngToLayerPoint(this._bounds.getSouthEast())), n = t.getSize();
3044
+ V(e, t.min), e.style.width = n.x + "px", e.style.height = n.y + "px";
3045
+ },
3046
+ _updateOpacity: function() {
3047
+ B(this._image, this.options.opacity);
3048
+ },
3049
+ _updateZIndex: function() {
3050
+ this._image && this.options.zIndex !== void 0 && this.options.zIndex !== null && (this._image.style.zIndex = this.options.zIndex);
3051
+ },
3052
+ _overlayOnError: function() {
3053
+ this.fire("error");
3054
+ var e = this.options.errorOverlayUrl;
3055
+ e && this._url !== e && (this._url = e, this._image.src = e);
3056
+ },
3057
+ getCenter: function() {
3058
+ return this._bounds.getCenter();
3059
+ }
3060
+ }), wr = function(e, t, n) {
3061
+ return new Cr(e, t, n);
3062
+ }, Tr = Cr.extend({
3063
+ options: {
3064
+ autoplay: !0,
3065
+ loop: !0,
3066
+ keepAspectRatio: !0,
3067
+ muted: !1,
3068
+ playsInline: !0
3069
+ },
3070
+ _initImage: function() {
3071
+ var e = this._url.tagName === "VIDEO", t = this._image = e ? this._url : F("video");
3072
+ 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) {
3073
+ for (var n = t.getElementsByTagName("source"), r = [], a = 0; a < n.length; a++) r.push(n[a].src);
3074
+ this._url = n.length > 0 ? r : [t.src];
3075
+ return;
3076
+ }
3077
+ _(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;
3078
+ for (var o = 0; o < this._url.length; o++) {
3079
+ var s = F("source");
3080
+ s.src = this._url[o], t.appendChild(s);
3081
+ }
3082
+ }
3083
+ });
3084
+ function Er(e, t, n) {
3085
+ return new Tr(e, t, n);
3086
+ }
3087
+ var Dr = Cr.extend({ _initImage: function() {
3088
+ var e = this._image = this._url;
3089
+ 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;
3090
+ } });
3091
+ function Or(e, t, n) {
3092
+ return new Dr(e, t, n);
3093
+ }
3094
+ var $ = X.extend({
3095
+ options: {
3096
+ interactive: !1,
3097
+ offset: [0, 0],
3098
+ className: "",
3099
+ pane: void 0,
3100
+ content: ""
3101
+ },
3102
+ initialize: function(e, t) {
3103
+ 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);
3104
+ },
3105
+ openOn: function(e) {
3106
+ return e = arguments.length ? e : this._source._map, e.hasLayer(this) || e.addLayer(this), this;
3107
+ },
3108
+ close: function() {
3109
+ return this._map && this._map.removeLayer(this), this;
3110
+ },
3111
+ toggle: function(e) {
3112
+ return this._map ? this.close() : (arguments.length ? this._source = e : e = this._source, this._prepareOpen(), this.openOn(e._map)), this;
3113
+ },
3114
+ onAdd: function(e) {
3115
+ 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));
3116
+ },
3117
+ onRemove: function(e) {
3118
+ 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));
3119
+ },
3120
+ getLatLng: function() {
3121
+ return this._latlng;
3122
+ },
3123
+ setLatLng: function(e) {
3124
+ return this._latlng = k(e), this._map && (this._updatePosition(), this._adjustPan()), this;
3125
+ },
3126
+ getContent: function() {
3127
+ return this._content;
3128
+ },
3129
+ setContent: function(e) {
3130
+ return this._content = e, this.update(), this;
3131
+ },
3132
+ getElement: function() {
3133
+ return this._container;
3134
+ },
3135
+ update: function() {
3136
+ this._map && (this._container.style.visibility = "hidden", this._updateContent(), this._updateLayout(), this._updatePosition(), this._container.style.visibility = "", this._adjustPan());
3137
+ },
3138
+ getEvents: function() {
3139
+ var e = {
3140
+ zoom: this._updatePosition,
3141
+ viewreset: this._updatePosition
3142
+ };
3143
+ return this._zoomAnimated && (e.zoomanim = this._animateZoom), e;
3144
+ },
3145
+ isOpen: function() {
3146
+ return !!this._map && this._map.hasLayer(this);
3147
+ },
3148
+ bringToFront: function() {
3149
+ return this._map && Dt(this._container), this;
3150
+ },
3151
+ bringToBack: function() {
3152
+ return this._map && Ot(this._container), this;
3153
+ },
3154
+ _prepareOpen: function(e) {
3155
+ var t = this._source;
3156
+ if (!t._map) return !1;
3157
+ if (t instanceof Z) {
3158
+ t = null;
3159
+ var n = this._source._layers;
3160
+ for (var r in n) if (n[r]._map) {
3161
+ t = n[r];
3162
+ break;
3163
+ }
3164
+ if (!t) return !1;
3165
+ this._source = t;
3166
+ }
3167
+ if (!e) {
3168
+ if (t.getCenter) e = t.getCenter();
3169
+ else if (t.getLatLng) e = t.getLatLng();
3170
+ else if (t.getBounds) e = t.getBounds().getCenter();
3171
+ else throw Error("Unable to get source layer LatLng.");
3172
+ }
3173
+ return this.setLatLng(e), this._map && this.update(), !0;
3174
+ },
3175
+ _updateContent: function() {
3176
+ if (this._content) {
3177
+ var e = this._contentNode, t = typeof this._content == "function" ? this._content(this._source || this) : this._content;
3178
+ if (typeof t == "string") e.innerHTML = t;
3179
+ else {
3180
+ for (; e.hasChildNodes();) e.removeChild(e.firstChild);
3181
+ e.appendChild(t);
3182
+ }
3183
+ this.fire("contentupdate");
3184
+ }
3185
+ },
3186
+ _updatePosition: function() {
3187
+ if (this._map) {
3188
+ var e = this._map.latLngToLayerPoint(this._latlng), t = C(this.options.offset), n = this._getAnchor();
3189
+ this._zoomAnimated ? V(this._container, e.add(n)) : t = t.add(e).add(n);
3190
+ var r = this._containerBottom = -t.y, i = this._containerLeft = -Math.round(this._containerWidth / 2) + t.x;
3191
+ this._container.style.bottom = r + "px", this._container.style.left = i + "px";
3192
+ }
3193
+ },
3194
+ _getAnchor: function() {
3195
+ return [0, 0];
3196
+ }
3197
+ });
3198
+ K.include({ _initOverlay: function(e, t, n, r) {
3199
+ var i = t;
3200
+ return i instanceof e || (i = new e(r).setContent(t)), n && i.setLatLng(n), i;
3201
+ } }), X.include({ _initOverlay: function(e, t, n, r) {
3202
+ var i = n;
3203
+ return i instanceof e ? (p(i, r), i._source = this) : (i = t && !r ? t : new e(r, this), i.setContent(n)), i;
3204
+ } });
3205
+ var kr = $.extend({
3206
+ options: {
3207
+ pane: "popupPane",
3208
+ offset: [0, 7],
3209
+ maxWidth: 300,
3210
+ minWidth: 50,
3211
+ maxHeight: null,
3212
+ autoPan: !0,
3213
+ autoPanPaddingTopLeft: null,
3214
+ autoPanPaddingBottomRight: null,
3215
+ autoPanPadding: [5, 5],
3216
+ keepInView: !1,
3217
+ closeButton: !0,
3218
+ autoClose: !0,
3219
+ closeOnEscapeKey: !0,
3220
+ className: ""
3221
+ },
3222
+ openOn: function(e) {
3223
+ 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);
3224
+ },
3225
+ onAdd: function(e) {
3226
+ $.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));
3227
+ },
3228
+ onRemove: function(e) {
3229
+ $.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));
3230
+ },
3231
+ getEvents: function() {
3232
+ var e = $.prototype.getEvents.call(this);
3233
+ 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;
3234
+ },
3235
+ _initLayout: function() {
3236
+ 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);
3237
+ 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) {
3238
+ var r = this._closeButton = F("a", e + "-close-button", t);
3239
+ 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) {
3240
+ G(e), this.close();
3241
+ }, this);
3242
+ }
3243
+ },
3244
+ _updateLayout: function() {
3245
+ var e = this._contentNode, t = e.style;
3246
+ t.width = "", t.whiteSpace = "nowrap";
3247
+ var n = e.offsetWidth;
3248
+ n = Math.min(n, this.options.maxWidth), n = Math.max(n, this.options.minWidth), t.width = n + 1 + "px", t.whiteSpace = "", t.height = "";
3249
+ var r = e.offsetHeight, i = this.options.maxHeight, a = "leaflet-popup-scrolled";
3250
+ i && r > i ? (t.height = i + "px", R(e, a)) : z(e, a), this._containerWidth = this._container.offsetWidth;
3251
+ },
3252
+ _animateZoom: function(e) {
3253
+ var t = this._map._latLngToNewLayerPoint(this._latlng, e.zoom, e.center), n = this._getAnchor();
3254
+ V(this._container, t.add(n));
3255
+ },
3256
+ _adjustPan: function() {
3257
+ if (this.options.autoPan) {
3258
+ if (this._map._panAnim && this._map._panAnim.stop(), this._autopanning) {
3259
+ this._autopanning = !1;
3260
+ return;
3261
+ }
3262
+ 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);
3263
+ i._add(Ft(this._container));
3264
+ 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;
3265
+ 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]));
3266
+ }
3267
+ },
3268
+ _getAnchor: function() {
3269
+ return C(this._source && this._source._getPopupAnchor ? this._source._getPopupAnchor() : [0, 0]);
3270
+ }
3271
+ }), Ar = function(e, t) {
3272
+ return new kr(e, t);
3273
+ };
3274
+ K.mergeOptions({ closePopupOnClick: !0 }), K.include({
3275
+ openPopup: function(e, t, n) {
3276
+ return this._initOverlay(kr, e, t, n).openOn(this), this;
3277
+ },
3278
+ closePopup: function(e) {
3279
+ return e = arguments.length ? e : this._popup, e && e.close(), this;
3280
+ }
3281
+ }), X.include({
3282
+ bindPopup: function(e, t) {
3283
+ return this._popup = this._initOverlay(kr, this._popup, e, t), this._popupHandlersAdded ||= (this.on({
3284
+ click: this._openPopup,
3285
+ keypress: this._onKeyPress,
3286
+ remove: this.closePopup,
3287
+ move: this._movePopup
3288
+ }), !0), this;
3289
+ },
3290
+ unbindPopup: function() {
3291
+ return this._popup &&= (this.off({
3292
+ click: this._openPopup,
3293
+ keypress: this._onKeyPress,
3294
+ remove: this.closePopup,
3295
+ move: this._movePopup
3296
+ }), this._popupHandlersAdded = !1, null), this;
3297
+ },
3298
+ openPopup: function(e) {
3299
+ return this._popup && (this instanceof Z || (this._popup._source = this), this._popup._prepareOpen(e || this._latlng) && this._popup.openOn(this._map)), this;
3300
+ },
3301
+ closePopup: function() {
3302
+ return this._popup && this._popup.close(), this;
3303
+ },
3304
+ togglePopup: function() {
3305
+ return this._popup && this._popup.toggle(this), this;
3306
+ },
3307
+ isPopupOpen: function() {
3308
+ return this._popup ? this._popup.isOpen() : !1;
3309
+ },
3310
+ setPopupContent: function(e) {
3311
+ return this._popup && this._popup.setContent(e), this;
3312
+ },
3313
+ getPopup: function() {
3314
+ return this._popup;
3315
+ },
3316
+ _openPopup: function(e) {
3317
+ if (!(!this._popup || !this._map)) {
3318
+ nn(e);
3319
+ var t = e.layer || e.target;
3320
+ if (this._popup._source === t && !(t instanceof rr)) {
3321
+ this._map.hasLayer(this._popup) ? this.closePopup() : this.openPopup(e.latlng);
3322
+ return;
3323
+ }
3324
+ this._popup._source = t, this.openPopup(e.latlng);
3325
+ }
3326
+ },
3327
+ _movePopup: function(e) {
3328
+ this._popup.setLatLng(e.latlng);
3329
+ },
3330
+ _onKeyPress: function(e) {
3331
+ e.originalEvent.keyCode === 13 && this._openPopup(e);
3332
+ }
3333
+ });
3334
+ var jr = $.extend({
3335
+ options: {
3336
+ pane: "tooltipPane",
3337
+ offset: [0, 0],
3338
+ direction: "auto",
3339
+ permanent: !1,
3340
+ sticky: !1,
3341
+ opacity: .9
3342
+ },
3343
+ onAdd: function(e) {
3344
+ $.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));
3345
+ },
3346
+ onRemove: function(e) {
3347
+ $.prototype.onRemove.call(this, e), e.fire("tooltipclose", { tooltip: this }), this._source && (this.removeEventParent(this._source), this._source.fire("tooltipclose", { tooltip: this }, !0));
3348
+ },
3349
+ getEvents: function() {
3350
+ var e = $.prototype.getEvents.call(this);
3351
+ return this.options.permanent || (e.preclick = this.close), e;
3352
+ },
3353
+ _initLayout: function() {
3354
+ var e = "leaflet-tooltip " + (this.options.className || "") + " leaflet-zoom-" + (this._zoomAnimated ? "animated" : "hide");
3355
+ this._contentNode = this._container = F("div", e), this._container.setAttribute("role", "tooltip"), this._container.setAttribute("id", "leaflet-tooltip-" + o(this));
3356
+ },
3357
+ _updateLayout: function() {},
3358
+ _adjustPan: function() {},
3359
+ _setPosition: function(e) {
3360
+ 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();
3361
+ 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);
3362
+ },
3363
+ _updatePosition: function() {
3364
+ var e = this._map.latLngToLayerPoint(this._latlng);
3365
+ this._setPosition(e);
3366
+ },
3367
+ setOpacity: function(e) {
3368
+ this.options.opacity = e, this._container && B(this._container, e);
3369
+ },
3370
+ _animateZoom: function(e) {
3371
+ var t = this._map._latLngToNewLayerPoint(this._latlng, e.zoom, e.center);
3372
+ this._setPosition(t);
3373
+ },
3374
+ _getAnchor: function() {
3375
+ return C(this._source && this._source._getTooltipAnchor && !this.options.sticky ? this._source._getTooltipAnchor() : [0, 0]);
3376
+ }
3377
+ }), Mr = function(e, t) {
3378
+ return new jr(e, t);
3379
+ };
3380
+ K.include({
3381
+ openTooltip: function(e, t, n) {
3382
+ return this._initOverlay(jr, e, t, n).openOn(this), this;
3383
+ },
3384
+ closeTooltip: function(e) {
3385
+ return e.close(), this;
3386
+ }
3387
+ }), X.include({
3388
+ bindTooltip: function(e, t) {
3389
+ 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;
3390
+ },
3391
+ unbindTooltip: function() {
3392
+ return this._tooltip &&= (this._initTooltipInteractions(!0), this.closeTooltip(), null), this;
3393
+ },
3394
+ _initTooltipInteractions: function(e) {
3395
+ if (!(!e && this._tooltipHandlersAdded)) {
3396
+ var t = e ? "off" : "on", n = {
3397
+ remove: this.closeTooltip,
3398
+ move: this._moveTooltip
3399
+ };
3400
+ 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;
3401
+ }
3402
+ },
3403
+ openTooltip: function(e) {
3404
+ 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;
3405
+ },
3406
+ closeTooltip: function() {
3407
+ if (this._tooltip) return this._tooltip.close();
3408
+ },
3409
+ toggleTooltip: function() {
3410
+ return this._tooltip && this._tooltip.toggle(this), this;
3411
+ },
3412
+ isTooltipOpen: function() {
3413
+ return this._tooltip.isOpen();
3414
+ },
3415
+ setTooltipContent: function(e) {
3416
+ return this._tooltip && this._tooltip.setContent(e), this;
3417
+ },
3418
+ getTooltip: function() {
3419
+ return this._tooltip;
3420
+ },
3421
+ _addFocusListeners: function() {
3422
+ this.getElement ? this._addFocusListenersOnLayer(this) : this.eachLayer && this.eachLayer(this._addFocusListenersOnLayer, this);
3423
+ },
3424
+ _addFocusListenersOnLayer: function(e) {
3425
+ var t = typeof e.getElement == "function" && e.getElement();
3426
+ t && (H(t, "focus", function() {
3427
+ this._tooltip._source = e, this.openTooltip();
3428
+ }, this), H(t, "blur", this.closeTooltip, this));
3429
+ },
3430
+ _setAriaDescribedByOnLayer: function(e) {
3431
+ var t = typeof e.getElement == "function" && e.getElement();
3432
+ t && t.setAttribute("aria-describedby", this._tooltip._container.id);
3433
+ },
3434
+ _openTooltip: function(e) {
3435
+ if (!(!this._tooltip || !this._map)) {
3436
+ if (this._map.dragging && this._map.dragging.moving() && !this._openOnceFlag) {
3437
+ this._openOnceFlag = !0;
3438
+ var t = this;
3439
+ this._map.once("moveend", function() {
3440
+ t._openOnceFlag = !1, t._openTooltip(e);
3441
+ });
3442
+ return;
3443
+ }
3444
+ this._tooltip._source = e.layer || e.target, this.openTooltip(this._tooltip.options.sticky ? e.latlng : void 0);
3445
+ }
3446
+ },
3447
+ _moveTooltip: function(e) {
3448
+ var t = e.latlng, n, r;
3449
+ 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);
3450
+ }
3451
+ });
3452
+ var Nr = Zn.extend({
3453
+ options: {
3454
+ iconSize: [12, 12],
3455
+ html: !1,
3456
+ bgPos: null,
3457
+ className: "leaflet-div-icon"
3458
+ },
3459
+ createIcon: function(e) {
3460
+ var t = e && e.tagName === "DIV" ? e : document.createElement("div"), n = this.options;
3461
+ if (n.html instanceof Element ? (Et(t), t.appendChild(n.html)) : t.innerHTML = n.html === !1 ? "" : n.html, n.bgPos) {
3462
+ var r = C(n.bgPos);
3463
+ t.style.backgroundPosition = -r.x + "px " + -r.y + "px";
3464
+ }
3465
+ return this._setIconStyles(t, "icon"), t;
3466
+ },
3467
+ createShadow: function() {
3468
+ return null;
3469
+ }
3470
+ });
3471
+ function Pr(e) {
3472
+ return new Nr(e);
3473
+ }
3474
+ Zn.Default = $n;
3475
+ var Fr = X.extend({
3476
+ options: {
3477
+ tileSize: 256,
3478
+ opacity: 1,
3479
+ updateWhenIdle: P.mobile,
3480
+ updateWhenZooming: !0,
3481
+ updateInterval: 200,
3482
+ zIndex: 1,
3483
+ bounds: null,
3484
+ minZoom: 0,
3485
+ maxZoom: void 0,
3486
+ maxNativeZoom: void 0,
3487
+ minNativeZoom: void 0,
3488
+ noWrap: !1,
3489
+ pane: "tilePane",
3490
+ className: "",
3491
+ keepBuffer: 2
3492
+ },
3493
+ initialize: function(e) {
3494
+ p(this, e);
3495
+ },
3496
+ onAdd: function() {
3497
+ this._initContainer(), this._levels = {}, this._tiles = {}, this._resetView();
3498
+ },
3499
+ beforeAdd: function(e) {
3500
+ e._addZoomLimit(this);
3501
+ },
3502
+ onRemove: function(e) {
3503
+ this._removeAllTiles(), I(this._container), e._removeZoomLimit(this), this._container = null, this._tileZoom = void 0;
3504
+ },
3505
+ bringToFront: function() {
3506
+ return this._map && (Dt(this._container), this._setAutoZIndex(Math.max)), this;
3507
+ },
3508
+ bringToBack: function() {
3509
+ return this._map && (Ot(this._container), this._setAutoZIndex(Math.min)), this;
3510
+ },
3511
+ getContainer: function() {
3512
+ return this._container;
3513
+ },
3514
+ setOpacity: function(e) {
3515
+ return this.options.opacity = e, this._updateOpacity(), this;
3516
+ },
3517
+ setZIndex: function(e) {
3518
+ return this.options.zIndex = e, this._updateZIndex(), this;
3519
+ },
3520
+ isLoading: function() {
3521
+ return this._loading;
3522
+ },
3523
+ redraw: function() {
3524
+ if (this._map) {
3525
+ this._removeAllTiles();
3526
+ var e = this._clampZoom(this._map.getZoom());
3527
+ e !== this._tileZoom && (this._tileZoom = e, this._updateLevels()), this._update();
3528
+ }
3529
+ return this;
3530
+ },
3531
+ getEvents: function() {
3532
+ var e = {
3533
+ viewprereset: this._invalidateAll,
3534
+ viewreset: this._resetView,
3535
+ zoom: this._resetView,
3536
+ moveend: this._onMoveEnd
3537
+ };
3538
+ return this.options.updateWhenIdle || (this._onMove ||= s(this._onMoveEnd, this.options.updateInterval, this), e.move = this._onMove), this._zoomAnimated && (e.zoomanim = this._animateZoom), e;
3539
+ },
3540
+ createTile: function() {
3541
+ return document.createElement("div");
3542
+ },
3543
+ getTileSize: function() {
3544
+ var e = this.options.tileSize;
3545
+ return e instanceof S ? e : new S(e, e);
3546
+ },
3547
+ _updateZIndex: function() {
3548
+ this._container && this.options.zIndex !== void 0 && this.options.zIndex !== null && (this._container.style.zIndex = this.options.zIndex);
3549
+ },
3550
+ _setAutoZIndex: function(e) {
3551
+ 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));
3552
+ isFinite(n) && (this.options.zIndex = n + e(-1, 1), this._updateZIndex());
3553
+ },
3554
+ _updateOpacity: function() {
3555
+ if (this._map && !P.ielt9) {
3556
+ B(this._container, this.options.opacity);
3557
+ var e = +/* @__PURE__ */ new Date(), t = !1, n = !1;
3558
+ for (var r in this._tiles) {
3559
+ var i = this._tiles[r];
3560
+ if (!(!i.current || !i.loaded)) {
3561
+ var a = Math.min(1, (e - i.loaded) / 200);
3562
+ B(i.el, a), a < 1 ? t = !0 : (i.active ? n = !0 : this._onOpaqueTile(i), i.active = !0);
3563
+ }
3564
+ }
3565
+ n && !this._noPrune && this._pruneTiles(), t && (y(this._fadeFrame), this._fadeFrame = v(this._updateOpacity, this));
3566
+ }
3567
+ },
3568
+ _onOpaqueTile: l,
3569
+ _initContainer: function() {
3570
+ this._container || (this._container = F("div", "leaflet-layer " + (this.options.className || "")), this._updateZIndex(), this.options.opacity < 1 && this._updateOpacity(), this.getPane().appendChild(this._container));
3571
+ },
3572
+ _updateLevels: function() {
3573
+ var e = this._tileZoom, t = this.options.maxZoom;
3574
+ if (e !== void 0) {
3575
+ 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]);
3576
+ var r = this._levels[e], i = this._map;
3577
+ 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;
3578
+ }
3579
+ },
3580
+ _onUpdateLevel: l,
3581
+ _onRemoveLevel: l,
3582
+ _onCreateLevel: l,
3583
+ _pruneTiles: function() {
3584
+ if (this._map) {
3585
+ var e, t, n = this._map.getZoom();
3586
+ if (n > this.options.maxZoom || n < this.options.minZoom) {
3587
+ this._removeAllTiles();
3588
+ return;
3589
+ }
3590
+ for (e in this._tiles) t = this._tiles[e], t.retain = t.current;
3591
+ for (e in this._tiles) if (t = this._tiles[e], t.current && !t.active) {
3592
+ var r = t.coords;
3593
+ this._retainParent(r.x, r.y, r.z, r.z - 5) || this._retainChildren(r.x, r.y, r.z, r.z + 2);
3594
+ }
3595
+ for (e in this._tiles) this._tiles[e].retain || this._removeTile(e);
3596
+ }
3597
+ },
3598
+ _removeTilesAtZoom: function(e) {
3599
+ for (var t in this._tiles) this._tiles[t].coords.z === e && this._removeTile(t);
3600
+ },
3601
+ _removeAllTiles: function() {
3602
+ for (var e in this._tiles) this._removeTile(e);
3603
+ },
3604
+ _invalidateAll: function() {
3605
+ for (var e in this._levels) I(this._levels[e].el), this._onRemoveLevel(Number(e)), delete this._levels[e];
3606
+ this._removeAllTiles(), this._tileZoom = void 0;
3607
+ },
3608
+ _retainParent: function(e, t, n, r) {
3609
+ var i = Math.floor(e / 2), a = Math.floor(t / 2), o = n - 1, s = new S(+i, +a);
3610
+ s.z = +o;
3611
+ var c = this._tileCoordsToKey(s), l = this._tiles[c];
3612
+ return l && l.active ? (l.retain = !0, !0) : (l && l.loaded && (l.retain = !0), o > r && this._retainParent(i, a, o, r));
3613
+ },
3614
+ _retainChildren: function(e, t, n, r) {
3615
+ for (var i = 2 * e; i < 2 * e + 2; i++) for (var a = 2 * t; a < 2 * t + 2; a++) {
3616
+ var o = new S(i, a);
3617
+ o.z = n + 1;
3618
+ var s = this._tileCoordsToKey(o), c = this._tiles[s];
3619
+ if (c && c.active) {
3620
+ c.retain = !0;
3621
+ continue;
3622
+ }
3623
+ c && c.loaded && (c.retain = !0), n + 1 < r && this._retainChildren(i, a, n + 1, r);
3624
+ }
3625
+ },
3626
+ _resetView: function(e) {
3627
+ var t = e && (e.pinch || e.flyTo);
3628
+ this._setView(this._map.getCenter(), this._map.getZoom(), t, t);
3629
+ },
3630
+ _animateZoom: function(e) {
3631
+ this._setView(e.center, e.zoom, !0, e.noUpdate);
3632
+ },
3633
+ _clampZoom: function(e) {
3634
+ var t = this.options;
3635
+ return t.minNativeZoom !== void 0 && e < t.minNativeZoom ? t.minNativeZoom : t.maxNativeZoom !== void 0 && t.maxNativeZoom < e ? t.maxNativeZoom : e;
3636
+ },
3637
+ _setView: function(e, t, n, r) {
3638
+ var i = Math.round(t);
3639
+ i = this.options.maxZoom !== void 0 && i > this.options.maxZoom || this.options.minZoom !== void 0 && i < this.options.minZoom ? void 0 : this._clampZoom(i);
3640
+ var a = this.options.updateWhenZooming && i !== this._tileZoom;
3641
+ (!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);
3642
+ },
3643
+ _setZoomTransforms: function(e, t) {
3644
+ for (var n in this._levels) this._setZoomTransform(this._levels[n], e, t);
3645
+ },
3646
+ _setZoomTransform: function(e, t, n) {
3647
+ var r = this._map.getZoomScale(n, e.zoom), i = e.origin.multiplyBy(r).subtract(this._map._getNewPixelOrigin(t, n)).round();
3648
+ P.any3d ? Pt(e.el, i, r) : V(e.el, i);
3649
+ },
3650
+ _resetGrid: function() {
3651
+ var e = this._map, t = e.options.crs, n = this._tileSize = this.getTileSize(), r = this._tileZoom, i = this._map.getPixelWorldBounds(this._tileZoom);
3652
+ 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)];
3653
+ },
3654
+ _onMoveEnd: function() {
3655
+ !this._map || this._map._animatingZoom || this._update();
3656
+ },
3657
+ _getTiledPixelBounds: function(e) {
3658
+ 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);
3659
+ return new w(i.subtract(a), i.add(a));
3660
+ },
3661
+ _update: function(e) {
3662
+ var t = this._map;
3663
+ if (t) {
3664
+ var n = this._clampZoom(t.getZoom());
3665
+ if (e === void 0 && (e = t.getCenter()), this._tileZoom !== void 0) {
3666
+ 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]));
3667
+ 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");
3668
+ for (var l in this._tiles) {
3669
+ var u = this._tiles[l].coords;
3670
+ (u.z !== this._tileZoom || !c.contains(new S(u.x, u.y))) && (this._tiles[l].current = !1);
3671
+ }
3672
+ if (Math.abs(n - this._tileZoom) > 1) {
3673
+ this._setView(e, n);
3674
+ return;
3675
+ }
3676
+ for (var d = i.min.y; d <= i.max.y; d++) for (var f = i.min.x; f <= i.max.x; f++) {
3677
+ var p = new S(f, d);
3678
+ if (p.z = this._tileZoom, this._isValidTile(p)) {
3679
+ var m = this._tiles[this._tileCoordsToKey(p)];
3680
+ m ? m.current = !0 : o.push(p);
3681
+ }
3682
+ }
3683
+ if (o.sort(function(e, t) {
3684
+ return e.distanceTo(a) - t.distanceTo(a);
3685
+ }), o.length !== 0) {
3686
+ this._loading || (this._loading = !0, this.fire("loading"));
3687
+ var h = document.createDocumentFragment();
3688
+ for (f = 0; f < o.length; f++) this._addTile(o[f], h);
3689
+ this._level.el.appendChild(h);
3690
+ }
3691
+ }
3692
+ }
3693
+ },
3694
+ _isValidTile: function(e) {
3695
+ var t = this._map.options.crs;
3696
+ if (!t.infinite) {
3697
+ var n = this._globalTileRange;
3698
+ 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;
3699
+ }
3700
+ if (!this.options.bounds) return !0;
3701
+ var r = this._tileCoordsToBounds(e);
3702
+ return D(this.options.bounds).overlaps(r);
3703
+ },
3704
+ _keyToBounds: function(e) {
3705
+ return this._tileCoordsToBounds(this._keyToTileCoords(e));
3706
+ },
3707
+ _tileCoordsToNwSe: function(e) {
3708
+ var t = this._map, n = this.getTileSize(), r = e.scaleBy(n), i = r.add(n);
3709
+ return [t.unproject(r, e.z), t.unproject(i, e.z)];
3710
+ },
3711
+ _tileCoordsToBounds: function(e) {
3712
+ var t = this._tileCoordsToNwSe(e), n = new E(t[0], t[1]);
3713
+ return this.options.noWrap || (n = this._map.wrapLatLngBounds(n)), n;
3714
+ },
3715
+ _tileCoordsToKey: function(e) {
3716
+ return e.x + ":" + e.y + ":" + e.z;
3717
+ },
3718
+ _keyToTileCoords: function(e) {
3719
+ var t = e.split(":"), n = new S(+t[0], +t[1]);
3720
+ return n.z = +t[2], n;
3721
+ },
3722
+ _removeTile: function(e) {
3723
+ var t = this._tiles[e];
3724
+ t && (I(t.el), delete this._tiles[e], this.fire("tileunload", {
3725
+ tile: t.el,
3726
+ coords: this._keyToTileCoords(e)
3727
+ }));
3728
+ },
3729
+ _initTile: function(e) {
3730
+ R(e, "leaflet-tile");
3731
+ var t = this.getTileSize();
3732
+ 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);
3733
+ },
3734
+ _addTile: function(e, t) {
3735
+ var n = this._getTilePos(e), r = this._tileCoordsToKey(e), a = this.createTile(this._wrapCoords(e), i(this._tileReady, this, e));
3736
+ this._initTile(a), this.createTile.length < 2 && v(i(this._tileReady, this, e, null, a)), V(a, n), this._tiles[r] = {
3737
+ el: a,
3738
+ coords: e,
3739
+ current: !0
3740
+ }, t.appendChild(a), this.fire("tileloadstart", {
3741
+ tile: a,
3742
+ coords: e
3743
+ });
3744
+ },
3745
+ _tileReady: function(e, t, n) {
3746
+ t && this.fire("tileerror", {
3747
+ error: t,
3748
+ tile: n,
3749
+ coords: e
3750
+ });
3751
+ var r = this._tileCoordsToKey(e);
3752
+ 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", {
3753
+ tile: n.el,
3754
+ coords: e
3755
+ })), this._noTilesToLoad() && (this._loading = !1, this.fire("load"), P.ielt9 || !this._map._fadeAnimated ? v(this._pruneTiles, this) : setTimeout(i(this._pruneTiles, this), 250)));
3756
+ },
3757
+ _getTilePos: function(e) {
3758
+ return e.scaleBy(this.getTileSize()).subtract(this._level.origin);
3759
+ },
3760
+ _wrapCoords: function(e) {
3761
+ var t = new S(this._wrapX ? c(e.x, this._wrapX) : e.x, this._wrapY ? c(e.y, this._wrapY) : e.y);
3762
+ return t.z = e.z, t;
3763
+ },
3764
+ _pxBoundsToTileRange: function(e) {
3765
+ var t = this.getTileSize();
3766
+ return new w(e.min.unscaleBy(t).floor(), e.max.unscaleBy(t).ceil().subtract([1, 1]));
3767
+ },
3768
+ _noTilesToLoad: function() {
3769
+ for (var e in this._tiles) if (!this._tiles[e].loaded) return !1;
3770
+ return !0;
3771
+ }
3772
+ });
3773
+ function Ir(e) {
3774
+ return new Fr(e);
3775
+ }
3776
+ var Lr = Fr.extend({
3777
+ options: {
3778
+ minZoom: 0,
3779
+ maxZoom: 18,
3780
+ subdomains: "abc",
3781
+ errorTileUrl: "",
3782
+ zoomOffset: 0,
3783
+ tms: !1,
3784
+ zoomReverse: !1,
3785
+ detectRetina: !1,
3786
+ crossOrigin: !1,
3787
+ referrerPolicy: !1
3788
+ },
3789
+ initialize: function(e, t) {
3790
+ 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);
3791
+ },
3792
+ setUrl: function(e, t) {
3793
+ return this._url === e && t === void 0 && (t = !0), this._url = e, t || this.redraw(), this;
3794
+ },
3795
+ createTile: function(e, t) {
3796
+ var n = document.createElement("img");
3797
+ 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;
3798
+ },
3799
+ getTileUrl: function(e) {
3800
+ var t = {
3801
+ r: P.retina ? "@2x" : "",
3802
+ s: this._getSubdomain(e),
3803
+ x: e.x,
3804
+ y: e.y,
3805
+ z: this._getZoomForUrl()
3806
+ };
3807
+ if (this._map && !this._map.options.crs.infinite) {
3808
+ var r = this._globalTileRange.max.y - e.y;
3809
+ this.options.tms && (t.y = r), t["-y"] = r;
3810
+ }
3811
+ return g(this._url, n(t, this.options));
3812
+ },
3813
+ _tileOnLoad: function(e, t) {
3814
+ P.ielt9 ? setTimeout(i(e, this, null, t), 0) : e(null, t);
3815
+ },
3816
+ _tileOnError: function(e, t, n) {
3817
+ var r = this.options.errorTileUrl;
3818
+ r && t.getAttribute("src") !== r && (t.src = r), e(n, t);
3819
+ },
3820
+ _onTileRemove: function(e) {
3821
+ e.tile.onload = null;
3822
+ },
3823
+ _getZoomForUrl: function() {
3824
+ var e = this._tileZoom, t = this.options.maxZoom, n = this.options.zoomReverse, r = this.options.zoomOffset;
3825
+ return n && (e = t - e), e + r;
3826
+ },
3827
+ _getSubdomain: function(e) {
3828
+ var t = Math.abs(e.x + e.y) % this.options.subdomains.length;
3829
+ return this.options.subdomains[t];
3830
+ },
3831
+ _abortLoading: function() {
3832
+ var e, t;
3833
+ 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)) {
3834
+ t.src = te;
3835
+ var n = this._tiles[e].coords;
3836
+ I(t), delete this._tiles[e], this.fire("tileabort", {
3837
+ tile: t,
3838
+ coords: n
3839
+ });
3840
+ }
3841
+ },
3842
+ _removeTile: function(e) {
3843
+ var t = this._tiles[e];
3844
+ if (t) return t.el.setAttribute("src", te), Fr.prototype._removeTile.call(this, e);
3845
+ },
3846
+ _tileReady: function(e, t, n) {
3847
+ if (!(!this._map || n && n.getAttribute("src") === te)) return Fr.prototype._tileReady.call(this, e, t, n);
3848
+ }
3849
+ });
3850
+ function Rr(e, t) {
3851
+ return new Lr(e, t);
3852
+ }
3853
+ var zr = Lr.extend({
3854
+ defaultWmsParams: {
3855
+ service: "WMS",
3856
+ request: "GetMap",
3857
+ layers: "",
3858
+ styles: "",
3859
+ format: "image/jpeg",
3860
+ transparent: !1,
3861
+ version: "1.1.1"
3862
+ },
3863
+ options: {
3864
+ crs: null,
3865
+ uppercase: !1
3866
+ },
3867
+ initialize: function(e, t) {
3868
+ this._url = e;
3869
+ var r = n({}, this.defaultWmsParams);
3870
+ for (var i in t) i in this.options || (r[i] = t[i]);
3871
+ t = p(this, t);
3872
+ var a = t.detectRetina && P.retina ? 2 : 1, o = this.getTileSize();
3873
+ r.width = o.x * a, r.height = o.y * a, this.wmsParams = r;
3874
+ },
3875
+ onAdd: function(e) {
3876
+ this._crs = this.options.crs || e.options.crs, this._wmsVersion = parseFloat(this.wmsParams.version);
3877
+ var t = this._wmsVersion >= 1.3 ? "crs" : "srs";
3878
+ this.wmsParams[t] = this._crs.code, Lr.prototype.onAdd.call(this, e);
3879
+ },
3880
+ getTileUrl: function(e) {
3881
+ 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 ? [
3882
+ i.y,
3883
+ i.x,
3884
+ a.y,
3885
+ a.x
3886
+ ] : [
3887
+ i.x,
3888
+ i.y,
3889
+ a.x,
3890
+ a.y
3891
+ ]).join(","), s = Lr.prototype.getTileUrl.call(this, e);
3892
+ return s + m(this.wmsParams, s, this.options.uppercase) + (this.options.uppercase ? "&BBOX=" : "&bbox=") + o;
3893
+ },
3894
+ setParams: function(e, t) {
3895
+ return n(this.wmsParams, e), t || this.redraw(), this;
3896
+ }
3897
+ });
3898
+ function Br(e, t) {
3899
+ return new zr(e, t);
3900
+ }
3901
+ Lr.WMS = zr, Rr.wms = Br;
3902
+ var Vr = X.extend({
3903
+ options: { padding: .1 },
3904
+ initialize: function(e) {
3905
+ p(this, e), o(this), this._layers = this._layers || {};
3906
+ },
3907
+ onAdd: function() {
3908
+ this._container || (this._initContainer(), R(this._container, "leaflet-zoom-animated")), this.getPane().appendChild(this._container), this._update(), this.on("update", this._updatePaths, this);
3909
+ },
3910
+ onRemove: function() {
3911
+ this.off("update", this._updatePaths, this), this._destroyContainer();
3912
+ },
3913
+ getEvents: function() {
3914
+ var e = {
3915
+ viewreset: this._reset,
3916
+ zoom: this._onZoom,
3917
+ moveend: this._update,
3918
+ zoomend: this._onZoomEnd
3919
+ };
3920
+ return this._zoomAnimated && (e.zoomanim = this._onAnimZoom), e;
3921
+ },
3922
+ _onAnimZoom: function(e) {
3923
+ this._updateTransform(e.center, e.zoom);
3924
+ },
3925
+ _onZoom: function() {
3926
+ this._updateTransform(this._map.getCenter(), this._map.getZoom());
3927
+ },
3928
+ _updateTransform: function(e, t) {
3929
+ 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));
3930
+ P.any3d ? Pt(this._container, a, n) : V(this._container, a);
3931
+ },
3932
+ _reset: function() {
3933
+ for (var e in this._update(), this._updateTransform(this._center, this._zoom), this._layers) this._layers[e]._reset();
3934
+ },
3935
+ _onZoomEnd: function() {
3936
+ for (var e in this._layers) this._layers[e]._project();
3937
+ },
3938
+ _updatePaths: function() {
3939
+ for (var e in this._layers) this._layers[e]._update();
3940
+ },
3941
+ _update: function() {
3942
+ var e = this.options.padding, t = this._map.getSize(), n = this._map.containerPointToLayerPoint(t.multiplyBy(-e)).round();
3943
+ this._bounds = new w(n, n.add(t.multiplyBy(1 + e * 2)).round()), this._center = this._map.getCenter(), this._zoom = this._map.getZoom();
3944
+ }
3945
+ }), Hr = Vr.extend({
3946
+ options: { tolerance: 0 },
3947
+ getEvents: function() {
3948
+ var e = Vr.prototype.getEvents.call(this);
3949
+ return e.viewprereset = this._onViewPreReset, e;
3950
+ },
3951
+ _onViewPreReset: function() {
3952
+ this._postponeUpdatePaths = !0;
3953
+ },
3954
+ onAdd: function() {
3955
+ Vr.prototype.onAdd.call(this), this._draw();
3956
+ },
3957
+ _initContainer: function() {
3958
+ var e = this._container = document.createElement("canvas");
3959
+ 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");
3960
+ },
3961
+ _destroyContainer: function() {
3962
+ y(this._redrawRequest), delete this._ctx, I(this._container), W(this._container), delete this._container;
3963
+ },
3964
+ _updatePaths: function() {
3965
+ if (!this._postponeUpdatePaths) {
3966
+ var e;
3967
+ for (var t in this._redrawBounds = null, this._layers) e = this._layers[t], e._update();
3968
+ this._redraw();
3969
+ }
3970
+ },
3971
+ _update: function() {
3972
+ if (!(this._map._animatingZoom && this._bounds)) {
3973
+ Vr.prototype._update.call(this);
3974
+ var e = this._bounds, t = this._container, n = e.getSize(), r = P.retina ? 2 : 1;
3975
+ 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");
3976
+ }
3977
+ },
3978
+ _reset: function() {
3979
+ Vr.prototype._reset.call(this), this._postponeUpdatePaths && (this._postponeUpdatePaths = !1, this._updatePaths());
3980
+ },
3981
+ _initPath: function(e) {
3982
+ this._updateDashArray(e), this._layers[o(e)] = e;
3983
+ var t = e._order = {
3984
+ layer: e,
3985
+ prev: this._drawLast,
3986
+ next: null
3987
+ };
3988
+ this._drawLast && (this._drawLast.next = t), this._drawLast = t, this._drawFirst = this._drawFirst || this._drawLast;
3989
+ },
3990
+ _addPath: function(e) {
3991
+ this._requestRedraw(e);
3992
+ },
3993
+ _removePath: function(e) {
3994
+ var t = e._order, n = t.next, r = t.prev;
3995
+ 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);
3996
+ },
3997
+ _updatePath: function(e) {
3998
+ this._extendRedrawBounds(e), e._project(), e._update(), this._requestRedraw(e);
3999
+ },
4000
+ _updateStyle: function(e) {
4001
+ this._updateDashArray(e), this._requestRedraw(e);
4002
+ },
4003
+ _updateDashArray: function(e) {
4004
+ if (typeof e.options.dashArray == "string") {
4005
+ var t = e.options.dashArray.split(/[, ]+/), n = [], r, i;
4006
+ for (i = 0; i < t.length; i++) {
4007
+ if (r = Number(t[i]), isNaN(r)) return;
4008
+ n.push(r);
4009
+ }
4010
+ e.options._dashArray = n;
4011
+ } else e.options._dashArray = e.options.dashArray;
4012
+ },
4013
+ _requestRedraw: function(e) {
4014
+ this._map && (this._extendRedrawBounds(e), this._redrawRequest = this._redrawRequest || v(this._redraw, this));
4015
+ },
4016
+ _extendRedrawBounds: function(e) {
4017
+ if (e._pxBounds) {
4018
+ var t = (e.options.weight || 0) + 1;
4019
+ this._redrawBounds = this._redrawBounds || new w(), this._redrawBounds.extend(e._pxBounds.min.subtract([t, t])), this._redrawBounds.extend(e._pxBounds.max.add([t, t]));
4020
+ }
4021
+ },
4022
+ _redraw: function() {
4023
+ this._redrawRequest = null, this._redrawBounds && (this._redrawBounds.min._floor(), this._redrawBounds.max._ceil()), this._clear(), this._draw(), this._redrawBounds = null;
4024
+ },
4025
+ _clear: function() {
4026
+ var e = this._redrawBounds;
4027
+ if (e) {
4028
+ var t = e.getSize();
4029
+ this._ctx.clearRect(e.min.x, e.min.y, t.x, t.y);
4030
+ } 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();
4031
+ },
4032
+ _draw: function() {
4033
+ var e, t = this._redrawBounds;
4034
+ if (this._ctx.save(), t) {
4035
+ var n = t.getSize();
4036
+ this._ctx.beginPath(), this._ctx.rect(t.min.x, t.min.y, n.x, n.y), this._ctx.clip();
4037
+ }
4038
+ this._drawing = !0;
4039
+ for (var r = this._drawFirst; r; r = r.next) e = r.layer, (!t || e._pxBounds && e._pxBounds.intersects(t)) && e._updatePath();
4040
+ this._drawing = !1, this._ctx.restore();
4041
+ },
4042
+ _updatePoly: function(e, t) {
4043
+ if (this._drawing) {
4044
+ var n, r, i, a, o = e._parts, s = o.length, c = this._ctx;
4045
+ if (s) {
4046
+ for (c.beginPath(), n = 0; n < s; n++) {
4047
+ for (r = 0, i = o[n].length; r < i; r++) a = o[n][r], c[r ? "lineTo" : "moveTo"](a.x, a.y);
4048
+ t && c.closePath();
4049
+ }
4050
+ this._fillStroke(c, e);
4051
+ }
4052
+ }
4053
+ },
4054
+ _updateCircle: function(e) {
4055
+ if (!(!this._drawing || e._empty())) {
4056
+ 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;
4057
+ 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);
4058
+ }
4059
+ },
4060
+ _fillStroke: function(e, t) {
4061
+ var n = t.options;
4062
+ 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());
4063
+ },
4064
+ _onClick: function(e) {
4065
+ 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);
4066
+ this._fireEvent(r ? [r] : !1, e);
4067
+ },
4068
+ _onMouseMove: function(e) {
4069
+ if (!(!this._map || this._map.dragging.moving() || this._map._animatingZoom)) {
4070
+ var t = this._map.mouseEventToLayerPoint(e);
4071
+ this._handleMouseHover(e, t);
4072
+ }
4073
+ },
4074
+ _handleMouseOut: function(e) {
4075
+ var t = this._hoveredLayer;
4076
+ t && (z(this._container, "leaflet-interactive"), this._fireEvent([t], e, "mouseout"), this._hoveredLayer = null, this._mouseHoverThrottled = !1);
4077
+ },
4078
+ _handleMouseHover: function(e, t) {
4079
+ if (!this._mouseHoverThrottled) {
4080
+ for (var n, r, a = this._drawFirst; a; a = a.next) n = a.layer, n.options.interactive && n._containsPoint(t) && (r = n);
4081
+ 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() {
4082
+ this._mouseHoverThrottled = !1;
4083
+ }, this), 32);
4084
+ }
4085
+ },
4086
+ _fireEvent: function(e, t, n) {
4087
+ this._map._fireDOMEvent(t, n || t.type, e);
4088
+ },
4089
+ _bringToFront: function(e) {
4090
+ var t = e._order;
4091
+ if (t) {
4092
+ var n = t.next, r = t.prev;
4093
+ if (n) n.prev = r;
4094
+ else return;
4095
+ 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);
4096
+ }
4097
+ },
4098
+ _bringToBack: function(e) {
4099
+ var t = e._order;
4100
+ if (t) {
4101
+ var n = t.next, r = t.prev;
4102
+ if (r) r.next = n;
4103
+ else return;
4104
+ 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);
4105
+ }
4106
+ }
4107
+ });
4108
+ function Ur(e) {
4109
+ return P.canvas ? new Hr(e) : null;
4110
+ }
4111
+ var Wr = (function() {
4112
+ try {
4113
+ return document.namespaces.add("lvml", "urn:schemas-microsoft-com:vml"), function(e) {
4114
+ return document.createElement("<lvml:" + e + " class=\"lvml\">");
4115
+ };
4116
+ } catch {}
4117
+ return function(e) {
4118
+ return document.createElement("<" + e + " xmlns=\"urn:schemas-microsoft.com:vml\" class=\"lvml\">");
4119
+ };
4120
+ })(), Gr = {
4121
+ _initContainer: function() {
4122
+ this._container = F("div", "leaflet-vml-container");
4123
+ },
4124
+ _update: function() {
4125
+ this._map._animatingZoom || (Vr.prototype._update.call(this), this.fire("update"));
4126
+ },
4127
+ _initPath: function(e) {
4128
+ var t = e._container = Wr("shape");
4129
+ 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;
4130
+ },
4131
+ _addPath: function(e) {
4132
+ var t = e._container;
4133
+ this._container.appendChild(t), e.options.interactive && e.addInteractiveTarget(t);
4134
+ },
4135
+ _removePath: function(e) {
4136
+ var t = e._container;
4137
+ I(t), e.removeInteractiveTarget(t), delete this._layers[o(e)];
4138
+ },
4139
+ _updateStyle: function(e) {
4140
+ var t = e._stroke, n = e._fill, r = e.options, i = e._container;
4141
+ 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);
4142
+ },
4143
+ _updateCircle: function(e) {
4144
+ var t = e._point.round(), n = Math.round(e._radius), r = Math.round(e._radiusY || n);
4145
+ this._setPath(e, e._empty() ? "M0 0" : "AL " + t.x + "," + t.y + " " + n + "," + r + " 0,23592600");
4146
+ },
4147
+ _setPath: function(e, t) {
4148
+ e._path.v = t;
4149
+ },
4150
+ _bringToFront: function(e) {
4151
+ Dt(e._container);
4152
+ },
4153
+ _bringToBack: function(e) {
4154
+ Ot(e._container);
4155
+ }
4156
+ }, Kr = P.vml ? Wr : _e, qr = Vr.extend({
4157
+ _initContainer: function() {
4158
+ this._container = Kr("svg"), this._container.setAttribute("pointer-events", "none"), this._rootGroup = Kr("g"), this._container.appendChild(this._rootGroup);
4159
+ },
4160
+ _destroyContainer: function() {
4161
+ I(this._container), W(this._container), delete this._container, delete this._rootGroup, delete this._svgSize;
4162
+ },
4163
+ _update: function() {
4164
+ if (!(this._map._animatingZoom && this._bounds)) {
4165
+ Vr.prototype._update.call(this);
4166
+ var e = this._bounds, t = e.getSize(), n = this._container;
4167
+ (!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", [
4168
+ e.min.x,
4169
+ e.min.y,
4170
+ t.x,
4171
+ t.y
4172
+ ].join(" ")), this.fire("update");
4173
+ }
4174
+ },
4175
+ _initPath: function(e) {
4176
+ var t = e._path = Kr("path");
4177
+ e.options.className && R(t, e.options.className), e.options.interactive && R(t, "leaflet-interactive"), this._updateStyle(e), this._layers[o(e)] = e;
4178
+ },
4179
+ _addPath: function(e) {
4180
+ this._rootGroup || this._initContainer(), this._rootGroup.appendChild(e._path), e.addInteractiveTarget(e._path);
4181
+ },
4182
+ _removePath: function(e) {
4183
+ I(e._path), e.removeInteractiveTarget(e._path), delete this._layers[o(e)];
4184
+ },
4185
+ _updatePath: function(e) {
4186
+ e._project(), e._update();
4187
+ },
4188
+ _updateStyle: function(e) {
4189
+ var t = e._path, n = e.options;
4190
+ 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"));
4191
+ },
4192
+ _updatePoly: function(e, t) {
4193
+ this._setPath(e, ve(e._parts, t));
4194
+ },
4195
+ _updateCircle: function(e) {
4196
+ 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 ";
4197
+ this._setPath(e, a);
4198
+ },
4199
+ _setPath: function(e, t) {
4200
+ e._path.setAttribute("d", t);
4201
+ },
4202
+ _bringToFront: function(e) {
4203
+ Dt(e._path);
4204
+ },
4205
+ _bringToBack: function(e) {
4206
+ Ot(e._path);
4207
+ }
4208
+ });
4209
+ P.vml && qr.include(Gr);
4210
+ function Jr(e) {
4211
+ return P.svg || P.vml ? new qr(e) : null;
4212
+ }
4213
+ K.include({
4214
+ getRenderer: function(e) {
4215
+ var t = e.options.renderer || this._getPaneRenderer(e.options.pane) || this.options.renderer || this._renderer;
4216
+ return t ||= this._renderer = this._createRenderer(), this.hasLayer(t) || this.addLayer(t), t;
4217
+ },
4218
+ _getPaneRenderer: function(e) {
4219
+ if (e === "overlayPane" || e === void 0) return !1;
4220
+ var t = this._paneRenderers[e];
4221
+ return t === void 0 && (t = this._createRenderer({ pane: e }), this._paneRenderers[e] = t), t;
4222
+ },
4223
+ _createRenderer: function(e) {
4224
+ return this.options.preferCanvas && Ur(e) || Jr(e);
4225
+ }
4226
+ });
4227
+ var Yr = lr.extend({
4228
+ initialize: function(e, t) {
4229
+ lr.prototype.initialize.call(this, this._boundsToLatLngs(e), t);
4230
+ },
4231
+ setBounds: function(e) {
4232
+ return this.setLatLngs(this._boundsToLatLngs(e));
4233
+ },
4234
+ _boundsToLatLngs: function(e) {
4235
+ return e = D(e), [
4236
+ e.getSouthWest(),
4237
+ e.getNorthWest(),
4238
+ e.getNorthEast(),
4239
+ e.getSouthEast()
4240
+ ];
4241
+ }
4242
+ });
4243
+ function Xr(e, t) {
4244
+ return new Yr(e, t);
4245
+ }
4246
+ 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 });
4247
+ var Zr = J.extend({
4248
+ initialize: function(e) {
4249
+ this._map = e, this._container = e._container, this._pane = e._panes.overlayPane, this._resetStateTimeout = 0, e.on("unload", this._destroy, this);
4250
+ },
4251
+ addHooks: function() {
4252
+ H(this._container, "mousedown", this._onMouseDown, this);
4253
+ },
4254
+ removeHooks: function() {
4255
+ W(this._container, "mousedown", this._onMouseDown, this);
4256
+ },
4257
+ moved: function() {
4258
+ return this._moved;
4259
+ },
4260
+ _destroy: function() {
4261
+ I(this._pane), delete this._pane;
4262
+ },
4263
+ _resetState: function() {
4264
+ this._resetStateTimeout = 0, this._moved = !1;
4265
+ },
4266
+ _clearDeferredResetState: function() {
4267
+ this._resetStateTimeout !== 0 && (clearTimeout(this._resetStateTimeout), this._resetStateTimeout = 0);
4268
+ },
4269
+ _onMouseDown: function(e) {
4270
+ if (!e.shiftKey || e.which !== 1 && e.button !== 1) return !1;
4271
+ this._clearDeferredResetState(), this._resetState(), It(), Bt(), this._startPoint = this._map.mouseEventToContainerPoint(e), H(document, {
4272
+ contextmenu: nn,
4273
+ mousemove: this._onMouseMove,
4274
+ mouseup: this._onMouseUp,
4275
+ keydown: this._onKeyDown
4276
+ }, this);
4277
+ },
4278
+ _onMouseMove: function(e) {
4279
+ 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);
4280
+ var t = new w(this._point, this._startPoint), n = t.getSize();
4281
+ V(this._box, t.min), this._box.style.width = n.x + "px", this._box.style.height = n.y + "px";
4282
+ },
4283
+ _finish: function() {
4284
+ this._moved && (I(this._box), z(this._container, "leaflet-crosshair")), Lt(), Vt(), W(document, {
4285
+ contextmenu: nn,
4286
+ mousemove: this._onMouseMove,
4287
+ mouseup: this._onMouseUp,
4288
+ keydown: this._onKeyDown
4289
+ }, this);
4290
+ },
4291
+ _onMouseUp: function(e) {
4292
+ if ((e.which === 1 || e.button === 1) && (this._finish(), this._moved)) {
4293
+ this._clearDeferredResetState(), this._resetStateTimeout = setTimeout(i(this._resetState, this), 0);
4294
+ var t = new E(this._map.containerPointToLatLng(this._startPoint), this._map.containerPointToLatLng(this._point));
4295
+ this._map.fitBounds(t).fire("boxzoomend", { boxZoomBounds: t });
4296
+ }
4297
+ },
4298
+ _onKeyDown: function(e) {
4299
+ e.keyCode === 27 && (this._finish(), this._clearDeferredResetState(), this._resetState());
4300
+ }
4301
+ });
4302
+ K.addInitHook("addHandler", "boxZoom", Zr), K.mergeOptions({ doubleClickZoom: !0 });
4303
+ var Qr = J.extend({
4304
+ addHooks: function() {
4305
+ this._map.on("dblclick", this._onDoubleClick, this);
4306
+ },
4307
+ removeHooks: function() {
4308
+ this._map.off("dblclick", this._onDoubleClick, this);
4309
+ },
4310
+ _onDoubleClick: function(e) {
4311
+ var t = this._map, n = t.getZoom(), r = t.options.zoomDelta, i = e.originalEvent.shiftKey ? n - r : n + r;
4312
+ t.options.doubleClickZoom === "center" ? t.setZoom(i) : t.setZoomAround(e.containerPoint, i);
4313
+ }
4314
+ });
4315
+ K.addInitHook("addHandler", "doubleClickZoom", Qr), K.mergeOptions({
4316
+ dragging: !0,
4317
+ inertia: !0,
4318
+ inertiaDeceleration: 3400,
4319
+ inertiaMaxSpeed: Infinity,
4320
+ easeLinearity: .2,
4321
+ worldCopyJump: !1,
4322
+ maxBoundsViscosity: 0
4323
+ });
4324
+ var $r = J.extend({
4325
+ addHooks: function() {
4326
+ if (!this._draggable) {
4327
+ var e = this._map;
4328
+ this._draggable = new Sn(e._mapPane, e._container), this._draggable.on({
4329
+ dragstart: this._onDragStart,
4330
+ drag: this._onDrag,
4331
+ dragend: this._onDragEnd
4332
+ }, 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));
4333
+ }
4334
+ R(this._map._container, "leaflet-grab leaflet-touch-drag"), this._draggable.enable(), this._positions = [], this._times = [];
4335
+ },
4336
+ removeHooks: function() {
4337
+ z(this._map._container, "leaflet-grab"), z(this._map._container, "leaflet-touch-drag"), this._draggable.disable();
4338
+ },
4339
+ moved: function() {
4340
+ return this._draggable && this._draggable._moved;
4341
+ },
4342
+ moving: function() {
4343
+ return this._draggable && this._draggable._moving;
4344
+ },
4345
+ _onDragStart: function() {
4346
+ var e = this._map;
4347
+ if (e._stop(), this._map.options.maxBounds && this._map.options.maxBoundsViscosity) {
4348
+ var t = D(this._map.options.maxBounds);
4349
+ 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));
4350
+ } else this._offsetLimit = null;
4351
+ e.fire("movestart").fire("dragstart"), e.options.inertia && (this._positions = [], this._times = []);
4352
+ },
4353
+ _onDrag: function(e) {
4354
+ if (this._map.options.inertia) {
4355
+ var t = this._lastTime = +/* @__PURE__ */ new Date(), n = this._lastPos = this._draggable._absPos || this._draggable._newPos;
4356
+ this._positions.push(n), this._times.push(t), this._prunePositions(t);
4357
+ }
4358
+ this._map.fire("move", e).fire("drag", e);
4359
+ },
4360
+ _prunePositions: function(e) {
4361
+ for (; this._positions.length > 1 && e - this._times[0] > 50;) this._positions.shift(), this._times.shift();
4362
+ },
4363
+ _onZoomEnd: function() {
4364
+ var e = this._map.getSize().divideBy(2), t = this._map.latLngToLayerPoint([0, 0]);
4365
+ this._initialWorldOffset = t.subtract(e).x, this._worldWidth = this._map.getPixelWorldBounds().getSize().x;
4366
+ },
4367
+ _viscousLimit: function(e, t) {
4368
+ return e - (e - t) * this._viscosity;
4369
+ },
4370
+ _onPreDragLimit: function() {
4371
+ if (!(!this._viscosity || !this._offsetLimit)) {
4372
+ var e = this._draggable._newPos.subtract(this._draggable._startPos), t = this._offsetLimit;
4373
+ 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);
4374
+ }
4375
+ },
4376
+ _onPreDragWrap: function() {
4377
+ 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;
4378
+ this._draggable._absPos = this._draggable._newPos.clone(), this._draggable._newPos.x = o;
4379
+ },
4380
+ _onDragEnd: function(e) {
4381
+ var t = this._map, n = t.options, r = !n.inertia || e.noInertia || this._times.length < 2;
4382
+ if (t.fire("dragend", e), r) t.fire("moveend");
4383
+ else {
4384
+ this._prunePositions(+/* @__PURE__ */ new Date());
4385
+ 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();
4386
+ !f.x && !f.y ? t.fire("moveend") : (f = t._limitOffset(f, t.options.maxBounds), v(function() {
4387
+ t.panBy(f, {
4388
+ duration: d,
4389
+ easeLinearity: o,
4390
+ noMoveStart: !0,
4391
+ animate: !0
4392
+ });
4393
+ }));
4394
+ }
4395
+ }
4396
+ });
4397
+ K.addInitHook("addHandler", "dragging", $r), K.mergeOptions({
4398
+ keyboard: !0,
4399
+ keyboardPanDelta: 80
4400
+ });
4401
+ var ei = J.extend({
4402
+ keyCodes: {
4403
+ left: [37],
4404
+ right: [39],
4405
+ down: [40],
4406
+ up: [38],
4407
+ zoomIn: [
4408
+ 187,
4409
+ 107,
4410
+ 61,
4411
+ 171
4412
+ ],
4413
+ zoomOut: [
4414
+ 189,
4415
+ 109,
4416
+ 54,
4417
+ 173
4418
+ ]
4419
+ },
4420
+ initialize: function(e) {
4421
+ this._map = e, this._setPanDelta(e.options.keyboardPanDelta), this._setZoomDelta(e.options.zoomDelta);
4422
+ },
4423
+ addHooks: function() {
4424
+ var e = this._map._container;
4425
+ e.tabIndex <= 0 && (e.tabIndex = "0"), H(e, {
4426
+ focus: this._onFocus,
4427
+ blur: this._onBlur,
4428
+ mousedown: this._onMouseDown
4429
+ }, this), this._map.on({
4430
+ focus: this._addHooks,
4431
+ blur: this._removeHooks
4432
+ }, this);
4433
+ },
4434
+ removeHooks: function() {
4435
+ this._removeHooks(), W(this._map._container, {
4436
+ focus: this._onFocus,
4437
+ blur: this._onBlur,
4438
+ mousedown: this._onMouseDown
4439
+ }, this), this._map.off({
4440
+ focus: this._addHooks,
4441
+ blur: this._removeHooks
4442
+ }, this);
4443
+ },
4444
+ _onMouseDown: function() {
4445
+ if (!this._focused) {
4446
+ var e = document.body, t = document.documentElement, n = e.scrollTop || t.scrollTop, r = e.scrollLeft || t.scrollLeft;
4447
+ this._map._container.focus(), window.scrollTo(r, n);
4448
+ }
4449
+ },
4450
+ _onFocus: function() {
4451
+ this._focused = !0, this._map.fire("focus");
4452
+ },
4453
+ _onBlur: function() {
4454
+ this._focused = !1, this._map.fire("blur");
4455
+ },
4456
+ _setPanDelta: function(e) {
4457
+ var t = this._panKeys = {}, n = this.keyCodes, r, i;
4458
+ for (r = 0, i = n.left.length; r < i; r++) t[n.left[r]] = [-1 * e, 0];
4459
+ for (r = 0, i = n.right.length; r < i; r++) t[n.right[r]] = [e, 0];
4460
+ for (r = 0, i = n.down.length; r < i; r++) t[n.down[r]] = [0, e];
4461
+ for (r = 0, i = n.up.length; r < i; r++) t[n.up[r]] = [0, -1 * e];
4462
+ },
4463
+ _setZoomDelta: function(e) {
4464
+ var t = this._zoomKeys = {}, n = this.keyCodes, r, i;
4465
+ for (r = 0, i = n.zoomIn.length; r < i; r++) t[n.zoomIn[r]] = e;
4466
+ for (r = 0, i = n.zoomOut.length; r < i; r++) t[n.zoomOut[r]] = -e;
4467
+ },
4468
+ _addHooks: function() {
4469
+ H(document, "keydown", this._onKeyDown, this);
4470
+ },
4471
+ _removeHooks: function() {
4472
+ W(document, "keydown", this._onKeyDown, this);
4473
+ },
4474
+ _onKeyDown: function(e) {
4475
+ if (!(e.altKey || e.ctrlKey || e.metaKey)) {
4476
+ var t = e.keyCode, n = this._map, r;
4477
+ if (t in this._panKeys) {
4478
+ if (!n._panAnim || !n._panAnim._inProgress) {
4479
+ 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) {
4480
+ var i = n.wrapLatLng(n.unproject(n.project(n.getCenter()).add(r)));
4481
+ n.panTo(i);
4482
+ } else n.panBy(r);
4483
+ }
4484
+ } else if (t in this._zoomKeys) n.setZoom(n.getZoom() + (e.shiftKey ? 3 : 1) * this._zoomKeys[t]);
4485
+ else if (t === 27 && n._popup && n._popup.options.closeOnEscapeKey) n.closePopup();
4486
+ else return;
4487
+ nn(e);
4488
+ }
4489
+ }
4490
+ });
4491
+ K.addInitHook("addHandler", "keyboard", ei), K.mergeOptions({
4492
+ scrollWheelZoom: !0,
4493
+ wheelDebounceTime: 40,
4494
+ wheelPxPerZoomLevel: 60
4495
+ });
4496
+ var ti = J.extend({
4497
+ addHooks: function() {
4498
+ H(this._map._container, "wheel", this._onWheelScroll, this), this._delta = 0;
4499
+ },
4500
+ removeHooks: function() {
4501
+ W(this._map._container, "wheel", this._onWheelScroll, this);
4502
+ },
4503
+ _onWheelScroll: function(e) {
4504
+ var t = sn(e), n = this._map.options.wheelDebounceTime;
4505
+ this._delta += t, this._lastMousePos = this._map.mouseEventToContainerPoint(e), this._startTime ||= +/* @__PURE__ */ new Date();
4506
+ var r = Math.max(n - (+/* @__PURE__ */ new Date() - this._startTime), 0);
4507
+ clearTimeout(this._timer), this._timer = setTimeout(i(this._performZoom, this), r), nn(e);
4508
+ },
4509
+ _performZoom: function() {
4510
+ var e = this._map, t = e.getZoom(), n = this._map.options.zoomSnap || 0;
4511
+ e._stop();
4512
+ 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;
4513
+ this._delta = 0, this._startTime = null, o && (e.options.scrollWheelZoom === "center" ? e.setZoom(t + o) : e.setZoomAround(this._lastMousePos, t + o));
4514
+ }
4515
+ });
4516
+ K.addInitHook("addHandler", "scrollWheelZoom", ti);
4517
+ var ni = 600;
4518
+ K.mergeOptions({
4519
+ tapHold: P.touchNative && P.safari && P.mobile,
4520
+ tapTolerance: 15
4521
+ });
4522
+ var ri = J.extend({
4523
+ addHooks: function() {
4524
+ H(this._map._container, "touchstart", this._onDown, this);
4525
+ },
4526
+ removeHooks: function() {
4527
+ W(this._map._container, "touchstart", this._onDown, this);
4528
+ },
4529
+ _onDown: function(e) {
4530
+ if (clearTimeout(this._holdTimeout), e.touches.length === 1) {
4531
+ var t = e.touches[0];
4532
+ this._startPos = this._newPos = new S(t.clientX, t.clientY), this._holdTimeout = setTimeout(i(function() {
4533
+ this._cancel(), this._isTapValid() && (H(document, "touchend", G), H(document, "touchend touchcancel", this._cancelClickPrevent), this._simulateEvent("contextmenu", t));
4534
+ }, this), ni), H(document, "touchend touchcancel contextmenu", this._cancel, this), H(document, "touchmove", this._onMove, this);
4535
+ }
4536
+ },
4537
+ _cancelClickPrevent: function e() {
4538
+ W(document, "touchend", G), W(document, "touchend touchcancel", e);
4539
+ },
4540
+ _cancel: function() {
4541
+ clearTimeout(this._holdTimeout), W(document, "touchend touchcancel contextmenu", this._cancel, this), W(document, "touchmove", this._onMove, this);
4542
+ },
4543
+ _onMove: function(e) {
4544
+ var t = e.touches[0];
4545
+ this._newPos = new S(t.clientX, t.clientY);
4546
+ },
4547
+ _isTapValid: function() {
4548
+ return this._newPos.distanceTo(this._startPos) <= this._map.options.tapTolerance;
4549
+ },
4550
+ _simulateEvent: function(e, t) {
4551
+ var n = new MouseEvent(e, {
4552
+ bubbles: !0,
4553
+ cancelable: !0,
4554
+ view: window,
4555
+ screenX: t.screenX,
4556
+ screenY: t.screenY,
4557
+ clientX: t.clientX,
4558
+ clientY: t.clientY
4559
+ });
4560
+ n._simulated = !0, t.target.dispatchEvent(n);
4561
+ }
4562
+ });
4563
+ K.addInitHook("addHandler", "tapHold", ri), K.mergeOptions({
4564
+ touchZoom: P.touch,
4565
+ bounceAtZoomLimits: !0
4566
+ });
4567
+ var ii = J.extend({
4568
+ addHooks: function() {
4569
+ R(this._map._container, "leaflet-touch-zoom"), H(this._map._container, "touchstart", this._onTouchStart, this);
4570
+ },
4571
+ removeHooks: function() {
4572
+ z(this._map._container, "leaflet-touch-zoom"), W(this._map._container, "touchstart", this._onTouchStart, this);
4573
+ },
4574
+ _onTouchStart: function(e) {
4575
+ var t = this._map;
4576
+ if (!(!e.touches || e.touches.length !== 2 || t._animatingZoom || this._zooming)) {
4577
+ var n = t.mouseEventToContainerPoint(e.touches[0]), r = t.mouseEventToContainerPoint(e.touches[1]);
4578
+ 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);
4579
+ }
4580
+ },
4581
+ _onTouchMove: function(e) {
4582
+ if (!(!e.touches || e.touches.length !== 2 || !this._zooming)) {
4583
+ var t = this._map, n = t.mouseEventToContainerPoint(e.touches[0]), r = t.mouseEventToContainerPoint(e.touches[1]), a = n.distanceTo(r) / this._startDist;
4584
+ 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") {
4585
+ if (this._center = this._startLatLng, a === 1) return;
4586
+ } else {
4587
+ var o = n._add(r)._divideBy(2)._subtract(this._centerPoint);
4588
+ if (a === 1 && o.x === 0 && o.y === 0) return;
4589
+ this._center = t.unproject(t.project(this._pinchStartLatLng, this._zoom).subtract(o), this._zoom);
4590
+ }
4591
+ this._moved ||= (t._moveStart(!0, !1), !0), y(this._animRequest);
4592
+ var s = i(t._move, t, this._center, this._zoom, {
4593
+ pinch: !0,
4594
+ round: !1
4595
+ }, void 0);
4596
+ this._animRequest = v(s, this, !0), G(e);
4597
+ }
4598
+ },
4599
+ _onTouchEnd: function() {
4600
+ if (!this._moved || !this._zooming) {
4601
+ this._zooming = !1;
4602
+ return;
4603
+ }
4604
+ 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));
4605
+ }
4606
+ });
4607
+ 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;
4608
+ var ai = window.L;
4609
+ e.noConflict = function() {
4610
+ return window.L = ai, this;
4611
+ }, window.L = e;
4612
+ }));
4613
+ })))(), 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";
4614
+ //#endregion
4615
+ //#region src/composables/useDeviceLocation.ts
4616
+ function A() {
4617
+ return { getCurrentPosition: async () => new Promise((e, t) => {
4618
+ if (!navigator.geolocation) {
4619
+ t(/* @__PURE__ */ Error("geolocation unavailable"));
4620
+ return;
4621
+ }
4622
+ navigator.geolocation.getCurrentPosition((t) => e({
4623
+ latitude: t.coords.latitude,
4624
+ longitude: t.coords.longitude
4625
+ }), (e) => t(e), {
4626
+ enableHighAccuracy: !0,
4627
+ timeout: 1e4
4628
+ });
4629
+ }) };
4630
+ }
4631
+ //#endregion
4632
+ //#region src/components/CuiAutomation/config/ConfigTriggerGeofence.vue?vue&type=script&setup=true&lang.ts
4633
+ 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 = {
4634
+ key: 0,
4635
+ class: "flex flex-col field-gap"
4636
+ }, Oe = { class: "cui-label" }, ke = { class: "text-xs text-muted font-medium" }, Ae = {
4637
+ key: 1,
4638
+ class: "cui-banner cui-banner-warn"
4639
+ }, je = /* @__PURE__ */ g({
4640
+ __name: "ConfigTriggerGeofence",
4641
+ props: { data: {} },
4642
+ emits: ["update:data"],
4643
+ setup(e, { emit: t }) {
4644
+ let o = e, g = t, { t: C } = v(), w = ae(), { userOptions: je } = ue(), { getCurrentPosition: Me } = A(), Ne = [
4645
+ {
4646
+ label: C("components.automation_nodes.geofence_event_enter"),
4647
+ value: "enter"
4648
+ },
4649
+ {
4650
+ label: C("components.automation_nodes.geofence_event_leave"),
4651
+ value: "leave"
4652
+ },
4653
+ {
4654
+ label: C("components.automation_nodes.geofence_event_both"),
4655
+ value: "both"
4656
+ }
4657
+ ], 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 ?? {}));
4658
+ function ze() {
4659
+ if (!Pe.value) return;
4660
+ let e = o.data.latitude || 51.505, t = o.data.longitude || -.09;
4661
+ 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);
4662
+ let n = E.icon({
4663
+ iconRetinaUrl: D,
4664
+ iconUrl: O,
4665
+ shadowUrl: k,
4666
+ iconSize: [25, 41],
4667
+ iconAnchor: [12, 41],
4668
+ popupAnchor: [1, -34],
4669
+ shadowSize: [41, 41]
4670
+ });
4671
+ Fe = E.marker([e, t], {
4672
+ draggable: !0,
4673
+ icon: n
4674
+ }).addTo(M), Ie = E.circle([e, t], {
4675
+ radius: o.data.radius || 200,
4676
+ color: "#3b82f6",
4677
+ fillOpacity: .15,
4678
+ weight: 2
4679
+ }).addTo(M), Fe.on("dragend", () => {
4680
+ let e = Fe.getLatLng();
4681
+ g("update:data", {
4682
+ latitude: e.lat,
4683
+ longitude: e.lng
4684
+ }), Ie.setLatLng(e);
4685
+ });
4686
+ }
4687
+ function Be(e, t, n) {
4688
+ M && (M.setView([e, t], n ?? M.getZoom()), Fe?.setLatLng([e, t]), Ie?.setLatLng([e, t]));
4689
+ }
4690
+ function Ve(e) {
4691
+ e != null && (g("update:data", { latitude: e }), Be(e, o.data.longitude));
4692
+ }
4693
+ function He(e) {
4694
+ e != null && (g("update:data", { longitude: e }), Be(o.data.latitude, e));
4695
+ }
4696
+ function Ue(e) {
4697
+ e != null && (qe("radius", e), Ie?.setRadius(e));
4698
+ }
4699
+ function We() {
4700
+ w.add({
4701
+ severity: "error",
4702
+ summary: C("components.toast.title_error"),
4703
+ detail: C("components.automation_nodes.geofence_location_error"),
4704
+ life: 4e3
4705
+ });
4706
+ }
4707
+ async function Ge() {
4708
+ try {
4709
+ let { latitude: e, longitude: t } = await Me();
4710
+ g("update:data", {
4711
+ latitude: e,
4712
+ longitude: t
4713
+ }), Be(e, t, 16);
4714
+ } catch {
4715
+ We();
4716
+ }
4717
+ }
4718
+ function Ke(e) {
4719
+ oe(e);
4720
+ }
4721
+ function qe(e, t) {
4722
+ g("update:data", { [e]: t });
4723
+ }
4724
+ return u(Pe, (e) => {
4725
+ e && !M && ze();
4726
+ }), i(() => {
4727
+ M?.remove(), M = null, Fe = null, Ie = null;
4728
+ }), (t, i) => {
4729
+ let o = se, c = T, u = y, p = ce, g = ie, ae = b, oe = x, v = ee, ue = ne, w = te, E = re, D = le;
4730
+ return r(), d("div", j, [
4731
+ m("div", de, [m("label", fe, a(s(C)("components.automation_nodes.geofence_zone_name")), 1), _(o, {
4732
+ "model-value": e.data.zoneName,
4733
+ placeholder: s(C)("components.automation_nodes.geofence_zone_name_placeholder"),
4734
+ class: "w-full",
4735
+ "onUpdate:modelValue": i[0] ||= (e) => qe("zoneName", e)
4736
+ }, null, 8, ["model-value", "placeholder"])]),
4737
+ m("div", pe, [
4738
+ m("label", me, a(s(C)("components.automation_nodes.geofence_map_hint")), 1),
4739
+ m("div", {
4740
+ ref_key: "mapContainerRef",
4741
+ ref: Pe,
4742
+ class: "rounded-lg overflow-hidden border-[1px] border-color",
4743
+ style: { height: "220px" }
4744
+ }, null, 512),
4745
+ _(u, {
4746
+ severity: "secondary",
4747
+ outlined: "",
4748
+ label: s(C)("components.automation_nodes.geofence_use_my_location"),
4749
+ class: "cui-button-small w-full",
4750
+ onClick: Ge
4751
+ }, {
4752
+ icon: l(() => [_(c, { class: "w-4 h-4" })]),
4753
+ _: 1
4754
+ }, 8, ["label"])
4755
+ ]),
4756
+ m("div", he, [m("label", ge, a(s(C)("components.automation_nodes.geofence_latitude")), 1), _(p, {
4757
+ "model-value": e.data.latitude,
4758
+ "min-fraction-digits": 4,
4759
+ "max-fraction-digits": 6,
4760
+ class: "w-full",
4761
+ "onUpdate:modelValue": Ve
4762
+ }, null, 8, ["model-value"])]),
4763
+ m("div", _e, [m("label", ve, a(s(C)("components.automation_nodes.geofence_longitude")), 1), _(p, {
4764
+ "model-value": e.data.longitude,
4765
+ "min-fraction-digits": 4,
4766
+ "max-fraction-digits": 6,
4767
+ class: "w-full",
4768
+ "onUpdate:modelValue": He
4769
+ }, null, 8, ["model-value"])]),
4770
+ m("div", ye, [
4771
+ m("label", be, a(s(C)("components.automation_nodes.geofence_radius")), 1),
4772
+ _(g, {
4773
+ "model-value": e.data.radius || 200,
4774
+ min: 50,
4775
+ max: 5e3,
4776
+ step: 50,
4777
+ class: "w-full",
4778
+ "onUpdate:modelValue": i[1] ||= (e) => Ue(Array.isArray(e) ? e[0] : e)
4779
+ }, null, 8, ["model-value"]),
4780
+ _(p, {
4781
+ "model-value": e.data.radius || 200,
4782
+ min: 50,
4783
+ max: 5e3,
4784
+ suffix: " m",
4785
+ class: "w-full",
4786
+ "onUpdate:modelValue": Ue
4787
+ }, null, 8, ["model-value"])
4788
+ ]),
4789
+ m("div", xe, [m("label", Se, a(s(C)("components.automation_nodes.geofence_event")), 1), _(ae, {
4790
+ "model-value": e.data.event || "both",
4791
+ options: Ne,
4792
+ "option-label": "label",
4793
+ "option-value": "value",
4794
+ class: "w-full",
4795
+ "onUpdate:modelValue": i[2] ||= (e) => qe("event", e)
4796
+ }, null, 8, ["model-value"])]),
4797
+ m("div", Ce, [
4798
+ m("label", we, a(s(C)("components.automation_nodes.geofence_users")), 1),
4799
+ _(oe, {
4800
+ "model-value": e.data.users,
4801
+ options: s(je),
4802
+ "option-label": "label",
4803
+ "option-value": "value",
4804
+ placeholder: s(C)("components.automation_nodes.geofence_users_placeholder"),
4805
+ class: "w-full",
4806
+ "onUpdate:modelValue": i[3] ||= (e) => qe("users", e)
4807
+ }, null, 8, [
4808
+ "model-value",
4809
+ "options",
4810
+ "placeholder"
4811
+ ]),
4812
+ _(v, {
4813
+ severity: "secondary",
4814
+ variant: "simple",
4815
+ size: "small",
4816
+ class: "cui-input-hint"
4817
+ }, {
4818
+ default: l(() => [h(a(s(C)("components.automation_nodes.geofence_users_hint")), 1)]),
4819
+ _: 1
4820
+ })
4821
+ ]),
4822
+ m("div", Te, [
4823
+ m("label", Ee, a(s(C)("components.automation_nodes.geofence_url")), 1),
4824
+ _(E, null, {
4825
+ default: l(() => [_(o, {
4826
+ "model-value": s(Le),
4827
+ readonly: "",
4828
+ class: "font-mono text-xs"
4829
+ }, null, 8, ["model-value"]), _(w, null, {
4830
+ default: l(() => [_(ue, {
4831
+ "action-text": s(C)("components.automation_nodes.webhook_secret_copied"),
4832
+ icon: s(S),
4833
+ "button-props": {
4834
+ severity: "secondary",
4835
+ text: !0
4836
+ },
4837
+ onAction: i[4] ||= (e) => Ke(s(Le))
4838
+ }, null, 8, ["action-text", "icon"])]),
4839
+ _: 1
4840
+ })]),
4841
+ _: 1
4842
+ }),
4843
+ _(v, {
4844
+ severity: "secondary",
4845
+ variant: "simple",
4846
+ size: "small",
4847
+ class: "cui-input-hint"
4848
+ }, {
4849
+ default: l(() => [h(a(s(C)("components.automation_nodes.geofence_url_hint")), 1)]),
4850
+ _: 1
4851
+ })
4852
+ ]),
4853
+ s(Re).length ? (r(), d("div", De, [
4854
+ m("label", Oe, a(s(C)("components.automation_nodes.geofence_secret")), 1),
4855
+ (r(!0), d(f, null, n(s(Re), ([e, t]) => (r(), d("div", {
4856
+ key: e,
4857
+ class: "flex flex-col gap-1"
4858
+ }, [m("span", ke, a(e), 1), _(E, null, {
4859
+ default: l(() => [_(o, {
4860
+ "model-value": t,
4861
+ readonly: "",
4862
+ class: "font-mono text-xs"
4863
+ }, null, 8, ["model-value"]), _(w, null, {
4864
+ default: l(() => [_(ue, {
4865
+ "action-text": s(C)("components.automation_nodes.webhook_secret_copied"),
4866
+ icon: s(S),
4867
+ "button-props": {
4868
+ severity: "secondary",
4869
+ text: !0
4870
+ },
4871
+ onAction: (e) => Ke(t)
4872
+ }, null, 8, [
4873
+ "action-text",
4874
+ "icon",
4875
+ "onAction"
4876
+ ])]),
4877
+ _: 2
4878
+ }, 1024)]),
4879
+ _: 2
4880
+ }, 1024)]))), 128)),
4881
+ _(v, {
4882
+ severity: "secondary",
4883
+ variant: "simple",
4884
+ size: "small",
4885
+ class: "cui-input-hint"
4886
+ }, {
4887
+ default: l(() => [h(a(s(C)("components.automation_nodes.geofence_secret_hint")), 1)]),
4888
+ _: 1
4889
+ })
4890
+ ])) : (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)]))
4891
+ ]);
4892
+ };
4893
+ }
4894
+ });
4895
+ //#endregion
4896
+ export { je as default };