// 折线 export default function brokenLine(dName=[],dValue=[] ,dColor=[],dx=[]){ return{ tooltip: { trigger: 'axis', axisPointer: { // 坐标轴指示器,坐标轴触发有效 type: 'line' // 默认为直线,可选为:'line' | 'shadow' }, confine: true }, legend: { icon: 'rectangle',//data图标样式 itemWidth: 8,//data图标大小 itemHeight: 8, left: 5, textStyle: { fontSize: 8, fontWeight: 400 }, // data: ['微博', '其他','短视频', '微信','APP', '论坛', '新闻'], data:dName // color:['#FF4852','#FF6E25','#FFBF00','#20CC62','#00D6D6','#00AAFF','#7257FF'], }, //图表位置 grid: { left: 7, right: 7, bottom: 7, top: 36, containLabel: true }, yAxis: [ { type: 'value', axisTick:{ show:false //去除刻度线 }, axisLine:{ show:false //去除轴线 }, axisLabel: { color: '#999999',//y轴文本颜色 textStyle: { fontSize : 9 }, formatter:(value) => { if(value >= 10000){ value = (value / 10000) + '万'; } return value; } }, splitLine: { //分割线 // lineStyle:{ // // color:"#2d3436" // } show: true, lineStyle: { type: 'dashed', color: '#E8E8E8', } } } ], xAxis: [ { type: 'category', // data: ['00:00', '04:00', '08:00', '12:00', '16:00', '20:00', '24:00'], data:dx, axisTick:{ show:false //去除刻度线 }, axisLine:{ show:false, //去除轴线 }, axisLabel: { color: '#999999',//x轴文本颜色 textStyle: { fontSize : 9 }, formatter: (value) => { let rex = "00:00:00"; let isCont = false; let str = value; for(let i = 0;i