/** * @file 路网单元模块中的chart options */ /** * AreaInfo页面-通行车次line-chart-option */ export const areaInfoOccByHourOption = { tooltip: { trigger: "axis", axisPointer: { type: "cross", crossStyle: { color: "#999", }, }, }, grid: { left: "15%", top: "30", right: "1", bottom: "20", }, legend: { data: [ { name: "通行车次数", icon: "roundRect", }, ], textStyle: { color: "#fff", }, }, xAxis: { type: "category", data: [] as any[], axisPointer: { type: "shadow", }, splitLine: { show: true, lineStyle: { color: "#6E7389", type: "dashed", }, }, }, yAxis: { type: "value", min: 0, max: 200, interval: 40, axisLabel: { formatter: "{value}", }, splitLine: { lineStyle: { color: "#6E7389", type: "dashed", }, }, }, series: [ { name: "通行车次数", type: "line", data: [] as any[], itemStyle: { color: "#AAD827", }, areaStyle: { color: { type: "linear", x: 0, y: 0, x2: 0, y2: 1, colorStops: [ { offset: 0, color: "#AAD827", // 0% 处的颜色 }, { offset: 1, color: "rgba(170, 216, 39, 0)", // 100% 处的颜色 }, ], }, }, }, ], }; /** * AreaInfo页面-平均车速line-chart-option */ export const areaInfoSpeedByHourOption = { tooltip: { trigger: "axis", axisPointer: { type: "cross", crossStyle: { color: "#999", }, }, }, grid: { left: "10%", top: "30", right: "1", bottom: "20", }, legend: { data: [ { name: "平均车速", icon: "roundRect", }, ], textStyle: { color: "#fff", }, }, xAxis: { type: "category", data: [] as any[], axisPointer: { type: "shadow", }, splitLine: { show: true, lineStyle: { color: "#6E7389", type: "dashed", }, }, }, yAxis: { type: "value", min: 0, max: 120, interval: 40, axisLabel: { formatter: "{value}", }, splitLine: { lineStyle: { color: "#6E7389", type: "dashed", }, }, }, series: [ { name: "平均车速", type: "line", data: [] as any[], itemStyle: { color: "#FAA603", }, areaStyle: { color: { type: "linear", x: 0, y: 0, x2: 0, y2: 1, colorStops: [ { offset: 0, color: "#FAA603", // 0% 处的颜色 }, { offset: 1, color: "rgba(250, 166, 3, 0)", // 100% 处的颜色 }, ], }, }, }, ], }; /** * RoadInfo页面-通行车次line-chart-option */ export const roadOccChartOption = { tooltip: { trigger: "axis", axisPointer: { type: "cross", crossStyle: { color: "#999", }, }, }, grid: { left: "10%", top: "30", right: "1", bottom: "20", }, legend: { data: [ { name: "通行车次数", icon: "roundRect", }, ], textStyle: { color: "#fff", }, }, xAxis: { type: "category", data: [] as any[], axisPointer: { type: "shadow", }, splitLine: { show: true, lineStyle: { color: "#6E7389", type: "dashed", }, }, }, yAxis: { type: "value", min: 0, interval: 5, axisLabel: { formatter: "{value}", }, splitLine: { lineStyle: { color: "#6E7389", type: "dashed", }, }, }, series: [ { name: "通行车次数", type: "line", data: [] as any[], itemStyle: { color: "#AAD827", }, areaStyle: { color: { type: "linear", x: 0, y: 0, x2: 0, y2: 1, colorStops: [ { offset: 0, color: "#AAD827", // 0% 处的颜色 }, { offset: 1, color: "rgba(170, 216, 39, 0)", // 100% 处的颜色 }, ], }, }, }, ], }; /** * RoadInfo页面-平均速度line-chart-option */ export const roadSpeedChartOption = { tooltip: { trigger: "axis", axisPointer: { type: "cross", crossStyle: { color: "#999", }, }, }, grid: { left: "10%", top: "30", right: "1", bottom: "20", }, legend: { data: [{ name: "平均速度", icon: "roundRect" }], textStyle: { color: "#fff", }, }, xAxis: { type: "category", data: [] as any[], axisPointer: { type: "shadow", }, splitLine: { show: true, lineStyle: { color: "#6E7389", type: "dashed", }, }, }, yAxis: { type: "value", min: 0, interval: 5, axisLabel: { formatter: "{value}", }, splitLine: { lineStyle: { color: "#6E7389", type: "dashed", }, }, }, series: [ { name: "平均速度", type: "line", data: [] as any[], itemStyle: { color: "#FAA603", }, areaStyle: { color: { type: "linear", x: 0, y: 0, x2: 0, y2: 1, colorStops: [ { offset: 0, color: "#FAA603", // 0% 处的颜色 }, { offset: 1, color: "rgba(250, 166, 3, 0)", // 100% 处的颜色 }, ], }, }, }, ], };