@appolabs/ui 0.1.14 → 0.1.21
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 +52 -4
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +27 -1
- package/dist/index.d.ts +27 -1
- package/dist/index.js +51 -5
- package/dist/index.js.map +1 -1
- package/package.json +4 -4
package/dist/index.cjs
CHANGED
|
@@ -7,8 +7,8 @@ var AccordionPrimitive = require('@radix-ui/react-accordion');
|
|
|
7
7
|
var lucideReact = require('lucide-react');
|
|
8
8
|
var jsxRuntime = require('react/jsx-runtime');
|
|
9
9
|
var classVarianceAuthority = require('class-variance-authority');
|
|
10
|
-
var AlertDialogPrimitive = require('@radix-ui/react-alert-dialog');
|
|
11
10
|
var reactSlot = require('@radix-ui/react-slot');
|
|
11
|
+
var AlertDialogPrimitive = require('@radix-ui/react-alert-dialog');
|
|
12
12
|
var AspectRatioPrimitive = require('@radix-ui/react-aspect-ratio');
|
|
13
13
|
var AvatarPrimitive = require('@radix-ui/react-avatar');
|
|
14
14
|
var reactDayPicker = require('react-day-picker');
|
|
@@ -345,6 +345,37 @@ var Button = React40__namespace.forwardRef(
|
|
|
345
345
|
}
|
|
346
346
|
);
|
|
347
347
|
Button.displayName = "Button";
|
|
348
|
+
function CookieBanner({
|
|
349
|
+
visible,
|
|
350
|
+
cookiePolicyUrl,
|
|
351
|
+
onAccept,
|
|
352
|
+
onReject,
|
|
353
|
+
onManage,
|
|
354
|
+
className
|
|
355
|
+
}) {
|
|
356
|
+
if (!visible) return null;
|
|
357
|
+
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: cn("fixed bottom-0 left-0 right-0 z-50 p-4", className), children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "rounded-xl border border-border bg-card/95 backdrop-blur-sm flex flex-col gap-4 px-4 py-4 sm:flex-row sm:items-center sm:justify-between", children: [
|
|
358
|
+
/* @__PURE__ */ jsxRuntime.jsxs("p", { className: "text-sm text-muted-foreground", children: [
|
|
359
|
+
"Utilizziamo i cookie per migliorare la tua esperienza.",
|
|
360
|
+
" ",
|
|
361
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
362
|
+
"a",
|
|
363
|
+
{
|
|
364
|
+
href: cookiePolicyUrl,
|
|
365
|
+
className: "text-foreground underline underline-offset-2 hover:no-underline",
|
|
366
|
+
target: "_blank",
|
|
367
|
+
rel: "noreferrer",
|
|
368
|
+
children: "Cookie policy"
|
|
369
|
+
}
|
|
370
|
+
)
|
|
371
|
+
] }),
|
|
372
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex shrink-0 items-center gap-2", children: [
|
|
373
|
+
onManage && /* @__PURE__ */ jsxRuntime.jsx(Button, { variant: "ghost", size: "sm", onClick: onManage, className: "hover:bg-transparent hover:underline", children: "Gestisci" }),
|
|
374
|
+
/* @__PURE__ */ jsxRuntime.jsx(Button, { variant: "outline", size: "sm", onClick: onReject, children: "Rifiuta" }),
|
|
375
|
+
/* @__PURE__ */ jsxRuntime.jsx(Button, { size: "sm", onClick: onAccept, children: "Accetta tutto" })
|
|
376
|
+
] })
|
|
377
|
+
] }) });
|
|
378
|
+
}
|
|
348
379
|
var AlertDialog = AlertDialogPrimitive__namespace.Root;
|
|
349
380
|
var AlertDialogTrigger = AlertDialogPrimitive__namespace.Trigger;
|
|
350
381
|
var AlertDialogPortal = AlertDialogPrimitive__namespace.Portal;
|
|
@@ -1409,7 +1440,7 @@ var DialogHeader = ({
|
|
|
1409
1440
|
"div",
|
|
1410
1441
|
{
|
|
1411
1442
|
className: cn(
|
|
1412
|
-
"flex flex-shrink-0 flex-col space-y-1.5 px-
|
|
1443
|
+
"flex flex-shrink-0 flex-col space-y-1.5 px-4 pt-4 text-center sm:text-left",
|
|
1413
1444
|
className
|
|
1414
1445
|
),
|
|
1415
1446
|
...props
|
|
@@ -1423,7 +1454,7 @@ var DialogBody = ({
|
|
|
1423
1454
|
"div",
|
|
1424
1455
|
{
|
|
1425
1456
|
className: cn(
|
|
1426
|
-
"flex-1 overflow-y-auto hide-scrollbar px-
|
|
1457
|
+
"flex-1 overflow-y-auto hide-scrollbar px-4 pb-2",
|
|
1427
1458
|
className
|
|
1428
1459
|
),
|
|
1429
1460
|
...props
|
|
@@ -1437,13 +1468,28 @@ var DialogFooter = ({
|
|
|
1437
1468
|
"div",
|
|
1438
1469
|
{
|
|
1439
1470
|
className: cn(
|
|
1440
|
-
"flex flex-shrink-0 flex-col-reverse gap-2 px-
|
|
1471
|
+
"flex flex-shrink-0 flex-col-reverse gap-2 px-4 pb-4 sm:flex-row sm:justify-end",
|
|
1441
1472
|
className
|
|
1442
1473
|
),
|
|
1443
1474
|
...props
|
|
1444
1475
|
}
|
|
1445
1476
|
);
|
|
1446
1477
|
DialogFooter.displayName = "DialogFooter";
|
|
1478
|
+
var DialogSteps = ({ currentStep, totalSteps, className }) => /* @__PURE__ */ jsxRuntime.jsx("div", { className: cn(
|
|
1479
|
+
"flex items-center justify-center gap-1.5 pt-4 -mb-2",
|
|
1480
|
+
"sm:absolute sm:right-4 sm:top-4 sm:pt-0 sm:mb-0 sm:z-10",
|
|
1481
|
+
className
|
|
1482
|
+
), children: Array.from({ length: totalSteps }).map((_, index) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1483
|
+
"div",
|
|
1484
|
+
{
|
|
1485
|
+
className: cn(
|
|
1486
|
+
"h-1.5 w-6 rounded-full transition-colors",
|
|
1487
|
+
index < currentStep - 1 ? "bg-primary" : index === currentStep - 1 ? "bg-primary/50" : "bg-muted"
|
|
1488
|
+
)
|
|
1489
|
+
},
|
|
1490
|
+
index
|
|
1491
|
+
)) });
|
|
1492
|
+
DialogSteps.displayName = "DialogSteps";
|
|
1447
1493
|
var DialogTitle = React40__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1448
1494
|
DialogPrimitive__namespace.Title,
|
|
1449
1495
|
{
|
|
@@ -4204,6 +4250,7 @@ exports.ContextMenuSub = ContextMenuSub;
|
|
|
4204
4250
|
exports.ContextMenuSubContent = ContextMenuSubContent;
|
|
4205
4251
|
exports.ContextMenuSubTrigger = ContextMenuSubTrigger;
|
|
4206
4252
|
exports.ContextMenuTrigger = ContextMenuTrigger;
|
|
4253
|
+
exports.CookieBanner = CookieBanner;
|
|
4207
4254
|
exports.Dialog = Dialog;
|
|
4208
4255
|
exports.DialogBody = DialogBody;
|
|
4209
4256
|
exports.DialogClose = DialogClose;
|
|
@@ -4213,6 +4260,7 @@ exports.DialogFooter = DialogFooter;
|
|
|
4213
4260
|
exports.DialogHeader = DialogHeader;
|
|
4214
4261
|
exports.DialogOverlay = DialogOverlay;
|
|
4215
4262
|
exports.DialogPortal = DialogPortal;
|
|
4263
|
+
exports.DialogSteps = DialogSteps;
|
|
4216
4264
|
exports.DialogTitle = DialogTitle;
|
|
4217
4265
|
exports.DialogTrigger = DialogTrigger;
|
|
4218
4266
|
exports.Drawer = Drawer;
|