hy-dispatch-ui-v3 0.2.67 → 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 (280) hide show
  1. package/dist/tailwind.css +232 -20
  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/hyButton/button.vue.mjs +2 -2
  42. package/es/components/hyButton/style/button.scss +48 -74
  43. package/es/components/hyCheckboxGroup/checkboxGroup.vue.mjs +119 -0
  44. package/es/components/hyCheckboxGroup/index.mjs +7 -0
  45. package/es/components/hyCheckboxGroup/style/checkboxGroup.scss +58 -0
  46. package/es/components/hyConfigProvider/configProvider.vue.mjs +51 -38
  47. package/es/components/hyConfirmDialog/confirmDialog.vue.mjs +57 -62
  48. package/es/components/hyConfirmDialog/confirmMethod.mjs +24 -22
  49. package/es/components/hyCutter/cutter.vue.mjs +9 -23
  50. package/es/components/hyDatePicker/datePicker.vue.mjs +12 -17
  51. package/es/components/hyDialog/dialog.vue.mjs +5 -9
  52. package/es/components/hyDialog/style/dialog.scss +12 -13
  53. package/es/components/hyDrawer/drawer.vue.mjs +100 -0
  54. package/es/components/hyDrawer/index.mjs +7 -0
  55. package/es/components/hyDrawer/style/drawer.scss +0 -0
  56. package/es/components/hyForm/cpns/arrayItem.vue.mjs +10 -28
  57. package/es/components/hyForm/cpns/arrayItem2.vue.mjs +198 -0
  58. package/es/components/hyForm/cpns/extraItem.vue.mjs +2 -3
  59. package/es/components/hyForm/cpns/formItem.vue.mjs +65 -35
  60. package/es/components/hyForm/cpns/locationSelect.vue.mjs +26 -26
  61. package/es/components/hyForm/form.vue.mjs +56 -24
  62. package/es/components/hyForm/js/index.mjs +4 -8
  63. package/es/components/hyForm/js/useAppForm.mjs +4 -9
  64. package/es/components/hyForm/style/form.scss +4 -13
  65. package/es/components/hyIcon/icon.vue.mjs +3 -3
  66. package/es/components/hyIconBox/style/iconBox.scss +2 -6
  67. package/es/components/hyInput/inputSearch.vue.mjs +8 -11
  68. package/es/components/hyInput/style/inputSearch.scss +3 -0
  69. package/es/components/hyLoading/index.mjs +3 -5
  70. package/es/components/hyMap/js/index.mjs +29 -4
  71. package/es/components/hyMap/map.vue.mjs +17 -3
  72. package/es/components/hyMenu/style/menu.scss +5 -15
  73. package/es/components/hyNoPermissions/noPermissions.vue.mjs +3 -4
  74. package/es/components/hyNoPermissionsMap/noPermissionsMap.vue.mjs +3 -6
  75. package/es/components/hyOrgCascader/js/index.mjs +1 -5
  76. package/es/components/hyOrgCascader/orgCascader.vue.mjs +25 -11
  77. package/es/components/hyOrgCascader/style/orgCascader.scss +7 -0
  78. package/es/components/hyRadioGroup/radioGroup.vue.mjs +48 -41
  79. package/es/components/hyRadioGroup/style/radioGroup.scss +9 -0
  80. package/es/components/hySearch/cpns/searchItem.vue.mjs +33 -20
  81. package/es/components/hySearch/js/index.mjs +1 -4
  82. package/es/components/hySearch/js/useAppSearch.mjs +5 -10
  83. package/es/components/hySearch/search.vue.mjs +9 -16
  84. package/es/components/hySearch/style/search.scss +2 -0
  85. package/es/components/hyStatus/index.mjs +7 -0
  86. package/es/components/hyStatus/status.vue.mjs +110 -0
  87. package/es/components/hyStatus/style/status.scss +0 -0
  88. package/es/components/hyTable/cpns/columnSelect.vue.mjs +24 -28
  89. package/es/components/hyTable/cpns/columnSelectItem.vue.mjs +8 -9
  90. package/es/components/hyTable/cpns/headerItem.vue.mjs +2 -2
  91. package/es/components/hyTable/cpns/virtualTable.vue.mjs +18 -28
  92. package/es/components/hyTable/js/index.mjs +56 -59
  93. package/es/components/hyTable/js/useAppTable.mjs +3 -4
  94. package/es/components/hyTable/style/table.scss +8 -0
  95. package/es/components/hyTable/table.vue.mjs +35 -41
  96. package/es/components/hyTableActionButton/tableActionButton.vue.mjs +4 -4
  97. package/es/components/hyTableForm/batchTableForm.vue.mjs +3 -7
  98. package/es/components/hyTableForm/js/index.mjs +2 -8
  99. package/es/components/hyTableForm/js/useAppTableForm.mjs +2 -7
  100. package/es/components/hyTableForm/style/batchTableForm.scss +26 -54
  101. package/es/components/hyTableForm/style/tableForm.scss +3 -2
  102. package/es/components/hyTableForm/tableForm.vue.mjs +90 -46
  103. package/es/components/hyTimePicker/timePicker.vue.mjs +4 -5
  104. package/es/components/hyTree/js/index.mjs +13 -40
  105. package/es/components/hyTree/style/index.css +1 -1
  106. package/es/components/hyTree/tree.vue.mjs +17 -16
  107. package/es/components/hyUserAvatar/userAvatar.vue.mjs +3 -6
  108. package/es/components/hyVideoPlayer/js/index.mjs +14 -23
  109. package/es/components/hyVideoPlayer/style/videoPlayer.scss +5 -7
  110. package/es/components/hyVideoPlayer/videoPlayer.vue.mjs +16 -26
  111. package/es/components/index.mjs +3 -0
  112. package/es/hooks/index.mjs +6 -2
  113. package/es/hooks/useAudioPlayerConfig.mjs +1 -3
  114. package/es/hooks/useBaseMainStore.mjs +29 -0
  115. package/es/hooks/useCurrentBus.mjs +20 -0
  116. package/es/hooks/useDialog.mjs +327 -0
  117. package/es/hooks/useExportFile.mjs +133 -0
  118. package/es/hooks/useGlobalConfig.mjs +10 -6
  119. package/es/hooks/useLocale.mjs +22 -12
  120. package/es/hooks/usePermissionMap.mjs +1 -3
  121. package/es/hooks/useResizeHandler.mjs +1 -4
  122. package/es/hooks/useResizeObserver.mjs +3 -1
  123. package/es/hooks/useSubscribe.mjs +2 -2
  124. package/es/hooks/useUserAvatarMap.mjs +1 -3
  125. package/es/hooks/useVideoPlayerConfig.mjs +1 -3
  126. package/es/index.mjs +11 -2
  127. package/es/locale/{en.mjs → en_US.mjs} +79 -4
  128. package/es/locale/index.mjs +2 -2
  129. package/es/locale/zh_CN.mjs +79 -2
  130. package/es/style/tailwind.scss +7 -3
  131. package/es/utils/adaptive.mjs +1 -3
  132. package/es/utils/form.mjs +7 -10
  133. package/es/utils/handler.mjs +4 -8
  134. package/es/utils/input.mjs +8 -9
  135. package/es/utils/map/hook/bigMap.mjs +14 -53
  136. package/es/utils/map/hook/gaode.mjs +5 -20
  137. package/es/utils/map/hook/leafletjs.mjs +23 -79
  138. package/es/utils/map/index.mjs +2 -8
  139. package/es/utils/map/js/webgis.mjs +12 -12
  140. package/es/version.mjs +1 -1
  141. package/lib/api/device.js +2 -3
  142. package/lib/api/exportExcel.js +62 -0
  143. package/lib/api/index.js +27 -16
  144. package/lib/api/mapRail.js +34 -0
  145. package/lib/api/organization.js +17 -8
  146. package/lib/api/rule.js +33 -0
  147. package/lib/api/sypct.js +2 -3
  148. package/lib/api/task.js +2 -3
  149. package/lib/bussiness/hyAddDepartmentType/addDepartmentType.vue.js +17 -18
  150. package/lib/bussiness/hyAddDepartmentType/style/addDepartmentType.scss +28 -28
  151. package/lib/bussiness/hyElectronicFence/cpns/addElectronicFenceDialog/addElectronicFenceDialog.vue.js +515 -0
  152. package/lib/bussiness/hyElectronicFence/cpns/batchSetElectronicFenceUserDialog/batchSetElectronicFenceUserDialog.vue.js +173 -0
  153. package/lib/bussiness/hyElectronicFence/cpns/electronicFenceAssociatedUsersDialog/electronicFenceAssociatedUsersDialog.vue.js +322 -0
  154. package/lib/bussiness/hyElectronicFence/cpns/electronicFenceAssociatedUsersDialog/electronicFenceAssociatedUsersItem.vue.js +127 -0
  155. package/lib/bussiness/hyElectronicFence/electronicFence.vue.js +362 -0
  156. package/lib/bussiness/hyElectronicFence/index.js +21 -0
  157. package/lib/bussiness/hyElectronicFence/style/electronicFence.scss +0 -0
  158. package/lib/bussiness/hyMapAearchPlace/js/index.js +1 -1
  159. package/lib/bussiness/hyMapAearchPlace/mapAearchPlace.vue.js +4 -6
  160. package/lib/bussiness/hyMapAearchPlace/style/mapAearchPlace.scss +4 -3
  161. package/lib/bussiness/hyRuleSetting/cpns/gatheringPeople/gatheringPeople.vue.js +274 -0
  162. package/lib/bussiness/hyRuleSetting/cpns/missionInRule/missionInRule.vue.js +255 -0
  163. package/lib/bussiness/hyRuleSetting/cpns/missionOutRule/missionOutRule.vue.js +255 -0
  164. package/lib/bussiness/hyRuleSetting/cpns/ruleAssignDialog/ruleAssignDialog.vue.js +399 -0
  165. package/lib/bussiness/hyRuleSetting/cpns/ruleFenceDialog/ruleFenceDialog.vue.js +655 -0
  166. package/lib/bussiness/hyRuleSetting/cpns/ruleSettingDialog/ruleSettingDialog.vue.js +361 -0
  167. package/lib/bussiness/hyRuleSetting/cpns/sedentary/sedentary.vue.js +265 -0
  168. package/lib/bussiness/hyRuleSetting/cpns/setRuleAggregationAlarmDialog/setRuleAggregationAlarmDialog.vue.js +364 -0
  169. package/lib/bussiness/hyRuleSetting/cpns/timedVideo/timedVideo.vue.js +244 -0
  170. package/lib/bussiness/hyRuleSetting/cpns/timerCamera/timerCamera.vue.js +262 -0
  171. package/lib/bussiness/hyRuleSetting/cpns/timingReturn/timingReturn.vue.js +244 -0
  172. package/lib/bussiness/hyRuleSetting/index.js +24 -0
  173. package/lib/bussiness/hyRuleSetting/js/ruleSetting.js +68 -0
  174. package/lib/bussiness/hyRuleSetting/ruleSetting.vue.js +133 -0
  175. package/lib/bussiness/hyRuleSetting/style/ruleSetting.scss +0 -0
  176. package/lib/bussiness/index.js +21 -10
  177. package/lib/components/hyAudioPlayer/audioPlayer.vue.js +5 -13
  178. package/lib/components/hyAudioPlayer/js/index.js +9 -14
  179. package/lib/components/hyAudioPlayer/style/audioPlayer.scss +7 -2
  180. package/lib/components/hyButton/button.vue.js +2 -2
  181. package/lib/components/hyButton/style/button.scss +48 -74
  182. package/lib/components/hyCheckboxGroup/checkboxGroup.vue.js +123 -0
  183. package/lib/components/hyCheckboxGroup/index.js +12 -0
  184. package/lib/components/hyCheckboxGroup/style/checkboxGroup.scss +58 -0
  185. package/lib/components/hyConfigProvider/configProvider.vue.js +50 -56
  186. package/lib/components/hyConfirmDialog/confirmDialog.vue.js +56 -61
  187. package/lib/components/hyConfirmDialog/confirmMethod.js +23 -21
  188. package/lib/components/hyCutter/cutter.vue.js +8 -22
  189. package/lib/components/hyDatePicker/datePicker.vue.js +11 -16
  190. package/lib/components/hyDialog/dialog.vue.js +5 -9
  191. package/lib/components/hyDialog/style/dialog.scss +12 -13
  192. package/lib/components/hyDrawer/drawer.vue.js +104 -0
  193. package/lib/components/hyDrawer/index.js +12 -0
  194. package/lib/components/hyDrawer/style/drawer.scss +0 -0
  195. package/lib/components/hyForm/cpns/arrayItem.vue.js +9 -27
  196. package/lib/components/hyForm/cpns/arrayItem2.vue.js +202 -0
  197. package/lib/components/hyForm/cpns/extraItem.vue.js +2 -3
  198. package/lib/components/hyForm/cpns/formItem.vue.js +66 -36
  199. package/lib/components/hyForm/cpns/locationSelect.vue.js +26 -26
  200. package/lib/components/hyForm/form.vue.js +51 -19
  201. package/lib/components/hyForm/js/index.js +3 -7
  202. package/lib/components/hyForm/js/useAppForm.js +4 -9
  203. package/lib/components/hyForm/style/form.scss +4 -13
  204. package/lib/components/hyIcon/icon.vue.js +3 -3
  205. package/lib/components/hyIconBox/style/iconBox.scss +2 -6
  206. package/lib/components/hyInput/inputSearch.vue.js +7 -10
  207. package/lib/components/hyInput/style/inputSearch.scss +3 -0
  208. package/lib/components/hyLoading/index.js +2 -4
  209. package/lib/components/hyMap/js/index.js +29 -4
  210. package/lib/components/hyMap/map.vue.js +17 -3
  211. package/lib/components/hyMenu/style/menu.scss +5 -15
  212. package/lib/components/hyNoPermissions/noPermissions.vue.js +3 -4
  213. package/lib/components/hyNoPermissionsMap/noPermissionsMap.vue.js +3 -6
  214. package/lib/components/hyOrgCascader/js/index.js +1 -5
  215. package/lib/components/hyOrgCascader/orgCascader.vue.js +23 -9
  216. package/lib/components/hyOrgCascader/style/orgCascader.scss +7 -0
  217. package/lib/components/hyRadioGroup/radioGroup.vue.js +47 -40
  218. package/lib/components/hyRadioGroup/style/radioGroup.scss +9 -0
  219. package/lib/components/hySearch/cpns/searchItem.vue.js +33 -20
  220. package/lib/components/hySearch/js/index.js +1 -4
  221. package/lib/components/hySearch/js/useAppSearch.js +5 -10
  222. package/lib/components/hySearch/search.vue.js +9 -16
  223. package/lib/components/hySearch/style/search.scss +2 -0
  224. package/lib/components/hyStatus/index.js +12 -0
  225. package/lib/components/hyStatus/status.vue.js +114 -0
  226. package/lib/components/hyStatus/style/status.scss +0 -0
  227. package/lib/components/hyTable/cpns/columnSelect.vue.js +22 -26
  228. package/lib/components/hyTable/cpns/columnSelectItem.vue.js +7 -8
  229. package/lib/components/hyTable/cpns/headerItem.vue.js +2 -2
  230. package/lib/components/hyTable/cpns/virtualTable.vue.js +17 -27
  231. package/lib/components/hyTable/js/index.js +54 -57
  232. package/lib/components/hyTable/js/useAppTable.js +2 -3
  233. package/lib/components/hyTable/style/table.scss +8 -0
  234. package/lib/components/hyTable/table.vue.js +35 -41
  235. package/lib/components/hyTableActionButton/tableActionButton.vue.js +4 -4
  236. package/lib/components/hyTableForm/batchTableForm.vue.js +3 -7
  237. package/lib/components/hyTableForm/js/index.js +2 -8
  238. package/lib/components/hyTableForm/js/useAppTableForm.js +2 -7
  239. package/lib/components/hyTableForm/style/batchTableForm.scss +26 -54
  240. package/lib/components/hyTableForm/style/tableForm.scss +3 -2
  241. package/lib/components/hyTableForm/tableForm.vue.js +89 -45
  242. package/lib/components/hyTimePicker/timePicker.vue.js +3 -4
  243. package/lib/components/hyTree/js/index.js +13 -40
  244. package/lib/components/hyTree/style/index.css +1 -1
  245. package/lib/components/hyTree/tree.vue.js +17 -16
  246. package/lib/components/hyUserAvatar/userAvatar.vue.js +3 -6
  247. package/lib/components/hyVideoPlayer/js/index.js +14 -23
  248. package/lib/components/hyVideoPlayer/style/videoPlayer.scss +5 -7
  249. package/lib/components/hyVideoPlayer/videoPlayer.vue.js +16 -26
  250. package/lib/components/index.js +46 -40
  251. package/lib/hooks/index.js +17 -0
  252. package/lib/hooks/useAudioPlayerConfig.js +1 -3
  253. package/lib/hooks/useBaseMainStore.js +32 -0
  254. package/lib/hooks/useCurrentBus.js +23 -0
  255. package/lib/hooks/useDialog.js +331 -0
  256. package/lib/hooks/useExportFile.js +135 -0
  257. package/lib/hooks/useGlobalConfig.js +10 -6
  258. package/lib/hooks/useLocale.js +25 -11
  259. package/lib/hooks/usePermissionMap.js +1 -3
  260. package/lib/hooks/useResizeHandler.js +1 -4
  261. package/lib/hooks/useResizeObserver.js +3 -1
  262. package/lib/hooks/useSubscribe.js +2 -1
  263. package/lib/hooks/useUserAvatarMap.js +1 -3
  264. package/lib/hooks/useVideoPlayerConfig.js +1 -3
  265. package/lib/index.js +107 -73
  266. package/lib/locale/{en.js → en_US.js} +79 -4
  267. package/lib/locale/index.js +3 -3
  268. package/lib/locale/zh_CN.js +79 -2
  269. package/lib/style/tailwind.scss +7 -3
  270. package/lib/utils/adaptive.js +1 -3
  271. package/lib/utils/form.js +6 -9
  272. package/lib/utils/handler.js +3 -7
  273. package/lib/utils/input.js +7 -8
  274. package/lib/utils/map/hook/bigMap.js +14 -53
  275. package/lib/utils/map/hook/gaode.js +5 -20
  276. package/lib/utils/map/hook/leafletjs.js +23 -79
  277. package/lib/utils/map/index.js +2 -8
  278. package/lib/utils/map/js/webgis.js +12 -12
  279. package/lib/version.js +1 -1
  280. package/package.json +3 -2
