@luxfi/ui 8.2.3 → 8.2.5

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.
Files changed (54) hide show
  1. package/dist/index.cjs +2008 -85
  2. package/dist/index.css +132 -0
  3. package/dist/index.d.ts +1 -0
  4. package/dist/index.d.ts.map +1 -1
  5. package/dist/index.js +2007 -111
  6. package/dist/site/root-layout/index.cjs +2 -89
  7. package/dist/site/root-layout/index.d.ts +1 -0
  8. package/dist/site/root-layout/index.d.ts.map +1 -1
  9. package/dist/site/root-layout/index.js +2 -88
  10. package/dist/site/site-def/footer/company.d.ts +3 -3
  11. package/package.json +1 -1
  12. package/src/index.ts +5 -0
  13. package/src/site/root-layout/index.tsx +2 -3
  14. package/src/site/style/lux-fonts.css +1 -2
  15. package/dist/site/next/font/font-desc.cjs +0 -2
  16. package/dist/site/next/font/font-desc.d.ts +0 -19
  17. package/dist/site/next/font/font-desc.d.ts.map +0 -1
  18. package/dist/site/next/font/font-desc.js +0 -1
  19. package/dist/site/next/font/fonts.cjs +0 -42
  20. package/dist/site/next/font/fonts.d.ts +0 -4
  21. package/dist/site/next/font/fonts.d.ts.map +0 -1
  22. package/dist/site/next/font/fonts.js +0 -40
  23. package/dist/site/next/font/get-app-router-font-classes.cjs +0 -96
  24. package/dist/site/next/font/get-app-router-font-classes.d.ts +0 -15
  25. package/dist/site/next/font/get-app-router-font-classes.d.ts.map +0 -1
  26. package/dist/site/next/font/get-app-router-font-classes.js +0 -90
  27. package/dist/site/next/font/load-and-return-lux-next-fonts-on-import.cjs +0 -90
  28. package/dist/site/next/font/load-and-return-lux-next-fonts-on-import.d.ts +0 -8
  29. package/dist/site/next/font/load-and-return-lux-next-fonts-on-import.d.ts.map +0 -1
  30. package/dist/site/next/font/load-and-return-lux-next-fonts-on-import.js +0 -84
  31. package/dist/site/next/font/local/InterVariable-Italic.ttf +0 -0
  32. package/dist/site/next/font/local/InterVariable-Italic.woff2 +0 -0
  33. package/dist/site/next/font/local/InterVariable.ttf +0 -0
  34. package/dist/site/next/font/local/InterVariable.woff2 +0 -0
  35. package/dist/site/next/font/local/Zen-Variable.woff2 +0 -0
  36. package/dist/site/next/font/next-font-desc.cjs +0 -2
  37. package/dist/site/next/font/next-font-desc.d.ts +0 -20
  38. package/dist/site/next/font/next-font-desc.d.ts.map +0 -1
  39. package/dist/site/next/font/next-font-desc.js +0 -1
  40. package/dist/site/next/font/pages-router-font-vars.cjs +0 -100
  41. package/dist/site/next/font/pages-router-font-vars.d.ts +0 -3
  42. package/dist/site/next/font/pages-router-font-vars.d.ts.map +0 -1
  43. package/dist/site/next/font/pages-router-font-vars.js +0 -94
  44. package/src/site/next/font/font-desc.ts +0 -18
  45. package/src/site/next/font/fonts.ts +0 -40
  46. package/src/site/next/font/get-app-router-font-classes.ts +0 -19
  47. package/src/site/next/font/load-and-return-lux-next-fonts-on-import.ts +0 -60
  48. package/src/site/next/font/local/InterVariable-Italic.ttf +0 -0
  49. package/src/site/next/font/local/InterVariable-Italic.woff2 +0 -0
  50. package/src/site/next/font/local/InterVariable.ttf +0 -0
  51. package/src/site/next/font/local/InterVariable.woff2 +0 -0
  52. package/src/site/next/font/local/Zen-Variable.woff2 +0 -0
  53. package/src/site/next/font/next-font-desc.ts +0 -29
  54. package/src/site/next/font/pages-router-font-vars.tsx +0 -18
package/dist/index.cjs CHANGED
@@ -27,6 +27,23 @@ var inputOtp = require('input-otp');
27
27
  var core = require('@dnd-kit/core');
28
28
  var sortable = require('@dnd-kit/sortable');
29
29
  var qrcode_react = require('qrcode.react');
30
+ var primitives = require('@hanzo/ui/primitives');
31
+ var logo = require('@luxfi/logo');
32
+ var reactHookForm = require('react-hook-form');
33
+ var zod = require('zod');
34
+ var zod$1 = require('@hookform/resolvers/zod');
35
+ var validator = require('validator');
36
+ var Link5 = require('next/link');
37
+ var react = require('@hanzo/iam/react');
38
+ var navigation = require('next/navigation');
39
+ var commerce = require('@hanzo/commerce');
40
+ var mobx = require('mobx');
41
+ var mobxReactLite = require('mobx-react-lite');
42
+ require('usehooks-ts');
43
+ var google = require('@next/third-parties/google');
44
+ var Script = require('next/script');
45
+ var reactTooltip = require('react-tooltip');
46
+ var emblaCarouselAutoplay = require('embla-carousel-autoplay');
30
47
 
31
48
  function _interopDefault (e) { return e && e.__esModule ? e : { default: e }; }
32
49
 
@@ -52,6 +69,10 @@ var React64__namespace = /*#__PURE__*/_interopNamespace(React64);
52
69
  var Editor__default = /*#__PURE__*/_interopDefault(Editor);
53
70
  var ResizablePrimitive__namespace = /*#__PURE__*/_interopNamespace(ResizablePrimitive);
54
71
  var RechartsPrimitive__namespace = /*#__PURE__*/_interopNamespace(RechartsPrimitive);
72
+ var validator__default = /*#__PURE__*/_interopDefault(validator);
73
+ var Link5__default = /*#__PURE__*/_interopDefault(Link5);
74
+ var Script__default = /*#__PURE__*/_interopDefault(Script);
75
+ var emblaCarouselAutoplay__default = /*#__PURE__*/_interopDefault(emblaCarouselAutoplay);
55
76
 
56
77
  var __defProp = Object.defineProperty;
