@deepnoid/ui 1.0.21 → 1.0.23
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/dist/{chunk-N4KPGD2N.mjs → chunk-25LWG2XP.mjs} +20 -20
- package/dist/{chunk-ZOTHPHXA.mjs → chunk-2C4HKBHM.mjs} +4 -4
- package/dist/{chunk-H7D5EBLL.mjs → chunk-32GYEUAB.mjs} +14 -8
- package/dist/{chunk-3K4OTUIB.mjs → chunk-3Z2WSTCH.mjs} +13 -13
- package/dist/{chunk-JGF5TY7M.mjs → chunk-4ALAPTAW.mjs} +10 -10
- package/dist/{chunk-O5VW7CHY.mjs → chunk-4FUD3BZV.mjs} +13 -14
- package/dist/{chunk-WTBRXQFT.mjs → chunk-5TBL2VZ5.mjs} +30 -30
- package/dist/{chunk-LHWHM4LQ.mjs → chunk-6J6AXUUE.mjs} +2 -2
- package/dist/{chunk-WQG4OYM6.mjs → chunk-7K3EB4DC.mjs} +67 -63
- package/dist/{chunk-WS4SOWDZ.mjs → chunk-AHKNFPHN.mjs} +27 -25
- package/dist/{chunk-IOJMTN6X.mjs → chunk-APZCX3PY.mjs} +7 -7
- package/dist/{chunk-KAB3AB67.mjs → chunk-AZ5QZAO6.mjs} +59 -53
- package/dist/{chunk-D7DDV4UN.mjs → chunk-B2LJEDXL.mjs} +22 -14
- package/dist/{chunk-6PN3DGOE.mjs → chunk-BEFT2F7D.mjs} +3 -3
- package/dist/{chunk-BJWYF2WY.mjs → chunk-C6S73EGR.mjs} +15 -17
- package/dist/{chunk-A6UUVHC6.mjs → chunk-C7OETP3D.mjs} +4 -4
- package/dist/{chunk-5RJYESLP.mjs → chunk-EVXLGMV6.mjs} +3 -3
- package/dist/{chunk-3IBJXQTJ.mjs → chunk-GWOMD7ZU.mjs} +1 -1
- package/dist/{chunk-62M6VPFS.mjs → chunk-HDCCDPYL.mjs} +65 -55
- package/dist/{chunk-7OP3JEMA.mjs → chunk-HLO5N6WD.mjs} +1 -1
- package/dist/{chunk-CBIV6KFQ.mjs → chunk-IF6XCBGN.mjs} +6 -6
- package/dist/{chunk-Y3A7PN4Q.mjs → chunk-IPP2GKZN.mjs} +16 -16
- package/dist/{chunk-SXSVNBRO.mjs → chunk-J2URLA5S.mjs} +22 -16
- package/dist/{chunk-ZCJPPLYH.mjs → chunk-JUPZBZ5Q.mjs} +7 -7
- package/dist/{chunk-USZSQXHS.mjs → chunk-KFM54LT4.mjs} +1 -1
- package/dist/{chunk-2J4MNIMS.mjs → chunk-KGRQ3ZYI.mjs} +10 -4
- package/dist/{chunk-27Y6K5NK.mjs → chunk-KJFYLLMP.mjs} +3 -3
- package/dist/{chunk-G6SZN3EK.mjs → chunk-LHEENTLV.mjs} +2 -2
- package/dist/{chunk-MAGZDGUW.mjs → chunk-LIYGCVZ3.mjs} +11 -11
- package/dist/{chunk-O2KC4CDE.mjs → chunk-MLMG22I4.mjs} +33 -31
- package/dist/{chunk-KIINY2GS.mjs → chunk-MS65QLWR.mjs} +6 -6
- package/dist/{chunk-XTMOAGLY.mjs → chunk-MVCUYH2W.mjs} +8 -8
- package/dist/{chunk-LCEFG5IY.mjs → chunk-NATO6PUP.mjs} +7 -7
- package/dist/{chunk-7CTICAGW.mjs → chunk-NMPATSTB.mjs} +2 -2
- package/dist/{chunk-R32BQ3NV.mjs → chunk-NUXN36KF.mjs} +22 -22
- package/dist/{chunk-CXVDES22.mjs → chunk-NYQKX23D.mjs} +12 -8
- package/dist/{chunk-MC7SI5Q7.mjs → chunk-OI5NXYUY.mjs} +8 -6
- package/dist/chunk-PPTFOHMW.mjs +169 -0
- package/dist/chunk-Q3SNUBIS.mjs +114 -0
- package/dist/{chunk-AO6LNH3D.mjs → chunk-QDAHI6GC.mjs} +4 -4
- package/dist/{chunk-AOU4QX7H.mjs → chunk-QOOYAQJ5.mjs} +773 -773
- package/dist/{chunk-D3DKXTTY.mjs → chunk-R6N6IQPN.mjs} +3 -3
- package/dist/{chunk-37BZALDV.mjs → chunk-RZD3NZIL.mjs} +10 -10
- package/dist/{chunk-SR76DO4M.mjs → chunk-SJLO65GQ.mjs} +12 -12
- package/dist/{chunk-PIUOU6LS.mjs → chunk-TEF3UA4E.mjs} +13 -13
- package/dist/{chunk-SLKXMIWY.mjs → chunk-TPWND4RF.mjs} +7 -8
- package/dist/{chunk-E3G5QXSH.mjs → chunk-UWT2WB6H.mjs} +2 -4
- package/dist/{chunk-MT7AFUKT.mjs → chunk-VJ7BQ3PK.mjs} +6 -5
- package/dist/{chunk-VZPVEICG.mjs → chunk-W6CQRLD2.mjs} +37 -29
- package/dist/{chunk-KE26ONWZ.mjs → chunk-YM5JOOTO.mjs} +3 -3
- package/dist/{chunk-FNFQCMB4.mjs → chunk-YNPIAFQ7.mjs} +31 -27
- package/dist/{chunk-QUWWLVCI.mjs → chunk-YUNTNMZ4.mjs} +6 -6
- package/dist/{chunk-XS32UZI3.mjs → chunk-YYWOSKGH.mjs} +3 -3
- package/dist/components/accordion/accordion.js +7 -8
- package/dist/components/accordion/accordion.mjs +2 -2
- package/dist/components/accordion/accordionItem.js +8 -11
- package/dist/components/accordion/accordionItem.mjs +2 -2
- package/dist/components/accordion/index.js +13 -15
- package/dist/components/accordion/index.mjs +3 -3
- package/dist/components/avatar/avatar.js +775 -775
- package/dist/components/avatar/avatar.mjs +2 -2
- package/dist/components/avatar/index.js +775 -775
- package/dist/components/avatar/index.mjs +2 -2
- package/dist/components/backdrop/backdrop.d.mts +4 -4
- package/dist/components/backdrop/backdrop.d.ts +4 -4
- package/dist/components/backdrop/backdrop.js +5 -5
- package/dist/components/backdrop/backdrop.mjs +2 -2
- package/dist/components/backdrop/index.js +5 -5
- package/dist/components/backdrop/index.mjs +2 -2
- package/dist/components/breadcrumb/breadcrumb.d.mts +2 -2
- package/dist/components/breadcrumb/breadcrumb.d.ts +2 -2
- package/dist/components/breadcrumb/breadcrumb.js +812 -814
- package/dist/components/breadcrumb/breadcrumb.mjs +13 -12
- package/dist/components/breadcrumb/index.js +812 -814
- package/dist/components/breadcrumb/index.mjs +13 -12
- package/dist/components/button/button-group.js +4 -4
- package/dist/components/button/button-group.mjs +2 -2
- package/dist/components/button/button.js +2976 -2979
- package/dist/components/button/button.mjs +6 -6
- package/dist/components/button/icon-button.js +2968 -2970
- package/dist/components/button/icon-button.mjs +6 -6
- package/dist/components/button/image-button.d.mts +194 -0
- package/dist/components/button/image-button.d.ts +194 -0
- package/dist/components/button/image-button.js +5572 -0
- package/dist/components/button/image-button.mjs +16 -0
- package/dist/components/button/index.d.mts +1 -0
- package/dist/components/button/index.d.ts +1 -0
- package/dist/components/button/index.js +3059 -2969
- package/dist/components/button/index.mjs +15 -11
- package/dist/components/button/text-button.js +62 -64
- package/dist/components/button/text-button.mjs +3 -3
- package/dist/components/charts/areaChart.d.mts +4 -4
- package/dist/components/charts/areaChart.d.ts +4 -4
- package/dist/components/charts/areaChart.js +39 -41
- package/dist/components/charts/areaChart.mjs +4 -4
- package/dist/components/charts/barChart.d.mts +8 -8
- package/dist/components/charts/barChart.d.ts +8 -8
- package/dist/components/charts/barChart.js +66 -58
- package/dist/components/charts/barChart.mjs +2 -2
- package/dist/components/charts/circularProgress.d.mts +2 -2
- package/dist/components/charts/circularProgress.d.ts +2 -2
- package/dist/components/charts/circularProgress.js +14 -16
- package/dist/components/charts/circularProgress.mjs +2 -2
- package/dist/components/charts/index.js +158 -148
- package/dist/components/charts/index.mjs +10 -10
- package/dist/components/charts/radarChart.d.mts +6 -6
- package/dist/components/charts/radarChart.d.ts +6 -6
- package/dist/components/charts/radarChart.js +17 -19
- package/dist/components/charts/radarChart.mjs +2 -2
- package/dist/components/charts/simpleBarChart.d.mts +6 -6
- package/dist/components/charts/simpleBarChart.d.ts +6 -6
- package/dist/components/charts/simpleBarChart.js +31 -33
- package/dist/components/charts/simpleBarChart.mjs +2 -2
- package/dist/components/checkbox/checkbox.js +13 -15
- package/dist/components/checkbox/checkbox.mjs +3 -3
- package/dist/components/checkbox/index.js +13 -15
- package/dist/components/checkbox/index.mjs +3 -3
- package/dist/components/chip/chip.js +782 -784
- package/dist/components/chip/chip.mjs +5 -5
- package/dist/components/chip/index.js +782 -784
- package/dist/components/chip/index.mjs +5 -5
- package/dist/components/drawer/drawer.js +15 -13
- package/dist/components/drawer/drawer.mjs +3 -3
- package/dist/components/drawer/index.js +15 -13
- package/dist/components/drawer/index.mjs +3 -3
- package/dist/components/fileUpload/fileUpload.d.mts +4 -4
- package/dist/components/fileUpload/fileUpload.d.ts +4 -4
- package/dist/components/fileUpload/fileUpload.js +880 -885
- package/dist/components/fileUpload/fileUpload.mjs +15 -14
- package/dist/components/fileUpload/index.js +880 -885
- package/dist/components/fileUpload/index.mjs +15 -14
- package/dist/components/icon/Icon.d.mts +179 -704
- package/dist/components/icon/Icon.d.ts +179 -704
- package/dist/components/icon/Icon.js +776 -776
- package/dist/components/icon/Icon.mjs +2 -2
- package/dist/components/icon/index.d.mts +1 -1
- package/dist/components/icon/index.d.ts +1 -1
- package/dist/components/icon/index.js +776 -776
- package/dist/components/icon/index.mjs +3 -3
- package/dist/components/icon/template.d.mts +3 -3
- package/dist/components/icon/template.d.ts +3 -3
- package/dist/components/icon/template.js +773 -773
- package/dist/components/icon/template.mjs +1 -1
- package/dist/components/input/index.js +793 -797
- package/dist/components/input/index.mjs +6 -6
- package/dist/components/input/input.js +793 -797
- package/dist/components/input/input.mjs +6 -6
- package/dist/components/list/index.js +786 -788
- package/dist/components/list/index.mjs +9 -9
- package/dist/components/list/list.js +3 -5
- package/dist/components/list/list.mjs +2 -2
- package/dist/components/list/listItem.js +785 -787
- package/dist/components/list/listItem.mjs +6 -6
- package/dist/components/modal/GlobalModalProvider.js +884 -887
- package/dist/components/modal/GlobalModalProvider.mjs +15 -14
- package/dist/components/modal/index.js +884 -887
- package/dist/components/modal/index.mjs +16 -15
- package/dist/components/modal/modal.js +875 -878
- package/dist/components/modal/modal.mjs +14 -13
- package/dist/components/modal/useGlobalModal.mjs +16 -15
- package/dist/components/pagination/index.js +850 -852
- package/dist/components/pagination/index.mjs +7 -7
- package/dist/components/pagination/pagination.js +850 -852
- package/dist/components/pagination/pagination.mjs +7 -7
- package/dist/components/picker/datePicker.d.mts +2 -2
- package/dist/components/picker/datePicker.d.ts +2 -2
- package/dist/components/picker/datePicker.js +1004 -1005
- package/dist/components/picker/datePicker.mjs +16 -15
- package/dist/components/picker/day.js +3 -5
- package/dist/components/picker/day.mjs +2 -2
- package/dist/components/picker/index.js +1026 -1011
- package/dist/components/picker/index.mjs +19 -18
- package/dist/components/picker/timePicker/Panel.d.mts +2 -2
- package/dist/components/picker/timePicker/Panel.d.ts +2 -2
- package/dist/components/picker/timePicker/Panel.js +116 -106
- package/dist/components/picker/timePicker/Panel.mjs +15 -14
- package/dist/components/picker/timePicker/WheelColumn.d.mts +2 -2
- package/dist/components/picker/timePicker/WheelColumn.d.ts +2 -2
- package/dist/components/picker/timePicker/WheelColumn.js +10 -4
- package/dist/components/picker/timePicker/WheelColumn.mjs +1 -1
- package/dist/components/picker/timePicker/index.js +1573 -1561
- package/dist/components/picker/timePicker/index.mjs +17 -16
- package/dist/components/picker/utils.js +1 -1
- package/dist/components/picker/utils.mjs +1 -1
- package/dist/components/progress/index.js +4 -6
- package/dist/components/progress/index.mjs +2 -2
- package/dist/components/progress/progress.d.mts +1 -1
- package/dist/components/progress/progress.d.ts +1 -1
- package/dist/components/progress/progress.js +4 -6
- package/dist/components/progress/progress.mjs +2 -2
- package/dist/components/radio/index.js +7 -9
- package/dist/components/radio/index.mjs +3 -3
- package/dist/components/radio/radio.js +7 -9
- package/dist/components/radio/radio.mjs +3 -3
- package/dist/components/ripple/index.js +3 -3
- package/dist/components/ripple/index.mjs +1 -1
- package/dist/components/ripple/ripple.d.mts +1 -1
- package/dist/components/ripple/ripple.d.ts +1 -1
- package/dist/components/ripple/ripple.js +3 -3
- package/dist/components/ripple/ripple.mjs +1 -1
- package/dist/components/ripple/useRipple.d.mts +2 -2
- package/dist/components/ripple/useRipple.d.ts +2 -2
- package/dist/components/scroll/index.js +5 -5
- package/dist/components/scroll/index.mjs +2 -2
- package/dist/components/scroll/scrollArea.d.mts +6 -6
- package/dist/components/scroll/scrollArea.d.ts +6 -6
- package/dist/components/scroll/scrollArea.js +5 -5
- package/dist/components/scroll/scrollArea.mjs +2 -2
- package/dist/components/select/index.js +884 -878
- package/dist/components/select/index.mjs +13 -12
- package/dist/components/select/select.d.mts +2 -2
- package/dist/components/select/select.d.ts +2 -2
- package/dist/components/select/select.js +884 -878
- package/dist/components/select/select.mjs +13 -12
- package/dist/components/skeleton/index.js +5 -5
- package/dist/components/skeleton/index.mjs +2 -2
- package/dist/components/skeleton/skeleton.d.mts +4 -4
- package/dist/components/skeleton/skeleton.d.ts +4 -4
- package/dist/components/skeleton/skeleton.js +5 -5
- package/dist/components/skeleton/skeleton.mjs +2 -2
- package/dist/components/slider/index.js +8 -10
- package/dist/components/slider/index.mjs +2 -2
- package/dist/components/slider/slider.js +8 -10
- package/dist/components/slider/slider.mjs +2 -2
- package/dist/components/starRating/index.js +798 -792
- package/dist/components/starRating/index.mjs +5 -5
- package/dist/components/starRating/starRating.js +798 -792
- package/dist/components/starRating/starRating.mjs +5 -5
- package/dist/components/switch/index.js +7 -9
- package/dist/components/switch/index.mjs +2 -2
- package/dist/components/switch/switch.js +7 -9
- package/dist/components/switch/switch.mjs +2 -2
- package/dist/components/table/definition-table.d.mts +11 -4
- package/dist/components/table/definition-table.d.ts +11 -4
- package/dist/components/table/definition-table.js +89 -60
- package/dist/components/table/definition-table.mjs +2 -2
- package/dist/components/table/form-table.d.mts +2 -2
- package/dist/components/table/form-table.d.ts +2 -2
- package/dist/components/table/form-table.js +10 -8
- package/dist/components/table/form-table.mjs +10 -8
- package/dist/components/table/index.js +2059 -2028
- package/dist/components/table/index.mjs +14 -14
- package/dist/components/table/table-body.d.mts +1 -1
- package/dist/components/table/table-body.d.ts +1 -1
- package/dist/components/table/table-body.js +1559 -1557
- package/dist/components/table/table-body.mjs +11 -11
- package/dist/components/table/table-head.d.mts +3 -3
- package/dist/components/table/table-head.d.ts +3 -3
- package/dist/components/table/table-head.js +1583 -1581
- package/dist/components/table/table-head.mjs +11 -11
- package/dist/components/table/table.d.mts +6 -6
- package/dist/components/table/table.d.ts +6 -6
- package/dist/components/table/table.js +1910 -1908
- package/dist/components/table/table.mjs +11 -11
- package/dist/components/tabs/index.js +2 -4
- package/dist/components/tabs/index.mjs +2 -2
- package/dist/components/tabs/tabs.d.mts +2 -2
- package/dist/components/tabs/tabs.d.ts +2 -2
- package/dist/components/tabs/tabs.js +2 -4
- package/dist/components/tabs/tabs.mjs +2 -2
- package/dist/components/textarea/index.js +14 -16
- package/dist/components/textarea/index.mjs +3 -3
- package/dist/components/textarea/textarea.js +14 -16
- package/dist/components/textarea/textarea.mjs +3 -3
- package/dist/components/timePicker/calendar.js +791 -791
- package/dist/components/timePicker/calendar.mjs +19 -17
- package/dist/components/timePicker/useDateTimePicker.d.mts +2 -2
- package/dist/components/timePicker/useDateTimePicker.d.ts +2 -2
- package/dist/components/timePicker/useDateTimePicker.js +3 -1
- package/dist/components/timePicker/useDateTimePicker.mjs +4 -2
- package/dist/components/toast/index.d.mts +1 -1
- package/dist/components/toast/index.d.ts +1 -1
- package/dist/components/toast/index.js +801 -797
- package/dist/components/toast/index.mjs +8 -8
- package/dist/components/toast/toast-utils.js +4 -4
- package/dist/components/toast/toast-utils.mjs +1 -1
- package/dist/components/toast/toast.d.mts +1 -1
- package/dist/components/toast/toast.d.ts +1 -1
- package/dist/components/toast/toast.js +785 -787
- package/dist/components/toast/toast.mjs +6 -6
- package/dist/components/toast/use-toast.d.mts +3 -3
- package/dist/components/toast/use-toast.d.ts +3 -3
- package/dist/components/toast/use-toast.js +801 -797
- package/dist/components/toast/use-toast.mjs +8 -8
- package/dist/components/tooltip/index.d.mts +1 -1
- package/dist/components/tooltip/index.d.ts +1 -1
- package/dist/components/tooltip/index.js +9 -9
- package/dist/components/tooltip/index.mjs +2 -2
- package/dist/components/tooltip/tooltip-utils.d.mts +1 -1
- package/dist/components/tooltip/tooltip-utils.d.ts +1 -1
- package/dist/components/tooltip/tooltip.d.mts +1 -1
- package/dist/components/tooltip/tooltip.d.ts +1 -1
- package/dist/components/tooltip/tooltip.js +9 -9
- package/dist/components/tooltip/tooltip.mjs +2 -2
- package/dist/components/tooltip/useTooltip.d.mts +1 -1
- package/dist/components/tooltip/useTooltip.d.ts +1 -1
- package/dist/components/tree/index.js +799 -799
- package/dist/components/tree/index.mjs +5 -5
- package/dist/components/tree/tree.d.mts +8 -8
- package/dist/components/tree/tree.d.ts +8 -8
- package/dist/components/tree/tree.js +799 -799
- package/dist/components/tree/tree.mjs +5 -5
- package/dist/hooks/useIsMounted.d.mts +2 -2
- package/dist/hooks/useIsMounted.d.ts +2 -2
- package/dist/index.d.mts +2 -1
- package/dist/index.d.ts +2 -1
- package/dist/index.js +2606 -2421
- package/dist/index.mjs +95 -91
- package/dist/{tooltip-utils-DO3LQaVM.d.ts → tooltip-utils-dEqsJ9t8.d.mts} +2 -2
- package/dist/{tooltip-utils-DO3LQaVM.d.mts → tooltip-utils-dEqsJ9t8.d.ts} +2 -2
- package/dist/utils/clsx.js +3 -3
- package/dist/utils/clsx.mjs +1 -1
- package/dist/utils/props.js +2 -4
- package/dist/utils/props.mjs +1 -1
- package/package.json +1 -1
- package/dist/chunk-HXBZB7CW.mjs +0 -140
- package/dist/{chunk-LXHUO6VM.mjs → chunk-EAFNOTY3.mjs} +3 -3
- /package/dist/{chunk-MY5U63QO.mjs → chunk-M5PMA3CT.mjs} +0 -0
- /package/dist/{chunk-ZYIIXWVY.mjs → chunk-WG2WVMAR.mjs} +0 -0
|
@@ -42,16 +42,14 @@ var mapPropsVariants = (props, variantKeys, removeVariantProps = true) => {
|
|
|
42
42
|
const picked = variantKeys.reduce((acc, key) => {
|
|
43
43
|
if (key in props) {
|
|
44
44
|
return { ...acc, [key]: props[key] };
|
|
45
|
-
} else {
|
|
46
|
-
return acc;
|
|
47
45
|
}
|
|
46
|
+
return acc;
|
|
48
47
|
}, {});
|
|
49
48
|
if (removeVariantProps) {
|
|
50
49
|
const omitted = Object.keys(props).filter((key) => !variantKeys.includes(key)).reduce((acc, key) => ({ ...acc, [key]: props[key] }), {});
|
|
51
50
|
return [omitted, picked];
|
|
52
|
-
} else {
|
|
53
|
-
return [props, picked];
|
|
54
51
|
}
|
|
52
|
+
return [props, picked];
|
|
55
53
|
};
|
|
56
54
|
|
|
57
55
|
// src/utils/tailwind-variants.ts
|
|
@@ -135,21 +133,21 @@ var CircularProgress = (0, import_react.forwardRef)((originalProps, ref) => {
|
|
|
135
133
|
const wrappedInnerContent = (0, import_react.useMemo)(() => {
|
|
136
134
|
return wrapSpanWithClass(innerContent);
|
|
137
135
|
}, [innerContent]);
|
|
138
|
-
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
|
|
136
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", { className: slots.base({ class: classNames == null ? void 0 : classNames.base }), ref, children: [
|
|
139
137
|
/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", { className: "relative", style: { width: size, height: size }, children: [
|
|
140
138
|
/* @__PURE__ */ (0, import_jsx_runtime.jsxs)(
|
|
141
139
|
import_recharts.RadialBarChart,
|
|
142
140
|
{
|
|
143
|
-
|
|
141
|
+
barSize: BAR_SIZE,
|
|
142
|
+
data,
|
|
143
|
+
endAngle: -270,
|
|
144
144
|
height: size,
|
|
145
145
|
innerRadius: INNER_RADIUS - 0.1,
|
|
146
146
|
outerRadius: OUTER_RADIUS,
|
|
147
|
-
barSize: BAR_SIZE,
|
|
148
|
-
data,
|
|
149
147
|
startAngle: 90,
|
|
150
|
-
|
|
148
|
+
width: size,
|
|
151
149
|
children: [
|
|
152
|
-
/* @__PURE__ */ (0, import_jsx_runtime.jsx)("defs", { children: /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("linearGradient", { id: gradientId, x1: "0%",
|
|
150
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)("defs", { children: /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("linearGradient", { id: gradientId, x1: "0%", x2: "100%", y1: "0%", y2: "100%", children: [
|
|
153
151
|
/* @__PURE__ */ (0, import_jsx_runtime.jsx)("stop", { offset: "0%", stopColor: currentGradient.start }),
|
|
154
152
|
/* @__PURE__ */ (0, import_jsx_runtime.jsx)("stop", { offset: "100%", stopColor: currentGradient.end })
|
|
155
153
|
] }) }),
|
|
@@ -158,8 +156,8 @@ var CircularProgress = (0, import_react.forwardRef)((originalProps, ref) => {
|
|
|
158
156
|
{
|
|
159
157
|
cx: size / 2,
|
|
160
158
|
cy: size / 2,
|
|
161
|
-
r: OUTER_RADIUS + BORDER_MARGIN,
|
|
162
159
|
fill: "#fff",
|
|
160
|
+
r: OUTER_RADIUS + BORDER_MARGIN,
|
|
163
161
|
stroke: "#DFE2E7",
|
|
164
162
|
strokeWidth: "1"
|
|
165
163
|
}
|
|
@@ -169,20 +167,20 @@ var CircularProgress = (0, import_react.forwardRef)((originalProps, ref) => {
|
|
|
169
167
|
{
|
|
170
168
|
cx: size / 2,
|
|
171
169
|
cy: size / 2,
|
|
172
|
-
r: BACKGROUND_RADIUS,
|
|
173
170
|
fill: "none",
|
|
171
|
+
r: BACKGROUND_RADIUS,
|
|
174
172
|
stroke: "rgba(0, 0, 0, 0.05)",
|
|
175
173
|
strokeWidth: BAR_SIZE
|
|
176
174
|
}
|
|
177
175
|
),
|
|
178
|
-
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_recharts.PolarAngleAxis, {
|
|
179
|
-
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_recharts.RadialBar, {
|
|
176
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_recharts.PolarAngleAxis, { angleAxisId: 0, domain: [0, 100], tick: false, type: "number" }),
|
|
177
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_recharts.RadialBar, { animationDuration: 1e3, cornerRadius: 12, dataKey: "value", fill: `url(#${gradientId})` })
|
|
180
178
|
]
|
|
181
179
|
}
|
|
182
180
|
),
|
|
183
|
-
innerContent
|
|
181
|
+
innerContent ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { className: slots.inner({ class: classNames == null ? void 0 : classNames.inner }), children: wrappedInnerContent }) : null
|
|
184
182
|
] }),
|
|
185
|
-
label
|
|
183
|
+
label ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)("p", { className: slots.label({ class: classNames == null ? void 0 : classNames.label }), children: label }) : null
|
|
186
184
|
] });
|
|
187
185
|
});
|
|
188
186
|
CircularProgress.displayName = "CircularProgress";
|
|
@@ -253,7 +251,7 @@ var import_tailwind_variants3 = require("tailwind-variants");
|
|
|
253
251
|
|
|
254
252
|
// src/utils/clsx.ts
|
|
255
253
|
function clsx(...args) {
|
|
256
|
-
|
|
254
|
+
let i = 0, tmp, x, str = "";
|
|
257
255
|
while (i < args.length) {
|
|
258
256
|
if (tmp = args[i++]) {
|
|
259
257
|
if (x = toVal(tmp)) {
|
|
@@ -265,12 +263,12 @@ function clsx(...args) {
|
|
|
265
263
|
return str;
|
|
266
264
|
}
|
|
267
265
|
function toVal(mix) {
|
|
268
|
-
|
|
266
|
+
let k, y, str = "";
|
|
269
267
|
if (typeof mix === "string" || typeof mix === "number") {
|
|
270
268
|
str += mix;
|
|
271
269
|
} else if (typeof mix === "object") {
|
|
272
270
|
if (Array.isArray(mix)) {
|
|
273
|
-
|
|
271
|
+
const len = mix.length;
|
|
274
272
|
for (k = 0; k < len; k++) {
|
|
275
273
|
if (mix[k]) {
|
|
276
274
|
if (y = toVal(mix[k])) {
|
|
@@ -293,9 +291,9 @@ function toVal(mix) {
|
|
|
293
291
|
|
|
294
292
|
// src/components/scroll/scrollArea.tsx
|
|
295
293
|
var import_jsx_runtime2 = require("react/jsx-runtime");
|
|
296
|
-
|
|
294
|
+
function ScrollArea({ children, className, direction, size, variant }) {
|
|
297
295
|
return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("div", { className: clsx(scrollAreaStyle({ direction, size, variant }), className), children });
|
|
298
|
-
}
|
|
296
|
+
}
|
|
299
297
|
ScrollArea.displayName = "ScrollArea";
|
|
300
298
|
var scrollArea_default = ScrollArea;
|
|
301
299
|
var scrollAreaStyle = (0, import_tailwind_variants3.tv)({
|
|
@@ -358,7 +356,7 @@ var AreaChartComponent = (0, import_react2.forwardRef)((originalProps, ref) => {
|
|
|
358
356
|
}, [data, startFromZero]);
|
|
359
357
|
const [tickPositions, setTickPositions] = (0, import_react2.useState)([]);
|
|
360
358
|
const tickRef = (0, import_react2.useRef)([]);
|
|
361
|
-
|
|
359
|
+
function CustomTick({ x, y, payload }) {
|
|
362
360
|
if (x !== void 0) {
|
|
363
361
|
tickRef.current.push(x);
|
|
364
362
|
}
|
|
@@ -368,17 +366,17 @@ var AreaChartComponent = (0, import_react2.forwardRef)((originalProps, ref) => {
|
|
|
368
366
|
return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
369
367
|
"text",
|
|
370
368
|
{
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
textAnchor: "middle",
|
|
369
|
+
className: "text-body-foreground",
|
|
370
|
+
fill: "currentColor",
|
|
374
371
|
fontSize: 12,
|
|
375
372
|
fontWeight: 700,
|
|
376
|
-
|
|
377
|
-
|
|
373
|
+
textAnchor: "middle",
|
|
374
|
+
x,
|
|
375
|
+
y: y + 11,
|
|
378
376
|
children: payload.value
|
|
379
377
|
}
|
|
380
378
|
);
|
|
381
|
-
}
|
|
379
|
+
}
|
|
382
380
|
(0, import_react2.useEffect)(() => {
|
|
383
381
|
const raf = requestAnimationFrame(() => {
|
|
384
382
|
const unique = [...new Set(tickRef.current)].sort((a, b) => a - b);
|
|
@@ -389,19 +387,21 @@ var AreaChartComponent = (0, import_react2.forwardRef)((originalProps, ref) => {
|
|
|
389
387
|
setTickPositions(mids);
|
|
390
388
|
tickRef.current = [];
|
|
391
389
|
});
|
|
392
|
-
return () =>
|
|
390
|
+
return () => {
|
|
391
|
+
cancelAnimationFrame(raf);
|
|
392
|
+
};
|
|
393
393
|
}, [processedData]);
|
|
394
|
-
|
|
394
|
+
function CustomDotWithShadow(props2) {
|
|
395
395
|
const { cx, cy, fill, stroke, payload } = props2;
|
|
396
396
|
if (cx === void 0 || cy === void 0) return null;
|
|
397
397
|
if (startFromZero && (payload == null ? void 0 : payload.name) === "") {
|
|
398
398
|
return null;
|
|
399
399
|
}
|
|
400
400
|
return /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(import_jsx_runtime3.Fragment, { children: [
|
|
401
|
-
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)("circle", { cx, cy,
|
|
402
|
-
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)("circle", { cx, cy, r: 3.5,
|
|
401
|
+
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)("circle", { cx, cy, fill, opacity: 0.2, r: 8 }),
|
|
402
|
+
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)("circle", { cx, cy, fill, r: 3.5, stroke, strokeWidth: 2 })
|
|
403
403
|
] });
|
|
404
|
-
}
|
|
404
|
+
}
|
|
405
405
|
const chartContent = /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
406
406
|
"div",
|
|
407
407
|
{
|
|
@@ -412,33 +412,33 @@ var AreaChartComponent = (0, import_react2.forwardRef)((originalProps, ref) => {
|
|
|
412
412
|
children: /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(
|
|
413
413
|
import_recharts2.AreaChart,
|
|
414
414
|
{
|
|
415
|
-
|
|
416
|
-
height: chartHeight + 30,
|
|
415
|
+
className: "bg-body-background [&_.recharts-surface]:outline-none [&_.recharts-surface]:focus:outline-none",
|
|
417
416
|
data: processedData,
|
|
417
|
+
height: chartHeight + 30,
|
|
418
418
|
margin: { left: -30 },
|
|
419
|
-
|
|
419
|
+
width: totalChartWidth || 400,
|
|
420
420
|
children: [
|
|
421
|
-
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)("defs", { children: /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)("linearGradient", { id: `colorGradient-${uniqueId}`, x1: "0",
|
|
421
|
+
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)("defs", { children: /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)("linearGradient", { id: `colorGradient-${uniqueId}`, x1: "0", x2: "0", y1: "0", y2: "1", children: [
|
|
422
422
|
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)("stop", { offset: "5%", stopColor: colorHex, stopOpacity: 0.3 }),
|
|
423
423
|
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)("stop", { offset: "95%", stopColor: colorHex, stopOpacity: 0 })
|
|
424
424
|
] }) }),
|
|
425
425
|
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
426
426
|
import_recharts2.CartesianGrid,
|
|
427
427
|
{
|
|
428
|
-
|
|
428
|
+
className: "stroke-neutral-light",
|
|
429
429
|
horizontal: false,
|
|
430
430
|
strokeDasharray: "4 4",
|
|
431
|
-
|
|
431
|
+
vertical: true,
|
|
432
432
|
verticalPoints: tickPositions
|
|
433
433
|
}
|
|
434
434
|
),
|
|
435
435
|
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
436
436
|
import_recharts2.XAxis,
|
|
437
437
|
{
|
|
438
|
-
dataKey: "name",
|
|
439
438
|
axisLine: { stroke: "#DFE2E7", strokeWidth: 1 },
|
|
440
|
-
|
|
439
|
+
dataKey: "name",
|
|
441
440
|
tick: CustomTick,
|
|
441
|
+
tickLine: false,
|
|
442
442
|
padding: { left: 35.5, right: 35.5 }
|
|
443
443
|
}
|
|
444
444
|
),
|
|
@@ -446,7 +446,7 @@ var AreaChartComponent = (0, import_react2.forwardRef)((originalProps, ref) => {
|
|
|
446
446
|
import_recharts2.YAxis,
|
|
447
447
|
{
|
|
448
448
|
axisLine: { stroke: "#DFE2E7", strokeWidth: 1 },
|
|
449
|
-
|
|
449
|
+
domain: [-6, 110],
|
|
450
450
|
tick: {
|
|
451
451
|
fontSize: 12,
|
|
452
452
|
fontWeight: 700,
|
|
@@ -454,20 +454,20 @@ var AreaChartComponent = (0, import_react2.forwardRef)((originalProps, ref) => {
|
|
|
454
454
|
textAnchor: "middle",
|
|
455
455
|
dx: -10
|
|
456
456
|
},
|
|
457
|
-
|
|
458
|
-
|
|
457
|
+
tickLine: false,
|
|
458
|
+
ticks: [0, 20, 40, 60, 80, 100]
|
|
459
459
|
}
|
|
460
460
|
),
|
|
461
461
|
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
462
462
|
import_recharts2.Area,
|
|
463
463
|
{
|
|
464
|
-
|
|
464
|
+
activeDot: false,
|
|
465
465
|
dataKey: "value",
|
|
466
|
+
dot: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(CustomDotWithShadow, { fill: colorHex, stroke: colorHex }),
|
|
467
|
+
fill: `url(#colorGradient-${uniqueId})`,
|
|
466
468
|
stroke: colorHex,
|
|
467
469
|
strokeWidth: 2,
|
|
468
|
-
|
|
469
|
-
dot: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(CustomDotWithShadow, { stroke: colorHex, fill: colorHex }),
|
|
470
|
-
activeDot: false
|
|
470
|
+
type: "monotone"
|
|
471
471
|
}
|
|
472
472
|
)
|
|
473
473
|
]
|
|
@@ -475,8 +475,8 @@ var AreaChartComponent = (0, import_react2.forwardRef)((originalProps, ref) => {
|
|
|
475
475
|
)
|
|
476
476
|
}
|
|
477
477
|
);
|
|
478
|
-
return /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)("div", {
|
|
479
|
-
label
|
|
478
|
+
return /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)("div", { className: slots.base({ class: classNames == null ? void 0 : classNames.base }), ref, children: [
|
|
479
|
+
label ? /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("p", { className: slots.label({ class: classNames == null ? void 0 : classNames.label }), children: label }) : null,
|
|
480
480
|
headerContent,
|
|
481
481
|
needsScroll ? /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(scrollArea_default, { direction: "x", size: "sm", children: chartContent }) : chartContent
|
|
482
482
|
] });
|
|
@@ -531,7 +531,7 @@ var BarChartComponent = (0, import_react3.forwardRef)((originalProps, ref) => {
|
|
|
531
531
|
const handleMouseEnter = (e, dataKey) => {
|
|
532
532
|
if (!tooltipFormatter || !chartRef.current) return;
|
|
533
533
|
const { payload, x, y } = e;
|
|
534
|
-
if (!payload
|
|
534
|
+
if (!(payload == null ? void 0 : payload[dataKey])) return;
|
|
535
535
|
setTooltipState({
|
|
536
536
|
barX: x,
|
|
537
537
|
barY: y - 10,
|
|
@@ -543,7 +543,7 @@ var BarChartComponent = (0, import_react3.forwardRef)((originalProps, ref) => {
|
|
|
543
543
|
const handleMouseLeave = () => {
|
|
544
544
|
setTooltipState(null);
|
|
545
545
|
};
|
|
546
|
-
|
|
546
|
+
function CustomBarShape({ x, y, width, height, fill }) {
|
|
547
547
|
var _a;
|
|
548
548
|
const radius = 5;
|
|
549
549
|
const [minDomain, maxDomain] = yAxisDomain;
|
|
@@ -562,38 +562,40 @@ var BarChartComponent = (0, import_react3.forwardRef)((originalProps, ref) => {
|
|
|
562
562
|
d: `M${x},${bottomY} L${x},${adjustedY + radius} Q${x},${adjustedY} ${x + radius},${adjustedY} L${x + width - radius},${adjustedY} Q${x + width},${adjustedY} ${x + width},${adjustedY + radius} L${x + width},${bottomY} Z`,
|
|
563
563
|
fill
|
|
564
564
|
}
|
|
565
|
-
) : /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("rect", {
|
|
566
|
-
}
|
|
567
|
-
|
|
565
|
+
) : /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("rect", { fill, height: 0, width, x, y });
|
|
566
|
+
}
|
|
567
|
+
function CustomTick({ x, y, payload }) {
|
|
568
568
|
if (x !== void 0) tickRef.current.push(x);
|
|
569
569
|
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
570
570
|
"text",
|
|
571
571
|
{
|
|
572
|
+
className: "text-body-foreground",
|
|
573
|
+
fill: "currentColor",
|
|
574
|
+
fontSize: 12,
|
|
575
|
+
fontWeight: 700,
|
|
576
|
+
textAnchor: "middle",
|
|
572
577
|
x,
|
|
573
578
|
y: y + 14,
|
|
574
|
-
|
|
579
|
+
children: payload.value
|
|
580
|
+
}
|
|
581
|
+
);
|
|
582
|
+
}
|
|
583
|
+
function CustomYAxisTick({ x, y, payload }) {
|
|
584
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
585
|
+
"text",
|
|
586
|
+
{
|
|
587
|
+
className: "text-body-foreground",
|
|
588
|
+
dy: 4,
|
|
589
|
+
fill: "currentColor",
|
|
575
590
|
fontSize: 12,
|
|
576
591
|
fontWeight: 700,
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
592
|
+
textAnchor: "middle",
|
|
593
|
+
x: x - 10,
|
|
594
|
+
y,
|
|
595
|
+
children: yAxisTickFormatter(payload.value)
|
|
580
596
|
}
|
|
581
597
|
);
|
|
582
|
-
}
|
|
583
|
-
const CustomYAxisTick = ({ x, y, payload }) => /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
584
|
-
"text",
|
|
585
|
-
{
|
|
586
|
-
x: x - 10,
|
|
587
|
-
y,
|
|
588
|
-
textAnchor: "middle",
|
|
589
|
-
fontSize: 12,
|
|
590
|
-
fontWeight: 700,
|
|
591
|
-
fill: "currentColor",
|
|
592
|
-
className: "text-body-foreground",
|
|
593
|
-
dy: 4,
|
|
594
|
-
children: yAxisTickFormatter(payload.value)
|
|
595
|
-
}
|
|
596
|
-
);
|
|
598
|
+
}
|
|
597
599
|
(0, import_react3.useEffect)(() => {
|
|
598
600
|
const raf = requestAnimationFrame(() => {
|
|
599
601
|
const unique = [...new Set(tickRef.current)].sort((a, b) => a - b);
|
|
@@ -604,7 +606,9 @@ var BarChartComponent = (0, import_react3.forwardRef)((originalProps, ref) => {
|
|
|
604
606
|
setTickPositions(mids);
|
|
605
607
|
tickRef.current = [];
|
|
606
608
|
});
|
|
607
|
-
return () =>
|
|
609
|
+
return () => {
|
|
610
|
+
cancelAnimationFrame(raf);
|
|
611
|
+
};
|
|
608
612
|
}, [data]);
|
|
609
613
|
(0, import_react3.useLayoutEffect)(() => {
|
|
610
614
|
if (!tooltipState || !chartRef.current || !tooltipRef.current) return;
|
|
@@ -624,7 +628,6 @@ var BarChartComponent = (0, import_react3.forwardRef)((originalProps, ref) => {
|
|
|
624
628
|
return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(
|
|
625
629
|
"div",
|
|
626
630
|
{
|
|
627
|
-
ref: chartRef,
|
|
628
631
|
className: slots.base({ class: classNames == null ? void 0 : classNames.base }),
|
|
629
632
|
onMouseLeave: handleMouseLeave,
|
|
630
633
|
onMouseMove: (e) => {
|
|
@@ -633,27 +636,28 @@ var BarChartComponent = (0, import_react3.forwardRef)((originalProps, ref) => {
|
|
|
633
636
|
setTooltipState(null);
|
|
634
637
|
}
|
|
635
638
|
},
|
|
639
|
+
ref: chartRef,
|
|
636
640
|
children: [
|
|
637
|
-
label
|
|
638
|
-
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)(import_recharts3.ResponsiveContainer, {
|
|
641
|
+
label ? /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("p", { className: slots.label({ class: classNames == null ? void 0 : classNames.label }), children: label }) : null,
|
|
642
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)(import_recharts3.ResponsiveContainer, { height: "100%", width: "100%", children: /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(
|
|
639
643
|
import_recharts3.BarChart,
|
|
640
644
|
{
|
|
641
|
-
data,
|
|
642
|
-
margin: { left: -20 },
|
|
643
|
-
barSize: 20,
|
|
644
645
|
barGap,
|
|
646
|
+
barSize: 20,
|
|
645
647
|
className: "[&_.recharts-surface]:outline-none [&_.recharts-surface]:focus:outline-none",
|
|
648
|
+
data,
|
|
649
|
+
margin: { left: -20 },
|
|
646
650
|
children: [
|
|
647
651
|
/* @__PURE__ */ (0, import_jsx_runtime4.jsxs)("defs", { children: [
|
|
648
|
-
/* @__PURE__ */ (0, import_jsx_runtime4.jsxs)("linearGradient", { id: "blueGradient", x1: "0",
|
|
652
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsxs)("linearGradient", { id: "blueGradient", x1: "0", x2: "0", y1: "0", y2: "1", children: [
|
|
649
653
|
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("stop", { offset: "0%", stopColor: "#DEC1FA" }),
|
|
650
654
|
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("stop", { offset: "100%", stopColor: "#3F9CF2" })
|
|
651
655
|
] }),
|
|
652
|
-
/* @__PURE__ */ (0, import_jsx_runtime4.jsxs)("linearGradient", { id: "greenGradient", x1: "0",
|
|
656
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsxs)("linearGradient", { id: "greenGradient", x1: "0", x2: "0", y1: "0", y2: "1", children: [
|
|
653
657
|
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("stop", { offset: "0%", stopColor: "#C2E59C" }),
|
|
654
658
|
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("stop", { offset: "100%", stopColor: "#64B3F4" })
|
|
655
659
|
] }),
|
|
656
|
-
/* @__PURE__ */ (0, import_jsx_runtime4.jsxs)("linearGradient", { id: "pinkGradient", x1: "0",
|
|
660
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsxs)("linearGradient", { id: "pinkGradient", x1: "0", x2: "0", y1: "0", y2: "1", children: [
|
|
657
661
|
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("stop", { offset: "0%", stopColor: "#DDD6F3" }),
|
|
658
662
|
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)("stop", { offset: "100%", stopColor: "#FAACA8" })
|
|
659
663
|
] })
|
|
@@ -661,31 +665,31 @@ var BarChartComponent = (0, import_react3.forwardRef)((originalProps, ref) => {
|
|
|
661
665
|
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
662
666
|
import_recharts3.CartesianGrid,
|
|
663
667
|
{
|
|
664
|
-
|
|
668
|
+
className: "stroke-neutral-light",
|
|
665
669
|
horizontal: false,
|
|
666
670
|
strokeDasharray: "4 4",
|
|
667
|
-
|
|
671
|
+
vertical: true,
|
|
668
672
|
verticalPoints: tickPositions
|
|
669
673
|
}
|
|
670
674
|
),
|
|
671
675
|
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
672
676
|
import_recharts3.XAxis,
|
|
673
677
|
{
|
|
674
|
-
dataKey: "title",
|
|
675
678
|
axisLine: { stroke: "#DFE2E7", strokeWidth: 1 },
|
|
676
|
-
|
|
679
|
+
dataKey: "title",
|
|
680
|
+
padding: { left: 0, right: 0 },
|
|
677
681
|
tick: CustomTick,
|
|
678
|
-
|
|
682
|
+
tickLine: false
|
|
679
683
|
}
|
|
680
684
|
),
|
|
681
685
|
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
682
686
|
import_recharts3.YAxis,
|
|
683
687
|
{
|
|
684
688
|
axisLine: { stroke: "#DFE2E7", strokeWidth: 1 },
|
|
685
|
-
|
|
689
|
+
domain: yAxisDomain,
|
|
686
690
|
tick: CustomYAxisTick,
|
|
687
|
-
|
|
688
|
-
|
|
691
|
+
tickLine: false,
|
|
692
|
+
ticks: yAxisTicks
|
|
689
693
|
}
|
|
690
694
|
),
|
|
691
695
|
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
@@ -693,9 +697,11 @@ var BarChartComponent = (0, import_react3.forwardRef)((originalProps, ref) => {
|
|
|
693
697
|
{
|
|
694
698
|
dataKey: "blue",
|
|
695
699
|
fill: "url(#blueGradient)",
|
|
696
|
-
|
|
697
|
-
|
|
698
|
-
|
|
700
|
+
onMouseEnter: (e) => {
|
|
701
|
+
handleMouseEnter(e, "blue");
|
|
702
|
+
},
|
|
703
|
+
onMouseLeave: handleMouseLeave,
|
|
704
|
+
shape: CustomBarShape
|
|
699
705
|
}
|
|
700
706
|
),
|
|
701
707
|
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
@@ -703,9 +709,11 @@ var BarChartComponent = (0, import_react3.forwardRef)((originalProps, ref) => {
|
|
|
703
709
|
{
|
|
704
710
|
dataKey: "green",
|
|
705
711
|
fill: "url(#greenGradient)",
|
|
706
|
-
|
|
707
|
-
|
|
708
|
-
|
|
712
|
+
onMouseEnter: (e) => {
|
|
713
|
+
handleMouseEnter(e, "green");
|
|
714
|
+
},
|
|
715
|
+
onMouseLeave: handleMouseLeave,
|
|
716
|
+
shape: CustomBarShape
|
|
709
717
|
}
|
|
710
718
|
),
|
|
711
719
|
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
@@ -713,15 +721,17 @@ var BarChartComponent = (0, import_react3.forwardRef)((originalProps, ref) => {
|
|
|
713
721
|
{
|
|
714
722
|
dataKey: "pink",
|
|
715
723
|
fill: "url(#pinkGradient)",
|
|
716
|
-
|
|
717
|
-
|
|
718
|
-
|
|
724
|
+
onMouseEnter: (e) => {
|
|
725
|
+
handleMouseEnter(e, "pink");
|
|
726
|
+
},
|
|
727
|
+
onMouseLeave: handleMouseLeave,
|
|
728
|
+
shape: CustomBarShape
|
|
719
729
|
}
|
|
720
730
|
)
|
|
721
731
|
]
|
|
722
732
|
}
|
|
723
733
|
) }),
|
|
724
|
-
tooltipFormatter
|
|
734
|
+
tooltipFormatter ? /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
725
735
|
"div",
|
|
726
736
|
{
|
|
727
737
|
ref: tooltipRef,
|
|
@@ -737,9 +747,9 @@ var BarChartComponent = (0, import_react3.forwardRef)((originalProps, ref) => {
|
|
|
737
747
|
width: "fit-content",
|
|
738
748
|
whiteSpace: "nowrap"
|
|
739
749
|
},
|
|
740
|
-
children: tooltipState
|
|
750
|
+
children: tooltipState ? tooltipFormatter(tooltipState) : null
|
|
741
751
|
}
|
|
742
|
-
)
|
|
752
|
+
) : null
|
|
743
753
|
]
|
|
744
754
|
}
|
|
745
755
|
);
|
|
@@ -797,14 +807,14 @@ var RadarChart = (0, import_react4.forwardRef)((originalProps, ref) => {
|
|
|
797
807
|
if (data.length === 3) return { cx: "50%", cy: "65%" };
|
|
798
808
|
return {};
|
|
799
809
|
}, [data]);
|
|
800
|
-
return /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("div", {
|
|
801
|
-
label
|
|
802
|
-
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)("div", { style: { width: "100%" }, children: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(import_recharts4.ResponsiveContainer, { width: "100%",
|
|
810
|
+
return /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("div", { className: slots.base({ class: classNames == null ? void 0 : classNames.base }), ref, children: [
|
|
811
|
+
label ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("p", { className: slots.label({ class: classNames == null ? void 0 : classNames.label }), children: label }) : null,
|
|
812
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)("div", { style: { width: "100%" }, children: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(import_recharts4.ResponsiveContainer, { height: containerHeight, width: "100%", children: /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(
|
|
803
813
|
import_recharts4.RadarChart,
|
|
804
814
|
{
|
|
805
815
|
data: normalizedData,
|
|
806
|
-
outerRadius,
|
|
807
816
|
margin: chartMargin,
|
|
817
|
+
outerRadius,
|
|
808
818
|
...chartCenter,
|
|
809
819
|
className: "[&_.recharts-surface]:outline-none [&_.recharts-surface]:focus:outline-none",
|
|
810
820
|
children: [
|
|
@@ -818,22 +828,23 @@ var RadarChart = (0, import_react4.forwardRef)((originalProps, ref) => {
|
|
|
818
828
|
tickSize: 15
|
|
819
829
|
}
|
|
820
830
|
),
|
|
821
|
-
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(import_recharts4.PolarRadiusAxis, { domain: [0, 100], tick: false, tickCount: 6
|
|
831
|
+
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(import_recharts4.PolarRadiusAxis, { axisLine: false, domain: [0, 100], tick: false, tickCount: 6 }),
|
|
822
832
|
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
|
|
823
833
|
import_recharts4.Radar,
|
|
824
834
|
{
|
|
825
|
-
|
|
835
|
+
activeDot: false,
|
|
826
836
|
dataKey: "value",
|
|
827
|
-
stroke: "#3F9CF2",
|
|
828
|
-
fill: "#EFF8FF",
|
|
829
|
-
strokeWidth: 1.75,
|
|
830
837
|
dot: false,
|
|
831
|
-
|
|
838
|
+
fill: "#EFF8FF",
|
|
839
|
+
name: label,
|
|
840
|
+
stroke: "#3F9CF2",
|
|
841
|
+
strokeWidth: 1.75
|
|
832
842
|
}
|
|
833
843
|
),
|
|
834
|
-
tooltipFormatter
|
|
844
|
+
tooltipFormatter ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
|
|
835
845
|
import_recharts4.Tooltip,
|
|
836
846
|
{
|
|
847
|
+
allowEscapeViewBox: { x: true, y: true },
|
|
837
848
|
content: ({ active, payload, label: tooltipLabel }) => {
|
|
838
849
|
var _a, _b;
|
|
839
850
|
const currentData = data == null ? void 0 : data.find((item) => item.name === tooltipLabel);
|
|
@@ -844,12 +855,11 @@ var RadarChart = (0, import_react4.forwardRef)((originalProps, ref) => {
|
|
|
844
855
|
data: currentData
|
|
845
856
|
}) });
|
|
846
857
|
},
|
|
847
|
-
|
|
848
|
-
allowEscapeViewBox: { x: true, y: true },
|
|
858
|
+
cursor: false,
|
|
849
859
|
isAnimationActive: false,
|
|
850
|
-
|
|
860
|
+
wrapperStyle: { zIndex: 9999 }
|
|
851
861
|
}
|
|
852
|
-
)
|
|
862
|
+
) : null
|
|
853
863
|
]
|
|
854
864
|
}
|
|
855
865
|
) }) })
|
|
@@ -934,7 +944,7 @@ var SimpleBarChartComponent = (0, import_react5.forwardRef)((originalProps, ref)
|
|
|
934
944
|
const handleMouseLeave = () => {
|
|
935
945
|
setTooltipState(null);
|
|
936
946
|
};
|
|
937
|
-
|
|
947
|
+
function CustomBarShape({ x, y, width, height, fill }) {
|
|
938
948
|
const radius = 4;
|
|
939
949
|
const extraHeight = 10;
|
|
940
950
|
const adjustedHeight = height + extraHeight;
|
|
@@ -946,23 +956,23 @@ var SimpleBarChartComponent = (0, import_react5.forwardRef)((originalProps, ref)
|
|
|
946
956
|
d: `M${x},${bottomY} L${x},${adjustedY + radius} Q${x},${adjustedY} ${x + radius},${adjustedY} L${x + width - radius},${adjustedY} Q${x + width},${adjustedY} ${x + width},${adjustedY + radius} L${x + width},${bottomY} Z`,
|
|
947
957
|
fill
|
|
948
958
|
}
|
|
949
|
-
) : /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("rect", {
|
|
950
|
-
}
|
|
951
|
-
|
|
959
|
+
) : /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("rect", { fill, height: 0, width, x, y });
|
|
960
|
+
}
|
|
961
|
+
function CustomTick({ x, y, payload }) {
|
|
952
962
|
return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
953
963
|
"text",
|
|
954
964
|
{
|
|
955
|
-
|
|
956
|
-
|
|
957
|
-
textAnchor: "middle",
|
|
965
|
+
className: "text-body-foreground",
|
|
966
|
+
fill: "currentColor",
|
|
958
967
|
fontSize: 12,
|
|
959
968
|
fontWeight: 700,
|
|
960
|
-
|
|
961
|
-
|
|
969
|
+
textAnchor: "middle",
|
|
970
|
+
x,
|
|
971
|
+
y: y + 14,
|
|
962
972
|
children: payload.value
|
|
963
973
|
}
|
|
964
974
|
);
|
|
965
|
-
}
|
|
975
|
+
}
|
|
966
976
|
(0, import_react5.useLayoutEffect)(() => {
|
|
967
977
|
if (!tooltipState || !chartRef.current || !tooltipRef.current) return;
|
|
968
978
|
const chartRect = chartRef.current.getBoundingClientRect();
|
|
@@ -981,7 +991,6 @@ var SimpleBarChartComponent = (0, import_react5.forwardRef)((originalProps, ref)
|
|
|
981
991
|
return /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(
|
|
982
992
|
"div",
|
|
983
993
|
{
|
|
984
|
-
ref: chartRef,
|
|
985
994
|
className: slots.base({ class: classNames == null ? void 0 : classNames.base }),
|
|
986
995
|
onMouseLeave: handleMouseLeave,
|
|
987
996
|
onMouseMove: (e) => {
|
|
@@ -990,63 +999,64 @@ var SimpleBarChartComponent = (0, import_react5.forwardRef)((originalProps, ref)
|
|
|
990
999
|
setTooltipState(null);
|
|
991
1000
|
}
|
|
992
1001
|
},
|
|
1002
|
+
ref: chartRef,
|
|
993
1003
|
children: [
|
|
994
|
-
label
|
|
995
|
-
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_recharts5.ResponsiveContainer, { width: "100%",
|
|
1004
|
+
label ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("p", { className: slots.label({ class: classNames == null ? void 0 : classNames.label }), children: label }) : null,
|
|
1005
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_recharts5.ResponsiveContainer, { height: 140, width: "100%", children: /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(
|
|
996
1006
|
import_recharts5.BarChart,
|
|
997
1007
|
{
|
|
998
|
-
data,
|
|
999
|
-
margin: { left: 0, right: 0, top: 0, bottom: 0 },
|
|
1000
|
-
barSize: 10,
|
|
1001
1008
|
barGap,
|
|
1009
|
+
barSize: 10,
|
|
1002
1010
|
className: "[&_.recharts-surface]:outline-none [&_.recharts-surface]:focus:outline-none",
|
|
1011
|
+
data,
|
|
1012
|
+
margin: { left: 0, right: 0, top: 0, bottom: 0 },
|
|
1003
1013
|
children: [
|
|
1004
1014
|
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
1005
1015
|
import_recharts5.CartesianGrid,
|
|
1006
1016
|
{
|
|
1007
|
-
|
|
1017
|
+
className: "stroke-neutral-light",
|
|
1008
1018
|
horizontal: false,
|
|
1009
1019
|
strokeDasharray: "4 4",
|
|
1010
|
-
|
|
1020
|
+
vertical: true,
|
|
1011
1021
|
verticalPoints: tickPositions
|
|
1012
1022
|
}
|
|
1013
1023
|
),
|
|
1014
1024
|
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
1015
1025
|
import_recharts5.CartesianGrid,
|
|
1016
1026
|
{
|
|
1017
|
-
|
|
1027
|
+
className: "stroke-neutral-light",
|
|
1018
1028
|
horizontal: false,
|
|
1019
1029
|
strokeDasharray: "0",
|
|
1020
1030
|
strokeWidth: 2,
|
|
1021
|
-
|
|
1031
|
+
vertical: true,
|
|
1022
1032
|
verticalPoints: [0]
|
|
1023
1033
|
}
|
|
1024
1034
|
),
|
|
1025
1035
|
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
1026
1036
|
import_recharts5.XAxis,
|
|
1027
1037
|
{
|
|
1028
|
-
dataKey: "title",
|
|
1029
1038
|
axisLine: { stroke: "#DFE2E7", strokeWidth: 1 },
|
|
1030
|
-
|
|
1039
|
+
dataKey: "title",
|
|
1040
|
+
padding: { left: 0, right: 0 },
|
|
1031
1041
|
tick: CustomTick,
|
|
1032
|
-
|
|
1042
|
+
tickLine: false
|
|
1033
1043
|
}
|
|
1034
1044
|
),
|
|
1035
|
-
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_recharts5.YAxis, { hide: true, ticks: yAxisTicks
|
|
1045
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_recharts5.YAxis, { domain: yAxisDomain, hide: true, ticks: yAxisTicks }),
|
|
1036
1046
|
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
1037
1047
|
import_recharts5.Bar,
|
|
1038
1048
|
{
|
|
1039
1049
|
dataKey: "value",
|
|
1040
1050
|
fill: "#C7E5FA",
|
|
1041
|
-
shape: CustomBarShape,
|
|
1042
1051
|
onMouseEnter: handleMouseEnter,
|
|
1043
|
-
onMouseLeave: handleMouseLeave
|
|
1052
|
+
onMouseLeave: handleMouseLeave,
|
|
1053
|
+
shape: CustomBarShape
|
|
1044
1054
|
}
|
|
1045
1055
|
)
|
|
1046
1056
|
]
|
|
1047
1057
|
}
|
|
1048
1058
|
) }),
|
|
1049
|
-
tooltipFormatter
|
|
1059
|
+
tooltipFormatter ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
1050
1060
|
"div",
|
|
1051
1061
|
{
|
|
1052
1062
|
ref: tooltipRef,
|
|
@@ -1062,9 +1072,9 @@ var SimpleBarChartComponent = (0, import_react5.forwardRef)((originalProps, ref)
|
|
|
1062
1072
|
width: "fit-content",
|
|
1063
1073
|
whiteSpace: "nowrap"
|
|
1064
1074
|
},
|
|
1065
|
-
children: tooltipState
|
|
1075
|
+
children: tooltipState ? tooltipFormatter(tooltipState) : null
|
|
1066
1076
|
}
|
|
1067
|
-
)
|
|
1077
|
+
) : null
|
|
1068
1078
|
]
|
|
1069
1079
|
}
|
|
1070
1080
|
);
|