@mlw-packages/react-components 1.10.4 → 1.10.6
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 +66 -10
- package/dist/index.d.mts +46 -63
- package/dist/index.d.ts +46 -63
- package/dist/index.js +285 -290
- package/dist/index.mjs +287 -285
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1562,20 +1562,20 @@ var TooltipContentBase = React32__namespace.forwardRef(
|
|
|
1562
1562
|
id: "tooltip-content",
|
|
1563
1563
|
role: "tooltip",
|
|
1564
1564
|
className: cn(
|
|
1565
|
-
"z-50
|
|
1566
|
-
"shadow
|
|
1567
|
-
"animate-in fade-in-0 zoom-in-95 duration-
|
|
1568
|
-
"data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[state=closed]:duration-
|
|
1569
|
-
"data-[side=bottom]:slide-in-from-top-
|
|
1570
|
-
"data-[side=left]:slide-in-from-right-
|
|
1571
|
-
"data-[side=right]:slide-in-from-left-
|
|
1572
|
-
"data-[side=top]:slide-in-from-bottom-
|
|
1565
|
+
"z-50 rounded-lg bg-popover px-3 py-1.5 text-sm leading-snug text-popover-foreground",
|
|
1566
|
+
"[filter:drop-shadow(0_0_0.5px_hsl(var(--border)))_drop-shadow(0_4px_12px_hsl(var(--foreground)/0.08))]",
|
|
1567
|
+
"animate-in fade-in-0 zoom-in-95 duration-150 ease-out",
|
|
1568
|
+
"data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[state=closed]:duration-100",
|
|
1569
|
+
"data-[side=bottom]:slide-in-from-top-1.5",
|
|
1570
|
+
"data-[side=left]:slide-in-from-right-1.5",
|
|
1571
|
+
"data-[side=right]:slide-in-from-left-1.5",
|
|
1572
|
+
"data-[side=top]:slide-in-from-bottom-1.5",
|
|
1573
1573
|
className
|
|
1574
1574
|
),
|
|
1575
1575
|
...props,
|
|
1576
1576
|
children: [
|
|
1577
1577
|
props.children,
|
|
1578
|
-
/* @__PURE__ */ jsxRuntime.jsx(TooltipPrimitive__namespace.Arrow, { className: "fill-
|
|
1578
|
+
/* @__PURE__ */ jsxRuntime.jsx(TooltipPrimitive__namespace.Arrow, { className: "fill-popover h-2 w-3.5" })
|
|
1579
1579
|
]
|
|
1580
1580
|
}
|
|
1581
1581
|
) });
|
|
@@ -2792,7 +2792,7 @@ function MultiSelectValueBase({
|
|
|
2792
2792
|
...props,
|
|
2793
2793
|
ref: handleResize,
|
|
2794
2794
|
className: cn(
|
|
2795
|
-
"flex w-full gap-1.5 overflow-hidden",
|
|
2795
|
+
"flex flex-1 w-full gap-1.5 overflow-hidden min-w-0",
|
|
2796
2796
|
shouldWrap && "h-full flex-wrap",
|
|
2797
2797
|
className
|
|
2798
2798
|
),
|
|
@@ -3810,7 +3810,7 @@ var FileUploader = React32__namespace.forwardRef(
|
|
|
3810
3810
|
showPreview = true,
|
|
3811
3811
|
dropzoneText = "Arraste arquivos aqui ou clique para selecionar",
|
|
3812
3812
|
dropzoneSubtext,
|
|
3813
|
-
animate = true,
|
|
3813
|
+
animate: animate2 = true,
|
|
3814
3814
|
...props
|
|
3815
3815
|
}, ref) => {
|
|
3816
3816
|
const [isDragging, setIsDragging] = React32__namespace.useState(false);
|
|
@@ -3963,7 +3963,7 @@ var FileUploader = React32__namespace.forwardRef(
|
|
|
3963
3963
|
framerMotion.motion.p,
|
|
3964
3964
|
{
|
|
3965
3965
|
className: "mb-2 text-xs font-semibold text-foreground",
|
|
3966
|
-
initial:
|
|
3966
|
+
initial: animate2 ? { opacity: 0, y: -10 } : false,
|
|
3967
3967
|
animate: { opacity: 1, y: 0 },
|
|
3968
3968
|
transition: { delay: 0.1 },
|
|
3969
3969
|
children: dropzoneText
|
|
@@ -3973,7 +3973,7 @@ var FileUploader = React32__namespace.forwardRef(
|
|
|
3973
3973
|
framerMotion.motion.p,
|
|
3974
3974
|
{
|
|
3975
3975
|
className: "text-xs text-muted-foreground",
|
|
3976
|
-
initial:
|
|
3976
|
+
initial: animate2 ? { opacity: 0, y: -10 } : false,
|
|
3977
3977
|
animate: { opacity: 1, y: 0 },
|
|
3978
3978
|
transition: { delay: 0.2 },
|
|
3979
3979
|
children: defaultSubtext
|
|
@@ -3983,7 +3983,7 @@ var FileUploader = React32__namespace.forwardRef(
|
|
|
3983
3983
|
framerMotion.motion.div,
|
|
3984
3984
|
{
|
|
3985
3985
|
className: "py-2 w-full",
|
|
3986
|
-
initial:
|
|
3986
|
+
initial: animate2 ? { opacity: 0, y: 10 } : false,
|
|
3987
3987
|
animate: { opacity: 1, y: 0 },
|
|
3988
3988
|
transition: { delay: 0.3 },
|
|
3989
3989
|
children: [
|
|
@@ -3998,7 +3998,7 @@ var FileUploader = React32__namespace.forwardRef(
|
|
|
3998
3998
|
framerMotion.motion.div,
|
|
3999
3999
|
{
|
|
4000
4000
|
layout: true,
|
|
4001
|
-
initial:
|
|
4001
|
+
initial: animate2 ? { opacity: 0, x: -20 } : false,
|
|
4002
4002
|
animate: { opacity: 1, x: 0 },
|
|
4003
4003
|
exit: {
|
|
4004
4004
|
opacity: 0,
|
|
@@ -4006,7 +4006,7 @@ var FileUploader = React32__namespace.forwardRef(
|
|
|
4006
4006
|
transition: { duration: 0.2 }
|
|
4007
4007
|
},
|
|
4008
4008
|
transition: {
|
|
4009
|
-
delay:
|
|
4009
|
+
delay: animate2 ? index * 0.05 : 0,
|
|
4010
4010
|
layout: { duration: 0.2 }
|
|
4011
4011
|
},
|
|
4012
4012
|
className: cn(
|
|
@@ -16242,11 +16242,12 @@ var SystemTooltip = ({
|
|
|
16242
16242
|
isLoading = false,
|
|
16243
16243
|
onMouseDown,
|
|
16244
16244
|
onClose,
|
|
16245
|
-
onPositionChange
|
|
16245
|
+
onPositionChange,
|
|
16246
|
+
onConnectionClick,
|
|
16247
|
+
onProcessClick
|
|
16246
16248
|
}) => {
|
|
16247
16249
|
const [localPos, setLocalPos] = React32.useState(position);
|
|
16248
16250
|
const [dragging, setDragging] = React32.useState(false);
|
|
16249
|
-
const [expandedId, setExpandedId] = React32.useState(null);
|
|
16250
16251
|
const offsetRef = React32.useRef({ x: 0, y: 0 });
|
|
16251
16252
|
const lastMouse = React32.useRef({ x: 0, y: 0 });
|
|
16252
16253
|
React32.useEffect(() => setLocalPos(position), [position]);
|
|
@@ -16317,6 +16318,19 @@ var SystemTooltip = ({
|
|
|
16317
16318
|
},
|
|
16318
16319
|
[id, onMouseDown]
|
|
16319
16320
|
);
|
|
16321
|
+
const handleConnClick = React32.useCallback(
|
|
16322
|
+
(e, conn) => {
|
|
16323
|
+
e.stopPropagation();
|
|
16324
|
+
const rect = e.currentTarget.getBoundingClientRect();
|
|
16325
|
+
const pos = { x: rect.right + 8, y: rect.top };
|
|
16326
|
+
if (conn.integration?.Nome) {
|
|
16327
|
+
onProcessClick?.(conn, pos);
|
|
16328
|
+
} else {
|
|
16329
|
+
onConnectionClick?.(conn, pos);
|
|
16330
|
+
}
|
|
16331
|
+
},
|
|
16332
|
+
[onConnectionClick, onProcessClick]
|
|
16333
|
+
);
|
|
16320
16334
|
const entries = React32.useMemo(
|
|
16321
16335
|
() => data.connections.filter((c) => c.type === "entrada"),
|
|
16322
16336
|
[data.connections]
|
|
@@ -16325,6 +16339,28 @@ var SystemTooltip = ({
|
|
|
16325
16339
|
() => data.connections.filter((c) => c.type === "saida"),
|
|
16326
16340
|
[data.connections]
|
|
16327
16341
|
);
|
|
16342
|
+
const renderConnections = (connections, color) => {
|
|
16343
|
+
const isEmerald = color === "emerald";
|
|
16344
|
+
return connections.map((conn) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
16345
|
+
"div",
|
|
16346
|
+
{
|
|
16347
|
+
className: `group flex items-center justify-between p-2 rounded-lg cursor-pointer transition-all
|
|
16348
|
+
${isEmerald ? "bg-emerald-500/5 border border-emerald-500/10 hover:border-emerald-500/30" : "bg-blue-500/5 border border-blue-500/10 hover:border-blue-500/30"}`,
|
|
16349
|
+
onClick: (e) => handleConnClick(e, conn),
|
|
16350
|
+
children: [
|
|
16351
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center gap-2 overflow-hidden", children: /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-sm font-medium truncate", children: conn.name }) }),
|
|
16352
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
16353
|
+
react.ArrowRightIcon,
|
|
16354
|
+
{
|
|
16355
|
+
size: 14,
|
|
16356
|
+
className: `shrink-0 ${isEmerald ? "text-emerald-500 rotate-180" : "text-blue-500"}`
|
|
16357
|
+
}
|
|
16358
|
+
)
|
|
16359
|
+
]
|
|
16360
|
+
},
|
|
16361
|
+
conn.id
|
|
16362
|
+
));
|
|
16363
|
+
};
|
|
16328
16364
|
return /* @__PURE__ */ jsxRuntime.jsx(framerMotion.AnimatePresence, { children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
16329
16365
|
framerMotion.motion.div,
|
|
16330
16366
|
{
|
|
@@ -16342,7 +16378,7 @@ var SystemTooltip = ({
|
|
|
16342
16378
|
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
16343
16379
|
"div",
|
|
16344
16380
|
{
|
|
16345
|
-
className: "flex items-center justify-between py-1 border-b border-border/10 bg-muted/30
|
|
16381
|
+
className: "flex items-center justify-between py-1 border-b border-border/10 bg-muted/30",
|
|
16346
16382
|
onMouseDown: handleMouseDownLocal,
|
|
16347
16383
|
onTouchStart: handleTouchStartLocal,
|
|
16348
16384
|
style: {
|
|
@@ -16362,7 +16398,7 @@ var SystemTooltip = ({
|
|
|
16362
16398
|
onClick: () => onClose(id),
|
|
16363
16399
|
className: "text-muted-foreground hover:text-destructive transition-colors hover:bg-destructive/10 mr-1",
|
|
16364
16400
|
style: { cursor: "pointer" },
|
|
16365
|
-
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
16401
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(react.XIcon, { size: 16 })
|
|
16366
16402
|
}
|
|
16367
16403
|
)
|
|
16368
16404
|
]
|
|
@@ -16375,7 +16411,7 @@ var SystemTooltip = ({
|
|
|
16375
16411
|
/* @__PURE__ */ jsxRuntime.jsx("h3", { className: "text-xl font-bold text-foreground tracking-tight truncate", children: data.name }),
|
|
16376
16412
|
data.description && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-sm text-muted-foreground tracking-tight truncate", children: data.description })
|
|
16377
16413
|
] }) }),
|
|
16378
|
-
/* @__PURE__ */ jsxRuntime.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: [
|
|
16414
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "px-3 pb-4 space-y-4 max-h-[300px] overflow-y-auto [&::-webkit-scrollbar]:w-1 [&::-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: [
|
|
16379
16415
|
/* @__PURE__ */ jsxRuntime.jsx(SeparatorBase, { className: "w-full" }),
|
|
16380
16416
|
isLoading ? /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
16381
16417
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-2", children: [
|
|
@@ -16398,128 +16434,14 @@ var SystemTooltip = ({
|
|
|
16398
16434
|
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-1.5 h-1.5 rounded-full bg-emerald-500" }),
|
|
16399
16435
|
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-[10px] font-bold text-muted-foreground uppercase", children: "Entradas" })
|
|
16400
16436
|
] }),
|
|
16401
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "space-y-1", children: entries
|
|
16402
|
-
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
16403
|
-
"div",
|
|
16404
|
-
{
|
|
16405
|
-
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 cursor-pointer",
|
|
16406
|
-
onClick: () => setExpandedId(
|
|
16407
|
-
expandedId === conn.id ? null : conn.id
|
|
16408
|
-
),
|
|
16409
|
-
children: [
|
|
16410
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center gap-2 overflow-hidden", children: /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-sm font-medium truncate", children: conn.name }) }),
|
|
16411
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
16412
|
-
react.ArrowRight,
|
|
16413
|
-
{
|
|
16414
|
-
size: 14,
|
|
16415
|
-
className: "text-emerald-500 shrink-0 rotate-180"
|
|
16416
|
-
}
|
|
16417
|
-
)
|
|
16418
|
-
]
|
|
16419
|
-
}
|
|
16420
|
-
),
|
|
16421
|
-
expandedId === conn.id && conn.integration && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "ml-2 p-2 rounded-lg bg-muted/30 border border-border/20 text-xs space-y-1", children: [
|
|
16422
|
-
conn.integration.Nome && /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
|
|
16423
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "font-semibold", children: "Nome:" }),
|
|
16424
|
-
" ",
|
|
16425
|
-
conn.integration.Nome
|
|
16426
|
-
] }),
|
|
16427
|
-
(conn.integration.tipo || conn.integration.Tipo) && /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
|
|
16428
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "font-semibold", children: "Tipo:" }),
|
|
16429
|
-
" ",
|
|
16430
|
-
conn.integration.tipo || conn.integration.Tipo
|
|
16431
|
-
] }),
|
|
16432
|
-
conn.integration.Protocolos && /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
|
|
16433
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "font-semibold", children: "Protocolos:" }),
|
|
16434
|
-
" ",
|
|
16435
|
-
conn.integration.Protocolos
|
|
16436
|
-
] }),
|
|
16437
|
-
conn.integration.Ambiente && /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
|
|
16438
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "font-semibold", children: "Ambiente:" }),
|
|
16439
|
-
" ",
|
|
16440
|
-
conn.integration.Ambiente
|
|
16441
|
-
] }),
|
|
16442
|
-
conn.integration.Setor && /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
|
|
16443
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "font-semibold", children: "Setor:" }),
|
|
16444
|
-
" ",
|
|
16445
|
-
conn.integration.Setor
|
|
16446
|
-
] }),
|
|
16447
|
-
conn.integration.Contato && /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
|
|
16448
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "font-semibold", children: "Contato:" }),
|
|
16449
|
-
" ",
|
|
16450
|
-
conn.integration.Contato
|
|
16451
|
-
] }),
|
|
16452
|
-
conn.integration.Sustentacao && /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
|
|
16453
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "font-semibold", children: "Sustenta\xE7\xE3o:" }),
|
|
16454
|
-
" ",
|
|
16455
|
-
conn.integration.Sustentacao
|
|
16456
|
-
] })
|
|
16457
|
-
] })
|
|
16458
|
-
] }, conn.id)) })
|
|
16437
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "space-y-1", children: renderConnections(entries, "emerald") })
|
|
16459
16438
|
] }),
|
|
16460
16439
|
exits.length > 0 && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-2", children: [
|
|
16461
16440
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2 px-1", children: [
|
|
16462
16441
|
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-1.5 h-1.5 rounded-full bg-blue-500" }),
|
|
16463
16442
|
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-[10px] font-bold text-muted-foreground uppercase", children: "Sa\xEDdas" })
|
|
16464
16443
|
] }),
|
|
16465
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "space-y-1", children: exits
|
|
16466
|
-
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
16467
|
-
"div",
|
|
16468
|
-
{
|
|
16469
|
-
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 cursor-pointer",
|
|
16470
|
-
onClick: () => setExpandedId(
|
|
16471
|
-
expandedId === conn.id ? null : conn.id
|
|
16472
|
-
),
|
|
16473
|
-
children: [
|
|
16474
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center gap-2 overflow-hidden", children: /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-sm font-medium truncate", children: conn.name }) }),
|
|
16475
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
16476
|
-
react.ArrowRight,
|
|
16477
|
-
{
|
|
16478
|
-
size: 14,
|
|
16479
|
-
className: "text-blue-500 shrink-0"
|
|
16480
|
-
}
|
|
16481
|
-
)
|
|
16482
|
-
]
|
|
16483
|
-
}
|
|
16484
|
-
),
|
|
16485
|
-
expandedId === conn.id && conn.integration && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "ml-2 p-2 rounded-lg bg-muted/30 border border-border/20 text-xs space-y-1", children: [
|
|
16486
|
-
conn.integration.Nome && /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
|
|
16487
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "font-semibold", children: "Nome:" }),
|
|
16488
|
-
" ",
|
|
16489
|
-
conn.integration.Nome
|
|
16490
|
-
] }),
|
|
16491
|
-
(conn.integration.tipo || conn.integration.Tipo) && /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
|
|
16492
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "font-semibold", children: "Tipo:" }),
|
|
16493
|
-
" ",
|
|
16494
|
-
conn.integration.tipo || conn.integration.Tipo
|
|
16495
|
-
] }),
|
|
16496
|
-
conn.integration.Protocolos && /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
|
|
16497
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "font-semibold", children: "Protocolos:" }),
|
|
16498
|
-
" ",
|
|
16499
|
-
conn.integration.Protocolos
|
|
16500
|
-
] }),
|
|
16501
|
-
conn.integration.Ambiente && /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
|
|
16502
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "font-semibold", children: "Ambiente:" }),
|
|
16503
|
-
" ",
|
|
16504
|
-
conn.integration.Ambiente
|
|
16505
|
-
] }),
|
|
16506
|
-
conn.integration.Setor && /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
|
|
16507
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "font-semibold", children: "Setor:" }),
|
|
16508
|
-
" ",
|
|
16509
|
-
conn.integration.Setor
|
|
16510
|
-
] }),
|
|
16511
|
-
conn.integration.Contato && /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
|
|
16512
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "font-semibold", children: "Contato:" }),
|
|
16513
|
-
" ",
|
|
16514
|
-
conn.integration.Contato
|
|
16515
|
-
] }),
|
|
16516
|
-
conn.integration.Sustentacao && /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
|
|
16517
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "font-semibold", children: "Sustenta\xE7\xE3o:" }),
|
|
16518
|
-
" ",
|
|
16519
|
-
conn.integration.Sustentacao
|
|
16520
|
-
] })
|
|
16521
|
-
] })
|
|
16522
|
-
] }, conn.id)) })
|
|
16444
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "space-y-1", children: renderConnections(exits, "blue") })
|
|
16523
16445
|
] }),
|
|
16524
16446
|
data.connections.length === 0 && !isLoading && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex flex-col items-center justify-center p-6 text-center", children: /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-xs text-muted-foreground", children: "Nenhuma conex\xE3o encontrada" }) })
|
|
16525
16447
|
] })
|
|
@@ -16543,6 +16465,78 @@ var useIsTruncated = (ref) => {
|
|
|
16543
16465
|
}, [ref]);
|
|
16544
16466
|
return truncated;
|
|
16545
16467
|
};
|
|
16468
|
+
var CopyData = ({ value }) => {
|
|
16469
|
+
const [copied, setCopied] = React32.useState(false);
|
|
16470
|
+
const handleCopy = React32.useCallback(() => {
|
|
16471
|
+
navigator.clipboard.writeText(value).then(() => {
|
|
16472
|
+
setCopied(true);
|
|
16473
|
+
setTimeout(() => setCopied(false), 1500);
|
|
16474
|
+
});
|
|
16475
|
+
}, [value]);
|
|
16476
|
+
return /* @__PURE__ */ jsxRuntime.jsx(TooltipProviderBase, { children: /* @__PURE__ */ jsxRuntime.jsxs(TooltipBase, { children: [
|
|
16477
|
+
/* @__PURE__ */ jsxRuntime.jsx(TooltipTriggerBase, { asChild: true, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
16478
|
+
"button",
|
|
16479
|
+
{
|
|
16480
|
+
onClick: handleCopy,
|
|
16481
|
+
className: "shrink-0 p-0.5 rounded transition-colors text-muted-foreground/40 hover:text-foreground hover:bg-muted",
|
|
16482
|
+
style: { cursor: "pointer" },
|
|
16483
|
+
children: copied ? /* @__PURE__ */ jsxRuntime.jsx(react.CheckIcon, {}) : /* @__PURE__ */ jsxRuntime.jsx(react.CopyIcon, {})
|
|
16484
|
+
}
|
|
16485
|
+
) }),
|
|
16486
|
+
/* @__PURE__ */ jsxRuntime.jsx(TooltipContentBase, { sideOffset: 6, className: "z-[10001]", children: copied ? "Copiado!" : "Copiar" })
|
|
16487
|
+
] }) });
|
|
16488
|
+
};
|
|
16489
|
+
var propertyLabels = {
|
|
16490
|
+
Nome: "Nome",
|
|
16491
|
+
tipo: "Tipo",
|
|
16492
|
+
Tipo: "Tipo",
|
|
16493
|
+
Protocolos: "Protocolos",
|
|
16494
|
+
Ambiente: "Ambiente",
|
|
16495
|
+
Setor: "Setor",
|
|
16496
|
+
Contato: "Contato",
|
|
16497
|
+
Sustentacao: "Sustenta\xE7\xE3o",
|
|
16498
|
+
Destino: "Destino",
|
|
16499
|
+
Origem: "Origem"
|
|
16500
|
+
};
|
|
16501
|
+
var IntegrationCard = ({ title, details }) => {
|
|
16502
|
+
const titleRef = React32.useRef(null);
|
|
16503
|
+
const isTitleTruncated = useIsTruncated(titleRef);
|
|
16504
|
+
const blackList = ["id", "elementId", "identity"];
|
|
16505
|
+
const entries = details ? Object.entries(details).filter(
|
|
16506
|
+
([key, value]) => value !== void 0 && value !== null && value !== "" && !blackList.includes(key)
|
|
16507
|
+
) : [];
|
|
16508
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "rounded-lg border border-border/40 bg-muted/20 overflow-hidden", children: [
|
|
16509
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2 px-3 py-2 border-b border-border/30", children: [
|
|
16510
|
+
/* @__PURE__ */ jsxRuntime.jsx(TooltipProviderBase, { children: /* @__PURE__ */ jsxRuntime.jsxs(TooltipBase, { children: [
|
|
16511
|
+
/* @__PURE__ */ jsxRuntime.jsx(TooltipTriggerBase, { asChild: true, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
16512
|
+
"span",
|
|
16513
|
+
{
|
|
16514
|
+
ref: titleRef,
|
|
16515
|
+
className: "text-sm font-bold text-foreground truncate flex-1 min-w-0 cursor-default",
|
|
16516
|
+
children: title
|
|
16517
|
+
}
|
|
16518
|
+
) }),
|
|
16519
|
+
isTitleTruncated && /* @__PURE__ */ jsxRuntime.jsx(TooltipContentBase, { sideOffset: 6, className: "z-[10001]", children: title })
|
|
16520
|
+
] }) }),
|
|
16521
|
+
entries.length > 0 && /* @__PURE__ */ jsxRuntime.jsx(
|
|
16522
|
+
CopyData,
|
|
16523
|
+
{
|
|
16524
|
+
value: entries.map(([k, v]) => `${propertyLabels[k] || k}: ${String(v)}`).join("\n")
|
|
16525
|
+
}
|
|
16526
|
+
)
|
|
16527
|
+
] }),
|
|
16528
|
+
entries.length > 0 && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "divide-y divide-border/20 px-0.5", children: entries.map(([key, value]) => {
|
|
16529
|
+
const label = propertyLabels[key] || key;
|
|
16530
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2 px-3 py-1.5", children: [
|
|
16531
|
+
/* @__PURE__ */ jsxRuntime.jsxs("span", { className: "text-xs font-semibold text-muted-foreground shrink-0 w-[40%] sm:w-[38%]", children: [
|
|
16532
|
+
label,
|
|
16533
|
+
":"
|
|
16534
|
+
] }),
|
|
16535
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-xs text-foreground break-all flex-1 min-w-0", children: String(value) })
|
|
16536
|
+
] }, key);
|
|
16537
|
+
}) })
|
|
16538
|
+
] });
|
|
16539
|
+
};
|
|
16546
16540
|
var NameTooltip = ({
|
|
16547
16541
|
name,
|
|
16548
16542
|
description
|
|
@@ -16553,7 +16547,7 @@ var NameTooltip = ({
|
|
|
16553
16547
|
const isDescTruncated = useIsTruncated(descRef);
|
|
16554
16548
|
const showTooltip = isNameTruncated || isDescTruncated;
|
|
16555
16549
|
return /* @__PURE__ */ jsxRuntime.jsx(TooltipProviderBase, { children: /* @__PURE__ */ jsxRuntime.jsxs(TooltipBase, { children: [
|
|
16556
|
-
/* @__PURE__ */ jsxRuntime.jsx(TooltipTriggerBase, { asChild: true, children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "cursor-default", children: [
|
|
16550
|
+
/* @__PURE__ */ jsxRuntime.jsx(TooltipTriggerBase, { asChild: true, children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "cursor-default min-w-0", children: [
|
|
16557
16551
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
16558
16552
|
"h3",
|
|
16559
16553
|
{
|
|
@@ -16580,7 +16574,7 @@ var NameTooltip = ({
|
|
|
16580
16574
|
var SystemNode = ({ label }) => {
|
|
16581
16575
|
const truncated = label.length > 9 ? label.substring(0, 9) + "\u2026" : label;
|
|
16582
16576
|
const needsTooltip = label.length > 9;
|
|
16583
|
-
const circle = /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-[76px] h-[76px] rounded-full bg-primary flex items-center justify-center shrink-0 z-10 cursor-default", children: /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-[10px] font-bold text-primary-foreground text-center px-2 leading-tight select-none", children: truncated }) });
|
|
16577
|
+
const circle = /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-[76px] h-[76px] rounded-full bg-primary flex items-center justify-center shrink-0 z-10 cursor-default max-w-xs", children: /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-[10px] font-bold text-primary-foreground text-center px-2 leading-tight select-none", children: truncated }) });
|
|
16584
16578
|
if (!needsTooltip) return circle;
|
|
16585
16579
|
return /* @__PURE__ */ jsxRuntime.jsx(TooltipProviderBase, { children: /* @__PURE__ */ jsxRuntime.jsxs(TooltipBase, { children: [
|
|
16586
16580
|
/* @__PURE__ */ jsxRuntime.jsx(TooltipTriggerBase, { asChild: true, children: circle }),
|
|
@@ -16627,14 +16621,13 @@ var Beam = ({ isInput, containerRef, leftRef, rightRef }) => {
|
|
|
16627
16621
|
if (leftRef.current) ro.observe(leftRef.current);
|
|
16628
16622
|
if (rightRef.current) ro.observe(rightRef.current);
|
|
16629
16623
|
const mo = new MutationObserver(schedule);
|
|
16630
|
-
|
|
16631
|
-
|
|
16632
|
-
|
|
16633
|
-
|
|
16634
|
-
|
|
16635
|
-
|
|
16636
|
-
|
|
16637
|
-
});
|
|
16624
|
+
if (containerRef.current) {
|
|
16625
|
+
mo.observe(containerRef.current, {
|
|
16626
|
+
attributes: true,
|
|
16627
|
+
attributeFilter: ["class", "style"],
|
|
16628
|
+
subtree: true
|
|
16629
|
+
});
|
|
16630
|
+
}
|
|
16638
16631
|
return () => {
|
|
16639
16632
|
cancelAnimationFrame(rafId);
|
|
16640
16633
|
ro.disconnect();
|
|
@@ -16647,7 +16640,7 @@ var Beam = ({ isInput, containerRef, leftRef, rightRef }) => {
|
|
|
16647
16640
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
16648
16641
|
"svg",
|
|
16649
16642
|
{
|
|
16650
|
-
className: "pointer-events-none absolute left-0 top-0",
|
|
16643
|
+
className: "pointer-events-none absolute left-0 top-0 right-0",
|
|
16651
16644
|
width: svgSize.w,
|
|
16652
16645
|
height: svgSize.h,
|
|
16653
16646
|
fill: "none",
|
|
@@ -16712,7 +16705,7 @@ var SystemsDiagram = ({ isInput, currentSystem, externalSystem }) => {
|
|
|
16712
16705
|
"div",
|
|
16713
16706
|
{
|
|
16714
16707
|
ref: containerRef,
|
|
16715
|
-
className: "relative flex items-center justify-between py-1 px-
|
|
16708
|
+
className: "relative flex items-center justify-between py-1 px-6 max-w-xs",
|
|
16716
16709
|
children: [
|
|
16717
16710
|
/* @__PURE__ */ jsxRuntime.jsx("div", { ref: leftRef, children: /* @__PURE__ */ jsxRuntime.jsx(SystemNode, { label: isInput ? externalSystem : currentSystem }) }),
|
|
16718
16711
|
/* @__PURE__ */ jsxRuntime.jsx("div", { ref: rightRef, children: /* @__PURE__ */ jsxRuntime.jsx(SystemNode, { label: isInput ? currentSystem : externalSystem }) }),
|
|
@@ -16729,110 +16722,7 @@ var SystemsDiagram = ({ isInput, currentSystem, externalSystem }) => {
|
|
|
16729
16722
|
}
|
|
16730
16723
|
);
|
|
16731
16724
|
};
|
|
16732
|
-
var
|
|
16733
|
-
const [copied, setCopied] = React32.useState(false);
|
|
16734
|
-
const handleCopy = React32.useCallback(() => {
|
|
16735
|
-
navigator.clipboard.writeText(value).then(() => {
|
|
16736
|
-
setCopied(true);
|
|
16737
|
-
setTimeout(() => setCopied(false), 1500);
|
|
16738
|
-
});
|
|
16739
|
-
}, [value]);
|
|
16740
|
-
return /* @__PURE__ */ jsxRuntime.jsx(TooltipProviderBase, { children: /* @__PURE__ */ jsxRuntime.jsxs(TooltipBase, { children: [
|
|
16741
|
-
/* @__PURE__ */ jsxRuntime.jsx(TooltipTriggerBase, { asChild: true, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
16742
|
-
"button",
|
|
16743
|
-
{
|
|
16744
|
-
onClick: handleCopy,
|
|
16745
|
-
className: "shrink-0 p-0.5 rounded transition-colors text-muted-foreground/40 hover:text-foreground hover:bg-muted",
|
|
16746
|
-
style: { cursor: "pointer" },
|
|
16747
|
-
children: copied ? /* @__PURE__ */ jsxRuntime.jsx("svg", { width: "12", height: "12", viewBox: "0 0 16 16", fill: "none", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
16748
|
-
"path",
|
|
16749
|
-
{
|
|
16750
|
-
d: "M3 8l3.5 3.5L13 4.5",
|
|
16751
|
-
stroke: "currentColor",
|
|
16752
|
-
strokeWidth: "2",
|
|
16753
|
-
strokeLinecap: "round",
|
|
16754
|
-
strokeLinejoin: "round"
|
|
16755
|
-
}
|
|
16756
|
-
) }) : /* @__PURE__ */ jsxRuntime.jsxs("svg", { width: "12", height: "12", viewBox: "0 0 16 16", fill: "none", children: [
|
|
16757
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
16758
|
-
"rect",
|
|
16759
|
-
{
|
|
16760
|
-
x: "5",
|
|
16761
|
-
y: "5",
|
|
16762
|
-
width: "8",
|
|
16763
|
-
height: "9",
|
|
16764
|
-
rx: "1.5",
|
|
16765
|
-
stroke: "currentColor",
|
|
16766
|
-
strokeWidth: "1.5"
|
|
16767
|
-
}
|
|
16768
|
-
),
|
|
16769
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
16770
|
-
"path",
|
|
16771
|
-
{
|
|
16772
|
-
d: "M3 11V3.5A1.5 1.5 0 0 1 4.5 2H11",
|
|
16773
|
-
stroke: "currentColor",
|
|
16774
|
-
strokeWidth: "1.5",
|
|
16775
|
-
strokeLinecap: "round"
|
|
16776
|
-
}
|
|
16777
|
-
)
|
|
16778
|
-
] })
|
|
16779
|
-
}
|
|
16780
|
-
) }),
|
|
16781
|
-
/* @__PURE__ */ jsxRuntime.jsx(TooltipContentBase, { sideOffset: 6, className: "z-[10001]", children: copied ? "Copiado!" : "Copiar" })
|
|
16782
|
-
] }) });
|
|
16783
|
-
};
|
|
16784
|
-
var propertyLabels = {
|
|
16785
|
-
Nome: "Nome",
|
|
16786
|
-
tipo: "Tipo",
|
|
16787
|
-
Tipo: "Tipo",
|
|
16788
|
-
Protocolos: "Protocolos",
|
|
16789
|
-
Ambiente: "Ambiente",
|
|
16790
|
-
Setor: "Setor",
|
|
16791
|
-
Contato: "Contato",
|
|
16792
|
-
Sustentacao: "Sustenta\xE7\xE3o",
|
|
16793
|
-
Destino: "Destino",
|
|
16794
|
-
Origem: "Origem"
|
|
16795
|
-
};
|
|
16796
|
-
var IntegrationCard = ({ title, details }) => {
|
|
16797
|
-
const titleRef = React32.useRef(null);
|
|
16798
|
-
const isTitleTruncated = useIsTruncated(titleRef);
|
|
16799
|
-
const blackList = ["id", "elementId", "identity"];
|
|
16800
|
-
const entries = details ? Object.entries(details).filter(
|
|
16801
|
-
([key, value]) => value !== void 0 && value !== null && value !== "" && !blackList.includes(key)
|
|
16802
|
-
) : [];
|
|
16803
|
-
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "rounded-sm border border-border/40 bg-muted/20 overflow-hidden", children: [
|
|
16804
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2 px-3 py-2 border-b border-border/30", children: [
|
|
16805
|
-
/* @__PURE__ */ jsxRuntime.jsx(TooltipProviderBase, { children: /* @__PURE__ */ jsxRuntime.jsxs(TooltipBase, { children: [
|
|
16806
|
-
/* @__PURE__ */ jsxRuntime.jsx(TooltipTriggerBase, { asChild: true, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
16807
|
-
"span",
|
|
16808
|
-
{
|
|
16809
|
-
ref: titleRef,
|
|
16810
|
-
className: "text-sm font-bold text-foreground truncate flex-1 cursor-default",
|
|
16811
|
-
children: title
|
|
16812
|
-
}
|
|
16813
|
-
) }),
|
|
16814
|
-
isTitleTruncated && /* @__PURE__ */ jsxRuntime.jsx(TooltipContentBase, { sideOffset: 6, className: "z-[10001]", children: title })
|
|
16815
|
-
] }) }),
|
|
16816
|
-
entries.length > 0 && /* @__PURE__ */ jsxRuntime.jsx(
|
|
16817
|
-
CopyData,
|
|
16818
|
-
{
|
|
16819
|
-
value: entries.map(([k, v]) => `${propertyLabels[k] || k}: ${String(v)}`).join("\n")
|
|
16820
|
-
}
|
|
16821
|
-
)
|
|
16822
|
-
] }),
|
|
16823
|
-
entries.length > 0 && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "divide-y divide-border/20", children: entries.map(([key, value]) => {
|
|
16824
|
-
const label = propertyLabels[key] || key;
|
|
16825
|
-
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2 px-3 py-1.5", children: [
|
|
16826
|
-
/* @__PURE__ */ jsxRuntime.jsxs("span", { className: "text-xs font-semibold text-muted-foreground shrink-0 w-[40%] sm:w-[38%]", children: [
|
|
16827
|
-
label,
|
|
16828
|
-
":"
|
|
16829
|
-
] }),
|
|
16830
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-xs text-foreground break-all flex-1", children: String(value) })
|
|
16831
|
-
] }, key);
|
|
16832
|
-
}) })
|
|
16833
|
-
] });
|
|
16834
|
-
};
|
|
16835
|
-
var TooltipBodyComponent = ({ data, isLoading, connections, isInput, externalSystem }) => /* @__PURE__ */ jsxRuntime.jsx(ScrollAreaBase, { className: "flex-1", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "px-3 py-3 space-y-3", children: [
|
|
16725
|
+
var TooltipBodyComponent = ({ data, isLoading, connections, isInput, externalSystem }) => /* @__PURE__ */ jsxRuntime.jsx(ScrollAreaBase, { className: "h-full", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "px-3 py-3 space-y-3 max-w-xs", children: [
|
|
16836
16726
|
isLoading ? /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-1.5", children: [
|
|
16837
16727
|
/* @__PURE__ */ jsxRuntime.jsx(SkeletonBase, { className: "h-6 w-3/4" }),
|
|
16838
16728
|
/* @__PURE__ */ jsxRuntime.jsx(SkeletonBase, { className: "h-3.5 w-1/2" })
|
|
@@ -16855,7 +16745,7 @@ var TooltipBodyComponent = ({ data, isLoading, connections, isInput, externalSys
|
|
|
16855
16745
|
},
|
|
16856
16746
|
i
|
|
16857
16747
|
))
|
|
16858
|
-
] }) : connections.length === 0 ? /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-xs text-muted-foreground text-center
|
|
16748
|
+
] }) : connections.length === 0 ? /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-xs text-muted-foreground text-center", children: "Nenhuma conex\xE3o encontrada" }) : /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
16859
16749
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
16860
16750
|
SystemsDiagram,
|
|
16861
16751
|
{
|
|
@@ -16865,8 +16755,8 @@ var TooltipBodyComponent = ({ data, isLoading, connections, isInput, externalSys
|
|
|
16865
16755
|
}
|
|
16866
16756
|
),
|
|
16867
16757
|
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "border-t border-border/20" }),
|
|
16868
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center
|
|
16869
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", {
|
|
16758
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center ", children: /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-[10px] font-bold text-muted-foreground uppercase -mb-2", children: isInput ? "Informa\xE7\xF5es de Entrada" : "Informa\xE7\xF5es de Sa\xEDda" }) }),
|
|
16759
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { children: connections.map((conn) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
16870
16760
|
IntegrationCard,
|
|
16871
16761
|
{
|
|
16872
16762
|
title: conn.name,
|
|
@@ -16910,7 +16800,12 @@ var IntegrationTooltip = ({
|
|
|
16910
16800
|
const [dragging, setDragging] = React32.useState(false);
|
|
16911
16801
|
const offsetRef = React32.useRef({ x: 0, y: 0 });
|
|
16912
16802
|
const lastMouse = React32.useRef({ x: 0, y: 0 });
|
|
16913
|
-
React32.
|
|
16803
|
+
const tooltipRef = React32.useRef(null);
|
|
16804
|
+
const currentPosRef = React32.useRef(position);
|
|
16805
|
+
React32.useEffect(() => {
|
|
16806
|
+
currentPosRef.current = position;
|
|
16807
|
+
setLocalPos(position);
|
|
16808
|
+
}, [position]);
|
|
16914
16809
|
React32.useEffect(() => {
|
|
16915
16810
|
let rafId = null;
|
|
16916
16811
|
const handleMouseMove = (e) => {
|
|
@@ -16924,13 +16819,18 @@ var IntegrationTooltip = ({
|
|
|
16924
16819
|
top: Math.max(0, Math.min(newTop, window.innerHeight - 200)),
|
|
16925
16820
|
left: Math.max(0, Math.min(newLeft, window.innerWidth - 320))
|
|
16926
16821
|
};
|
|
16927
|
-
|
|
16822
|
+
currentPosRef.current = p;
|
|
16823
|
+
if (tooltipRef.current) {
|
|
16824
|
+
tooltipRef.current.style.top = `${p.top}px`;
|
|
16825
|
+
tooltipRef.current.style.left = `${p.left}px`;
|
|
16826
|
+
}
|
|
16928
16827
|
onPositionChange?.(id, p);
|
|
16929
16828
|
});
|
|
16930
16829
|
};
|
|
16931
16830
|
const handleMouseUp = () => {
|
|
16932
16831
|
if (dragging) {
|
|
16933
16832
|
setDragging(false);
|
|
16833
|
+
setLocalPos(currentPosRef.current);
|
|
16934
16834
|
if (rafId) cancelAnimationFrame(rafId);
|
|
16935
16835
|
}
|
|
16936
16836
|
};
|
|
@@ -16992,7 +16892,7 @@ var IntegrationTooltip = ({
|
|
|
16992
16892
|
const header = /* @__PURE__ */ jsxRuntime.jsxs(
|
|
16993
16893
|
"div",
|
|
16994
16894
|
{
|
|
16995
|
-
className: "flex items-center justify-between py-1 border-b border-border/10 bg-muted/30 shrink-0",
|
|
16895
|
+
className: "flex items-center justify-between py-1 border-b border-border/10 bg-muted/30 shrink-0 max-w-lg",
|
|
16996
16896
|
onMouseDown: handleMouseDownLocal,
|
|
16997
16897
|
onTouchStart: handleTouchStartLocal,
|
|
16998
16898
|
style: {
|
|
@@ -17035,7 +16935,7 @@ var IntegrationTooltip = ({
|
|
|
17035
16935
|
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
17036
16936
|
framerMotion.motion.div,
|
|
17037
16937
|
{
|
|
17038
|
-
className: "fixed bottom-0 left-0 right-0 z-[10000] bg-card border-t border-border/50 rounded-t-2xl shadow-2xl flex flex-col",
|
|
16938
|
+
className: "fixed bottom-0 left-0 right-0 z-[10000] bg-card border-t border-border/50 rounded-t-2xl shadow-2xl flex flex-col min-h-0",
|
|
17039
16939
|
style: { maxHeight: "85dvh" },
|
|
17040
16940
|
initial: { y: "100%" },
|
|
17041
16941
|
animate: { y: 0 },
|
|
@@ -17045,7 +16945,7 @@ var IntegrationTooltip = ({
|
|
|
17045
16945
|
children: [
|
|
17046
16946
|
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex justify-center pt-2.5 pb-1 shrink-0", children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-10 h-1 rounded-full bg-border" }) }),
|
|
17047
16947
|
header,
|
|
17048
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "
|
|
16948
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex-1 min-h-0", children: /* @__PURE__ */ jsxRuntime.jsx(TooltipBody, { ...bodyProps }) })
|
|
17049
16949
|
]
|
|
17050
16950
|
},
|
|
17051
16951
|
`sheet-${id}`
|
|
@@ -17055,7 +16955,8 @@ var IntegrationTooltip = ({
|
|
|
17055
16955
|
return /* @__PURE__ */ jsxRuntime.jsx(framerMotion.AnimatePresence, { children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
17056
16956
|
framerMotion.motion.div,
|
|
17057
16957
|
{
|
|
17058
|
-
|
|
16958
|
+
ref: tooltipRef,
|
|
16959
|
+
className: "fixed bg-card/95 backdrop-blur-md border border-border/50 rounded-lg shadow-2xl z-[10000] w-[calc(100vw-32px)] max-w-sm sm:w-80 overflow-hidden flex flex-col max-h-[60vh] sm:max-h-[520px]",
|
|
17059
16960
|
variants: tooltipVariants3,
|
|
17060
16961
|
initial: "hidden",
|
|
17061
16962
|
animate: "visible",
|
|
@@ -17064,7 +16965,7 @@ var IntegrationTooltip = ({
|
|
|
17064
16965
|
onClick: (e) => e.stopPropagation(),
|
|
17065
16966
|
children: [
|
|
17066
16967
|
header,
|
|
17067
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "
|
|
16968
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex-1 min-h-0", children: /* @__PURE__ */ jsxRuntime.jsx(TooltipBody, { ...bodyProps }) })
|
|
17068
16969
|
]
|
|
17069
16970
|
},
|
|
17070
16971
|
id
|
|
@@ -19991,11 +19892,9 @@ var ZoomImage = React32__namespace.forwardRef(
|
|
|
19991
19892
|
const mouseY = framerMotion.useMotionValue(50);
|
|
19992
19893
|
const zoomLevel = framerMotion.useMotionValue(1);
|
|
19993
19894
|
const springConfig = { damping: 20, stiffness: 150, mass: 0.5 };
|
|
19994
|
-
const smoothMouseX = framerMotion.useSpring(mouseX, springConfig);
|
|
19995
|
-
const smoothMouseY = framerMotion.useSpring(mouseY, springConfig);
|
|
19996
19895
|
const smoothZoomLevel = framerMotion.useSpring(zoomLevel, springConfig);
|
|
19997
19896
|
const transformOrigin = framerMotion.useTransform(
|
|
19998
|
-
[
|
|
19897
|
+
[mouseX, mouseY],
|
|
19999
19898
|
([latestX, latestY]) => `${latestX}% ${latestY}%`
|
|
20000
19899
|
);
|
|
20001
19900
|
const touchStartDist = React32__namespace.useRef(0);
|
|
@@ -20097,7 +19996,7 @@ var ZoomImage = React32__namespace.forwardRef(
|
|
|
20097
19996
|
{
|
|
20098
19997
|
src,
|
|
20099
19998
|
alt,
|
|
20100
|
-
className: cn("w-full h-full object-
|
|
19999
|
+
className: cn("w-full h-full object-contain", imageClassName),
|
|
20101
20000
|
style: {
|
|
20102
20001
|
borderRadius: `${borderRadius}px`,
|
|
20103
20002
|
transformOrigin,
|
|
@@ -20448,7 +20347,7 @@ function CarouselBase({
|
|
|
20448
20347
|
src: item.url,
|
|
20449
20348
|
alt: item.title,
|
|
20450
20349
|
className: cn(
|
|
20451
|
-
"w-full h-full object-
|
|
20350
|
+
"w-full h-full object-contain rounded-lg select-none pointer-events-none",
|
|
20452
20351
|
imageClassName
|
|
20453
20352
|
),
|
|
20454
20353
|
draggable: false
|
|
@@ -20459,7 +20358,7 @@ function CarouselBase({
|
|
|
20459
20358
|
src: item.url,
|
|
20460
20359
|
alt: item.title,
|
|
20461
20360
|
className: cn(
|
|
20462
|
-
"w-full h-full object-
|
|
20361
|
+
"w-full h-full object-contain rounded-lg select-none pointer-events-none",
|
|
20463
20362
|
imageClassName
|
|
20464
20363
|
),
|
|
20465
20364
|
draggable: false
|
|
@@ -20476,8 +20375,7 @@ function CarouselBase({
|
|
|
20476
20375
|
onMouseDown: (e) => e.stopPropagation(),
|
|
20477
20376
|
className: cn(
|
|
20478
20377
|
"absolute top-4 right-4 z-50 p-2 rounded-full text-white transition-colors border border-white/10",
|
|
20479
|
-
downloadSuccess ? "bg-green-500 hover:bg-green-600" : "bg-black/50 hover:bg-black/70"
|
|
20480
|
-
className
|
|
20378
|
+
downloadSuccess ? "bg-green-500 hover:bg-green-600" : "bg-black/50 hover:bg-black/70"
|
|
20481
20379
|
),
|
|
20482
20380
|
title: "Download image",
|
|
20483
20381
|
initial: false,
|
|
@@ -20563,8 +20461,7 @@ function CarouselBase({
|
|
|
20563
20461
|
className: cn(
|
|
20564
20462
|
"absolute left-4 top-1/2 -translate-y-1/2 w-10 h-10 rounded-full flex items-center justify-center shadow-lg transition-all z-50",
|
|
20565
20463
|
!emblaApi?.canScrollPrev() ? "opacity-40 cursor-not-allowed" : "hover:scale-110 hover:opacity-100 opacity-70",
|
|
20566
|
-
"bg-primary text-primary-foreground"
|
|
20567
|
-
className
|
|
20464
|
+
"bg-primary text-primary-foreground"
|
|
20568
20465
|
),
|
|
20569
20466
|
style: fernando ? { backgroundColor: fernando } : void 0,
|
|
20570
20467
|
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -20598,8 +20495,7 @@ function CarouselBase({
|
|
|
20598
20495
|
className: cn(
|
|
20599
20496
|
"absolute right-4 top-1/2 -translate-y-1/2 w-10 h-10 rounded-full flex items-center justify-center shadow-lg transition-all z-50",
|
|
20600
20497
|
!emblaApi?.canScrollNext() ? "opacity-40 cursor-not-allowed" : "hover:scale-110 hover:opacity-100 opacity-70",
|
|
20601
|
-
"bg-primary text-primary-foreground"
|
|
20602
|
-
className
|
|
20498
|
+
"bg-primary text-primary-foreground"
|
|
20603
20499
|
),
|
|
20604
20500
|
style: fernando ? { backgroundColor: fernando } : void 0,
|
|
20605
20501
|
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -20632,8 +20528,7 @@ function CarouselBase({
|
|
|
20632
20528
|
onMouseDown: (e) => e.stopPropagation(),
|
|
20633
20529
|
className: cn(
|
|
20634
20530
|
"h-2 rounded-full transition-all duration-300",
|
|
20635
|
-
i === index ? cn("w-8 bg-primary") : cn("w-2 hover:opacity-80 bg-primary opacity-40")
|
|
20636
|
-
className
|
|
20531
|
+
i === index ? cn("w-8 bg-primary") : cn("w-2 hover:opacity-80 bg-primary opacity-40")
|
|
20637
20532
|
),
|
|
20638
20533
|
style: fernando ? { backgroundColor: fernando } : void 0
|
|
20639
20534
|
},
|
|
@@ -20877,12 +20772,13 @@ function ControlledCombobox({
|
|
|
20877
20772
|
"aria-disabled": disabled || void 0,
|
|
20878
20773
|
disabled,
|
|
20879
20774
|
className: cn(
|
|
20880
|
-
`flex items-center gap-2 justify-between [&>div]:line-clamp-1 relative h-9 no-active-animation`,
|
|
20881
|
-
error && "border-red-500"
|
|
20775
|
+
`flex items-center gap-2 justify-between [&>div]:line-clamp-1 relative h-9 no-active-animation font-light`,
|
|
20776
|
+
error && "border-red-500",
|
|
20777
|
+
placeholder && !hasSelected && "text-muted-foreground"
|
|
20882
20778
|
),
|
|
20883
20779
|
"data-testid": testIds.trigger ?? "combobox-trigger",
|
|
20884
20780
|
children: [
|
|
20885
|
-
renderSelected,
|
|
20781
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "truncate min-w-0", children: renderSelected }),
|
|
20886
20782
|
/* @__PURE__ */ jsxRuntime.jsx(framerMotion.motion.span, { className: "flex items-center", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-row gap-0 items-center ", children: [
|
|
20887
20783
|
hasSelected && onClear && !disabled && !hideClear && /* @__PURE__ */ jsxRuntime.jsx(
|
|
20888
20784
|
ClearButton,
|
|
@@ -20954,9 +20850,9 @@ function ControlledCombobox({
|
|
|
20954
20850
|
{
|
|
20955
20851
|
keywords: [item.label],
|
|
20956
20852
|
value: item.value,
|
|
20957
|
-
onSelect: (
|
|
20853
|
+
onSelect: () => {
|
|
20958
20854
|
if (disabled) return;
|
|
20959
|
-
handleSelection(
|
|
20855
|
+
handleSelection(item.value);
|
|
20960
20856
|
if (!keepOpen) setOpen(false);
|
|
20961
20857
|
},
|
|
20962
20858
|
disabled,
|
|
@@ -21008,6 +20904,112 @@ function ControlledCombobox({
|
|
|
21008
20904
|
}
|
|
21009
20905
|
);
|
|
21010
20906
|
}
|
|
20907
|
+
var sizeMap = {
|
|
20908
|
+
sm: { container: "size-24", text: "text-lg" },
|
|
20909
|
+
md: { container: "size-40", text: "text-2xl" },
|
|
20910
|
+
lg: { container: "size-56", text: "text-3xl" },
|
|
20911
|
+
xl: { container: "size-72", text: "text-4xl" }
|
|
20912
|
+
};
|
|
20913
|
+
function CircularProgress({
|
|
20914
|
+
value,
|
|
20915
|
+
className,
|
|
20916
|
+
max: max2 = 100,
|
|
20917
|
+
min: min2 = 0,
|
|
20918
|
+
size = "md",
|
|
20919
|
+
showValue = true,
|
|
20920
|
+
label,
|
|
20921
|
+
disableAnimation = false,
|
|
20922
|
+
midThreshold = 50,
|
|
20923
|
+
lowThreshold = 10,
|
|
20924
|
+
formatValue
|
|
20925
|
+
}) {
|
|
20926
|
+
const circumference = 2 * Math.PI * 45;
|
|
20927
|
+
const currentPercent = Math.round((value - min2) / (max2 - min2) * 100);
|
|
20928
|
+
const count = framerMotion.useMotionValue(disableAnimation ? currentPercent : 0);
|
|
20929
|
+
const rounded = framerMotion.useTransform(count, (v) => {
|
|
20930
|
+
const pct = Math.round(v);
|
|
20931
|
+
return formatValue ? formatValue(pct) : `${pct}%`;
|
|
20932
|
+
});
|
|
20933
|
+
const strokePercent = framerMotion.useSpring(disableAnimation ? currentPercent : 0, {
|
|
20934
|
+
stiffness: 55,
|
|
20935
|
+
damping: 18,
|
|
20936
|
+
restDelta: 1e-3
|
|
20937
|
+
});
|
|
20938
|
+
const strokeDasharray = framerMotion.useTransform(
|
|
20939
|
+
strokePercent,
|
|
20940
|
+
(v) => `${v / 100 * circumference} ${circumference}`
|
|
20941
|
+
);
|
|
20942
|
+
let colorClass;
|
|
20943
|
+
if (currentPercent >= midThreshold) colorClass = "stroke-emerald-500";
|
|
20944
|
+
else if (currentPercent > lowThreshold) colorClass = "stroke-yellow-500";
|
|
20945
|
+
else colorClass = "stroke-red-500";
|
|
20946
|
+
React32.useEffect(() => {
|
|
20947
|
+
if (disableAnimation) {
|
|
20948
|
+
count.set(currentPercent);
|
|
20949
|
+
strokePercent.set(currentPercent);
|
|
20950
|
+
return;
|
|
20951
|
+
}
|
|
20952
|
+
strokePercent.set(currentPercent);
|
|
20953
|
+
const controls = framerMotion.animate(count, currentPercent, {
|
|
20954
|
+
duration: 1.4,
|
|
20955
|
+
ease: "easeOut",
|
|
20956
|
+
delay: 0.15
|
|
20957
|
+
});
|
|
20958
|
+
return controls.stop;
|
|
20959
|
+
}, [currentPercent, count, strokePercent, disableAnimation]);
|
|
20960
|
+
const { container, text } = sizeMap[size];
|
|
20961
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
20962
|
+
framerMotion.motion.div,
|
|
20963
|
+
{
|
|
20964
|
+
className: cn("relative flex flex-col items-center gap-1", className),
|
|
20965
|
+
initial: disableAnimation ? false : { opacity: 0, scale: 0.88 },
|
|
20966
|
+
animate: { opacity: 1, scale: 1 },
|
|
20967
|
+
transition: { duration: 0.5, ease: "easeOut" },
|
|
20968
|
+
children: [
|
|
20969
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: cn("relative font-semibold", container, text), children: [
|
|
20970
|
+
/* @__PURE__ */ jsxRuntime.jsxs("svg", { fill: "none", className: "size-full", strokeWidth: "2", viewBox: "0 0 100 100", children: [
|
|
20971
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
20972
|
+
"circle",
|
|
20973
|
+
{
|
|
20974
|
+
cx: "50",
|
|
20975
|
+
cy: "50",
|
|
20976
|
+
r: "45",
|
|
20977
|
+
strokeWidth: 10,
|
|
20978
|
+
strokeLinecap: "round",
|
|
20979
|
+
className: `${colorClass} opacity-15`
|
|
20980
|
+
}
|
|
20981
|
+
),
|
|
20982
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
20983
|
+
framerMotion.motion.circle,
|
|
20984
|
+
{
|
|
20985
|
+
cx: "50",
|
|
20986
|
+
cy: "50",
|
|
20987
|
+
r: "45",
|
|
20988
|
+
strokeWidth: 10,
|
|
20989
|
+
strokeLinecap: "round",
|
|
20990
|
+
className: colorClass,
|
|
20991
|
+
strokeDashoffset: "0",
|
|
20992
|
+
strokeDasharray,
|
|
20993
|
+
style: { rotate: -90, transformOrigin: "50px 50px" }
|
|
20994
|
+
}
|
|
20995
|
+
)
|
|
20996
|
+
] }),
|
|
20997
|
+
showValue && /* @__PURE__ */ jsxRuntime.jsx(
|
|
20998
|
+
framerMotion.motion.span,
|
|
20999
|
+
{
|
|
21000
|
+
className: "absolute inset-0 m-auto flex size-fit items-center justify-center",
|
|
21001
|
+
initial: disableAnimation ? false : { opacity: 0, y: 6 },
|
|
21002
|
+
animate: { opacity: 1, y: 0 },
|
|
21003
|
+
transition: { duration: 0.45, delay: 0.2, ease: "easeOut" },
|
|
21004
|
+
children: rounded
|
|
21005
|
+
}
|
|
21006
|
+
)
|
|
21007
|
+
] }),
|
|
21008
|
+
label && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-muted-foreground text-sm font-medium", children: label })
|
|
21009
|
+
]
|
|
21010
|
+
}
|
|
21011
|
+
);
|
|
21012
|
+
}
|
|
21011
21013
|
|
|
21012
21014
|
exports.AddButton = AddButton;
|
|
21013
21015
|
exports.Agenda = Agenda;
|
|
@@ -21031,7 +21033,6 @@ exports.AvatarFallbackBase = AvatarFallbackBase;
|
|
|
21031
21033
|
exports.AvatarImageBase = AvatarImageBase;
|
|
21032
21034
|
exports.BackButton = BackButton;
|
|
21033
21035
|
exports.Badge = Badge;
|
|
21034
|
-
exports.Beam = Beam;
|
|
21035
21036
|
exports.BreadcrumbBase = BreadcrumbBase;
|
|
21036
21037
|
exports.BreadcrumbEllipsisBase = BreadcrumbEllipsisBase;
|
|
21037
21038
|
exports.BreadcrumbItemBase = BreadcrumbItemBase;
|
|
@@ -21061,6 +21062,7 @@ exports.ChartTotalLegend = ChartTotalLegend_default;
|
|
|
21061
21062
|
exports.CheckButton = CheckButton;
|
|
21062
21063
|
exports.CheckboxBase = CheckboxBase;
|
|
21063
21064
|
exports.CheckboxTree = CheckboxTree;
|
|
21065
|
+
exports.CircularProgress = CircularProgress;
|
|
21064
21066
|
exports.CloseAllButton = CloseAllButton_default;
|
|
21065
21067
|
exports.CloseButton = CloseButton;
|
|
21066
21068
|
exports.CodeBlock = CodeBlock;
|
|
@@ -21095,7 +21097,6 @@ exports.ContextMenuSubTriggerBase = ContextMenuSubTriggerBase;
|
|
|
21095
21097
|
exports.ContextMenuTriggerBase = ContextMenuTriggerBase;
|
|
21096
21098
|
exports.ControlledCombobox = ControlledCombobox;
|
|
21097
21099
|
exports.CopyButton = CopyButton;
|
|
21098
|
-
exports.CopyData = CopyData;
|
|
21099
21100
|
exports.DateTimePicker = DateTimePicker;
|
|
21100
21101
|
exports.DayView = DayView;
|
|
21101
21102
|
exports.DayViewAgenda = DayViewAgenda;
|
|
@@ -21177,7 +21178,6 @@ exports.InputOTPBase = InputOTPBase;
|
|
|
21177
21178
|
exports.InputOTPGroupBase = InputOTPGroupBase;
|
|
21178
21179
|
exports.InputOTPSeparatorBase = InputOTPSeparatorBase;
|
|
21179
21180
|
exports.InputOTPSlotBase = InputOTPSlotBase;
|
|
21180
|
-
exports.IntegrationCard = IntegrationCard;
|
|
21181
21181
|
exports.IntegrationTooltip = IntegrationTooltip_default;
|
|
21182
21182
|
exports.LabelBase = LabelBase_default;
|
|
21183
21183
|
exports.Leaderboard = Leaderboard;
|
|
@@ -21208,7 +21208,6 @@ exports.MultiSelectItemBase = MultiSelectItemBase;
|
|
|
21208
21208
|
exports.MultiSelectSeparatorBase = MultiSelectSeparatorBase;
|
|
21209
21209
|
exports.MultiSelectTriggerBase = MultiSelectTriggerBase;
|
|
21210
21210
|
exports.MultiSelectValueBase = MultiSelectValueBase;
|
|
21211
|
-
exports.NameTooltip = NameTooltip;
|
|
21212
21211
|
exports.NavigationMenuBase = NavigationMenuBase;
|
|
21213
21212
|
exports.NavigationMenuContentBase = NavigationMenuContentBase;
|
|
21214
21213
|
exports.NavigationMenuIndicatorBase = NavigationMenuIndicatorBase;
|
|
@@ -21290,9 +21289,7 @@ exports.StartHour = StartHour;
|
|
|
21290
21289
|
exports.StartHourAgenda = StartHourAgenda;
|
|
21291
21290
|
exports.StatusIndicator = StatusIndicator;
|
|
21292
21291
|
exports.SwitchBase = SwitchBase;
|
|
21293
|
-
exports.SystemNode = SystemNode;
|
|
21294
21292
|
exports.SystemTooltip = SystemTooltip_default;
|
|
21295
|
-
exports.SystemsDiagram = SystemsDiagram;
|
|
21296
21293
|
exports.TableBase = TableBase;
|
|
21297
21294
|
exports.TableBodyBase = TableBodyBase;
|
|
21298
21295
|
exports.TableCaptionBase = TableCaptionBase;
|
|
@@ -21312,7 +21309,6 @@ exports.TimePickerInput = TimePickerInput;
|
|
|
21312
21309
|
exports.TimeSeries = TimeSeries_default;
|
|
21313
21310
|
exports.Toaster = Toaster;
|
|
21314
21311
|
exports.TooltipBase = TooltipBase;
|
|
21315
|
-
exports.TooltipBody = TooltipBody;
|
|
21316
21312
|
exports.TooltipContentBase = TooltipContentBase;
|
|
21317
21313
|
exports.TooltipProviderBase = TooltipProviderBase;
|
|
21318
21314
|
exports.TooltipSimple = TooltipSimple_default;
|
|
@@ -21417,7 +21413,6 @@ exports.useDrag = useDrag;
|
|
|
21417
21413
|
exports.useEventVisibility = useEventVisibility;
|
|
21418
21414
|
exports.useEventVisibilityAgenda = useEventVisibilityAgenda;
|
|
21419
21415
|
exports.useIsMobile = useIsMobile;
|
|
21420
|
-
exports.useIsTruncated = useIsTruncated;
|
|
21421
21416
|
exports.useOpenTooltipForPeriod = useOpenTooltipForPeriod;
|
|
21422
21417
|
exports.useProcessedData = useProcessedData;
|
|
21423
21418
|
exports.useSeriesOpacity = useSeriesOpacity;
|