57
78
  var __require = /* @__PURE__ */ ((x) => typeof require !== "undefined" ? require : typeof Proxy !== "undefined" ? new Proxy(x, {
@@ -639,7 +660,7 @@ var DrawerStateContext = React64__namespace.createContext({
639
660
  var DrawerRoot = (props2) => {
640
661
  const {
641
662
  children,
642
- open,
663
+ open: open2,
643
664
  defaultOpen,
644
665
  onOpenChange,
645
666
  placement = "right",
@@ -647,8 +668,8 @@ var DrawerRoot = (props2) => {
647
668
  size = "md"
648
669
  } = props2;
649
670
  const [uncontrolled, setUncontrolled] = React64__namespace.useState(defaultOpen ?? false);
650
- const isControlled = open !== void 0;
651
- const isOpen = isControlled ? open : uncontrolled;
671
+ const isControlled = open2 !== void 0;
672
+ const isOpen = isControlled ? open2 : uncontrolled;
652
673
  const narrow = useIsNarrow();
653
674
  const setOpen = React64__namespace.useCallback((nextOpen) => {
654
675
  if (!isControlled) setUncontrolled(nextOpen);
@@ -681,12 +702,12 @@ var DrawerContent = React64__namespace.forwardRef(
681
702
  const { children, portalled = true, portalRef: _portalRef, offset: _offset, backdrop = true, ...rest } = props2;
682
703
  const placement = React64__namespace.useContext(DrawerPlacementContext);
683
704
  const size = React64__namespace.useContext(DrawerSizeContext);
684
- const { open, setOpen, modal, narrow } = React64__namespace.useContext(DrawerStateContext);
705
+ const { open: open2, setOpen, modal, narrow } = React64__namespace.useContext(DrawerStateContext);
685
706
  if (narrow) {
686
707
  return /* @__PURE__ */ jsxRuntime.jsxs(
687
708
  gui.Sheet,
688
709
  {
689
- open,
710
+ open: open2,
690
711
  onOpenChange: setOpen,
691
712
  modal,
692
713
  dismissOnSnapToBottom: true,
@@ -795,7 +816,7 @@ var ROW = {
795
816
  };
796
817
  var MenuRoot = ({
797
818
  children,
798
- open,
819
+ open: open2,
799
820
  defaultOpen,
800
821
  onOpenChange,
801
822
  positioning,
@@ -803,7 +824,7 @@ var MenuRoot = ({
803
824
  }) => /* @__PURE__ */ jsxRuntime.jsx(
804
825
  gui.Menu,
805
826
  {
806
- open,
827
+ open: open2,
807
828
  defaultOpen,
808
829
  onOpenChange: onOpenChange ? (isOpen) => onOpenChange({ open: isOpen }) : void 0,
809
830
  modal,
@@ -872,8 +893,8 @@ var MenuSeparator = (props2) => /* @__PURE__ */ jsxRuntime.jsx(
872
893
  ...props2
873
894
  }
874
895
  );
875
- var MenuItemGroup = ({ title, children, ...rest }) => /* @__PURE__ */ jsxRuntime.jsxs(gui.Menu.Group, { unstyled: true, ...rest, children: [
876
- title && /* @__PURE__ */ jsxRuntime.jsx(
896
+ var MenuItemGroup = ({ title: title2, children, ...rest }) => /* @__PURE__ */ jsxRuntime.jsxs(gui.Menu.Group, { unstyled: true, ...rest, children: [
897
+ title2 && /* @__PURE__ */ jsxRuntime.jsx(
877
898
  gui.Menu.Label,
878
899
  {
879
900
  unstyled: true,
@@ -884,7 +905,7 @@ var MenuItemGroup = ({ title, children, ...rest }) => /* @__PURE__ */ jsxRuntime
884
905
  userSelect: "none",
885
906
  opacity: 0.6,
886
907
  color: TEXT,
887
- children: title
908
+ children: title2
888
909
  }
889
910
  ),
890
911
  children
@@ -977,7 +998,7 @@ var Row = ({ item, onDone, menu }) => {
977
998
  return menu ? /* @__PURE__ */ jsxRuntime.jsx(MenuItem, { value: item.id, asChild: true, children: control }) : control;
978
999
  };
979
1000
  var Switcher = ({
980
- title,
1001
+ title: title2,
981
1002
  label,
982
1003
  icon,
983
1004
  items,
@@ -990,13 +1011,13 @@ var Switcher = ({
990
1011
  align = "start",
991
1012
  testId
992
1013
  }) => {
993
- const [open, setOpen] = React64__namespace.useState(false);
1014
+ const [open2, setOpen] = React64__namespace.useState(false);
994
1015
  const narrow = useIsNarrow();
995
1016
  const close = React64__namespace.useCallback(() => setOpen(false), []);
996
1017
  const message = status === "loading" ? "Loading\u2026" : status === "error" ? error ?? "Could not reach IAM." : status === "anonymous" ? null : items.length === 0 ? empty : null;
997
1018
  const rows = status === "anonymous" && onSignIn ? [{ id: "sign-in", label: signInLabel, icon: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.User, { "aria-hidden": "true", style: ui.css("h-4 w-4") }), onSelect: onSignIn }] : status === "ready" ? items : [];
998
1019
  const panel = (menu) => /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
999
- /* @__PURE__ */ jsxRuntime.jsx(ui.Box, { className: "px-2 pb-1 pt-1 text-[11px] font-semibold uppercase tracking-wide opacity-55", children: title }),
1020
+ /* @__PURE__ */ jsxRuntime.jsx(ui.Box, { className: "px-2 pb-1 pt-1 text-[11px] font-semibold uppercase tracking-wide opacity-55", children: title2 }),
1000
1021
  message ? /* @__PURE__ */ jsxRuntime.jsx(ui.Box, { "data-testid": "chrome-message", className: "px-2 py-2 text-sm opacity-70", children: message }) : null,
1001
1022
  rows.map((item) => /* @__PURE__ */ jsxRuntime.jsx(Row, { item, onDone: close, menu }, item.id)),
1002
1023
  footer.length > 0 ? /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
@@ -1010,9 +1031,9 @@ var Switcher = ({
1010
1031
  tag: "button",
1011
1032
  type: "button",
1012
1033
  "data-testid": testId,
1013
- "aria-label": title,
1034
+ "aria-label": title2,
1014
1035
  "aria-haspopup": "menu",
1015
- "aria-expanded": open,
1036
+ "aria-expanded": open2,
1016
1037
  className: ui.cn(
1017
1038
  "flex max-w-[14rem] items-center gap-2 rounded-md px-2 py-1.5 text-sm font-medium",
1018
1039
  "hover:bg-[rgba(127,127,127,0.14)]"
@@ -1025,10 +1046,10 @@ var Switcher = ({
1025
1046
  }
1026
1047
  );
1027
1048
  if (narrow) {
1028
- return /* @__PURE__ */ jsxRuntime.jsxs(DrawerRoot, { open, onOpenChange: (d) => setOpen(d.open), placement: "bottom", size: "md", children: [
1049
+ return /* @__PURE__ */ jsxRuntime.jsxs(DrawerRoot, { open: open2, onOpenChange: (d) => setOpen(d.open), placement: "bottom", size: "md", children: [
1029
1050
  React64__namespace.cloneElement(trigger, { onClick: () => setOpen(true) }),
1030
1051
  /* @__PURE__ */ jsxRuntime.jsxs(DrawerContent, { "data-testid": testId ? `${testId}-panel` : void 0, children: [
1031
- /* @__PURE__ */ jsxRuntime.jsx(DrawerHeader, { children: /* @__PURE__ */ jsxRuntime.jsx(DrawerTitle, { children: title }) }),
1052
+ /* @__PURE__ */ jsxRuntime.jsx(DrawerHeader, { children: /* @__PURE__ */ jsxRuntime.jsx(DrawerTitle, { children: title2 }) }),
1032
1053
  /* @__PURE__ */ jsxRuntime.jsx(DrawerBody, { children: panel(false) })
1033
1054
  ] })
1034
1055
  ] });
@@ -1036,7 +1057,7 @@ var Switcher = ({
1036
1057
  return /* @__PURE__ */ jsxRuntime.jsxs(
1037
1058
  MenuRoot,
1038
1059
  {
1039
- open,
1060
+ open: open2,
1040
1061
  onOpenChange: (d) => setOpen(d.open),
1041
1062
  positioning: { placement: align === "end" ? "bottom-end" : "bottom-start" },
1042
1063
  children: [
@@ -1210,7 +1231,7 @@ var AppNav = ({
1210
1231
  };
1211
1232
  var IndicatorIcon = () => /* @__PURE__ */ jsxRuntime.jsx("svg", { width: "20", height: "20", viewBox: "0 0 20 20", fill: "none", xmlns: "http://www.w3.org/2000/svg", children: /* @__PURE__ */ jsxRuntime.jsx("path", { d: "M7.5 15L12.5 10L7.5 5", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round" }) });
1212
1233
  var BAR = "var(--color-text-primary)";
1213
- var Indicator2 = ({ open, variant }) => variant === "faq" ? /* @__PURE__ */ jsxRuntime.jsxs(gui.XStack, { width: 12, height: 12, flexShrink: 0, alignItems: "center", justifyContent: "center", position: "relative", children: [
1234
+ var Indicator2 = ({ open: open2, variant }) => variant === "faq" ? /* @__PURE__ */ jsxRuntime.jsxs(gui.XStack, { width: 12, height: 12, flexShrink: 0, alignItems: "center", justifyContent: "center", position: "relative", children: [
1214
1235
  /* @__PURE__ */ jsxRuntime.jsx(gui.View, { position: "absolute", width: "100%", height: 2, borderRadius: 2, backgroundColor: BAR }),
1215
1236
  /* @__PURE__ */ jsxRuntime.jsx(
1216
1237
  gui.View,
@@ -1220,10 +1241,10 @@ var Indicator2 = ({ open, variant }) => variant === "faq" ? /* @__PURE__ */ jsxR
1220
1241
  height: "100%",
1221
1242
  borderRadius: 2,
1222
1243
  backgroundColor: BAR,
1223
- rotate: open ? "90deg" : "0deg"
1244
+ rotate: open2 ? "90deg" : "0deg"
1224
1245
  }
1225
1246
  )
1226
- ] }) : /* @__PURE__ */ jsxRuntime.jsx(gui.XStack, { flexShrink: 0, alignItems: "center", rotate: open ? "270deg" : "180deg", children: /* @__PURE__ */ jsxRuntime.jsx(IndicatorIcon, {}) });
1247
+ ] }) : /* @__PURE__ */ jsxRuntime.jsx(gui.XStack, { flexShrink: 0, alignItems: "center", rotate: open2 ? "270deg" : "180deg", children: /* @__PURE__ */ jsxRuntime.jsx(IndicatorIcon, {}) });
1227
1248
  var Variant = React64__namespace.createContext(void 0);
1228
1249
  var AccordionRoot = ({
1229
1250
  value: value2,
@@ -1283,10 +1304,10 @@ var AccordionItemTrigger = ({
1283
1304
  cursor: "pointer",
1284
1305
  className: "lux-accordion-trigger",
1285
1306
  ...rest,
1286
- children: (({ open }) => /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
1287
- placement === "start" && !noIndicator && /* @__PURE__ */ jsxRuntime.jsx(Indicator2, { open, variant }),
1307
+ children: (({ open: open2 }) => /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
1308
+ placement === "start" && !noIndicator && /* @__PURE__ */ jsxRuntime.jsx(Indicator2, { open: open2, variant }),
1288
1309
  ink(children, void 0, { color: "inherit", textAlign: "left" }),
1289
- placement === "end" && !noIndicator && /* @__PURE__ */ jsxRuntime.jsx(Indicator2, { open, variant })
1310
+ placement === "end" && !noIndicator && /* @__PURE__ */ jsxRuntime.jsx(Indicator2, { open: open2, variant })
1290
1311
  ] }))
1291
1312
  }
1292
1313
  ) });
@@ -1406,7 +1427,7 @@ var INDICATOR_SIZE = {
1406
1427
  var Alert = React64__namespace.forwardRef(
1407
1428
  function Alert2(props2, ref2) {
1408
1429
  const {
1409
- title,
1430
+ title: title2,
1410
1431
  children,
1411
1432
  icon,
1412
1433
  closable,
@@ -1495,7 +1516,7 @@ var Alert = React64__namespace.forwardRef(
1495
1516
  children: [
1496
1517
  iconElement,
1497
1518
  children ? /* @__PURE__ */ jsxRuntime.jsxs(ContentFrame, { flex: 1, alignItems: inline ? "center" : void 0, children: [
1498
- title && /* @__PURE__ */ jsxRuntime.jsx(gui.Text, { fontWeight: "600", fontSize, color: ALERT_FG, children: title }),
1519
+ title2 && /* @__PURE__ */ jsxRuntime.jsx(gui.Text, { fontWeight: "600", fontSize, color: ALERT_FG, children: title2 }),
1499
1520
  /* @__PURE__ */ jsxRuntime.jsx(
1500
1521
  gui.XStack,
1501
1522
  {
@@ -1506,7 +1527,7 @@ var Alert = React64__namespace.forwardRef(
1506
1527
  children: ink(children, void 0, { fontSize, color: ALERT_FG })
1507
1528
  }
1508
1529
  )
1509
- ] }) : /* @__PURE__ */ jsxRuntime.jsx(gui.Text, { flex: 1, fontWeight: "600", fontSize, color: ALERT_FG, children: title }),
1530
+ ] }) : /* @__PURE__ */ jsxRuntime.jsx(gui.Text, { flex: 1, fontWeight: "600", fontSize, color: ALERT_FG, children: title2 }),
1510
1531
  endElement,
1511
1532
  closable && /* @__PURE__ */ jsxRuntime.jsx(gui.View, { position: "relative", alignSelf: "flex-start", children: /* @__PURE__ */ jsxRuntime.jsx(CloseButton, { onClick: handleClose }) })
1512
1533
  ]
@@ -1651,7 +1672,7 @@ var Tooltip = React64__namespace.forwardRef(
1651
1672
  interactive,
1652
1673
  positioning
1653
1674
  } = props2;
1654
- const [open, setOpen] = React64__namespace.useState(defaultOpen);
1675
+ const [open2, setOpen] = React64__namespace.useState(defaultOpen);
1655
1676
  const timeoutRef = React64__namespace.useRef(null);
1656
1677
  const isMobile = useIsTouch();
1657
1678
  const handleOpenChange = React64__namespace.useCallback((nextOpen) => {
@@ -1666,12 +1687,12 @@ var Tooltip = React64__namespace.forwardRef(
1666
1687
  }, nextOpen ? openDelay : closeDelay);
1667
1688
  }, [closeDelay, openDelay, onOpenChange]);
1668
1689
  const handleClickAway = React64__namespace.useCallback(() => {
1669
- if (open) handleOpenChangeManual(false);
1670
- }, [open, handleOpenChangeManual]);
1690
+ if (open2) handleOpenChangeManual(false);
1691
+ }, [open2, handleOpenChangeManual]);
1671
1692
  const triggerRef = usehooks.useClickAway(handleClickAway);
1672
1693
  const handleTriggerClick = React64__namespace.useCallback(() => {
1673
- handleOpenChangeManual(!open);
1674
- }, [handleOpenChangeManual, open]);
1694
+ handleOpenChangeManual(!open2);
1695
+ }, [handleOpenChangeManual, open2]);
1675
1696
  const handleContentClick = React64__namespace.useCallback((event) => {
1676
1697
  event.stopPropagation();
1677
1698
  if (interactive) {
@@ -1697,7 +1718,7 @@ var Tooltip = React64__namespace.forwardRef(
1697
1718
  return /* @__PURE__ */ jsxRuntime.jsx(gui.TooltipGroup, { delay: openDelay, children: /* @__PURE__ */ jsxRuntime.jsxs(
1698
1719
  gui.Tooltip,
1699
1720
  {
1700
- open,
1721
+ open: open2,
1701
1722
  onOpenChange: handleOpenChange,
1702
1723
  delay: { open: openDelay, close: closeDelay },
1703
1724
  placement,
@@ -2858,7 +2879,7 @@ function sizeClasses(size) {
2858
2879
  }
2859
2880
  var DialogRoot = ({
2860
2881
  children,
2861
- open,
2882
+ open: open2,
2862
2883
  defaultOpen,
2863
2884
  onOpenChange,
2864
2885
  size = "md",
@@ -2875,7 +2896,7 @@ var DialogRoot = ({
2875
2896
  return /* @__PURE__ */ jsxRuntime.jsx(DialogSizeContext.Provider, { value: ctx, children: /* @__PURE__ */ jsxRuntime.jsx(
2876
2897
  gui.Dialog,
2877
2898
  {
2878
- open,
2899
+ open: open2,
2879
2900
  defaultOpen,
2880
2901
  onOpenChange: handleOpenChange,
2881
2902
  modal,
@@ -3014,10 +3035,10 @@ var ICONS = {};
3014
3035
  var MUTED = "var(--color-text-secondary)";
3015
3036
  var EmptyState = React64__namespace.forwardRef(
3016
3037
  function EmptyState2(props2, ref2) {
3017
- const { title, description, term, type = "query", icon, children, className: className2, ...rest } = props2;
3038
+ const { title: title2, description, term, type = "query", icon, children, className: className2, ...rest } = props2;
3018
3039
  const titleContent = (() => {
3019
- if (title) {
3020
- return title;
3040
+ if (title2) {
3041
+ return title2;
3021
3042
  }
3022
3043
  if (type === "stats") {
3023
3044
  return "Collecting data";
@@ -3913,7 +3934,7 @@ var PositioningContext = React64__namespace.createContext({
3913
3934
  var PopoverRoot = (props2) => {
3914
3935
  const {
3915
3936
  children,
3916
- open,
3937
+ open: open2,
3917
3938
  defaultOpen,
3918
3939
  onOpenChange,
3919
3940
  positioning,
@@ -3960,7 +3981,7 @@ var PopoverRoot = (props2) => {
3960
3981
  return /* @__PURE__ */ jsxRuntime.jsx(PositioningContext.Provider, { value: positioningValue, children: /* @__PURE__ */ jsxRuntime.jsx(
3961
3982
  gui.Popover,
3962
3983
  {
3963
- open,
3984
+ open: open2,
3964
3985
  defaultOpen,
3965
3986
  onOpenChange: handleOpenChange,
3966
3987
  placement,
@@ -4563,8 +4584,8 @@ var SelectRoot = React64__namespace.forwardRef(
4563
4584
  const selectedItems = React64__namespace.useMemo(() => {
4564
4585
  return currentValue.map((v) => collection.items.find((item) => item.value === v)).filter(Boolean);
4565
4586
  }, [currentValue, collection.items]);
4566
- const [open, setOpen] = React64__namespace.useState(defaultOpen ?? false);
4567
- const isOpen = openProp ?? open;
4587
+ const [open2, setOpen] = React64__namespace.useState(defaultOpen ?? false);
4588
+ const isOpen = openProp ?? open2;
4568
4589
  const handleOpenChange = React64__namespace.useCallback((nextOpen) => {
4569
4590
  setOpen(nextOpen);
4570
4591
  onOpenChange?.(nextOpen);
@@ -5881,8 +5902,8 @@ var One = ({ entry }) => /* @__PURE__ */ jsxRuntime.jsxs(
5881
5902
  gui.Toast,
5882
5903
  {
5883
5904
  duration: entry.duration ?? DURATION,
5884
- onOpenChange: (open) => {
5885
- if (!open) remove(entry.id);
5905
+ onOpenChange: (open2) => {
5906
+ if (!open2) remove(entry.id);
5886
5907
  },
5887
5908
  unstyled: true,
5888
5909
  flexDirection: "column",
@@ -6694,7 +6715,7 @@ var PnlDiagram = React64__namespace.forwardRef(
6694
6715
  React64__namespace.useEffect(() => {
6695
6716
  const el = containerRef.current;
6696
6717
  if (!el) return;
6697
- const observer2 = new ResizeObserver((entries2) => {
6718
+ const observer11 = new ResizeObserver((entries2) => {
6698
6719
  const entry = entries2[0];
6699
6720
  if (entry) {
6700
6721
  setDims({
@@ -6703,8 +6724,8 @@ var PnlDiagram = React64__namespace.forwardRef(
6703
6724
  });
6704
6725
  }
6705
6726
  });
6706
- observer2.observe(el);
6707
- return () => observer2.disconnect();
6727
+ observer11.observe(el);
6728
+ return () => observer11.disconnect();
6708
6729
  }, []);
6709
6730
  const allStrikes = legs.map((l) => l.strike);
6710
6731
  const minStrike = Math.min(...allStrikes, spotPrice);
@@ -8542,7 +8563,7 @@ Grid3D.displayName = "Grid3D";
8542
8563
  var Grid3DCard = React64__namespace.forwardRef(
8543
8564
  ({
8544
8565
  className: className2,
8545
- title,
8566
+ title: title2,
8546
8567
  description,
8547
8568
  image,
8548
8569
  badge,
@@ -8570,14 +8591,14 @@ var Grid3DCard = React64__namespace.forwardRef(
8570
8591
  {
8571
8592
  tag: "img",
8572
8593
  src: image,
8573
- alt: title || "",
8594
+ alt: title2 || "",
8574
8595
  className: "w-full h-full object-cover transition-transform duration-300 group-hover:scale-110"
8575
8596
  }
8576
8597
  ),
8577
8598
  badge && /* @__PURE__ */ jsxRuntime.jsx(ui.Box, { className: "absolute top-2 right-2 px-2 py-1 text-xs rounded-full bg-primary text-primary-foreground", children: badge })
8578
8599
  ] }),
8579
8600
  /* @__PURE__ */ jsxRuntime.jsxs(ui.Box, { className: "flex-1 p-4 flex flex-col justify-between", children: [
8580
- title && /* @__PURE__ */ jsxRuntime.jsx(ui.Box, { tag: "h3", className: "font-semibold text-lg mb-2 line-clamp-2 group-hover:text-primary transition-colors", children: title }),
8601
+ title2 && /* @__PURE__ */ jsxRuntime.jsx(ui.Box, { tag: "h3", className: "font-semibold text-lg mb-2 line-clamp-2 group-hover:text-primary transition-colors", children: title2 }),
8581
8602
  description && /* @__PURE__ */ jsxRuntime.jsx(ui.Box, { tag: "p", className: "text-sm text-muted-foreground line-clamp-3 mb-4", children: description }),
8582
8603
  children && /* @__PURE__ */ jsxRuntime.jsx(ui.Box, { className: "mt-auto", children })
8583
8604
  ] }),
@@ -17557,7 +17578,7 @@ function inView(elementOrSelector, onStart, { root, margin: rootMargin, amount =
17557
17578
  if (typeof newOnEnd === "function") {
17558
17579
  activeIntersections.set(entry.target, newOnEnd);
17559
17580
  } else {
17560
- observer2.unobserve(entry.target);
17581
+ observer11.unobserve(entry.target);
17561
17582
  }
17562
17583
  } else if (typeof onEnd === "function") {
17563
17584
  onEnd(entry);
@@ -17565,13 +17586,13 @@ function inView(elementOrSelector, onStart, { root, margin: rootMargin, amount =
17565
17586
  }
17566
17587
  });
17567
17588
  };
17568
- const observer2 = new IntersectionObserver(onIntersectionChange, {
17589
+ const observer11 = new IntersectionObserver(onIntersectionChange, {
17569
17590
  root,
17570
17591
  rootMargin,
17571
17592
  threshold: typeof amount === "number" ? amount : thresholds[amount]
17572
17593
  });
17573
- elements.forEach((element) => observer2.observe(element));
17574
- return () => observer2.disconnect();
17594
+ elements.forEach((element) => observer11.observe(element));
17595
+ return () => observer11.disconnect();
17575
17596
  }
17576
17597
 
17577
17598
  // ../../node_modules/.pnpm/framer-motion@12.38.0_@emotion+is-prop-valid@1.4.0_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/framer-motion/dist/es/utils/use-in-view.mjs
@@ -18608,7 +18629,7 @@ ModelViewer3DPreset.Basic.displayName = "ModelViewer3DPreset.Basic";
18608
18629
  ModelViewer3DPreset.Advanced.displayName = "ModelViewer3DPreset.Advanced";
18609
18630
  ModelViewer3DPreset.Presentation.displayName = "ModelViewer3DPreset.Presentation";
18610
18631
  var Pin3D = React64__namespace.forwardRef(
18611
- ({ className: className2, title, href, children, ...props2 }, ref2) => {
18632
+ ({ className: className2, title: title2, href, children, ...props2 }, ref2) => {
18612
18633
  return /* @__PURE__ */ jsxRuntime.jsxs(
18613
18634
  ui.Box,
18614
18635
  {
@@ -19677,7 +19698,7 @@ var AgentCard = ({
19677
19698
  );
19678
19699
  };
19679
19700
  var CreateAgentDialog = ({ onAgentCreate }) => {
19680
- const [open, setOpen] = React64.useState(false);
19701
+ const [open2, setOpen] = React64.useState(false);
19681
19702
  const [formData, setFormData] = React64.useState({
19682
19703
  name: "",
19683
19704
  type: "research",
@@ -19702,7 +19723,7 @@ var CreateAgentDialog = ({ onAgentCreate }) => {
19702
19723
  });
19703
19724
  setOpen(false);
19704
19725
  };
19705
- return /* @__PURE__ */ jsxRuntime.jsxs(ui.Dialog, { open, onOpenChange: setOpen, children: [
19726
+ return /* @__PURE__ */ jsxRuntime.jsxs(ui.Dialog, { open: open2, onOpenChange: setOpen, children: [
19706
19727
  /* @__PURE__ */ jsxRuntime.jsx(ui.DialogTrigger, { asChild: true, children: /* @__PURE__ */ jsxRuntime.jsxs(Button, { children: [
19707
19728
  /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Plus, { style: ui.css("h-4 w-4 mr-2") }),
19708
19729
  "Create Agent"
@@ -19769,7 +19790,7 @@ var CreateAgentDialog = ({ onAgentCreate }) => {
19769
19790
  ] });
19770
19791
  };
19771
19792
  var TaskAssignmentDialog = ({ agents, onTaskAssign }) => {
19772
- const [open, setOpen] = React64.useState(false);
19793
+ const [open2, setOpen] = React64.useState(false);
19773
19794
  const [taskData, setTaskData] = React64.useState({
19774
19795
  title: "",
19775
19796
  description: "",
@@ -19799,7 +19820,7 @@ var TaskAssignmentDialog = ({ agents, onTaskAssign }) => {
19799
19820
  });
19800
19821
  setOpen(false);
19801
19822
  };
19802
- return /* @__PURE__ */ jsxRuntime.jsxs(ui.Dialog, { open, onOpenChange: setOpen, children: [
19823
+ return /* @__PURE__ */ jsxRuntime.jsxs(ui.Dialog, { open: open2, onOpenChange: setOpen, children: [
19803
19824
  /* @__PURE__ */ jsxRuntime.jsx(ui.DialogTrigger, { asChild: true, children: /* @__PURE__ */ jsxRuntime.jsxs(Button, { variant: "outline", children: [
19804
19825
  /* @__PURE__ */ jsxRuntime.jsx(lucideReact.MessageSquare, { style: ui.css("h-4 w-4 mr-2") }),
19805
19826
  "Assign Task"
@@ -29595,7 +29616,7 @@ var CodeTerminal = React64__namespace.forwardRef(
29595
29616
  className: className2,
29596
29617
  theme,
29597
29618
  size,
29598
- title = "Terminal",
29619
+ title: title2 = "Terminal",
29599
29620
  prompt = "$",
29600
29621
  maxLines = 1e3,
29601
29622
  showLineNumbers = false,
@@ -29774,7 +29795,7 @@ var CodeTerminal = React64__namespace.forwardRef(
29774
29795
  /* @__PURE__ */ jsxRuntime.jsx(ui.Box, { className: "w-3 h-3 rounded-full bg-[var(--lux-state-success)]" })
29775
29796
  ] }),
29776
29797
  /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Terminal, { style: ui.css("h-4 w-4") }),
29777
- /* @__PURE__ */ jsxRuntime.jsx(ui.Box, { tag: "span", className: "text-sm font-medium", children: title }),
29798
+ /* @__PURE__ */ jsxRuntime.jsx(ui.Box, { tag: "span", className: "text-sm font-medium", children: title2 }),
29778
29799
  lines.length > 0 && /* @__PURE__ */ jsxRuntime.jsxs(ui.Box, { tag: "span", className: "text-xs text-muted-foreground", children: [
29779
29800
  lines.length,
29780
29801
  " lines"
@@ -29867,9 +29888,9 @@ var CodeTerminal = React64__namespace.forwardRef(
29867
29888
  }
29868
29889
  );
29869
29890
  CodeTerminal.displayName = "CodeTerminal";
29870
- var CollaborationNavigationBar = React64__namespace.forwardRef(({ className: className2, title, collaborators = [], ...props2 }, ref2) => {
29891
+ var CollaborationNavigationBar = React64__namespace.forwardRef(({ className: className2, title: title2, collaborators = [], ...props2 }, ref2) => {
29871
29892
  return /* @__PURE__ */ jsxRuntime.jsx(ui.Box, { tag: "nav", ref: ref2, className: ui.cn("border-b", className2), ...props2, children: /* @__PURE__ */ jsxRuntime.jsxs(ui.Box, { className: "container flex h-16 items-center justify-between", children: [
29872
- /* @__PURE__ */ jsxRuntime.jsx(ui.Box, { tag: "h2", className: "text-lg font-semibold", children: title }),
29893
+ /* @__PURE__ */ jsxRuntime.jsx(ui.Box, { tag: "h2", className: "text-lg font-semibold", children: title2 }),
29873
29894
  /* @__PURE__ */ jsxRuntime.jsxs(ui.Box, { className: "flex items-center gap-3", children: [
29874
29895
  /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Users, { style: ui.css("h-5 w-5 text-muted-foreground") }),
29875
29896
  /* @__PURE__ */ jsxRuntime.jsxs(ui.Box, { className: "flex -space-x-2", children: [
@@ -29935,15 +29956,15 @@ function Combobox({
29935
29956
  placeholder = "Select option...",
29936
29957
  emptyText = "No option found."
29937
29958
  }) {
29938
- const [open, setOpen] = React64__namespace.useState(false);
29959
+ const [open2, setOpen] = React64__namespace.useState(false);
29939
29960
  const [searchValue, setSearchValue] = React64__namespace.useState("");
29940
- return /* @__PURE__ */ jsxRuntime.jsxs(ui.Popover, { open, onOpenChange: setOpen, children: [
29961
+ return /* @__PURE__ */ jsxRuntime.jsxs(ui.Popover, { open: open2, onOpenChange: setOpen, children: [
29941
29962
  /* @__PURE__ */ jsxRuntime.jsx(ui.PopoverTrigger, { asChild: true, children: /* @__PURE__ */ jsxRuntime.jsxs(
29942
29963
  Button,
29943
29964
  {
29944
29965
  variant: "outline",
29945
29966
  role: "combobox",
29946
- "aria-expanded": open,
29967
+ "aria-expanded": open2,
29947
29968
  ...ui.sx("w-full justify-between"),
29948
29969
  children: [
29949
29970
  value2 ? options.find((option) => option.value === value2)?.label : placeholder,
@@ -30141,9 +30162,9 @@ var Cursor = React64__namespace.forwardRef(
30141
30162
  }
30142
30163
  );
30143
30164
  Cursor.displayName = "Cursor";
30144
- var DashboardNavigationBar = React64__namespace.forwardRef(({ className: className2, title, user, ...props2 }, ref2) => {
30165
+ var DashboardNavigationBar = React64__namespace.forwardRef(({ className: className2, title: title2, user, ...props2 }, ref2) => {
30145
30166
  return /* @__PURE__ */ jsxRuntime.jsx(ui.Box, { tag: "nav", ref: ref2, className: ui.cn("border-b", className2), ...props2, children: /* @__PURE__ */ jsxRuntime.jsxs(ui.Box, { className: "container flex h-16 items-center justify-between", children: [
30146
- /* @__PURE__ */ jsxRuntime.jsx(ui.Box, { tag: "h1", className: "text-xl font-semibold", children: title }),
30167
+ /* @__PURE__ */ jsxRuntime.jsx(ui.Box, { tag: "h1", className: "text-xl font-semibold", children: title2 }),
30147
30168
  /* @__PURE__ */ jsxRuntime.jsxs(ui.Box, { className: "flex items-center gap-4", children: [
30148
30169
  /* @__PURE__ */ jsxRuntime.jsx(Button, { variant: "ghost", size: "icon", children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Search, { style: ui.css("h-5 w-5") }) }),
30149
30170
  /* @__PURE__ */ jsxRuntime.jsx(Button, { variant: "ghost", size: "icon", children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Bell, { style: ui.css("h-5 w-5") }) }),
@@ -31520,7 +31541,7 @@ function KanbanColumnComponent({
31520
31541
  );
31521
31542
  }
31522
31543
  function CardFormDialog({
31523
- open,
31544
+ open: open2,
31524
31545
  onOpenChange,
31525
31546
  card,
31526
31547
  onSave,
@@ -31566,7 +31587,7 @@ function CardFormDialog({
31566
31587
  });
31567
31588
  }
31568
31589
  }, [card]);
31569
- return /* @__PURE__ */ jsxRuntime.jsx(ui.Dialog, { open, onOpenChange, children: /* @__PURE__ */ jsxRuntime.jsxs(ui.DialogContent, { ...ui.sx("max-w-md"), children: [
31590
+ return /* @__PURE__ */ jsxRuntime.jsx(ui.Dialog, { open: open2, onOpenChange, children: /* @__PURE__ */ jsxRuntime.jsxs(ui.DialogContent, { ...ui.sx("max-w-md"), children: [
31570
31591
  /* @__PURE__ */ jsxRuntime.jsxs(ui.DialogHeader, { children: [
31571
31592
  /* @__PURE__ */ jsxRuntime.jsx(ui.DialogTitle, { children: card ? "Edit Card" : "Create Card" }),
31572
31593
  /* @__PURE__ */ jsxRuntime.jsx(ui.DialogDescription, { children: card ? "Update the card details below." : "Create a new card for your kanban board." })
@@ -31947,7 +31968,7 @@ var LimelightNav = React64__namespace.forwardRef(
31947
31968
  const down = (e) => {
31948
31969
  if (e.key === "k" && (e.metaKey || e.ctrlKey)) {
31949
31970
  e.preventDefault();
31950
- setIsOpen((open) => !open);
31971
+ setIsOpen((open2) => !open2);
31951
31972
  }
31952
31973
  };
31953
31974
  document.addEventListener("keydown", down);
@@ -32148,8 +32169,8 @@ var MenuDock = React64__namespace.forwardRef(
32148
32169
  MenuDock.displayName = "MenuDock";
32149
32170
  var BarContext = React64.createContext(null);
32150
32171
  function Menubar({ children, ...rest }) {
32151
- const [open, setOpen] = React64.useState(null);
32152
- return /* @__PURE__ */ jsxRuntime.jsx(BarContext.Provider, { value: { open, setOpen }, children: /* @__PURE__ */ jsxRuntime.jsx(
32172
+ const [open2, setOpen] = React64.useState(null);
32173
+ return /* @__PURE__ */ jsxRuntime.jsx(BarContext.Provider, { value: { open: open2, setOpen }, children: /* @__PURE__ */ jsxRuntime.jsx(
32153
32174
  gui.XStack,
32154
32175
  {
32155
32176
  role: "menubar",
@@ -32170,9 +32191,9 @@ function MenubarMenu({ children }) {
32170
32191
  const bar = React64.useContext(BarContext);
32171
32192
  const [id3] = React64.useState(() => `menubar-${seq += 1}`);
32172
32193
  const [own, setOwn] = React64.useState(false);
32173
- const open = bar ? bar.open === id3 : own;
32194
+ const open2 = bar ? bar.open === id3 : own;
32174
32195
  const setOpen = (next) => bar ? bar.setOpen(next ? id3 : null) : setOwn(next);
32175
- return /* @__PURE__ */ jsxRuntime.jsx(ui.DropdownMenu, { open, onOpenChange: setOpen, children: /* @__PURE__ */ jsxRuntime.jsx(MenuIdContext.Provider, { value: { id: id3, open, setOpen }, children }) });
32196
+ return /* @__PURE__ */ jsxRuntime.jsx(ui.DropdownMenu, { open: open2, onOpenChange: setOpen, children: /* @__PURE__ */ jsxRuntime.jsx(MenuIdContext.Provider, { value: { id: id3, open: open2, setOpen }, children }) });
32176
32197
  }
32177
32198
  var MenuIdContext = React64.createContext(null);
32178
32199
  function MenubarTrigger({ children, ...rest }) {
@@ -34342,10 +34363,10 @@ function SidebarProvider({
34342
34363
  const isMobile = useIsMobile();
34343
34364
  const [openMobile, setOpenMobile] = React64__namespace.useState(false);
34344
34365
  const [_open, _setOpen] = React64__namespace.useState(defaultOpen);
34345
- const open = openProp ?? _open;
34366
+ const open2 = openProp ?? _open;
34346
34367
  const setOpen = React64__namespace.useCallback(
34347
34368
  (value2) => {
34348
- const openState = typeof value2 === "function" ? value2(open) : value2;
34369
+ const openState = typeof value2 === "function" ? value2(open2) : value2;
34349
34370
  if (setOpenProp) {
34350
34371
  setOpenProp(openState);
34351
34372
  } else {
@@ -34353,10 +34374,10 @@ function SidebarProvider({
34353
34374
  }
34354
34375
  document.cookie = `${SIDEBAR_COOKIE_NAME}=${openState}; path=/; max-age=${SIDEBAR_COOKIE_MAX_AGE}`;
34355
34376
  },
34356
- [setOpenProp, open]
34377
+ [setOpenProp, open2]
34357
34378
  );
34358
34379
  const toggleSidebar = React64__namespace.useCallback(() => {
34359
- return isMobile ? setOpenMobile((open2) => !open2) : setOpen((open2) => !open2);
34380
+ return isMobile ? setOpenMobile((open3) => !open3) : setOpen((open3) => !open3);
34360
34381
  }, [isMobile, setOpen, setOpenMobile]);
34361
34382
  React64__namespace.useEffect(() => {
34362
34383
  const handleKeyDown = (event) => {
@@ -34368,18 +34389,18 @@ function SidebarProvider({
34368
34389
  window.addEventListener("keydown", handleKeyDown);
34369
34390
  return () => window.removeEventListener("keydown", handleKeyDown);
34370
34391
  }, [toggleSidebar]);
34371
- const state = open ? "expanded" : "collapsed";
34392
+ const state = open2 ? "expanded" : "collapsed";
34372
34393
  const contextValue = React64__namespace.useMemo(
34373
34394
  () => ({
34374
34395
  state,
34375
- open,
34396
+ open: open2,
34376
34397
  setOpen,
34377
34398
  isMobile,
34378
34399
  openMobile,
34379
34400
  setOpenMobile,
34380
34401
  toggleSidebar
34381
34402
  }),
34382
- [state, open, setOpen, isMobile, openMobile, setOpenMobile, toggleSidebar]
34403
+ [state, open2, setOpen, isMobile, openMobile, setOpenMobile, toggleSidebar]
34383
34404
  );
34384
34405
  return /* @__PURE__ */ jsxRuntime.jsx(SidebarContext.Provider, { value: contextValue, children: /* @__PURE__ */ jsxRuntime.jsx(ui.TooltipProvider, { delay: 0, children: /* @__PURE__ */ jsxRuntime.jsx(
34385
34406
  ui.Box,
@@ -35476,7 +35497,7 @@ var Timeline = React64__namespace.forwardRef(
35476
35497
  setVisibleItems(new Set(items.map((item) => item.id)));
35477
35498
  return;
35478
35499
  }
35479
- const observer2 = new IntersectionObserver(
35500
+ const observer11 = new IntersectionObserver(
35480
35501
  (entries2) => {
35481
35502
  entries2.forEach((entry) => {
35482
35503
  if (entry.isIntersecting) {
@@ -35493,8 +35514,8 @@ var Timeline = React64__namespace.forwardRef(
35493
35514
  }
35494
35515
  );
35495
35516
  const elements = document.querySelectorAll("[data-timeline-id]");
35496
- elements.forEach((el) => observer2.observe(el));
35497
- return () => observer2.disconnect();
35517
+ elements.forEach((el) => observer11.observe(el));
35518
+ return () => observer11.disconnect();
35498
35519
  }, [items, animated]);
35499
35520
  const getStatusIcon = (status) => {
35500
35521
  switch (status) {
@@ -36446,6 +36467,1885 @@ var YouTubePipPlayer = React64__namespace.forwardRef(
36446
36467
  }
36447
36468
  );
36448
36469
  YouTubePipPlayer.displayName = "YouTubePipPlayer";
36470
+ var AccessCodeInput = ({
36471
+ onSuccess,
36472
+ onFail,
36473
+ validCodes,
36474
+ className: className2
36475
+ }) => {
36476
+ const [status, setStatus] = React64.useState();
36477
+ const checkAccessCode = (code2) => {
36478
+ setStatus(void 0);
36479
+ if (code2.length === 6) {
36480
+ setStatus("checking");
36481
+ setTimeout(() => {
36482
+ if (validCodes?.includes(code2) && onSuccess) {
36483
+ setStatus("valid");
36484
+ onSuccess();
36485
+ } else {
36486
+ setStatus("invalid");
36487
+ onFail && onFail();
36488
+ }
36489
+ }, 1e3);
36490
+ }
36491
+ };
36492
+ return /* @__PURE__ */ jsxRuntime.jsxs(ui.Box, { className: ui.cn("flex flex-col gap-2 mx-auto w-full text-center items-center", className2), children: [
36493
+ /* @__PURE__ */ jsxRuntime.jsx(
36494
+ primitives.InputOTP,
36495
+ {
36496
+ className: "mx-auto",
36497
+ maxLength: 6,
36498
+ onInput: (event) => checkAccessCode(event.target.value),
36499
+ render: ({ slots }) => /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
36500
+ /* @__PURE__ */ jsxRuntime.jsxs(primitives.InputOTPGroup, { children: [
36501
+ slots.slice(0, 3).map((slot, index) => /* @__PURE__ */ jsxRuntime.jsx(primitives.InputOTPSlot, { ...slot }, index)),
36502
+ " "
36503
+ ] }),
36504
+ /* @__PURE__ */ jsxRuntime.jsx(primitives.InputOTPSeparator, {}),
36505
+ /* @__PURE__ */ jsxRuntime.jsx(primitives.InputOTPGroup, { children: slots.slice(3).map((slot, index) => /* @__PURE__ */ jsxRuntime.jsx(primitives.InputOTPSlot, { ...slot }, index + 3)) })
36506
+ ] })
36507
+ }
36508
+ ),
36509
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "h-[3rem]", children: status === "checking" ? "Checking access code..." : status === "invalid" ? /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-destructive", children: "Invalid access code!" }) : status === "valid" ? /* @__PURE__ */ jsxRuntime.jsx("span", { children: "Access code is valid! Redirecting..." }) : null })
36510
+ ] });
36511
+ };
36512
+ var access_code_input_default = AccessCodeInput;
36513
+ var ChatWidget = ({
36514
+ title: title2,
36515
+ chatbotUrl,
36516
+ subtitle,
36517
+ question,
36518
+ suggestedQuestions,
36519
+ buttonClx = ""
36520
+ }) => {
36521
+ const [showChatbot, setShowChatbot] = React64__namespace.default.useState(false);
36522
+ const onClick = () => {
36523
+ setShowChatbot(!showChatbot);
36524
+ };
36525
+ const searchParams = new URLSearchParams();
36526
+ if (question) {
36527
+ searchParams.append("question", question);
36528
+ }
36529
+ if (suggestedQuestions) {
36530
+ searchParams.append("sQuestions", suggestedQuestions.map(({ message }) => message).join(","));
36531
+ searchParams.append("sHeadings", suggestedQuestions.map(({ heading }) => heading).join(","));
36532
+ searchParams.append("sIcons", suggestedQuestions.map(({ icon }) => icon).join(","));
36533
+ }
36534
+ const iframeSrc = `${chatbotUrl}?${searchParams.toString()}`;
36535
+ return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
36536
+ /* @__PURE__ */ jsxRuntime.jsx(ui.Box, { className: "fixed bottom-0 sm:bottom-16 right-0 w-full h-full sm:max-w-[400px] sm:max-h-[550px] sm:px-4 z-floating " + (showChatbot ? "flex" : "hidden"), children: /* @__PURE__ */ jsxRuntime.jsxs(primitives.Card, { className: "flex flex-col h-full w-full", children: [
36537
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex px-4 py-2 h-12 bg-level-0 items-center justify-between", children: [
36538
+ /* @__PURE__ */ jsxRuntime.jsxs("h1", { className: "font-semibold font-heading", children: [
36539
+ title2,
36540
+ " ",
36541
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "opacity-60", children: subtitle })
36542
+ ] }),
36543
+ /* @__PURE__ */ jsxRuntime.jsx(primitives.Button, { onClick, variant: "link", size: "icon", className: "w-fit sm:hidden", children: /* @__PURE__ */ jsxRuntime.jsx(logo.LuxLogo, { variant: "white", size: 24 }) })
36544
+ ] }),
36545
+ /* @__PURE__ */ jsxRuntime.jsx("iframe", { src: iframeSrc, className: "h-full" })
36546
+ ] }) }),
36547
+ /* @__PURE__ */ jsxRuntime.jsx(
36548
+ ui.Box,
36549
+ {
36550
+ tag: "span",
36551
+ onClick,
36552
+ className: ui.cn(
36553
+ // z-index should be below anything in commerce-iu (buy drawer and checkout widget)
36554
+ "fixed bottom-5 right-[24px] md:z-floating z-16 cursor-pointer",
36555
+ "hover:drop-shadow-[0_2px_6px_rgba(255,255,255,1)]",
36556
+ "transition-transform",
36557
+ showChatbot ? "rotate-180" : "",
36558
+ buttonClx
36559
+ ),
36560
+ children: /* @__PURE__ */ jsxRuntime.jsx(logo.LuxLogo, { variant: "white", size: 28 })
36561
+ }
36562
+ )
36563
+ ] });
36564
+ };
36565
+ var chat_widget_default = ChatWidget;
36566
+ var ContactFormSchema = zod.z.object({
36567
+ email: zod.z.string().min(1, { message: "Email must be provided." }).email("Invalid email."),
36568
+ phone: zod.z.string().min(1, { message: "Telephone must be provided." }).refine(validator__default.default.isMobilePhone, { message: "Invalid format." })
36569
+ });
36570
+ var ContactForm = ({
36571
+ onSubmit: _onSubmit,
36572
+ enclosure
36573
+ }) => {
36574
+ const form = reactHookForm.useForm({
36575
+ resolver: zod$1.zodResolver(ContactFormSchema),
36576
+ defaultValues: {
36577
+ email: "",
36578
+ phone: ""
36579
+ }
36580
+ });
36581
+ const [isPending, startTransition] = React64.useTransition();
36582
+ const onSubmit = (data) => {
36583
+ startTransition(async () => {
36584
+ await _onSubmit(data, enclosure);
36585
+ });
36586
+ };
36587
+ const MyFormItem = ({
36588
+ field,
36589
+ placeholder
36590
+ }) => /* @__PURE__ */ jsxRuntime.jsxs(ui.FormItem, { className: "space-y-0", children: [
36591
+ /* @__PURE__ */ jsxRuntime.jsx(ui.FormControl, { children: /* @__PURE__ */ jsxRuntime.jsx(primitives.Input, { placeholder, ...field, className: "mt-0 text-foreground" }) }),
36592
+ /* @__PURE__ */ jsxRuntime.jsx(ui.Box, { className: "flex flex-row justify-start items-stretch gap-2", children: /* @__PURE__ */ jsxRuntime.jsx(ui.FormMessage, {}) })
36593
+ ] });
36594
+ return /* @__PURE__ */ jsxRuntime.jsx(ui.Form, { ...form, children: /* @__PURE__ */ jsxRuntime.jsx(ui.Box, { tag: "form", onSubmit: form.handleSubmit(onSubmit), className: "w-3/4", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col justify-start items-stretch mt-4", children: [
36595
+ /* @__PURE__ */ jsxRuntime.jsx(
36596
+ ui.FormField,
36597
+ {
36598
+ control: form.control,
36599
+ name: "email",
36600
+ render: ({ field }) => /* @__PURE__ */ jsxRuntime.jsx(MyFormItem, { field, placeholder: "email" })
36601
+ }
36602
+ ),
36603
+ /* @__PURE__ */ jsxRuntime.jsx(
36604
+ ui.FormField,
36605
+ {
36606
+ control: form.control,
36607
+ name: "phone",
36608
+ render: ({ field }) => /* @__PURE__ */ jsxRuntime.jsx(MyFormItem, { field, placeholder: "phone" })
36609
+ }
36610
+ ),
36611
+ /* @__PURE__ */ jsxRuntime.jsx(primitives.Button, { disabled: isPending, type: "submit", className: "bg-primary text-primary-fg hover:bg-primary-hover", children: isPending ? /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
36612
+ /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Loader2, { style: ui.css("mr-2 h-4 w-4 animate-spin") }),
36613
+ "Please wait"
36614
+ ] }) : /* @__PURE__ */ jsxRuntime.jsx(jsxRuntime.Fragment, { children: "Submit" }) })
36615
+ ] }) }) });
36616
+ };
36617
+ var contact_form_default = ContactForm;
36618
+ var Disclaimer = () => /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
36619
+ "By entering your mobile number and submitting, you consent to receive text messages from Lux at the number provided. Message and data rates may apply. Message frequency varies. You can unsubscribe at any time by replying STOP. View our ",
36620
+ /* @__PURE__ */ jsxRuntime.jsx("a", { href: "/privacy", children: "Privacy Policy" }),
36621
+ " and ",
36622
+ /* @__PURE__ */ jsxRuntime.jsx("a", { href: "/terms", children: "Terms & conditions" }),
36623
+ "."
36624
+ ] });
36625
+ var disclaimer_default = Disclaimer;
36626
+ var ContactDialog = ({
36627
+ open: open2,
36628
+ onOpenChange,
36629
+ buttonText,
36630
+ buttonProps,
36631
+ title: title2,
36632
+ byline,
36633
+ action,
36634
+ actionEnclosure
36635
+ }) => {
36636
+ const [success, setSuccess] = React64.useState(false);
36637
+ const onSubmit = async (formData, enclosure) => {
36638
+ const result2 = await action(formData, enclosure);
36639
+ if (result2.success) {
36640
+ setSuccess(true);
36641
+ }
36642
+ };
36643
+ return /* @__PURE__ */ jsxRuntime.jsxs(primitives.Dialog, { open: open2, onOpenChange, children: [
36644
+ /* @__PURE__ */ jsxRuntime.jsx(primitives.DialogTrigger, { asChild: true, children: /* @__PURE__ */ jsxRuntime.jsx(primitives.Button, { ...buttonProps, children: buttonText }) }),
36645
+ /* @__PURE__ */ jsxRuntime.jsxs(primitives.DialogContent, { className: "sm:max-w-[500px] p-0 gap-0 bg-background border", children: [
36646
+ /* @__PURE__ */ jsxRuntime.jsxs(primitives.DialogHeader, { className: "py-6 text-foreground", children: [
36647
+ /* @__PURE__ */ jsxRuntime.jsx(primitives.DialogTitle, { className: "text-4xl text-center text-inherit", children: title2 }),
36648
+ byline && /* @__PURE__ */ jsxRuntime.jsxs(primitives.DialogDescription, { className: "text-inherit text-lg text-center", children: [
36649
+ byline,
36650
+ " "
36651
+ ] })
36652
+ ] }),
36653
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "px-8 pb-8 rounded-e-lg flex flex-col justify-start items-center", children: [
36654
+ success ? /* @__PURE__ */ jsxRuntime.jsx("p", { children: actionEnclosure?.reply }) : /* @__PURE__ */ jsxRuntime.jsx(contact_form_default, { onSubmit, enclosure: actionEnclosure }),
36655
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "text-muted-1 text-xs mt-4", children: /* @__PURE__ */ jsxRuntime.jsx(disclaimer_default, {}) })
36656
+ ] })
36657
+ ] })
36658
+ ] });
36659
+ };
36660
+ var contact_dialog_default = ContactDialog;
36661
+ var FIRST = 2020;
36662
+ var Copyright = ({
36663
+ className: className2 = ""
36664
+ }) => {
36665
+ const year = (/* @__PURE__ */ new Date()).getFullYear();
36666
+ const yearString = year > FIRST ? `${FIRST} - ${year}` : FIRST.toString();
36667
+ return /* @__PURE__ */ jsxRuntime.jsxs(ui.Box, { className: className2, children: [
36668
+ `Copyright \xA9 ${yearString}`,
36669
+ "\xA0",
36670
+ /* @__PURE__ */ jsxRuntime.jsx("br", { className: "sm:hidden" }),
36671
+ "Lux Industries Inc.\xA0",
36672
+ /* @__PURE__ */ jsxRuntime.jsx("br", { className: "md:hidden" }),
36673
+ "\xA0All rights reserved."
36674
+ ] });
36675
+ };
36676
+ var copyright_default = Copyright;
36677
+
36678
+ // src/site/site-def/footer/legal.ts
36679
+ var legal = [
36680
+ {
36681
+ title: "Terms and Conditions",
36682
+ href: "https://docs.google.com/document/d/1mvkjr1w8Rv8ttirs1mu-_2fw_PXclOyS/preview",
36683
+ newTab: true
36684
+ },
36685
+ {
36686
+ title: "Privacy Policy",
36687
+ href: "https://docs.google.com/document/d/1vZjOKaNdOoThDIaVLERWxflQLtOsuvLn/preview",
36688
+ newTab: true
36689
+ }
36690
+ ];
36691
+ var title = {
36692
+ title: "Legal",
36693
+ href: "",
36694
+ variant: "linkFG"
36695
+ };
36696
+ [title, ...legal];
36697
+ var FooterNav = ({
36698
+ items,
36699
+ currentAs,
36700
+ className: className2 = ""
36701
+ }) => /* @__PURE__ */ jsxRuntime.jsx(
36702
+ primitives.NavItems,
36703
+ {
36704
+ items,
36705
+ currentAs,
36706
+ as: "nav",
36707
+ className: className2,
36708
+ itemClx: (def) => def.variant === "linkFG" ? "font-nav text-[15px]/[1.3] font-medium tracking-normal text-muted-1 sm:hover:text-foreground transition-color duration-500" : "text-[15px]/[1.1] font-normal tracking-[0.2px] text-muted-1 sm:hover:text-foreground transition-color duration-500"
36709
+ }
36710
+ );
36711
+ var footer_nav_default = FooterNav;
36712
+ var SIZE12 = {
36713
+ xl: { mark: 40, word: 22, gap: "gap-4" },
36714
+ lg: { mark: 40, word: 22, gap: "gap-4" },
36715
+ md: { mark: 32, word: 18, gap: "gap-3" },
36716
+ sm: { mark: 24, word: 13, gap: "gap-2" },
36717
+ xs: { mark: 16, word: 9, gap: "gap-1.5" }
36718
+ };
36719
+ var Logo = ({
36720
+ size = "md",
36721
+ href,
36722
+ // no default please!
36723
+ outerClx = "",
36724
+ variant = "full",
36725
+ onClick
36726
+ }) => {
36727
+ const s = SIZE12[size] ?? SIZE12.md;
36728
+ const clx = "flex flex-row items-center " + s.gap + " " + (href ? "hover:opacity-80 cursor-pointer " : "cursor-default ") + outerClx;
36729
+ const art = /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
36730
+ variant !== "wordmark" && /* @__PURE__ */ jsxRuntime.jsx(logo.Logo, { variant: "white", size: s.mark }),
36731
+ variant !== "mark" && /* @__PURE__ */ jsxRuntime.jsx(logo.Wordmark, { height: s.word })
36732
+ ] });
36733
+ return href ? /* @__PURE__ */ jsxRuntime.jsx(Link5__default.default, { href, style: ui.css(clx), onClick, children: art }) : /* @__PURE__ */ jsxRuntime.jsx(ui.Box, { tag: "span", className: clx, onClick, children: art });
36734
+ };
36735
+ var Footer = ({
36736
+ siteDef,
36737
+ className: className2 = "",
36738
+ noHorizPadding = false
36739
+ }) => {
36740
+ const { footer, aboveCopyright } = siteDef;
36741
+ const smGridCols = Math.floor(footer.length / 2);
36742
+ const smGridColsClx = `sm:grid-cols-${smGridCols} `;
36743
+ const _aboveCopyright = typeof aboveCopyright === "undefined" ? legal : aboveCopyright;
36744
+ return /* @__PURE__ */ jsxRuntime.jsxs(ui.Box, { tag: "footer", className: ui.cn("grow flex flex-col justify-between gap-6 pb-[2vh]", className2), children: [
36745
+ /* @__PURE__ */ jsxRuntime.jsxs(ui.Box, { className: (noHorizPadding ? "" : "px-5 md:px-8 ") + "grid grid-cols-2 gap-4 gap-y-6 md:gap-x-6 lg:gap-8 " + smGridColsClx + "md:w-full sm:justify-items-center md:mx-0 lg:w-full md:flex md:flex-row md:justify-between px-[24px]", children: [
36746
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "hidden lg:flex flex-col", children: /* @__PURE__ */ jsxRuntime.jsx(Logo, { size: "md", variant: "wordmark" }) }, 0),
36747
+ footer.map((defs, index) => {
36748
+ const xsColSpanClx = index === footer.length - 1 && footer.length % 2 === 1 ? "xs:col-span-2 xs:mx-auto md:col-span-1 md:mx-0 " : "";
36749
+ return /* @__PURE__ */ jsxRuntime.jsx(
36750
+ footer_nav_default,
36751
+ {
36752
+ items: defs,
36753
+ currentAs: siteDef.currentAs,
36754
+ className: ui.cn(
36755
+ "sm:min-w-[150px] md:min-w-0 flex flex-col justify-start items-start gap-[11px] sm:gap-[12px] md:gap-[15px] ",
36756
+ xsColSpanClx
36757
+ )
36758
+ },
36759
+ index + 1
36760
+ );
36761
+ })
36762
+ ] }),
36763
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "md:mt-[2vh]", children: [
36764
+ _aboveCopyright.length > 0 && /* @__PURE__ */ jsxRuntime.jsx(
36765
+ primitives.NavItems,
36766
+ {
36767
+ items: _aboveCopyright,
36768
+ as: "div",
36769
+ className: "flex flex-row justify-center gap-4 mb-2",
36770
+ itemClx: "text-sm text-center text-muted-2 underline hover:text-foreground"
36771
+ }
36772
+ ),
36773
+ /* @__PURE__ */ jsxRuntime.jsx(copyright_default, { className: "text-sm text-center text-muted-3" })
36774
+ ] })
36775
+ ] });
36776
+ };
36777
+ var footer_default = Footer;
36778
+
36779
+ // src/site/components/auth/resume.ts
36780
+ var KEY = "lux-auth-resume";
36781
+ var remember = () => {
36782
+ sessionStorage.setItem(KEY, window.location.pathname + window.location.search);
36783
+ };
36784
+ var Widget = ({
36785
+ noLogin = false,
36786
+ handleLogin,
36787
+ className: className2
36788
+ }) => {
36789
+ const { isAuthenticated, isLoading, login, logout: logout2 } = react.useIam();
36790
+ const identity = react.useIamIdentity();
36791
+ if (isLoading) {
36792
+ return null;
36793
+ }
36794
+ if (!isAuthenticated) {
36795
+ return noLogin ? null : /* @__PURE__ */ jsxRuntime.jsx(
36796
+ primitives.Button,
36797
+ {
36798
+ variant: "primary",
36799
+ className: ui.cn("h-8 w-fit !min-w-0", className2),
36800
+ onClick: handleLogin ?? (() => {
36801
+ remember();
36802
+ void login();
36803
+ }),
36804
+ children: "Login"
36805
+ }
36806
+ );
36807
+ }
36808
+ return /* @__PURE__ */ jsxRuntime.jsxs(primitives.Popover, { children: [
36809
+ /* @__PURE__ */ jsxRuntime.jsx(primitives.PopoverTrigger, { asChild: true, children: /* @__PURE__ */ jsxRuntime.jsx(
36810
+ primitives.Button,
36811
+ {
36812
+ variant: "outline",
36813
+ size: "icon",
36814
+ className: ui.cn("rounded-full text-muted border-2 border-muted bg-level-1 hover:bg-level-2 hover:border-foreground hover:text-foreground uppercase w-8 h-8", className2),
36815
+ children: identity?.initials
36816
+ }
36817
+ ) }),
36818
+ /* @__PURE__ */ jsxRuntime.jsx(primitives.PopoverContent, { className: "bg-level-0", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "grid gap-4", children: [
36819
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-2 truncate", children: [
36820
+ /* @__PURE__ */ jsxRuntime.jsx("h4", { className: "font-medium leading-none truncate", children: identity?.name }),
36821
+ identity?.email && identity.email !== identity.name && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-sm opacity-50 truncate", children: identity.email })
36822
+ ] }),
36823
+ /* @__PURE__ */ jsxRuntime.jsx(primitives.Separator, {}),
36824
+ /* @__PURE__ */ jsxRuntime.jsx(primitives.Button, { variant: "outline", onClick: () => {
36825
+ logout2();
36826
+ }, children: "Logout" })
36827
+ ] }) })
36828
+ ] });
36829
+ };
36830
+ var AuthWidget = (props2) => React64.useContext(react.IamContext) ? /* @__PURE__ */ jsxRuntime.jsx(Widget, { ...props2 }) : null;
36831
+ var widget_default = AuthWidget;
36832
+ var Avatar9 = (props2) => /* @__PURE__ */ jsxRuntime.jsxs("svg", { width: "17", height: "21", viewBox: "0 0 17 21", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...props2, children: [
36833
+ /* @__PURE__ */ jsxRuntime.jsx("path", { d: "M8.66112 10.3544C6.14668 10.3544 4.32664 6.91073 4.32664 4.59206C4.32664 2.12213 6.27238 0.115723 8.66112 0.115723C11.0499 0.115723 12.9956 2.12514 12.9956 4.59206C12.9956 6.91398 11.1756 10.3544 8.66112 10.3544ZM8.66112 1.1542C6.82539 1.1542 5.33242 2.69703 5.33242 4.59185C5.33242 6.65402 6.94715 9.31553 8.66112 9.31553C10.3761 9.31553 11.9898 6.65387 11.9898 4.5925C11.9898 2.69668 10.4969 1.15398 8.66112 1.15398V1.1542Z", fill: "white" }),
36834
+ /* @__PURE__ */ jsxRuntime.jsx("path", { d: "M6.79776 11.3345H10.5242C13.7802 11.3345 16.4302 14.0712 16.4302 17.4338C16.4302 19.0831 15.1297 20.423 13.5356 20.423H3.78923C2.19216 20.423 0.894689 19.0831 0.894689 17.4338C0.893706 14.0712 3.54156 11.3345 6.79776 11.3345ZM3.78819 19.3844H13.5337C14.5749 19.3844 15.4225 18.509 15.4225 17.4338C15.4225 14.6453 13.2253 12.3731 10.5223 12.3731H6.79862C4.0956 12.3731 1.89839 14.6423 1.89839 17.4338C1.89937 18.509 2.74701 19.3844 3.78816 19.3844H3.78819Z", fill: "white" })
36835
+ ] });
36836
+ var avatar_default = Avatar9;
36837
+ var BagIcon = (props2) => /* @__PURE__ */ jsxRuntime.jsx("svg", { fill: "none", viewBox: "0 0 1019 1281", ...props2, children: /* @__PURE__ */ jsxRuntime.jsx("path", { d: "m977.243 365.553h-175.407v-90.629c0-151.923-131.968-274.924-292.334-274.924-160.367 0-292.337 123.002-292.337 274.924v90.629h-175.4023c-23.3886 0-41.7627 17.051-41.7627 38.756v775.121c0 55.8 48.4456 100.76 108.582 100.76h801.84c60.138 0 108.578-44.96 108.578-100.76v-775.121c0-21.705-18.37-38.756-41.757-38.756zm-676.553-90.629c0-108.517 93.546-196.9408 208.812-196.9408 115.265 0 208.813 88.4218 208.813 196.9408v89.08h-417.625z", fill: "currentColor" }) });
36838
+ var bag_icon_default = BagIcon;
36839
+
36840
+ // src/site/next/analytics/google-analytics.ts
36841
+ var sendGAEvent = (name, options = {}) => {
36842
+ window.gtag("event", name, options);
36843
+ };
36844
+ var DesktopBagPopup = ({
36845
+ triggerClx = "",
36846
+ popupClx = "",
36847
+ trigger
36848
+ }) => {
36849
+ const cmmc = commerce.useCommerce();
36850
+ const [bagOpen, setBagOpen] = React64.useState(false);
36851
+ const router = navigation.useRouter();
36852
+ React64.useEffect(() => {
36853
+ if (bagOpen) {
36854
+ sendGAEvent("view_cart", {
36855
+ items: cmmc.cartItems.map((item) => ({
36856
+ item_id: item.sku,
36857
+ item_name: item.title,
36858
+ item_category: item.familyId,
36859
+ price: item.price,
36860
+ quantity: item.quantity
36861
+ })),
36862
+ value: cmmc.cartTotal,
36863
+ currency: "USD"
36864
+ });
36865
+ }
36866
+ }, [bagOpen]);
36867
+ return /* @__PURE__ */ jsxRuntime.jsxs(primitives.Popover, { open: bagOpen, onOpenChange: setBagOpen, children: [
36868
+ /* @__PURE__ */ jsxRuntime.jsx(primitives.PopoverTrigger, { className: triggerClx, children: trigger }),
36869
+ /* @__PURE__ */ jsxRuntime.jsxs(primitives.PopoverContent, { sideOffset: 28, className: ui.cn("relative flex flex-col p-0 px-4 pb-4 pt-2", popupClx), children: [
36870
+ /* @__PURE__ */ jsxRuntime.jsx(primitives.PopoverClose, { className: "absolute z-above-content right-2 top-2 self-end hover:bg-level-3 text-muted hover:text-accent p-1 rounded-full", children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.X, { className: "w-5 h-5" }) }),
36871
+ /* @__PURE__ */ jsxRuntime.jsxs(
36872
+ commerce.CartPanel,
36873
+ {
36874
+ handleCheckout: () => {
36875
+ router.push("/checkout");
36876
+ },
36877
+ className: "mt-4 mb-4 border-none py-0 px-4",
36878
+ listClx: "rounded-sm pr-3",
36879
+ scrollAfter: 5,
36880
+ scrollHeightClx: "h-[70vh]",
36881
+ itemClx: "mt-3",
36882
+ totalClx: "sticky px-1 pr-2 -bottom-[1px] bg-level-1",
36883
+ buttonClx: "max-w-[220px] flex-none",
36884
+ children: [
36885
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-row items-center flex-none justify-center ", children: [
36886
+ /* @__PURE__ */ jsxRuntime.jsx(bag_icon_default, { className: "mr-2 relative w-6 h-7 fill-foreground " }),
36887
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "font-heading text-foreground text-default", children: "Your Bag" })
36888
+ ] }),
36889
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "h-[1px] w-pr-80 bg-muted-3 mx-auto mt-1.5 flex-none" })
36890
+ ]
36891
+ }
36892
+ )
36893
+ ] })
36894
+ ] });
36895
+ };
36896
+ var desktop_bag_popup_default = DesktopBagPopup;
36897
+ var BagButton = mobxReactLite.observer(({
36898
+ showIfEmpty = false,
36899
+ animateOnHover = true,
36900
+ animateOnQuantityChange = true,
36901
+ size = "default",
36902
+ className: className2 = "",
36903
+ iconClx = "",
36904
+ onClick
36905
+ }) => {
36906
+ const c = commerce.useCommerce();
36907
+ const wiggleRef = React64.useRef(mobx.observable.box("none"));
36908
+ React64.useEffect(() => (
36909
+ // return IReactionDisposer
36910
+ animateOnQuantityChange && c ? mobx.reaction(
36911
+ () => c.cartQuantity,
36912
+ (curr, prev) => {
36913
+ if (curr > prev) {
36914
+ mobx.runInAction(() => {
36915
+ wiggleRef.current.set("more");
36916
+ });
36917
+ } else {
36918
+ mobx.runInAction(() => {
36919
+ wiggleRef.current.set("less");
36920
+ });
36921
+ }
36922
+ setTimeout(() => {
36923
+ mobx.runInAction(() => {
36924
+ wiggleRef.current.set("none");
36925
+ });
36926
+ }, 800);
36927
+ }
36928
+ ) : void 0
36929
+ ), []);
36930
+ if (!c || !showIfEmpty && c.cartEmpty) {
36931
+ return /* @__PURE__ */ jsxRuntime.jsx("div", {});
36932
+ }
36933
+ return /* @__PURE__ */ jsxRuntime.jsxs(
36934
+ ui.Box,
36935
+ {
36936
+ "aria-label": "Bag",
36937
+ role: "button",
36938
+ onClick,
36939
+ className: ui.cn(
36940
+ primitives.buttonVariants({ variant: "ghost", size }),
36941
+ "rounded-md",
36942
+ // Overides the bg change on hover --not a "hover effect"
36943
+ "relative group p-0 aspect-square hover:bg-background",
36944
+ wiggleRef.current.get() === "more" ? "item-added-to-cart-animation" : wiggleRef.current.get() === "less" ? "item-removed-from-cart-animation" : "",
36945
+ className2
36946
+ ),
36947
+ children: [
36948
+ !c.cartEmpty && /* @__PURE__ */ jsxRuntime.jsxs(ui.Box, { className: "z-above-content flex flex-col justify-center items-center absolute left-0 right-0 top-0 bottom-0 leading-none font-sans font-bold text-primary-fg text-xs ", children: [
36949
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "h-[3px] w-full" }),
36950
+ /* @__PURE__ */ jsxRuntime.jsx("div", { children: c.cartQuantity })
36951
+ ] }),
36952
+ /* @__PURE__ */ jsxRuntime.jsx(bag_icon_default, { width: "24", height: "28", className: ui.cn(
36953
+ "relative -top-[3px] fill-primary",
36954
+ iconClx,
36955
+ animateOnHover ? "group-hover:fill-primary-hover group-hover:scale-105 transition-scale transition-duration-300" : ""
36956
+ ), "aria-hidden": "true" })
36957
+ ]
36958
+ }
36959
+ );
36960
+ });
36961
+ var bag_button_default = BagButton;
36962
+ var DesktopNav = ({ links, isMenuOpened, setIsMenuOpen }) => {
36963
+ React64__namespace.useEffect(() => {
36964
+ const preventScroll = (e) => {
36965
+ e.preventDefault();
36966
+ };
36967
+ if (isMenuOpened) {
36968
+ window.addEventListener("wheel", preventScroll, { passive: false });
36969
+ window.addEventListener("touchmove", preventScroll, { passive: false });
36970
+ window.addEventListener("keydown", preventScrollKeys, { passive: false });
36971
+ } else {
36972
+ window.removeEventListener("wheel", preventScroll);
36973
+ window.removeEventListener("touchmove", preventScroll);
36974
+ window.removeEventListener("keydown", preventScrollKeys);
36975
+ }
36976
+ return () => {
36977
+ window.removeEventListener("wheel", preventScroll);
36978
+ window.removeEventListener("touchmove", preventScroll);
36979
+ window.removeEventListener("keydown", preventScrollKeys);
36980
+ };
36981
+ }, [isMenuOpened]);
36982
+ const preventScrollKeys = (e) => {
36983
+ if (["ArrowUp", "ArrowDown", "ArrowLeft", "ArrowRight", " "].includes(e.key)) {
36984
+ e.preventDefault();
36985
+ }
36986
+ };
36987
+ const handleMouseEnter = React64__namespace.useCallback(() => {
36988
+ setIsMenuOpen(true);
36989
+ }, [setIsMenuOpen]);
36990
+ const handleMouseLeave = React64__namespace.useCallback(() => {
36991
+ setIsMenuOpen(false);
36992
+ }, [setIsMenuOpen]);
36993
+ const handleContentMouseMove = () => {
36994
+ setIsMenuOpen(false);
36995
+ };
36996
+ const menuHiddenClass = !isMenuOpened ? "invisible" : "";
36997
+ return links.length > 0 ? /* @__PURE__ */ jsxRuntime.jsx(primitives.NavigationMenu, { children: /* @__PURE__ */ jsxRuntime.jsx(primitives.NavigationMenuList, { children: links.map((el, index) => /* @__PURE__ */ jsxRuntime.jsx(primitives.NavigationMenuItem, { className: "!m-0", children: el.isAIMenu ? /* @__PURE__ */ jsxRuntime.jsx(Link5__default.default, { href: el.href, style: ui.css(ui.cn(primitives.navigationMenuTriggerStyle(), " text-muted-1 bg-transparent")), children: el.title }) : el.title === "Cards" ? /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
36998
+ /* @__PURE__ */ jsxRuntime.jsx(
36999
+ primitives.NavigationMenuTrigger,
37000
+ {
37001
+ className: "text-muted-1 bg-transparent",
37002
+ onMouseEnter: handleMouseEnter,
37003
+ onFocus: handleMouseEnter,
37004
+ onMouseLeave: handleMouseLeave,
37005
+ onBlur: handleMouseLeave,
37006
+ children: /* @__PURE__ */ jsxRuntime.jsx(Link5__default.default, { href: el.href, children: el.title })
37007
+ }
37008
+ ),
37009
+ /* @__PURE__ */ jsxRuntime.jsx(
37010
+ primitives.NavigationMenuContent,
37011
+ {
37012
+ className: ui.cn("fixed left-0 top-14 pt-6 w-screen h-full border-0 !backdrop-blur-3xl bg-transparent mt-0", menuHiddenClass),
37013
+ onMouseEnter: handleMouseEnter,
37014
+ onMouseLeave: handleMouseLeave,
37015
+ children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex justify-center items-start", children: /* @__PURE__ */ jsxRuntime.jsx(
37016
+ "div",
37017
+ {
37018
+ className: "grid xl:grid-cols-3 w-full justify-center max-w-[750px]",
37019
+ onMouseLeave: handleContentMouseMove,
37020
+ children: GroupChildMenu({ childs: el.childMenu, isCards: true })
37021
+ }
37022
+ ) })
37023
+ }
37024
+ )
37025
+ ] }) : /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
37026
+ /* @__PURE__ */ jsxRuntime.jsx(
37027
+ primitives.NavigationMenuTrigger,
37028
+ {
37029
+ className: "text-muted-1 bg-transparent",
37030
+ onMouseEnter: handleMouseEnter,
37031
+ onFocus: handleMouseEnter,
37032
+ onMouseLeave: handleMouseLeave,
37033
+ onBlur: handleMouseLeave,
37034
+ children: el.href && el.href !== "" ? /* @__PURE__ */ jsxRuntime.jsx(Link5__default.default, { href: el.href, children: el.title }) : /* @__PURE__ */ jsxRuntime.jsx(jsxRuntime.Fragment, { children: el.title })
37035
+ }
37036
+ ),
37037
+ /* @__PURE__ */ jsxRuntime.jsx(
37038
+ primitives.NavigationMenuContent,
37039
+ {
37040
+ className: ui.cn("fixed left-0 top-14 pt-6 w-screen h-full border-0 !backdrop-blur-3xl bg-transparent mt-0", menuHiddenClass),
37041
+ onMouseEnter: handleMouseEnter,
37042
+ onMouseLeave: handleMouseLeave,
37043
+ children: /* @__PURE__ */ jsxRuntime.jsx(
37044
+ "div",
37045
+ {
37046
+ className: "flex flex-row w-full justify-center",
37047
+ onMouseLeave: handleContentMouseMove,
37048
+ children: GroupChildMenu({ childs: el.childMenu })
37049
+ }
37050
+ )
37051
+ }
37052
+ )
37053
+ ] }) }, index)) }) }) : null;
37054
+ };
37055
+ var desktop_nav_menu_default = DesktopNav;
37056
+ var ListItem2 = React64__namespace.forwardRef(({ className: className2, title: title2, children, ...props2 }, ref2) => /* @__PURE__ */ jsxRuntime.jsx("li", { children: /* @__PURE__ */ jsxRuntime.jsx(primitives.NavigationMenuLink, { asChild: true, children: /* @__PURE__ */ jsxRuntime.jsxs(
37057
+ ui.Box,
37058
+ {
37059
+ tag: "a",
37060
+ ref: ref2,
37061
+ className: ui.cn(
37062
+ "block select-none space-y-1 rounded-md p-3 leading-none no-underline outline-none transition-colors hover:text-accent-foreground focus:bg-level-1 focus:text-accent-foreground text-muted-1 hover:text-primary hover:bg-transparent duration-1000 ease-in-out",
37063
+ className2
37064
+ ),
37065
+ ...props2,
37066
+ children: [
37067
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "text-sm font-medium leading-none", children: title2 }),
37068
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "line-clamp-3 text-sm leading-snug text-muted-1", children })
37069
+ ]
37070
+ }
37071
+ ) }) }, title2));
37072
+ ListItem2.displayName = "ListItem";
37073
+ var GroupChildMenu = (params) => {
37074
+ const { childs, isCards = false } = params;
37075
+ if (!childs) {
37076
+ return null;
37077
+ }
37078
+ const groupedChildMenus = childs.reduce((grouped, childLink) => {
37079
+ if (childLink.groupName) {
37080
+ grouped[childLink.groupName] = grouped[childLink.groupName] || [];
37081
+ grouped[childLink.groupName].push(childLink);
37082
+ }
37083
+ return grouped;
37084
+ }, {});
37085
+ const getChildExtraClass = (index) => {
37086
+ if (isCards && (index === 3 || index === 4)) {
37087
+ return "xl:-mt-32";
37088
+ }
37089
+ return "";
37090
+ };
37091
+ return Object.entries(groupedChildMenus).map(([groupName, childLinks], index) => /* @__PURE__ */ jsxRuntime.jsxs(ui.Box, { className: ui.cn("py-4 px-4 ", getChildExtraClass(index)), children: [
37092
+ /* @__PURE__ */ jsxRuntime.jsx("h2", { className: "text-muted-1", children: groupName }),
37093
+ /* @__PURE__ */ jsxRuntime.jsx("ul", { className: "w-[200px] gap-3 md:w-[250px] lg:w-[250px]", children: childLinks.map((link) => /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex justify-start items-center", children: [
37094
+ link.icon,
37095
+ /* @__PURE__ */ jsxRuntime.jsx(ListItem2, { title: link.title, href: link.href, className: "ml-[14px]", children: link.contents }, link.title)
37096
+ ] }, link.title)) })
37097
+ ] }, groupName));
37098
+ };
37099
+ var DesktopHeader = ({
37100
+ links,
37101
+ className: className2 = "",
37102
+ noAuth = false,
37103
+ noCommerce = false,
37104
+ children,
37105
+ logoVariant = "full"
37106
+ }) => {
37107
+ const [isMenuOpened, setIsMenuOpen] = React64__namespace.default.useState(false);
37108
+ return /* @__PURE__ */ jsxRuntime.jsx(ui.Box, { tag: "header", id: "DESKTOP_HEADER", className: ui.cn(
37109
+ "bg-[rgba(0, 0, 0, 0.5)] !backdrop-blur-3xl fixed z-header top-0 left-0 right-0",
37110
+ className2,
37111
+ isMenuOpened ? " h-full" : ""
37112
+ ), children: /* @__PURE__ */ jsxRuntime.jsxs(ui.Box, { className: "flex flex-row h-[80px] items-center justify-between mx-[24px] w-full max-w-screen", children: [
37113
+ /* @__PURE__ */ jsxRuntime.jsx(Logo, { size: logoVariant === "mark" ? "lg" : "md", href: "/", outerClx: "hidden lg:flex", variant: logoVariant }, "two"),
37114
+ /* @__PURE__ */ jsxRuntime.jsx(Logo, { size: "sm", href: "/", outerClx: "hidden md:flex lg:hidden", variant: logoVariant }, "one"),
37115
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex w-full gap-4 items-center justify-center", children: /* @__PURE__ */ jsxRuntime.jsx(desktop_nav_menu_default, { links, isMenuOpened, setIsMenuOpen }) }),
37116
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center", children: [
37117
+ !noCommerce && /* @__PURE__ */ jsxRuntime.jsx(desktop_bag_popup_default, { popupClx: "w-[340px]", trigger: /* @__PURE__ */ jsxRuntime.jsx(bag_button_default, { className: "text-primary -mr-[3px] lg:min-w-0" }) }),
37118
+ !noAuth && /* @__PURE__ */ jsxRuntime.jsx(widget_default, {}),
37119
+ children
37120
+ ] })
37121
+ ] }) });
37122
+ };
37123
+ var desktop_default = DesktopHeader;
37124
+ var Login = ({
37125
+ className: className2,
37126
+ onSuccess
37127
+ }) => {
37128
+ const { config: config2 } = react.useIam();
37129
+ const [state] = React64.useState(() => crypto.randomUUID());
37130
+ React64.useEffect(remember, []);
37131
+ return /* @__PURE__ */ jsxRuntime.jsx(
37132
+ react.Login,
37133
+ {
37134
+ serverUrl: config2.serverUrl,
37135
+ clientId: config2.clientId,
37136
+ redirectUri: config2.redirectUri,
37137
+ organization: config2.organization,
37138
+ state,
37139
+ className: ui.cn("hanzo-iam-card", className2),
37140
+ onSuccess
37141
+ }
37142
+ );
37143
+ };
37144
+ var login_default = Login;
37145
+ var MobileMenuToggleButton = ({
37146
+ open: open2,
37147
+ setOpen,
37148
+ className: className2 = ""
37149
+ }) => {
37150
+ return /* @__PURE__ */ jsxRuntime.jsx(
37151
+ primitives.Button,
37152
+ {
37153
+ variant: "ghost",
37154
+ size: "default",
37155
+ className: ui.cn("rounded-full", ui.cn("p-0 aspect-square hover:bg-background sm:hover:bg-level-1 active:scale-75", className2)),
37156
+ onClick: () => {
37157
+ setOpen(!open2);
37158
+ },
37159
+ children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Plus, { width: 28, height: 28, style: ui.css(
37160
+ "block h-full will-change-transform transition-transform transition-scale transition-duration-[1500] " + (open2 ? "rotate-[135deg] scale-110" : "rotate-none")
37161
+ ) })
37162
+ }
37163
+ );
37164
+ };
37165
+ var mobile_menu_toggle_button_default = MobileMenuToggleButton;
37166
+ var MobileBagDrawer = ({
37167
+ open: open2,
37168
+ setOpen,
37169
+ handleCheckout,
37170
+ className: className2 = ""
37171
+ }) => {
37172
+ return /* @__PURE__ */ jsxRuntime.jsx(primitives.Drawer, { open: open2, onOpenChange: setOpen, children: /* @__PURE__ */ jsxRuntime.jsx(primitives.DrawerContent, { className: ui.cn("rounded-t-xl mt-6 pb-12 h-auto", className2), children: /* @__PURE__ */ jsxRuntime.jsxs(
37173
+ commerce.CartPanel,
37174
+ {
37175
+ handleCheckout,
37176
+ className: "mt-4 mb-4 border-none py-0 px-4 w-full ",
37177
+ listClx: "rounded-sm pr-3",
37178
+ scrollAfter: 5,
37179
+ itemClx: "mt-2",
37180
+ totalClx: "sticky px-1 pr-2 border rounded-sm -bottom-[1px] bg-background",
37181
+ buttonClx: "max-w-[220px] flex-none",
37182
+ children: [
37183
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-row items-center flex-none justify-center ", children: [
37184
+ /* @__PURE__ */ jsxRuntime.jsx(
37185
+ bag_button_default,
37186
+ {
37187
+ animateOnHover: false,
37188
+ showIfEmpty: true,
37189
+ className: "mr-2 relative w-6 h-7",
37190
+ iconClx: "fill-foreground "
37191
+ }
37192
+ ),
37193
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "font-heading text-foreground text-default", children: "Your Bag" })
37194
+ ] }),
37195
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "h-[1px] w-pr-80 bg-muted-3 mx-auto mt-1.5 flex-none" })
37196
+ ]
37197
+ }
37198
+ ) }) });
37199
+ };
37200
+ var mobile_bag_drawer_default = MobileBagDrawer;
37201
+ var MobileNavMenuAI = ({ setMenuOpen }) => {
37202
+ const [isOpen, setIsOpen] = React64.useState(false);
37203
+ return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
37204
+ /* @__PURE__ */ jsxRuntime.jsxs(ui.Box, { className: "w-full text-2xl cursor-pointer", children: [
37205
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex justify-between", children: [
37206
+ /* @__PURE__ */ jsxRuntime.jsx(Logo, { variant: "wordmark", size: "md", outerClx: "p-6 h-full" }),
37207
+ /* @__PURE__ */ jsxRuntime.jsx(ui.Box, { tag: "span", className: ui.cn("grid", "block h-full aspect-square hover:bg-background sm:hover:bg-level-1 active:scale-75 text-foreground will-change-transform transition-transform transition-scale transition-duration-[1500] mt-6 mr-6 " + (!open ? "rotate-none" : "rotate-[135deg] scale-110")), children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Plus, { width: 28, height: 28, style: ui.css("w-full h-full"), onClick: () => setMenuOpen(false) }) })
37208
+ ] }),
37209
+ /* @__PURE__ */ jsxRuntime.jsx(ui.Box, { className: "flex items-center gap-5 border-b border-[#3A3A3A] mt-4 rounded-full bg-muted-4 mx-6", children: /* @__PURE__ */ jsxRuntime.jsxs(ui.Box, { className: "text-muted-1 font-bold flex-1 flex justify-between min-h-12 items-center px-2", onClick: () => setIsOpen(true), children: [
37210
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-base pl-2 font-light", children: "Ask AI a question" }),
37211
+ /* @__PURE__ */ jsxRuntime.jsx(lucideReact.ArrowRight, {})
37212
+ ] }) })
37213
+ ] }),
37214
+ /* @__PURE__ */ jsxRuntime.jsx(ui.Box, { className: "fixed bottom-0 sm:bottom-16 right-0 w-full h-full sm:max-w-[400px] sm:max-h-[550px] sm:px-4 z-floating " + (isOpen ? "flex" : "hidden"), children: /* @__PURE__ */ jsxRuntime.jsxs(primitives.Card, { className: "flex flex-col h-full w-full", children: [
37215
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex px-4 py-2 h-16 bg-level-0 items-center justify-between", children: [
37216
+ /* @__PURE__ */ jsxRuntime.jsxs("h3", { className: "font-semibold font-heading", children: [
37217
+ "LUX",
37218
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "opacity-60", children: "AI" })
37219
+ ] }),
37220
+ /* @__PURE__ */ jsxRuntime.jsx(primitives.Button, { onClick: () => setIsOpen(false), variant: "link", size: "icon", className: "w-fit sm:hidden", children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Plus, { className: "w-6 h-6 flex-none mr-1 rotate-45 transition-transform" }) })
37221
+ ] }),
37222
+ /* @__PURE__ */ jsxRuntime.jsx("iframe", { src: "https://lux.chat/iframe", className: "h-full" })
37223
+ ] }) })
37224
+ ] });
37225
+ };
37226
+ var mobile_nav_menu_ai_default = MobileNavMenuAI;
37227
+ var MobileNav = ({
37228
+ currentAs,
37229
+ links,
37230
+ setMenuState,
37231
+ className: className2 = "",
37232
+ commonItemClx,
37233
+ setChatbotOpen,
37234
+ setMenuOpen
37235
+ }) => links.length > 0 ? /* @__PURE__ */ jsxRuntime.jsxs(ui.Box, { className: ui.cn("flex flex-col h-full", className2), children: [
37236
+ /* @__PURE__ */ jsxRuntime.jsx(mobile_nav_menu_ai_default, { setMenuOpen }),
37237
+ /* @__PURE__ */ jsxRuntime.jsx(ui.Box, { className: "flex flex-col flex-1 overflow-auto", children: /* @__PURE__ */ jsxRuntime.jsx(primitives.Accordion, { type: "single", collapsible: true, className: "w-full h-full", children: links.map((el, index) => {
37238
+ const itemClx = commonItemClx ? typeof commonItemClx === "string" ? commonItemClx : commonItemClx(el) : "";
37239
+ const variant = el.variant ?? "link";
37240
+ let internalClx = variant === "link" ? " text-muted hover:text-foreground active:text-accent rounded-none" : " min-w-0";
37241
+ if (currentAs && currentAs === el.href) {
37242
+ internalClx += " pointer-events-none";
37243
+ if (variant === "link") {
37244
+ internalClx += " text-accent";
37245
+ }
37246
+ }
37247
+ if (!el.isAIMenu) {
37248
+ return /* @__PURE__ */ jsxRuntime.jsxs(primitives.AccordionItem, { value: el.title ? el.title : "", className: "!no-underline !border-0 px-6", children: [
37249
+ /* @__PURE__ */ jsxRuntime.jsxs(primitives.AccordionTrigger, { className: ui.cn(internalClx, itemClx, ""), children: [
37250
+ /* @__PURE__ */ jsxRuntime.jsx(ui.Box, { className: ui.cn(internalClx, itemClx, "flex items-center justify-between w-full pl-3 text-base font-normal leading-6"), children: el.title }),
37251
+ /* @__PURE__ */ jsxRuntime.jsx(lucideReact.ChevronDown, { style: ui.css("w-4 h-4 mr-3") })
37252
+ ] }),
37253
+ /* @__PURE__ */ jsxRuntime.jsx(primitives.AccordionContent, { children: el.childMenu && /* @__PURE__ */ jsxRuntime.jsx(ui.Box, { className: "px-4", children: Object.entries(el.childMenu.reduce((acc, child) => {
37254
+ const group = acc[child.groupName ? child.groupName : ""] || [];
37255
+ group.push(child);
37256
+ acc[child.groupName ? child.groupName : ""] = group;
37257
+ return acc;
37258
+ }, {})).map(([groupName, children]) => /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
37259
+ /* @__PURE__ */ jsxRuntime.jsx(ui.Box, { className: "mt-4 mb-4 font-light text-muted-1", children: groupName }),
37260
+ children.map((child, childIndex) => /* @__PURE__ */ jsxRuntime.jsx(ui.Box, { className: "m-2", children: /* @__PURE__ */ jsxRuntime.jsxs(ui.Box, { className: "flex items-center py-1", children: [
37261
+ /* @__PURE__ */ jsxRuntime.jsx("span", { children: child.icon && child.icon }),
37262
+ /* @__PURE__ */ jsxRuntime.jsx(
37263
+ Link5__default.default,
37264
+ {
37265
+ href: child.href,
37266
+ target: child.newTab ? "_blank" : "_self",
37267
+ rel: "noopener noreferrer",
37268
+ children: /* @__PURE__ */ jsxRuntime.jsx(ui.Box, { tag: "span", className: "text-muted-2 hover:underline ml-5 hover:text-primary", children: child.title })
37269
+ }
37270
+ )
37271
+ ] }) }, childIndex))
37272
+ ] }, groupName)) }) })
37273
+ ] }, index);
37274
+ }
37275
+ }) }) }),
37276
+ /* @__PURE__ */ jsxRuntime.jsx(widget_default, { className: "text-2xl z-10", handleLogin: () => {
37277
+ setMenuState("login");
37278
+ } })
37279
+ ] }) : null;
37280
+ var mobile_nav_menu_default = MobileNav;
37281
+ var bagClx = "mt-4 mb-8 border-none py-0 px-4 w-full sm:min-w-[350px] sm:max-w-[500px] sm:mx-auto min-h-[60vh] max-h-[70vh] sm:animate-in sm:zoom-in-90 ";
37282
+ var MobileHeader = ({
37283
+ currentAs,
37284
+ links,
37285
+ className: className2 = "",
37286
+ setChatbotOpen,
37287
+ noAuth = false,
37288
+ // :aa TODO
37289
+ noCommerce = false
37290
+ // :aa TODO
37291
+ }) => {
37292
+ const cmmc = commerce.useCommerce();
37293
+ const [menuState, setMenuState] = React64.useState("closed");
37294
+ const [bagDrawerOpen, setBagDrawerOpen] = React64.useState(false);
37295
+ const router = navigation.useRouter();
37296
+ React64.useEffect(() => {
37297
+ if (menuState === "bag" || bagDrawerOpen) {
37298
+ sendGAEvent("view_cart", {
37299
+ items: cmmc.cartItems.map((item) => ({
37300
+ item_id: item.sku,
37301
+ item_name: item.title,
37302
+ item_category: item.familyId,
37303
+ price: item.price,
37304
+ quantity: item.quantity
37305
+ })),
37306
+ value: cmmc.cartTotal,
37307
+ currency: "USD"
37308
+ });
37309
+ }
37310
+ }, [menuState, bagDrawerOpen]);
37311
+ const menuOpen = () => menuState !== "closed";
37312
+ const onLoginChanged = (token) => {
37313
+ if (!!token) {
37314
+ setMenuState("nav");
37315
+ }
37316
+ };
37317
+ const setMenuOpen = (open2) => {
37318
+ if (!open2) {
37319
+ setMenuState("closed");
37320
+ } else {
37321
+ setMenuState("nav");
37322
+ }
37323
+ };
37324
+ const handleCheckout = () => {
37325
+ setMenuState("closed");
37326
+ setBagDrawerOpen(false);
37327
+ router.push("/checkout");
37328
+ };
37329
+ const openBag = () => {
37330
+ if (menuOpen()) {
37331
+ setMenuState("bag");
37332
+ } else {
37333
+ setBagDrawerOpen(true);
37334
+ }
37335
+ };
37336
+ return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
37337
+ /* @__PURE__ */ jsxRuntime.jsx(ui.Box, { tag: "header", id: "MOBILE_HEADER", className: ui.cn(
37338
+ `bg-background fixed z-header top-0 left-0 w-full ${menuOpen() ? "hidden" : "block"}`,
37339
+ className2
37340
+ ), children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "w-full h-full flex flex-row justify-between items-center font-bold pr-5", children: [
37341
+ /* @__PURE__ */ jsxRuntime.jsx(Logo, { href: "/", size: "md", outerClx: "p-6 h-full", variant: "wordmark" }),
37342
+ menuOpen() && /* @__PURE__ */ jsxRuntime.jsx(ui.Box, { className: "absolute left-0 top-0 bottom-0 right-0 pl-8 flex flex-row bg-background animate-mobile-menu-open", children: /* @__PURE__ */ jsxRuntime.jsx(avatar_default, { className: "self-center " }) }),
37343
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex gap-0 flex-row", children: [
37344
+ /* @__PURE__ */ jsxRuntime.jsx(bag_button_default, { className: "text-primary -mr-[3px]", onClick: openBag }),
37345
+ /* @__PURE__ */ jsxRuntime.jsx(mobile_menu_toggle_button_default, { className: "text-foreground", open: menuOpen(), setOpen: setMenuOpen })
37346
+ ] })
37347
+ ] }) }),
37348
+ !noCommerce && /* @__PURE__ */ jsxRuntime.jsx(
37349
+ mobile_bag_drawer_default,
37350
+ {
37351
+ className: "",
37352
+ open: bagDrawerOpen,
37353
+ setOpen: setBagDrawerOpen,
37354
+ handleCheckout
37355
+ }
37356
+ ),
37357
+ menuOpen() && /* @__PURE__ */ jsxRuntime.jsx(ui.Box, { className: "fixed top-0 left-0 w-full h-full flex flex-column bg-background z-below-header animate-mobile-menu-open", children: !!!noAuth && menuState === "login" ? /* @__PURE__ */ jsxRuntime.jsx(login_default, { onSuccess: onLoginChanged, className: "sm:animate-in sm:zoom-in-90 m-auto w-full max-w-sm px-8" }) : !!!noCommerce && menuState === "bag" ? /* @__PURE__ */ jsxRuntime.jsxs(
37358
+ commerce.CartPanel,
37359
+ {
37360
+ handleCheckout: () => {
37361
+ router.push("/checkout");
37362
+ },
37363
+ className: bagClx,
37364
+ listClx: "rounded-sm",
37365
+ scrollAfter: 6,
37366
+ scrollHeightClx: "h-[80vh]",
37367
+ itemClx: "mt-2",
37368
+ totalClx: "sticky px-1 pr-2 border rounded-sm -bottom-[1px] bg-level-1",
37369
+ buttonClx: "max-w-[220px] flex-none",
37370
+ children: [
37371
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-row items-center flex-none justify-center ", children: [
37372
+ /* @__PURE__ */ jsxRuntime.jsx(bag_icon_default, { className: "mr-2 relative w-4 h-5 fill-foreground " }),
37373
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "font-heading text-foreground text-default", children: "Your Bag" })
37374
+ ] }),
37375
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "h-[1px] w-pr-80 bg-muted-3 mx-auto mt-1.5 flex-none" })
37376
+ ]
37377
+ }
37378
+ ) : (
37379
+ /* menuState === 'nav' */
37380
+ /* @__PURE__ */ jsxRuntime.jsx(
37381
+ mobile_nav_menu_default,
37382
+ {
37383
+ currentAs,
37384
+ links,
37385
+ className: "sm:animate-in sm:zoom-in-90 w-full",
37386
+ commonItemClx: "px-0 text-xl h-16 justify-start ",
37387
+ setMenuState,
37388
+ setChatbotOpen,
37389
+ setMenuOpen
37390
+ }
37391
+ )
37392
+ ) })
37393
+ ] });
37394
+ };
37395
+ var mobile_default = MobileHeader;
37396
+ var Header = ({
37397
+ siteDef,
37398
+ className: className2 = "",
37399
+ children,
37400
+ logoVariant = "full"
37401
+ }) => {
37402
+ const [open2, setOpen] = React64__namespace.default.useState(false);
37403
+ const { nav: { common, featured }, currentAs, noAuth, commerce } = siteDef;
37404
+ const links = featured ? [...common, ...featured] : common;
37405
+ return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
37406
+ /* @__PURE__ */ jsxRuntime.jsx(
37407
+ desktop_default,
37408
+ {
37409
+ className: ui.cn(className2, "hidden md:flex"),
37410
+ links,
37411
+ currentAs,
37412
+ noAuth,
37413
+ noCommerce: !!!commerce,
37414
+ logoVariant,
37415
+ children
37416
+ }
37417
+ ),
37418
+ /* @__PURE__ */ jsxRuntime.jsx(
37419
+ mobile_default,
37420
+ {
37421
+ className: ui.cn(className2, "md:hidden"),
37422
+ links,
37423
+ currentAs,
37424
+ setChatbotOpen: setOpen,
37425
+ noAuth,
37426
+ noCommerce: !!!commerce
37427
+ }
37428
+ )
37429
+ ] });
37430
+ };
37431
+ var header_default = Header;
37432
+ var Main = ({
37433
+ children,
37434
+ className: className2 = "",
37435
+ headerSpace = true,
37436
+ standardWidth = true,
37437
+ id: id3
37438
+ }) => /* @__PURE__ */ jsxRuntime.jsx(ui.Box, { tag: "main", id: id3 ?? "LUX_UI_MAIN", className: ui.cn(
37439
+ "flex flex-col justify-start items-center",
37440
+ "px-4 md:px-6 lg:px-8",
37441
+ standardWidth ? "max-w-screen-2xl w-full lg:mx-auto" : "",
37442
+ headerSpace ? "pt-[44px] md:pt-[80px]" : "py-4",
37443
+ className2
37444
+ ), children });
37445
+ var main_default = Main;
37446
+ var MiniChart = ({
37447
+ widgetProps,
37448
+ containerStyles = {}
37449
+ }) => {
37450
+ const {
37451
+ symbol,
37452
+ exchange,
37453
+ lineColor,
37454
+ topGradientColor,
37455
+ bottomGradientColor,
37456
+ width,
37457
+ height,
37458
+ autosize,
37459
+ locale,
37460
+ ...rest
37461
+ } = widgetProps;
37462
+ const symbolString = exchange ? `${exchange}:${symbol}` : symbol;
37463
+ const containerRef = React64.useRef(null);
37464
+ React64.useEffect(() => {
37465
+ if (!containerRef.current) {
37466
+ return;
37467
+ }
37468
+ const script = document.createElement("script");
37469
+ script.type = "text/javascript";
37470
+ script.src = "https://s3.tradingview.com/external-embedding/embed-widget-mini-symbol-overview.js";
37471
+ script.async = true;
37472
+ script.onload = async () => {
37473
+ const iframe = containerRef.current?.querySelector("iframe");
37474
+ if (iframe && iframe instanceof Element) {
37475
+ iframe.style.colorScheme = "normal";
37476
+ setTimeout(() => {
37477
+ document.querySelector("#mini-symbol-overview-ticker");
37478
+ }, 1200);
37479
+ }
37480
+ const copyDiv = document.querySelector(".tradingview-widget-copyright");
37481
+ if (copyDiv) {
37482
+ setTimeout(() => {
37483
+ copyDiv.classList.remove("invisible");
37484
+ }, 1200);
37485
+ }
37486
+ };
37487
+ const config2 = JSON.stringify({
37488
+ symbol: symbolString,
37489
+ width: autosize ? "100%" : width || 350,
37490
+ height: autosize ? "100%" : height || 220,
37491
+ locale: locale ?? "en",
37492
+ isTransparent: "true",
37493
+ trendLineColor: lineColor || "rgba(41, 98, 255, 1)",
37494
+ underLineColor: topGradientColor || "rgba(41, 98, 255, 0.3)",
37495
+ underLineBottomColor: bottomGradientColor || "rgba(41, 98, 255, 0)",
37496
+ ...rest
37497
+ });
37498
+ script.innerHTML = config2;
37499
+ containerRef.current.appendChild(script);
37500
+ return () => {
37501
+ while (containerRef.current?.firstChild) {
37502
+ containerRef.current.removeChild(containerRef.current.firstChild);
37503
+ }
37504
+ };
37505
+ }, [JSON.stringify(widgetProps)]);
37506
+ return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
37507
+ /* @__PURE__ */ jsxRuntime.jsx("div", { style: containerStyles, className: "tradingview-widget-container h-[150px]", ref: containerRef }),
37508
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "tradingview-widget-copyright border-t w-full invisible", children: [
37509
+ /* @__PURE__ */ jsxRuntime.jsx("a", { href: `https://www.tradingview.com/symbols/${symbol}${exchange ? `/?exchange=${exchange}` : ""}`, rel: "noopener", target: "_blank", children: /* @__PURE__ */ jsxRuntime.jsxs(ui.Box, { tag: "span", className: "text-[--hz-ui-primary]", children: [
37510
+ symbol,
37511
+ " quotes"
37512
+ ] }) }),
37513
+ "\xA0by TradingView"
37514
+ ] })
37515
+ ] });
37516
+ };
37517
+ var mini_chart_default = MiniChart;
37518
+ var Wrapper = ({
37519
+ symbol,
37520
+ exchange
37521
+ }) => /* @__PURE__ */ jsxRuntime.jsx(mini_chart_default, { widgetProps: {
37522
+ symbol,
37523
+ exchange,
37524
+ autosize: true,
37525
+ colorTheme: "dark",
37526
+ lineColor: "rgb(114, 27, 228)",
37527
+ bottomGradientColor: "rgba(255, 255, 255, 0.1)",
37528
+ dateRange: "60M"
37529
+ } });
37530
+ var wrapper_default = Wrapper;
37531
+ var NotFound = ({
37532
+ header = false,
37533
+ siteDef
37534
+ }) => /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
37535
+ header && /* @__PURE__ */ jsxRuntime.jsx(header_default, { siteDef }),
37536
+ /* @__PURE__ */ jsxRuntime.jsx(main_default, { className: "h-[100svh] sm:h-[700px] px-8 sm:px-10", headerSpace: header, children: /* @__PURE__ */ jsxRuntime.jsxs(ui.ApplyTypography, { className: "mt-[200px] flex flex-col md:gap-8", children: [
37537
+ /* @__PURE__ */ jsxRuntime.jsx("h3", { children: "...Huh?" }),
37538
+ /* @__PURE__ */ jsxRuntime.jsx("h4", { children: "Sorry, we're fresh out of those." }),
37539
+ /* @__PURE__ */ jsxRuntime.jsxs("h4", { children: [
37540
+ "...try something from the ",
37541
+ /* @__PURE__ */ jsxRuntime.jsx("a", { href: "/", children: "Home Page" }),
37542
+ "?"
37543
+ ] })
37544
+ ] }) }),
37545
+ /* @__PURE__ */ jsxRuntime.jsx(footer_default, { siteDef })
37546
+ ] });
37547
+ var not_found_default = NotFound;
37548
+ var BackButton = ({
37549
+ variant = "ghost",
37550
+ size = "default",
37551
+ clx = "",
37552
+ iconClx = "",
37553
+ onBack
37554
+ }) => {
37555
+ const router = navigation.useRouter();
37556
+ const back = () => {
37557
+ if (onBack) {
37558
+ onBack();
37559
+ }
37560
+ router.back();
37561
+ };
37562
+ return /* @__PURE__ */ jsxRuntime.jsx(
37563
+ primitives.Button,
37564
+ {
37565
+ variant,
37566
+ size,
37567
+ onClick: back,
37568
+ className: clx,
37569
+ children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.ChevronLeft, { style: ui.css(iconClx) })
37570
+ }
37571
+ );
37572
+ };
37573
+ var back_button_default = BackButton;
37574
+ mobxReactLite.enableStaticRendering(typeof window === "undefined");
37575
+ var CommerceUIContext = React64.createContext(void 0);
37576
+ var useCommerceDrawer = () => {
37577
+ return React64.useContext(CommerceUIContext);
37578
+ };
37579
+ var useSelectAndBuy = () => {
37580
+ return React64.useContext(CommerceUIContext);
37581
+ };
37582
+ var CommerceDrawer = mobxReactLite.observer(({
37583
+ children,
37584
+ handleHandleClicked,
37585
+ drawerClx = "",
37586
+ ...rest
37587
+ }) => {
37588
+ const drawer = useCommerceDrawer();
37589
+ return /* @__PURE__ */ jsxRuntime.jsx(
37590
+ primitives.Drawer,
37591
+ {
37592
+ open: drawer.open,
37593
+ onOpenChange: () => {
37594
+ },
37595
+ modal: drawer.modal,
37596
+ snapPoints: drawer.points,
37597
+ activeSnapPoint: drawer.activePoint,
37598
+ setActiveSnapPoint: drawer.onActivePointChanged.bind(drawer),
37599
+ fastDragSkipsToEnd: false,
37600
+ dragHandleOnly: true,
37601
+ handleHandleClicked,
37602
+ extendHandleDragRegion: false,
37603
+ ...rest,
37604
+ children: /* @__PURE__ */ jsxRuntime.jsxs(
37605
+ primitives.DrawerContent,
37606
+ {
37607
+ defaultHandle: false,
37608
+ className: ui.cn(
37609
+ "border-0",
37610
+ drawer.isMobile ? "pt-5" : "pt-6",
37611
+ "w-full h-full"
37612
+ ),
37613
+ onOpenAutoFocus: (e) => {
37614
+ e.preventDefault();
37615
+ },
37616
+ children: [
37617
+ /* @__PURE__ */ jsxRuntime.jsx(
37618
+ primitives.DrawerHandle,
37619
+ {
37620
+ className: ui.cn(
37621
+ "absolute top-0 left-0 right-0 mx-auto z-10",
37622
+ "flex justify-center items-start",
37623
+ "border-t rounded-t-lg border-muted-3",
37624
+ drawer.isMobile ? "h-5 touch-pan-y" : "h-6"
37625
+ ),
37626
+ children: /* @__PURE__ */ jsxRuntime.jsx(ui.Box, { className: ui.cn(
37627
+ // pseudo-handle
37628
+ "rounded-[3px] bg-level-3",
37629
+ drawer.isMobile ? "w-[155px] mt-[5px] h-1.5" : "w-[180px] mt-[3px] h-2.5 hover:bg-level-4",
37630
+ !drawer.isMobile ? "cursor-grab active:cursor-grabbing" : ""
37631
+ ) })
37632
+ }
37633
+ ),
37634
+ children
37635
+ ]
37636
+ }
37637
+ )
37638
+ }
37639
+ );
37640
+ });
37641
+ var shell_default = CommerceDrawer;
37642
+ var IconAndQuantity = mobxReactLite.observer(({
37643
+ animateOnQuantityChange = false,
37644
+ showArrow = true,
37645
+ showQuantity = true,
37646
+ clx = "",
37647
+ iconClx = "",
37648
+ digitClx = ""
37649
+ }) => {
37650
+ const cmmc = commerce.useCommerce();
37651
+ const wiggleRef = React64.useRef(mobx.observable.box("none"));
37652
+ React64.useEffect(() => (
37653
+ // return IReactionDisposer
37654
+ animateOnQuantityChange ? mobx.reaction(
37655
+ () => cmmc.cartQuantity,
37656
+ (curr, prev) => {
37657
+ if (curr > prev) {
37658
+ mobx.runInAction(() => {
37659
+ wiggleRef.current.set("more");
37660
+ });
37661
+ } else {
37662
+ mobx.runInAction(() => {
37663
+ wiggleRef.current.set("less");
37664
+ });
37665
+ }
37666
+ setTimeout(() => {
37667
+ mobx.runInAction(() => {
37668
+ wiggleRef.current.set("none");
37669
+ });
37670
+ }, 800);
37671
+ }
37672
+ ) : void 0
37673
+ ), []);
37674
+ return /* @__PURE__ */ jsxRuntime.jsxs(ui.Box, { className: ui.cn("flex items-center justify-center", clx), children: [
37675
+ showQuantity && /* @__PURE__ */ jsxRuntime.jsxs(ui.Box, { className: ui.cn(
37676
+ "relative flex items-center justify-center mr-1",
37677
+ wiggleRef.current.get() === "more" ? "item-added-to-cart-animation" : wiggleRef.current.get() === "less" ? "item-removed-from-cart-animation" : ""
37678
+ ), children: [
37679
+ cmmc.cartQuantity > 0 && /* @__PURE__ */ jsxRuntime.jsx(ui.Box, { className: ui.cn(
37680
+ "z-above-content flex flex-col justify-center items-center",
37681
+ "absolute left-0 right-0 top-0 bottom-0",
37682
+ digitClx
37683
+ ), children: /* @__PURE__ */ jsxRuntime.jsx("div", { style: {
37684
+ /* color: 'white' tailwind bug? ,*/
37685
+ fontSize: "11px",
37686
+ position: "relative",
37687
+ top: "1px"
37688
+ }, children: cmmc.cartQuantity }) }),
37689
+ /* @__PURE__ */ jsxRuntime.jsx(bag_icon_default, { width: "19", height: "24", className: ui.cn("relative -top-[3px] opacity-70", iconClx), "aria-hidden": "true" })
37690
+ ] }),
37691
+ showArrow && /* @__PURE__ */ jsxRuntime.jsx("span", { style: { fontSize: "17px" }, children: "\u203A" })
37692
+ ] });
37693
+ });
37694
+ var CheckoutButton = ({
37695
+ handleCheckout,
37696
+ variant = "primary",
37697
+ rounded = "lg",
37698
+ className: className2,
37699
+ showQuantity = true,
37700
+ showArrow = true,
37701
+ animateOnQuantityChange = true,
37702
+ centerText = true,
37703
+ children,
37704
+ ...rest
37705
+ }) => {
37706
+ return /* @__PURE__ */ jsxRuntime.jsxs(
37707
+ primitives.Button,
37708
+ {
37709
+ ...rest,
37710
+ onClick: handleCheckout,
37711
+ variant,
37712
+ className: ui.cn(`rounded-${rounded}`, ui.cn(
37713
+ "flex justify-between items-stretch group",
37714
+ showQuantity ? centerText ? "px-1.5" : "pl-2.5 pr-1.5" : "",
37715
+ className2
37716
+ )),
37717
+ children: [
37718
+ centerText && // must scale this one too, as it effects layout
37719
+ /* @__PURE__ */ jsxRuntime.jsx(
37720
+ IconAndQuantity,
37721
+ {
37722
+ showArrow,
37723
+ showQuantity,
37724
+ clx: "invisible group-hover:scale-105 transition-scale transition-duration-300"
37725
+ }
37726
+ ),
37727
+ children ?? /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex justify-center items-center", children: "Checkout" }),
37728
+ /* @__PURE__ */ jsxRuntime.jsx(
37729
+ IconAndQuantity,
37730
+ {
37731
+ clx: "group-hover:scale-105 transition-scale transition-duration-300",
37732
+ animateOnQuantityChange,
37733
+ showArrow,
37734
+ showQuantity,
37735
+ iconClx: "fill-background",
37736
+ digitClx: "text-foreground group-hover:opacity-80 leading-none font-bold font-sans"
37737
+ }
37738
+ )
37739
+ ]
37740
+ }
37741
+ );
37742
+ };
37743
+ var checkout_button_default = CheckoutButton;
37744
+ var CN = {
37745
+ // h: mind padding!
37746
+ mobile: { w: 36, h: 32 },
37747
+ sm: { w: 60, h: 34 },
37748
+ desktop: { w: 60, h: 32 }
37749
+ };
37750
+ var Info2 = ({
37751
+ item,
37752
+ clx = ""
37753
+ }) => {
37754
+ const cmmc = commerce.useCommerce();
37755
+ const family = cmmc.getFamilyById(item.familyId);
37756
+ let topLine = family.title;
37757
+ if (item.sku.startsWith("LXM-AG") || item.sku.startsWith("LXM-AU")) {
37758
+ topLine = family.parentTitle + ", " + family.title;
37759
+ }
37760
+ const optionLabel = item.optionLabelShort ?? item.optionLabel;
37761
+ const priceStr = commerce.formatCurrencyValue(item.price);
37762
+ return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
37763
+ /* @__PURE__ */ jsxRuntime.jsxs(ui.Box, { className: ui.cn("sm:hidden flex flex-col !text-muted items-stretch whitespace-nowrap text-ellipsis ", clx), children: [
37764
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-left text-xs", children: topLine }),
37765
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex justify-between text-xxs", children: [
37766
+ /* @__PURE__ */ jsxRuntime.jsx("div", { children: optionLabel }),
37767
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "pl-2.5", children: priceStr })
37768
+ ] })
37769
+ ] }),
37770
+ /* @__PURE__ */ jsxRuntime.jsxs(ui.Box, { className: ui.cn("hidden sm:flex !text-muted flex-col items-stretch whitespace-nowrap text-ellipsis text-xs", clx), children: [
37771
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-left", children: topLine }),
37772
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex justify-between", children: [
37773
+ /* @__PURE__ */ jsxRuntime.jsx("div", { children: optionLabel }),
37774
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "pl-2.5", children: priceStr })
37775
+ ] })
37776
+ ] })
37777
+ ] });
37778
+ };
37779
+ var PROMPT_COMMON_CLX = "block absolute top-0 left-0 bg-transparent duration-400 transition-opacity";
37780
+ var Micro = mobxReactLite.observer(({
37781
+ clx = "",
37782
+ handleCheckout,
37783
+ handleItemClicked
37784
+ }) => {
37785
+ const drawer = useCommerceDrawer();
37786
+ const cmmc = commerce.useCommerce();
37787
+ return /* @__PURE__ */ jsxRuntime.jsxs(ui.Box, { className: ui.cn(
37788
+ drawer.showRecent ? "grid grid-cols-2" : "flex justify-center items-center ",
37789
+ drawer.showRecent ? drawer.isMobile ? "-mt-3" : "-mt-3" : "",
37790
+ "gap-2 md:gap-3 relative",
37791
+ clx
37792
+ ), children: [
37793
+ drawer.showRecent && /* @__PURE__ */ jsxRuntime.jsxs(ui.Box, { className: "flex flex-col items-stretch " + (drawer.isMobile ? "justify-start" : "group"), children: [
37794
+ /* @__PURE__ */ jsxRuntime.jsxs(ui.Box, { tag: "p", className: "relative text-muted text-xxs md:text-xs leading-none pl-1 self-start " + (drawer.isMobile ? "top-[3px]" : "top-[1px]"), children: [
37795
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "invisible", children: "scrictly for layout" }),
37796
+ drawer.isMobile ? /* @__PURE__ */ jsxRuntime.jsx(ui.Box, { tag: "span", className: PROMPT_COMMON_CLX, children: "tap for options:" }) : /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
37797
+ /* @__PURE__ */ jsxRuntime.jsx(ui.Box, { tag: "span", className: PROMPT_COMMON_CLX + " group-hover:opacity-0", children: "recent item:" }),
37798
+ /* @__PURE__ */ jsxRuntime.jsx(ui.Box, { tag: "span", className: PROMPT_COMMON_CLX + " opacity-0 group-hover:opacity-100", children: "view options:" })
37799
+ ] })
37800
+ ] }),
37801
+ /* @__PURE__ */ jsxRuntime.jsxs(
37802
+ primitives.Button,
37803
+ {
37804
+ variant: "ghost",
37805
+ className: ui.cn(`rounded-${drawer.isMobile ? "md" : "lg"}`, ui.cn(
37806
+ "box-content",
37807
+ "flex flex-row justify-between items-center gap-1",
37808
+ "-ml-1.5",
37809
+ "overflow-hidden ",
37810
+ "px-1 md:px-2 py-[2px]",
37811
+ "border border-transparent group-hover:border-muted-3",
37812
+ "group-hover:!bg-transparent",
37813
+ "!min-w-0"
37814
+ )),
37815
+ size: drawer.isMobile ? "sm" : "default",
37816
+ onClick: handleItemClicked,
37817
+ children: [
37818
+ cmmc.recentItem?.item.img && /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
37819
+ /* @__PURE__ */ jsxRuntime.jsx(ui.MediaStack, { media: { img: cmmc.recentItem.item.img }, constrainTo: CN.mobile, className: "sm:hidden grow-0 shrink-0" }),
37820
+ /* @__PURE__ */ jsxRuntime.jsx(ui.MediaStack, { media: { img: cmmc.recentItem.item.img }, constrainTo: CN.sm, className: "hidden sm:block md:hidden grow-0 shrink-0" }),
37821
+ /* @__PURE__ */ jsxRuntime.jsx(ui.MediaStack, { media: { img: cmmc.recentItem.item.img }, constrainTo: CN.desktop, className: "hidden md:block grow-0 shrink-0" })
37822
+ ] }),
37823
+ cmmc.recentItem && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "grow w-full", children: /* @__PURE__ */ jsxRuntime.jsx(Info2, { item: cmmc.recentItem.item, clx: "w-full" }) })
37824
+ ]
37825
+ }
37826
+ )
37827
+ ] }),
37828
+ drawer.showCheckout && /* @__PURE__ */ jsxRuntime.jsxs(ui.Box, { className: ui.cn(
37829
+ "flex flex-col w-full",
37830
+ drawer.showRecent ? "items-stretch" : "items-center",
37831
+ drawer.isMobile ? "justify-start" : "justify-center"
37832
+ ), children: [
37833
+ drawer.showRecent && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "invisible text-muted text-xxs md:text-xs leading-none pl-1 self-start", children: "for layout" }),
37834
+ /* @__PURE__ */ jsxRuntime.jsx(
37835
+ checkout_button_default,
37836
+ {
37837
+ handleCheckout,
37838
+ variant: "primary",
37839
+ size: drawer.isMobile ? "sm" : "lg",
37840
+ className: ui.cn(`rounded-${drawer.isMobile ? "md" : "lg"}`, ui.cn(
37841
+ drawer.isMobile ? drawer.showRecent ? "pl-3.5 pr-2.5" : "min-w-[320px]" : drawer.showRecent ? "" : "w-[320px]",
37842
+ "text-sm font-semibold"
37843
+ )),
37844
+ centerText: drawer.isMobile ? !drawer.showRecent : true
37845
+ }
37846
+ )
37847
+ ] })
37848
+ ] });
37849
+ });
37850
+ var micro_default = Micro;
37851
+ var CommerceUIComponent = mobxReactLite.observer(() => {
37852
+ const buy = useSelectAndBuy();
37853
+ const drawer = useCommerceDrawer();
37854
+ const router = navigation.useRouter();
37855
+ const handleCheckout = () => {
37856
+ router.push("/checkout");
37857
+ };
37858
+ const handleHandleClicked = () => {
37859
+ if (drawer.state === "full") {
37860
+ buy.hideVariants();
37861
+ } else if (drawer.state === "micro") {
37862
+ buy.showRecentVariants();
37863
+ }
37864
+ };
37865
+ const handleItemClicked = () => {
37866
+ buy.showRecentVariants();
37867
+ };
37868
+ const handleCloseGesture = () => {
37869
+ if (drawer.state === "full") {
37870
+ buy.hideVariants();
37871
+ return true;
37872
+ }
37873
+ return false;
37874
+ };
37875
+ return /* @__PURE__ */ jsxRuntime.jsxs(
37876
+ shell_default,
37877
+ {
37878
+ handleHandleClicked,
37879
+ handleCloseGesture,
37880
+ drawerClx: "flex flex-col",
37881
+ children: [
37882
+ drawer.state === "full" && /* The actual drawer is larger than the visible area (due to awkward
37883
+ vaul impl. So we have to ask the drawer for its currect snappoint
37884
+ and constrain layout to that.
37885
+ */
37886
+ /* @__PURE__ */ jsxRuntime.jsx("div", { style: {
37887
+ height: drawer.snapPointPx - 24
37888
+ /* fudge factor for handle area */
37889
+ }, children: /* @__PURE__ */ jsxRuntime.jsx(
37890
+ commerce.CarouselBuyCard,
37891
+ {
37892
+ skuPath: buy.currentSkuPath,
37893
+ checkoutButton: /* @__PURE__ */ jsxRuntime.jsx(
37894
+ checkout_button_default,
37895
+ {
37896
+ handleCheckout,
37897
+ className: "w-full min-w-[160px] sm:max-w-[320px]"
37898
+ }
37899
+ ),
37900
+ clx: "justify-between h-full pb-3 gap-8",
37901
+ addBtnClx: "w-full min-w-[160px] sm:max-w-[320px]",
37902
+ buttonsAreaClx: "grow-0 shrink-0 mt-0",
37903
+ selectorClx: "max-w-[475px] justify-between grow"
37904
+ }
37905
+ ) }),
37906
+ drawer.state === "micro" && /* @__PURE__ */ jsxRuntime.jsx(
37907
+ micro_default,
37908
+ {
37909
+ handleCheckout,
37910
+ handleItemClicked,
37911
+ clx: "w-full px-2 sm:w-[460px] sm:mx-auto md:w-[550px]"
37912
+ }
37913
+ )
37914
+ ]
37915
+ }
37916
+ );
37917
+ });
37918
+ var drawer_default = CommerceUIComponent;
37919
+ var DrawerMargin = mobxReactLite.observer(({
37920
+ clx = ""
37921
+ }) => {
37922
+ const drawer = useCommerceDrawer();
37923
+ if (!drawer) {
37924
+ throw new Error("DrawerMargin must be used with a CommerceUIContext!");
37925
+ }
37926
+ return /* @__PURE__ */ jsxRuntime.jsx(
37927
+ ui.Box,
37928
+ {
37929
+ className: ui.cn("transition-height", clx),
37930
+ style: {
37931
+ height: drawer.state === "micro" ? drawer.microHeight : 0
37932
+ }
37933
+ }
37934
+ );
37935
+ });
37936
+ var drawer_margin_default = DrawerMargin;
37937
+ var BuyButton = ({
37938
+ skuPath,
37939
+ children,
37940
+ className: className2 = "",
37941
+ ...rest
37942
+ }) => {
37943
+ const buyOptions = useSelectAndBuy();
37944
+ const handleClick = () => {
37945
+ buyOptions.showVariants(skuPath);
37946
+ };
37947
+ return /* @__PURE__ */ jsxRuntime.jsx(primitives.Button, { onClick: handleClick, ...rest, className: ui.cn(className2, ""), children });
37948
+ };
37949
+ var buy_button_default = BuyButton;
37950
+ var ThankYou = ({}) => /* @__PURE__ */ jsxRuntime.jsxs(primitives.ApplyTypography, { className: "flex flex-col gap-4 text-center mt-10", children: [
37951
+ /* @__PURE__ */ jsxRuntime.jsx("h3", { children: "Thank you for your order!" }),
37952
+ /* @__PURE__ */ jsxRuntime.jsx("h6", { children: "Once your payment has been confirmed, you'll recieve an email with additional information." }),
37953
+ /* @__PURE__ */ jsxRuntime.jsxs("p", { children: [
37954
+ "While you wait, we cordially invite you to join the ",
37955
+ /* @__PURE__ */ jsxRuntime.jsx(Link5__default.default, { href: "https://warpcast.com/~/channel/lux", children: "Lux Channel" }),
37956
+ " on ",
37957
+ /* @__PURE__ */ jsxRuntime.jsx(Link5__default.default, { href: "https://warpcast.com/~/invite-page/227706?id=fbc9ca91", children: "Warpcast" }),
37958
+ "."
37959
+ ] })
37960
+ ] });
37961
+ var thank_you_default = ThankYou;
37962
+ var DesktopBagCarousel = mobxReactLite.observer(({
37963
+ constrainTo,
37964
+ className: className2 = ""
37965
+ }) => {
37966
+ const cmmc = commerce.useCommerce();
37967
+ return /* @__PURE__ */ jsxRuntime.jsx(
37968
+ commerce.CarouselItemSelector,
37969
+ {
37970
+ items: cmmc.cartItems,
37971
+ selectedItemRef: cmmc,
37972
+ scrollable: false,
37973
+ selectSku: cmmc.setCurrentItem.bind(cmmc),
37974
+ clx: className2,
37975
+ ext: {
37976
+ options: { loop: true },
37977
+ constrainTo,
37978
+ imageOnly: true
37979
+ }
37980
+ }
37981
+ );
37982
+ });
37983
+ var desktop_bag_carousel_default = DesktopBagCarousel;
37984
+ var linkClx = ui.cn(primitives.buttonVariants({ variant: "linkMuted" }), "rounded-none");
37985
+ var PolicyLinks = ({
37986
+ clx = ""
37987
+ }) => /* @__PURE__ */ jsxRuntime.jsxs(ui.Box, { className: ui.cn("flex flex-col items-center", clx), children: [
37988
+ /* @__PURE__ */ jsxRuntime.jsx(primitives.Separator, {}),
37989
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex gap-4 py-2 text-sm", children: [
37990
+ /* @__PURE__ */ jsxRuntime.jsx(Link5__default.default, { style: ui.css(linkClx), href: "", children: "refund policy" }),
37991
+ /* @__PURE__ */ jsxRuntime.jsx(Link5__default.default, { style: ui.css(linkClx), href: "", children: "privacy policy" })
37992
+ ] })
37993
+ ] });
37994
+ var policy_links_default = PolicyLinks;
37995
+ var DesktopCheckoutPanel = mobxReactLite.observer(({
37996
+ step,
37997
+ stepNames,
37998
+ onLeave,
37999
+ clx = "",
38000
+ children
38001
+ }) => {
38002
+ const cmmc = commerce.useCommerce();
38003
+ return /* @__PURE__ */ jsxRuntime.jsxs(ui.Box, { className: ui.cn("grid grid-cols-2", clx), children: [
38004
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-full h-full bg-background flex flex-row items-start justify-end", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "w-full h-full max-w-[750px] relative flex flex-col items-stretch justify-start px-8 pb-8", children: [
38005
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "h-[80px] grow-0 flex flex-row items-center z-10", children: [
38006
+ /* @__PURE__ */ jsxRuntime.jsx(Logo, { size: "md", href: "/", onClick: onLeave, variant: "wordmark", outerClx: "logo-outer-tooltip-class" }),
38007
+ /* @__PURE__ */ jsxRuntime.jsx(tooltip_default, { select: ".logo-outer-tooltip-class", text: "home", position: "right", offset: 6 })
38008
+ ] }, 1),
38009
+ /* @__PURE__ */ jsxRuntime.jsx(
38010
+ back_button_default,
38011
+ {
38012
+ size: "sm",
38013
+ clx: "z-10 absolute top-14 left-6 !px-0 aspect-square rounded-full hover:!bg-level-3 back-button-tooltip-class ",
38014
+ onBack: onLeave
38015
+ }
38016
+ ),
38017
+ /* @__PURE__ */ jsxRuntime.jsx(tooltip_default, { select: ".back-button-tooltip-class", text: "back", position: "right", offset: 5 }),
38018
+ /* @__PURE__ */ jsxRuntime.jsxs(ui.Box, { className: ui.cn(
38019
+ "w-full grow min-h-0 max-w-[550px] mx-auto flex flex-col gap-3",
38020
+ cmmc.cartItems.length > 4 ? "justify-between" : "justify-start gap-10 pt-10"
38021
+ ), children: [
38022
+ /* @__PURE__ */ jsxRuntime.jsx(desktop_bag_carousel_default, { className: "grow-0 h-[260px] w-[360px] lg:w-[420px] mx-auto -mt-8", constrainTo: { w: 250, h: 250 } }),
38023
+ /* @__PURE__ */ jsxRuntime.jsx(
38024
+ commerce.CartPanel,
38025
+ {
38026
+ className: "w-full border-none p-0",
38027
+ itemClx: "mb-2",
38028
+ totalClx: "sticky bottom-0 bg-background",
38029
+ listClx: "pr-3",
38030
+ scrollAfter: 4,
38031
+ scrollHeightClx: "min-h-[50vh] grow",
38032
+ showPromoCode: true,
38033
+ showShipping: true,
38034
+ selectItems: true
38035
+ }
38036
+ )
38037
+ ] }, 2)
38038
+ ] }) }, 1),
38039
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "w-full h-full flex flex-col bg-level-1 min-h-screen justify-between", children: [
38040
+ /* @__PURE__ */ jsxRuntime.jsx(primitives.ScrollArea, { className: "w-full flex flex-row items-start justify-start overflow-y-auto", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "h-full w-full max-w-[750px] relative flex flex-col items-center px-8 pt-0", children: [
38041
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "bg-level-1 sticky h-[80px] bg-[#aaaaff] w-full top-0 flex justify-center items-end", children: [
38042
+ /* @__PURE__ */ jsxRuntime.jsx(widget_default, { noLogin: true, className: "hidden md:flex absolute top-4 right-4 " }),
38043
+ /* @__PURE__ */ jsxRuntime.jsx(primitives.StepIndicator, { dotSizeRem: 1.35, steps: stepNames, currentStep: step, className: "gap-2 text-base w-pr-70" })
38044
+ ] }, 1),
38045
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-full max-w-[550px] mx-auto py-8", children }, 2)
38046
+ ] }) }),
38047
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-full max-w-[750px] relative flex flex-col items-center px-8 pt-0", children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-full max-w-[550px] mx-auto flex flex-col items-center", children: /* @__PURE__ */ jsxRuntime.jsx(policy_links_default, { clx: "w-full" }) }) })
38048
+ ] }, 2)
38049
+ ] });
38050
+ });
38051
+ var desktop_cp_default = DesktopCheckoutPanel;
38052
+ var CartAccordian = mobxReactLite.observer(({
38053
+ icon,
38054
+ clx = "",
38055
+ panelClx = "",
38056
+ triggerClx = "",
38057
+ scrollAfter,
38058
+ scrollHeightClx
38059
+ }) => {
38060
+ const cmmc = commerce.useCommerce();
38061
+ return /* @__PURE__ */ jsxRuntime.jsx(primitives.Accordion, { type: "single", collapsible: true, className: clx, children: /* @__PURE__ */ jsxRuntime.jsxs(primitives.AccordionItem, { value: "cart", className: "w-full border-b-0", children: [
38062
+ /* @__PURE__ */ jsxRuntime.jsxs(primitives.AccordionTrigger, { className: "!no-underline group flex justify-between ", children: [
38063
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex gap-0 items-center", children: [
38064
+ icon,
38065
+ /* @__PURE__ */ jsxRuntime.jsxs("h5", { className: "text-sm sm:text-xl grow", children: [
38066
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "group-data-[state=open]:hidden", children: "Order Total:" }),
38067
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "group-data-[state=closed]:hidden", children: "Your Order" })
38068
+ ] })
38069
+ ] }),
38070
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex gap-1 items-center", children: [
38071
+ /* @__PURE__ */ jsxRuntime.jsx("h5", { className: "text-sm sm:text-xl grow truncate", children: commerce.formatCurrencyValue(cmmc.promoAppliedCartTotal) }),
38072
+ /* @__PURE__ */ jsxRuntime.jsx(lucideReact.ChevronRight, { style: ui.css("h-5 w-5 -mr-2 shrink-0 transition-transform duration-200 group-data-[state=open]:rotate-90") })
38073
+ ] })
38074
+ ] }),
38075
+ /* @__PURE__ */ jsxRuntime.jsx(primitives.AccordionContent, { className: "data-[state=open]:mb-4", children: /* @__PURE__ */ jsxRuntime.jsx(
38076
+ commerce.CartPanel,
38077
+ {
38078
+ className: ui.cn("w-full", panelClx),
38079
+ scrollAfter,
38080
+ scrollHeightClx,
38081
+ listClx: "mt-0",
38082
+ itemClx: "mt-0.5 mb-0",
38083
+ totalClx: "sticky px-1 pr-2 border-t -bottom-[1px] bg-background",
38084
+ showShipping: true,
38085
+ showPromoCode: true
38086
+ }
38087
+ ) })
38088
+ ] }) });
38089
+ });
38090
+ var cart_accordian_default = CartAccordian;
38091
+ var MobileCheckoutPanel = ({
38092
+ step,
38093
+ stepNames,
38094
+ onLeave,
38095
+ clx = "",
38096
+ children
38097
+ }) => /* @__PURE__ */ jsxRuntime.jsxs(ui.Box, { className: ui.cn("bg-background flex flex-col justify-start px-4 pt-[101px]", clx), children: [
38098
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "fixed z-11 top-0 h-[45px] w-full flex justify-between items-stretch bg-background", children: [
38099
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-stretch gap-1 grow-0", children: [
38100
+ /* @__PURE__ */ jsxRuntime.jsx(
38101
+ back_button_default,
38102
+ {
38103
+ size: "sm",
38104
+ clx: "-ml-5 !px-0 aspect-square h-full rounded-full active:!bg-level-3 ",
38105
+ onBack: onLeave
38106
+ }
38107
+ ),
38108
+ /* @__PURE__ */ jsxRuntime.jsx(Logo, { size: "sm", variant: "wordmark", href: "/", onClick: onLeave, outerClx: "-ml-2" })
38109
+ ] }),
38110
+ /* @__PURE__ */ jsxRuntime.jsx(
38111
+ primitives.StepIndicator,
38112
+ {
38113
+ dotSizeRem: 1,
38114
+ steps: stepNames,
38115
+ currentStep: step,
38116
+ className: "relative grow mx-2 top-[14px] text-xs font-semibold w-full"
38117
+ }
38118
+ ),
38119
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-[72px] grow-0 shrink-0 flex items-center justify-center", children: /* @__PURE__ */ jsxRuntime.jsx(widget_default, { noLogin: true, className: "" }) })
38120
+ ] }),
38121
+ /* @__PURE__ */ jsxRuntime.jsx(
38122
+ cart_accordian_default,
38123
+ {
38124
+ icon: /* @__PURE__ */ jsxRuntime.jsx(
38125
+ bag_button_default,
38126
+ {
38127
+ animateOnHover: false,
38128
+ showIfEmpty: true,
38129
+ size: "sm",
38130
+ className: "mr-1 relative w-5 h-6 sm:w-6 sm:h-7",
38131
+ iconClx: "fill-foreground"
38132
+ }
38133
+ ),
38134
+ clx: "flex items-center justify-center w-full",
38135
+ triggerClx: "bg-background fixed z-11 top-[45px] left-0 right-0 !m-0 px-4",
38136
+ panelClx: "!py-0",
38137
+ scrollAfter: 3,
38138
+ scrollHeightClx: "h-[385px]"
38139
+ }
38140
+ ),
38141
+ children,
38142
+ /* @__PURE__ */ jsxRuntime.jsx(policy_links_default, { clx: "mt-auto mb-3 pt-2" })
38143
+ ] });
38144
+ var mobile_cp_default = MobileCheckoutPanel;
38145
+ var STEPS = [
38146
+ {
38147
+ name: "payment",
38148
+ Comp: commerce.PaymentStepForm
38149
+ },
38150
+ {
38151
+ name: "delivery",
38152
+ Comp: commerce.ShippingStepForm
38153
+ },
38154
+ {
38155
+ name: "done",
38156
+ label: "Done!",
38157
+ Comp: thank_you_default
38158
+ }
38159
+ ];
38160
+ var STEP_NAMES = STEPS.map((s) => s.label ? s.label : ui.capitalize(s.name));
38161
+ var CheckoutPanel = ({
38162
+ clx = ""
38163
+ }) => {
38164
+ const cmmc = commerce.useCommerce();
38165
+ if (!cmmc) {
38166
+ console.log("CHECKOUT PANEL: cmmc svc undefined!");
38167
+ return /* @__PURE__ */ jsxRuntime.jsx(jsxRuntime.Fragment, {});
38168
+ }
38169
+ const [stepIndex, setStepIndex] = React64.useState(0);
38170
+ const [orderId, setOrderId] = React64.useState(void 0);
38171
+ const setStep = (name) => {
38172
+ if (name === "first") {
38173
+ setStepIndex(0);
38174
+ } else if (name === "last") {
38175
+ setStepIndex(STEPS.length - 1);
38176
+ } else if (name === "next") {
38177
+ if (stepIndex <= STEPS.length - 2) {
38178
+ setStepIndex(stepIndex + 1);
38179
+ } else {
38180
+ throw new Error("CheckoutPanel.setStep(): Attempting to advance past last step!");
38181
+ }
38182
+ } else {
38183
+ const indexFound = STEPS.findIndex((el) => el.name === name);
38184
+ if (indexFound !== -1) {
38185
+ setStepIndex(indexFound);
38186
+ } else {
38187
+ throw new Error("CheckoutPanel.setStep(): Step named " + name + " not found!");
38188
+ }
38189
+ }
38190
+ };
38191
+ const _close = () => {
38192
+ setStep("first");
38193
+ };
38194
+ const desktopElement = React64.useRef(null);
38195
+ const [layout2, setLayout] = React64.useState(void 0);
38196
+ React64.useLayoutEffect(() => {
38197
+ const checkLayout = () => {
38198
+ setLayout(!!desktopElement.current?.offsetParent ? "desktop" : "mobile");
38199
+ };
38200
+ checkLayout();
38201
+ window.addEventListener("resize", checkLayout);
38202
+ return () => {
38203
+ window.removeEventListener("resize", checkLayout);
38204
+ };
38205
+ }, []);
38206
+ const StepToRender = STEPS[stepIndex].Comp;
38207
+ return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
38208
+ /* @__PURE__ */ jsxRuntime.jsxs(
38209
+ desktop_cp_default,
38210
+ {
38211
+ clx: ui.cn("h-full", clx, "hidden md:flex"),
38212
+ onLeave: _close,
38213
+ step: stepIndex,
38214
+ stepNames: STEP_NAMES,
38215
+ children: [
38216
+ /* @__PURE__ */ jsxRuntime.jsx("div", { ref: desktopElement }),
38217
+ layout2 === "desktop" && /* @__PURE__ */ jsxRuntime.jsx(StepToRender, { onDone: () => {
38218
+ setStep("next");
38219
+ }, orderId, setOrderId })
38220
+ ]
38221
+ }
38222
+ ),
38223
+ /* @__PURE__ */ jsxRuntime.jsx(
38224
+ mobile_cp_default,
38225
+ {
38226
+ clx: ui.cn("w-full h-full overflow-y-auto", clx, "md:hidden"),
38227
+ onLeave: _close,
38228
+ step: stepIndex,
38229
+ stepNames: STEP_NAMES,
38230
+ children: layout2 === "mobile" && /* @__PURE__ */ jsxRuntime.jsx(StepToRender, { onDone: () => {
38231
+ setStep("next");
38232
+ }, orderId, setOrderId })
38233
+ }
38234
+ )
38235
+ ] });
38236
+ };
38237
+ var checkout_panel_default = CheckoutPanel;
38238
+ var LoginPanel = ({
38239
+ close,
38240
+ className: className2 = "",
38241
+ reviews
38242
+ }) => {
38243
+ return /* @__PURE__ */ jsxRuntime.jsxs(ui.Box, { className: ui.cn("grid grid-cols-1 md:grid-cols-2", className2), children: [
38244
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "hidden md:flex w-full h-full bg-[radial-gradient(circle_at_24.1%_68.8%_,_rgba(15,14,14,0)_,_rgba(9,9,9,99.4))] flex-row items-end justify-end overflow-y-auto min-h-screen", children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "h-full w-full max-w-[750px] px-8 pt-0", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "h-full w-full max-w-[550px] mx-auto flex flex-col justify-between min-h-screen py-10", children: [
38245
+ /* @__PURE__ */ jsxRuntime.jsx(
38246
+ primitives.Button,
38247
+ {
38248
+ variant: "ghost",
38249
+ onClick: close,
38250
+ className: "w-fit !min-w-0 p-2",
38251
+ children: /* @__PURE__ */ jsxRuntime.jsx(Logo, { size: "md", variant: "wordmark" })
38252
+ }
38253
+ ),
38254
+ /* @__PURE__ */ jsxRuntime.jsx(
38255
+ primitives.Carousel,
38256
+ {
38257
+ options: { align: "center", loop: true, autoplay: 5e3 },
38258
+ className: "w-full",
38259
+ children: /* @__PURE__ */ jsxRuntime.jsx(primitives.CarouselContent, { children: reviews.map(({ text, author, href }, index) => /* @__PURE__ */ jsxRuntime.jsx(primitives.CarouselItem, { children: /* @__PURE__ */ jsxRuntime.jsxs(Link5__default.default, { href, className: "flex flex-col gap-3 cursor-pointer", children: [
38260
+ /* @__PURE__ */ jsxRuntime.jsxs("p", { children: [
38261
+ "\u201C",
38262
+ text,
38263
+ "\u201C"
38264
+ ] }),
38265
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-sm", children: author })
38266
+ ] }) }, index)) })
38267
+ }
38268
+ )
38269
+ ] }) }) }),
38270
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-full h-full bg-background flex flex-row items-center", children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-full max-w-[750px] relative flex flex-col items-center px-8 pt-0 text-center", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "relative h-full w-full max-w-[400px] mx-auto flex flex-col gap-4 items-center py-10", children: [
38271
+ /* @__PURE__ */ jsxRuntime.jsx(
38272
+ primitives.Button,
38273
+ {
38274
+ variant: "ghost",
38275
+ onClick: close,
38276
+ className: "block md:hidden absolute rounded-full p-2 left-0 h-auto hover:bg-background",
38277
+ children: /* @__PURE__ */ jsxRuntime.jsx(logo.LuxLogo, { variant: "white", size: 20 })
38278
+ }
38279
+ ),
38280
+ /* @__PURE__ */ jsxRuntime.jsx(login_default, { className: "w-full max-w-sm" }),
38281
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-sm opacity-50", children: legal.map(({ title: title2, href }, index) => /* @__PURE__ */ jsxRuntime.jsxs(React64__namespace.default.Fragment, { children: [
38282
+ index > 0 && " \xB7 ",
38283
+ /* @__PURE__ */ jsxRuntime.jsx(Link5__default.default, { href, className: "underline", children: title2 })
38284
+ ] }, href)) })
38285
+ ] }) }) })
38286
+ ] });
38287
+ };
38288
+ var login_panel_default = LoginPanel;
38289
+
38290
+ // src/site/next/analytics/fpixel.ts
38291
+ var FB_PIXEL_ID = process.env.NEXT_PUBLIC_FACEBOOK_PIXEL_ID || "";
38292
+ var pageview = () => {
38293
+ window.fbq("track", "PageView");
38294
+ };
38295
+ var FacebookPixel = () => {
38296
+ const [loaded, setLoaded] = React64.useState(false);
38297
+ const pathname = navigation.usePathname();
38298
+ React64.useEffect(() => {
38299
+ if (!loaded) return;
38300
+ pageview();
38301
+ }, [pathname, loaded]);
38302
+ return /* @__PURE__ */ jsxRuntime.jsx("div", { children: /* @__PURE__ */ jsxRuntime.jsx(
38303
+ Script__default.default,
38304
+ {
38305
+ id: "fb-pixel",
38306
+ strategy: "afterInteractive",
38307
+ onLoad: () => setLoaded(true),
38308
+ dangerouslySetInnerHTML: {
38309
+ __html: `
38310
+ !function(f,b,e,v,n,t,s)
38311
+ {if(f.fbq)return;n=f.fbq=function(){n.callMethod?
38312
+ n.callMethod.apply(n,arguments):n.queue.push(arguments)};
38313
+ if(!f._fbq)f._fbq=n;n.push=n;n.loaded=!0;n.version='2.0';
38314
+ n.queue=[];t=b.createElement(e);t.async=!0;
38315
+ t.src=v;s=b.getElementsByTagName(e)[0];
38316
+ s.parentNode.insertBefore(t,s)}(window, document,'script',
38317
+ 'https://connect.facebook.net/en_US/fbevents.js');
38318
+ fbq('init', ${FB_PIXEL_ID});
38319
+ `
38320
+ }
38321
+ }
38322
+ ) });
38323
+ };
38324
+ var Analytics = () => /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
38325
+ /* @__PURE__ */ jsxRuntime.jsx(FacebookPixel, {}),
38326
+ /* @__PURE__ */ jsxRuntime.jsx(google.GoogleAnalytics, { gaId: process.env.NEXT_PUBLIC_GA_MEASUREMENT_ID ?? "" })
38327
+ ] });
38328
+ var Tooltip6 = ({
38329
+ select,
38330
+ text,
38331
+ clx = "",
38332
+ position = "bottom",
38333
+ offset = 2
38334
+ }) => /* @__PURE__ */ jsxRuntime.jsx(
38335
+ reactTooltip.Tooltip,
38336
+ {
38337
+ anchorSelect: select,
38338
+ noArrow: true,
38339
+ opacity: 1,
38340
+ content: text,
38341
+ place: position,
38342
+ offset,
38343
+ delayShow: 100,
38344
+ delayHide: 100,
38345
+ className: "!opacity-100 !bg-level-2 border rounded-[3px] !px-1.5 !py-1 z-floating" + clx
38346
+ }
38347
+ );
38348
+ var tooltip_default = Tooltip6;
36449
38349
 
