hy-dispatch-ui-v3 0.1.0 → 0.1.2

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 (256) hide show
  1. package/dist/tailwind.css +186 -45
  2. package/es/bussiness/index.mjs +0 -1
  3. package/es/components/appButton/appButton.vue.mjs +133 -0
  4. package/es/components/appButton/index.mjs +6 -0
  5. package/es/components/appButton/style/appButton.scss +289 -0
  6. package/es/components/appConfigProvider/appConfigProvider.vue.mjs +91 -0
  7. package/es/components/appConfigProvider/index.mjs +6 -0
  8. package/es/components/appConfirmDialog/appConfirmDialog.vue.mjs +105 -60
  9. package/es/components/appConfirmDialog/appConfirmMethod.mjs +49 -27
  10. package/es/components/appConfirmDialog/index.mjs +0 -1
  11. package/es/components/appDatePicker/appDatePicker.vue.mjs +0 -1
  12. package/es/components/appDatePicker/index.mjs +0 -1
  13. package/es/components/appForm/appForm.vue.mjs +64 -67
  14. package/es/components/appForm/index.mjs +0 -1
  15. package/es/components/appForm/js/index.mjs +0 -1
  16. package/es/components/appForm/js/useAppForm.mjs +0 -1
  17. package/es/components/appForm/style/appForm.scss +1 -1
  18. package/es/components/{svgIcon/svgIcon.vue.mjs → appIcon/appIcon.vue.mjs} +4 -5
  19. package/es/components/appIcon/index.mjs +6 -0
  20. package/es/components/{svgIcon/style/svgIcon.scss → appIcon/style/appIcon.scss} +1 -4
  21. package/es/components/{svgIcon/iconBox.vue.mjs → appIconBox/appIconBox.vue.mjs} +6 -7
  22. package/es/components/appIconBox/index.mjs +6 -0
  23. package/es/components/appIconBox/style/appIconBox.scss +27 -0
  24. package/es/components/appOrgCascader/appOrgCascader.vue.mjs +18 -11
  25. package/es/components/appOrgCascader/index.mjs +0 -1
  26. package/es/components/appSearch/appSearch.vue.mjs +2 -6
  27. package/es/components/appSearch/index.mjs +0 -1
  28. package/es/components/appSearch/js/index.mjs +5 -6
  29. package/es/components/appSearch/js/useAppSearch.mjs +0 -1
  30. package/es/components/appSearch/style/appSearch.scss +17 -11
  31. package/es/components/appTable/appTable.vue.mjs +57 -32
  32. package/es/components/appTable/cpns/columnSelect.vue.mjs +87 -123
  33. package/es/components/appTable/cpns/columnSelectItem.vue.mjs +5 -0
  34. package/es/components/appTable/cpns/columnSelectItem.vue2.mjs +167 -0
  35. package/es/components/appTable/index.mjs +0 -1
  36. package/es/components/appTable/js/index.mjs +9 -8
  37. package/es/components/appTable/js/search.mjs +6 -6
  38. package/es/components/appTable/js/useAppTable.mjs +6 -3
  39. package/es/components/appTable/style/appTable.scss +20 -11
  40. package/es/components/appTooltip/appTooltip.vue.mjs +0 -1
  41. package/es/components/appTooltip/index.mjs +0 -1
  42. package/es/components/appUserAvatar/appUserAvatar.vue.mjs +136 -0
  43. package/es/components/appUserAvatar/index.mjs +6 -0
  44. package/es/components/appUserAvatar/style/appUserAvatar.scss +33 -0
  45. package/es/components/index.mjs +5 -2
  46. package/es/config/index.mjs +0 -1
  47. package/es/constants/index.mjs +0 -1
  48. package/es/constants/keys.mjs +0 -1
  49. package/es/hooks/index.mjs +4 -3
  50. package/es/hooks/useApi.mjs +20 -5
  51. package/es/hooks/useGlobalConfig.mjs +19 -10
  52. package/es/hooks/useLocale.mjs +1 -2
  53. package/es/hooks/useMixins.mjs +0 -1
  54. package/es/{store/maintain.mjs → hooks/useResizeHandler.mjs} +29 -44
  55. package/es/hooks/useUserAvatarMap.mjs +9 -0
  56. package/es/index.mjs +9 -6
  57. package/es/locale/{en_US.mjs → en.mjs} +8 -5
  58. package/es/locale/index.mjs +2 -3
  59. package/es/locale/zh_CN.mjs +6 -3
  60. package/es/make-installer.mjs +2 -8
  61. package/es/static/hy-svg-icons.mjs +11 -0
  62. package/es/style/element/element.scss +16313 -0
  63. package/es/style/element/index.scss +932 -0
  64. package/es/style/index.scss +37 -0
  65. package/es/style/theme.scss +18 -120
  66. package/es/utils/adaptive.mjs +0 -1
  67. package/es/utils/bus.mjs +0 -1
  68. package/es/utils/crypto.mjs +0 -1
  69. package/es/utils/date.mjs +0 -1
  70. package/es/utils/handler.mjs +0 -1
  71. package/es/utils/index.mjs +0 -1
  72. package/es/utils/is.mjs +0 -1
  73. package/es/version.mjs +1 -2
  74. package/lib/bussiness/index.js +0 -1
  75. package/lib/components/appButton/appButton.vue.js +137 -0
  76. package/lib/components/appButton/index.js +11 -0
  77. package/lib/components/appButton/style/appButton.scss +289 -0
  78. package/lib/components/appConfigProvider/appConfigProvider.vue.js +114 -0
  79. package/lib/components/appConfigProvider/index.js +11 -0
  80. package/lib/components/appConfirmDialog/appConfirmDialog.vue.js +103 -58
  81. package/lib/components/appConfirmDialog/appConfirmMethod.js +48 -26
  82. package/lib/components/appConfirmDialog/index.js +0 -1
  83. package/lib/components/appDatePicker/appDatePicker.vue.js +0 -1
  84. package/lib/components/appDatePicker/index.js +0 -1
  85. package/lib/components/appForm/appForm.vue.js +61 -64
  86. package/lib/components/appForm/index.js +0 -1
  87. package/lib/components/appForm/js/index.js +0 -1
  88. package/lib/components/appForm/js/useAppForm.js +0 -1
  89. package/lib/components/appForm/style/appForm.scss +1 -1
  90. package/lib/components/{svgIcon/svgIcon.vue.js → appIcon/appIcon.vue.js} +4 -5
  91. package/lib/components/appIcon/index.js +11 -0
  92. package/lib/components/{svgIcon/style/svgIcon.scss → appIcon/style/appIcon.scss} +1 -4
  93. package/lib/components/{svgIcon/iconBox.vue.js → appIconBox/appIconBox.vue.js} +6 -7
  94. package/lib/components/appIconBox/index.js +11 -0
  95. package/lib/components/appIconBox/style/appIconBox.scss +27 -0
  96. package/lib/components/appOrgCascader/appOrgCascader.vue.js +18 -11
  97. package/lib/components/appOrgCascader/index.js +0 -1
  98. package/lib/components/appSearch/appSearch.vue.js +2 -6
  99. package/lib/components/appSearch/index.js +0 -1
  100. package/lib/components/appSearch/js/index.js +5 -6
  101. package/lib/components/appSearch/js/useAppSearch.js +0 -1
  102. package/lib/components/appSearch/style/appSearch.scss +17 -11
  103. package/lib/components/appTable/appTable.vue.js +56 -31
  104. package/lib/components/appTable/cpns/columnSelect.vue.js +86 -122
  105. package/lib/components/appTable/cpns/columnSelectItem.vue.js +9 -0
  106. package/lib/components/appTable/cpns/columnSelectItem.vue2.js +171 -0
  107. package/lib/components/appTable/index.js +0 -1
  108. package/lib/components/appTable/js/index.js +9 -7
  109. package/lib/components/appTable/js/search.js +6 -6
  110. package/lib/components/appTable/js/useAppTable.js +6 -3
  111. package/lib/components/appTable/style/appTable.scss +20 -11
  112. package/lib/components/appTooltip/appTooltip.vue.js +0 -1
  113. package/lib/components/appTooltip/index.js +0 -1
  114. package/lib/components/appUserAvatar/appUserAvatar.vue.js +140 -0
  115. package/lib/components/appUserAvatar/index.js +11 -0
  116. package/lib/components/appUserAvatar/style/appUserAvatar.scss +33 -0
  117. package/lib/components/index.js +24 -18
  118. package/lib/config/index.js +0 -1
  119. package/lib/constants/index.js +0 -1
  120. package/lib/constants/keys.js +0 -1
  121. package/lib/hooks/index.js +8 -2
  122. package/lib/hooks/useApi.js +19 -3
  123. package/lib/hooks/useGlobalConfig.js +21 -11
  124. package/lib/hooks/useLocale.js +1 -2
  125. package/lib/hooks/useMixins.js +0 -1
  126. package/lib/{store/maintain.js → hooks/useResizeHandler.js} +29 -44
  127. package/lib/hooks/useUserAvatarMap.js +12 -0
  128. package/lib/index.js +37 -28
  129. package/lib/locale/{en_US.js → en.js} +8 -5
  130. package/lib/locale/index.js +3 -4
  131. package/lib/locale/zh_CN.js +6 -3
  132. package/lib/make-installer.js +1 -7
  133. package/lib/static/hy-svg-icons.js +13 -0
  134. package/lib/style/element/element.scss +16313 -0
  135. package/lib/style/element/index.scss +932 -0
  136. package/lib/style/index.scss +37 -0
  137. package/lib/style/theme.scss +18 -120
  138. package/lib/utils/adaptive.js +0 -1
  139. package/lib/utils/bus.js +0 -1
  140. package/lib/utils/crypto.js +0 -1
  141. package/lib/utils/date.js +0 -1
  142. package/lib/utils/handler.js +0 -1
  143. package/lib/utils/index.js +0 -1
  144. package/lib/utils/is.js +0 -1
  145. package/lib/version.js +1 -2
  146. package/package.json +17 -7
  147. package/es/bussiness/index.mjs.map +0 -1
  148. package/es/components/appConfirmDialog/appConfirmDialog.vue.mjs.map +0 -1
  149. package/es/components/appConfirmDialog/appConfirmMethod.mjs.map +0 -1
  150. package/es/components/appConfirmDialog/index.mjs.map +0 -1
  151. package/es/components/appConfirmDialog/style/appConfirmDialog.scss +0 -5
  152. package/es/components/appDatePicker/appDatePicker.vue.mjs.map +0 -1
  153. package/es/components/appDatePicker/index.mjs.map +0 -1
  154. package/es/components/appForm/appForm.vue.mjs.map +0 -1
  155. package/es/components/appForm/index.mjs.map +0 -1
  156. package/es/components/appForm/js/index.mjs.map +0 -1
  157. package/es/components/appForm/js/useAppForm.mjs.map +0 -1
  158. package/es/components/appOrgCascader/appOrgCascader.vue.mjs.map +0 -1
  159. package/es/components/appOrgCascader/index.mjs.map +0 -1
  160. package/es/components/appSearch/appSearch.vue.mjs.map +0 -1
  161. package/es/components/appSearch/index.mjs.map +0 -1
  162. package/es/components/appSearch/js/index.mjs.map +0 -1
  163. package/es/components/appSearch/js/useAppSearch.mjs.map +0 -1
  164. package/es/components/appTable/appTable.vue.mjs.map +0 -1
  165. package/es/components/appTable/cpns/columnSelect.vue.mjs.map +0 -1
  166. package/es/components/appTable/index.mjs.map +0 -1
  167. package/es/components/appTable/js/index.mjs.map +0 -1
  168. package/es/components/appTable/js/search.mjs.map +0 -1
  169. package/es/components/appTable/js/useAppTable.mjs.map +0 -1
  170. package/es/components/appTooltip/appTooltip.vue.mjs.map +0 -1
  171. package/es/components/appTooltip/index.mjs.map +0 -1
  172. package/es/components/index.mjs.map +0 -1
  173. package/es/components/svgIcon/iconBox.vue.mjs.map +0 -1
  174. package/es/components/svgIcon/index.mjs +0 -9
  175. package/es/components/svgIcon/index.mjs.map +0 -1
  176. package/es/components/svgIcon/style/iconBox.scss +0 -13
  177. package/es/components/svgIcon/svgIcon.vue.mjs.map +0 -1
  178. package/es/config/index.mjs.map +0 -1
  179. package/es/constants/index.mjs.map +0 -1
  180. package/es/constants/keys.mjs.map +0 -1
  181. package/es/hooks/index.mjs.map +0 -1
  182. package/es/hooks/useApi.mjs.map +0 -1
  183. package/es/hooks/useGlobalConfig.mjs.map +0 -1
  184. package/es/hooks/useLocale.mjs.map +0 -1
  185. package/es/hooks/useMixins.mjs.map +0 -1
  186. package/es/index.mjs.map +0 -1
  187. package/es/locale/en_US.mjs.map +0 -1
  188. package/es/locale/index.mjs.map +0 -1
  189. package/es/locale/zh_CN.mjs.map +0 -1
  190. package/es/make-installer.mjs.map +0 -1
  191. package/es/store/index.mjs +0 -7
  192. package/es/store/index.mjs.map +0 -1
  193. package/es/store/maintain.mjs.map +0 -1
  194. package/es/utils/adaptive.mjs.map +0 -1
  195. package/es/utils/bus.mjs.map +0 -1
  196. package/es/utils/crypto.mjs.map +0 -1
  197. package/es/utils/date.mjs.map +0 -1
  198. package/es/utils/handler.mjs.map +0 -1
  199. package/es/utils/index.mjs.map +0 -1
  200. package/es/utils/is.mjs.map +0 -1
  201. package/es/version.mjs.map +0 -1
  202. package/lib/bussiness/index.js.map +0 -1
  203. package/lib/components/appConfirmDialog/appConfirmDialog.vue.js.map +0 -1
  204. package/lib/components/appConfirmDialog/appConfirmMethod.js.map +0 -1
  205. package/lib/components/appConfirmDialog/index.js.map +0 -1
  206. package/lib/components/appConfirmDialog/style/appConfirmDialog.scss +0 -5
  207. package/lib/components/appDatePicker/appDatePicker.vue.js.map +0 -1
  208. package/lib/components/appDatePicker/index.js.map +0 -1
  209. package/lib/components/appForm/appForm.vue.js.map +0 -1
  210. package/lib/components/appForm/index.js.map +0 -1
  211. package/lib/components/appForm/js/index.js.map +0 -1
  212. package/lib/components/appForm/js/useAppForm.js.map +0 -1
  213. package/lib/components/appOrgCascader/appOrgCascader.vue.js.map +0 -1
  214. package/lib/components/appOrgCascader/index.js.map +0 -1
  215. package/lib/components/appSearch/appSearch.vue.js.map +0 -1
  216. package/lib/components/appSearch/index.js.map +0 -1
  217. package/lib/components/appSearch/js/index.js.map +0 -1
  218. package/lib/components/appSearch/js/useAppSearch.js.map +0 -1
  219. package/lib/components/appTable/appTable.vue.js.map +0 -1
  220. package/lib/components/appTable/cpns/columnSelect.vue.js.map +0 -1
  221. package/lib/components/appTable/index.js.map +0 -1
  222. package/lib/components/appTable/js/index.js.map +0 -1
  223. package/lib/components/appTable/js/search.js.map +0 -1
  224. package/lib/components/appTable/js/useAppTable.js.map +0 -1
  225. package/lib/components/appTooltip/appTooltip.vue.js.map +0 -1
  226. package/lib/components/appTooltip/index.js.map +0 -1
  227. package/lib/components/index.js.map +0 -1
  228. package/lib/components/svgIcon/iconBox.vue.js.map +0 -1
  229. package/lib/components/svgIcon/index.js +0 -15
  230. package/lib/components/svgIcon/index.js.map +0 -1
  231. package/lib/components/svgIcon/style/iconBox.scss +0 -13
  232. package/lib/components/svgIcon/svgIcon.vue.js.map +0 -1
  233. package/lib/config/index.js.map +0 -1
  234. package/lib/constants/index.js.map +0 -1
  235. package/lib/constants/keys.js.map +0 -1
  236. package/lib/hooks/index.js.map +0 -1
  237. package/lib/hooks/useApi.js.map +0 -1
  238. package/lib/hooks/useGlobalConfig.js.map +0 -1
  239. package/lib/hooks/useLocale.js.map +0 -1
  240. package/lib/hooks/useMixins.js.map +0 -1
  241. package/lib/index.js.map +0 -1
  242. package/lib/locale/en_US.js.map +0 -1
  243. package/lib/locale/index.js.map +0 -1
  244. package/lib/locale/zh_CN.js.map +0 -1
  245. package/lib/make-installer.js.map +0 -1
  246. package/lib/store/index.js +0 -10
  247. package/lib/store/index.js.map +0 -1
  248. package/lib/store/maintain.js.map +0 -1
  249. package/lib/utils/adaptive.js.map +0 -1
  250. package/lib/utils/bus.js.map +0 -1
  251. package/lib/utils/crypto.js.map +0 -1
  252. package/lib/utils/date.js.map +0 -1
  253. package/lib/utils/handler.js.map +0 -1
  254. package/lib/utils/index.js.map +0 -1
  255. package/lib/utils/is.js.map +0 -1
  256. package/lib/version.js.map +0 -1
