@aplus-frontend/ui 7.14.5 → 7.15.1

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 (107) hide show
  1. package/es/src/ag-grid/editable/form-item.vue.mjs +8 -7
  2. package/es/src/ag-grid/editable/index.vue.mjs +19 -18
  3. package/es/src/ag-grid/index.vue.mjs +110 -105
  4. package/es/src/ag-grid/interface.d.ts +7 -0
  5. package/es/src/ap-field/checkbox/index.vue.d.ts +1 -1
  6. package/es/src/ap-field/date/index.vue.d.ts +1086 -6
  7. package/es/src/ap-field/date/index.vue.mjs +63 -57
  8. package/es/src/ap-field/date-range/index.vue.d.ts +1155 -4
  9. package/es/src/ap-field/date-range/index.vue.mjs +70 -63
  10. package/es/src/ap-field/interface.d.ts +25 -29
  11. package/es/src/ap-field/number/index.vue.d.ts +1 -1
  12. package/es/src/ap-field/radio/index.vue.d.ts +1 -1
  13. package/es/src/ap-field/rate/index.vue.d.ts +1 -1
  14. package/es/src/ap-field/second/index.vue.d.ts +1 -1
  15. package/es/src/ap-field/select/index.vue.d.ts +3 -2
  16. package/es/src/ap-field/select/index.vue.mjs +116 -104
  17. package/es/src/ap-field/select/read.vue2.mjs +4 -3
  18. package/es/src/ap-field/slider/index.vue.d.ts +1 -1
  19. package/es/src/ap-field/switch/index.vue.d.ts +232 -4
  20. package/es/src/ap-field/switch/index.vue.mjs +48 -42
  21. package/es/src/ap-field/text/password.vue.d.ts +1 -1
  22. package/es/src/ap-field/text-area/index.vue.d.ts +1 -1
  23. package/es/src/ap-form/drawer-form/index.vue.d.ts +1 -0
  24. package/es/src/ap-form/drawer-form/index.vue.mjs +107 -116
  25. package/es/src/ap-form/interface.d.ts +1 -1
  26. package/es/src/ap-form/item-group/index.vue.d.ts +2 -4
  27. package/es/src/ap-form/item-group/index.vue.mjs +37 -42
  28. package/es/src/ap-form/items/checkbox/index.vue.d.ts +66 -5
  29. package/es/src/ap-form/items/checkbox/index.vue.mjs +20 -14
  30. package/es/src/ap-form/items/date/index.vue.d.ts +1497 -5
  31. package/es/src/ap-form/items/date/index.vue.mjs +25 -19
  32. package/es/src/ap-form/items/date-range/index.vue.d.ts +1607 -5
  33. package/es/src/ap-form/items/date-range/index.vue.mjs +25 -19
  34. package/es/src/ap-form/items/number/index.vue.d.ts +4 -4
  35. package/es/src/ap-form/items/radio/index.vue.d.ts +5 -5
  36. package/es/src/ap-form/items/radio/index.vue.mjs +2 -3
  37. package/es/src/ap-form/items/select/index.vue.d.ts +18 -12
  38. package/es/src/ap-form/items/switch/index.vue.d.ts +436 -5
  39. package/es/src/ap-form/items/switch/index.vue.mjs +24 -17
  40. package/es/src/ap-form/items/text/password.vue.d.ts +5 -5
  41. package/es/src/ap-form/items/text-area/index.vue.d.ts +5 -5
  42. package/es/src/ap-table/components/setting/template/item.vue2.mjs +27 -26
  43. package/es/src/ap-table/constants.d.ts +1923 -107
  44. package/es/src/time-ago/index.vue.mjs +21 -17
  45. package/es/src/time-ago/interface.d.ts +8 -0
  46. package/es/src/time-ago/useTimeAgo.d.ts +21 -0
  47. package/es/src/time-ago/useTimeAgo.mjs +36 -34
  48. package/es/src/time-ago/utils.d.ts +11 -0
  49. package/es/src/time-ago/utils.mjs +41 -9
  50. package/es/src/utils/index.d.ts +1 -0
  51. package/es/src/utils/index.mjs +18 -14
  52. package/es/src/version.d.ts +1 -1
  53. package/es/src/version.mjs +1 -1
  54. package/lib/src/ag-grid/editable/form-item.vue.js +1 -1
  55. package/lib/src/ag-grid/editable/index.vue.js +1 -1
  56. package/lib/src/ag-grid/index.vue.js +1 -1
  57. package/lib/src/ag-grid/interface.d.ts +7 -0
  58. package/lib/src/ap-field/checkbox/index.vue.d.ts +1 -1
  59. package/lib/src/ap-field/date/index.vue.d.ts +1086 -6
  60. package/lib/src/ap-field/date/index.vue.js +1 -1
  61. package/lib/src/ap-field/date-range/index.vue.d.ts +1155 -4
  62. package/lib/src/ap-field/date-range/index.vue.js +1 -1
  63. package/lib/src/ap-field/interface.d.ts +25 -29
  64. package/lib/src/ap-field/number/index.vue.d.ts +1 -1
  65. package/lib/src/ap-field/radio/index.vue.d.ts +1 -1
  66. package/lib/src/ap-field/rate/index.vue.d.ts +1 -1
  67. package/lib/src/ap-field/second/index.vue.d.ts +1 -1
  68. package/lib/src/ap-field/select/index.vue.d.ts +3 -2
  69. package/lib/src/ap-field/select/index.vue.js +1 -1
  70. package/lib/src/ap-field/select/read.vue2.js +1 -1
  71. package/lib/src/ap-field/slider/index.vue.d.ts +1 -1
  72. package/lib/src/ap-field/switch/index.vue.d.ts +232 -4
  73. package/lib/src/ap-field/switch/index.vue.js +1 -1
  74. package/lib/src/ap-field/text/password.vue.d.ts +1 -1
  75. package/lib/src/ap-field/text-area/index.vue.d.ts +1 -1
  76. package/lib/src/ap-form/drawer-form/index.vue.d.ts +1 -0
  77. package/lib/src/ap-form/drawer-form/index.vue.js +1 -1
  78. package/lib/src/ap-form/interface.d.ts +1 -1
  79. package/lib/src/ap-form/item-group/index.vue.d.ts +2 -4
  80. package/lib/src/ap-form/item-group/index.vue.js +1 -1
  81. package/lib/src/ap-form/items/checkbox/index.vue.d.ts +66 -5
  82. package/lib/src/ap-form/items/checkbox/index.vue.js +1 -1
  83. package/lib/src/ap-form/items/date/index.vue.d.ts +1497 -5
  84. package/lib/src/ap-form/items/date/index.vue.js +1 -1
  85. package/lib/src/ap-form/items/date-range/index.vue.d.ts +1607 -5
  86. package/lib/src/ap-form/items/date-range/index.vue.js +1 -1
  87. package/lib/src/ap-form/items/number/index.vue.d.ts +4 -4
  88. package/lib/src/ap-form/items/radio/index.vue.d.ts +5 -5
  89. package/lib/src/ap-form/items/radio/index.vue.js +1 -1
  90. package/lib/src/ap-form/items/select/index.vue.d.ts +18 -12
  91. package/lib/src/ap-form/items/switch/index.vue.d.ts +436 -5
  92. package/lib/src/ap-form/items/switch/index.vue.js +1 -1
  93. package/lib/src/ap-form/items/text/password.vue.d.ts +5 -5
  94. package/lib/src/ap-form/items/text-area/index.vue.d.ts +5 -5
  95. package/lib/src/ap-table/components/setting/template/item.vue2.js +1 -1
  96. package/lib/src/ap-table/constants.d.ts +1923 -107
  97. package/lib/src/time-ago/index.vue.js +1 -1
  98. package/lib/src/time-ago/interface.d.ts +8 -0
  99. package/lib/src/time-ago/useTimeAgo.d.ts +21 -0
  100. package/lib/src/time-ago/useTimeAgo.js +1 -1
  101. package/lib/src/time-ago/utils.d.ts +11 -0
  102. package/lib/src/time-ago/utils.js +1 -1
  103. package/lib/src/utils/index.d.ts +1 -0
  104. package/lib/src/utils/index.js +1 -1
  105. package/lib/src/version.d.ts +1 -1
  106. package/lib/src/version.js +1 -1
  107. package/package.json +5 -5
