@geomak/ui 7.5.2 → 7.5.3
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.cjs +62 -46
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +62 -46
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -2515,52 +2515,68 @@ function PopConfirm({
|
|
|
2515
2515
|
onCancel?.();
|
|
2516
2516
|
setOpen(false);
|
|
2517
2517
|
};
|
|
2518
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
2519
|
-
|
|
2520
|
-
|
|
2521
|
-
|
|
2522
|
-
{
|
|
2523
|
-
|
|
2524
|
-
|
|
2525
|
-
|
|
2526
|
-
|
|
2527
|
-
|
|
2528
|
-
|
|
2529
|
-
|
|
2530
|
-
|
|
2531
|
-
|
|
2532
|
-
|
|
2533
|
-
|
|
2534
|
-
|
|
2535
|
-
|
|
2536
|
-
|
|
2537
|
-
|
|
2538
|
-
|
|
2539
|
-
|
|
2540
|
-
|
|
2541
|
-
|
|
2542
|
-
|
|
2543
|
-
|
|
2544
|
-
|
|
2545
|
-
|
|
2546
|
-
|
|
2547
|
-
|
|
2548
|
-
|
|
2549
|
-
|
|
2550
|
-
|
|
2551
|
-
|
|
2552
|
-
|
|
2553
|
-
|
|
2554
|
-
|
|
2555
|
-
|
|
2556
|
-
|
|
2557
|
-
|
|
2558
|
-
|
|
2559
|
-
|
|
2560
|
-
|
|
2561
|
-
|
|
2562
|
-
|
|
2563
|
-
|
|
2518
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
2519
|
+
Popover__namespace.Root,
|
|
2520
|
+
{
|
|
2521
|
+
open: isOpen,
|
|
2522
|
+
onOpenChange: (o) => {
|
|
2523
|
+
if (o) setOpen(true);
|
|
2524
|
+
else if (!loading) handleCancel();
|
|
2525
|
+
},
|
|
2526
|
+
children: [
|
|
2527
|
+
/* @__PURE__ */ jsxRuntime.jsx(Popover__namespace.Trigger, { asChild: true, children }),
|
|
2528
|
+
/* @__PURE__ */ jsxRuntime.jsx(Popover__namespace.Portal, { children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
2529
|
+
Popover__namespace.Content,
|
|
2530
|
+
{
|
|
2531
|
+
side,
|
|
2532
|
+
sideOffset: 8,
|
|
2533
|
+
collisionPadding: 12,
|
|
2534
|
+
className: cx("z-[400] focus:outline-none", className),
|
|
2535
|
+
onEscapeKeyDown: (e) => {
|
|
2536
|
+
if (loading) e.preventDefault();
|
|
2537
|
+
},
|
|
2538
|
+
onInteractOutside: (e) => {
|
|
2539
|
+
if (loading) e.preventDefault();
|
|
2540
|
+
},
|
|
2541
|
+
children: [
|
|
2542
|
+
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
2543
|
+
framerMotion.motion.div,
|
|
2544
|
+
{
|
|
2545
|
+
initial: { opacity: 0, scale: 0.95 },
|
|
2546
|
+
animate: { opacity: 1, scale: 1 },
|
|
2547
|
+
transition: { duration: 0.12, ease: [0.16, 1, 0.3, 1] },
|
|
2548
|
+
className: "w-64 rounded-lg border border-border bg-surface p-3.5 shadow-lg",
|
|
2549
|
+
children: [
|
|
2550
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex gap-2.5", children: [
|
|
2551
|
+
icon && /* @__PURE__ */ jsxRuntime.jsx("span", { className: `mt-0.5 flex h-5 w-5 flex-shrink-0 items-center justify-center ${ICON_COLOR[tone]}`, children: icon }),
|
|
2552
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "min-w-0", children: [
|
|
2553
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "text-sm font-medium text-foreground", children: title }),
|
|
2554
|
+
description && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "mt-1 text-xs text-foreground-secondary leading-snug", children: description })
|
|
2555
|
+
] })
|
|
2556
|
+
] }),
|
|
2557
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "mt-3 flex justify-end gap-2", children: [
|
|
2558
|
+
/* @__PURE__ */ jsxRuntime.jsx(Button_default, { content: cancelText, size: "sm", variant: "ghost", disabled: loading, onClick: handleCancel }),
|
|
2559
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2560
|
+
Button_default,
|
|
2561
|
+
{
|
|
2562
|
+
content: confirmText,
|
|
2563
|
+
size: "sm",
|
|
2564
|
+
variant: CONFIRM_VARIANT[tone],
|
|
2565
|
+
loading,
|
|
2566
|
+
onClick: handleConfirm
|
|
2567
|
+
}
|
|
2568
|
+
)
|
|
2569
|
+
] })
|
|
2570
|
+
]
|
|
2571
|
+
}
|
|
2572
|
+
),
|
|
2573
|
+
/* @__PURE__ */ jsxRuntime.jsx(Popover__namespace.Arrow, { className: "fill-surface" })
|
|
2574
|
+
]
|
|
2575
|
+
}
|
|
2576
|
+
) })
|
|
2577
|
+
]
|
|
2578
|
+
}
|
|
2579
|
+
);
|
|
2564
2580
|
}
|
|
2565
2581
|
var DEFAULT_EVENTS = ["mousemove", "mousedown", "keydown", "touchstart", "scroll", "wheel"];
|
|
2566
2582
|
var formatTime = (ms) => {
|