欢迎来到尧图网

客户服务 关于我们

您的位置:首页 > 文旅 > 明星 > ECharts

ECharts

2025/3/11 14:21:35 来源:https://blog.csdn.net/qq_41985405/article/details/146155959  浏览:    关键词:ECharts

饼图

在这里插入图片描述`

{tooltip: {trigger: 'item'},color: ['rgb(78, 253, 254)', 'rgb(27, 194, 55)', 'rgb(150, 254, 46)', 'rgb(254, 224, 44)', 'rgb(241, 179, 28)', 'rgb(234, 147, 59)', 'rgb(253, 102, 60)'],series: [{name: '',type: 'pie',radius: ['65%', '78%'],itemStyle: {borderColor: '#112654',borderWidth: 2},label: {show: true,position: 'outside',margin: 30,formatter: '{b}\n{d|{d}%}',rich: {d: {// 视觉映射得到的颜色,如系列色color: 'inherit',fontWeight: 500,fontSize: 24,lineHeight: 29,}},color: 'rgb(211, 242, 255)',fontWeight: 400,fontSize: 20,lineHeight: 30,},labelLine: {show: true,length: 32,length2: 48,},data: asData.value,// 在标签拥挤重叠的情况下会挪动各个标签的位置,防止标签间的重叠。avoidLabelOverlap: true}]
}

折线图

在这里插入图片描述

{grid: {show: false,left: 50,top: 10,bottom: 30},tooltip: {show: true},xAxis: {type: 'category',data: props.xData,// 坐标轴轴线axisLine: {show: false},// 坐标轴刻度axisTick: {show: false},// 坐标轴刻度标签axisLabel: {// 是否隐藏重叠的标签hideOverlap: true,color: 'rgba(255, 250, 255, 0.7)',fontWeight: 400,fontSize: 20,lineHeight: 30},// 坐标轴在 grid 区域中的分隔线splitLine: {show: true,lineStyle: {color: 'rgb(60, 91, 117)',width: 1,type: [4, 4],}}},yAxis: {type: 'value',// 坐标轴刻度标签axisLabel: {// 是否隐藏重叠的标签hideOverlap: true,color: 'rgba(255, 250, 255, 0.7)',fontWeight: 400,fontSize: 20,lineHeight: 30},// 坐标轴在 grid 区域中的分隔线splitLine: {show: true,lineStyle: {color: 'rgb(60, 91, 117)',width: 1,type: [4, 4],}}},series: [{data: props.yData,type: 'line',// 折线拐点标志的样式itemStyle: {color: 'rgb(68, 215, 182)',},// 区域填充样式areaStyle: {// 渐变色color: {type: 'linear',x: 0,y: 0,x2: 0,y2: 1,colorStops: [{offset: 0, color: 'rgba(68, 215, 182, 0.3)' // 0% 处的颜色}, {offset: 1, color: 'rgba(68, 215, 182, 0)' // 100% 处的颜色}],}}}]
}

版权声明:

本网仅为发布的内容提供存储空间,不对发表、转载的内容提供任何形式的保证。凡本网注明“来源:XXX网络”的作品,均转载自其它媒体,著作权归作者所有,商业转载请联系作者获得授权,非商业转载请注明出处。

我们尊重并感谢每一位作者,均已注明文章来源和作者。如因作品内容、版权或其它问题,请及时与我们联系,联系邮箱:809451989@qq.com,投稿邮箱:809451989@qq.com

热搜词