@@ -0,0 +1,110 @@
1
+ import { defineComponent, openBlock, createElementBlock, Fragment, createBlock, unref, normalizeClass, createElementVNode, renderSlot, createTextVNode, toDisplayString } from 'vue';
2
+ import '../index.mjs';
3
+ import { HyIcon } from '../hyIcon/index.mjs';
4
+
5
+ import "./style/status.scss";
6
+
7
+ const __default__ = defineComponent({
8
+ name: "HyStatus"
9
+ });
10
+ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
11
+ props: {
12
+ type: {
13
+ type: String,
14
+ default: "default"
15
+ },
16
+ label: {
17
+ type: String
18
+ },
19
+ isOnline: {
20
+ type: Boolean,
21
+ default: false
22
+ }
23
+ },
24
+ emits: [],
25
+ setup(__props, { expose: __expose, emit: __emit }) {
26
+ const props = __props;
27
+ const emits = __emit;
28
+ const color = {
29
+ default: "text-auxiliary",
30
+ primary: "text-theme",
31
+ success: "text-success",
32
+ warning: "text-warning",
33
+ danger: "text-danger-2"
34
+ };
35
+ const bgColor = {
36
+ default: "bg-auxiliary",
37
+ primary: "bg-theme",
38
+ success: "bg-success",
39
+ warning: "bg-warning",
40
+ danger: "bg-danger-2"
41
+ };
42
+ const shadowColor = {
43
+ default: "bg-[rgba(var(--hy-auxiliary),0.28)]",
44
+ primary: "bg-[rgba(var(--hy-theme),0.28)]",
45
+ success: "bg-[rgba(var(--hy-success),0.28)]",
46
+ warning: "bg-[rgba(var(--hy-warning),0.28)]",
47
+ danger: "bg-[rgba(var(--hy-danger),0.28)]"
48
+ };
49
+ __expose({});
50
+ return (_ctx, _cache) => {
51
+ return openBlock(), createElementBlock("div", { class: "inline-flex items-center gap-2 text-sm" }, [
52
+ __props.isOnline ? (openBlock(), createElementBlock(
53
+ Fragment,
54
+ { key: 0 },
55
+ [
56
+ __props.type === "danger" ? (openBlock(), createBlock(unref(HyIcon), {
57
+ key: 0,
58
+ "svg-name": "ops-list-device-id-off-line",
59
+ class: "!w-3 !h-3"
60
+ })) : (openBlock(), createBlock(unref(HyIcon), {
61
+ key: 1,
62
+ "svg-name": "ops-list-device-id-on-line",
63
+ class: "!w-3 !h-3"
64
+ }))
65
+ ],
66
+ 64
67
+ /* STABLE_FRAGMENT */
68
+ )) : (openBlock(), createElementBlock(
69
+ "div",
70
+ {
71
+ key: 1,
72
+ class: normalizeClass(["w-2.5 h-2.5 flex items-center justify-center rounded-full flex-shrink-0 box-border", [shadowColor[__props.type]]])
73
+ },
74
+ [
75
+ createElementVNode(
76
+ "div",
77
+ {
78
+ class: normalizeClass(["w-1.5 h-1.5 rounded-full", [bgColor[__props.type]]])
79
+ },
80
+ null,
81
+ 2
82
+ /* CLASS */
83
+ )
84
+ ],
85
+ 2
86
+ /* CLASS */
87
+ )),
88
+ createElementVNode(
89
+ "span",
90
+ {
91
+ class: normalizeClass([color[__props.type]])
92
+ },
93
+ [
94
+ renderSlot(_ctx.$slots, "default", {}, () => [
95
+ createTextVNode(
96
+ toDisplayString(__props.label),
97
+ 1
98
+ /* TEXT */
99
+ )
100
+ ])
101
+ ],
102
+ 2
103
+ /* CLASS */
104
+ )
105
+ ]);
106
+ };
107
+ }
108
+ });
109
+
110
+ export { _sfc_main as default };
File without changes
@@ -1,4 +1,4 @@
1
- import { useTemplateRef, ref, computed, unref, nextTick, watch, openBlock, createBlock, withCtx, createElementVNode, toDisplayString, createVNode, normalizeClass, createCommentVNode, createElementBlock, Fragment, renderList, createTextVNode } from 'vue';
1
+ import { useTemplateRef, ref, computed, unref, nextTick, watch, openBlock, createBlock, withCtx, createElementVNode, toDisplayString, createVNode, createElementBlock, normalizeClass, createCommentVNode, Fragment, renderList, createTextVNode } from 'vue';
2
2
  import Sortable from 'sortablejs';
