export class DownloadHistoryEntity {
  id: string = ''
  title: string = ''
  status: string = ''
  description: string = ''
  create_time: string = ''
  domain: string = ''
  request: string = ''
  save_cost: string = ''
  save_end_time: string = ''
  save_size: string = ''
  save_start_time: string = ''
  save_status: string = ''

  getTypeBgColor(): string {
    switch (this.domain) {
      case 'b23.tv':
      case 'm.bilibili.com':
      case 'www.bilibili.com':
        return '#F4306F'
      case 'v.douyin.com':
      case 'www.iesdouyin.com':
      case 'vt.tiktok.com':
        return '#80FFFFFF'
      case 'm.toutiao.com':
        return '#F91716'
      case 'video.weibo.com':
      case 'weibo.com':
      case 'm.weibo.cn':
      case 'shop.sc.weibo.com':
        return '#DE860C'
      case 'v.kuaishou.com':
        return '#DE440D'
      case 'wxapp.tc.qq.com':
      case 'm.v.qq.com':
        return '#0D95F3'
      case 'twitter.com':
      case 'x.com':
        return '#139EEA'
      case 'xhslink.com':
      case 'www.xiaohongshu.com':
        return '#EA3046'
      case 'instagram.com':
      case 'www.instagram.com':
        return '#8D32F4'
      case 'mr.baidu.com':
      case 'm.baidu.com':
      case 'mbd.baidu.com':
        return '#0D95F3'
      case 'youtu.be':
      case 'youtube.com':
      case 'm.youtube.com':
      case 'www.youtube.com':
        return '#F92C2C'
      case 'mp.weixin.qq.com':
        return '#1DDB50'
      case 'e.tb.cn':
      case 'm.tb.cn':
        return '#F96E12'
      case 'www.facebook.com':
        return '#1B6EF6'
      case 'v.ixigua.com':
      case 'www.ixigua.com':
        return '#F01566'
      case 'mobile.yangkeduo.com':
        return '#F40F18'
      case 'm.youku.com':
        return '#0CB3E2'
      case '163cn.tv':
        return '#F42C34'
      case 'qishui.douyin.com':
        return '#20C485'
      case 'qr.1688.com':
      case 'detail.m.1688.com':
        return '#F65611'
      case 'h5.pipix.com':
        return '#EE3958'
      case 'app.cctv.com':
        return '#80FFFFFF'
      case 'vk.com':
        return '#1E82F3'
      case 'www.finkapp.cn':
        return '#F62C2C'
      case 'novelquickapp.com':
        return '#F18221'
      case 'video.weishi.qq.com':
        return '#2E5DF0'
      case 'm.ctrip.com':
        return '#177DF0'
    }
    return '#33FFFFFF'
  }

  getTypeTextColor(): string {
    switch (this.domain) {
      case 'v.douyin.com':
      case 'app.cctv.com':
        return '#CC000000'
    }
    return '#CCFFFFFF'
  }
}