@sikka/hawa 0.36.2-next → 0.37.1-next
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/appLayout/index.js +1 -1
- package/dist/appLayout/index.js.map +1 -1
- package/dist/appLayout/index.mjs +1 -1
- package/dist/appLayout/index.mjs.map +1 -1
- package/dist/blocks/auth/index.js +24 -25
- package/dist/blocks/auth/index.mjs +4 -4
- package/dist/blocks/feedback/index.js +24 -25
- package/dist/blocks/feedback/index.mjs +5 -5
- package/dist/blocks/index.js +308 -192
- package/dist/blocks/index.mjs +3 -3
- package/dist/blocks/misc/index.js +270 -154
- package/dist/blocks/misc/index.mjs +53 -19
- package/dist/blocks/pricing/index.js +107 -22
- package/dist/blocks/pricing/index.mjs +4 -4
- package/dist/card/index.d.mts +3 -1
- package/dist/card/index.d.ts +3 -1
- package/dist/card/index.js +13 -11
- package/dist/card/index.js.map +1 -1
- package/dist/card/index.mjs +13 -11
- package/dist/card/index.mjs.map +1 -1
- package/dist/{chunk-WABHQMUI.mjs → chunk-BPHQFAWM.mjs} +1 -1
- package/dist/{chunk-MVKP55SZ.mjs → chunk-BTDR3VAG.mjs} +1 -1
- package/dist/{chunk-7L2JUNG2.mjs → chunk-DS3AACQJ.mjs} +1 -1
- package/dist/{chunk-BXBSZD5X.mjs → chunk-MDHDHEPZ.mjs} +1 -1
- package/dist/{chunk-6QIOEUE2.mjs → chunk-ODOCZAWC.mjs} +1 -1
- package/dist/{chunk-YP2CCKZG.mjs → chunk-PXGL7ZXQ.mjs} +13 -11
- package/dist/{chunk-HLYAX77R.mjs → chunk-QXH7ZDMN.mjs} +12 -15
- package/dist/{chunk-T33FXOHA.mjs → chunk-QYWOI3DO.mjs} +152 -41
- package/dist/{chunk-NNPNQK6F.mjs → chunk-RNFJAEEU.mjs} +13 -11
- package/dist/{chunk-OPYDG34F.mjs → chunk-ZBUBNKF6.mjs} +93 -1
- package/dist/{chunk-CJ57JBYA.mjs → chunk-ZTUWU652.mjs} +95 -12
- package/dist/combobox/index.d.mts +1 -4
- package/dist/combobox/index.d.ts +1 -4
- package/dist/combobox/index.js +2 -1
- package/dist/combobox/index.js.map +1 -1
- package/dist/combobox/index.mjs +2 -1
- package/dist/combobox/index.mjs.map +1 -1
- package/dist/command/index.d.mts +4 -36
- package/dist/command/index.d.ts +4 -36
- package/dist/command/index.js +43 -5
- package/dist/command/index.js.map +1 -1
- package/dist/command/index.mjs +39 -3
- package/dist/command/index.mjs.map +1 -1
- package/dist/destroyableCard/index.js +13 -11
- package/dist/destroyableCard/index.js.map +1 -1
- package/dist/destroyableCard/index.mjs +13 -11
- package/dist/destroyableCard/index.mjs.map +1 -1
- package/dist/elements/index.d.mts +31 -3
- package/dist/elements/index.d.ts +31 -3
- package/dist/elements/index.js +450 -295
- package/dist/elements/index.mjs +43 -6
- package/dist/hooks/index.d.mts +25 -1
- package/dist/hooks/index.d.ts +25 -1
- package/dist/hooks/index.js +96 -0
- package/dist/hooks/index.mjs +9 -1
- package/dist/index-e_Ob_SnB.d.mts +63 -0
- package/dist/index-e_Ob_SnB.d.ts +63 -0
- package/dist/index.css +20 -3
- package/dist/index.d.mts +55 -3
- package/dist/index.d.ts +55 -3
- package/dist/index.js +966 -718
- package/dist/index.mjs +494 -252
- package/dist/layout/index.js +14 -12
- package/dist/layout/index.mjs +3 -3
- package/dist/phoneInput/index.js +11 -14
- package/dist/phoneInput/index.js.map +1 -1
- package/dist/phoneInput/index.mjs +11 -14
- package/dist/phoneInput/index.mjs.map +1 -1
- package/dist/scrollArea/index.js +94 -11
- package/dist/scrollArea/index.js.map +1 -1
- package/dist/scrollArea/index.mjs +94 -11
- package/dist/scrollArea/index.mjs.map +1 -1
- package/dist/select/index.js +11 -14
- package/dist/select/index.js.map +1 -1
- package/dist/select/index.mjs +11 -14
- package/dist/select/index.mjs.map +1 -1
- package/dist/stats/index.js +13 -11
- package/dist/stats/index.js.map +1 -1
- package/dist/stats/index.mjs +13 -11
- package/dist/stats/index.mjs.map +1 -1
- package/dist/tabs/index.d.mts +3 -1
- package/dist/tabs/index.d.ts +3 -1
- package/dist/tabs/index.js +189 -32
- package/dist/tabs/index.js.map +1 -1
- package/dist/tabs/index.mjs +184 -27
- package/dist/tabs/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
@@ -66,17 +66,19 @@ var Card = React.forwardRef(
|
|
66
66
|
);
|
67
67
|
}
|
68
68
|
);
|
69
|
-
var CardHeader = React.forwardRef(
|
70
|
-
"div",
|
71
|
-
|
72
|
-
|
73
|
-
|
74
|
-
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
|
69
|
+
var CardHeader = React.forwardRef(
|
70
|
+
({ className, ...props }, ref) => /* @__PURE__ */ React.createElement("div", { className: "hawa-flex hawa-flex-row hawa-justify-between" }, /* @__PURE__ */ React.createElement(
|
71
|
+
"div",
|
72
|
+
{
|
73
|
+
ref,
|
74
|
+
className: cn(
|
75
|
+
"hawa-flex hawa-flex-col hawa-space-y-1.5 hawa-p-6",
|
76
|
+
className
|
77
|
+
),
|
78
|
+
...props
|
79
|
+
}
|
80
|
+
), props.actions && /* @__PURE__ */ React.createElement("div", { className: "hawa-p-6" }, props.actions))
|
81
|
+
);
|
80
82
|
var CardTitle = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ React.createElement(
|
81
83
|
"h3",
|
82
84
|
{
|
@@ -3478,6 +3480,7 @@ import * as PopoverPrimitive2 from "@radix-ui/react-popover";
|
|
3478
3480
|
|
3479
3481
|
// elements/command/Command.tsx
|
3480
3482
|
import * as React27 from "react";
|
3483
|
+
import { Dialog as Dialog2 } from "@radix-ui/react-dialog";
|
3481
3484
|
import { Command as CommandPrimitive } from "cmdk";
|
3482
3485
|
var Command = React27.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ React27.createElement(
|
3483
3486
|
CommandPrimitive,
|
@@ -3491,7 +3494,7 @@ var Command = React27.forwardRef(({ className, ...props }, ref) => /* @__PURE__
|
|
3491
3494
|
}
|
3492
3495
|
));
|
3493
3496
|
var CommandDialog = ({ children, ...props }) => {
|
3494
|
-
return /* @__PURE__ */ React27.createElement(
|
3497
|
+
return /* @__PURE__ */ React27.createElement(Dialog2, { ...props }, /* @__PURE__ */ React27.createElement(DialogContent, { className: "hawa-overflow-hidden hawa-p-0 hawa-shadow-lg" }, /* @__PURE__ */ React27.createElement(Command, { className: "[&_[cmdk-group-heading]]:hawa-px-2 [&_[cmdk-group-heading]]:hawa-font-medium [&_[cmdk-group-heading]]:hawa-text-muted-foreground [&_[cmdk-group]:not([hidden])_~[cmdk-group]]:hawa-pt-0 [&_[cmdk-group]]:hawa-px-2 [&_[cmdk-input-wrapper]_svg]:hawa-h-5 [&_[cmdk-input-wrapper]_svg]:hawa-w-5 [&_[cmdk-input]]:hawa-h-12 [&_[cmdk-item]]:hawa-px-2 [&_[cmdk-item]]:hawa-py-3 [&_[cmdk-item]_svg]:hawa-h-5 [&_[cmdk-item]_svg]:hawa-w-5" }, children)));
|
3495
3498
|
};
|
3496
3499
|
var CommandInput = React27.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ React27.createElement(
|
3497
3500
|
"div",
|
@@ -3586,13 +3589,47 @@ var CommandShortcut = ({
|
|
3586
3589
|
"span",
|
3587
3590
|
{
|
3588
3591
|
className: cn(
|
3589
|
-
"hawa-
|
3592
|
+
"hawa-ms-auto hawa-text-xs hawa-tracking-widest hawa-text-muted-foreground",
|
3590
3593
|
className
|
3591
3594
|
),
|
3592
3595
|
...props
|
3593
3596
|
}
|
3594
3597
|
);
|
3595
3598
|
};
|
3599
|
+
var FullCommand = ({ items, direction = "ltr", texts }) => {
|
3600
|
+
return /* @__PURE__ */ React27.createElement(
|
3601
|
+
Command,
|
3602
|
+
{
|
3603
|
+
dir: direction,
|
3604
|
+
className: "hawa-rounded-lg hawa-border hawa-shadow-md !hawa-h-full"
|
3605
|
+
},
|
3606
|
+
/* @__PURE__ */ React27.createElement(
|
3607
|
+
CommandInput,
|
3608
|
+
{
|
3609
|
+
placeholder: (texts == null ? void 0 : texts.searchPlaceholder) || "Type a command or search..."
|
3610
|
+
}
|
3611
|
+
),
|
3612
|
+
/* @__PURE__ */ React27.createElement(CommandList, null, /* @__PURE__ */ React27.createElement(CommandEmpty, null, (texts == null ? void 0 : texts.emptyText) || "No results found."), items.map((item, index) => {
|
3613
|
+
var _a;
|
3614
|
+
if (item.type === "group") {
|
3615
|
+
return /* @__PURE__ */ React27.createElement(CommandGroup, { heading: item.heading, key: index }, (_a = item.items) == null ? void 0 : _a.map((subItem, subIndex) => /* @__PURE__ */ React27.createElement(CommandItem, { key: subIndex, onSelect: subItem.action }, /* @__PURE__ */ React27.createElement(subItem.icon, { className: "hawa-icon hawa-me-2" }), /* @__PURE__ */ React27.createElement("span", null, subItem.text), subItem.shortcut && /* @__PURE__ */ React27.createElement(CommandShortcut, null, subItem.shortcut))));
|
3616
|
+
} else if (item.type === "separator") {
|
3617
|
+
return /* @__PURE__ */ React27.createElement(CommandSeparator, { key: index });
|
3618
|
+
}
|
3619
|
+
return null;
|
3620
|
+
}))
|
3621
|
+
);
|
3622
|
+
};
|
3623
|
+
var AppCommand = ({ commandProps, dialogProps }) => {
|
3624
|
+
return /* @__PURE__ */ React27.createElement(Dialog2, { ...dialogProps }, /* @__PURE__ */ React27.createElement(
|
3625
|
+
DialogContent,
|
3626
|
+
{
|
3627
|
+
hideCloseButton: true,
|
3628
|
+
className: "hawa-overflow-hidden !hawa-p-0 hawa-shadow-l "
|
3629
|
+
},
|
3630
|
+
/* @__PURE__ */ React27.createElement(FullCommand, { ...commandProps })
|
3631
|
+
));
|
3632
|
+
};
|
3596
3633
|
CommandShortcut.displayName = "CommandShortcut";
|
3597
3634
|
CommandItem.displayName = CommandPrimitive.Item.displayName;
|
3598
3635
|
CommandSeparator.displayName = CommandPrimitive.Separator.displayName;
|
@@ -4085,7 +4122,7 @@ var SortButton = (props) => {
|
|
4085
4122
|
};
|
4086
4123
|
|
4087
4124
|
// elements/tabs/Tabs.tsx
|
4088
|
-
import * as
|
4125
|
+
import * as React42 from "react";
|
4089
4126
|
|
4090
4127
|
// hooks/useIsomorphicEffect.ts
|
4091
4128
|
import { useEffect as useEffect7, useLayoutEffect } from "react";
|
@@ -4531,6 +4568,94 @@ function useClickOutside(handler, events, nodes) {
|
|
4531
4568
|
return ref;
|
4532
4569
|
}
|
4533
4570
|
|
4571
|
+
// hooks/useShortcuts.ts
|
4572
|
+
import { useEffect as useEffect21 } from "react";
|
4573
|
+
function parseHotkey(hotkey) {
|
4574
|
+
const keys = hotkey.toLowerCase().split("+").map((part) => part.trim());
|
4575
|
+
const modifiers = {
|
4576
|
+
alt: keys.includes("alt"),
|
4577
|
+
ctrl: keys.includes("ctrl"),
|
4578
|
+
meta: keys.includes("meta"),
|
4579
|
+
mod: keys.includes("mod"),
|
4580
|
+
shift: keys.includes("shift")
|
4581
|
+
};
|
4582
|
+
const reservedKeys = ["alt", "ctrl", "meta", "shift", "mod"];
|
4583
|
+
const freeKey = keys.find((key) => !reservedKeys.includes(key));
|
4584
|
+
return {
|
4585
|
+
...modifiers,
|
4586
|
+
key: freeKey
|
4587
|
+
};
|
4588
|
+
}
|
4589
|
+
function isExactHotkey(hotkey, event) {
|
4590
|
+
const { alt, ctrl, meta, mod, shift, key } = hotkey;
|
4591
|
+
const { altKey, ctrlKey, metaKey, shiftKey, key: pressedKey } = event;
|
4592
|
+
if (alt !== altKey) {
|
4593
|
+
return false;
|
4594
|
+
}
|
4595
|
+
if (mod) {
|
4596
|
+
if (!ctrlKey && !metaKey) {
|
4597
|
+
return false;
|
4598
|
+
}
|
4599
|
+
} else {
|
4600
|
+
if (ctrl !== ctrlKey) {
|
4601
|
+
return false;
|
4602
|
+
}
|
4603
|
+
if (meta !== metaKey) {
|
4604
|
+
return false;
|
4605
|
+
}
|
4606
|
+
}
|
4607
|
+
if (shift !== shiftKey) {
|
4608
|
+
return false;
|
4609
|
+
}
|
4610
|
+
if (key && (pressedKey.toLowerCase() === key.toLowerCase() || event.code.replace("Key", "").toLowerCase() === key.toLowerCase())) {
|
4611
|
+
return true;
|
4612
|
+
}
|
4613
|
+
return false;
|
4614
|
+
}
|
4615
|
+
function getHotkeyMatcher(hotkey) {
|
4616
|
+
return (event) => isExactHotkey(parseHotkey(hotkey), event);
|
4617
|
+
}
|
4618
|
+
function getHotkeyHandler(hotkeys) {
|
4619
|
+
return (event) => {
|
4620
|
+
const _event = "nativeEvent" in event ? event.nativeEvent : event;
|
4621
|
+
hotkeys.forEach(([hotkey, handler, options = { preventDefault: true }]) => {
|
4622
|
+
if (getHotkeyMatcher(hotkey)(_event)) {
|
4623
|
+
if (options.preventDefault) {
|
4624
|
+
event.preventDefault();
|
4625
|
+
}
|
4626
|
+
handler(_event);
|
4627
|
+
}
|
4628
|
+
});
|
4629
|
+
};
|
4630
|
+
}
|
4631
|
+
function shouldFireEvent(event, tagsToIgnore, triggerOnContentEditable = false) {
|
4632
|
+
if (event.target instanceof HTMLElement) {
|
4633
|
+
if (triggerOnContentEditable) {
|
4634
|
+
return !tagsToIgnore.includes(event.target.tagName);
|
4635
|
+
}
|
4636
|
+
return !event.target.isContentEditable && !tagsToIgnore.includes(event.target.tagName);
|
4637
|
+
}
|
4638
|
+
return true;
|
4639
|
+
}
|
4640
|
+
function useShortcuts(hotkeys, tagsToIgnore = ["INPUT", "TEXTAREA", "SELECT"], triggerOnContentEditable = false) {
|
4641
|
+
useEffect21(() => {
|
4642
|
+
const keydownListener = (event) => {
|
4643
|
+
hotkeys.forEach(
|
4644
|
+
([hotkey, handler, options = { preventDefault: true }]) => {
|
4645
|
+
if (getHotkeyMatcher(hotkey)(event) && shouldFireEvent(event, tagsToIgnore, triggerOnContentEditable)) {
|
4646
|
+
if (options.preventDefault) {
|
4647
|
+
event.preventDefault();
|
4648
|
+
}
|
4649
|
+
handler(event);
|
4650
|
+
}
|
4651
|
+
}
|
4652
|
+
);
|
4653
|
+
};
|
4654
|
+
document.documentElement.addEventListener("keydown", keydownListener);
|
4655
|
+
return () => document.documentElement.removeEventListener("keydown", keydownListener);
|
4656
|
+
}, [hotkeys]);
|
4657
|
+
}
|
4658
|
+
|
4534
4659
|
// elements/tabs/Tabs.tsx
|
4535
4660
|
import * as TabsPrimitive from "@radix-ui/react-tabs";
|
4536
4661
|
import { tv } from "tailwind-variants";
|
@@ -4590,14 +4715,137 @@ var FloatBox = ({
|
|
4590
4715
|
);
|
4591
4716
|
};
|
4592
4717
|
|
4718
|
+
// elements/scrollArea/ScrollArea.tsx
|
4719
|
+
import * as React41 from "react";
|
4720
|
+
import * as ScrollAreaPrimitive from "@radix-ui/react-scroll-area";
|
4721
|
+
var ScrollArea = React41.forwardRef(({ className, children, orientation = "vertical", ...props }, ref) => {
|
4722
|
+
const scrollAreaRef = React41.useRef(null);
|
4723
|
+
const isDragging = React41.useRef(false);
|
4724
|
+
const startPos = React41.useRef({ x: 0, y: 0 });
|
4725
|
+
const scrollPos = React41.useRef({ top: 0, left: 0 });
|
4726
|
+
const [showLeftFade, setShowLeftFade] = React41.useState(false);
|
4727
|
+
const [showRightFade, setShowRightFade] = React41.useState(false);
|
4728
|
+
const checkOverflow = () => {
|
4729
|
+
if (scrollAreaRef.current) {
|
4730
|
+
const { scrollLeft, scrollWidth, clientWidth } = scrollAreaRef.current;
|
4731
|
+
setShowLeftFade(scrollLeft > 0);
|
4732
|
+
setShowRightFade(scrollLeft + clientWidth < scrollWidth);
|
4733
|
+
}
|
4734
|
+
};
|
4735
|
+
const onMouseDown = (e) => {
|
4736
|
+
isDragging.current = true;
|
4737
|
+
startPos.current = { x: e.clientX, y: e.clientY };
|
4738
|
+
if (scrollAreaRef.current) {
|
4739
|
+
scrollPos.current = {
|
4740
|
+
top: scrollAreaRef.current.scrollTop,
|
4741
|
+
left: scrollAreaRef.current.scrollLeft
|
4742
|
+
};
|
4743
|
+
}
|
4744
|
+
document.addEventListener("mousemove", onMouseMove);
|
4745
|
+
document.addEventListener("mouseup", onMouseUp);
|
4746
|
+
};
|
4747
|
+
const onMouseMove = (e) => {
|
4748
|
+
if (!isDragging.current || !scrollAreaRef.current)
|
4749
|
+
return;
|
4750
|
+
const dx = e.clientX - startPos.current.x;
|
4751
|
+
const dy = e.clientY - startPos.current.y;
|
4752
|
+
if (orientation === "vertical") {
|
4753
|
+
scrollAreaRef.current.scrollTop = scrollPos.current.top - dy;
|
4754
|
+
} else {
|
4755
|
+
scrollAreaRef.current.scrollLeft = scrollPos.current.left - dx;
|
4756
|
+
checkOverflow();
|
4757
|
+
}
|
4758
|
+
};
|
4759
|
+
const onMouseUp = () => {
|
4760
|
+
isDragging.current = false;
|
4761
|
+
document.removeEventListener("mousemove", onMouseMove);
|
4762
|
+
document.removeEventListener("mouseup", onMouseUp);
|
4763
|
+
};
|
4764
|
+
React41.useEffect(() => {
|
4765
|
+
checkOverflow();
|
4766
|
+
if (scrollAreaRef.current) {
|
4767
|
+
scrollAreaRef.current.addEventListener("scroll", checkOverflow);
|
4768
|
+
window.addEventListener("resize", checkOverflow);
|
4769
|
+
}
|
4770
|
+
return () => {
|
4771
|
+
if (scrollAreaRef.current) {
|
4772
|
+
scrollAreaRef.current.removeEventListener("scroll", checkOverflow);
|
4773
|
+
}
|
4774
|
+
window.removeEventListener("resize", checkOverflow);
|
4775
|
+
};
|
4776
|
+
}, []);
|
4777
|
+
return /* @__PURE__ */ React41.createElement(
|
4778
|
+
ScrollAreaPrimitive.Root,
|
4779
|
+
{
|
4780
|
+
ref,
|
4781
|
+
className: cn("hawa-relative hawa-overflow-hidden", className),
|
4782
|
+
...props
|
4783
|
+
},
|
4784
|
+
/* @__PURE__ */ React41.createElement(
|
4785
|
+
"div",
|
4786
|
+
{
|
4787
|
+
className: cn(
|
4788
|
+
"hawa-pointer-events-none hawa-absolute hawa-bg-background/ hawa-h-full hawa-w-[50px] hawa-z-10 hawa-start-0 hawa-mask-fade-right",
|
4789
|
+
showLeftFade ? "hawa-block" : "hawa-hidden"
|
4790
|
+
)
|
4791
|
+
}
|
4792
|
+
),
|
4793
|
+
/* @__PURE__ */ React41.createElement(
|
4794
|
+
"div",
|
4795
|
+
{
|
4796
|
+
className: cn(
|
4797
|
+
"hawa-pointer-events-none hawa-absolute hawa-bg-background/ hawa-mask-fade-left hawa-end-0 hawa-h-full hawa-w-[50px] hawa-z-10 ",
|
4798
|
+
showRightFade ? "hawa-block" : "hawa-hidden"
|
4799
|
+
)
|
4800
|
+
}
|
4801
|
+
),
|
4802
|
+
/* @__PURE__ */ React41.createElement(
|
4803
|
+
ScrollAreaPrimitive.Viewport,
|
4804
|
+
{
|
4805
|
+
ref: scrollAreaRef,
|
4806
|
+
className: "hawa-h-full hawa-w-full hawa-rounded-[inherit]",
|
4807
|
+
onMouseDown
|
4808
|
+
},
|
4809
|
+
children
|
4810
|
+
),
|
4811
|
+
/* @__PURE__ */ React41.createElement(ScrollBar, { orientation }),
|
4812
|
+
/* @__PURE__ */ React41.createElement(ScrollAreaPrimitive.Corner, null)
|
4813
|
+
);
|
4814
|
+
});
|
4815
|
+
ScrollArea.displayName = ScrollAreaPrimitive.Root.displayName;
|
4816
|
+
var ScrollBar = React41.forwardRef(({ className, orientation = "vertical", ...props }, ref) => /* @__PURE__ */ React41.createElement(
|
4817
|
+
ScrollAreaPrimitive.ScrollAreaScrollbar,
|
4818
|
+
{
|
4819
|
+
ref,
|
4820
|
+
orientation,
|
4821
|
+
className: cn(
|
4822
|
+
"hawa-flex hawa-touch-none hawa-select-none hawa-transition-colors",
|
4823
|
+
orientation === "vertical" && "hawa-h-full hawa-w-2.5 hawa-border-l hawa-border-l-transparent hawa-p-[1px]",
|
4824
|
+
orientation === "horizontal" && "hawa-h-2.5 hawa-border-t hawa-border-t-transparent hawa-p-[1px]",
|
4825
|
+
className
|
4826
|
+
),
|
4827
|
+
...props
|
4828
|
+
},
|
4829
|
+
/* @__PURE__ */ React41.createElement(
|
4830
|
+
ScrollAreaPrimitive.ScrollAreaThumb,
|
4831
|
+
{
|
4832
|
+
className: cn(
|
4833
|
+
"hawa-relative hawa-rounded-full hawa-bg-border",
|
4834
|
+
orientation === "vertical" && "hawa-flex-1"
|
4835
|
+
)
|
4836
|
+
}
|
4837
|
+
)
|
4838
|
+
));
|
4839
|
+
ScrollBar.displayName = ScrollAreaPrimitive.ScrollAreaScrollbar.displayName;
|
4840
|
+
|
4593
4841
|
// elements/tabs/Tabs.tsx
|
4594
4842
|
var tabsListVariant = tv({
|
4595
4843
|
base: "",
|
4596
4844
|
variants: {
|
4597
4845
|
variant: {
|
4598
|
-
default: "hawa-flex hawa-w-fit hawa-
|
4599
|
-
underlined: "hawa-flex hawa-w-fit hawa-
|
4600
|
-
underlined_tabs: "hawa-flex hawa-w-fit hawa-
|
4846
|
+
default: "hawa-flex hawa-w-fit hawa-items-center hawa-justify-start hawa-gap-1 hawa-rounded hawa-border hawa-bg-muted hawa-p-1 hawa-text-muted-foreground dark:hawa-border-primary/10",
|
4847
|
+
underlined: "hawa-flex hawa-w-fit hawa-items-center hawa-justify-start hawa-gap-1 hawa-rounded hawa-p-1 hawa-text-muted-foreground dark:hawa-border-primary/10",
|
4848
|
+
underlined_tabs: "hawa-flex hawa-w-fit hawa-items-center hawa-justify-start hawa-gap-1 hawa-text-muted-foreground"
|
4601
4849
|
},
|
4602
4850
|
orientation: { horizontal: "", vertical: "" }
|
4603
4851
|
},
|
@@ -4649,8 +4897,8 @@ var tabsTriggerVariant = tv({
|
|
4649
4897
|
],
|
4650
4898
|
defaultVariants: { variant: "default", orientation: "horizontal" }
|
4651
4899
|
});
|
4652
|
-
var TabsContext =
|
4653
|
-
var Tabs =
|
4900
|
+
var TabsContext = React42.createContext({ orientation: "horizontal", variant: "default" });
|
4901
|
+
var Tabs = React42.forwardRef(({ className, orientation, variant = "default", ...props }, ref) => /* @__PURE__ */ React42.createElement(
|
4654
4902
|
TabsPrimitive.Root,
|
4655
4903
|
{
|
4656
4904
|
ref,
|
@@ -4661,28 +4909,59 @@ var Tabs = React41.forwardRef(({ className, orientation, variant = "default", ..
|
|
4661
4909
|
),
|
4662
4910
|
...props
|
4663
4911
|
},
|
4664
|
-
/* @__PURE__ */
|
4912
|
+
/* @__PURE__ */ React42.createElement(TabsContext.Provider, { value: { orientation, variant } }, props.children)
|
4665
4913
|
));
|
4666
|
-
var TabsList =
|
4667
|
-
const { orientation, variant } =
|
4668
|
-
|
4669
|
-
|
4670
|
-
{
|
4671
|
-
ref,
|
4672
|
-
className: cn(
|
4673
|
-
tabsListVariant({ variant, orientation }),
|
4674
|
-
orientation === "vertical" ? "hawa-flex-col" : "hawa-flex-row",
|
4675
|
-
className
|
4676
|
-
),
|
4677
|
-
...props
|
4678
|
-
}
|
4914
|
+
var TabsList = React42.forwardRef(({ className, ...props }, ref) => {
|
4915
|
+
const { orientation, variant } = React42.useContext(TabsContext);
|
4916
|
+
const [size, setSize] = React42.useState(
|
4917
|
+
typeof window !== "undefined" && window.innerWidth || 1200
|
4679
4918
|
);
|
4919
|
+
React42.useEffect(() => {
|
4920
|
+
if (typeof window !== "undefined") {
|
4921
|
+
const resize = () => {
|
4922
|
+
setSize(window.innerWidth);
|
4923
|
+
};
|
4924
|
+
resize();
|
4925
|
+
window.addEventListener("resize", resize);
|
4926
|
+
return () => {
|
4927
|
+
window.removeEventListener("resize", resize);
|
4928
|
+
};
|
4929
|
+
}
|
4930
|
+
}, []);
|
4931
|
+
if ((props.scrollable || size < 768) && orientation === "horizontal") {
|
4932
|
+
return /* @__PURE__ */ React42.createElement(ScrollArea, { orientation: "horizontal" }, /* @__PURE__ */ React42.createElement(
|
4933
|
+
TabsPrimitive.List,
|
4934
|
+
{
|
4935
|
+
ref,
|
4936
|
+
className: cn(
|
4937
|
+
tabsListVariant({ variant, orientation }),
|
4938
|
+
"hawa-flex-row hawa-flex-nowrap",
|
4939
|
+
className
|
4940
|
+
),
|
4941
|
+
...props
|
4942
|
+
}
|
4943
|
+
));
|
4944
|
+
} else {
|
4945
|
+
return /* @__PURE__ */ React42.createElement(
|
4946
|
+
TabsPrimitive.List,
|
4947
|
+
{
|
4948
|
+
ref,
|
4949
|
+
className: cn(
|
4950
|
+
tabsListVariant({ variant, orientation }),
|
4951
|
+
orientation === "vertical" ? "hawa-flex-col" : "hawa-flex-row",
|
4952
|
+
"hawa-flex-wrap",
|
4953
|
+
className
|
4954
|
+
),
|
4955
|
+
...props
|
4956
|
+
}
|
4957
|
+
);
|
4958
|
+
}
|
4680
4959
|
});
|
4681
|
-
var TabsTrigger =
|
4682
|
-
const { orientation, variant } =
|
4683
|
-
const tabTriggerRef =
|
4960
|
+
var TabsTrigger = React42.forwardRef(({ className, chipProps, ...props }, ref) => {
|
4961
|
+
const { orientation, variant } = React42.useContext(TabsContext);
|
4962
|
+
const tabTriggerRef = React42.useRef(null);
|
4684
4963
|
const { width } = useMeasureDirty(tabTriggerRef);
|
4685
|
-
return /* @__PURE__ */
|
4964
|
+
return /* @__PURE__ */ React42.createElement(
|
4686
4965
|
TabsPrimitive.Trigger,
|
4687
4966
|
{
|
4688
4967
|
ref: tabTriggerRef,
|
@@ -4694,8 +4973,8 @@ var TabsTrigger = React41.forwardRef(({ className, chipProps, ...props }, ref) =
|
|
4694
4973
|
...props
|
4695
4974
|
},
|
4696
4975
|
props.children,
|
4697
|
-
chipProps && /* @__PURE__ */
|
4698
|
-
/* @__PURE__ */
|
4976
|
+
chipProps && /* @__PURE__ */ React42.createElement(Chip, { ...chipProps }),
|
4977
|
+
/* @__PURE__ */ React42.createElement(
|
4699
4978
|
FloatBox,
|
4700
4979
|
{
|
4701
4980
|
withArrow: true,
|
@@ -4708,7 +4987,7 @@ var TabsTrigger = React41.forwardRef(({ className, chipProps, ...props }, ref) =
|
|
4708
4987
|
)
|
4709
4988
|
);
|
4710
4989
|
});
|
4711
|
-
var TabsContent =
|
4990
|
+
var TabsContent = React42.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ React42.createElement(
|
4712
4991
|
TabsPrimitive.Content,
|
4713
4992
|
{
|
4714
4993
|
ref,
|
@@ -4725,7 +5004,7 @@ TabsTrigger.displayName = TabsPrimitive.Trigger.displayName;
|
|
4725
5004
|
TabsContent.displayName = TabsPrimitive.Content.displayName;
|
4726
5005
|
|
4727
5006
|
// elements/select/Select.tsx
|
4728
|
-
import
|
5007
|
+
import React43 from "react";
|
4729
5008
|
import ReactSelect from "react-select";
|
4730
5009
|
import CreatableSelect from "react-select/creatable";
|
4731
5010
|
import clsx3 from "clsx";
|
@@ -4736,10 +5015,10 @@ var Select = ({
|
|
4736
5015
|
}) => {
|
4737
5016
|
const NoOption = () => {
|
4738
5017
|
var _a, _b;
|
4739
|
-
return /* @__PURE__ */
|
5018
|
+
return /* @__PURE__ */ React43.createElement("div", null, (_b = (_a = props.texts) == null ? void 0 : _a.noOptions) != null ? _b : "No Items Found");
|
4740
5019
|
};
|
4741
5020
|
const Control = ({ children, innerProps, innerRef }) => {
|
4742
|
-
return /* @__PURE__ */
|
5021
|
+
return /* @__PURE__ */ React43.createElement(
|
4743
5022
|
"div",
|
4744
5023
|
{
|
4745
5024
|
ref: innerRef,
|
@@ -4752,7 +5031,7 @@ var Select = ({
|
|
4752
5031
|
);
|
4753
5032
|
};
|
4754
5033
|
const Option = ({ children, innerProps, innerRef }) => {
|
4755
|
-
return /* @__PURE__ */
|
5034
|
+
return /* @__PURE__ */ React43.createElement(
|
4756
5035
|
"div",
|
4757
5036
|
{
|
4758
5037
|
ref: innerRef,
|
@@ -4773,7 +5052,7 @@ var Select = ({
|
|
4773
5052
|
...menuProps
|
4774
5053
|
}) => {
|
4775
5054
|
const menuOpen = menuProps.selectProps.menuIsOpen;
|
4776
|
-
return /* @__PURE__ */
|
5055
|
+
return /* @__PURE__ */ React43.createElement(
|
4777
5056
|
"div",
|
4778
5057
|
{
|
4779
5058
|
className: cn(
|
@@ -4787,7 +5066,11 @@ var Select = ({
|
|
4787
5066
|
children
|
4788
5067
|
);
|
4789
5068
|
};
|
4790
|
-
|
5069
|
+
let phoneCodeStyles = "hawa-min-w-[65px] hawa-text-right hawa-w-[100px] hawa-p-0 hawa-rounded-r-none hawa-h-[40px]";
|
5070
|
+
let selectContainerStyles = "hawa-rounded hawa-block hawa-w-full hawa-border hawa-transition-all hawa-bg-background hawa-p-0 hawa-px-1 hawa-text-sm";
|
5071
|
+
let selectPlaceholderStyles = "hawa-text-muted-foreground hawa-cursor-pointer hawa-px-1";
|
5072
|
+
let selectIndicatorContainerStyles = "hawa-cursor-pointer hawa-text-muted-foreground hawa-absolute hawa-end-0 hawa-top-[50%] hawa-bottom-[50%] ";
|
5073
|
+
return /* @__PURE__ */ React43.createElement(
|
4791
5074
|
"div",
|
4792
5075
|
{
|
4793
5076
|
className: cn(
|
@@ -4795,10 +5078,10 @@ var Select = ({
|
|
4795
5078
|
props.width === "fit" ? "hawa-w-fit" : "hawa-w-full"
|
4796
5079
|
)
|
4797
5080
|
},
|
4798
|
-
props.label && /* @__PURE__ */
|
4799
|
-
props.isLoading ? /* @__PURE__ */
|
5081
|
+
props.label && /* @__PURE__ */ React43.createElement(Label2, { ...labelProps }, props.label),
|
5082
|
+
props.isLoading ? /* @__PURE__ */ React43.createElement(Skeleton, { className: "hawa-h-[40px] hawa-w-full" }) : !props.isCreatable ? (
|
4800
5083
|
// TODO: enable keyboard to go to the next item in the list
|
4801
|
-
/* @__PURE__ */
|
5084
|
+
/* @__PURE__ */ React43.createElement(
|
4802
5085
|
ReactSelect,
|
4803
5086
|
{
|
4804
5087
|
noOptionsMessage: NoOption,
|
@@ -4808,26 +5091,22 @@ var Select = ({
|
|
4808
5091
|
props.controlClassNames
|
4809
5092
|
),
|
4810
5093
|
container: () => cn(
|
4811
|
-
|
4812
|
-
props.phoneCode &&
|
4813
|
-
"hawa-block hawa-w-full hawa-rounded hawa-border hawa-transition-all hawa-bg-background hawa-p-0 hawa-px-1 hawa-text-sm",
|
5094
|
+
selectContainerStyles,
|
5095
|
+
props.phoneCode && phoneCodeStyles,
|
4814
5096
|
props.disabled ? "hawa-cursor-not-allowed" : "hawa-cursor-pointer",
|
4815
5097
|
props.isMulti && "hawa-ps-0 "
|
4816
5098
|
),
|
4817
|
-
placeholder: () =>
|
5099
|
+
placeholder: () => selectPlaceholderStyles,
|
4818
5100
|
valueContainer: () => "hawa-text-foreground hawa-px-1 ",
|
4819
5101
|
singleValue: () => "hawa-text-foreground",
|
4820
5102
|
indicatorsContainer: () => cn(
|
4821
|
-
|
5103
|
+
selectIndicatorContainerStyles,
|
4822
5104
|
props.hideIndicator ? "hawa-invisible" : "hawa-px-1"
|
4823
5105
|
)
|
4824
5106
|
},
|
4825
5107
|
unstyled: true,
|
4826
|
-
|
4827
|
-
|
4828
|
-
Menu: Menu2,
|
4829
|
-
IndicatorsContainer: () => null
|
4830
|
-
} : {
|
5108
|
+
autoFocus: false,
|
5109
|
+
components: props.hideIndicator ? { Option, Menu: Menu2, IndicatorsContainer: () => null } : {
|
4831
5110
|
Option,
|
4832
5111
|
Menu: Menu2,
|
4833
5112
|
// Control: (e) => (
|
@@ -4836,7 +5115,7 @@ var Select = ({
|
|
4836
5115
|
// {...e}
|
4837
5116
|
// />
|
4838
5117
|
// ),
|
4839
|
-
ValueContainer: (e) => /* @__PURE__ */
|
5118
|
+
ValueContainer: (e) => /* @__PURE__ */ React43.createElement(
|
4840
5119
|
"div",
|
4841
5120
|
{
|
4842
5121
|
className: cn(
|
@@ -4846,13 +5125,10 @@ var Select = ({
|
|
4846
5125
|
...e
|
4847
5126
|
}
|
4848
5127
|
),
|
4849
|
-
MultiValueContainer: (e) => /* @__PURE__ */
|
5128
|
+
MultiValueContainer: (e) => /* @__PURE__ */ React43.createElement(
|
4850
5129
|
"div",
|
4851
5130
|
{
|
4852
|
-
className:
|
4853
|
-
// e.className,
|
4854
|
-
"hawa-rounded hawa-border hawa-p-1 hawa-px-2 hawa-flex hawa-flex-row"
|
4855
|
-
),
|
5131
|
+
className: "hawa-rounded hawa-border hawa-p-1 hawa-px-2 hawa-flex hawa-flex-row",
|
4856
5132
|
...e
|
4857
5133
|
}
|
4858
5134
|
)
|
@@ -4868,7 +5144,7 @@ var Select = ({
|
|
4868
5144
|
isSearchable: props.isSearchable
|
4869
5145
|
}
|
4870
5146
|
)
|
4871
|
-
) : /* @__PURE__ */
|
5147
|
+
) : /* @__PURE__ */ React43.createElement(
|
4872
5148
|
CreatableSelect,
|
4873
5149
|
{
|
4874
5150
|
formatCreateLabel: (inputValue) => {
|
@@ -4898,7 +5174,7 @@ var Select = ({
|
|
4898
5174
|
onInputChange: (newValue, action) => props.onInputChange(newValue, action)
|
4899
5175
|
}
|
4900
5176
|
),
|
4901
|
-
!props.hideHelperText && /* @__PURE__ */
|
5177
|
+
!props.hideHelperText && /* @__PURE__ */ React43.createElement(
|
4902
5178
|
"p",
|
4903
5179
|
{
|
4904
5180
|
className: cn(
|
@@ -4912,15 +5188,15 @@ var Select = ({
|
|
4912
5188
|
};
|
4913
5189
|
|
4914
5190
|
// elements/switch/Switch.tsx
|
4915
|
-
import * as
|
5191
|
+
import * as React44 from "react";
|
4916
5192
|
import * as SwitchPrimitives from "@radix-ui/react-switch";
|
4917
|
-
var Switch =
|
5193
|
+
var Switch = React44.forwardRef(
|
4918
5194
|
({ className, size = "default", roundedness = "inherit", label, ...props }, ref) => {
|
4919
|
-
const [parentDirection, setParentDirection] =
|
5195
|
+
const [parentDirection, setParentDirection] = React44.useState(
|
4920
5196
|
null
|
4921
5197
|
);
|
4922
|
-
const parentRef =
|
4923
|
-
|
5198
|
+
const parentRef = React44.useRef(null);
|
5199
|
+
React44.useEffect(() => {
|
4924
5200
|
var _a;
|
4925
5201
|
const parentNode = (_a = parentRef.current) == null ? void 0 : _a.parentNode;
|
4926
5202
|
if (parentNode) {
|
@@ -4948,13 +5224,13 @@ var Switch = React43.forwardRef(
|
|
4948
5224
|
full: "hawa-rounded-full",
|
4949
5225
|
inherit: "hawa-rounded-inner"
|
4950
5226
|
};
|
4951
|
-
return /* @__PURE__ */
|
5227
|
+
return /* @__PURE__ */ React44.createElement(
|
4952
5228
|
"div",
|
4953
5229
|
{
|
4954
5230
|
className: "hawa-flex hawa-flex-row hawa-items-center",
|
4955
5231
|
ref: parentRef
|
4956
5232
|
},
|
4957
|
-
/* @__PURE__ */
|
5233
|
+
/* @__PURE__ */ React44.createElement(
|
4958
5234
|
SwitchPrimitives.Root,
|
4959
5235
|
{
|
4960
5236
|
className: cn(
|
@@ -4968,7 +5244,7 @@ var Switch = React43.forwardRef(
|
|
4968
5244
|
...props,
|
4969
5245
|
ref
|
4970
5246
|
},
|
4971
|
-
/* @__PURE__ */
|
5247
|
+
/* @__PURE__ */ React44.createElement(
|
4972
5248
|
SwitchPrimitives.Thumb,
|
4973
5249
|
{
|
4974
5250
|
className: cn(
|
@@ -4982,14 +5258,14 @@ var Switch = React43.forwardRef(
|
|
4982
5258
|
}
|
4983
5259
|
)
|
4984
5260
|
),
|
4985
|
-
label && /* @__PURE__ */
|
5261
|
+
label && /* @__PURE__ */ React44.createElement("span", { className: "hawa-mx-2 hawa-text-sm hawa-font-medium hawa-text-gray-900 dark:hawa-text-gray-300" }, label)
|
4986
5262
|
);
|
4987
5263
|
}
|
4988
5264
|
);
|
4989
5265
|
Switch.displayName = SwitchPrimitives.Root.displayName;
|
4990
5266
|
|
4991
5267
|
// elements/checkbox/Checkbox.tsx
|
4992
|
-
import * as
|
5268
|
+
import * as React45 from "react";
|
4993
5269
|
import * as CheckboxPrimitive from "@radix-ui/react-checkbox";
|
4994
5270
|
var Checkbox = ({
|
4995
5271
|
id,
|
@@ -5009,7 +5285,7 @@ var Checkbox = ({
|
|
5009
5285
|
lg: 0.9,
|
5010
5286
|
xl: 1
|
5011
5287
|
};
|
5012
|
-
return /* @__PURE__ */
|
5288
|
+
return /* @__PURE__ */ React45.createElement(
|
5013
5289
|
"div",
|
5014
5290
|
{
|
5015
5291
|
className: cn(
|
@@ -5017,7 +5293,7 @@ var Checkbox = ({
|
|
5017
5293
|
size === "default" ? "hawa-items-top" : "hawa-items-center"
|
5018
5294
|
)
|
5019
5295
|
},
|
5020
|
-
/* @__PURE__ */
|
5296
|
+
/* @__PURE__ */ React45.createElement(
|
5021
5297
|
CheckboxElement,
|
5022
5298
|
{
|
5023
5299
|
...props,
|
@@ -5027,7 +5303,7 @@ var Checkbox = ({
|
|
5027
5303
|
id
|
5028
5304
|
}
|
5029
5305
|
),
|
5030
|
-
(label || helperText) && /* @__PURE__ */
|
5306
|
+
(label || helperText) && /* @__PURE__ */ React45.createElement("div", { className: "hawa-grid hawa-gap-1.5" }, label && /* @__PURE__ */ React45.createElement(
|
5031
5307
|
"label",
|
5032
5308
|
{
|
5033
5309
|
htmlFor: id,
|
@@ -5041,7 +5317,7 @@ var Checkbox = ({
|
|
5041
5317
|
}
|
5042
5318
|
},
|
5043
5319
|
label
|
5044
|
-
), sublabel && /* @__PURE__ */
|
5320
|
+
), sublabel && /* @__PURE__ */ React45.createElement(
|
5045
5321
|
"label",
|
5046
5322
|
{
|
5047
5323
|
htmlFor: id,
|
@@ -5051,7 +5327,7 @@ var Checkbox = ({
|
|
5051
5327
|
)
|
5052
5328
|
},
|
5053
5329
|
sublabel
|
5054
|
-
), helperText && !disabled && /* @__PURE__ */
|
5330
|
+
), helperText && !disabled && /* @__PURE__ */ React45.createElement(
|
5055
5331
|
"label",
|
5056
5332
|
{
|
5057
5333
|
htmlFor: id,
|
@@ -5064,7 +5340,7 @@ var Checkbox = ({
|
|
5064
5340
|
))
|
5065
5341
|
);
|
5066
5342
|
};
|
5067
|
-
var CheckboxElement =
|
5343
|
+
var CheckboxElement = React45.forwardRef(({ radius = "inherit", size = "default", className, ...props }, ref) => {
|
5068
5344
|
let checkboxRadius = {
|
5069
5345
|
none: "hawa-rounded-none",
|
5070
5346
|
inherit: "hawa-rounded-sm",
|
@@ -5086,7 +5362,7 @@ var CheckboxElement = React44.forwardRef(({ radius = "inherit", size = "default"
|
|
5086
5362
|
lg: "1em",
|
5087
5363
|
xl: "1.25em"
|
5088
5364
|
};
|
5089
|
-
return /* @__PURE__ */
|
5365
|
+
return /* @__PURE__ */ React45.createElement(
|
5090
5366
|
CheckboxPrimitive.Root,
|
5091
5367
|
{
|
5092
5368
|
ref,
|
@@ -5098,14 +5374,14 @@ var CheckboxElement = React44.forwardRef(({ radius = "inherit", size = "default"
|
|
5098
5374
|
),
|
5099
5375
|
...props
|
5100
5376
|
},
|
5101
|
-
/* @__PURE__ */
|
5377
|
+
/* @__PURE__ */ React45.createElement(
|
5102
5378
|
CheckboxPrimitive.Indicator,
|
5103
5379
|
{
|
5104
5380
|
className: cn(
|
5105
5381
|
"hawa-flex hawa-items-center hawa-justify-center hawa-text-current"
|
5106
5382
|
)
|
5107
5383
|
},
|
5108
|
-
/* @__PURE__ */
|
5384
|
+
/* @__PURE__ */ React45.createElement(
|
5109
5385
|
"svg",
|
5110
5386
|
{
|
5111
5387
|
"aria-label": "Check Mark",
|
@@ -5116,7 +5392,7 @@ var CheckboxElement = React44.forwardRef(({ radius = "inherit", size = "default"
|
|
5116
5392
|
height: checkboxIndicatorSizes[size],
|
5117
5393
|
width: checkboxIndicatorSizes[size]
|
5118
5394
|
},
|
5119
|
-
/* @__PURE__ */
|
5395
|
+
/* @__PURE__ */ React45.createElement("path", { d: "M173.898 439.404l-166.4-166.4c-9.997-9.997-9.997-26.206 0-36.204l36.203-36.204c9.997-9.998 26.207-9.998 36.204 0L192 312.69 432.095 72.596c9.997-9.997 26.207-9.997 36.204 0l36.203 36.204c9.997 9.997 9.997 26.206 0 36.204l-294.4 294.401c-9.998 9.997-26.207 9.997-36.204-.001z" })
|
5120
5396
|
),
|
5121
5397
|
" "
|
5122
5398
|
)
|
@@ -5125,9 +5401,9 @@ var CheckboxElement = React44.forwardRef(({ radius = "inherit", size = "default"
|
|
5125
5401
|
CheckboxElement.displayName = CheckboxPrimitive.Root.displayName;
|
5126
5402
|
|
5127
5403
|
// elements/progress/Progress.tsx
|
5128
|
-
import * as
|
5404
|
+
import * as React46 from "react";
|
5129
5405
|
import * as ProgressPrimitive from "@radix-ui/react-progress";
|
5130
|
-
var Progress =
|
5406
|
+
var Progress = React46.forwardRef(({ className, value, ...props }, ref) => /* @__PURE__ */ React46.createElement("div", { className: "hawa-flex hawa-flex-col hawa-gap-2" }, props.label && /* @__PURE__ */ React46.createElement(Label2, { ...props.labelProps }, props.label), /* @__PURE__ */ React46.createElement(
|
5131
5407
|
ProgressPrimitive.Root,
|
5132
5408
|
{
|
5133
5409
|
ref,
|
@@ -5137,7 +5413,7 @@ var Progress = React45.forwardRef(({ className, value, ...props }, ref) => /* @_
|
|
5137
5413
|
),
|
5138
5414
|
...props
|
5139
5415
|
},
|
5140
|
-
/* @__PURE__ */
|
5416
|
+
/* @__PURE__ */ React46.createElement(
|
5141
5417
|
ProgressPrimitive.Indicator,
|
5142
5418
|
{
|
5143
5419
|
className: "hawa-h-full hawa-w-full hawa-flex-1 hawa-bg-primary hawa-transition-all",
|
@@ -5148,7 +5424,7 @@ var Progress = React45.forwardRef(({ className, value, ...props }, ref) => /* @_
|
|
5148
5424
|
Progress.displayName = ProgressPrimitive.Root.displayName;
|
5149
5425
|
|
5150
5426
|
// elements/breadcrumb/Breadcrumb.tsx
|
5151
|
-
import
|
5427
|
+
import React47 from "react";
|
5152
5428
|
var Breadcrumb = ({
|
5153
5429
|
breadcrumbLinks,
|
5154
5430
|
separator = ">",
|
@@ -5159,7 +5435,7 @@ var Breadcrumb = ({
|
|
5159
5435
|
small: "hawa-text-sm",
|
5160
5436
|
xs: "hawa-text-xs"
|
5161
5437
|
};
|
5162
|
-
return /* @__PURE__ */
|
5438
|
+
return /* @__PURE__ */ React47.createElement(
|
5163
5439
|
"div",
|
5164
5440
|
{
|
5165
5441
|
className: cn(
|
@@ -5167,13 +5443,13 @@ var Breadcrumb = ({
|
|
5167
5443
|
textStyles[size]
|
5168
5444
|
)
|
5169
5445
|
},
|
5170
|
-
breadcrumbLinks.map((singleBreadcrumbLink, index) => /* @__PURE__ */
|
5446
|
+
breadcrumbLinks.map((singleBreadcrumbLink, index) => /* @__PURE__ */ React47.createElement(
|
5171
5447
|
"div",
|
5172
5448
|
{
|
5173
5449
|
key: index,
|
5174
5450
|
className: "hawa-flex hawa-flex-row hawa-items-center hawa-justify-center hawa-gap-2"
|
5175
5451
|
},
|
5176
|
-
/* @__PURE__ */
|
5452
|
+
/* @__PURE__ */ React47.createElement(
|
5177
5453
|
"a",
|
5178
5454
|
{
|
5179
5455
|
href: singleBreadcrumbLink.href,
|
@@ -5181,49 +5457,49 @@ var Breadcrumb = ({
|
|
5181
5457
|
},
|
5182
5458
|
singleBreadcrumbLink.label
|
5183
5459
|
),
|
5184
|
-
index != breadcrumbLinks.length - 1 ? typeof separator == "string" ? /* @__PURE__ */
|
5460
|
+
index != breadcrumbLinks.length - 1 ? typeof separator == "string" ? /* @__PURE__ */ React47.createElement("div", null, separator) : /* @__PURE__ */ React47.createElement("div", null, separator) : null
|
5185
5461
|
))
|
5186
5462
|
);
|
5187
5463
|
};
|
5188
5464
|
|
5189
5465
|
// elements/appStores/AppStores.tsx
|
5190
|
-
import
|
5466
|
+
import React48 from "react";
|
5191
5467
|
var AppStores = (props) => {
|
5192
|
-
return /* @__PURE__ */
|
5468
|
+
return /* @__PURE__ */ React48.createElement("div", { className: "hawa-flex hawa-justify-center" }, /* @__PURE__ */ React48.createElement("div", null, props.store === "apple" ? /* @__PURE__ */ React48.createElement("div", { className: "hawa-mt-3 hawa-flex hawa-h-14 hawa-w-48 hawa-items-center hawa-justify-center hawa-rounded-lg hawa-bg-black hawa-text-white dark:hawa-bg-white dark:hawa-text-black" }, /* @__PURE__ */ React48.createElement("div", { className: "hawa-mr-3" }, /* @__PURE__ */ React48.createElement("svg", { viewBox: "0 0 384 512", width: "30" }, /* @__PURE__ */ React48.createElement(
|
5193
5469
|
"path",
|
5194
5470
|
{
|
5195
5471
|
fill: "currentColor",
|
5196
5472
|
d: "M318.7 268.7c-.2-36.7 16.4-64.4 50-84.8-18.8-26.9-47.2-41.7-84.7-44.6-35.5-2.8-74.3 20.7-88.5 20.7-15 0-49.4-19.7-76.4-19.7C63.3 141.2 4 184.8 4 273.5q0 39.3 14.4 81.2c12.8 36.7 59 126.7 107.2 125.2 25.2-.6 43-17.9 75.8-17.9 31.8 0 48.3 17.9 76.4 17.9 48.6-.7 90.4-82.5 102.6-119.3-65.2-30.7-61.7-90-61.7-91.9zm-56.6-164.2c27.3-32.4 24.8-61.9 24-72.5-24.1 1.4-52 16.4-67.9 34.9-17.5 19.8-27.8 44.3-25.6 71.9 26.1 2 49.9-11.4 69.5-34.3z"
|
5197
5473
|
}
|
5198
|
-
))), /* @__PURE__ */
|
5474
|
+
))), /* @__PURE__ */ React48.createElement("div", null, /* @__PURE__ */ React48.createElement("div", { className: "hawa-text-xs" }, "Download on the"), /* @__PURE__ */ React48.createElement("div", { className: "hawa--mt-1 hawa-font-sans hawa-text-2xl hawa-font-semibold" }, "App Store"))) : /* @__PURE__ */ React48.createElement("div", { className: "hawa-mt-3 hawa-flex hawa-h-14 hawa-w-48 hawa-items-center hawa-justify-center hawa-rounded-lg hawa-border hawa-border-black hawa-bg-black hawa-text-white dark:hawa-bg-white dark:hawa-text-black" }, /* @__PURE__ */ React48.createElement("div", { className: "hawa-mr-3" }, /* @__PURE__ */ React48.createElement("svg", { viewBox: "30 336.7 120.9 129.2", width: "30" }, /* @__PURE__ */ React48.createElement(
|
5199
5475
|
"path",
|
5200
5476
|
{
|
5201
5477
|
fill: "#FFD400",
|
5202
5478
|
d: "M119.2,421.2c15.3-8.4,27-14.8,28-15.3c3.2-1.7,6.5-6.2,0-9.7 c-2.1-1.1-13.4-7.3-28-15.3l-20.1,20.2L119.2,421.2z"
|
5203
5479
|
}
|
5204
|
-
), /* @__PURE__ */
|
5480
|
+
), /* @__PURE__ */ React48.createElement(
|
5205
5481
|
"path",
|
5206
5482
|
{
|
5207
5483
|
fill: "#FF3333",
|
5208
5484
|
d: "M99.1,401.1l-64.2,64.7c1.5,0.2,3.2-0.2,5.2-1.3 c4.2-2.3,48.8-26.7,79.1-43.3L99.1,401.1L99.1,401.1z"
|
5209
5485
|
}
|
5210
|
-
), /* @__PURE__ */
|
5486
|
+
), /* @__PURE__ */ React48.createElement(
|
5211
5487
|
"path",
|
5212
5488
|
{
|
5213
5489
|
fill: "#48FF48",
|
5214
5490
|
d: "M99.1,401.1l20.1-20.2c0,0-74.6-40.7-79.1-43.1 c-1.7-1-3.6-1.3-5.3-1L99.1,401.1z"
|
5215
5491
|
}
|
5216
|
-
), /* @__PURE__ */
|
5492
|
+
), /* @__PURE__ */ React48.createElement(
|
5217
5493
|
"path",
|
5218
5494
|
{
|
5219
5495
|
fill: "#3BCCFF",
|
5220
5496
|
d: "M99.1,401.1l-64.3-64.3c-2.6,0.6-4.8,2.9-4.8,7.6 c0,7.5,0,107.5,0,113.8c0,4.3,1.7,7.4,4.9,7.7L99.1,401.1z"
|
5221
5497
|
}
|
5222
|
-
))), /* @__PURE__ */
|
5498
|
+
))), /* @__PURE__ */ React48.createElement("div", null, /* @__PURE__ */ React48.createElement("div", { className: "hawa-text-xs" }, "GET IT ON"), /* @__PURE__ */ React48.createElement("div", { className: "hawa--mt-1 hawa-font-sans hawa-text-xl hawa-font-semibold" }, "Google Play")))));
|
5223
5499
|
};
|
5224
5500
|
|
5225
5501
|
// elements/badge/Badge.tsx
|
5226
|
-
import
|
5502
|
+
import React49, { useEffect as useEffect25, useState as useState27, useRef as useRef17 } from "react";
|
5227
5503
|
var Badge = ({
|
5228
5504
|
anchor,
|
5229
5505
|
position = "right",
|
@@ -5231,14 +5507,14 @@ var Badge = ({
|
|
5231
5507
|
text,
|
5232
5508
|
className
|
5233
5509
|
}) => {
|
5234
|
-
const [badgePosition, setBadgePosition] =
|
5235
|
-
const indicatorRef =
|
5510
|
+
const [badgePosition, setBadgePosition] = useState27(null);
|
5511
|
+
const indicatorRef = useRef17(null);
|
5236
5512
|
const sizeStyles2 = {
|
5237
5513
|
small: { top: 4, left: 6, right: 7, classes: "hawa-w-3 hawa-h-3" },
|
5238
5514
|
default: { top: 4, left: 7, right: 5, classes: "hawa-w-3 hawa-h-3" },
|
5239
5515
|
large: { top: 6, left: 12, right: 7, classes: "hawa-w-6 hawa-h-6" }
|
5240
5516
|
};
|
5241
|
-
|
5517
|
+
useEffect25(() => {
|
5242
5518
|
const handlePositioning = () => {
|
5243
5519
|
var _a;
|
5244
5520
|
if (anchor.current && indicatorRef.current) {
|
@@ -5261,7 +5537,7 @@ var Badge = ({
|
|
5261
5537
|
window.removeEventListener("resize", handlePositioning);
|
5262
5538
|
};
|
5263
5539
|
}, [anchor]);
|
5264
|
-
return /* @__PURE__ */
|
5540
|
+
return /* @__PURE__ */ React49.createElement("div", { ref: indicatorRef, className: cn("hawa-relative", className) }, badgePosition && /* @__PURE__ */ React49.createElement(
|
5265
5541
|
"div",
|
5266
5542
|
{
|
5267
5543
|
style: {
|
@@ -5286,8 +5562,8 @@ var BadgedComponent = ({
|
|
5286
5562
|
size,
|
5287
5563
|
text
|
5288
5564
|
}) => {
|
5289
|
-
const ref =
|
5290
|
-
return /* @__PURE__ */
|
5565
|
+
const ref = useRef17(null);
|
5566
|
+
return /* @__PURE__ */ React49.createElement("div", { className: cn("hawa-relative hawa-w-fit", className), ref }, !hideBadge && /* @__PURE__ */ React49.createElement(
|
5291
5567
|
Badge,
|
5292
5568
|
{
|
5293
5569
|
size,
|
@@ -5300,7 +5576,7 @@ var BadgedComponent = ({
|
|
5300
5576
|
};
|
5301
5577
|
|
5302
5578
|
// elements/phoneInput/PhoneInput.tsx
|
5303
|
-
import
|
5579
|
+
import React50, { useState as useState28, useRef as useRef18 } from "react";
|
5304
5580
|
|
5305
5581
|
// countries.ts
|
5306
5582
|
var countries = [
|
@@ -7002,9 +7278,9 @@ var PhoneInput = ({
|
|
7002
7278
|
countryCodes,
|
7003
7279
|
...props
|
7004
7280
|
}) => {
|
7005
|
-
const [phoneNumber, setPhoneNumber] =
|
7006
|
-
const [countryCode, setCountryCode] =
|
7007
|
-
const inputRef =
|
7281
|
+
const [phoneNumber, setPhoneNumber] = useState28("");
|
7282
|
+
const [countryCode, setCountryCode] = useState28(props.preferredCountry);
|
7283
|
+
const inputRef = useRef18(null);
|
7008
7284
|
const handleInputChange = (e) => {
|
7009
7285
|
console.log("test e ", e.target.value);
|
7010
7286
|
const validChars = /^[0-9-()]+$/;
|
@@ -7018,7 +7294,7 @@ var PhoneInput = ({
|
|
7018
7294
|
console.log("handleChange prop was not provided in <PhoneInput/>");
|
7019
7295
|
}
|
7020
7296
|
};
|
7021
|
-
return /* @__PURE__ */
|
7297
|
+
return /* @__PURE__ */ React50.createElement("div", { className: "hawa-flex hawa-h-fit hawa-w-full hawa-flex-col hawa-gap-2" }, props.label && /* @__PURE__ */ React50.createElement(Label2, { ...labelProps }, props.label), /* @__PURE__ */ React50.createElement("div", { dir: "ltr", className: "hawa-flex hawa-w-full hawa-flex-row" }, /* @__PURE__ */ React50.createElement(
|
7022
7298
|
Select,
|
7023
7299
|
{
|
7024
7300
|
phoneCode: true,
|
@@ -7034,7 +7310,7 @@ var PhoneInput = ({
|
|
7034
7310
|
value: countryCode == null ? void 0 : countryCode.label,
|
7035
7311
|
defaultValue: props.preferredCountry
|
7036
7312
|
}
|
7037
|
-
), /* @__PURE__ */
|
7313
|
+
), /* @__PURE__ */ React50.createElement("div", { className: "hawa-relative hawa-flex hawa-h-fit hawa-w-full hawa-flex-col hawa-justify-center hawa-gap-0" }, /* @__PURE__ */ React50.createElement(
|
7038
7314
|
"input",
|
7039
7315
|
{
|
7040
7316
|
type: "tel",
|
@@ -7048,7 +7324,7 @@ var PhoneInput = ({
|
|
7048
7324
|
),
|
7049
7325
|
...inputProps
|
7050
7326
|
}
|
7051
|
-
))), /* @__PURE__ */
|
7327
|
+
))), /* @__PURE__ */ React50.createElement(
|
7052
7328
|
"p",
|
7053
7329
|
{
|
7054
7330
|
className: cn(
|
@@ -7061,7 +7337,7 @@ var PhoneInput = ({
|
|
7061
7337
|
};
|
7062
7338
|
|
7063
7339
|
// elements/pinInput/PinInput.tsx
|
7064
|
-
import
|
7340
|
+
import React51, { useEffect as useEffect27, useState as useState29 } from "react";
|
7065
7341
|
var PinInput = ({
|
7066
7342
|
label,
|
7067
7343
|
icon,
|
@@ -7071,7 +7347,7 @@ var PinInput = ({
|
|
7071
7347
|
inputProps,
|
7072
7348
|
...props
|
7073
7349
|
}) => {
|
7074
|
-
const [pin, setPin] =
|
7350
|
+
const [pin, setPin] = useState29(Array.from(Array(digits)));
|
7075
7351
|
const handleKeyDown = (e, index) => {
|
7076
7352
|
let backTo = 0;
|
7077
7353
|
if (e.key === "Backspace") {
|
@@ -7080,7 +7356,7 @@ var PinInput = ({
|
|
7080
7356
|
previousInput == null ? void 0 : previousInput.focus();
|
7081
7357
|
}
|
7082
7358
|
};
|
7083
|
-
|
7359
|
+
useEffect27(() => {
|
7084
7360
|
let unfilled = pin.includes(void 0);
|
7085
7361
|
if (!unfilled && getPins) {
|
7086
7362
|
getPins(pin);
|
@@ -7105,13 +7381,13 @@ var PinInput = ({
|
|
7105
7381
|
}
|
7106
7382
|
}
|
7107
7383
|
};
|
7108
|
-
return /* @__PURE__ */
|
7384
|
+
return /* @__PURE__ */ React51.createElement("div", { className: "hawa-flex hawa-flex-col hawa-gap-2" }, /* @__PURE__ */ React51.createElement(
|
7109
7385
|
"div",
|
7110
7386
|
{
|
7111
7387
|
className: "hawa-flex hawa-w-full hawa-flex-row hawa-justify-center hawa-gap-2",
|
7112
7388
|
dir: "ltr"
|
7113
7389
|
},
|
7114
|
-
pin.map((value, index) => /* @__PURE__ */
|
7390
|
+
pin.map((value, index) => /* @__PURE__ */ React51.createElement(
|
7115
7391
|
"input",
|
7116
7392
|
{
|
7117
7393
|
key: index,
|
@@ -7131,7 +7407,7 @@ var PinInput = ({
|
|
7131
7407
|
...inputProps
|
7132
7408
|
}
|
7133
7409
|
))
|
7134
|
-
), /* @__PURE__ */
|
7410
|
+
), /* @__PURE__ */ React51.createElement(
|
7135
7411
|
"p",
|
7136
7412
|
{
|
7137
7413
|
className: cn(
|
@@ -7144,58 +7420,18 @@ var PinInput = ({
|
|
7144
7420
|
};
|
7145
7421
|
|
7146
7422
|
// elements/stopPropagationWrapper/StopPropagationWrapper.tsx
|
7147
|
-
import
|
7423
|
+
import React52 from "react";
|
7148
7424
|
var StopPropagationWrapper = (props) => {
|
7149
7425
|
const handleClick = (e) => {
|
7150
7426
|
e.stopPropagation();
|
7151
7427
|
};
|
7152
|
-
return /* @__PURE__ */
|
7428
|
+
return /* @__PURE__ */ React52.createElement("div", { onClick: handleClick }, props.children);
|
7153
7429
|
};
|
7154
7430
|
|
7155
|
-
// elements/scrollArea/ScrollArea.tsx
|
7156
|
-
import * as React52 from "react";
|
7157
|
-
import * as ScrollAreaPrimitive from "@radix-ui/react-scroll-area";
|
7158
|
-
var ScrollArea = React52.forwardRef(({ className, children, orientation = "vertical", ...props }, ref) => /* @__PURE__ */ React52.createElement(
|
7159
|
-
ScrollAreaPrimitive.Root,
|
7160
|
-
{
|
7161
|
-
ref,
|
7162
|
-
className: cn("hawa-relative hawa-overflow-hidden", className),
|
7163
|
-
...props
|
7164
|
-
},
|
7165
|
-
/* @__PURE__ */ React52.createElement(ScrollAreaPrimitive.Viewport, { className: "hawa-h-full hawa-w-full hawa-rounded-[inherit]" }, children),
|
7166
|
-
/* @__PURE__ */ React52.createElement(ScrollBar, { orientation }),
|
7167
|
-
/* @__PURE__ */ React52.createElement(ScrollAreaPrimitive.Corner, null)
|
7168
|
-
));
|
7169
|
-
ScrollArea.displayName = ScrollAreaPrimitive.Root.displayName;
|
7170
|
-
var ScrollBar = React52.forwardRef(({ className, orientation = "vertical", ...props }, ref) => /* @__PURE__ */ React52.createElement(
|
7171
|
-
ScrollAreaPrimitive.ScrollAreaScrollbar,
|
7172
|
-
{
|
7173
|
-
ref,
|
7174
|
-
orientation,
|
7175
|
-
className: cn(
|
7176
|
-
"hawa-flex hawa-touch-none hawa-select-none hawa-transition-colors",
|
7177
|
-
orientation === "vertical" && "hawa-h-full hawa-w-2.5 hawa-border-l hawa-border-l-transparent hawa-p-[1px]",
|
7178
|
-
orientation === "horizontal" && "hawa-h-2.5 hawa-border-t hawa-border-t-transparent hawa-p-[1px]",
|
7179
|
-
className
|
7180
|
-
),
|
7181
|
-
...props
|
7182
|
-
},
|
7183
|
-
/* @__PURE__ */ React52.createElement(
|
7184
|
-
ScrollAreaPrimitive.ScrollAreaThumb,
|
7185
|
-
{
|
7186
|
-
className: cn(
|
7187
|
-
"hawa-relative hawa-rounded-full hawa-bg-border",
|
7188
|
-
orientation === "vertical" && "hawa-flex-1"
|
7189
|
-
)
|
7190
|
-
}
|
7191
|
-
)
|
7192
|
-
));
|
7193
|
-
ScrollBar.displayName = ScrollAreaPrimitive.ScrollAreaScrollbar.displayName;
|
7194
|
-
|
7195
7431
|
// elements/colorPicker/ColorPicker.tsx
|
7196
7432
|
import React53, {
|
7197
|
-
useState as
|
7198
|
-
useEffect as
|
7433
|
+
useState as useState30,
|
7434
|
+
useEffect as useEffect28
|
7199
7435
|
} from "react";
|
7200
7436
|
var ColorPicker = ({
|
7201
7437
|
containerProps,
|
@@ -7207,8 +7443,8 @@ var ColorPicker = ({
|
|
7207
7443
|
preview = false,
|
7208
7444
|
...props
|
7209
7445
|
}) => {
|
7210
|
-
const [selectedColor, setSelectedColor] =
|
7211
|
-
|
7446
|
+
const [selectedColor, setSelectedColor] = useState30(props.color);
|
7447
|
+
useEffect28(() => {
|
7212
7448
|
if (selectedColor && selectedColor[0] !== "#") {
|
7213
7449
|
setSelectedColor(`#${selectedColor}`);
|
7214
7450
|
}
|
@@ -7490,7 +7726,7 @@ var Pagination = ({
|
|
7490
7726
|
};
|
7491
7727
|
|
7492
7728
|
// elements/passwordInput/PasswordInput.tsx
|
7493
|
-
import React59, { useEffect as
|
7729
|
+
import React59, { useEffect as useEffect29, useState as useState31 } from "react";
|
7494
7730
|
|
7495
7731
|
// icons/Emojis.tsx
|
7496
7732
|
import React56 from "react";
|
@@ -7727,16 +7963,16 @@ var PasswordInput = ({
|
|
7727
7963
|
hidePopover,
|
7728
7964
|
...props
|
7729
7965
|
}) => {
|
7730
|
-
const [inputValue, setInputValue] =
|
7731
|
-
const [isInputFocused, setIsInputFocused] =
|
7732
|
-
const [currentStr, setCurrentStr] =
|
7733
|
-
const [passwordVisible, setPasswordVisible] =
|
7734
|
-
const [lengthCriteriaMet, setLengthCriteriaMet] =
|
7735
|
-
const [numberCriteriaMet, setNumberCriteriaMet] =
|
7736
|
-
const [specialCharCriteriaMet, setSpecialCharCriteriaMet] =
|
7737
|
-
const [lowercaseCriteriaMet, setLowercaseCriteriaMet] =
|
7738
|
-
const [uppercaseCriteriaMet, setUppercaseCriteriaMet] =
|
7739
|
-
|
7966
|
+
const [inputValue, setInputValue] = useState31("");
|
7967
|
+
const [isInputFocused, setIsInputFocused] = useState31(false);
|
7968
|
+
const [currentStr, setCurrentStr] = useState31(0);
|
7969
|
+
const [passwordVisible, setPasswordVisible] = useState31(false);
|
7970
|
+
const [lengthCriteriaMet, setLengthCriteriaMet] = useState31(false);
|
7971
|
+
const [numberCriteriaMet, setNumberCriteriaMet] = useState31(false);
|
7972
|
+
const [specialCharCriteriaMet, setSpecialCharCriteriaMet] = useState31(false);
|
7973
|
+
const [lowercaseCriteriaMet, setLowercaseCriteriaMet] = useState31(false);
|
7974
|
+
const [uppercaseCriteriaMet, setUppercaseCriteriaMet] = useState31(false);
|
7975
|
+
useEffect29(() => {
|
7740
7976
|
const calculateStrength = () => {
|
7741
7977
|
let strengthScore = 0;
|
7742
7978
|
if (lengthCriteriaMet)
|
@@ -7937,12 +8173,12 @@ var Separator2 = ({
|
|
7937
8173
|
);
|
7938
8174
|
|
7939
8175
|
// elements/scrollIndicator/ScrollIndicator.tsx
|
7940
|
-
import React63, { useState as
|
8176
|
+
import React63, { useState as useState32, useEffect as useEffect30 } from "react";
|
7941
8177
|
var ScrollIndicator = ({
|
7942
8178
|
anchor,
|
7943
8179
|
inContainer = false
|
7944
8180
|
}) => {
|
7945
|
-
const [scrollPercentage, setScrollPercentage] =
|
8181
|
+
const [scrollPercentage, setScrollPercentage] = useState32(0);
|
7946
8182
|
const onScroll = () => {
|
7947
8183
|
const scrollElement = anchor.current;
|
7948
8184
|
if (scrollElement) {
|
@@ -7953,7 +8189,7 @@ var ScrollIndicator = ({
|
|
7953
8189
|
setScrollPercentage(percentageScrolled);
|
7954
8190
|
}
|
7955
8191
|
};
|
7956
|
-
|
8192
|
+
useEffect30(() => {
|
7957
8193
|
if (!anchor.current)
|
7958
8194
|
return;
|
7959
8195
|
anchor.current.addEventListener("scroll", onScroll);
|
@@ -7978,7 +8214,7 @@ var ScrollIndicator = ({
|
|
7978
8214
|
};
|
7979
8215
|
|
7980
8216
|
// elements/codeBlock/CodeBlock.tsx
|
7981
|
-
import React64, { useState as
|
8217
|
+
import React64, { useState as useState33 } from "react";
|
7982
8218
|
import { Highlight, themes, Prism } from "prism-react-renderer";
|
7983
8219
|
(typeof global !== "undefined" ? global : window).Prism = Prism;
|
7984
8220
|
__require("prismjs/components/prism-bash");
|
@@ -8010,7 +8246,7 @@ var CodeBlock = ({
|
|
8010
8246
|
...props
|
8011
8247
|
}) => {
|
8012
8248
|
const clipboard = useClipboard();
|
8013
|
-
const [selectedTab, setSelectedTab] =
|
8249
|
+
const [selectedTab, setSelectedTab] = useState33(0);
|
8014
8250
|
const theme = themes.oceanicNext;
|
8015
8251
|
let widthStyles = {
|
8016
8252
|
full: "hawa-w-full",
|
@@ -8138,7 +8374,7 @@ var CodeBlock = ({
|
|
8138
8374
|
};
|
8139
8375
|
|
8140
8376
|
// elements/carousel/Carousel.tsx
|
8141
|
-
import React65, { useEffect as
|
8377
|
+
import React65, { useEffect as useEffect31, useState as useState34 } from "react";
|
8142
8378
|
import useEmblaCarousel2 from "embla-carousel-react";
|
8143
8379
|
var Carousel = ({
|
8144
8380
|
items,
|
@@ -8154,8 +8390,8 @@ var Carousel = ({
|
|
8154
8390
|
direction,
|
8155
8391
|
loop: autoplay ? true : (options == null ? void 0 : options.loop) || false
|
8156
8392
|
});
|
8157
|
-
const [selectedIndex, setSelectedIndex] =
|
8158
|
-
|
8393
|
+
const [selectedIndex, setSelectedIndex] = useState34(0);
|
8394
|
+
useEffect31(() => {
|
8159
8395
|
function selectHandler() {
|
8160
8396
|
const index = emblaApi == null ? void 0 : emblaApi.selectedScrollSnap();
|
8161
8397
|
setSelectedIndex(index || 0);
|
@@ -8165,7 +8401,7 @@ var Carousel = ({
|
|
8165
8401
|
emblaApi == null ? void 0 : emblaApi.off("select", selectHandler);
|
8166
8402
|
};
|
8167
8403
|
}, [emblaApi]);
|
8168
|
-
|
8404
|
+
useEffect31(() => {
|
8169
8405
|
let autoplayTimer;
|
8170
8406
|
if (autoplay && emblaApi) {
|
8171
8407
|
autoplayTimer = setInterval(() => {
|
@@ -8469,15 +8705,15 @@ function Toaster(props) {
|
|
8469
8705
|
}
|
8470
8706
|
|
8471
8707
|
// elements/destroyableCard/DestroyableCard.tsx
|
8472
|
-
import React69, { useRef as
|
8708
|
+
import React69, { useRef as useRef19, useState as useState35 } from "react";
|
8473
8709
|
var DestroyableCard = ({
|
8474
8710
|
position = "bottom-right",
|
8475
8711
|
fixed,
|
8476
8712
|
direction,
|
8477
8713
|
...props
|
8478
8714
|
}) => {
|
8479
|
-
const [closed, setClosed] =
|
8480
|
-
const popUpRef =
|
8715
|
+
const [closed, setClosed] = useState35(false);
|
8716
|
+
const popUpRef = useRef19(null);
|
8481
8717
|
const boxPosition = {
|
8482
8718
|
"bottom-right": "hawa-right-4 hawa-bottom-4",
|
8483
8719
|
"bottom-left": "hawa-left-4 hawa-bottom-4"
|
@@ -8543,7 +8779,7 @@ var DestroyableCard = ({
|
|
8543
8779
|
};
|
8544
8780
|
|
8545
8781
|
// elements/interfaceSettings/InterfaceSettings.tsx
|
8546
|
-
import React70, { useState as
|
8782
|
+
import React70, { useState as useState36 } from "react";
|
8547
8783
|
var InterfaceSettings = ({
|
8548
8784
|
orientation = "horizontal",
|
8549
8785
|
width = "default",
|
@@ -8551,8 +8787,8 @@ var InterfaceSettings = ({
|
|
8551
8787
|
handleLanguage,
|
8552
8788
|
...props
|
8553
8789
|
}) => {
|
8554
|
-
const [color, setColor] =
|
8555
|
-
const [language, setLanguage] =
|
8790
|
+
const [color, setColor] = useState36(props.currentColorMode);
|
8791
|
+
const [language, setLanguage] = useState36(props.currentLanguage);
|
8556
8792
|
let orientationStyle = {
|
8557
8793
|
horizontal: "hawa-flex hawa-flex-row hawa-justify-between",
|
8558
8794
|
vertical: "hawa-flex hawa-flex-col hawa-items-center hawa-gap-2"
|
@@ -8893,7 +9129,7 @@ var Copyrights = (props) => {
|
|
8893
9129
|
};
|
8894
9130
|
|
8895
9131
|
// layout/navbar/Navbar.tsx
|
8896
|
-
import React75, { useState as
|
9132
|
+
import React75, { useState as useState37 } from "react";
|
8897
9133
|
|
8898
9134
|
// elements/collapsible/Collapsible.tsx
|
8899
9135
|
import * as CollapsiblePrimitive from "@radix-ui/react-collapsible";
|
@@ -8909,7 +9145,7 @@ var Navbar = ({
|
|
8909
9145
|
...props
|
8910
9146
|
}) => {
|
8911
9147
|
var _a, _b;
|
8912
|
-
const [isOpen, setIsOpen] =
|
9148
|
+
const [isOpen, setIsOpen] = useState37(false);
|
8913
9149
|
return /* @__PURE__ */ React75.createElement("nav", { className: " hawa-sticky hawa-top-2 hawa-transition-all" }, /* @__PURE__ */ React75.createElement(
|
8914
9150
|
Collapsible,
|
8915
9151
|
{
|
@@ -9013,8 +9249,8 @@ var Navbar = ({
|
|
9013
9249
|
};
|
9014
9250
|
|
9015
9251
|
// layout/appLayout/AppLayout.tsx
|
9016
|
-
import React76, { useEffect as
|
9017
|
-
import * as
|
9252
|
+
import React76, { useEffect as useEffect32, useState as useState38 } from "react";
|
9253
|
+
import * as Dialog3 from "@radix-ui/react-dialog";
|
9018
9254
|
var LOCAL_STORAGE_KEY2 = "@sikka/hawa/keep-drawer-open";
|
9019
9255
|
var AppLayout = ({
|
9020
9256
|
profileMenuWidth = "default",
|
@@ -9032,7 +9268,7 @@ var AppLayout = ({
|
|
9032
9268
|
...props
|
9033
9269
|
}) => {
|
9034
9270
|
var _a, _b;
|
9035
|
-
|
9271
|
+
useEffect32(() => {
|
9036
9272
|
let isDrawerOpen = localStorage.getItem(LOCAL_STORAGE_KEY2);
|
9037
9273
|
if (isDrawerOpen === null) {
|
9038
9274
|
localStorage.setItem(LOCAL_STORAGE_KEY2, JSON.stringify(false));
|
@@ -9049,16 +9285,16 @@ var AppLayout = ({
|
|
9049
9285
|
}
|
9050
9286
|
};
|
9051
9287
|
const isRTL = direction === "rtl";
|
9052
|
-
const [openedSidebarItem, setOpenedSidebarItem] =
|
9053
|
-
const [size, setSize] =
|
9288
|
+
const [openedSidebarItem, setOpenedSidebarItem] = useState38("");
|
9289
|
+
const [size, setSize] = useState38(
|
9054
9290
|
typeof window !== "undefined" && window.innerWidth || 1200
|
9055
9291
|
);
|
9056
|
-
const [openSideMenu, setOpenSideMenu] =
|
9292
|
+
const [openSideMenu, setOpenSideMenu] = useState38(() => {
|
9057
9293
|
const savedState = localStorage.getItem(LOCAL_STORAGE_KEY2);
|
9058
9294
|
return savedState ? JSON.parse(savedState) : false;
|
9059
9295
|
});
|
9060
9296
|
const [container, setContainer] = React76.useState(null);
|
9061
|
-
const [keepDrawerOpen, setKeepDrawerOpen] =
|
9297
|
+
const [keepDrawerOpen, setKeepDrawerOpen] = useState38(() => {
|
9062
9298
|
const savedState = localStorage.getItem(LOCAL_STORAGE_KEY2);
|
9063
9299
|
return savedState ? JSON.parse(savedState) : false;
|
9064
9300
|
});
|
@@ -9071,7 +9307,7 @@ var AppLayout = ({
|
|
9071
9307
|
}
|
9072
9308
|
};
|
9073
9309
|
const ref = useClickOutside(handleClickOutside);
|
9074
|
-
|
9310
|
+
useEffect32(() => {
|
9075
9311
|
if (typeof window !== "undefined") {
|
9076
9312
|
const resize = () => {
|
9077
9313
|
setSize(window.innerWidth);
|
@@ -9088,13 +9324,13 @@ var AppLayout = ({
|
|
9088
9324
|
};
|
9089
9325
|
}
|
9090
9326
|
}, []);
|
9091
|
-
|
9327
|
+
useEffect32(() => {
|
9092
9328
|
setKeepDrawerOpen(() => {
|
9093
9329
|
const savedState = localStorage.getItem(LOCAL_STORAGE_KEY2);
|
9094
9330
|
return savedState ? JSON.parse(savedState) : true;
|
9095
9331
|
});
|
9096
9332
|
}, [setKeepDrawerOpen]);
|
9097
|
-
|
9333
|
+
useEffect32(() => {
|
9098
9334
|
if (size > 600) {
|
9099
9335
|
setOpenSideMenu(keepDrawerOpen);
|
9100
9336
|
} else {
|
@@ -9328,12 +9564,12 @@ var AppLayout = ({
|
|
9328
9564
|
) : null
|
9329
9565
|
)
|
9330
9566
|
)), /* @__PURE__ */ React76.createElement(
|
9331
|
-
|
9567
|
+
Dialog3.Root,
|
9332
9568
|
{
|
9333
9569
|
open: size < 600 && openSideMenu,
|
9334
9570
|
onOpenChange: setOpenSideMenu
|
9335
9571
|
},
|
9336
|
-
/* @__PURE__ */ React76.createElement(
|
9572
|
+
/* @__PURE__ */ React76.createElement(Dialog3.Portal, { container }, /* @__PURE__ */ React76.createElement(Dialog3.Overlay, { className: "hawa-fixed hawa-inset-0 hawa-bg-foreground/20 hawa-backdrop-blur-[2px] data-[state=open]:hawa-animate-in data-[state=closed]:hawa-animate-out hawa-z-10 data-[state=closed]:hawa-fade-out-0 data-[state=open]:hawa-fade-in-0" }))
|
9337
9573
|
), /* @__PURE__ */ React76.createElement(
|
9338
9574
|
"div",
|
9339
9575
|
{
|
@@ -9663,9 +9899,9 @@ var MenubarShortcut = ({
|
|
9663
9899
|
MenubarShortcut.displayname = "MenubarShortcut";
|
9664
9900
|
|
9665
9901
|
// layout/appTabs/AppTabs.tsx
|
9666
|
-
import React79, { useState as
|
9902
|
+
import React79, { useState as useState39 } from "react";
|
9667
9903
|
var AppTabs = ({ tabs, className }) => {
|
9668
|
-
const [selectedIndex, setSelectedIndex] =
|
9904
|
+
const [selectedIndex, setSelectedIndex] = useState39(0);
|
9669
9905
|
return /* @__PURE__ */ React79.createElement(
|
9670
9906
|
"div",
|
9671
9907
|
{
|
@@ -9707,7 +9943,7 @@ var AppTabs = ({ tabs, className }) => {
|
|
9707
9943
|
};
|
9708
9944
|
|
9709
9945
|
// layout/docsLayout/DocsLayout.tsx
|
9710
|
-
import React81, { useEffect as
|
9946
|
+
import React81, { useEffect as useEffect33, useRef as useRef21, useState as useState40 } from "react";
|
9711
9947
|
|
9712
9948
|
// layout/docsSidebar/DocsSidebar.tsx
|
9713
9949
|
import React80 from "react";
|
@@ -9797,15 +10033,15 @@ var DocsLayout = ({
|
|
9797
10033
|
lg: closeDrawerWidth
|
9798
10034
|
}
|
9799
10035
|
};
|
9800
|
-
const ref =
|
10036
|
+
const ref = useRef21(null);
|
9801
10037
|
const isRTL = direction === "rtl";
|
9802
10038
|
let size = useBreakpoint();
|
9803
10039
|
if (typeof window == "undefined") {
|
9804
10040
|
size = 1200;
|
9805
10041
|
}
|
9806
|
-
const [currentPage, setCurrentPage] =
|
9807
|
-
const [openSideMenu, setOpenSideMenu] =
|
9808
|
-
|
10042
|
+
const [currentPage, setCurrentPage] = useState40("Introduction");
|
10043
|
+
const [openSideMenu, setOpenSideMenu] = useState40(true);
|
10044
|
+
useEffect33(() => {
|
9809
10045
|
const handleClickOutside = (event) => {
|
9810
10046
|
if (ref.current && !ref.current.contains(event.target) && !openSideMenu) {
|
9811
10047
|
setOpenSideMenu(false);
|
@@ -9816,7 +10052,7 @@ var DocsLayout = ({
|
|
9816
10052
|
document.removeEventListener("click", handleClickOutside, true);
|
9817
10053
|
};
|
9818
10054
|
}, [openSideMenu]);
|
9819
|
-
|
10055
|
+
useEffect33(() => {
|
9820
10056
|
const handleResize = () => {
|
9821
10057
|
setOpenSideMenu(window.innerWidth > 600 ? true : false);
|
9822
10058
|
};
|
@@ -9833,7 +10069,7 @@ var DocsLayout = ({
|
|
9833
10069
|
setCurrentPage(entry.target.id);
|
9834
10070
|
}
|
9835
10071
|
};
|
9836
|
-
|
10072
|
+
useEffect33(() => {
|
9837
10073
|
observerRef.current = new IntersectionObserver(handleIntersection, {
|
9838
10074
|
threshold: 0.5
|
9839
10075
|
// Adjust threshold as needed to determine when a section is in view
|
@@ -10075,7 +10311,7 @@ var AuthButtons = (props) => {
|
|
10075
10311
|
|
10076
10312
|
// blocks/auth/LoginForm.tsx
|
10077
10313
|
import React83 from "react";
|
10078
|
-
import { useState as
|
10314
|
+
import { useState as useState41 } from "react";
|
10079
10315
|
import { Controller, useForm } from "react-hook-form";
|
10080
10316
|
import { zodResolver } from "@hookform/resolvers/zod";
|
10081
10317
|
import {
|
@@ -10092,7 +10328,7 @@ var LoginForm = ({
|
|
10092
10328
|
...props
|
10093
10329
|
}) => {
|
10094
10330
|
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q;
|
10095
|
-
const [passwordVisible, setPasswordVisible] =
|
10331
|
+
const [passwordVisible, setPasswordVisible] = useState41(false);
|
10096
10332
|
const thirdPartyAuthTexts = {
|
10097
10333
|
continueWithGoogle: texts == null ? void 0 : texts.continueWithGoogle,
|
10098
10334
|
continueWithTwitter: texts == null ? void 0 : texts.continueWithTwitter,
|
@@ -10411,7 +10647,7 @@ var LoginForm = ({
|
|
10411
10647
|
};
|
10412
10648
|
|
10413
10649
|
// blocks/auth/RegisterForm.tsx
|
10414
|
-
import React84, { useState as
|
10650
|
+
import React84, { useState as useState42 } from "react";
|
10415
10651
|
import { Controller as Controller2, FormProvider, useForm as useForm2 } from "react-hook-form";
|
10416
10652
|
import { zodResolver as zodResolver2 } from "@hookform/resolvers/zod";
|
10417
10653
|
import * as z2 from "zod";
|
@@ -10423,7 +10659,7 @@ var RegisterForm = ({
|
|
10423
10659
|
...props
|
10424
10660
|
}) => {
|
10425
10661
|
var _a, _b, _c, _d, _e, _f, _g, _h;
|
10426
|
-
const [passwordVisible, setPasswordVisible] =
|
10662
|
+
const [passwordVisible, setPasswordVisible] = useState42(false);
|
10427
10663
|
const thirdPartyAuthTexts = {
|
10428
10664
|
continueWithGoogle: texts == null ? void 0 : texts.continueWithGoogle,
|
10429
10665
|
continueWithTwitter: texts == null ? void 0 : texts.continueWithTwitter,
|
@@ -11044,7 +11280,7 @@ var ResetPasswordForm = ({
|
|
11044
11280
|
};
|
11045
11281
|
|
11046
11282
|
// blocks/auth/CodeConfirmation.tsx
|
11047
|
-
import React89, { useEffect as
|
11283
|
+
import React89, { useEffect as useEffect34, useState as useState43 } from "react";
|
11048
11284
|
import { Controller as Controller5, useForm as useForm5 } from "react-hook-form";
|
11049
11285
|
import { zodResolver as zodResolver5 } from "@hookform/resolvers/zod";
|
11050
11286
|
import * as z5 from "zod";
|
@@ -11056,9 +11292,9 @@ var CodeConfirmation = (props) => {
|
|
11056
11292
|
const { handleSubmit, control, formState, setValue } = useForm5({
|
11057
11293
|
resolver: zodResolver5(formSchema)
|
11058
11294
|
});
|
11059
|
-
const [resendTimer, setResendTimer] =
|
11060
|
-
const [remainingTime, setRemainingTime] =
|
11061
|
-
const [showResendTimer, setShowResendTimer] =
|
11295
|
+
const [resendTimer, setResendTimer] = useState43(null);
|
11296
|
+
const [remainingTime, setRemainingTime] = useState43(0);
|
11297
|
+
const [showResendTimer, setShowResendTimer] = useState43(false);
|
11062
11298
|
const startResendTimer = () => {
|
11063
11299
|
if (resendTimer !== null) {
|
11064
11300
|
clearInterval(resendTimer);
|
@@ -11080,7 +11316,7 @@ var CodeConfirmation = (props) => {
|
|
11080
11316
|
}, 1e3);
|
11081
11317
|
setResendTimer(newTimer);
|
11082
11318
|
};
|
11083
|
-
|
11319
|
+
useEffect34(() => {
|
11084
11320
|
return () => {
|
11085
11321
|
if (resendTimer !== null) {
|
11086
11322
|
clearInterval(resendTimer);
|
@@ -11143,7 +11379,7 @@ var CodeConfirmation = (props) => {
|
|
11143
11379
|
};
|
11144
11380
|
|
11145
11381
|
// blocks/feedback/UserReferralSource.tsx
|
11146
|
-
import React90, { useRef as
|
11382
|
+
import React90, { useRef as useRef22, useState as useState44 } from "react";
|
11147
11383
|
import { Controller as Controller6, useForm as useForm6 } from "react-hook-form";
|
11148
11384
|
import { zodResolver as zodResolver6 } from "@hookform/resolvers/zod";
|
11149
11385
|
import * as z6 from "zod";
|
@@ -11153,8 +11389,8 @@ var UserReferralSource = ({
|
|
11153
11389
|
...props
|
11154
11390
|
}) => {
|
11155
11391
|
var _a, _b;
|
11156
|
-
const [closed, setClosed] =
|
11157
|
-
const popUpRef =
|
11392
|
+
const [closed, setClosed] = useState44(false);
|
11393
|
+
const popUpRef = useRef22(null);
|
11158
11394
|
const formSchema = z6.object({
|
11159
11395
|
source: z6.string({ required_error: (_a = props.texts) == null ? void 0 : _a.pleaseSelectOption }),
|
11160
11396
|
feedback: z6.string().optional()
|
@@ -11301,21 +11537,21 @@ var UserReferralSource = ({
|
|
11301
11537
|
};
|
11302
11538
|
|
11303
11539
|
// blocks/feedback/FeedbackRating.tsx
|
11304
|
-
import React91, { useEffect as
|
11540
|
+
import React91, { useEffect as useEffect35, useRef as useRef23, useState as useState45 } from "react";
|
11305
11541
|
var FeedbackRating = ({
|
11306
11542
|
position = "bottom-right",
|
11307
11543
|
...props
|
11308
11544
|
}) => {
|
11309
|
-
const [closed, setClosed] =
|
11310
|
-
const [answered, setAnswered] =
|
11311
|
-
const [clickedOption, setClickedOption] =
|
11312
|
-
const [closingTimer, setClosingTimer] =
|
11313
|
-
const popUpRef =
|
11545
|
+
const [closed, setClosed] = useState45(false);
|
11546
|
+
const [answered, setAnswered] = useState45(false);
|
11547
|
+
const [clickedOption, setClickedOption] = useState45(null);
|
11548
|
+
const [closingTimer, setClosingTimer] = useState45(5);
|
11549
|
+
const popUpRef = useRef23(null);
|
11314
11550
|
const boxPosition = {
|
11315
11551
|
"bottom-right": "hawa-right-4",
|
11316
11552
|
"bottom-left": "hawa-left-4"
|
11317
11553
|
};
|
11318
|
-
|
11554
|
+
useEffect35(() => {
|
11319
11555
|
const timeoutHide = setTimeout(() => {
|
11320
11556
|
if (closingTimer >= 0) {
|
11321
11557
|
setClosingTimer(closingTimer - 1);
|
@@ -11415,12 +11651,12 @@ var FeedbackRating = ({
|
|
11415
11651
|
};
|
11416
11652
|
|
11417
11653
|
// blocks/feedback/FeedbackEmoji.tsx
|
11418
|
-
import React92, { useState as
|
11654
|
+
import React92, { useState as useState46 } from "react";
|
11419
11655
|
var FeedbackEmoji = (props) => {
|
11420
|
-
const [selectedEmoji, setSelectedEmoji] =
|
11421
|
-
const [loadingSubmit, setLoadingSubmit] =
|
11422
|
-
const [feedbackText, setFeedbackText] =
|
11423
|
-
const [helperText, setHelperText] =
|
11656
|
+
const [selectedEmoji, setSelectedEmoji] = useState46(null);
|
11657
|
+
const [loadingSubmit, setLoadingSubmit] = useState46(false);
|
11658
|
+
const [feedbackText, setFeedbackText] = useState46("");
|
11659
|
+
const [helperText, setHelperText] = useState46(false);
|
11424
11660
|
let emojis = [
|
11425
11661
|
{ icon: /* @__PURE__ */ React92.createElement(VeryGoodEmoji, null), value: "very-good" },
|
11426
11662
|
{ icon: /* @__PURE__ */ React92.createElement(GoodEmoji, null), value: "good" },
|
@@ -11984,9 +12220,9 @@ var ContactForm = ({
|
|
11984
12220
|
import React107 from "react";
|
11985
12221
|
|
11986
12222
|
// blocks/cards/ActionCard.tsx
|
11987
|
-
import React102, { useState as
|
12223
|
+
import React102, { useState as useState47 } from "react";
|
11988
12224
|
var ActionCard = (props) => {
|
11989
|
-
const [hovered, setHovered] =
|
12225
|
+
const [hovered, setHovered] = useState47(false);
|
11990
12226
|
return /* @__PURE__ */ React102.createElement("div", { className: "hawa-flex hawa-h-full hawa-w-full hawa-flex-col hawa-gap-1" }, /* @__PURE__ */ React102.createElement(
|
11991
12227
|
"div",
|
11992
12228
|
{
|
@@ -12023,15 +12259,15 @@ var ActionCard = (props) => {
|
|
12023
12259
|
};
|
12024
12260
|
|
12025
12261
|
// blocks/cards/AdCard.tsx
|
12026
|
-
import React103, { useState as
|
12262
|
+
import React103, { useState as useState48, useEffect as useEffect36, useRef as useRef24 } from "react";
|
12027
12263
|
var AdCard = ({
|
12028
12264
|
orientation = "vertical",
|
12029
12265
|
...props
|
12030
12266
|
}) => {
|
12031
|
-
const adRef =
|
12032
|
-
const [closed, setClosed] =
|
12267
|
+
const adRef = useRef24(null);
|
12268
|
+
const [closed, setClosed] = useState48(false);
|
12033
12269
|
let duration = 0;
|
12034
|
-
|
12270
|
+
useEffect36(() => {
|
12035
12271
|
if (duration) {
|
12036
12272
|
const timeoutHide = setTimeout(() => {
|
12037
12273
|
setClosed(true);
|
@@ -12219,7 +12455,7 @@ var PricingCard = ({
|
|
12219
12455
|
};
|
12220
12456
|
|
12221
12457
|
// blocks/cards/ItemCard.tsx
|
12222
|
-
import React105, { useEffect as
|
12458
|
+
import React105, { useEffect as useEffect37, useState as useState49 } from "react";
|
12223
12459
|
var ItemCard = ({
|
12224
12460
|
actions,
|
12225
12461
|
counts,
|
@@ -12248,12 +12484,12 @@ var ItemCard = ({
|
|
12248
12484
|
)
|
12249
12485
|
};
|
12250
12486
|
let headerActionsButtonStyle = "hawa-inline-block hawa-rounded hawa-p-1 hawa-text-sm hawa-text-gray-500 hover:hawa-bg-gray-100 focus:hawa-outline-none focus:hawa-ring-4 focus:hawa-ring-gray-200 dark:hawa-text-gray-400 dark:hover:hawa-bg-gray-700 dark:focus:hawa-ring-gray-700";
|
12251
|
-
const [openActionHeader, setOpenActionHeader] =
|
12487
|
+
const [openActionHeader, setOpenActionHeader] = useState49(false);
|
12252
12488
|
function handleOpenActionHeader(e) {
|
12253
12489
|
e.stopPropagation();
|
12254
12490
|
setOpenActionHeader(!openActionHeader);
|
12255
12491
|
}
|
12256
|
-
|
12492
|
+
useEffect37(() => {
|
12257
12493
|
window.onclick = () => {
|
12258
12494
|
if (openActionHeader) {
|
12259
12495
|
setOpenActionHeader(false);
|
@@ -12580,9 +12816,9 @@ var ComparingPlans = (props) => {
|
|
12580
12816
|
};
|
12581
12817
|
|
12582
12818
|
// blocks/pricing/HorizontalPricing.tsx
|
12583
|
-
import React109, { useState as
|
12819
|
+
import React109, { useState as useState50 } from "react";
|
12584
12820
|
var HorizontalPricing = (props) => {
|
12585
|
-
const [selectedCard, setSelectedCard] =
|
12821
|
+
const [selectedCard, setSelectedCard] = useState50("");
|
12586
12822
|
let data = [
|
12587
12823
|
{ title: "basic", price: "$49", cycle: "/mo" },
|
12588
12824
|
{ title: "business", price: "$99", cycle: "/mo" },
|
@@ -12704,6 +12940,7 @@ export {
|
|
12704
12940
|
AdCard,
|
12705
12941
|
Alert,
|
12706
12942
|
Announcement,
|
12943
|
+
AppCommand,
|
12707
12944
|
AppLanding,
|
12708
12945
|
AppLayout,
|
12709
12946
|
AppStores,
|
@@ -12783,6 +13020,7 @@ export {
|
|
12783
13020
|
FeedbackRating,
|
12784
13021
|
FileDropzone,
|
12785
13022
|
FileUploader,
|
13023
|
+
FullCommand,
|
12786
13024
|
HorizontalPricing,
|
12787
13025
|
Input,
|
12788
13026
|
InterfaceSettings,
|
@@ -12892,7 +13130,10 @@ export {
|
|
12892
13130
|
Usage,
|
12893
13131
|
UserReferralSource,
|
12894
13132
|
buttonVariants,
|
13133
|
+
getHotkeyHandler,
|
13134
|
+
getHotkeyMatcher,
|
12895
13135
|
navigationMenuTriggerStyle,
|
13136
|
+
parseHotkey,
|
12896
13137
|
reducer,
|
12897
13138
|
toast,
|
12898
13139
|
useBreakpoint,
|
@@ -12904,6 +13145,7 @@ export {
|
|
12904
13145
|
useMeasureDirty,
|
12905
13146
|
useMediaQuery,
|
12906
13147
|
useMultiStepDialog,
|
13148
|
+
useShortcuts,
|
12907
13149
|
useTabs,
|
12908
13150
|
useToast,
|
12909
13151
|
useWindowSize
|