3
3
  import { ElMessage, ElPopover, ElCheckboxGroup } from 'element-plus';
4
4
  import '../../../hooks/index.mjs';
@@ -6,7 +6,7 @@ import '../../../utils/index.mjs';
6
6
  import '../../index.mjs';
7
7
  import { tableColumnShowHandler, tableColumnHandler } from '../js/index.mjs';
8
8
  import _sfc_main$1 from './columnSelectItem.vue.mjs';
9
- import { useLocale } from '../../../hooks/useLocale.mjs';
9
+ import { $t } from '../../../hooks/useLocale.mjs';
10
10
  import { isEmpty } from '../../../utils/is.mjs';
11
11
  import { HyIcon } from '../../hyIcon/index.mjs';
12
12
  import { HyTooltip } from '../../hyTooltip/index.mjs';
@@ -32,7 +32,6 @@ const _sfc_main = {
32
32
  setup(__props, { expose: __expose, emit: __emit }) {
33
33
  const props = __props;
34
34
  const emits = __emit;
35
- const { t } = useLocale();
36
35
  const popoverRef = useTemplateRef("popoverRef");
37
36
  const listRef = useTemplateRef("listRef");
38
37
  const tableColumns = ref([]);
@@ -42,6 +41,11 @@ const _sfc_main = {
42
41
  return total + (isShowColumn(column) ? 1 : 0);
43
42
  }, 0);
44
43
  });
