Toggle navigation
简约折线图
By
藏***i
2020-03-11 02:05:15
脚本
16
21
作品使用的第三方脚本
数据管理
上传数据
支持小于 5M 任意格式(csv, xlsx, json, xml, ...)的数据文件
上传后可以通过生成的文件链接异步获取托管的数据。
历史数据
0 条
无历史数据
代码修改记录
信息提示
保存作品
对当前截图不满意?你还可以
上传本地截图
重新截图
作品名称
作品描述
标签
geo
grid
legend
markLine
markPoint
bar
effectScatter
line
lines
map
timeline
title
toolbox
tooltip
visualMap
作品默认版本
最新
16
15
14
13
12
11
10
9
8
7
6
5
4
3
2
1
20:11:45
图表已生成
整理代码
刷新
代码
//对话框图片 var uploadedDataURL = "/asset/get/s/data-1547533200844-7eBMgp66l.png"; option = { grid: { left: -10, right: -10, top: 26, bottom: 10, containLabel: true }, xAxis: { type: 'category', data: ['2.20', '2.21', '2.22', '2.23', '2.24', '2.25', '2.26'], axisLine: { lineStyle:{ color:'#000000'//x轴线条颜色 } }, axisPointer: { type: 'shadow'},//展示区域 axisTick: {//不显示刻度线 show: false }, axisLabel:{ textStyle: { color: '#101010'//x轴字体颜色 } }, splitLine:{//设置网格线样式x轴对应的竖线 show: true, lineStyle:{ color: ['#999999'], } } }, yAxis: { type: 'value', splitLine:{show: false},//不显示横线 axisLabel : { show: false,},//y轴不显示数据 axisLine: {show: false,},//不显示坐标轴线 axisTick:{show:false},//不显示坐标轴刻度线 }, series: [{ name:'order', data: [14, 21, 22, 10, 18, 12, 15],//订单值 type: 'line',//折线线条 symbol: 'circle', //数值点设定为实心点 itemStyle : { normal : { color: "#02b4fd",//点的颜色 lineStyle:{ color:'#02b3fd'//线的颜色 } } }, label: { show: false, distance: 1, formatter: function(params) { var value = params.data; return value; }, emphasis: { show: true, offset: [1, 0], backgroundColor: { image: uploadedDataURL }, color: '#ffffff', padding: [6, 6, 6, 6], textStyle: { color: '#ffffff' }, rich: { bg: { backgroundColor: { image: uploadedDataURL }, color: '#ffffff', }, br: { width: '100%', height: '100%' } } } }, }], tooltip: {//指示器展示 trigger: 'axis', label: { show: true }, axisPointer : { // 坐标轴指示器,坐标轴触发有效 type : 'shadow', // 默认为直线,可选为:'line' | 'shadow' shadowStyle : { // 阴影指示器样式设置 width: 'auto', // 阴影大小 color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [{ offset: 0,//上半段颜色 color: 'rgba(254,255,255,0.00)' }, { offset: .34,//中间段颜色 color: 'rgba(208,234,252,0.25)' },{ offset: 1,//最下断段颜色 color: 'rgba(183,223,250,1)' }] ) } }, formatter: function(param) {//不展示文本 return ''; } }, };