@deepnoid/ui 0.1.180 → 0.1.182
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.
- package/.turbo/turbo-build.log +161 -161
- package/dist/{chunk-ROXKJQSJ.mjs → chunk-6NO7GQHG.mjs} +3 -3
- package/dist/{chunk-GWHUQUKA.mjs → chunk-6WD32ERF.mjs} +93 -79
- package/dist/{chunk-ADU7DFVK.mjs → chunk-GPJVGQ5W.mjs} +8 -2
- package/dist/{chunk-RMZ3ZIP7.mjs → chunk-KDBM7UVG.mjs} +3 -3
- package/dist/{chunk-SAWYH3JL.mjs → chunk-M5ZLURXE.mjs} +4 -4
- package/dist/{chunk-2H5EBNCD.mjs → chunk-SX2FQY4L.mjs} +4 -4
- package/dist/{chunk-MU6QDNYC.mjs → chunk-W67QZ4OB.mjs} +1 -1
- package/dist/chunk-WKTRWHDA.mjs +264 -0
- package/dist/{chunk-7C7RHDHV.mjs → chunk-XZTVXEOD.mjs} +4 -4
- package/dist/{chunk-5S4NCYZF.mjs → chunk-YTW5HJJH.mjs} +6 -6
- package/dist/components/backdrop/backdrop.mjs +2 -2
- package/dist/components/backdrop/index.mjs +2 -2
- package/dist/components/breadcrumb/breadcrumb.mjs +4 -4
- package/dist/components/breadcrumb/index.mjs +4 -4
- package/dist/components/button/button.mjs +1 -1
- package/dist/components/button/icon-button.mjs +1 -1
- package/dist/components/button/index.mjs +5 -5
- package/dist/components/button/text-button.mjs +2 -2
- package/dist/components/charts/areaChart.mjs +1 -1
- package/dist/components/charts/barChart.js +125 -111
- package/dist/components/charts/barChart.mjs +1 -1
- package/dist/components/charts/index.js +218 -190
- package/dist/components/charts/index.mjs +3 -3
- package/dist/components/charts/simpleBarChart.js +93 -79
- package/dist/components/charts/simpleBarChart.mjs +1 -1
- package/dist/components/checkbox/checkbox.mjs +2 -2
- package/dist/components/checkbox/index.mjs +2 -2
- package/dist/components/chip/chip.mjs +1 -1
- package/dist/components/chip/index.mjs +1 -1
- package/dist/components/drawer/drawer.mjs +2 -2
- package/dist/components/drawer/index.mjs +2 -2
- package/dist/components/fileUpload/fileUpload.js +6 -0
- package/dist/components/fileUpload/fileUpload.mjs +6 -6
- package/dist/components/fileUpload/index.js +6 -0
- package/dist/components/fileUpload/index.mjs +6 -6
- package/dist/components/input/index.mjs +3 -3
- package/dist/components/input/input.mjs +3 -3
- package/dist/components/list/index.mjs +2 -2
- package/dist/components/list/listItem.mjs +2 -2
- package/dist/components/modal/index.mjs +5 -5
- package/dist/components/modal/modal.mjs +5 -5
- package/dist/components/pagination/index.mjs +4 -4
- package/dist/components/pagination/pagination.mjs +4 -4
- package/dist/components/picker/datePicker.mjs +5 -5
- package/dist/components/picker/index.mjs +7 -7
- package/dist/components/picker/timePicker.mjs +4 -4
- package/dist/components/progress/index.mjs +2 -2
- package/dist/components/progress/progress.mjs +2 -2
- package/dist/components/radio/index.mjs +2 -2
- package/dist/components/radio/radio.mjs +2 -2
- package/dist/components/select/index.mjs +3 -3
- package/dist/components/select/select.mjs +3 -3
- package/dist/components/starRating/index.mjs +1 -1
- package/dist/components/starRating/starRating.mjs +1 -1
- package/dist/components/table/definition-table.mjs +2 -2
- package/dist/components/table/index.mjs +7 -7
- package/dist/components/table/table-body.mjs +6 -6
- package/dist/components/table/table-head.mjs +6 -6
- package/dist/components/table/table.mjs +6 -6
- package/dist/components/textarea/index.mjs +2 -2
- package/dist/components/textarea/textarea.mjs +2 -2
- package/dist/components/timePicker/calendar.mjs +1 -1
- package/dist/components/toast/index.mjs +5 -5
- package/dist/components/toast/toast.mjs +3 -3
- package/dist/components/toast/use-toast.mjs +4 -4
- package/dist/components/tree/index.mjs +2 -2
- package/dist/components/tree/tree.mjs +2 -2
- package/dist/index.js +224 -190
- package/dist/index.mjs +44 -44
- package/package.json +1 -1
- package/dist/chunk-JOK735WN.mjs +0 -250
- package/dist/{chunk-OEIEALIP.mjs → chunk-3DCUMRYP.mjs} +3 -3
- package/dist/{chunk-3CRSSRCH.mjs → chunk-3HXNAVAN.mjs} +3 -3
- package/dist/{chunk-IH3BJRTV.mjs → chunk-4X35QQTI.mjs} +3 -3
- package/dist/{chunk-RXDRG6MC.mjs → chunk-7H6U5XJA.mjs} +3 -3
- package/dist/{chunk-KH63CD55.mjs → chunk-ACZ3DQVT.mjs} +3 -3
- package/dist/{chunk-DS5CGU2X.mjs → chunk-BH3I4LIZ.mjs} +3 -3
- package/dist/{chunk-GS5X67UB.mjs → chunk-GVTYOGSV.mjs} +3 -3
- package/dist/{chunk-4EELFA6L.mjs → chunk-LE7PGMCV.mjs} +3 -3
- package/dist/{chunk-4LUASWAN.mjs → chunk-NDNIAALB.mjs} +3 -3
- package/dist/{chunk-MWUA62VL.mjs → chunk-NKF2TQMA.mjs} +3 -3
- package/dist/{chunk-A3WPBLOW.mjs → chunk-UINFH5AT.mjs} +3 -3
- package/dist/{chunk-PRNE3U26.mjs → chunk-XL6LZDT4.mjs} +3 -3
- package/dist/{chunk-45Y7ANPK.mjs → chunk-ZFC5O2V3.mjs} +3 -3
package/dist/index.js
CHANGED
|
@@ -12364,6 +12364,7 @@ function FileUpload({
|
|
|
12364
12364
|
const [message, setMessage] = (0, import_react38.useState)(errorMessage);
|
|
12365
12365
|
const [displayFileName, setDisplayFileName] = (0, import_react38.useState)(() => (defaultFile == null ? void 0 : defaultFile.name) || "");
|
|
12366
12366
|
const [hasUploadedFile, setHasUploadedFile] = (0, import_react38.useState)(false);
|
|
12367
|
+
const [isUploading, setIsUploading] = (0, import_react38.useState)(false);
|
|
12367
12368
|
const slots = fileUploadStyle();
|
|
12368
12369
|
const handleButtonClick = () => {
|
|
12369
12370
|
var _a;
|
|
@@ -12382,11 +12383,13 @@ function FileUpload({
|
|
|
12382
12383
|
const startUploadSimulation = (file) => {
|
|
12383
12384
|
let progress = 0;
|
|
12384
12385
|
setUploadProgress(0);
|
|
12386
|
+
setIsUploading(true);
|
|
12385
12387
|
uploadIntervalRef.current = window.setInterval(() => {
|
|
12386
12388
|
progress += 10;
|
|
12387
12389
|
setUploadProgress(progress);
|
|
12388
12390
|
if (progress >= 100) {
|
|
12389
12391
|
clearInterval(uploadIntervalRef.current);
|
|
12392
|
+
setIsUploading(false);
|
|
12390
12393
|
onFileUpload == null ? void 0 : onFileUpload(file);
|
|
12391
12394
|
}
|
|
12392
12395
|
}, 100);
|
|
@@ -12401,6 +12404,7 @@ function FileUpload({
|
|
|
12401
12404
|
setCurrentFile(null);
|
|
12402
12405
|
setDisplayFileName((defaultFile == null ? void 0 : defaultFile.name) || "");
|
|
12403
12406
|
setHasUploadedFile(false);
|
|
12407
|
+
setIsUploading(false);
|
|
12404
12408
|
if (fileInputRef.current) {
|
|
12405
12409
|
fileInputRef.current.value = "";
|
|
12406
12410
|
}
|
|
@@ -12421,6 +12425,7 @@ function FileUpload({
|
|
|
12421
12425
|
setMessage("");
|
|
12422
12426
|
setDisplayFileName((defaultFile == null ? void 0 : defaultFile.name) || "");
|
|
12423
12427
|
setHasUploadedFile(false);
|
|
12428
|
+
setIsUploading(false);
|
|
12424
12429
|
if (fileInputRef.current) {
|
|
12425
12430
|
fileInputRef.current.value = "";
|
|
12426
12431
|
}
|
|
@@ -12474,6 +12479,7 @@ function FileUpload({
|
|
|
12474
12479
|
variant: "outline",
|
|
12475
12480
|
onClick: handleButtonClick,
|
|
12476
12481
|
disabled: !!(currentFile && hasUploadedFile),
|
|
12482
|
+
isLoading: isUploading,
|
|
12477
12483
|
children: buttonText
|
|
12478
12484
|
}
|
|
12479
12485
|
),
|
|
@@ -12928,8 +12934,8 @@ var BarChartComponent = (0, import_react41.forwardRef)((originalProps, ref) => {
|
|
|
12928
12934
|
const { payload, x, y } = e;
|
|
12929
12935
|
if (!payload || !payload[dataKey]) return;
|
|
12930
12936
|
setTooltipState({
|
|
12931
|
-
x,
|
|
12932
|
-
y,
|
|
12937
|
+
barX: x,
|
|
12938
|
+
barY: y - 10,
|
|
12933
12939
|
value: payload[dataKey],
|
|
12934
12940
|
dataKey,
|
|
12935
12941
|
label: payload.title
|
|
@@ -13000,7 +13006,7 @@ var BarChartComponent = (0, import_react41.forwardRef)((originalProps, ref) => {
|
|
|
13000
13006
|
const tooltipRect = tooltipRef.current.getBoundingClientRect();
|
|
13001
13007
|
const chartWidth = chartRect.width;
|
|
13002
13008
|
const tooltipWidth = tooltipRect.width;
|
|
13003
|
-
let left = tooltipState.
|
|
13009
|
+
let left = tooltipState.barX - tooltipWidth / 2;
|
|
13004
13010
|
const padding2 = 8;
|
|
13005
13011
|
if (left < padding2) {
|
|
13006
13012
|
left = padding2;
|
|
@@ -13009,114 +13015,128 @@ var BarChartComponent = (0, import_react41.forwardRef)((originalProps, ref) => {
|
|
|
13009
13015
|
}
|
|
13010
13016
|
setTooltipLeft(left);
|
|
13011
13017
|
}, [tooltipState]);
|
|
13012
|
-
return /* @__PURE__ */ (0, import_jsx_runtime43.jsxs)(
|
|
13013
|
-
|
|
13014
|
-
|
|
13015
|
-
|
|
13016
|
-
{
|
|
13017
|
-
|
|
13018
|
-
|
|
13019
|
-
|
|
13020
|
-
|
|
13021
|
-
|
|
13022
|
-
|
|
13023
|
-
|
|
13024
|
-
|
|
13025
|
-
|
|
13026
|
-
|
|
13027
|
-
|
|
13028
|
-
|
|
13029
|
-
|
|
13030
|
-
|
|
13031
|
-
|
|
13032
|
-
|
|
13033
|
-
|
|
13034
|
-
|
|
13035
|
-
|
|
13036
|
-
|
|
13037
|
-
|
|
13038
|
-
|
|
13039
|
-
|
|
13040
|
-
|
|
13041
|
-
|
|
13042
|
-
|
|
13043
|
-
|
|
13044
|
-
|
|
13045
|
-
|
|
13046
|
-
|
|
13047
|
-
|
|
13048
|
-
|
|
13049
|
-
|
|
13050
|
-
|
|
13051
|
-
|
|
13052
|
-
|
|
13053
|
-
|
|
13054
|
-
|
|
13055
|
-
|
|
13056
|
-
|
|
13057
|
-
|
|
13058
|
-
|
|
13059
|
-
|
|
13060
|
-
|
|
13061
|
-
|
|
13062
|
-
|
|
13063
|
-
|
|
13064
|
-
|
|
13065
|
-
|
|
13066
|
-
|
|
13067
|
-
|
|
13068
|
-
|
|
13069
|
-
|
|
13070
|
-
|
|
13071
|
-
|
|
13072
|
-
|
|
13073
|
-
|
|
13074
|
-
|
|
13075
|
-
|
|
13076
|
-
|
|
13077
|
-
|
|
13078
|
-
|
|
13079
|
-
|
|
13080
|
-
|
|
13081
|
-
|
|
13082
|
-
|
|
13083
|
-
|
|
13084
|
-
|
|
13085
|
-
|
|
13086
|
-
|
|
13087
|
-
|
|
13088
|
-
|
|
13089
|
-
|
|
13090
|
-
|
|
13091
|
-
|
|
13092
|
-
|
|
13093
|
-
|
|
13094
|
-
|
|
13095
|
-
|
|
13096
|
-
|
|
13097
|
-
|
|
13098
|
-
|
|
13099
|
-
|
|
13100
|
-
|
|
13101
|
-
|
|
13102
|
-
|
|
13103
|
-
|
|
13104
|
-
|
|
13105
|
-
|
|
13106
|
-
|
|
13107
|
-
|
|
13108
|
-
|
|
13109
|
-
|
|
13110
|
-
|
|
13111
|
-
|
|
13112
|
-
|
|
13113
|
-
|
|
13114
|
-
|
|
13115
|
-
|
|
13116
|
-
|
|
13117
|
-
|
|
13118
|
-
|
|
13119
|
-
|
|
13018
|
+
return /* @__PURE__ */ (0, import_jsx_runtime43.jsxs)(
|
|
13019
|
+
"div",
|
|
13020
|
+
{
|
|
13021
|
+
ref: chartRef,
|
|
13022
|
+
className: slots.base({ class: classNames == null ? void 0 : classNames.base }),
|
|
13023
|
+
onMouseLeave: handleMouseLeave,
|
|
13024
|
+
onMouseMove: (e) => {
|
|
13025
|
+
const target = e.target;
|
|
13026
|
+
if (!target.closest('[data-testid="recharts-bar-rectangle"]') && !target.closest(".recharts-bar-rectangle") && target.tagName !== "path") {
|
|
13027
|
+
setTooltipState(null);
|
|
13028
|
+
}
|
|
13029
|
+
},
|
|
13030
|
+
children: [
|
|
13031
|
+
label && /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("p", { className: slots.label({ class: classNames == null ? void 0 : classNames.label }), children: label }),
|
|
13032
|
+
/* @__PURE__ */ (0, import_jsx_runtime43.jsx)(import_recharts3.ResponsiveContainer, { width: "100%", height: "100%", children: /* @__PURE__ */ (0, import_jsx_runtime43.jsxs)(
|
|
13033
|
+
import_recharts3.BarChart,
|
|
13034
|
+
{
|
|
13035
|
+
data,
|
|
13036
|
+
margin: { left: -20 },
|
|
13037
|
+
barSize: 20,
|
|
13038
|
+
barGap,
|
|
13039
|
+
className: "[&_.recharts-surface]:outline-none [&_.recharts-surface]:focus:outline-none",
|
|
13040
|
+
children: [
|
|
13041
|
+
/* @__PURE__ */ (0, import_jsx_runtime43.jsxs)("defs", { children: [
|
|
13042
|
+
/* @__PURE__ */ (0, import_jsx_runtime43.jsxs)("linearGradient", { id: "blueGradient", x1: "0", y1: "0", x2: "0", y2: "1", children: [
|
|
13043
|
+
/* @__PURE__ */ (0, import_jsx_runtime43.jsx)("stop", { offset: "0%", stopColor: "#DEC1FA" }),
|
|
13044
|
+
/* @__PURE__ */ (0, import_jsx_runtime43.jsx)("stop", { offset: "100%", stopColor: "#3F9CF2" })
|
|
13045
|
+
] }),
|
|
13046
|
+
/* @__PURE__ */ (0, import_jsx_runtime43.jsxs)("linearGradient", { id: "greenGradient", x1: "0", y1: "0", x2: "0", y2: "1", children: [
|
|
13047
|
+
/* @__PURE__ */ (0, import_jsx_runtime43.jsx)("stop", { offset: "0%", stopColor: "#C2E59C" }),
|
|
13048
|
+
/* @__PURE__ */ (0, import_jsx_runtime43.jsx)("stop", { offset: "100%", stopColor: "#64B3F4" })
|
|
13049
|
+
] }),
|
|
13050
|
+
/* @__PURE__ */ (0, import_jsx_runtime43.jsxs)("linearGradient", { id: "pinkGradient", x1: "0", y1: "0", x2: "0", y2: "1", children: [
|
|
13051
|
+
/* @__PURE__ */ (0, import_jsx_runtime43.jsx)("stop", { offset: "0%", stopColor: "#DDD6F3" }),
|
|
13052
|
+
/* @__PURE__ */ (0, import_jsx_runtime43.jsx)("stop", { offset: "100%", stopColor: "#FAACA8" })
|
|
13053
|
+
] })
|
|
13054
|
+
] }),
|
|
13055
|
+
/* @__PURE__ */ (0, import_jsx_runtime43.jsx)(
|
|
13056
|
+
import_recharts3.CartesianGrid,
|
|
13057
|
+
{
|
|
13058
|
+
vertical: true,
|
|
13059
|
+
horizontal: false,
|
|
13060
|
+
strokeDasharray: "4 4",
|
|
13061
|
+
className: "stroke-neutral-light",
|
|
13062
|
+
verticalPoints: tickPositions
|
|
13063
|
+
}
|
|
13064
|
+
),
|
|
13065
|
+
/* @__PURE__ */ (0, import_jsx_runtime43.jsx)(
|
|
13066
|
+
import_recharts3.XAxis,
|
|
13067
|
+
{
|
|
13068
|
+
dataKey: "title",
|
|
13069
|
+
axisLine: { stroke: "#DFE2E7", strokeWidth: 1 },
|
|
13070
|
+
tickLine: false,
|
|
13071
|
+
tick: CustomTick,
|
|
13072
|
+
padding: { left: 0, right: 0 }
|
|
13073
|
+
}
|
|
13074
|
+
),
|
|
13075
|
+
/* @__PURE__ */ (0, import_jsx_runtime43.jsx)(
|
|
13076
|
+
import_recharts3.YAxis,
|
|
13077
|
+
{
|
|
13078
|
+
axisLine: { stroke: "#DFE2E7", strokeWidth: 1 },
|
|
13079
|
+
tickLine: false,
|
|
13080
|
+
tick: CustomYAxisTick,
|
|
13081
|
+
ticks: yAxisTicks,
|
|
13082
|
+
domain: yAxisDomain
|
|
13083
|
+
}
|
|
13084
|
+
),
|
|
13085
|
+
/* @__PURE__ */ (0, import_jsx_runtime43.jsx)(
|
|
13086
|
+
import_recharts3.Bar,
|
|
13087
|
+
{
|
|
13088
|
+
dataKey: "blue",
|
|
13089
|
+
fill: "url(#blueGradient)",
|
|
13090
|
+
shape: CustomBarShape,
|
|
13091
|
+
onMouseEnter: (e) => handleMouseEnter(e, "blue"),
|
|
13092
|
+
onMouseLeave: handleMouseLeave
|
|
13093
|
+
}
|
|
13094
|
+
),
|
|
13095
|
+
/* @__PURE__ */ (0, import_jsx_runtime43.jsx)(
|
|
13096
|
+
import_recharts3.Bar,
|
|
13097
|
+
{
|
|
13098
|
+
dataKey: "green",
|
|
13099
|
+
fill: "url(#greenGradient)",
|
|
13100
|
+
shape: CustomBarShape,
|
|
13101
|
+
onMouseEnter: (e) => handleMouseEnter(e, "green"),
|
|
13102
|
+
onMouseLeave: handleMouseLeave
|
|
13103
|
+
}
|
|
13104
|
+
),
|
|
13105
|
+
/* @__PURE__ */ (0, import_jsx_runtime43.jsx)(
|
|
13106
|
+
import_recharts3.Bar,
|
|
13107
|
+
{
|
|
13108
|
+
dataKey: "pink",
|
|
13109
|
+
fill: "url(#pinkGradient)",
|
|
13110
|
+
shape: CustomBarShape,
|
|
13111
|
+
onMouseEnter: (e) => handleMouseEnter(e, "pink"),
|
|
13112
|
+
onMouseLeave: handleMouseLeave
|
|
13113
|
+
}
|
|
13114
|
+
)
|
|
13115
|
+
]
|
|
13116
|
+
}
|
|
13117
|
+
) }),
|
|
13118
|
+
tooltipFormatter && /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(
|
|
13119
|
+
"div",
|
|
13120
|
+
{
|
|
13121
|
+
ref: tooltipRef,
|
|
13122
|
+
style: {
|
|
13123
|
+
position: "absolute",
|
|
13124
|
+
left: tooltipLeft + 10,
|
|
13125
|
+
top: (tooltipState == null ? void 0 : tooltipState.barY) || 0,
|
|
13126
|
+
pointerEvents: "none",
|
|
13127
|
+
zIndex: 10,
|
|
13128
|
+
opacity: tooltipState ? 1 : 0,
|
|
13129
|
+
transition: "opacity 0.1s ease-out",
|
|
13130
|
+
visibility: tooltipState ? "visible" : "hidden",
|
|
13131
|
+
width: "fit-content",
|
|
13132
|
+
whiteSpace: "nowrap"
|
|
13133
|
+
},
|
|
13134
|
+
children: tooltipState && tooltipFormatter(tooltipState)
|
|
13135
|
+
}
|
|
13136
|
+
)
|
|
13137
|
+
]
|
|
13138
|
+
}
|
|
13139
|
+
);
|
|
13120
13140
|
});
|
|
13121
13141
|
BarChartComponent.displayName = "barChart";
|
|
13122
13142
|
var barChart_default = BarChartComponent;
|
|
@@ -13299,8 +13319,8 @@ var SimpleBarChartComponent = (0, import_react43.forwardRef)((originalProps, ref
|
|
|
13299
13319
|
const { payload, x, y } = e;
|
|
13300
13320
|
if (!payload) return;
|
|
13301
13321
|
setTooltipState({
|
|
13302
|
-
x,
|
|
13303
|
-
y,
|
|
13322
|
+
barX: x,
|
|
13323
|
+
barY: y - 20,
|
|
13304
13324
|
value: payload.value,
|
|
13305
13325
|
label: payload.title
|
|
13306
13326
|
});
|
|
@@ -13343,7 +13363,7 @@ var SimpleBarChartComponent = (0, import_react43.forwardRef)((originalProps, ref
|
|
|
13343
13363
|
const tooltipRect = tooltipRef.current.getBoundingClientRect();
|
|
13344
13364
|
const chartWidth = chartRect.width;
|
|
13345
13365
|
const tooltipWidth = tooltipRect.width;
|
|
13346
|
-
let left = tooltipState.
|
|
13366
|
+
let left = tooltipState.barX - tooltipWidth / 2;
|
|
13347
13367
|
const padding2 = 8;
|
|
13348
13368
|
if (left < padding2) {
|
|
13349
13369
|
left = padding2;
|
|
@@ -13352,82 +13372,96 @@ var SimpleBarChartComponent = (0, import_react43.forwardRef)((originalProps, ref
|
|
|
13352
13372
|
}
|
|
13353
13373
|
setTooltipLeft(left);
|
|
13354
13374
|
}, [tooltipState]);
|
|
13355
|
-
return /* @__PURE__ */ (0, import_jsx_runtime45.jsxs)(
|
|
13356
|
-
|
|
13357
|
-
|
|
13358
|
-
|
|
13359
|
-
{
|
|
13360
|
-
|
|
13361
|
-
|
|
13362
|
-
|
|
13363
|
-
|
|
13364
|
-
|
|
13365
|
-
|
|
13366
|
-
|
|
13367
|
-
|
|
13368
|
-
|
|
13369
|
-
|
|
13370
|
-
|
|
13371
|
-
|
|
13372
|
-
|
|
13373
|
-
|
|
13374
|
-
|
|
13375
|
-
|
|
13376
|
-
|
|
13377
|
-
|
|
13378
|
-
|
|
13379
|
-
|
|
13380
|
-
|
|
13381
|
-
|
|
13382
|
-
|
|
13383
|
-
|
|
13384
|
-
|
|
13385
|
-
|
|
13386
|
-
|
|
13387
|
-
|
|
13388
|
-
|
|
13389
|
-
|
|
13390
|
-
|
|
13391
|
-
|
|
13392
|
-
|
|
13393
|
-
|
|
13394
|
-
|
|
13395
|
-
|
|
13396
|
-
|
|
13397
|
-
|
|
13398
|
-
|
|
13399
|
-
|
|
13400
|
-
|
|
13401
|
-
|
|
13402
|
-
|
|
13403
|
-
|
|
13404
|
-
|
|
13405
|
-
|
|
13406
|
-
|
|
13407
|
-
|
|
13408
|
-
|
|
13409
|
-
|
|
13410
|
-
|
|
13411
|
-
|
|
13412
|
-
|
|
13413
|
-
|
|
13414
|
-
|
|
13415
|
-
|
|
13416
|
-
|
|
13417
|
-
|
|
13418
|
-
|
|
13419
|
-
|
|
13420
|
-
|
|
13421
|
-
|
|
13422
|
-
|
|
13423
|
-
|
|
13424
|
-
|
|
13425
|
-
|
|
13426
|
-
|
|
13427
|
-
|
|
13428
|
-
|
|
13429
|
-
|
|
13430
|
-
|
|
13375
|
+
return /* @__PURE__ */ (0, import_jsx_runtime45.jsxs)(
|
|
13376
|
+
"div",
|
|
13377
|
+
{
|
|
13378
|
+
ref: chartRef,
|
|
13379
|
+
className: slots.base({ class: classNames == null ? void 0 : classNames.base }),
|
|
13380
|
+
onMouseLeave: handleMouseLeave,
|
|
13381
|
+
onMouseMove: (e) => {
|
|
13382
|
+
const target = e.target;
|
|
13383
|
+
if (!target.closest('[data-testid="recharts-bar-rectangle"]') && !target.closest(".recharts-bar-rectangle") && target.tagName !== "path") {
|
|
13384
|
+
setTooltipState(null);
|
|
13385
|
+
}
|
|
13386
|
+
},
|
|
13387
|
+
children: [
|
|
13388
|
+
label && /* @__PURE__ */ (0, import_jsx_runtime45.jsx)("p", { className: slots.label({ class: classNames == null ? void 0 : classNames.label }), children: label }),
|
|
13389
|
+
/* @__PURE__ */ (0, import_jsx_runtime45.jsx)(import_recharts5.ResponsiveContainer, { width: "100%", height: 140, children: /* @__PURE__ */ (0, import_jsx_runtime45.jsxs)(
|
|
13390
|
+
import_recharts5.BarChart,
|
|
13391
|
+
{
|
|
13392
|
+
data,
|
|
13393
|
+
margin: { left: 0, right: 0, top: 0, bottom: 0 },
|
|
13394
|
+
barSize: 10,
|
|
13395
|
+
barGap,
|
|
13396
|
+
className: "[&_.recharts-surface]:outline-none [&_.recharts-surface]:focus:outline-none",
|
|
13397
|
+
children: [
|
|
13398
|
+
/* @__PURE__ */ (0, import_jsx_runtime45.jsx)(
|
|
13399
|
+
import_recharts5.CartesianGrid,
|
|
13400
|
+
{
|
|
13401
|
+
vertical: true,
|
|
13402
|
+
horizontal: false,
|
|
13403
|
+
strokeDasharray: "4 4",
|
|
13404
|
+
className: "stroke-neutral-light",
|
|
13405
|
+
verticalPoints: tickPositions
|
|
13406
|
+
}
|
|
13407
|
+
),
|
|
13408
|
+
/* @__PURE__ */ (0, import_jsx_runtime45.jsx)(
|
|
13409
|
+
import_recharts5.CartesianGrid,
|
|
13410
|
+
{
|
|
13411
|
+
vertical: true,
|
|
13412
|
+
horizontal: false,
|
|
13413
|
+
strokeDasharray: "0",
|
|
13414
|
+
strokeWidth: 2,
|
|
13415
|
+
className: "stroke-neutral-light",
|
|
13416
|
+
verticalPoints: [0]
|
|
13417
|
+
}
|
|
13418
|
+
),
|
|
13419
|
+
/* @__PURE__ */ (0, import_jsx_runtime45.jsx)(
|
|
13420
|
+
import_recharts5.XAxis,
|
|
13421
|
+
{
|
|
13422
|
+
dataKey: "title",
|
|
13423
|
+
axisLine: { stroke: "#DFE2E7", strokeWidth: 1 },
|
|
13424
|
+
tickLine: false,
|
|
13425
|
+
tick: CustomTick,
|
|
13426
|
+
padding: { left: 0, right: 0 }
|
|
13427
|
+
}
|
|
13428
|
+
),
|
|
13429
|
+
/* @__PURE__ */ (0, import_jsx_runtime45.jsx)(import_recharts5.YAxis, { hide: true, ticks: yAxisTicks, domain: yAxisDomain }),
|
|
13430
|
+
/* @__PURE__ */ (0, import_jsx_runtime45.jsx)(
|
|
13431
|
+
import_recharts5.Bar,
|
|
13432
|
+
{
|
|
13433
|
+
dataKey: "value",
|
|
13434
|
+
fill: "#C7E5FA",
|
|
13435
|
+
shape: CustomBarShape,
|
|
13436
|
+
onMouseEnter: handleMouseEnter,
|
|
13437
|
+
onMouseLeave: handleMouseLeave
|
|
13438
|
+
}
|
|
13439
|
+
)
|
|
13440
|
+
]
|
|
13441
|
+
}
|
|
13442
|
+
) }),
|
|
13443
|
+
tooltipFormatter && /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(
|
|
13444
|
+
"div",
|
|
13445
|
+
{
|
|
13446
|
+
ref: tooltipRef,
|
|
13447
|
+
style: {
|
|
13448
|
+
position: "absolute",
|
|
13449
|
+
left: tooltipLeft + 5,
|
|
13450
|
+
top: (tooltipState == null ? void 0 : tooltipState.barY) || 0,
|
|
13451
|
+
pointerEvents: "none",
|
|
13452
|
+
zIndex: 10,
|
|
13453
|
+
opacity: tooltipState ? 1 : 0,
|
|
13454
|
+
transition: "opacity 0.1s ease-out",
|
|
13455
|
+
visibility: tooltipState ? "visible" : "hidden",
|
|
13456
|
+
width: "fit-content",
|
|
13457
|
+
whiteSpace: "nowrap"
|
|
13458
|
+
},
|
|
13459
|
+
children: tooltipState && tooltipFormatter(tooltipState)
|
|
13460
|
+
}
|
|
13461
|
+
)
|
|
13462
|
+
]
|
|
13463
|
+
}
|
|
13464
|
+
);
|
|
13431
13465
|
});
|
|
13432
13466
|
SimpleBarChartComponent.displayName = "simpleBarChart";
|
|
13433
13467
|
var simpleBarChart_default = SimpleBarChartComponent;
|