@aplus-frontend/ui 0.6.0-beta.0 → 0.6.0-beta.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 (209) hide show
  1. package/es/src/ap-button/ap-button.vue.mjs +1 -1
  2. package/es/src/ap-form/ap-form.vue2.mjs +57 -58
  3. package/es/src/ap-form/interface.d.ts +4 -0
  4. package/es/src/ap-form/item/index.vue.mjs +33 -28
  5. package/es/src/ap-form/items/checkbox/index.vue.mjs +1 -0
  6. package/es/src/ap-form/items/date/index.vue.mjs +8 -7
  7. package/es/src/ap-form/items/date-range/index.vue.mjs +1 -0
  8. package/es/src/ap-form/items/number/index.vue.mjs +9 -8
  9. package/es/src/ap-form/items/radio/index.vue.mjs +1 -0
  10. package/es/src/ap-form/items/select/index.vue.mjs +7 -6
  11. package/es/src/ap-form/items/switch/index.vue.mjs +1 -0
  12. package/es/src/ap-form/items/text/index.vue2.mjs +8 -7
  13. package/es/src/ap-form/items/text/password.vue.mjs +1 -0
  14. package/es/src/ap-form/items/text-area/index.vue.mjs +1 -0
  15. package/es/src/ap-form/items/tree-select/index.vue.mjs +6 -5
  16. package/es/src/ap-form/render/item.vue.mjs +5 -4
  17. package/es/src/ap-form/search-form/components/popover-filter.vue2.mjs +10 -10
  18. package/es/src/ap-form/search-form/components/popover-sorter/sortable-item.vue2.mjs +8 -8
  19. package/es/src/ap-form/search-form/index.vue.mjs +36 -35
  20. package/es/src/ap-grid/editable/form-item.vue.mjs +1 -1
  21. package/es/src/ap-grid/editable/index.vue.mjs +1 -1
  22. package/es/src/ap-grid/index.vue.mjs +149 -140
  23. package/es/src/ap-grid/interface.d.ts +1 -1
  24. package/es/src/ap-table/ap-table.vue2.mjs +206 -199
  25. package/es/src/ap-tag/ap-tag.vue.d.ts +1 -0
  26. package/es/src/ap-tag/ap-tag.vue.mjs +18 -12
  27. package/es/src/ap-tag/interface.d.ts +4 -0
  28. package/es/src/business/ap-expand-alert/ApExpandAlert.vue2.mjs +11 -12
  29. package/es/src/business/ap-export-group/ApExportGroup.vue.d.ts +1 -0
  30. package/es/src/business/ap-export-group/ApExportGroup.vue2.mjs +108 -99
  31. package/es/src/business/ap-export-group/index.d.ts +3 -0
  32. package/es/src/business/ap-export-group/interface.d.ts +7 -2
  33. package/es/src/business/ap-table-modal/modal-title.vue2.mjs +2 -2
  34. package/es/src/business/ap-view/ap-view.vue2.mjs +120 -114
  35. package/es/src/business/ap-view/components/main-button-content.vue2.mjs +63 -55
  36. package/es/src/business/ap-view/components/menu-list-content.vue2.mjs +38 -38
  37. package/es/src/business/ap-view/interface.d.ts +4 -0
  38. package/es/src/business/batch-input-group/form-item.vue.mjs +1 -0
  39. package/es/src/business/hooks/usePageListApGrid.mjs +2 -4
  40. package/es/src/check-card/index.vue2.mjs +1 -1
  41. package/es/src/config-provider/css-var.mjs +2 -2
  42. package/es/src/design-token/index.mjs +9 -3
  43. package/es/src/editable-table/form-item.vue.mjs +1 -1
  44. package/es/src/editable-table/index.vue.mjs +27 -27
  45. package/es/src/locale/lang/en.mjs +1 -1
  46. package/es/src/locale/lang/zh-cn.mjs +1 -1
  47. package/lib/src/ap-button/ap-button.vue.js +1 -1
  48. package/lib/src/ap-form/ap-form.vue2.js +1 -1
  49. package/lib/src/ap-form/interface.d.ts +4 -0
  50. package/lib/src/ap-form/item/index.vue.js +1 -1
  51. package/lib/src/ap-form/items/checkbox/index.vue.js +1 -1
  52. package/lib/src/ap-form/items/date/index.vue.js +1 -1
  53. package/lib/src/ap-form/items/date-range/index.vue.js +1 -1
  54. package/lib/src/ap-form/items/number/index.vue.js +1 -1
  55. package/lib/src/ap-form/items/radio/index.vue.js +1 -1
  56. package/lib/src/ap-form/items/select/index.vue.js +1 -1
  57. package/lib/src/ap-form/items/switch/index.vue.js +1 -1
  58. package/lib/src/ap-form/items/text/index.vue2.js +1 -1
  59. package/lib/src/ap-form/items/text/password.vue.js +1 -1
  60. package/lib/src/ap-form/items/text-area/index.vue.js +1 -1
  61. package/lib/src/ap-form/items/tree-select/index.vue.js +1 -1
  62. package/lib/src/ap-form/render/item.vue.js +1 -1
  63. package/lib/src/ap-form/search-form/components/popover-filter.vue2.js +1 -1
  64. package/lib/src/ap-form/search-form/components/popover-sorter/sortable-item.vue2.js +1 -1
  65. package/lib/src/ap-form/search-form/index.vue.js +1 -1
  66. package/lib/src/ap-grid/editable/form-item.vue.js +1 -1
  67. package/lib/src/ap-grid/editable/index.vue.js +1 -1
  68. package/lib/src/ap-grid/index.vue.js +1 -1
  69. package/lib/src/ap-grid/interface.d.ts +1 -1
  70. package/lib/src/ap-table/ap-table.vue2.js +1 -1
  71. package/lib/src/ap-tag/ap-tag.vue.d.ts +1 -0
  72. package/lib/src/ap-tag/ap-tag.vue.js +1 -1
  73. package/lib/src/ap-tag/interface.d.ts +4 -0
  74. package/lib/src/business/ap-expand-alert/ApExpandAlert.vue2.js +1 -1
  75. package/lib/src/business/ap-export-group/ApExportGroup.vue.d.ts +1 -0
  76. package/lib/src/business/ap-export-group/ApExportGroup.vue2.js +1 -1
  77. package/lib/src/business/ap-export-group/index.d.ts +3 -0
  78. package/lib/src/business/ap-export-group/interface.d.ts +7 -2
  79. package/lib/src/business/ap-table-modal/modal-title.vue2.js +1 -1
  80. package/lib/src/business/ap-view/ap-view.vue2.js +1 -1
  81. package/lib/src/business/ap-view/components/main-button-content.vue2.js +1 -1
  82. package/lib/src/business/ap-view/components/menu-list-content.vue2.js +1 -1
  83. package/lib/src/business/ap-view/interface.d.ts +4 -0
  84. package/lib/src/business/batch-input-group/form-item.vue.js +1 -1
  85. package/lib/src/business/hooks/usePageListApGrid.js +1 -1
  86. package/lib/src/check-card/index.vue2.js +1 -1
  87. package/lib/src/config-provider/css-var.js +1 -1
  88. package/lib/src/design-token/index.js +1 -1
  89. package/lib/src/editable-table/form-item.vue.js +1 -1
  90. package/lib/src/editable-table/index.vue.js +1 -1
  91. package/lib/src/locale/lang/en.js +1 -1
  92. package/lib/src/locale/lang/zh-cn.js +1 -1
  93. package/package.json +1 -1
  94. package/theme/antd-global-overwrite/admin/index.css +5 -8
  95. package/theme/antd-global-overwrite/admin/modal.css +2 -5
  96. package/theme/antd-global-overwrite/admin/modal.less +3 -3
  97. package/theme/antd-global-overwrite/admin/table.css +3 -3
  98. package/theme/antd-global-overwrite/admin/table.less +3 -3
  99. package/theme/antd-global-overwrite/aplus/index.css +5 -8
  100. package/theme/antd-global-overwrite/aplus/modal.css +2 -5
  101. package/theme/antd-global-overwrite/aplus/modal.less +3 -3
  102. package/theme/antd-global-overwrite/aplus/table.css +3 -3
  103. package/theme/antd-global-overwrite/aplus/table.less +3 -3
  104. package/theme/ap-action/item-dropdown.css +5 -5
  105. package/theme/ap-action/item-dropdown.less +1 -1
  106. package/theme/ap-action/item.css +5 -5
  107. package/theme/ap-action/item.less +1 -1
  108. package/theme/ap-appendix/ap-appendix.css +7 -5
  109. package/theme/ap-appendix/ap-appendix.less +4 -2
  110. package/theme/ap-attachment/ap-attachment.css +7 -7
  111. package/theme/ap-attachment/ap-attachment.less +4 -4
  112. package/theme/ap-batch-action/ap-batch-action.css +9 -6
  113. package/theme/ap-batch-action/ap-batch-action.less +6 -3
  114. package/theme/ap-button/ap-button.css +3 -3
  115. package/theme/ap-card/ap-card.css +3 -3
  116. package/theme/ap-descriptions/ap-descriptions.css +6 -8
  117. package/theme/ap-descriptions/ap-descriptions.less +3 -5
  118. package/theme/ap-download/ap-download.css +10 -13
  119. package/theme/ap-download/ap-download.less +8 -11
  120. package/theme/ap-expand-alert/ap-expand-alert.css +4 -4
  121. package/theme/ap-expand-alert/ap-expand-alert.less +3 -4
  122. package/theme/ap-field/checkbox.css +4 -4
  123. package/theme/ap-field/checkbox.less +2 -1
  124. package/theme/ap-field/index.css +5 -5
  125. package/theme/ap-field/number.css +3 -3
  126. package/theme/ap-field/radio.css +4 -4
  127. package/theme/ap-field/radio.less +1 -1
  128. package/theme/ap-field/text-area.css +3 -3
  129. package/theme/ap-form/ap-form-item-group.css +3 -3
  130. package/theme/ap-form/ap-form-item.css +10 -8
  131. package/theme/ap-form/ap-form-item.less +8 -6
  132. package/theme/ap-form/drawer-form.css +3 -3
  133. package/theme/ap-form/index.css +21 -19
  134. package/theme/ap-form/item-text-group.css +3 -3
  135. package/theme/ap-form/item-text.css +3 -3
  136. package/theme/ap-form/modal-form.css +3 -3
  137. package/theme/ap-form/search-form-sorter.css +12 -12
  138. package/theme/ap-form/search-form-sorter.less +7 -7
  139. package/theme/ap-form/search-form.css +21 -19
  140. package/theme/ap-form/search-form.less +5 -5
  141. package/theme/ap-grid/editable.css +5 -5
  142. package/theme/ap-grid/editable.less +3 -2
  143. package/theme/ap-grid/index.css +43 -32
  144. package/theme/ap-grid/index.less +20 -9
  145. package/theme/ap-group-search/ap-extension-select.css +3 -3
  146. package/theme/ap-group-search/ap-group-search.css +3 -3
  147. package/theme/ap-group-search/ap-popover-select.css +3 -3
  148. package/theme/ap-image/ap-image.css +3 -3
  149. package/theme/ap-input-radio/ap-input-radio.css +3 -3
  150. package/theme/ap-label/ap-label.css +3 -3
  151. package/theme/ap-ladder/ap-ladder.css +6 -6
  152. package/theme/ap-ladder/ap-ladder.less +3 -3
  153. package/theme/ap-layout/ap-info-layout.css +3 -3
  154. package/theme/ap-list/index.css +4 -4
  155. package/theme/ap-list/index.less +2 -1
  156. package/theme/ap-product-info/ap-product-info.css +3 -3
  157. package/theme/ap-select-layout/ap-select-layout.css +11 -11
  158. package/theme/ap-select-layout/ap-select-layout.less +8 -8
  159. package/theme/ap-size-input/ap-size-input.css +3 -3
  160. package/theme/ap-status/ap-status.css +5 -6
  161. package/theme/ap-status/ap-status.less +2 -4
  162. package/theme/ap-summary/index.css +6 -6
  163. package/theme/ap-summary/index.less +3 -3
  164. package/theme/ap-table/ap-table-index.css +8 -8
  165. package/theme/ap-table/ap-table-index.less +5 -5
  166. package/theme/ap-table/ap-table-paragraph-ellipsis.css +3 -3
  167. package/theme/ap-table/ap-table-paragraph-ellipsis.less +1 -1
  168. package/theme/ap-table/ap-table.css +46 -42
  169. package/theme/ap-table/ap-table.less +10 -9
  170. package/theme/ap-table/setting/index.css +7 -7
  171. package/theme/ap-table/setting/modal.css +5 -5
  172. package/theme/ap-table/setting/select-group.css +3 -3
  173. package/theme/ap-table/setting/sortable-item-meta.css +3 -3
  174. package/theme/ap-table/setting/sortable-item.css +3 -3
  175. package/theme/ap-table/setting/sorter.css +5 -5
  176. package/theme/ap-table-modal/index.css +46 -42
  177. package/theme/ap-tag/ap-tag-group.css +3 -3
  178. package/theme/ap-tag/ap-tag-group.less +2 -2
  179. package/theme/ap-tag/ap-tag.css +27 -18
  180. package/theme/ap-tag/ap-tag.less +37 -24
  181. package/theme/ap-title/ap-title.css +5 -5
  182. package/theme/ap-title/ap-title.less +2 -2
  183. package/theme/ap-upload/index.css +6 -6
  184. package/theme/ap-upload/multiple-file.css +4 -4
  185. package/theme/ap-upload/multiple-file.less +1 -1
  186. package/theme/ap-upload/picture.css +5 -5
  187. package/theme/ap-upload/picture.less +2 -2
  188. package/theme/ap-upload/single-file.css +3 -3
  189. package/theme/ap-upload/upload.css +3 -3
  190. package/theme/ap-upload-single/index.css +3 -3
  191. package/theme/ap-view/ap-view.css +7 -3
  192. package/theme/ap-view/ap-view.less +4 -0
  193. package/theme/batch-input-group/index.css +5 -5
  194. package/theme/batch-input-group/popover-input.css +3 -3
  195. package/theme/check-card/index.css +22 -22
  196. package/theme/check-card/index.less +17 -15
  197. package/theme/editable-table/index.css +36 -32
  198. package/theme/editable-table/index.less +9 -7
  199. package/theme/full-screen/index.css +3 -3
  200. package/theme/index.css +174 -147
  201. package/theme/mask/index.css +3 -3
  202. package/theme/mixins/config.less +26 -4
  203. package/theme/mixins/mixins.css +3 -3
  204. package/theme/scroll-bar/index.css +3 -3
  205. package/theme/scroll-view/index.css +3 -3
  206. package/theme/splitter/index.css +8 -8
  207. package/theme/text/group.css +3 -3
  208. package/theme/text/index.css +5 -5
  209. package/theme/work-order-modal/index.css +3 -3
