import { LoginCollect } from './LoginCollect'

export interface BasicType<T> {
  src?: ResourceStr,
  acSrc?: ResourceStr,
  text?: string,
  message?: string,
  color?: ResourceColor,
  click?: () => void,
  number?: number,
  generics?: T,
  date?: string,
  index?: number,
  loginType?: LoginCollect
  finally?: () => void
}

export type ReqString = Record<string, string>

export interface AvoidType {
  top?: number,
  bottom?: number
}

export interface MessageType {
  text: string,
  header: ResourceStr,
  role: Role,
  id?: number
}

export enum Role {
  USER,
  OTHER,
  CARD
}


export interface DelPhotoParam {
  src: string,
  type: 'bill' | 'header' | 'image'
}

/**
 * @description 结果回调函数的类型别名
 * @param res 结果输出
 * @param err 错误输出
 */
export type ResultCallBack<T> = (res?: T, err?: Error) => void

/**
 * @description 断点字符串类型
 */
export type BreakPointString = 'xs' | 'sm' | 'md' | 'lg'


