@aplus-frontend/ui 0.5.3 → 0.5.5

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 (193) hide show
  1. package/es/index.mjs +37 -33
  2. package/es/src/ap-action/group/index.vue.mjs +3 -3
  3. package/es/src/ap-action/item/index.vue2.mjs +5 -5
  4. package/es/src/ap-action/item-dropdown/index.vue.mjs +7 -7
  5. package/es/src/ap-action/item-modal/index.vue.mjs +2 -2
  6. package/es/src/ap-action/item-popconfirm/index.vue.mjs +2 -2
  7. package/es/src/ap-button/ap-action-button.vue.mjs +2 -2
  8. package/es/src/ap-button/ap-button.vue.mjs +2 -2
  9. package/es/src/ap-button/ap-confirm-button.vue.mjs +2 -2
  10. package/es/src/ap-descriptions/ap-descriptions.vue.mjs +3 -3
  11. package/es/src/ap-descriptions/help-message/index.vue2.mjs +4 -4
  12. package/es/src/ap-download/ap-download.vue.mjs +1 -1
  13. package/es/src/ap-field/checkbox/index.vue.mjs +1 -1
  14. package/es/src/ap-field/date/index.vue.mjs +4 -4
  15. package/es/src/ap-field/date-range/index.vue.mjs +8 -8
  16. package/es/src/ap-field/index.mjs +30 -30
  17. package/es/src/ap-field/number/index.vue.mjs +8 -8
  18. package/es/src/ap-field/radio/index.vue.mjs +1 -1
  19. package/es/src/ap-field/rate/index.vue.mjs +2 -2
  20. package/es/src/ap-field/segmented/index.vue.mjs +1 -1
  21. package/es/src/ap-field/select/index.vue.mjs +2 -2
  22. package/es/src/ap-field/slider/index.vue.mjs +4 -4
  23. package/es/src/ap-field/switch/index.vue.mjs +3 -3
  24. package/es/src/ap-field/text/index.vue2.mjs +13 -13
  25. package/es/src/ap-field/text/password.vue.mjs +2 -2
  26. package/es/src/ap-field/text-area/index.vue.mjs +3 -3
  27. package/es/src/ap-form/ap-form.vue2.mjs +2 -2
  28. package/es/src/ap-form/drawer-form/index.vue.mjs +9 -9
  29. package/es/src/ap-form/item/index.vue.mjs +7 -7
  30. package/es/src/ap-form/item-group/index.vue.mjs +3 -3
  31. package/es/src/ap-form/items/checkbox/index.vue.mjs +2 -2
  32. package/es/src/ap-form/items/date/index.vue.mjs +2 -2
  33. package/es/src/ap-form/items/date-range/index.vue.mjs +2 -2
  34. package/es/src/ap-form/items/number/index.vue.mjs +2 -2
  35. package/es/src/ap-form/items/radio/index.vue.mjs +2 -2
  36. package/es/src/ap-form/items/select/index.vue.mjs +2 -2
  37. package/es/src/ap-form/items/switch/index.vue.mjs +2 -2
  38. package/es/src/ap-form/items/text/group.vue2.mjs +2 -2
  39. package/es/src/ap-form/items/text/index.vue2.mjs +2 -2
  40. package/es/src/ap-form/items/text/password.vue.mjs +2 -2
  41. package/es/src/ap-form/items/text-area/index.vue.mjs +2 -2
  42. package/es/src/ap-form/modal-form/index.vue.mjs +7 -7
  43. package/es/src/ap-form/render/item.vue.mjs +2 -2
  44. package/es/src/ap-form/search-form/index.vue.mjs +1 -1
  45. package/es/src/ap-form/set/index.vue.mjs +1 -1
  46. package/es/src/ap-grid/editable/form-item.vue.d.ts +16 -0
  47. package/es/src/ap-grid/editable/form-item.vue.mjs +257 -0
  48. package/es/src/ap-grid/editable/form-item.vue2.mjs +4 -0
  49. package/es/src/ap-grid/editable/index.vue.d.ts +18 -0
  50. package/es/src/ap-grid/editable/index.vue.mjs +288 -0
  51. package/es/src/ap-grid/editable/index.vue2.mjs +4 -0
  52. package/es/src/ap-grid/editable/interface.d.ts +95 -0
  53. package/es/src/ap-grid/editable/interface.mjs +1 -0
  54. package/es/src/ap-grid/editable/style/css.d.ts +0 -0
  55. package/es/src/ap-grid/editable/style/css.js +1 -0
  56. package/es/src/ap-grid/editable/style/index.d.ts +0 -0
  57. package/es/src/ap-grid/editable/style/index.js +1 -0
  58. package/es/src/ap-grid/hooks/use-editable-columns.d.ts +6 -0
  59. package/es/src/ap-grid/hooks/use-editable-columns.mjs +68 -0
  60. package/es/src/ap-grid/hooks/use-inner-params.mjs +3 -3
  61. package/es/src/ap-grid/index.d.ts +4 -1
  62. package/es/src/ap-grid/index.mjs +3 -0
  63. package/es/src/ap-grid/index.vue.mjs +113 -103
  64. package/es/src/ap-grid/interface.d.ts +15 -0
  65. package/es/src/ap-grid/utils/col.mjs +39 -39
  66. package/es/src/ap-grid/utils/editable.d.ts +3 -0
  67. package/es/src/ap-grid/utils/editable.mjs +27 -0
  68. package/es/src/ap-grid/utils/table.mjs +24 -17
  69. package/es/src/ap-info-layout/ApInfoLayout.vue.mjs +2 -2
  70. package/es/src/ap-info-layout/ap-info-layout-admin/ApInfoLayoutAdmin.vue2.mjs +2 -2
  71. package/es/src/ap-info-layout/ap-info-layout-aplus/ap-info-layout.vue2.mjs +1 -1
  72. package/es/src/ap-list/index.vue.mjs +4 -4
  73. package/es/src/ap-table/ap-table.vue2.mjs +172 -159
  74. package/es/src/ap-table/components/dynamic-component/index.vue2.mjs +2 -2
  75. package/es/src/ap-table/components/index/index.vue2.mjs +2 -2
  76. package/es/src/ap-table/components/paragraph-ellipsis/index.vue2.mjs +3 -3
  77. package/es/src/ap-table/components/setting/modal/index.vue2.mjs +3 -3
  78. package/es/src/ap-table/components/setting/select-group/index.vue2.mjs +1 -1
  79. package/es/src/ap-table/components/setting/sortable/index.vue2.mjs +1 -1
  80. package/es/src/ap-table/components/setting/sortable/item.vue2.mjs +1 -1
  81. package/es/src/ap-table/components/setting/sorter/index.vue2.mjs +11 -11
  82. package/es/src/ap-table/components/setting/tree-select/index.vue2.mjs +1 -1
  83. package/es/src/ap-table/components/status/index.vue2.mjs +2 -2
  84. package/es/src/ap-table/constants.mjs +40 -40
  85. package/es/src/ap-table/context.d.ts +4 -4
  86. package/es/src/ap-table/hooks/use-sorted-filtered.d.ts +4 -1
  87. package/es/src/ap-table/hooks/use-sorted-filtered.mjs +11 -9
  88. package/es/src/ap-table/hooks/use-table-column-state.mjs +3 -3
  89. package/es/src/ap-table/hooks/use-table-paging-ng.d.ts +3 -1
  90. package/es/src/ap-table/hooks/use-table-paging-ng.mjs +53 -49
  91. package/es/src/ap-table/hooks/use-table-paging.d.ts +1 -1
  92. package/es/src/ap-tag/ap-tag-group.vue.mjs +8 -8
  93. package/es/src/ap-tag/ap-tag.vue.mjs +2 -2
  94. package/es/src/ap-upload/apUpload.vue.mjs +5 -5
  95. package/es/src/ap-upload/components/MultipleFile.vue2.mjs +3 -3
  96. package/es/src/ap-upload/components/Picture.vue2.mjs +6 -6
  97. package/es/src/ap-upload/components/SingleFile.vue2.mjs +7 -7
  98. package/es/src/business/ap-appendix/ap-appendix.vue2.mjs +1 -1
  99. package/es/src/business/ap-appendix/icons/file-icon.vue.mjs +2 -2
  100. package/es/src/business/ap-batch-action/ApBatchAction.vue2.mjs +2 -2
  101. package/es/src/business/ap-batch-action-group/ApBatchActionGroup.vue.d.ts +2 -2
  102. package/es/src/business/ap-batch-action-group/ApBatchActionGroup.vue2.mjs +10 -10
  103. package/es/src/business/ap-batch-action-group/MenuItemGroup.vue2.mjs +1 -1
  104. package/es/src/business/ap-batch-action-group/index.d.ts +4 -4
  105. package/es/src/business/ap-button-group/ApButtonGroup.vue2.mjs +1 -1
  106. package/es/src/business/ap-card/ApCard.vue2.mjs +7 -7
  107. package/es/src/business/ap-expand-alert/ApExpandAlert.vue2.mjs +11 -11
  108. package/es/src/business/ap-export-group/ApExportGroup.vue2.mjs +9 -9
  109. package/es/src/business/ap-group-search/ap-group-search.vue2.mjs +5 -5
  110. package/es/src/business/ap-group-search/extension-select/index.vue2.mjs +4 -4
  111. package/es/src/business/ap-group-search/images/icon-down.vue.mjs +2 -2
  112. package/es/src/business/ap-group-search/images/icon-line-select.vue.mjs +2 -2
  113. package/es/src/business/ap-group-search/popover-select/index.vue2.mjs +2 -2
  114. package/es/src/business/ap-image/ApImage.vue2.mjs +1 -1
  115. package/es/src/business/ap-input-radio/ApInputRadio.vue2.mjs +2 -2
  116. package/es/src/business/ap-ladder/ApLadder.vue2.mjs +1 -1
  117. package/es/src/business/ap-ladder/HelpMessageIcon.vue2.mjs +1 -1
  118. package/es/src/business/ap-select-layout/select-layout.vue2.mjs +4 -4
  119. package/es/src/business/ap-status/ApStatus.vue2.mjs +8 -8
  120. package/es/src/business/ap-status/group/ApStatusGroup.vue2.mjs +4 -4
  121. package/es/src/business/ap-summary/ap-summary.vue2.mjs +1 -1
  122. package/es/src/business/ap-table-modal/modal-title.vue2.mjs +2 -2
  123. package/es/src/business/ap-table-modal/table-layout/index.vue2.mjs +14 -14
  124. package/es/src/business/ap-table-modal/table-modal.vue2.mjs +3 -3
  125. package/es/src/business/ap-title/ApTitle.vue2.mjs +7 -7
  126. package/es/src/business/ap-upload-file/ap-upload-single/ap-upload-single.vue.mjs +1 -1
  127. package/es/src/business/ap-upload-file/icon/delete-icon.vue.mjs +2 -2
  128. package/es/src/business/ap-upload-file/icon/file-icon.vue.mjs +2 -2
  129. package/es/src/business/batch-input-group/form-item.vue.mjs +2 -2
  130. package/es/src/business/batch-input-group/index.vue.mjs +7 -6
  131. package/es/src/business/batch-input-group/popover-input/index.vue2.mjs +2 -2
  132. package/es/src/check-card/index.vue2.mjs +3 -3
  133. package/es/src/config-provider/config-provider-props.mjs +1 -1
  134. package/es/src/editable-table/form-item.vue.mjs +2 -2
  135. package/es/src/editable-table/index.vue.mjs +2 -2
  136. package/es/src/editable-table/utils.d.ts +3 -2
  137. package/es/src/full-screen/index.vue.mjs +3 -3
  138. package/es/src/hooks/useFullScreen.mjs +5 -5
  139. package/es/src/index.mjs +24 -20
  140. package/es/src/path-map.mjs +3 -1
  141. package/es/src/portal/index.vue.mjs +2 -2
  142. package/es/src/scroll-bar/index.vue.mjs +3 -3
  143. package/es/src/scroll-bar/internal.vue.mjs +2 -2
  144. package/es/src/scroll-view/index.vue.mjs +9 -9
  145. package/es/src/work-order-modal/help-message.vue2.mjs +2 -2
  146. package/es/src/work-order-modal/work-order-modal.vue.mjs +2 -2
  147. package/lib/index.js +1 -1
  148. package/lib/src/ap-action/item-dropdown/index.vue.js +1 -1
  149. package/lib/src/ap-field/index.js +1 -1
  150. package/lib/src/ap-field/text/index.vue2.js +1 -1
  151. package/lib/src/ap-grid/editable/form-item.vue.d.ts +16 -0
  152. package/lib/src/ap-grid/editable/form-item.vue.js +1 -0
  153. package/lib/src/ap-grid/editable/form-item.vue2.js +1 -0
  154. package/lib/src/ap-grid/editable/index.vue.d.ts +18 -0
  155. package/lib/src/ap-grid/editable/index.vue.js +1 -0
  156. package/lib/src/ap-grid/editable/index.vue2.js +1 -0
  157. package/lib/src/ap-grid/editable/interface.d.ts +95 -0
  158. package/lib/src/ap-grid/editable/interface.js +1 -0
  159. package/lib/src/ap-grid/editable/style/css.cjs +1 -0
  160. package/lib/src/ap-grid/editable/style/css.d.ts +0 -0
  161. package/lib/src/ap-grid/editable/style/index.cjs +1 -0
  162. package/lib/src/ap-grid/editable/style/index.d.ts +0 -0
  163. package/lib/src/ap-grid/hooks/use-editable-columns.d.ts +6 -0
  164. package/lib/src/ap-grid/hooks/use-editable-columns.js +1 -0
  165. package/lib/src/ap-grid/index.d.ts +4 -1
  166. package/lib/src/ap-grid/index.js +1 -1
  167. package/lib/src/ap-grid/index.vue.js +1 -1
  168. package/lib/src/ap-grid/interface.d.ts +15 -0
  169. package/lib/src/ap-grid/utils/col.js +1 -1
  170. package/lib/src/ap-grid/utils/editable.d.ts +3 -0
  171. package/lib/src/ap-grid/utils/editable.js +1 -0
  172. package/lib/src/ap-grid/utils/table.js +1 -1
  173. package/lib/src/ap-table/ap-table.vue2.js +1 -1
  174. package/lib/src/ap-table/constants.js +1 -1
  175. package/lib/src/ap-table/context.d.ts +4 -4
  176. package/lib/src/ap-table/hooks/use-sorted-filtered.d.ts +4 -1
  177. package/lib/src/ap-table/hooks/use-sorted-filtered.js +1 -1
  178. package/lib/src/ap-table/hooks/use-table-paging-ng.d.ts +3 -1
  179. package/lib/src/ap-table/hooks/use-table-paging-ng.js +1 -1
  180. package/lib/src/ap-table/hooks/use-table-paging.d.ts +1 -1
  181. package/lib/src/ap-upload/apUpload.vue.js +1 -1
  182. package/lib/src/business/ap-batch-action-group/ApBatchActionGroup.vue.d.ts +2 -2
  183. package/lib/src/business/ap-batch-action-group/index.d.ts +4 -4
  184. package/lib/src/business/batch-input-group/index.vue.js +2 -2
  185. package/lib/src/config-provider/config-provider-props.js +1 -1
  186. package/lib/src/editable-table/utils.d.ts +3 -2
  187. package/lib/src/index.js +1 -1
  188. package/lib/src/path-map.js +1 -1
  189. package/package.json +1 -1
  190. package/theme/ap-grid/editable.css +22 -0
  191. package/theme/ap-grid/editable.less +28 -0
  192. package/theme/index.css +22 -0
  193. package/theme/index.less +1 -0
