@arco-design/web-vue
Version:
Arco Design Vue 2.0: A Vue.js 3 UI Library
279 lines (278 loc) • 7.84 kB
TypeScript
import type { PropType } from 'vue';
import type { CustomIcon, FileItem, ListType, RequestOption, UploadRequest } from './interfaces';
declare const _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
fileList: {
type: PropType<FileItem[]>;
default: undefined;
};
defaultFileList: {
type: PropType<FileItem[]>;
default: () => never[];
};
accept: StringConstructor;
action: StringConstructor;
disabled: {
type: BooleanConstructor;
default: boolean;
};
multiple: {
type: BooleanConstructor;
default: boolean;
};
directory: {
type: BooleanConstructor;
default: boolean;
};
draggable: {
type: BooleanConstructor;
default: boolean;
};
tip: StringConstructor;
headers: {
type: PropType<Record<string, string>>;
};
data: {
type: PropType<Record<string, string | Blob> | ((fileItem: FileItem) => Record<string, string | Blob>)>;
};
name: {
type: PropType<string | ((fileItem: FileItem) => string)>;
};
withCredentials: {
type: BooleanConstructor;
default: boolean;
};
customRequest: {
type: PropType<(option: RequestOption) => UploadRequest>;
};
limit: {
type: NumberConstructor;
default: number;
};
autoUpload: {
type: BooleanConstructor;
default: boolean;
};
showFileList: {
type: BooleanConstructor;
default: boolean;
};
showRemoveButton: {
type: BooleanConstructor;
default: boolean;
};
showRetryButton: {
type: BooleanConstructor;
default: boolean;
};
showCancelButton: {
type: BooleanConstructor;
default: boolean;
};
showUploadButton: {
type: PropType<boolean | {
showOnExceedLimit: boolean;
}>;
default: boolean;
};
showPreviewButton: {
type: BooleanConstructor;
default: boolean;
};
download: {
type: BooleanConstructor;
default: boolean;
};
showLink: {
type: BooleanConstructor;
default: boolean;
};
imageLoading: {
type: PropType<"eager" | "lazy">;
};
listType: {
type: PropType<ListType>;
default: string;
};
responseUrlKey: {
type: PropType<string | ((fileItem: FileItem) => string)>;
};
customIcon: {
type: PropType<CustomIcon>;
};
imagePreview: {
type: BooleanConstructor;
default: boolean;
};
onBeforeUpload: {
type: PropType<(file: File) => boolean | Promise<boolean | File>>;
};
onBeforeRemove: {
type: PropType<(fileItem: FileItem) => Promise<boolean>>;
};
onButtonClick: {
type: PropType<(event: Event) => Promise<FileList> | void>;
};
}>, {
prefixCls: string;
render: () => false | import("vue/jsx-runtime").JSX.Element;
innerSubmit: (fileItem?: FileItem | undefined) => void;
innerAbort: (fileItem: FileItem) => void;
innerUpdateFile: (id: string, file: File) => void;
innerUpload: (files: File[]) => void;
}, {}, {}, {
submit(fileItem?: FileItem | undefined): void;
abort(fileItem: FileItem): void;
updateFile(id: string, file: File): void;
upload(files: File[]): void;
}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
'update:fileList': (fileList: FileItem[]) => true;
exceedLimit: (fileList: FileItem[], files: File[]) => true;
change: (fileList: FileItem[], fileItem: FileItem) => true;
progress: (fileItem: FileItem, ev?: ProgressEvent<EventTarget> | undefined) => true;
preview: (fileItem: FileItem) => true;
success: (fileItem: FileItem) => true;
error: (fileItem: FileItem) => true;
}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
fileList: {
type: PropType<FileItem[]>;
default: undefined;
};
defaultFileList: {
type: PropType<FileItem[]>;
default: () => never[];
};
accept: StringConstructor;
action: StringConstructor;
disabled: {
type: BooleanConstructor;
default: boolean;
};
multiple: {
type: BooleanConstructor;
default: boolean;
};
directory: {
type: BooleanConstructor;
default: boolean;
};
draggable: {
type: BooleanConstructor;
default: boolean;
};
tip: StringConstructor;
headers: {
type: PropType<Record<string, string>>;
};
data: {
type: PropType<Record<string, string | Blob> | ((fileItem: FileItem) => Record<string, string | Blob>)>;
};
name: {
type: PropType<string | ((fileItem: FileItem) => string)>;
};
withCredentials: {
type: BooleanConstructor;
default: boolean;
};
customRequest: {
type: PropType<(option: RequestOption) => UploadRequest>;
};
limit: {
type: NumberConstructor;
default: number;
};
autoUpload: {
type: BooleanConstructor;
default: boolean;
};
showFileList: {
type: BooleanConstructor;
default: boolean;
};
showRemoveButton: {
type: BooleanConstructor;
default: boolean;
};
showRetryButton: {
type: BooleanConstructor;
default: boolean;
};
showCancelButton: {
type: BooleanConstructor;
default: boolean;
};
showUploadButton: {
type: PropType<boolean | {
showOnExceedLimit: boolean;
}>;
default: boolean;
};
showPreviewButton: {
type: BooleanConstructor;
default: boolean;
};
download: {
type: BooleanConstructor;
default: boolean;
};
showLink: {
type: BooleanConstructor;
default: boolean;
};
imageLoading: {
type: PropType<"eager" | "lazy">;
};
listType: {
type: PropType<ListType>;
default: string;
};
responseUrlKey: {
type: PropType<string | ((fileItem: FileItem) => string)>;
};
customIcon: {
type: PropType<CustomIcon>;
};
imagePreview: {
type: BooleanConstructor;
default: boolean;
};
onBeforeUpload: {
type: PropType<(file: File) => boolean | Promise<boolean | File>>;
};
onBeforeRemove: {
type: PropType<(fileItem: FileItem) => Promise<boolean>>;
};
onButtonClick: {
type: PropType<(event: Event) => Promise<FileList> | void>;
};
}>> & Readonly<{
onChange?: ((fileList: FileItem[], fileItem: FileItem) => any) | undefined;
onError?: ((fileItem: FileItem) => any) | undefined;
onProgress?: ((fileItem: FileItem, ev?: ProgressEvent<EventTarget> | undefined) => any) | undefined;
onSuccess?: ((fileItem: FileItem) => any) | undefined;
onPreview?: ((fileItem: FileItem) => any) | undefined;
onExceedLimit?: ((fileList: FileItem[], files: File[]) => any) | undefined;
"onUpdate:fileList"?: ((fileList: FileItem[]) => any) | undefined;
}>, {
disabled: boolean;
multiple: boolean;
draggable: boolean;
limit: number;
fileList: FileItem[];
defaultFileList: FileItem[];
directory: boolean;
withCredentials: boolean;
autoUpload: boolean;
showFileList: boolean;
showRemoveButton: boolean;
showRetryButton: boolean;
showCancelButton: boolean;
showUploadButton: boolean | {
showOnExceedLimit: boolean;
};
showPreviewButton: boolean;
download: boolean;
showLink: boolean;
listType: ListType;
imagePreview: boolean;
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
export default _default;