@aplus-frontend/ui 6.26.4 → 6.27.0

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 (102) hide show
  1. package/es/src/ag-grid/hooks/use-columns-def.d.ts +2 -2
  2. package/es/src/ag-grid/hooks/use-columns-def.mjs +29 -29
  3. package/es/src/ag-grid/hooks/use-columns.d.ts +1 -1
  4. package/es/src/ag-grid/hooks/use-columns.mjs +8 -8
  5. package/es/src/ag-grid/hooks/use-pinned-row.d.ts +7 -0
  6. package/es/src/ag-grid/hooks/use-pinned-row.mjs +32 -0
  7. package/es/src/ag-grid/hooks/use-virtual-config.d.ts +5 -0
  8. package/es/src/ag-grid/hooks/use-virtual-config.mjs +25 -0
  9. package/es/src/ag-grid/index.vue.mjs +274 -232
  10. package/es/src/ag-grid/interface.d.ts +25 -2
  11. package/es/src/ap-field/select/index.vue.d.ts +51 -21
  12. package/es/src/ap-field/select/index.vue.mjs +51 -49
  13. package/es/src/ap-field/select/read.vue2.mjs +4 -1
  14. package/es/src/ap-field/tree-select/index.vue.d.ts +29 -21
  15. package/es/src/ap-field/tree-select/index.vue.mjs +11 -9
  16. package/es/src/ap-field/tree-select/read.vue2.mjs +7 -5
  17. package/es/src/ap-form/ap-form.vue.d.ts +20 -0
  18. package/es/src/ap-form/ap-form.vue2.mjs +11 -10
  19. package/es/src/ap-form/drawer-form/index.vue.d.ts +22 -0
  20. package/es/src/ap-form/drawer-form/index.vue.mjs +1 -0
  21. package/es/src/ap-form/hooks/use-watch.mjs +25 -28
  22. package/es/src/ap-form/interface.d.ts +1 -1
  23. package/es/src/ap-form/items/select/index.vue.d.ts +64 -28
  24. package/es/src/ap-form/items/tree-select/index.vue.d.ts +40 -28
  25. package/es/src/ap-form/modal-form/index.vue.d.ts +22 -0
  26. package/es/src/ap-form/modal-form/index.vue.mjs +31 -30
  27. package/es/src/ap-form/search-form/index.vue.d.ts +24 -2
  28. package/es/src/ap-form/search-form/index.vue.mjs +72 -68
  29. package/es/src/ap-table/constants.d.ts +52 -28
  30. package/es/src/ap-upload/apUpload.vue.d.ts +9 -0
  31. package/es/src/ap-upload/apUpload.vue.mjs +38 -34
  32. package/es/src/ap-upload/components/MultipleFile.vue2.mjs +59 -59
  33. package/es/src/ap-upload/components/Picture.vue2.mjs +74 -74
  34. package/es/src/ap-upload/components/SingleFile.vue2.mjs +95 -95
  35. package/es/src/business/ap-value-select-card/index.vue2.mjs +120 -123
  36. package/es/src/business/ap-view/components/main-button-content.vue.d.ts +11 -0
  37. package/es/src/business/ap-view/components/menu-list-content.vue.d.ts +11 -0
  38. package/es/src/business/hooks/usePageListAgGrid.d.ts +1 -1
  39. package/es/src/business/hooks/usePageListAgGrid.mjs +4 -4
  40. package/es/src/business/hooks/usePageListApGrid.mjs +14 -14
  41. package/es/src/config-provider/config-provider-props.d.ts +14 -1
  42. package/es/src/config-provider/config-provider.d.ts +31 -1
  43. package/es/src/config-provider/hooks/use-global-config.d.ts +14 -1
  44. package/es/src/config-provider/index.d.ts +52 -1
  45. package/es/src/utils/config-provider-preset.d.ts +11 -1
  46. package/es/src/version.d.ts +1 -1
  47. package/es/src/version.mjs +1 -1
  48. package/es/src/work-order-modal/work-order-modal.vue.d.ts +11 -0
  49. package/lib/src/ag-grid/hooks/use-columns-def.d.ts +2 -2
  50. package/lib/src/ag-grid/hooks/use-columns-def.js +1 -1
  51. package/lib/src/ag-grid/hooks/use-columns.d.ts +1 -1
  52. package/lib/src/ag-grid/hooks/use-columns.js +1 -1
  53. package/lib/src/ag-grid/hooks/use-pinned-row.d.ts +7 -0
  54. package/lib/src/ag-grid/hooks/use-pinned-row.js +1 -0
  55. package/lib/src/ag-grid/hooks/use-virtual-config.d.ts +5 -0
  56. package/lib/src/ag-grid/hooks/use-virtual-config.js +1 -0
  57. package/lib/src/ag-grid/index.vue.js +1 -1
  58. package/lib/src/ag-grid/interface.d.ts +25 -2
  59. package/lib/src/ap-field/select/index.vue.d.ts +51 -21
  60. package/lib/src/ap-field/select/index.vue.js +1 -1
  61. package/lib/src/ap-field/select/read.vue2.js +1 -1
  62. package/lib/src/ap-field/tree-select/index.vue.d.ts +29 -21
  63. package/lib/src/ap-field/tree-select/index.vue.js +1 -1
  64. package/lib/src/ap-field/tree-select/read.vue2.js +1 -1
  65. package/lib/src/ap-form/ap-form.vue.d.ts +20 -0
  66. package/lib/src/ap-form/ap-form.vue2.js +1 -1
  67. package/lib/src/ap-form/drawer-form/index.vue.d.ts +22 -0
  68. package/lib/src/ap-form/drawer-form/index.vue.js +1 -1
  69. package/lib/src/ap-form/hooks/use-watch.js +1 -1
  70. package/lib/src/ap-form/interface.d.ts +1 -1
  71. package/lib/src/ap-form/items/select/index.vue.d.ts +64 -28
  72. package/lib/src/ap-form/items/tree-select/index.vue.d.ts +40 -28
  73. package/lib/src/ap-form/modal-form/index.vue.d.ts +22 -0
  74. package/lib/src/ap-form/modal-form/index.vue.js +1 -1
  75. package/lib/src/ap-form/search-form/index.vue.d.ts +24 -2
  76. package/lib/src/ap-form/search-form/index.vue.js +1 -1
  77. package/lib/src/ap-table/constants.d.ts +52 -28
  78. package/lib/src/ap-upload/apUpload.vue.d.ts +9 -0
  79. package/lib/src/ap-upload/apUpload.vue.js +1 -1
  80. package/lib/src/ap-upload/components/MultipleFile.vue2.js +1 -1
  81. package/lib/src/ap-upload/components/Picture.vue2.js +1 -1
  82. package/lib/src/ap-upload/components/SingleFile.vue2.js +1 -1
  83. package/lib/src/business/ap-value-select-card/index.vue2.js +1 -1
  84. package/lib/src/business/ap-view/components/main-button-content.vue.d.ts +11 -0
  85. package/lib/src/business/ap-view/components/menu-list-content.vue.d.ts +11 -0
  86. package/lib/src/business/hooks/usePageListAgGrid.d.ts +1 -1
  87. package/lib/src/business/hooks/usePageListAgGrid.js +1 -1
  88. package/lib/src/business/hooks/usePageListApGrid.js +1 -1
  89. package/lib/src/config-provider/config-provider-props.d.ts +14 -1
  90. package/lib/src/config-provider/config-provider.d.ts +31 -1
  91. package/lib/src/config-provider/hooks/use-global-config.d.ts +14 -1
  92. package/lib/src/config-provider/index.d.ts +52 -1
  93. package/lib/src/utils/config-provider-preset.d.ts +11 -1
  94. package/lib/src/version.d.ts +1 -1
  95. package/lib/src/version.js +1 -1
  96. package/lib/src/work-order-modal/work-order-modal.vue.d.ts +11 -0
  97. package/package.json +3 -3
  98. package/theme/ap-pro-card/index.css +5 -5
  99. package/theme/ap-pro-card/index.less +5 -5
  100. package/theme/ap-value-select-card/index.css +3 -4
  101. package/theme/ap-value-select-card/index.less +3 -4
  102. package/theme/index.css +8 -9