44
+ const cannotDragged = computed(() => {
45
+ return props.columns.reduce((total, column) => {
46
+ return total + (isShowColumn(column) && column.editable.lock ? 1 : 0);
47
+ }, 0);
48
+ });
45
49
  function isShowColumn(column) {
46
50
  return tableColumnShowHandler(column) && column.editable.edit;
47
51
  }
@@ -81,9 +85,7 @@ const _sfc_main = {
81
85
  }, /* @__PURE__ */ new Map());
82
86
  });
83
87
  function onCheckedHandler(target) {
84
- const currentIndex = checkedList.value.findIndex(
85
- (item) => item === target.prop
86
- );
88
+ const currentIndex = checkedList.value.findIndex((item) => item === target.prop);
87
89
  if (currentIndex !== -1) {
88
90
  checkedList.value.splice(currentIndex, 1);
89
91
  } else {
@@ -93,11 +95,11 @@ const _sfc_main = {
93
95
  }
94
96
  function onConfirmHandler() {
95
97
  if (!checkedList.value.length && showColumnsLength.value === tableEditableColumns.value?.length) {
96
- ElMessage.warning(t("table.theColumnsDisplayedInTheTableCannotBeLeftBlank"));
98
+ ElMessage.warning($t("table.theColumnsDisplayedInTheTableCannotBeLeftBlank"));
97
99
  return;
98
100
  }
99
101
  if (checkedList.value.length > 15) {
100
- ElMessage.warning(t("table.maxColumnLimitTip"));
102
+ ElMessage.warning($t("table.maxColumnLimitTip"));
101
103
  return;
102
104
  }
103
105
  const editableObj = tableEditableColumns.value.reduce(
@@ -112,9 +114,7 @@ const _sfc_main = {
112
114
  closePopover();
113
115
  }
114
116
  function onClearHandler() {
115
- const { columnsList, columnsEditablele } = tableColumnHandler(
116
- props.originColumns
117
- );
117
+ const { columnsList, columnsEditablele } = tableColumnHandler(props.originColumns);
118
118
  initColumnsInfo(columnsList, columnsEditablele);
119
119
  showReset.value = false;
120
120
  }
@@ -128,19 +128,14 @@ const _sfc_main = {
128
128
  animation: 150,
129
129
  onEnd(event) {
130
130
  const { oldIndex, newIndex } = event;
131
- if (isEmpty(oldIndex) || isEmpty(newIndex) || oldIndex === newIndex)
132
- return;
131
+ if (isEmpty(oldIndex) || isEmpty(newIndex) || oldIndex === newIndex) return;
133
132
  const minIndex = Math.min(oldIndex, newIndex);
134
133
  const maxIndex = Math.max(oldIndex, newIndex);
135
134
  const sortList = [];
136
135
  for (let i = minIndex; i <= maxIndex; i++) {
137
136
  sortList[i] = tableEditableColumns.value[i].sortIndex;
138
137
  }
139
- tableEditableColumns.value.splice(
140
- newIndex,
141
- 0,
142
- tableEditableColumns.value.splice(oldIndex, 1)[0]
143
- );
138
+ tableEditableColumns.value.splice(newIndex, 0, tableEditableColumns.value.splice(oldIndex, 1)[0]);
144
139
  for (let i = minIndex; i <= maxIndex; i++) {
145
140
  tableEditableColumns.value[i].sortIndex = sortList[i];
146
141
  }
@@ -176,7 +171,7 @@ const _sfc_main = {
176
171
  },
177
172
  {
178
173
  reference: withCtx(() => [
179
- createElementVNode("div", { class: "h-[32px] flex items-center gap-[10px] clickBox px-3 rounded hover:bg-background-2" }, [
174
+ createElementVNode("div", { class: "h-[32px] flex items-center gap-[10px] clickBox px-3 rounded hover:bg-background-2 box-border" }, [
180
175
  createVNode(unref(HyIcon), {
181
176
  "svg-name": "ops-button-edit-column",
182
177
  "class-name": "!w-3 !h-3"
@@ -184,7 +179,7 @@ const _sfc_main = {
184
179
  createElementVNode(
185
180
  "span",
186
181
  null,
187
- toDisplayString(unref(t)("table.editColumn")) + " \xB7 " + toDisplayString(showColumnsLength.value),
182
+ toDisplayString(unref($t)("table.editColumn")) + " \xB7 " + toDisplayString(showColumnsLength.value),
188
183
  1
189
184
  /* TEXT */
190
185
  )
@@ -196,7 +191,7 @@ const _sfc_main = {
196
191
  createElementVNode(
197
192
  "span",
198
193
  { class: "text-main font-bold" },
199
- toDisplayString(unref(t)("table.editColumn")),
194
+ toDisplayString(unref($t)("table.editColumn")),
200
195
  1
201
196
  /* TEXT */
202
197
  ),
@@ -206,7 +201,7 @@ const _sfc_main = {
206
201
  onClick: closePopover
207
202
  })
208
203
  ]),
209
- createElementVNode("div", { class: "flex items-center gap-1.5 px-4 py-2.5 text-xs text-theme" }, [
204
+ createElementVNode("div", { class: "flex items-center gap-1.5 px-4 py-2.5 text-xs text-theme box-border" }, [
210
205
  createVNode(unref(HyIcon), {
211
206
  "svg-name": "dispatch-share1-prompt",
212
207
  "class-name": "!w-3 !h-3"
@@ -219,9 +214,10 @@ const _sfc_main = {
219
214
  "onUpdate:modelValue": ($event) => checkedList.value = $event
220
215
  }, {
221
216
  default: withCtx(() => [
222
- createElementVNode(
217
+ cannotDragged.value > 0 ? (openBlock(), createElementBlock(
223
218
  "div",
224
219
  {
220
+ key: 0,
225
221
  class: normalizeClass(["flex flex-col gap-1.5 leading-3 text-info", { "mb-1.5": tableEditableColumns.value.length > 0 }])
226
222
  },
227
223
  [
@@ -250,7 +246,7 @@ const _sfc_main = {
250
246
  ],
251
247
  2
252
248
  /* CLASS */
253
- ),
249
+ )) : createCommentVNode("v-if", true),
254
250
  createCommentVNode(" \u53EF\u62D6\u62FD "),
255
251
  createElementVNode(
256
252
  "div",
@@ -289,7 +285,7 @@ const _sfc_main = {
289
285
  createElementVNode(
290
286
  "span",
291
287
  null,
292
- toDisplayString(unref(t)("table.selectedNumberItems", [checkedList.value?.length || 0])),
288
+ toDisplayString(unref($t)("table.selectedNumberItems", [checkedList.value?.length || 0])),
293
289
  1
294
290
  /* TEXT */
295
291
  ),
@@ -300,7 +296,7 @@ const _sfc_main = {
300
296
  class: "clickBox text-danger-2 ml-3",
301
297
  onClick: onClearHandler
302
298
  },
303
- toDisplayString(unref(t)("hy.reset")),
299
+ toDisplayString(unref($t)("hy.reset")),
304
300
  1
305
301
  /* TEXT */
306
302
  )) : createCommentVNode("v-if", true)
@@ -316,7 +312,7 @@ const _sfc_main = {
316
312
  }),
317
313
  createVNode(unref(HyTooltip), {
318
314
  "is-always": false,
319
- content: unref(t)("table.tooManyFieldsWillAffectReadability"),
315
+ content: unref($t)("table.tooManyFieldsWillAffectReadability"),
320
316
  class: "mr-2 text-auxiliary"
321
317
  }, null, 8, ["content"])
322
318
  ],
@@ -330,7 +326,7 @@ const _sfc_main = {
330
326
  }, {
331
327
  default: withCtx(() => [
332
328
  createTextVNode(
333
- toDisplayString(unref(t)("hy.confirm")),
329
+ toDisplayString(unref($t)("hy.confirm")),
334
330
  1
335
331
  /* TEXT */
336
332
  )
@@ -4,7 +4,7 @@ import { Lock } from '@element-plus/icons-vue';
4
4
  import '../../../hooks/index.mjs';
5
5
  import { renderHeaderHandler } from '../js/index.mjs';
6
6
  import '../../index.mjs';
7
- import { useLocale } from '../../../hooks/useLocale.mjs';
7
+ import { $t } from '../../../hooks/useLocale.mjs';
8
8
  import { HyTooltip } from '../../hyTooltip/index.mjs';
9
9
 
10
10
  const _sfc_main = {
@@ -27,7 +27,6 @@ const _sfc_main = {
27
27
  setup(__props, { emit: __emit }) {
28
28
  const props = __props;
29
29
  const emits = __emit;
30
- const { t } = useLocale();
31
30
  function onClickHandler(column) {
32
31
  if (column.editable.lock) return;
33
32
  emits("checked", column);
@@ -78,7 +77,7 @@ const _sfc_main = {
78
77
  __props.checkMap.has(__props.column.prop) ? (openBlock(), createElementBlock(
79
78
  "span",
80
79
  { key: 0 },
81
- toDisplayString(unref(t)("table.show")),
80
+ toDisplayString(unref($t)("table.show")),
82
81
  1
83
82
  /* TEXT */
84
83
  )) : (openBlock(), createElementBlock(
@@ -87,7 +86,7 @@ const _sfc_main = {
87
86
  key: 1,
88
87
  class: "text-info"
89
88
  },
90
- toDisplayString(unref(t)("table.notShown")),
89
+ toDisplayString(unref($t)("table.notShown")),
91
90
  1
92
91
  /* TEXT */
93
92
  )),
@@ -99,7 +98,7 @@ const _sfc_main = {
99
98
  }, [
100
99
  createElementVNode("div", {
101
100
  class: "w-5 h-2.5",
102
- style: { "background": "radial-gradient(\n circle,\n rgba(var(--hy-theme)) 1px,\n transparent 2px\n )\n 0px 0px / 5px 5px" }
101
+ style: { "background": "radial-gradient(circle, rgba(var(--hy-theme)) 1px, transparent 2px) 0px 0px / 5px 5px" }
103
102
  })
104
103
  ], 8, ["onClick"])) : createCommentVNode("v-if", true)
105
104
  ])) : createCommentVNode("v-if", true)
@@ -108,12 +107,12 @@ const _sfc_main = {
108
107
  default: withCtx(() => [
109
108
  createElementVNode(
110
109
  "div",
111
- { class: "h-[45px] px-[14px] flex items-center text-main text-sm font-bold border-b border-border" },
110
+ { class: "h-[45px] px-[14px] flex items-center text-main text-sm font-bold border-b border-border box-border" },
112
111
  toDisplayString(unref(renderHeaderHandler)(__props.column)),
113
112
  1
114
113
  /* TEXT */
115
114
  ),
116
- createElementVNode("div", { class: "flex flex-col gap-3 px-4 pt-2.5 pb-4 text-main text-xs" }, [
115
+ createElementVNode("div", { class: "flex flex-col gap-3 px-4 pt-2.5 pb-4 text-main text-xs box-border" }, [
117
116
  __props.column.editable.desc ? (openBlock(), createElementBlock(
118
117
  "div",
119
118
  { key: 0 },
@@ -125,7 +124,7 @@ const _sfc_main = {
125
124
  createElementVNode(
126
125
  "div",
127
126
  { class: "text-auxiliary mb-1.5" },
128
- toDisplayString(unref(t)("table.example")),
127
+ toDisplayString(unref($t)("table.example")),
129
128
  1
130
129
  /* TEXT */
131
130
  ),
@@ -138,7 +137,7 @@ const _sfc_main = {
138
137
  "div",
139
138
  {
140
139
  key: index,
141
- class: "leading-5 bg-background-2 px-1.5 rounded-[2px]"
140
+ class: "leading-5 bg-background-2 px-1.5 rounded-[2px] box-border"
142
141
  },
143
142
  toDisplayString(item),
144
143
  1
@@ -64,10 +64,10 @@ const _sfc_main = {
64
64
  return (_ctx, _cache) => {
65
65
  return columnSort.value.show ? (openBlock(), createElementBlock("div", {
66
66
  key: 0,
67
- class: "w-full relative cursor-pointer",
67
+ class: "w-full flex items-center gap-1 relative cursor-pointer",
68
68
  onClick: ($event) => onSortHandler(columnSort.value.prop, null)
69
69
  }, [
70
- createElementVNode("div", { class: "flex flex-col absolute top-1/2 -left-1 transform -translate-y-1/2 -translate-x-full" }, [
70
+ createElementVNode("div", { class: "flex flex-col" }, [
71
71
  createVNode(unref(ElIcon), {
72
72
  size: "8",
73
73
  color: isSortActive(columnSort.value.prop, "asc") ? "rgba(var(--hy-theme))" : "rgba(var(--hy-auxiliary))",
@@ -1,4 +1,4 @@
1
- import { useModel, computed, ref, openBlock, createBlock, unref, withCtx, renderSlot, createCommentVNode, createElementBlock, Fragment, renderList, normalizeStyle, withModifiers, normalizeClass, createVNode, mergeProps, createTextVNode, toDisplayString, createElementVNode, normalizeProps, guardReactiveProps, mergeModels } from 'vue';
1
+ import { useModel, useTemplateRef, computed, ref, openBlock, createBlock, unref, withCtx, renderSlot, createCommentVNode, createElementBlock, Fragment, renderList, normalizeStyle, withModifiers, normalizeClass, createVNode, mergeProps, createTextVNode, toDisplayString, createElementVNode, normalizeProps, guardReactiveProps, mergeModels } from 'vue';
2
2
  import { ElTableV2, ElCheckbox, ElDropdown, ElIcon, ElDropdownMenu, ElDropdownItem } from 'element-plus';
3
3
  import { MoreFilled } from '@element-plus/icons-vue';
4
4
  import '../../index.mjs';
@@ -6,10 +6,10 @@ import '../../../hooks/index.mjs';
6
6
  import '../../../utils/index.mjs';
7
7
  import { operatorFilterHandler, operatorClickHandler, operatorDisabledHandler, operatorIsDotHandler, operatorDisableTextdHandler, renderContentHandler, renderHeaderHandler } from '../js/index.mjs';
8
8
  import _sfc_main$1 from './headerItem.vue.mjs';
9
- import { useLocale } from '../../../hooks/useLocale.mjs';
10
9
  import { isNumber, isString, isFunction, isArray, isBoolean, isEmpty } from '../../../utils/is.mjs';
11
10
  import { HyIcon } from '../../hyIcon/index.mjs';
12
11
  import { HyTooltip } from '../../hyTooltip/index.mjs';
12
+ import { $t } from '../../../hooks/useLocale.mjs';
13
13
 
14
14
  const _sfc_main = {
15
15
  __name: "virtualTable",
@@ -79,7 +79,7 @@ const _sfc_main = {
79
79
  const props = __props;
80
80
  const emits = __emit;
81
81
  const expandedRowKeys = useModel(__props, "expandedRowKeys");
82
- const { t } = useLocale();
82
+ const tableRef = useTemplateRef("tableRef");
83
83
  const avgWidth = computed(() => {
84
84
  const { total, totalWidth } = props.columns.reduce(
85
85
  ({ total: total2, totalWidth: totalWidth2 }, column) => {
@@ -277,10 +277,18 @@ const _sfc_main = {
277
277
  isAllChecked.value = false;
278
278
  selectedMap.value.clear();
279
279
  indeterminateKeys.value.clear();
280
+ },
281
+ scrollToTop(top) {
282
+ tableRef.value.scrollToTop(top);
283
+ },
284
+ scrollToLeft(left) {
285
+ tableRef.value.scrollToLeft(left);
280
286
  }
281
287
  });
282
288
  return (_ctx, _cache) => {
283
289
  return openBlock(), createBlock(unref(ElTableV2), {
290
+ ref_key: "tableRef",
291
+ ref: tableRef,
284
292
  "expanded-row-keys": expandedRowKeys.value,
285
293
  "onUpdate:expandedRowKeys": ($event) => expandedRowKeys.value = $event,
286
294
  cache: 0,
@@ -422,11 +430,7 @@ const _sfc_main = {
422
430
  (openBlock(true), createElementBlock(
423
431
  Fragment,
424
432
  null,
425
- renderList(unref(operatorFilterHandler)(
426
- column,
427
- { column, row, $index, cellIndex },
428
- "default"
429
- ), (citem, cindex) => {
433
+ renderList(unref(operatorFilterHandler)(column, { column, row, $index, cellIndex }, "default"), (citem, cindex) => {
430
434
  return openBlock(), createBlock(unref(HyTooltip), {
431
435
  key: cindex,
432
436
  "is-always": "",
@@ -444,12 +448,7 @@ const _sfc_main = {
444
448
  cellIndex
445
449
  }) ? "cursor-not-allowed text-[var(--hy-el-text-color-disabled)] hover:border-[rgba(var(--hy-auxiliary),1)] hover:shadow-[0px_0px_5px_0px_rgba(var(--hy-auxiliary),0.5)]" : "cursor-pointer hover:border-theme hover:shadow-[0px_0px_5px_0px_rgba(var(--hy-theme),0.5)]"
446
450
  ]]),
447
- onClick: ($event) => unref(operatorClickHandler)(
448
- cindex,
449
- column,
450
- { column, row, $index, cellIndex },
451
- "default"
452
- )
451
+ onClick: ($event) => unref(operatorClickHandler)(cindex, column, { column, row, $index, cellIndex }, "default")
453
452
  }, [
454
453
  createVNode(unref(HyIcon), {
455
454
  "svg-name": citem.svgName,
@@ -486,23 +485,14 @@ const _sfc_main = {
486
485
  128
487
486
  /* KEYED_FRAGMENT */
488
487
  )),
489
- unref(operatorFilterHandler)(
490
- column,
491
- { column, row, $index, cellIndex },
492
- "more"
493
- )?.length ? (openBlock(), createBlock(unref(ElDropdown), {
488
+ unref(operatorFilterHandler)(column, { column, row, $index, cellIndex }, "more")?.length ? (openBlock(), createBlock(unref(ElDropdown), {
494
489
  key: 0,
495
490
  ref_for: true,
496
491
  ref: "operatorDropdownRef",
497
492
  trigger: "click",
498
493
  "popper-style": "min-width: 150px",
499
- placement: "bottom",
500
- onCommand: ($event) => unref(operatorClickHandler)(
501
- $event,
502
- column,
503
- { column, row, $index, cellIndex },
504
- "more"
505
- )
494
+ placement: "bottom-end",
495
+ onCommand: ($event) => unref(operatorClickHandler)($event, column, { column, row, $index, cellIndex }, "more")
506
496
  }, {
507
497
  dropdown: withCtx(() => [
508
498
  createVNode(
@@ -588,7 +578,7 @@ const _sfc_main = {
588
578
  createVNode(unref(HyTooltip), {
589
579
  "is-always": "",
590
580
  overLine: 1,
591
- content: unref(t)("table.moreOperations")
581
+ content: unref($t)("table.moreOperations")
592
582
  }, {
593
583
  default: withCtx(() => [
594
584
  createElementVNode("div", { class: "w-[40px] h-[48px] inline-flex flex-col items-center justify-center text-main text-xs hover:font-bold border border-transparent hover:border-theme hover:shadow-[0px_0px_5px_0px_rgba(var(--hy-theme),0.5)] rounded box-border cursor-pointer" }, [
@@ -607,7 +597,7 @@ const _sfc_main = {
607
597
  createElementVNode(
608
598
  "div",
609
599
  { class: "mt-1" },
610
- toDisplayString(unref(t)("table.more")),
600
+ toDisplayString(unref($t)("table.more")),
611
601
  1
612
602
  /* TEXT */
613
603
  )