@@ -6,7 +6,7 @@ import { omit as F } from "lodash-unified";
6
6
  import { transferOpacityColor as O, isAsynchronous as j } from "./utils/index.mjs";
7
7
  import { useNamespace as G } from "../config-provider/hooks/use-namespace.mjs";
8
8
  import { useGlobalConfig as R } from "../config-provider/hooks/use-global-config.mjs";
9
- const q = 88, E = 300, Y = /* @__PURE__ */ W({
9
+ const q = 72, E = 300, Y = /* @__PURE__ */ W({
10
10
  __name: "ap-button",
11
11
  props: {
12
12
  prefixCls: {},
@@ -1,13 +1,13 @@
1
- import { defineComponent as Q, reactive as X, ref as j, unref as p, nextTick as Y, toRaw as x, watch as Z, onWatcherCleanup as z, computed as ee, createBlock as te, openBlock as re, mergeProps as le, withCtx as oe, renderSlot as se } from "vue";
2
- import { Form as ie } from "@aplus-frontend/antdv";
3
- import { useProvideForm as ne } from "./context.mjs";
4
- import { isArray as f, cloneDeep as ae, isFunction as _, isPlainObject as B, omit as ue } from "lodash-unified";
1
+ import { defineComponent as Q, reactive as X, ref as E, unref as p, nextTick as Y, toRaw as _, watch as Z, onWatcherCleanup as z, computed as ee, createBlock as te, openBlock as re, mergeProps as le, withCtx as oe, renderSlot as se } from "vue";
2
+ import { Form as ne } from "@aplus-frontend/antdv";
3
+ import { useProvideForm as ie } from "./context.mjs";
4
+ import { isArray as f, cloneDeep as ae, isFunction as B, isPlainObject as M, omit as ue } from "lodash-unified";
5
5
  import { useUrlSearchParams as ce } from "@vueuse/core";
6
6
  import { INTERNAL_FORM_INSTANCE_MARK as fe } from "./constant.mjs";
7
7
  import { getRouteType as de, isDef as V } from "../utils/index.mjs";
8
8
  import ge from "./utils/set.mjs";
9
- import { genParams as M, setToParams as E } from "./utils/params.mjs";
10
- import { useInjectFormProvider as Fe } from "./provider/context.mjs";
9
+ import { genParams as b, setToParams as A } from "./utils/params.mjs";
10
+ import { useInjectFormProvider as he } from "./provider/context.mjs";
11
11
  const Re = /* @__PURE__ */ Q({
12
12
  __name: "ap-form",
13
13
  props: {
@@ -38,11 +38,11 @@ const Re = /* @__PURE__ */ Q({
38
38
  syncToUrl: { type: [Boolean, Function], default: !1 },
39
39
  syncToUrlPriority: { type: Boolean }
40
40
  },
41
- setup(A, { expose: C }) {
42
- function N(e, t) {
41
+ setup(C, { expose: N }) {
42
+ function S(e, t) {
43
43
  return f(t) ? t.reduce((r, o) => r == null ? void 0 : r[o], e) : e == null ? void 0 : e[t];
44
44
  }
45
- const l = A;
45
+ const l = C;
46
46
  function v(e, t, r = !0, o) {
47
47
  var s;
48
48
  if (f(e)) {
@@ -59,13 +59,13 @@ const Re = /* @__PURE__ */ Q({
59
59
  }
60
60
  T();
61
61
  }
62
- const u = j(), I = ce(de()), y = Fe(), P = j(
63
- l.syncToUrl ? M(l.syncToUrl, I, "get") : {}
62
+ const u = E(), I = ce(de()), y = he(), P = E(
63
+ l.syncToUrl ? b(l.syncToUrl, I, "get") : {}
64
64
  );
65
- let m = ae(b()), g = {};
66
- const n = X(b());
67
- let F = [];
68
- function b() {
65
+ let m = ae(w()), g = {};
66
+ const n = X(w());
67
+ let h = [];
68
+ function w() {
69
69
  const e = l.initialValues || {};
70
70
  return l.syncToUrlPriority ? {
71
71
  ...e,
@@ -75,43 +75,42 @@ const Re = /* @__PURE__ */ Q({
75
75
  ...e
76
76
  };
77
77
  }
78
- function S(e) {
78
+ function W(e) {
79
79
  var r;
80
- const t = h(e, g);
81
- y.triggerFormFinish(l.name, e), l.syncToUrl && E(I, M(l.syncToUrl, t, "set")), (r = l.onFinish) == null || r.call(l, t);
80
+ const t = F(e, g);
81
+ y.triggerFormFinish(l.name, e), l.syncToUrl && A(I, b(l.syncToUrl, t, "set")), (r = l.onFinish) == null || r.call(l, t);
82
82
  }
83
- const W = async () => {
83
+ const q = async () => {
84
84
  var e;
85
85
  (e = u.value) == null || e.resetFields(), await Y(() => {
86
- Object.keys(n).forEach((t) => delete n[t]), Object.assign(n, m), T(), l.syncToUrl && E(
86
+ Object.keys(n).forEach((t) => delete n[t]), Object.assign(n, m), T(), l.syncToUrl && A(
87
87
  I,
88
- M(
88
+ b(
89
89
  l.syncToUrl,
90
- h(m, g),
90
+ F(m, g),
91
91
  "set"
92
92
  )
93
93
  );
94
94
  });
95
- }, q = (e) => {
95
+ }, D = (e) => {
96
96
  var t;
97
97
  (t = u.value) == null || t.clearValidate(e);
98
- }, D = (e, t) => {
98
+ }, k = (e, t) => {
99
99
  var r;
100
100
  return (r = u.value) == null ? void 0 : r.validateFields(e, t);
101
- }, L = async (e, t) => {
101
+ }, K = async (e, t) => {
102
102
  var o;
103
103
  const r = await ((o = u.value) == null ? void 0 : o.validateFields(
104
104
  e,
105
105
  t
106
106
  ));
107
- return h(r, g);
108
- }, k = (e) => {
107
+ return F(r, g);
108
+ }, O = (e) => {
109
109
  var t;
110
- return (t = u.value) == null ? void 0 : t.getFieldsValue(e);
111
- }, K = (e) => {
112
- var r;
113
- const t = (r = u.value) == null ? void 0 : r.getFieldsValue(e);
114
- return h(t, g);
110
+ return e === !0 ? _(n) : (t = u.value) == null ? void 0 : t.getFieldsValue(e);
111
+ }, L = (e) => {
112
+ const t = O(e);
113
+ return F(t, g);
115
114
  }, $ = (e, t) => {
116
115
  var r;
117
116
  return (r = u.value) == null ? void 0 : r.validate(e, t);
@@ -124,13 +123,13 @@ const Re = /* @__PURE__ */ Q({
124
123
  v(e, t, r, o), T();
125
124
  };
126
125
  function R(e, t) {
127
- return t || e(x(n)), F.push(e), () => {
128
- F = F.filter((r) => r !== e);
126
+ return t || e(_(n)), h.push(e), () => {
127
+ h = h.filter((r) => r !== e);
129
128
  };
130
129
  }
131
- function w({ initialValue: e, name: t, transform: r }) {
130
+ function j({ initialValue: e, name: t, transform: r }) {
132
131
  if (V(e) && V(t)) {
133
- const o = N(p(P), t);
132
+ const o = S(p(P), t);
134
133
  if (!V(o) || !l.syncToUrlPriority)
135
134
  if (v(t, e, !1), f(t)) {
136
135
  let i = m;
@@ -153,33 +152,33 @@ const Re = /* @__PURE__ */ Q({
153
152
  return;
154
153
  }
155
154
  return {
156
- registerField: w,
155
+ registerField: j,
157
156
  registerWatch: R,
158
157
  setFieldValue: U
159
158
  };
160
159
  }
161
160
  function T() {
162
- if (F.length) {
163
- const e = x(n);
164
- F.forEach((t) => {
161
+ if (h.length) {
162
+ const e = _(n);
163
+ h.forEach((t) => {
165
164
  t(e);
166
165
  });
167
166
  }
168
167
  }
169
- function h(e, t) {
168
+ function F(e, t) {
170
169
  if (e == null)
171
170
  return;
172
171
  let r = f(e) ? [] : {};
173
172
  return Object.keys(e).forEach((o) => {
174
- const i = e[o], s = t == null ? void 0 : t[o], a = _(s) ? s : s == null ? void 0 : s.transformer, d = _(s) ? !0 : s == null ? void 0 : s.flat;
175
- if (_(a)) {
173
+ const i = e[o], s = t == null ? void 0 : t[o], a = B(s) ? s : s == null ? void 0 : s.transformer, d = B(s) ? !0 : s == null ? void 0 : s.flat;
174
+ if (B(a)) {
176
175
  const c = a(i);
177
- d ? f(c) && f(r) ? r = [...r, ...c] : B(c) && B(r) ? r = {
176
+ d ? f(c) && f(r) ? r = [...r, ...c] : M(c) && M(r) ? r = {
178
177
  ...r,
179
178
  ...c
180
179
  } : r[o] = c : r[o] = c;
181
- } else if (B(i) || f(i)) {
182
- const c = h(
180
+ } else if (M(i) || f(i)) {
181
+ const c = F(
183
182
  i,
184
183
  s
185
184
  );
@@ -188,44 +187,44 @@ const Re = /* @__PURE__ */ Q({
188
187
  r[o] = i;
189
188
  }), r;
190
189
  }
191
- const O = {
192
- resetFields: W,
193
- clearValidate: q,
194
- validateFields: D,
195
- getFieldsValue: k,
190
+ const x = {
191
+ resetFields: q,
192
+ clearValidate: D,
193
+ validateFields: k,
194
+ getFieldsValue: O,
196
195
  validate: $,
197
196
  scrollToField: G,
198
197
  setFieldsValue: H,
199
198
  setFieldValue: U,
200
199
  registerWatch: R,
201
- validateFieldsReturnTransformed: L,
202
- getFieldsValueTransformed: K,
200
+ validateFieldsReturnTransformed: K,
201
+ getFieldsValueTransformed: L,
203
202
  getInternalInstance: J
204
203
  };
205
204
  return Z(
206
205
  () => l.name,
207
206
  (e) => {
208
- e && (y.registerForm(e, O), z(() => {
207
+ e && (y.registerForm(e, x), z(() => {
209
208
  y.unregisterForm(l.name);
210
209
  }));
211
210
  },
212
211
  {
213
212
  immediate: !0
214
213
  }
215
- ), ne({
214
+ ), ie({
216
215
  model: ee(() => n),
217
216
  updateModel: v,
218
217
  internalInstance: {
219
218
  registerWatch: R,
220
- registerField: w,
219
+ registerField: j,
221
220
  setFieldValue: U
222
221
  }
223
- }), C(O), (e, t) => (re(), te(p(ie), le({
222
+ }), N(x), (e, t) => (re(), te(p(ne), le({
224
223
  ref_key: "formRef",
225
224
  ref: u
226
225
  }, p(ue)(l, ["initialValues", "onValuesChange", "onFinish"]), {
227
226
  model: n,
228
- onFinish: S
227
+ onFinish: W
229
228
  }), {
230
229
  default: oe(() => [
231
230
  se(e.$slots, "default")
@@ -34,6 +34,10 @@ export type ApFormItemProps = FormItemProps & Partial<ApFormColProps> & {
34
34
  */
35
35
  transform?: ApFormItemTransformType;
36
36
  tooltip?: any;
37
+ /**
38
+ * 此表单项的描述,设置此信息后,在查询表单排序时将优先使用此属性值
39
+ */
40
+ description?: string;
37
41
  };
38
42
  export type ApFormItemGroupProps = RowProps & {
39
43
  countPerRow?: number;
@@ -1,14 +1,14 @@
1
- import { defineComponent as D, useSlots as $, ref as d, onMounted as j, computed as F, unref as l, watch as q, cloneVNode as E, createBlock as g, openBlock as h, mergeProps as K, createSlots as O, withCtx as i, createCommentVNode as Q, resolveDynamicComponent as U, renderList as G, createElementVNode as H, normalizeClass as J, createVNode as p, normalizeStyle as M, renderSlot as W, normalizeProps as X, guardReactiveProps as Y } from "vue";
1
+ import { defineComponent as D, useSlots as $, ref as f, onMounted as j, computed as F, unref as l, watch as q, cloneVNode as E, createBlock as g, openBlock as h, mergeProps as K, createSlots as O, withCtx as i, createCommentVNode as Q, resolveDynamicComponent as U, renderList as G, createElementVNode as H, normalizeClass as J, createVNode as p, normalizeStyle as M, renderSlot as W, normalizeProps as X, guardReactiveProps as Y } from "vue";
2
2
  import { Form as Z, Tooltip as ee, TypographyText as oe } from "@aplus-frontend/antdv";
3
3
  import { useToken as le } from "@aplus-frontend/antdv/es/theme/internal";
4
- import { isFunction as B, cloneDeep as te, isArray as ae, omit as C } from "lodash-unified";
5
- import { apFormItemColPropKeys as re } from "../constant.mjs";
4
+ import { isFunction as B, cloneDeep as te, isArray as re, omit as C } from "lodash-unified";
5
+ import { apFormItemColPropKeys as ae } from "../constant.mjs";
6
6
  import { QuestionCircleOutlined as ne } from "@ant-design/icons-vue";
7
7
  import "../../config-provider/index.mjs";
8
8
  import { useInjectForm as ie } from "../context.mjs";
9
9
  import { isPromise as se } from "@fruits-chain/utils";
10
10
  import { getSingleVNode as ue, getValidVNodeList as me } from "../../utils/slot.mjs";
11
- import { useNamespace as fe } from "../../config-provider/hooks/use-namespace.mjs";
11
+ import { useNamespace as de } from "../../config-provider/hooks/use-namespace.mjs";
12
12
  const Ce = /* @__PURE__ */ D({
13
13
  name: "ApFormItem",
14
14
  __name: "index",
@@ -51,10 +51,11 @@ const Ce = /* @__PURE__ */ D({
51
51
  valuePropName: { default: "value" },
52
52
  initialValue: {},
53
53
  _signal: {},
54
- transform: {}
54
+ transform: {},
55
+ description: {}
55
56
  },
56
57
  setup(N, { expose: k }) {
57
- const o = N, r = $(), { model: s, updateModel: u, internalInstance: m } = ie(), { m: c, b: P } = fe("ap-form-item"), f = d(!1), n = d(), [, x] = le();
58
+ const o = N, a = $(), { model: s, updateModel: u, internalInstance: m } = ie(), { m: c, b: P } = de("ap-form-item"), d = f(!1), n = f(), [, x] = le();
58
59
  j(async () => {
59
60
  let e = B(o.initialValue) ? o.initialValue() : o.initialValue;
60
61
  se(e) && (e = await e), m == null || m.registerField({
@@ -63,11 +64,11 @@ const Ce = /* @__PURE__ */ D({
63
64
  transform: o.transform
64
65
  });
65
66
  });
66
- const y = F(() => o.name ? ae(o.name) ? o.name.reduce((e, t) => e == null ? void 0 : e[t], l(s)) : s == null ? void 0 : s.value[o.name] : null), v = d(ue(r.default));
67
+ const y = F(() => o.name ? re(o.name) ? o.name.reduce((e, t) => e == null ? void 0 : e[t], l(s)) : s == null ? void 0 : s.value[o.name] : null), v = f(ue(a.default));
67
68
  q(
68
69
  () => {
69
70
  var e;
70
- return (e = r.default) == null ? void 0 : e.call(r);
71
+ return (e = a.default) == null ? void 0 : e.call(a);
71
72
  },
72
73
  (e) => {
73
74
  v.value = me(e)[0];
@@ -77,20 +78,20 @@ const Ce = /* @__PURE__ */ D({
77
78
  u == null || u(o.name, e);
78
79
  }
79
80
  function S() {
80
- f.value = !0;
81
+ d.value = !0;
81
82
  }
82
83
  function I() {
83
- f.value = !1;
84
+ d.value = !1;
84
85
  }
85
86
  const V = F(() => {
86
- var t, a;
87
+ var t, r;
87
88
  if (!o.name)
88
- return (t = r.default()) == null ? void 0 : t[0];
89
+ return (t = a.default()) == null ? void 0 : t[0];
89
90
  const e = l(v);
90
91
  return e ? E(e, {
91
92
  [o.valuePropName]: l(y),
92
93
  [`onUpdate:${o.valuePropName}`]: w,
93
- bordered: o.bordered ? !1 : (a = e == null ? void 0 : e.props) == null ? void 0 : a.bordered,
94
+ bordered: o.bordered ? !1 : (r = e == null ? void 0 : e.props) == null ? void 0 : r.bordered,
94
95
  onFocus: S,
95
96
  onBlur: I
96
97
  }) : null;
@@ -115,8 +116,8 @@ const Ce = /* @__PURE__ */ D({
115
116
  const t = l(y);
116
117
  if (!e || !o.transform)
117
118
  return t;
118
- const a = B(o.transform) ? o.transform : o.transform.transformer;
119
- return o.transform ? a(t) : t;
119
+ const r = B(o.transform) ? o.transform : o.transform.transformer;
120
+ return o.transform ? r(t) : t;
120
121
  }
121
122
  return k({
122
123
  onFieldBlur: T,
@@ -124,17 +125,21 @@ const Ce = /* @__PURE__ */ D({
124
125
  clearValidate: A,
125
126
  resetField: L,
126
127
  getFieldValue: R
127
- }), (e, t) => (h(), g(l(Z).Item, K({
128
- ref_key: "formItemRef",
129
- ref: n
130
- }, l(C)(o, [...l(re), "tooltip", "label"]), {
131
- class: {
132
- [l(c)("bordered")]: e.bordered,
133
- [l(c)("focused")]: e.bordered && f.value,
134
- [l(P)()]: !0
128
+ }), (e, t) => (h(), g(l(Z).Item, K(
129
+ {
130
+ ref_key: "formItemRef",
131
+ ref: n
135
132
  },
136
- colon: e.bordered ? !1 : o.colon
137
- }), O({
133
+ l(C)(o, [...l(ae), "tooltip", "label", "description"]),
134
+ {
135
+ class: {
136
+ [l(c)("bordered")]: e.bordered,
137
+ [l(c)("focused")]: e.bordered && d.value,
138
+ [l(P)()]: !0
139
+ },
140
+ colon: e.bordered ? !1 : o.colon
141
+ }
142
+ ), O({
138
143
  default: i(() => [
139
144
  V.value ? (h(), g(U(V.value), { key: 0 })) : Q("", !0)
140
145
  ]),
@@ -142,9 +147,9 @@ const Ce = /* @__PURE__ */ D({
142
147
  }, [
143
148
  o.tooltip ? {
144
149
  name: "tooltip",
145
- fn: i(({ class: a }) => [
150
+ fn: i(({ class: r }) => [
146
151
  H("span", {
147
- class: J(a)
152
+ class: J(r)
148
153
  }, [
149
154
  p(l(ee), {
150
155
  title: o.tooltip
@@ -171,7 +176,7 @@ const Ce = /* @__PURE__ */ D({
171
176
  ]),
172
177
  key: "1"
173
178
  } : void 0,
174
- G(l(C)(r, "default"), (a, b) => ({
179
+ G(l(C)(a, "default"), (r, b) => ({
175
180
  name: b,
176
181
  fn: i((_) => [
177
182
  W(e.$slots, b, X(Y(_ || {})))
@@ -46,6 +46,7 @@ const w = /* @__PURE__ */ f({
46
46
  initialValue: {},
47
47
  _signal: {},
48
48
  transform: {},
49
+ description: {},
49
50
  field: { default: () => ({}) },
50
51
  disabled: { type: Boolean, default: void 0 }
51
52
  },
@@ -1,4 +1,4 @@
1
- import { defineComponent as h, useSlots as B, computed as v, createBlock as y, openBlock as x, normalizeProps as r, guardReactiveProps as t, unref as a, createSlots as s, withCtx as i, createVNode as g, renderList as p, renderSlot as f } from "vue";
1
+ import { defineComponent as h, useSlots as B, computed as v, createBlock as y, openBlock as x, normalizeProps as a, guardReactiveProps as t, unref as r, createSlots as s, withCtx as i, createVNode as g, renderList as p, renderSlot as f } from "vue";
2
2
  import "../../item/index.vue2.mjs";
3
3
  import "../../../ap-field/date/index.vue2.mjs";
4
4
  import { isUndefined as F, omit as m, pick as S } from "lodash-unified";
@@ -48,6 +48,7 @@ const L = /* @__PURE__ */ h({
48
48
  initialValue: {},
49
49
  _signal: {},
50
50
  transform: {},
51
+ description: {},
51
52
  field: { default: () => ({}) },
52
53
  placeholder: {},
53
54
  disabled: { type: Boolean, default: void 0 }
@@ -62,23 +63,23 @@ const L = /* @__PURE__ */ h({
62
63
  bordered: e.bordered ? !1 : F((o = e.field) == null ? void 0 : o.bordered) ? !0 : e.field.bordered
63
64
  };
64
65
  });
65
- return (o, P) => (x(), y(k, r(t(a(m)(e, ["field", "placeholder", "disabled"]))), s({
66
+ return (o, P) => (x(), y(k, a(t(r(m)(e, ["field", "placeholder", "disabled"]))), s({
66
67
  default: i(() => [
67
- g(C, r(t(b.value)), s({ _: 2 }, [
68
- p(a(m)(n, a(u)), (_, l) => ({
68
+ g(C, a(t(b.value)), s({ _: 2 }, [
69
+ p(r(m)(n, r(u)), (_, l) => ({
69
70
  name: l,
70
71
  fn: i((d) => [
71
- f(o.$slots, l, r(t(d || {})))
72
+ f(o.$slots, l, a(t(d || {})))
72
73
  ])
73
74
  }))
74
75
  ]), 1040)
75
76
  ]),
76
77
  _: 2
77
78
  }, [
78
- p(a(S)(n, a(u)), (_, l) => ({
79
+ p(r(S)(n, r(u)), (_, l) => ({
79
80
  name: l,
80
81
  fn: i((d) => [
81
- f(o.$slots, l, r(t(d || {})))
82
+ f(o.$slots, l, a(t(d || {})))
82
83
  ])
83
84
  }))
84
85
  ]), 1040));
@@ -48,6 +48,7 @@ const I = /* @__PURE__ */ B({
48
48
  initialValue: {},
49
49
  _signal: {},
50
50
  transform: {},
51
+ description: {},
51
52
  field: { default: () => ({}) },
52
53
  placeholder: {},
53
54
  disabled: { type: Boolean, default: void 0 }
@@ -48,33 +48,34 @@ const T = /* @__PURE__ */ y({
48
48
  initialValue: {},
49
49
  _signal: {},
50
50
  transform: {},
51
+ description: {},
51
52
  field: { default: () => ({}) },
52
53
  placeholder: {},
53
54
  disabled: { type: Boolean, default: void 0 }
54
55
  },
55
56
  setup(c, { expose: b }) {
56
- const h = c, p = B(), a = _();
57
+ const h = c, p = B(), r = _();
57
58
  return b({
58
59
  focus: () => {
59
60
  var e;
60
- (e = a.value) == null || e.focus();
61
+ (e = r.value) == null || e.focus();
61
62
  },
62
63
  blur: () => {
63
64
  var e;
64
- (e = a.value) == null || e.blur();
65
+ (e = r.value) == null || e.blur();
65
66
  }
66
67
  }), (e, R) => (x(), g(C, t(s(l(f)(h, ["field", "placeholder", "disabled"]))), d({
67
68
  default: n(() => [
68
69
  k(F, N({
69
70
  ref_key: "inputNumberRef",
70
- ref: a,
71
+ ref: r,
71
72
  placeholder: e.placeholder,
72
73
  disabled: e.disabled
73
74
  }, e.field), d({ _: 2 }, [
74
75
  i(l(f)(p, l(m)), (v, o) => ({
75
76
  name: o,
76
- fn: n((r) => [
77
- u(e.$slots, o, t(s(r || {})))
77
+ fn: n((a) => [
78
+ u(e.$slots, o, t(s(a || {})))
78
79
  ])
79
80
  }))
80
81
  ]), 1040, ["placeholder", "disabled"])
@@ -83,8 +84,8 @@ const T = /* @__PURE__ */ y({
83
84
  }, [
84
85
  i(l(S)(p, l(m)), (v, o) => ({
85
86
  name: o,
86
- fn: n((r) => [
87
- u(e.$slots, o, t(s(r || {})))
87
+ fn: n((a) => [
88
+ u(e.$slots, o, t(s(a || {})))
88
89
  ])
89
90
  }))
90
91
  ]), 1040));
@@ -46,6 +46,7 @@ const q = /* @__PURE__ */ u({
46
46
  initialValue: {},
47
47
  _signal: {},
48
48
  transform: {},
49
+ description: {},
49
50
  field: { default: () => ({}) },
50
51
  disabled: { type: Boolean, default: void 0 }
51
52
  },
@@ -1,7 +1,7 @@
1
- import { defineComponent as B, ref as x, useSlots as g, computed as S, createBlock as k, openBlock as F, normalizeProps as d, guardReactiveProps as n, unref as l, createSlots as f, withCtx as i, createVNode as C, mergeProps as P, renderList as u, renderSlot as m } from "vue";
1
+ import { defineComponent as B, ref as x, useSlots as g, computed as S, createBlock as k, openBlock as F, normalizeProps as d, guardReactiveProps as n, unref as l, createSlots as f, withCtx as i, createVNode as C, mergeProps as P, renderList as u, renderSlot as c } from "vue";
2
2
  import "../../item/index.vue2.mjs";
3
3
  import "../../../ap-field/index.mjs";
4
- import { isUndefined as q, omit as c, pick as $ } from "lodash-unified";
4
+ import { isUndefined as q, omit as m, pick as $ } from "lodash-unified";
5
5
  import { apFormItemSlotNames as b } from "../../constant.mjs";
6
6
  import N from "../../item/index.vue.mjs";
7
7
  import R from "../../../ap-field/select/index.vue.mjs";
@@ -48,6 +48,7 @@ const E = /* @__PURE__ */ B({
48
48
  initialValue: {},
49
49
  _signal: {},
50
50
  transform: {},
51
+ description: {},
51
52
  field: { default: () => ({}) },
52
53
  placeholder: {},
53
54
  disabled: { type: Boolean, default: void 0 }
@@ -77,16 +78,16 @@ const E = /* @__PURE__ */ B({
77
78
  bordered: o.bordered ? !1 : q((e = o.field) == null ? void 0 : e.bordered) ? !0 : (a = o.field) == null ? void 0 : a.bordered
78
79
  };
79
80
  });
80
- return (e, a) => (F(), k(N, d(n(l(c)(o, ["field", "placeholder", "disabled"]))), f({
81
+ return (e, a) => (F(), k(N, d(n(l(m)(o, ["field", "placeholder", "disabled"]))), f({
81
82
  default: i(() => [
82
83
  C(l(R), P(h.value, {
83
84
  ref_key: "selectRef",
84
85
  ref: t
85
86
  }), f({ _: 2 }, [
86
- u(l(c)(p, l(b)), (y, r) => ({
87
+ u(l(m)(p, l(b)), (y, r) => ({
87
88
  name: r,
88
89
  fn: i((s) => [
89
- m(e.$slots, r, d(n(s || {})))
90
+ c(e.$slots, r, d(n(s || {})))
90
91
  ])
91
92
  }))
92
93
  ]), 1040)
@@ -96,7 +97,7 @@ const E = /* @__PURE__ */ B({
96
97
  u(l($)(p, l(b)), (y, r) => ({
97
98
  name: r,
98
99
  fn: i((s) => [
99
- m(e.$slots, r, d(n(s || {})))
100
+ c(e.$slots, r, d(n(s || {})))
100
101
  ])
101
102
  }))
102
103
  ]), 1040));
@@ -47,6 +47,7 @@ const I = /* @__PURE__ */ b({
47
47
  initialValue: {},
48
48
  _signal: {},
49
49
  transform: {},
50
+ description: {},
50
51
  field: { default: () => ({}) },
51
52
  disabled: { type: Boolean, default: void 0 }
52
53
  },
@@ -1,4 +1,4 @@
1
- import { defineComponent as B, useSlots as x, ref as S, computed as _, createBlock as k, openBlock as F, normalizeProps as n, guardReactiveProps as p, unref as t, createSlots as u, withCtx as d, createVNode as R, mergeProps as C, renderList as f, renderSlot as c } from "vue";
1
+ import { defineComponent as B, useSlots as x, ref as S, computed as _, createBlock as k, openBlock as F, normalizeProps as n, guardReactiveProps as p, unref as t, createSlots as u, withCtx as i, createVNode as R, mergeProps as C, renderList as f, renderSlot as c } from "vue";
2
2
  import "../../item/index.vue2.mjs";
3
3
  import { ApField as P } from "../../../ap-field/index.mjs";
4
4
  import { omit as m, pick as A } from "lodash-unified";
@@ -47,12 +47,13 @@ const E = /* @__PURE__ */ B({
47
47
  initialValue: {},
48
48
  _signal: {},
49
49
  transform: {},
50
+ description: {},
50
51
  field: { default: () => ({}) },
51
52
  placeholder: {},
52
53
  disabled: { type: Boolean, default: void 0 }
53
54
  },
54
55
  setup(v, { expose: h }) {
55
- const { Text: g } = P, i = x(), y = v, l = S();
56
+ const { Text: g } = P, d = x(), y = v, l = S();
56
57
  return h({
57
58
  focus: (e) => {
58
59
  var a;
@@ -75,16 +76,16 @@ const E = /* @__PURE__ */ B({
75
76
  return (e = l.value) == null ? void 0 : e.input;
76
77
  })
77
78
  }), (e, a) => (F(), k(N, n(p(t(m)(y, ["field", "disabled", "placeholder"]))), u({
78
- default: d(() => [
79
+ default: i(() => [
79
80
  R(t(g), C({
80
81
  ref_key: "inputRef",
81
82
  ref: l,
82
83
  disabled: e.disabled,
83
84
  placeholder: e.placeholder
84
85
  }, e.field), u({ _: 2 }, [
85
- f(t(m)(i, t(b)), (r, o) => ({
86
+ f(t(m)(d, t(b)), (r, o) => ({
86
87
  name: o,
87
- fn: d((s) => [
88
+ fn: i((s) => [
88
89
  c(e.$slots, o, n(p(s || {})))
89
90
  ])
90
91
  }))
@@ -92,9 +93,9 @@ const E = /* @__PURE__ */ B({
92
93
  ]),
93
94
  _: 2
94
95
  }, [
95
- f(t(A)(i, t(b)), (r, o) => ({
96
+ f(t(A)(d, t(b)), (r, o) => ({
96
97
  name: o,
97
- fn: d((s) => [
98
+ fn: i((s) => [
98
99
  c(e.$slots, o, n(p(s || {})))
99
100
  ])
100
101
  }))
@@ -47,6 +47,7 @@ const z = /* @__PURE__ */ B({
47
47
  initialValue: {},
48
48
  _signal: {},
49
49
  transform: {},
50
+ description: {},
50
51
  field: { default: () => ({}) },
51
52
  placeholder: {},
52
53
  disabled: { type: Boolean, default: void 0 }
@@ -45,6 +45,7 @@ const $ = /* @__PURE__ */ c({
45
45
  initialValue: {},
46
46
  _signal: {},
47
47
  transform: {},
48
+ description: {},
48
49
  field: { default: () => ({}) },
49
50
  placeholder: {},
50
51
  disabled: { type: Boolean, default: void 0 }