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 '#FFE1EB'
      case 'v.douyin.com':
      case 'www.iesdouyin.com':
      case 'vt.tiktok.com':
        return '#D9D9D9'
      case 'm.toutiao.com':
        return '#FFD9D9'
      case 'video.weibo.com':
      case 'weibo.com':
      case 'm.weibo.cn':
      case 'shop.sc.weibo.com':
        return '#FFF0DC'
      case 'v.kuaishou.com':
        return '#FFE4DA'
      case 'wxapp.tc.qq.com':
      case 'm.v.qq.com':
        return '#D9F0FF'
      case 'twitter.com':
      case 'x.com':
        return '#DCF1FC'
      case 'xhslink.com':
      case 'www.xiaohongshu.com':
        return '#FFDEE2'
      case 'instagram.com':
      case 'www.instagram.com':
        return '#EEE1FE'
      case 'mr.baidu.com':
      case 'm.baidu.com':
      case 'mbd.baidu.com':
        return '#EAF1FF'
      case 'youtu.be':
      case 'youtube.com':
      case 'm.youtube.com':
      case 'www.youtube.com':
        return '#FFE8E8'
      case 'mp.weixin.qq.com':
        return '#E5FAE5'
      case 'e.tb.cn':
      case 'm.tb.cn':
        return '#FFEFE5'
      case 'www.facebook.com':
        return '#E6EFFE'
      case 'v.ixigua.com':
      case 'www.ixigua.com':
        return '#FFDCE9'
      case 'mobile.yangkeduo.com':
        return '#FDE5E6'
      case 'm.youku.com':
        return '#D9F7FF'
      case '163cn.tv':
        return '#FDE5E6'
      case 'qishui.douyin.com':
        return '#DBFBDC'
      case 'qr.1688.com':
      case 'detail.m.1688.com':
        return '#FFEDE5'
      case 'h5.pipix.com':
        return '#FFEDF0'
      case 'app.cctv.com':
        return '#E5E5E5'
      case 'vk.com':
        return '#E9F3FD'
      case 'www.finkapp.cn':
        return '#FEEBEB'
      case 'novelquickapp.com':
        return '#FFF4EA'
      case 'video.weishi.qq.com':
        return '#EAEFFE'
      case 'm.ctrip.com':
        return '#E8F2FC'
    }
    return '#F0F0F0'
  }

  getTypeTextColor(): string {
    switch (this.domain) {
      case 'b23.tv':
      case 'm.bilibili.com':
      case 'www.bilibili.com':
        return '#FD3575'
      case 'v.douyin.com':
      case 'www.iesdouyin.com':
      case 'vt.tiktok.com':
        return '#000000'
      case 'm.toutiao.com':
        return '#FF1A19'
      case 'video.weibo.com':
      case 'weibo.com':
      case 'm.weibo.cn':
      case 'shop.sc.weibo.com':
        return '#FF9C13'
      case 'v.kuaishou.com':
        return '#FE4806'
      case 'wxapp.tc.qq.com':
      case 'm.v.qq.com':
        return '#0097FF'
      case 'twitter.com':
      case 'x.com':
        return '#139EEA'
      case 'xhslink.com':
      case 'www.xiaohongshu.com':
        return '#FF213C'
      case 'instagram.com':
      case 'www.instagram.com':
        return '#8F35F6'
      case 'mr.baidu.com':
      case 'm.baidu.com':
      case 'mbd.baidu.com':
        return '#2F73FF'
      case 'youtu.be':
      case 'youtube.com':
      case 'm.youtube.com':
      case 'www.youtube.com':
        return '#FF2222'
      case 'mp.weixin.qq.com':
        return '#01D200'
      case 'e.tb.cn':
      case 'm.tb.cn':
        return '#FF6601'
      case 'www.facebook.com':
        return '#0865FE'
      case 'v.ixigua.com':
      case 'www.ixigua.com':
        return '#FF146B'
      case 'mobile.yangkeduo.com':
        return '#F30009'
      case 'm.youku.com':
        return '#00C6FE'
      case '163cn.tv':
        return '#F30009'
      case 'qishui.douyin.com':
        return '#0AE515'
      case 'qr.1688.com':
      case 'detail.m.1688.com':
        return '#FF4C00'
      case 'h5.pipix.com':
        return '#FF5370'
      case 'app.cctv.com':
        return '#000000'
      case 'vk.com':
        return '#2888F5'
      case 'www.finkapp.cn':
        return '#FC4040'
      case 'novelquickapp.com':
        return '#FF9436'
      case 'video.weishi.qq.com':
        return '#3565FB'
      case 'm.ctrip.com':
        return '#1E82E9'
    }
    return '#999999'
  }
}