@@ -1,19 +1,20 @@
1
- import { defineComponent as ie, useSlots as de, ref as I, shallowRef as ce, computed as s, onMounted as pe, watch as fe, unref as n, createVNode as f, createElementBlock as _, createBlock as C, openBlock as m, toDisplayString as N, mergeProps as me, h as he, createSlots as ve, withCtx as h, createElementVNode as x, normalizeClass as v, createCommentVNode as M, resolveDynamicComponent as P, withModifiers as ye, renderList as ge, renderSlot as Ce, normalizeProps as be, guardReactiveProps as we } from "vue";
2
- import { Select as Se, Flex as D, Checkbox as T, Spin as ke } from "@aplus-frontend/antdv";
3
- import { debounce as Be, isFunction as q, isArray as Ne, isNil as xe, omit as L, isNumber as Fe } from "lodash-unified";
1
+ import { defineComponent as pe, useSlots as fe, ref as k, shallowRef as me, computed as s, onMounted as he, watch as ve, unref as n, createVNode as f, createElementBlock as M, createBlock as C, openBlock as m, toDisplayString as B, mergeProps as ye, h as ge, createSlots as Ce, withCtx as h, createElementVNode as N, normalizeClass as v, createCommentVNode as P, resolveDynamicComponent as T, withModifiers as be, renderList as we, renderSlot as Se, normalizeProps as Fe, guardReactiveProps as Oe } from "vue";
2
+ import { Select as ke, Flex as q, Checkbox as L, Spin as Be } from "@aplus-frontend/antdv";
3
+ import { debounce as Ne, isFunction as R, isArray as xe, isNil as Ae, omit as z, isNumber as Ve } from "lodash-unified";
4
4
  import "../../config-provider/index.mjs";
