@dazhicheng/ui 1.5.198 → 1.5.201

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 (242) hide show
  1. package/dist/_virtual/_plugin-vue_export-helper.js +9 -0
  2. package/dist/api/dataTypeContext.js +17 -0
  3. package/dist/assets/img/empty_images/no_data.png.js +4 -0
  4. package/dist/assets/img/empty_images/search.png.js +4 -0
  5. package/dist/assets/img/image_status/develop.png.js +4 -0
  6. package/dist/assets/img/image_status/loading.gif.js +4 -0
  7. package/dist/assets/img/image_status/loading_fail.png.js +4 -0
  8. package/dist/assets/img/image_status/no_network.png.js +4 -0
  9. package/dist/assets/img/image_status/no_permission.png.js +4 -0
  10. package/dist/assets/svg/action_more.svg.js +4 -0
  11. package/dist/assets/svg/close.svg.js +4 -0
  12. package/dist/assets/svg/item_error.svg.js +4 -0
  13. package/dist/assets/svg/paixu-jiangxu.svg.js +4 -0
  14. package/dist/assets/svg/paixu-moren.svg.js +4 -0
  15. package/dist/assets/svg/paixu-shengxu.svg.js +4 -0
  16. package/dist/assets/svg/quanping.svg.js +4 -0
  17. package/dist/assets/svg/suoxiao.svg.js +4 -0
  18. package/dist/components/tt-api-component/index.js +7 -0
  19. package/dist/components/tt-api-component/index.vue.js +7 -0
  20. package/dist/components/tt-api-component/index.vue2.js +199 -0
  21. package/dist/components/tt-area/TtArea.vue.js +7 -0
  22. package/dist/components/tt-area/TtArea.vue2.js +36 -0
  23. package/dist/components/tt-button/components/AddButton.vue.js +24 -0
  24. package/dist/components/tt-button/components/AddButton.vue2.js +4 -0
  25. package/dist/components/tt-button/index.js +9 -0
  26. package/dist/components/tt-button/index.vue.js +7 -0
  27. package/dist/components/tt-button/index.vue2.js +68 -0
  28. package/dist/components/tt-checkbox/index.js +7 -0
  29. package/dist/components/tt-checkbox/index.vue.js +77 -0
  30. package/dist/components/tt-checkbox/index.vue2.js +4 -0
  31. package/dist/components/tt-drawer/index.js +14 -0
  32. package/dist/components/tt-drawer/src/RenderDrawer.vue.js +156 -0
  33. package/dist/components/tt-drawer/src/RenderDrawer.vue3.js +5 -0
  34. package/dist/components/tt-drawer/src/components/DrawerFooter.vue.js +56 -0
  35. package/dist/components/tt-drawer/src/components/DrawerFooter.vue3.js +5 -0
  36. package/dist/components/tt-drawer/src/components/DrawerHeader.vue.js +7 -0
  37. package/dist/components/tt-drawer/src/components/DrawerHeader.vue2.js +21 -0
  38. package/dist/components/tt-drawer/src/hooks/useDrawerRender.js +124 -0
  39. package/dist/components/tt-drawer/src/hooks/useResizable.js +98 -0
  40. package/dist/components/tt-drawer/src/index.js +17 -0
  41. package/dist/components/tt-drawer/src/props.js +72 -0
  42. package/dist/components/tt-drawer/src/utils/drawer-api.js +191 -0
  43. package/dist/components/tt-empty/index.js +34 -0
  44. package/dist/components/tt-form/index.js +65 -0
  45. package/dist/components/tt-form/src/components/ExpandableArrow.vue2.js +38 -0
  46. package/dist/components/tt-form/src/components/ExpandableArrow.vue3.js +5 -0
  47. package/dist/components/tt-form/src/components/FormActions.vue2.js +177 -0
  48. package/dist/components/tt-form/src/components/FormActions.vue3.js +5 -0
  49. package/dist/components/tt-form/src/components/FormElInput.vue.js +80 -0
  50. package/dist/components/tt-form/src/components/FormElInput.vue2.js +4 -0
  51. package/dist/components/tt-form/src/components/Slot.js +28 -0
  52. package/dist/components/tt-form/src/config.js +57 -0
  53. package/dist/components/tt-form/src/form/FormControl.vue.js +16 -0
  54. package/dist/components/tt-form/src/form/FormControl.vue2.js +4 -0
  55. package/dist/components/tt-form/src/form/FormDescription.vue.js +21 -0
  56. package/dist/components/tt-form/src/form/FormDescription.vue2.js +4 -0
  57. package/dist/components/tt-form/src/form/FormItem.vue.js +20 -0
  58. package/dist/components/tt-form/src/form/FormItem.vue2.js +4 -0
  59. package/dist/components/tt-form/src/form/FormLabel.vue.js +19 -0
  60. package/dist/components/tt-form/src/form/FormLabel.vue2.js +4 -0
  61. package/dist/components/tt-form/src/form/FormMessage.vue.js +18 -0
  62. package/dist/components/tt-form/src/form/FormMessage.vue2.js +4 -0
  63. package/dist/components/tt-form/src/form/FormMessageToolTip.vue.js +30 -0
  64. package/dist/components/tt-form/src/form/FormMessageToolTip.vue2.js +4 -0
  65. package/dist/components/tt-form/src/form/RenderContent.vue.js +31 -0
  66. package/dist/components/tt-form/src/form/RenderContent.vue2.js +4 -0
  67. package/dist/components/tt-form/src/form/injectionKeys.js +4 -0
  68. package/dist/components/tt-form/src/form/useFormField.js +24 -0
  69. package/dist/components/tt-form/src/form-render/FormField.vue.js +4 -0
  70. package/dist/components/tt-form/src/form-render/FormField.vue2.js +346 -0
  71. package/dist/components/tt-form/src/form-render/FormFieldContact.js +54 -0
  72. package/dist/components/tt-form/src/form-render/FormLabel.vue.js +4 -0
  73. package/dist/components/tt-form/src/form-render/FormLabel.vue2.js +102 -0
  74. package/dist/components/tt-form/src/form-render/array-register/FormArrayRegister.js +195 -0
  75. package/dist/components/tt-form/src/form-render/array-register/props.js +47 -0
  76. package/dist/components/tt-form/src/form-render/array-register/utils.js +12 -0
  77. package/dist/components/tt-form/src/form-render/context.js +15 -0
  78. package/dist/components/tt-form/src/form-render/dependencies.js +51 -0
  79. package/dist/components/tt-form/src/form-render/expandable.js +46 -0
  80. package/dist/components/tt-form/src/form-render/form.vue2.js +197 -0
  81. package/dist/components/tt-form/src/form-render/form.vue3.js +5 -0
  82. package/dist/components/tt-form/src/form-render/helper.js +22 -0
  83. package/dist/components/tt-form/src/form-render/rootWrapperClass.js +10 -0
  84. package/dist/components/tt-form/src/formApi.js +790 -0
  85. package/dist/components/tt-form/src/group-form/GroupForm.vue2.js +223 -0
  86. package/dist/components/tt-form/src/group-form/GroupForm.vue3.js +5 -0
  87. package/dist/components/tt-form/src/group-form/GroupSection.vue2.js +278 -0
  88. package/dist/components/tt-form/src/group-form/GroupSection.vue3.js +5 -0
  89. package/dist/components/tt-form/src/group-form/LazyFormField.vue.js +153 -0
  90. package/dist/components/tt-form/src/group-form/LazyFormField.vue3.js +5 -0
  91. package/dist/components/tt-form/src/group-form/groupFormApi.js +700 -0
  92. package/dist/components/tt-form/src/group-form/lazyContext.js +38 -0
  93. package/dist/components/tt-form/src/group-form/useGroupForm.js +83 -0
  94. package/dist/components/tt-form/src/group-form/utils.js +106 -0
  95. package/dist/components/tt-form/src/hooks/useArrayRegistry.js +22 -0
  96. package/dist/components/tt-form/src/hooks/useFieldArray.js +137 -0
  97. package/dist/components/tt-form/src/hooks/useForwardPriorityValues.js +33 -0
  98. package/dist/components/tt-form/src/hooks/useSelectCollapse.js +81 -0
  99. package/dist/components/tt-form/src/index.vue2.js +149 -0
  100. package/dist/components/tt-form/src/index.vue3.js +5 -0
  101. package/dist/components/tt-form/src/shared/createContext.js +14 -0
  102. package/dist/components/tt-form/src/shared/global-state.js +22 -0
  103. package/dist/components/tt-form/src/shared/zod-defaults.js +47 -0
  104. package/dist/components/tt-form/src/types/forms.js +6 -0
  105. package/dist/components/tt-form/src/useForm.js +28 -0
  106. package/dist/components/tt-form/src/useFormContext.js +320 -0
  107. package/dist/components/tt-form/src/utils/array-path.js +18 -0
  108. package/dist/components/tt-form-item-error-tooltip/index.js +9 -0
  109. package/dist/components/tt-form-item-error-tooltip/index.vue.js +183 -0
  110. package/dist/components/tt-form-item-error-tooltip/index.vue3.js +5 -0
  111. package/dist/components/tt-icon/components/AddIcon.vue.js +28 -0
  112. package/dist/components/tt-icon/components/AddIcon.vue2.js +4 -0
  113. package/dist/components/tt-icon/components/SubIcon.vue.js +28 -0
  114. package/dist/components/tt-icon/components/SubIcon.vue2.js +4 -0
  115. package/dist/components/tt-icon/index.js +11 -0
  116. package/dist/components/tt-icon/index.vue.js +8 -0
  117. package/dist/components/tt-icon/index.vue2.js +115 -0
  118. package/dist/components/tt-image/index.js +9 -0
  119. package/dist/components/tt-image/src/components/ImageViewer.js +41 -0
  120. package/dist/components/tt-image/tt-image.js +55 -0
  121. package/dist/components/tt-loading/index.js +8 -0
  122. package/dist/components/tt-loading/src/directive.js +51 -0
  123. package/dist/components/tt-loading/src/loading.vue.js +7 -0
  124. package/dist/components/tt-loading/src/loading.vue2.js +75 -0
  125. package/dist/components/tt-loading/src/service.js +79 -0
  126. package/dist/components/tt-log/index.js +7 -0
  127. package/dist/components/tt-log/index.vue.js +30 -0
  128. package/dist/components/tt-log/index.vue2.js +4 -0
  129. package/dist/components/tt-modal/index.js +14 -0
  130. package/dist/components/tt-modal/src/RenderModal.vue.js +310 -0
  131. package/dist/components/tt-modal/src/RenderModal.vue3.js +5 -0
  132. package/dist/components/tt-modal/src/components/ModalFooter.vue.js +7 -0
  133. package/dist/components/tt-modal/src/components/ModalFooter.vue2.js +74 -0
  134. package/dist/components/tt-modal/src/components/ModalHeader.vue.js +7 -0
  135. package/dist/components/tt-modal/src/components/ModalHeader.vue2.js +22 -0
  136. package/dist/components/tt-modal/src/components/ModalWrapper.vue.js +48 -0
  137. package/dist/components/tt-modal/src/components/ModalWrapper.vue2.js +4 -0
  138. package/dist/components/tt-modal/src/hooks/useModalRender.js +131 -0
  139. package/dist/components/tt-modal/src/index.js +17 -0
  140. package/dist/components/tt-modal/src/props.js +75 -0
  141. package/dist/components/tt-modal/src/utils/modal-api.js +200 -0
  142. package/dist/components/tt-modal/src/utils/modal-stack.js +28 -0
  143. package/dist/components/tt-modal-form/hooks/useModalFormSlot.js +22 -0
  144. package/dist/components/tt-modal-form/index.vue.js +178 -0
  145. package/dist/components/tt-modal-form/index.vue2.js +4 -0
  146. package/dist/components/tt-modal-form/useModalForm.js +30 -0
  147. package/dist/components/tt-nav-anchor/index.js +8 -0
  148. package/dist/components/tt-nav-anchor/src/TtNavAnchor.vue.js +234 -0
  149. package/dist/components/tt-nav-anchor/src/TtNavAnchor.vue3.js +5 -0
  150. package/dist/components/tt-nav-anchor/src/constants.js +4 -0
  151. package/dist/components/tt-panel-select/index.js +7 -0
  152. package/dist/components/tt-panel-select/src/common.js +4 -0
  153. package/dist/components/tt-panel-select/src/components/PanelLeft.vue.js +56 -0
  154. package/dist/components/tt-panel-select/src/components/PanelLeft.vue2.js +4 -0
  155. package/dist/components/tt-panel-select/src/components/PanelMiddle.vue.js +277 -0
  156. package/dist/components/tt-panel-select/src/components/PanelMiddle.vue2.js +4 -0
  157. package/dist/components/tt-panel-select/src/components/PanelRight.vue.js +108 -0
  158. package/dist/components/tt-panel-select/src/components/PanelRight.vue2.js +4 -0
  159. package/dist/components/tt-panel-select/src/hooks/usePanelData.js +184 -0
  160. package/dist/components/tt-panel-select/src/hooks/usePanelSelection.js +91 -0
  161. package/dist/components/tt-panel-select/src/index.vue.js +386 -0
  162. package/dist/components/tt-panel-select/src/index.vue2.js +4 -0
  163. package/dist/components/tt-select/index.js +8 -0
  164. package/dist/components/tt-select/src/Select.vue.js +315 -0
  165. package/dist/components/tt-select/src/Select.vue3.js +5 -0
  166. package/dist/components/tt-select/src/components/SelectTable.vue.js +86 -0
  167. package/dist/components/tt-select/src/components/SelectTable.vue3.js +5 -0
  168. package/dist/components/tt-select/src/components/Table.vue.js +307 -0
  169. package/dist/components/tt-select/src/components/Table.vue3.js +5 -0
  170. package/dist/components/tt-select/src/const.js +19 -0
  171. package/dist/components/tt-select/src/hooks/useDataSource.js +196 -0
  172. package/dist/components/tt-select/src/hooks/useGrid.js +97 -0
  173. package/dist/components/tt-select/src/hooks/useKeyboard.js +63 -0
  174. package/dist/components/tt-select/src/hooks/usePagination.js +45 -0
  175. package/dist/components/tt-select/src/hooks/useSelect.js +100 -0
  176. package/dist/components/tt-select/src/hooks/useSelectTableEvent.d.ts +1 -1
  177. package/dist/components/tt-select/src/hooks/useSelectTableEvent.js +345 -0
  178. package/dist/components/tt-select/src/props.js +201 -0
  179. package/dist/components/tt-select/src/utils/index.js +16 -0
  180. package/dist/components/tt-table/index.js +33 -0
  181. package/dist/components/tt-table/src/Table.vue.js +623 -0
  182. package/dist/components/tt-table/src/Table.vue3.js +5 -0
  183. package/dist/components/tt-table/src/TableForm.vue.js +317 -0
  184. package/dist/components/tt-table/src/TableForm.vue2.js +4 -0
  185. package/dist/components/tt-table/src/componentMap.js +4 -0
  186. package/dist/components/tt-table/src/components/RowContext.js +24 -0
  187. package/dist/components/tt-table/src/components/TableAction.vue.js +222 -0
  188. package/dist/components/tt-table/src/components/TableAction.vue2.js +4 -0
  189. package/dist/components/tt-table/src/components/TableButtons.js +117 -0
  190. package/dist/components/tt-table/src/components/TableColumnModal.vue2.js +233 -0
  191. package/dist/components/tt-table/src/components/TableColumnModal.vue3.js +5 -0
  192. package/dist/components/tt-table/src/components/TableToobalTools.vue.js +87 -0
  193. package/dist/components/tt-table/src/components/TableToobalTools.vue2.js +4 -0
  194. package/dist/components/tt-table/src/emits.js +15 -0
  195. package/dist/components/tt-table/src/hooks/useCellArea.js +15 -0
  196. package/dist/components/tt-table/src/hooks/useColumns.js +275 -0
  197. package/dist/components/tt-table/src/hooks/useCustomColumns.js +53 -0
  198. package/dist/components/tt-table/src/hooks/useDataSource.js +224 -0
  199. package/dist/components/tt-table/src/hooks/useLeftRightSlot.js +64 -0
  200. package/dist/components/tt-table/src/hooks/usePagination.js +44 -0
  201. package/dist/components/tt-table/src/hooks/useRowSelection.js +84 -0
  202. package/dist/components/tt-table/src/hooks/useTableContext.js +20 -0
  203. package/dist/components/tt-table/src/hooks/useTableEvent.js +197 -0
  204. package/dist/components/tt-table/src/hooks/useTableForm.js +60 -0
  205. package/dist/components/tt-table/src/hooks/useTableRender.js +33 -0
  206. package/dist/components/tt-table/src/hooks/useTableSlot.js +17 -0
  207. package/dist/components/tt-table/src/props.js +482 -0
  208. package/dist/components/tt-table/src/toolProps.js +30 -0
  209. package/dist/components/tt-table/src/utils/context.js +17 -0
  210. package/dist/components/tt-table/src/utils/table-api.js +386 -0
  211. package/dist/components/tt-table/src/utils/table-form-api.js +122 -0
  212. package/dist/components/tt-text/index.js +7 -0
  213. package/dist/components/tt-text/index.vue.js +7 -0
  214. package/dist/components/tt-text/index.vue2.js +73 -0
  215. package/dist/components/tt-upload/index.js +9 -0
  216. package/dist/components/tt-upload/src/TtUpload.vue.js +305 -0
  217. package/dist/components/tt-upload/src/TtUpload.vue2.js +4 -0
  218. package/dist/components/tt-upload/src/typing.js +107 -0
  219. package/dist/directives/auto-tip/index.js +62 -0
  220. package/dist/directives/dialog-resize/index.js +49 -0
  221. package/dist/directives/dialog-resize/use-css-variable.js +44 -0
  222. package/dist/directives/dialog-resize/use-draggable.js +35 -0
  223. package/dist/directives/dialog-resize/use-fullscreen.js +38 -0
  224. package/dist/directives/dialog-resize/use-parse-translate.js +9 -0
  225. package/dist/directives/dialog-resize/use-resizer.js +37 -0
  226. package/dist/directives/disabled-tip/index.js +78 -0
  227. package/dist/directives/index.js +8 -0
  228. package/dist/hooks/useDataPermissionOptions.js +142 -0
  229. package/dist/hooks/useFormSchemasLink.js +261 -0
  230. package/dist/hooks/useFormat.js +44 -0
  231. package/dist/hooks/useLoading.js +22 -0
  232. package/dist/hooks/useScreenshotOss.js +69 -0
  233. package/dist/hooks/useSetup.js +59 -0
  234. package/dist/index.js +142 -60274
  235. package/dist/plugins/default/renderCellContent.js +58 -0
  236. package/dist/plugins/vxeTable/switchStatus.js +91 -0
  237. package/dist/plugins.js +4 -146
  238. package/dist/style.css +1 -1
  239. package/dist/utils/xhr.js +8 -0
  240. package/package.json +5 -3
  241. package/dist/index-NG5FNCLD.js +0 -3430
  242. package/dist/index.modern-4Cf3dcJP.js +0 -3069