@@ -159,7 +159,9 @@ declare function __VLS_template(): {
159
159
  id: StringConstructor;
160
160
  clearIcon: VueTypeValidableDef<any>;
161
161
  notFoundContent: VueTypeValidableDef<any>;
162
+ maxCount: NumberConstructor;
162
163
  onDeselect: PropType<SelectHandler<unknown, BaseOptionType>>;
164
+ prefix: VueTypeValidableDef<any>;
163
165
  onSearch: {
164
166
  type: PropType<(value: string) => void>;
165
167
  };
@@ -218,10 +220,6 @@ declare function __VLS_template(): {
218
220
  getRawInputElement: {
219
221
  type: PropType<() => any>;
220
222
  };
221
- showArrow: {
222
- type: BooleanConstructor;
223
- default: any;
224
- };
225
223
  onPopupScroll: PropType<(e: UIEvent) => void>;
226
224
  listItemHeight: NumberConstructor;
227
225
  inputValue: StringConstructor;
@@ -233,6 +231,10 @@ declare function __VLS_template(): {
233
231
  type: BooleanConstructor;
234
232
  default: any;
235
233
  };
234
+ showArrow: {
235
+ type: BooleanConstructor;
236
+ default: any;
237
+ };
236
238
  showCheckedStrategy: {
237
239
  type: PropType<CheckedStrategy>;
238
240
  };
@@ -287,9 +289,9 @@ declare function __VLS_template(): {
287
289
  replaceFields: FieldNames;
288
290
  treeCheckable: boolean;
289
291
  showSearch: boolean;
290
- showArrow: boolean;
291
292
  autoClearSearchValue: boolean;
292
293
  labelInValue: boolean;
294
+ showArrow: boolean;
293
295
  treeDefaultExpandAll: boolean;
294
296
  treeLine: boolean | {
295
297
  showLeafIcon: boolean;
@@ -436,7 +438,9 @@ declare function __VLS_template(): {
436
438
  id: StringConstructor;
437
439
  clearIcon: VueTypeValidableDef<any>;
438
440
  notFoundContent: VueTypeValidableDef<any>;
441
+ maxCount: NumberConstructor;
439
442
  onDeselect: PropType<SelectHandler<unknown, BaseOptionType>>;
443
+ prefix: VueTypeValidableDef<any>;
440
444
  onSearch: {
441
445
  type: PropType<(value: string) => void>;
442
446
  };
@@ -495,10 +499,6 @@ declare function __VLS_template(): {
495
499
  getRawInputElement: {
496
500
  type: PropType<() => any>;
497
501
  };
498
- showArrow: {
499
- type: BooleanConstructor;
500
- default: any;
501
- };
502
502
  onPopupScroll: PropType<(e: UIEvent) => void>;
503
503
  listItemHeight: NumberConstructor;
504
504
  inputValue: StringConstructor;
@@ -510,6 +510,10 @@ declare function __VLS_template(): {
510
510
  type: BooleanConstructor;
511
511
  default: any;
512
512
  };
513
+ showArrow: {
514
+ type: BooleanConstructor;
515
+ default: any;
516
+ };
513
517
  showCheckedStrategy: {
514
518
  type: PropType<CheckedStrategy>;
515
519
  };
@@ -564,9 +568,9 @@ declare function __VLS_template(): {
564
568
  replaceFields: FieldNames;
565
569
  treeCheckable: boolean;
566
570
  showSearch: boolean;
567
- showArrow: boolean;
568
571
  autoClearSearchValue: boolean;
569
572
  labelInValue: boolean;
573
+ showArrow: boolean;
570
574
  treeDefaultExpandAll: boolean;
571
575
  treeLine: boolean | {
572
576
  showLeafIcon: boolean;
@@ -600,8 +604,8 @@ declare const __VLS_component: DefineComponent<ApFieldTreeSelectProps, {
600
604
  dropdownMatchSelectWidth: number | boolean;
601
605
  allowClear: boolean;
602
606
  defaultOpen: boolean;
603
- showSearch: boolean;
604
607
  showArrow: boolean;
608
+ showSearch: boolean;
605
609
  autoClearSearchValue: boolean;
606
610
  labelInValue: boolean;
607
611
  treeCheckable: boolean;
@@ -728,7 +732,9 @@ declare const __VLS_component: DefineComponent<ApFieldTreeSelectProps, {
728
732
  id: StringConstructor;
729
733
  clearIcon: VueTypeValidableDef<any>;
730
734
  notFoundContent: VueTypeValidableDef<any>;
735
+ maxCount: NumberConstructor;
731
736
  onDeselect: PropType<SelectHandler<unknown, BaseOptionType>>;
737
+ prefix: VueTypeValidableDef<any>;
732
738
  onSearch: {
733
739
  type: PropType<(value: string) => void>;
734
740
  };
@@ -787,10 +793,6 @@ declare const __VLS_component: DefineComponent<ApFieldTreeSelectProps, {
787
793
  getRawInputElement: {
788
794
  type: PropType<() => any>;
789
795
  };
790
- showArrow: {
791
- type: BooleanConstructor;
792
- default: any;
793
- };
794
796
  onPopupScroll: PropType<(e: UIEvent) => void>;
795
797
  listItemHeight: NumberConstructor;
796
798
  inputValue: StringConstructor;
@@ -802,6 +804,10 @@ declare const __VLS_component: DefineComponent<ApFieldTreeSelectProps, {
802
804
  type: BooleanConstructor;
803
805
  default: any;
804
806
  };
807
+ showArrow: {
808
+ type: BooleanConstructor;
809
+ default: any;
810
+ };
805
811
  showCheckedStrategy: {
806
812
  type: PropType<CheckedStrategy>;
807
813
  };
@@ -856,9 +862,9 @@ declare const __VLS_component: DefineComponent<ApFieldTreeSelectProps, {
856
862
  replaceFields: FieldNames;
857
863
  treeCheckable: boolean;
858
864
  showSearch: boolean;
859
- showArrow: boolean;
860
865
  autoClearSearchValue: boolean;
861
866
  labelInValue: boolean;
867
+ showArrow: boolean;
862
868
  treeDefaultExpandAll: boolean;
863
869
  treeLine: boolean | {
864
870
  showLeafIcon: boolean;
@@ -1005,7 +1011,9 @@ declare const __VLS_component: DefineComponent<ApFieldTreeSelectProps, {
1005
1011
  id: StringConstructor;
1006
1012
  clearIcon: VueTypeValidableDef<any>;
1007
1013
  notFoundContent: VueTypeValidableDef<any>;
1014
+ maxCount: NumberConstructor;
1008
1015
  onDeselect: PropType<SelectHandler<unknown, BaseOptionType>>;
1016
+ prefix: VueTypeValidableDef<any>;
1009
1017
  onSearch: {
1010
1018
  type: PropType<(value: string) => void>;
1011
1019
  };
@@ -1064,10 +1072,6 @@ declare const __VLS_component: DefineComponent<ApFieldTreeSelectProps, {
1064
1072
  getRawInputElement: {
1065
1073
  type: PropType<() => any>;
1066
1074
  };
1067
- showArrow: {
1068
- type: BooleanConstructor;
1069
- default: any;
1070
- };
1071
1075
  onPopupScroll: PropType<(e: UIEvent) => void>;
1072
1076
  listItemHeight: NumberConstructor;
1073
1077
  inputValue: StringConstructor;
@@ -1079,6 +1083,10 @@ declare const __VLS_component: DefineComponent<ApFieldTreeSelectProps, {
1079
1083
  type: BooleanConstructor;
1080
1084
  default: any;
1081
1085
  };
1086
+ showArrow: {
1087
+ type: BooleanConstructor;
1088
+ default: any;
1089
+ };
1082
1090
  showCheckedStrategy: {
1083
1091
  type: PropType<CheckedStrategy>;
1084
1092
  };
@@ -1133,9 +1141,9 @@ declare const __VLS_component: DefineComponent<ApFieldTreeSelectProps, {
1133
1141
  replaceFields: FieldNames;
1134
1142
  treeCheckable: boolean;
1135
1143
  showSearch: boolean;
1136
- showArrow: boolean;
1137
1144
  autoClearSearchValue: boolean;
1138
1145
  labelInValue: boolean;
1146
+ showArrow: boolean;
1139
1147
  treeDefaultExpandAll: boolean;
1140
1148
  treeLine: boolean | {
1141
1149
  showLeafIcon: boolean;
@@ -4,7 +4,7 @@ import "../../hooks/index.mjs";
4
4
  import { isArray as J, omit as Q } from "lodash-unified";
5
5
  import { useRequest as X } from "./use-request.mjs";
6
6
  import { useControllableValue as Y } from "../../hooks/useControllableValue.mjs";
7
- function w(r) {
7
+ function x(r) {
8
8
  return typeof r == "function" || Object.prototype.toString.call(r) === "[object Object]" && !F(r);
9
9
  }
10
10
  const de = /* @__PURE__ */ L({
@@ -92,7 +92,9 @@ const de = /* @__PURE__ */ L({
92
92
  id: {},
93
93
  clearIcon: {},
94
94
  notFoundContent: {},
95
+ maxCount: {},
95
96
  onDeselect: {},
97
+ prefix: {},
96
98
  onSearch: {},
97
99
  fieldNames: {},
98
100
  dropdownStyle: {},
@@ -121,10 +123,6 @@ const de = /* @__PURE__ */ L({
121
123
  onClear: {},
122
124
  onDropdownVisibleChange: {},
123
125
  getRawInputElement: {},
124
- showArrow: {
125
- type: Boolean,
126
- default: void 0
127
- },
128
126
  onPopupScroll: {},
129
127
  listItemHeight: {},
130
128
  inputValue: {},
@@ -136,6 +134,10 @@ const de = /* @__PURE__ */ L({
136
134
  type: Boolean,
137
135
  default: void 0
138
136
  },
137
+ showArrow: {
138
+ type: Boolean,
139
+ default: void 0
140
+ },
139
141
  showCheckedStrategy: {},
140
142
  treeExpandAction: {},
141
143
  treeDefaultExpandAll: {
@@ -171,9 +173,9 @@ const de = /* @__PURE__ */ L({
171
173
  emits: ["update:value"],
172
174
  setup(r, {
173
175
  expose: C,
174
- emit: x
176
+ emit: w
175
177
  }) {
176
- const o = r, N = R(), T = x, p = _(), {
178
+ const o = r, N = R(), T = w, p = _(), {
177
179
  value: f,
178
180
  updateValue: b
179
181
  } = Y(o, T), {
@@ -195,10 +197,10 @@ const de = /* @__PURE__ */ L({
195
197
  }
196
198
  return h(e(c)), n.length ? n.length === 1 ? d("span", null, [n[0]]) : d($, {
197
199
  size: 4
198
- }, w(t = n.map((a, l) => d(H, {
200
+ }, x(t = n.map((a, l) => d(H, {
199
201
  style: "margin-right: 0px",
200
202
  key: `${a}-${l}`
201
- }, w(a) ? a : {
203
+ }, x(a) ? a : {
202
204
  default: () => [a]
203
205
  }))) ? t : {
204
206
  default: () => [t]
@@ -1,4 +1,4 @@
1
- import { isVNode as h, defineComponent as g, computed as B, createVNode as l, Fragment as c, createBlock as w, openBlock as x, resolveDynamicComponent as C } from "vue";
1
+ import { isVNode as h, defineComponent as g, computed as B, createVNode as l, Fragment as c, createBlock as x, openBlock as w, resolveDynamicComponent as C } from "vue";
2
2
  import { isArray as N } from "lodash-unified";
3
3
  import { Space as S, Tag as T } from "@aplus-frontend/antdv";
4
4
  function s(a) {
@@ -78,7 +78,9 @@ const I = /* @__PURE__ */ g({
78
78
  id: {},
79
79
  clearIcon: {},
80
80
  notFoundContent: {},
81
+ maxCount: {},
81
82
  onDeselect: {},
83
+ prefix: {},
82
84
  onSearch: {},
83
85
  fieldNames: {},
84
86
  dropdownStyle: {},
@@ -105,9 +107,6 @@ const I = /* @__PURE__ */ g({
105
107
  onClear: {},
106
108
  onDropdownVisibleChange: {},
107
109
  getRawInputElement: {},
108
- showArrow: {
109
- type: Boolean
110
- },
111
110
  onPopupScroll: {},
112
111
  listItemHeight: {},
113
112
  inputValue: {},
@@ -117,6 +116,9 @@ const I = /* @__PURE__ */ g({
117
116
  labelInValue: {
118
117
  type: Boolean
119
118
  },
119
+ showArrow: {
120
+ type: Boolean
121
+ },
120
122
  showCheckedStrategy: {},
121
123
  treeExpandAction: {},
122
124
  treeDefaultExpandAll: {
@@ -172,7 +174,7 @@ const I = /* @__PURE__ */ g({
172
174
  default: () => [r]
173
175
  }) : l(c, null, [e.emptyText]);
174
176
  });
175
- return (r, p) => (x(), w(C(u.value)));
177
+ return (r, p) => (w(), x(C(u.value)));
176
178
  }
177
179
  });
178
180
  export {
@@ -238,11 +238,16 @@ declare function __VLS_template(): {
238
238
  type: PropType<(name: string | number | string[] | number[], status: boolean, errors: string[]) => void>;
239
239
  default: (name: string | number | string[] | number[], status: boolean, errors: string[]) => void;
240
240
  };
241
+ variant: {
242
+ type: PropType<"filled" | "outlined" | "borderless" | "underlined">;
243
+ default: "filled" | "outlined" | "borderless" | "underlined";
244
+ };
241
245
  }>> & Readonly<{}>, () => VueNode, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, PublicProps, {
242
246
  size: ButtonSize;
243
247
  onSubmit: (e: Event) => void;
244
248
  disabled: boolean;
245
249
  validateTrigger: string | string[];
250
+ variant: "filled" | "outlined" | "borderless" | "underlined";
246
251
  onFinish: (values: any) => void;
247
252
  validateMessages: ValidateMessages;
248
253
  requiredMark: "" | RequiredMark;
@@ -558,11 +563,16 @@ declare function __VLS_template(): {
558
563
  type: PropType<(name: string | number | string[] | number[], status: boolean, errors: string[]) => void>;
559
564
  default: (name: string | number | string[] | number[], status: boolean, errors: string[]) => void;
560
565
  };
566
+ variant: {
567
+ type: PropType<"filled" | "outlined" | "borderless" | "underlined">;
568
+ default: "filled" | "outlined" | "borderless" | "underlined";
569
+ };
561
570
  }>> & Readonly<{}>, () => VueNode, {}, {}, {}, {
562
571
  size: ButtonSize;
563
572
  onSubmit: (e: Event) => void;
564
573
  disabled: boolean;
565
574
  validateTrigger: string | string[];
575
+ variant: "filled" | "outlined" | "borderless" | "underlined";
566
576
  onFinish: (values: any) => void;
567
577
  validateMessages: ValidateMessages;
568
578
  requiredMark: "" | RequiredMark;
@@ -898,11 +908,16 @@ declare const __VLS_component: DefineComponent<ApFormProps, {
898
908
  type: PropType<(name: string | number | string[] | number[], status: boolean, errors: string[]) => void>;
899
909
  default: (name: string | number | string[] | number[], status: boolean, errors: string[]) => void;
900
910
  };
911
+ variant: {
912
+ type: PropType<"filled" | "outlined" | "borderless" | "underlined">;
913
+ default: "filled" | "outlined" | "borderless" | "underlined";
914
+ };
901
915
  }>> & Readonly<{}>, () => VueNode, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, PublicProps, {
902
916
  size: ButtonSize;
903
917
  onSubmit: (e: Event) => void;
904
918
  disabled: boolean;
905
919
  validateTrigger: string | string[];
920
+ variant: "filled" | "outlined" | "borderless" | "underlined";
906
921
  onFinish: (values: any) => void;
907
922
  validateMessages: ValidateMessages;
908
923
  requiredMark: "" | RequiredMark;
@@ -1218,11 +1233,16 @@ declare const __VLS_component: DefineComponent<ApFormProps, {
1218
1233
  type: PropType<(name: string | number | string[] | number[], status: boolean, errors: string[]) => void>;
1219
1234
  default: (name: string | number | string[] | number[], status: boolean, errors: string[]) => void;
1220
1235
  };
1236
+ variant: {
1237
+ type: PropType<"filled" | "outlined" | "borderless" | "underlined">;
1238
+ default: "filled" | "outlined" | "borderless" | "underlined";
1239
+ };
1221
1240
  }>> & Readonly<{}>, () => VueNode, {}, {}, {}, {
1222
1241
  size: ButtonSize;
1223
1242
  onSubmit: (e: Event) => void;
1224
1243
  disabled: boolean;
1225
1244
  validateTrigger: string | string[];
1245
+ variant: "filled" | "outlined" | "borderless" | "underlined";
1226
1246
  onFinish: (values: any) => void;
1227
1247
  validateMessages: ValidateMessages;
1228
1248
  requiredMark: "" | RequiredMark;
@@ -35,6 +35,7 @@ const we = /* @__PURE__ */ z({
35
35
  onFinish: {},
36
36
  onFinishFailed: {},
37
37
  onValidate: {},
38
+ variant: {},
38
39
  initialValues: {},
39
40
  onValuesChange: {},
40
41
  syncToUrl: { type: [Boolean, Function], default: !1 },
@@ -57,8 +58,8 @@ const we = /* @__PURE__ */ z({
57
58
  }
58
59
  y();
59
60
  }
60
- const s = j(), C = me(Fe()), F = Te(), v = j(
61
- n.syncToUrl ? B(n.syncToUrl, C, "get") : {}
61
+ const s = j(), v = me(Fe()), F = Te(), C = j(
62
+ n.syncToUrl ? B(n.syncToUrl, v, "get") : {}
62
63
  );
63
64
  let d = de(_()), g = {};
64
65
  const l = ee(_());
@@ -67,20 +68,20 @@ const we = /* @__PURE__ */ z({
67
68
  const e = n.initialValues || {};
68
69
  return n.syncToUrlPriority ? {
69
70
  ...e,
70
- ...h(v)
71
+ ...h(C)
71
72
  } : {
72
- ...h(v),
73
+ ...h(C),
73
74
  ...e
74
75
  };
75
76
  }
76
77
  function W(e) {
77
78
  const t = m(e, g);
78
- F.triggerFormFinish(n.name, e), n.syncToUrl && A(C, B(n.syncToUrl, t, "set")), n.onFinish?.(t);
79
+ F.triggerFormFinish(n.name, e), n.syncToUrl && A(v, B(n.syncToUrl, t, "set")), n.onFinish?.(t);
79
80
  }
80
81
  const q = async () => {
81
82
  s.value?.resetFields(), await te(() => {
82
83
  Object.keys(l).forEach((e) => delete l[e]), Object.assign(l, d), y(), n.syncToUrl && A(
83
- C,
84
+ v,
84
85
  B(
85
86
  n.syncToUrl,
86
87
  m(d, g),
@@ -106,9 +107,9 @@ const we = /* @__PURE__ */ z({
106
107
  }, I = (e, t, r = !0, o) => {
107
108
  V(e, t, r, o), y();
108
109
  };
109
- function U(e, t) {
110
- return t || e(P(l)), p.push(e), () => {
111
- p = p.filter((r) => r !== e);
110
+ function U(e) {
111
+ return e(P(l)), p.push(e), () => {
112
+ p = p.filter((t) => t !== e);
112
113
  };
113
114
  }
114
115
  function J(e, t) {
@@ -126,7 +127,7 @@ const we = /* @__PURE__ */ z({
126
127
  const r = x(d, t);
127
128
  if (ge(r, e))
128
129
  return;
129
- const o = x(h(v), t);
130
+ const o = x(h(C), t);
130
131
  T(o) && n.syncToUrlPriority || (V(t, e, !1), J(t, e));
131
132
  }
132
133
  function X(e, t) {
@@ -115,6 +115,7 @@ declare function __VLS_template(): {
115
115
  readonly onFinish?: ((values: any) => void) | undefined;
116
116
  readonly onFinishFailed?: ((errorInfo: ValidateErrorEntity<any>) => void) | undefined;
117
117
  readonly onValidate?: ((name: string | number | string[] | number[], status: boolean, errors: string[]) => void) | undefined;
118
+ readonly variant?: "filled" | "outlined" | "borderless" | "underlined" | undefined;
118
119
  readonly initialValues?: Recordable | undefined;
119
120
  readonly onValuesChange?: ((changedValues: Recordable, allValues: Recordable, fieldName: NamePath) => void) | undefined;
120
121
  readonly syncToUrl?: boolean | ((values: Recordable, type: "get" | "set") => Recordable) | undefined;
@@ -349,11 +350,16 @@ declare function __VLS_template(): {
349
350
  type: PropType<(name: string | number | string[] | number[], status: boolean, errors: string[]) => void>;
350
351
  default: (name: string | number | string[] | number[], status: boolean, errors: string[]) => void;
351
352
  };
353
+ variant: {
354
+ type: PropType<"filled" | "outlined" | "borderless" | "underlined">;
355
+ default: "filled" | "outlined" | "borderless" | "underlined";
356
+ };
352
357
  }>> & Readonly<{}>, () => VueNode, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, PublicProps, {
353
358
  size: ButtonSize;
354
359
  onSubmit: (e: Event) => void;
355
360
  disabled: boolean;
356
361
  validateTrigger: string | string[];
362
+ variant: "filled" | "outlined" | "borderless" | "underlined";
357
363
  onFinish: (values: any) => void;
358
364
  validateMessages: ValidateMessages;
359
365
  requiredMark: "" | RequiredMark;
@@ -669,11 +675,16 @@ declare function __VLS_template(): {
669
675
  type: PropType<(name: string | number | string[] | number[], status: boolean, errors: string[]) => void>;
670
676
  default: (name: string | number | string[] | number[], status: boolean, errors: string[]) => void;
671
677
  };
678
+ variant: {
679
+ type: PropType<"filled" | "outlined" | "borderless" | "underlined">;
680
+ default: "filled" | "outlined" | "borderless" | "underlined";
681
+ };
672
682
  }>> & Readonly<{}>, () => VueNode, {}, {}, {}, {
673
683
  size: ButtonSize;
674
684
  onSubmit: (e: Event) => void;
675
685
  disabled: boolean;
676
686
  validateTrigger: string | string[];
687
+ variant: "filled" | "outlined" | "borderless" | "underlined";
677
688
  onFinish: (values: any) => void;
678
689
  validateMessages: ValidateMessages;
679
690
  requiredMark: "" | RequiredMark;
@@ -1063,6 +1074,7 @@ declare const __VLS_component: DefineComponent<ApFormDrawerFormProps, {
1063
1074
  readonly onFinish?: ((values: any) => void) | undefined;
1064
1075
  readonly onFinishFailed?: ((errorInfo: ValidateErrorEntity<any>) => void) | undefined;
1065
1076
  readonly onValidate?: ((name: string | number | string[] | number[], status: boolean, errors: string[]) => void) | undefined;
1077
+ readonly variant?: "filled" | "outlined" | "borderless" | "underlined" | undefined;
1066
1078
  readonly initialValues?: Recordable | undefined;
1067
1079
  readonly onValuesChange?: ((changedValues: Recordable, allValues: Recordable, fieldName: NamePath) => void) | undefined;
1068
1080
  readonly syncToUrl?: boolean | ((values: Recordable, type: "get" | "set") => Recordable) | undefined;
@@ -1297,11 +1309,16 @@ declare const __VLS_component: DefineComponent<ApFormDrawerFormProps, {
1297
1309
  type: PropType<(name: string | number | string[] | number[], status: boolean, errors: string[]) => void>;
1298
1310
  default: (name: string | number | string[] | number[], status: boolean, errors: string[]) => void;
1299
1311
  };
1312
+ variant: {
1313
+ type: PropType<"filled" | "outlined" | "borderless" | "underlined">;
1314
+ default: "filled" | "outlined" | "borderless" | "underlined";
1315
+ };
1300
1316
  }>> & Readonly<{}>, () => VueNode, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, PublicProps, {
1301
1317
  size: ButtonSize;
1302
1318
  onSubmit: (e: Event) => void;
1303
1319
  disabled: boolean;
1304
1320
  validateTrigger: string | string[];
1321
+ variant: "filled" | "outlined" | "borderless" | "underlined";
1305
1322
  onFinish: (values: any) => void;
1306
1323
  validateMessages: ValidateMessages;
1307
1324
  requiredMark: "" | RequiredMark;
@@ -1617,11 +1634,16 @@ declare const __VLS_component: DefineComponent<ApFormDrawerFormProps, {
1617
1634
  type: PropType<(name: string | number | string[] | number[], status: boolean, errors: string[]) => void>;
1618
1635
  default: (name: string | number | string[] | number[], status: boolean, errors: string[]) => void;
1619
1636
  };
1637
+ variant: {
1638
+ type: PropType<"filled" | "outlined" | "borderless" | "underlined">;
1639
+ default: "filled" | "outlined" | "borderless" | "underlined";
1640
+ };
1620
1641
  }>> & Readonly<{}>, () => VueNode, {}, {}, {}, {
1621
1642
  size: ButtonSize;
1622
1643
  onSubmit: (e: Event) => void;
1623
1644
  disabled: boolean;
1624
1645
  validateTrigger: string | string[];
1646
+ variant: "filled" | "outlined" | "borderless" | "underlined";
1625
1647
  onFinish: (values: any) => void;
1626
1648
  validateMessages: ValidateMessages;
1627
1649
  requiredMark: "" | RequiredMark;
@@ -57,6 +57,7 @@ const Le = /* @__PURE__ */ K({
57
57
  onFieldsChange: {},
58
58
  onFinishFailed: {},
59
59
  onValidate: {},
60
+ variant: {},
60
61
  initialValues: {},
61
62
  onValuesChange: {},
62
63
  syncToUrl: {
@@ -1,38 +1,35 @@
1
- import { useInjectForm as I } from "../context.mjs";
2
- import { ref as S, watchEffect as N, unref as c, watch as M } from "vue";
3
- import { INTERNAL_FORM_INSTANCE_MARK as R } from "../constant.mjs";
4
- import { getModelValue as m } from "../utils/get.mjs";
5
- function o(e) {
1
+ import { useInjectForm as h } from "../context.mjs";
2
+ import { ref as w, computed as I, watchEffect as S, unref as c, watch as N } from "vue";
3
+ import { INTERNAL_FORM_INSTANCE_MARK as M } from "../constant.mjs";
4
+ import { getModelValue as v } from "../utils/get.mjs";
5
+ function o(t) {
6
6
  try {
7
- return JSON.stringify(e);
7
+ return JSON.stringify(t);
8
8
  } catch {
9
9
  return Math.random();
10
10
  }
11
11
  }
12
- function x(e, n, v) {
13
- const { internalInstance: d, model: g } = I(), u = v?.initialValue || n?.initialValue || void 0, l = S(u);
14
- let a = o(u), s = !0;
15
- const h = n && "value" in n ? n : void 0;
16
- return N((i) => {
17
- const t = h?.value?.getInternalInstance(R) || d;
18
- if (!t) {
19
- s = !1;
12
+ function _(t, e, V) {
13
+ const { internalInstance: d, model: g } = h(), i = V?.initialValue || e?.initialValue || void 0, u = w(i);
14
+ let n = o(i);
15
+ const f = I(() => (e && "value" in e ? e : void 0)?.value?.getInternalInstance(M) || d);
16
+ return S((a) => {
17
+ if (!f.value)
20
18
  return;
19
+ const r = f.value.registerWatch((l) => {
20
+ const s = v(l, c(t)), m = o(s);
21
+ m !== n && (u.value = s, n = m);
22
+ });
23
+ a(r);
24
+ }), N(
25
+ () => c(t),
26
+ (a) => {
27
+ const r = v(c(g), a), l = o(r);
28
+ l !== n && (u.value = r, n = l);
21
29
  }
22
- const r = t.registerWatch((w) => {
23
- const f = m(w, c(e)), V = o(f);
24
- V !== a && (l.value = f, a = V);
25
- }, s);
26
- i(r);
27
- }), M(
28
- () => c(e),
29
- (i) => {
30
- const t = m(c(g), i), r = o(t);
31
- r !== a && (l.value = t, a = r);
32
- }
33
- ), l;
30
+ ), u;
34
31
  }
35
32
  export {
36
- x as default,
37
- x as useWatch
33
+ _ as default,
34
+ _ as useWatch
38
35
  };
@@ -114,7 +114,7 @@ export type ApFormInternalInstance = {
114
114
  * @param inner
115
115
  * @returns
116
116
  */
117
- registerWatch: (callback: WatchFunc, inner: boolean) => () => void;
117
+ registerWatch: (callback: WatchFunc, inner?: boolean) => () => void;
118
118
  /**
119
119
  * 注册表单项
120
120
  * @param field