hy-dispatch-ui-v3 0.2.66 → 0.2.68

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 (288) hide show
  1. package/dist/tailwind.css +257 -21
  2. package/es/api/device.mjs +2 -3
  3. package/es/api/exportExcel.mjs +57 -0
  4. package/es/api/index.mjs +27 -16
  5. package/es/api/mapRail.mjs +31 -0
  6. package/es/api/organization.mjs +17 -9
  7. package/es/api/rule.mjs +30 -0
  8. package/es/api/sypct.mjs +2 -3
  9. package/es/api/task.mjs +2 -3
  10. package/es/bussiness/hyAddDepartmentType/addDepartmentType.vue.mjs +18 -19
  11. package/es/bussiness/hyAddDepartmentType/style/addDepartmentType.scss +28 -28
  12. package/es/bussiness/hyElectronicFence/cpns/addElectronicFenceDialog/addElectronicFenceDialog.vue.mjs +511 -0
  13. package/es/bussiness/hyElectronicFence/cpns/batchSetElectronicFenceUserDialog/batchSetElectronicFenceUserDialog.vue.mjs +169 -0
  14. package/es/bussiness/hyElectronicFence/cpns/electronicFenceAssociatedUsersDialog/electronicFenceAssociatedUsersDialog.vue.mjs +318 -0
  15. package/es/bussiness/hyElectronicFence/cpns/electronicFenceAssociatedUsersDialog/electronicFenceAssociatedUsersItem.vue.mjs +123 -0
  16. package/es/bussiness/hyElectronicFence/electronicFence.vue.mjs +358 -0
  17. package/es/bussiness/hyElectronicFence/index.mjs +13 -0
  18. package/es/bussiness/hyElectronicFence/style/electronicFence.scss +0 -0
  19. package/es/bussiness/hyMapAearchPlace/js/index.mjs +1 -1
  20. package/es/bussiness/hyMapAearchPlace/mapAearchPlace.vue.mjs +4 -6
  21. package/es/bussiness/hyMapAearchPlace/style/mapAearchPlace.scss +4 -3
  22. package/es/bussiness/hyRuleSetting/cpns/gatheringPeople/gatheringPeople.vue.mjs +270 -0
  23. package/es/bussiness/hyRuleSetting/cpns/missionInRule/missionInRule.vue.mjs +251 -0
  24. package/es/bussiness/hyRuleSetting/cpns/missionOutRule/missionOutRule.vue.mjs +251 -0
  25. package/es/bussiness/hyRuleSetting/cpns/ruleAssignDialog/ruleAssignDialog.vue.mjs +395 -0
  26. package/es/bussiness/hyRuleSetting/cpns/ruleFenceDialog/ruleFenceDialog.vue.mjs +651 -0
  27. package/es/bussiness/hyRuleSetting/cpns/ruleSettingDialog/ruleSettingDialog.vue.mjs +357 -0
  28. package/es/bussiness/hyRuleSetting/cpns/sedentary/sedentary.vue.mjs +261 -0
  29. package/es/bussiness/hyRuleSetting/cpns/setRuleAggregationAlarmDialog/setRuleAggregationAlarmDialog.vue.mjs +360 -0
  30. package/es/bussiness/hyRuleSetting/cpns/timedVideo/timedVideo.vue.mjs +240 -0
  31. package/es/bussiness/hyRuleSetting/cpns/timerCamera/timerCamera.vue.mjs +258 -0
  32. package/es/bussiness/hyRuleSetting/cpns/timingReturn/timingReturn.vue.mjs +240 -0
  33. package/es/bussiness/hyRuleSetting/index.mjs +15 -0
  34. package/es/bussiness/hyRuleSetting/js/ruleSetting.mjs +65 -0
  35. package/es/bussiness/hyRuleSetting/ruleSetting.vue.mjs +129 -0
  36. package/es/bussiness/hyRuleSetting/style/ruleSetting.scss +0 -0
  37. package/es/bussiness/index.mjs +2 -0
  38. package/es/components/hyAudioPlayer/audioPlayer.vue.mjs +5 -13
  39. package/es/components/hyAudioPlayer/js/index.mjs +9 -14
  40. package/es/components/hyAudioPlayer/style/audioPlayer.scss +7 -2
  41. package/es/components/hyBatchUploadDialog/batchUploadDialog.vue.mjs +174 -142
  42. package/es/components/hyButton/button.vue.mjs +18 -5
  43. package/es/components/hyButton/style/button.scss +50 -74
  44. package/es/components/hyCheckboxGroup/checkboxGroup.vue.mjs +119 -0
  45. package/es/components/hyCheckboxGroup/index.mjs +7 -0
  46. package/es/components/hyCheckboxGroup/style/checkboxGroup.scss +58 -0
  47. package/es/components/hyConfigProvider/configProvider.vue.mjs +51 -38
  48. package/es/components/hyConfirmDialog/confirmDialog.vue.mjs +57 -62
  49. package/es/components/hyConfirmDialog/confirmMethod.mjs +24 -22
  50. package/es/components/hyCutter/cutter.vue.mjs +9 -23
  51. package/es/components/hyDatePicker/datePicker.vue.mjs +12 -17
  52. package/es/components/hyDialog/dialog.vue.mjs +5 -9
  53. package/es/components/hyDialog/style/dialog.scss +12 -13
  54. package/es/components/hyDrawer/drawer.vue.mjs +100 -0
  55. package/es/components/hyDrawer/index.mjs +7 -0
  56. package/es/components/hyDrawer/style/drawer.scss +0 -0
  57. package/es/components/hyForm/cpns/arrayItem.vue.mjs +10 -28
  58. package/es/components/hyForm/cpns/arrayItem2.vue.mjs +198 -0
  59. package/es/components/hyForm/cpns/extraItem.vue.mjs +2 -3
  60. package/es/components/hyForm/cpns/formItem.vue.mjs +149 -69
  61. package/es/components/hyForm/cpns/locationSelect.vue.mjs +26 -26
  62. package/es/components/hyForm/form.vue.mjs +74 -28
  63. package/es/components/hyForm/js/index.mjs +4 -8
  64. package/es/components/hyForm/js/useAppForm.mjs +4 -9
  65. package/es/components/hyForm/style/form.scss +4 -13
  66. package/es/components/hyIcon/icon.vue.mjs +3 -3
  67. package/es/components/hyIconBox/style/iconBox.scss +2 -6
  68. package/es/components/hyInput/inputSearch.vue.mjs +8 -11
  69. package/es/components/hyInput/style/inputSearch.scss +3 -0
  70. package/es/components/hyLoading/index.mjs +3 -5
  71. package/es/components/hyMap/js/index.mjs +35 -10
  72. package/es/components/hyMap/map.vue.mjs +30 -6
  73. package/es/components/hyMenu/style/menu.scss +5 -15
  74. package/es/components/hyNoPermissions/noPermissions.vue.mjs +3 -4
  75. package/es/components/hyNoPermissionsMap/noPermissionsMap.vue.mjs +3 -6
  76. package/es/components/hyOrgCascader/js/index.mjs +1 -5
  77. package/es/components/hyOrgCascader/orgCascader.vue.mjs +31 -12
  78. package/es/components/hyOrgCascader/style/orgCascader.scss +7 -0
  79. package/es/components/hyRadioGroup/radioGroup.vue.mjs +48 -41
  80. package/es/components/hyRadioGroup/style/radioGroup.scss +9 -0
  81. package/es/components/hySearch/cpns/searchItem.vue.mjs +409 -324
  82. package/es/components/hySearch/js/index.mjs +1 -4
  83. package/es/components/hySearch/js/useAppSearch.mjs +5 -10
  84. package/es/components/hySearch/search.vue.mjs +23 -20
  85. package/es/components/hySearch/style/search.scss +9 -0
  86. package/es/components/hyStatus/index.mjs +7 -0
  87. package/es/components/hyStatus/status.vue.mjs +110 -0
  88. package/es/components/hyStatus/style/status.scss +0 -0
  89. package/es/components/hyTable/cpns/columnSelect.vue.mjs +24 -28
  90. package/es/components/hyTable/cpns/columnSelectItem.vue.mjs +8 -9
  91. package/es/components/hyTable/cpns/headerItem.vue.mjs +2 -2
  92. package/es/components/hyTable/cpns/virtualTable.vue.mjs +43 -34
  93. package/es/components/hyTable/js/index.mjs +67 -64
  94. package/es/components/hyTable/js/search.mjs +25 -1
  95. package/es/components/hyTable/js/useAppTable.mjs +3 -4
  96. package/es/components/hyTable/style/table.scss +8 -0
  97. package/es/components/hyTable/table.vue.mjs +68 -53
  98. package/es/components/hyTableActionButton/tableActionButton.vue.mjs +13 -6
  99. package/es/components/hyTableForm/batchTableForm.vue.mjs +26 -9
  100. package/es/components/hyTableForm/js/index.mjs +2 -8
  101. package/es/components/hyTableForm/js/useAppTableForm.mjs +3 -8
  102. package/es/components/hyTableForm/style/batchTableForm.scss +26 -54
  103. package/es/components/hyTableForm/style/tableForm.scss +3 -2
  104. package/es/components/hyTableForm/tableForm.vue.mjs +160 -70
  105. package/es/components/hyTimePicker/timePicker.vue.mjs +4 -5
  106. package/es/components/hyTree/js/index.mjs +113 -72
  107. package/es/components/hyTree/style/index.css +1 -1
  108. package/es/components/hyTree/tree.vue.mjs +21 -18
  109. package/es/components/hyUserAvatar/userAvatar.vue.mjs +3 -6
  110. package/es/components/hyVideoPlayer/js/index.mjs +14 -23
  111. package/es/components/hyVideoPlayer/style/videoPlayer.scss +5 -7
  112. package/es/components/hyVideoPlayer/videoPlayer.vue.mjs +16 -26
  113. package/es/components/index.mjs +3 -0
  114. package/es/hooks/index.mjs +6 -2
  115. package/es/hooks/useAudioPlayerConfig.mjs +1 -3
  116. package/es/hooks/useBaseMainStore.mjs +29 -0
  117. package/es/hooks/useCurrentBus.mjs +20 -0
  118. package/es/hooks/useDialog.mjs +327 -0
  119. package/es/hooks/useExportFile.mjs +133 -0
  120. package/es/hooks/useGlobalConfig.mjs +10 -6
  121. package/es/hooks/useLocale.mjs +22 -12
  122. package/es/hooks/usePermissionMap.mjs +1 -3
  123. package/es/hooks/useResizeHandler.mjs +1 -4
  124. package/es/hooks/useResizeObserver.mjs +3 -1
  125. package/es/hooks/useSubscribe.mjs +2 -2
  126. package/es/hooks/useUserAvatarMap.mjs +1 -3
  127. package/es/hooks/useVideoPlayerConfig.mjs +1 -3
  128. package/es/index.mjs +11 -2
  129. package/es/locale/{en.mjs → en_US.mjs} +79 -4
  130. package/es/locale/index.mjs +2 -2
  131. package/es/locale/zh_CN.mjs +79 -2
  132. package/es/style/index.scss +0 -1
  133. package/es/style/tailwind.scss +7 -4
  134. package/es/utils/adaptive.mjs +1 -3
  135. package/es/utils/form.mjs +7 -10
  136. package/es/utils/handler.mjs +4 -8
  137. package/es/utils/input.mjs +8 -9
  138. package/es/utils/is.mjs +3 -1
  139. package/es/utils/map/hook/bigMap.mjs +16 -53
  140. package/es/utils/map/hook/gaode.mjs +53 -33
  141. package/es/utils/map/hook/leafletjs.mjs +38 -82
  142. package/es/utils/map/index.mjs +3 -9
  143. package/es/utils/map/js/webgis.mjs +12 -12
  144. package/es/version.mjs +1 -1
  145. package/lib/api/device.js +2 -3
  146. package/lib/api/exportExcel.js +62 -0
  147. package/lib/api/index.js +27 -16
  148. package/lib/api/mapRail.js +34 -0
  149. package/lib/api/organization.js +17 -8
  150. package/lib/api/rule.js +33 -0
  151. package/lib/api/sypct.js +2 -3
  152. package/lib/api/task.js +2 -3
  153. package/lib/bussiness/hyAddDepartmentType/addDepartmentType.vue.js +17 -18
  154. package/lib/bussiness/hyAddDepartmentType/style/addDepartmentType.scss +28 -28
  155. package/lib/bussiness/hyElectronicFence/cpns/addElectronicFenceDialog/addElectronicFenceDialog.vue.js +515 -0
  156. package/lib/bussiness/hyElectronicFence/cpns/batchSetElectronicFenceUserDialog/batchSetElectronicFenceUserDialog.vue.js +173 -0
  157. package/lib/bussiness/hyElectronicFence/cpns/electronicFenceAssociatedUsersDialog/electronicFenceAssociatedUsersDialog.vue.js +322 -0
  158. package/lib/bussiness/hyElectronicFence/cpns/electronicFenceAssociatedUsersDialog/electronicFenceAssociatedUsersItem.vue.js +127 -0
  159. package/lib/bussiness/hyElectronicFence/electronicFence.vue.js +362 -0
  160. package/lib/bussiness/hyElectronicFence/index.js +21 -0
  161. package/lib/bussiness/hyElectronicFence/style/electronicFence.scss +0 -0
  162. package/lib/bussiness/hyMapAearchPlace/js/index.js +1 -1
  163. package/lib/bussiness/hyMapAearchPlace/mapAearchPlace.vue.js +4 -6
  164. package/lib/bussiness/hyMapAearchPlace/style/mapAearchPlace.scss +4 -3
  165. package/lib/bussiness/hyRuleSetting/cpns/gatheringPeople/gatheringPeople.vue.js +274 -0
  166. package/lib/bussiness/hyRuleSetting/cpns/missionInRule/missionInRule.vue.js +255 -0
  167. package/lib/bussiness/hyRuleSetting/cpns/missionOutRule/missionOutRule.vue.js +255 -0
  168. package/lib/bussiness/hyRuleSetting/cpns/ruleAssignDialog/ruleAssignDialog.vue.js +399 -0
  169. package/lib/bussiness/hyRuleSetting/cpns/ruleFenceDialog/ruleFenceDialog.vue.js +655 -0
  170. package/lib/bussiness/hyRuleSetting/cpns/ruleSettingDialog/ruleSettingDialog.vue.js +361 -0
  171. package/lib/bussiness/hyRuleSetting/cpns/sedentary/sedentary.vue.js +265 -0
  172. package/lib/bussiness/hyRuleSetting/cpns/setRuleAggregationAlarmDialog/setRuleAggregationAlarmDialog.vue.js +364 -0
  173. package/lib/bussiness/hyRuleSetting/cpns/timedVideo/timedVideo.vue.js +244 -0
  174. package/lib/bussiness/hyRuleSetting/cpns/timerCamera/timerCamera.vue.js +262 -0
  175. package/lib/bussiness/hyRuleSetting/cpns/timingReturn/timingReturn.vue.js +244 -0
  176. package/lib/bussiness/hyRuleSetting/index.js +24 -0
  177. package/lib/bussiness/hyRuleSetting/js/ruleSetting.js +68 -0
  178. package/lib/bussiness/hyRuleSetting/ruleSetting.vue.js +133 -0
  179. package/lib/bussiness/hyRuleSetting/style/ruleSetting.scss +0 -0
  180. package/lib/bussiness/index.js +21 -10
  181. package/lib/components/hyAudioPlayer/audioPlayer.vue.js +5 -13
  182. package/lib/components/hyAudioPlayer/js/index.js +9 -14
  183. package/lib/components/hyAudioPlayer/style/audioPlayer.scss +7 -2
  184. package/lib/components/hyBatchUploadDialog/batchUploadDialog.vue.js +173 -141
  185. package/lib/components/hyButton/button.vue.js +17 -4
  186. package/lib/components/hyButton/style/button.scss +50 -74
  187. package/lib/components/hyCheckboxGroup/checkboxGroup.vue.js +123 -0
  188. package/lib/components/hyCheckboxGroup/index.js +12 -0
  189. package/lib/components/hyCheckboxGroup/style/checkboxGroup.scss +58 -0
  190. package/lib/components/hyConfigProvider/configProvider.vue.js +50 -56
  191. package/lib/components/hyConfirmDialog/confirmDialog.vue.js +56 -61
  192. package/lib/components/hyConfirmDialog/confirmMethod.js +23 -21
  193. package/lib/components/hyCutter/cutter.vue.js +8 -22
  194. package/lib/components/hyDatePicker/datePicker.vue.js +11 -16
  195. package/lib/components/hyDialog/dialog.vue.js +5 -9
  196. package/lib/components/hyDialog/style/dialog.scss +12 -13
  197. package/lib/components/hyDrawer/drawer.vue.js +104 -0
  198. package/lib/components/hyDrawer/index.js +12 -0
  199. package/lib/components/hyDrawer/style/drawer.scss +0 -0
  200. package/lib/components/hyForm/cpns/arrayItem.vue.js +9 -27
  201. package/lib/components/hyForm/cpns/arrayItem2.vue.js +202 -0
  202. package/lib/components/hyForm/cpns/extraItem.vue.js +2 -3
  203. package/lib/components/hyForm/cpns/formItem.vue.js +148 -68
  204. package/lib/components/hyForm/cpns/locationSelect.vue.js +26 -26
  205. package/lib/components/hyForm/form.vue.js +69 -23
  206. package/lib/components/hyForm/js/index.js +3 -7
  207. package/lib/components/hyForm/js/useAppForm.js +4 -9
  208. package/lib/components/hyForm/style/form.scss +4 -13
  209. package/lib/components/hyIcon/icon.vue.js +3 -3
  210. package/lib/components/hyIconBox/style/iconBox.scss +2 -6
  211. package/lib/components/hyInput/inputSearch.vue.js +7 -10
  212. package/lib/components/hyInput/style/inputSearch.scss +3 -0
  213. package/lib/components/hyLoading/index.js +2 -4
  214. package/lib/components/hyMap/js/index.js +34 -9
  215. package/lib/components/hyMap/map.vue.js +29 -5
  216. package/lib/components/hyMenu/style/menu.scss +5 -15
  217. package/lib/components/hyNoPermissions/noPermissions.vue.js +3 -4
  218. package/lib/components/hyNoPermissionsMap/noPermissionsMap.vue.js +3 -6
  219. package/lib/components/hyOrgCascader/js/index.js +1 -5
  220. package/lib/components/hyOrgCascader/orgCascader.vue.js +29 -10
  221. package/lib/components/hyOrgCascader/style/orgCascader.scss +7 -0
  222. package/lib/components/hyRadioGroup/radioGroup.vue.js +47 -40
  223. package/lib/components/hyRadioGroup/style/radioGroup.scss +9 -0
  224. package/lib/components/hySearch/cpns/searchItem.vue.js +407 -322
  225. package/lib/components/hySearch/js/index.js +1 -4
  226. package/lib/components/hySearch/js/useAppSearch.js +5 -10
  227. package/lib/components/hySearch/search.vue.js +23 -20
  228. package/lib/components/hySearch/style/search.scss +9 -0
  229. package/lib/components/hyStatus/index.js +12 -0
  230. package/lib/components/hyStatus/status.vue.js +114 -0
  231. package/lib/components/hyStatus/style/status.scss +0 -0
  232. package/lib/components/hyTable/cpns/columnSelect.vue.js +22 -26
  233. package/lib/components/hyTable/cpns/columnSelectItem.vue.js +7 -8
  234. package/lib/components/hyTable/cpns/headerItem.vue.js +2 -2
  235. package/lib/components/hyTable/cpns/virtualTable.vue.js +41 -32
  236. package/lib/components/hyTable/js/index.js +65 -61
  237. package/lib/components/hyTable/js/search.js +25 -1
  238. package/lib/components/hyTable/js/useAppTable.js +2 -3
  239. package/lib/components/hyTable/style/table.scss +8 -0
  240. package/lib/components/hyTable/table.vue.js +67 -52
  241. package/lib/components/hyTableActionButton/tableActionButton.vue.js +13 -6
  242. package/lib/components/hyTableForm/batchTableForm.vue.js +26 -9
  243. package/lib/components/hyTableForm/js/index.js +2 -8
  244. package/lib/components/hyTableForm/js/useAppTableForm.js +3 -8
  245. package/lib/components/hyTableForm/style/batchTableForm.scss +26 -54
  246. package/lib/components/hyTableForm/style/tableForm.scss +3 -2
  247. package/lib/components/hyTableForm/tableForm.vue.js +159 -69
  248. package/lib/components/hyTimePicker/timePicker.vue.js +3 -4
  249. package/lib/components/hyTree/js/index.js +113 -72
  250. package/lib/components/hyTree/style/index.css +1 -1
  251. package/lib/components/hyTree/tree.vue.js +21 -18
  252. package/lib/components/hyUserAvatar/userAvatar.vue.js +3 -6
  253. package/lib/components/hyVideoPlayer/js/index.js +14 -23
  254. package/lib/components/hyVideoPlayer/style/videoPlayer.scss +5 -7
  255. package/lib/components/hyVideoPlayer/videoPlayer.vue.js +16 -26
  256. package/lib/components/index.js +46 -40
  257. package/lib/hooks/index.js +17 -0
  258. package/lib/hooks/useAudioPlayerConfig.js +1 -3
  259. package/lib/hooks/useBaseMainStore.js +32 -0
  260. package/lib/hooks/useCurrentBus.js +23 -0
  261. package/lib/hooks/useDialog.js +331 -0
  262. package/lib/hooks/useExportFile.js +135 -0
  263. package/lib/hooks/useGlobalConfig.js +10 -6
  264. package/lib/hooks/useLocale.js +25 -11
  265. package/lib/hooks/usePermissionMap.js +1 -3
  266. package/lib/hooks/useResizeHandler.js +1 -4
  267. package/lib/hooks/useResizeObserver.js +3 -1
  268. package/lib/hooks/useSubscribe.js +2 -1
  269. package/lib/hooks/useUserAvatarMap.js +1 -3
  270. package/lib/hooks/useVideoPlayerConfig.js +1 -3
  271. package/lib/index.js +107 -73
  272. package/lib/locale/{en.js → en_US.js} +79 -4
  273. package/lib/locale/index.js +3 -3
  274. package/lib/locale/zh_CN.js +79 -2
  275. package/lib/style/index.scss +0 -1
  276. package/lib/style/tailwind.scss +7 -4
  277. package/lib/utils/adaptive.js +1 -3
  278. package/lib/utils/form.js +6 -9
  279. package/lib/utils/handler.js +3 -7
  280. package/lib/utils/input.js +7 -8
  281. package/lib/utils/is.js +5 -3
  282. package/lib/utils/map/hook/bigMap.js +16 -53
  283. package/lib/utils/map/hook/gaode.js +53 -33
  284. package/lib/utils/map/hook/leafletjs.js +38 -82
  285. package/lib/utils/map/index.js +3 -9
  286. package/lib/utils/map/js/webgis.js +12 -12
  287. package/lib/version.js +1 -1
  288. package/package.json +3 -2