@@ -1,26 +1,26 @@
1
- import { defineComponent as Ne, useSlots as Ie, ref as h, computed as s, unref as t, createVNode as f, Fragment as Y, watch as I, openBlock as m, createElementBlock as k, normalizeClass as y, normalizeStyle as K, mergeProps as w, createSlots as Z, withCtx as v, renderList as ee, createBlock as oe, resolveDynamicComponent as Ke, renderSlot as R, createCommentVNode as re, createElementVNode as E, normalizeProps as Ee, guardReactiveProps as Oe } from "vue";
2
- import { Divider as Ve, Table as Le } from "@aplus-frontend/antdv";
3
- import { useToken as $e } from "@aplus-frontend/antdv/es/theme/internal";
4
- import { ApForm as Ae } from "../ap-form/index.mjs";
5
- import { noRenderAsFormItemValueList as ae } from "./constants.mjs";
1
+ import { defineComponent as Ee, useSlots as Oe, ref as h, computed as s, unref as l, watch as k, createElementBlock as B, openBlock as p, normalizeStyle as K, normalizeClass as m, createCommentVNode as Z, createElementVNode as E, createVNode as y, mergeProps as w, createSlots as ee, withCtx as v, Fragment as oe, renderList as re, createBlock as ae, resolveDynamicComponent as Ve, renderSlot as R, normalizeProps as Le, guardReactiveProps as $e } from "vue";
2
+ import { Divider as Ae, Table as De } from "@aplus-frontend/antdv";
3
+ import { useToken as We } from "@aplus-frontend/antdv/es/theme/internal";
4
+ import { ApForm as je } from "../ap-form/index.mjs";
5
+ import { noRenderAsFormItemValueList as te } from "./constants.mjs";
6
6
  import "../config-provider/index.mjs";
