import type { ComponentProps } from 'vue-component-type-helpers'; import { type OUIAProps } from '../../helpers/ouia'; import PfFileUploadField from './FileUploadField.vue'; export type FileErrorCode = 'file-invalid-type' | 'file-too-large' | 'file-too-small' | 'too-many-files'; export interface FileError { code: FileErrorCode; message: string; } export interface FileRejection { file: File; errors: FileError[]; } interface Props extends OUIAProps, Omit, 'ouiaId' | 'ouiaSafe' | 'modelValue' | 'filename' | 'loading' | 'dragActive'> { /** Unique id for the text area. Also used to generate ids for accessible labels. */ id?: string; /** What type of file. With 'text' or 'dataURL' the file is read and its content becomes the value; otherwise the value is the selected File object. */ type?: 'text' | 'dataURL'; /** Name property for the hidden file input, so that the selected file is submitted with a native form. */ name?: string; /** Accepted file types, as MIME types (`text/csv`, `image/*`) or extensions (`.csv`), like the accept attribute of a file input. */ accept?: string | readonly string[]; /** Maximum file size in bytes. */ maxSize?: number; /** Minimum file size in bytes. */ minSize?: number; /** Flag to show if the field is disabled. */ disabled?: boolean; } declare const _default: typeof __VLS_export; export default _default; declare const __VLS_export: __VLS_WithSlots any; "update:filename": (value: string | null) => any; "update:loading": (value: boolean) => any; } & { browseButtonClick: (e: PointerEvent) => any; clearButtonClick: (e: PointerEvent) => any; fileInputChange: (file: File | null) => any; dropAccepted: (files: File[]) => any; dropRejected: (rejections: FileRejection[]) => any; readStarted: (file: File) => any; readFinished: (file: File, content: string) => any; readFailed: (error: DOMException | null, file: File) => any; }, string, import("vue").PublicProps, Readonly & Readonly<{ "onUpdate:modelValue"?: ((value: string | File | null) => any) | undefined; onBrowseButtonClick?: ((e: PointerEvent) => any) | undefined; onClearButtonClick?: ((e: PointerEvent) => any) | undefined; "onUpdate:filename"?: ((value: string | null) => any) | undefined; "onUpdate:loading"?: ((value: boolean) => any) | undefined; onFileInputChange?: ((file: File | null) => any) | undefined; onDropAccepted?: ((files: File[]) => any) | undefined; onDropRejected?: ((rejections: FileRejection[]) => any) | undefined; onReadStarted?: ((file: File) => any) | undefined; onReadFinished?: ((file: File, content: string) => any) | undefined; onReadFailed?: ((error: DOMException | null, file: File) => any) | undefined; }>, { id: string; }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, { /** Additional content rendered after (or instead of) the file preview, like a pf-file-upload-helper-text */ default?: (props?: Record) => any; }>; type __VLS_WithSlots = T & { new (): { $slots: S; }; }; //# sourceMappingURL=FileUpload.vue.d.ts.map