@a2simcode/ui 0.0.21 → 0.0.22
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/LICENSE +53 -53
- package/README.md +130 -130
- package/dist/components/autocomplete/index.d.ts +3 -0
- package/dist/components/autocomplete/src/autocomplete.vue.d.ts +3 -0
- package/dist/components/barcode/index.d.ts +520 -93
- package/dist/components/barcode/src/barcode.vue.d.ts +419 -98
- package/dist/components/button-select/index.d.ts +61 -0
- package/dist/components/button-select/src/button-select.vue.d.ts +35 -0
- package/dist/components/cascader-select/index.d.ts +4 -20
- package/dist/components/cascader-select/src/cascader-select.vue.d.ts +4 -33
- package/dist/components/checkbox/index.d.ts +3 -3
- package/dist/components/checkbox/src/checkbox.vue.d.ts +1 -1
- package/dist/components/code-mirror/index.d.ts +0 -1
- package/dist/components/code-mirror/src/code-mirror.vue.d.ts +0 -1
- package/dist/components/collapse/index.d.ts +44 -0
- package/dist/components/collapse/src/collapse.vue.d.ts +37 -0
- package/dist/components/comp/index.d.ts +30 -15
- package/dist/components/comp/src/comp.vue.d.ts +31 -45
- package/dist/components/comp/src/interface.d.ts +101 -0
- package/dist/components/count-up/index.d.ts +3 -3
- package/dist/components/count-up/src/count-up.vue.d.ts +1 -1
- package/dist/components/dialog/index.d.ts +5 -5
- package/dist/components/dialog/src/index.vue.d.ts +2 -2
- package/dist/components/dialog-full/index.d.ts +5 -5
- package/dist/components/dialog-full/src/index.vue.d.ts +2 -2
- package/dist/components/drawer/index.d.ts +5 -5
- package/dist/components/drawer/src/drawer.vue.d.ts +2 -2
- package/dist/components/editor/index.d.ts +160 -0
- package/dist/components/editor/src/editor.vue.d.ts +86 -0
- package/dist/components/form/index.d.ts +6 -6
- package/dist/components/form/src/form.vue.d.ts +3 -3
- package/dist/components/form-item/src/form-item.vue.d.ts +1 -1
- package/dist/components/icon/src/icon.vue.d.ts +0 -4
- package/dist/components/index.d.ts +22 -6
- package/dist/components/inject-provide.d.ts +159 -0
- package/dist/components/input/index.d.ts +3 -1
- package/dist/components/input/src/input.vue.d.ts +5 -1
- package/dist/components/input-color/index.d.ts +114 -0
- package/dist/components/input-color/src/input-color.vue.d.ts +73 -0
- package/dist/components/input-rows/index.d.ts +200 -0
- package/dist/components/input-rows/src/input-rows.vue.d.ts +154 -0
- package/dist/components/input-rows/src/interface.d.ts +33 -0
- package/dist/components/layer-form/index.d.ts +178 -0
- package/dist/components/layer-form/src/layer-form.vue.d.ts +149 -0
- package/dist/components/map/index.d.ts +127 -0
- package/dist/components/map/src/map.vue.d.ts +92 -0
- package/dist/components/number/index.d.ts +3 -3
- package/dist/components/number/src/number.vue.d.ts +3 -3
- package/dist/components/page/index.d.ts +6 -6
- package/dist/components/page/src/page.vue.d.ts +2 -2
- package/dist/components/select/index.d.ts +6 -1
- package/dist/components/select/src/select.vue.d.ts +7 -2
- package/dist/components/slider/index.d.ts +3 -3
- package/dist/components/slider/src/slider.vue.d.ts +1 -1
- package/dist/components/switch/index.d.ts +71 -0
- package/dist/components/switch/src/switch.vue.d.ts +83 -0
- package/dist/components/table/index.d.ts +275 -66
- package/dist/components/table/src/editors/index.d.ts +26 -0
- package/dist/components/table/src/editors/j-comp-editor.d.ts +62 -0
- package/dist/components/table/src/table.vue.d.ts +326 -61
- package/dist/components/table/src/theme/default.d.ts +27 -0
- package/dist/components/table-panel/index.d.ts +459 -0
- package/dist/components/table-panel/src/column-panel.vue.d.ts +37 -0
- package/dist/components/table-panel/src/filter-panel.vue.d.ts +49 -0
- package/dist/components/table-panel/src/keyword-panel.vue.d.ts +36 -0
- package/dist/components/table-panel/src/order-panel.vue.d.ts +24 -0
- package/dist/components/table-panel/src/table-panel.vue.d.ts +445 -0
- package/dist/components/tabs/index.d.ts +156 -0
- package/dist/components/tabs/src/tabs.vue.d.ts +110 -0
- package/dist/components/tree/index.d.ts +451 -0
- package/dist/components/tree/src/tree.vue.d.ts +478 -0
- package/dist/components/upload/index.d.ts +13 -13
- package/dist/components/upload/src/list.vue.d.ts +1 -1
- package/dist/components/upload/src/upload.vue.d.ts +5 -5
- package/dist/core/utils/comp.d.ts +18 -0
- package/dist/core/utils/index.d.ts +2 -0
- package/dist/core/utils/map.d.ts +1 -0
- package/dist/core/utils/tree.d.ts +1 -0
- package/dist/core/utils/useSortable.d.ts +5 -0
- package/dist/simcode-ui.es.js +6888 -3212
- package/dist/simcode-ui.umd.js +2 -2
- package/dist/stats.html +1 -1
- package/dist/ui.css +1 -1
- package/package.json +49 -24
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
declare const _default: import('vue').DefineComponent<import('vue').ExtractPropTypes<{
|
|
2
|
+
/**
|
|
3
|
+
* @zh 详细地址
|
|
4
|
+
* @vModel
|
|
5
|
+
*/
|
|
6
|
+
address: StringConstructor;
|
|
7
|
+
/**
|
|
8
|
+
* @zh 经度
|
|
9
|
+
* @vModel
|
|
10
|
+
*/
|
|
11
|
+
lng: NumberConstructor;
|
|
12
|
+
/**
|
|
13
|
+
* @zh 纬度
|
|
14
|
+
* @vModel
|
|
15
|
+
*/
|
|
16
|
+
lat: NumberConstructor;
|
|
17
|
+
/**
|
|
18
|
+
* @zh 地图高度
|
|
19
|
+
*/
|
|
20
|
+
height: {
|
|
21
|
+
type: StringConstructor;
|
|
22
|
+
default: string;
|
|
23
|
+
};
|
|
24
|
+
/**
|
|
25
|
+
* @zh 百度地图密钥
|
|
26
|
+
*/
|
|
27
|
+
mapKey: {
|
|
28
|
+
type: StringConstructor;
|
|
29
|
+
default: string;
|
|
30
|
+
};
|
|
31
|
+
}>, {
|
|
32
|
+
setPoint: (lng?: number, lat?: number) => void;
|
|
33
|
+
querySearchAsync: (str: string, cb: any) => void;
|
|
34
|
+
}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
|
|
35
|
+
change: (data: {
|
|
36
|
+
value: {
|
|
37
|
+
address: string;
|
|
38
|
+
lng: number;
|
|
39
|
+
lat: number;
|
|
40
|
+
};
|
|
41
|
+
}) => any;
|
|
42
|
+
"update:address": (val: string) => any;
|
|
43
|
+
"update:lng": (val: number) => any;
|
|
44
|
+
"update:lat": (val: number) => any;
|
|
45
|
+
}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<{
|
|
46
|
+
/**
|
|
47
|
+
* @zh 详细地址
|
|
48
|
+
* @vModel
|
|
49
|
+
*/
|
|
50
|
+
address: StringConstructor;
|
|
51
|
+
/**
|
|
52
|
+
* @zh 经度
|
|
53
|
+
* @vModel
|
|
54
|
+
*/
|
|
55
|
+
lng: NumberConstructor;
|
|
56
|
+
/**
|
|
57
|
+
* @zh 纬度
|
|
58
|
+
* @vModel
|
|
59
|
+
*/
|
|
60
|
+
lat: NumberConstructor;
|
|
61
|
+
/**
|
|
62
|
+
* @zh 地图高度
|
|
63
|
+
*/
|
|
64
|
+
height: {
|
|
65
|
+
type: StringConstructor;
|
|
66
|
+
default: string;
|
|
67
|
+
};
|
|
68
|
+
/**
|
|
69
|
+
* @zh 百度地图密钥
|
|
70
|
+
*/
|
|
71
|
+
mapKey: {
|
|
72
|
+
type: StringConstructor;
|
|
73
|
+
default: string;
|
|
74
|
+
};
|
|
75
|
+
}>> & Readonly<{
|
|
76
|
+
onChange?: ((data: {
|
|
77
|
+
value: {
|
|
78
|
+
address: string;
|
|
79
|
+
lng: number;
|
|
80
|
+
lat: number;
|
|
81
|
+
};
|
|
82
|
+
}) => any) | undefined;
|
|
83
|
+
"onUpdate:address"?: ((val: string) => any) | undefined;
|
|
84
|
+
"onUpdate:lng"?: ((val: number) => any) | undefined;
|
|
85
|
+
"onUpdate:lat"?: ((val: number) => any) | undefined;
|
|
86
|
+
}>, {
|
|
87
|
+
height: string;
|
|
88
|
+
mapKey: string;
|
|
89
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {
|
|
90
|
+
mapRef: HTMLDivElement;
|
|
91
|
+
}, HTMLDivElement>;
|
|
92
|
+
export default _default;
|
|
@@ -18,9 +18,9 @@ declare const JNumber: {
|
|
|
18
18
|
readonly: boolean;
|
|
19
19
|
placeholder: string;
|
|
20
20
|
step: number;
|
|
21
|
-
validateEvent: boolean;
|
|
22
21
|
stepStrictly: boolean;
|
|
23
22
|
controls: boolean;
|
|
23
|
+
controlsPosition: string;
|
|
24
24
|
align: "left" | "center" | "right";
|
|
25
25
|
disabledScientific: boolean;
|
|
26
26
|
}, false, {}, {}, import('vue').GlobalComponents, import('vue').GlobalDirectives, string, {
|
|
@@ -46,9 +46,9 @@ declare const JNumber: {
|
|
|
46
46
|
readonly: boolean;
|
|
47
47
|
placeholder: string;
|
|
48
48
|
step: number;
|
|
49
|
-
validateEvent: boolean;
|
|
50
49
|
stepStrictly: boolean;
|
|
51
50
|
controls: boolean;
|
|
51
|
+
controlsPosition: string;
|
|
52
52
|
align: "left" | "center" | "right";
|
|
53
53
|
disabledScientific: boolean;
|
|
54
54
|
}>;
|
|
@@ -74,9 +74,9 @@ declare const JNumber: {
|
|
|
74
74
|
readonly: boolean;
|
|
75
75
|
placeholder: string;
|
|
76
76
|
step: number;
|
|
77
|
-
validateEvent: boolean;
|
|
78
77
|
stepStrictly: boolean;
|
|
79
78
|
controls: boolean;
|
|
79
|
+
controlsPosition: string;
|
|
80
80
|
align: "left" | "center" | "right";
|
|
81
81
|
disabledScientific: boolean;
|
|
82
82
|
}, {}, string, {}, import('vue').GlobalComponents, import('vue').GlobalDirectives, string, import('vue').ComponentProvideOptions> & import('vue').VNodeProps & import('vue').AllowedComponentProps & import('vue').ComponentCustomProps & {
|
|
@@ -29,8 +29,6 @@ export interface NumberProps {
|
|
|
29
29
|
id?: string;
|
|
30
30
|
/** 当输入框被清空时显示的值 */
|
|
31
31
|
valueOnClear?: number | null | '';
|
|
32
|
-
/** 是否触发表单验证 */
|
|
33
|
-
validateEvent?: boolean;
|
|
34
32
|
/** 等价于原生 input aria-label 属性 */
|
|
35
33
|
label?: string;
|
|
36
34
|
/** 等价于原生 input inputmode 属性 */
|
|
@@ -47,6 +45,8 @@ export interface NumberProps {
|
|
|
47
45
|
decreaseIcon?: string;
|
|
48
46
|
/** 自定义输入框按钮增加图标 */
|
|
49
47
|
increaseIcon?: string;
|
|
48
|
+
/** 是否自动聚焦 */
|
|
49
|
+
autoFocus?: boolean;
|
|
50
50
|
}
|
|
51
51
|
declare const _default: import('vue').DefineComponent<NumberProps, {
|
|
52
52
|
blur: () => void;
|
|
@@ -67,9 +67,9 @@ declare const _default: import('vue').DefineComponent<NumberProps, {
|
|
|
67
67
|
readonly: boolean;
|
|
68
68
|
placeholder: string;
|
|
69
69
|
step: number;
|
|
70
|
-
validateEvent: boolean;
|
|
71
70
|
stepStrictly: boolean;
|
|
72
71
|
controls: boolean;
|
|
72
|
+
controlsPosition: string;
|
|
73
73
|
align: "left" | "center" | "right";
|
|
74
74
|
disabledScientific: boolean;
|
|
75
75
|
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {
|
|
@@ -13,9 +13,9 @@ export declare const JPage: {
|
|
|
13
13
|
default: () => {};
|
|
14
14
|
};
|
|
15
15
|
}>> & Readonly<{}>, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, import('vue').PublicProps, {
|
|
16
|
-
schema: import('..').PageSchemaConfig[];
|
|
17
|
-
noPadding: boolean;
|
|
18
16
|
actions: Record<string, any>;
|
|
17
|
+
noPadding: boolean;
|
|
18
|
+
schema: import('..').PageSchemaConfig[];
|
|
19
19
|
}, true, {}, {}, import('vue').GlobalComponents, import('vue').GlobalDirectives, string, {}, HTMLDivElement, import('vue').ComponentProvideOptions, {
|
|
20
20
|
P: {};
|
|
21
21
|
B: {};
|
|
@@ -37,9 +37,9 @@ export declare const JPage: {
|
|
|
37
37
|
default: () => {};
|
|
38
38
|
};
|
|
39
39
|
}>> & Readonly<{}>, {}, {}, {}, {}, {
|
|
40
|
-
schema: import('..').PageSchemaConfig[];
|
|
41
|
-
noPadding: boolean;
|
|
42
40
|
actions: Record<string, any>;
|
|
41
|
+
noPadding: boolean;
|
|
42
|
+
schema: import('..').PageSchemaConfig[];
|
|
43
43
|
}>;
|
|
44
44
|
__isFragment?: never;
|
|
45
45
|
__isTeleport?: never;
|
|
@@ -58,9 +58,9 @@ export declare const JPage: {
|
|
|
58
58
|
default: () => {};
|
|
59
59
|
};
|
|
60
60
|
}>> & Readonly<{}>, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, {
|
|
61
|
-
schema: import('..').PageSchemaConfig[];
|
|
62
|
-
noPadding: boolean;
|
|
63
61
|
actions: Record<string, any>;
|
|
62
|
+
noPadding: boolean;
|
|
63
|
+
schema: import('..').PageSchemaConfig[];
|
|
64
64
|
}, {}, string, {}, import('vue').GlobalComponents, import('vue').GlobalDirectives, string, import('vue').ComponentProvideOptions> & import('vue').VNodeProps & import('vue').AllowedComponentProps & import('vue').ComponentCustomProps & {
|
|
65
65
|
install: (app: import('vue').App) => void;
|
|
66
66
|
};
|
|
@@ -45,8 +45,8 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
|
|
|
45
45
|
default: () => {};
|
|
46
46
|
};
|
|
47
47
|
}>> & Readonly<{}>, {
|
|
48
|
-
schema: PageSchemaConfig[];
|
|
49
|
-
noPadding: boolean;
|
|
50
48
|
actions: Record<string, any>;
|
|
49
|
+
noPadding: boolean;
|
|
50
|
+
schema: PageSchemaConfig[];
|
|
51
51
|
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, HTMLDivElement>;
|
|
52
52
|
export default _default;
|
|
@@ -11,6 +11,7 @@ declare const JSelect: {
|
|
|
11
11
|
readonly: boolean;
|
|
12
12
|
placeholder: string;
|
|
13
13
|
clearable: boolean;
|
|
14
|
+
autoFocus: boolean;
|
|
14
15
|
options: import('..').SelectOption[];
|
|
15
16
|
teleported: boolean;
|
|
16
17
|
noBorder: boolean;
|
|
@@ -24,7 +25,9 @@ declare const JSelect: {
|
|
|
24
25
|
filterable: boolean;
|
|
25
26
|
isGroup: boolean;
|
|
26
27
|
groupKey: string;
|
|
27
|
-
}, false, {}, {}, import('vue').GlobalComponents, import('vue').GlobalDirectives, string, {
|
|
28
|
+
}, false, {}, {}, import('vue').GlobalComponents, import('vue').GlobalDirectives, string, {
|
|
29
|
+
selectRef: unknown;
|
|
30
|
+
}, any, import('vue').ComponentProvideOptions, {
|
|
28
31
|
P: {};
|
|
29
32
|
B: {};
|
|
30
33
|
D: {};
|
|
@@ -40,6 +43,7 @@ declare const JSelect: {
|
|
|
40
43
|
readonly: boolean;
|
|
41
44
|
placeholder: string;
|
|
42
45
|
clearable: boolean;
|
|
46
|
+
autoFocus: boolean;
|
|
43
47
|
options: import('..').SelectOption[];
|
|
44
48
|
teleported: boolean;
|
|
45
49
|
noBorder: boolean;
|
|
@@ -69,6 +73,7 @@ declare const JSelect: {
|
|
|
69
73
|
readonly: boolean;
|
|
70
74
|
placeholder: string;
|
|
71
75
|
clearable: boolean;
|
|
76
|
+
autoFocus: boolean;
|
|
72
77
|
options: import('..').SelectOption[];
|
|
73
78
|
teleported: boolean;
|
|
74
79
|
noBorder: boolean;
|
|
@@ -8,7 +8,7 @@ export interface SelectOption {
|
|
|
8
8
|
}
|
|
9
9
|
export interface SelectProps {
|
|
10
10
|
/** 绑定值 */
|
|
11
|
-
modelValue: string | number |
|
|
11
|
+
modelValue: string | number | undefined;
|
|
12
12
|
/** 选项列表 */
|
|
13
13
|
options?: SelectOption[];
|
|
14
14
|
/** 尺寸 */
|
|
@@ -45,6 +45,8 @@ export interface SelectProps {
|
|
|
45
45
|
isGroup?: boolean;
|
|
46
46
|
/** 分组键 */
|
|
47
47
|
groupKey?: string;
|
|
48
|
+
/** 是否自动选择 */
|
|
49
|
+
autoFocus?: boolean;
|
|
48
50
|
}
|
|
49
51
|
declare const _default: import('vue').DefineComponent<SelectProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
50
52
|
"update:modelValue": (value: string | number | (string | number)[] | undefined) => any;
|
|
@@ -58,6 +60,7 @@ declare const _default: import('vue').DefineComponent<SelectProps, {}, {}, {}, {
|
|
|
58
60
|
readonly: boolean;
|
|
59
61
|
placeholder: string;
|
|
60
62
|
clearable: boolean;
|
|
63
|
+
autoFocus: boolean;
|
|
61
64
|
options: SelectOption[];
|
|
62
65
|
teleported: boolean;
|
|
63
66
|
noBorder: boolean;
|
|
@@ -71,5 +74,7 @@ declare const _default: import('vue').DefineComponent<SelectProps, {}, {}, {}, {
|
|
|
71
74
|
filterable: boolean;
|
|
72
75
|
isGroup: boolean;
|
|
73
76
|
groupKey: string;
|
|
74
|
-
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {
|
|
77
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {
|
|
78
|
+
selectRef: unknown;
|
|
79
|
+
}, any>;
|
|
75
80
|
export default _default;
|
|
@@ -11,8 +11,8 @@ export declare const JSlider: {
|
|
|
11
11
|
}) => any;
|
|
12
12
|
}, import('vue').PublicProps, {
|
|
13
13
|
size: "large" | "default" | "small";
|
|
14
|
-
readonly: boolean;
|
|
15
14
|
vertical: boolean;
|
|
15
|
+
readonly: boolean;
|
|
16
16
|
modelValue: number | number[];
|
|
17
17
|
max: number;
|
|
18
18
|
min: number;
|
|
@@ -39,8 +39,8 @@ export declare const JSlider: {
|
|
|
39
39
|
}) => any) | undefined;
|
|
40
40
|
}>, {}, {}, {}, {}, {
|
|
41
41
|
size: "large" | "default" | "small";
|
|
42
|
-
readonly: boolean;
|
|
43
42
|
vertical: boolean;
|
|
43
|
+
readonly: boolean;
|
|
44
44
|
modelValue: number | number[];
|
|
45
45
|
max: number;
|
|
46
46
|
min: number;
|
|
@@ -69,8 +69,8 @@ export declare const JSlider: {
|
|
|
69
69
|
}) => any;
|
|
70
70
|
}, string, {
|
|
71
71
|
size: "large" | "default" | "small";
|
|
72
|
-
readonly: boolean;
|
|
73
72
|
vertical: boolean;
|
|
73
|
+
readonly: boolean;
|
|
74
74
|
modelValue: number | number[];
|
|
75
75
|
max: number;
|
|
76
76
|
min: number;
|
|
@@ -58,8 +58,8 @@ declare const _default: import('vue').DefineComponent<SliderProps, {}, {}, {}, {
|
|
|
58
58
|
}) => any) | undefined;
|
|
59
59
|
}>, {
|
|
60
60
|
size: "large" | "default" | "small";
|
|
61
|
-
readonly: boolean;
|
|
62
61
|
vertical: boolean;
|
|
62
|
+
readonly: boolean;
|
|
63
63
|
modelValue: number | number[];
|
|
64
64
|
max: number;
|
|
65
65
|
min: number;
|
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
declare const JSwitch: {
|
|
2
|
+
new (...args: any[]): import('vue').CreateComponentPublicInstanceWithMixins<Readonly<import('..').SwitchProps> & Readonly<{
|
|
3
|
+
"onUpdate:modelValue"?: ((value: string | number | boolean) => any) | undefined;
|
|
4
|
+
onChange?: ((value: string | number | boolean) => any) | undefined;
|
|
5
|
+
}>, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
|
|
6
|
+
"update:modelValue": (value: string | number | boolean) => any;
|
|
7
|
+
change: (value: string | number | boolean) => any;
|
|
8
|
+
}, import('vue').PublicProps, {
|
|
9
|
+
width: number | string;
|
|
10
|
+
disabled: boolean;
|
|
11
|
+
loading: boolean;
|
|
12
|
+
readonly: boolean;
|
|
13
|
+
modelValue: boolean | string | number;
|
|
14
|
+
validateEvent: boolean;
|
|
15
|
+
autoFocus: boolean;
|
|
16
|
+
activeValue: boolean | string | number;
|
|
17
|
+
inactiveValue: boolean | string | number;
|
|
18
|
+
inlinePrompt: boolean;
|
|
19
|
+
}, false, {}, {}, import('vue').GlobalComponents, import('vue').GlobalDirectives, string, {}, any, import('vue').ComponentProvideOptions, {
|
|
20
|
+
P: {};
|
|
21
|
+
B: {};
|
|
22
|
+
D: {};
|
|
23
|
+
C: {};
|
|
24
|
+
M: {};
|
|
25
|
+
Defaults: {};
|
|
26
|
+
}, Readonly<import('..').SwitchProps> & Readonly<{
|
|
27
|
+
"onUpdate:modelValue"?: ((value: string | number | boolean) => any) | undefined;
|
|
28
|
+
onChange?: ((value: string | number | boolean) => any) | undefined;
|
|
29
|
+
}>, {}, {}, {}, {}, {
|
|
30
|
+
width: number | string;
|
|
31
|
+
disabled: boolean;
|
|
32
|
+
loading: boolean;
|
|
33
|
+
readonly: boolean;
|
|
34
|
+
modelValue: boolean | string | number;
|
|
35
|
+
validateEvent: boolean;
|
|
36
|
+
autoFocus: boolean;
|
|
37
|
+
activeValue: boolean | string | number;
|
|
38
|
+
inactiveValue: boolean | string | number;
|
|
39
|
+
inlinePrompt: boolean;
|
|
40
|
+
}>;
|
|
41
|
+
__isFragment?: never;
|
|
42
|
+
__isTeleport?: never;
|
|
43
|
+
__isSuspense?: never;
|
|
44
|
+
} & import('vue').ComponentOptionsBase<Readonly<import('..').SwitchProps> & Readonly<{
|
|
45
|
+
"onUpdate:modelValue"?: ((value: string | number | boolean) => any) | undefined;
|
|
46
|
+
onChange?: ((value: string | number | boolean) => any) | undefined;
|
|
47
|
+
}>, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
|
|
48
|
+
"update:modelValue": (value: string | number | boolean) => any;
|
|
49
|
+
change: (value: string | number | boolean) => any;
|
|
50
|
+
}, string, {
|
|
51
|
+
width: number | string;
|
|
52
|
+
disabled: boolean;
|
|
53
|
+
loading: boolean;
|
|
54
|
+
readonly: boolean;
|
|
55
|
+
modelValue: boolean | string | number;
|
|
56
|
+
validateEvent: boolean;
|
|
57
|
+
autoFocus: boolean;
|
|
58
|
+
activeValue: boolean | string | number;
|
|
59
|
+
inactiveValue: boolean | string | number;
|
|
60
|
+
inlinePrompt: boolean;
|
|
61
|
+
}, {}, string, {}, import('vue').GlobalComponents, import('vue').GlobalDirectives, string, import('vue').ComponentProvideOptions> & import('vue').VNodeProps & import('vue').AllowedComponentProps & import('vue').ComponentCustomProps & (new () => {
|
|
62
|
+
$slots: {
|
|
63
|
+
'active-action'?(_: {}): any;
|
|
64
|
+
'inactive-action'?(_: {}): any;
|
|
65
|
+
active?(_: {}): any;
|
|
66
|
+
inactive?(_: {}): any;
|
|
67
|
+
};
|
|
68
|
+
}) & {
|
|
69
|
+
install: (app: import('vue').App) => void;
|
|
70
|
+
};
|
|
71
|
+
export default JSwitch;
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
export interface SwitchProps {
|
|
2
|
+
/** 绑定值 */
|
|
3
|
+
modelValue?: boolean | string | number;
|
|
4
|
+
/** 尺寸 */
|
|
5
|
+
size?: 'large' | 'default' | 'small';
|
|
6
|
+
/** 是否禁用 */
|
|
7
|
+
disabled?: boolean;
|
|
8
|
+
/** 是否只读 */
|
|
9
|
+
readonly?: boolean;
|
|
10
|
+
/** 激活时的值 */
|
|
11
|
+
activeValue?: boolean | string | number;
|
|
12
|
+
/** 非激活时的值 */
|
|
13
|
+
inactiveValue?: boolean | string | number;
|
|
14
|
+
/** 激活时的文字 */
|
|
15
|
+
activeText?: string;
|
|
16
|
+
/** 非激活时的文字 */
|
|
17
|
+
inactiveText?: string;
|
|
18
|
+
/** 激活时的图标 */
|
|
19
|
+
activeIcon?: string | Record<string, unknown>;
|
|
20
|
+
/** 非激活时的图标 */
|
|
21
|
+
inactiveIcon?: string | Record<string, unknown>;
|
|
22
|
+
/** 激活时的动作图标 */
|
|
23
|
+
activeActionIcon?: string | Record<string, unknown>;
|
|
24
|
+
/** 非激活时的动作图标 */
|
|
25
|
+
inactiveActionIcon?: string | Record<string, unknown>;
|
|
26
|
+
/** switch 的宽度 */
|
|
27
|
+
width?: number | string;
|
|
28
|
+
/** 是否在点内显示图标或文本 */
|
|
29
|
+
inlinePrompt?: boolean;
|
|
30
|
+
/** switch 对应的 name 属性 */
|
|
31
|
+
name?: string;
|
|
32
|
+
/** 是否触发表单验证 */
|
|
33
|
+
validateEvent?: boolean;
|
|
34
|
+
/** 切换前的钩子 */
|
|
35
|
+
beforeChange?: () => boolean | Promise<boolean>;
|
|
36
|
+
/** input 的 id */
|
|
37
|
+
id?: string;
|
|
38
|
+
/** input 的 tabindex */
|
|
39
|
+
tabindex?: number | string;
|
|
40
|
+
/** aria-label 属性 */
|
|
41
|
+
ariaLabel?: string;
|
|
42
|
+
/** 是否显示加载中状态 */
|
|
43
|
+
loading?: boolean;
|
|
44
|
+
/** 是否自动获取焦点 */
|
|
45
|
+
autoFocus?: boolean;
|
|
46
|
+
}
|
|
47
|
+
declare function __VLS_template(): {
|
|
48
|
+
attrs: Partial<{}>;
|
|
49
|
+
slots: {
|
|
50
|
+
'active-action'?(_: {}): any;
|
|
51
|
+
'inactive-action'?(_: {}): any;
|
|
52
|
+
active?(_: {}): any;
|
|
53
|
+
inactive?(_: {}): any;
|
|
54
|
+
};
|
|
55
|
+
refs: {};
|
|
56
|
+
rootEl: any;
|
|
57
|
+
};
|
|
58
|
+
type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
|
|
59
|
+
declare const __VLS_component: import('vue').DefineComponent<SwitchProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
|
|
60
|
+
"update:modelValue": (value: string | number | boolean) => any;
|
|
61
|
+
change: (value: string | number | boolean) => any;
|
|
62
|
+
}, string, import('vue').PublicProps, Readonly<SwitchProps> & Readonly<{
|
|
63
|
+
"onUpdate:modelValue"?: ((value: string | number | boolean) => any) | undefined;
|
|
64
|
+
onChange?: ((value: string | number | boolean) => any) | undefined;
|
|
65
|
+
}>, {
|
|
66
|
+
width: number | string;
|
|
67
|
+
disabled: boolean;
|
|
68
|
+
loading: boolean;
|
|
69
|
+
readonly: boolean;
|
|
70
|
+
modelValue: boolean | string | number;
|
|
71
|
+
validateEvent: boolean;
|
|
72
|
+
autoFocus: boolean;
|
|
73
|
+
activeValue: boolean | string | number;
|
|
74
|
+
inactiveValue: boolean | string | number;
|
|
75
|
+
inlinePrompt: boolean;
|
|
76
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
77
|
+
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
|
|
78
|
+
export default _default;
|
|
79
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
80
|
+
new (): {
|
|
81
|
+
$slots: S;
|
|
82
|
+
};
|
|
83
|
+
};
|