36450
38350
  Object.defineProperty(exports, "MenubarCheckboxItem", {
36451
38351
  enumerable: true,
@@ -36503,6 +38403,10 @@ Object.defineProperty(exports, "cn", {
36503
38403
  enumerable: true,
36504
38404
  get: function () { return ui.cn; }
36505
38405
  });
38406
+ Object.defineProperty(exports, "EmblaAutoplay", {
38407
+ enumerable: true,
38408
+ get: function () { return emblaCarouselAutoplay__default.default; }
38409
+ });
36506
38410
  exports.AIActions = AIActions;
36507
38411
  exports.AIAgents = AIAgents;
36508
38412
  exports.AIAssistant = AIAssistant;
@@ -36516,12 +38420,14 @@ exports.AIVision = AIVision;
36516
38420
  exports.AIVoice = AIVoice;
36517
38421
  exports.AIVoiceSettings = AIVoiceSettings;
36518
38422
  exports.AI_MODELS = AI_MODELS;
38423
+ exports.AccessCodeInput = access_code_input_default;
36519
38424
  exports.AccordionItem = AccordionItem;
36520
38425
  exports.AccordionItemContent = AccordionItemContent;
36521
38426
  exports.AccordionItemTrigger = AccordionItemTrigger;
36522
38427
  exports.AccordionRoot = AccordionRoot;
36523
38428
  exports.AdvancedNavigationBar = AdvancedNavigationBar;
36524
38429
  exports.Alert = Alert;
38430
+ exports.Analytics = Analytics;
36525
38431
  exports.Android = Android;
36526
38432
  exports.AnimatedBackground = AnimatedBackground;
36527
38433
  exports.AnimatedBackgroundPresets = AnimatedBackgroundPresets;
@@ -36548,6 +38454,7 @@ exports.AuthProvider = AuthProvider;
36548
38454
  exports.AutoListenToggle = AutoListenToggle;
36549
38455
  exports.Avatar = Avatar;
36550
38456
  exports.AvatarGroup = AvatarGroup;
38457
+ exports.BackButton = back_button_default;
36551
38458
  exports.Badge = Badge;
36552
38459
  exports.BankAlert = BankAlert;
36553
38460
  exports.BankAlertText = BankAlertText;
@@ -36571,6 +38478,8 @@ exports.Button3DLoading = Button3DLoading;
36571
38478
  exports.Button3DPreset = Button3DPreset;
36572
38479
  exports.ButtonGroup = ButtonGroup;
36573
38480
  exports.ButtonGroupRadio = ButtonGroupRadio;
38481
+ exports.BuyButton = buy_button_default;
38482
+ exports.BuyDrawer = drawer_default;
36574
38483
  exports.CALLBACK_PATH = CALLBACK_PATH;
36575
38484
  exports.Calendar = Calendar;
36576
38485
  exports.Card3D = Card3D;
@@ -36593,8 +38502,11 @@ exports.ChartStyle = ChartStyle;
36593
38502
  exports.ChartTooltip = ChartTooltip;
36594
38503
  exports.ChartTooltipContent = ChartTooltipContent;
36595
38504
  exports.ChatMessage = ChatMessageComponent;
38505
+ exports.ChatWidget = chat_widget_default;
36596
38506
  exports.Checkbox = Checkbox2;
36597
38507
  exports.CheckboxGroup = CheckboxGroup2;
38508
+ exports.CheckoutButton = checkout_button_default;
38509
+ exports.CheckoutPanel = checkout_panel_default;
36598
38510
  exports.Choicebox = Choicebox;
36599
38511
  exports.CloseButton = CloseButton;
36600
38512
  exports.CodeBlock = CodeBlock;
@@ -36614,7 +38526,9 @@ exports.ColorPicker = ColorPicker;
36614
38526
  exports.Combobox = Combobox;
36615
38527
  exports.CommunicationNavigationBar = CommunicationNavigationBar;
36616
38528
  exports.Comparison = Comparison;
38529
+ exports.ContactDialog = contact_dialog_default;
36617
38530
  exports.ContextSwitcherNavigationBar = ContextSwitcherNavigationBar;
38531
+ exports.Copyright = copyright_default;
36618
38532
  exports.CreditCard = CreditCard;
36619
38533
  exports.Cursor = Cursor;
36620
38534
  exports.CustomInstructions = CustomInstructions;
@@ -36642,6 +38556,7 @@ exports.DrawerContent = DrawerContent;
36642
38556
  exports.DrawerDescription = DrawerDescription;
36643
38557
  exports.DrawerFooter = DrawerFooter;
36644
38558
  exports.DrawerHeader = DrawerHeader;
38559
+ exports.DrawerMargin = drawer_margin_default;
36645
38560
  exports.DrawerRoot = DrawerRoot;
36646
38561
  exports.DrawerTitle = DrawerTitle;
36647
38562
  exports.DrawerTrigger = DrawerTrigger;
@@ -36657,6 +38572,7 @@ exports.EmptyState = EmptyState;
36657
38572
  exports.EmptyTitle = EmptyTitle;
36658
38573
  exports.ExpirationSelector = ExpirationSelector;
36659
38574
  exports.Field = Field;
38575
+ exports.Footer = footer_default;
36660
38576
  exports.Gantt = Gantt;
36661
38577
  exports.GreeksDisplay = GreeksDisplay;
36662
38578
  exports.Grid3D = Grid3D;
@@ -36665,6 +38581,7 @@ exports.Grid3DCard = Grid3DCard;
36665
38581
  exports.Grid3DPreset = Grid3DPreset;
36666
38582
  exports.GridPattern = GridPattern;
36667
38583
  exports.GridPatternPresets = GridPatternPresets;
38584
+ exports.Header = header_default;
36668
38585
  exports.Heading = Heading;
36669
38586
  exports.HeartbeatPulse = HeartbeatPulse;
36670
38587
  exports.IAM_PAGE_SIZE = IAM_PAGE_SIZE;
@@ -36707,7 +38624,11 @@ exports.LinkOverlay = LinkOverlay;
36707
38624
  exports.List = List2;
36708
38625
  exports.ListItem = ListItem;
36709
38626
  exports.LoadingBar = LoadingBar;
38627
+ exports.Login = login_default;
38628
+ exports.LoginPanel = login_panel_default;
38629
+ exports.Logo = Logo;
36710
38630
  exports.Magnetic = Magnetic;
38631
+ exports.Main = main_default;
36711
38632
  exports.Marquee = Marquee;
36712
38633
  exports.Marquee3D = Marquee3D;
36713
38634
  exports.Marquee3DFloating = Marquee3DFloating;
@@ -36730,6 +38651,7 @@ exports.MenubarMenu = MenubarMenu;
36730
38651
  exports.MenubarTrigger = MenubarTrigger;
36731
38652
  exports.MessageDock = MessageDock;
36732
38653
  exports.MiniCalendar = MiniCalendar;
38654
+ exports.MiniChart = wrapper_default;
36733
38655
  exports.MinimalTiptap = MinimalTiptap;
36734
38656
  exports.ModelViewer3D = ModelViewer3D;
36735
38657
  exports.ModelViewer3DPreset = ModelViewer3DPreset;
@@ -36740,6 +38662,7 @@ exports.NativeSelect = NativeSelect;
36740
38662
  exports.NativeSelectOptGroup = NativeSelectOptGroup;
36741
38663
  exports.NativeSelectOption = NativeSelectOption;
36742
38664
  exports.NoiseCancellationToggle = NoiseCancellationToggle;
38665
+ exports.NotFound = not_found_default;
36743
38666
  exports.OptionChain = OptionChain;
36744
38667
  exports.OptionPositionCard = OptionPositionCard;
36745
38668
  exports.OrderEntry = OrderEntry;