@tmagic/form 1.5.0-beta.12 → 1.5.0-beta.13
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.
- package/dist/tmagic-form.js +21 -8
- package/dist/tmagic-form.umd.cjs +21 -8
- package/package.json +3 -3
- package/src/Form.vue +9 -1
- package/src/FormBox.vue +2 -0
- package/src/FormDialog.vue +2 -0
- package/src/FormDrawer.vue +2 -0
- package/types/index.d.ts +35 -0
package/dist/tmagic-form.js
CHANGED
|
@@ -2821,6 +2821,7 @@ const _sfc_main$d = /* @__PURE__ */ defineComponent({
|
|
|
2821
2821
|
labelPosition: { default: "right" },
|
|
2822
2822
|
keyProp: { default: "__key" },
|
|
2823
2823
|
popperClass: {},
|
|
2824
|
+
preventSubmitDefault: { type: Boolean },
|
|
2824
2825
|
extendState: {}
|
|
2825
2826
|
},
|
|
2826
2827
|
emits: ["change", "error", "field-input", "field-change"],
|
|
@@ -2851,8 +2852,8 @@ const _sfc_main$d = /* @__PURE__ */ defineComponent({
|
|
|
2851
2852
|
post: (options) => {
|
|
2852
2853
|
if (requestFuc) {
|
|
2853
2854
|
return requestFuc({
|
|
2854
|
-
|
|
2855
|
-
|
|
2855
|
+
method: "POST",
|
|
2856
|
+
...options
|
|
2856
2857
|
});
|
|
2857
2858
|
}
|
|
2858
2859
|
}
|
|
@@ -2901,6 +2902,11 @@ const _sfc_main$d = /* @__PURE__ */ defineComponent({
|
|
|
2901
2902
|
const changeHandler = () => {
|
|
2902
2903
|
emit("change", values.value);
|
|
2903
2904
|
};
|
|
2905
|
+
const submitHandler = (e) => {
|
|
2906
|
+
if (props.preventSubmitDefault) {
|
|
2907
|
+
e.preventDefault();
|
|
2908
|
+
}
|
|
2909
|
+
};
|
|
2904
2910
|
__expose({
|
|
2905
2911
|
values,
|
|
2906
2912
|
lastValuesProcessed,
|
|
@@ -2935,7 +2941,8 @@ const _sfc_main$d = /* @__PURE__ */ defineComponent({
|
|
|
2935
2941
|
"label-width": _ctx.labelWidth,
|
|
2936
2942
|
style: normalizeStyle(`height: ${_ctx.height}`),
|
|
2937
2943
|
inline: _ctx.inline,
|
|
2938
|
-
"label-position": _ctx.labelPosition
|
|
2944
|
+
"label-position": _ctx.labelPosition,
|
|
2945
|
+
onSubmit: submitHandler
|
|
2939
2946
|
}, {
|
|
2940
2947
|
default: withCtx(() => [
|
|
2941
2948
|
initialized.value && Array.isArray(_ctx.config) ? (openBlock(true), createElementBlock(Fragment, { key: 0 }, renderList(_ctx.config, (item, index) => {
|
|
@@ -2978,7 +2985,8 @@ const _sfc_main$c = /* @__PURE__ */ defineComponent({
|
|
|
2978
2985
|
labelPosition: {},
|
|
2979
2986
|
zIndex: {},
|
|
2980
2987
|
size: {},
|
|
2981
|
-
confirmText: { default: "确定" }
|
|
2988
|
+
confirmText: { default: "确定" },
|
|
2989
|
+
preventSubmitDefault: { type: Boolean }
|
|
2982
2990
|
},
|
|
2983
2991
|
emits: ["close", "submit", "error", "change"],
|
|
2984
2992
|
setup(__props, { expose: __expose, emit: __emit }) {
|
|
@@ -3147,8 +3155,9 @@ const _sfc_main$c = /* @__PURE__ */ defineComponent({
|
|
|
3147
3155
|
"label-width": _ctx.labelWidth,
|
|
3148
3156
|
"label-position": _ctx.labelPosition,
|
|
3149
3157
|
inline: _ctx.inline,
|
|
3158
|
+
"prevent-submit-default": _ctx.preventSubmitDefault,
|
|
3150
3159
|
onChange: changeHandler
|
|
3151
|
-
}, null, 8, ["modelValue", "size", "disabled", "config", "init-values", "parent-values", "label-width", "label-position", "inline"]),
|
|
3160
|
+
}, null, 8, ["modelValue", "size", "disabled", "config", "init-values", "parent-values", "label-width", "label-position", "inline", "prevent-submit-default"]),
|
|
3152
3161
|
renderSlot(_ctx.$slots, "default")
|
|
3153
3162
|
], 4)) : createCommentVNode("", true)
|
|
3154
3163
|
]),
|
|
@@ -4240,6 +4249,7 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
4240
4249
|
confirmText: { default: "确定" },
|
|
4241
4250
|
inline: { type: Boolean },
|
|
4242
4251
|
labelPosition: {},
|
|
4252
|
+
preventSubmitDefault: { type: Boolean },
|
|
4243
4253
|
beforeClose: {}
|
|
4244
4254
|
},
|
|
4245
4255
|
emits: ["close", "closed", "submit", "error", "change", "open", "opened"],
|
|
@@ -4376,8 +4386,9 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
4376
4386
|
"label-width": _ctx.labelWidth,
|
|
4377
4387
|
"label-position": _ctx.labelPosition,
|
|
4378
4388
|
inline: _ctx.inline,
|
|
4389
|
+
"prevent-submit-default": _ctx.preventSubmitDefault,
|
|
4379
4390
|
onChange: changeHandler
|
|
4380
|
-
}, null, 8, ["size", "disabled", "config", "init-values", "parent-values", "label-width", "label-position", "inline"]),
|
|
4391
|
+
}, null, 8, ["size", "disabled", "config", "init-values", "parent-values", "label-width", "label-position", "inline", "prevent-submit-default"]),
|
|
4381
4392
|
renderSlot(_ctx.$slots, "default")
|
|
4382
4393
|
], 512)) : createCommentVNode("", true)
|
|
4383
4394
|
]),
|
|
@@ -4404,7 +4415,8 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
4404
4415
|
size: {},
|
|
4405
4416
|
confirmText: { default: "确定" },
|
|
4406
4417
|
inline: { type: Boolean },
|
|
4407
|
-
labelPosition: {}
|
|
4418
|
+
labelPosition: {},
|
|
4419
|
+
preventSubmitDefault: { type: Boolean }
|
|
4408
4420
|
},
|
|
4409
4421
|
emits: ["submit", "change", "error"],
|
|
4410
4422
|
setup(__props, { expose: __expose, emit: __emit }) {
|
|
@@ -4472,8 +4484,9 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
4472
4484
|
"label-width": _ctx.labelWidth,
|
|
4473
4485
|
"label-position": _ctx.labelPosition,
|
|
4474
4486
|
inline: _ctx.inline,
|
|
4487
|
+
"prevent-submit-default": _ctx.preventSubmitDefault,
|
|
4475
4488
|
onChange: changeHandler
|
|
4476
|
-
}, null, 8, ["size", "disabled", "config", "init-values", "parent-values", "label-width", "label-position", "inline"]),
|
|
4489
|
+
}, null, 8, ["size", "disabled", "config", "init-values", "parent-values", "label-width", "label-position", "inline", "prevent-submit-default"]),
|
|
4477
4490
|
renderSlot(_ctx.$slots, "default")
|
|
4478
4491
|
]),
|
|
4479
4492
|
_: 3
|
package/dist/tmagic-form.umd.cjs
CHANGED
|
@@ -2818,6 +2818,7 @@
|
|
|
2818
2818
|
labelPosition: { default: "right" },
|
|
2819
2819
|
keyProp: { default: "__key" },
|
|
2820
2820
|
popperClass: {},
|
|
2821
|
+
preventSubmitDefault: { type: Boolean },
|
|
2821
2822
|
extendState: {}
|
|
2822
2823
|
},
|
|
2823
2824
|
emits: ["change", "error", "field-input", "field-change"],
|
|
@@ -2848,8 +2849,8 @@
|
|
|
2848
2849
|
post: (options) => {
|
|
2849
2850
|
if (requestFuc) {
|
|
2850
2851
|
return requestFuc({
|
|
2851
|
-
|
|
2852
|
-
|
|
2852
|
+
method: "POST",
|
|
2853
|
+
...options
|
|
2853
2854
|
});
|
|
2854
2855
|
}
|
|
2855
2856
|
}
|
|
@@ -2898,6 +2899,11 @@
|
|
|
2898
2899
|
const changeHandler = () => {
|
|
2899
2900
|
emit("change", values.value);
|
|
2900
2901
|
};
|
|
2902
|
+
const submitHandler = (e) => {
|
|
2903
|
+
if (props.preventSubmitDefault) {
|
|
2904
|
+
e.preventDefault();
|
|
2905
|
+
}
|
|
2906
|
+
};
|
|
2901
2907
|
__expose({
|
|
2902
2908
|
values,
|
|
2903
2909
|
lastValuesProcessed,
|
|
@@ -2932,7 +2938,8 @@
|
|
|
2932
2938
|
"label-width": _ctx.labelWidth,
|
|
2933
2939
|
style: vue.normalizeStyle(`height: ${_ctx.height}`),
|
|
2934
2940
|
inline: _ctx.inline,
|
|
2935
|
-
"label-position": _ctx.labelPosition
|
|
2941
|
+
"label-position": _ctx.labelPosition,
|
|
2942
|
+
onSubmit: submitHandler
|
|
2936
2943
|
}, {
|
|
2937
2944
|
default: vue.withCtx(() => [
|
|
2938
2945
|
initialized.value && Array.isArray(_ctx.config) ? (vue.openBlock(true), vue.createElementBlock(vue.Fragment, { key: 0 }, vue.renderList(_ctx.config, (item, index) => {
|
|
@@ -2975,7 +2982,8 @@
|
|
|
2975
2982
|
labelPosition: {},
|
|
2976
2983
|
zIndex: {},
|
|
2977
2984
|
size: {},
|
|
2978
|
-
confirmText: { default: "确定" }
|
|
2985
|
+
confirmText: { default: "确定" },
|
|
2986
|
+
preventSubmitDefault: { type: Boolean }
|
|
2979
2987
|
},
|
|
2980
2988
|
emits: ["close", "submit", "error", "change"],
|
|
2981
2989
|
setup(__props, { expose: __expose, emit: __emit }) {
|
|
@@ -3144,8 +3152,9 @@
|
|
|
3144
3152
|
"label-width": _ctx.labelWidth,
|
|
3145
3153
|
"label-position": _ctx.labelPosition,
|
|
3146
3154
|
inline: _ctx.inline,
|
|
3155
|
+
"prevent-submit-default": _ctx.preventSubmitDefault,
|
|
3147
3156
|
onChange: changeHandler
|
|
3148
|
-
}, null, 8, ["modelValue", "size", "disabled", "config", "init-values", "parent-values", "label-width", "label-position", "inline"]),
|
|
3157
|
+
}, null, 8, ["modelValue", "size", "disabled", "config", "init-values", "parent-values", "label-width", "label-position", "inline", "prevent-submit-default"]),
|
|
3149
3158
|
vue.renderSlot(_ctx.$slots, "default")
|
|
3150
3159
|
], 4)) : vue.createCommentVNode("", true)
|
|
3151
3160
|
]),
|
|
@@ -4237,6 +4246,7 @@
|
|
|
4237
4246
|
confirmText: { default: "确定" },
|
|
4238
4247
|
inline: { type: Boolean },
|
|
4239
4248
|
labelPosition: {},
|
|
4249
|
+
preventSubmitDefault: { type: Boolean },
|
|
4240
4250
|
beforeClose: {}
|
|
4241
4251
|
},
|
|
4242
4252
|
emits: ["close", "closed", "submit", "error", "change", "open", "opened"],
|
|
@@ -4373,8 +4383,9 @@
|
|
|
4373
4383
|
"label-width": _ctx.labelWidth,
|
|
4374
4384
|
"label-position": _ctx.labelPosition,
|
|
4375
4385
|
inline: _ctx.inline,
|
|
4386
|
+
"prevent-submit-default": _ctx.preventSubmitDefault,
|
|
4376
4387
|
onChange: changeHandler
|
|
4377
|
-
}, null, 8, ["size", "disabled", "config", "init-values", "parent-values", "label-width", "label-position", "inline"]),
|
|
4388
|
+
}, null, 8, ["size", "disabled", "config", "init-values", "parent-values", "label-width", "label-position", "inline", "prevent-submit-default"]),
|
|
4378
4389
|
vue.renderSlot(_ctx.$slots, "default")
|
|
4379
4390
|
], 512)) : vue.createCommentVNode("", true)
|
|
4380
4391
|
]),
|
|
@@ -4401,7 +4412,8 @@
|
|
|
4401
4412
|
size: {},
|
|
4402
4413
|
confirmText: { default: "确定" },
|
|
4403
4414
|
inline: { type: Boolean },
|
|
4404
|
-
labelPosition: {}
|
|
4415
|
+
labelPosition: {},
|
|
4416
|
+
preventSubmitDefault: { type: Boolean }
|
|
4405
4417
|
},
|
|
4406
4418
|
emits: ["submit", "change", "error"],
|
|
4407
4419
|
setup(__props, { expose: __expose, emit: __emit }) {
|
|
@@ -4469,8 +4481,9 @@
|
|
|
4469
4481
|
"label-width": _ctx.labelWidth,
|
|
4470
4482
|
"label-position": _ctx.labelPosition,
|
|
4471
4483
|
inline: _ctx.inline,
|
|
4484
|
+
"prevent-submit-default": _ctx.preventSubmitDefault,
|
|
4472
4485
|
onChange: changeHandler
|
|
4473
|
-
}, null, 8, ["size", "disabled", "config", "init-values", "parent-values", "label-width", "label-position", "inline"]),
|
|
4486
|
+
}, null, 8, ["size", "disabled", "config", "init-values", "parent-values", "label-width", "label-position", "inline", "prevent-submit-default"]),
|
|
4474
4487
|
vue.renderSlot(_ctx.$slots, "default")
|
|
4475
4488
|
]),
|
|
4476
4489
|
_: 3
|
package/package.json
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
{
|
|
2
|
-
"version": "1.5.0-beta.
|
|
2
|
+
"version": "1.5.0-beta.13",
|
|
3
3
|
"name": "@tmagic/form",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"sideEffects": [
|
|
@@ -55,8 +55,8 @@
|
|
|
55
55
|
"peerDependencies": {
|
|
56
56
|
"vue": "^3.5.0",
|
|
57
57
|
"typescript": "*",
|
|
58
|
-
"@tmagic/design": "1.5.0-beta.
|
|
59
|
-
"@tmagic/utils": "1.5.0-beta.
|
|
58
|
+
"@tmagic/design": "1.5.0-beta.13",
|
|
59
|
+
"@tmagic/utils": "1.5.0-beta.13"
|
|
60
60
|
},
|
|
61
61
|
"peerDependenciesMeta": {
|
|
62
62
|
"typescript": {
|
package/src/Form.vue
CHANGED
|
@@ -7,6 +7,7 @@
|
|
|
7
7
|
:style="`height: ${height}`"
|
|
8
8
|
:inline="inline"
|
|
9
9
|
:label-position="labelPosition"
|
|
10
|
+
@submit="submitHandler"
|
|
10
11
|
>
|
|
11
12
|
<template v-if="initialized && Array.isArray(config)">
|
|
12
13
|
<Container
|
|
@@ -61,6 +62,7 @@ const props = withDefaults(
|
|
|
61
62
|
labelPosition?: string;
|
|
62
63
|
keyProp?: string;
|
|
63
64
|
popperClass?: string;
|
|
65
|
+
preventSubmitDefault?: boolean;
|
|
64
66
|
extendState?: (state: FormState) => Record<string, any> | Promise<Record<string, any>>;
|
|
65
67
|
}>(),
|
|
66
68
|
{
|
|
@@ -107,8 +109,8 @@ const formState: FormState = reactive<FormState>({
|
|
|
107
109
|
post: (options: any) => {
|
|
108
110
|
if (requestFuc) {
|
|
109
111
|
return requestFuc({
|
|
110
|
-
...options,
|
|
111
112
|
method: 'POST',
|
|
113
|
+
...options,
|
|
112
114
|
});
|
|
113
115
|
}
|
|
114
116
|
},
|
|
@@ -167,6 +169,12 @@ const changeHandler = () => {
|
|
|
167
169
|
emit('change', values.value);
|
|
168
170
|
};
|
|
169
171
|
|
|
172
|
+
const submitHandler = (e: SubmitEvent) => {
|
|
173
|
+
if (props.preventSubmitDefault) {
|
|
174
|
+
e.preventDefault();
|
|
175
|
+
}
|
|
176
|
+
};
|
|
177
|
+
|
|
170
178
|
defineExpose({
|
|
171
179
|
values,
|
|
172
180
|
lastValuesProcessed,
|
package/src/FormBox.vue
CHANGED
|
@@ -12,6 +12,7 @@
|
|
|
12
12
|
:label-width="labelWidth"
|
|
13
13
|
:label-position="labelPosition"
|
|
14
14
|
:inline="inline"
|
|
15
|
+
:prevent-submit-default="preventSubmitDefault"
|
|
15
16
|
@change="changeHandler"
|
|
16
17
|
></Form>
|
|
17
18
|
<slot></slot>
|
|
@@ -58,6 +59,7 @@ const props = withDefaults(
|
|
|
58
59
|
confirmText?: string;
|
|
59
60
|
inline?: boolean;
|
|
60
61
|
labelPosition?: string;
|
|
62
|
+
preventSubmitDefault?: boolean;
|
|
61
63
|
}>(),
|
|
62
64
|
{
|
|
63
65
|
config: () => [],
|
package/src/FormDialog.vue
CHANGED
|
@@ -27,6 +27,7 @@
|
|
|
27
27
|
:label-width="labelWidth"
|
|
28
28
|
:label-position="labelPosition"
|
|
29
29
|
:inline="inline"
|
|
30
|
+
:prevent-submit-default="preventSubmitDefault"
|
|
30
31
|
@change="changeHandler"
|
|
31
32
|
></Form>
|
|
32
33
|
<slot></slot>
|
|
@@ -85,6 +86,7 @@ const props = withDefaults(
|
|
|
85
86
|
zIndex?: number;
|
|
86
87
|
size?: 'small' | 'default' | 'large';
|
|
87
88
|
confirmText?: string;
|
|
89
|
+
preventSubmitDefault?: boolean;
|
|
88
90
|
}>(),
|
|
89
91
|
{
|
|
90
92
|
config: () => [],
|
package/src/FormDrawer.vue
CHANGED
|
@@ -27,6 +27,7 @@
|
|
|
27
27
|
:label-width="labelWidth"
|
|
28
28
|
:label-position="labelPosition"
|
|
29
29
|
:inline="inline"
|
|
30
|
+
:prevent-submit-default="preventSubmitDefault"
|
|
30
31
|
@change="changeHandler"
|
|
31
32
|
></Form>
|
|
32
33
|
<slot></slot>
|
|
@@ -79,6 +80,7 @@ withDefaults(
|
|
|
79
80
|
confirmText?: string;
|
|
80
81
|
inline?: boolean;
|
|
81
82
|
labelPosition?: string;
|
|
83
|
+
preventSubmitDefault?: boolean;
|
|
82
84
|
/** 关闭前的回调,会暂停 Drawer 的关闭; done 是个 function type 接受一个 boolean 参数, 执行 done 使用 true 参数或不提供参数将会终止关闭 */
|
|
83
85
|
beforeClose?: (done: (cancel?: boolean) => void) => void;
|
|
84
86
|
}>(),
|
package/types/index.d.ts
CHANGED
|
@@ -642,6 +642,7 @@ declare const _default$v: vue.DefineComponent<{
|
|
|
642
642
|
labelPosition?: string;
|
|
643
643
|
keyProp?: string;
|
|
644
644
|
popperClass?: string;
|
|
645
|
+
preventSubmitDefault?: boolean;
|
|
645
646
|
extendState?: (state: FormState) => Record<string, any> | Promise<Record<string, any>>;
|
|
646
647
|
}, {
|
|
647
648
|
values: vue.Ref<FormValue, FormValue>;
|
|
@@ -675,6 +676,7 @@ declare const _default$v: vue.DefineComponent<{
|
|
|
675
676
|
labelPosition?: string;
|
|
676
677
|
keyProp?: string;
|
|
677
678
|
popperClass?: string;
|
|
679
|
+
preventSubmitDefault?: boolean;
|
|
678
680
|
extendState?: (state: FormState) => Record<string, any> | Promise<Record<string, any>>;
|
|
679
681
|
}> & Readonly<{
|
|
680
682
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
@@ -718,6 +720,7 @@ declare function __VLS_template$4(): {
|
|
|
718
720
|
labelPosition?: string;
|
|
719
721
|
keyProp?: string;
|
|
720
722
|
popperClass?: string;
|
|
723
|
+
preventSubmitDefault?: boolean;
|
|
721
724
|
extendState?: (state: FormState) => Record<string, any> | Promise<Record<string, any>>;
|
|
722
725
|
}> & Readonly<{
|
|
723
726
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
@@ -752,6 +755,7 @@ declare function __VLS_template$4(): {
|
|
|
752
755
|
labelPosition?: string;
|
|
753
756
|
keyProp?: string;
|
|
754
757
|
popperClass?: string;
|
|
758
|
+
preventSubmitDefault?: boolean;
|
|
755
759
|
extendState?: (state: FormState) => Record<string, any> | Promise<Record<string, any>>;
|
|
756
760
|
}> & Readonly<{
|
|
757
761
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
@@ -793,6 +797,7 @@ declare function __VLS_template$4(): {
|
|
|
793
797
|
labelPosition?: string;
|
|
794
798
|
keyProp?: string;
|
|
795
799
|
popperClass?: string;
|
|
800
|
+
preventSubmitDefault?: boolean;
|
|
796
801
|
extendState?: (state: FormState) => Record<string, any> | Promise<Record<string, any>>;
|
|
797
802
|
}> & Readonly<{
|
|
798
803
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
@@ -839,6 +844,7 @@ declare const __VLS_component$4: vue.DefineComponent<{
|
|
|
839
844
|
zIndex?: number;
|
|
840
845
|
size?: "small" | "default" | "large";
|
|
841
846
|
confirmText?: string;
|
|
847
|
+
preventSubmitDefault?: boolean;
|
|
842
848
|
}, {
|
|
843
849
|
form: vue.Ref<vue.CreateComponentPublicInstanceWithMixins<Readonly<{
|
|
844
850
|
config: FormConfig;
|
|
@@ -855,6 +861,7 @@ declare const __VLS_component$4: vue.DefineComponent<{
|
|
|
855
861
|
labelPosition?: string;
|
|
856
862
|
keyProp?: string;
|
|
857
863
|
popperClass?: string;
|
|
864
|
+
preventSubmitDefault?: boolean;
|
|
858
865
|
extendState?: (state: FormState) => Record<string, any> | Promise<Record<string, any>>;
|
|
859
866
|
}> & Readonly<{
|
|
860
867
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
@@ -889,6 +896,7 @@ declare const __VLS_component$4: vue.DefineComponent<{
|
|
|
889
896
|
labelPosition?: string;
|
|
890
897
|
keyProp?: string;
|
|
891
898
|
popperClass?: string;
|
|
899
|
+
preventSubmitDefault?: boolean;
|
|
892
900
|
extendState?: (state: FormState) => Record<string, any> | Promise<Record<string, any>>;
|
|
893
901
|
}> & Readonly<{
|
|
894
902
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
@@ -930,6 +938,7 @@ declare const __VLS_component$4: vue.DefineComponent<{
|
|
|
930
938
|
labelPosition?: string;
|
|
931
939
|
keyProp?: string;
|
|
932
940
|
popperClass?: string;
|
|
941
|
+
preventSubmitDefault?: boolean;
|
|
933
942
|
extendState?: (state: FormState) => Record<string, any> | Promise<Record<string, any>>;
|
|
934
943
|
}> & Readonly<{
|
|
935
944
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
@@ -972,6 +981,7 @@ declare const __VLS_component$4: vue.DefineComponent<{
|
|
|
972
981
|
labelPosition?: string;
|
|
973
982
|
keyProp?: string;
|
|
974
983
|
popperClass?: string;
|
|
984
|
+
preventSubmitDefault?: boolean;
|
|
975
985
|
extendState?: (state: FormState) => Record<string, any> | Promise<Record<string, any>>;
|
|
976
986
|
}> & Readonly<{
|
|
977
987
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
@@ -1006,6 +1016,7 @@ declare const __VLS_component$4: vue.DefineComponent<{
|
|
|
1006
1016
|
labelPosition?: string;
|
|
1007
1017
|
keyProp?: string;
|
|
1008
1018
|
popperClass?: string;
|
|
1019
|
+
preventSubmitDefault?: boolean;
|
|
1009
1020
|
extendState?: (state: FormState) => Record<string, any> | Promise<Record<string, any>>;
|
|
1010
1021
|
}> & Readonly<{
|
|
1011
1022
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
@@ -1047,6 +1058,7 @@ declare const __VLS_component$4: vue.DefineComponent<{
|
|
|
1047
1058
|
labelPosition?: string;
|
|
1048
1059
|
keyProp?: string;
|
|
1049
1060
|
popperClass?: string;
|
|
1061
|
+
preventSubmitDefault?: boolean;
|
|
1050
1062
|
extendState?: (state: FormState) => Record<string, any> | Promise<Record<string, any>>;
|
|
1051
1063
|
}> & Readonly<{
|
|
1052
1064
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
@@ -1100,6 +1112,7 @@ declare const __VLS_component$4: vue.DefineComponent<{
|
|
|
1100
1112
|
zIndex?: number;
|
|
1101
1113
|
size?: "small" | "default" | "large";
|
|
1102
1114
|
confirmText?: string;
|
|
1115
|
+
preventSubmitDefault?: boolean;
|
|
1103
1116
|
}> & Readonly<{
|
|
1104
1117
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
1105
1118
|
onClose?: ((...args: any[]) => any) | undefined;
|
|
@@ -1229,6 +1242,7 @@ declare function __VLS_template$3(): {
|
|
|
1229
1242
|
labelPosition?: string;
|
|
1230
1243
|
keyProp?: string;
|
|
1231
1244
|
popperClass?: string;
|
|
1245
|
+
preventSubmitDefault?: boolean;
|
|
1232
1246
|
extendState?: (state: FormState) => Record<string, any> | Promise<Record<string, any>>;
|
|
1233
1247
|
}> & Readonly<{
|
|
1234
1248
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
@@ -1263,6 +1277,7 @@ declare function __VLS_template$3(): {
|
|
|
1263
1277
|
labelPosition?: string;
|
|
1264
1278
|
keyProp?: string;
|
|
1265
1279
|
popperClass?: string;
|
|
1280
|
+
preventSubmitDefault?: boolean;
|
|
1266
1281
|
extendState?: (state: FormState) => Record<string, any> | Promise<Record<string, any>>;
|
|
1267
1282
|
}> & Readonly<{
|
|
1268
1283
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
@@ -1304,6 +1319,7 @@ declare function __VLS_template$3(): {
|
|
|
1304
1319
|
labelPosition?: string;
|
|
1305
1320
|
keyProp?: string;
|
|
1306
1321
|
popperClass?: string;
|
|
1322
|
+
preventSubmitDefault?: boolean;
|
|
1307
1323
|
extendState?: (state: FormState) => Record<string, any> | Promise<Record<string, any>>;
|
|
1308
1324
|
}> & Readonly<{
|
|
1309
1325
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
@@ -1350,6 +1366,7 @@ declare const __VLS_component$3: vue.DefineComponent<{
|
|
|
1350
1366
|
confirmText?: string;
|
|
1351
1367
|
inline?: boolean;
|
|
1352
1368
|
labelPosition?: string;
|
|
1369
|
+
preventSubmitDefault?: boolean;
|
|
1353
1370
|
/** 关闭前的回调,会暂停 Drawer 的关闭; done 是个 function type 接受一个 boolean 参数, 执行 done 使用 true 参数或不提供参数将会终止关闭 */
|
|
1354
1371
|
beforeClose?: (done: (cancel?: boolean) => void) => void;
|
|
1355
1372
|
}, {
|
|
@@ -1368,6 +1385,7 @@ declare const __VLS_component$3: vue.DefineComponent<{
|
|
|
1368
1385
|
labelPosition?: string;
|
|
1369
1386
|
keyProp?: string;
|
|
1370
1387
|
popperClass?: string;
|
|
1388
|
+
preventSubmitDefault?: boolean;
|
|
1371
1389
|
extendState?: (state: FormState) => Record<string, any> | Promise<Record<string, any>>;
|
|
1372
1390
|
}> & Readonly<{
|
|
1373
1391
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
@@ -1402,6 +1420,7 @@ declare const __VLS_component$3: vue.DefineComponent<{
|
|
|
1402
1420
|
labelPosition?: string;
|
|
1403
1421
|
keyProp?: string;
|
|
1404
1422
|
popperClass?: string;
|
|
1423
|
+
preventSubmitDefault?: boolean;
|
|
1405
1424
|
extendState?: (state: FormState) => Record<string, any> | Promise<Record<string, any>>;
|
|
1406
1425
|
}> & Readonly<{
|
|
1407
1426
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
@@ -1443,6 +1462,7 @@ declare const __VLS_component$3: vue.DefineComponent<{
|
|
|
1443
1462
|
labelPosition?: string;
|
|
1444
1463
|
keyProp?: string;
|
|
1445
1464
|
popperClass?: string;
|
|
1465
|
+
preventSubmitDefault?: boolean;
|
|
1446
1466
|
extendState?: (state: FormState) => Record<string, any> | Promise<Record<string, any>>;
|
|
1447
1467
|
}> & Readonly<{
|
|
1448
1468
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
@@ -1485,6 +1505,7 @@ declare const __VLS_component$3: vue.DefineComponent<{
|
|
|
1485
1505
|
labelPosition?: string;
|
|
1486
1506
|
keyProp?: string;
|
|
1487
1507
|
popperClass?: string;
|
|
1508
|
+
preventSubmitDefault?: boolean;
|
|
1488
1509
|
extendState?: (state: FormState) => Record<string, any> | Promise<Record<string, any>>;
|
|
1489
1510
|
}> & Readonly<{
|
|
1490
1511
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
@@ -1519,6 +1540,7 @@ declare const __VLS_component$3: vue.DefineComponent<{
|
|
|
1519
1540
|
labelPosition?: string;
|
|
1520
1541
|
keyProp?: string;
|
|
1521
1542
|
popperClass?: string;
|
|
1543
|
+
preventSubmitDefault?: boolean;
|
|
1522
1544
|
extendState?: (state: FormState) => Record<string, any> | Promise<Record<string, any>>;
|
|
1523
1545
|
}> & Readonly<{
|
|
1524
1546
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
@@ -1560,6 +1582,7 @@ declare const __VLS_component$3: vue.DefineComponent<{
|
|
|
1560
1582
|
labelPosition?: string;
|
|
1561
1583
|
keyProp?: string;
|
|
1562
1584
|
popperClass?: string;
|
|
1585
|
+
preventSubmitDefault?: boolean;
|
|
1563
1586
|
extendState?: (state: FormState) => Record<string, any> | Promise<Record<string, any>>;
|
|
1564
1587
|
}> & Readonly<{
|
|
1565
1588
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
@@ -1615,6 +1638,7 @@ declare const __VLS_component$3: vue.DefineComponent<{
|
|
|
1615
1638
|
confirmText?: string;
|
|
1616
1639
|
inline?: boolean;
|
|
1617
1640
|
labelPosition?: string;
|
|
1641
|
+
preventSubmitDefault?: boolean;
|
|
1618
1642
|
/** 关闭前的回调,会暂停 Drawer 的关闭; done 是个 function type 接受一个 boolean 参数, 执行 done 使用 true 参数或不提供参数将会终止关闭 */
|
|
1619
1643
|
beforeClose?: (done: (cancel?: boolean) => void) => void;
|
|
1620
1644
|
}> & Readonly<{
|
|
@@ -1661,6 +1685,7 @@ declare function __VLS_template$2(): {
|
|
|
1661
1685
|
labelPosition?: string;
|
|
1662
1686
|
keyProp?: string;
|
|
1663
1687
|
popperClass?: string;
|
|
1688
|
+
preventSubmitDefault?: boolean;
|
|
1664
1689
|
extendState?: (state: FormState) => Record<string, any> | Promise<Record<string, any>>;
|
|
1665
1690
|
}> & Readonly<{
|
|
1666
1691
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
@@ -1695,6 +1720,7 @@ declare function __VLS_template$2(): {
|
|
|
1695
1720
|
labelPosition?: string;
|
|
1696
1721
|
keyProp?: string;
|
|
1697
1722
|
popperClass?: string;
|
|
1723
|
+
preventSubmitDefault?: boolean;
|
|
1698
1724
|
extendState?: (state: FormState) => Record<string, any> | Promise<Record<string, any>>;
|
|
1699
1725
|
}> & Readonly<{
|
|
1700
1726
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
@@ -1736,6 +1762,7 @@ declare function __VLS_template$2(): {
|
|
|
1736
1762
|
labelPosition?: string;
|
|
1737
1763
|
keyProp?: string;
|
|
1738
1764
|
popperClass?: string;
|
|
1765
|
+
preventSubmitDefault?: boolean;
|
|
1739
1766
|
extendState?: (state: FormState) => Record<string, any> | Promise<Record<string, any>>;
|
|
1740
1767
|
}> & Readonly<{
|
|
1741
1768
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
@@ -1780,6 +1807,7 @@ declare const __VLS_component$2: vue.DefineComponent<{
|
|
|
1780
1807
|
confirmText?: string;
|
|
1781
1808
|
inline?: boolean;
|
|
1782
1809
|
labelPosition?: string;
|
|
1810
|
+
preventSubmitDefault?: boolean;
|
|
1783
1811
|
}, {
|
|
1784
1812
|
form: vue.Ref<vue.CreateComponentPublicInstanceWithMixins<Readonly<{
|
|
1785
1813
|
config: FormConfig;
|
|
@@ -1796,6 +1824,7 @@ declare const __VLS_component$2: vue.DefineComponent<{
|
|
|
1796
1824
|
labelPosition?: string;
|
|
1797
1825
|
keyProp?: string;
|
|
1798
1826
|
popperClass?: string;
|
|
1827
|
+
preventSubmitDefault?: boolean;
|
|
1799
1828
|
extendState?: (state: FormState) => Record<string, any> | Promise<Record<string, any>>;
|
|
1800
1829
|
}> & Readonly<{
|
|
1801
1830
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
@@ -1830,6 +1859,7 @@ declare const __VLS_component$2: vue.DefineComponent<{
|
|
|
1830
1859
|
labelPosition?: string;
|
|
1831
1860
|
keyProp?: string;
|
|
1832
1861
|
popperClass?: string;
|
|
1862
|
+
preventSubmitDefault?: boolean;
|
|
1833
1863
|
extendState?: (state: FormState) => Record<string, any> | Promise<Record<string, any>>;
|
|
1834
1864
|
}> & Readonly<{
|
|
1835
1865
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
@@ -1871,6 +1901,7 @@ declare const __VLS_component$2: vue.DefineComponent<{
|
|
|
1871
1901
|
labelPosition?: string;
|
|
1872
1902
|
keyProp?: string;
|
|
1873
1903
|
popperClass?: string;
|
|
1904
|
+
preventSubmitDefault?: boolean;
|
|
1874
1905
|
extendState?: (state: FormState) => Record<string, any> | Promise<Record<string, any>>;
|
|
1875
1906
|
}> & Readonly<{
|
|
1876
1907
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
@@ -1913,6 +1944,7 @@ declare const __VLS_component$2: vue.DefineComponent<{
|
|
|
1913
1944
|
labelPosition?: string;
|
|
1914
1945
|
keyProp?: string;
|
|
1915
1946
|
popperClass?: string;
|
|
1947
|
+
preventSubmitDefault?: boolean;
|
|
1916
1948
|
extendState?: (state: FormState) => Record<string, any> | Promise<Record<string, any>>;
|
|
1917
1949
|
}> & Readonly<{
|
|
1918
1950
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
@@ -1947,6 +1979,7 @@ declare const __VLS_component$2: vue.DefineComponent<{
|
|
|
1947
1979
|
labelPosition?: string;
|
|
1948
1980
|
keyProp?: string;
|
|
1949
1981
|
popperClass?: string;
|
|
1982
|
+
preventSubmitDefault?: boolean;
|
|
1950
1983
|
extendState?: (state: FormState) => Record<string, any> | Promise<Record<string, any>>;
|
|
1951
1984
|
}> & Readonly<{
|
|
1952
1985
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
@@ -1988,6 +2021,7 @@ declare const __VLS_component$2: vue.DefineComponent<{
|
|
|
1988
2021
|
labelPosition?: string;
|
|
1989
2022
|
keyProp?: string;
|
|
1990
2023
|
popperClass?: string;
|
|
2024
|
+
preventSubmitDefault?: boolean;
|
|
1991
2025
|
extendState?: (state: FormState) => Record<string, any> | Promise<Record<string, any>>;
|
|
1992
2026
|
}> & Readonly<{
|
|
1993
2027
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
@@ -2035,6 +2069,7 @@ declare const __VLS_component$2: vue.DefineComponent<{
|
|
|
2035
2069
|
confirmText?: string;
|
|
2036
2070
|
inline?: boolean;
|
|
2037
2071
|
labelPosition?: string;
|
|
2072
|
+
preventSubmitDefault?: boolean;
|
|
2038
2073
|
}> & Readonly<{
|
|
2039
2074
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
2040
2075
|
onError?: ((...args: any[]) => any) | undefined;
|