fix: polish yak forecast overlay chart

V2.0
M先生 4 weeks ago
parent 34ca64f930
commit a34d7b57ce
  1. 13
      src/views/yakManagement/index.vue

@ -21,6 +21,7 @@
:tile-url-template="yakMapTileUrlTemplate"
:center="yakOlMapCenter"
:max-zoom="21"
:overlay-layer="activeYakMapLayer"
@ready="handleYakOlReady"
@layer-status="handleYakLayerStatus"
@tile-status="handleYakTileStatus"
@ -1749,7 +1750,7 @@ const monthlyForecastOption = computed(() => ({
itemHeight: 8,
textStyle: { color: "rgba(222, 250, 255, 0.78)", fontSize: 10 },
},
grid: { left: 40, right: 42, top: 34, bottom: 28 },
grid: { left: 52, right: 42, top: 34, bottom: 28 },
xAxis: {
type: "category",
data: monthlyRows.value.map((item) => item.month || item.name),
@ -1760,7 +1761,15 @@ const monthlyForecastOption = computed(() => ({
yAxis: [
{
type: "value",
axisLabel: { color: "rgba(223, 250, 255, 0.58)", fontSize: 10 },
axisLabel: {
color: "rgba(223, 250, 255, 0.58)",
fontSize: 10,
formatter: (value) => {
const number = Number(value)
if (!Number.isFinite(number)) return value
return Math.abs(number) >= 10000 ? `${Number((number / 10000).toFixed(1))}` : `${number}`
},
},
splitLine: { lineStyle: { color: "rgba(48, 220, 255, 0.1)", type: "dashed" } },
},
{

Loading…
Cancel
Save