@aveonline/ui-react 2.28.1 → 2.28.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -3,7 +3,7 @@ interface PieData {
|
|
|
3
3
|
name: string;
|
|
4
4
|
value: number;
|
|
5
5
|
}
|
|
6
|
-
export default function Pie<T extends PieData>({ data, width, height, innerRadius, outerRadius, cx, cy, paddingAngle, cornerRadius, dataKey, isLoading, minValue, colors, decimals }: IPropsPie<T> & {
|
|
6
|
+
export default function Pie<T extends PieData>({ data, width, height, innerRadius, outerRadius, cx, cy, paddingAngle, cornerRadius, dataKey, isLoading, minValue, colors, decimals, hasLabel, children }: IPropsPie<T> & {
|
|
7
7
|
minValue?: number;
|
|
8
8
|
colors?: string[];
|
|
9
9
|
}): JSX.Element;
|
package/dist/ui-react.mjs
CHANGED
|
@@ -49498,24 +49498,33 @@ function f9e({
|
|
|
49498
49498
|
isLoading: d = !1,
|
|
49499
49499
|
minValue: f = 2,
|
|
49500
49500
|
colors: h,
|
|
49501
|
-
decimals: p = 3
|
|
49501
|
+
decimals: p = 3,
|
|
49502
|
+
hasLabel: g = !0,
|
|
49503
|
+
children: v
|
|
49502
49504
|
}) {
|
|
49503
|
-
const
|
|
49504
|
-
return d ? /* @__PURE__ */ A.jsx("div", { className: "flex flex-col items-center gap-y-3 justify-center text-center rounded-b-sm border-border-subdued", children: /* @__PURE__ */ A.jsx("div", { className: "py-8", children: /* @__PURE__ */ A.jsx(Ia, { size: "lg" }) }) }) : /* @__PURE__ */ A.
|
|
49505
|
-
|
|
49506
|
-
|
|
49507
|
-
|
|
49508
|
-
|
|
49509
|
-
|
|
49510
|
-
|
|
49511
|
-
|
|
49512
|
-
|
|
49513
|
-
|
|
49514
|
-
|
|
49515
|
-
|
|
49516
|
-
|
|
49517
|
-
|
|
49518
|
-
|
|
49505
|
+
const C = e.filter((E) => E.value >= f), b = O6e(C), x = h && h.length >= b.length ? h : Array.from({ length: b.length }, (E, w) => `hsl(${w * 360 / b.length}, 70%, 50%)`), y = a || Math.min(t, n) / (b.length > 5 ? 2.5 : 2);
|
|
49506
|
+
return d ? /* @__PURE__ */ A.jsx("div", { className: "flex flex-col items-center gap-y-3 justify-center text-center rounded-b-sm border-border-subdued", children: /* @__PURE__ */ A.jsx("div", { className: "py-8", children: /* @__PURE__ */ A.jsx(Ia, { size: "lg" }) }) }) : /* @__PURE__ */ A.jsxs(d5e, { width: t, height: n, children: [
|
|
49507
|
+
/* @__PURE__ */ A.jsx(
|
|
49508
|
+
Y1,
|
|
49509
|
+
{
|
|
49510
|
+
data: b,
|
|
49511
|
+
innerRadius: r,
|
|
49512
|
+
outerRadius: y,
|
|
49513
|
+
cx: i,
|
|
49514
|
+
cy: o,
|
|
49515
|
+
paddingAngle: l,
|
|
49516
|
+
dataKey: u,
|
|
49517
|
+
cornerRadius: s,
|
|
49518
|
+
labelLine: g,
|
|
49519
|
+
label: ({ value: E, name: w }) => {
|
|
49520
|
+
if (g)
|
|
49521
|
+
return w ? `${w} - ${parseFloat(E).toFixed(p)}%` : `${parseFloat(E).toFixed(p)}%`;
|
|
49522
|
+
},
|
|
49523
|
+
children: b.map((E, w) => /* @__PURE__ */ A.jsx(_o, { fill: x[w] }, `cell-${w}`))
|
|
49524
|
+
}
|
|
49525
|
+
),
|
|
49526
|
+
v
|
|
49527
|
+
] });
|
|
49519
49528
|
}
|
|
49520
49529
|
function h9e({
|
|
49521
49530
|
data: e,
|