export const CircelOptions = () => ({
  tooltip: {
    trigger: 'item'
  },
  series: [
    {
      name: '通行车次',
      type: 'pie',
      radius: ['70%', '80%'],
      labelLine: {
        show: false
      },
      label: {
        show: false
      },
      data: [
        { value: 0, name: '危化品车' },
        { value: 0, name: '客车' },
        { value: 0, name: '轿车' },
        { value: 0, name: '货车' },
        { value: 0, name: '其他' }
      ]
    }
  ]
})

export const BarOptions = () => ({
  title: {
    left: 'left',
    textStyle: {
      color: '#FFFFFF',
      fontSize: 14
    }
  },
  tooltip: {
    show: true
  },
  grid: {
    top: 45,
    bottom: 45,
    left: 86,
    right: 20
  },
  legend: {
    show: true,
    top: 6,
    right: 22,
    itemWidth: 8,
    itemHeight: 8,
    textStyle: {
      color: '#ffffff'
    }
  },
  xAxis: {
    type: 'category',
    data: [],
    
    axisTick: {
      show: false
    },
    axisLabel: {
      color: '#ffffff',
      rotate: 30,
      margin: 20,
      padding: [0, -15, 0, 0]
    },
    axisLine: {
      show: true,
      lineStyle: {
        color: 'rgba(255, 255, 255, 0.2)'
      }
    }
  },
  yAxis: {
    type: 'value',
    name: '车次',
    nameTextStyle: {
      color: '#ffffff'
    },
    splitLine: {
      show: false,
    },
    axisLabel: {
      color: '#ffffff'
    },
    axisLine: {
      show: true,
      lineStyle: {
        color: 'rgba(255, 255, 255, 0.2)'
      }
    }
  },
  barWidth: 10,
  series: []
})

export const CAR_TYPES = [
  { name: '危化品车', color: '#FFA71A' },
  { name: '客车', color: '#507AFC' },
  { name: '轿车', color: '#70A9FF' },
  { name: '货车', color: '#A5D80B' },
  { name: '其他', color: '#00C2C2' }
]

export const CAR_SPEED_TYPES = [
  { name: '大型车', color: '#FFA71A', key: 'largeSpeed' },
  { name: '小型车', color: '#507AFC', key: 'smallSpeed' }
]