@@ -0,0 +1,167 @@
1
+ import { defineComponent, openBlock, createBlock, unref, withCtx, createElementVNode, toDisplayString, createElementBlock, createCommentVNode, Fragment, renderList, normalizeClass, createVNode, withModifiers } from 'vue';
2
+ import { ElPopover, ElIcon, ElCheckbox } from 'element-plus';
3
+ import { Lock, DCaret } from '@element-plus/icons-vue';
4
+ import { AppTooltip } from '../../appTooltip/index.mjs';
5
+ import { useLocale } from '../../../hooks/useLocale.mjs';
6
+
7
+ var _sfc_main = /* @__PURE__ */ defineComponent({
8
+ __name: "columnSelectItem",
9
+ props: {
10
+ column: {
11
+ type: Object,
12
+ default: () => ({})
13
+ },
14
+ checkMap: {
15
+ type: Map,
16
+ default: () => /* @__PURE__ */ new Map()
17
+ },
18
+ columnsLength: {
19
+ type: Number,
20
+ ddefault: 0
21
+ }
22
+ },
23
+ emits: ["checked"],
24
+ setup(__props, { emit: __emit }) {
25
+ const emits = __emit;
26
+ const { t } = useLocale();
27
+ function onClickHandler(column) {
28
+ if (column.editable.lock) return;
29
+ emits("checked", column);
30
+ }
31
+ return (_ctx, _cache) => {
32
+ var _a;
33
+ return openBlock(), createBlock(unref(ElPopover), {
34
+ trigger: "hover",
35
+ placement: "right-end",
36
+ "popper-class": "!bg-background !p-0 border !border-border",
37
+ effect: "dark",
38
+ width: "268",
39
+ "show-arrow": false,
40
+ disabled: !__props.column.editable.desc && !((_a = __props.column.editable.examples) == null ? void 0 : _a.length)
41
+ }, {
42
+ reference: withCtx(() => {
43
+ var _a2;
44
+ return [
45
+ createElementVNode("div", {
46
+ class: normalizeClass(["h-[36px] text-sm flex items-center pl-3 pr-2.5 bg-background-2 hover:bg-background-3", [((_a2 = __props.column.editable) == null ? void 0 : _a2.lock) ? "cursor-default" : "cursor-pointer"]]),
47
+ onClick: ($event) => onClickHandler(__props.column)
48
+ }, [
49
+ __props.column.editable.lock ? (openBlock(), createBlock(unref(ElIcon), {
50
+ key: 0,
51
+ size: "14",
52
+ color: "rgb(var(--hy-info))",
53
+ class: "mr-2"
54
+ }, {
55
+ default: withCtx(() => [
56
+ createVNode(unref(Lock))
57
+ ]),
58
+ _: 1
59
+ /* STABLE */
60
+ })) : (openBlock(), createBlock(unref(ElCheckbox), {
61
+ key: 1,
62
+ value: __props.column.prop,
63
+ onClick: withModifiers(() => {
64
+ }, ["stop"])
65
+ }, null, 8, ["value", "onClick"])),
66
+ createElementVNode("div", { class: "w-0 flex-1" }, [
67
+ createVNode(unref(AppTooltip), {
68
+ "over-line": 1,
69
+ content: __props.column.label
70
+ }, null, 8, ["content"])
71
+ ]),
72
+ !__props.column.editable.lock ? (openBlock(), createElementBlock("div", {
73
+ key: 2,
74
+ class: "h-full flex items-center text-auxiliary select-none ml-1"
75
+ }, [
76
+ __props.checkMap.has(__props.column.prop) ? (openBlock(), createElementBlock(
77
+ "span",
78
+ { key: 0 },
79
+ toDisplayString(unref(t)("table.show")),
80
+ 1
81
+ /* TEXT */
82
+ )) : (openBlock(), createElementBlock(
83
+ "span",
84
+ {
85
+ key: 1,
86
+ class: "text-info"
87
+ },
88
+ toDisplayString(unref(t)("table.notShown")),
89
+ 1
90
+ /* TEXT */
91
+ )),
92
+ __props.columnsLength > 1 ? (openBlock(), createElementBlock("div", {
93
+ key: 2,
94
+ class: "w-5 h-full flex items-center justify-center handle cursor-grab ml-3",
95
+ onClick: withModifiers(() => {
96
+ }, ["stop"])
97
+ }, [
98
+ createVNode(unref(ElIcon), null, {
99
+ default: withCtx(() => [
100
+ createVNode(unref(DCaret))
101
+ ]),
102
+ _: 1
103
+ /* STABLE */
104
+ })
105
+ ], 8, ["onClick"])) : createCommentVNode("v-if", true)
106
+ ])) : createCommentVNode("v-if", true)
107
+ ], 10, ["onClick"])
108
+ ];
109
+ }),
110
+ default: withCtx(() => {
111
+ var _a2;
112
+ return [
113
+ createElementVNode(
114
+ "div",
115
+ { class: "h-[45px] px-[14px] flex items-center text-main text-sm font-bold border-b border-border" },
116
+ toDisplayString(__props.column.label),
117
+ 1
118
+ /* TEXT */
119
+ ),
120
+ createElementVNode("div", { class: "flex flex-col gap-3 px-4 pt-2.5 pb-4 text-main text-xs" }, [
121
+ __props.column.editable.desc ? (openBlock(), createElementBlock(
122
+ "div",
123
+ { key: 0 },
124
+ toDisplayString(__props.column.editable.desc),
125
+ 1
126
+ /* TEXT */
127
+ )) : createCommentVNode("v-if", true),
128
+ ((_a2 = __props.column.editable.examples) == null ? void 0 : _a2.length) ? (openBlock(), createElementBlock("div", { key: 1 }, [
129
+ createElementVNode(
130
+ "div",
131
+ { class: "text-auxiliary mb-1.5" },
132
+ toDisplayString(unref(t)("table.example")),
133
+ 1
134
+ /* TEXT */
135
+ ),
136
+ createElementVNode("div", { class: "flex flex-wrap gap-2" }, [
137
+ (openBlock(true), createElementBlock(
138
+ Fragment,
139
+ null,
140
+ renderList(__props.column.editable.examples, (item, index) => {
141
+ return openBlock(), createElementBlock(
142
+ "div",
143
+ {
144
+ key: index,
145
+ class: "leading-5 bg-background-2 px-1.5 rounded-[2px]"
146
+ },
147
+ toDisplayString(item),
148
+ 1
149
+ /* TEXT */
150
+ );
151
+ }),
152
+ 128
153
+ /* KEYED_FRAGMENT */
154
+ ))
155
+ ])
156
+ ])) : createCommentVNode("v-if", true)
157
+ ])
158
+ ];
159
+ }),
160
+ _: 1
161
+ /* STABLE */
162
+ }, 8, ["disabled"]);
163
+ };
164
+ }
165
+ });
166
+
167
+ export { _sfc_main as default };
@@ -5,4 +5,3 @@ import { withInstall } from '../../utils/handler.mjs';
5
5
  const AppTable = withInstall(_sfc_main);