7
- import { useTablePaging as De } from "./hooks/use-table-paging-ng.mjs";
8
- import { isUndefined as b, omit as te, isBoolean as We } from "lodash-unified";
9
- import { getColumnOrder as le, updateFormProps as je, getFieldProps as _e, getSearchFormItemRenderNode as He, recursionApColumns as ne, apColumnToColumn as Ue, getTableTitle as qe, getTableRenderType as Me, getTableRenderProps as Ge, getTableCellRenderNode as Je, falseToUndefined as Qe } from "./utils.mjs";
10
- import Xe from "./hooks/use-table-content-height.mjs";
11
- import Ye from "./hooks/use-table-row-selection.mjs";
12
- import { getScrollbarSize as Ze, isDef as eo } from "../utils/index.mjs";
7
+ import { useTablePaging as _e } from "./hooks/use-table-paging-ng.mjs";
8
+ import { isUndefined as g, omit as le, isBoolean as He } from "lodash-unified";
9
+ import { getColumnOrder as ne, updateFormProps as Ue, getFieldProps as qe, getSearchFormItemRenderNode as Me, recursionApColumns as se, falseToUndefined as Ge, getTableTitle as Je, getTableRenderType as Qe, getTableRenderProps as Xe, getTableCellRenderNode as Ye, apColumnToColumn as Ze } from "./utils.mjs";
10
+ import eo from "./hooks/use-table-content-height.mjs";
11
+ import oo from "./hooks/use-table-row-selection.mjs";
12
+ import { getScrollbarSize as ro, isDef as ao } from "../utils/index.mjs";
13
13
  import "./components/setting/modal/index.vue.mjs";
