From 2cbddaeb4a4a45b1e0b8dbc802f10b0efe2c72d5 Mon Sep 17 00:00:00 2001 From: aixianling Date: Sun, 29 Sep 2024 14:37:58 +0800 Subject: [PATCH] =?UTF-8?q?=E8=B0=83=E6=95=B4=E7=A7=AF=E5=88=86=E6=8E=92?= =?UTF-8?q?=E5=90=8D=E7=9A=84=E6=A0=B7=E5=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- project/biaopin/dv/weiyang/AppWeiyangDv.vue | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/project/biaopin/dv/weiyang/AppWeiyangDv.vue b/project/biaopin/dv/weiyang/AppWeiyangDv.vue index cf160347..0d8347a2 100644 --- a/project/biaopin/dv/weiyang/AppWeiyangDv.vue +++ b/project/biaopin/dv/weiyang/AppWeiyangDv.vue @@ -35,7 +35,8 @@ const aiTrend = { } const integralOrder = { series: { - name: "c", type: "bar", barWidth: 10, + type: "bar", barWidth: 10, + encode: {x: 'integral', y: 'name'}, label: {position: [390, 0], show: true, color: "#fff"}, labelLine: hide, showBackground: !0, backgroundStyle: {color: "rgba(107,126,148,0.4)"}, @@ -60,10 +61,11 @@ const integralOrder = { yAxis: { type: "category", inverse: true, axisLine: hide, axisTick: hide, axisPointer: hide, axisLabel: { + showMaxLabel: true, align: 'left', margin:60, color: "#9CB3C9", formatter: (name, index) => { const icon = { 0: "🥇", 1: "🥈", 2: "🥉", - }[index] ?? `{div|${index}}` + }[index] ?? `{div|${index + 1}} ` return `${icon} ${name}` }, rich: { @@ -72,13 +74,13 @@ const integralOrder = { borderColor: {type: "linear", x: 0, y: 0, x2: 0, y2: 1, colorStops: [{offset: 0, color: "#00EFFF"}, {offset: 1, color: "#00527D"}]}, color: '#fff', borderRadius: 4, - padding: [3, 4] + padding: [2, 2, 0, 2] } } } }, xAxis: hide, - grid: {left: 20, right: 40, top: 0, bottom: 0, containLabel: true}, + grid: {left: -40, right: 40, top: 0, bottom: 0, containLabel: true}, legend: hide, tooltip: {trigger: 'axis', backgroundColor: "#33333388", textStyle: {color: '#fff'}} }