zartui 3.2.0 → 3.2.2
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/README.md +27 -27
- package/es/action-sheet/ActionSheet.d.ts +16 -3
- package/es/action-sheet/ActionSheet.mjs +30 -26
- package/es/action-sheet/index.css +1 -1
- package/es/action-sheet/index.d.ts +9 -2
- package/es/button/index.css +1 -1
- package/es/date-time-picker/DateTimePicker.d.ts +8 -0
- package/es/date-time-picker/DateTimePickerWrapper.d.ts +12 -0
- package/es/date-time-picker/index.d.ts +8 -0
- package/es/date-time-picker/utils.d.ts +4 -0
- package/es/dialog/Dialog.d.ts +6 -0
- package/es/dialog/Dialog.mjs +6 -2
- package/es/dialog/function-call.mjs +2 -0
- package/es/dialog/index.css +1 -1
- package/es/dialog/index.d.ts +4 -0
- package/es/dropdown-item/DropdownItem.mjs +1 -0
- package/es/index.d.ts +1 -0
- package/es/index.mjs +3 -0
- package/es/lazyload/vue-lazyload/index.d.ts +55 -55
- package/es/media-picker/MediaPicker.d.ts +7 -3
- package/es/media-picker/MediaPicker.mjs +76 -24
- package/es/media-picker/index.d.ts +3 -2
- package/es/media-picker/type.d.ts +2 -1
- package/es/picker/Picker.d.ts +16 -0
- package/es/picker/Picker.mjs +5 -15
- package/es/picker/PickerToolbar.d.ts +15 -1
- package/es/picker/PickerToolbar.mjs +17 -15
- package/es/picker/index.css +1 -1
- package/es/picker/index.d.ts +8 -0
- package/es/search/index.css +1 -1
- package/es/speech-recognizer/SpeechRecognizer.d.ts +51 -0
- package/es/speech-recognizer/SpeechRecognizer.mjs +209 -0
- package/es/speech-recognizer/index.css +1 -0
- package/es/speech-recognizer/index.d.ts +43 -0
- package/es/speech-recognizer/index.mjs +8 -0
- package/es/speech-recognizer/recorder.d.ts +53 -0
- package/es/speech-recognizer/recorder.mjs +75 -0
- package/es/speech-recognizer/style/index.d.ts +1 -0
- package/es/speech-recognizer/style/index.mjs +10 -0
- package/es/speech-recognizer/types.d.ts +0 -0
- package/es/speech-recognizer/types.mjs +0 -0
- package/es/tab/style/index.mjs +1 -0
- package/es/tabs/Tabs.mjs +47 -2
- package/es/tabs/index.css +1 -1
- package/es/tabs/style/index.mjs +1 -0
- package/es/time-picker/TimePicker.d.ts +12 -0
- package/es/time-picker/index.d.ts +8 -0
- package/es/vue-sfc-shim.d.ts +6 -6
- package/es/vue-tsx-shim.d.ts +23 -23
- package/lib/action-sheet/ActionSheet.d.ts +16 -3
- package/lib/action-sheet/ActionSheet.js +29 -25
- package/lib/action-sheet/index.css +1 -1
- package/lib/action-sheet/index.d.ts +9 -2
- package/lib/button/index.css +1 -1
- package/lib/date-time-picker/DateTimePicker.d.ts +8 -0
- package/lib/date-time-picker/DateTimePickerWrapper.d.ts +12 -0
- package/lib/date-time-picker/index.d.ts +8 -0
- package/lib/date-time-picker/utils.d.ts +4 -0
- package/lib/dialog/Dialog.d.ts +6 -0
- package/lib/dialog/Dialog.js +6 -2
- package/lib/dialog/function-call.js +2 -0
- package/lib/dialog/index.css +1 -1
- package/lib/dialog/index.d.ts +4 -0
- package/lib/dropdown-item/DropdownItem.js +1 -0
- package/lib/index.css +1 -1
- package/lib/index.d.ts +1 -0
- package/lib/index.js +3 -0
- package/lib/lazyload/vue-lazyload/index.d.ts +55 -55
- package/lib/media-picker/MediaPicker.d.ts +7 -3
- package/lib/media-picker/MediaPicker.js +75 -23
- package/lib/media-picker/index.d.ts +3 -2
- package/lib/media-picker/type.d.ts +2 -1
- package/lib/picker/Picker.d.ts +16 -0
- package/lib/picker/Picker.js +4 -14
- package/lib/picker/PickerToolbar.d.ts +15 -1
- package/lib/picker/PickerToolbar.js +16 -14
- package/lib/picker/index.css +1 -1
- package/lib/picker/index.d.ts +8 -0
- package/lib/search/index.css +1 -1
- package/lib/speech-recognizer/SpeechRecognizer.d.ts +51 -0
- package/lib/speech-recognizer/SpeechRecognizer.js +238 -0
- package/lib/speech-recognizer/index.css +1 -0
- package/lib/speech-recognizer/index.d.ts +43 -0
- package/lib/speech-recognizer/index.js +37 -0
- package/lib/speech-recognizer/recorder.d.ts +53 -0
- package/lib/speech-recognizer/recorder.js +94 -0
- package/lib/speech-recognizer/style/index.d.ts +1 -0
- package/lib/speech-recognizer/style/index.js +10 -0
- package/lib/speech-recognizer/types.d.ts +0 -0
- package/lib/speech-recognizer/types.js +0 -0
- package/lib/tab/style/index.js +1 -0
- package/lib/tabs/Tabs.js +47 -2
- package/lib/tabs/index.css +1 -1
- package/lib/tabs/style/index.js +1 -0
- package/lib/time-picker/TimePicker.d.ts +12 -0
- package/lib/time-picker/index.d.ts +8 -0
- package/lib/vue-sfc-shim.d.ts +6 -6
- package/lib/vue-tsx-shim.d.ts +23 -23
- package/lib/web-types.json +1 -1
- package/lib/zartui.cjs.js +1358 -990
- package/lib/zartui.es.js +1358 -990
- package/lib/zartui.js +1406 -1021
- package/lib/zartui.min.js +1 -1
- package/package.json +11 -11
package/lib/index.d.ts
CHANGED
package/lib/index.js
CHANGED
|
@@ -81,6 +81,7 @@ var import_search = require("./search");
|
|
|
81
81
|
var import_signature = require("./signature");
|
|
82
82
|
var import_skeleton = require("./skeleton");
|
|
83
83
|
var import_slider = require("./slider");
|
|
84
|
+
var import_speech_recognizer = require("./speech-recognizer");
|
|
84
85
|
var import_step = require("./step");
|
|
85
86
|
var import_stepper = require("./stepper");
|
|
86
87
|
var import_steps = require("./steps");
|
|
@@ -160,6 +161,7 @@ __reExport(stdin_exports, require("./search"), module.exports);
|
|
|
160
161
|
__reExport(stdin_exports, require("./signature"), module.exports);
|
|
161
162
|
__reExport(stdin_exports, require("./skeleton"), module.exports);
|
|
162
163
|
__reExport(stdin_exports, require("./slider"), module.exports);
|
|
164
|
+
__reExport(stdin_exports, require("./speech-recognizer"), module.exports);
|
|
163
165
|
__reExport(stdin_exports, require("./step"), module.exports);
|
|
164
166
|
__reExport(stdin_exports, require("./stepper"), module.exports);
|
|
165
167
|
__reExport(stdin_exports, require("./steps"), module.exports);
|
|
@@ -241,6 +243,7 @@ function install(app) {
|
|
|
241
243
|
import_signature.Signature,
|
|
242
244
|
import_skeleton.Skeleton,
|
|
243
245
|
import_slider.Slider,
|
|
246
|
+
import_speech_recognizer.SpeechRecognizer,
|
|
244
247
|
import_step.Step,
|
|
245
248
|
import_stepper.Stepper,
|
|
246
249
|
import_steps.Steps,
|
|
@@ -1,55 +1,55 @@
|
|
|
1
|
-
import type { App } from 'vue';
|
|
2
|
-
|
|
3
|
-
declare type ListenEvent =
|
|
4
|
-
| 'scroll'
|
|
5
|
-
| 'wheel'
|
|
6
|
-
| 'mousewheel'
|
|
7
|
-
| 'resize'
|
|
8
|
-
| 'animationend'
|
|
9
|
-
| 'transitionend'
|
|
10
|
-
| 'touchmove';
|
|
11
|
-
|
|
12
|
-
// eslint-disable-next-line
|
|
13
|
-
declare type Callback = (listener: any, options: LazyloadOptions) => void;
|
|
14
|
-
|
|
15
|
-
declare type Filter = {
|
|
16
|
-
webp?: Callback;
|
|
17
|
-
progressive?: Callback;
|
|
18
|
-
};
|
|
19
|
-
|
|
20
|
-
declare type Adapter = {
|
|
21
|
-
error?: Callback;
|
|
22
|
-
loaded?: Callback;
|
|
23
|
-
loading?: Callback;
|
|
24
|
-
};
|
|
25
|
-
|
|
26
|
-
export declare type LazyloadOptions = {
|
|
27
|
-
error?: string;
|
|
28
|
-
filter?: Filter;
|
|
29
|
-
silent?: boolean;
|
|
30
|
-
adapter?: Adapter;
|
|
31
|
-
loading?: string;
|
|
32
|
-
attempt?: number;
|
|
33
|
-
preLoad?: number;
|
|
34
|
-
observer?: boolean;
|
|
35
|
-
lazyImage?: boolean;
|
|
36
|
-
throttleWait?: number;
|
|
37
|
-
listenEvents?: ListenEvent[];
|
|
38
|
-
dispatchEvent?: boolean;
|
|
39
|
-
lazyComponent?: boolean;
|
|
40
|
-
observerOptions?: IntersectionObserverInit;
|
|
41
|
-
};
|
|
42
|
-
|
|
43
|
-
export declare const Lazyload: {
|
|
44
|
-
install(app: App, options?: LazyloadOptions): void;
|
|
45
|
-
};
|
|
46
|
-
|
|
47
|
-
declare module '@vue/runtime-core' {
|
|
48
|
-
interface ComponentCustomProperties {
|
|
49
|
-
$Lazyload: {
|
|
50
|
-
$on: (event: string, handler: Callback) => void;
|
|
51
|
-
$off: (event: string, handler?: Callback) => void;
|
|
52
|
-
$once: (event: string, handler: Callback) => void;
|
|
53
|
-
};
|
|
54
|
-
}
|
|
55
|
-
}
|
|
1
|
+
import type { App } from 'vue';
|
|
2
|
+
|
|
3
|
+
declare type ListenEvent =
|
|
4
|
+
| 'scroll'
|
|
5
|
+
| 'wheel'
|
|
6
|
+
| 'mousewheel'
|
|
7
|
+
| 'resize'
|
|
8
|
+
| 'animationend'
|
|
9
|
+
| 'transitionend'
|
|
10
|
+
| 'touchmove';
|
|
11
|
+
|
|
12
|
+
// eslint-disable-next-line
|
|
13
|
+
declare type Callback = (listener: any, options: LazyloadOptions) => void;
|
|
14
|
+
|
|
15
|
+
declare type Filter = {
|
|
16
|
+
webp?: Callback;
|
|
17
|
+
progressive?: Callback;
|
|
18
|
+
};
|
|
19
|
+
|
|
20
|
+
declare type Adapter = {
|
|
21
|
+
error?: Callback;
|
|
22
|
+
loaded?: Callback;
|
|
23
|
+
loading?: Callback;
|
|
24
|
+
};
|
|
25
|
+
|
|
26
|
+
export declare type LazyloadOptions = {
|
|
27
|
+
error?: string;
|
|
28
|
+
filter?: Filter;
|
|
29
|
+
silent?: boolean;
|
|
30
|
+
adapter?: Adapter;
|
|
31
|
+
loading?: string;
|
|
32
|
+
attempt?: number;
|
|
33
|
+
preLoad?: number;
|
|
34
|
+
observer?: boolean;
|
|
35
|
+
lazyImage?: boolean;
|
|
36
|
+
throttleWait?: number;
|
|
37
|
+
listenEvents?: ListenEvent[];
|
|
38
|
+
dispatchEvent?: boolean;
|
|
39
|
+
lazyComponent?: boolean;
|
|
40
|
+
observerOptions?: IntersectionObserverInit;
|
|
41
|
+
};
|
|
42
|
+
|
|
43
|
+
export declare const Lazyload: {
|
|
44
|
+
install(app: App, options?: LazyloadOptions): void;
|
|
45
|
+
};
|
|
46
|
+
|
|
47
|
+
declare module '@vue/runtime-core' {
|
|
48
|
+
interface ComponentCustomProperties {
|
|
49
|
+
$Lazyload: {
|
|
50
|
+
$on: (event: string, handler: Callback) => void;
|
|
51
|
+
$off: (event: string, handler?: Callback) => void;
|
|
52
|
+
$once: (event: string, handler: Callback) => void;
|
|
53
|
+
};
|
|
54
|
+
}
|
|
55
|
+
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { ExtractPropTypes, PropType } from 'vue';
|
|
2
|
-
import type { Media, MediaAfterRead, MediaBeforeDelete, MediaBeforeRead, MediaPick, MediaPreview, MediaSizeType } from './type';
|
|
1
|
+
import { ComponentPublicInstance, ExtractPropTypes, PropType } from 'vue';
|
|
2
|
+
import type { Media, MediaAddType, MediaAfterRead, MediaBeforeDelete, MediaBeforeRead, MediaPick, MediaPreview, MediaSizeType, MediaType } from './type';
|
|
3
3
|
import { MediaPlayerProps } from '../media-player';
|
|
4
4
|
declare const mediaPickerProps: {
|
|
5
5
|
disabled: BooleanConstructor;
|
|
@@ -81,6 +81,9 @@ declare const mediaPickerProps: {
|
|
|
81
81
|
mediaPlayerProps: PropType<Partial<MediaPlayerProps>>;
|
|
82
82
|
};
|
|
83
83
|
export type MediaPickerProps = ExtractPropTypes<typeof mediaPickerProps>;
|
|
84
|
+
export type MediaPickerInstance = ComponentPublicInstance<{
|
|
85
|
+
mediaPickAction: (mediaType: MediaType, mediaAddType: MediaAddType) => void;
|
|
86
|
+
}>;
|
|
84
87
|
declare const _default: import("vue").DefineComponent<ExtractPropTypes<{
|
|
85
88
|
disabled: BooleanConstructor;
|
|
86
89
|
showTitle: BooleanConstructor;
|
|
@@ -159,7 +162,7 @@ declare const _default: import("vue").DefineComponent<ExtractPropTypes<{
|
|
|
159
162
|
default: MediaSizeType;
|
|
160
163
|
};
|
|
161
164
|
mediaPlayerProps: PropType<Partial<MediaPlayerProps>>;
|
|
162
|
-
}>, () => import("vue/jsx-runtime").JSX.Element, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("delete" | "update:mediaList")[], "delete" | "update:mediaList", import("vue").PublicProps, Readonly<ExtractPropTypes<{
|
|
165
|
+
}>, () => import("vue/jsx-runtime").JSX.Element, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("delete" | "processing" | "update:mediaList")[], "delete" | "processing" | "update:mediaList", import("vue").PublicProps, Readonly<ExtractPropTypes<{
|
|
163
166
|
disabled: BooleanConstructor;
|
|
164
167
|
showTitle: BooleanConstructor;
|
|
165
168
|
useFileNameAsLabel: BooleanConstructor;
|
|
@@ -239,6 +242,7 @@ declare const _default: import("vue").DefineComponent<ExtractPropTypes<{
|
|
|
239
242
|
mediaPlayerProps: PropType<Partial<MediaPlayerProps>>;
|
|
240
243
|
}>> & Readonly<{
|
|
241
244
|
onDelete?: ((...args: any[]) => any) | undefined;
|
|
245
|
+
onProcessing?: ((...args: any[]) => any) | undefined;
|
|
242
246
|
"onUpdate:mediaList"?: ((...args: any[]) => any) | undefined;
|
|
243
247
|
}>, {
|
|
244
248
|
title: string;
|
|
@@ -74,6 +74,7 @@ var import_media_util = require("./util/media-util");
|
|
|
74
74
|
var import_image_preview = require("../image-preview");
|
|
75
75
|
var import_app_media_utils = require("@egova-mobile/app-media-utils");
|
|
76
76
|
var import_wx_util = require("./util/wx-util");
|
|
77
|
+
var import_use_expose = require("../composables/use-expose");
|
|
77
78
|
const [name, bem] = (0, import_utils.createNamespace)("media-picker");
|
|
78
79
|
const FILE_SIZE_LIMIT = 100;
|
|
79
80
|
const mediaPickerProps = {
|
|
@@ -132,7 +133,7 @@ const mediaPickerProps = {
|
|
|
132
133
|
var stdin_default = (0, import_vue2.defineComponent)({
|
|
133
134
|
name,
|
|
134
135
|
props: mediaPickerProps,
|
|
135
|
-
emits: ["update:mediaList", "delete"],
|
|
136
|
+
emits: ["update:mediaList", "delete", "processing"],
|
|
136
137
|
setup(props, {
|
|
137
138
|
emit,
|
|
138
139
|
slots
|
|
@@ -150,6 +151,7 @@ var stdin_default = (0, import_vue2.defineComponent)({
|
|
|
150
151
|
const audioRecorderInputRef = (0, import_vue2.ref)();
|
|
151
152
|
const audioFileInputRef = (0, import_vue2.ref)();
|
|
152
153
|
const fileInputRef = (0, import_vue2.ref)();
|
|
154
|
+
const mediaListPlaceholder = (0, import_vue2.ref)([]);
|
|
153
155
|
const checkFileCountBeforeAdd = (mediaType) => {
|
|
154
156
|
if (props.mediaList.length === props.maxMediaCount) {
|
|
155
157
|
(0, import_toast.showFailToast)("\u5DF2\u8FBE\u5230\u6587\u4EF6\u6700\u5927\u6570\u91CF\u9650\u5236");
|
|
@@ -172,7 +174,7 @@ var stdin_default = (0, import_vue2.defineComponent)({
|
|
|
172
174
|
const triggerHiddenInput = (ref2) => {
|
|
173
175
|
ref2 && ref2.click();
|
|
174
176
|
};
|
|
175
|
-
const
|
|
177
|
+
const mediaPickAction = (mediaType, mediaAddType) => {
|
|
176
178
|
if (props.disabled) {
|
|
177
179
|
return;
|
|
178
180
|
}
|
|
@@ -248,24 +250,24 @@ var stdin_default = (0, import_vue2.defineComponent)({
|
|
|
248
250
|
return [{
|
|
249
251
|
name: "\u62CD\u6444",
|
|
250
252
|
callback: () => {
|
|
251
|
-
|
|
253
|
+
mediaPickAction("video", "take");
|
|
252
254
|
}
|
|
253
255
|
}, {
|
|
254
256
|
name: "\u89C6\u9891\u6587\u4EF6",
|
|
255
257
|
callback: () => {
|
|
256
|
-
|
|
258
|
+
mediaPickAction("video", "pick");
|
|
257
259
|
}
|
|
258
260
|
}];
|
|
259
261
|
} else if (audioOptionsVisible.value) {
|
|
260
262
|
return [{
|
|
261
263
|
name: "\u5F55\u97F3",
|
|
262
264
|
callback: () => {
|
|
263
|
-
|
|
265
|
+
mediaPickAction("audio", "take");
|
|
264
266
|
}
|
|
265
267
|
}, {
|
|
266
268
|
name: "\u97F3\u9891\u6587\u4EF6",
|
|
267
269
|
callback: () => {
|
|
268
|
-
|
|
270
|
+
mediaPickAction("audio", "pick");
|
|
269
271
|
}
|
|
270
272
|
}];
|
|
271
273
|
}
|
|
@@ -331,6 +333,7 @@ var stdin_default = (0, import_vue2.defineComponent)({
|
|
|
331
333
|
fileName: f.name,
|
|
332
334
|
originalName: f.name,
|
|
333
335
|
originalSize: f.size,
|
|
336
|
+
originalFile: f,
|
|
334
337
|
deletable: true,
|
|
335
338
|
message: ""
|
|
336
339
|
};
|
|
@@ -353,17 +356,13 @@ var stdin_default = (0, import_vue2.defineComponent)({
|
|
|
353
356
|
message: "",
|
|
354
357
|
originalName: file.name,
|
|
355
358
|
// 原始名称
|
|
356
|
-
originalSize: file.size
|
|
359
|
+
originalSize: file.size,
|
|
357
360
|
// 原始大小
|
|
361
|
+
originalFile: file
|
|
358
362
|
};
|
|
359
363
|
return media;
|
|
360
364
|
});
|
|
361
365
|
});
|
|
362
|
-
(0, import_toast.showLoadingToast)({
|
|
363
|
-
message: "\u5904\u7406\u4E2D...",
|
|
364
|
-
forbidClick: true,
|
|
365
|
-
duration: 0
|
|
366
|
-
});
|
|
367
366
|
return Promise.all(mediaList).then((medias) => {
|
|
368
367
|
const _medias = [];
|
|
369
368
|
medias.forEach((media) => {
|
|
@@ -373,7 +372,6 @@ var stdin_default = (0, import_vue2.defineComponent)({
|
|
|
373
372
|
});
|
|
374
373
|
return _medias;
|
|
375
374
|
}).finally(() => {
|
|
376
|
-
(0, import_toast.closeToast)();
|
|
377
375
|
});
|
|
378
376
|
};
|
|
379
377
|
const transformImageFiles = (files) => {
|
|
@@ -432,11 +430,6 @@ var stdin_default = (0, import_vue2.defineComponent)({
|
|
|
432
430
|
});
|
|
433
431
|
promisesTodo.push(promise);
|
|
434
432
|
}
|
|
435
|
-
(0, import_toast.showLoadingToast)({
|
|
436
|
-
message: "\u5904\u7406\u4E2D...",
|
|
437
|
-
forbidClick: true,
|
|
438
|
-
duration: 0
|
|
439
|
-
});
|
|
440
433
|
return Promise.all(promisesTodo).then((medias) => {
|
|
441
434
|
const _medias = [];
|
|
442
435
|
medias.forEach((media) => {
|
|
@@ -446,10 +439,47 @@ var stdin_default = (0, import_vue2.defineComponent)({
|
|
|
446
439
|
});
|
|
447
440
|
return _medias;
|
|
448
441
|
}).finally(() => {
|
|
449
|
-
(0, import_toast.closeToast)();
|
|
450
442
|
});
|
|
451
443
|
};
|
|
452
444
|
const readFiles = (files) => {
|
|
445
|
+
emit("processing", true);
|
|
446
|
+
mediaListPlaceholder.value = files.map((file) => {
|
|
447
|
+
let type;
|
|
448
|
+
if ((0, import_media_util.isAudioType)(file)) {
|
|
449
|
+
type = "audio";
|
|
450
|
+
} else if ((0, import_media_util.isVideoType)(file)) {
|
|
451
|
+
type = "video";
|
|
452
|
+
} else if ((0, import_media_util.isImageType)(file)) {
|
|
453
|
+
type = "photo";
|
|
454
|
+
} else {
|
|
455
|
+
type = "file";
|
|
456
|
+
}
|
|
457
|
+
return {
|
|
458
|
+
file,
|
|
459
|
+
message: "\u5904\u7406\u4E2D...",
|
|
460
|
+
status: "processing",
|
|
461
|
+
type
|
|
462
|
+
};
|
|
463
|
+
});
|
|
464
|
+
emit("processing", true);
|
|
465
|
+
mediaListPlaceholder.value = files.map((file) => {
|
|
466
|
+
let type;
|
|
467
|
+
if ((0, import_media_util.isAudioType)(file)) {
|
|
468
|
+
type = "audio";
|
|
469
|
+
} else if ((0, import_media_util.isVideoType)(file)) {
|
|
470
|
+
type = "video";
|
|
471
|
+
} else if ((0, import_media_util.isImageType)(file)) {
|
|
472
|
+
type = "photo";
|
|
473
|
+
} else {
|
|
474
|
+
type = "file";
|
|
475
|
+
}
|
|
476
|
+
return {
|
|
477
|
+
file,
|
|
478
|
+
message: "\u5904\u7406\u4E2D...",
|
|
479
|
+
status: "processing",
|
|
480
|
+
type
|
|
481
|
+
};
|
|
482
|
+
});
|
|
453
483
|
const notImages = files.filter((f) => !(0, import_media_util.isImageType)(f)).map((f) => transformNotImageFile(f));
|
|
454
484
|
let newMedias = [];
|
|
455
485
|
if (notImages.length > 0) {
|
|
@@ -472,6 +502,8 @@ var stdin_default = (0, import_vue2.defineComponent)({
|
|
|
472
502
|
newMedia.label = newMedia.originalName;
|
|
473
503
|
});
|
|
474
504
|
}
|
|
505
|
+
mediaListPlaceholder.value = [];
|
|
506
|
+
emit("processing", false);
|
|
475
507
|
emit("update:mediaList", [...props.mediaList, ...newMedias]);
|
|
476
508
|
if (props.afterRead) {
|
|
477
509
|
props.afterRead(newMedias);
|
|
@@ -607,7 +639,7 @@ var stdin_default = (0, import_vue2.defineComponent)({
|
|
|
607
639
|
"class": bem("box")
|
|
608
640
|
}, [(0, import_vue.createVNode)("div", {
|
|
609
641
|
"class": bem("button"),
|
|
610
|
-
"onClick": () =>
|
|
642
|
+
"onClick": () => mediaPickAction(mediaType, mediaAddType)
|
|
611
643
|
}, [renderIcon(mediaType, mediaAddType)]), (0, import_vue.createVNode)("div", {
|
|
612
644
|
"class": bem("label")
|
|
613
645
|
}, [label])]);
|
|
@@ -648,7 +680,7 @@ var stdin_default = (0, import_vue2.defineComponent)({
|
|
|
648
680
|
status,
|
|
649
681
|
message
|
|
650
682
|
} = media;
|
|
651
|
-
if (status === "uploading" || status === "failed") {
|
|
683
|
+
if (status === "processing" || status === "uploading" || status === "failed") {
|
|
652
684
|
const MaskIcon = status === "failed" ? (0, import_vue.createVNode)(import_icon.default, {
|
|
653
685
|
"name": "close",
|
|
654
686
|
"class": bem("mask-icon")
|
|
@@ -703,7 +735,7 @@ var stdin_default = (0, import_vue2.defineComponent)({
|
|
|
703
735
|
}
|
|
704
736
|
return (0, import_vue.createVNode)("div", {
|
|
705
737
|
"class": bem("thumbnail-label")
|
|
706
|
-
}, [media.label
|
|
738
|
+
}, [media.label]);
|
|
707
739
|
};
|
|
708
740
|
const onDelete = (media, index) => {
|
|
709
741
|
if (props.beforeDelete) {
|
|
@@ -781,6 +813,15 @@ var stdin_default = (0, import_vue2.defineComponent)({
|
|
|
781
813
|
(0, import_toast.showFailToast)("\u6682\u4E0D\u652F\u6301\u6B64\u7C7B\u6587\u4EF6\u7684\u9884\u89C8");
|
|
782
814
|
}
|
|
783
815
|
});
|
|
816
|
+
const renderMediaListPlaceholder = () => {
|
|
817
|
+
return mediaListPlaceholder.value.map((media) => {
|
|
818
|
+
return (0, import_vue.createVNode)(import_grid_item.default, {
|
|
819
|
+
"key": media.uniqueCode
|
|
820
|
+
}, {
|
|
821
|
+
default: () => [renderMediaThumbnail(media), renderMediaLabel(media), genThumbnailMask(media)]
|
|
822
|
+
});
|
|
823
|
+
});
|
|
824
|
+
};
|
|
784
825
|
const renderMediaList = () => props.mediaList.map((media, index) => {
|
|
785
826
|
const showDelete = media.deletable && media.status !== "uploading";
|
|
786
827
|
const deleteIcon = showDelete && (0, import_vue.createVNode)(import_DeleteIcon.default, {
|
|
@@ -801,6 +842,9 @@ var stdin_default = (0, import_vue2.defineComponent)({
|
|
|
801
842
|
actionVisible.value = false;
|
|
802
843
|
action.func && action.func();
|
|
803
844
|
};
|
|
845
|
+
(0, import_use_expose.useExpose)({
|
|
846
|
+
mediaPickAction
|
|
847
|
+
});
|
|
804
848
|
return () => {
|
|
805
849
|
const title = props.showTitle && (0, import_vue.createVNode)("div", {
|
|
806
850
|
"class": bem("title")
|
|
@@ -831,7 +875,15 @@ var stdin_default = (0, import_vue2.defineComponent)({
|
|
|
831
875
|
"class": bem("grid")
|
|
832
876
|
}, {
|
|
833
877
|
default: () => [renderMediaList()]
|
|
834
|
-
}), [[import_vue.vShow, props.mediaList.length]])
|
|
878
|
+
}), [[import_vue.vShow, props.mediaList.length]]), (0, import_vue.withDirectives)((0, import_vue.createVNode)(import_grid.default, {
|
|
879
|
+
"column-num": "3",
|
|
880
|
+
"border": false,
|
|
881
|
+
"square": true,
|
|
882
|
+
"gutter": "4",
|
|
883
|
+
"class": bem("grid")
|
|
884
|
+
}, {
|
|
885
|
+
default: () => [renderMediaListPlaceholder()]
|
|
886
|
+
}), [[import_vue.vShow, mediaListPlaceholder.value.length]])]);
|
|
835
887
|
};
|
|
836
888
|
}
|
|
837
889
|
});
|
|
@@ -66,7 +66,7 @@ export declare const MediaPicker: import("../utils").WithInstall<import("vue").D
|
|
|
66
66
|
default: import("./type").MediaSizeType;
|
|
67
67
|
};
|
|
68
68
|
mediaPlayerProps: import("vue").PropType<Partial<import("..").MediaPlayerProps>>;
|
|
69
|
-
}>, () => import("vue/jsx-runtime").JSX.Element, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("delete" | "update:mediaList")[], "delete" | "update:mediaList", import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
69
|
+
}>, () => import("vue/jsx-runtime").JSX.Element, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("delete" | "processing" | "update:mediaList")[], "delete" | "processing" | "update:mediaList", import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
70
70
|
disabled: BooleanConstructor;
|
|
71
71
|
showTitle: BooleanConstructor;
|
|
72
72
|
useFileNameAsLabel: BooleanConstructor;
|
|
@@ -136,6 +136,7 @@ export declare const MediaPicker: import("../utils").WithInstall<import("vue").D
|
|
|
136
136
|
mediaPlayerProps: import("vue").PropType<Partial<import("..").MediaPlayerProps>>;
|
|
137
137
|
}>> & Readonly<{
|
|
138
138
|
onDelete?: ((...args: any[]) => any) | undefined;
|
|
139
|
+
onProcessing?: ((...args: any[]) => any) | undefined;
|
|
139
140
|
"onUpdate:mediaList"?: ((...args: any[]) => any) | undefined;
|
|
140
141
|
}>, {
|
|
141
142
|
title: string;
|
|
@@ -162,7 +163,7 @@ export declare const MediaPicker: import("../utils").WithInstall<import("vue").D
|
|
|
162
163
|
imageSizeType: import("./type").MediaSizeType;
|
|
163
164
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>>;
|
|
164
165
|
export default MediaPicker;
|
|
165
|
-
export type { MediaPickerProps } from './MediaPicker';
|
|
166
|
+
export type { MediaPickerProps, MediaPickerInstance } from './MediaPicker';
|
|
166
167
|
export type { Media, MediaType, MediaAddType, MediaUploadStatus, MediaPreview, MediaPick, MediaBeforeRead, MediaAfterRead, MediaBeforeDelete, MediaPickerThemeVars, MediaSizeType, } from './type';
|
|
167
168
|
export { defaultMedia } from './type';
|
|
168
169
|
declare module 'vue' {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
export type MediaType = 'photo' | 'audio' | 'video' | 'file';
|
|
2
2
|
export type MediaAddType = 'take' | 'pick' | 'take_and_pick';
|
|
3
|
-
export type MediaUploadStatus = 'uploading' | 'done' | 'failed';
|
|
3
|
+
export type MediaUploadStatus = 'processing' | 'uploading' | 'done' | 'failed';
|
|
4
4
|
export type WxMediaType = 'camera' | 'album';
|
|
5
5
|
export type MediaSizeType = 'original' | 'compressed';
|
|
6
6
|
export type Media = {
|
|
@@ -13,6 +13,7 @@ export type Media = {
|
|
|
13
13
|
fileName: string;
|
|
14
14
|
originalName: string;
|
|
15
15
|
originalSize: number;
|
|
16
|
+
originalFile?: File;
|
|
16
17
|
lastModified: number;
|
|
17
18
|
deletable: boolean;
|
|
18
19
|
status?: MediaUploadStatus;
|
package/lib/picker/Picker.d.ts
CHANGED
|
@@ -30,6 +30,10 @@ export declare const pickerSharedProps: {
|
|
|
30
30
|
default: string;
|
|
31
31
|
};
|
|
32
32
|
} & {
|
|
33
|
+
title: {
|
|
34
|
+
type: PropType<string>;
|
|
35
|
+
default: string;
|
|
36
|
+
};
|
|
33
37
|
cancelButtonText: StringConstructor;
|
|
34
38
|
confirmButtonText: StringConstructor;
|
|
35
39
|
};
|
|
@@ -62,6 +66,10 @@ export declare const pickerProps: {
|
|
|
62
66
|
default: string;
|
|
63
67
|
};
|
|
64
68
|
} & {
|
|
69
|
+
title: {
|
|
70
|
+
type: PropType<string>;
|
|
71
|
+
default: string;
|
|
72
|
+
};
|
|
65
73
|
cancelButtonText: StringConstructor;
|
|
66
74
|
confirmButtonText: StringConstructor;
|
|
67
75
|
} & {
|
|
@@ -126,6 +134,10 @@ declare const _default: import("vue").DefineComponent<ExtractPropTypes<{
|
|
|
126
134
|
default: string;
|
|
127
135
|
};
|
|
128
136
|
} & {
|
|
137
|
+
title: {
|
|
138
|
+
type: PropType<string>;
|
|
139
|
+
default: string;
|
|
140
|
+
};
|
|
129
141
|
cancelButtonText: StringConstructor;
|
|
130
142
|
confirmButtonText: StringConstructor;
|
|
131
143
|
} & {
|
|
@@ -188,6 +200,10 @@ declare const _default: import("vue").DefineComponent<ExtractPropTypes<{
|
|
|
188
200
|
default: string;
|
|
189
201
|
};
|
|
190
202
|
} & {
|
|
203
|
+
title: {
|
|
204
|
+
type: PropType<string>;
|
|
205
|
+
default: string;
|
|
206
|
+
};
|
|
191
207
|
cancelButtonText: StringConstructor;
|
|
192
208
|
confirmButtonText: StringConstructor;
|
|
193
209
|
} & {
|
package/lib/picker/Picker.js
CHANGED
|
@@ -209,16 +209,6 @@ var stdin_default = (0, import_vue.defineComponent)({
|
|
|
209
209
|
}), (0, import_utils.pick)(slots, import_PickerToolbar.pickerToolbarSlots));
|
|
210
210
|
}
|
|
211
211
|
};
|
|
212
|
-
const renderTitleBar = () => {
|
|
213
|
-
if (props.showTitle) {
|
|
214
|
-
if (slots["title-bar"]) {
|
|
215
|
-
return slots["title-bar"]();
|
|
216
|
-
}
|
|
217
|
-
return (0, import_vue.createVNode)("div", {
|
|
218
|
-
"class": [(0, import_utils2.bem)("title"), import_utils.HAPTICS_FEEDBACK]
|
|
219
|
-
}, [props.title]);
|
|
220
|
-
}
|
|
221
|
-
};
|
|
222
212
|
const buttomDivider = () => props.showToolbar ? (0, import_vue.createVNode)(import_divider.Divider, {
|
|
223
213
|
"style": "margin: 0"
|
|
224
214
|
}, null) : null;
|
|
@@ -261,9 +251,9 @@ var stdin_default = (0, import_vue.defineComponent)({
|
|
|
261
251
|
var _a, _b;
|
|
262
252
|
return (0, import_vue.createVNode)("div", {
|
|
263
253
|
"class": (0, import_utils2.bem)()
|
|
264
|
-
}, [
|
|
254
|
+
}, [renderToolbar(), props.loading ? (0, import_vue.createVNode)(import_loading.Loading, {
|
|
265
255
|
"class": (0, import_utils2.bem)("loading")
|
|
266
|
-
}, null) : null, (_a = slots["columns-top"]) == null ? void 0 : _a.call(slots), renderColumns(), (_b = slots["columns-bottom"]) == null ? void 0 : _b.call(slots)
|
|
256
|
+
}, null) : null, (_a = slots["columns-top"]) == null ? void 0 : _a.call(slots), renderColumns(), (_b = slots["columns-bottom"]) == null ? void 0 : _b.call(slots)]);
|
|
267
257
|
};
|
|
268
258
|
const renderOptionItems = () => {
|
|
269
259
|
return currentColumns.value.map((options, columnIndex) => {
|
|
@@ -290,9 +280,9 @@ var stdin_default = (0, import_vue.defineComponent)({
|
|
|
290
280
|
var _a, _b;
|
|
291
281
|
return (0, import_vue.createVNode)("div", {
|
|
292
282
|
"class": (0, import_utils2.bem)()
|
|
293
|
-
}, [
|
|
283
|
+
}, [renderToolbar(), props.loading ? (0, import_vue.createVNode)(import_loading.Loading, {
|
|
294
284
|
"class": (0, import_utils2.bem)("loading")
|
|
295
|
-
}, null) : null, (_a = slots["columns-top"]) == null ? void 0 : _a.call(slots), renderOptions(), (_b = slots["columns-bottom"]) == null ? void 0 : _b.call(slots)
|
|
285
|
+
}, null) : null, (_a = slots["columns-top"]) == null ? void 0 : _a.call(slots), renderOptions(), (_b = slots["columns-bottom"]) == null ? void 0 : _b.call(slots)]);
|
|
296
286
|
};
|
|
297
287
|
return () => {
|
|
298
288
|
if (isButtonPicker.value) {
|
|
@@ -1,4 +1,8 @@
|
|
|
1
1
|
export declare const pickerToolbarProps: {
|
|
2
|
+
title: {
|
|
3
|
+
type: import("vue").PropType<string>;
|
|
4
|
+
default: string;
|
|
5
|
+
};
|
|
2
6
|
cancelButtonText: StringConstructor;
|
|
3
7
|
confirmButtonText: StringConstructor;
|
|
4
8
|
};
|
|
@@ -6,13 +10,23 @@ export declare const pickerToolbarSlots: string[];
|
|
|
6
10
|
export type PickerToolbarPropKeys = Array<keyof typeof pickerToolbarProps>;
|
|
7
11
|
export declare const pickerToolbarPropKeys: PickerToolbarPropKeys;
|
|
8
12
|
declare const _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
13
|
+
title: {
|
|
14
|
+
type: import("vue").PropType<string>;
|
|
15
|
+
default: string;
|
|
16
|
+
};
|
|
9
17
|
cancelButtonText: StringConstructor;
|
|
10
18
|
confirmButtonText: StringConstructor;
|
|
11
19
|
}>, () => import("vue/jsx-runtime").JSX.Element, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("cancel" | "confirm")[], "cancel" | "confirm", import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
20
|
+
title: {
|
|
21
|
+
type: import("vue").PropType<string>;
|
|
22
|
+
default: string;
|
|
23
|
+
};
|
|
12
24
|
cancelButtonText: StringConstructor;
|
|
13
25
|
confirmButtonText: StringConstructor;
|
|
14
26
|
}>> & Readonly<{
|
|
15
27
|
onCancel?: ((...args: any[]) => any) | undefined;
|
|
16
28
|
onConfirm?: ((...args: any[]) => any) | undefined;
|
|
17
|
-
}>, {
|
|
29
|
+
}>, {
|
|
30
|
+
title: string;
|
|
31
|
+
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
18
32
|
export default _default;
|
|
@@ -26,10 +26,9 @@ module.exports = __toCommonJS(stdin_exports);
|
|
|
26
26
|
var import_vue = require("vue");
|
|
27
27
|
var import_utils = require("./utils");
|
|
28
28
|
var import_utils2 = require("../utils");
|
|
29
|
-
var import_button = require("../button");
|
|
30
29
|
const [name] = (0, import_utils2.createNamespace)("picker-toolbar");
|
|
31
30
|
const pickerToolbarProps = {
|
|
32
|
-
|
|
31
|
+
title: (0, import_utils2.makeStringProp)("\u8BF7\u9009\u62E9"),
|
|
33
32
|
cancelButtonText: String,
|
|
34
33
|
confirmButtonText: String
|
|
35
34
|
};
|
|
@@ -43,31 +42,34 @@ var stdin_default = (0, import_vue.defineComponent)({
|
|
|
43
42
|
emit,
|
|
44
43
|
slots
|
|
45
44
|
}) {
|
|
45
|
+
const renderTitle = () => {
|
|
46
|
+
if (slots.title) {
|
|
47
|
+
return slots.title();
|
|
48
|
+
}
|
|
49
|
+
if (props.title) {
|
|
50
|
+
return (0, import_vue.createVNode)("div", {
|
|
51
|
+
"class": [(0, import_utils.bem)("title"), "zt-ellipsis"]
|
|
52
|
+
}, [props.title]);
|
|
53
|
+
}
|
|
54
|
+
};
|
|
46
55
|
const onCancel = () => emit("cancel");
|
|
47
56
|
const onConfirm = () => emit("confirm");
|
|
48
57
|
const renderCancel = () => {
|
|
49
58
|
const text = props.cancelButtonText || (0, import_utils.t)("cancel");
|
|
50
|
-
return (0, import_vue.createVNode)(
|
|
51
|
-
"type": "default",
|
|
52
|
-
"hairline": true,
|
|
59
|
+
return (0, import_vue.createVNode)("div", {
|
|
53
60
|
"class": (0, import_utils.bem)("cancel"),
|
|
54
61
|
"onClick": onCancel
|
|
55
|
-
},
|
|
56
|
-
default: () => [slots.cancel ? slots.cancel() : text]
|
|
57
|
-
});
|
|
62
|
+
}, [slots.cancel ? slots.cancel() : text]);
|
|
58
63
|
};
|
|
59
64
|
const renderConfirm = () => {
|
|
60
65
|
const text = props.confirmButtonText || (0, import_utils.t)("confirm");
|
|
61
|
-
return (0, import_vue.createVNode)(
|
|
62
|
-
"type": "primary",
|
|
66
|
+
return (0, import_vue.createVNode)("div", {
|
|
63
67
|
"class": [(0, import_utils.bem)("confirm"), import_utils2.HAPTICS_FEEDBACK],
|
|
64
68
|
"onClick": onConfirm
|
|
65
|
-
},
|
|
66
|
-
default: () => [slots.confirm ? slots.confirm() : text]
|
|
67
|
-
});
|
|
69
|
+
}, [slots.confirm ? slots.confirm() : text]);
|
|
68
70
|
};
|
|
69
71
|
return () => (0, import_vue.createVNode)("div", {
|
|
70
72
|
"class": (0, import_utils.bem)("toolbar")
|
|
71
|
-
}, [slots.toolbar ? slots.toolbar() : [renderCancel(), renderConfirm()]]);
|
|
73
|
+
}, [slots.toolbar ? slots.toolbar() : [renderCancel(), renderTitle(), renderConfirm()]]);
|
|
72
74
|
}
|
|
73
75
|
});
|
package/lib/picker/index.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
:root{--zt-picker-cancel-
|
|
1
|
+
:root{--zt-picker-cancel-padding: 15px 20px;--zt-picker-confirm-padding: 15px 20px;--zt-picker-title-margin: 0 20px;--zt-picker-title-height: 56px;--zt-picker-title-border-radius: 16px 16px 0 0;--zt-picker-title-text-color: var(--zt-gray-60);--zt-picker-background: var(--zt-background-popup);--zt-picker-toolbar-height: 52px;--zt-picker-toolbar-background: var(--zt-background-popup);--zt-picker-title-background: var(--zt-background-popup);--zt-picker-option-padding: 0 var(--zt-padding-base);--zt-picker-option-text-color: var(--zt-text-color);--zt-picker-option-disabled-opacity: var(--zt-disabled-opacity);--zt-picker-option-disabled-background: var(--zt-gray-10);--zt-picker-loading-icon-color: var(--zt-primary-color);--zt-picker-loading-mask-color: rgba(255, 255, 255, .9);--zt-picker-mask-color: linear-gradient(180deg, rgba(255, 255, 255, .9), rgba(255, 255, 255, .4)), linear-gradient(0deg, rgba(255, 255, 255, .9), rgba(255, 255, 255, .4));--zt-picker-warpper-padding: 12px 16px 4px 16px;--zt-picker-option-item-text-color: var(--zt-gray-40);--zt-picker-option-item-padding: 0 4px 8px 0;--zt-picker-options-ellipsis-height: 36px;--zt-picker-options-ellipsis-border: 1px solid var(--zt-gray-20);--zt-picker-option-item-disabled-opacity: var(--zt-disabled-opacity);--zt-picker-frame-background-color: rgba(0, 0, 0, .02)}:root[zt-theme-size=large]{--zt-picker-options-ellipsis-height: 50px}.zt-theme-dark{--zt-picker-loading-mask-color: rgba(0, 0, 0, .6);--zt-picker-mask-color: linear-gradient(180deg, rgba(0, 0, 0, .6), rgba(0, 0, 0, .1)), linear-gradient(0deg, rgba(0, 0, 0, .6), rgba(0, 0, 0, .1))}.zt-picker{position:relative;background:var(--zt-picker-background);-webkit-user-select:none;-moz-user-select:none;user-select:none}.zt-picker__toolbar{display:flex;align-items:center;justify-content:space-between;height:var(--zt-picker-toolbar-height);background:var(--zt-picker-toolbar-background)}.zt-picker__cancel,.zt-picker__confirm{flex:0 0 auto}.zt-picker__cancel{padding:var(--zt-picker-cancel-padding);font-size:var(--zt-font-size-md);color:var(--zt-primary-color)}.zt-picker__confirm{margin:var(--zt-picker-confirm-padding);font-size:var(--zt-font-size-md);color:var(--zt-primary-color)}.zt-picker__title{min-width:0;font-size:var(--zt-font-size-xl);color:var(--zt-picker-title-text-color);font-weight:700;margin:var(--zt-picker-title-margin)}.zt-picker__columns{position:relative;display:flex;cursor:grab}.zt-picker__options{position:relative;display:flex;cursor:grab;overflow-y:scroll}.zt-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-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-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-picker-loading-icon-color);background:var(--zt-picker-loading-mask-color)}.zt-picker__frame{position:absolute;top:50%;z-index:2;transform:translateY(-50%);pointer-events:none;width:100%;background:var(--zt-picker-frame-background-color)}.zt-picker__mask{position:absolute;top:0;left:0;z-index:1;width:100%;height:100%;background-image:linear-gradient(180deg,hsla(0,0%,100%,.9),hsla(0,0%,100%,.4)),linear-gradient(0deg,hsla(0,0%,100%,.9),hsla(0,0%,100%,.4));background-repeat:no-repeat;background-position:top,bottom;transform:translateZ(0);pointer-events:none}.zt-picker-column{flex:1;overflow:hidden;font-size:var(--zt-font-size-lg)}.zt-picker-column__wrapper{transition-timing-function:cubic-bezier(.23,1,.68,1)}.zt-picker-column__item{display:flex;align-items:center;justify-content:center;padding:var(--zt-picker-option-padding);color:var(--zt-picker-option-text-color)}.zt-picker-column__item--disabled{cursor:not-allowed;opacity:var(--zt-picker-option-disabled-opacity)}.zt-picker-column__item--selected{font-weight:700;font-size:var(--zt-font-size-xl)}.zt-picker-column__unit{background:var(--zt-picker-title-background);position:absolute;display:flex;align-items:center;justify-content:center;font-weight:700;color:var(--zt-picker-option-text-color);font-size:var(--zt-font-size-lg);width:100%;height:100%}.zt-picker-column__unit-text{margin:0 4px;font-size:var(--zt-font-size-md)}.zt-picker-options{flex:1;overflow-y:scroll;font-size:var(--zt-font-size-md);margin:0;outline:0 none;padding:0}.zt-picker-options__wrapper{display:flex;flex-wrap:wrap;background-color:var(--zt-picker-background);padding:var(--zt-picker-warpper-padding)}.zt-picker-options__item{color:var(--zt-picker-option-item-text-color);padding:var(--zt-picker-option-item-padding);box-sizing:border-box;text-align:center;font-size:var(--zt-font-size-md)}.zt-picker-options__item .zt-ellipsis{height:var(--zt-picker-options-ellipsis-height);line-height:var(--zt-picker-options-ellipsis-height);border-radius:calc(var(--zt-picker-options-ellipsis-height) / 2);background:var(--zt-gray-10);padding:0 var(--zt-padding-md)}.zt-picker-options__item:active{opacity:var(--zt-active-opacity)}.zt-picker-options__item--disabled{cursor:not-allowed;color:var(--zt-gray-20)}.zt-picker-options__item--disabled .zt-ellipsis{background:var(--zt-picker-option-disabled-background)!important}.zt-picker-options__item--last{padding-right:0}.zt-picker-options__item--selected{color:var(--zt-white)}.zt-picker-options__item--selected .zt-ellipsis{background:var(--zt-primary-color)}.zt-picker-options__item--disabled-selected{cursor:not-allowed;color:var(--zt-gray)!important}.zt-picker-options__item--disabled-selected .zt-ellipsis{background:var(--zt-picker-option-disabled-background)!important}
|