6
6
 
7
7
  export { AppTable, AppTable as default };
8
- //# sourceMappingURL=index.mjs.map
@@ -52,14 +52,16 @@ function tableColumnsEditableleHandler(columns, columnsEditablele, searchArr) {
52
52
  }
53
53
  );
54
54
  }
55
- function tableColumnHandler(cacheKey, columns, searchArr) {
56
- const cacheColumnsValue = JSON.parse(sessionStorage.getItem(cacheKey) || "{}");
55
+ function tableColumnHandler(columns, cacheKey, searchArr) {
56
+ const cacheColumnsValue = cacheKey ? JSON.parse(sessionStorage.getItem(cacheKey) || "{}") : {};
57
57
  const cacheColumnsEditablele = columns.reduce((obj, column) => {
58
58
  obj[column.prop] = {
59
59
  ...column.editable,
60
60
  ...cacheColumnsValue[column.prop],
61
61
  lock: column.editable.lock,
62
- edit: column.editable.edit
62
+ edit: column.editable.edit,
63
+ desc: column.editable.desc,
64
+ examples: column.editable.examples
63
65
  };
64
66
  return obj;
65
67
  }, {});
@@ -112,7 +114,7 @@ function operatorFilterHandler(column, scope, type = "all") {
112
114
  function operatorClickHandler(command, column, scope, type = "all") {
113
115
  const operator = operatorFilterHandler(column, scope, type);
114
116
  const target = operator[command];
115
- (target == null ? void 0 : target.onClick) && target.onClick(scope);
117
+ (target == null ? void 0 : target.handler) && target.handler(scope);
116
118
  }
117
119
  const useAppTableWrapper = (hy) => {
118
120
  const {
@@ -124,7 +126,7 @@ const useAppTableWrapper = (hy) => {
124
126
  operatorDropdownRef
125
127
  } = hy;
126
128
  const { t } = useLocale();
127
- const CACHE_COLUMNS_KEY = "CACHE_COLUMNS_KEY";
129
+ const CACHE_COLUMNS_KEY = props.controller || props.url || "CACHE_COLUMNS_KEY";
128
130
  const loading = ref(true);
129
131
  const tableDataSource = ref([]);
130
132
  const tableColumns = ref([]);
@@ -268,8 +270,8 @@ const useAppTableWrapper = (hy) => {
268
270
  }
269
271
  watchEffect(() => {
270
272
  const { columnsList, columnsEditablele, searchText } = tableColumnHandler(
271
- CACHE_COLUMNS_KEY,
272
273
  props.tableColumns,
274
+ CACHE_COLUMNS_KEY,
273
275
  props.searchArr
274
276
  );
275
277
  tableColumns.value = columnsList;
@@ -300,5 +302,4 @@ const useAppTableWrapper = (hy) => {
300
302
  };
301
303
  };
302
304
 
303
- export { operatorClickHandler, operatorDisableTextdHandler, operatorDisabledHandler, operatorFilterHandler, tableColumnShowHandler, useAppTableWrapper };
304
- //# sourceMappingURL=index.mjs.map
305
+ export { operatorClickHandler, operatorDisableTextdHandler, operatorDisabledHandler, operatorFilterHandler, tableColumnHandler, tableColumnShowHandler, useAppTableWrapper };
@@ -35,14 +35,15 @@ function useAppTableSearch(hy) {
35
35
  }
36
36
  }
37
37
  const params = getParametersFn();
38
+ const options = { baseURL: props.baseURL, isJSON: props.isJsonData };
38
39
  if (props.controller) {
39
- api.page(props.controller, params).then(successFun).finally(() => {
40
+ unref(api).post(`${props.controller}/page`, params, options).then(successFun).finally(() => {
40
41
  resolve();
41
42
  closeAppTableLoading();
42
43
  clearSelection();
43
44
  });
44
45
  } else if (props.url) {
45
- api.post(props.url, params).then(successFun).finally(() => {
46
+ unref(api).post(props.url, params, options).then(successFun).finally(() => {
46
47
  resolve();
47
48
  closeAppTableLoading();
48
49
  clearSelection();
@@ -58,6 +59,7 @@ function useAppTableSearch(hy) {
58
59
  getData(1);
59
60
  return;
60
61
  }
62
+ console.log("res", res);
61
63
  const data = res.data.content ? res.data.content : res.data || [];
62
64
  if (props.beforeDataHandler) {
63
65
  tableDataSource.value = props.beforeDataHandler(data);
@@ -80,7 +82,6 @@ function useAppTableSearch(hy) {
80
82
  ...unref(formModel),
81
83
  page: unref(formModel).page - 1
82
84
  },
83
- { isJSON: props.isJsonData },
84
85
  unref(props.requestParams)
85
86
  );
86
87
  }
@@ -114,11 +115,11 @@ function useAppTableSearch(hy) {
114
115
  totalElements,
115
116
  showFilter,
116
117
  getData,
118
+ setData,
117
119
  resetFn,
118
120
  switchShowFilter,
119
- getTableDataSource,
120
121
  getTotalElements,
121
- setData,
122
+ getTableDataSource,
122
123
  onSizeChangeHandler,
123
124
  onCurrentChangeHandler,
124
125
  onSearchQueryHandler
@@ -126,4 +127,3 @@ function useAppTableSearch(hy) {
126
127
  }
127
128
 
128
129
  export { useAppTableSearch };
129
- //# sourceMappingURL=search.mjs.map
@@ -21,7 +21,9 @@ function getColumnsEditable(column, index) {
21
21
  index,
22
22
  lock: false,
23
23
  edit: !type || type === "default",
24
- checked: !!editable
24
+ checked: !!editable,
25
+ desc: void 0,
26
+ examples: []
25
27
  };
26
28
  }
27
29
  return {
@@ -29,6 +31,8 @@ function getColumnsEditable(column, index) {
29
31
  lock: false,
30
32
  edit: !type || type === "default",
31
33
  checked: !type || type !== "default" || prop === "operator",
34
+ desc: void 0,
35
+ examples: [],
32
36
  ...editable || {}
33
37
  };
34
38
  }
@@ -42,7 +46,7 @@ const useAppTable = (config = {}) => {
42
46
  throw Error("\u3010column.prop\u3011\u4E0D\u80FD\u4E3A\u7A7A");
43
47
  }
44
48
  tableColumns.push({
45
- prop: column.type !== "default" ? `${column.type}_prop` : column.prop,
49
+ prop: column.prop || column.type !== "default" ? `${column.type}_prop` : column.prop,
46
50
  ...column,
47
51
  type: column.type || "default",
48
52
  width: getColumnDefaultWidth(column),
@@ -60,4 +64,3 @@ const useAppTable = (config = {}) => {
60
64
  };
61
65
 
62
66
  export { useAppTable };
63
- //# sourceMappingURL=useAppTable.mjs.map
@@ -1,15 +1,24 @@
1
- .el-table {
2
- &.hideSelect {
3
- /* 禁用全选 */
4
- .el-table__header-wrapper .el-checkbox {
5
- display: none !important;
1
+ .app-table {
2
+ width: 100%;
3
+ height: 100%;
4
+ display: flex;
5
+ flex-direction: column;
6
+ color: rgb(var(--hy-main));
7
+ font-size: 14px;
8
+ background-color: rgb(var(--hy-background));
9
+ .el-table {
10
+ &.hideSelect {
11
+ /* 禁用全选 */
12
+ .el-table__header-wrapper .el-checkbox {
13
+ display: none !important;
14
+ }
6
15
  }
7
- }
8
- .el-table__cell .cell {
9
- display: flex;
10
- align-items: center;
11
- .el-table__expand-icon {
12
- flex-shrink: 0;
16
+ .el-table__cell .cell {
17
+ display: flex;
18
+ align-items: center;
19
+ .el-table__expand-icon {
20
+ flex-shrink: 0;
21
+ }
13
22
  }
14
23
  }
15
24
  }
@@ -91,4 +91,3 @@ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
91
91
  });
92
92
 
93
93
  export { _sfc_main as default };
94
- //# sourceMappingURL=appTooltip.vue.mjs.map
@@ -4,4 +4,3 @@ import { withInstall } from '../../utils/handler.mjs';
4
4
  const AppTooltip = withInstall(_sfc_main);
5
5
 
6
6
  export { AppTooltip, AppTooltip as default };
7
- //# sourceMappingURL=index.mjs.map
@@ -0,0 +1,136 @@
1
+ import { defineComponent, computed, unref, openBlock, createElementBlock, normalizeStyle, createBlock, normalizeClass, createCommentVNode } from 'vue';
2
+ import { AppIcon } from '../appIcon/index.mjs';
3
+ import { useUserAvatarMap } from '../../hooks/useUserAvatarMap.mjs';
4
+ import { pxTorem } from '../../utils/adaptive.mjs';
5
+ import { useLocale } from '../../hooks/useLocale.mjs';
6
+
7
+ import "./style/appUserAvatar.scss";
8
+
9
+ const __default__ = defineComponent({
10
+ name: "AppUserAvatar"
11
+ });
12
+ const _sfc_main = /* @__PURE__ */ Object.assign(__default__, {
13
+ props: {
14
+ initSelectSvgName: {
15
+ type: String,
16
+ default: () => {
17
+ return "user_online-2";
18
+ }
19
+ },
20
+ initSvgName: {
21
+ type: String,
22
+ default: () => {
23
+ return "user_offline-2";
24
+ }
25
+ },
26
+ device: Object,
27
+ // 设备信息
28
+ audioContextType: {
29
+ type: Boolean,
30
+ default: () => {
31
+ return false;
32
+ }
33
+ },
34
+ iconType: {
35
+ type: Boolean,
36
+ default: () => {
37
+ return true;
38
+ }
39
+ },
40
+ width: {
41
+ type: String,
42
+ default: () => {
43
+ return "54px";
44
+ }
45
+ },
46
+ height: {
47
+ type: String,
48
+ default: () => {
49
+ return "54px";
50
+ }
51
+ }
52
+ },
53
+ emits: [],
54
+ setup(__props, { emit: __emit }) {
55
+ const props = __props;
56
+ const { t } = useLocale();
57
+ const { userAvatarMap } = useUserAvatarMap();
58
+ const headImg = computed(() => {
59
+ var _a;
60
+ return props.device && ((_a = unref(userAvatarMap)) == null ? void 0 : _a.get(props.device.deviceId));
61
+ });
62
+ function parseRem(res) {
63
+ let px = res;
64
+ if (px) {
65
+ px = parseInt(px, 10);
66
+ if (isNaN(px)) {
67
+ return "";
68
+ }
69
+ return pxTorem(px);
70
+ }
71
+ return "";
72
+ }
73
+ return (_ctx, _cache) => {
74
+ var _a, _b, _c, _d, _e, _f;
75
+ return openBlock(), createElementBlock(
76
+ "div",
77
+ {
78
+ style: normalizeStyle({
79
+ width: `${parseRem(__props.width)}rem`,
80
+ height: `${parseRem(__props.height)}rem`,
81
+ "border-color": ((_a = __props.device) == null ? void 0 : _a.onlineState) === 1 ? __props.audioContextType ? "rgb(var(--hy-theme))" : ((_b = __props.device) == null ? void 0 : _b.gbDevice) === 1 ? "#FDE777" : "rgb(var(--hy-auxiliary))" : "rgb(var(--hy-info))"
82
+ }),
83
+ class: "app-user-avatar"
84
+ },
85
+ [
86
+ ((_c = __props.device) == null ? void 0 : _c.gbDevice) === 1 ? (openBlock(), createElementBlock(
87
+ "div",
88
+ {
89
+ key: 0,
90
+ style: normalizeStyle(
91
+ ((_d = __props.device) == null ? void 0 : _d.onlineState) === 1 ? "background:linear-gradient(180deg, #5A2120 0%, #C81F12 100%); color:#FDE777;" : "background: rgb(var(--hy-background-2)); color: rgb(var(--hy-auxiliary));"
92
+ ),
93
+ class: "user-avatar font-[600] text-base"
94
+ },
95
+ " GB ",
96
+ 4
97
+ /* STYLE */
98
+ )) : (openBlock(), createElementBlock("div", {
99
+ key: 1,
100
+ class: "user-avatar"
101
+ }, [
102
+ headImg.value ? (openBlock(), createElementBlock("img", {
103
+ key: 0,
104
+ src: headImg.value,
105
+ alt: unref(t)("userAvatar.userAvatar")
106
+ }, null, 8, ["src", "alt"])) : ((_e = __props.device) == null ? void 0 : _e.onlineState) === 1 ? (openBlock(), createBlock(unref(AppIcon), {
107
+ key: 1,
108
+ "svg-name": __props.initSelectSvgName,
109
+ className: "svgBox"
110
+ }, null, 8, ["svg-name"])) : (openBlock(), createBlock(unref(AppIcon), {
111
+ key: 2,
112
+ "svg-name": __props.initSvgName,
113
+ className: "svgBox"
114
+ }, null, 8, ["svg-name"]))
115
+ ])),
116
+ __props.iconType ? (openBlock(), createElementBlock(
117
+ "span",
118
+ {
119
+ key: 2,
120
+ class: normalizeClass(
121
+ ((_f = __props.device) == null ? void 0 : _f.onlineState) === 1 ? "bg-success shadow-[0_0_4px_0] shadow-success" : "bg-info"
122
+ )
123
+ },
124
+ null,
125
+ 2
126
+ /* CLASS */
127
+ )) : createCommentVNode("v-if", true)
128
+ ],
129
+ 4
130
+ /* STYLE */
131
+ );
132
+ };
133
+ }
134
+ });
135
+
136
+ export { _sfc_main as default };
@@ -0,0 +1,6 @@
1
+ import _sfc_main from './appUserAvatar.vue.mjs';
2
+ import { withInstall } from '../../utils/handler.mjs';
3
+
4
+ const AppUserAvatar = withInstall(_sfc_main);
5
+
6
+ export { AppUserAvatar, AppUserAvatar as default };
@@ -0,0 +1,33 @@
1
+ .app-user-avatar {
2
+ background: rgb(var(--hy-background-2));
3
+ position: relative;
4
+ border: 1px solid rgb(var(--hy-main));
5
+ box-sizing: border-box;
6
+ flex-shrink: 0;
7
+ border-radius: 50%;
8
+ .user-avatar {
9
+ width: 100%;
10
+ height: 100%;
11
+ border-radius: 50%;
12
+ overflow: hidden;
13
+ display: flex;
14
+ align-items: center;
15
+ justify-content: center;
16
+ img {
17
+ height: 100%;
18
+ }
19
+ .svgBox {
20
+ width: 90%;
21
+ height: 90%;
22
+ color: rgb(var(--hy-main));
23
+ }
24
+ }
25
+ span {
26
+ width: 32%;
27
+ height: 32%;
28
+ border-radius: 50%;
29
+ position: absolute;
30
+ bottom: -4%;
31
+ right: -2%;
32
+ }
33
+ }
@@ -2,11 +2,14 @@ export { AppOrgCascader } from './appOrgCascader/index.mjs';
2
2
  export { AppConfirmDialog } from './appConfirmDialog/index.mjs';
3
3
  export { AppDatePicker } from './appDatePicker/index.mjs';
4
4
  export { AppForm } from './appForm/index.mjs';
5
- export { IconBox, SvgIcon } from './svgIcon/index.mjs';
5
+ export { AppIcon } from './appIcon/index.mjs';
6
+ export { AppIconBox } from './appIconBox/index.mjs';
6
7
  export { AppSearch } from './appSearch/index.mjs';
7
8
  export { AppTable } from './appTable/index.mjs';
8
9
  export { AppTooltip } from './appTooltip/index.mjs';
10
+ export { AppConfigProvider } from './appConfigProvider/index.mjs';
11
+ export { AppButton } from './appButton/index.mjs';
12
+ export { AppUserAvatar } from './appUserAvatar/index.mjs';
9
13
  export { useAppForm } from './appForm/js/useAppForm.mjs';
10
14
  export { useAppSearch } from './appSearch/js/useAppSearch.mjs';
11
15
  export { useAppTable } from './appTable/js/useAppTable.mjs';
12
- //# sourceMappingURL=index.mjs.map
@@ -1,2 +1 @@
1
1
 
2
- //# sourceMappingURL=index.mjs.map
@@ -1,4 +1,3 @@
1
1
  const INSTALLED_KEY = /* @__PURE__ */ Symbol("HY_INSTALLED_KEY");
2
2
 
3
3
  export { INSTALLED_KEY };
4
- //# sourceMappingURL=index.mjs.map
@@ -1,2 +1 @@
1
1
 
2
- //# sourceMappingURL=keys.mjs.map
@@ -1,5 +1,6 @@
1
- export { localApiKey, useApi } from './useApi.mjs';
1
+ export { defaultAxios, localApiKey, useApi } from './useApi.mjs';
2
2
  export { buildLocaleContext, buildTranslator, getLanguage, localeContextKey, translate, useLocale } from './useLocale.mjs';
3
- export { getGlobalConfig, useGlobalConfig } from './useGlobalConfig.mjs';
3
+ export { configProviderContextKey, provideGlobalConfig, useGlobalConfig } from './useGlobalConfig.mjs';
4
4
  export { useMixins } from './useMixins.mjs';
5
- //# sourceMappingURL=index.mjs.map
5
+ export { localUserAvatarMapKey, useUserAvatarMap } from './useUserAvatarMap.mjs';
6
+ export { useResizeHandler } from './useResizeHandler.mjs';
@@ -1,10 +1,25 @@
1
- import { inject, ref, unref } from 'vue';
1
+ import axios from 'axios';
2
+ import { ref, inject, unref } from 'vue';
2
3
 
3
4
  const localApiKey = /* @__PURE__ */ Symbol("localApiKey");
5
+ const defaultAxios = ref(
6
+ axios.create({
7
+ withCredentials: false,
8
+ timeout: 6e4
9
+ })
10
+ );
11
+ defaultAxios.value.interceptors.response.use(
12
+ (response) => {
13
+ const data = response == null ? void 0 : response.data;
14
+ return Promise.resolve(data);
15
+ },
16
+ (error) => {
17
+ return Promise.reject(error);
18
+ }
19
+ );
4
20
  const useApi = () => {
5
- const api = inject(localApiKey, ref({}));
6
- return { api: unref(api) };
21
+ const api = inject(localApiKey, defaultAxios);
22
+ return { api: unref(api) ? api : defaultAxios };
7
23
  };
8
24
 
9
- export { localApiKey, useApi };
10
- //# sourceMappingURL=useApi.mjs.map
25
+ export { defaultAxios, localApiKey, useApi };