export interface UploadFile {
    id: string;
    name: string;
    file?: File;
    progress: number;
    controller?: AbortController;
    status: 'uploading' | 'done' | 'error';
    url?: string;
    size?: number;
    preview?: string;
    timer?: number;
    realProgress?: number;
}
type UploadOptions = {
    modelKey?: string;
    signal?: AbortSignal;
    onProgress?: (p: number) => void;
};
type UploadWithProgressOptions = UploadOptions & {
    onFakeProgress?: (delta: number) => void;
};
export declare class AssetHelper {
    static minioBasePath: string;
    private static transfer;
    private static fileUrlMap;
    private static imageCache;
    static init(opts: {
        transfer: (key: string) => string;
    }): void;
    /** 上传（基础版） */
    static upload(file: File, opts?: UploadOptions): Promise<any>;
    /** 上传（带进度） */
    static uploadWithProgress(file: File, opts?: UploadWithProgressOptions): Promise<any>;
    /** 上传前校验 */
    static beforeUploadFun(file: File, { maxSize, acceptList, beforeUpload, }: {
        maxSize: number;
        acceptList: string[];
        beforeUpload?: (file: File) => Promise<unknown>;
    }): Promise<undefined>;
    /** 地址转化 */
    static resolveUrl(src?: string | File | null): string | null;
    /**
     * 加载图片，返回 HTMLImageElement
     * @param src File | minio key | http url
     */
    static loadImage(src?: string | File | null): Promise<HTMLImageElement | null>;
    /**
     * 获取预览 URL（统一出口）
     */
    static getPreviewUrl(url?: string | File | null, name?: string, callback?: (url: string) => string): string | null;
    static revoke(file?: File | null): void;
    /**
     * 生成白底文字图片（兜底图）
     */
    private static createWhiteImageWithText;
    static clear(): void;
}
export {};
