如何使顶点图表反应饼图更厚
How to make apex chart react pie bar thicker
如何让钢筋变粗?
import React from "react";
import Chart from "react-apexcharts";
const series = [44, 55, 41, 17, 15];
const options = {
chart: {
type: "donut"
}
};
export default function PieChart() {
return (
<div>
<Chart options={options} series={series} type="donut" height={300} />
</div>
);
}
*此处为沙盒示例 https://codesandbox.io/s/vigilant-pateu-tv4t5q?file=/src/App.tsx *
使用 plotOptions -> pie -> donut --> size
增加或减少甜甜圈的大小。增加甜甜圈大小会减小条形宽度,反之亦然。已更新 codesandbox
const options = {
chart: {
type: "donut"
},
plotOptions: {
pie: {
donut: {
size: "25%"
}
}
}
};
如何让钢筋变粗?
import React from "react";
import Chart from "react-apexcharts";
const series = [44, 55, 41, 17, 15];
const options = {
chart: {
type: "donut"
}
};
export default function PieChart() {
return (
<div>
<Chart options={options} series={series} type="donut" height={300} />
</div>
);
}
*此处为沙盒示例 https://codesandbox.io/s/vigilant-pateu-tv4t5q?file=/src/App.tsx *
使用 plotOptions -> pie -> donut --> size
增加或减少甜甜圈的大小。增加甜甜圈大小会减小条形宽度,反之亦然。已更新 codesandbox
const options = {
chart: {
type: "donut"
},
plotOptions: {
pie: {
donut: {
size: "25%"
}
}
}
};