@@ -1,14 +1,14 @@
1
- import { defineComponent, useTemplateRef, computed, ref, reactive, unref, provide, toRefs, onMounted, nextTick, openBlock, createBlock, mergeProps, withCtx, createElementVNode, normalizeStyle, createCommentVNode, createElementBlock, Fragment, renderList, normalizeClass, toDisplayString, createVNode, createSlots, renderSlot } from 'vue';
1
+ import { defineComponent, useTemplateRef, inject, ref, computed, reactive, provide, toRefs, onMounted, watch, unref, nextTick, openBlock, createBlock, mergeProps, withCtx, createElementVNode, normalizeStyle, createCommentVNode, createElementBlock, Fragment, renderList, normalizeClass, toDisplayString, createVNode, createSlots, renderSlot } from 'vue';
2
2
  import { ElForm, ElDivider } from 'element-plus';
3
3
  import '../../hooks/index.mjs';
4
4
  import '../../utils/index.mjs';
5
- import _sfc_main$4 from './cpns/formItem.vue.mjs';
5
+ import _sfc_main$5 from './cpns/formItem.vue.mjs';
6
6
  import _sfc_main$1 from './cpns/extraItem.vue.mjs';
7
7
  import _sfc_main$2 from './cpns/arrayItem.vue.mjs';
