import type { AttachmentButtonProps } from '../AttachmentButton';
import type { AttachmentButtonPopoverProps } from '../AttachmentButton/AttachmentButtonPopover';
import type { AttachmentFile } from '../AttachmentButton/types';
type SupportedFileFormatsType = AttachmentButtonPopoverProps['supportedFormat'];
export interface FileUploadManagerProps {
    /** 附件配置 */
    attachment?: {
        enable?: boolean;
        supportedFormat?: SupportedFileFormatsType;
    } & AttachmentButtonProps;
    /** 文件映射表 */
    fileMap?: Map<string, AttachmentFile>;
    /** 文件映射表变化回调 */
    onFileMapChange?: (fileMap?: Map<string, AttachmentFile>) => void;
}
export interface FileUploadManagerReturn {
    /** 文件映射表 */
    fileMap?: Map<string, AttachmentFile>;
    /** 文件上传是否完成 */
    fileUploadDone: boolean;
    /** 文件上传状态 */
    fileUploadStatus: 'uploading' | 'done' | 'error';
    /** 文件上传状态统计 */
    fileUploadSummary: {
        totalCount: number;
        doneCount: number;
        uploadingCount: number;
        errorCount: number;
    };
    /** 支持的文件格式 */
    supportedFormat: SupportedFileFormatsType;
    /** 上传图片 */
    uploadImage: (forGallery?: boolean) => Promise<void>;
    /** 更新附件文件列表 */
    updateAttachmentFiles: (newFileMap?: Map<string, AttachmentFile>) => void;
    /** 处理文件删除 */
    handleFileRemoval: (file: AttachmentFile) => Promise<void>;
    /** 处理文件重试 */
    handleFileRetry: (file: AttachmentFile) => Promise<void>;
}
/**
 * 文件上传管理器
 *
 * @description 封装文件上传相关的逻辑，包括上传、删除、重试等操作
 */
export declare const useFileUploadManager: ({ attachment, fileMap, onFileMapChange, }: FileUploadManagerProps) => FileUploadManagerReturn;
export {};
