mirror of
https://github.com/youzan/vant.git
synced 2025-10-16 08:00:34 +00:00
[bugfix] ImagePreview: fix ts definition (#1767)
This commit is contained in:
8
types/image-preview.d.ts
vendored
8
types/image-preview.d.ts
vendored
@@ -1,12 +1,18 @@
|
||||
import { VanPopupMixin } from './mixins/popup';
|
||||
|
||||
export type ImagePreviewOptions = string[] | {
|
||||
images: string[];
|
||||
startPosition?: number;
|
||||
onClose?: () => any;
|
||||
};
|
||||
|
||||
export class VanImagePreview extends VanPopupMixin {
|
||||
images: string[];
|
||||
startPosition: number;
|
||||
}
|
||||
|
||||
export interface ImagePreview {
|
||||
(images: string[], startPosition?: number): VanImagePreview;
|
||||
(options: ImagePreviewOptions, startPosition?: number): VanImagePreview;
|
||||
install(): void;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user