8
- import _sfc_main$3 from './cpns/locationSelect.vue.mjs';
8
+ import _sfc_main$3 from './cpns/arrayItem2.vue.mjs';
9
+ import _sfc_main$4 from './cpns/locationSelect.vue.mjs';
9
10
  import { formContextKey, columnShowHandler, columnItemStyle } from './js/index.mjs';
10
11
  import { resetAppFormValue } from './js/useAppForm.mjs';
11
- import { useLocale } from '../../hooks/useLocale.mjs';
12
12
  import { isArray, isNumber } from '../../utils/is.mjs';
13
13
 
14
14
  import "./style/form.scss";
@@ -50,14 +50,22 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
50
50
  type: String,
51
51
  default: "default"
52
52
  // 'large' | 'default' | 'small'
53
+ },
54
+ showMessage: {
55
+ type: Boolean,
56
+ default: true
57
+ },
58
+ isTableForm: {
59
+ type: Boolean,
60
+ default: false
53
61
  }
54
62
  },
55
- emits: ["on-allMapSelect", "complete"],
63
+ emits: ["on-allMapSelect", "complete", "optionsStatus"],
56
64
  setup(__props, { expose: __expose, emit: __emit }) {
57
65
  const props = __props;
58
66
  const emits = __emit;
59
- const { t } = useLocale();
60
67
  const formTemplateRef = useTemplateRef("formTemplateRef");
68
+ const validateTriggerId = inject("validateTriggerId", ref(0));
61
69
  const formColumnMap = computed(() => {
62
70
  return (props.columns || []).reduce((map, column) => {
63
71
  if (isArray(column.field)) {
@@ -88,31 +96,34 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
88
96
  fields.push(field);
89
97
  }
90
98
  const removeField = (field) => {
91
- if (unref(field.columnAttrs)) {
99
+ if (field.propString) {
92
100
  fields.splice(fields.indexOf(field), 1);
93
101
  }
94
102
  };
95
103
  function filterFields(fields2 = [], keys = []) {
96
104
  const filterKeys = keys.map((prop) => isArray(prop) ? prop.join(".") : prop);
97
- return filterKeys.length ? fields2.filter(
98
- (field) => field.propString && filterKeys.includes(field.propString)
99
- ) : fields2;
105
+ return filterKeys.length ? fields2.filter((field) => field.propString && filterKeys.includes(field.propString)) : fields2;
100
106
  }
101
- async function obtainOptionsFields(keys) {
107
+ async function obtainOptionsFields(keys, isMountedLoad = false) {
102
108
  const filteredFields = filterFields(fields, keys);
103
- await Promise.allSettled(filteredFields.map((field) => field.obtainOptions()));
109
+ await Promise.allSettled(filteredFields.map((field) => field.obtainOptions(isMountedLoad)));
104
110
  }
105
- async function getOptions() {
106
- await obtainOptionsFields();
111
+ async function getOptions(isMountedLoad = false) {
112
+ await obtainOptionsFields([], isMountedLoad);
113
+ emitOptionsStatus();
107
114
  }
108
115
  async function getOptionsFields(keys) {
109
116
  await obtainOptionsFields(keys);
117
+ emitOptionsStatus();
110
118
  }
111
119
  async function getOptionsError() {
112
- const filteredFields = fields.filter(
113
- (field) => field.propString && field.optionsError
114
- );
120
+ const filteredFields = fields.filter((field) => field.propString && field.optionsError);
115
121
  await Promise.allSettled(filteredFields.map((field) => field.obtainOptions()));
122
+ emitOptionsStatus();
123
+ }
124
+ function emitOptionsStatus() {
125
+ const hasError = fields.some((item) => item.optionsError === "error");
126
+ emits("optionsStatus", { result: !hasError });
116
127
  }
117
128
  provide(
118
129
  formContextKey,
@@ -120,11 +131,16 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
120
131
  ...toRefs(props),
121
132
  emits,
122
133
  addField,
123
- removeField
134
+ removeField,
135
+ emitOptionsStatus
124
136
  })
125
137
  );
126
138
  onMounted(() => {
127
- getOptions();
139
+ getOptions(true);
140
+ watch(validateTriggerId, () => {
141
+ unref(formTemplateRef).validate(() => {
142
+ });
143
+ });
128
144
  });
129
145
  __expose({
130
146
  validate: async (callback) => {
@@ -158,10 +174,19 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
158
174
  await nextTick();
159
175
  return unref(formTemplateRef).getField(fields2);
160
176
  },
161
- setMarker: (latlng) => {
177
+ setMarker: async (latlng, getAddress = false) => {
162
178
  if (locationSelectRef.value) {
163
- isArray(locationSelectRef.value) ? locationSelectRef.value.map((item) => item.setMarker(latlng)) : locationSelectRef.value.setMarker(latlng);
179
+ if (isArray(locationSelectRef.value)) {
180
+ await Promise.all(
181
+ locationSelectRef.value.map(
182
+ (item) => item.setMarker(latlng, getAddress)
183
+ )
184
+ );
185
+ } else {
186
+ await locationSelectRef.value.setMarker(latlng, getAddress);
187
+ }
164
188
  }
189
+ return 200;
165
190
  },
166
191
  clearMarker: () => {
167
192
  if (locationSelectRef.value) {
@@ -219,10 +244,7 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
219
244
  "div",
220
245
  {
221
246
  key: 0,
222
- class: normalizeClass(["w-full flex items-center text-theme whitespace-nowrap relative mb-3 mt-1", [
223
- __props.size === "small" ? "text-xs" : "text-sm",
224
- allMapSelect.value ? "hidden" : ""
225
- ]]),
247
+ class: normalizeClass(["w-full flex items-center text-theme whitespace-nowrap relative mb-3 mt-1", [__props.size === "small" ? "text-xs" : "text-sm", allMapSelect.value ? "hidden" : ""]]),
226
248
  style: normalizeStyle(unref(columnItemStyle)(props, column))
227
249
  },
228
250
  [
@@ -283,7 +305,7 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
283
305
  { key: 2 },
284
306
  [
285
307
  createCommentVNode(" \u8868\u5355\u6570\u7EC4 "),
286
- unref(columnShowHandler)(props, column) ? (openBlock(), createBlock(_sfc_main$2, {
308
+ !__props.isTableForm && unref(columnShowHandler)(props, column) ? (openBlock(), createBlock(_sfc_main$2, {
287
309
  key: 0,
288
310
  class: normalizeClass([allMapSelect.value ? "hidden" : ""]),
289
311
  model: __props.model,
@@ -307,6 +329,30 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
307
329
  ])
308
330
  };
309
331
  })
332
+ ]), 1032, ["class", "model", "column", "rules", "columnNum", "loading", "disabled", "readonly", "size", "style"])) : __props.isTableForm && unref(columnShowHandler)(props, column) ? (openBlock(), createBlock(_sfc_main$3, {
333
+ key: 1,
334
+ class: normalizeClass([allMapSelect.value ? "hidden" : ""]),
335
+ model: __props.model,
336
+ column,
337
+ rules: __props.rules,
338
+ columnNum: __props.columnNum,
339
+ loading: __props.loading,
340
+ disabled: __props.disabled,
341
+ readonly: __props.readonly,
342
+ size: __props.size,
343
+ style: normalizeStyle(unref(columnItemStyle)(props, column))
344
+ }, createSlots({
345
+ _: 2
346
+ /* DYNAMIC */
347
+ }, [
348
+ renderList(_ctx.$slots, (_, slotName) => {
349
+ return {
350
+ name: slotName,
351
+ fn: withCtx((scope) => [
352
+ renderSlot(_ctx.$slots, slotName, mergeProps({ ref_for: true }, scope))
353
+ ])
354
+ };
355
+ })
310
356
  ]), 1032, ["class", "model", "column", "rules", "columnNum", "loading", "disabled", "readonly", "size", "style"])) : createCommentVNode("v-if", true)
311
357
  ],
312
358
  64
@@ -315,7 +361,7 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
315
361
  Fragment,
316
362
  { key: 3 },
317
363
  [
318
- unref(columnShowHandler)(props, column) ? (openBlock(), createBlock(_sfc_main$3, {
364
+ unref(columnShowHandler)(props, column) ? (openBlock(), createBlock(_sfc_main$4, {
319
365
  key: 0,
320
366
  ref_for: true,
321
367
  ref_key: "locationSelectRef",
@@ -341,7 +387,7 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
341
387
  { key: 4 },
342
388
  [
343
389
  createCommentVNode(" \u8868\u5355 "),
344
- createVNode(_sfc_main$4, {
390
+ createVNode(_sfc_main$5, {
345
391
  class: normalizeClass([allMapSelect.value ? "hidden" : ""]),
346
392
  model: __props.model,
347
393
  column,
@@ -4,7 +4,7 @@ import '../../../hooks/index.mjs';
4
4
  import { funRunHandler } from '../../../utils/handler.mjs';
5
5
  import { isNumber, isBoolean, isFunction, isString, isArray, isObject } from '../../../utils/is.mjs';
6
6
  import { columnRuleHandler, getValueByProp } from '../../../utils/form.mjs';
7
- import { useLocale } from '../../../hooks/useLocale.mjs';
7
+ import { $t } from '../../../hooks/useLocale.mjs';
8
8
 
9
9
  const formContextKey = /* @__PURE__ */ Symbol("formContextKey");
10
10
  function columnItemStyle(props, column) {
@@ -88,9 +88,7 @@ function renderText(props, column = {}) {
88
88
  }
89
89
  if (/^(select|radio|checkbox)$/.test(type)) {
90
90
  const optionList = optionsHandler(props, column);
91
- const target = optionList.find(
92
- (item) => item[fieldNames.value] === columnValue
93
- );
91
+ const target = optionList.find((item) => item[fieldNames.value] === columnValue);
94
92
  return target?.[fieldNames.label] || columnValue || "";
95
93
  }
96
94
  if (Array.isArray(field)) {
@@ -102,16 +100,14 @@ function renderText(props, column = {}) {
102
100
  return columnValue || "";
103
101
  }
104
102
  function renderArrayItemLabel(props, column, index) {
105
- const { t } = useLocale();
106
103
  const itemLabel = unref(column.itemLabel);
107
104
  if (isFunction(itemLabel)) return itemLabel(column, index);
108
- return (itemLabel || t("form.dynamicFormItem")) + ` ${index + 1}`;
105
+ return (itemLabel || $t("form.dynamicFormItem")) + ` ${index + 1}`;
109
106
  }
110
107
  function renderAddLabel(props, column) {
111
- const { t } = useLocale();
112
108
  let addLabel = unref(column.addLabel);
113
109
  if (isFunction(addLabel)) return addLabel();
114
- return addLabel || t("form.addFormItem");
110
+ return addLabel || $t("form.addFormItem");
115
111
  }
116
112
  function optionsHandler(props, column) {
117
113
  const options = unref(column.attrs.options);
@@ -1,5 +1,4 @@
1
1
  import { unref, toRef } from 'vue';
2
- import '../../../hooks/index.mjs';
3
2
  import '../../../utils/index.mjs';
4
3
  import { genColumnDefaultLabel, genValueByProp } from '../../../utils/form.mjs';
5
4
  import { mergeDeep, funRunHandler } from '../../../utils/handler.mjs';
@@ -23,11 +22,11 @@ function appFormItemHandler(column = {}) {
23
22
  return {
24
23
  ...column,
25
24
  attrs: {
26
- maxlength: attrs.type === "textarea" ? 255 : attrs.type === "text" ? 100 : void 0,
25
+ maxlength: attrs.type === "text" ? 255 : void 0,
27
26
  ...attrs
28
27
  }
29
28
  };
30
- } else if (/^(radio|radio-group|checkbox|select|select-v2)$/.test(column.type)) {
29
+ } else if (/^(radio|radio-group|checkbox|checkbox-group|select|select-v2)$/.test(column.type)) {
31
30
  return {
32
31
  ...column,
33
32
  attrs: {
@@ -48,7 +47,7 @@ function appFormItemHandler(column = {}) {
48
47
  };
49
48
  } else if (/^(array)$/.test(column.type)) {
50
49
  return {
51
- height: 500,
50
+ height: void 0,
52
51
  emptyChildren: false,
53
52
  ...column,
54
53
  children: (column.children || []).map((item) => appFormItemHandler(item))
@@ -81,11 +80,7 @@ const resetAppFormValue = (columns = [], obj = {}) => {
81
80
  resetAppFormValue(item.children, obj);
82
81
  } else if (Array.isArray(item.prop)) {
83
82
  for (let i = 0; i < item.prop.length; i++) {
84
- genValueByProp(
85
- obj,
86
- item.prop[i],
87
- Array.isArray(value) ? value[i] : void 0
88
- );
83
+ genValueByProp(obj, item.prop[i], Array.isArray(value) ? value[i] : void 0);
89
84
  }
90
85
  } else {
91
86
  genValueByProp(obj, item.prop, value);
@@ -25,6 +25,7 @@
25
25
  transition: all 0.1s linear;
26
26
  user-select: none;
27
27
  z-index: 2;
28
+ box-sizing: border-box;
28
29
  .hy-form-extra-arrow {
29
30
  transform: rotateZ(90deg) rotateY(0deg);
30
31
  transition: all 0.3s linear;
@@ -34,11 +35,7 @@
34
35
  border-color: rgba(var(--hy-theme));
35
36
  box-shadow: 0px 0px 12px 1px rgba(var(--hy-theme), 0.5);
36
37
  & + .hy-form-extra-line {
37
- background: radial-gradient(
38
- circle,
39
- rgba(var(--hy-theme), 1),
40
- rgba(var(--hy-theme), 0)
41
- );
38
+ background: radial-gradient(circle, rgba(var(--hy-theme), 1), rgba(var(--hy-theme), 0));
42
39
  }
43
40
  }
44
41
  &.expand {
@@ -47,7 +44,7 @@
47
44
  }
48
45
  }
49
46
  }
50
-
47
+
51
48
  .hy-form-extra-line {
52
49
  width: 100%;
53
50
  height: 2px;
@@ -56,12 +53,6 @@
56
53
  top: 50%;
57
54
  transform: translateY(-50%);
58
55
  pointer-events: none;
59
- background: radial-gradient(
60
- circle,
61
- rgba(var(--hy-auxiliary), 1),
62
- rgba(var(--hy-auxiliary), 0)
63
- );
56
+ background: radial-gradient(circle, rgba(var(--hy-auxiliary), 1), rgba(var(--hy-auxiliary), 0));
64
57
  }
65
58
  }
66
-
67
-
@@ -32,11 +32,11 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
32
32
  }
33
33
  const iconName = computed(() => `#${props.prefix}${props.svgName}`);
34
34
  const svgClass = computed(() => {
35
+ const classList = ["hy-icon"];
35
36
  if (props.className) {
36
- return "hy-icon " + props.className || "";
37
- } else {
38
- return "hy-icon";
37
+ classList.push(props.className);
39
38
  }
39
+ return classList.filter(Boolean).join(" ");
40
40
  });
41
41
  return (_ctx, _cache) => {
42
42
  return openBlock(), createElementBlock("svg", {
@@ -14,14 +14,10 @@
14
14
  user-select: none;
15
15
  border-radius: 100%;
16
16
  background:
17
- radial-gradient(
18
- 142% 47% at 50% 119%,
19
- rgb(var(--hy-theme), 0.5) 0%,
20
- rgb(var(--hy-theme), 0) 100%
21
- ),
17
+ radial-gradient(142% 47% at 50% 119%, rgb(var(--hy-theme), 0.5) 0%, rgb(var(--hy-theme), 0) 100%),
22
18
  rgb(var(--hy-background-3));
23
19
  border: 1px solid rgb(var(--hy-auxiliary), 0.5);
24
20
  box-shadow: 0px 2px 5px 0px rgba(29, 33, 41, 0.5);
21
+ box-sizing: border-box;
25
22
  }
26
23
  }
27
-
@@ -1,7 +1,7 @@
1
- import { defineComponent, useModel, useTemplateRef, ref, computed, openBlock, createElementBlock, normalizeClass, renderSlot, createVNode, mergeProps, withKeys, createSlots, renderList, withCtx, normalizeProps, guardReactiveProps, createElementVNode, unref, mergeModels } from 'vue';
2
- import { ElIcon } from 'element-plus';
3
- import { Search } from '@element-plus/icons-vue';
4
- import _sfc_main$1 from './input.vue.mjs';
1
+ import { defineComponent, useModel, useTemplateRef, ref, computed, openBlock, createElementBlock, normalizeClass, renderSlot, createVNode, unref, mergeProps, withKeys, createSlots, renderList, withCtx, normalizeProps, guardReactiveProps, createElementVNode, mergeModels } from 'vue';
2
+ import '../../index.mjs';
3
+ import { HyInput } from './index.mjs';
4
+ import { HyIcon } from '../hyIcon/index.mjs';
5
5
 
6
6
  import "./style/inputSearch.scss";
7
7
 
@@ -75,7 +75,7 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
75
75
  },
76
76
  [
77
77
  renderSlot(_ctx.$slots, "before"),
78
- createVNode(_sfc_main$1, mergeProps({
78
+ createVNode(unref(HyInput), mergeProps({
79
79
  ref_key: "inputRef",
80
80
  ref: inputRef,
81
81
  modelValue: modelValue.value,
@@ -104,12 +104,9 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
104
104
  class: "w-[32px] h-[32px] flex-shrink-0 flex items-center justify-center bg-background-3 rounded-[2px] cursor-pointer",
105
105
  onClick: onSearchQueryHandler
106
106
  }, [
107
- createVNode(unref(ElIcon), { size: "18" }, {
108
- default: withCtx(() => [
109
- createVNode(unref(Search))
110
- ]),
111
- _: 1
112
- /* STABLE */
107
+ createVNode(unref(HyIcon), {
108
+ "svg-name": "dispatch-share-v3-base-search",
109
+ class: "w-[18px] h-[18px]"
113
110
  })
114
111
  ])
115
112
  ],
@@ -10,6 +10,7 @@
10
10
  padding: 2px 4px;
11
11
  overflow: hidden;
12
12
  background: rgba(var(--hy-background-2));
13
+ box-sizing: border-box;
13
14
  &:hover,
14
15
  &.focus {
15
16
  border: 1px solid rgba(var(--hy-theme));
@@ -21,6 +22,7 @@
21
22
  & > .hy-el-input__wrapper {
22
23
  padding-left: 8px;
23
24
  padding-right: 4px;
25
+ box-sizing: border-box;
24
26
  }
25
27
  .hy-el-input__inner::placeholder {
26
28
  font-size: 12px;
@@ -34,6 +36,7 @@
34
36
  box-shadow: none;
35
37
  padding: 4px;
36
38
  min-height: 100%;
39
+ box-sizing: border-box;
37
40
  }
38
41
  }
39
42
  }
@@ -2,7 +2,7 @@ import { ElLoading } from 'element-plus';
2
2
  import '../../utils/index.mjs';
3
3
  import '../../hooks/index.mjs';
4
4
  import { loadingSvg } from '../../utils/sharedContent.mjs';
5
- import { useLocale } from '../../hooks/useLocale.mjs';
5
+ import { $t } from '../../hooks/useLocale.mjs';
6
6
 
7
7
  const loadingConfig = {
8
8
  svg: loadingSvg,
@@ -20,8 +20,7 @@ const HyLoading = {
20
20
  directive: {
21
21
  ...ElLoading.directive,
22
22
  mounted: function(el, binding, vnode, prevVnode) {
23
- const { t } = useLocale();
24
- el.setAttribute("element-loading-text", `${t("hy.loading")}...`);
23
+ el.setAttribute("element-loading-text", `${$t("hy.loading")}...`);
25
24
  el.setAttribute("element-loading-svg", loadingConfig.svg);
26
25
  el.setAttribute("element-loading-svg-view-box", loadingConfig.svgViewBox);
27
26
  el.setAttribute("element-loading-background", loadingConfig.background);
@@ -29,9 +28,8 @@ const HyLoading = {
29
28
  }
30
29
  },
31
30
  service: function(options = {}) {
32
- const { t } = useLocale();
33
31
  return ElLoading.service.call(this, {
34
- text: `${t("hy.loading")}...`,
32
+ text: `${$t("hy.loading")}...`,
35
33
  ...loadingConfig,
36
34
  ...options
37
35
  });
@@ -1,14 +1,16 @@
1
1
  import { InitMap } from '../../../utils/map/index.mjs';
2
- import { nextTick } from 'vue';
2
+ import { shallowRef, nextTick } from 'vue';
3
3
 
4
4
  const useAppMapWrapper = (hy) => {
5
5
  const {
6
6
  props: { mapConfig },
7
7
  mapRef,
8
- emits
8
+ emits,
9
+ isUnmounted
9
10
  } = hy;
10
- const hyMap = null;
11
- const map = null;
11
+ let hyMap = shallowRef(null);
12
+ let map = shallowRef(null);
13
+ let initTimer = null;
12
14
  function newMap(mapType) {
13
15
  const mapFilters = [
14
16
  {
@@ -92,7 +94,7 @@ const useAppMapWrapper = (hy) => {
92
94
  filter: "saturate(180%) brightness(105%) contrast(115%)"
93
95
  }
94
96
  ];
95
- hy.hyMap = new InitMap({
97
+ hy.hyMap.value = new InitMap({
96
98
  ...mapConfig,
97
99
  mapType,
98
100
  BM: window.BM
@@ -110,12 +112,28 @@ const useAppMapWrapper = (hy) => {
110
112
  // },
111
113
  // ], // 地图瓦片地址
112
114
  });
113
- setTimeout(() => {
114
- hy.initMap();
115
+ if (initTimer) {
116
+ clearTimeout(initTimer);
117
+ }
118
+ initTimer = setTimeout(() => {
119
+ if (!isUnmounted.value) {
120
+ hy.initMap();
121
+ }
122
+ initTimer = null;
115
123
  }, 800);
116
124
  }
117
125
  function initMap() {
118
- hy.map = hy.hyMap.InitMap(mapRef.value, {
126
+ if (isUnmounted.value || !mapRef.value) {
127
+ return;
128
+ }
129
+ const container = mapRef.value;
130
+ if (container) {
131
+ delete container._leaflet_id;
132
+ delete container._bm_id;
133
+ delete container._amap_id;
134
+ container.innerHTML = "";
135
+ }
136
+ hy.map.value = hy.hyMap.value.InitMap(mapRef.value, {
119
137
  minZoom: mapConfig.minZoom || 8,
120
138
  maxZoom: mapConfig.maxZoom || 18,
121
139
  center: mapConfig.center || {
@@ -125,16 +143,23 @@ const useAppMapWrapper = (hy) => {
125
143
  zoom: mapConfig.zoom || 14,
126
144
  completeCallbacks: () => {
127
145
  nextTick(() => {
128
- emits("complete", hy.hyMap, hy.map);
146
+ emits("complete", hy.hyMap.value, hy.map.value);
129
147
  });
130
148
  }
131
149
  });
132
150
  }
151
+ function clearInitTimer() {
152
+ if (initTimer) {
153
+ clearTimeout(initTimer);
154
+ initTimer = null;
155
+ }
156
+ }
133
157
  return {
134
158
  hyMap,
135
159
  map,
136
160
  newMap,
137
- initMap
161
+ initMap,
162
+ clearInitTimer
138
163
  };
139
164
  };
140
165
 
@@ -1,7 +1,9 @@
1
- import { ref, onMounted, openBlock, createElementBlock, createElementVNode } from 'vue';
1
+ import { ref, onMounted, onBeforeUnmount, openBlock, createElementBlock, createBlock, unref } from 'vue';
2
2
  import '../../hooks/index.mjs';
3
+ import '../../index.mjs';
3
4
  import { useAppMapWrapper } from './js/index.mjs';
4
5
  import { useMixins } from '../../hooks/useMixins.mjs';
6
+ import { HyNoPermissionsMap } from '../hyNoPermissionsMap/index.mjs';
5
7
  import { useMapConfig } from '../../hooks/useMapConfig.mjs';
6
8
 
7
9
  import "../../static/map/bigemap.css";
@@ -35,22 +37,44 @@ const _sfc_main = {
35
37
  const props = __props;
36
38
  const emits = __emit;
37
39
  const mapRef = ref();
38
- const { newMap, map, hyMap } = useMixins(
40
+ const isUnmounted = ref(false);
41
+ const { newMap, map, hyMap, clearInitTimer } = useMixins(
39
42
  {
40
43
  props,
41
44
  emits,
42
- mapRef
45
+ mapRef,
46
+ isUnmounted
43
47
  },
44
48
  [useAppMapWrapper]
45
49
  );
46
50
  onMounted(() => {
47
- newMap(props.mapType);
51
+ if (props.mapType !== "nomap") {
52
+ newMap(props.mapType);
53
+ }
54
+ });
55
+ onBeforeUnmount(() => {
56
+ isUnmounted.value = true;
57
+ clearInitTimer();
58
+ try {
59
+ map.value?.removeMap();
60
+ } catch (error) {
61
+ console.warn("\u5730\u56FE\u5378\u8F7D\u8B66\u544A:", error);
62
+ }
63
+ map.value = null;
64
+ hyMap.value = null;
65
+ if (mapRef.value) {
66
+ mapRef.value.innerHTML = "";
67
+ delete mapRef.value._leaflet_id;
68
+ delete mapRef.value._bm_id;
69
+ delete mapRef.value._amap_id;
70
+ }
48
71
  });
49
72
  return (_ctx, _cache) => {
50
73
  return openBlock(), createElementBlock("div", { class: "w-full h-full box-border border-border border relative" }, [
51
- createElementVNode(
74
+ props.mapType !== "nomap" ? (openBlock(), createElementBlock(
52
75
  "div",
53
76
  {
77
+ key: 0,
54
78
  ref_key: "mapRef",
55
79
  ref: mapRef,
56
80
  class: "w-full h-full rounded overflow-hidden"
@@ -58,7 +82,7 @@ const _sfc_main = {
58
82
  null,
59
83
  512
60
84
  /* NEED_PATCH */
61
- )
85
+ )) : (openBlock(), createBlock(unref(HyNoPermissionsMap), { key: 1 }))
62
86
  ]);
63
87
  };
64
88
  }
@@ -10,12 +10,9 @@
10
10
  transition: all 0.3s linear;
11
11
  background:
12
12
  linear-gradient(180deg, rgba(33, 58, 84, 0.3) 0.08%, #213a54 100%),
13
- radial-gradient(
14
- 21% 31% at 150% 40%,
15
- rgba(61, 98, 134, 0.5) 0%,
16
- rgba(61, 98, 134, 0) 100%
17
- );
13
+ radial-gradient(21% 31% at 150% 40%, rgba(61, 98, 134, 0.5) 0%, rgba(61, 98, 134, 0) 100%);
18
14
  border-right: 1px solid rgba(var(--hy-border));
15
+ box-sizing: border-box;
19
16
 
20
17
  .operator-menu-list {
21
18
  width: 100%;
@@ -34,6 +31,7 @@
34
31
  font-size: 16px;
35
32
  position: relative;
36
33
  cursor: pointer;
34
+ box-sizing: border-box;
37
35
 
38
36
  .operator-label {
39
37
  width: 100%;
@@ -72,11 +70,7 @@
72
70
  position: absolute;
73
71
  left: 0;
74
72
  top: 3px;
75
- background: linear-gradient(
76
- 90deg,
77
- rgba(var(--hy-theme), 0) 2%,
78
- rgba(var(--hy-theme), 0.4) 100%
79
- );
73
+ background: linear-gradient(90deg, rgba(var(--hy-theme), 0) 2%, rgba(var(--hy-theme), 0.4) 100%);
80
74
  border-radius: 0px 4px 4px 0px;
81
75
  }
82
76
  }
@@ -135,11 +129,7 @@
135
129
  position: absolute;
136
130
  left: 0;
137
131
  top: 0;
138
- background: linear-gradient(
139
- 90deg,
140
- rgba(var(--hy-theme), 0) 2%,
141
- rgba(var(--hy-theme), 0.4) 100%
142
- );
132
+ background: linear-gradient(90deg, rgba(var(--hy-theme), 0) 2%, rgba(var(--hy-theme), 0.4) 100%);
143
133
  //border-radius: 0px 4px 4px 0px;
144
134
  }
145
135
  }