export type UploadFileType =
  | 'image'
  | 'video'
  | 'audio'
  | 'word'
  | 'excel'
  | 'ppt'
  | 'pdf'
  | 'rar'
  | 'file'

export type UploadRule = {
  name: string
  type: UploadFileType
  color: string
  exts: string[]
}

export type UploadItem = {
  uid: string
  name: string
  url: string
  preload?: string
  type: UploadFileType
  size?: number
  progress: number
  error?: string
}

export type UploadOptions = {
  prefixPath?: string
  onProgress?: (progress: number) => void
}

export type UploadResult = {
  url: string
  key?: string
  fileId?: string
}
