zartui 3.1.13 → 3.1.15
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/es/cell/index.css +1 -1
- package/es/dropdown-item/DropdownItem.d.ts +7 -0
- package/es/dropdown-item/DropdownItem.mjs +39 -25
- package/es/dropdown-item/index.css +1 -1
- package/es/dropdown-item/index.d.ts +4 -0
- package/es/dropdown-item/style/index.mjs +1 -0
- package/es/dropdown-item/types.d.ts +2 -1
- package/es/dropdown-menu/index.css +1 -1
- package/es/field/index.css +1 -1
- package/es/form/index.css +1 -0
- package/es/form/style/index.mjs +1 -0
- package/es/icon/config.mjs +3 -1
- package/es/icon/index.css +1 -1
- package/es/image-preview/ImagePreview.d.ts +1 -1
- package/es/image-preview/index.d.ts +1 -1
- package/es/index.d.ts +2 -1
- package/es/index.mjs +4 -1
- package/es/media-picker/MediaPicker.mjs +12 -2
- package/es/media-picker/type.d.ts +3 -0
- package/es/multiple-picker/MultiplePicker.d.ts +44 -3
- package/es/multiple-picker/MultiplePicker.mjs +45 -18
- package/es/multiple-picker/MultiplePickerOptions.mjs +5 -2
- package/es/multiple-picker/index.css +1 -1
- package/es/multiple-picker/index.d.ts +31 -3
- package/es/picker/Picker.d.ts +30 -4
- package/es/picker/Picker.mjs +69 -16
- package/es/picker/PickerOptions.d.ts +75 -0
- package/es/picker/PickerOptions.mjs +93 -0
- package/es/picker/index.css +1 -1
- package/es/picker/index.d.ts +21 -3
- package/es/picker/types.d.ts +5 -1
- package/es/popup/Popup.mjs +3 -3
- package/es/radio-picker/RadioPicker.d.ts +11 -11
- package/es/radio-picker/index.d.ts +9 -9
- package/es/radio-picker/style/index.mjs +1 -1
- package/es/skeleton/index.css +1 -1
- package/es/slider/Slider.d.ts +139 -0
- package/es/slider/Slider.mjs +335 -0
- package/es/slider/index.css +1 -0
- package/es/slider/index.d.ts +103 -0
- package/es/slider/index.mjs +10 -0
- package/es/slider/style/index.d.ts +1 -0
- package/es/slider/style/index.mjs +2 -0
- package/es/slider/types.d.ts +11 -0
- package/es/slider/types.mjs +0 -0
- package/es/style/base.css +1 -1
- package/es/style/css-variables.css +1 -1
- package/es/tabbar-item/index.css +1 -1
- package/es/utils/mount-component.mjs +1 -1
- package/lib/cell/index.css +1 -1
- package/lib/dropdown-item/DropdownItem.d.ts +7 -0
- package/lib/dropdown-item/DropdownItem.js +37 -23
- package/lib/dropdown-item/index.css +1 -1
- package/lib/dropdown-item/index.d.ts +4 -0
- package/lib/dropdown-item/style/index.js +1 -0
- package/lib/dropdown-item/types.d.ts +2 -1
- package/lib/dropdown-menu/index.css +1 -1
- package/lib/field/index.css +1 -1
- package/lib/form/index.css +1 -0
- package/lib/form/style/index.js +1 -0
- package/lib/icon/config.js +3 -1
- package/lib/icon/index.css +1 -1
- package/lib/image-preview/ImagePreview.d.ts +1 -1
- package/lib/image-preview/index.d.ts +1 -1
- package/lib/index.css +1 -1
- package/lib/index.d.ts +2 -1
- package/lib/index.js +4 -1
- package/lib/media-picker/MediaPicker.js +12 -2
- package/lib/media-picker/type.d.ts +3 -0
- package/lib/multiple-picker/MultiplePicker.d.ts +44 -3
- package/lib/multiple-picker/MultiplePicker.js +45 -18
- package/lib/multiple-picker/MultiplePickerOptions.js +5 -2
- package/lib/multiple-picker/index.css +1 -1
- package/lib/multiple-picker/index.d.ts +31 -3
- package/lib/picker/Picker.d.ts +30 -4
- package/lib/picker/Picker.js +68 -15
- package/lib/picker/PickerOptions.d.ts +75 -0
- package/lib/picker/PickerOptions.js +112 -0
- package/lib/picker/index.css +1 -1
- package/lib/picker/index.d.ts +21 -3
- package/lib/picker/types.d.ts +5 -1
- package/lib/popup/Popup.js +3 -3
- package/lib/radio-picker/RadioPicker.d.ts +11 -11
- package/lib/radio-picker/index.d.ts +9 -9
- package/lib/radio-picker/style/index.js +1 -1
- package/lib/skeleton/index.css +1 -1
- package/lib/slider/Slider.d.ts +139 -0
- package/lib/slider/Slider.js +354 -0
- package/lib/slider/index.css +1 -0
- package/lib/slider/index.d.ts +103 -0
- package/lib/slider/index.js +39 -0
- package/lib/slider/style/index.d.ts +1 -0
- package/lib/slider/style/index.js +2 -0
- package/lib/slider/types.d.ts +11 -0
- package/lib/slider/types.js +15 -0
- package/lib/style/base.css +1 -1
- package/lib/style/css-variables.css +1 -1
- package/lib/tabbar-item/index.css +1 -1
- package/lib/utils/mount-component.js +1 -1
- package/lib/web-types.json +1 -1
- package/lib/zartui.cjs.js +1440 -919
- package/lib/zartui.es.js +1440 -919
- package/lib/zartui.js +1440 -919
- package/lib/zartui.min.js +1 -1
- package/package.json +7 -7
- package/README.md +0 -23
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { ExtractPropTypes } from 'vue';
|
|
2
|
+
import { Numeric } from '../utils';
|
|
2
3
|
import { PickerOption } from './types';
|
|
3
4
|
declare const multiplePickerProps: {
|
|
4
5
|
title: StringConstructor;
|
|
@@ -27,6 +28,10 @@ declare const multiplePickerProps: {
|
|
|
27
28
|
type: BooleanConstructor;
|
|
28
29
|
default: true;
|
|
29
30
|
};
|
|
31
|
+
showTitle: {
|
|
32
|
+
type: BooleanConstructor;
|
|
33
|
+
default: true;
|
|
34
|
+
};
|
|
30
35
|
options: {
|
|
31
36
|
type: import("vue").PropType<PickerOption[]>;
|
|
32
37
|
default: () => PickerOption[];
|
|
@@ -47,6 +52,14 @@ declare const multiplePickerProps: {
|
|
|
47
52
|
type: import("vue").PropType<number[]>;
|
|
48
53
|
default: () => number[];
|
|
49
54
|
};
|
|
55
|
+
selectedValue: {
|
|
56
|
+
type: import("vue").PropType<Numeric[]>;
|
|
57
|
+
default: () => Numeric[];
|
|
58
|
+
};
|
|
59
|
+
popup: {
|
|
60
|
+
type: BooleanConstructor;
|
|
61
|
+
default: true;
|
|
62
|
+
};
|
|
50
63
|
};
|
|
51
64
|
export type MultiplePickerProps = ExtractPropTypes<typeof multiplePickerProps>;
|
|
52
65
|
declare const _default: import("vue").DefineComponent<{
|
|
@@ -76,6 +89,10 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
76
89
|
type: BooleanConstructor;
|
|
77
90
|
default: true;
|
|
78
91
|
};
|
|
92
|
+
showTitle: {
|
|
93
|
+
type: BooleanConstructor;
|
|
94
|
+
default: true;
|
|
95
|
+
};
|
|
79
96
|
options: {
|
|
80
97
|
type: import("vue").PropType<PickerOption[]>;
|
|
81
98
|
default: () => PickerOption[];
|
|
@@ -96,7 +113,15 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
96
113
|
type: import("vue").PropType<number[]>;
|
|
97
114
|
default: () => number[];
|
|
98
115
|
};
|
|
99
|
-
|
|
116
|
+
selectedValue: {
|
|
117
|
+
type: import("vue").PropType<Numeric[]>;
|
|
118
|
+
default: () => Numeric[];
|
|
119
|
+
};
|
|
120
|
+
popup: {
|
|
121
|
+
type: BooleanConstructor;
|
|
122
|
+
default: true;
|
|
123
|
+
};
|
|
124
|
+
}, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("cancel" | "change" | "confirm" | "update:showPicker" | "update:selectedIndex" | "update:selectedValue")[], "cancel" | "change" | "confirm" | "update:showPicker" | "update:selectedIndex" | "update:selectedValue", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<ExtractPropTypes<{
|
|
100
125
|
title: StringConstructor;
|
|
101
126
|
loading: BooleanConstructor;
|
|
102
127
|
readonly: BooleanConstructor;
|
|
@@ -123,6 +148,10 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
123
148
|
type: BooleanConstructor;
|
|
124
149
|
default: true;
|
|
125
150
|
};
|
|
151
|
+
showTitle: {
|
|
152
|
+
type: BooleanConstructor;
|
|
153
|
+
default: true;
|
|
154
|
+
};
|
|
126
155
|
options: {
|
|
127
156
|
type: import("vue").PropType<PickerOption[]>;
|
|
128
157
|
default: () => PickerOption[];
|
|
@@ -143,25 +172,37 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
143
172
|
type: import("vue").PropType<number[]>;
|
|
144
173
|
default: () => number[];
|
|
145
174
|
};
|
|
175
|
+
selectedValue: {
|
|
176
|
+
type: import("vue").PropType<Numeric[]>;
|
|
177
|
+
default: () => Numeric[];
|
|
178
|
+
};
|
|
179
|
+
popup: {
|
|
180
|
+
type: BooleanConstructor;
|
|
181
|
+
default: true;
|
|
182
|
+
};
|
|
146
183
|
}>> & {
|
|
147
184
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
148
185
|
onCancel?: ((...args: any[]) => any) | undefined;
|
|
149
186
|
onConfirm?: ((...args: any[]) => any) | undefined;
|
|
150
187
|
"onUpdate:showPicker"?: ((...args: any[]) => any) | undefined;
|
|
151
188
|
"onUpdate:selectedIndex"?: ((...args: any[]) => any) | undefined;
|
|
189
|
+
"onUpdate:selectedValue"?: ((...args: any[]) => any) | undefined;
|
|
152
190
|
}, {
|
|
153
191
|
readonly: boolean;
|
|
154
192
|
closeOnClickOverlay: boolean;
|
|
155
193
|
closeOnPopstate: boolean;
|
|
194
|
+
popup: boolean;
|
|
156
195
|
loading: boolean;
|
|
196
|
+
showTitle: boolean;
|
|
157
197
|
options: PickerOption[];
|
|
158
198
|
allowHtml: boolean;
|
|
199
|
+
showToolbar: boolean;
|
|
200
|
+
showPicker: boolean;
|
|
159
201
|
textKey: string;
|
|
160
202
|
itemHeight: string | number;
|
|
161
203
|
columnCounts: number;
|
|
162
|
-
showPicker: boolean;
|
|
163
|
-
showToolbar: boolean;
|
|
164
204
|
toolbarPosition: string;
|
|
165
205
|
selectedIndex: number[];
|
|
206
|
+
selectedValue: Numeric[];
|
|
166
207
|
}, {}>;
|
|
167
208
|
export default _default;
|
|
@@ -2,6 +2,7 @@ import { createVNode as _createVNode } from "vue";
|
|
|
2
2
|
import { ref, watch, computed, defineComponent } from "vue";
|
|
3
3
|
import { createNamespace, makeArrayProp, makeNumberProp, makeNumericProp, makeStringProp, truthProp } from "../utils/index.mjs";
|
|
4
4
|
import { unitToPx } from "../utils/format.mjs";
|
|
5
|
+
import { deepClone } from "../utils/deep-clone.mjs";
|
|
5
6
|
import Loading from "../loading/index.mjs";
|
|
6
7
|
import MultiplePickerOptions from "./MultiplePickerOptions.mjs";
|
|
7
8
|
import Popup from "../popup/index.mjs";
|
|
@@ -19,21 +20,37 @@ const multiplePickerProps = {
|
|
|
19
20
|
closeOnPopstate: truthProp,
|
|
20
21
|
closeOnClickOverlay: truthProp,
|
|
21
22
|
showToolbar: truthProp,
|
|
23
|
+
showTitle: truthProp,
|
|
22
24
|
options: makeArrayProp(),
|
|
23
25
|
toolbarPosition: makeStringProp("bottom"),
|
|
24
26
|
textKey: makeStringProp("text"),
|
|
25
27
|
columnCounts: makeNumberProp(3),
|
|
26
|
-
selectedIndex: makeArrayProp([])
|
|
28
|
+
selectedIndex: makeArrayProp([]),
|
|
29
|
+
selectedValue: makeArrayProp([]),
|
|
30
|
+
popup: truthProp
|
|
27
31
|
};
|
|
28
32
|
var stdin_default = defineComponent({
|
|
29
33
|
name,
|
|
30
34
|
props: multiplePickerProps,
|
|
31
|
-
emits: ["cancel", "confirm", "change", "update:showPicker", "update:selectedIndex"],
|
|
35
|
+
emits: ["cancel", "confirm", "change", "update:showPicker", "update:selectedIndex", "update:selectedValue"],
|
|
32
36
|
setup(props, {
|
|
33
37
|
emit,
|
|
34
38
|
slots
|
|
35
39
|
}) {
|
|
36
40
|
const confirmIndexes = ref(props.selectedIndex);
|
|
41
|
+
const confirmValues = ref(props.selectedValue);
|
|
42
|
+
const getIndexesByValues = () => {
|
|
43
|
+
var _a;
|
|
44
|
+
if (confirmValues.value && confirmValues.value.length > 0) {
|
|
45
|
+
confirmIndexes.value.splice(0, confirmIndexes.value.length);
|
|
46
|
+
(_a = props.options) == null ? void 0 : _a.forEach((option, index) => {
|
|
47
|
+
if (option.value && confirmValues.value.includes(option.value)) {
|
|
48
|
+
confirmIndexes.value.push(index);
|
|
49
|
+
}
|
|
50
|
+
});
|
|
51
|
+
}
|
|
52
|
+
};
|
|
53
|
+
getIndexesByValues();
|
|
37
54
|
const pickerOptions = ref();
|
|
38
55
|
const currentShow = ref(props.showPicker);
|
|
39
56
|
const DEFAULT_ITEM_HEIGHT = ref(36);
|
|
@@ -41,7 +58,9 @@ var stdin_default = defineComponent({
|
|
|
41
58
|
if (newValue !== props.showPicker) {
|
|
42
59
|
emit("update:showPicker", newValue);
|
|
43
60
|
}
|
|
44
|
-
confirmIndexes.value = props.selectedIndex;
|
|
61
|
+
confirmIndexes.value = deepClone(props.selectedIndex);
|
|
62
|
+
confirmValues.value = deepClone(props.selectedValue);
|
|
63
|
+
getIndexesByValues();
|
|
45
64
|
});
|
|
46
65
|
watch(() => props.showPicker, (newValue) => {
|
|
47
66
|
var _a;
|
|
@@ -78,12 +97,14 @@ var stdin_default = defineComponent({
|
|
|
78
97
|
emit("confirm", options);
|
|
79
98
|
};
|
|
80
99
|
const genTitle = () => {
|
|
81
|
-
if (
|
|
82
|
-
|
|
100
|
+
if (props.showTitle) {
|
|
101
|
+
if (slots.title) {
|
|
102
|
+
return slots.title();
|
|
103
|
+
}
|
|
104
|
+
return _createVNode("div", {
|
|
105
|
+
"class": ["zt-ellipsis", bem("title")]
|
|
106
|
+
}, [props.title ? props.title : "\u8BF7\u9009\u62E9"]);
|
|
83
107
|
}
|
|
84
|
-
return _createVNode("div", {
|
|
85
|
-
"class": ["zt-ellipsis", bem("title")]
|
|
86
|
-
}, [props.title ? props.title : "\u8BF7\u9009\u62E9"]);
|
|
87
108
|
};
|
|
88
109
|
const genCancel = () => {
|
|
89
110
|
const text = props.cancelButtonText || "\u53D6\u6D88";
|
|
@@ -152,16 +173,22 @@ var stdin_default = defineComponent({
|
|
|
152
173
|
}, [genTitle(), props.loading ? _createVNode(Loading, {
|
|
153
174
|
"class": bem("loading")
|
|
154
175
|
}, null) : "", genOptions(), props.toolbarPosition === "bottom" ? genToolbar() : ""]);
|
|
155
|
-
return () =>
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
176
|
+
return () => {
|
|
177
|
+
if (props.popup) {
|
|
178
|
+
return _createVNode(Popup, {
|
|
179
|
+
"show": currentShow.value,
|
|
180
|
+
"onUpdate:show": [($event) => currentShow.value = $event, updateShow],
|
|
181
|
+
"round": true,
|
|
182
|
+
"position": "bottom",
|
|
183
|
+
"closeOnPopstate": props.closeOnPopstate,
|
|
184
|
+
"closeOnClickOverlay": props.closeOnClickOverlay
|
|
185
|
+
}, {
|
|
186
|
+
default: renderMultiplePicker
|
|
187
|
+
});
|
|
188
|
+
} else {
|
|
189
|
+
return renderMultiplePicker();
|
|
190
|
+
}
|
|
191
|
+
};
|
|
165
192
|
}
|
|
166
193
|
});
|
|
167
194
|
export {
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { createVNode as _createVNode } from "vue";
|
|
2
2
|
import { ref, defineComponent, reactive } from "vue";
|
|
3
3
|
import { createNamespace, isObject, makeArrayProp, makeNumberProp, makeStringProp } from "../utils/index.mjs";
|
|
4
|
+
import { deepClone } from "../utils/deep-clone.mjs";
|
|
4
5
|
import { useExpose } from "../composables/use-expose.mjs";
|
|
5
6
|
const [name, bem] = createNamespace("multiple-picker-options");
|
|
6
7
|
const multiplePickerOptionsProps = {
|
|
@@ -49,7 +50,7 @@ var stdin_default = defineComponent({
|
|
|
49
50
|
}
|
|
50
51
|
return option;
|
|
51
52
|
};
|
|
52
|
-
const isOptionDisabled = (option) => isObject(option) && option.disabled;
|
|
53
|
+
const isOptionDisabled = (option) => props.readonly || isObject(option) && option.disabled;
|
|
53
54
|
const genOptions = () => {
|
|
54
55
|
columnCounts.value = Number(props.columnCounts);
|
|
55
56
|
if (columnCounts.value && columnCounts.value > 3) {
|
|
@@ -77,12 +78,14 @@ var stdin_default = defineComponent({
|
|
|
77
78
|
"class": [bem("item", {
|
|
78
79
|
disabled,
|
|
79
80
|
selected: currentIndexes.value.indexOf(index) > -1,
|
|
81
|
+
"disabled-selected": disabled && currentIndexes.value.indexOf(index) > -1,
|
|
80
82
|
last: (index + 1) % columnCounts.value === 0
|
|
81
83
|
})]
|
|
82
84
|
}, [slots.options ? slots.options(option) : _createVNode("div", childData, null)]);
|
|
83
85
|
});
|
|
84
86
|
};
|
|
85
|
-
const setConfirmIndex = (
|
|
87
|
+
const setConfirmIndex = (data) => {
|
|
88
|
+
const indexes = deepClone(data);
|
|
86
89
|
state.confirmed = true;
|
|
87
90
|
const keys = Object.keys(indexes);
|
|
88
91
|
currentIndexes.value.length = 0;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
:root{--zt-multiple-picker-warpper-padding: 12px 16px 4px 16px;--zt-multiple-picker-option-text-color: var(--zt-gray-a6);--zt-multiple-picker-background-color: var(--zt-background-popup);--zt-multiple-picker-toolbar-height: 44px;--zt-multiple-picker-title-text-color: var(--zt-gray-a4);--zt-multiple-picker-title-padding: 12px 0;--zt-multiple-picker-item-padding: 0 4px 8px 0;--zt-multiple-picker-option-disabled-opacity: var(--zt-disabled-opacity);--zt-multiple-picker-max-height: 84vh;--zt-multiple-picker-loading-icon-color: var(--zt-primary-color);--zt-multiple-picker-loading-mask-color: var(--zt-picker-loading-mask-color);--zt-multiple-picker-toolbar-padding: 8px 16px;--zt-multiple-picker-ellipsis-border: 1px solid var(--zt-gray-a2);--zt-multiple-picker-title-background: var(--zt-background-popup);--zt-multiple-picker-ellipsis-height: 38px}:root[zt-theme-size=large]{--zt-multiple-picker-ellipsis-height: 50px}.zt-multiple-picker{display:flex;flex-direction:column;justify-content:space-between;position:relative;background-color:var(--zt-multiple-picker-background-color);-webkit-user-select:none;user-select:none;max-height:var(--zt-multiple-picker-max-height)}.zt-multiple-picker__toolbar{display:flex;align-items:center;justify-content:space-between;box-sizing:content-box;flex-shrink:0;background:var(--zt-multiple-picker-title-background);height:var(--zt-multiple-picker-toolbar-height);padding:var(--zt-multiple-picker-toolbar-padding)}.zt-multiple-picker__title{flex-shrink:0;font-weight:var(--zt-multiple-picker-cancel-action-font-weight);font-size:var(--zt-font-size-md);line-height:var(--zt-line-height-md);text-align:center;background:var(--zt-multiple-picker-title-background);color:var(--zt-multiple-picker-title-text-color);padding:var(--zt-multiple-picker-title-padding)}.zt-multiple-picker__options{position:relative;display:flex;cursor:-webkit-grab;cursor:grab;overflow-y:scroll}.zt-multiple-picker__options:after{position:absolute;box-sizing:border-box;content:" ";pointer-events:none;right:0;bottom:0;left:0;border-bottom:1px solid var(--zt-border-color);transform:scaleY(.5)}.zt-multiple-picker__options:before{position:absolute;box-sizing:border-box;content:" ";pointer-events:none;top:0;right:0;left:0;border-top:1px solid var(--zt-border-color);transform:scaleY(.5)}.zt-multiple-picker__loading{position:absolute;top:0;right:0;bottom:0;left:0;z-index:3;display:flex;align-items:center;justify-content:center;color:var(--zt-multiple-picker-loading-icon-color);background-color:var(--zt-multiple-picker-loading-mask-color)}.zt-multiple-picker-options{flex:1;overflow-y:scroll;font-size:var(--zt-font-size-md);margin:0;outline:0 none;padding:0}.zt-multiple-picker-options__wrapper{display:flex;flex-wrap:wrap;background-color:var(--zt-multiple-picker-background-color);padding:var(--zt-multiple-picker-warpper-padding)}.zt-multiple-picker-options__item{color:var(--zt-multiple-picker-option-text-color);padding:var(--zt-multiple-picker-item-padding);box-sizing:border-box;text-align:center;font-size:var(--zt-font-size-md)}.zt-multiple-picker-options__item .zt-ellipsis{height:var(--zt-multiple-picker-ellipsis-height);line-height:var(--zt-multiple-picker-ellipsis-height);border-radius:calc(var(--zt-multiple-picker-ellipsis-height) / 2);border:var(--zt-multiple-picker-ellipsis-border);padding:0 var(--zt-padding-md)}.zt-multiple-picker-options__item:active{opacity:var(--zt-active-opacity)}.zt-multiple-picker-options__item--disabled{cursor:not-allowed;
|
|
1
|
+
:root{--zt-multiple-picker-warpper-padding: 12px 16px 4px 16px;--zt-multiple-picker-option-text-color: var(--zt-gray-a6);--zt-multiple-picker-background-color: var(--zt-background-popup);--zt-multiple-picker-toolbar-height: 44px;--zt-multiple-picker-title-text-color: var(--zt-gray-a4);--zt-multiple-picker-title-padding: 12px 0;--zt-multiple-picker-item-padding: 0 4px 8px 0;--zt-multiple-picker-option-disabled-opacity: var(--zt-disabled-opacity);--zt-multiple-picker-option-disabled-background: var(--zt-gray-a04);--zt-multiple-picker-max-height: 84vh;--zt-multiple-picker-loading-icon-color: var(--zt-primary-color);--zt-multiple-picker-loading-mask-color: var(--zt-picker-loading-mask-color);--zt-multiple-picker-toolbar-padding: 8px 16px;--zt-multiple-picker-ellipsis-border: 1px solid var(--zt-gray-a2);--zt-multiple-picker-ellipsis-border-selected: 1px solid var(--zt-blue-a6);--zt-multiple-picker-title-background: var(--zt-background-popup);--zt-multiple-picker-ellipsis-height: 38px}:root[zt-theme-size=large]{--zt-multiple-picker-ellipsis-height: 50px}.zt-multiple-picker{display:flex;flex-direction:column;justify-content:space-between;position:relative;background-color:var(--zt-multiple-picker-background-color);-webkit-user-select:none;user-select:none;max-height:var(--zt-multiple-picker-max-height)}.zt-multiple-picker__toolbar{display:flex;align-items:center;justify-content:space-between;box-sizing:content-box;flex-shrink:0;background:var(--zt-multiple-picker-title-background);height:var(--zt-multiple-picker-toolbar-height);padding:var(--zt-multiple-picker-toolbar-padding)}.zt-multiple-picker__title{flex-shrink:0;font-weight:var(--zt-multiple-picker-cancel-action-font-weight);font-size:var(--zt-font-size-md);line-height:var(--zt-line-height-md);text-align:center;background:var(--zt-multiple-picker-title-background);color:var(--zt-multiple-picker-title-text-color);padding:var(--zt-multiple-picker-title-padding)}.zt-multiple-picker__options{position:relative;display:flex;cursor:-webkit-grab;cursor:grab;overflow-y:scroll}.zt-multiple-picker__options:after{position:absolute;box-sizing:border-box;content:" ";pointer-events:none;right:0;bottom:0;left:0;border-bottom:1px solid var(--zt-border-color);transform:scaleY(.5)}.zt-multiple-picker__options:before{position:absolute;box-sizing:border-box;content:" ";pointer-events:none;top:0;right:0;left:0;border-top:1px solid var(--zt-border-color);transform:scaleY(.5)}.zt-multiple-picker__loading{position:absolute;top:0;right:0;bottom:0;left:0;z-index:3;display:flex;align-items:center;justify-content:center;color:var(--zt-multiple-picker-loading-icon-color);background-color:var(--zt-multiple-picker-loading-mask-color)}.zt-multiple-picker-options{flex:1;overflow-y:scroll;font-size:var(--zt-font-size-md);margin:0;outline:0 none;padding:0}.zt-multiple-picker-options__wrapper{display:flex;flex-wrap:wrap;background-color:var(--zt-multiple-picker-background-color);padding:var(--zt-multiple-picker-warpper-padding)}.zt-multiple-picker-options__item{color:var(--zt-multiple-picker-option-text-color);padding:var(--zt-multiple-picker-item-padding);box-sizing:border-box;text-align:center;font-size:var(--zt-font-size-md)}.zt-multiple-picker-options__item .zt-ellipsis{height:var(--zt-multiple-picker-ellipsis-height);line-height:var(--zt-multiple-picker-ellipsis-height);border-radius:calc(var(--zt-multiple-picker-ellipsis-height) / 2);border:var(--zt-multiple-picker-ellipsis-border);padding:0 var(--zt-padding-md)}.zt-multiple-picker-options__item:active{opacity:var(--zt-active-opacity)}.zt-multiple-picker-options__item--disabled{cursor:not-allowed;color:var(--zt-gray-a2)}.zt-multiple-picker-options__item--disabled .zt-ellipsis{background:var(--zt-multiple-picker-option-disabled-background);border:0}.zt-multiple-picker-options__item--last{padding-right:0}.zt-multiple-picker-options__item--selected{color:var(--zt-primary-color)}.zt-multiple-picker-options__item--selected .zt-ellipsis{background:var(--zt-primary-color-a1);border:var(--zt-multiple-picker-ellipsis-border-selected)}.zt-multiple-picker-options__item--disabled-selected{cursor:not-allowed;color:var(--zt-gray)!important}.zt-multiple-picker-options__item--disabled-selected .zt-ellipsis{background:var(--zt-picker-option-disabled-background)!important;border:0!important}
|
|
@@ -27,6 +27,10 @@ export declare const MultiplePicker: import("../utils").WithInstall<import("vue"
|
|
|
27
27
|
type: BooleanConstructor;
|
|
28
28
|
default: true;
|
|
29
29
|
};
|
|
30
|
+
showTitle: {
|
|
31
|
+
type: BooleanConstructor;
|
|
32
|
+
default: true;
|
|
33
|
+
};
|
|
30
34
|
options: {
|
|
31
35
|
type: import("vue").PropType<import("./types").PickerOption[]>;
|
|
32
36
|
default: () => import("./types").PickerOption[];
|
|
@@ -47,7 +51,15 @@ export declare const MultiplePicker: import("../utils").WithInstall<import("vue"
|
|
|
47
51
|
type: import("vue").PropType<number[]>;
|
|
48
52
|
default: () => number[];
|
|
49
53
|
};
|
|
50
|
-
|
|
54
|
+
selectedValue: {
|
|
55
|
+
type: import("vue").PropType<import("../utils").Numeric[]>;
|
|
56
|
+
default: () => import("../utils").Numeric[];
|
|
57
|
+
};
|
|
58
|
+
popup: {
|
|
59
|
+
type: BooleanConstructor;
|
|
60
|
+
default: true;
|
|
61
|
+
};
|
|
62
|
+
}, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("cancel" | "change" | "confirm" | "update:showPicker" | "update:selectedIndex" | "update:selectedValue")[], "cancel" | "change" | "confirm" | "update:showPicker" | "update:selectedIndex" | "update:selectedValue", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
51
63
|
title: StringConstructor;
|
|
52
64
|
loading: BooleanConstructor;
|
|
53
65
|
readonly: BooleanConstructor;
|
|
@@ -74,6 +86,10 @@ export declare const MultiplePicker: import("../utils").WithInstall<import("vue"
|
|
|
74
86
|
type: BooleanConstructor;
|
|
75
87
|
default: true;
|
|
76
88
|
};
|
|
89
|
+
showTitle: {
|
|
90
|
+
type: BooleanConstructor;
|
|
91
|
+
default: true;
|
|
92
|
+
};
|
|
77
93
|
options: {
|
|
78
94
|
type: import("vue").PropType<import("./types").PickerOption[]>;
|
|
79
95
|
default: () => import("./types").PickerOption[];
|
|
@@ -94,26 +110,38 @@ export declare const MultiplePicker: import("../utils").WithInstall<import("vue"
|
|
|
94
110
|
type: import("vue").PropType<number[]>;
|
|
95
111
|
default: () => number[];
|
|
96
112
|
};
|
|
113
|
+
selectedValue: {
|
|
114
|
+
type: import("vue").PropType<import("../utils").Numeric[]>;
|
|
115
|
+
default: () => import("../utils").Numeric[];
|
|
116
|
+
};
|
|
117
|
+
popup: {
|
|
118
|
+
type: BooleanConstructor;
|
|
119
|
+
default: true;
|
|
120
|
+
};
|
|
97
121
|
}>> & {
|
|
98
122
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
99
123
|
onCancel?: ((...args: any[]) => any) | undefined;
|
|
100
124
|
onConfirm?: ((...args: any[]) => any) | undefined;
|
|
101
125
|
"onUpdate:showPicker"?: ((...args: any[]) => any) | undefined;
|
|
102
126
|
"onUpdate:selectedIndex"?: ((...args: any[]) => any) | undefined;
|
|
127
|
+
"onUpdate:selectedValue"?: ((...args: any[]) => any) | undefined;
|
|
103
128
|
}, {
|
|
104
129
|
readonly: boolean;
|
|
105
130
|
closeOnClickOverlay: boolean;
|
|
106
131
|
closeOnPopstate: boolean;
|
|
132
|
+
popup: boolean;
|
|
107
133
|
loading: boolean;
|
|
134
|
+
showTitle: boolean;
|
|
108
135
|
options: import("./types").PickerOption[];
|
|
109
136
|
allowHtml: boolean;
|
|
137
|
+
showToolbar: boolean;
|
|
138
|
+
showPicker: boolean;
|
|
110
139
|
textKey: string;
|
|
111
140
|
itemHeight: string | number;
|
|
112
141
|
columnCounts: number;
|
|
113
|
-
showPicker: boolean;
|
|
114
|
-
showToolbar: boolean;
|
|
115
142
|
toolbarPosition: string;
|
|
116
143
|
selectedIndex: number[];
|
|
144
|
+
selectedValue: import("../utils").Numeric[];
|
|
117
145
|
}, {}>>;
|
|
118
146
|
export default MultiplePicker;
|
|
119
147
|
export type { MultiplePickerProps };
|
package/es/picker/Picker.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { PropType, ExtractPropTypes } from 'vue';
|
|
2
2
|
import { Numeric } from '../utils';
|
|
3
|
-
import type { PickerColumn, PickerOption, PickerFieldNames, PickerToolbarPosition } from './types';
|
|
3
|
+
import type { PickerColumn, PickerOption, PickerFieldNames, PickerShowType, PickerToolbarPosition } from './types';
|
|
4
4
|
export declare const pickerSharedProps: {
|
|
5
5
|
loading: BooleanConstructor;
|
|
6
6
|
readonly: BooleanConstructor;
|
|
@@ -87,6 +87,14 @@ export declare const pickerProps: {
|
|
|
87
87
|
type: BooleanConstructor;
|
|
88
88
|
default: true;
|
|
89
89
|
};
|
|
90
|
+
showType: {
|
|
91
|
+
type: PropType<PickerShowType>;
|
|
92
|
+
default: PickerShowType;
|
|
93
|
+
};
|
|
94
|
+
columnCounts: {
|
|
95
|
+
type: NumberConstructor;
|
|
96
|
+
default: number;
|
|
97
|
+
};
|
|
90
98
|
};
|
|
91
99
|
export type PickerProps = ExtractPropTypes<typeof pickerProps>;
|
|
92
100
|
declare const _default: import("vue").DefineComponent<{
|
|
@@ -143,7 +151,15 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
143
151
|
type: BooleanConstructor;
|
|
144
152
|
default: true;
|
|
145
153
|
};
|
|
146
|
-
|
|
154
|
+
showType: {
|
|
155
|
+
type: PropType<PickerShowType>;
|
|
156
|
+
default: PickerShowType;
|
|
157
|
+
};
|
|
158
|
+
columnCounts: {
|
|
159
|
+
type: NumberConstructor;
|
|
160
|
+
default: number;
|
|
161
|
+
};
|
|
162
|
+
}, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("update:modelValue" | "cancel" | "change" | "confirm" | "clickOption" | "update:showPicker")[], "update:modelValue" | "cancel" | "change" | "confirm" | "clickOption" | "update:showPicker", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<ExtractPropTypes<{
|
|
147
163
|
loading: BooleanConstructor;
|
|
148
164
|
readonly: BooleanConstructor;
|
|
149
165
|
allowHtml: BooleanConstructor;
|
|
@@ -197,25 +213,35 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
197
213
|
type: BooleanConstructor;
|
|
198
214
|
default: true;
|
|
199
215
|
};
|
|
216
|
+
showType: {
|
|
217
|
+
type: PropType<PickerShowType>;
|
|
218
|
+
default: PickerShowType;
|
|
219
|
+
};
|
|
220
|
+
columnCounts: {
|
|
221
|
+
type: NumberConstructor;
|
|
222
|
+
default: number;
|
|
223
|
+
};
|
|
200
224
|
}>> & {
|
|
201
225
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
202
226
|
"onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
|
|
203
227
|
onCancel?: ((...args: any[]) => any) | undefined;
|
|
204
228
|
onConfirm?: ((...args: any[]) => any) | undefined;
|
|
205
|
-
"onUpdate:showPicker"?: ((...args: any[]) => any) | undefined;
|
|
206
229
|
onClickOption?: ((...args: any[]) => any) | undefined;
|
|
230
|
+
"onUpdate:showPicker"?: ((...args: any[]) => any) | undefined;
|
|
207
231
|
}, {
|
|
208
232
|
title: string;
|
|
209
233
|
modelValue: Numeric[];
|
|
210
234
|
readonly: boolean;
|
|
211
235
|
popup: boolean;
|
|
212
236
|
loading: boolean;
|
|
237
|
+
showType: PickerShowType;
|
|
213
238
|
showTitle: boolean;
|
|
214
239
|
columns: (PickerColumn | PickerOption)[];
|
|
215
240
|
allowHtml: boolean;
|
|
216
241
|
swipeDuration: string | number;
|
|
217
|
-
showPicker: boolean;
|
|
218
242
|
showToolbar: boolean;
|
|
243
|
+
showPicker: boolean;
|
|
244
|
+
columnCounts: number;
|
|
219
245
|
toolbarPosition: PickerToolbarPosition;
|
|
220
246
|
optionHeight: string | number;
|
|
221
247
|
visibleOptionNum: string | number;
|
package/es/picker/Picker.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { mergeProps as _mergeProps, createVNode as _createVNode } from "vue";
|
|
2
2
|
import { ref, watch, computed, defineComponent, nextTick } from "vue";
|
|
3
|
-
import { pick, extend, unitToPx, truthProp, HAPTICS_FEEDBACK, isSameValue, makeArrayProp, preventDefault, makeStringProp, makeNumericProp } from "../utils/index.mjs";
|
|
3
|
+
import { pick, extend, unitToPx, truthProp, HAPTICS_FEEDBACK, isSameValue, makeArrayProp, preventDefault, makeStringProp, makeNumericProp, makeNumberProp } from "../utils/index.mjs";
|
|
4
4
|
import { bem, name, isOptionExist, getColumnsType, findOptionByValue, assignDefaultFields, formatCascadeColumns, getFirstEnabledOption } from "./utils.mjs";
|
|
5
5
|
import { useChildren, useEventListener } from "@zartui/use";
|
|
6
6
|
import { useExpose } from "../composables/use-expose.mjs";
|
|
@@ -9,6 +9,7 @@ import Column, { PICKER_KEY } from "./PickerColumn.mjs";
|
|
|
9
9
|
import { Divider } from "../divider/index.mjs";
|
|
10
10
|
import Toolbar, { pickerToolbarPropKeys, pickerToolbarProps, pickerToolbarSlots } from "./PickerToolbar.mjs";
|
|
11
11
|
import Popup from "../popup/index.mjs";
|
|
12
|
+
import PickerOptions from "./PickerOptions.mjs";
|
|
12
13
|
const pickerSharedProps = extend({
|
|
13
14
|
loading: Boolean,
|
|
14
15
|
readonly: Boolean,
|
|
@@ -27,7 +28,9 @@ const pickerProps = extend({}, pickerSharedProps, {
|
|
|
27
28
|
toolbarPosition: makeStringProp("top"),
|
|
28
29
|
columnsFieldNames: Object,
|
|
29
30
|
showPicker: Boolean,
|
|
30
|
-
popup: truthProp
|
|
31
|
+
popup: truthProp,
|
|
32
|
+
showType: makeStringProp("default"),
|
|
33
|
+
columnCounts: makeNumberProp(3)
|
|
31
34
|
});
|
|
32
35
|
var stdin_default = defineComponent({
|
|
33
36
|
name,
|
|
@@ -37,6 +40,7 @@ var stdin_default = defineComponent({
|
|
|
37
40
|
emit,
|
|
38
41
|
slots
|
|
39
42
|
}) {
|
|
43
|
+
const pickerOptions = ref();
|
|
40
44
|
const columnsRef = ref();
|
|
41
45
|
const selectedValues = ref(props.modelValue.slice(0));
|
|
42
46
|
const showPicker = ref(props.showPicker);
|
|
@@ -63,6 +67,9 @@ var stdin_default = defineComponent({
|
|
|
63
67
|
});
|
|
64
68
|
const hasOptions = computed(() => currentColumns.value.some((options) => options.length));
|
|
65
69
|
const selectedOptions = computed(() => currentColumns.value.map((options, index) => findOptionByValue(options, selectedValues.value[index], fields.value)));
|
|
70
|
+
const isButtonPicker = computed(() => {
|
|
71
|
+
return props.showType === "button" && columnsType.value === "default";
|
|
72
|
+
});
|
|
66
73
|
watch(showPicker, (newValue) => {
|
|
67
74
|
if (newValue !== props.showPicker) {
|
|
68
75
|
emit("update:showPicker", newValue);
|
|
@@ -100,10 +107,12 @@ var stdin_default = defineComponent({
|
|
|
100
107
|
}, getEventParams()));
|
|
101
108
|
});
|
|
102
109
|
};
|
|
103
|
-
const onClickOption = (currentOption, columnIndex) =>
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
110
|
+
const onClickOption = (currentOption, columnIndex) => {
|
|
111
|
+
emit("clickOption", extend({
|
|
112
|
+
columnIndex,
|
|
113
|
+
currentOption
|
|
114
|
+
}, getEventParams()));
|
|
115
|
+
};
|
|
107
116
|
const confirm = () => {
|
|
108
117
|
children.forEach((child) => child.stopMomentum());
|
|
109
118
|
const params = getEventParams();
|
|
@@ -185,7 +194,8 @@ var stdin_default = defineComponent({
|
|
|
185
194
|
}, null) : null;
|
|
186
195
|
watch(currentColumns, (columns) => {
|
|
187
196
|
columns.forEach((options, index) => {
|
|
188
|
-
|
|
197
|
+
const judgeSelectedValue = isButtonPicker.value ? selectedValues.value[index] : true;
|
|
198
|
+
if (options.length && judgeSelectedValue && !isOptionExist(options, selectedValues.value[index], fields.value)) {
|
|
189
199
|
setValue(index, getFirstEnabledOption(options)[fields.value.value]);
|
|
190
200
|
}
|
|
191
201
|
});
|
|
@@ -225,18 +235,61 @@ var stdin_default = defineComponent({
|
|
|
225
235
|
"class": bem("loading")
|
|
226
236
|
}, null) : null, topDivider(), (_a = slots["columns-top"]) == null ? void 0 : _a.call(slots), renderColumns(), (_b = slots["columns-bottom"]) == null ? void 0 : _b.call(slots), buttomDivider(), renderToolbar()]);
|
|
227
237
|
};
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
return _createVNode(
|
|
231
|
-
"
|
|
232
|
-
"
|
|
233
|
-
"
|
|
234
|
-
"
|
|
238
|
+
const renderOptionItems = () => {
|
|
239
|
+
return currentColumns.value.map((options, columnIndex) => {
|
|
240
|
+
return _createVNode(PickerOptions, {
|
|
241
|
+
"ref": pickerOptions,
|
|
242
|
+
"value": selectedValues.value[columnIndex],
|
|
243
|
+
"columnCounts": props.columnCounts,
|
|
244
|
+
"fields": fields.value,
|
|
245
|
+
"options": options,
|
|
246
|
+
"allowHtml": props.allowHtml,
|
|
247
|
+
"readonly": props.readonly,
|
|
248
|
+
"itemHeight": optionHeight.value,
|
|
249
|
+
"onChange": (value) => onChange(value, columnIndex),
|
|
250
|
+
"onClickOption": (option) => onClickOption(option, columnIndex)
|
|
235
251
|
}, {
|
|
236
|
-
|
|
252
|
+
option: slots.option
|
|
237
253
|
});
|
|
254
|
+
});
|
|
255
|
+
};
|
|
256
|
+
const renderOptions = () => _createVNode("div", {
|
|
257
|
+
"class": bem("options")
|
|
258
|
+
}, [renderOptionItems()]);
|
|
259
|
+
const renderTiledPicker = () => {
|
|
260
|
+
var _a, _b;
|
|
261
|
+
return _createVNode("div", {
|
|
262
|
+
"class": bem()
|
|
263
|
+
}, [renderTitleBar(), props.loading ? _createVNode(Loading, {
|
|
264
|
+
"class": bem("loading")
|
|
265
|
+
}, null) : null, topDivider(), (_a = slots["columns-top"]) == null ? void 0 : _a.call(slots), renderOptions(), (_b = slots["columns-bottom"]) == null ? void 0 : _b.call(slots), buttomDivider(), renderToolbar()]);
|
|
266
|
+
};
|
|
267
|
+
return () => {
|
|
268
|
+
if (isButtonPicker.value) {
|
|
269
|
+
if (props.popup) {
|
|
270
|
+
return _createVNode(Popup, {
|
|
271
|
+
"show": showPicker.value,
|
|
272
|
+
"onUpdate:show": [($event) => showPicker.value = $event, updateShow],
|
|
273
|
+
"round": true,
|
|
274
|
+
"position": "bottom"
|
|
275
|
+
}, {
|
|
276
|
+
default: renderTiledPicker
|
|
277
|
+
});
|
|
278
|
+
}
|
|
279
|
+
return renderTiledPicker();
|
|
280
|
+
} else {
|
|
281
|
+
if (props.popup) {
|
|
282
|
+
return _createVNode(Popup, {
|
|
283
|
+
"show": showPicker.value,
|
|
284
|
+
"onUpdate:show": [($event) => showPicker.value = $event, updateShow],
|
|
285
|
+
"round": true,
|
|
286
|
+
"position": "bottom"
|
|
287
|
+
}, {
|
|
288
|
+
default: renderPicker
|
|
289
|
+
});
|
|
290
|
+
}
|
|
291
|
+
return renderPicker();
|
|
238
292
|
}
|
|
239
|
-
return renderPicker();
|
|
240
293
|
};
|
|
241
294
|
}
|
|
242
295
|
});
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
import { ExtractPropTypes, PropType } from 'vue';
|
|
2
|
+
import { PickerOption, PickerFieldNames } from './types';
|
|
3
|
+
declare const pickerOptionsProps: {
|
|
4
|
+
value: (NumberConstructor | StringConstructor)[];
|
|
5
|
+
fields: {
|
|
6
|
+
type: PropType<Required<PickerFieldNames>>;
|
|
7
|
+
required: true;
|
|
8
|
+
};
|
|
9
|
+
readonly: BooleanConstructor;
|
|
10
|
+
allowHtml: BooleanConstructor;
|
|
11
|
+
itemHeight: {
|
|
12
|
+
type: NumberConstructor;
|
|
13
|
+
default: number;
|
|
14
|
+
};
|
|
15
|
+
columnCounts: {
|
|
16
|
+
type: NumberConstructor;
|
|
17
|
+
default: number;
|
|
18
|
+
};
|
|
19
|
+
options: {
|
|
20
|
+
type: PropType<PickerOption[]>;
|
|
21
|
+
default: () => PickerOption[];
|
|
22
|
+
};
|
|
23
|
+
};
|
|
24
|
+
export type PickerOptionsProps = ExtractPropTypes<typeof pickerOptionsProps>;
|
|
25
|
+
declare const _default: import("vue").DefineComponent<{
|
|
26
|
+
value: (NumberConstructor | StringConstructor)[];
|
|
27
|
+
fields: {
|
|
28
|
+
type: PropType<Required<PickerFieldNames>>;
|
|
29
|
+
required: true;
|
|
30
|
+
};
|
|
31
|
+
readonly: BooleanConstructor;
|
|
32
|
+
allowHtml: BooleanConstructor;
|
|
33
|
+
itemHeight: {
|
|
34
|
+
type: NumberConstructor;
|
|
35
|
+
default: number;
|
|
36
|
+
};
|
|
37
|
+
columnCounts: {
|
|
38
|
+
type: NumberConstructor;
|
|
39
|
+
default: number;
|
|
40
|
+
};
|
|
41
|
+
options: {
|
|
42
|
+
type: PropType<PickerOption[]>;
|
|
43
|
+
default: () => PickerOption[];
|
|
44
|
+
};
|
|
45
|
+
}, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("change" | "clickOption")[], "change" | "clickOption", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<ExtractPropTypes<{
|
|
46
|
+
value: (NumberConstructor | StringConstructor)[];
|
|
47
|
+
fields: {
|
|
48
|
+
type: PropType<Required<PickerFieldNames>>;
|
|
49
|
+
required: true;
|
|
50
|
+
};
|
|
51
|
+
readonly: BooleanConstructor;
|
|
52
|
+
allowHtml: BooleanConstructor;
|
|
53
|
+
itemHeight: {
|
|
54
|
+
type: NumberConstructor;
|
|
55
|
+
default: number;
|
|
56
|
+
};
|
|
57
|
+
columnCounts: {
|
|
58
|
+
type: NumberConstructor;
|
|
59
|
+
default: number;
|
|
60
|
+
};
|
|
61
|
+
options: {
|
|
62
|
+
type: PropType<PickerOption[]>;
|
|
63
|
+
default: () => PickerOption[];
|
|
64
|
+
};
|
|
65
|
+
}>> & {
|
|
66
|
+
onChange?: ((...args: any[]) => any) | undefined;
|
|
67
|
+
onClickOption?: ((...args: any[]) => any) | undefined;
|
|
68
|
+
}, {
|
|
69
|
+
readonly: boolean;
|
|
70
|
+
options: PickerOption[];
|
|
71
|
+
allowHtml: boolean;
|
|
72
|
+
itemHeight: number;
|
|
73
|
+
columnCounts: number;
|
|
74
|
+
}, {}>;
|
|
75
|
+
export default _default;
|