@mlw-packages/react-components 1.8.8 → 1.8.10
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/index.css +161 -3
- package/dist/index.d.mts +115 -89
- package/dist/index.d.ts +115 -89
- package/dist/index.js +549 -237
- package/dist/index.mjs +550 -239
- package/package.json +3 -3
package/dist/index.mjs
CHANGED
|
@@ -5,7 +5,7 @@ import { Slot } from '@radix-ui/react-slot';
|
|
|
5
5
|
import { cva } from 'class-variance-authority';
|
|
6
6
|
import { clsx } from 'clsx';
|
|
7
7
|
import { twMerge } from 'tailwind-merge';
|
|
8
|
-
import { XIcon, CircleNotchIcon, MagnifyingGlassIcon, CaretUpIcon, CaretDownIcon, CheckIcon, CaretRightIcon, CircleIcon, CloudArrowUpIcon, MinusIcon, CaretUpDownIcon, PencilSimpleIcon, ArrowsLeftRightIcon, FloppyDiskIcon, PlusIcon, TrashIcon, SidebarSimpleIcon, FilePdfIcon, FileDocIcon, FileXlsIcon, FilePptIcon, FileCsvIcon, FileTextIcon, FileImageIcon, FileVideoIcon, FileAudioIcon, FileZipIcon, FileIcon, DotsSixVerticalIcon, InfoIcon, WarningIcon, XCircleIcon, CheckCircleIcon, SunIcon, MoonIcon, CaretLeftIcon, DownloadSimpleIcon, UploadSimpleIcon, CopyIcon, ArrowClockwiseIcon, ArrowLeftIcon, GearIcon, BellIcon, DotsThreeIcon, FunnelIcon, HeartIcon, StarIcon, EyeIcon, EyeSlashIcon, LockIcon, LockOpenIcon, ArrowRightIcon as ArrowRightIcon$1, FolderIcon, ArrowsOutIcon, DownloadIcon, CalendarBlankIcon, CalendarIcon, CaretLeft, CaretRight, ArrowDownIcon, ClockUserIcon, EyeSlash, Eye, ArrowUpRightIcon, ArrowDownRightIcon, FileArchiveIcon, TerminalIcon, CodeIcon, CalendarDotIcon as CalendarDotIcon$1, DesktopIcon } from '@phosphor-icons/react';
|
|
8
|
+
import { XIcon, CircleNotchIcon, MagnifyingGlassIcon, CaretUpIcon, CaretDownIcon, CheckIcon, CaretRightIcon, CircleIcon, CloudArrowUpIcon, MinusIcon, CaretUpDownIcon, PencilSimpleIcon, ArrowsLeftRightIcon, FloppyDiskIcon, PlusIcon, TrashIcon, SidebarSimpleIcon, FilePdfIcon, FileDocIcon, FileXlsIcon, FilePptIcon, FileCsvIcon, FileTextIcon, FileImageIcon, FileVideoIcon, FileAudioIcon, FileZipIcon, FileIcon, DotsSixVerticalIcon, InfoIcon, WarningIcon, XCircleIcon, CheckCircleIcon, SunIcon, MoonIcon, CaretLeftIcon, DownloadSimpleIcon, UploadSimpleIcon, CopyIcon, ArrowClockwiseIcon, ArrowLeftIcon, GearIcon, BellIcon, DotsThreeIcon, FunnelIcon, HeartIcon, StarIcon, EyeIcon, EyeSlashIcon, LockIcon, LockOpenIcon, ArrowRightIcon as ArrowRightIcon$1, FolderIcon, ArrowsOutIcon, DownloadIcon, CalendarBlankIcon, CalendarIcon, CaretLeft, CaretRight, ArrowDownIcon, ClockUserIcon, EyeSlash, Eye, ArrowRight, ArrowUpRightIcon, ArrowDownRightIcon, FileArchiveIcon, TerminalIcon, CodeIcon, CalendarDotIcon as CalendarDotIcon$1, DesktopIcon } from '@phosphor-icons/react';
|
|
9
9
|
import * as AlertDialogPrimitive from '@radix-ui/react-alert-dialog';
|
|
10
10
|
import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
|
|
11
11
|
import * as DialogPrimitive from '@radix-ui/react-dialog';
|
|
@@ -645,7 +645,7 @@ var DialogContentBase = React33.forwardRef(
|
|
|
645
645
|
{
|
|
646
646
|
ref,
|
|
647
647
|
className: cn(
|
|
648
|
-
"fixed left-[50%] top-[50%] z-50
|
|
648
|
+
"fixed left-[50%] top-[50%] z-50 w-lg grid translate-x-[-50%] translate-y-[-50%] gap-4 border bg-background p-6 shadow-lg duration-200 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[state=closed]:slide-out-to-left-1/2 data-[state=closed]:slide-out-to-top-[48%] data-[state=open]:slide-in-from-left-1/2 data-[state=open]:slide-in-from-top-[48%] sm:rounded-lg max-h-[100dvh] overflow-auto rounded-md border-border",
|
|
649
649
|
className
|
|
650
650
|
),
|
|
651
651
|
"data-testid": dataTestId,
|
|
@@ -654,7 +654,7 @@ var DialogContentBase = React33.forwardRef(
|
|
|
654
654
|
children: [
|
|
655
655
|
children,
|
|
656
656
|
/* @__PURE__ */ jsxs(DialogPrimitive.Close, { className: "absolute right-3 top-3 sm:right-4 sm:top-4 rounded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-accent data-[state=open]:text-muted-foreground z-10 touch-manipulation", children: [
|
|
657
|
-
/* @__PURE__ */ jsx(XIcon, { className: "h-
|
|
657
|
+
/* @__PURE__ */ jsx(XIcon, { className: "h-6 w-6 sm:h-4 sm:w-4 hover:text-red-500 font-extrabold" }),
|
|
658
658
|
/* @__PURE__ */ jsx("span", { className: "sr-only", children: "Close" })
|
|
659
659
|
] })
|
|
660
660
|
]
|
|
@@ -1027,7 +1027,7 @@ var ProgressBase = React33.forwardRef(
|
|
|
1027
1027
|
]
|
|
1028
1028
|
}
|
|
1029
1029
|
),
|
|
1030
|
-
showValue && valuePosition === "right" && /* @__PURE__ */ jsxs("div", { className: "
|
|
1030
|
+
showValue && valuePosition === "right" && /* @__PURE__ */ jsxs("div", { className: " text-sm font-bold text-left", children: [
|
|
1031
1031
|
Math.round(value || 0),
|
|
1032
1032
|
"%"
|
|
1033
1033
|
] }),
|
|
@@ -1289,35 +1289,55 @@ var useDrag = (options = {}) => {
|
|
|
1289
1289
|
const [positions, setPositions] = useState({});
|
|
1290
1290
|
const dragStartPos = useRef(null);
|
|
1291
1291
|
const dragId = useRef(null);
|
|
1292
|
-
const
|
|
1293
|
-
e
|
|
1294
|
-
|
|
1295
|
-
|
|
1296
|
-
|
|
1297
|
-
|
|
1298
|
-
|
|
1299
|
-
|
|
1300
|
-
|
|
1301
|
-
|
|
1302
|
-
|
|
1303
|
-
|
|
1304
|
-
|
|
1305
|
-
|
|
1306
|
-
|
|
1307
|
-
|
|
1308
|
-
|
|
1309
|
-
|
|
1310
|
-
|
|
1311
|
-
|
|
1312
|
-
|
|
1313
|
-
|
|
1314
|
-
|
|
1315
|
-
|
|
1316
|
-
|
|
1317
|
-
[
|
|
1318
|
-
|
|
1319
|
-
|
|
1320
|
-
|
|
1292
|
+
const handleDragStart = useCallback(
|
|
1293
|
+
(id, e) => {
|
|
1294
|
+
const isTouchEvent = "touches" in e;
|
|
1295
|
+
const clientX = isTouchEvent ? e.touches[0].clientX : e.clientX;
|
|
1296
|
+
const clientY = isTouchEvent ? e.touches[0].clientY : e.clientY;
|
|
1297
|
+
if (!isTouchEvent) {
|
|
1298
|
+
e.preventDefault();
|
|
1299
|
+
}
|
|
1300
|
+
const currentPosition = positions[id] || { top: 0, left: 0 };
|
|
1301
|
+
dragStartPos.current = {
|
|
1302
|
+
x: clientX,
|
|
1303
|
+
y: clientY,
|
|
1304
|
+
elementX: currentPosition.left,
|
|
1305
|
+
elementY: currentPosition.top
|
|
1306
|
+
};
|
|
1307
|
+
dragId.current = id;
|
|
1308
|
+
setIsDragging(id);
|
|
1309
|
+
options.onDragStart?.(id);
|
|
1310
|
+
},
|
|
1311
|
+
[positions, options]
|
|
1312
|
+
);
|
|
1313
|
+
const handleMouseMove = useCallback(
|
|
1314
|
+
(e) => {
|
|
1315
|
+
if (!isDragging || !dragStartPos.current || !dragId.current) return;
|
|
1316
|
+
const isTouchEvent = "touches" in e;
|
|
1317
|
+
const clientX = isTouchEvent ? e.touches[0].clientX : e.clientX;
|
|
1318
|
+
const clientY = isTouchEvent ? e.touches[0].clientY : e.clientY;
|
|
1319
|
+
const deltaX = clientX - dragStartPos.current.x;
|
|
1320
|
+
const deltaY = clientY - dragStartPos.current.y;
|
|
1321
|
+
const newPosition = {
|
|
1322
|
+
left: dragStartPos.current.elementX + deltaX,
|
|
1323
|
+
top: dragStartPos.current.elementY + deltaY
|
|
1324
|
+
};
|
|
1325
|
+
newPosition.left = Math.max(
|
|
1326
|
+
0,
|
|
1327
|
+
Math.min(window.innerWidth - 300, newPosition.left)
|
|
1328
|
+
);
|
|
1329
|
+
newPosition.top = Math.max(
|
|
1330
|
+
0,
|
|
1331
|
+
Math.min(window.innerHeight - 200, newPosition.top)
|
|
1332
|
+
);
|
|
1333
|
+
setPositions((prev) => ({
|
|
1334
|
+
...prev,
|
|
1335
|
+
[dragId.current]: newPosition
|
|
1336
|
+
}));
|
|
1337
|
+
options.onDrag?.(dragId.current, newPosition);
|
|
1338
|
+
},
|
|
1339
|
+
[isDragging, options]
|
|
1340
|
+
);
|
|
1321
1341
|
const handleMouseUp = useCallback(() => {
|
|
1322
1342
|
if (dragId.current) {
|
|
1323
1343
|
options.onDragEnd?.(dragId.current);
|
|
@@ -1330,10 +1350,16 @@ var useDrag = (options = {}) => {
|
|
|
1330
1350
|
if (isDragging) {
|
|
1331
1351
|
document.addEventListener("mousemove", handleMouseMove);
|
|
1332
1352
|
document.addEventListener("mouseup", handleMouseUp);
|
|
1353
|
+
document.addEventListener("touchmove", handleMouseMove, {
|
|
1354
|
+
passive: false
|
|
1355
|
+
});
|
|
1356
|
+
document.addEventListener("touchend", handleMouseUp);
|
|
1333
1357
|
document.body.style.userSelect = "none";
|
|
1334
1358
|
return () => {
|
|
1335
1359
|
document.removeEventListener("mousemove", handleMouseMove);
|
|
1336
1360
|
document.removeEventListener("mouseup", handleMouseUp);
|
|
1361
|
+
document.removeEventListener("touchmove", handleMouseMove);
|
|
1362
|
+
document.removeEventListener("touchend", handleMouseUp);
|
|
1337
1363
|
document.body.style.userSelect = "";
|
|
1338
1364
|
};
|
|
1339
1365
|
}
|
|
@@ -1344,14 +1370,20 @@ var useDrag = (options = {}) => {
|
|
|
1344
1370
|
[id]: position
|
|
1345
1371
|
}));
|
|
1346
1372
|
}, []);
|
|
1347
|
-
const getPosition = useCallback(
|
|
1348
|
-
|
|
1349
|
-
|
|
1350
|
-
|
|
1351
|
-
|
|
1352
|
-
|
|
1373
|
+
const getPosition = useCallback(
|
|
1374
|
+
(id) => {
|
|
1375
|
+
return positions[id] || { top: 0, left: 0 };
|
|
1376
|
+
},
|
|
1377
|
+
[positions]
|
|
1378
|
+
);
|
|
1379
|
+
const isElementDragging = useCallback(
|
|
1380
|
+
(id) => {
|
|
1381
|
+
return isDragging === id;
|
|
1382
|
+
},
|
|
1383
|
+
[isDragging]
|
|
1384
|
+
);
|
|
1353
1385
|
return {
|
|
1354
|
-
handleMouseDown,
|
|
1386
|
+
handleMouseDown: handleDragStart,
|
|
1355
1387
|
getPosition,
|
|
1356
1388
|
setPosition,
|
|
1357
1389
|
isElementDragging,
|
|
@@ -1392,7 +1424,8 @@ var TooltipBase = ({ children, delayDuration = TOOLTIP_DELAY_DURATION, ...props
|
|
|
1392
1424
|
) });
|
|
1393
1425
|
};
|
|
1394
1426
|
TooltipBase.displayName = "TooltipBase";
|
|
1395
|
-
var TooltipTriggerBase = React33.forwardRef(({ children, onPointerDown, ...props }, ref) => {
|
|
1427
|
+
var TooltipTriggerBase = React33.forwardRef(({ children, onPointerDown, onClick: propOnClick, ...props }, ref) => {
|
|
1428
|
+
const { setOpen, isMobile } = React33.useContext(TooltipClickContext);
|
|
1396
1429
|
const handlePointerDown = React33.useCallback(
|
|
1397
1430
|
(e) => {
|
|
1398
1431
|
if (onPointerDown) {
|
|
@@ -1403,11 +1436,26 @@ var TooltipTriggerBase = React33.forwardRef(({ children, onPointerDown, ...props
|
|
|
1403
1436
|
);
|
|
1404
1437
|
const onClick = React33.useCallback(
|
|
1405
1438
|
(e) => {
|
|
1439
|
+
if (propOnClick) {
|
|
1440
|
+
propOnClick(e);
|
|
1441
|
+
}
|
|
1406
1442
|
if (onPointerDown) {
|
|
1407
1443
|
onPointerDown(e);
|
|
1408
1444
|
}
|
|
1445
|
+
if (isMobile && setOpen) {
|
|
1446
|
+
e.preventDefault();
|
|
1447
|
+
setOpen((prev) => !prev);
|
|
1448
|
+
}
|
|
1409
1449
|
},
|
|
1410
|
-
[onPointerDown]
|
|
1450
|
+
[onPointerDown, isMobile, setOpen, propOnClick]
|
|
1451
|
+
);
|
|
1452
|
+
const preventDefaultOnMobile = React33.useCallback(
|
|
1453
|
+
(e) => {
|
|
1454
|
+
if (isMobile) {
|
|
1455
|
+
e.preventDefault();
|
|
1456
|
+
}
|
|
1457
|
+
},
|
|
1458
|
+
[isMobile]
|
|
1411
1459
|
);
|
|
1412
1460
|
return /* @__PURE__ */ jsx(
|
|
1413
1461
|
TooltipPrimitive.Trigger,
|
|
@@ -1416,6 +1464,9 @@ var TooltipTriggerBase = React33.forwardRef(({ children, onPointerDown, ...props
|
|
|
1416
1464
|
tabIndex: -1,
|
|
1417
1465
|
onPointerDown: onPointerDown ? handlePointerDown : void 0,
|
|
1418
1466
|
onClick,
|
|
1467
|
+
onFocus: preventDefaultOnMobile,
|
|
1468
|
+
onMouseEnter: preventDefaultOnMobile,
|
|
1469
|
+
onMouseLeave: preventDefaultOnMobile,
|
|
1419
1470
|
"data-tooltip-trigger": true,
|
|
1420
1471
|
"aria-describedby": "tooltip-content",
|
|
1421
1472
|
...props,
|
|
@@ -3118,9 +3169,13 @@ function ModeToggleBase({
|
|
|
3118
3169
|
className,
|
|
3119
3170
|
variant = "ghost"
|
|
3120
3171
|
}) {
|
|
3172
|
+
const [mounted, setMounted] = useState(false);
|
|
3121
3173
|
const { setTheme, theme: currentTheme } = useTheme();
|
|
3122
3174
|
const buttonRef = useRef(null);
|
|
3123
|
-
|
|
3175
|
+
useEffect(() => {
|
|
3176
|
+
setMounted(true);
|
|
3177
|
+
}, []);
|
|
3178
|
+
const isDark = mounted && (currentTheme?.includes("dark") || currentTheme === "system" && typeof window !== "undefined" && window.matchMedia("(prefers-color-scheme: dark)").matches);
|
|
3124
3179
|
const toggleTheme = async (newTheme) => {
|
|
3125
3180
|
if (!buttonRef.current || !document.startViewTransition) {
|
|
3126
3181
|
setTheme(newTheme);
|
|
@@ -3161,7 +3216,7 @@ function ModeToggleBase({
|
|
|
3161
3216
|
variant,
|
|
3162
3217
|
size: "icon",
|
|
3163
3218
|
className: cn(
|
|
3164
|
-
"relative overflow-hidden
|
|
3219
|
+
"relative overflow-hidden group",
|
|
3165
3220
|
className
|
|
3166
3221
|
),
|
|
3167
3222
|
children: [
|
|
@@ -3187,7 +3242,7 @@ function ModeToggleBase({
|
|
|
3187
3242
|
DropDownMenuContentBase,
|
|
3188
3243
|
{
|
|
3189
3244
|
align: "end",
|
|
3190
|
-
className: "border-border bg-popover text-popover-foreground min-w-[140px]",
|
|
3245
|
+
className: "border-border bg-popover text-popover-foreground min-w-[140px] ",
|
|
3191
3246
|
children: themes.map((theme) => {
|
|
3192
3247
|
const isActive = currentTheme === theme;
|
|
3193
3248
|
return /* @__PURE__ */ jsxs(
|
|
@@ -3195,8 +3250,8 @@ function ModeToggleBase({
|
|
|
3195
3250
|
{
|
|
3196
3251
|
onClick: () => toggleTheme(theme),
|
|
3197
3252
|
className: cn(
|
|
3198
|
-
"gap-
|
|
3199
|
-
isActive ? "bg-accent/80 text-accent-foreground border-l-2 border-primary font-medium pl-1.5" : "hover:bg-accent hover:text-accent-foreground"
|
|
3253
|
+
"gap-2 transition-all duration-200",
|
|
3254
|
+
isActive ? "bg-accent/80 text-accent-foreground border-l-2 border-primary font-medium pl-1.5 my-0.5" : "hover:bg-accent hover:text-accent-foreground"
|
|
3200
3255
|
),
|
|
3201
3256
|
children: [
|
|
3202
3257
|
/* @__PURE__ */ jsx(ThemeIcon, { theme }),
|
|
@@ -7428,18 +7483,17 @@ function ScrollColumn({ value, onChange, max, label }) {
|
|
|
7428
7483
|
}
|
|
7429
7484
|
}, 100);
|
|
7430
7485
|
};
|
|
7431
|
-
const
|
|
7486
|
+
const handleStart = (pageY) => {
|
|
7432
7487
|
if (!containerRef.current) return;
|
|
7433
7488
|
setIsDragging(true);
|
|
7434
|
-
setStartY(
|
|
7489
|
+
setStartY(pageY);
|
|
7435
7490
|
setScrollTop(containerRef.current.scrollTop);
|
|
7436
7491
|
};
|
|
7437
|
-
const
|
|
7492
|
+
const handleMove = (pageY) => {
|
|
7438
7493
|
if (!isDragging || !containerRef.current) return;
|
|
7439
|
-
|
|
7440
|
-
containerRef.current.scrollTop = scrollTop + (startY - e.pageY) * 2;
|
|
7494
|
+
containerRef.current.scrollTop = scrollTop + (startY - pageY) * 2;
|
|
7441
7495
|
};
|
|
7442
|
-
const
|
|
7496
|
+
const handleEnd = () => {
|
|
7443
7497
|
if (!containerRef.current) return;
|
|
7444
7498
|
setIsDragging(false);
|
|
7445
7499
|
requestAnimationFrame(() => {
|
|
@@ -7451,8 +7505,32 @@ function ScrollColumn({ value, onChange, max, label }) {
|
|
|
7451
7505
|
}
|
|
7452
7506
|
});
|
|
7453
7507
|
};
|
|
7508
|
+
const handleMouseDown = (e) => {
|
|
7509
|
+
handleStart(e.pageY);
|
|
7510
|
+
};
|
|
7511
|
+
const handleMouseMove = (e) => {
|
|
7512
|
+
if (isDragging) {
|
|
7513
|
+
e.preventDefault();
|
|
7514
|
+
handleMove(e.pageY);
|
|
7515
|
+
}
|
|
7516
|
+
};
|
|
7517
|
+
const handleMouseUp = () => {
|
|
7518
|
+
handleEnd();
|
|
7519
|
+
};
|
|
7454
7520
|
const handleMouseLeave = () => {
|
|
7455
|
-
if (isDragging)
|
|
7521
|
+
if (isDragging) handleEnd();
|
|
7522
|
+
};
|
|
7523
|
+
const handleTouchStart = (e) => {
|
|
7524
|
+
handleStart(e.touches[0].pageY);
|
|
7525
|
+
};
|
|
7526
|
+
const handleTouchMove = (e) => {
|
|
7527
|
+
if (isDragging) {
|
|
7528
|
+
if (e.cancelable) e.preventDefault();
|
|
7529
|
+
handleMove(e.touches[0].pageY);
|
|
7530
|
+
}
|
|
7531
|
+
};
|
|
7532
|
+
const handleTouchEnd = () => {
|
|
7533
|
+
handleEnd();
|
|
7456
7534
|
};
|
|
7457
7535
|
const handleWheel = (e) => {
|
|
7458
7536
|
e.stopPropagation();
|
|
@@ -7470,6 +7548,9 @@ function ScrollColumn({ value, onChange, max, label }) {
|
|
|
7470
7548
|
onMouseMove: handleMouseMove,
|
|
7471
7549
|
onMouseUp: handleMouseUp,
|
|
7472
7550
|
onMouseLeave: handleMouseLeave,
|
|
7551
|
+
onTouchStart: handleTouchStart,
|
|
7552
|
+
onTouchMove: handleTouchMove,
|
|
7553
|
+
onTouchEnd: handleTouchEnd,
|
|
7473
7554
|
style: {
|
|
7474
7555
|
height: `${containerHeight}px`,
|
|
7475
7556
|
paddingTop: `${centerIndex * itemHeight}px`,
|
|
@@ -13783,7 +13864,7 @@ function MultiSelect({
|
|
|
13783
13864
|
|
|
13784
13865
|
// src/components/ui/charts/utils/helpers.ts
|
|
13785
13866
|
var formatFieldName = (fieldName) => {
|
|
13786
|
-
return fieldName.
|
|
13867
|
+
return (fieldName.match(/[^/_-]+/g) || []).map((word) => {
|
|
13787
13868
|
return word.charAt(0).toUpperCase() + word.slice(1);
|
|
13788
13869
|
}).join(" ").trim();
|
|
13789
13870
|
};
|
|
@@ -14510,7 +14591,7 @@ var DraggableTooltipComponent = ({
|
|
|
14510
14591
|
highlightedSeries,
|
|
14511
14592
|
toggleHighlight,
|
|
14512
14593
|
showOnlyHighlighted,
|
|
14513
|
-
valueFormatter
|
|
14594
|
+
valueFormatter,
|
|
14514
14595
|
categoryFormatter
|
|
14515
14596
|
}) => {
|
|
14516
14597
|
const visibleKeys = useMemo(
|
|
@@ -14926,7 +15007,7 @@ var DraggableTooltipComponent = ({
|
|
|
14926
15007
|
{
|
|
14927
15008
|
data,
|
|
14928
15009
|
visibleKeys,
|
|
14929
|
-
valueFormatter
|
|
15010
|
+
valueFormatter
|
|
14930
15011
|
}
|
|
14931
15012
|
) })
|
|
14932
15013
|
] }) }),
|
|
@@ -14945,7 +15026,7 @@ var DraggableTooltipComponent = ({
|
|
|
14945
15026
|
);
|
|
14946
15027
|
const val = typeof value === "number" ? value : Number(value) || 0;
|
|
14947
15028
|
const defaultFormatted = val.toLocaleString("pt-BR");
|
|
14948
|
-
const displayValue =
|
|
15029
|
+
const displayValue = valueFormatter ? valueFormatter({
|
|
14949
15030
|
value,
|
|
14950
15031
|
formattedValue: defaultFormatted,
|
|
14951
15032
|
dataKey: key,
|
|
@@ -15026,7 +15107,7 @@ var DraggableTooltipComponent = ({
|
|
|
15026
15107
|
highlightedSeries,
|
|
15027
15108
|
toggleHighlight,
|
|
15028
15109
|
finalColors,
|
|
15029
|
-
|
|
15110
|
+
valueFormatter
|
|
15030
15111
|
]
|
|
15031
15112
|
),
|
|
15032
15113
|
/* @__PURE__ */ jsx("div", { className: "mt-3 pt-2 border-t", children: /* @__PURE__ */ jsxs("p", { className: "text-xs text-muted-foreground flex items-center gap-1", children: [
|
|
@@ -15060,7 +15141,7 @@ var RechartTooltipWithTotal = ({
|
|
|
15060
15141
|
finalColors = {},
|
|
15061
15142
|
periodLabel = "Per\xEDodo",
|
|
15062
15143
|
totalLabel = "Total",
|
|
15063
|
-
valueFormatter
|
|
15144
|
+
valueFormatter,
|
|
15064
15145
|
categoryFormatter,
|
|
15065
15146
|
yAxisMap,
|
|
15066
15147
|
isBiaxial = false
|
|
@@ -15084,7 +15165,7 @@ var RechartTooltipWithTotal = ({
|
|
|
15084
15165
|
}
|
|
15085
15166
|
return total.toLocaleString("pt-BR");
|
|
15086
15167
|
})();
|
|
15087
|
-
const displayTotal =
|
|
15168
|
+
const displayTotal = valueFormatter ? valueFormatter({
|
|
15088
15169
|
value: total,
|
|
15089
15170
|
formattedValue: defaultTotalFormatted,
|
|
15090
15171
|
dataKey: "total",
|
|
@@ -15147,7 +15228,7 @@ var RechartTooltipWithTotal = ({
|
|
|
15147
15228
|
}
|
|
15148
15229
|
return value.toLocaleString("pt-BR");
|
|
15149
15230
|
})();
|
|
15150
|
-
const displayValue =
|
|
15231
|
+
const displayValue = valueFormatter ? valueFormatter({
|
|
15151
15232
|
value: entry.value,
|
|
15152
15233
|
formattedValue: defaultFormatted,
|
|
15153
15234
|
dataKey: entry.dataKey,
|
|
@@ -15212,7 +15293,7 @@ var TooltipSimple = ({
|
|
|
15212
15293
|
label,
|
|
15213
15294
|
finalColors = {},
|
|
15214
15295
|
periodLabel = "Per\xEDodo",
|
|
15215
|
-
valueFormatter
|
|
15296
|
+
valueFormatter,
|
|
15216
15297
|
categoryFormatter,
|
|
15217
15298
|
yAxisMap,
|
|
15218
15299
|
isBiaxial = false
|
|
@@ -15260,7 +15341,7 @@ var TooltipSimple = ({
|
|
|
15260
15341
|
}
|
|
15261
15342
|
return value.toLocaleString("pt-BR");
|
|
15262
15343
|
})();
|
|
15263
|
-
const displayValue =
|
|
15344
|
+
const displayValue = valueFormatter ? valueFormatter({
|
|
15264
15345
|
value: entry.value,
|
|
15265
15346
|
formattedValue: defaultFormatted,
|
|
15266
15347
|
dataKey: entry.dataKey,
|
|
@@ -15302,6 +15383,210 @@ var TooltipSimple = ({
|
|
|
15302
15383
|
);
|
|
15303
15384
|
};
|
|
15304
15385
|
var TooltipSimple_default = TooltipSimple;
|
|
15386
|
+
var tooltipVariants2 = {
|
|
15387
|
+
hidden: {
|
|
15388
|
+
opacity: 0,
|
|
15389
|
+
scale: 0.96,
|
|
15390
|
+
transition: { type: "spring", stiffness: 400, damping: 28 }
|
|
15391
|
+
},
|
|
15392
|
+
visible: {
|
|
15393
|
+
opacity: 1,
|
|
15394
|
+
scale: 1,
|
|
15395
|
+
transition: { type: "spring", stiffness: 300, damping: 28 }
|
|
15396
|
+
},
|
|
15397
|
+
exit: {
|
|
15398
|
+
opacity: 0,
|
|
15399
|
+
scale: 0.96,
|
|
15400
|
+
transition: { type: "spring", stiffness: 400, damping: 28 }
|
|
15401
|
+
}
|
|
15402
|
+
};
|
|
15403
|
+
var SystemTooltip = ({
|
|
15404
|
+
id,
|
|
15405
|
+
data,
|
|
15406
|
+
position,
|
|
15407
|
+
title = "Conex\xF5es",
|
|
15408
|
+
onMouseDown,
|
|
15409
|
+
onClose,
|
|
15410
|
+
onPositionChange
|
|
15411
|
+
}) => {
|
|
15412
|
+
const [localPos, setLocalPos] = useState(position);
|
|
15413
|
+
const [dragging, setDragging] = useState(false);
|
|
15414
|
+
const offsetRef = useRef({ x: 0, y: 0 });
|
|
15415
|
+
const lastMouse = useRef({ x: 0, y: 0 });
|
|
15416
|
+
useEffect(() => setLocalPos(position), [position]);
|
|
15417
|
+
useEffect(() => {
|
|
15418
|
+
let rafId = null;
|
|
15419
|
+
const handleMouseMove = (e) => {
|
|
15420
|
+
if (!dragging) return;
|
|
15421
|
+
lastMouse.current = { x: e.clientX, y: e.clientY };
|
|
15422
|
+
if (rafId) cancelAnimationFrame(rafId);
|
|
15423
|
+
rafId = requestAnimationFrame(() => {
|
|
15424
|
+
const newLeft = lastMouse.current.x - offsetRef.current.x;
|
|
15425
|
+
const newTop = lastMouse.current.y - offsetRef.current.y;
|
|
15426
|
+
const rawPosition = {
|
|
15427
|
+
top: Math.max(0, Math.min(newTop, window.innerHeight - 200)),
|
|
15428
|
+
left: Math.max(0, Math.min(newLeft, window.innerWidth - 320))
|
|
15429
|
+
};
|
|
15430
|
+
setLocalPos(rawPosition);
|
|
15431
|
+
if (onPositionChange) onPositionChange(id, rawPosition);
|
|
15432
|
+
});
|
|
15433
|
+
};
|
|
15434
|
+
const handleMouseUp = () => {
|
|
15435
|
+
if (dragging) {
|
|
15436
|
+
setDragging(false);
|
|
15437
|
+
if (rafId) cancelAnimationFrame(rafId);
|
|
15438
|
+
}
|
|
15439
|
+
};
|
|
15440
|
+
if (dragging) {
|
|
15441
|
+
document.addEventListener("mousemove", handleMouseMove, {
|
|
15442
|
+
passive: true
|
|
15443
|
+
});
|
|
15444
|
+
document.addEventListener("mouseup", handleMouseUp);
|
|
15445
|
+
document.body.style.cursor = "grabbing";
|
|
15446
|
+
document.body.style.userSelect = "none";
|
|
15447
|
+
}
|
|
15448
|
+
return () => {
|
|
15449
|
+
if (rafId) cancelAnimationFrame(rafId);
|
|
15450
|
+
document.removeEventListener("mousemove", handleMouseMove);
|
|
15451
|
+
document.removeEventListener("mouseup", handleMouseUp);
|
|
15452
|
+
document.body.style.cursor = "";
|
|
15453
|
+
document.body.style.userSelect = "";
|
|
15454
|
+
};
|
|
15455
|
+
}, [dragging, id, onPositionChange]);
|
|
15456
|
+
const handleMouseDownLocal = useCallback(
|
|
15457
|
+
(e) => {
|
|
15458
|
+
e.preventDefault();
|
|
15459
|
+
e.stopPropagation();
|
|
15460
|
+
const rect = e.currentTarget.closest(".fixed")?.getBoundingClientRect();
|
|
15461
|
+
if (!rect) return;
|
|
15462
|
+
offsetRef.current = { x: e.clientX - rect.left, y: e.clientY - rect.top };
|
|
15463
|
+
setDragging(true);
|
|
15464
|
+
onMouseDown?.(id, e);
|
|
15465
|
+
},
|
|
15466
|
+
[id, onMouseDown]
|
|
15467
|
+
);
|
|
15468
|
+
const handleTouchStartLocal = useCallback(
|
|
15469
|
+
(e) => {
|
|
15470
|
+
e.stopPropagation();
|
|
15471
|
+
const touch = e.touches[0];
|
|
15472
|
+
if (!touch) return;
|
|
15473
|
+
const rect = e.currentTarget.closest(".fixed")?.getBoundingClientRect();
|
|
15474
|
+
if (!rect) return;
|
|
15475
|
+
offsetRef.current = {
|
|
15476
|
+
x: touch.clientX - rect.left,
|
|
15477
|
+
y: touch.clientY - rect.top
|
|
15478
|
+
};
|
|
15479
|
+
setDragging(true);
|
|
15480
|
+
onMouseDown?.(id, e);
|
|
15481
|
+
},
|
|
15482
|
+
[id, onMouseDown]
|
|
15483
|
+
);
|
|
15484
|
+
const entries = useMemo(
|
|
15485
|
+
() => data.connections.filter((c) => c.type === "entrada"),
|
|
15486
|
+
[data.connections]
|
|
15487
|
+
);
|
|
15488
|
+
const exits = useMemo(
|
|
15489
|
+
() => data.connections.filter((c) => c.type === "saida"),
|
|
15490
|
+
[data.connections]
|
|
15491
|
+
);
|
|
15492
|
+
return /* @__PURE__ */ jsx(AnimatePresence, { children: /* @__PURE__ */ jsxs(
|
|
15493
|
+
motion.div,
|
|
15494
|
+
{
|
|
15495
|
+
className: "fixed bg-card/95 backdrop-blur-md border border-border/50 rounded-xl shadow-2xl z-50 w-80 overflow-hidden",
|
|
15496
|
+
variants: tooltipVariants2,
|
|
15497
|
+
initial: "hidden",
|
|
15498
|
+
animate: "visible",
|
|
15499
|
+
exit: "exit",
|
|
15500
|
+
style: {
|
|
15501
|
+
top: localPos.top,
|
|
15502
|
+
left: localPos.left
|
|
15503
|
+
},
|
|
15504
|
+
onClick: (e) => e.stopPropagation(),
|
|
15505
|
+
children: [
|
|
15506
|
+
/* @__PURE__ */ jsxs(
|
|
15507
|
+
"div",
|
|
15508
|
+
{
|
|
15509
|
+
className: "flex items-center justify-between py-1 border-b border-border/10 bg-muted/30 ",
|
|
15510
|
+
onMouseDown: handleMouseDownLocal,
|
|
15511
|
+
onTouchStart: handleTouchStartLocal,
|
|
15512
|
+
style: {
|
|
15513
|
+
touchAction: "none",
|
|
15514
|
+
cursor: dragging ? "grabbing" : "grab"
|
|
15515
|
+
},
|
|
15516
|
+
children: [
|
|
15517
|
+
/* @__PURE__ */ jsxs("div", { className: "flex items-center gap-2 px-3", children: [
|
|
15518
|
+
/* @__PURE__ */ jsx("div", { className: "rounded", children: /* @__PURE__ */ jsx(DotsSixVerticalIcon, { size: 16, className: "text-primary" }) }),
|
|
15519
|
+
/* @__PURE__ */ jsx("span", { className: "text-xs font-semibold text-muted-foreground uppercase tracking-wider", children: title })
|
|
15520
|
+
] }),
|
|
15521
|
+
/* @__PURE__ */ jsx(
|
|
15522
|
+
ButtonBase,
|
|
15523
|
+
{
|
|
15524
|
+
variant: "ghost",
|
|
15525
|
+
size: "icon",
|
|
15526
|
+
onClick: () => onClose(id),
|
|
15527
|
+
className: "text-muted-foreground hover:text-destructive transition-colors hover:bg-destructive/10 mr-1",
|
|
15528
|
+
style: { cursor: "pointer" },
|
|
15529
|
+
children: /* @__PURE__ */ jsx(XIcon$1, { size: 16 })
|
|
15530
|
+
}
|
|
15531
|
+
)
|
|
15532
|
+
]
|
|
15533
|
+
}
|
|
15534
|
+
),
|
|
15535
|
+
/* @__PURE__ */ jsxs("div", { className: "px-4 pt-4 pb-3", children: [
|
|
15536
|
+
/* @__PURE__ */ jsx("h3", { className: "text-xl font-bold text-foreground tracking-tight truncate", children: data.name }),
|
|
15537
|
+
/* @__PURE__ */ jsx("h3", { className: "text-sm font-bold text-muted-foreground tracking-tight truncate", children: data.description })
|
|
15538
|
+
] }),
|
|
15539
|
+
/* @__PURE__ */ jsxs("div", { className: "px-3 pb-4 space-y-4 max-h-[300px] overflow-y-auto [&::-webkit-scrollbar]:w- [&::-webkit-scrollbar-track]:bg-transparent [&::-webkit-scrollbar-thumb]:bg-muted-foreground/20 [&::-webkit-scrollbar-thumb]:rounded-full hover:[&::-webkit-scrollbar-thumb]:bg-muted-foreground/40 transition-colors", children: [
|
|
15540
|
+
/* @__PURE__ */ jsx(SeparatorBase, { className: "w-full" }),
|
|
15541
|
+
entries.length > 0 && /* @__PURE__ */ jsxs("div", { className: "space-y-2", children: [
|
|
15542
|
+
/* @__PURE__ */ jsxs("div", { className: "flex items-center gap-2 px-1", children: [
|
|
15543
|
+
/* @__PURE__ */ jsx("div", { className: "w-1.5 h-1.5 rounded-full bg-emerald-500" }),
|
|
15544
|
+
/* @__PURE__ */ jsx("span", { className: "text-[10px] font-bold text-muted-foreground uppercase", children: "Entradas" })
|
|
15545
|
+
] }),
|
|
15546
|
+
/* @__PURE__ */ jsx("div", { className: "space-y-1", children: entries.map((conn) => /* @__PURE__ */ jsxs(
|
|
15547
|
+
"div",
|
|
15548
|
+
{
|
|
15549
|
+
className: "group flex items-center justify-between p-2 rounded-lg bg-emerald-500/5 border border-emerald-500/10 hover:border-emerald-500/30 transition-all",
|
|
15550
|
+
children: [
|
|
15551
|
+
/* @__PURE__ */ jsx("div", { className: "flex items-center gap-2 overflow-hidden", children: /* @__PURE__ */ jsx("span", { className: "text-sm font-medium truncate", children: conn.name }) }),
|
|
15552
|
+
" ",
|
|
15553
|
+
/* @__PURE__ */ jsx(
|
|
15554
|
+
ArrowRight,
|
|
15555
|
+
{
|
|
15556
|
+
size: 14,
|
|
15557
|
+
className: "text-emerald-500 shrink-0 rotate-180"
|
|
15558
|
+
}
|
|
15559
|
+
)
|
|
15560
|
+
]
|
|
15561
|
+
},
|
|
15562
|
+
conn.id
|
|
15563
|
+
)) })
|
|
15564
|
+
] }),
|
|
15565
|
+
exits.length > 0 && /* @__PURE__ */ jsxs("div", { className: "space-y-2", children: [
|
|
15566
|
+
/* @__PURE__ */ jsxs("div", { className: "flex items-center gap-2 px-1", children: [
|
|
15567
|
+
/* @__PURE__ */ jsx("div", { className: "w-1.5 h-1.5 rounded-full bg-blue-500" }),
|
|
15568
|
+
/* @__PURE__ */ jsx("span", { className: "text-[10px] font-bold text-muted-foreground uppercase", children: "Sa\xEDdas" })
|
|
15569
|
+
] }),
|
|
15570
|
+
/* @__PURE__ */ jsx("div", { className: "space-y-1", children: exits.map((conn) => /* @__PURE__ */ jsxs(
|
|
15571
|
+
"div",
|
|
15572
|
+
{
|
|
15573
|
+
className: "group flex items-center justify-between p-2 rounded-lg bg-blue-500/5 border border-blue-500/10 hover:border-blue-500/30 transition-all",
|
|
15574
|
+
children: [
|
|
15575
|
+
/* @__PURE__ */ jsx("div", { className: "flex items-center gap-2 overflow-hidden", children: /* @__PURE__ */ jsx("span", { className: "text-sm font-medium truncate", children: conn.name }) }),
|
|
15576
|
+
/* @__PURE__ */ jsx(ArrowRight, { size: 14, className: "text-blue-500 shrink-0" })
|
|
15577
|
+
]
|
|
15578
|
+
},
|
|
15579
|
+
conn.id
|
|
15580
|
+
)) })
|
|
15581
|
+
] }),
|
|
15582
|
+
data.connections.length === 0 && /* @__PURE__ */ jsx("div", { className: "flex flex-col items-center justify-center p-6 text-center", children: /* @__PURE__ */ jsx("p", { className: "text-xs text-muted-foreground", children: "Nenhuma conex\xE3o encontrada" }) })
|
|
15583
|
+
] })
|
|
15584
|
+
]
|
|
15585
|
+
},
|
|
15586
|
+
id
|
|
15587
|
+
) });
|
|
15588
|
+
};
|
|
15589
|
+
var SystemTooltip_default = SystemTooltip;
|
|
15305
15590
|
var Brush = ({
|
|
15306
15591
|
data,
|
|
15307
15592
|
legend,
|
|
@@ -15556,11 +15841,11 @@ var parseNumber = (v) => {
|
|
|
15556
15841
|
return Number(v);
|
|
15557
15842
|
return void 0;
|
|
15558
15843
|
};
|
|
15559
|
-
var renderPillLabel = (color, variant,
|
|
15844
|
+
var renderPillLabel = (color, variant, valueFormatter) => {
|
|
15560
15845
|
return (props) => {
|
|
15561
15846
|
const { x, y, value } = props;
|
|
15562
15847
|
const defaultFormatted = typeof value === "number" ? formatCompactNumber(value) : String(value ?? "");
|
|
15563
|
-
const text =
|
|
15848
|
+
const text = valueFormatter ? valueFormatter({
|
|
15564
15849
|
value,
|
|
15565
15850
|
formattedValue: defaultFormatted,
|
|
15566
15851
|
...props
|
|
@@ -15649,11 +15934,11 @@ var renderPillLabel = (color, variant, valueFormatter2) => {
|
|
|
15649
15934
|
};
|
|
15650
15935
|
};
|
|
15651
15936
|
var pillLabelRenderer_default = renderPillLabel;
|
|
15652
|
-
var renderInsideBarLabel = (color,
|
|
15937
|
+
var renderInsideBarLabel = (color, valueFormatter) => {
|
|
15653
15938
|
return (props) => {
|
|
15654
15939
|
const { x, y, value, width, height, viewBox, cx, cy, index } = props;
|
|
15655
15940
|
const defaultFormatted = typeof value === "number" ? formatCompactNumber(value) : String(value ?? "");
|
|
15656
|
-
const text =
|
|
15941
|
+
const text = valueFormatter ? valueFormatter({ value, formattedValue: defaultFormatted, ...props }) : defaultFormatted;
|
|
15657
15942
|
const parseNumberLocal = (v) => {
|
|
15658
15943
|
if (typeof v === "number") return v;
|
|
15659
15944
|
if (typeof v === "string" && v.trim() !== "" && !Number.isNaN(Number(v)))
|
|
@@ -15798,7 +16083,7 @@ var NoData = ({
|
|
|
15798
16083
|
"div",
|
|
15799
16084
|
{
|
|
15800
16085
|
className: cn(
|
|
15801
|
-
"rounded-xl bg-card relative overflow-hidden w-full border border-border/50 shadow-sm",
|
|
16086
|
+
"rounded-xl bg-card relative overflow-hidden w-full border border-border/50 shadow-sm h-full",
|
|
15802
16087
|
className
|
|
15803
16088
|
),
|
|
15804
16089
|
style: {
|
|
@@ -16255,6 +16540,128 @@ function useTimeSeriesRange({
|
|
|
16255
16540
|
handleMouseDown
|
|
16256
16541
|
};
|
|
16257
16542
|
}
|
|
16543
|
+
var filtersOrder = (mapperConfig, series) => {
|
|
16544
|
+
const seriesOrder = [];
|
|
16545
|
+
if (series) {
|
|
16546
|
+
if (series.bar)
|
|
16547
|
+
series.bar.forEach((k) => seriesOrder.push({ type: "bar", key: k }));
|
|
16548
|
+
if (series.line)
|
|
16549
|
+
series.line.forEach((k) => seriesOrder.push({ type: "line", key: k }));
|
|
16550
|
+
if (series.area)
|
|
16551
|
+
series.area.forEach((k) => seriesOrder.push({ type: "area", key: k }));
|
|
16552
|
+
} else {
|
|
16553
|
+
Object.keys(mapperConfig).forEach(
|
|
16554
|
+
(k) => seriesOrder.push({ type: "bar", key: k })
|
|
16555
|
+
);
|
|
16556
|
+
}
|
|
16557
|
+
return seriesOrder;
|
|
16558
|
+
};
|
|
16559
|
+
var fnOpenTooltipForPeriod = (enableDraggableTooltips, processedData, periodName, activeTooltips, setActiveTooltips, maxTooltips, effectiveChartWidth) => {
|
|
16560
|
+
if (!enableDraggableTooltips) return;
|
|
16561
|
+
const row = processedData.find((r) => String(r.name) === periodName);
|
|
16562
|
+
if (!row) return;
|
|
16563
|
+
const tooltipId = String(periodName);
|
|
16564
|
+
const existingIndex = activeTooltips.findIndex((t) => t.id === tooltipId);
|
|
16565
|
+
if (existingIndex !== -1) {
|
|
16566
|
+
setActiveTooltips((prev) => prev.filter((t) => t.id !== tooltipId));
|
|
16567
|
+
return;
|
|
16568
|
+
}
|
|
16569
|
+
if (activeTooltips.length >= maxTooltips) {
|
|
16570
|
+
toast$1.warning(
|
|
16571
|
+
`Limite de ${maxTooltips} janelas de informa\xE7\xE3o atingido. A mais antiga ser\xE1 substitu\xEDda.`
|
|
16572
|
+
);
|
|
16573
|
+
}
|
|
16574
|
+
const offsetIndex = activeTooltips.length;
|
|
16575
|
+
const availableWidth = effectiveChartWidth;
|
|
16576
|
+
const gap = 28;
|
|
16577
|
+
const leftGap = 28;
|
|
16578
|
+
const newTooltip = {
|
|
16579
|
+
id: tooltipId,
|
|
16580
|
+
data: row,
|
|
16581
|
+
position: {
|
|
16582
|
+
top: 48 + offsetIndex * gap,
|
|
16583
|
+
left: Math.max(120, availableWidth - 280 - offsetIndex * leftGap)
|
|
16584
|
+
}
|
|
16585
|
+
};
|
|
16586
|
+
setActiveTooltips((prev) => {
|
|
16587
|
+
const next = [...prev, newTooltip];
|
|
16588
|
+
return next.length > maxTooltips ? next.slice(1) : next;
|
|
16589
|
+
});
|
|
16590
|
+
};
|
|
16591
|
+
var fnSmartConfig = ({ xAxis, data, labelMap }) => {
|
|
16592
|
+
const resolvedXAxisKey = typeof xAxis === "string" ? xAxis : xAxis && xAxis.dataKey || detectXAxis(data);
|
|
16593
|
+
const xAxisConfig = typeof xAxis === "string" ? {
|
|
16594
|
+
dataKey: resolvedXAxisKey,
|
|
16595
|
+
label: formatFieldName(resolvedXAxisKey),
|
|
16596
|
+
autoLabel: true
|
|
16597
|
+
} : {
|
|
16598
|
+
dataKey: resolvedXAxisKey,
|
|
16599
|
+
label: xAxis?.label ?? formatFieldName(resolvedXAxisKey),
|
|
16600
|
+
valueFormatter: xAxis?.valueFormatter,
|
|
16601
|
+
autoLabel: xAxis?.autoLabel ?? true
|
|
16602
|
+
};
|
|
16603
|
+
const detectedFields = detectDataFields(data, xAxisConfig.dataKey);
|
|
16604
|
+
const mapperConfig = detectedFields.reduce((acc, field) => {
|
|
16605
|
+
acc[field] = {
|
|
16606
|
+
label: labelMap?.[field] ?? formatFieldName(field),
|
|
16607
|
+
type: "number",
|
|
16608
|
+
visible: true
|
|
16609
|
+
};
|
|
16610
|
+
return acc;
|
|
16611
|
+
}, {});
|
|
16612
|
+
return { xAxisConfig, mapperConfig };
|
|
16613
|
+
};
|
|
16614
|
+
var fnConfigRightKeys = (biaxialConfigNormalized, yTickFormatter, finalColors) => {
|
|
16615
|
+
const decimals = typeof biaxialConfigNormalized?.decimals === "number" ? Math.max(0, Math.floor(biaxialConfigNormalized.decimals)) : 2;
|
|
16616
|
+
const rightTickFormatter = (v) => {
|
|
16617
|
+
if (biaxialConfigNormalized?.percentage) {
|
|
16618
|
+
const num = Number(String(v));
|
|
16619
|
+
const nf = new Intl.NumberFormat("pt-BR", {
|
|
16620
|
+
minimumFractionDigits: decimals,
|
|
16621
|
+
maximumFractionDigits: decimals
|
|
16622
|
+
});
|
|
16623
|
+
const out = Number.isNaN(num) ? String(v ?? "") : nf.format(num);
|
|
16624
|
+
return `${out}%`;
|
|
16625
|
+
}
|
|
16626
|
+
return yTickFormatter(v);
|
|
16627
|
+
};
|
|
16628
|
+
const firstRightKey = biaxialConfigNormalized?.key && biaxialConfigNormalized.key[0];
|
|
16629
|
+
const defaultRightColor = firstRightKey && finalColors[firstRightKey] || "hsl(var(--muted-foreground))";
|
|
16630
|
+
const rightAxisColor = (() => {
|
|
16631
|
+
if (!biaxialConfigNormalized) return defaultRightColor;
|
|
16632
|
+
if (typeof biaxialConfigNormalized.stroke === "string")
|
|
16633
|
+
return biaxialConfigNormalized.stroke;
|
|
16634
|
+
if (biaxialConfigNormalized.stroke && firstRightKey && typeof biaxialConfigNormalized.stroke === "object")
|
|
16635
|
+
return biaxialConfigNormalized.stroke[firstRightKey] || defaultRightColor;
|
|
16636
|
+
return defaultRightColor;
|
|
16637
|
+
})();
|
|
16638
|
+
return { rightAxisColor, rightTickFormatter };
|
|
16639
|
+
};
|
|
16640
|
+
var fnFormatterValueLegend = (value, mapperConfig, labelMap, legendUppercase) => {
|
|
16641
|
+
const key = String(value);
|
|
16642
|
+
const label = mapperConfig[key]?.label ?? labelMap?.[key] ?? formatFieldName(key);
|
|
16643
|
+
return legendUppercase ? label.toUpperCase() : label;
|
|
16644
|
+
};
|
|
16645
|
+
var fnBuildConfigData = (s, mapperConfig, labelMap, finalColors, rightKeys, biaxialConfigNormalized) => {
|
|
16646
|
+
const key = s.key;
|
|
16647
|
+
const label = mapperConfig[key]?.label ?? labelMap?.[key] ?? formatFieldName(key);
|
|
16648
|
+
let color = finalColors[key];
|
|
16649
|
+
if (rightKeys.includes(key) && biaxialConfigNormalized?.stroke) {
|
|
16650
|
+
if (typeof biaxialConfigNormalized.stroke === "string") {
|
|
16651
|
+
color = biaxialConfigNormalized.stroke;
|
|
16652
|
+
} else {
|
|
16653
|
+
color = biaxialConfigNormalized.stroke[key] ?? color;
|
|
16654
|
+
}
|
|
16655
|
+
}
|
|
16656
|
+
return { label, color, key };
|
|
16657
|
+
};
|
|
16658
|
+
var fnContentLabelList = (p) => {
|
|
16659
|
+
const barHeight = typeof p.height === "number" ? p.height : typeof p.height === "string" ? Number(p.height) : 0;
|
|
16660
|
+
const barWidth = typeof p.width === "number" ? p.width : typeof p.width === "string" ? Number(p.width) : 0;
|
|
16661
|
+
const smallThreshold = 14;
|
|
16662
|
+
const needsOutside = barHeight > 0 && barHeight < smallThreshold || barWidth > 0 && barWidth < smallThreshold;
|
|
16663
|
+
return needsOutside ? null : true;
|
|
16664
|
+
};
|
|
16258
16665
|
var DEFAULT_COLORS2 = ["#55af7d", "#8e68ff", "#2273e1"];
|
|
16259
16666
|
var Chart = ({
|
|
16260
16667
|
data,
|
|
@@ -16276,7 +16683,7 @@ var Chart = ({
|
|
|
16276
16683
|
xAxisLabel,
|
|
16277
16684
|
yAxisLabel,
|
|
16278
16685
|
labelMap,
|
|
16279
|
-
valueFormatter
|
|
16686
|
+
valueFormatter,
|
|
16280
16687
|
categoryFormatter,
|
|
16281
16688
|
enableHighlights = false,
|
|
16282
16689
|
enableShowOnly = false,
|
|
@@ -16293,30 +16700,9 @@ var Chart = ({
|
|
|
16293
16700
|
timeSeriesLegend,
|
|
16294
16701
|
customLegend
|
|
16295
16702
|
}) => {
|
|
16296
|
-
const
|
|
16297
|
-
|
|
16298
|
-
const xAxisConfig2 = typeof xAxis === "string" ? {
|
|
16299
|
-
dataKey: resolvedXAxisKey,
|
|
16300
|
-
label: formatFieldName(resolvedXAxisKey),
|
|
16301
|
-
autoLabel: true
|
|
16302
|
-
} : {
|
|
16303
|
-
dataKey: resolvedXAxisKey,
|
|
16304
|
-
label: xAxis?.label ?? formatFieldName(resolvedXAxisKey),
|
|
16305
|
-
valueFormatter: xAxis?.valueFormatter,
|
|
16306
|
-
autoLabel: xAxis?.autoLabel ?? true
|
|
16307
|
-
};
|
|
16308
|
-
const detectedFields = detectDataFields(data, xAxisConfig2.dataKey);
|
|
16309
|
-
const mapperConfig2 = detectedFields.reduce((acc, field) => {
|
|
16310
|
-
acc[field] = {
|
|
16311
|
-
label: labelMap?.[field] ?? formatFieldName(field),
|
|
16312
|
-
type: "number",
|
|
16313
|
-
visible: true
|
|
16314
|
-
};
|
|
16315
|
-
return acc;
|
|
16316
|
-
}, {});
|
|
16317
|
-
return { xAxisConfig: xAxisConfig2, mapperConfig: mapperConfig2 };
|
|
16703
|
+
const { xAxisConfig, mapperConfig } = useMemo(() => {
|
|
16704
|
+
return fnSmartConfig({ xAxis, data, labelMap });
|
|
16318
16705
|
}, [data, xAxis, labelMap]);
|
|
16319
|
-
const { xAxisConfig, mapperConfig } = smartConfig;
|
|
16320
16706
|
const {
|
|
16321
16707
|
highlightedSeries,
|
|
16322
16708
|
showOnlyHighlighted,
|
|
@@ -16358,19 +16744,7 @@ var Chart = ({
|
|
|
16358
16744
|
}
|
|
16359
16745
|
return mapped;
|
|
16360
16746
|
}, [data, xAxisConfig.dataKey, timeSeriesConfig, startIndex, endIndex]);
|
|
16361
|
-
const seriesOrder =
|
|
16362
|
-
if (series) {
|
|
16363
|
-
if (series.bar)
|
|
16364
|
-
series.bar.forEach((k) => seriesOrder.push({ type: "bar", key: k }));
|
|
16365
|
-
if (series.line)
|
|
16366
|
-
series.line.forEach((k) => seriesOrder.push({ type: "line", key: k }));
|
|
16367
|
-
if (series.area)
|
|
16368
|
-
series.area.forEach((k) => seriesOrder.push({ type: "area", key: k }));
|
|
16369
|
-
} else {
|
|
16370
|
-
Object.keys(mapperConfig).forEach(
|
|
16371
|
-
(k) => seriesOrder.push({ type: "bar", key: k })
|
|
16372
|
-
);
|
|
16373
|
-
}
|
|
16747
|
+
const seriesOrder = filtersOrder(mapperConfig, series);
|
|
16374
16748
|
const allKeys = seriesOrder.map((s) => s.key).filter(Boolean);
|
|
16375
16749
|
const finalColors = useMemo(
|
|
16376
16750
|
() => generateColorMap(allKeys, colors2, mapperConfig),
|
|
@@ -16453,8 +16827,8 @@ var Chart = ({
|
|
|
16453
16827
|
[highlightedSeries]
|
|
16454
16828
|
);
|
|
16455
16829
|
const finalValueFormatter = useMemo(
|
|
16456
|
-
() => createValueFormatter(
|
|
16457
|
-
[
|
|
16830
|
+
() => createValueFormatter(valueFormatter, formatBR),
|
|
16831
|
+
[valueFormatter, formatBR]
|
|
16458
16832
|
);
|
|
16459
16833
|
const yTickFormatter = useMemo(
|
|
16460
16834
|
() => createYTickFormatter(finalValueFormatter),
|
|
@@ -16489,36 +16863,15 @@ var Chart = ({
|
|
|
16489
16863
|
const rightYAxisLabelDx = Math.max(12, Math.round(finalChartRightMargin / 2));
|
|
16490
16864
|
const openTooltipForPeriod = useCallback(
|
|
16491
16865
|
(periodName) => {
|
|
16492
|
-
|
|
16493
|
-
|
|
16494
|
-
|
|
16495
|
-
|
|
16496
|
-
|
|
16497
|
-
|
|
16498
|
-
|
|
16499
|
-
|
|
16500
|
-
|
|
16501
|
-
if (activeTooltips.length >= maxTooltips) {
|
|
16502
|
-
toast$1.warning(
|
|
16503
|
-
`Limite de ${maxTooltips} janelas de informa\xE7\xE3o atingido. A mais antiga ser\xE1 substitu\xEDda.`
|
|
16504
|
-
);
|
|
16505
|
-
}
|
|
16506
|
-
const offsetIndex = activeTooltips.length;
|
|
16507
|
-
const availableWidth = effectiveChartWidth;
|
|
16508
|
-
const gap = 28;
|
|
16509
|
-
const leftGap = 28;
|
|
16510
|
-
const newTooltip = {
|
|
16511
|
-
id: tooltipId,
|
|
16512
|
-
data: row,
|
|
16513
|
-
position: {
|
|
16514
|
-
top: 48 + offsetIndex * gap,
|
|
16515
|
-
left: Math.max(120, availableWidth - 280 - offsetIndex * leftGap)
|
|
16516
|
-
}
|
|
16517
|
-
};
|
|
16518
|
-
setActiveTooltips((prev) => {
|
|
16519
|
-
const next = [...prev, newTooltip];
|
|
16520
|
-
return next.length > maxTooltips ? next.slice(1) : next;
|
|
16521
|
-
});
|
|
16866
|
+
fnOpenTooltipForPeriod(
|
|
16867
|
+
enableDraggableTooltips,
|
|
16868
|
+
processedData,
|
|
16869
|
+
periodName,
|
|
16870
|
+
activeTooltips,
|
|
16871
|
+
setActiveTooltips,
|
|
16872
|
+
maxTooltips,
|
|
16873
|
+
effectiveChartWidth
|
|
16874
|
+
);
|
|
16522
16875
|
},
|
|
16523
16876
|
[
|
|
16524
16877
|
enableDraggableTooltips,
|
|
@@ -16757,29 +17110,7 @@ var Chart = ({
|
|
|
16757
17110
|
}
|
|
16758
17111
|
),
|
|
16759
17112
|
rightKeys.length > 0 && (() => {
|
|
16760
|
-
const
|
|
16761
|
-
const rightTickFormatter = (v) => {
|
|
16762
|
-
if (biaxialConfigNormalized?.percentage) {
|
|
16763
|
-
const num = Number(String(v));
|
|
16764
|
-
const nf = new Intl.NumberFormat("pt-BR", {
|
|
16765
|
-
minimumFractionDigits: decimals,
|
|
16766
|
-
maximumFractionDigits: decimals
|
|
16767
|
-
});
|
|
16768
|
-
const out = Number.isNaN(num) ? String(v ?? "") : nf.format(num);
|
|
16769
|
-
return `${out}%`;
|
|
16770
|
-
}
|
|
16771
|
-
return yTickFormatter(v);
|
|
16772
|
-
};
|
|
16773
|
-
const firstRightKey = biaxialConfigNormalized?.key && biaxialConfigNormalized.key[0];
|
|
16774
|
-
const defaultRightColor = firstRightKey && finalColors[firstRightKey] || "hsl(var(--muted-foreground))";
|
|
16775
|
-
const rightAxisColor = (() => {
|
|
16776
|
-
if (!biaxialConfigNormalized) return defaultRightColor;
|
|
16777
|
-
if (typeof biaxialConfigNormalized.stroke === "string")
|
|
16778
|
-
return biaxialConfigNormalized.stroke;
|
|
16779
|
-
if (biaxialConfigNormalized.stroke && firstRightKey && typeof biaxialConfigNormalized.stroke === "object")
|
|
16780
|
-
return biaxialConfigNormalized.stroke[firstRightKey] || defaultRightColor;
|
|
16781
|
-
return defaultRightColor;
|
|
16782
|
-
})();
|
|
17113
|
+
const { rightAxisColor, rightTickFormatter } = fnConfigRightKeys(biaxialConfigNormalized, yTickFormatter, finalColors);
|
|
16783
17114
|
return /* @__PURE__ */ jsx(
|
|
16784
17115
|
YAxis,
|
|
16785
17116
|
{
|
|
@@ -16837,38 +17168,26 @@ var Chart = ({
|
|
|
16837
17168
|
{
|
|
16838
17169
|
iconSize: 12,
|
|
16839
17170
|
formatter: (value) => {
|
|
16840
|
-
|
|
16841
|
-
|
|
16842
|
-
|
|
16843
|
-
|
|
16844
|
-
|
|
16845
|
-
|
|
16846
|
-
className: "inline-flex items-center gap-2 px-1 py-1.5",
|
|
16847
|
-
style: {
|
|
16848
|
-
fontSize: "13px",
|
|
16849
|
-
fontWeight: 600,
|
|
16850
|
-
letterSpacing: "0.01em",
|
|
16851
|
-
color: "hsl(var(--foreground))"
|
|
16852
|
-
},
|
|
16853
|
-
children: displayLabel
|
|
16854
|
-
}
|
|
16855
|
-
);
|
|
17171
|
+
return /* @__PURE__ */ jsx("span", { className: "tracking-[0]", children: fnFormatterValueLegend(
|
|
17172
|
+
value,
|
|
17173
|
+
mapperConfig,
|
|
17174
|
+
labelMap,
|
|
17175
|
+
legendUppercase
|
|
17176
|
+
) });
|
|
16856
17177
|
}
|
|
16857
17178
|
}
|
|
16858
17179
|
),
|
|
16859
17180
|
seriesOrder.map((s) => {
|
|
16860
|
-
|
|
16861
|
-
if (showOnlyHighlighted && !highlightedSeries.has(key))
|
|
17181
|
+
if (showOnlyHighlighted && !highlightedSeries.has(s.key))
|
|
16862
17182
|
return null;
|
|
16863
|
-
const label
|
|
16864
|
-
|
|
16865
|
-
|
|
16866
|
-
|
|
16867
|
-
|
|
16868
|
-
|
|
16869
|
-
|
|
16870
|
-
|
|
16871
|
-
}
|
|
17183
|
+
const { label, color, key } = fnBuildConfigData(
|
|
17184
|
+
s,
|
|
17185
|
+
mapperConfig,
|
|
17186
|
+
labelMap,
|
|
17187
|
+
finalColors,
|
|
17188
|
+
rightKeys,
|
|
17189
|
+
biaxialConfigNormalized
|
|
17190
|
+
);
|
|
16872
17191
|
if (s.type === "bar") {
|
|
16873
17192
|
return /* @__PURE__ */ jsx(
|
|
16874
17193
|
Bar,
|
|
@@ -16895,14 +17214,8 @@ var Chart = ({
|
|
|
16895
17214
|
{
|
|
16896
17215
|
dataKey: key,
|
|
16897
17216
|
content: (props) => {
|
|
16898
|
-
|
|
16899
|
-
const barHeight = typeof p.height === "number" ? p.height : typeof p.height === "string" ? Number(p.height) : 0;
|
|
16900
|
-
const barWidth = typeof p.width === "number" ? p.width : typeof p.width === "string" ? Number(p.width) : 0;
|
|
16901
|
-
const smallThreshold = 14;
|
|
16902
|
-
const needsOutside = barHeight > 0 && barHeight < smallThreshold || barWidth > 0 && barWidth < smallThreshold;
|
|
16903
|
-
if (needsOutside) {
|
|
17217
|
+
if (!fnContentLabelList(props))
|
|
16904
17218
|
return null;
|
|
16905
|
-
}
|
|
16906
17219
|
const inside = renderInsideBarLabel(
|
|
16907
17220
|
color,
|
|
16908
17221
|
finalValueFormatter
|
|
@@ -18426,8 +18739,7 @@ function Leaderboard({
|
|
|
18426
18739
|
title = "LeaderBoard",
|
|
18427
18740
|
className,
|
|
18428
18741
|
isLoading = false,
|
|
18429
|
-
legend
|
|
18430
|
-
best = false
|
|
18742
|
+
legend
|
|
18431
18743
|
}) {
|
|
18432
18744
|
const [order, setOrder] = useState(initialOrder);
|
|
18433
18745
|
const [searchTerm, setSearchTerm] = useState("");
|
|
@@ -18459,55 +18771,54 @@ function Leaderboard({
|
|
|
18459
18771
|
if (typeof aValue === "number") return order === "desc" ? -1 : 1;
|
|
18460
18772
|
return order === "desc" ? 1 : -1;
|
|
18461
18773
|
});
|
|
18462
|
-
const getBadgeColor = (value
|
|
18463
|
-
if (best) {
|
|
18464
|
-
const third = total / 3;
|
|
18465
|
-
if (best) {
|
|
18466
|
-
if (index < third) return "green";
|
|
18467
|
-
if (index < 2 * third) return "yellow";
|
|
18468
|
-
return "red";
|
|
18469
|
-
}
|
|
18470
|
-
}
|
|
18774
|
+
const getBadgeColor = (value) => {
|
|
18471
18775
|
const numValue = typeof value === "string" ? parseFloat(value) : value;
|
|
18472
18776
|
if (isNaN(numValue)) return "green";
|
|
18473
|
-
if (numValue
|
|
18474
|
-
if (numValue >=
|
|
18475
|
-
return "
|
|
18777
|
+
if (numValue > 100) return "green";
|
|
18778
|
+
if (numValue >= 95) return "yellow";
|
|
18779
|
+
return "red";
|
|
18476
18780
|
};
|
|
18477
18781
|
return /* @__PURE__ */ jsxs(
|
|
18478
18782
|
"div",
|
|
18479
18783
|
{
|
|
18480
|
-
className: `border rounded-xl flex flex-col max-h-80 w-
|
|
18784
|
+
className: `border rounded-xl flex flex-col max-h-80 w-[52rem] ${className}`,
|
|
18481
18785
|
children: [
|
|
18482
18786
|
/* @__PURE__ */ jsxs("div", { className: "flex items-center justify-between py-2 px-4 border-b flex-shrink-0 gap-3 ", children: [
|
|
18483
18787
|
/* @__PURE__ */ jsx("h2", { className: "text-lg font-semibold px-1 whitespace-nowrap", children: title }),
|
|
18484
|
-
/* @__PURE__ */
|
|
18485
|
-
|
|
18486
|
-
|
|
18487
|
-
|
|
18488
|
-
|
|
18489
|
-
|
|
18490
|
-
|
|
18491
|
-
|
|
18492
|
-
|
|
18493
|
-
|
|
18494
|
-
|
|
18495
|
-
|
|
18496
|
-
|
|
18497
|
-
|
|
18498
|
-
|
|
18499
|
-
|
|
18500
|
-
|
|
18501
|
-
|
|
18502
|
-
|
|
18503
|
-
|
|
18504
|
-
|
|
18505
|
-
|
|
18506
|
-
|
|
18507
|
-
|
|
18508
|
-
|
|
18509
|
-
|
|
18510
|
-
|
|
18788
|
+
/* @__PURE__ */ jsxs("div", { className: "flex items-center gap-2", children: [
|
|
18789
|
+
/* @__PURE__ */ jsx(
|
|
18790
|
+
InputBase,
|
|
18791
|
+
{
|
|
18792
|
+
value: searchTerm,
|
|
18793
|
+
onChange: (e) => {
|
|
18794
|
+
const value = e.target.value;
|
|
18795
|
+
if (/^[a-zA-Z0-9\s()À-ÿ~^´`]*$/.test(value)) {
|
|
18796
|
+
setSearchTerm(value);
|
|
18797
|
+
}
|
|
18798
|
+
},
|
|
18799
|
+
placeholder: "Pesquisar...",
|
|
18800
|
+
leftIcon: /* @__PURE__ */ jsx(MagnifyingGlassIcon, { size: 16 }),
|
|
18801
|
+
className: "h-8 py-1 w-24"
|
|
18802
|
+
}
|
|
18803
|
+
),
|
|
18804
|
+
/* @__PURE__ */ jsx(
|
|
18805
|
+
ButtonBase,
|
|
18806
|
+
{
|
|
18807
|
+
size: "icon",
|
|
18808
|
+
variant: "outline",
|
|
18809
|
+
onClick: () => setOrder(order === "desc" ? "asc" : "desc"),
|
|
18810
|
+
disabled: isLoading || sortedData.length === 0,
|
|
18811
|
+
children: /* @__PURE__ */ jsx(
|
|
18812
|
+
motion.div,
|
|
18813
|
+
{
|
|
18814
|
+
animate: { rotate: order === "asc" ? 180 : 0 },
|
|
18815
|
+
transition: { type: "spring", stiffness: 300, damping: 20 },
|
|
18816
|
+
children: /* @__PURE__ */ jsx(CaretUpDownIcon, {})
|
|
18817
|
+
}
|
|
18818
|
+
)
|
|
18819
|
+
}
|
|
18820
|
+
)
|
|
18821
|
+
] })
|
|
18511
18822
|
] }),
|
|
18512
18823
|
/* @__PURE__ */ jsx("div", { className: "overflow-y-auto flex-1 [&::-webkit-scrollbar]:w-1.5 [&::-webkit-scrollbar-track]:bg-transparent [&::-webkit-scrollbar-thumb]:bg-muted-foreground/20 [&::-webkit-scrollbar-thumb]:rounded-full hover:[&::-webkit-scrollbar-thumb]:bg-muted-foreground/40 transition-colors", children: isLoading ? /* @__PURE__ */ jsx("div", { className: "p-4 space-y-3", children: Array.from({ length: 5 }).map((_, idx) => /* @__PURE__ */ jsxs("div", { className: "flex items-center justify-between p-1", children: [
|
|
18513
18824
|
/* @__PURE__ */ jsxs("div", { className: "flex items-center gap-3 flex-1", children: [
|
|
@@ -18534,7 +18845,7 @@ function Leaderboard({
|
|
|
18534
18845
|
/* @__PURE__ */ jsx(
|
|
18535
18846
|
Badge,
|
|
18536
18847
|
{
|
|
18537
|
-
color: getBadgeColor(item.value
|
|
18848
|
+
color: getBadgeColor(item.value),
|
|
18538
18849
|
size: "md",
|
|
18539
18850
|
className: "font-bold",
|
|
18540
18851
|
children: item.value
|
|
@@ -18550,4 +18861,4 @@ function Leaderboard({
|
|
|
18550
18861
|
);
|
|
18551
18862
|
}
|
|
18552
18863
|
|
|
18553
|
-
export { AddButton, Agenda, AgendaDaysToShow, AgendaDaysToShowAgenda, AgendaView, AlertDialogActionBase, AlertDialogBase, AlertDialogCancelBase, AlertDialogContentBase, AlertDialogDescriptionBase, AlertDialogFooterBase, AlertDialogHeaderBase, AlertDialogOverlayBase, AlertDialogPortalBase, AlertDialogTitleBase, AlertDialogTriggerBase, AvatarBase, AvatarCombobox, AvatarFallbackBase, AvatarImageBase, BackButton, Badge, BarChart_default as BarChart, BreadcrumbBase, BreadcrumbEllipsisBase, BreadcrumbItemBase, BreadcrumbLinkBase, BreadcrumbListBase, BreadcrumbPageBase, BreadcrumbSeparatorBase, Brush_default as Brush, ButtonBase, ButtonGroupBase, CalendarBase, CalendarDndProvider, CalendarDndProviderAgenda, CardBase, CardContentBase, CardDescriptionBase, CardFooterBase, CardHeaderBase, CardTitleBase, CarouselBase, CarouselContentBase, CarouselItemBase, CarouselNextBase, CarouselPreviousBase, ChangeButton, Chart_default as Chart, ChartTotalLegend_default as ChartTotalLegend, CheckButton, CheckboxBase, CheckboxTree, CloseAllButton_default as CloseAllButton, CloseButton, CodeBlock, CollapsibleBase, CollapsibleContentBase, CollapsibleTriggerBase, Combobox, CommandBase, CommandDialogBase, CommandEmptyBase, CommandGroupBase, CommandInputBase, CommandItemBase, CommandListBase, CommandSeparatorBase, CommandShortcutBase, ContextMenuBase, ContextMenuCheckboxItemBase, ContextMenuContentBase, ContextMenuGroupBase, ContextMenuItemBase, ContextMenuLabelBase, ContextMenuPortalBase, ContextMenuRadioGroupBase, ContextMenuRadioItemBase, ContextMenuSeparatorBase, ContextMenuShortcutBase, ContextMenuSubBase, ContextMenuSubContentBase, ContextMenuSubTriggerBase, ContextMenuTriggerBase, CopyButton, DateTimePicker, DayView, DayViewAgenda, DebouncedInput, DefaultEndHour, DefaultEndHourAgenda, DefaultStartHour, DefaultStartHourAgenda, DestructiveDialog, DialogBase, DialogCloseBase, DialogContentBase, DialogDescriptionBase, DialogFooterBase, DialogHeaderBase, DialogOverlayBase, DialogPortalBase, DialogTitleBase, DialogTriggerBase, DownloadButton, DraggableEvent2 as DraggableEvent, DraggableTooltip_default as DraggableTooltip, DrawerBase, DrawerCloseBase, DrawerContentBase, DrawerDescriptionBase, DrawerFooterBase, DrawerHeaderBase, DrawerOverlayBase, DrawerPortalBase, DrawerTitleBase, DrawerTriggerBase, DropDownMenuBase, DropDownMenuCheckboxItemBase, DropDownMenuContentBase, DropDownMenuGroupBase, DropDownMenuItemBase, DropDownMenuLabelBase, DropDownMenuPortalBase, DropDownMenuRadioGroupBase, DropDownMenuRadioItemBase, DropDownMenuSeparatorBase, DropDownMenuShortcutBase, DropDownMenuSubBase, DropDownMenuSubContentBase, DropDownMenuSubTriggerBase, DropDownMenuTriggerBase, DroppableCell, DroppableCellAgenda, EditButton, EndHour, EndHourAgenda, ErrorMessage_default as ErrorMessage, EventAgenda, EventCalendar, EventDialog, EventGap, EventGapAgenda, EventHeight, EventHeightAgenda, EventItem, EventItemAgenda, EventsPopup, FavoriteButton, FileUploader, FilterButton, HideButton, Highlights_default as Highlights, HoverCardBase, HoverCardContentBase, HoverCardTriggerBase, InputBase, InputOTPBase, InputOTPGroupBase, InputOTPSeparatorBase, InputOTPSlotBase, LabelBase_default as LabelBase, Leaderboard, LikeButton, LineChart_default as LineChart, LoadingBase, LockButton, ModalBase, ModalCloseBase, ModalContentBase, ModalDescriptionBase, ModalFooterBase, ModalHeaderBase, ModalOverlayBase, ModalPortalBase, ModalTitleBase, ModalTriggerBase, ModeToggleBase, MonthView, MonthViewAgenda, MoreButton, MultiCombobox, MultiSelect, MultiSelectBase, MultiSelectContentBase, MultiSelectGroupBase, MultiSelectItemBase, MultiSelectSeparatorBase, MultiSelectTriggerBase, MultiSelectValueBase, NavigationMenuBase, NavigationMenuContentBase, NavigationMenuIndicatorBase, NavigationMenuItemBase, NavigationMenuLinkBase, NavigationMenuListBase, NavigationMenuTriggerBase, NavigationMenuViewportBase, NoData_default as NoData, NotificationButton, PeriodsDropdown_default as PeriodsDropdown, PieChart_default as PieChart, PopoverAnchorBase, PopoverBase, PopoverContentBase, PopoverTriggerBase, ProgressBase, ProgressCirclesBase, ProgressPanelsBase, ProgressSegmentsBase, RangePicker, RefreshButton, SaveButton, ScrollAreaBase, ScrollBarBase, SearchButton, Select, SelectBase, SelectContentBase, SelectGroupBase, SelectItemBase, SelectLabelBase, SelectScrollDownButtonBase, SelectScrollUpButtonBase, SelectSeparatorBase, SelectTriggerBase, SelectValueBase, SeparatorBase, SettingsButton, SheetBase, SheetCloseBase, SheetContentBase, SheetDescriptionBase, SheetFooterBase, SheetHeaderBase, SheetOverlayBase, SheetPortalBase, SheetTitleBase, SheetTriggerBase, ShowOnly_default as ShowOnly, SidebarBase, SidebarContentBase, SidebarFooterBase, SidebarGroupActionBase, SidebarGroupBase, SidebarGroupContentBase, SidebarGroupLabelBase, SidebarHeaderBase, SidebarInputBase, SidebarInsetBase, SidebarMenuActionBase, SidebarMenuBadgeBase, SidebarMenuBase, SidebarMenuButtonBase, SidebarMenuItemBase, SidebarMenuSkeletonBase, SidebarMenuSubBase, SidebarMenuSubButtonBase, SidebarMenuSubItemBase, SidebarProviderBase, SidebarRailBase, SidebarSeparatorBase, SidebarTriggerBase, SkeletonBase, SlideBase, StartHour, StartHourAgenda, StatusIndicator, SwitchBase, TableBase, TableBodyBase, TableCaptionBase, TableCellBase, TableFooterBase, TableHeadBase, TableHeaderBase, TableRowBase, TabsBase, TabsContentBase, TabsListBase, TabsTriggerBase, TextAreaBase, ThemeProviderBase, TimePicker, TimePickerInput, TimeSeries_default as TimeSeries, Toaster, TooltipBase, TooltipContentBase, TooltipProviderBase, TooltipSimple_default as TooltipSimple, TooltipTriggerBase, TooltipWithTotal_default as TooltipWithTotal, UndatedEvents, UniversalTooltipRenderer, UnlockButton, UploadButton, UseSideBarBase, ViewButton, VisibilityButton, WeekCellsHeight, WeekCellsHeightAgenda, WeekView, WeekViewAgenda, adaptDataForTooltip, addHoursToDate, addHoursToDateAgenda, addMinutesToDateAgenda, badgeVariants, buttonVariantsBase, compactTick, computeChartWidth, computeNiceMax, computeYAxisTickWidth, convert12HourTo24Hour, createValueFormatter, createYTickFormatter, detectDataFields, detectXAxis, display12HourValue, formatFieldName, generateAdditionalColors, generateColorMap, getAgendaEventsForDay, getAgendaEventsForDayAgenda, getAllEventsForDay, getAllEventsForDayAgenda, getArrowByType, getBorderRadiusClasses, getBorderRadiusClassesAgenda, getDateByType, getEventColorClasses, getEventColorClassesAgenda, getEventEndDate, getEventStartDate, getEventsForDay, getEventsForDayAgenda, getMaxDataValue, getMinDataValue, getSpanningEventsForDay, getSpanningEventsForDayAgenda, getValid12Hour, getValidArrow12Hour, getValidArrowHour, getValidArrowMinuteOrSecond, getValidArrowNumber, getValidHour, getValidMinuteOrSecond, getValidNumber, isMultiDayEvent, isMultiDayEventAgenda, isValid12Hour, isValidHour, isValidMinuteOrSecond, niceCeil, normalizeAttendDate, renderInsideBarLabel, pillLabelRenderer_default as renderPillLabel, resolveChartMargins, resolveContainerPaddingLeft, set12Hours, setDateByType, setHours, setMinutes, setSeconds, sortEvents, sortEventsAgenda, toast, useCalendarDnd, useCalendarDndAgenda, useChartClick, useChartDimensions, useChartHighlights, useChartTooltips, useCurrentTimeIndicator, useCurrentTimeIndicatorAgenda, useDrag, useEventVisibility, useEventVisibilityAgenda, useIsMobile, useTheme, useTimeSeriesRange, visualForItem };
|
|
18864
|
+
export { AddButton, Agenda, AgendaDaysToShow, AgendaDaysToShowAgenda, AgendaView, AlertDialogActionBase, AlertDialogBase, AlertDialogCancelBase, AlertDialogContentBase, AlertDialogDescriptionBase, AlertDialogFooterBase, AlertDialogHeaderBase, AlertDialogOverlayBase, AlertDialogPortalBase, AlertDialogTitleBase, AlertDialogTriggerBase, AvatarBase, AvatarCombobox, AvatarFallbackBase, AvatarImageBase, BackButton, Badge, BarChart_default as BarChart, BreadcrumbBase, BreadcrumbEllipsisBase, BreadcrumbItemBase, BreadcrumbLinkBase, BreadcrumbListBase, BreadcrumbPageBase, BreadcrumbSeparatorBase, Brush_default as Brush, ButtonBase, ButtonGroupBase, CalendarBase, CalendarDndProvider, CalendarDndProviderAgenda, CardBase, CardContentBase, CardDescriptionBase, CardFooterBase, CardHeaderBase, CardTitleBase, CarouselBase, CarouselContentBase, CarouselItemBase, CarouselNextBase, CarouselPreviousBase, ChangeButton, Chart_default as Chart, ChartTotalLegend_default as ChartTotalLegend, CheckButton, CheckboxBase, CheckboxTree, CloseAllButton_default as CloseAllButton, CloseButton, CodeBlock, CollapsibleBase, CollapsibleContentBase, CollapsibleTriggerBase, Combobox, CommandBase, CommandDialogBase, CommandEmptyBase, CommandGroupBase, CommandInputBase, CommandItemBase, CommandListBase, CommandSeparatorBase, CommandShortcutBase, ContextMenuBase, ContextMenuCheckboxItemBase, ContextMenuContentBase, ContextMenuGroupBase, ContextMenuItemBase, ContextMenuLabelBase, ContextMenuPortalBase, ContextMenuRadioGroupBase, ContextMenuRadioItemBase, ContextMenuSeparatorBase, ContextMenuShortcutBase, ContextMenuSubBase, ContextMenuSubContentBase, ContextMenuSubTriggerBase, ContextMenuTriggerBase, CopyButton, DateTimePicker, DayView, DayViewAgenda, DebouncedInput, DefaultEndHour, DefaultEndHourAgenda, DefaultStartHour, DefaultStartHourAgenda, DestructiveDialog, DialogBase, DialogCloseBase, DialogContentBase, DialogDescriptionBase, DialogFooterBase, DialogHeaderBase, DialogOverlayBase, DialogPortalBase, DialogTitleBase, DialogTriggerBase, DownloadButton, DraggableEvent2 as DraggableEvent, DraggableTooltip_default as DraggableTooltip, DrawerBase, DrawerCloseBase, DrawerContentBase, DrawerDescriptionBase, DrawerFooterBase, DrawerHeaderBase, DrawerOverlayBase, DrawerPortalBase, DrawerTitleBase, DrawerTriggerBase, DropDownMenuBase, DropDownMenuCheckboxItemBase, DropDownMenuContentBase, DropDownMenuGroupBase, DropDownMenuItemBase, DropDownMenuLabelBase, DropDownMenuPortalBase, DropDownMenuRadioGroupBase, DropDownMenuRadioItemBase, DropDownMenuSeparatorBase, DropDownMenuShortcutBase, DropDownMenuSubBase, DropDownMenuSubContentBase, DropDownMenuSubTriggerBase, DropDownMenuTriggerBase, DroppableCell, DroppableCellAgenda, EditButton, EndHour, EndHourAgenda, ErrorMessage_default as ErrorMessage, EventAgenda, EventCalendar, EventDialog, EventGap, EventGapAgenda, EventHeight, EventHeightAgenda, EventItem, EventItemAgenda, EventsPopup, FavoriteButton, FileUploader, FilterButton, HideButton, Highlights_default as Highlights, HoverCardBase, HoverCardContentBase, HoverCardTriggerBase, InputBase, InputOTPBase, InputOTPGroupBase, InputOTPSeparatorBase, InputOTPSlotBase, LabelBase_default as LabelBase, Leaderboard, LikeButton, LineChart_default as LineChart, LoadingBase, LockButton, ModalBase, ModalCloseBase, ModalContentBase, ModalDescriptionBase, ModalFooterBase, ModalHeaderBase, ModalOverlayBase, ModalPortalBase, ModalTitleBase, ModalTriggerBase, ModeToggleBase, MonthView, MonthViewAgenda, MoreButton, MultiCombobox, MultiSelect, MultiSelectBase, MultiSelectContentBase, MultiSelectGroupBase, MultiSelectItemBase, MultiSelectSeparatorBase, MultiSelectTriggerBase, MultiSelectValueBase, NavigationMenuBase, NavigationMenuContentBase, NavigationMenuIndicatorBase, NavigationMenuItemBase, NavigationMenuLinkBase, NavigationMenuListBase, NavigationMenuTriggerBase, NavigationMenuViewportBase, NoData_default as NoData, NotificationButton, PeriodsDropdown_default as PeriodsDropdown, PieChart_default as PieChart, PopoverAnchorBase, PopoverBase, PopoverContentBase, PopoverTriggerBase, ProgressBase, ProgressCirclesBase, ProgressPanelsBase, ProgressSegmentsBase, RangePicker, RefreshButton, SaveButton, ScrollAreaBase, ScrollBarBase, SearchButton, Select, SelectBase, SelectContentBase, SelectGroupBase, SelectItemBase, SelectLabelBase, SelectScrollDownButtonBase, SelectScrollUpButtonBase, SelectSeparatorBase, SelectTriggerBase, SelectValueBase, SeparatorBase, SettingsButton, SheetBase, SheetCloseBase, SheetContentBase, SheetDescriptionBase, SheetFooterBase, SheetHeaderBase, SheetOverlayBase, SheetPortalBase, SheetTitleBase, SheetTriggerBase, ShowOnly_default as ShowOnly, SidebarBase, SidebarContentBase, SidebarFooterBase, SidebarGroupActionBase, SidebarGroupBase, SidebarGroupContentBase, SidebarGroupLabelBase, SidebarHeaderBase, SidebarInputBase, SidebarInsetBase, SidebarMenuActionBase, SidebarMenuBadgeBase, SidebarMenuBase, SidebarMenuButtonBase, SidebarMenuItemBase, SidebarMenuSkeletonBase, SidebarMenuSubBase, SidebarMenuSubButtonBase, SidebarMenuSubItemBase, SidebarProviderBase, SidebarRailBase, SidebarSeparatorBase, SidebarTriggerBase, SkeletonBase, SlideBase, StartHour, StartHourAgenda, StatusIndicator, SwitchBase, SystemTooltip_default as SystemTooltip, TableBase, TableBodyBase, TableCaptionBase, TableCellBase, TableFooterBase, TableHeadBase, TableHeaderBase, TableRowBase, TabsBase, TabsContentBase, TabsListBase, TabsTriggerBase, TextAreaBase, ThemeProviderBase, TimePicker, TimePickerInput, TimeSeries_default as TimeSeries, Toaster, TooltipBase, TooltipContentBase, TooltipProviderBase, TooltipSimple_default as TooltipSimple, TooltipTriggerBase, TooltipWithTotal_default as TooltipWithTotal, UndatedEvents, UniversalTooltipRenderer, UnlockButton, UploadButton, UseSideBarBase, ViewButton, VisibilityButton, WeekCellsHeight, WeekCellsHeightAgenda, WeekView, WeekViewAgenda, adaptDataForTooltip, addHoursToDate, addHoursToDateAgenda, addMinutesToDateAgenda, badgeVariants, buttonVariantsBase, compactTick, computeChartWidth, computeNiceMax, computeYAxisTickWidth, convert12HourTo24Hour, createValueFormatter, createYTickFormatter, detectDataFields, detectXAxis, display12HourValue, formatFieldName, generateAdditionalColors, generateColorMap, getAgendaEventsForDay, getAgendaEventsForDayAgenda, getAllEventsForDay, getAllEventsForDayAgenda, getArrowByType, getBorderRadiusClasses, getBorderRadiusClassesAgenda, getDateByType, getEventColorClasses, getEventColorClassesAgenda, getEventEndDate, getEventStartDate, getEventsForDay, getEventsForDayAgenda, getMaxDataValue, getMinDataValue, getSpanningEventsForDay, getSpanningEventsForDayAgenda, getValid12Hour, getValidArrow12Hour, getValidArrowHour, getValidArrowMinuteOrSecond, getValidArrowNumber, getValidHour, getValidMinuteOrSecond, getValidNumber, isMultiDayEvent, isMultiDayEventAgenda, isValid12Hour, isValidHour, isValidMinuteOrSecond, niceCeil, normalizeAttendDate, renderInsideBarLabel, pillLabelRenderer_default as renderPillLabel, resolveChartMargins, resolveContainerPaddingLeft, set12Hours, setDateByType, setHours, setMinutes, setSeconds, sortEvents, sortEventsAgenda, toast, useCalendarDnd, useCalendarDndAgenda, useChartClick, useChartDimensions, useChartHighlights, useChartTooltips, useCurrentTimeIndicator, useCurrentTimeIndicatorAgenda, useDrag, useEventVisibility, useEventVisibilityAgenda, useIsMobile, useTheme, useTimeSeriesRange, visualForItem };
|