@@ -0,0 +1,33 @@
1
+ import { useStore as i } from "@tanstack/vue-store";
2
+ import { defineComponent as s, h as p } from "vue";
3
+ import f from "../Table.vue.js";
4
+ /* empty css */
5
+ import u from "../TableForm.vue.js";
6
+ import { TableApi as c } from "../utils/table-api.js";
7
+ import { TableFormApi as d } from "../utils/table-form-api.js";
8
+ function S(r) {
9
+ const t = new d(r), e = t;
10
+ return e.useStore = (n) => i(t.store, n), [s(
11
+ (n, { attrs: a, slots: o }) => () => p(u, { ...r, ...n, ...a, tableFormApi: e }, o),
12
+ {
13
+ name: "TtTableFormRender",
14
+ inheritAttrs: !1
15
+ }
16
+ ), e];
17
+ }
18
+ function w(r) {
19
+ const t = new c(r), e = t;
20
+ e.useStore = (o) => i(t.store, o);
21
+ const { testId: m } = r, n = m ? { testId: m } : {};
22
+ return [s(
23
+ (o, { attrs: l, slots: b }) => () => p(f, { ...n, ...o, ...l, tableApi: e }, b),
24
+ {
25
+ name: "TtTableRender",
26
+ inheritAttrs: !1
27
+ }
28
+ ), e];
29
+ }
30
+ export {
31
+ S as useTableFormRender,
32
+ w as useTableRender
33
+ };
@@ -0,0 +1,17 @@
1
+ import { useTemplateSlot as e } from "@dazhicheng-ui/hooks/useTemplateSlot";
2
+ function c() {
3
+ const { getSlotKeys: t, replaceSlotKey: o } = e("t-"), { getSlotKeys: l, replaceSlotKey: r } = e("form-");
4
+ return {
5
+ replaceTableSlotKey: o,
6
+ // 表格插槽key前缀替换方法
7
+ replaceFormSlotKey: r,
8
+ // 表单插槽key前缀替换方法
9
+ getTableSlotKeysFunc: t,
10
+ // 获取表格插槽key的方法
11
+ getFormSlotKeysFunc: l
12
+ // 获取表单插槽key的方法
13
+ };
14
+ }
15
+ export {
16
+ c as useTableSlot
17
+ };
@@ -0,0 +1,482 @@
1
+ import { isFunction as f } from "@dazhicheng/utils";
2
+ import { propTypes as t } from "@dazhicheng/hooks";
3
+ import { GlobalConfig as l } from "@dazhicheng-ui/hooks/useSetup";
4
+ const r = {
5
+ /** 是否显示分页 */
6
+ showPager: t.bool.def(!0),
7
+ /** 数据总数 */
8
+ total: t.number.def(0),
9
+ /** 当前页数 field */
10
+ currentPageField: {
11
+ type: String,
12
+ default: () => {
13
+ var e;
14
+ return (e = l.table) == null ? void 0 : e.currentPageField;
15
+ }
16
+ },
17
+ /** 当前页的大小 field */
18
+ pageSizeField: {
19
+ type: String,
20
+ default: () => {
21
+ var e;
22
+ return (e = l.table) == null ? void 0 : e.pageSizeField;
23
+ }
24
+ },
25
+ /** 总数 field */
26
+ totalField: {
27
+ type: String,
28
+ default: () => {
29
+ var e;
30
+ return (e = l.table) == null ? void 0 : e.totalField;
31
+ }
32
+ },
33
+ /** 数据的 field */
34
+ dataField: {
35
+ type: String,
36
+ default: () => {
37
+ var e;
38
+ return (e = l.table) == null ? void 0 : e.dataField;
39
+ }
40
+ }
41
+ }, n = {
42
+ /** 是否显示复选框 */
43
+ showCheckbox: t.bool.def(!1),
44
+ /** 是否显示单选框 */
45
+ showRadio: t.bool.def(!1),
46
+ /** 是否显示展开列 */
47
+ showExpand: t.bool.def(!1),
48
+ /** 是否显示序号 */
49
+ showIndex: t.bool.def(!1),
50
+ /** 是否需要列拖拽 */
51
+ isCellResize: t.bool.def(!1),
52
+ /**
53
+ * 是否拖动列
54
+ * @deprecated 请使用 column-config drag 配合column-drag-config配置 支持的版本看官方文档,后续不在维护列拖拽
55
+ * @default true
56
+ */
57
+ isColumnsDrag: t.bool.def(!1),
58
+ /** 是否列排序 */
59
+ isCellSort: t.bool.def(!1),
60
+ /**
61
+ * 是否checkbox区域选择 选中数据
62
+ * @deprecated
63
+ */
64
+ isAreaCheckData: t.bool.def(!1),
65
+ /** 是否显示操作列 */
66
+ showAction: t.bool.def(!1),
67
+ /** 操作列宽度 */
68
+ actionWidth: t.number.def(0),
69
+ /** 操作列列名 */
70
+ actionTitle: t.string.def(""),
71
+ /** 操作列Props */
72
+ actionProps: {
73
+ type: Object,
74
+ default: () => ({})
75
+ },
76
+ /** 序号列Props */
77
+ indexColumnProps: {
78
+ type: Object,
79
+ default: () => ({})
80
+ },
81
+ /** 复选框列Props */
82
+ checkboxColumnProps: {
83
+ type: Object,
84
+ default: () => ({})
85
+ },
86
+ /** 展开行props */
87
+ expandColumnProps: {
88
+ type: Object,
89
+ default: () => ({})
90
+ },
91
+ /** 单选框列Props */
92
+ radioColumnProps: {
93
+ type: Object,
94
+ default: () => ({})
95
+ },
96
+ /** 表格行id */
97
+ tableRowId: {
98
+ type: String,
99
+ default: () => {
100
+ var e;
101
+ return (e = l.table) == null ? void 0 : e.tableRowId;
102
+ }
103
+ },
104
+ /** 自定义Column函数 */
105
+ customizeColumn: {
106
+ type: Function
107
+ // default: () => GlobalConfig.table?.customizeColumn,
108
+ }
109
+ }, i = {
110
+ /** api请求方法 */
111
+ api: {
112
+ type: Function,
113
+ default: null
114
+ },
115
+ /** 表格额外参数 */
116
+ searchInfo: {
117
+ type: Object,
118
+ default: () => ({})
119
+ },
120
+ /** 是否初始化加载数据 */
121
+ immediate: t.bool.def(!0),
122
+ /**
123
+ * 请求的状态吗
124
+ * @deprecated
125
+ */
126
+ resultCode: {
127
+ type: [String, Number],
128
+ default: 200
129
+ },
130
+ /** 请求后的回调 */
131
+ afterFetch: {
132
+ type: Function,
133
+ default: null
134
+ },
135
+ /** 请求前的回调 */
136
+ beforeFetch: {
137
+ type: Function,
138
+ default: null
139
+ },
140
+ /** data */
141
+ data: {
142
+ type: Array,
143
+ default: []
144
+ },
145
+ /** 是否滚动加载数据 */
146
+ isScrollFetch: {
147
+ type: Boolean,
148
+ default: !1
149
+ },
150
+ /** 滚动加载数据是否显示loading */
151
+ showScrollFetchLoading: {
152
+ type: Boolean,
153
+ default: !0
154
+ }
155
+ }, u = {
156
+ /** 是否显示toolbar */
157
+ showToolbar: t.bool.def(!1),
158
+ /** 具体某些列排序 field数组 */
159
+ columnsFieldSort: t.array.def([]),
160
+ /** 具体某些列不排序 field数组 */
161
+ columnsFieldNoSort: t.array.def([]),
162
+ /** 是否显示右边刷新按钮 */
163
+ showRefresh: {
164
+ type: Boolean,
165
+ default: () => {
166
+ var e;
167
+ return (e = l.table) == null ? void 0 : e.showRefresh;
168
+ }
169
+ },
170
+ /** 是否显示右边设置 */
171
+ showSetting: {
172
+ type: Boolean,
173
+ default: () => {
174
+ var e;
175
+ return (e = l.table) == null ? void 0 : e.showSetting;
176
+ }
177
+ },
178
+ /** 是否显示自定义列 */
179
+ showSetColumn: {
180
+ type: Boolean,
181
+ default: () => {
182
+ var e;
183
+ return (e = l.table) == null ? void 0 : e.showSetColumn;
184
+ }
185
+ },
186
+ /** 是否显示自定义行距 */
187
+ showLineHeight: {
188
+ type: Boolean,
189
+ default: () => {
190
+ var e;
191
+ return (e = l.table) == null ? void 0 : e.showLineHeight;
192
+ }
193
+ },
194
+ /** 不可自定义列数组 field数组 */
195
+ notSetColumnField: t.array.def([]),
196
+ /** 需要对不显示的字段进行过滤 主要针对于自定义 field数组 */
197
+ filterNoVisibleField: t.array.def([]),
198
+ /** 是否显示表格上方 alert */
199
+ showTableAlert: t.bool.def(!1)
200
+ }, b = {
201
+ modelValue: {
202
+ type: Array,
203
+ default: () => []
204
+ },
205
+ /** 标题内容 */
206
+ title: t.string.def(""),
207
+ /** 是否显示标题 */
208
+ showTitle: t.bool.def(!1),
209
+ /** 是否自适应高度 */
210
+ autoHeight: t.bool.def(!0),
211
+ /**
212
+ * 额外减去的高度
213
+ * @deprecated
214
+ */
215
+ offsetHeight: t.number.def(12),
216
+ /** 左侧插槽的宽度 */
217
+ leftSlotWidth: t.number.def(0),
218
+ /** 右侧插槽的宽度 */
219
+ rightSlotWidth: t.number.def(0),
220
+ /** loading text */
221
+ loadingText: {
222
+ type: String,
223
+ default: () => {
224
+ var e;
225
+ return (e = l.table) == null ? void 0 : e.loadingText;
226
+ }
227
+ },
228
+ /** 暂无数据的样式 */
229
+ emptyImageStyle: t.object.def({}),
230
+ /** 暂无数据 */
231
+ emptyText: {
232
+ type: String,
233
+ default: () => {
234
+ var e;
235
+ return (e = l.table) == null ? void 0 : e.emptyText;
236
+ }
237
+ },
238
+ /**
239
+ * 空数据图片状态, 对于不传api的默认展示情况
240
+ * @default 'no-data'
241
+ */
242
+ emptyImageStatus: {
243
+ type: String,
244
+ default: "no-data"
245
+ },
246
+ /** 未查询时文字 */
247
+ noSearchText: {
248
+ type: String,
249
+ default: () => {
250
+ var e;
251
+ return (e = l.table) == null ? void 0 : e.noSearchText;
252
+ }
253
+ },
254
+ /** 是否手动触发查询事件 */
255
+ isHanderSubmit: t.bool.def(!1),
256
+ /** 储存的key值,支持函数动态获取 */
257
+ columnsKey: {
258
+ type: [String, Function],
259
+ default: ""
260
+ },
261
+ /** 是否开启服务端缓存 */
262
+ useHttpCache: {
263
+ type: Boolean,
264
+ default: () => {
265
+ var e;
266
+ return (e = l.table) == null ? void 0 : e.useHttpCache;
267
+ }
268
+ },
269
+ /** 开启服务端缓存时默认展示的列 用户列为null时默认展示的列 */
270
+ defaultDisplayFields: {
271
+ type: Array,
272
+ default: () => {
273
+ var e;
274
+ return (e = l.table) == null ? void 0 : e.defaultDisplayFields;
275
+ }
276
+ },
277
+ /**
278
+ * 是否需要行拖拽-树形表格
279
+ * @deprecated 请使用 row-config drag 配合row-drag-config配置 支持的版本看官方文档,后续不在维护行拖拽
280
+ * @default false
281
+ */
282
+ treeNode: t.bool.def(!1),
283
+ /** 外部插槽 */
284
+ getSyncSlotComponent: {
285
+ type: Function
286
+ },
287
+ /** 是否清空树形展开状态 */
288
+ clearTreeExpand: t.bool.def(!0),
289
+ /** 是否进行国际化 */
290
+ isI18n: t.bool.def(!0),
291
+ /**
292
+ * 外部数据是否拷贝一份
293
+ * 设置为 false 时,会有性能问题
294
+ * @default true
295
+ */
296
+ isDataCloneDeep: t.bool.def(!0),
297
+ /** 表格的api */
298
+ tableApi: {
299
+ type: Object
300
+ },
301
+ /** 表格的api */
302
+ formApi: {
303
+ type: Object
304
+ },
305
+ /** 是否使用搜索form */
306
+ useSearchForm: t.bool.def(!1),
307
+ /** 是否禁用Teleport将节点输送至body */
308
+ disabledTeleport: t.bool.def(!1),
309
+ /** 表格 testId,用于生成测试标识 */
310
+ testId: {
311
+ type: String,
312
+ default: void 0
313
+ },
314
+ ...r,
315
+ ...n,
316
+ ...i,
317
+ ...u
318
+ }, s = {
319
+ /** 按键配置项 */
320
+ keyboardConfig: {
321
+ type: Object,
322
+ default: () => {
323
+ var e;
324
+ return (e = l.table) == null ? void 0 : e.keyboardConfig;
325
+ }
326
+ },
327
+ /** 右键菜单配置项 */
328
+ menuConfig: {
329
+ type: Object,
330
+ default: () => ({})
331
+ },
332
+ /** 鼠标配置项 */
333
+ mouseConfig: {
334
+ type: Object,
335
+ default: () => {
336
+ var e;
337
+ return (e = l.table) == null ? void 0 : e.mouseConfig;
338
+ }
339
+ },
340
+ /** 复选框配置项 */
341
+ checkboxConfig: {
342
+ type: Object,
343
+ default: () => {
344
+ var e;
345
+ return (e = l.table) == null ? void 0 : e.checkboxConfig;
346
+ }
347
+ },
348
+ /** 单选框配置项 */
349
+ radioConfig: {
350
+ type: Object,
351
+ default: () => {
352
+ var e;
353
+ return (e = l.table) == null ? void 0 : e.radioConfig;
354
+ }
355
+ }
356
+ }, p = Object.entries(b).reduce((e, a) => {
357
+ if (a) {
358
+ const [d, o] = a;
359
+ f(o.default) ? e[d] = o.default() : e[d] = o.default;
360
+ }
361
+ return e;
362
+ }, {}), h = {
363
+ tableData: {
364
+ type: Array,
365
+ default: () => []
366
+ },
367
+ /** table参数 */
368
+ table: {
369
+ type: Object,
370
+ default: p
371
+ },
372
+ /** 是否使用搜索form */
373
+ useSearchForm: t.bool.def(!0),
374
+ /** BasicFormProps 的配置 */
375
+ form: {
376
+ type: Object,
377
+ default: () => ({})
378
+ },
379
+ /** 查询条件请求之前处理 */
380
+ handleSearchInfoFn: {
381
+ type: Function,
382
+ default: null
383
+ },
384
+ /** 刷新前的调用方法 */
385
+ tableRefreshBefore: {
386
+ type: Function,
387
+ default: null
388
+ },
389
+ /** TtTableTools的props */
390
+ toolConfig: {
391
+ type: Object,
392
+ default: null
393
+ },
394
+ /** 表格行id */
395
+ tableRowId: {
396
+ type: String,
397
+ default: () => {
398
+ var e;
399
+ return (e = l.table) == null ? void 0 : e.tableRowId;
400
+ }
401
+ },
402
+ /** 表格 testId,用于生成测试标识 */
403
+ testId: {
404
+ type: String,
405
+ default: void 0
406
+ },
407
+ /** 表格的api */
408
+ tableFormApi: {
409
+ type: Object
410
+ }
411
+ }, m = {
412
+ /** 列配置 */
413
+ columns: {
414
+ type: Array,
415
+ default: () => []
416
+ },
417
+ /**
418
+ * 表格的高度;支持铺满父容器或者固定高度,如果设置 auto 为铺满父容器(如果设置为 auto,则必须确保存在父节点且不允许存在相邻元素)
419
+ */
420
+ height: {
421
+ type: [Number, String],
422
+ default: void 0
423
+ },
424
+ /**
425
+ * 设置所有内容过长时显示为省略号(如果是固定列建议设置该值,提升渲染速度
426
+ * @default true
427
+ */
428
+ showOverflow: {
429
+ type: [String, Boolean],
430
+ default: !0
431
+ },
432
+ /**
433
+ * @description 内部使用插槽重写title内容。true 和 'tooltip' 都会有 tooltip 效果,false 和其他的值会显示省略号不会有 tooltip 效果
434
+ * @default true
435
+ */
436
+ showHeaderOverflow: {
437
+ type: [String, Boolean],
438
+ default: !0
439
+ },
440
+ /** 分页配置 */
441
+ pagerConfig: {
442
+ type: Object,
443
+ default: () => {
444
+ var e;
445
+ return (e = l.table) == null ? void 0 : e.pagerConfig;
446
+ }
447
+ },
448
+ /** toolbar 配置 */
449
+ toolbarConfig: {
450
+ type: Object,
451
+ default: () => null
452
+ },
453
+ /** 缩放配置项 */
454
+ zoomConfig: {
455
+ type: Object,
456
+ default: () => null
457
+ },
458
+ /** 表格大小 */
459
+ size: {
460
+ type: String,
461
+ default: () => {
462
+ var e;
463
+ return (e = l.table) == null ? void 0 : e.size;
464
+ }
465
+ },
466
+ /**
467
+ * tooltip错误提示方向,用于控制错误信息提示的显示位置
468
+ * 可选值: 'top', 'bottom', 'left', 'right'
469
+ * @default 'right'
470
+ */
471
+ toolTipErrorPlacement: {
472
+ type: String,
473
+ default: "right"
474
+ },
475
+ ...s
476
+ };
477
+ export {
478
+ h as tableFormProps,
479
+ m as tableOtherProps,
480
+ s as tableProProps,
481
+ b as tableProps
482
+ };
@@ -0,0 +1,30 @@
1
+ const e = {
2
+ /** 是否显示设置 */
3
+ showSetting: {
4
+ type: Boolean,
5
+ default: !0
6
+ },
7
+ /** 是否显示刷新按钮 */
8
+ showRefresh: {
9
+ type: Boolean,
10
+ default: !0
11
+ },
12
+ /** 是否显示导出按钮 */
13
+ showExport: {
14
+ type: Boolean,
15
+ default: !1
16
+ },
17
+ /** 是否显示列设置按钮 */
18
+ showSetColumn: {
19
+ type: Boolean,
20
+ default: !0
21
+ },
22
+ /** 储存的key,支持函数动态获取 */
23
+ columnsKey: {
24
+ type: [String, Function],
25
+ default: ""
26
+ }
27
+ };
28
+ export {
29
+ e as toolProps
30
+ };
@@ -0,0 +1,17 @@
1
+ import { inject as r, provide as c } from "vue";
2
+ function s(t, u) {
3
+ const i = `${t}Context`, e = Symbol(i);
4
+ return [(n) => {
5
+ const o = r(e, n);
6
+ if (o || o === null) return o;
7
+ throw new Error(
8
+ `Injection \`${e.toString()}\` not found. Component must be used within ${Array.isArray(t) ? `one of the following components: ${t.join(", ")}` : `\`${t}\``}`
9
+ );
10
+ }, (n) => (c(e, n), n)];
11
+ }
12
+ const [d, l] = s("FormActionTestIds");
13
+ export {
14
+ s as createContext,
15
+ d as injectFormActionTestIds,
16
+ l as provideFormActionTestIds
17
+ };