14
14
  import "./components/paragraph-ellipsis/index.vue.mjs";
15
- import { useProvideApTable as oo } from "./context.mjs";
15
+ import { useProvideApTable as to } from "./context.mjs";
16
16
  import "../scroll-bar/index.mjs";
17
- import { useStickyScroll as ro } from "./hooks/use-sticky-scroll.mjs";
18
- import { useNamespace as ao } from "../config-provider/hooks/use-namespace.mjs";
19
- import { useGlobalConfig as to } from "../config-provider/hooks/use-global-config.mjs";
20
- import lo from "./components/paragraph-ellipsis/index.vue2.mjs";
21
- import no from "./components/setting/modal/index.vue2.mjs";
22
- import so from "../scroll-bar/index.vue.mjs";
23
- const No = /* @__PURE__ */ Ne({
17
+ import { useStickyScroll as lo } from "./hooks/use-sticky-scroll.mjs";
18
+ import { useNamespace as no } from "../config-provider/hooks/use-namespace.mjs";
19
+ import { useGlobalConfig as so } from "../config-provider/hooks/use-global-config.mjs";
20
+ import uo from "./components/setting/modal/index.vue2.mjs";
21
+ import io from "../scroll-bar/index.vue.mjs";
22
+ import co from "./components/paragraph-ellipsis/index.vue2.mjs";
23
+ const Eo = /* @__PURE__ */ Ee({
24
24
  name: "ApTable",
25
25
  __name: "ap-table",
26
26
  props: {
@@ -144,187 +144,200 @@ const No = /* @__PURE__ */ Ne({
144
144
  default: void 0
145
145
  }
146
146
  },
147
- setup(se, {
148
- expose: de
147
+ setup(de, {
148
+ expose: ue
149
149
  }) {
150
- const o = se;
150
+ const o = de;
151
151
  let O = 0;
152
- const C = Ie(), [, ue] = $e(), {
153
- e: B,
152
+ const C = Oe(), [, ie] = We(), {
153
+ e: z,
154
154
  b: c,
155
155
  be: V,
156
- m: ie,
157
- cssVar: ce
158
- } = ao("ap-table"), L = to("valueTypeMap"), {
156
+ m: ce,
157
+ cssVar: fe
158
+ } = no("ap-table"), L = so("valueTypeMap"), {
159
159
  height: pe,
160
- contentRef: fe
161
- } = Xe(), $ = h(), A = h(), {
160
+ contentRef: me
161
+ } = eo(), $ = h(), A = h(), {
162
162
  isStickyMode: D,
163
163
  scrollBarRef: i
164
- } = ro($), z = h(o.size), u = h([]), W = h([]), j = Ze();
165
- oo({
164
+ } = lo($), P = h(o.size), u = h([]), W = h([]), j = ro();
165
+ to({
166
166
  columns: s(() => u.value),
167
167
  columnsBackup: s(() => W.value),
168
- size: s(() => z.value),
168
+ size: s(() => P.value),
169
169
  updateColumns(e) {
170
170
  u.value = e;
171
171
  },
172
172
  updateSize(e) {
173
- z.value = e;
173
+ P.value = e;
174
174
  },
175
- dataSource: s(() => t(g).records)
175
+ dataSource: s(() => l(b).records)
176
176
  });
177
177
  const _ = s(() => {
178
178
  var e, a, r;
179
- return O++, ((r = (a = (e = o.columns) == null ? void 0 : e.filter((l) => !l.hideInSearch && l.dataIndex && (l.valueType || l.customRenderFormItem) && !ae.includes(l.valueType))) == null ? void 0 : a.sort((l, d) => {
180
- let n = le(l.order);
181
- return le(d.order) - n;
182
- })) == null ? void 0 : r.map((l) => {
183
- const d = je(l, _e(l.fieldProps, {})), n = {
184
- ...l,
179
+ return O++, ((r = (a = (e = o.columns) == null ? void 0 : e.filter((t) => !t.hideInSearch && t.dataIndex && (t.valueType || t.customRenderFormItem) && !te.includes(t.valueType))) == null ? void 0 : a.sort((t, d) => {
180
+ let n = ne(t.order);
181
+ return ne(d.order) - n;
182
+ })) == null ? void 0 : r.map((t) => {
183
+ const d = Ue(t, qe(t.fieldProps, {})), n = {
184
+ ...t,
185
185
  fieldProps: {
186
- label: l.title,
187
- name: l.dataIndex,
186
+ label: t.title,
187
+ name: t.dataIndex,
188
188
  ...d || {},
189
189
  _signal: O
190
190
  },
191
191
  renderNode: void 0
192
192
  };
193
- return n.renderNode = He(n, t(L)), n;
193
+ return n.renderNode = Me(n, l(L)), n;
194
194
  })) || [];
195
- }), me = s(() => ne(t(u), (e) => {
195
+ }), ye = s(() => se(l(u), (e) => {
196
196
  if (e.sorter === !0)
197
- return e.key || e.dataIndex;
198
- }).filter(Boolean)), ye = s(() => ne(t(u), (e) => {
197
+ return e.key || (e == null ? void 0 : e.dataIndex);
198
+ }).filter(Boolean)), ge = s(() => se(l(u), (e) => {
199
199
  if (e.filters && !e.onFilter)
200
- return e.key || e.dataIndex;
201
- }).filter(Boolean)), be = s(() => b(o.dataSource) ? g.records : o.dataSource), {
200
+ return e.key || (e == null ? void 0 : e.dataIndex);
201
+ }).filter(Boolean)), be = s(() => g(o.dataSource) ? b.records : o.dataSource), {
202
202
  rowSelection: T,
203
203
  selectedRows: F,
204
204
  ...x
205
- } = Ye({
205
+ } = oo({
206
206
  fixed: !0,
207
207
  ...o.rowSelection === !0 ? {} : o.rowSelection,
208
208
  rowKey: o.rowKey,
209
209
  dataSource: be
210
210
  }), {
211
- formRef: P,
211
+ formRef: I,
212
212
  submit: H,
213
213
  reset: U,
214
214
  tableProps: q,
215
- refresh: ge,
216
- data: g,
217
- setDataSource: Se,
218
- getColumnSFConfig: he
219
- } = De({
215
+ refresh: Se,
216
+ data: b,
217
+ setDataSource: he,
218
+ getColumnSFConfig: M,
219
+ sortedInfo: we,
220
+ filteredInfo: ve
221
+ } = _e({
220
222
  async request(e) {
221
- var r, l;
222
- if (!T.value.preserveSelectedRowKeys && b(o.dataSource) && x.clearAll(), !b(o.dataSource))
223
+ var r, t;
224
+ if (!T.value.preserveSelectedRowKeys && g(o.dataSource) && x.clearAll(), !g(o.dataSource))
223
225
  return {
224
226
  data: o.dataSource || [],
225
227
  total: o.dataSource.length || 0
226
228
  };
227
229
  const a = await ((r = o.request) == null ? void 0 : r.call(o, e));
228
- return (l = o.onLoad) == null || l.call(o, (a == null ? void 0 : a.data) || []), {
230
+ return (t = o.onLoad) == null || t.call(o, (a == null ? void 0 : a.data) || []), {
229
231
  data: (a == null ? void 0 : a.data) || [],
230
232
  total: (a == null ? void 0 : a.total) || 0
231
233
  };
232
234
  },
233
- filterFields: ye,
234
- sortFields: me,
235
+ filterFields: ge,
236
+ sortFields: ye,
235
237
  defaultParams: o.params,
236
238
  defaultData: o.defaultData,
237
239
  manual: o.manual,
238
240
  formatParams: o.beforeSearchSubmit,
239
241
  pagination: o.pagination
240
- }), we = () => {
242
+ }), Re = () => {
241
243
  var r;
242
- let e = ((r = o.columns) == null ? void 0 : r.filter((l) => !l.hideInTable)) || [];
243
- function a(l, d) {
244
- return l.map((n) => ({
245
- resizable: eo(n.resizable) ? n.resizable : o.columnResizable,
246
- ...te(Ue(n), ["ellipsis"]),
244
+ let e = ((r = o.columns) == null ? void 0 : r.filter((t) => !t.hideInTable)) || [];
245
+ function a(t, d) {
246
+ return t.map((n) => ({
247
+ resizable: ao(n.resizable) ? n.resizable : o.columnResizable,
248
+ ...le(Ze(n), ["ellipsis"]),
247
249
  // tips: 此函数内部依赖查询&筛选的相应式值
248
- ...he(n),
250
+ ...M(n),
249
251
  fixed: d ? d.fixed : n.fixed,
250
- title: qe(n, V("table-header", "title"), C.headerCell, t(ue).colorPrimary),
252
+ title: Je(n, V("table-header", "title"), C.headerCell, l(ie).colorPrimary),
251
253
  customRender({
252
- value: p,
254
+ value: f,
253
255
  ...S
254
256
  }) {
255
- var Q, X;
256
- const G = Me(n), Be = Ge({
257
+ var X, Y;
258
+ const J = Qe(n), Ie = Xe({
257
259
  ...n,
258
- valueType: G
260
+ valueType: J
259
261
  }, {
260
- value: p,
262
+ value: f,
261
263
  ...S
262
- }), ze = Je(G, Be, S.record, t(L)), J = ((Q = n.renderText) == null ? void 0 : Q.call(n, {
263
- value: p,
264
+ }), Ne = Ye(J, Ie, S.record, l(L)), Q = ((X = n.renderText) == null ? void 0 : X.call(n, {
265
+ value: f,
264
266
  ...S
265
- })) || p, Pe = n.renderText ? f(Y, null, [(X = n.renderText) == null ? void 0 : X.call(n, {
266
- value: p,
267
+ })) || f, Ke = n.renderText ? y(oe, null, [(Y = n.renderText) == null ? void 0 : Y.call(n, {
268
+ value: f,
267
269
  ...S
268
- })]) : ze;
269
- let N = Te(n, J, Pe);
270
+ })]) : Ne;
271
+ let N = ke(n, Q, Ke);
270
272
  return n.customRender && (N = n.customRender({
271
- value: p,
273
+ value: f,
272
274
  ...S,
273
275
  column: n,
274
276
  originalNode: N,
275
- originalText: J
277
+ originalText: Q
276
278
  })), N;
277
279
  },
278
280
  children: a(n.children || [], d || n)
279
281
  }));
280
282
  }
281
283
  return a(e);
284
+ }, Ce = () => {
285
+ function e(a) {
286
+ var r;
287
+ for (const t of a)
288
+ (r = t.children) != null && r.length ? e(t.children) : M(t, !0);
289
+ }
290
+ e(u.value);
282
291
  };
283
- I(() => [o.columnResizable, o.columns], () => {
284
- const e = we();
292
+ k(() => [o.columns, o.columnResizable], () => {
293
+ const e = Re();
285
294
  u.value = e, W.value = e;
286
295
  }, {
287
296
  deep: !0,
288
297
  immediate: !0
298
+ }), k(() => [we.value, ve.value], () => {
299
+ Ce();
300
+ }, {
301
+ deep: !0
289
302
  });
290
- const ve = s(() => {
303
+ const Te = s(() => {
291
304
  var a, r;
292
- if (o.adaptive && (g.total > 0 || ((a = o.dataSource) == null ? void 0 : a.length)))
305
+ if (o.adaptive && (b.total > 0 || ((a = o.dataSource) == null ? void 0 : a.length)))
293
306
  return {
294
- y: t(pe),
307
+ y: l(pe),
295
308
  x: ((r = o.scroll) == null ? void 0 : r.x) || "100%"
296
309
  };
297
310
  if (o.scroll)
298
311
  return o.scroll;
299
- }), Re = s(() => {
312
+ }), Fe = s(() => {
300
313
  var e;
301
314
  if (o.tableLayout)
302
315
  return o.tableLayout;
303
316
  if ((e = o.columns) != null && e.some((a) => a.ellipsis))
304
317
  return "fixed";
305
- }), M = s(() => {
318
+ }), G = s(() => {
306
319
  var r;
307
- const e = t(q), a = t(T);
320
+ const e = l(q), a = l(T);
308
321
  return {
309
322
  ...o,
310
323
  ...e,
311
324
  rowSelection: o.rowSelection === !0 || ((r = o.rowSelection) == null ? void 0 : r.mode) === "internal" ? {
312
325
  ...a,
313
326
  // tips 如果是前端分页,则默认会走缓存
314
- preserveSelectedRowKeys: b(o.dataSource) ? a.preserveSelectedRowKeys : !0
315
- } : Qe(o.rowSelection),
316
- loading: b(o.loading) ? e.loading : o.loading,
327
+ preserveSelectedRowKeys: g(o.dataSource) ? a.preserveSelectedRowKeys : !0
328
+ } : Ge(o.rowSelection),
329
+ loading: g(o.loading) ? e.loading : o.loading,
317
330
  pagination: o.pagination === !1 ? !1 : e.pagination,
318
- scroll: t(ve)
331
+ scroll: l(Te)
319
332
  };
320
- }), Ce = s(() => {
333
+ }), xe = s(() => {
321
334
  var e;
322
- return [c(), o.card ? null : c("wrapper"), o.adaptive ? c("adaptive") : null, D.value && ((e = i.value) != null && e.visible) ? ie(`sticky-${j === 0 ? "absolute" : "relative"}`) : null].filter(Boolean);
335
+ return [c(), o.card ? null : c("wrapper"), o.adaptive ? c("adaptive") : null, D.value && ((e = i.value) != null && e.visible) ? ce(`sticky-${j === 0 ? "absolute" : "relative"}`) : null].filter(Boolean);
323
336
  });
324
- function Te(e, a, r) {
325
- return ae.includes(e.valueType) ? r : e.copyable || e.ellipsis ? f(lo, {
337
+ function ke(e, a, r) {
338
+ return te.includes(e.valueType) ? r : e.copyable || e.ellipsis ? y(co, {
326
339
  copyable: e.copyable,
327
- ellipsis: e.ellipsis ? We(e.ellipsis) ? {
340
+ ellipsis: e.ellipsis ? He(e.ellipsis) ? {
328
341
  tooltip: r,
329
342
  rows: 1
330
343
  } : {
@@ -334,36 +347,36 @@ const No = /* @__PURE__ */ Ne({
334
347
  content: r
335
348
  }, null) : r;
336
349
  }
337
- I(() => t(g).loading, (e) => {
350
+ k(() => l(b).loading, (e) => {
338
351
  var a;
339
352
  (a = o.onLoadingChange) == null || a.call(o, e);
340
- }), I(() => o.dataSource, (e) => {
341
- Se(e);
353
+ }), k(() => o.dataSource, (e) => {
354
+ he(e);
342
355
  }, {
343
356
  immediate: !0
344
357
  });
345
- function Fe(e) {
346
- var a, r, l;
347
- (l = (r = (a = P.value) == null ? void 0 : a.apForm) == null ? void 0 : r.setFieldsValue) == null || l.call(r, e);
358
+ function Be(e) {
359
+ var a, r, t;
360
+ (t = (r = (a = I.value) == null ? void 0 : a.apForm) == null ? void 0 : r.setFieldsValue) == null || t.call(r, e);
348
361
  }
349
- function xe(e = !1) {
350
- var r, l, d;
362
+ function ze(e = !1) {
363
+ var r, t, d;
351
364
  const a = e ? "getFieldsValueTransformed" : "getFieldsValue";
352
- return (d = (l = (r = P.value) == null ? void 0 : r.apForm) == null ? void 0 : l[a]) == null ? void 0 : d.call(l, !0);
365
+ return (d = (t = (r = I.value) == null ? void 0 : r.apForm) == null ? void 0 : t[a]) == null ? void 0 : d.call(t, !0);
353
366
  }
354
- function ke() {
355
- return t(u);
367
+ function Pe() {
368
+ return l(u);
356
369
  }
357
- return de({
370
+ return ue({
358
371
  submit: () => H(),
359
372
  reset: () => U(),
360
- refresh: () => ge(),
361
- setSearchFormValues: Fe,
362
- getSearchFormValues: xe,
363
- getShownColumns: ke,
364
- dataSource: s(() => t(g).records),
373
+ refresh: () => Se(),
374
+ setSearchFormValues: Be,
375
+ getSearchFormValues: ze,
376
+ getShownColumns: Pe,
377
+ dataSource: s(() => l(b).records),
365
378
  rowSelection: {
366
- selectedRows: s(() => t(F)),
379
+ selectedRows: s(() => l(F)),
367
380
  ...x
368
381
  },
369
382
  scrollBar: {
@@ -379,26 +392,26 @@ const No = /* @__PURE__ */ Ne({
379
392
  },
380
393
  y: void 0
381
394
  }
382
- }), (e, a) => (m(), k("div", {
395
+ }), (e, a) => (p(), B("div", {
383
396
  ref_key: "tableWrapperRef",
384
397
  ref: $,
385
- class: y(Ce.value),
386
- style: K(t(ce)({
387
- "scroll-bar-width": `${t(j)}px`
398
+ class: m(xe.value),
399
+ style: K(l(fe)({
400
+ "scroll-bar-width": `${l(j)}px`
388
401
  }))
389
- }, [t(b)(e.dataSource) && e.searchForm !== !1 && _.value.length > 0 ? (m(), k("div", {
402
+ }, [l(g)(e.dataSource) && e.searchForm !== !1 && _.value.length > 0 ? (p(), B("div", {
390
403
  key: 0,
391
- class: y(e.card ? t(B)("search-wrapper") : null),
404
+ class: m(e.card ? l(z)("search-wrapper") : null),
392
405
  style: K(e.searchFormWrapperStyle)
393
- }, [f(t(Ae).SearchForm, w(e.searchForm || {}, {
406
+ }, [y(l(je).SearchForm, w(e.searchForm || {}, {
394
407
  ref_key: "formRef",
395
- ref: P,
408
+ ref: I,
396
409
  "custom-reset": "",
397
- "submit-loading": t(q).loading,
398
- onSubmit: t(H),
399
- onReset: t(U)
400
- }), Z({
401
- default: v(() => [(m(!0), k(Y, null, ee(_.value, (r) => (m(), oe(Ke(r.renderNode.Comp), w({
410
+ "submit-loading": l(q).loading,
411
+ onSubmit: l(H),
412
+ onReset: l(U)
413
+ }), ee({
414
+ default: v(() => [(p(!0), B(oe, null, re(_.value, (r) => (p(), ae(Ve(r.renderNode.Comp), w({
402
415
  key: r.dataIndex,
403
416
  item: r,
404
417
  ref_for: !0
@@ -411,66 +424,66 @@ const No = /* @__PURE__ */ Ne({
411
424
  name: "extra",
412
425
  fn: v(() => [R(e.$slots, "searchFormExtra")]),
413
426
  key: "0"
414
- } : void 0]), 1040, ["submit-loading", "onSubmit", "onReset"])], 6)) : re("", !0), E("div", {
427
+ } : void 0]), 1040, ["submit-loading", "onSubmit", "onReset"])], 6)) : Z("", !0), E("div", {
415
428
  ref_key: "contentRef",
416
- ref: fe,
417
- class: y([t(B)("table-wrapper"), e.card ? t(B)("table-wrapper-card") : null]),
429
+ ref: me,
430
+ class: m([l(z)("table-wrapper"), e.card ? l(z)("table-wrapper-card") : null]),
418
431
  style: K(e.tableWrapperStyle)
419
432
  }, [E("div", {
420
- class: y(t(c)("header-wrapper"))
421
- }, [e.settings ? (m(), k("div", {
433
+ class: m(l(c)("header-wrapper"))
434
+ }, [e.settings ? (p(), B("div", {
422
435
  key: 0,
423
- class: y(t(c)("header"))
436
+ class: m(l(c)("header"))
424
437
  }, [E("div", {
425
- class: y(t(V)("header", "title"))
438
+ class: m(l(V)("header", "title"))
426
439
  }, [R(e.$slots, "title", w({
427
- selectedRows: t(F),
428
- selectedRowKeys: t(T).selectedRowKeys,
440
+ selectedRows: l(F),
441
+ selectedRowKeys: l(T).selectedRowKeys,
429
442
  shownColumns: u.value
430
- }, x))], 2), C.title ? (m(), oe(t(Ve), {
443
+ }, x))], 2), C.title ? (p(), ae(l(Ae), {
431
444
  key: 0,
432
445
  type: "vertical"
433
- })) : re("", !0), f(no, {
446
+ })) : Z("", !0), y(uo, {
434
447
  config: e.settings === !0 ? {} : e.settings
435
448
  }, null, 8, ["config"])], 2)) : R(e.$slots, "title", w({
436
449
  key: 1,
437
- selectedRows: t(F),
438
- selectedRowKeys: t(T).selectedRowKeys,
450
+ selectedRows: l(F),
451
+ selectedRowKeys: l(T).selectedRowKeys,
439
452
  shownColumns: u.value
440
- }, x))], 2), f(t(Le), w({
453
+ }, x))], 2), y(l(De), w({
441
454
  ref_key: "antdTableRef",
442
455
  ref: A,
443
- class: t(c)("table")
444
- }, M.value, {
445
- size: z.value,
446
- "table-layout": Re.value,
456
+ class: l(c)("table")
457
+ }, G.value, {
458
+ size: P.value,
459
+ "table-layout": Fe.value,
447
460
  columns: u.value,
448
- onResizeColumn: a[0] || (a[0] = (r, l) => l.width = r)
449
- }), Z({
461
+ onResizeColumn: a[0] || (a[0] = (r, t) => t.width = r)
462
+ }), ee({
450
463
  summary: v(() => [R(e.$slots, "summary", {
451
464
  columns: u.value,
452
- records: M.value.dataSource,
453
- selectedRows: t(F)
465
+ records: G.value.dataSource,
466
+ selectedRows: l(F)
454
467
  })]),
455
468
  _: 2
456
- }, [t(D) ? {
469
+ }, [l(D) ? {
457
470
  name: "bottomPaginationTop",
458
471
  fn: v(() => {
459
- var r, l;
460
- return [f(t(so), {
472
+ var r, t;
473
+ return [y(l(io), {
461
474
  ref_key: "scrollBarRef",
462
475
  ref: i,
463
- "scroll-container": (l = (r = A.value) == null ? void 0 : r.table) == null ? void 0 : l.scrollBodyRef,
476
+ "scroll-container": (t = (r = A.value) == null ? void 0 : r.table) == null ? void 0 : t.scrollBodyRef,
464
477
  direction: "horizontal"
465
478
  }, null, 8, ["scroll-container"])];
466
479
  }),
467
480
  key: "0"
468
- } : void 0, ee(t(te)(C, ["title", "searchFormExtra", "headerCell", "summary"]), (r, l) => ({
469
- name: l,
470
- fn: v((d) => [R(e.$slots, l, Ee(Oe(d || {})))])
481
+ } : void 0, re(l(le)(C, ["title", "searchFormExtra", "headerCell", "summary"]), (r, t) => ({
482
+ name: t,
483
+ fn: v((d) => [R(e.$slots, t, Le($e(d || {})))])
471
484
  }))]), 1040, ["class", "size", "table-layout", "columns"])], 6)], 6));
472
485
  }
473
486
  });
474
487
  export {
475
- No as default
488
+ Eo as default
476
489
  };
@@ -1,4 +1,4 @@
1
- import { defineComponent as n, openBlock as o, createBlock as t, resolveDynamicComponent as r } from "vue";
1
+ import { defineComponent as n, createBlock as o, openBlock as t, resolveDynamicComponent as r } from "vue";
2
2
  const s = /* @__PURE__ */ n({
3
3
  name: "ApTableDynamicComponent",
4
4
  inheritAttrs: !1,
@@ -7,7 +7,7 @@ const s = /* @__PURE__ */ n({
7
7
  customRender: { type: Function }
8
8
  },
9
9
  setup(p) {
10
- return (e, a) => (o(), t(r(e.customRender(e.$attrs))));
10
+ return (e, a) => (t(), o(r(e.customRender(e.$attrs))));
11
11
  }
12
12
  });
13
13
  export {
@@ -1,4 +1,4 @@
1
- import { defineComponent as n, computed as l, openBlock as s, createElementBlock as p, normalizeClass as d, toDisplayString as m } from "vue";
1
+ import { defineComponent as n, computed as l, createElementBlock as s, openBlock as p, normalizeClass as d, toDisplayString as m } from "vue";
2
2
  import "../../../config-provider/index.mjs";
3
3
  import { useNamespace as c } from "../../../config-provider/hooks/use-namespace.mjs";
4
4
  const _ = /* @__PURE__ */ n({
@@ -10,7 +10,7 @@ const _ = /* @__PURE__ */ n({
10
10
  },
11
11
  setup(e) {
12
12
  const o = e, { m: a } = c("ap-table-index"), r = l(() => [o.bordered ? a("bordered") : null].filter(Boolean));
13
- return (t, i) => (s(), p("div", {
13
+ return (t, i) => (p(), s("div", {
14
14
  class: d(r.value)
15
15
  }, m(t.value), 3));
16
16
  }
@@ -1,4 +1,4 @@
1
- import { defineComponent as x, ref as _, computed as B, openBlock as i, createElementBlock as f, mergeProps as E, unref as l, createElementVNode as O, normalizeClass as y, createVNode as v, createSlots as N, withCtx as m, createBlock as c, resolveDynamicComponent as b, h, createCommentVNode as j } from "vue";
1
+ import { defineComponent as x, ref as _, computed as B, createElementBlock as f, openBlock as i, mergeProps as E, unref as l, createElementVNode as O, createCommentVNode as N, normalizeClass as y, createVNode as v, createSlots as j, withCtx as m, createBlock as c, resolveDynamicComponent as b, h } from "vue";
2
2
  import "../../../config-provider/index.mjs";
3
3
  import { Tooltip as w } from "@aplus-frontend/antdv";
4
4
  import { CopyOutlined as S, CheckOutlined as V } from "@ant-design/icons-vue";
@@ -65,7 +65,7 @@ const G = /* @__PURE__ */ x({
65
65
  O("div", {
66
66
  class: y([l(u)("content")])
67
67
  }, [
68
- v(l(w), null, N({
68
+ v(l(w), null, j({
69
69
  default: m(() => {
70
70
  var s;
71
71
  return [
@@ -98,7 +98,7 @@ const G = /* @__PURE__ */ x({
98
98
  ]),
99
99
  _: 1
100
100
  }, 8, ["title"])
101
- ], 2)) : j("", !0)
101
+ ], 2)) : N("", !0)
102
102
  ], 16);
103
103
  };
104
104
  }
@@ -1,4 +1,4 @@
1
- import { defineComponent as G, ref as y, unref as e, computed as H, useSlots as L, createVNode as l, cloneVNode as M, openBlock as x, createElementBlock as P, Fragment as q, createBlock as J, resolveDynamicComponent as Q, createCommentVNode as W, withCtx as i, createElementVNode as s, normalizeClass as r, toDisplayString as c, createTextVNode as C, isRef as X } from "vue";
1
+ import { defineComponent as G, ref as y, unref as e, computed as H, useSlots as L, createVNode as l, cloneVNode as M, createElementBlock as P, openBlock as x, Fragment as q, createBlock as J, createCommentVNode as Q, resolveDynamicComponent as W, withCtx as i, createElementVNode as s, normalizeClass as r, toDisplayString as c, createTextVNode as C, isRef as X } from "vue";
2
2
  import { Button as B, Modal as Y, RadioGroup as Z, RadioButton as _, Divider as h } from "@aplus-frontend/antdv";
3
3
  import { getSingleVNode as ee } from "../../../../utils/slot.mjs";
4
4
  import { useInjectApTable as te } from "../../../context.mjs";
@@ -62,9 +62,9 @@ const re = {
62
62
  const p = N(n.value);
63
63
  E(p), I(p), (o = (t = m.config) == null ? void 0 : t.onChange) == null || o.call(t, p);
64
64
  }
65
- return (p, t) => (x(), P(q, null, [e(k) ? (x(), J(Q(e(k)), {
65
+ return (p, t) => (x(), P(q, null, [e(k) ? (x(), J(W(e(k)), {
66
66
  key: 0
67
- })) : W("", !0), l(e(Y), {
67
+ })) : Q("", !0), l(e(Y), {
68
68
  open: u.value,
69
69
  "onUpdate:open": t[2] || (t[2] = (o) => u.value = o),
70
70
  title: e(a)("ap.apTable.setting.title"),
@@ -1,4 +1,4 @@
1
- import { defineComponent as P, ref as U, computed as p, unref as l, watch as x, openBlock as s, createElementBlock as v, createElementVNode as k, normalizeClass as D, createVNode as u, withCtx as i, createBlock as h, resolveDynamicComponent as w, Fragment as L, renderList as j, mergeProps as z } from "vue";
1
+ import { defineComponent as P, ref as U, computed as p, unref as l, watch as x, createElementBlock as v, openBlock as s, createElementVNode as k, normalizeClass as D, createVNode as u, withCtx as i, createBlock as h, resolveDynamicComponent as w, Fragment as L, renderList as j, mergeProps as z } from "vue";
2
2
  import { Checkbox as b, Row as F, Col as I } from "@aplus-frontend/antdv";
3
3
  import "../../../../config-provider/index.mjs";
4
4
  import { useInjectApTable as R } from "../../../context.mjs";
@@ -1,4 +1,4 @@
1
- import { defineComponent as f, ref as c, openBlock as n, createElementBlock as u, normalizeClass as m, unref as r, createVNode as i, withCtx as k, createBlock as y, createCommentVNode as p } from "vue";
1
+ import { defineComponent as f, ref as c, createElementBlock as u, openBlock as n, normalizeClass as m, unref as r, createVNode as i, createCommentVNode as p, withCtx as k, createBlock as y } from "vue";
2
2
  import "./item.vue.mjs";
3
3
  import "../../../../config-provider/index.mjs";
4
4
  import V from "vuedraggable";
@@ -1,4 +1,4 @@
1
- import { defineComponent as E, openBlock as s, createElementBlock as g, normalizeClass as t, unref as e, createElementVNode as p, createVNode as c, createCommentVNode as r, createBlock as u, resolveDynamicComponent as I, withCtx as d } from "vue";
1
+ import { defineComponent as E, createElementBlock as g, openBlock as s, normalizeClass as t, unref as e, createElementVNode as p, createVNode as c, createCommentVNode as r, createBlock as u, resolveDynamicComponent as I, withCtx as d } from "vue";
2
2
  import { Space as O, Tooltip as m } from "@aplus-frontend/antdv";
3
3
  import { HolderOutlined as D, VerticalAlignTopOutlined as k, VerticalAlignMiddleOutlined as z, DeleteOutlined as A } from "@ant-design/icons-vue";
4
4
  import "../../../../config-provider/index.mjs";