自己做的,第一个是我自己做的, 想要把标题改成第二的样式, 在线等, 比较急, 求帮忙
怎么把Y轴的标题往左边调一点点
想要移动的位置
js
let option = {
color: ["#003366", "#006699", "#4cabce", "#e5323e"],
title: {
show: true,
text: "电导率us/cm",
// padding: [10],
textStyle: {
fontWeight: "normal",
color: "#fff", // 标题颜色
fontSize: 14,
},
left: "center"
},
tooltip: {
trigger: "axis",
// 鼠标移动柱状图是提示文字
show: true,
axisPointer: {
type: "shadow"
}
},
legend: {
data: legend,
textStyle: {
color: "#fff"
}
},
toolbox: {
show: true,
orient: "vertical",
left: "right",
top: "center",
feature: {
mark: {
show: true
},
dataView: {
show: true,
readOnly: false
},
magicType: {
show: true,
type: ["line", "bar", "stack", "tiled"]
},
restore: {
show: true
},
saveAsImage: {
show: true
}
}
},
calculable: true,
xAxis: [
{
type: "category",
axisLabel: {
show: true,
textStyle: {
color: "#fff"
}
},
axisLine: {
lineStyle: {
color: "#fff"
}
},
axisTick: {
show: false
},
data: names
}
],
yAxis: [
{
type: "value",
axisLine: {
lineStyle: {
color: "#fff"
}
},
splitLine: {
lineStyle: {
color: ["#fff"]
}
}
}
],
series: solumList
};
感觉用
yAxis
的name
合理一点 设置nameLocation:'center'