5
5
  import "../../utils/index.mjs";
6
+ import { useDevWarning as Ie } from "../../utils/warning.mjs";
6
7
  import "../../hooks/index.mjs";
7
- import { useDefaultPlaceholder as Oe } from "../hooks/use-default-placeholder.mjs";
8
- import Ae from "../style/index.mjs";
9
- import { useSelectOptions as Ve } from "./use-select-options.mjs";
10
- import { useNamespace as R } from "../../config-provider/hooks/use-namespace.mjs";
11
- import { useLocale as Ie } from "../../config-provider/hooks/use-locale.mjs";
12
- import { useControllableValue as _e } from "../../hooks/useControllableValue.mjs";
13
- import { isDef as z } from "../../utils/is.mjs";
14
- const Me = {
8
+ import { useDefaultPlaceholder as _e } from "../hooks/use-default-placeholder.mjs";
9
+ import De from "../style/index.mjs";
10
+ import { useSelectOptions as Me } from "./use-select-options.mjs";
11
+ import { isDef as x } from "../../utils/is.mjs";
12
+ import { useNamespace as E } from "../../config-provider/hooks/use-namespace.mjs";
13
+ import { useLocale as Pe } from "../../config-provider/hooks/use-locale.mjs";
14
+ import { useControllableValue as Te } from "../../hooks/useControllableValue.mjs";
15
+ const qe = {
15
16
  key: 0
16
- }, Pe = ["onClick"], Ge = /* @__PURE__ */ ie({
17
+ }, Le = ["onClick"], Ze = /* @__PURE__ */ pe({
17
18
  name: "ApFieldSelect",
18
19
  __name: "index",
19
20
  props: {
@@ -154,8 +155,12 @@ const Me = {
154
155
  type: Boolean,
155
156
  default: !1
156
157
  },
157
- lazy: {
158
+ fetchOnFocus: {
158
159
  type: Boolean,
160
+ default: void 0
161
+ },
162
+ lazy: {
163
+ type: [Boolean, String],
159
164
  default: !1
160
165
  },
161
166
  addAll: {
@@ -172,194 +177,201 @@ const Me = {
172
177
  }
173
178
  },
174
179
  emits: ["update:value"],
175
- setup(E, {
176
- expose: U,
177
- emit: $
180
+ setup(U, {
181
+ expose: $,
182
+ emit: K
178
183
  }) {
179
184
  let r = 0;
180
- const F = de(), e = E, {
185
+ const A = fe(), e = U, {
186
+ deprecated: j
187
+ } = Ie("ApFieldSelect");
188
+ j(!x(e.refetchOnFocus), "refetchOnFocus", "fetchOnFocus");
189
+ const {
181
190
  b
182
- } = R("field-select"), {
183
- b: d
184
- } = R("field-select-popup-option"), K = Ae("field"), O = I(!1), {
185
- t: A
186
- } = Ie(), j = Be((t) => {
187
- if (!q(e.request))
191
+ } = E("field-select"), {
192
+ b: c
193
+ } = E("field-select-popup-option"), H = De("field"), V = k(!1), I = k(!1), {
194
+ t: _
195
+ } = Pe(), W = Ne((t) => {
196
+ if (!R(e.request))
188
197
  return;
189
198
  r += 1;
190
199
  const o = r;
191
- y([]), u.value = !0, e.request(t).then((l) => {
192
- r === o && (y(l), u.value = !1);
200
+ g([]), u.value = !0, e.request(t).then((l) => {
201
+ r === o && (g(l), u.value = !1);
193
202
  });
194
- }, e.searchDelay), H = (t, o) => {
203
+ }, e.searchDelay), G = (t, o) => {
195
204
  const l = e.fieldNames?.label || "label";
196
205
  return typeof o?.[l] == "string" && o[l].toLowerCase().indexOf(t.toLowerCase()) > -1;
197
206
  }, {
198
- options: c,
199
- updateOptions: y
200
- } = Ve(e), w = ce(), u = I(e?.loading || !1), W = $, G = s(() => {
207
+ options: d,
208
+ updateOptions: g
209
+ } = Me(e), w = me(), u = k(e?.loading || !1), J = K, Q = s(() => e.fetchOnFocus ?? e.refetchOnFocus), X = s(() => {
201
210
  if (e.multiple)
202
211
  return e.tokenSeparators ? "tags" : "multiple";
203
212
  });
204
- async function g(t = !0) {
205
- if (!q(e.request))
213
+ async function y(t = !0) {
214
+ if (!R(e.request))
206
215
  return;
207
216
  u.value = !0, r += 1;
208
217
  const o = r;
209
218
  try {
210
- t && y([]);
219
+ t && g([]);
211
220
  const l = await e.request(void 0, e.params);
212
221
  if (o !== r)
213
222
  return;
214
- y(l);
223
+ g(l);
215
224
  } finally {
216
225
  u.value = !1;
217
226
  }
218
227
  }
219
- function J(t) {
220
- e.onFocus?.(t), e.refetchOnFocus && r > 0 && !u.value && g(!0);
228
+ function Y(t) {
229
+ !I.value && r === 0 && e.lazy === "first-focus" ? y() : Q.value && !u.value && y(!0), e.onFocus?.(t), I.value = !0;
221
230
  }
222
- pe(() => {
223
- e.lazy || g();
224
- }), fe(() => e.params, () => {
225
- g();
231
+ he(() => {
232
+ if (!e.lazy) {
233
+ y();
234
+ return;
235
+ }
236
+ }), ve(() => e.params, () => {
237
+ y();
226
238
  }, {
227
239
  deep: !0
228
240
  });
229
241
  const {
230
242
  value: p,
231
243
  updateValue: S
232
- } = _e(e, W), Q = Oe("Select", e), X = s(() => {
244
+ } = Te(e, J), Z = _e("Select", e), ee = s(() => {
233
245
  const t = n(p);
234
246
  if (!t)
235
247
  return e.emptyText;
236
248
  const o = e.fieldNames?.label || "label", l = e.fieldNames?.value || "value";
237
- return Ne(t) ? t.map((a) => n(c).find((re) => re[l] === a)?.[o]).filter(Boolean).join("、") || e.emptyText : n(c).find((a) => a[l] === t)?.[o] || e.emptyText;
238
- }), Y = s(() => {
249
+ return xe(t) ? t.map((a) => n(d).find((de) => de[l] === a)?.[o]).filter(Boolean).join("、") || e.emptyText : n(d).find((a) => a[l] === t)?.[o] || e.emptyText;
250
+ }), te = s(() => {
239
251
  const t = !!e?.showSearch, o = e.searchMode;
240
252
  let l = {};
241
253
  return t && (l = o === "request" ? {
242
254
  defaultActiveFirstOption: !1,
243
- onSearch: j,
255
+ onSearch: W,
244
256
  notFoundContent: u.value ? void 0 : null,
245
257
  filterOption: !1,
246
258
  suffixIcon: null
247
259
  } : {
248
- filterOption: xe(e?.filterOption) ? H : e?.filterOption
260
+ filterOption: Ae(e?.filterOption) ? G : e?.filterOption
249
261
  }), {
250
- ...L(e, ["mode", "value", "onUpdate:value", "onSearch", "request", "searchMode", "onFocus", "onBeforeSelect"]),
251
- placeholder: n(Q),
262
+ ...z(e, ["mode", "value", "onUpdate:value", "onSearch", "request", "searchMode", "onFocus", "onBeforeSelect"]),
263
+ placeholder: n(Z),
252
264
  ...l
253
265
  };
254
- }), Z = s(() => c.value.map((t) => t[e.fieldNames?.value || "value"])), k = s(() => c.value.filter((t) => !t.disabled).map((t) => t[e.fieldNames?.value || "value"])), V = s(() => !e.multiple || z(e.maxCount) ? !1 : Fe(e.addAll) ? Z.value.length >= e.addAll : !!e.addAll), ee = s(() => e.multiple && e.allowOnlySelect && (!z(e.maxCount) || e.maxCount >= 1));
255
- function te() {
266
+ }), oe = s(() => d.value.map((t) => t[e.fieldNames?.value || "value"])), F = s(() => d.value.filter((t) => !t.disabled).map((t) => t[e.fieldNames?.value || "value"])), D = s(() => !e.multiple || x(e.maxCount) ? !1 : Ve(e.addAll) ? oe.value.length >= e.addAll : !!e.addAll), le = s(() => e.multiple && e.allowOnlySelect && (!x(e.maxCount) || e.maxCount >= 1));
267
+ function ne() {
256
268
  w.value?.focus();
257
269
  }
258
- function oe() {
270
+ function ae() {
259
271
  w.value?.blur();
260
272
  }
261
- function B(t, o) {
273
+ function O(t, o) {
262
274
  const l = e.fieldNames?.[o] ?? o;
263
275
  return t[l];
264
276
  }
265
- function le(t) {
266
- const o = B(t, "value");
277
+ function se(t) {
278
+ const o = O(t, "value");
267
279
  S(e.multiple ? [o] : o), e.onChange?.([o], [t]);
268
280
  }
269
- function ne(t) {
270
- return F.option ? f("div", {
271
- class: d("custom")
272
- }, [F.option(t)]) : f("span", {
273
- class: d("label")
274
- }, [B(t, "label")]);
281
+ function ue(t) {
282
+ return A.option ? f("div", {
283
+ class: c("custom")
284
+ }, [A.option(t)]) : f("span", {
285
+ class: c("label")
286
+ }, [O(t, "label")]);
275
287
  }
276
- const ae = s(() => {
277
- const t = n(p) || [], o = k.value;
288
+ const re = s(() => {
289
+ const t = n(p) || [], o = F.value;
278
290
  return o.length > 0 && o.every((l) => t.includes(l));
279
- }), se = s(() => {
280
- const t = n(p) || [], o = k.value, l = o.filter((i) => t.includes(i)).length;
291
+ }), ie = s(() => {
292
+ const t = n(p) || [], o = F.value, l = o.filter((i) => t.includes(i)).length;
281
293
  return l > 0 && l < o.length;
282
294
  });
283
- function ue() {
284
- const t = new Set(n(p) || []), o = k.value;
295
+ function ce() {
296
+ const t = new Set(n(p) || []), o = F.value;
285
297
  o.length > 0 && o.every((a) => t.has(a)) ? o.forEach((a) => t.delete(a)) : o.forEach((a) => t.add(a));
286
- const i = c.value.filter((a) => t.has(a[e.fieldNames?.value || "value"]));
298
+ const i = d.value.filter((a) => t.has(a[e.fieldNames?.value || "value"]));
287
299
  S([...t]), e.onChange?.([...t], i);
288
300
  }
289
- return U({
290
- focus: te,
291
- blur: oe,
292
- request: g
293
- }), (t, o) => t.mode === "read" ? (m(), _("span", Me, N(X.value), 1)) : (m(), C(n(Se), me({
301
+ return $({
302
+ focus: ne,
303
+ blur: ae,
304
+ request: y
305
+ }), (t, o) => t.mode === "read" ? (m(), M("span", qe, B(ee.value), 1)) : (m(), C(n(ke), ye({
294
306
  key: 1,
295
307
  ref_key: "selectRef",
296
308
  ref: w,
297
309
  "allow-clear": ""
298
- }, Y.value, {
299
- mode: G.value,
310
+ }, te.value, {
311
+ mode: X.value,
300
312
  value: n(p),
301
- options: n(c),
313
+ options: n(d),
302
314
  loading: u.value,
303
- "menu-item-selected-icon": he("span"),
304
- "popup-class-name": `${n(b)("popup")} ${n(K)}`,
305
- open: O.value,
315
+ "menu-item-selected-icon": ge("span"),
316
+ "popup-class-name": `${n(b)("popup")} ${n(H)}`,
317
+ open: V.value,
306
318
  "onUpdate:value": n(S),
307
- onFocus: J,
308
- onDropdownVisibleChange: o[0] || (o[0] = (l) => O.value = l)
309
- }), ve({
310
- option: h((l) => [x("div", {
311
- class: v(n(d)("outter"))
312
- }, [f(n(D), {
319
+ onFocus: Y,
320
+ onDropdownVisibleChange: o[0] || (o[0] = (l) => V.value = l)
321
+ }), Ce({
322
+ option: h((l) => [N("div", {
323
+ class: v(n(c)("outter"))
324
+ }, [f(n(q), {
313
325
  justify: "space-between",
314
326
  align: "center",
315
- class: v(n(d)("wrapper")),
327
+ class: v(n(c)("wrapper")),
316
328
  gap: 8
317
329
  }, {
318
- default: h(() => [f(n(D), {
330
+ default: h(() => [f(n(q), {
319
331
  gap: 8,
320
332
  align: "center",
321
- class: v(n(d)("content-wrapper"))
333
+ class: v(n(c)("content-wrapper"))
322
334
  }, {
323
- default: h(() => [V.value ? (m(), C(n(T), {
335
+ default: h(() => [D.value ? (m(), C(n(L), {
324
336
  key: 0,
325
- checked: n(p)?.includes(B(l, "value"))
326
- }, null, 8, ["checked"])) : M("", !0), (m(), C(P(ne(l))))]),
337
+ checked: n(p)?.includes(O(l, "value"))
338
+ }, null, 8, ["checked"])) : P("", !0), (m(), C(T(ue(l))))]),
327
339
  _: 2
328
- }, 1032, ["class"]), ee.value && !l?.disabled ? (m(), _("span", {
340
+ }, 1032, ["class"]), le.value && !l?.disabled ? (m(), M("span", {
329
341
  key: 0,
330
- class: v(n(d)("action")),
331
- onClick: ye(() => le(l), ["stop"])
332
- }, N(n(A)("ap.field.chooseOnly")), 11, Pe)) : M("", !0)]),
342
+ class: v(n(c)("action")),
343
+ onClick: be(() => se(l), ["stop"])
344
+ }, B(n(_)("ap.field.chooseOnly")), 11, Le)) : P("", !0)]),
333
345
  _: 2
334
346
  }, 1032, ["class"])], 2)]),
335
347
  _: 2
336
- }, [ge(n(L)(t.$slots, ["option"]), (l, i) => ({
348
+ }, [we(n(z)(t.$slots, ["option"]), (l, i) => ({
337
349
  name: i,
338
- fn: h((a) => [Ce(t.$slots, i, be(we(a || {})))])
350
+ fn: h((a) => [Se(t.$slots, i, Fe(Oe(a || {})))])
339
351
  })), u.value ? {
340
352
  name: "notFoundContent",
341
- fn: h(() => [f(n(ke), {
353
+ fn: h(() => [f(n(Be), {
342
354
  size: "small"
343
355
  })]),
344
356
  key: "0"
345
- } : void 0, V.value ? {
357
+ } : void 0, D.value ? {
346
358
  name: "dropdownRender",
347
359
  fn: h(({
348
360
  menuNode: l
349
- }) => [x("div", {
361
+ }) => [N("div", {
350
362
  tabindex: -1,
351
363
  class: v(n(b)("popup-all-option")),
352
- onClick: ue
353
- }, [f(n(T), {
354
- checked: ae.value,
355
- indeterminate: se.value
356
- }, null, 8, ["checked", "indeterminate"]), x("span", {
364
+ onClick: ce
365
+ }, [f(n(L), {
366
+ checked: re.value,
367
+ indeterminate: ie.value
368
+ }, null, 8, ["checked", "indeterminate"]), N("span", {
357
369
  class: v(n(b)("popup-all-option-label"))
358
- }, N(n(A)("ap.field.selectAll")), 3)], 2), (m(), C(P(l)))]),
370
+ }, B(n(_)("ap.field.selectAll")), 3)], 2), (m(), C(T(l)))]),
359
371
  key: "1"
360
372
  } : void 0]), 1040, ["mode", "value", "options", "loading", "menu-item-selected-icon", "popup-class-name", "open", "onUpdate:value"]));
361
373
  }
362
374
  });
363
375
  export {
364
- Ge as default
376
+ Ze as default
365
377
  };
@@ -1,4 +1,4 @@
1
- import { defineComponent as i, computed as s, createElementBlock as d, createCommentVNode as c, openBlock as u, toDisplayString as m } from "vue";
1
+ import { defineComponent as i, computed as s, createElementBlock as c, createCommentVNode as d, openBlock as u, toDisplayString as m } from "vue";
2
2
  import { isArray as y } from "lodash-unified";
3
3
  const f = { key: 0 }, C = /* @__PURE__ */ i({
4
4
  name: "ApFieldSelectRead",
@@ -90,7 +90,8 @@ const f = { key: 0 }, C = /* @__PURE__ */ i({
90
90
  "onUpdate:value": {},
91
91
  searchMode: {},
92
92
  refetchOnFocus: { type: Boolean },
93
- lazy: { type: Boolean },
93
+ fetchOnFocus: { type: Boolean },
94
+ lazy: { type: [Boolean, String] },
94
95
  addAll: { type: [Boolean, Number] },
95
96
  params: {},
96
97
  searchDelay: {},
@@ -108,7 +109,7 @@ const f = { key: 0 }, C = /* @__PURE__ */ i({
108
109
  (n) => n[a] === o
109
110
  )?.[t] || e.emptyText;
110
111
  });
111
- return (o, t) => o.mode === "read" ? (u(), d("span", f, m(r.value), 1)) : c("", !0);
112
+ return (o, t) => o.mode === "read" ? (u(), c("span", f, m(r.value), 1)) : d("", !0);
112
113
  }
113
114
  });
114
115
  export {
@@ -169,8 +169,8 @@ declare function __VLS_template(): {
169
169
  };
170
170
  type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
171
171
  declare const __VLS_component: DefineComponent<ApFieldSliderProps, {
172
- focus: () => void;
173
172
  blur: () => void;
173
+ focus: () => void;
174
174
  }, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {
175
175
  "update:value": (...args: any[]) => void;
176
176
  }, string, PublicProps, Readonly<ApFieldSliderProps> & Readonly<{
@@ -1,5 +1,8 @@
1
1
  import { ApFieldSwitchProps } from '../interface';
2
- import { DefineComponent, ComponentOptionsMixin, PublicProps, ComponentProvideOptions } from 'vue';
2
+ import { CreateComponentPublicInstanceWithMixins, ExtractPropTypes, PropType, ComponentOptionsMixin, PublicProps, GlobalComponents, GlobalDirectives, ComponentProvideOptions, DefineComponent } from 'vue';
3
+ import { VueTypeDef, VueTypeValidableDef } from '../../../node_modules/vue-types';
4
+ import { FocusEventHandler } from '@aplus-frontend/antdv/es/_util/EventInterface';
5
+ import { VueNode, CustomSlotsType } from '@aplus-frontend/antdv/es/_util/type';
3
6
  type ApFieldSwitchSlots = {
4
7
  checkedChildren: any;
5
8
  unCheckedChildren: any;
@@ -8,11 +11,125 @@ type ApFieldSwitchSlots = {
8
11
  declare function __VLS_template(): {
9
12
  attrs: Partial<{}>;
10
13
  slots: Readonly<ApFieldSwitchSlots> & ApFieldSwitchSlots;
11
- refs: {};
14
+ refs: {
15
+ switchRef: CreateComponentPublicInstanceWithMixins<Readonly< ExtractPropTypes<{
16
+ id: StringConstructor;
17
+ prefixCls: StringConstructor;
18
+ size: VueTypeDef<"default" | "small">;
19
+ disabled: {
20
+ type: BooleanConstructor;
21
+ default: any;
22
+ };
23
+ checkedChildren: VueTypeValidableDef<any>;
24
+ unCheckedChildren: VueTypeValidableDef<any>;
25
+ tabindex: VueTypeDef<string | number>;
26
+ autofocus: {
27
+ type: BooleanConstructor;
28
+ default: any;
29
+ };
30
+ loading: {
31
+ type: BooleanConstructor;
32
+ default: any;
33
+ };
34
+ checked: VueTypeDef<string | number | boolean>;
35
+ checkedValue: VueTypeDef<string | number | boolean> & {
36
+ default: string | number | boolean;
37
+ };
38
+ unCheckedValue: VueTypeDef<string | number | boolean> & {
39
+ default: string | number | boolean;
40
+ };
41
+ onChange: {
42
+ type: PropType<(checked: string | number | boolean, e: Event) => void>;
43
+ };
44
+ onClick: {
45
+ type: PropType<(checked: string | number | boolean, e: Event) => void>;
46
+ };
47
+ onKeydown: {
48
+ type: PropType<(e: Event) => void>;
49
+ };
50
+ onMouseup: {
51
+ type: PropType<(e: Event) => void>;
52
+ };
53
+ 'onUpdate:checked': {
54
+ type: PropType<(checked: string | number | boolean) => void>;
55
+ };
56
+ onBlur: PropType<FocusEventHandler>;
57
+ onFocus: PropType<FocusEventHandler>;
58
+ }>> & Readonly<{}>, () => VueNode, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, PublicProps, {
59
+ disabled: boolean;
60
+ autofocus: boolean;
61
+ loading: boolean;
62
+ checkedValue: string | number | boolean;
63
+ unCheckedValue: string | number | boolean;
64
+ }, true, {}, CustomSlotsType<{
65
+ checkedChildren: any;
66
+ unCheckedChildren: any;
67
+ default: any;
68
+ }>, GlobalComponents, GlobalDirectives, string, {}, any, ComponentProvideOptions, {
69
+ P: {};
70
+ B: {};
71
+ D: {};
72
+ C: {};
73
+ M: {};
74
+ Defaults: {};
75
+ }, Readonly< ExtractPropTypes<{
76
+ id: StringConstructor;
77
+ prefixCls: StringConstructor;
78
+ size: VueTypeDef<"default" | "small">;
79
+ disabled: {
80
+ type: BooleanConstructor;
81
+ default: any;
82
+ };
83
+ checkedChildren: VueTypeValidableDef<any>;
84
+ unCheckedChildren: VueTypeValidableDef<any>;
85
+ tabindex: VueTypeDef<string | number>;
86
+ autofocus: {
87
+ type: BooleanConstructor;
88
+ default: any;
89
+ };
90
+ loading: {
91
+ type: BooleanConstructor;
92
+ default: any;
93
+ };
94
+ checked: VueTypeDef<string | number | boolean>;
95
+ checkedValue: VueTypeDef<string | number | boolean> & {
96
+ default: string | number | boolean;
97
+ };
98
+ unCheckedValue: VueTypeDef<string | number | boolean> & {
99
+ default: string | number | boolean;
100
+ };
101
+ onChange: {
102
+ type: PropType<(checked: string | number | boolean, e: Event) => void>;
103
+ };
104
+ onClick: {
105
+ type: PropType<(checked: string | number | boolean, e: Event) => void>;
106
+ };
107
+ onKeydown: {
108
+ type: PropType<(e: Event) => void>;
109
+ };
110
+ onMouseup: {
111
+ type: PropType<(e: Event) => void>;
112
+ };
113
+ 'onUpdate:checked': {
114
+ type: PropType<(checked: string | number | boolean) => void>;
115
+ };
116
+ onBlur: PropType<FocusEventHandler>;
117
+ onFocus: PropType<FocusEventHandler>;
118
+ }>> & Readonly<{}>, () => VueNode, {}, {}, {}, {
119
+ disabled: boolean;
120
+ autofocus: boolean;
121
+ loading: boolean;
122
+ checkedValue: string | number | boolean;
123
+ unCheckedValue: string | number | boolean;
124
+ }> | null;
125
+ };
12
126
  rootEl: any;
13
127
  };
14
128
  type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
15
- declare const __VLS_component: DefineComponent<ApFieldSwitchProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {
129
+ declare const __VLS_component: DefineComponent<ApFieldSwitchProps, {
130
+ blur: () => void;
131
+ focus: () => void;
132
+ }, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {
16
133
  "update:checked": (...args: any[]) => void;
17
134
  }, string, PublicProps, Readonly<ApFieldSwitchProps> & Readonly<{
18
135
  "onUpdate:checked"?: ((...args: any[]) => any) | undefined;
@@ -23,7 +140,118 @@ declare const __VLS_component: DefineComponent<ApFieldSwitchProps, {}, {}, {}, {
23
140
  emptyText: string;
24
141
  checkedValue: string | number | boolean;
25
142
  unCheckedValue: string | number | boolean;
26
- }, {}, {}, {}, string, ComponentProvideOptions, false, {}, any>;
143
+ }, {}, {}, {}, string, ComponentProvideOptions, false, {
144
+ switchRef: CreateComponentPublicInstanceWithMixins<Readonly< ExtractPropTypes<{
145
+ id: StringConstructor;
146
+ prefixCls: StringConstructor;
147
+ size: VueTypeDef<"default" | "small">;
148
+ disabled: {
149
+ type: BooleanConstructor;
150
+ default: any;
151
+ };
152
+ checkedChildren: VueTypeValidableDef<any>;
153
+ unCheckedChildren: VueTypeValidableDef<any>;
154
+ tabindex: VueTypeDef<string | number>;
155
+ autofocus: {
156
+ type: BooleanConstructor;
157
+ default: any;
158
+ };
159
+ loading: {
160
+ type: BooleanConstructor;
161
+ default: any;
162
+ };
163
+ checked: VueTypeDef<string | number | boolean>;
164
+ checkedValue: VueTypeDef<string | number | boolean> & {
165
+ default: string | number | boolean;
166
+ };
167
+ unCheckedValue: VueTypeDef<string | number | boolean> & {
168
+ default: string | number | boolean;
169
+ };
170
+ onChange: {
171
+ type: PropType<(checked: string | number | boolean, e: Event) => void>;
172
+ };
173
+ onClick: {
174
+ type: PropType<(checked: string | number | boolean, e: Event) => void>;
175
+ };
176
+ onKeydown: {
177
+ type: PropType<(e: Event) => void>;
178
+ };
179
+ onMouseup: {
180
+ type: PropType<(e: Event) => void>;
181
+ };
182
+ 'onUpdate:checked': {
183
+ type: PropType<(checked: string | number | boolean) => void>;
184
+ };
185
+ onBlur: PropType<FocusEventHandler>;
186
+ onFocus: PropType<FocusEventHandler>;
187
+ }>> & Readonly<{}>, () => VueNode, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, PublicProps, {
188
+ disabled: boolean;
189
+ autofocus: boolean;
190
+ loading: boolean;
191
+ checkedValue: string | number | boolean;
192
+ unCheckedValue: string | number | boolean;
193
+ }, true, {}, CustomSlotsType<{
194
+ checkedChildren: any;
195
+ unCheckedChildren: any;
196
+ default: any;
197
+ }>, GlobalComponents, GlobalDirectives, string, {}, any, ComponentProvideOptions, {
198
+ P: {};
199
+ B: {};
200
+ D: {};
201
+ C: {};
202
+ M: {};
203
+ Defaults: {};
204
+ }, Readonly< ExtractPropTypes<{
205
+ id: StringConstructor;
206
+ prefixCls: StringConstructor;
207
+ size: VueTypeDef<"default" | "small">;
208
+ disabled: {
209
+ type: BooleanConstructor;
210
+ default: any;
211
+ };
212
+ checkedChildren: VueTypeValidableDef<any>;
213
+ unCheckedChildren: VueTypeValidableDef<any>;
214
+ tabindex: VueTypeDef<string | number>;
215
+ autofocus: {
216
+ type: BooleanConstructor;
217
+ default: any;
218
+ };
219
+ loading: {
220
+ type: BooleanConstructor;
221
+ default: any;
222
+ };
223
+ checked: VueTypeDef<string | number | boolean>;
224
+ checkedValue: VueTypeDef<string | number | boolean> & {
225
+ default: string | number | boolean;
226
+ };
227
+ unCheckedValue: VueTypeDef<string | number | boolean> & {
228
+ default: string | number | boolean;
229
+ };
230
+ onChange: {
231
+ type: PropType<(checked: string | number | boolean, e: Event) => void>;
232
+ };
233
+ onClick: {
234
+ type: PropType<(checked: string | number | boolean, e: Event) => void>;
235
+ };
236
+ onKeydown: {
237
+ type: PropType<(e: Event) => void>;
238
+ };
239
+ onMouseup: {
240
+ type: PropType<(e: Event) => void>;
241
+ };
242
+ 'onUpdate:checked': {
243
+ type: PropType<(checked: string | number | boolean) => void>;
244
+ };
245
+ onBlur: PropType<FocusEventHandler>;
246
+ onFocus: PropType<FocusEventHandler>;
247
+ }>> & Readonly<{}>, () => VueNode, {}, {}, {}, {
248
+ disabled: boolean;
249
+ autofocus: boolean;
250
+ loading: boolean;
251
+ checkedValue: string | number | boolean;
252
+ unCheckedValue: string | number | boolean;
253
+ }> | null;
254
+ }, any>;
27
255
  declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
28
256
  export default _default;
29
257
  type __VLS_WithTemplateSlots<T, S> = T & {