@sikka/hawa 0.37.2-next → 0.38.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/{Radio-y9uhxitu.d.ts → Radio-lgoClQrv.d.ts} +2 -2
- package/dist/{Radio-BCD7k628.d.mts → Radio-uQ7DtzcI.d.mts} +2 -2
- package/dist/alert/index.js +43 -19
- package/dist/alert/index.js.map +1 -1
- package/dist/alert/index.mjs +43 -19
- package/dist/alert/index.mjs.map +1 -1
- package/dist/appLayout/index.js +43 -19
- package/dist/appLayout/index.js.map +1 -1
- package/dist/appLayout/index.mjs +43 -19
- package/dist/appLayout/index.mjs.map +1 -1
- package/dist/backToTop/index.js +43 -19
- package/dist/backToTop/index.js.map +1 -1
- package/dist/backToTop/index.mjs +43 -19
- package/dist/backToTop/index.mjs.map +1 -1
- package/dist/blocks/auth/index.d.mts +1 -0
- package/dist/blocks/auth/index.d.ts +1 -0
- package/dist/blocks/auth/index.js +251 -143
- package/dist/blocks/auth/index.mjs +205 -102
- package/dist/blocks/feedback/index.js +47 -59
- package/dist/blocks/feedback/index.mjs +5 -5
- package/dist/blocks/index.d.mts +2 -1
- package/dist/blocks/index.d.ts +2 -1
- package/dist/blocks/index.js +501 -420
- package/dist/blocks/index.mjs +11 -9
- package/dist/blocks/misc/index.js +48 -51
- package/dist/blocks/misc/index.mjs +5 -5
- package/dist/blocks/pricing/index.js +47 -41
- package/dist/blocks/pricing/index.mjs +4 -4
- package/dist/button/index.d.mts +4 -0
- package/dist/button/index.d.ts +4 -0
- package/dist/button/index.js +43 -19
- package/dist/button/index.js.map +1 -1
- package/dist/button/index.mjs +43 -19
- package/dist/button/index.mjs.map +1 -1
- package/dist/calendar/index.js +43 -19
- package/dist/calendar/index.js.map +1 -1
- package/dist/calendar/index.mjs +43 -19
- package/dist/calendar/index.mjs.map +1 -1
- package/dist/checkbox/index.d.mts +1 -1
- package/dist/checkbox/index.d.ts +1 -1
- package/dist/checkbox/index.js.map +1 -1
- package/dist/checkbox/index.mjs.map +1 -1
- package/dist/{chunk-ZTUWU652.mjs → chunk-EZBHA2IL.mjs} +3 -3
- package/dist/{chunk-ODOCZAWC.mjs → chunk-F23GAE2P.mjs} +1 -1
- package/dist/{chunk-DS3AACQJ.mjs → chunk-IC5WYNKN.mjs} +1 -1
- package/dist/{chunk-QXH7ZDMN.mjs → chunk-RTK6REIK.mjs} +3 -11
- package/dist/{chunk-QYWOI3DO.mjs → chunk-UDJFVH2I.mjs} +204 -144
- package/dist/{chunk-BPHQFAWM.mjs → chunk-UJ5SXC3M.mjs} +3 -11
- package/dist/{chunk-PXGL7ZXQ.mjs → chunk-UMOBOCED.mjs} +44 -19
- package/dist/{chunk-RNFJAEEU.mjs → chunk-V7O5MQZQ.mjs} +44 -19
- package/dist/{chunk-BTDR3VAG.mjs → chunk-WDCKXU54.mjs} +4 -21
- package/dist/{chunk-MDHDHEPZ.mjs → chunk-XFSBC5VI.mjs} +3 -11
- package/dist/codeBlock/index.js +43 -19
- package/dist/codeBlock/index.js.map +1 -1
- package/dist/codeBlock/index.mjs +43 -19
- package/dist/codeBlock/index.mjs.map +1 -1
- package/dist/colorPicker/index.d.mts +1 -1
- package/dist/colorPicker/index.d.ts +1 -1
- package/dist/colorPicker/index.js +35 -31
- package/dist/colorPicker/index.js.map +1 -1
- package/dist/colorPicker/index.mjs +33 -29
- package/dist/colorPicker/index.mjs.map +1 -1
- package/dist/combobox/index.d.mts +1 -1
- package/dist/combobox/index.d.ts +1 -1
- package/dist/combobox/index.js +52 -48
- package/dist/combobox/index.js.map +1 -1
- package/dist/combobox/index.mjs +52 -48
- package/dist/combobox/index.mjs.map +1 -1
- package/dist/dataTable/index.js +44 -29
- package/dist/dataTable/index.js.map +1 -1
- package/dist/dataTable/index.mjs +44 -29
- package/dist/dataTable/index.mjs.map +1 -1
- package/dist/datePicker/index.d.mts +4 -0
- package/dist/datePicker/index.d.ts +4 -0
- package/dist/datePicker/index.js +44 -19
- package/dist/datePicker/index.js.map +1 -1
- package/dist/datePicker/index.mjs +44 -19
- package/dist/datePicker/index.mjs.map +1 -1
- package/dist/docsLayout/index.js +43 -19
- package/dist/docsLayout/index.js.map +1 -1
- package/dist/docsLayout/index.mjs +43 -19
- package/dist/docsLayout/index.mjs.map +1 -1
- package/dist/elements/index.d.mts +46 -21
- package/dist/elements/index.d.ts +46 -21
- package/dist/elements/index.js +378 -309
- package/dist/elements/index.mjs +14 -23
- package/dist/fileDropzone/index.js +43 -19
- package/dist/fileDropzone/index.js.map +1 -1
- package/dist/fileDropzone/index.mjs +43 -19
- package/dist/fileDropzone/index.mjs.map +1 -1
- package/dist/index.css +29 -3
- package/dist/index.d.mts +48 -22
- package/dist/index.d.ts +48 -22
- package/dist/index.js +808 -737
- package/dist/index.mjs +331 -264
- package/dist/input/index.d.mts +1 -1
- package/dist/input/index.d.ts +1 -1
- package/dist/input/index.js +46 -42
- package/dist/input/index.js.map +1 -1
- package/dist/input/index.mjs +45 -41
- package/dist/input/index.mjs.map +1 -1
- package/dist/interfaceSettings/index.js +64 -69
- package/dist/interfaceSettings/index.js.map +1 -1
- package/dist/interfaceSettings/index.mjs +57 -62
- package/dist/interfaceSettings/index.mjs.map +1 -1
- package/dist/layout/index.d.mts +1 -1
- package/dist/layout/index.d.ts +1 -1
- package/dist/layout/index.js +43 -19
- package/dist/layout/index.mjs +2 -2
- package/dist/passwordInput/index.js +70 -66
- package/dist/passwordInput/index.js.map +1 -1
- package/dist/passwordInput/index.mjs +59 -55
- package/dist/passwordInput/index.mjs.map +1 -1
- package/dist/phoneInput/index.js +50 -55
- package/dist/phoneInput/index.js.map +1 -1
- package/dist/phoneInput/index.mjs +47 -52
- package/dist/phoneInput/index.mjs.map +1 -1
- package/dist/pinInput/index.d.mts +37 -16
- package/dist/pinInput/index.d.ts +37 -16
- package/dist/pinInput/index.js +208 -78
- package/dist/pinInput/index.js.map +1 -1
- package/dist/pinInput/index.mjs +203 -77
- package/dist/pinInput/index.mjs.map +1 -1
- package/dist/radio/index.d.mts +1 -1
- package/dist/radio/index.d.ts +1 -1
- package/dist/radio/index.js +55 -60
- package/dist/radio/index.js.map +1 -1
- package/dist/radio/index.mjs +50 -55
- package/dist/radio/index.mjs.map +1 -1
- package/dist/scrollArea/index.js +2 -2
- package/dist/scrollArea/index.js.map +1 -1
- package/dist/scrollArea/index.mjs +2 -2
- package/dist/scrollArea/index.mjs.map +1 -1
- package/dist/select/index.d.mts +1 -1
- package/dist/select/index.d.ts +1 -1
- package/dist/select/index.js +43 -39
- package/dist/select/index.js.map +1 -1
- package/dist/select/index.mjs +43 -39
- package/dist/select/index.mjs.map +1 -1
- package/dist/signature/index.d.mts +1 -1
- package/dist/signature/index.d.ts +1 -1
- package/dist/signature/index.js.map +1 -1
- package/dist/signature/index.mjs.map +1 -1
- package/dist/sortButton/index.js +43 -19
- package/dist/sortButton/index.js.map +1 -1
- package/dist/sortButton/index.mjs +43 -19
- package/dist/sortButton/index.mjs.map +1 -1
- package/dist/splitButton/index.d.mts +4 -0
- package/dist/splitButton/index.d.ts +4 -0
- package/dist/splitButton/index.js +43 -19
- package/dist/splitButton/index.js.map +1 -1
- package/dist/splitButton/index.mjs +43 -19
- package/dist/splitButton/index.mjs.map +1 -1
- package/dist/stats/index.d.mts +1 -1
- package/dist/stats/index.d.ts +1 -1
- package/dist/stats/index.js.map +1 -1
- package/dist/stats/index.mjs.map +1 -1
- package/dist/tabs/index.js +2 -2
- package/dist/tabs/index.js.map +1 -1
- package/dist/tabs/index.mjs +2 -2
- package/dist/tabs/index.mjs.map +1 -1
- package/dist/textarea/index.d.mts +1 -1
- package/dist/textarea/index.d.ts +1 -1
- package/dist/textarea/index.js +34 -30
- package/dist/textarea/index.js.map +1 -1
- package/dist/textarea/index.mjs +34 -30
- package/dist/textarea/index.mjs.map +1 -1
- package/package.json +2 -1
package/dist/index.js
CHANGED
@@ -167,6 +167,10 @@ __export(components_exports, {
|
|
167
167
|
PhoneInput: () => PhoneInput,
|
168
168
|
PhoneMockup: () => PhoneMockup,
|
169
169
|
PinInput: () => PinInput,
|
170
|
+
PinInputGroup: () => PinInputGroup,
|
171
|
+
PinInputRoot: () => PinInputRoot,
|
172
|
+
PinInputSeperator: () => PinInputSeperator,
|
173
|
+
PinInputSlot: () => PinInputSlot,
|
170
174
|
Popover: () => Popover,
|
171
175
|
PopoverContent: () => PopoverContent,
|
172
176
|
PopoverPortal: () => PopoverPortal,
|
@@ -2349,30 +2353,54 @@ var Button = React17.forwardRef(
|
|
2349
2353
|
children,
|
2350
2354
|
labelProps,
|
2351
2355
|
showHelperText = false,
|
2356
|
+
inForm = false,
|
2352
2357
|
...props
|
2353
2358
|
}, ref) => {
|
2354
2359
|
const Comp = "button";
|
2355
2360
|
const loadingColor = variant === "outline" || variant === "ghost" || variant === "neoBrutalism" ? "hawa-bg-primary" : "hawa-bg-primary-foreground";
|
2356
|
-
|
2357
|
-
|
2358
|
-
|
2359
|
-
className: cn(
|
2360
|
-
buttonVariants({ variant, size, className }),
|
2361
|
-
centered && "hawa-justify-center"
|
2362
|
-
),
|
2363
|
-
ref,
|
2364
|
-
...props
|
2365
|
-
},
|
2366
|
-
isLoading ? /* @__PURE__ */ React17.createElement(
|
2367
|
-
Loading,
|
2361
|
+
if (inForm) {
|
2362
|
+
return /* @__PURE__ */ React17.createElement("div", { className: "hawa-flex hawa-flex-col hawa-gap-2" }, label && /* @__PURE__ */ React17.createElement(Label2, { ...labelProps }, label), /* @__PURE__ */ React17.createElement(
|
2363
|
+
Comp,
|
2368
2364
|
{
|
2369
|
-
|
2370
|
-
|
2371
|
-
|
2372
|
-
|
2373
|
-
|
2374
|
-
|
2375
|
-
|
2365
|
+
className: cn(
|
2366
|
+
buttonVariants({ variant, size, className }),
|
2367
|
+
centered && "hawa-justify-center"
|
2368
|
+
),
|
2369
|
+
ref,
|
2370
|
+
...props
|
2371
|
+
},
|
2372
|
+
isLoading ? /* @__PURE__ */ React17.createElement(
|
2373
|
+
Loading,
|
2374
|
+
{
|
2375
|
+
design: size === "icon" || size === "smallIcon" ? "spinner" : "dots-pulse",
|
2376
|
+
themeMode: variant === "outline" ? "light" : "dark",
|
2377
|
+
color: loadingColor,
|
2378
|
+
size: size === "sm" || size === "xs" ? "xs" : "button"
|
2379
|
+
}
|
2380
|
+
) : children
|
2381
|
+
), showHelperText && /* @__PURE__ */ React17.createElement(HelperText, { helperText: props.helperText }));
|
2382
|
+
} else {
|
2383
|
+
return /* @__PURE__ */ React17.createElement(
|
2384
|
+
Comp,
|
2385
|
+
{
|
2386
|
+
className: cn(
|
2387
|
+
buttonVariants({ variant, size, className }),
|
2388
|
+
centered && "hawa-justify-center"
|
2389
|
+
),
|
2390
|
+
ref,
|
2391
|
+
...props
|
2392
|
+
},
|
2393
|
+
isLoading ? /* @__PURE__ */ React17.createElement(
|
2394
|
+
Loading,
|
2395
|
+
{
|
2396
|
+
design: size === "icon" || size === "smallIcon" ? "spinner" : "dots-pulse",
|
2397
|
+
themeMode: variant === "outline" ? "light" : "dark",
|
2398
|
+
color: loadingColor,
|
2399
|
+
size: size === "sm" || size === "xs" ? "xs" : "button"
|
2400
|
+
}
|
2401
|
+
) : children
|
2402
|
+
);
|
2403
|
+
}
|
2376
2404
|
}
|
2377
2405
|
);
|
2378
2406
|
Button.displayName = "Button";
|
@@ -2775,16 +2803,7 @@ var Input = (0, import_react11.forwardRef)(
|
|
2775
2803
|
inputProps == null ? void 0 : inputProps.className
|
2776
2804
|
)
|
2777
2805
|
}
|
2778
|
-
)), !forceHideHelperText && /* @__PURE__ */ import_react11.default.createElement(
|
2779
|
-
"p",
|
2780
|
-
{
|
2781
|
-
className: cn(
|
2782
|
-
"hawa-my-0 hawa-text-start hawa-text-xs hawa-text-helper-color hawa-transition-all",
|
2783
|
-
props.helperText ? "hawa-h-4 hawa-opacity-100" : "hawa-h-0 hawa-opacity-0"
|
2784
|
-
)
|
2785
|
-
},
|
2786
|
-
props.helperText
|
2787
|
-
), !props.disabled && forceHideHelperText && /* @__PURE__ */ import_react11.default.createElement(
|
2806
|
+
)), !forceHideHelperText && /* @__PURE__ */ import_react11.default.createElement(HelperText, { helperText: props.helperText }), !props.disabled && forceHideHelperText && /* @__PURE__ */ import_react11.default.createElement(
|
2788
2807
|
"div",
|
2789
2808
|
{
|
2790
2809
|
className: cn(
|
@@ -3599,16 +3618,7 @@ var Radio = (0, import_react13.forwardRef)(
|
|
3599
3618
|
opt.label
|
3600
3619
|
);
|
3601
3620
|
})
|
3602
|
-
), !forceHideHelperText && /* @__PURE__ */ import_react13.default.createElement(
|
3603
|
-
"p",
|
3604
|
-
{
|
3605
|
-
className: cn(
|
3606
|
-
"hawa-my-0 hawa-text-start hawa-text-xs hawa-text-helper-color hawa-transition-all",
|
3607
|
-
props.helperText ? "hawa-h-4 hawa-opacity-100" : "hawa-h-0 hawa-opacity-0"
|
3608
|
-
)
|
3609
|
-
},
|
3610
|
-
props.helperText
|
3611
|
-
));
|
3621
|
+
), !forceHideHelperText && /* @__PURE__ */ import_react13.default.createElement(HelperText, { helperText: props.helperText }));
|
3612
3622
|
case "bordered":
|
3613
3623
|
return /* @__PURE__ */ import_react13.default.createElement("div", { className: cn(orientationStyle[orientation], "hawa-gap-4") }, props.options && props.options.map((opt, i) => /* @__PURE__ */ import_react13.default.createElement("div", { key: i, className: "hawa-w-full hawa-rounded hawa-border" }, /* @__PURE__ */ import_react13.default.createElement(
|
3614
3624
|
"div",
|
@@ -3697,16 +3707,7 @@ var Radio = (0, import_react13.forwardRef)(
|
|
3697
3707
|
},
|
3698
3708
|
opt.label
|
3699
3709
|
)
|
3700
|
-
))), /* @__PURE__ */ import_react13.default.createElement(
|
3701
|
-
"p",
|
3702
|
-
{
|
3703
|
-
className: cn(
|
3704
|
-
"hawa-my-0 hawa-text-start hawa-text-xs hawa-text-helper-color hawa-transition-all",
|
3705
|
-
props.helperText ? "hawa-h-4 hawa-opacity-100" : "hawa-h-0 hawa-opacity-0"
|
3706
|
-
)
|
3707
|
-
},
|
3708
|
-
props.helperText
|
3709
|
-
));
|
3710
|
+
))), /* @__PURE__ */ import_react13.default.createElement(HelperText, { helperText: props.helperText }));
|
3710
3711
|
}
|
3711
3712
|
}
|
3712
3713
|
);
|
@@ -3976,16 +3977,7 @@ var Combobox = React28.forwardRef(
|
|
3976
3977
|
},
|
3977
3978
|
/* @__PURE__ */ React28.createElement("path", { d: "m6 9 6 6 6-6" })
|
3978
3979
|
)
|
3979
|
-
), /* @__PURE__ */ React28.createElement(
|
3980
|
-
"p",
|
3981
|
-
{
|
3982
|
-
className: cn(
|
3983
|
-
"hawa-my-0 hawa-text-start hawa-text-xs hawa-text-helper-color hawa-transition-all",
|
3984
|
-
props.helperText ? "hawa-h-4 hawa-opacity-100" : "hawa-h-0 hawa-opacity-0"
|
3985
|
-
)
|
3986
|
-
},
|
3987
|
-
props.helperText
|
3988
|
-
))), /* @__PURE__ */ React28.createElement(
|
3980
|
+
), /* @__PURE__ */ React28.createElement(HelperText, { helperText: props.helperText }))), /* @__PURE__ */ React28.createElement(
|
3989
3981
|
PopoverContent,
|
3990
3982
|
{
|
3991
3983
|
sideOffset: 0,
|
@@ -4109,16 +4101,7 @@ var Textarea = React29.forwardRef(
|
|
4109
4101
|
ref
|
4110
4102
|
}
|
4111
4103
|
),
|
4112
|
-
/* @__PURE__ */ React29.createElement("div", { className: "hawa-flex hawa-flex-row hawa-justify-between" }, !forceHideHelperText && /* @__PURE__ */ React29.createElement(
|
4113
|
-
"p",
|
4114
|
-
{
|
4115
|
-
className: cn(
|
4116
|
-
"hawa-my-0 hawa-text-start hawa-text-xs hawa-text-helper-color hawa-transition-all",
|
4117
|
-
props.helperText ? "hawa-h-4 hawa-opacity-100" : "hawa-h-0 hawa-opacity-0"
|
4118
|
-
)
|
4119
|
-
},
|
4120
|
-
props.helperText
|
4121
|
-
), showCount && countPosition === "bottom" && /* @__PURE__ */ React29.createElement("div", { className: "hawa-text-start hawa-text-xs hawa-transition-all" }, (textareaProps == null ? void 0 : textareaProps.value) ? String(textareaProps == null ? void 0 : textareaProps.value).length : 0, "/", textareaProps == null ? void 0 : textareaProps.maxLength))
|
4104
|
+
/* @__PURE__ */ React29.createElement("div", { className: "hawa-flex hawa-flex-row hawa-justify-between" }, !forceHideHelperText && /* @__PURE__ */ React29.createElement(HelperText, { helperText: props.helperText }), showCount && countPosition === "bottom" && /* @__PURE__ */ React29.createElement("div", { className: "hawa-text-start hawa-text-xs hawa-transition-all" }, (textareaProps == null ? void 0 : textareaProps.value) ? String(textareaProps == null ? void 0 : textareaProps.value).length : 0, "/", textareaProps == null ? void 0 : textareaProps.maxLength))
|
4122
4105
|
);
|
4123
4106
|
}
|
4124
4107
|
);
|
@@ -5044,7 +5027,7 @@ var ScrollArea = React41.forwardRef(({ className, children, orientation = "verti
|
|
5044
5027
|
"div",
|
5045
5028
|
{
|
5046
5029
|
className: cn(
|
5047
|
-
"hawa-pointer-events-none hawa-absolute hawa-bg-background
|
5030
|
+
"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",
|
5048
5031
|
showLeftFade ? "hawa-block" : "hawa-hidden"
|
5049
5032
|
)
|
5050
5033
|
}
|
@@ -5053,7 +5036,7 @@ var ScrollArea = React41.forwardRef(({ className, children, orientation = "verti
|
|
5053
5036
|
"div",
|
5054
5037
|
{
|
5055
5038
|
className: cn(
|
5056
|
-
"hawa-pointer-events-none hawa-absolute hawa-bg-background
|
5039
|
+
"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 ",
|
5057
5040
|
showRightFade ? "hawa-block" : "hawa-hidden"
|
5058
5041
|
)
|
5059
5042
|
}
|
@@ -5433,16 +5416,7 @@ var Select = ({
|
|
5433
5416
|
onInputChange: (newValue, action) => props.onInputChange(newValue, action)
|
5434
5417
|
}
|
5435
5418
|
),
|
5436
|
-
!props.hideHelperText && /* @__PURE__ */ import_react33.default.createElement(
|
5437
|
-
"p",
|
5438
|
-
{
|
5439
|
-
className: cn(
|
5440
|
-
"hawa-my-0 hawa-text-start hawa-text-xs hawa-text-helper-color hawa-transition-all",
|
5441
|
-
props.helperText ? "hawa-h-4 hawa-opacity-100" : "hawa-h-0 hawa-opacity-0"
|
5442
|
-
)
|
5443
|
-
},
|
5444
|
-
props.helperText
|
5445
|
-
)
|
5419
|
+
!props.hideHelperText && /* @__PURE__ */ import_react33.default.createElement(HelperText, { helperText: props.helperText })
|
5446
5420
|
);
|
5447
5421
|
};
|
5448
5422
|
|
@@ -7583,112 +7557,162 @@ var PhoneInput = ({
|
|
7583
7557
|
),
|
7584
7558
|
...inputProps
|
7585
7559
|
}
|
7586
|
-
))), /* @__PURE__ */ import_react37.default.createElement(
|
7587
|
-
"p",
|
7588
|
-
{
|
7589
|
-
className: cn(
|
7590
|
-
"hawa-my-0 hawa-text-start hawa-text-xs hawa-text-helper-color hawa-transition-all",
|
7591
|
-
props.helperText ? "hawa-h-4 hawa-opacity-100" : "hawa-h-0 hawa-opacity-0"
|
7592
|
-
)
|
7593
|
-
},
|
7594
|
-
props.helperText
|
7595
|
-
));
|
7560
|
+
))), /* @__PURE__ */ import_react37.default.createElement(HelperText, { helperText: props.helperText }));
|
7596
7561
|
};
|
7597
7562
|
|
7598
7563
|
// elements/pinInput/PinInput.tsx
|
7599
|
-
var
|
7600
|
-
var
|
7601
|
-
|
7602
|
-
|
7603
|
-
|
7604
|
-
|
7605
|
-
|
7606
|
-
|
7607
|
-
|
7608
|
-
|
7609
|
-
|
7610
|
-
|
7611
|
-
|
7612
|
-
|
7613
|
-
|
7614
|
-
|
7615
|
-
|
7616
|
-
|
7617
|
-
|
7618
|
-
|
7619
|
-
|
7620
|
-
|
7621
|
-
|
7622
|
-
|
7623
|
-
|
7624
|
-
|
7625
|
-
|
7626
|
-
|
7627
|
-
|
7628
|
-
|
7629
|
-
|
7630
|
-
|
7631
|
-
|
7632
|
-
|
7633
|
-
|
7634
|
-
|
7635
|
-
|
7636
|
-
|
7637
|
-
|
7638
|
-
|
7639
|
-
|
7640
|
-
|
7641
|
-
}
|
7642
|
-
};
|
7643
|
-
return /* @__PURE__ */ import_react38.default.createElement("div", { className: "hawa-flex hawa-flex-col hawa-gap-2" }, /* @__PURE__ */ import_react38.default.createElement(
|
7644
|
-
"div",
|
7645
|
-
{
|
7646
|
-
className: "hawa-flex hawa-w-full hawa-flex-row hawa-justify-center hawa-gap-2",
|
7647
|
-
dir: "ltr"
|
7648
|
-
},
|
7649
|
-
pin.map((value, index) => /* @__PURE__ */ import_react38.default.createElement(
|
7650
|
-
"input",
|
7564
|
+
var React51 = __toESM(require("react"));
|
7565
|
+
var import_input_otp = require("input-otp");
|
7566
|
+
|
7567
|
+
// ../../node_modules/.pnpm/lucide-react@0.379.0_react@18.3.1/node_modules/lucide-react/dist/esm/createLucideIcon.js
|
7568
|
+
var import_react39 = require("react");
|
7569
|
+
|
7570
|
+
// ../../node_modules/.pnpm/lucide-react@0.379.0_react@18.3.1/node_modules/lucide-react/dist/esm/shared/src/utils.js
|
7571
|
+
var toKebabCase = (string9) => string9.replace(/([a-z0-9])([A-Z])/g, "$1-$2").toLowerCase();
|
7572
|
+
var mergeClasses = (...classes) => classes.filter((className, index, array) => {
|
7573
|
+
return Boolean(className) && array.indexOf(className) === index;
|
7574
|
+
}).join(" ");
|
7575
|
+
|
7576
|
+
// ../../node_modules/.pnpm/lucide-react@0.379.0_react@18.3.1/node_modules/lucide-react/dist/esm/Icon.js
|
7577
|
+
var import_react38 = require("react");
|
7578
|
+
|
7579
|
+
// ../../node_modules/.pnpm/lucide-react@0.379.0_react@18.3.1/node_modules/lucide-react/dist/esm/defaultAttributes.js
|
7580
|
+
var defaultAttributes = {
|
7581
|
+
xmlns: "http://www.w3.org/2000/svg",
|
7582
|
+
width: 24,
|
7583
|
+
height: 24,
|
7584
|
+
viewBox: "0 0 24 24",
|
7585
|
+
fill: "none",
|
7586
|
+
stroke: "currentColor",
|
7587
|
+
strokeWidth: 2,
|
7588
|
+
strokeLinecap: "round",
|
7589
|
+
strokeLinejoin: "round"
|
7590
|
+
};
|
7591
|
+
|
7592
|
+
// ../../node_modules/.pnpm/lucide-react@0.379.0_react@18.3.1/node_modules/lucide-react/dist/esm/Icon.js
|
7593
|
+
var Icon = (0, import_react38.forwardRef)(
|
7594
|
+
({
|
7595
|
+
color = "currentColor",
|
7596
|
+
size = 24,
|
7597
|
+
strokeWidth = 2,
|
7598
|
+
absoluteStrokeWidth,
|
7599
|
+
className = "",
|
7600
|
+
children,
|
7601
|
+
iconNode,
|
7602
|
+
...rest
|
7603
|
+
}, ref) => {
|
7604
|
+
return (0, import_react38.createElement)(
|
7605
|
+
"svg",
|
7651
7606
|
{
|
7652
|
-
|
7653
|
-
|
7654
|
-
|
7655
|
-
|
7656
|
-
|
7657
|
-
|
7658
|
-
|
7659
|
-
|
7660
|
-
|
7661
|
-
|
7662
|
-
),
|
7663
|
-
|
7664
|
-
|
7665
|
-
|
7666
|
-
|
7667
|
-
|
7668
|
-
|
7669
|
-
|
7670
|
-
|
7607
|
+
ref,
|
7608
|
+
...defaultAttributes,
|
7609
|
+
width: size,
|
7610
|
+
height: size,
|
7611
|
+
stroke: color,
|
7612
|
+
strokeWidth: absoluteStrokeWidth ? Number(strokeWidth) * 24 / Number(size) : strokeWidth,
|
7613
|
+
className: mergeClasses("lucide", className),
|
7614
|
+
...rest
|
7615
|
+
},
|
7616
|
+
[
|
7617
|
+
...iconNode.map(([tag, attrs]) => (0, import_react38.createElement)(tag, attrs)),
|
7618
|
+
...Array.isArray(children) ? children : [children]
|
7619
|
+
]
|
7620
|
+
);
|
7621
|
+
}
|
7622
|
+
);
|
7623
|
+
|
7624
|
+
// ../../node_modules/.pnpm/lucide-react@0.379.0_react@18.3.1/node_modules/lucide-react/dist/esm/createLucideIcon.js
|
7625
|
+
var createLucideIcon = (iconName, iconNode) => {
|
7626
|
+
const Component = (0, import_react39.forwardRef)(
|
7627
|
+
({ className, ...props }, ref) => (0, import_react39.createElement)(Icon, {
|
7628
|
+
ref,
|
7629
|
+
iconNode,
|
7630
|
+
className: mergeClasses(`lucide-${toKebabCase(iconName)}`, className),
|
7631
|
+
...props
|
7632
|
+
})
|
7633
|
+
);
|
7634
|
+
Component.displayName = `${iconName}`;
|
7635
|
+
return Component;
|
7636
|
+
};
|
7637
|
+
|
7638
|
+
// ../../node_modules/.pnpm/lucide-react@0.379.0_react@18.3.1/node_modules/lucide-react/dist/esm/icons/dot.js
|
7639
|
+
var Dot = createLucideIcon("Dot", [
|
7640
|
+
["circle", { cx: "12.1", cy: "12.1", r: "1", key: "18d7e5" }]
|
7641
|
+
]);
|
7642
|
+
|
7643
|
+
// elements/pinInput/PinInput.tsx
|
7644
|
+
var PinInputRoot = React51.forwardRef(({ className, containerClassName, ...props }, ref) => /* @__PURE__ */ React51.createElement(
|
7645
|
+
import_input_otp.OTPInput,
|
7646
|
+
{
|
7647
|
+
ref,
|
7648
|
+
containerClassName: cn(
|
7649
|
+
"hawa-flex hawa-items-center hawa-gap-2 has-[:disabled]:hawa-opacity-50",
|
7650
|
+
containerClassName
|
7651
|
+
),
|
7652
|
+
className: cn("disabled:hawa-cursor-not-allowed", className),
|
7653
|
+
...props
|
7654
|
+
}
|
7655
|
+
));
|
7656
|
+
PinInputRoot.displayName = "PinInputRoot";
|
7657
|
+
var PinInputGroup = React51.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ React51.createElement(
|
7658
|
+
"div",
|
7659
|
+
{
|
7660
|
+
ref,
|
7661
|
+
className: cn("hawa-flex hawa-items-center", className),
|
7662
|
+
...props
|
7663
|
+
}
|
7664
|
+
));
|
7665
|
+
PinInputGroup.displayName = "PinInputGroup";
|
7666
|
+
var PinInputSlot = React51.forwardRef(({ index, className, ...props }, ref) => {
|
7667
|
+
const pinInputContext = React51.useContext(import_input_otp.OTPInputContext);
|
7668
|
+
const { char, hasFakeCaret, isActive } = pinInputContext.slots[index];
|
7669
|
+
return /* @__PURE__ */ React51.createElement(
|
7670
|
+
"div",
|
7671
7671
|
{
|
7672
|
+
ref,
|
7672
7673
|
className: cn(
|
7673
|
-
"hawa-
|
7674
|
-
|
7675
|
-
|
7674
|
+
"hawa-border-input hawa-relative hawa-flex hawa-h-10 hawa-w-10 hawa-items-center hawa-justify-center hawa-border-y hawa-border-r hawa-text-sm hawa-transition-all first:hawa-rounded-l-md first:hawa-border-l last:hawa-rounded-r-md",
|
7675
|
+
isActive && "hawa-ring-ring hawa-ring-offset-background hawa-z-10 hawa-ring-2",
|
7676
|
+
className
|
7677
|
+
),
|
7678
|
+
...props
|
7676
7679
|
},
|
7677
|
-
|
7678
|
-
|
7680
|
+
char,
|
7681
|
+
hasFakeCaret && /* @__PURE__ */ React51.createElement("div", { className: "hawa-pointer-events-none hawa-absolute hawa-inset-0 hawa-flex hawa-items-center hawa-justify-center" }, /* @__PURE__ */ React51.createElement("div", { className: "hawa-animate-caret-blink hawa-bg-foreground hawa-h-4 hawa-w-px hawa-duration-1000" }))
|
7682
|
+
);
|
7683
|
+
});
|
7684
|
+
PinInputSlot.displayName = "PinInputSlot";
|
7685
|
+
var PinInputSeperator = React51.forwardRef(({ ...props }, ref) => /* @__PURE__ */ React51.createElement("div", { ref, role: "separator", ...props }, /* @__PURE__ */ React51.createElement(Dot, null)));
|
7686
|
+
PinInputSeperator.displayName = "PinInputSeperator";
|
7687
|
+
var PinInput = ({
|
7688
|
+
separatorPosition = 0,
|
7689
|
+
...props
|
7690
|
+
}) => {
|
7691
|
+
const maxLength = props.maxLength || 6;
|
7692
|
+
const clampedSeparatorPosition = Math.min(separatorPosition, maxLength);
|
7693
|
+
const firstGroupLength = clampedSeparatorPosition > 0 ? clampedSeparatorPosition : 0;
|
7694
|
+
const secondGroupLength = maxLength - firstGroupLength;
|
7695
|
+
return /* @__PURE__ */ React51.createElement("div", { className: "hawa-flex hawa-flex-col hawa-gap-2" }, /* @__PURE__ */ React51.createElement(PinInputRoot, { ...props }, firstGroupLength > 0 && /* @__PURE__ */ React51.createElement(PinInputGroup, { className: "hawa-w-full" }, [...Array(firstGroupLength)].map((_, index) => /* @__PURE__ */ React51.createElement(PinInputSlot, { key: index, index, className: "hawa-w-full" }))), separatorPosition > 0 && separatorPosition < props.maxLength && /* @__PURE__ */ React51.createElement(PinInputSeperator, null), secondGroupLength > 0 && /* @__PURE__ */ React51.createElement(PinInputGroup, { className: "hawa-w-full" }, [...Array(secondGroupLength)].map((_, index) => /* @__PURE__ */ React51.createElement(
|
7696
|
+
PinInputSlot,
|
7697
|
+
{
|
7698
|
+
key: index + firstGroupLength,
|
7699
|
+
index: index + firstGroupLength,
|
7700
|
+
className: "hawa-w-full"
|
7701
|
+
}
|
7702
|
+
)))), /* @__PURE__ */ React51.createElement(HelperText, { helperText: props.helperText }));
|
7679
7703
|
};
|
7680
7704
|
|
7681
7705
|
// elements/stopPropagationWrapper/StopPropagationWrapper.tsx
|
7682
|
-
var
|
7706
|
+
var import_react40 = __toESM(require("react"));
|
7683
7707
|
var StopPropagationWrapper = (props) => {
|
7684
7708
|
const handleClick = (e) => {
|
7685
7709
|
e.stopPropagation();
|
7686
7710
|
};
|
7687
|
-
return /* @__PURE__ */
|
7711
|
+
return /* @__PURE__ */ import_react40.default.createElement("div", { onClick: handleClick }, props.children);
|
7688
7712
|
};
|
7689
7713
|
|
7690
7714
|
// elements/colorPicker/ColorPicker.tsx
|
7691
|
-
var
|
7715
|
+
var import_react41 = __toESM(require("react"));
|
7692
7716
|
var ColorPicker = ({
|
7693
7717
|
containerProps,
|
7694
7718
|
colorPickerProps,
|
@@ -7699,8 +7723,8 @@ var ColorPicker = ({
|
|
7699
7723
|
preview = false,
|
7700
7724
|
...props
|
7701
7725
|
}) => {
|
7702
|
-
const [selectedColor, setSelectedColor] = (0,
|
7703
|
-
(0,
|
7726
|
+
const [selectedColor, setSelectedColor] = (0, import_react41.useState)(props.color);
|
7727
|
+
(0, import_react41.useEffect)(() => {
|
7704
7728
|
if (selectedColor && selectedColor[0] !== "#") {
|
7705
7729
|
setSelectedColor(`#${selectedColor}`);
|
7706
7730
|
}
|
@@ -7717,13 +7741,13 @@ var ColorPicker = ({
|
|
7717
7741
|
props.handleChange(e);
|
7718
7742
|
}
|
7719
7743
|
};
|
7720
|
-
return /* @__PURE__ */
|
7744
|
+
return /* @__PURE__ */ import_react41.default.createElement("div", { className: "hawa-flex hawa-w-fit hawa-flex-col hawa-gap-2" }, props.label && /* @__PURE__ */ import_react41.default.createElement(Label2, { ...labelProps }, props.label), isLoading ? /* @__PURE__ */ import_react41.default.createElement(Skeleton, { style: { height: 40, width: 148 } }) : /* @__PURE__ */ import_react41.default.createElement("div", { dir: "ltr", className: "hawa-flex hawa-w-full hawa-flex-row" }, /* @__PURE__ */ import_react41.default.createElement(
|
7721
7745
|
"div",
|
7722
7746
|
{
|
7723
7747
|
style: { height: 40, backgroundColor: selectedColor },
|
7724
7748
|
className: "hawa-rounded-bl-lg hawa-rounded-tl-lg hawa-border"
|
7725
7749
|
},
|
7726
|
-
/* @__PURE__ */
|
7750
|
+
/* @__PURE__ */ import_react41.default.createElement(
|
7727
7751
|
"input",
|
7728
7752
|
{
|
7729
7753
|
disabled: preview,
|
@@ -7742,7 +7766,7 @@ var ColorPicker = ({
|
|
7742
7766
|
...colorPickerProps
|
7743
7767
|
}
|
7744
7768
|
)
|
7745
|
-
), /* @__PURE__ */
|
7769
|
+
), /* @__PURE__ */ import_react41.default.createElement("div", { className: "hawa-relative hawa-flex hawa-max-h-fit hawa-w-full hawa-flex-col hawa-justify-center hawa-gap-0" }, /* @__PURE__ */ import_react41.default.createElement(
|
7746
7770
|
"input",
|
7747
7771
|
{
|
7748
7772
|
disabled: preview,
|
@@ -7761,20 +7785,11 @@ var ColorPicker = ({
|
|
7761
7785
|
},
|
7762
7786
|
...textInputProps
|
7763
7787
|
}
|
7764
|
-
))), !forceHideHelperText && /* @__PURE__ */
|
7765
|
-
"p",
|
7766
|
-
{
|
7767
|
-
className: cn(
|
7768
|
-
"hawa-my-0 hawa-text-start hawa-text-xs hawa-text-helper-color hawa-transition-all",
|
7769
|
-
props.helperText ? "hawa-h-4 hawa-opacity-100" : "hawa-h-0 hawa-opacity-0"
|
7770
|
-
)
|
7771
|
-
},
|
7772
|
-
props.helperText
|
7773
|
-
));
|
7788
|
+
))), !forceHideHelperText && /* @__PURE__ */ import_react41.default.createElement(HelperText, { helperText: props.helperText }));
|
7774
7789
|
};
|
7775
7790
|
|
7776
7791
|
// elements/progressCircle/ProgressCircle.tsx
|
7777
|
-
var
|
7792
|
+
var import_react42 = __toESM(require("react"));
|
7778
7793
|
var size2config = {
|
7779
7794
|
xs: { radius: 15, strokeWidth: 3 },
|
7780
7795
|
sm: { radius: 19, strokeWidth: 4 },
|
@@ -7791,7 +7806,7 @@ function getLimitedValue(input) {
|
|
7791
7806
|
return input;
|
7792
7807
|
}
|
7793
7808
|
}
|
7794
|
-
var ProgressCircle =
|
7809
|
+
var ProgressCircle = import_react42.default.forwardRef((props, ref) => {
|
7795
7810
|
const {
|
7796
7811
|
value: inputValue,
|
7797
7812
|
size = "md",
|
@@ -7811,7 +7826,7 @@ var ProgressCircle = import_react41.default.forwardRef((props, ref) => {
|
|
7811
7826
|
const circumference = normalizedRadius * 2 * Math.PI;
|
7812
7827
|
const strokeDashoffset = value / 100 * circumference;
|
7813
7828
|
const offset = circumference - strokeDashoffset;
|
7814
|
-
return /* @__PURE__ */
|
7829
|
+
return /* @__PURE__ */ import_react42.default.createElement(import_react42.default.Fragment, null, /* @__PURE__ */ import_react42.default.createElement(
|
7815
7830
|
"div",
|
7816
7831
|
{
|
7817
7832
|
ref,
|
@@ -7820,7 +7835,7 @@ var ProgressCircle = import_react41.default.forwardRef((props, ref) => {
|
|
7820
7835
|
className
|
7821
7836
|
)
|
7822
7837
|
},
|
7823
|
-
/* @__PURE__ */
|
7838
|
+
/* @__PURE__ */ import_react42.default.createElement(
|
7824
7839
|
"svg",
|
7825
7840
|
{
|
7826
7841
|
width: radius * 2,
|
@@ -7828,7 +7843,7 @@ var ProgressCircle = import_react41.default.forwardRef((props, ref) => {
|
|
7828
7843
|
viewBox: `0 0 ${radius * 2} ${radius * 2}`,
|
7829
7844
|
className: "hawa-rotate-180 hawa-transform"
|
7830
7845
|
},
|
7831
|
-
/* @__PURE__ */
|
7846
|
+
/* @__PURE__ */ import_react42.default.createElement(
|
7832
7847
|
"circle",
|
7833
7848
|
{
|
7834
7849
|
r: normalizedRadius,
|
@@ -7844,7 +7859,7 @@ var ProgressCircle = import_react41.default.forwardRef((props, ref) => {
|
|
7844
7859
|
)
|
7845
7860
|
}
|
7846
7861
|
),
|
7847
|
-
value > 0 ? /* @__PURE__ */
|
7862
|
+
value > 0 ? /* @__PURE__ */ import_react42.default.createElement(
|
7848
7863
|
"circle",
|
7849
7864
|
{
|
7850
7865
|
r: normalizedRadius,
|
@@ -7864,24 +7879,24 @@ var ProgressCircle = import_react41.default.forwardRef((props, ref) => {
|
|
7864
7879
|
}
|
7865
7880
|
) : null
|
7866
7881
|
),
|
7867
|
-
/* @__PURE__ */
|
7882
|
+
/* @__PURE__ */ import_react42.default.createElement("div", { className: cn("hawa-absolute hawa-flex") }, children)
|
7868
7883
|
));
|
7869
7884
|
});
|
7870
7885
|
ProgressCircle.displayName = "ProgressCircle";
|
7871
7886
|
|
7872
7887
|
// elements/pagination/Pagination.tsx
|
7873
|
-
var
|
7888
|
+
var import_react43 = __toESM(require("react"));
|
7874
7889
|
var import_react_headless_pagination = require("react-headless-pagination");
|
7875
7890
|
var Pagination = ({
|
7876
7891
|
direction,
|
7877
7892
|
totalPages,
|
7878
7893
|
currentPage
|
7879
7894
|
}) => {
|
7880
|
-
const [page, setPage] =
|
7895
|
+
const [page, setPage] = import_react43.default.useState(currentPage || 0);
|
7881
7896
|
const handlePageChange = (page2) => {
|
7882
7897
|
setPage(page2);
|
7883
7898
|
};
|
7884
|
-
return /* @__PURE__ */
|
7899
|
+
return /* @__PURE__ */ import_react43.default.createElement(
|
7885
7900
|
import_react_headless_pagination.Pagination,
|
7886
7901
|
{
|
7887
7902
|
totalPages,
|
@@ -7893,10 +7908,10 @@ var Pagination = ({
|
|
7893
7908
|
truncableText: "...",
|
7894
7909
|
truncableClassName: "hawa-w-10 hawa-px-0.5 hawa-text-center"
|
7895
7910
|
},
|
7896
|
-
/* @__PURE__ */
|
7911
|
+
/* @__PURE__ */ import_react43.default.createElement(
|
7897
7912
|
import_react_headless_pagination.Pagination.PrevButton,
|
7898
7913
|
{
|
7899
|
-
as: /* @__PURE__ */
|
7914
|
+
as: /* @__PURE__ */ import_react43.default.createElement(
|
7900
7915
|
"button",
|
7901
7916
|
{
|
7902
7917
|
"aria-label": "Previous Table Page",
|
@@ -7906,7 +7921,7 @@ var Pagination = ({
|
|
7906
7921
|
),
|
7907
7922
|
style: { minWidth: 36 }
|
7908
7923
|
},
|
7909
|
-
/* @__PURE__ */
|
7924
|
+
/* @__PURE__ */ import_react43.default.createElement(
|
7910
7925
|
"svg",
|
7911
7926
|
{
|
7912
7927
|
xmlns: "http://www.w3.org/2000/svg",
|
@@ -7919,7 +7934,7 @@ var Pagination = ({
|
|
7919
7934
|
strokeLinecap: "round",
|
7920
7935
|
strokeLinejoin: "round"
|
7921
7936
|
},
|
7922
|
-
/* @__PURE__ */
|
7937
|
+
/* @__PURE__ */ import_react43.default.createElement("path", { d: "m15 18-6-6 6-6" })
|
7923
7938
|
)
|
7924
7939
|
),
|
7925
7940
|
className: cn(
|
@@ -7932,17 +7947,17 @@ var Pagination = ({
|
|
7932
7947
|
},
|
7933
7948
|
"Previous"
|
7934
7949
|
),
|
7935
|
-
/* @__PURE__ */
|
7950
|
+
/* @__PURE__ */ import_react43.default.createElement("nav", { className: "hawa-flex hawa-flex-grow hawa-justify-center" }, /* @__PURE__ */ import_react43.default.createElement("ul", { className: "hawa-flex hawa-items-center hawa-gap-1" }, /* @__PURE__ */ import_react43.default.createElement(
|
7936
7951
|
import_react_headless_pagination.Pagination.PageButton,
|
7937
7952
|
{
|
7938
7953
|
className: "hawa-tap-highlight-transparent hawa-text-default-foreground data-[focus-visible=true]:hawa-outline-focus data-[disabled=true]:hawa-text-default-300 hawa-min-w-9 hawa-text-small hawa-box-border hawa-flex hawa-h-9 hawa-w-9 hawa-cursor-pointer hawa-touch-none hawa-select-none hawa-flex-wrap hawa-items-center hawa-justify-center hawa-truncate hawa-rounded hawa-border hawa-bg-card hawa-outline-none hawa-transition-all hover:hawa-scale-[1.1] data-[disabled=true]:hawa-pointer-events-none data-[focus-visible=true]:hawa-z-10 data-[pressed=true]:hawa-scale-[0.97] data-[focus-visible=true]:hawa-outline-2 data-[focus-visible=true]:hawa-outline-offset-2",
|
7939
7954
|
activeClassName: "hawa-bg-primary hawa-text-primary-foreground hawa-transition-all"
|
7940
7955
|
}
|
7941
7956
|
))),
|
7942
|
-
/* @__PURE__ */
|
7957
|
+
/* @__PURE__ */ import_react43.default.createElement(
|
7943
7958
|
import_react_headless_pagination.Pagination.NextButton,
|
7944
7959
|
{
|
7945
|
-
as: /* @__PURE__ */
|
7960
|
+
as: /* @__PURE__ */ import_react43.default.createElement(
|
7946
7961
|
"button",
|
7947
7962
|
{
|
7948
7963
|
"aria-label": "Previous Table Page",
|
@@ -7952,7 +7967,7 @@ var Pagination = ({
|
|
7952
7967
|
),
|
7953
7968
|
style: { minWidth: 36 }
|
7954
7969
|
},
|
7955
|
-
/* @__PURE__ */
|
7970
|
+
/* @__PURE__ */ import_react43.default.createElement(
|
7956
7971
|
"svg",
|
7957
7972
|
{
|
7958
7973
|
xmlns: "http://www.w3.org/2000/svg",
|
@@ -7965,7 +7980,7 @@ var Pagination = ({
|
|
7965
7980
|
strokeLinecap: "round",
|
7966
7981
|
strokeLinejoin: "round"
|
7967
7982
|
},
|
7968
|
-
/* @__PURE__ */
|
7983
|
+
/* @__PURE__ */ import_react43.default.createElement("path", { d: "m15 18-6-6 6-6" })
|
7969
7984
|
)
|
7970
7985
|
),
|
7971
7986
|
className: cn(
|
@@ -7982,11 +7997,11 @@ var Pagination = ({
|
|
7982
7997
|
};
|
7983
7998
|
|
7984
7999
|
// elements/passwordInput/PasswordInput.tsx
|
7985
|
-
var
|
8000
|
+
var import_react47 = __toESM(require("react"));
|
7986
8001
|
|
7987
8002
|
// icons/Emojis.tsx
|
7988
|
-
var
|
7989
|
-
var VeryGoodEmoji = () => /* @__PURE__ */
|
8003
|
+
var import_react44 = __toESM(require("react"));
|
8004
|
+
var VeryGoodEmoji = () => /* @__PURE__ */ import_react44.default.createElement(
|
7990
8005
|
"svg",
|
7991
8006
|
{
|
7992
8007
|
fill: "none",
|
@@ -7995,7 +8010,7 @@ var VeryGoodEmoji = () => /* @__PURE__ */ import_react43.default.createElement(
|
|
7995
8010
|
width: "16",
|
7996
8011
|
xmlns: "http://www.w3.org/2000/svg"
|
7997
8012
|
},
|
7998
|
-
/* @__PURE__ */
|
8013
|
+
/* @__PURE__ */ import_react44.default.createElement("g", { clipPath: "url(#clip0_53_166)" }, /* @__PURE__ */ import_react44.default.createElement(
|
7999
8014
|
"path",
|
8000
8015
|
{
|
8001
8016
|
clipRule: "evenodd",
|
@@ -8003,7 +8018,7 @@ var VeryGoodEmoji = () => /* @__PURE__ */ import_react43.default.createElement(
|
|
8003
8018
|
fill: "currentColor",
|
8004
8019
|
fillRule: "evenodd"
|
8005
8020
|
}
|
8006
|
-
), /* @__PURE__ */
|
8021
|
+
), /* @__PURE__ */ import_react44.default.createElement(
|
8007
8022
|
"path",
|
8008
8023
|
{
|
8009
8024
|
clipRule: "evenodd",
|
@@ -8013,7 +8028,7 @@ var VeryGoodEmoji = () => /* @__PURE__ */ import_react43.default.createElement(
|
|
8013
8028
|
}
|
8014
8029
|
))
|
8015
8030
|
);
|
8016
|
-
var GoodEmoji = () => /* @__PURE__ */
|
8031
|
+
var GoodEmoji = () => /* @__PURE__ */ import_react44.default.createElement(
|
8017
8032
|
"svg",
|
8018
8033
|
{
|
8019
8034
|
fill: "none",
|
@@ -8022,7 +8037,7 @@ var GoodEmoji = () => /* @__PURE__ */ import_react43.default.createElement(
|
|
8022
8037
|
width: "16",
|
8023
8038
|
xmlns: "http://www.w3.org/2000/svg"
|
8024
8039
|
},
|
8025
|
-
/* @__PURE__ */
|
8040
|
+
/* @__PURE__ */ import_react44.default.createElement("g", { clipPath: "url(#clip0_53_167)" }, /* @__PURE__ */ import_react44.default.createElement(
|
8026
8041
|
"path",
|
8027
8042
|
{
|
8028
8043
|
clipRule: "evenodd",
|
@@ -8032,7 +8047,7 @@ var GoodEmoji = () => /* @__PURE__ */ import_react43.default.createElement(
|
|
8032
8047
|
}
|
8033
8048
|
))
|
8034
8049
|
);
|
8035
|
-
var BadEmoji = () => /* @__PURE__ */
|
8050
|
+
var BadEmoji = () => /* @__PURE__ */ import_react44.default.createElement(
|
8036
8051
|
"svg",
|
8037
8052
|
{
|
8038
8053
|
fill: "none",
|
@@ -8041,7 +8056,7 @@ var BadEmoji = () => /* @__PURE__ */ import_react43.default.createElement(
|
|
8041
8056
|
width: "16",
|
8042
8057
|
xmlns: "http://www.w3.org/2000/svg"
|
8043
8058
|
},
|
8044
|
-
/* @__PURE__ */
|
8059
|
+
/* @__PURE__ */ import_react44.default.createElement("g", { clipPath: "url(#clip0_53_152)" }, /* @__PURE__ */ import_react44.default.createElement(
|
8045
8060
|
"path",
|
8046
8061
|
{
|
8047
8062
|
clipRule: "evenodd",
|
@@ -8051,7 +8066,7 @@ var BadEmoji = () => /* @__PURE__ */ import_react43.default.createElement(
|
|
8051
8066
|
}
|
8052
8067
|
))
|
8053
8068
|
);
|
8054
|
-
var VeryBadEmoji = () => /* @__PURE__ */
|
8069
|
+
var VeryBadEmoji = () => /* @__PURE__ */ import_react44.default.createElement(
|
8055
8070
|
"svg",
|
8056
8071
|
{
|
8057
8072
|
fill: "none",
|
@@ -8060,13 +8075,13 @@ var VeryBadEmoji = () => /* @__PURE__ */ import_react43.default.createElement(
|
|
8060
8075
|
width: "16",
|
8061
8076
|
xmlns: "http://www.w3.org/2000/svg"
|
8062
8077
|
},
|
8063
|
-
/* @__PURE__ */
|
8078
|
+
/* @__PURE__ */ import_react44.default.createElement("g", { clipPath: "url(#clip0_53_151)" }, /* @__PURE__ */ import_react44.default.createElement(
|
8064
8079
|
"path",
|
8065
8080
|
{
|
8066
8081
|
d: "M11.841 12.0225C12.7197 12.9324 12.7197 14.4077 11.841 15.3176C10.9623 16.2275 9.53769 16.2275 8.65901 15.3176C7.78033 14.4077 7.78033 12.9324 8.65901 12.0225L10.25 10.375L11.841 12.0225Z",
|
8067
8082
|
fill: "#0070F3"
|
8068
8083
|
}
|
8069
|
-
), /* @__PURE__ */
|
8084
|
+
), /* @__PURE__ */ import_react44.default.createElement(
|
8070
8085
|
"path",
|
8071
8086
|
{
|
8072
8087
|
clipRule: "evenodd",
|
@@ -8078,8 +8093,8 @@ var VeryBadEmoji = () => /* @__PURE__ */ import_react43.default.createElement(
|
|
8078
8093
|
);
|
8079
8094
|
|
8080
8095
|
// icons/InputIcons.tsx
|
8081
|
-
var
|
8082
|
-
var EyeIcon = (props) => /* @__PURE__ */
|
8096
|
+
var import_react45 = __toESM(require("react"));
|
8097
|
+
var EyeIcon = (props) => /* @__PURE__ */ import_react45.default.createElement("div", { className: cn("hawa-h-5 hawa-w-5", props.className) }, /* @__PURE__ */ import_react45.default.createElement(
|
8083
8098
|
"svg",
|
8084
8099
|
{
|
8085
8100
|
xmlns: "http://www.w3.org/2000/svg",
|
@@ -8090,10 +8105,10 @@ var EyeIcon = (props) => /* @__PURE__ */ import_react44.default.createElement("d
|
|
8090
8105
|
strokeLinecap: "round",
|
8091
8106
|
strokeLinejoin: "round"
|
8092
8107
|
},
|
8093
|
-
/* @__PURE__ */
|
8094
|
-
/* @__PURE__ */
|
8108
|
+
/* @__PURE__ */ import_react45.default.createElement("path", { d: "M2 12s3-7 10-7 10 7 10 7-3 7-10 7-10-7-10-7Z" }),
|
8109
|
+
/* @__PURE__ */ import_react45.default.createElement("circle", { cx: "12", cy: "12", r: "3" })
|
8095
8110
|
));
|
8096
|
-
var HiddenEyeIcon = (props) => /* @__PURE__ */
|
8111
|
+
var HiddenEyeIcon = (props) => /* @__PURE__ */ import_react45.default.createElement("div", { className: cn("hawa-h-5 hawa-w-5", props.className) }, /* @__PURE__ */ import_react45.default.createElement(
|
8097
8112
|
"svg",
|
8098
8113
|
{
|
8099
8114
|
xmlns: "http://www.w3.org/2000/svg",
|
@@ -8104,20 +8119,20 @@ var HiddenEyeIcon = (props) => /* @__PURE__ */ import_react44.default.createElem
|
|
8104
8119
|
strokeLinecap: "round",
|
8105
8120
|
strokeLinejoin: "round"
|
8106
8121
|
},
|
8107
|
-
/* @__PURE__ */
|
8108
|
-
/* @__PURE__ */
|
8109
|
-
/* @__PURE__ */
|
8110
|
-
/* @__PURE__ */
|
8122
|
+
/* @__PURE__ */ import_react45.default.createElement("path", { d: "M9.88 9.88a3 3 0 1 0 4.24 4.24" }),
|
8123
|
+
/* @__PURE__ */ import_react45.default.createElement("path", { d: "M10.73 5.08A10.43 10.43 0 0 1 12 5c7 0 10 7 10 7a13.16 13.16 0 0 1-1.67 2.68" }),
|
8124
|
+
/* @__PURE__ */ import_react45.default.createElement("path", { d: "M6.61 6.61A13.526 13.526 0 0 0 2 12s3 7 10 7a9.74 9.74 0 0 0 5.39-1.61" }),
|
8125
|
+
/* @__PURE__ */ import_react45.default.createElement("line", { x1: "2", x2: "22", y1: "2", y2: "22" })
|
8111
8126
|
));
|
8112
8127
|
|
8113
8128
|
// icons/CommonIcons.tsx
|
8114
|
-
var
|
8129
|
+
var import_react46 = __toESM(require("react"));
|
8115
8130
|
var CheckMark = ({ size = "default", className }) => {
|
8116
8131
|
let sizeStyles2 = {
|
8117
8132
|
default: "hawa-h-5 hawa-w-5",
|
8118
8133
|
sm: "hawa-h-3 hawa-w-3"
|
8119
8134
|
};
|
8120
|
-
return /* @__PURE__ */
|
8135
|
+
return /* @__PURE__ */ import_react46.default.createElement(
|
8121
8136
|
"svg",
|
8122
8137
|
{
|
8123
8138
|
className: cn(sizeStyles2[size], className),
|
@@ -8125,7 +8140,7 @@ var CheckMark = ({ size = "default", className }) => {
|
|
8125
8140
|
fill: "currentColor",
|
8126
8141
|
viewBox: "0 0 20 20"
|
8127
8142
|
},
|
8128
|
-
/* @__PURE__ */
|
8143
|
+
/* @__PURE__ */ import_react46.default.createElement(
|
8129
8144
|
"path",
|
8130
8145
|
{
|
8131
8146
|
fillRule: "evenodd",
|
@@ -8140,7 +8155,7 @@ var UncheckMark = ({ size = "default", className }) => {
|
|
8140
8155
|
default: "hawa-h-5 hawa-w-5",
|
8141
8156
|
sm: "hawa-h-3 hawa-w-3"
|
8142
8157
|
};
|
8143
|
-
return /* @__PURE__ */
|
8158
|
+
return /* @__PURE__ */ import_react46.default.createElement(
|
8144
8159
|
"svg",
|
8145
8160
|
{
|
8146
8161
|
className: cn(sizeStyles2[size], className),
|
@@ -8148,7 +8163,7 @@ var UncheckMark = ({ size = "default", className }) => {
|
|
8148
8163
|
fill: "currentColor",
|
8149
8164
|
viewBox: "0 0 20 20"
|
8150
8165
|
},
|
8151
|
-
/* @__PURE__ */
|
8166
|
+
/* @__PURE__ */ import_react46.default.createElement(
|
8152
8167
|
"path",
|
8153
8168
|
{
|
8154
8169
|
fillRule: "evenodd",
|
@@ -8158,7 +8173,7 @@ var UncheckMark = ({ size = "default", className }) => {
|
|
8158
8173
|
)
|
8159
8174
|
);
|
8160
8175
|
};
|
8161
|
-
var MenuIcon = () => /* @__PURE__ */
|
8176
|
+
var MenuIcon = () => /* @__PURE__ */ import_react46.default.createElement(
|
8162
8177
|
"svg",
|
8163
8178
|
{
|
8164
8179
|
"aria-label": "Menu Button",
|
@@ -8170,7 +8185,7 @@ var MenuIcon = () => /* @__PURE__ */ import_react45.default.createElement(
|
|
8170
8185
|
height: "1.6em",
|
8171
8186
|
width: "1.6em"
|
8172
8187
|
},
|
8173
|
-
/* @__PURE__ */
|
8188
|
+
/* @__PURE__ */ import_react46.default.createElement(
|
8174
8189
|
"path",
|
8175
8190
|
{
|
8176
8191
|
fillRule: "evenodd",
|
@@ -8207,7 +8222,7 @@ var PasswordStrengthIndicator = ({ strength }) => {
|
|
8207
8222
|
strong: "80%",
|
8208
8223
|
"very-strong": "100%"
|
8209
8224
|
}[currentStrengthLevel];
|
8210
|
-
return /* @__PURE__ */
|
8225
|
+
return /* @__PURE__ */ import_react47.default.createElement("div", { className: "hawa-mt-0.5 hawa-h-2 hawa-w-full hawa-rounded hawa-bg-gray-200" }, /* @__PURE__ */ import_react47.default.createElement(
|
8211
8226
|
"div",
|
8212
8227
|
{
|
8213
8228
|
className: `${strengthColors[currentStrengthLevel]} hawa-h-full hawa-rounded hawa-transition-all hawa-duration-300`,
|
@@ -8219,16 +8234,16 @@ var PasswordInput = ({
|
|
8219
8234
|
hidePopover,
|
8220
8235
|
...props
|
8221
8236
|
}) => {
|
8222
|
-
const [inputValue, setInputValue] = (0,
|
8223
|
-
const [isInputFocused, setIsInputFocused] = (0,
|
8224
|
-
const [currentStr, setCurrentStr] = (0,
|
8225
|
-
const [passwordVisible, setPasswordVisible] = (0,
|
8226
|
-
const [lengthCriteriaMet, setLengthCriteriaMet] = (0,
|
8227
|
-
const [numberCriteriaMet, setNumberCriteriaMet] = (0,
|
8228
|
-
const [specialCharCriteriaMet, setSpecialCharCriteriaMet] = (0,
|
8229
|
-
const [lowercaseCriteriaMet, setLowercaseCriteriaMet] = (0,
|
8230
|
-
const [uppercaseCriteriaMet, setUppercaseCriteriaMet] = (0,
|
8231
|
-
(0,
|
8237
|
+
const [inputValue, setInputValue] = (0, import_react47.useState)("");
|
8238
|
+
const [isInputFocused, setIsInputFocused] = (0, import_react47.useState)(false);
|
8239
|
+
const [currentStr, setCurrentStr] = (0, import_react47.useState)(0);
|
8240
|
+
const [passwordVisible, setPasswordVisible] = (0, import_react47.useState)(false);
|
8241
|
+
const [lengthCriteriaMet, setLengthCriteriaMet] = (0, import_react47.useState)(false);
|
8242
|
+
const [numberCriteriaMet, setNumberCriteriaMet] = (0, import_react47.useState)(false);
|
8243
|
+
const [specialCharCriteriaMet, setSpecialCharCriteriaMet] = (0, import_react47.useState)(false);
|
8244
|
+
const [lowercaseCriteriaMet, setLowercaseCriteriaMet] = (0, import_react47.useState)(false);
|
8245
|
+
const [uppercaseCriteriaMet, setUppercaseCriteriaMet] = (0, import_react47.useState)(false);
|
8246
|
+
(0, import_react47.useEffect)(() => {
|
8232
8247
|
const calculateStrength = () => {
|
8233
8248
|
let strengthScore = 0;
|
8234
8249
|
if (lengthCriteriaMet)
|
@@ -8267,7 +8282,7 @@ var PasswordInput = ({
|
|
8267
8282
|
setIsInputFocused(false);
|
8268
8283
|
};
|
8269
8284
|
const getCriteriaClass = (isMet) => isMet ? "hawa-flex hawa-flex-row hawa-gap-2 hawa-text-sm hawa-items-center hawa-text-green-500" : "hawa-flex hawa-flex-row hawa-gap-2 hawa-text-sm hawa-items-center hawa-text-red-600";
|
8270
|
-
return /* @__PURE__ */
|
8285
|
+
return /* @__PURE__ */ import_react47.default.createElement("div", null, /* @__PURE__ */ import_react47.default.createElement(
|
8271
8286
|
Popover,
|
8272
8287
|
{
|
8273
8288
|
width: "trigger",
|
@@ -8276,7 +8291,7 @@ var PasswordInput = ({
|
|
8276
8291
|
onOpenChange: setIsInputFocused,
|
8277
8292
|
triggerProps: { asChild: true },
|
8278
8293
|
contentProps: { onOpenAutoFocus: (e) => e.preventDefault() },
|
8279
|
-
trigger: /* @__PURE__ */
|
8294
|
+
trigger: /* @__PURE__ */ import_react47.default.createElement(
|
8280
8295
|
"div",
|
8281
8296
|
{
|
8282
8297
|
onClick: (e) => {
|
@@ -8286,7 +8301,7 @@ var PasswordInput = ({
|
|
8286
8301
|
}
|
8287
8302
|
}
|
8288
8303
|
},
|
8289
|
-
/* @__PURE__ */
|
8304
|
+
/* @__PURE__ */ import_react47.default.createElement(
|
8290
8305
|
Input,
|
8291
8306
|
{
|
8292
8307
|
width: "full",
|
@@ -8296,21 +8311,21 @@ var PasswordInput = ({
|
|
8296
8311
|
onFocus: handleInputFocus,
|
8297
8312
|
onBlur: handleInputBlur,
|
8298
8313
|
type: passwordVisible ? "text" : "password",
|
8299
|
-
endIcon: /* @__PURE__ */
|
8314
|
+
endIcon: /* @__PURE__ */ import_react47.default.createElement(
|
8300
8315
|
"div",
|
8301
8316
|
{
|
8302
8317
|
className: "hawa-cursor-pointer",
|
8303
8318
|
onClick: () => setPasswordVisible(!passwordVisible)
|
8304
8319
|
},
|
8305
|
-
passwordVisible ? /* @__PURE__ */
|
8320
|
+
passwordVisible ? /* @__PURE__ */ import_react47.default.createElement(EyeIcon, { className: "hawa-text-gray-500" }) : /* @__PURE__ */ import_react47.default.createElement(HiddenEyeIcon, { className: "hawa-text-gray-500" }),
|
8306
8321
|
" "
|
8307
8322
|
)
|
8308
8323
|
}
|
8309
8324
|
)
|
8310
8325
|
)
|
8311
8326
|
},
|
8312
|
-
/* @__PURE__ */
|
8313
|
-
), /* @__PURE__ */
|
8327
|
+
/* @__PURE__ */ import_react47.default.createElement("div", { className: "hawa-rounded hawa-p-2" }, /* @__PURE__ */ import_react47.default.createElement("ul", { className: "hawa-rounded hawa-p-2" }, /* @__PURE__ */ import_react47.default.createElement("li", { className: getCriteriaClass(lengthCriteriaMet) }, lengthCriteriaMet ? /* @__PURE__ */ import_react47.default.createElement(CheckMark, { size: "sm" }) : /* @__PURE__ */ import_react47.default.createElement(UncheckMark, { size: "sm" }), "At least 8 characters long"), /* @__PURE__ */ import_react47.default.createElement("li", { className: getCriteriaClass(numberCriteriaMet) }, numberCriteriaMet ? /* @__PURE__ */ import_react47.default.createElement(CheckMark, { size: "sm" }) : /* @__PURE__ */ import_react47.default.createElement(UncheckMark, { size: "sm" }), "At least 1 number"), /* @__PURE__ */ import_react47.default.createElement("li", { className: getCriteriaClass(specialCharCriteriaMet) }, specialCharCriteriaMet ? /* @__PURE__ */ import_react47.default.createElement(CheckMark, { size: "sm" }) : /* @__PURE__ */ import_react47.default.createElement(UncheckMark, { size: "sm" }), "At least 1 special character"), /* @__PURE__ */ import_react47.default.createElement("li", { className: getCriteriaClass(lowercaseCriteriaMet) }, lowercaseCriteriaMet ? /* @__PURE__ */ import_react47.default.createElement(CheckMark, { size: "sm" }) : /* @__PURE__ */ import_react47.default.createElement(UncheckMark, { size: "sm" }), "At least 1 lowercase letter"), /* @__PURE__ */ import_react47.default.createElement("li", { className: getCriteriaClass(uppercaseCriteriaMet) }, uppercaseCriteriaMet ? /* @__PURE__ */ import_react47.default.createElement(CheckMark, { size: "sm" }) : /* @__PURE__ */ import_react47.default.createElement(UncheckMark, { size: "sm" }), "At least 1 uppercase letter")))
|
8328
|
+
), /* @__PURE__ */ import_react47.default.createElement(PasswordStrengthIndicator, { strength: currentStr }));
|
8314
8329
|
};
|
8315
8330
|
|
8316
8331
|
// elements/slider/Slider.tsx
|
@@ -8425,12 +8440,12 @@ var Separator2 = ({
|
|
8425
8440
|
);
|
8426
8441
|
|
8427
8442
|
// elements/scrollIndicator/ScrollIndicator.tsx
|
8428
|
-
var
|
8443
|
+
var import_react48 = __toESM(require("react"));
|
8429
8444
|
var ScrollIndicator = ({
|
8430
8445
|
anchor,
|
8431
8446
|
inContainer = false
|
8432
8447
|
}) => {
|
8433
|
-
const [scrollPercentage, setScrollPercentage] = (0,
|
8448
|
+
const [scrollPercentage, setScrollPercentage] = (0, import_react48.useState)(0);
|
8434
8449
|
const onScroll = () => {
|
8435
8450
|
const scrollElement = anchor.current;
|
8436
8451
|
if (scrollElement) {
|
@@ -8441,7 +8456,7 @@ var ScrollIndicator = ({
|
|
8441
8456
|
setScrollPercentage(percentageScrolled);
|
8442
8457
|
}
|
8443
8458
|
};
|
8444
|
-
(0,
|
8459
|
+
(0, import_react48.useEffect)(() => {
|
8445
8460
|
if (!anchor.current)
|
8446
8461
|
return;
|
8447
8462
|
anchor.current.addEventListener("scroll", onScroll);
|
@@ -8450,7 +8465,7 @@ var ScrollIndicator = ({
|
|
8450
8465
|
(_a = anchor.current) == null ? void 0 : _a.removeEventListener("scroll", onScroll);
|
8451
8466
|
};
|
8452
8467
|
}, [anchor]);
|
8453
|
-
return /* @__PURE__ */
|
8468
|
+
return /* @__PURE__ */ import_react48.default.createElement(
|
8454
8469
|
"div",
|
8455
8470
|
{
|
8456
8471
|
style: {
|
@@ -8466,11 +8481,11 @@ var ScrollIndicator = ({
|
|
8466
8481
|
};
|
8467
8482
|
|
8468
8483
|
// elements/codeBlock/CodeBlock.tsx
|
8469
|
-
var
|
8484
|
+
var import_react49 = __toESM(require("react"));
|
8470
8485
|
var import_prism_react_renderer = require("prism-react-renderer");
|
8471
8486
|
(typeof global !== "undefined" ? global : window).Prism = import_prism_react_renderer.Prism;
|
8472
8487
|
require("prismjs/components/prism-bash");
|
8473
|
-
var CopyIcon = () => /* @__PURE__ */
|
8488
|
+
var CopyIcon = () => /* @__PURE__ */ import_react49.default.createElement(
|
8474
8489
|
"svg",
|
8475
8490
|
{
|
8476
8491
|
"aria-label": "Copy",
|
@@ -8483,8 +8498,8 @@ var CopyIcon = () => /* @__PURE__ */ import_react48.default.createElement(
|
|
8483
8498
|
height: "1em",
|
8484
8499
|
width: "1em"
|
8485
8500
|
},
|
8486
|
-
/* @__PURE__ */
|
8487
|
-
/* @__PURE__ */
|
8501
|
+
/* @__PURE__ */ import_react49.default.createElement("rect", { width: "14", height: "14", x: "8", y: "8", rx: "2", ry: "2" }),
|
8502
|
+
/* @__PURE__ */ import_react49.default.createElement("path", { d: "M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2" })
|
8488
8503
|
);
|
8489
8504
|
var CodeBlock = ({
|
8490
8505
|
tabs,
|
@@ -8498,7 +8513,7 @@ var CodeBlock = ({
|
|
8498
8513
|
...props
|
8499
8514
|
}) => {
|
8500
8515
|
const clipboard = useClipboard();
|
8501
|
-
const [selectedTab, setSelectedTab] = (0,
|
8516
|
+
const [selectedTab, setSelectedTab] = (0, import_react49.useState)(0);
|
8502
8517
|
const theme = import_prism_react_renderer.themes.oceanicNext;
|
8503
8518
|
let widthStyles = {
|
8504
8519
|
full: "hawa-w-full",
|
@@ -8506,7 +8521,7 @@ var CodeBlock = ({
|
|
8506
8521
|
sm: "hawa-w-full hawa-max-w-sm",
|
8507
8522
|
xs: "hawa-w-full hawa-max-w-xs"
|
8508
8523
|
};
|
8509
|
-
return /* @__PURE__ */
|
8524
|
+
return /* @__PURE__ */ import_react49.default.createElement(
|
8510
8525
|
"div",
|
8511
8526
|
{
|
8512
8527
|
className: cn(
|
@@ -8515,7 +8530,7 @@ var CodeBlock = ({
|
|
8515
8530
|
classNames == null ? void 0 : classNames.root
|
8516
8531
|
)
|
8517
8532
|
},
|
8518
|
-
fileName && /* @__PURE__ */
|
8533
|
+
fileName && /* @__PURE__ */ import_react49.default.createElement(
|
8519
8534
|
"div",
|
8520
8535
|
{
|
8521
8536
|
className: cn(
|
@@ -8524,7 +8539,7 @@ var CodeBlock = ({
|
|
8524
8539
|
classNames == null ? void 0 : classNames.fileName
|
8525
8540
|
)
|
8526
8541
|
},
|
8527
|
-
/* @__PURE__ */
|
8542
|
+
/* @__PURE__ */ import_react49.default.createElement(
|
8528
8543
|
"div",
|
8529
8544
|
{
|
8530
8545
|
className: cn(
|
@@ -8534,7 +8549,7 @@ var CodeBlock = ({
|
|
8534
8549
|
fileName
|
8535
8550
|
)
|
8536
8551
|
),
|
8537
|
-
tabs && /* @__PURE__ */
|
8552
|
+
tabs && /* @__PURE__ */ import_react49.default.createElement(
|
8538
8553
|
"div",
|
8539
8554
|
{
|
8540
8555
|
className: cn(
|
@@ -8543,7 +8558,7 @@ var CodeBlock = ({
|
|
8543
8558
|
classNames == null ? void 0 : classNames.tabs
|
8544
8559
|
)
|
8545
8560
|
},
|
8546
|
-
tabs.map((tab, i) => /* @__PURE__ */
|
8561
|
+
tabs.map((tab, i) => /* @__PURE__ */ import_react49.default.createElement(
|
8547
8562
|
"div",
|
8548
8563
|
{
|
8549
8564
|
key: i,
|
@@ -8552,7 +8567,7 @@ var CodeBlock = ({
|
|
8552
8567
|
classNames == null ? void 0 : classNames.tab
|
8553
8568
|
)
|
8554
8569
|
},
|
8555
|
-
/* @__PURE__ */
|
8570
|
+
/* @__PURE__ */ import_react49.default.createElement(
|
8556
8571
|
"div",
|
8557
8572
|
{
|
8558
8573
|
onClick: () => setSelectedTab(i),
|
@@ -8564,7 +8579,7 @@ var CodeBlock = ({
|
|
8564
8579
|
)
|
8565
8580
|
))
|
8566
8581
|
),
|
8567
|
-
/* @__PURE__ */
|
8582
|
+
/* @__PURE__ */ import_react49.default.createElement(
|
8568
8583
|
"div",
|
8569
8584
|
{
|
8570
8585
|
className: cn(
|
@@ -8574,22 +8589,22 @@ var CodeBlock = ({
|
|
8574
8589
|
"hawa-overflow-y-auto"
|
8575
8590
|
)
|
8576
8591
|
},
|
8577
|
-
/* @__PURE__ */
|
8592
|
+
/* @__PURE__ */ import_react49.default.createElement(
|
8578
8593
|
"div",
|
8579
8594
|
{
|
8580
8595
|
className: cn(
|
8581
8596
|
"hawa-flex hawa-absolute hawa-w-fit hawa-flex-row hawa-items-center hawa-gap-2 hawa-z-50 hawa-right-3 hawa-top-3"
|
8582
8597
|
)
|
8583
8598
|
},
|
8584
|
-
/* @__PURE__ */
|
8599
|
+
/* @__PURE__ */ import_react49.default.createElement(
|
8585
8600
|
Tooltip,
|
8586
8601
|
{
|
8587
8602
|
open: clipboard.copied,
|
8588
8603
|
side: "left",
|
8589
|
-
content: /* @__PURE__ */
|
8604
|
+
content: /* @__PURE__ */ import_react49.default.createElement("div", null, "Copied!"),
|
8590
8605
|
triggerProps: { asChild: true }
|
8591
8606
|
},
|
8592
|
-
/* @__PURE__ */
|
8607
|
+
/* @__PURE__ */ import_react49.default.createElement(
|
8593
8608
|
Button,
|
8594
8609
|
{
|
8595
8610
|
size: "smallIcon",
|
@@ -8597,18 +8612,18 @@ var CodeBlock = ({
|
|
8597
8612
|
variant: "outline",
|
8598
8613
|
className: "hawa-text-gray-200 hawa-opacity-50 dark:hawa-border-gray-200 dark:hover:hawa-border-gray-400"
|
8599
8614
|
},
|
8600
|
-
/* @__PURE__ */
|
8615
|
+
/* @__PURE__ */ import_react49.default.createElement(CopyIcon, null)
|
8601
8616
|
)
|
8602
8617
|
)
|
8603
8618
|
),
|
8604
|
-
/* @__PURE__ */
|
8619
|
+
/* @__PURE__ */ import_react49.default.createElement(
|
8605
8620
|
import_prism_react_renderer.Highlight,
|
8606
8621
|
{
|
8607
8622
|
theme,
|
8608
8623
|
code: tabs ? tabs[selectedTab].code : code || "",
|
8609
8624
|
language
|
8610
8625
|
},
|
8611
|
-
({ tokens, getLineProps, getTokenProps }) => /* @__PURE__ */
|
8626
|
+
({ tokens, getLineProps, getTokenProps }) => /* @__PURE__ */ import_react49.default.createElement(
|
8612
8627
|
"pre",
|
8613
8628
|
{
|
8614
8629
|
className: cn(
|
@@ -8618,7 +8633,7 @@ var CodeBlock = ({
|
|
8618
8633
|
wrapText && "hawa-text-wrap"
|
8619
8634
|
)
|
8620
8635
|
},
|
8621
|
-
tokens.map((line, i) => /* @__PURE__ */
|
8636
|
+
tokens.map((line, i) => /* @__PURE__ */ import_react49.default.createElement("div", { key: i, ...getLineProps({ line }) }, props.lineNumbers && /* @__PURE__ */ import_react49.default.createElement("span", { className: "hawa-mr-4" }, i + 1), line.map((token, key) => /* @__PURE__ */ import_react49.default.createElement("span", { key, ...getTokenProps({ token }) }))))
|
8622
8637
|
)
|
8623
8638
|
)
|
8624
8639
|
)
|
@@ -8626,7 +8641,7 @@ var CodeBlock = ({
|
|
8626
8641
|
};
|
8627
8642
|
|
8628
8643
|
// elements/carousel/Carousel.tsx
|
8629
|
-
var
|
8644
|
+
var import_react50 = __toESM(require("react"));
|
8630
8645
|
var import_embla_carousel_react2 = __toESM(require("embla-carousel-react"));
|
8631
8646
|
var Carousel = ({
|
8632
8647
|
items,
|
@@ -8642,8 +8657,8 @@ var Carousel = ({
|
|
8642
8657
|
direction,
|
8643
8658
|
loop: autoplay ? true : (options == null ? void 0 : options.loop) || false
|
8644
8659
|
});
|
8645
|
-
const [selectedIndex, setSelectedIndex] = (0,
|
8646
|
-
(0,
|
8660
|
+
const [selectedIndex, setSelectedIndex] = (0, import_react50.useState)(0);
|
8661
|
+
(0, import_react50.useEffect)(() => {
|
8647
8662
|
function selectHandler() {
|
8648
8663
|
const index = emblaApi == null ? void 0 : emblaApi.selectedScrollSnap();
|
8649
8664
|
setSelectedIndex(index || 0);
|
@@ -8653,7 +8668,7 @@ var Carousel = ({
|
|
8653
8668
|
emblaApi == null ? void 0 : emblaApi.off("select", selectHandler);
|
8654
8669
|
};
|
8655
8670
|
}, [emblaApi]);
|
8656
|
-
(0,
|
8671
|
+
(0, import_react50.useEffect)(() => {
|
8657
8672
|
let autoplayTimer;
|
8658
8673
|
if (autoplay && emblaApi) {
|
8659
8674
|
autoplayTimer = setInterval(() => {
|
@@ -8665,17 +8680,17 @@ var Carousel = ({
|
|
8665
8680
|
clearInterval(autoplayTimer);
|
8666
8681
|
};
|
8667
8682
|
}, [emblaApi, autoplay, autoplayInterval]);
|
8668
|
-
const length =
|
8683
|
+
const length = import_react50.default.Children.count(items);
|
8669
8684
|
const canScrollNext = !!(emblaApi == null ? void 0 : emblaApi.canScrollNext());
|
8670
8685
|
const canScrollPrev = !!(emblaApi == null ? void 0 : emblaApi.canScrollPrev());
|
8671
|
-
return /* @__PURE__ */
|
8686
|
+
return /* @__PURE__ */ import_react50.default.createElement("div", { className: " hawa-relative hawa-h-full" }, /* @__PURE__ */ import_react50.default.createElement("div", { className: "hawa-h-full hawa-overflow-hidden" }, /* @__PURE__ */ import_react50.default.createElement("div", { className: "hawa-h-full", ref: emblaRef }, /* @__PURE__ */ import_react50.default.createElement("div", { className: "hawa-flex hawa-h-full" }, items == null ? void 0 : items.map((item, i) => /* @__PURE__ */ import_react50.default.createElement(
|
8672
8687
|
"div",
|
8673
8688
|
{
|
8674
8689
|
key: i,
|
8675
8690
|
className: "hawa-flex hawa-h-full hawa-min-w-0 hawa-flex-[0_0_100%] hawa-items-center hawa-justify-center"
|
8676
8691
|
},
|
8677
8692
|
item
|
8678
|
-
))))), /* @__PURE__ */
|
8693
|
+
))))), /* @__PURE__ */ import_react50.default.createElement(
|
8679
8694
|
Dots,
|
8680
8695
|
{
|
8681
8696
|
direction,
|
@@ -8683,7 +8698,7 @@ var Carousel = ({
|
|
8683
8698
|
selectedIndex,
|
8684
8699
|
onDotClick: (index) => emblaApi == null ? void 0 : emblaApi.scrollTo(index)
|
8685
8700
|
}
|
8686
|
-
), showArrows && /* @__PURE__ */
|
8701
|
+
), showArrows && /* @__PURE__ */ import_react50.default.createElement(
|
8687
8702
|
CarouselControls,
|
8688
8703
|
{
|
8689
8704
|
canScrollNext,
|
@@ -8700,7 +8715,7 @@ var Dots = ({
|
|
8700
8715
|
direction
|
8701
8716
|
}) => {
|
8702
8717
|
const arr = new Array(itemsLength).fill(0);
|
8703
|
-
return /* @__PURE__ */
|
8718
|
+
return /* @__PURE__ */ import_react50.default.createElement(
|
8704
8719
|
"div",
|
8705
8720
|
{
|
8706
8721
|
dir: direction,
|
@@ -8708,7 +8723,7 @@ var Dots = ({
|
|
8708
8723
|
},
|
8709
8724
|
arr.map((_, index) => {
|
8710
8725
|
const selected = index === selectedIndex;
|
8711
|
-
return /* @__PURE__ */
|
8726
|
+
return /* @__PURE__ */ import_react50.default.createElement(
|
8712
8727
|
"div",
|
8713
8728
|
{
|
8714
8729
|
key: index,
|
@@ -8723,7 +8738,7 @@ var Dots = ({
|
|
8723
8738
|
);
|
8724
8739
|
};
|
8725
8740
|
var CarouselControls = (props) => {
|
8726
|
-
return /* @__PURE__ */
|
8741
|
+
return /* @__PURE__ */ import_react50.default.createElement("div", { className: "hawa-flex hawa-justify-end hawa-gap-2 " }, /* @__PURE__ */ import_react50.default.createElement(
|
8727
8742
|
"button",
|
8728
8743
|
{
|
8729
8744
|
onClick: () => props.canScrollPrev && props.onPrev(),
|
@@ -8734,7 +8749,7 @@ var CarouselControls = (props) => {
|
|
8734
8749
|
props.canScrollPrev && "hawa-bg-primary"
|
8735
8750
|
)
|
8736
8751
|
},
|
8737
|
-
/* @__PURE__ */
|
8752
|
+
/* @__PURE__ */ import_react50.default.createElement(
|
8738
8753
|
"svg",
|
8739
8754
|
{
|
8740
8755
|
"aria-label": "Chevron Right Icon",
|
@@ -8743,9 +8758,9 @@ var CarouselControls = (props) => {
|
|
8743
8758
|
viewBox: "0 0 16 16",
|
8744
8759
|
className: "hawa-h-2 hawa-w-2 hawa-shrink-0 hawa-rotate-180 hawa-transition-transform hawa-duration-200 "
|
8745
8760
|
},
|
8746
|
-
/* @__PURE__ */
|
8761
|
+
/* @__PURE__ */ import_react50.default.createElement("path", { d: "M4.646 1.646a.5.5 0 0 1 .708 0l6 6a.5.5 0 0 1 0 .708l-6 6a.5.5 0 0 1-.708-.708L10.293 8 4.646 2.354a.5.5 0 0 1 0-.708z" })
|
8747
8762
|
)
|
8748
|
-
), /* @__PURE__ */
|
8763
|
+
), /* @__PURE__ */ import_react50.default.createElement(
|
8749
8764
|
"button",
|
8750
8765
|
{
|
8751
8766
|
onClick: () => props.canScrollNext && props.onNext(),
|
@@ -8756,7 +8771,7 @@ var CarouselControls = (props) => {
|
|
8756
8771
|
props.canScrollNext && "hawa-bg-primary"
|
8757
8772
|
)
|
8758
8773
|
},
|
8759
|
-
/* @__PURE__ */
|
8774
|
+
/* @__PURE__ */ import_react50.default.createElement(
|
8760
8775
|
"svg",
|
8761
8776
|
{
|
8762
8777
|
"aria-label": "Chevron Right Icon",
|
@@ -8765,15 +8780,15 @@ var CarouselControls = (props) => {
|
|
8765
8780
|
viewBox: "0 0 16 16",
|
8766
8781
|
className: "hawa-h-2 hawa-w-2 hawa-shrink-0 hawa-transition-transform hawa-duration-200 "
|
8767
8782
|
},
|
8768
|
-
/* @__PURE__ */
|
8783
|
+
/* @__PURE__ */ import_react50.default.createElement("path", { d: "M4.646 1.646a.5.5 0 0 1 .708 0l6 6a.5.5 0 0 1 0 .708l-6 6a.5.5 0 0 1-.708-.708L10.293 8 4.646 2.354a.5.5 0 0 1 0-.708z" })
|
8769
8784
|
)
|
8770
8785
|
));
|
8771
8786
|
};
|
8772
8787
|
|
8773
8788
|
// elements/count/Count.tsx
|
8774
|
-
var
|
8789
|
+
var import_react51 = __toESM(require("react"));
|
8775
8790
|
var Count = (props) => {
|
8776
|
-
return /* @__PURE__ */
|
8791
|
+
return /* @__PURE__ */ import_react51.default.createElement("div", { className: "hawa-flex hawa-h-fit hawa-flex-row hawa-items-center hawa-gap-2 hawa-px-2" }, /* @__PURE__ */ import_react51.default.createElement("div", null, props.icon), /* @__PURE__ */ import_react51.default.createElement("div", { className: "hawa-text-sm" }, props.count));
|
8777
8792
|
};
|
8778
8793
|
|
8779
8794
|
// elements/toast/Toast.tsx
|
@@ -8914,11 +8929,11 @@ var ToastDescription = React67.forwardRef(({ className, size = "default", ...pro
|
|
8914
8929
|
ToastDescription.displayName = ToastPrimitives.Description.displayName;
|
8915
8930
|
|
8916
8931
|
// elements/toaster/Toaster.tsx
|
8917
|
-
var
|
8932
|
+
var import_react52 = __toESM(require("react"));
|
8918
8933
|
function Toaster(props) {
|
8919
8934
|
var _a;
|
8920
8935
|
let isRTL = props.direction === "rtl";
|
8921
|
-
return /* @__PURE__ */
|
8936
|
+
return /* @__PURE__ */ import_react52.default.createElement(ToastProvider, { swipeDirection: isRTL ? "left" : "right" }, (_a = props.toasts) == null ? void 0 : _a.map(function({
|
8922
8937
|
id,
|
8923
8938
|
title,
|
8924
8939
|
description,
|
@@ -8926,7 +8941,7 @@ function Toaster(props) {
|
|
8926
8941
|
action,
|
8927
8942
|
...toastProps
|
8928
8943
|
}) {
|
8929
|
-
return /* @__PURE__ */
|
8944
|
+
return /* @__PURE__ */ import_react52.default.createElement(Toast, { direction: props.direction, key: id, ...toastProps }, /* @__PURE__ */ import_react52.default.createElement(
|
8930
8945
|
"div",
|
8931
8946
|
{
|
8932
8947
|
className: cn(
|
@@ -8934,9 +8949,9 @@ function Toaster(props) {
|
|
8934
8949
|
action && "hawa-justify-between"
|
8935
8950
|
)
|
8936
8951
|
},
|
8937
|
-
/* @__PURE__ */
|
8938
|
-
/* @__PURE__ */
|
8939
|
-
/* @__PURE__ */
|
8952
|
+
/* @__PURE__ */ import_react52.default.createElement("div", { className: "hawa-flex hawa-h-full hawa-flex-col hawa-p-2 hawa-pe-0" }, /* @__PURE__ */ import_react52.default.createElement(ToastClose, null)),
|
8953
|
+
/* @__PURE__ */ import_react52.default.createElement("div", { className: "hawa-mx-0 hawa-h-auto hawa-max-h-full hawa-w-px hawa-bg-primary-foreground/10" }),
|
8954
|
+
/* @__PURE__ */ import_react52.default.createElement(
|
8940
8955
|
"div",
|
8941
8956
|
{
|
8942
8957
|
className: cn(
|
@@ -8944,11 +8959,11 @@ function Toaster(props) {
|
|
8944
8959
|
{ "hawa-p-4": size === "default", "hawa-p-2": size === "sm" }
|
8945
8960
|
)
|
8946
8961
|
},
|
8947
|
-
/* @__PURE__ */
|
8948
|
-
action && /* @__PURE__ */
|
8962
|
+
/* @__PURE__ */ import_react52.default.createElement("div", { className: "hawa-grid hawa-gap-1 hawa-text-start" }, title && /* @__PURE__ */ import_react52.default.createElement(ToastTitle, { size }, title), description && /* @__PURE__ */ import_react52.default.createElement(ToastDescription, { size }, description)),
|
8963
|
+
action && /* @__PURE__ */ import_react52.default.createElement("div", { className: "hawa-flex hawa-flex-col hawa-justify-center" }, action)
|
8949
8964
|
)
|
8950
8965
|
));
|
8951
|
-
}), /* @__PURE__ */
|
8966
|
+
}), /* @__PURE__ */ import_react52.default.createElement(
|
8952
8967
|
ToastViewport,
|
8953
8968
|
{
|
8954
8969
|
className: cn("hawa-gap-2", isRTL && "hawa-fixed hawa-left-0")
|
@@ -8957,20 +8972,20 @@ function Toaster(props) {
|
|
8957
8972
|
}
|
8958
8973
|
|
8959
8974
|
// elements/destroyableCard/DestroyableCard.tsx
|
8960
|
-
var
|
8975
|
+
var import_react53 = __toESM(require("react"));
|
8961
8976
|
var DestroyableCard = ({
|
8962
8977
|
position = "bottom-right",
|
8963
8978
|
fixed,
|
8964
8979
|
direction,
|
8965
8980
|
...props
|
8966
8981
|
}) => {
|
8967
|
-
const [closed, setClosed] = (0,
|
8968
|
-
const popUpRef = (0,
|
8982
|
+
const [closed, setClosed] = (0, import_react53.useState)(false);
|
8983
|
+
const popUpRef = (0, import_react53.useRef)(null);
|
8969
8984
|
const boxPosition = {
|
8970
8985
|
"bottom-right": "hawa-right-4 hawa-bottom-4",
|
8971
8986
|
"bottom-left": "hawa-left-4 hawa-bottom-4"
|
8972
8987
|
};
|
8973
|
-
return /* @__PURE__ */
|
8988
|
+
return /* @__PURE__ */ import_react53.default.createElement(
|
8974
8989
|
"div",
|
8975
8990
|
{
|
8976
8991
|
className: cn(
|
@@ -8979,7 +8994,7 @@ var DestroyableCard = ({
|
|
8979
8994
|
),
|
8980
8995
|
ref: popUpRef
|
8981
8996
|
},
|
8982
|
-
/* @__PURE__ */
|
8997
|
+
/* @__PURE__ */ import_react53.default.createElement(
|
8983
8998
|
Card,
|
8984
8999
|
{
|
8985
9000
|
className: cn(
|
@@ -8988,7 +9003,7 @@ var DestroyableCard = ({
|
|
8988
9003
|
),
|
8989
9004
|
dir: direction
|
8990
9005
|
},
|
8991
|
-
/* @__PURE__ */
|
9006
|
+
/* @__PURE__ */ import_react53.default.createElement(
|
8992
9007
|
"button",
|
8993
9008
|
{
|
8994
9009
|
type: "button",
|
@@ -9007,7 +9022,7 @@ var DestroyableCard = ({
|
|
9007
9022
|
}, 200);
|
9008
9023
|
}
|
9009
9024
|
},
|
9010
|
-
/* @__PURE__ */
|
9025
|
+
/* @__PURE__ */ import_react53.default.createElement(
|
9011
9026
|
"svg",
|
9012
9027
|
{
|
9013
9028
|
"aria-hidden": "true",
|
@@ -9015,7 +9030,7 @@ var DestroyableCard = ({
|
|
9015
9030
|
fill: "currentColor",
|
9016
9031
|
viewBox: "0 0 20 20"
|
9017
9032
|
},
|
9018
|
-
/* @__PURE__ */
|
9033
|
+
/* @__PURE__ */ import_react53.default.createElement(
|
9019
9034
|
"path",
|
9020
9035
|
{
|
9021
9036
|
fillRule: "evenodd",
|
@@ -9025,13 +9040,13 @@ var DestroyableCard = ({
|
|
9025
9040
|
)
|
9026
9041
|
)
|
9027
9042
|
),
|
9028
|
-
/* @__PURE__ */
|
9043
|
+
/* @__PURE__ */ import_react53.default.createElement(CardContent, { headless: true }, props.children)
|
9029
9044
|
)
|
9030
9045
|
);
|
9031
9046
|
};
|
9032
9047
|
|
9033
9048
|
// elements/interfaceSettings/InterfaceSettings.tsx
|
9034
|
-
var
|
9049
|
+
var import_react54 = __toESM(require("react"));
|
9035
9050
|
var InterfaceSettings = ({
|
9036
9051
|
orientation = "horizontal",
|
9037
9052
|
width = "default",
|
@@ -9039,13 +9054,13 @@ var InterfaceSettings = ({
|
|
9039
9054
|
handleLanguage,
|
9040
9055
|
...props
|
9041
9056
|
}) => {
|
9042
|
-
const [color, setColor] = (0,
|
9043
|
-
const [language, setLanguage] = (0,
|
9057
|
+
const [color, setColor] = (0, import_react54.useState)(props.currentColorMode);
|
9058
|
+
const [language, setLanguage] = (0, import_react54.useState)(props.currentLanguage);
|
9044
9059
|
let orientationStyle = {
|
9045
9060
|
horizontal: "hawa-flex hawa-flex-row hawa-justify-between",
|
9046
9061
|
vertical: "hawa-flex hawa-flex-col hawa-items-center hawa-gap-2"
|
9047
9062
|
};
|
9048
|
-
return /* @__PURE__ */
|
9063
|
+
return /* @__PURE__ */ import_react54.default.createElement("div", { className: cn(orientationStyle[orientation]) }, /* @__PURE__ */ import_react54.default.createElement(
|
9049
9064
|
Radio,
|
9050
9065
|
{
|
9051
9066
|
name: "language",
|
@@ -9063,7 +9078,7 @@ var InterfaceSettings = ({
|
|
9063
9078
|
{ value: "en", label: "English" }
|
9064
9079
|
]
|
9065
9080
|
}
|
9066
|
-
), /* @__PURE__ */
|
9081
|
+
), /* @__PURE__ */ import_react54.default.createElement(
|
9067
9082
|
Radio,
|
9068
9083
|
{
|
9069
9084
|
name: "theme",
|
@@ -9079,7 +9094,7 @@ var InterfaceSettings = ({
|
|
9079
9094
|
options: [
|
9080
9095
|
{
|
9081
9096
|
value: "light",
|
9082
|
-
label: /* @__PURE__ */
|
9097
|
+
label: /* @__PURE__ */ import_react54.default.createElement(
|
9083
9098
|
"svg",
|
9084
9099
|
{
|
9085
9100
|
width: "15",
|
@@ -9089,7 +9104,7 @@ var InterfaceSettings = ({
|
|
9089
9104
|
xmlns: "http://www.w3.org/2000/svg",
|
9090
9105
|
className: "hawa-h-[1.2rem] hawa-w-[1.2rem] hawa-rotate-0 hawa-scale-100 hawa-transition-all dark:hawa--rotate-90"
|
9091
9106
|
},
|
9092
|
-
/* @__PURE__ */
|
9107
|
+
/* @__PURE__ */ import_react54.default.createElement(
|
9093
9108
|
"path",
|
9094
9109
|
{
|
9095
9110
|
d: "M7.5 0C7.77614 0 8 0.223858 8 0.5V2.5C8 2.77614 7.77614 3 7.5 3C7.22386 3 7 2.77614 7 2.5V0.5C7 0.223858 7.22386 0 7.5 0ZM2.1967 2.1967C2.39196 2.00144 2.70854 2.00144 2.90381 2.1967L4.31802 3.61091C4.51328 3.80617 4.51328 4.12276 4.31802 4.31802C4.12276 4.51328 3.80617 4.51328 3.61091 4.31802L2.1967 2.90381C2.00144 2.70854 2.00144 2.39196 2.1967 2.1967ZM0.5 7C0.223858 7 0 7.22386 0 7.5C0 7.77614 0.223858 8 0.5 8H2.5C2.77614 8 3 7.77614 3 7.5C3 7.22386 2.77614 7 2.5 7H0.5ZM2.1967 12.8033C2.00144 12.608 2.00144 12.2915 2.1967 12.0962L3.61091 10.682C3.80617 10.4867 4.12276 10.4867 4.31802 10.682C4.51328 10.8772 4.51328 11.1938 4.31802 11.3891L2.90381 12.8033C2.70854 12.9986 2.39196 12.9986 2.1967 12.8033ZM12.5 7C12.2239 7 12 7.22386 12 7.5C12 7.77614 12.2239 8 12.5 8H14.5C14.7761 8 15 7.77614 15 7.5C15 7.22386 14.7761 7 14.5 7H12.5ZM10.682 4.31802C10.4867 4.12276 10.4867 3.80617 10.682 3.61091L12.0962 2.1967C12.2915 2.00144 12.608 2.00144 12.8033 2.1967C12.9986 2.39196 12.9986 2.70854 12.8033 2.90381L11.3891 4.31802C11.1938 4.51328 10.8772 4.51328 10.682 4.31802ZM8 12.5C8 12.2239 7.77614 12 7.5 12C7.22386 12 7 12.2239 7 12.5V14.5C7 14.7761 7.22386 15 7.5 15C7.77614 15 8 14.7761 8 14.5V12.5ZM10.682 10.682C10.8772 10.4867 11.1938 10.4867 11.3891 10.682L12.8033 12.0962C12.9986 12.2915 12.9986 12.608 12.8033 12.8033C12.608 12.9986 12.2915 12.9986 12.0962 12.8033L10.682 11.3891C10.4867 11.1938 10.4867 10.8772 10.682 10.682ZM5.5 7.5C5.5 6.39543 6.39543 5.5 7.5 5.5C8.60457 5.5 9.5 6.39543 9.5 7.5C9.5 8.60457 8.60457 9.5 7.5 9.5C6.39543 9.5 5.5 8.60457 5.5 7.5ZM7.5 4.5C5.84315 4.5 4.5 5.84315 4.5 7.5C4.5 9.15685 5.84315 10.5 7.5 10.5C9.15685 10.5 10.5 9.15685 10.5 7.5C10.5 5.84315 9.15685 4.5 7.5 4.5Z",
|
@@ -9100,7 +9115,7 @@ var InterfaceSettings = ({
|
|
9100
9115
|
},
|
9101
9116
|
{
|
9102
9117
|
value: "dark",
|
9103
|
-
label: /* @__PURE__ */
|
9118
|
+
label: /* @__PURE__ */ import_react54.default.createElement(
|
9104
9119
|
"svg",
|
9105
9120
|
{
|
9106
9121
|
xmlns: "http://www.w3.org/2000/svg",
|
@@ -9111,7 +9126,7 @@ var InterfaceSettings = ({
|
|
9111
9126
|
stroke: "currentColor",
|
9112
9127
|
className: "hawa-h-[1.2rem] hawa-w-[1.2rem] hawa-transition-all dark:hawa-rotate-0 dark:hawa-scale-100"
|
9113
9128
|
},
|
9114
|
-
/* @__PURE__ */
|
9129
|
+
/* @__PURE__ */ import_react54.default.createElement("path", { d: "M12 3a6 6 0 0 0 9 9 9 9 0 1 1-9-9Z" })
|
9115
9130
|
)
|
9116
9131
|
}
|
9117
9132
|
]
|
@@ -9120,17 +9135,17 @@ var InterfaceSettings = ({
|
|
9120
9135
|
};
|
9121
9136
|
|
9122
9137
|
// elements/phoneMockup/PhoneMockup.tsx
|
9123
|
-
var
|
9138
|
+
var import_react55 = __toESM(require("react"));
|
9124
9139
|
var PhoneMockup = ({
|
9125
9140
|
children,
|
9126
9141
|
upperOverlayGradiant,
|
9127
9142
|
lowerOverlayGradiant,
|
9128
9143
|
phone,
|
9129
9144
|
hideButtons
|
9130
|
-
}) => /* @__PURE__ */
|
9145
|
+
}) => /* @__PURE__ */ import_react55.default.createElement("div", { className: "hawa-relative hawa-mx-auto hawa-h-[600px] hawa-w-[300px] hawa-rounded-[2.5rem] hawa-border-[14px] hawa-border-gray-800 hawa-bg-gray-800 hawa-dark:border-gray-800" }, !hideButtons && /* @__PURE__ */ import_react55.default.createElement(import_react55.default.Fragment, null, /* @__PURE__ */ import_react55.default.createElement("div", { className: "hawa-absolute hawa--left-[16px] hawa-top-[72px] hawa-h-[32px] hawa-w-[3px] hawa-rounded-l-lg hawa-bg-gray-800 hawa-dark:bg-gray-800" }), /* @__PURE__ */ import_react55.default.createElement("div", { className: "hawa-absolute hawa--left-[16px] hawa-top-[124px] hawa-h-[46px] hawa-w-[3px] hawa-rounded-l-lg hawa-bg-gray-800 hawa-dark:bg-gray-800" }), /* @__PURE__ */ import_react55.default.createElement("div", { className: "hawa-absolute hawa--left-[16px] hawa-top-[178px] hawa-h-[46px] hawa-w-[3px] hawa-rounded-l-lg hawa-bg-gray-800 hawa-dark:bg-gray-800" }), /* @__PURE__ */ import_react55.default.createElement("div", { className: "hawa-absolute hawa--right-[16px] hawa-top-[142px] hawa-h-[64px] hawa-w-[3px] hawa-rounded-r-lg hawa-bg-gray-800 hawa-dark:bg-gray-800" })), /* @__PURE__ */ import_react55.default.createElement("div", { className: "no-scrollbar hawa-left-0 hawa-h-[572px] hawa-w-[272px] hawa-overflow-y-scroll hawa-rounded-[2rem] hawa-bg-white hawa-[clip-path:inset(0px_-1px_0px_0px_round_2rem)] hawa-dark:bg-gray-800" }, children), upperOverlayGradiant && /* @__PURE__ */ import_react55.default.createElement("div", { className: "hawa-pointer-events-none hawa-absolute hawa-left-0 hawa-top-0 hawa-h-[72px] hawa-w-[272px] hawa-rounded-t-[2rem] hawa-bg-gradient-to-t hawa-from-transparent hawa-to-black hawa-opacity-50 hawa-[clip-path:inset(0px_0px_0px_0px_round_0rem)]" }), lowerOverlayGradiant && /* @__PURE__ */ import_react55.default.createElement("div", { className: "hawa-pointer-events-none hawa-absolute hawa-bottom-0 hawa-left-0 hawa-h-[72px] hawa-w-[272px] hawa-rounded-b-[2rem] hawa-bg-gradient-to-t hawa-from-black hawa-to-transparent hawa-opacity-50 hawa-[clip-path:inset(0px_0px_0px_0px_round_0rem)]" }));
|
9131
9146
|
|
9132
9147
|
// layout/stats/Stats.tsx
|
9133
|
-
var
|
9148
|
+
var import_react56 = __toESM(require("react"));
|
9134
9149
|
var Stats = ({
|
9135
9150
|
label,
|
9136
9151
|
icon,
|
@@ -9149,7 +9164,7 @@ var Stats = ({
|
|
9149
9164
|
negative: "hawa-text-red-600 dark:hawa-text-red-500",
|
9150
9165
|
muted: "hawa-text-muted-foreground"
|
9151
9166
|
};
|
9152
|
-
return /* @__PURE__ */
|
9167
|
+
return /* @__PURE__ */ import_react56.default.createElement(Card, { ...props, clickable }, /* @__PURE__ */ import_react56.default.createElement("div", { className: "hawa-flex hawa-flex-row hawa-items-center hawa-justify-between hawa-p-4 hawa-px-6" }, /* @__PURE__ */ import_react56.default.createElement(CardTitle, { className: "hawa-text-sm hawa-font-medium" }, label), icon && /* @__PURE__ */ import_react56.default.createElement("span", null, icon)), /* @__PURE__ */ import_react56.default.createElement(CardContent, { className: "hawa-transition-all" }, isLoading ? /* @__PURE__ */ import_react56.default.createElement(Skeleton, { className: "hawa-h-8 hawa-w-3/4" }) : /* @__PURE__ */ import_react56.default.createElement("div", { className: "hawa-text-2xl hawa-font-bold" }, number), helperText && /* @__PURE__ */ import_react56.default.createElement(
|
9153
9168
|
"div",
|
9154
9169
|
{
|
9155
9170
|
className: cn(
|
@@ -9158,8 +9173,8 @@ var Stats = ({
|
|
9158
9173
|
helperText ? "hawa-h-4 hawa-opacity-100" : "hawa-h-0 hawa-opacity-0"
|
9159
9174
|
)
|
9160
9175
|
},
|
9161
|
-
isLoading ? /* @__PURE__ */
|
9162
|
-
), chart && (isLoading ? /* @__PURE__ */
|
9176
|
+
isLoading ? /* @__PURE__ */ import_react56.default.createElement(Skeleton, { className: "hawa-mt-2 hawa-h-4 hawa-w-1/2" }) : helperText
|
9177
|
+
), chart && (isLoading ? /* @__PURE__ */ import_react56.default.createElement(Skeleton, { className: "hawa-mt-2 hawa-h-4 hawa-w-1/2" }) : chart)));
|
9163
9178
|
};
|
9164
9179
|
|
9165
9180
|
// layout/sidebar/Sidebar.tsx
|
@@ -9375,13 +9390,13 @@ var SidebarItem = ({
|
|
9375
9390
|
};
|
9376
9391
|
|
9377
9392
|
// layout/copyrights/Copyrights.tsx
|
9378
|
-
var
|
9393
|
+
var import_react57 = __toESM(require("react"));
|
9379
9394
|
var Copyrights = (props) => {
|
9380
|
-
return /* @__PURE__ */
|
9395
|
+
return /* @__PURE__ */ import_react57.default.createElement("div", { className: "hawa-my-2 hawa-flex hawa-flex-col hawa-items-center hawa-justify-center hawa-gap-1 hawa-text-xs hawa-text-gray-400" }, props.withLogo ? /* @__PURE__ */ import_react57.default.createElement("a", { href: props.onLogoClicked }, /* @__PURE__ */ import_react57.default.createElement("div", { className: "hawa-cursor-pointer" }, /* @__PURE__ */ import_react57.default.createElement("image", { href: props.logoURL, width: 100, height: 50 }))) : null, /* @__PURE__ */ import_react57.default.createElement("div", null, props.version), props.credits ? props.credits : null);
|
9381
9396
|
};
|
9382
9397
|
|
9383
9398
|
// layout/navbar/Navbar.tsx
|
9384
|
-
var
|
9399
|
+
var import_react58 = __toESM(require("react"));
|
9385
9400
|
|
9386
9401
|
// elements/collapsible/Collapsible.tsx
|
9387
9402
|
var CollapsiblePrimitive = __toESM(require("@radix-ui/react-collapsible"));
|
@@ -9397,14 +9412,14 @@ var Navbar = ({
|
|
9397
9412
|
...props
|
9398
9413
|
}) => {
|
9399
9414
|
var _a, _b;
|
9400
|
-
const [isOpen, setIsOpen] = (0,
|
9401
|
-
return /* @__PURE__ */
|
9415
|
+
const [isOpen, setIsOpen] = (0, import_react58.useState)(false);
|
9416
|
+
return /* @__PURE__ */ import_react58.default.createElement("nav", { className: " hawa-sticky hawa-top-2 hawa-transition-all" }, /* @__PURE__ */ import_react58.default.createElement(
|
9402
9417
|
Collapsible,
|
9403
9418
|
{
|
9404
9419
|
className: "hawa-relative hawa-m-2 hawa-rounded hawa-p-2",
|
9405
9420
|
style: { backgroundColor: backgroundColor || "#1f2937" }
|
9406
9421
|
},
|
9407
|
-
/* @__PURE__ */
|
9422
|
+
/* @__PURE__ */ import_react58.default.createElement("div", { className: "hawa-flex hawa-items-center hawa-justify-between hawa-px-3 " }, /* @__PURE__ */ import_react58.default.createElement("div", { className: "hawa-flex hawa-items-center" }, /* @__PURE__ */ import_react58.default.createElement(
|
9408
9423
|
"div",
|
9409
9424
|
{
|
9410
9425
|
className: "hawa-p-1.5 hawa-text-xl hawa-font-bold hawa-text-white",
|
@@ -9415,7 +9430,7 @@ var Navbar = ({
|
|
9415
9430
|
}
|
9416
9431
|
},
|
9417
9432
|
logo
|
9418
|
-
)), /* @__PURE__ */
|
9433
|
+
)), /* @__PURE__ */ import_react58.default.createElement("div", { className: "hawa-hidden md:hawa-flex " }, (_a = props.menuItems) == null ? void 0 : _a.map((item, i) => /* @__PURE__ */ import_react58.default.createElement(
|
9419
9434
|
"div",
|
9420
9435
|
{
|
9421
9436
|
key: i,
|
@@ -9423,14 +9438,14 @@ var Navbar = ({
|
|
9423
9438
|
className: "hawa-cursor-pointer hawa-rounded hawa-p-1.5 hawa-px-2 hawa-text-center hawa-text-sm hawa-text-white hawa-transition-all hover:hawa-bg-gray-300 hover:hawa-text-black"
|
9424
9439
|
},
|
9425
9440
|
item.label
|
9426
|
-
))), /* @__PURE__ */
|
9441
|
+
))), /* @__PURE__ */ import_react58.default.createElement("div", { className: "hawa-m-0 hawa-flex hawa-h-fit hawa-p-0 md:hawa-hidden" }, /* @__PURE__ */ import_react58.default.createElement(
|
9427
9442
|
CollapsibleTrigger2,
|
9428
9443
|
{
|
9429
9444
|
onClick: () => setIsOpen(!isOpen),
|
9430
9445
|
className: "hawa-h-full hawa-text-white selection:hawa-p-0 ",
|
9431
9446
|
"aria-label": "Toggle menu"
|
9432
9447
|
},
|
9433
|
-
/* @__PURE__ */
|
9448
|
+
/* @__PURE__ */ import_react58.default.createElement(
|
9434
9449
|
"svg",
|
9435
9450
|
{
|
9436
9451
|
xmlns: "http://www.w3.org/2000/svg",
|
@@ -9447,11 +9462,11 @@ var Navbar = ({
|
|
9447
9462
|
isOpen ? "hawa-invisible" : "hawa-visible"
|
9448
9463
|
)
|
9449
9464
|
},
|
9450
|
-
/* @__PURE__ */
|
9451
|
-
/* @__PURE__ */
|
9452
|
-
/* @__PURE__ */
|
9465
|
+
/* @__PURE__ */ import_react58.default.createElement("line", { x1: "4", x2: "20", y1: "12", y2: "12" }),
|
9466
|
+
/* @__PURE__ */ import_react58.default.createElement("line", { x1: "4", x2: "20", y1: "6", y2: "6" }),
|
9467
|
+
/* @__PURE__ */ import_react58.default.createElement("line", { x1: "4", x2: "20", y1: "18", y2: "18" })
|
9453
9468
|
),
|
9454
|
-
/* @__PURE__ */
|
9469
|
+
/* @__PURE__ */ import_react58.default.createElement(
|
9455
9470
|
"svg",
|
9456
9471
|
{
|
9457
9472
|
xmlns: "http://www.w3.org/2000/svg",
|
@@ -9468,11 +9483,11 @@ var Navbar = ({
|
|
9468
9483
|
!isOpen ? "hawa-invisible" : "hawa-visible"
|
9469
9484
|
)
|
9470
9485
|
},
|
9471
|
-
/* @__PURE__ */
|
9472
|
-
/* @__PURE__ */
|
9486
|
+
/* @__PURE__ */ import_react58.default.createElement("path", { d: "M18 6 6 18" }),
|
9487
|
+
/* @__PURE__ */ import_react58.default.createElement("path", { d: "m6 6 12 12" })
|
9473
9488
|
)
|
9474
9489
|
))),
|
9475
|
-
/* @__PURE__ */
|
9490
|
+
/* @__PURE__ */ import_react58.default.createElement(
|
9476
9491
|
CollapsibleContent2,
|
9477
9492
|
{
|
9478
9493
|
className: cn(
|
@@ -9487,7 +9502,7 @@ var Navbar = ({
|
|
9487
9502
|
zIndex: -100
|
9488
9503
|
}
|
9489
9504
|
},
|
9490
|
-
(_b = props.menuItems) == null ? void 0 : _b.map((item, i) => /* @__PURE__ */
|
9505
|
+
(_b = props.menuItems) == null ? void 0 : _b.map((item, i) => /* @__PURE__ */ import_react58.default.createElement(
|
9491
9506
|
"div",
|
9492
9507
|
{
|
9493
9508
|
key: i,
|
@@ -9501,7 +9516,7 @@ var Navbar = ({
|
|
9501
9516
|
};
|
9502
9517
|
|
9503
9518
|
// layout/appLayout/AppLayout.tsx
|
9504
|
-
var
|
9519
|
+
var import_react59 = __toESM(require("react"));
|
9505
9520
|
var Dialog3 = __toESM(require("@radix-ui/react-dialog"));
|
9506
9521
|
var LOCAL_STORAGE_KEY2 = "@sikka/hawa/keep-drawer-open";
|
9507
9522
|
var AppLayout = ({
|
@@ -9520,7 +9535,7 @@ var AppLayout = ({
|
|
9520
9535
|
...props
|
9521
9536
|
}) => {
|
9522
9537
|
var _a, _b;
|
9523
|
-
(0,
|
9538
|
+
(0, import_react59.useEffect)(() => {
|
9524
9539
|
let isDrawerOpen = localStorage.getItem(LOCAL_STORAGE_KEY2);
|
9525
9540
|
if (isDrawerOpen === null) {
|
9526
9541
|
localStorage.setItem(LOCAL_STORAGE_KEY2, JSON.stringify(false));
|
@@ -9537,16 +9552,16 @@ var AppLayout = ({
|
|
9537
9552
|
}
|
9538
9553
|
};
|
9539
9554
|
const isRTL = direction === "rtl";
|
9540
|
-
const [openedSidebarItem, setOpenedSidebarItem] = (0,
|
9541
|
-
const [size, setSize] = (0,
|
9555
|
+
const [openedSidebarItem, setOpenedSidebarItem] = (0, import_react59.useState)("");
|
9556
|
+
const [size, setSize] = (0, import_react59.useState)(
|
9542
9557
|
typeof window !== "undefined" && window.innerWidth || 1200
|
9543
9558
|
);
|
9544
|
-
const [openSideMenu, setOpenSideMenu] = (0,
|
9559
|
+
const [openSideMenu, setOpenSideMenu] = (0, import_react59.useState)(() => {
|
9545
9560
|
const savedState = localStorage.getItem(LOCAL_STORAGE_KEY2);
|
9546
9561
|
return savedState ? JSON.parse(savedState) : false;
|
9547
9562
|
});
|
9548
|
-
const [container, setContainer] =
|
9549
|
-
const [keepDrawerOpen, setKeepDrawerOpen] = (0,
|
9563
|
+
const [container, setContainer] = import_react59.default.useState(null);
|
9564
|
+
const [keepDrawerOpen, setKeepDrawerOpen] = (0, import_react59.useState)(() => {
|
9550
9565
|
const savedState = localStorage.getItem(LOCAL_STORAGE_KEY2);
|
9551
9566
|
return savedState ? JSON.parse(savedState) : false;
|
9552
9567
|
});
|
@@ -9559,7 +9574,7 @@ var AppLayout = ({
|
|
9559
9574
|
}
|
9560
9575
|
};
|
9561
9576
|
const ref = useClickOutside(handleClickOutside);
|
9562
|
-
(0,
|
9577
|
+
(0, import_react59.useEffect)(() => {
|
9563
9578
|
if (typeof window !== "undefined") {
|
9564
9579
|
const resize = () => {
|
9565
9580
|
setSize(window.innerWidth);
|
@@ -9576,13 +9591,13 @@ var AppLayout = ({
|
|
9576
9591
|
};
|
9577
9592
|
}
|
9578
9593
|
}, []);
|
9579
|
-
(0,
|
9594
|
+
(0, import_react59.useEffect)(() => {
|
9580
9595
|
setKeepDrawerOpen(() => {
|
9581
9596
|
const savedState = localStorage.getItem(LOCAL_STORAGE_KEY2);
|
9582
9597
|
return savedState ? JSON.parse(savedState) : true;
|
9583
9598
|
});
|
9584
9599
|
}, [setKeepDrawerOpen]);
|
9585
|
-
(0,
|
9600
|
+
(0, import_react59.useEffect)(() => {
|
9586
9601
|
if (size > 600) {
|
9587
9602
|
setOpenSideMenu(keepDrawerOpen);
|
9588
9603
|
} else {
|
@@ -9591,7 +9606,7 @@ var AppLayout = ({
|
|
9591
9606
|
}
|
9592
9607
|
}, [size, keepDrawerOpen]);
|
9593
9608
|
const drawerSizeCondition = size > 600 ? drawerSizeStyle[keepDrawerOpen ? "opened" : "closed"][drawerSize] : 0;
|
9594
|
-
return /* @__PURE__ */
|
9609
|
+
return /* @__PURE__ */ import_react59.default.createElement("div", { className: "hawa-fixed hawa-start-0" }, props.topBar && /* @__PURE__ */ import_react59.default.createElement(
|
9595
9610
|
"div",
|
9596
9611
|
{
|
9597
9612
|
dir: direction,
|
@@ -9600,7 +9615,7 @@ var AppLayout = ({
|
|
9600
9615
|
bordered && "hawa-border-b-[1px]"
|
9601
9616
|
)
|
9602
9617
|
},
|
9603
|
-
size > 600 ? /* @__PURE__ */
|
9618
|
+
size > 600 ? /* @__PURE__ */ import_react59.default.createElement(
|
9604
9619
|
"div",
|
9605
9620
|
{
|
9606
9621
|
className: cn(
|
@@ -9614,24 +9629,24 @@ var AppLayout = ({
|
|
9614
9629
|
props.pageTitle
|
9615
9630
|
) : (
|
9616
9631
|
// Mobile Drawer Menu Button
|
9617
|
-
/* @__PURE__ */
|
9632
|
+
/* @__PURE__ */ import_react59.default.createElement(
|
9618
9633
|
"div",
|
9619
9634
|
{
|
9620
9635
|
dir: direction,
|
9621
9636
|
className: "hawa-flex hawa-items-center hawa-justify-center hawa-gap-0.5"
|
9622
9637
|
},
|
9623
|
-
/* @__PURE__ */
|
9638
|
+
/* @__PURE__ */ import_react59.default.createElement(
|
9624
9639
|
"div",
|
9625
9640
|
{
|
9626
9641
|
onClick: () => setOpenSideMenu(true),
|
9627
9642
|
className: "hawa-z-40 hawa-mx-1 hawa-cursor-pointer hawa-rounded hawa-p-2 hawa-transition-all "
|
9628
9643
|
},
|
9629
|
-
/* @__PURE__ */
|
9644
|
+
/* @__PURE__ */ import_react59.default.createElement(MenuIcon, null)
|
9630
9645
|
),
|
9631
|
-
props.pageTitle ? /* @__PURE__ */
|
9646
|
+
props.pageTitle ? /* @__PURE__ */ import_react59.default.createElement("div", { className: "hawa-text-sm" }, props.pageTitle) : /* @__PURE__ */ import_react59.default.createElement("div", null)
|
9632
9647
|
)
|
9633
9648
|
),
|
9634
|
-
/* @__PURE__ */
|
9649
|
+
/* @__PURE__ */ import_react59.default.createElement("div", { className: cn("hawa-flex hawa-gap-2 dark:hawa-text-white") }, size > 600 ? /* @__PURE__ */ import_react59.default.createElement("div", { className: "hawa-text-end hawa-text-xs" }, /* @__PURE__ */ import_react59.default.createElement("div", { className: "hawa-font-bold" }, props.username), " ", /* @__PURE__ */ import_react59.default.createElement("div", null, props.email)) : null, /* @__PURE__ */ import_react59.default.createElement(
|
9635
9650
|
DropdownMenu,
|
9636
9651
|
{
|
9637
9652
|
LinkComponent: MenuLinkComponent,
|
@@ -9643,13 +9658,13 @@ var AppLayout = ({
|
|
9643
9658
|
direction,
|
9644
9659
|
items: props.profileMenuItems || [],
|
9645
9660
|
onItemSelect: (e) => console.log("selecting item ", e),
|
9646
|
-
trigger: /* @__PURE__ */
|
9661
|
+
trigger: /* @__PURE__ */ import_react59.default.createElement(
|
9647
9662
|
"div",
|
9648
9663
|
{
|
9649
9664
|
onClick: onAvatarClick,
|
9650
9665
|
className: "hawa-relative hawa-h-8 hawa-w-8 hawa-cursor-pointer hawa-overflow-clip hawa-rounded hawa-ring-1 hawa-ring-primary/30 dark:hawa-bg-gray-600"
|
9651
9666
|
},
|
9652
|
-
props.avatarImage ? /* @__PURE__ */
|
9667
|
+
props.avatarImage ? /* @__PURE__ */ import_react59.default.createElement("img", { src: props.avatarImage, alt: "User Avatar" }) : /* @__PURE__ */ import_react59.default.createElement(
|
9653
9668
|
"svg",
|
9654
9669
|
{
|
9655
9670
|
"aria-label": "Avatar Icon",
|
@@ -9657,7 +9672,7 @@ var AppLayout = ({
|
|
9657
9672
|
fill: "currentColor",
|
9658
9673
|
viewBox: "0 0 20 20"
|
9659
9674
|
},
|
9660
|
-
/* @__PURE__ */
|
9675
|
+
/* @__PURE__ */ import_react59.default.createElement(
|
9661
9676
|
"path",
|
9662
9677
|
{
|
9663
9678
|
fillRule: "evenodd",
|
@@ -9669,7 +9684,7 @@ var AppLayout = ({
|
|
9669
9684
|
)
|
9670
9685
|
}
|
9671
9686
|
))
|
9672
|
-
), /* @__PURE__ */
|
9687
|
+
), /* @__PURE__ */ import_react59.default.createElement("div", { ref: setContainer }, /* @__PURE__ */ import_react59.default.createElement(
|
9673
9688
|
"div",
|
9674
9689
|
{
|
9675
9690
|
className: cn(
|
@@ -9695,7 +9710,7 @@ var AppLayout = ({
|
|
9695
9710
|
},
|
9696
9711
|
ref
|
9697
9712
|
},
|
9698
|
-
/* @__PURE__ */
|
9713
|
+
/* @__PURE__ */ import_react59.default.createElement(
|
9699
9714
|
"div",
|
9700
9715
|
{
|
9701
9716
|
onClick: props.onLogoClick,
|
@@ -9710,7 +9725,7 @@ var AppLayout = ({
|
|
9710
9725
|
}
|
9711
9726
|
},
|
9712
9727
|
openSideMenu && props.header && props.header,
|
9713
|
-
!props.header && /* @__PURE__ */
|
9728
|
+
!props.header && /* @__PURE__ */ import_react59.default.createElement(
|
9714
9729
|
"img",
|
9715
9730
|
{
|
9716
9731
|
src: props.logoLink,
|
@@ -9721,7 +9736,7 @@ var AppLayout = ({
|
|
9721
9736
|
)
|
9722
9737
|
}
|
9723
9738
|
),
|
9724
|
-
size > 600 ? /* @__PURE__ */
|
9739
|
+
size > 600 ? /* @__PURE__ */ import_react59.default.createElement(
|
9725
9740
|
"img",
|
9726
9741
|
{
|
9727
9742
|
src: props.logoSymbol,
|
@@ -9733,7 +9748,7 @@ var AppLayout = ({
|
|
9733
9748
|
}
|
9734
9749
|
) : null
|
9735
9750
|
),
|
9736
|
-
/* @__PURE__ */
|
9751
|
+
/* @__PURE__ */ import_react59.default.createElement(
|
9737
9752
|
"div",
|
9738
9753
|
{
|
9739
9754
|
className: cn(
|
@@ -9744,7 +9759,7 @@ var AppLayout = ({
|
|
9744
9759
|
width: size > 600 ? `${openSideMenu ? openDrawerWidth : drawerSizeCondition}px` : `${openSideMenu ? openDrawerWidth : 0}px`
|
9745
9760
|
}
|
9746
9761
|
},
|
9747
|
-
/* @__PURE__ */
|
9762
|
+
/* @__PURE__ */ import_react59.default.createElement(
|
9748
9763
|
SidebarGroup,
|
9749
9764
|
{
|
9750
9765
|
direction,
|
@@ -9759,7 +9774,7 @@ var AppLayout = ({
|
|
9759
9774
|
}
|
9760
9775
|
)
|
9761
9776
|
),
|
9762
|
-
/* @__PURE__ */
|
9777
|
+
/* @__PURE__ */ import_react59.default.createElement(
|
9763
9778
|
"div",
|
9764
9779
|
{
|
9765
9780
|
className: cn(
|
@@ -9770,8 +9785,8 @@ var AppLayout = ({
|
|
9770
9785
|
width: size > 600 ? `${openSideMenu ? openDrawerWidth : 56}px` : `${openSideMenu ? openDrawerWidth : 0}px`
|
9771
9786
|
}
|
9772
9787
|
},
|
9773
|
-
DrawerFooterActions && openSideMenu ? /* @__PURE__ */
|
9774
|
-
size > 600 && openSideMenu ? /* @__PURE__ */
|
9788
|
+
DrawerFooterActions && openSideMenu ? /* @__PURE__ */ import_react59.default.createElement(import_react59.default.Fragment, null, DrawerFooterActions) : null,
|
9789
|
+
size > 600 && openSideMenu ? /* @__PURE__ */ import_react59.default.createElement(
|
9775
9790
|
Tooltip,
|
9776
9791
|
{
|
9777
9792
|
side: "left",
|
@@ -9779,7 +9794,7 @@ var AppLayout = ({
|
|
9779
9794
|
triggerProps: { asChild: true },
|
9780
9795
|
content: keepDrawerOpen ? ((_a = props.texts) == null ? void 0 : _a.collapseSidebar) || "Collapse Sidebar" : ((_b = props.texts) == null ? void 0 : _b.expandSidebar) || "Expand Sidebar"
|
9781
9796
|
},
|
9782
|
-
/* @__PURE__ */
|
9797
|
+
/* @__PURE__ */ import_react59.default.createElement(
|
9783
9798
|
Button,
|
9784
9799
|
{
|
9785
9800
|
variant: "outline",
|
@@ -9793,7 +9808,7 @@ var AppLayout = ({
|
|
9793
9808
|
setKeepDrawerOpen(newKeepOpenState);
|
9794
9809
|
}
|
9795
9810
|
},
|
9796
|
-
/* @__PURE__ */
|
9811
|
+
/* @__PURE__ */ import_react59.default.createElement(
|
9797
9812
|
"svg",
|
9798
9813
|
{
|
9799
9814
|
className: cn(
|
@@ -9803,7 +9818,7 @@ var AppLayout = ({
|
|
9803
9818
|
fill: "currentColor",
|
9804
9819
|
viewBox: "0 0 20 20"
|
9805
9820
|
},
|
9806
|
-
/* @__PURE__ */
|
9821
|
+
/* @__PURE__ */ import_react59.default.createElement(
|
9807
9822
|
"path",
|
9808
9823
|
{
|
9809
9824
|
fillRule: "evenodd",
|
@@ -9815,14 +9830,14 @@ var AppLayout = ({
|
|
9815
9830
|
)
|
9816
9831
|
) : null
|
9817
9832
|
)
|
9818
|
-
)), /* @__PURE__ */
|
9833
|
+
)), /* @__PURE__ */ import_react59.default.createElement(
|
9819
9834
|
Dialog3.Root,
|
9820
9835
|
{
|
9821
9836
|
open: size < 600 && openSideMenu,
|
9822
9837
|
onOpenChange: setOpenSideMenu
|
9823
9838
|
},
|
9824
|
-
/* @__PURE__ */
|
9825
|
-
), /* @__PURE__ */
|
9839
|
+
/* @__PURE__ */ import_react59.default.createElement(Dialog3.Portal, { container }, /* @__PURE__ */ import_react59.default.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" }))
|
9840
|
+
), /* @__PURE__ */ import_react59.default.createElement(
|
9826
9841
|
"div",
|
9827
9842
|
{
|
9828
9843
|
className: "hawa-fixed hawa-overflow-y-auto hawa-transition-all hawa-z-0",
|
@@ -9843,11 +9858,11 @@ var AppLayout = ({
|
|
9843
9858
|
};
|
9844
9859
|
|
9845
9860
|
// layout/appTopbar/AppTopbar.tsx
|
9846
|
-
var
|
9861
|
+
var import_react60 = __toESM(require("react"));
|
9847
9862
|
var AppTopbar = ({ ...props }) => {
|
9848
9863
|
const isRTL = props.direction === "ltr";
|
9849
9864
|
const size = 1200;
|
9850
|
-
return /* @__PURE__ */
|
9865
|
+
return /* @__PURE__ */ import_react60.default.createElement(
|
9851
9866
|
"div",
|
9852
9867
|
{
|
9853
9868
|
className: cn(
|
@@ -9855,24 +9870,24 @@ var AppTopbar = ({ ...props }) => {
|
|
9855
9870
|
isRTL ? "hawa-flex-row-reverse" : "hawa-flex-row"
|
9856
9871
|
)
|
9857
9872
|
},
|
9858
|
-
size > 600 ? /* @__PURE__ */
|
9873
|
+
size > 600 ? /* @__PURE__ */ import_react60.default.createElement(
|
9859
9874
|
"div",
|
9860
9875
|
null,
|
9861
9876
|
"page title"
|
9862
9877
|
) : (
|
9863
9878
|
// Mobile Drawer Menu Button
|
9864
|
-
/* @__PURE__ */
|
9879
|
+
/* @__PURE__ */ import_react60.default.createElement(
|
9865
9880
|
"div",
|
9866
9881
|
{
|
9867
9882
|
dir: props.direction,
|
9868
9883
|
className: "hawa-flex hawa-items-center hawa-justify-center hawa-gap-0.5"
|
9869
9884
|
},
|
9870
|
-
/* @__PURE__ */
|
9885
|
+
/* @__PURE__ */ import_react60.default.createElement(
|
9871
9886
|
"div",
|
9872
9887
|
{
|
9873
9888
|
className: "hawa-z-40 hawa-mx-1 hawa-cursor-pointer hawa-rounded hawa-p-2 hawa-transition-all hover:hawa-bg-gray-100"
|
9874
9889
|
},
|
9875
|
-
/* @__PURE__ */
|
9890
|
+
/* @__PURE__ */ import_react60.default.createElement(
|
9876
9891
|
"svg",
|
9877
9892
|
{
|
9878
9893
|
stroke: "currentColor",
|
@@ -9883,7 +9898,7 @@ var AppTopbar = ({ ...props }) => {
|
|
9883
9898
|
height: "1.6em",
|
9884
9899
|
width: "1.6em"
|
9885
9900
|
},
|
9886
|
-
/* @__PURE__ */
|
9901
|
+
/* @__PURE__ */ import_react60.default.createElement(
|
9887
9902
|
"path",
|
9888
9903
|
{
|
9889
9904
|
fillRule: "evenodd",
|
@@ -9896,7 +9911,7 @@ var AppTopbar = ({ ...props }) => {
|
|
9896
9911
|
"Mobile title"
|
9897
9912
|
)
|
9898
9913
|
),
|
9899
|
-
/* @__PURE__ */
|
9914
|
+
/* @__PURE__ */ import_react60.default.createElement(
|
9900
9915
|
"div",
|
9901
9916
|
{
|
9902
9917
|
className: cn(
|
@@ -9904,16 +9919,16 @@ var AppTopbar = ({ ...props }) => {
|
|
9904
9919
|
isRTL ? "hawa-flex-row-reverse" : "hawa-flex-row"
|
9905
9920
|
)
|
9906
9921
|
},
|
9907
|
-
size > 600 ? /* @__PURE__ */
|
9922
|
+
size > 600 ? /* @__PURE__ */ import_react60.default.createElement(
|
9908
9923
|
"div",
|
9909
9924
|
{
|
9910
9925
|
className: isRTL ? "hawa-text-left hawa-text-xs" : "hawa-text-right hawa-text-xs"
|
9911
9926
|
},
|
9912
|
-
/* @__PURE__ */
|
9927
|
+
/* @__PURE__ */ import_react60.default.createElement("div", { className: "hawa-font-bold" }, props.username),
|
9913
9928
|
" ",
|
9914
|
-
/* @__PURE__ */
|
9929
|
+
/* @__PURE__ */ import_react60.default.createElement("div", null, props.email)
|
9915
9930
|
) : null,
|
9916
|
-
/* @__PURE__ */
|
9931
|
+
/* @__PURE__ */ import_react60.default.createElement(
|
9917
9932
|
DropdownMenu,
|
9918
9933
|
{
|
9919
9934
|
triggerClassname: "hawa-mx-2",
|
@@ -9924,7 +9939,7 @@ var AppTopbar = ({ ...props }) => {
|
|
9924
9939
|
direction: isRTL ? "rtl" : "ltr",
|
9925
9940
|
items: props.profileMenuItems || [],
|
9926
9941
|
onItemSelect: (e) => console.log("selecting item ", e),
|
9927
|
-
trigger: /* @__PURE__ */
|
9942
|
+
trigger: /* @__PURE__ */ import_react60.default.createElement("div", { className: "hawa-relative hawa-h-8 hawa-w-8 hawa-cursor-pointer hawa-overflow-clip hawa-rounded hawa-ring-1 hawa-ring-primary/30 dark:hawa-bg-gray-600" }, props.avatarImage ? /* @__PURE__ */ import_react60.default.createElement("img", { src: props.avatarImage, alt: "User Avatar" }) : /* @__PURE__ */ import_react60.default.createElement(
|
9928
9943
|
"svg",
|
9929
9944
|
{
|
9930
9945
|
"aria-label": "Avatar Icon",
|
@@ -9932,7 +9947,7 @@ var AppTopbar = ({ ...props }) => {
|
|
9932
9947
|
fill: "currentColor",
|
9933
9948
|
viewBox: "0 0 20 20"
|
9934
9949
|
},
|
9935
|
-
/* @__PURE__ */
|
9950
|
+
/* @__PURE__ */ import_react60.default.createElement(
|
9936
9951
|
"path",
|
9937
9952
|
{
|
9938
9953
|
fillRule: "evenodd",
|
@@ -10151,10 +10166,10 @@ var MenubarShortcut = ({
|
|
10151
10166
|
MenubarShortcut.displayname = "MenubarShortcut";
|
10152
10167
|
|
10153
10168
|
// layout/appTabs/AppTabs.tsx
|
10154
|
-
var
|
10169
|
+
var import_react61 = __toESM(require("react"));
|
10155
10170
|
var AppTabs = ({ tabs, className }) => {
|
10156
|
-
const [selectedIndex, setSelectedIndex] = (0,
|
10157
|
-
return /* @__PURE__ */
|
10171
|
+
const [selectedIndex, setSelectedIndex] = (0, import_react61.useState)(0);
|
10172
|
+
return /* @__PURE__ */ import_react61.default.createElement(
|
10158
10173
|
"div",
|
10159
10174
|
{
|
10160
10175
|
className: cn(
|
@@ -10162,9 +10177,9 @@ var AppTabs = ({ tabs, className }) => {
|
|
10162
10177
|
className
|
10163
10178
|
)
|
10164
10179
|
},
|
10165
|
-
/* @__PURE__ */
|
10180
|
+
/* @__PURE__ */ import_react61.default.createElement("div", { className: "hawa-flex hawa-flex-row hawa-justify-center " }, tabs.map((tab, index) => {
|
10166
10181
|
const selected = index === selectedIndex;
|
10167
|
-
return /* @__PURE__ */
|
10182
|
+
return /* @__PURE__ */ import_react61.default.createElement(
|
10168
10183
|
"a",
|
10169
10184
|
{
|
10170
10185
|
href: tab.path,
|
@@ -10195,16 +10210,16 @@ var AppTabs = ({ tabs, className }) => {
|
|
10195
10210
|
};
|
10196
10211
|
|
10197
10212
|
// layout/docsLayout/DocsLayout.tsx
|
10198
|
-
var
|
10213
|
+
var import_react63 = __toESM(require("react"));
|
10199
10214
|
|
10200
10215
|
// layout/docsSidebar/DocsSidebar.tsx
|
10201
|
-
var
|
10216
|
+
var import_react62 = __toESM(require("react"));
|
10202
10217
|
var DocsSidebar = ({
|
10203
10218
|
currentPage: propCurrentPage,
|
10204
10219
|
pages,
|
10205
10220
|
direction
|
10206
10221
|
}) => {
|
10207
|
-
const [activePage, setActivePage] =
|
10222
|
+
const [activePage, setActivePage] = import_react62.default.useState(pages[0]);
|
10208
10223
|
const handlePageClick = (page, event) => {
|
10209
10224
|
event.preventDefault();
|
10210
10225
|
setTimeout(() => {
|
@@ -10226,7 +10241,7 @@ var DocsSidebar = ({
|
|
10226
10241
|
}
|
10227
10242
|
return pages[0];
|
10228
10243
|
};
|
10229
|
-
|
10244
|
+
import_react62.default.useEffect(() => {
|
10230
10245
|
const handleScroll = () => {
|
10231
10246
|
setActivePage(getCurrentSection());
|
10232
10247
|
};
|
@@ -10239,13 +10254,13 @@ var DocsSidebar = ({
|
|
10239
10254
|
rtl: "hawa-border-r-4 hawa-border-primary hawa-border-collapse hawa-bg-gray-200",
|
10240
10255
|
ltr: "hawa-border-l-4 hawa-border-primary hawa-border-collapse hawa-bg-gray-200"
|
10241
10256
|
};
|
10242
|
-
return /* @__PURE__ */
|
10257
|
+
return /* @__PURE__ */ import_react62.default.createElement(
|
10243
10258
|
"div",
|
10244
10259
|
{
|
10245
10260
|
className: "hawa-flex hawa-flex-col hawa-overflow-x-clip",
|
10246
10261
|
dir: direction
|
10247
10262
|
},
|
10248
|
-
pages.map((page, index) => /* @__PURE__ */
|
10263
|
+
pages.map((page, index) => /* @__PURE__ */ import_react62.default.createElement(
|
10249
10264
|
"div",
|
10250
10265
|
{
|
10251
10266
|
key: index,
|
@@ -10285,15 +10300,15 @@ var DocsLayout = ({
|
|
10285
10300
|
lg: closeDrawerWidth
|
10286
10301
|
}
|
10287
10302
|
};
|
10288
|
-
const ref = (0,
|
10303
|
+
const ref = (0, import_react63.useRef)(null);
|
10289
10304
|
const isRTL = direction === "rtl";
|
10290
10305
|
let size = useBreakpoint();
|
10291
10306
|
if (typeof window == "undefined") {
|
10292
10307
|
size = 1200;
|
10293
10308
|
}
|
10294
|
-
const [currentPage, setCurrentPage] = (0,
|
10295
|
-
const [openSideMenu, setOpenSideMenu] = (0,
|
10296
|
-
(0,
|
10309
|
+
const [currentPage, setCurrentPage] = (0, import_react63.useState)("Introduction");
|
10310
|
+
const [openSideMenu, setOpenSideMenu] = (0, import_react63.useState)(true);
|
10311
|
+
(0, import_react63.useEffect)(() => {
|
10297
10312
|
const handleClickOutside = (event) => {
|
10298
10313
|
if (ref.current && !ref.current.contains(event.target) && !openSideMenu) {
|
10299
10314
|
setOpenSideMenu(false);
|
@@ -10304,7 +10319,7 @@ var DocsLayout = ({
|
|
10304
10319
|
document.removeEventListener("click", handleClickOutside, true);
|
10305
10320
|
};
|
10306
10321
|
}, [openSideMenu]);
|
10307
|
-
(0,
|
10322
|
+
(0, import_react63.useEffect)(() => {
|
10308
10323
|
const handleResize = () => {
|
10309
10324
|
setOpenSideMenu(window.innerWidth > 600 ? true : false);
|
10310
10325
|
};
|
@@ -10314,19 +10329,19 @@ var DocsLayout = ({
|
|
10314
10329
|
window.removeEventListener("resize", handleResize);
|
10315
10330
|
};
|
10316
10331
|
}, [keepOpen]);
|
10317
|
-
const observerRef =
|
10332
|
+
const observerRef = import_react63.default.useRef(null);
|
10318
10333
|
const handleIntersection = (entries) => {
|
10319
10334
|
const entry = entries.find((entry2) => entry2.isIntersecting);
|
10320
10335
|
if (entry) {
|
10321
10336
|
setCurrentPage(entry.target.id);
|
10322
10337
|
}
|
10323
10338
|
};
|
10324
|
-
(0,
|
10339
|
+
(0, import_react63.useEffect)(() => {
|
10325
10340
|
observerRef.current = new IntersectionObserver(handleIntersection, {
|
10326
10341
|
threshold: 0.5
|
10327
10342
|
// Adjust threshold as needed to determine when a section is in view
|
10328
10343
|
});
|
10329
|
-
|
10344
|
+
import_react63.default.Children.forEach(props.children, (child) => {
|
10330
10345
|
if (child && child.props.id) {
|
10331
10346
|
const element = document.getElementById(child.props.id);
|
10332
10347
|
if (element && observerRef.current) {
|
@@ -10341,7 +10356,7 @@ var DocsLayout = ({
|
|
10341
10356
|
};
|
10342
10357
|
}, [props.children]);
|
10343
10358
|
let drawerSizeCondition = drawerSizeStyle[openSideMenu ? "opened" : "closed"][drawerSize];
|
10344
|
-
return /* @__PURE__ */
|
10359
|
+
return /* @__PURE__ */ import_react63.default.createElement("div", { className: "hawa-fixed" }, /* @__PURE__ */ import_react63.default.createElement(
|
10345
10360
|
"div",
|
10346
10361
|
{
|
10347
10362
|
className: cn(
|
@@ -10349,7 +10364,7 @@ var DocsLayout = ({
|
|
10349
10364
|
isRTL ? "hawa-flex-row-reverse" : "hawa-flex-row"
|
10350
10365
|
)
|
10351
10366
|
},
|
10352
|
-
size > 600 ? /* @__PURE__ */
|
10367
|
+
size > 600 ? /* @__PURE__ */ import_react63.default.createElement("div", { onClick: props.onLogoClick, dir: direction }, /* @__PURE__ */ import_react63.default.createElement(
|
10353
10368
|
"img",
|
10354
10369
|
{
|
10355
10370
|
className: cn(
|
@@ -10360,18 +10375,18 @@ var DocsLayout = ({
|
|
10360
10375
|
}
|
10361
10376
|
)) : (
|
10362
10377
|
// Mobile Drawer Menu Button
|
10363
|
-
/* @__PURE__ */
|
10378
|
+
/* @__PURE__ */ import_react63.default.createElement(
|
10364
10379
|
"div",
|
10365
10380
|
{
|
10366
10381
|
dir: direction,
|
10367
10382
|
className: "hawa-flex hawa-items-center hawa-justify-center hawa-gap-0.5"
|
10368
10383
|
},
|
10369
|
-
/* @__PURE__ */
|
10384
|
+
/* @__PURE__ */ import_react63.default.createElement(Sheet, null, /* @__PURE__ */ import_react63.default.createElement(SheetTrigger, null, " ", /* @__PURE__ */ import_react63.default.createElement(
|
10370
10385
|
"div",
|
10371
10386
|
{
|
10372
10387
|
className: "hawa-z-40 hawa-mx-1 hawa-cursor-pointer hawa-rounded hawa-p-2 hawa-transition-all hover:hawa-bg-gray-100"
|
10373
10388
|
},
|
10374
|
-
/* @__PURE__ */
|
10389
|
+
/* @__PURE__ */ import_react63.default.createElement(
|
10375
10390
|
"svg",
|
10376
10391
|
{
|
10377
10392
|
"aria-label": "Menu Icon",
|
@@ -10383,7 +10398,7 @@ var DocsLayout = ({
|
|
10383
10398
|
height: "1.6em",
|
10384
10399
|
width: "1.6em"
|
10385
10400
|
},
|
10386
|
-
/* @__PURE__ */
|
10401
|
+
/* @__PURE__ */ import_react63.default.createElement(
|
10387
10402
|
"path",
|
10388
10403
|
{
|
10389
10404
|
fillRule: "evenodd",
|
@@ -10392,17 +10407,17 @@ var DocsLayout = ({
|
|
10392
10407
|
}
|
10393
10408
|
)
|
10394
10409
|
)
|
10395
|
-
)), /* @__PURE__ */
|
10410
|
+
)), /* @__PURE__ */ import_react63.default.createElement(
|
10396
10411
|
SheetContent,
|
10397
10412
|
{
|
10398
10413
|
side: isRTL ? "right" : "left",
|
10399
10414
|
className: "hawa-pt-10"
|
10400
10415
|
},
|
10401
|
-
/* @__PURE__ */
|
10416
|
+
/* @__PURE__ */ import_react63.default.createElement(DocsSidebar, { direction, pages: pages || [] })
|
10402
10417
|
))
|
10403
10418
|
)
|
10404
10419
|
),
|
10405
|
-
/* @__PURE__ */
|
10420
|
+
/* @__PURE__ */ import_react63.default.createElement(
|
10406
10421
|
"div",
|
10407
10422
|
{
|
10408
10423
|
className: cn(
|
@@ -10410,9 +10425,9 @@ var DocsLayout = ({
|
|
10410
10425
|
isRTL ? "hawa-flex-row-reverse" : "hawa-flex-row"
|
10411
10426
|
)
|
10412
10427
|
},
|
10413
|
-
/* @__PURE__ */
|
10428
|
+
/* @__PURE__ */ import_react63.default.createElement(Button, { variant: "ghost", size: "smallIcon" }, /* @__PURE__ */ import_react63.default.createElement(Logos.github, { className: "hawa-icon" }))
|
10414
10429
|
)
|
10415
|
-
), /* @__PURE__ */
|
10430
|
+
), /* @__PURE__ */ import_react63.default.createElement(
|
10416
10431
|
"div",
|
10417
10432
|
{
|
10418
10433
|
className: cn(
|
@@ -10435,7 +10450,7 @@ var DocsLayout = ({
|
|
10435
10450
|
},
|
10436
10451
|
ref
|
10437
10452
|
},
|
10438
|
-
/* @__PURE__ */
|
10453
|
+
/* @__PURE__ */ import_react63.default.createElement(
|
10439
10454
|
DocsSidebar,
|
10440
10455
|
{
|
10441
10456
|
direction,
|
@@ -10443,7 +10458,7 @@ var DocsLayout = ({
|
|
10443
10458
|
currentPage
|
10444
10459
|
}
|
10445
10460
|
)
|
10446
|
-
), /* @__PURE__ */
|
10461
|
+
), /* @__PURE__ */ import_react63.default.createElement(
|
10447
10462
|
"div",
|
10448
10463
|
{
|
10449
10464
|
className: "hawa-fixed hawa-overflow-y-auto hawa-transition-all ",
|
@@ -10465,10 +10480,10 @@ var DocsLayout = ({
|
|
10465
10480
|
};
|
10466
10481
|
|
10467
10482
|
// blocks/auth/AuthButtons.tsx
|
10468
|
-
var
|
10483
|
+
var import_react64 = __toESM(require("react"));
|
10469
10484
|
var AuthButtons = (props) => {
|
10470
10485
|
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r;
|
10471
|
-
return /* @__PURE__ */
|
10486
|
+
return /* @__PURE__ */ import_react64.default.createElement("div", { className: "hawa-flex hawa-flex-col hawa-gap-4" }, props.viaMetamask && /* @__PURE__ */ import_react64.default.createElement(
|
10472
10487
|
Button,
|
10473
10488
|
{
|
10474
10489
|
disabled: props.isMetamaskLoading,
|
@@ -10476,9 +10491,9 @@ var AuthButtons = (props) => {
|
|
10476
10491
|
variant: "outline",
|
10477
10492
|
onClick: props.handleMetamask
|
10478
10493
|
},
|
10479
|
-
props.isMetamaskLoading ? /* @__PURE__ */
|
10494
|
+
props.isMetamaskLoading ? /* @__PURE__ */ import_react64.default.createElement(Loading, { size: "button" }) : /* @__PURE__ */ import_react64.default.createElement(Logos.metamask, { className: "hawa-h-6" }),
|
10480
10495
|
(_b = (_a = props.texts) == null ? void 0 : _a.continueWithMetamask) != null ? _b : "Connect Metamask"
|
10481
|
-
), props.viaNafath && /* @__PURE__ */
|
10496
|
+
), props.viaNafath && /* @__PURE__ */ import_react64.default.createElement(
|
10482
10497
|
Button,
|
10483
10498
|
{
|
10484
10499
|
disabled: props.isNafathLoading,
|
@@ -10486,9 +10501,9 @@ var AuthButtons = (props) => {
|
|
10486
10501
|
variant: "outline",
|
10487
10502
|
onClick: props.handleNafath
|
10488
10503
|
},
|
10489
|
-
props.isNafathLoading ? /* @__PURE__ */
|
10504
|
+
props.isNafathLoading ? /* @__PURE__ */ import_react64.default.createElement(Loading, { size: "button" }) : /* @__PURE__ */ import_react64.default.createElement(Logos.nafath, { className: "hawa-h-4" }),
|
10490
10505
|
(_d = (_c = props.texts) == null ? void 0 : _c.continueWithNafath) != null ? _d : "Continue With Nafath"
|
10491
|
-
), props.viaGoogle && /* @__PURE__ */
|
10506
|
+
), props.viaGoogle && /* @__PURE__ */ import_react64.default.createElement(
|
10492
10507
|
Button,
|
10493
10508
|
{
|
10494
10509
|
disabled: props.isGoogleLoading,
|
@@ -10496,9 +10511,9 @@ var AuthButtons = (props) => {
|
|
10496
10511
|
variant: "outline",
|
10497
10512
|
onClick: props.handleGoogle
|
10498
10513
|
},
|
10499
|
-
props.isGoogleLoading ? /* @__PURE__ */
|
10514
|
+
props.isGoogleLoading ? /* @__PURE__ */ import_react64.default.createElement(Loading, { size: "button" }) : /* @__PURE__ */ import_react64.default.createElement(Logos.google, { className: "hawa-icon" }),
|
10500
10515
|
(_f = (_e = props.texts) == null ? void 0 : _e.continueWithGoogle) != null ? _f : "Continue With Google"
|
10501
|
-
), props.viaGithub && /* @__PURE__ */
|
10516
|
+
), props.viaGithub && /* @__PURE__ */ import_react64.default.createElement(
|
10502
10517
|
Button,
|
10503
10518
|
{
|
10504
10519
|
disabled: props.isGithubLoading,
|
@@ -10506,9 +10521,9 @@ var AuthButtons = (props) => {
|
|
10506
10521
|
variant: "outline",
|
10507
10522
|
onClick: props.handleGithub
|
10508
10523
|
},
|
10509
|
-
props.isGithubLoading ? /* @__PURE__ */
|
10524
|
+
props.isGithubLoading ? /* @__PURE__ */ import_react64.default.createElement(Loading, { size: "button" }) : /* @__PURE__ */ import_react64.default.createElement(Logos.github, { className: "hawa-icon" }),
|
10510
10525
|
(_h = (_g = props.texts) == null ? void 0 : _g.continueWithGithub) != null ? _h : "Continue With Github"
|
10511
|
-
), props.viaTwitter && /* @__PURE__ */
|
10526
|
+
), props.viaTwitter && /* @__PURE__ */ import_react64.default.createElement(
|
10512
10527
|
Button,
|
10513
10528
|
{
|
10514
10529
|
disabled: props.isTwitterLoading,
|
@@ -10516,9 +10531,9 @@ var AuthButtons = (props) => {
|
|
10516
10531
|
variant: "outline",
|
10517
10532
|
onClick: props.handleTwitter
|
10518
10533
|
},
|
10519
|
-
props.isTwitterLoading ? /* @__PURE__ */
|
10534
|
+
props.isTwitterLoading ? /* @__PURE__ */ import_react64.default.createElement(Loading, { size: "button" }) : /* @__PURE__ */ import_react64.default.createElement(Logos.twitter, { className: "hawa-icon" }),
|
10520
10535
|
(_j = (_i = props.texts) == null ? void 0 : _i.continueWithTwitter) != null ? _j : "Continue With Twitter"
|
10521
|
-
), props.viaApple && /* @__PURE__ */
|
10536
|
+
), props.viaApple && /* @__PURE__ */ import_react64.default.createElement(
|
10522
10537
|
Button,
|
10523
10538
|
{
|
10524
10539
|
disabled: props.isAppleLoading,
|
@@ -10526,9 +10541,9 @@ var AuthButtons = (props) => {
|
|
10526
10541
|
variant: "outline",
|
10527
10542
|
onClick: props.handleApple
|
10528
10543
|
},
|
10529
|
-
props.isAppleLoading ? /* @__PURE__ */
|
10544
|
+
props.isAppleLoading ? /* @__PURE__ */ import_react64.default.createElement(Loading, { size: "button" }) : /* @__PURE__ */ import_react64.default.createElement(Logos.apple, { className: "hawa-icon" }),
|
10530
10545
|
(_l = (_k = props.texts) == null ? void 0 : _k.continueWithApple) != null ? _l : "Continue With Apple"
|
10531
|
-
), props.viaMicrosoft && /* @__PURE__ */
|
10546
|
+
), props.viaMicrosoft && /* @__PURE__ */ import_react64.default.createElement(
|
10532
10547
|
Button,
|
10533
10548
|
{
|
10534
10549
|
disabled: props.isMicrosoftLoading,
|
@@ -10536,9 +10551,9 @@ var AuthButtons = (props) => {
|
|
10536
10551
|
variant: "outline",
|
10537
10552
|
onClick: props.handleMicrosoft
|
10538
10553
|
},
|
10539
|
-
props.isMicrosoftLoading ? /* @__PURE__ */
|
10554
|
+
props.isMicrosoftLoading ? /* @__PURE__ */ import_react64.default.createElement(Loading, { size: "button" }) : /* @__PURE__ */ import_react64.default.createElement(Logos.microsoft, { className: "hawa-icon" }),
|
10540
10555
|
(_n = (_m = props.texts) == null ? void 0 : _m.continueWithMicrosoft) != null ? _n : "Continue With Microsoft"
|
10541
|
-
), props.viaEmail && /* @__PURE__ */
|
10556
|
+
), props.viaEmail && /* @__PURE__ */ import_react64.default.createElement(
|
10542
10557
|
Button,
|
10543
10558
|
{
|
10544
10559
|
disabled: props.isEmailLoading,
|
@@ -10546,9 +10561,9 @@ var AuthButtons = (props) => {
|
|
10546
10561
|
variant: "outline",
|
10547
10562
|
onClick: props.handleEmail
|
10548
10563
|
},
|
10549
|
-
props.isEmailLoading ? /* @__PURE__ */
|
10564
|
+
props.isEmailLoading ? /* @__PURE__ */ import_react64.default.createElement(Loading, { size: "button" }) : /* @__PURE__ */ import_react64.default.createElement(Logos.mail, { className: "hawa-icon" }),
|
10550
10565
|
(_p = (_o = props.texts) == null ? void 0 : _o.continueWithEmail) != null ? _p : "Continue With Email"
|
10551
|
-
), props.viaPhone && /* @__PURE__ */
|
10566
|
+
), props.viaPhone && /* @__PURE__ */ import_react64.default.createElement(
|
10552
10567
|
Button,
|
10553
10568
|
{
|
10554
10569
|
disabled: props.isPhoneLoading,
|
@@ -10556,14 +10571,14 @@ var AuthButtons = (props) => {
|
|
10556
10571
|
variant: "outline",
|
10557
10572
|
onClick: props.handlePhone
|
10558
10573
|
},
|
10559
|
-
props.isPhoneLoading ? /* @__PURE__ */
|
10574
|
+
props.isPhoneLoading ? /* @__PURE__ */ import_react64.default.createElement(Loading, { size: "button" }) : /* @__PURE__ */ import_react64.default.createElement(Logos.phone, { className: "hawa-icon" }),
|
10560
10575
|
(_r = (_q = props.texts) == null ? void 0 : _q.continueWithPhone) != null ? _r : "Continue With Phone"
|
10561
10576
|
));
|
10562
10577
|
};
|
10563
10578
|
|
10564
10579
|
// blocks/auth/LoginForm.tsx
|
10565
|
-
var
|
10566
|
-
var
|
10580
|
+
var import_react65 = __toESM(require("react"));
|
10581
|
+
var import_react66 = require("react");
|
10567
10582
|
var import_react_hook_form = require("react-hook-form");
|
10568
10583
|
var import_zod = require("@hookform/resolvers/zod");
|
10569
10584
|
var import_libphonenumber_js = require("libphonenumber-js");
|
@@ -10575,7 +10590,7 @@ var LoginForm = ({
|
|
10575
10590
|
...props
|
10576
10591
|
}) => {
|
10577
10592
|
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q;
|
10578
|
-
const [passwordVisible, setPasswordVisible] = (0,
|
10593
|
+
const [passwordVisible, setPasswordVisible] = (0, import_react66.useState)(false);
|
10579
10594
|
const thirdPartyAuthTexts = {
|
10580
10595
|
continueWithGoogle: texts == null ? void 0 : texts.continueWithGoogle,
|
10581
10596
|
continueWithTwitter: texts == null ? void 0 : texts.continueWithTwitter,
|
@@ -10637,14 +10652,14 @@ var LoginForm = ({
|
|
10637
10652
|
const renderFields = () => {
|
10638
10653
|
switch (loginType) {
|
10639
10654
|
case "email":
|
10640
|
-
return /* @__PURE__ */
|
10655
|
+
return /* @__PURE__ */ import_react65.default.createElement(import_react65.default.Fragment, null, /* @__PURE__ */ import_react65.default.createElement(
|
10641
10656
|
import_react_hook_form.Controller,
|
10642
10657
|
{
|
10643
10658
|
control,
|
10644
10659
|
name: "email",
|
10645
10660
|
render: ({ field }) => {
|
10646
10661
|
var _a2, _b2, _c2;
|
10647
|
-
return /* @__PURE__ */
|
10662
|
+
return /* @__PURE__ */ import_react65.default.createElement(
|
10648
10663
|
Input,
|
10649
10664
|
{
|
10650
10665
|
inputProps: {
|
@@ -10664,27 +10679,27 @@ var LoginForm = ({
|
|
10664
10679
|
);
|
10665
10680
|
}
|
10666
10681
|
}
|
10667
|
-
), /* @__PURE__ */
|
10682
|
+
), /* @__PURE__ */ import_react65.default.createElement("div", null, /* @__PURE__ */ import_react65.default.createElement(
|
10668
10683
|
import_react_hook_form.Controller,
|
10669
10684
|
{
|
10670
10685
|
control,
|
10671
10686
|
name: "password",
|
10672
10687
|
render: ({ field }) => {
|
10673
10688
|
var _a2, _b2, _c2;
|
10674
|
-
return /* @__PURE__ */
|
10689
|
+
return /* @__PURE__ */ import_react65.default.createElement(
|
10675
10690
|
Input,
|
10676
10691
|
{
|
10677
10692
|
width: "full",
|
10678
10693
|
autoComplete: "current-password",
|
10679
10694
|
type: passwordVisible ? "text" : "password",
|
10680
10695
|
label: ((_a2 = texts == null ? void 0 : texts.password) == null ? void 0 : _a2.label) || "Password",
|
10681
|
-
endIcon: /* @__PURE__ */
|
10696
|
+
endIcon: /* @__PURE__ */ import_react65.default.createElement(
|
10682
10697
|
"div",
|
10683
10698
|
{
|
10684
10699
|
className: "hawa-cursor-pointer",
|
10685
10700
|
onClick: () => setPasswordVisible(!passwordVisible)
|
10686
10701
|
},
|
10687
|
-
passwordVisible ? /* @__PURE__ */
|
10702
|
+
passwordVisible ? /* @__PURE__ */ import_react65.default.createElement(EyeIcon, { className: "hawa-text-gray-500" }) : /* @__PURE__ */ import_react65.default.createElement(HiddenEyeIcon, { className: "hawa-text-gray-500" })
|
10688
10703
|
),
|
10689
10704
|
placeholder: ((_b2 = texts == null ? void 0 : texts.password) == null ? void 0 : _b2.placeholder) || "Enter your password",
|
10690
10705
|
helperText: (_c2 = formState.errors.password) == null ? void 0 : _c2.message,
|
@@ -10693,7 +10708,7 @@ var LoginForm = ({
|
|
10693
10708
|
);
|
10694
10709
|
}
|
10695
10710
|
}
|
10696
|
-
), props.withResetPassword && /* @__PURE__ */
|
10711
|
+
), props.withResetPassword && /* @__PURE__ */ import_react65.default.createElement(
|
10697
10712
|
"div",
|
10698
10713
|
{
|
10699
10714
|
onClick: props.onForgotPassword,
|
@@ -10702,14 +10717,14 @@ var LoginForm = ({
|
|
10702
10717
|
(texts == null ? void 0 : texts.forgotPassword) || "Forgot Password?"
|
10703
10718
|
)));
|
10704
10719
|
case "username":
|
10705
|
-
return /* @__PURE__ */
|
10720
|
+
return /* @__PURE__ */ import_react65.default.createElement(import_react65.default.Fragment, null, /* @__PURE__ */ import_react65.default.createElement(
|
10706
10721
|
import_react_hook_form.Controller,
|
10707
10722
|
{
|
10708
10723
|
control,
|
10709
10724
|
name: "username",
|
10710
10725
|
render: ({ field }) => {
|
10711
10726
|
var _a2, _b2, _c2;
|
10712
|
-
return /* @__PURE__ */
|
10727
|
+
return /* @__PURE__ */ import_react65.default.createElement(
|
10713
10728
|
Input,
|
10714
10729
|
{
|
10715
10730
|
width: "full",
|
@@ -10722,27 +10737,27 @@ var LoginForm = ({
|
|
10722
10737
|
);
|
10723
10738
|
}
|
10724
10739
|
}
|
10725
|
-
), /* @__PURE__ */
|
10740
|
+
), /* @__PURE__ */ import_react65.default.createElement("div", null, /* @__PURE__ */ import_react65.default.createElement(
|
10726
10741
|
import_react_hook_form.Controller,
|
10727
10742
|
{
|
10728
10743
|
control,
|
10729
10744
|
name: "password",
|
10730
10745
|
render: ({ field }) => {
|
10731
10746
|
var _a2, _b2, _c2;
|
10732
|
-
return /* @__PURE__ */
|
10747
|
+
return /* @__PURE__ */ import_react65.default.createElement(
|
10733
10748
|
Input,
|
10734
10749
|
{
|
10735
10750
|
width: "full",
|
10736
10751
|
autoComplete: "current-password",
|
10737
10752
|
type: passwordVisible ? "text" : "password",
|
10738
10753
|
label: ((_a2 = texts == null ? void 0 : texts.password) == null ? void 0 : _a2.label) || "Password",
|
10739
|
-
endIcon: /* @__PURE__ */
|
10754
|
+
endIcon: /* @__PURE__ */ import_react65.default.createElement(
|
10740
10755
|
"div",
|
10741
10756
|
{
|
10742
10757
|
className: "hawa-cursor-pointer",
|
10743
10758
|
onClick: () => setPasswordVisible(!passwordVisible)
|
10744
10759
|
},
|
10745
|
-
passwordVisible ? /* @__PURE__ */
|
10760
|
+
passwordVisible ? /* @__PURE__ */ import_react65.default.createElement(EyeIcon, { className: "hawa-text-gray-500" }) : /* @__PURE__ */ import_react65.default.createElement(HiddenEyeIcon, { className: "hawa-text-gray-500" })
|
10746
10761
|
),
|
10747
10762
|
placeholder: ((_b2 = texts == null ? void 0 : texts.password) == null ? void 0 : _b2.placeholder) || "Enter your password",
|
10748
10763
|
helperText: (_c2 = formState.errors.password) == null ? void 0 : _c2.message,
|
@@ -10751,7 +10766,7 @@ var LoginForm = ({
|
|
10751
10766
|
);
|
10752
10767
|
}
|
10753
10768
|
}
|
10754
|
-
), props.withResetPassword && /* @__PURE__ */
|
10769
|
+
), props.withResetPassword && /* @__PURE__ */ import_react65.default.createElement(
|
10755
10770
|
"div",
|
10756
10771
|
{
|
10757
10772
|
onClick: props.onForgotPassword,
|
@@ -10760,14 +10775,14 @@ var LoginForm = ({
|
|
10760
10775
|
(texts == null ? void 0 : texts.forgotPassword) || "Forgot Password?"
|
10761
10776
|
)));
|
10762
10777
|
case "phone":
|
10763
|
-
return /* @__PURE__ */
|
10778
|
+
return /* @__PURE__ */ import_react65.default.createElement(import_react65.default.Fragment, null, /* @__PURE__ */ import_react65.default.createElement(
|
10764
10779
|
import_react_hook_form.Controller,
|
10765
10780
|
{
|
10766
10781
|
control,
|
10767
10782
|
name: "phone",
|
10768
10783
|
render: ({ field }) => {
|
10769
10784
|
var _a2, _b2;
|
10770
|
-
return /* @__PURE__ */
|
10785
|
+
return /* @__PURE__ */ import_react65.default.createElement(
|
10771
10786
|
PhoneInput,
|
10772
10787
|
{
|
10773
10788
|
label: ((_a2 = texts == null ? void 0 : texts.phone) == null ? void 0 : _a2.label) || "Phone Number",
|
@@ -10788,14 +10803,14 @@ var LoginForm = ({
|
|
10788
10803
|
}
|
10789
10804
|
));
|
10790
10805
|
case "link":
|
10791
|
-
return /* @__PURE__ */
|
10806
|
+
return /* @__PURE__ */ import_react65.default.createElement(import_react65.default.Fragment, null, /* @__PURE__ */ import_react65.default.createElement(
|
10792
10807
|
import_react_hook_form.Controller,
|
10793
10808
|
{
|
10794
10809
|
control,
|
10795
10810
|
name: "email",
|
10796
10811
|
render: ({ field }) => {
|
10797
10812
|
var _a2, _b2, _c2;
|
10798
|
-
return /* @__PURE__ */
|
10813
|
+
return /* @__PURE__ */ import_react65.default.createElement(
|
10799
10814
|
Input,
|
10800
10815
|
{
|
10801
10816
|
width: "full",
|
@@ -10816,7 +10831,7 @@ var LoginForm = ({
|
|
10816
10831
|
break;
|
10817
10832
|
}
|
10818
10833
|
};
|
10819
|
-
return /* @__PURE__ */
|
10834
|
+
return /* @__PURE__ */ import_react65.default.createElement("div", { className: "hawa-flex hawa-flex-col hawa-gap-4" }, /* @__PURE__ */ import_react65.default.createElement(
|
10820
10835
|
Card,
|
10821
10836
|
{
|
10822
10837
|
dir: props.direction,
|
@@ -10824,7 +10839,7 @@ var LoginForm = ({
|
|
10824
10839
|
props.cardless && "!hawa-border-none !hawa-bg-transparent !hawa-shadow-none !hawa-drop-shadow-none"
|
10825
10840
|
)
|
10826
10841
|
},
|
10827
|
-
/* @__PURE__ */
|
10842
|
+
/* @__PURE__ */ import_react65.default.createElement(CardContent, { headless: true, noPadding: props.cardless }, props.showError && /* @__PURE__ */ import_react65.default.createElement(
|
10828
10843
|
Alert,
|
10829
10844
|
{
|
10830
10845
|
direction: props.direction,
|
@@ -10832,7 +10847,7 @@ var LoginForm = ({
|
|
10832
10847
|
text: props.errorText,
|
10833
10848
|
severity: "error"
|
10834
10849
|
}
|
10835
|
-
), /* @__PURE__ */
|
10850
|
+
), /* @__PURE__ */ import_react65.default.createElement(
|
10836
10851
|
"form",
|
10837
10852
|
{
|
10838
10853
|
noValidate: true,
|
@@ -10846,7 +10861,7 @@ var LoginForm = ({
|
|
10846
10861
|
})
|
10847
10862
|
},
|
10848
10863
|
renderFields(),
|
10849
|
-
/* @__PURE__ */
|
10864
|
+
/* @__PURE__ */ import_react65.default.createElement(
|
10850
10865
|
Button,
|
10851
10866
|
{
|
10852
10867
|
className: "hawa-mt-0 hawa-w-full",
|
@@ -10856,8 +10871,8 @@ var LoginForm = ({
|
|
10856
10871
|
},
|
10857
10872
|
(texts == null ? void 0 : texts.loginText) || "Login"
|
10858
10873
|
),
|
10859
|
-
props.additionalButtons,
|
10860
|
-
props.allowRegister && /* @__PURE__ */
|
10874
|
+
props.additionalButtons && props.additionalButtons,
|
10875
|
+
props.allowRegister && /* @__PURE__ */ import_react65.default.createElement("div", { className: "hawa-select-none hawa-p-3 hawa-text-center hawa-text-sm hawa-font-normal dark:hawa-text-gray-300" }, (texts == null ? void 0 : texts.newUserText) || "New user?", " ", /* @__PURE__ */ import_react65.default.createElement(
|
10861
10876
|
"span",
|
10862
10877
|
{
|
10863
10878
|
onClick: props.onRouteToRegister,
|
@@ -10866,7 +10881,7 @@ var LoginForm = ({
|
|
10866
10881
|
(texts == null ? void 0 : texts.createAccount) || "Create Account"
|
10867
10882
|
))
|
10868
10883
|
)),
|
10869
|
-
props.viaGithub || props.viaGoogle || props.viaTwitter ? /* @__PURE__ */
|
10884
|
+
props.viaGithub || props.viaGoogle || props.viaTwitter ? /* @__PURE__ */ import_react65.default.createElement(
|
10870
10885
|
CardFooter,
|
10871
10886
|
{
|
10872
10887
|
noPadding: props.cardless,
|
@@ -10874,7 +10889,7 @@ var LoginForm = ({
|
|
10874
10889
|
props.logosOnly ? "hawa-flex hawa-flex-row hawa-justify-center hawa-gap-2" : "hawa-grid hawa-grid-cols-1 hawa-gap-2"
|
10875
10890
|
)
|
10876
10891
|
},
|
10877
|
-
/* @__PURE__ */
|
10892
|
+
/* @__PURE__ */ import_react65.default.createElement(
|
10878
10893
|
AuthButtons,
|
10879
10894
|
{
|
10880
10895
|
texts: thirdPartyAuthTexts,
|
@@ -10894,7 +10909,7 @@ var LoginForm = ({
|
|
10894
10909
|
};
|
10895
10910
|
|
10896
10911
|
// blocks/auth/RegisterForm.tsx
|
10897
|
-
var
|
10912
|
+
var import_react67 = __toESM(require("react"));
|
10898
10913
|
var import_react_hook_form2 = require("react-hook-form");
|
10899
10914
|
var import_zod2 = require("@hookform/resolvers/zod");
|
10900
10915
|
var z2 = __toESM(require("zod"));
|
@@ -10906,7 +10921,7 @@ var RegisterForm = ({
|
|
10906
10921
|
...props
|
10907
10922
|
}) => {
|
10908
10923
|
var _a, _b, _c, _d, _e, _f, _g, _h;
|
10909
|
-
const [passwordVisible, setPasswordVisible] = (0,
|
10924
|
+
const [passwordVisible, setPasswordVisible] = (0, import_react67.useState)(false);
|
10910
10925
|
const thirdPartyAuthTexts = {
|
10911
10926
|
continueWithGoogle: texts == null ? void 0 : texts.continueWithGoogle,
|
10912
10927
|
continueWithTwitter: texts == null ? void 0 : texts.continueWithTwitter,
|
@@ -10973,7 +10988,7 @@ var RegisterForm = ({
|
|
10973
10988
|
const { handleSubmit, control, formState } = (0, import_react_hook_form2.useForm)({
|
10974
10989
|
resolver: (0, import_zod2.zodResolver)(formSchema)
|
10975
10990
|
});
|
10976
|
-
return /* @__PURE__ */
|
10991
|
+
return /* @__PURE__ */ import_react67.default.createElement(
|
10977
10992
|
"div",
|
10978
10993
|
{
|
10979
10994
|
className: cn(
|
@@ -10981,7 +10996,7 @@ var RegisterForm = ({
|
|
10981
10996
|
(_g = props.classNames) == null ? void 0 : _g.root
|
10982
10997
|
)
|
10983
10998
|
},
|
10984
|
-
/* @__PURE__ */
|
10999
|
+
/* @__PURE__ */ import_react67.default.createElement(
|
10985
11000
|
Card,
|
10986
11001
|
{
|
10987
11002
|
dir: props.direction,
|
@@ -10990,7 +11005,7 @@ var RegisterForm = ({
|
|
10990
11005
|
props.cardless && "hawa-border-none hawa-bg-transparent !hawa-shadow-none !hawa-drop-shadow-none"
|
10991
11006
|
)
|
10992
11007
|
},
|
10993
|
-
/* @__PURE__ */
|
11008
|
+
/* @__PURE__ */ import_react67.default.createElement(CardContent, { headless: true, noPadding: props.cardless }, /* @__PURE__ */ import_react67.default.createElement("div", null, props.showError && /* @__PURE__ */ import_react67.default.createElement(
|
10994
11009
|
Alert,
|
10995
11010
|
{
|
10996
11011
|
direction: props.direction,
|
@@ -11003,7 +11018,7 @@ var RegisterForm = ({
|
|
11003
11018
|
}
|
11004
11019
|
}
|
11005
11020
|
}
|
11006
|
-
), /* @__PURE__ */
|
11021
|
+
), /* @__PURE__ */ import_react67.default.createElement(import_react_hook_form2.FormProvider, { ...methods }, /* @__PURE__ */ import_react67.default.createElement(
|
11007
11022
|
"form",
|
11008
11023
|
{
|
11009
11024
|
noValidate: true,
|
@@ -11018,9 +11033,9 @@ var RegisterForm = ({
|
|
11018
11033
|
}),
|
11019
11034
|
className: "hawa-flex hawa-flex-col hawa-gap-4"
|
11020
11035
|
},
|
11021
|
-
/* @__PURE__ */
|
11036
|
+
/* @__PURE__ */ import_react67.default.createElement("div", { className: "hawa-flex hawa-flex-col hawa-gap-4" }, registerFields.map((fld, i) => {
|
11022
11037
|
if (fld === "fullname") {
|
11023
|
-
return /* @__PURE__ */
|
11038
|
+
return /* @__PURE__ */ import_react67.default.createElement(
|
11024
11039
|
import_react_hook_form2.Controller,
|
11025
11040
|
{
|
11026
11041
|
key: i,
|
@@ -11028,7 +11043,7 @@ var RegisterForm = ({
|
|
11028
11043
|
name: "fullName",
|
11029
11044
|
render: ({ field }) => {
|
11030
11045
|
var _a2, _b2, _c2;
|
11031
|
-
return /* @__PURE__ */
|
11046
|
+
return /* @__PURE__ */ import_react67.default.createElement(
|
11032
11047
|
Input,
|
11033
11048
|
{
|
11034
11049
|
width: "full",
|
@@ -11043,7 +11058,7 @@ var RegisterForm = ({
|
|
11043
11058
|
);
|
11044
11059
|
}
|
11045
11060
|
if (fld === "email") {
|
11046
|
-
return /* @__PURE__ */
|
11061
|
+
return /* @__PURE__ */ import_react67.default.createElement(
|
11047
11062
|
import_react_hook_form2.Controller,
|
11048
11063
|
{
|
11049
11064
|
key: i,
|
@@ -11051,7 +11066,7 @@ var RegisterForm = ({
|
|
11051
11066
|
name: "email",
|
11052
11067
|
render: ({ field }) => {
|
11053
11068
|
var _a2, _b2, _c2;
|
11054
|
-
return /* @__PURE__ */
|
11069
|
+
return /* @__PURE__ */ import_react67.default.createElement(
|
11055
11070
|
Input,
|
11056
11071
|
{
|
11057
11072
|
dir: "ltr",
|
@@ -11076,7 +11091,7 @@ var RegisterForm = ({
|
|
11076
11091
|
);
|
11077
11092
|
}
|
11078
11093
|
if (fld === "username") {
|
11079
|
-
return /* @__PURE__ */
|
11094
|
+
return /* @__PURE__ */ import_react67.default.createElement(
|
11080
11095
|
import_react_hook_form2.Controller,
|
11081
11096
|
{
|
11082
11097
|
key: i,
|
@@ -11084,7 +11099,7 @@ var RegisterForm = ({
|
|
11084
11099
|
name: "username",
|
11085
11100
|
render: ({ field }) => {
|
11086
11101
|
var _a2, _b2, _c2, _d2;
|
11087
|
-
return /* @__PURE__ */
|
11102
|
+
return /* @__PURE__ */ import_react67.default.createElement(
|
11088
11103
|
Input,
|
11089
11104
|
{
|
11090
11105
|
width: "full",
|
@@ -11103,25 +11118,25 @@ var RegisterForm = ({
|
|
11103
11118
|
);
|
11104
11119
|
}
|
11105
11120
|
})),
|
11106
|
-
/* @__PURE__ */
|
11121
|
+
/* @__PURE__ */ import_react67.default.createElement(
|
11107
11122
|
import_react_hook_form2.Controller,
|
11108
11123
|
{
|
11109
11124
|
control,
|
11110
11125
|
name: "password",
|
11111
11126
|
render: ({ field }) => {
|
11112
11127
|
var _a2, _b2, _c2;
|
11113
|
-
return /* @__PURE__ */
|
11128
|
+
return /* @__PURE__ */ import_react67.default.createElement(
|
11114
11129
|
Input,
|
11115
11130
|
{
|
11116
11131
|
width: "full",
|
11117
11132
|
type: passwordVisible ? "text" : "password",
|
11118
|
-
endIcon: /* @__PURE__ */
|
11133
|
+
endIcon: /* @__PURE__ */ import_react67.default.createElement(
|
11119
11134
|
"div",
|
11120
11135
|
{
|
11121
11136
|
className: "hawa-cursor-pointer",
|
11122
11137
|
onClick: () => setPasswordVisible(!passwordVisible)
|
11123
11138
|
},
|
11124
|
-
passwordVisible ? /* @__PURE__ */
|
11139
|
+
passwordVisible ? /* @__PURE__ */ import_react67.default.createElement(EyeIcon, { className: "hawa-text-gray-500" }) : /* @__PURE__ */ import_react67.default.createElement(HiddenEyeIcon, { className: "hawa-text-gray-500" }),
|
11125
11140
|
" "
|
11126
11141
|
),
|
11127
11142
|
autoComplete: "new-password",
|
@@ -11134,14 +11149,14 @@ var RegisterForm = ({
|
|
11134
11149
|
}
|
11135
11150
|
}
|
11136
11151
|
),
|
11137
|
-
/* @__PURE__ */
|
11152
|
+
/* @__PURE__ */ import_react67.default.createElement(
|
11138
11153
|
import_react_hook_form2.Controller,
|
11139
11154
|
{
|
11140
11155
|
control,
|
11141
11156
|
name: "confirm_password",
|
11142
11157
|
render: ({ field }) => {
|
11143
11158
|
var _a2, _b2, _c2;
|
11144
|
-
return /* @__PURE__ */
|
11159
|
+
return /* @__PURE__ */ import_react67.default.createElement(
|
11145
11160
|
Input,
|
11146
11161
|
{
|
11147
11162
|
width: "full",
|
@@ -11157,14 +11172,14 @@ var RegisterForm = ({
|
|
11157
11172
|
}
|
11158
11173
|
),
|
11159
11174
|
props.additionalInputs,
|
11160
|
-
props.showRefCode && /* @__PURE__ */
|
11175
|
+
props.showRefCode && /* @__PURE__ */ import_react67.default.createElement(
|
11161
11176
|
import_react_hook_form2.Controller,
|
11162
11177
|
{
|
11163
11178
|
control,
|
11164
11179
|
name: "refCode",
|
11165
11180
|
render: ({ field }) => {
|
11166
11181
|
var _a2;
|
11167
|
-
return /* @__PURE__ */
|
11182
|
+
return /* @__PURE__ */ import_react67.default.createElement(
|
11168
11183
|
Input,
|
11169
11184
|
{
|
11170
11185
|
width: "full",
|
@@ -11177,14 +11192,14 @@ var RegisterForm = ({
|
|
11177
11192
|
}
|
11178
11193
|
}
|
11179
11194
|
),
|
11180
|
-
props.showUserSource && /* @__PURE__ */
|
11195
|
+
props.showUserSource && /* @__PURE__ */ import_react67.default.createElement(
|
11181
11196
|
import_react_hook_form2.Controller,
|
11182
11197
|
{
|
11183
11198
|
control,
|
11184
11199
|
name: "reference",
|
11185
11200
|
render: ({ field }) => {
|
11186
11201
|
var _a2, _b2;
|
11187
|
-
return /* @__PURE__ */
|
11202
|
+
return /* @__PURE__ */ import_react67.default.createElement(
|
11188
11203
|
Select,
|
11189
11204
|
{
|
11190
11205
|
label: ((_a2 = texts == null ? void 0 : texts.userReference) == null ? void 0 : _a2.label) || "How did you learn about us?",
|
@@ -11200,20 +11215,20 @@ var RegisterForm = ({
|
|
11200
11215
|
}
|
11201
11216
|
}
|
11202
11217
|
),
|
11203
|
-
showTermsOption || showNewsletterOption ? /* @__PURE__ */
|
11218
|
+
showTermsOption || showNewsletterOption ? /* @__PURE__ */ import_react67.default.createElement("div", { className: "hawa-flex hawa-flex-col hawa-gap-3 hawa-mb-2" }, showTermsOption && /* @__PURE__ */ import_react67.default.createElement(
|
11204
11219
|
import_react_hook_form2.Controller,
|
11205
11220
|
{
|
11206
11221
|
control,
|
11207
11222
|
name: "terms_accepted",
|
11208
11223
|
render: ({ field }) => {
|
11209
11224
|
var _a2, _b2;
|
11210
|
-
return /* @__PURE__ */
|
11225
|
+
return /* @__PURE__ */ import_react67.default.createElement(
|
11211
11226
|
Checkbox,
|
11212
11227
|
{
|
11213
11228
|
id: "terms_accepted",
|
11214
11229
|
helperText: (_b2 = (_a2 = formState.errors.terms_accepted) == null ? void 0 : _a2.message) == null ? void 0 : _b2.toString(),
|
11215
11230
|
onCheckedChange: (e) => field.onChange(e),
|
11216
|
-
label: /* @__PURE__ */
|
11231
|
+
label: /* @__PURE__ */ import_react67.default.createElement("div", { className: "hawa-flex hawa-flex-row hawa-gap-0.5 hawa-whitespace-nowrap hawa-flex-wrap" }, (texts == null ? void 0 : texts.iAcceptText) || "I accept the", " ", /* @__PURE__ */ import_react67.default.createElement(StopPropagationWrapper, null, /* @__PURE__ */ import_react67.default.createElement(
|
11217
11232
|
"span",
|
11218
11233
|
{
|
11219
11234
|
onClick: (e) => {
|
@@ -11230,12 +11245,12 @@ var RegisterForm = ({
|
|
11230
11245
|
);
|
11231
11246
|
}
|
11232
11247
|
}
|
11233
|
-
), showNewsletterOption && /* @__PURE__ */
|
11248
|
+
), showNewsletterOption && /* @__PURE__ */ import_react67.default.createElement(
|
11234
11249
|
import_react_hook_form2.Controller,
|
11235
11250
|
{
|
11236
11251
|
control,
|
11237
11252
|
name: "newsletter_accepted",
|
11238
|
-
render: ({ field }) => /* @__PURE__ */
|
11253
|
+
render: ({ field }) => /* @__PURE__ */ import_react67.default.createElement(
|
11239
11254
|
Checkbox,
|
11240
11255
|
{
|
11241
11256
|
id: "newsletter_accepted",
|
@@ -11245,7 +11260,7 @@ var RegisterForm = ({
|
|
11245
11260
|
)
|
11246
11261
|
}
|
11247
11262
|
)) : null,
|
11248
|
-
/* @__PURE__ */
|
11263
|
+
/* @__PURE__ */ import_react67.default.createElement(
|
11249
11264
|
Button,
|
11250
11265
|
{
|
11251
11266
|
className: " hawa-w-full",
|
@@ -11256,8 +11271,8 @@ var RegisterForm = ({
|
|
11256
11271
|
(texts == null ? void 0 : texts.registerText) || "Register"
|
11257
11272
|
),
|
11258
11273
|
props.additionalButtons
|
11259
|
-
)), props.onRouteToLogin && /* @__PURE__ */
|
11260
|
-
props.viaGithub || props.viaGoogle || props.viaTwitter ? /* @__PURE__ */
|
11274
|
+
)), props.onRouteToLogin && /* @__PURE__ */ import_react67.default.createElement("div", { className: "hawa-flex hawa-flex-row hawa-items-center hawa-justify-center hawa-gap-1 hawa-p-3 hawa-text-center hawa-text-sm hawa-font-normal dark:hawa-text-white" }, /* @__PURE__ */ import_react67.default.createElement("span", null, (texts == null ? void 0 : texts.existingUserText) || "Already have an account?"), /* @__PURE__ */ import_react67.default.createElement("span", { onClick: props.onRouteToLogin, className: "clickable-link" }, (texts == null ? void 0 : texts.loginText) || "Login")))),
|
11275
|
+
props.viaGithub || props.viaGoogle || props.viaTwitter ? /* @__PURE__ */ import_react67.default.createElement(
|
11261
11276
|
CardFooter,
|
11262
11277
|
{
|
11263
11278
|
noPadding: props.cardless,
|
@@ -11265,7 +11280,7 @@ var RegisterForm = ({
|
|
11265
11280
|
props.logosOnly ? "hawa-flex hawa-flex-row hawa-justify-center hawa-gap-2" : "hawa-grid hawa-grid-cols-1 hawa-gap-2"
|
11266
11281
|
)
|
11267
11282
|
},
|
11268
|
-
/* @__PURE__ */
|
11283
|
+
/* @__PURE__ */ import_react67.default.createElement(
|
11269
11284
|
AuthButtons,
|
11270
11285
|
{
|
11271
11286
|
texts: thirdPartyAuthTexts,
|
@@ -11286,7 +11301,7 @@ var RegisterForm = ({
|
|
11286
11301
|
};
|
11287
11302
|
|
11288
11303
|
// blocks/auth/AppLanding.tsx
|
11289
|
-
var
|
11304
|
+
var import_react68 = __toESM(require("react"));
|
11290
11305
|
var AppLanding = ({ texts, ...props }) => {
|
11291
11306
|
const thirdPartyAuthTexts = {
|
11292
11307
|
continueWithGoogle: texts == null ? void 0 : texts.continueWithGoogle,
|
@@ -11297,7 +11312,7 @@ var AppLanding = ({ texts, ...props }) => {
|
|
11297
11312
|
continueWithEmail: texts == null ? void 0 : texts.continueWithEmail,
|
11298
11313
|
continueWithPhone: texts == null ? void 0 : texts.continueWithPhone
|
11299
11314
|
};
|
11300
|
-
return /* @__PURE__ */
|
11315
|
+
return /* @__PURE__ */ import_react68.default.createElement("div", { dir: props.direction }, /* @__PURE__ */ import_react68.default.createElement(Card, null, /* @__PURE__ */ import_react68.default.createElement(CardContent, { headless: true, className: "hawa-flex hawa-flex-col hawa-gap-6" }, /* @__PURE__ */ import_react68.default.createElement(
|
11301
11316
|
AuthButtons,
|
11302
11317
|
{
|
11303
11318
|
texts: thirdPartyAuthTexts,
|
@@ -11316,7 +11331,7 @@ var AppLanding = ({ texts, ...props }) => {
|
|
11316
11331
|
handleEmail: props.handleEmail,
|
11317
11332
|
handlePhone: props.handlePhone
|
11318
11333
|
}
|
11319
|
-
), props.allowRegister && /* @__PURE__ */
|
11334
|
+
), props.allowRegister && /* @__PURE__ */ import_react68.default.createElement("div", { className: "hawa-p-3 hawa-text-center hawa-text-sm hawa-font-normal dark:hawa-text-gray-300" }, texts == null ? void 0 : texts.newUserText, " ", /* @__PURE__ */ import_react68.default.createElement(
|
11320
11335
|
"span",
|
11321
11336
|
{
|
11322
11337
|
onClick: props.handleRouteToRegister,
|
@@ -11327,9 +11342,9 @@ var AppLanding = ({ texts, ...props }) => {
|
|
11327
11342
|
};
|
11328
11343
|
|
11329
11344
|
// blocks/auth/CheckEmail.tsx
|
11330
|
-
var
|
11345
|
+
var import_react69 = __toESM(require("react"));
|
11331
11346
|
var CheckEmail = ({ texts, handleResend }) => {
|
11332
|
-
return /* @__PURE__ */
|
11347
|
+
return /* @__PURE__ */ import_react69.default.createElement(Card, null, /* @__PURE__ */ import_react69.default.createElement(CardContent, { headless: true }, /* @__PURE__ */ import_react69.default.createElement("div", { className: "hawa-flex hawa-flex-col hawa-items-center hawa-justify-center hawa-text-center" }, /* @__PURE__ */ import_react69.default.createElement("div", { className: "hawa-flex hawa-h-16 hawa-w-16 hawa-flex-col hawa-items-center hawa-justify-center hawa-rounded-3xl hawa-bg-primary hawa-text-6xl hawa-font-bold hawa-text-primary-foreground" }, /* @__PURE__ */ import_react69.default.createElement(
|
11333
11348
|
"svg",
|
11334
11349
|
{
|
11335
11350
|
stroke: "currentColor",
|
@@ -11342,13 +11357,13 @@ var CheckEmail = ({ texts, handleResend }) => {
|
|
11342
11357
|
width: "0.5em",
|
11343
11358
|
xmlns: "http://www.w3.org/2000/svg"
|
11344
11359
|
},
|
11345
|
-
/* @__PURE__ */
|
11346
|
-
/* @__PURE__ */
|
11347
|
-
)), /* @__PURE__ */
|
11360
|
+
/* @__PURE__ */ import_react69.default.createElement("path", { d: "M4 4h16c1.1 0 2 .9 2 2v12c0 1.1-.9 2-2 2H4c-1.1 0-2-.9-2-2V6c0-1.1.9-2 2-2z" }),
|
11361
|
+
/* @__PURE__ */ import_react69.default.createElement("polyline", { points: "22,6 12,13 2,6" })
|
11362
|
+
)), /* @__PURE__ */ import_react69.default.createElement("div", { className: "hawa-m-2 hawa-text-xl hawa-font-bold" }, (texts == null ? void 0 : texts.checkEmail) || "Check your Email"), /* @__PURE__ */ import_react69.default.createElement("div", { className: "hawa-text-sm" }, (texts == null ? void 0 : texts.pleaseVerify) || "Thank you for signing up! To complete your registration, we've sent a verification email to the address you provided. Please check your inbox and follow the instructions in the email to activate your account."))), /* @__PURE__ */ import_react69.default.createElement(CardFooter, { className: "hawa-flex hawa-flex-col hawa-justify-center " }, /* @__PURE__ */ import_react69.default.createElement("span", { className: "clickable-link hawa-text-sm", onClick: handleResend }, (texts == null ? void 0 : texts.resendEmail) || "Resend Email")));
|
11348
11363
|
};
|
11349
11364
|
|
11350
11365
|
// blocks/auth/NewPassword.tsx
|
11351
|
-
var
|
11366
|
+
var import_react70 = __toESM(require("react"));
|
11352
11367
|
var import_react_hook_form3 = require("react-hook-form");
|
11353
11368
|
var import_zod3 = require("@hookform/resolvers/zod");
|
11354
11369
|
var z3 = __toESM(require("zod"));
|
@@ -11370,7 +11385,7 @@ var NewPasswordForm = ({
|
|
11370
11385
|
const { handleSubmit, control, formState } = (0, import_react_hook_form3.useForm)({
|
11371
11386
|
resolver: (0, import_zod3.zodResolver)(formSchema)
|
11372
11387
|
});
|
11373
|
-
return /* @__PURE__ */
|
11388
|
+
return /* @__PURE__ */ import_react70.default.createElement(Card, { dir: props.direction }, props.showSuccess ? /* @__PURE__ */ import_react70.default.createElement(CardContent, { headless: true }, /* @__PURE__ */ import_react70.default.createElement("div", { className: "hawa-text-center" }, texts == null ? void 0 : texts.passwordChanged)) : /* @__PURE__ */ import_react70.default.createElement(
|
11374
11389
|
"form",
|
11375
11390
|
{
|
11376
11391
|
noValidate: true,
|
@@ -11384,7 +11399,7 @@ var NewPasswordForm = ({
|
|
11384
11399
|
}
|
11385
11400
|
})
|
11386
11401
|
},
|
11387
|
-
/* @__PURE__ */
|
11402
|
+
/* @__PURE__ */ import_react70.default.createElement(CardContent, { headless: true, className: "hawa-flex hawa-flex-col" }, props.showError && /* @__PURE__ */ import_react70.default.createElement(
|
11388
11403
|
Alert,
|
11389
11404
|
{
|
11390
11405
|
direction: props.direction,
|
@@ -11392,14 +11407,14 @@ var NewPasswordForm = ({
|
|
11392
11407
|
text: props.errorText,
|
11393
11408
|
severity: "error"
|
11394
11409
|
}
|
11395
|
-
), /* @__PURE__ */
|
11410
|
+
), /* @__PURE__ */ import_react70.default.createElement("div", { className: "hawa-flex hawa-flex-col hawa-gap-4 hawa-mb-4" }, /* @__PURE__ */ import_react70.default.createElement(
|
11396
11411
|
import_react_hook_form3.Controller,
|
11397
11412
|
{
|
11398
11413
|
control,
|
11399
11414
|
name: "password",
|
11400
11415
|
render: ({ field }) => {
|
11401
11416
|
var _a2, _b2, _c2;
|
11402
|
-
return /* @__PURE__ */
|
11417
|
+
return /* @__PURE__ */ import_react70.default.createElement(
|
11403
11418
|
Input,
|
11404
11419
|
{
|
11405
11420
|
width: "full",
|
@@ -11413,14 +11428,14 @@ var NewPasswordForm = ({
|
|
11413
11428
|
);
|
11414
11429
|
}
|
11415
11430
|
}
|
11416
|
-
), /* @__PURE__ */
|
11431
|
+
), /* @__PURE__ */ import_react70.default.createElement(
|
11417
11432
|
import_react_hook_form3.Controller,
|
11418
11433
|
{
|
11419
11434
|
control,
|
11420
11435
|
name: "confirm_password",
|
11421
11436
|
render: ({ field }) => {
|
11422
11437
|
var _a2, _b2, _c2;
|
11423
|
-
return /* @__PURE__ */
|
11438
|
+
return /* @__PURE__ */ import_react70.default.createElement(
|
11424
11439
|
Input,
|
11425
11440
|
{
|
11426
11441
|
width: "full",
|
@@ -11434,7 +11449,7 @@ var NewPasswordForm = ({
|
|
11434
11449
|
);
|
11435
11450
|
}
|
11436
11451
|
}
|
11437
|
-
)), /* @__PURE__ */
|
11452
|
+
)), /* @__PURE__ */ import_react70.default.createElement(Button, { className: "hawa-w-full", type: "submit", isLoading }, texts == null ? void 0 : texts.updatePassword), props.allowRegister && /* @__PURE__ */ import_react70.default.createElement("div", { className: "hawa-mt-4 hawa-pb-0 hawa-text-center hawa-text-sm dark:hawa-text-gray-300" }, (_g = texts == null ? void 0 : texts.dontHaveAccount) != null ? _g : "Don't have an account? ", /* @__PURE__ */ import_react70.default.createElement(
|
11438
11453
|
"span",
|
11439
11454
|
{
|
11440
11455
|
className: "clickable-link",
|
@@ -11446,7 +11461,7 @@ var NewPasswordForm = ({
|
|
11446
11461
|
};
|
11447
11462
|
|
11448
11463
|
// blocks/auth/ResetPassword.tsx
|
11449
|
-
var
|
11464
|
+
var import_react71 = __toESM(require("react"));
|
11450
11465
|
var import_react_hook_form4 = require("react-hook-form");
|
11451
11466
|
var import_zod4 = require("@hookform/resolvers/zod");
|
11452
11467
|
var z4 = __toESM(require("zod"));
|
@@ -11464,7 +11479,7 @@ var ResetPasswordForm = ({
|
|
11464
11479
|
const { handleSubmit, control, formState } = (0, import_react_hook_form4.useForm)({
|
11465
11480
|
resolver: (0, import_zod4.zodResolver)(formSchema)
|
11466
11481
|
});
|
11467
|
-
return /* @__PURE__ */
|
11482
|
+
return /* @__PURE__ */ import_react71.default.createElement(Card, { dir: props.direction }, !props.sent ? /* @__PURE__ */ import_react71.default.createElement(import_react71.default.Fragment, null, !props.headless && /* @__PURE__ */ import_react71.default.createElement(CardHeader, null, /* @__PURE__ */ import_react71.default.createElement(CardTitle, null, ((_g = props.texts) == null ? void 0 : _g.headTitle) || "Reset Password"), /* @__PURE__ */ import_react71.default.createElement(CardDescription, null, ((_h = props.texts) == null ? void 0 : _h.headDescription) || "Enter your email to reset your account password")), /* @__PURE__ */ import_react71.default.createElement(
|
11468
11483
|
"form",
|
11469
11484
|
{
|
11470
11485
|
noValidate: true,
|
@@ -11476,7 +11491,7 @@ var ResetPasswordForm = ({
|
|
11476
11491
|
}
|
11477
11492
|
})
|
11478
11493
|
},
|
11479
|
-
/* @__PURE__ */
|
11494
|
+
/* @__PURE__ */ import_react71.default.createElement(CardContent, { headless: props.headless, className: "hawa-pb-4" }, props.showError && /* @__PURE__ */ import_react71.default.createElement(
|
11480
11495
|
Alert,
|
11481
11496
|
{
|
11482
11497
|
direction: props.direction,
|
@@ -11484,14 +11499,14 @@ var ResetPasswordForm = ({
|
|
11484
11499
|
text: props.errorText,
|
11485
11500
|
severity: "error"
|
11486
11501
|
}
|
11487
|
-
), /* @__PURE__ */
|
11502
|
+
), /* @__PURE__ */ import_react71.default.createElement(
|
11488
11503
|
import_react_hook_form4.Controller,
|
11489
11504
|
{
|
11490
11505
|
control,
|
11491
11506
|
name: "email",
|
11492
11507
|
render: ({ field }) => {
|
11493
11508
|
var _a2, _b2, _c2, _d2, _e2;
|
11494
|
-
return /* @__PURE__ */
|
11509
|
+
return /* @__PURE__ */ import_react71.default.createElement(
|
11495
11510
|
Input,
|
11496
11511
|
{
|
11497
11512
|
width: "full",
|
@@ -11507,7 +11522,7 @@ var ResetPasswordForm = ({
|
|
11507
11522
|
}
|
11508
11523
|
}
|
11509
11524
|
)),
|
11510
|
-
/* @__PURE__ */
|
11525
|
+
/* @__PURE__ */ import_react71.default.createElement(CardFooter, { className: "hawa-flex hawa-flex-col" }, /* @__PURE__ */ import_react71.default.createElement(
|
11511
11526
|
Button,
|
11512
11527
|
{
|
11513
11528
|
type: "submit",
|
@@ -11515,7 +11530,7 @@ var ResetPasswordForm = ({
|
|
11515
11530
|
isLoading
|
11516
11531
|
},
|
11517
11532
|
((_i = props.texts) == null ? void 0 : _i.resetPassword) || "Reset Password"
|
11518
|
-
), allowRegister && /* @__PURE__ */
|
11533
|
+
), allowRegister && /* @__PURE__ */ import_react71.default.createElement("div", { className: "hawa-mt-4 hawa-pb-0 hawa-text-center hawa-text-sm dark:hawa-text-gray-300" }, (_k = (_j = props.texts) == null ? void 0 : _j.dontHaveAccount) != null ? _k : "Don't have an account? ", /* @__PURE__ */ import_react71.default.createElement(
|
11519
11534
|
"span",
|
11520
11535
|
{
|
11521
11536
|
className: "clickable-link",
|
@@ -11523,25 +11538,28 @@ var ResetPasswordForm = ({
|
|
11523
11538
|
},
|
11524
11539
|
(_m = (_l = props.texts) == null ? void 0 : _l.registerText) != null ? _m : "Register"
|
11525
11540
|
)))
|
11526
|
-
)) : /* @__PURE__ */
|
11541
|
+
)) : /* @__PURE__ */ import_react71.default.createElement(CardContent, { headless: true }, /* @__PURE__ */ import_react71.default.createElement("div", { className: "hawa-text-center" }, ((_n = props.texts) == null ? void 0 : _n.emailSentText) || "An email has been sent with a link to set a new password")));
|
11527
11542
|
};
|
11528
11543
|
|
11529
11544
|
// blocks/auth/CodeConfirmation.tsx
|
11530
|
-
var
|
11545
|
+
var import_react72 = __toESM(require("react"));
|
11531
11546
|
var import_react_hook_form5 = require("react-hook-form");
|
11532
11547
|
var import_zod5 = require("@hookform/resolvers/zod");
|
11533
11548
|
var z5 = __toESM(require("zod"));
|
11534
|
-
var CodeConfirmation = (
|
11549
|
+
var CodeConfirmation = ({
|
11550
|
+
codeLength = 6,
|
11551
|
+
...props
|
11552
|
+
}) => {
|
11535
11553
|
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k;
|
11536
11554
|
const formSchema = z5.object({
|
11537
|
-
otp_code: z5.string({ required_error: (_a = props.texts) == null ? void 0 : _a.codeRequiredText }).min(
|
11555
|
+
otp_code: z5.string({ required_error: (_a = props.texts) == null ? void 0 : _a.codeRequiredText }).min(codeLength, { message: (_b = props.texts) == null ? void 0 : _b.codeTooShort })
|
11538
11556
|
});
|
11539
11557
|
const { handleSubmit, control, formState, setValue } = (0, import_react_hook_form5.useForm)({
|
11540
11558
|
resolver: (0, import_zod5.zodResolver)(formSchema)
|
11541
11559
|
});
|
11542
|
-
const [resendTimer, setResendTimer] = (0,
|
11543
|
-
const [remainingTime, setRemainingTime] = (0,
|
11544
|
-
const [showResendTimer, setShowResendTimer] = (0,
|
11560
|
+
const [resendTimer, setResendTimer] = (0, import_react72.useState)(null);
|
11561
|
+
const [remainingTime, setRemainingTime] = (0, import_react72.useState)(0);
|
11562
|
+
const [showResendTimer, setShowResendTimer] = (0, import_react72.useState)(false);
|
11545
11563
|
const startResendTimer = () => {
|
11546
11564
|
if (resendTimer !== null) {
|
11547
11565
|
clearInterval(resendTimer);
|
@@ -11563,21 +11581,21 @@ var CodeConfirmation = (props) => {
|
|
11563
11581
|
}, 1e3);
|
11564
11582
|
setResendTimer(newTimer);
|
11565
11583
|
};
|
11566
|
-
(0,
|
11584
|
+
(0, import_react72.useEffect)(() => {
|
11567
11585
|
return () => {
|
11568
11586
|
if (resendTimer !== null) {
|
11569
11587
|
clearInterval(resendTimer);
|
11570
11588
|
}
|
11571
11589
|
};
|
11572
11590
|
}, []);
|
11573
|
-
return /* @__PURE__ */
|
11591
|
+
return /* @__PURE__ */ import_react72.default.createElement(Card, null, /* @__PURE__ */ import_react72.default.createElement(CardContent, { headless: true }, props.showError && /* @__PURE__ */ import_react72.default.createElement(
|
11574
11592
|
Alert,
|
11575
11593
|
{
|
11576
11594
|
title: props.errorTitle,
|
11577
11595
|
text: props.errorText,
|
11578
11596
|
severity: "error"
|
11579
11597
|
}
|
11580
|
-
), /* @__PURE__ */
|
11598
|
+
), /* @__PURE__ */ import_react72.default.createElement("div", { className: "hawa-mb-4 dark:hawa-text-white" }, /* @__PURE__ */ import_react72.default.createElement("div", { className: "hawa-text-lg hawa-font-bold" }, ((_c = props.texts) == null ? void 0 : _c.checkYourPhone) || "Please check your phone"), /* @__PURE__ */ import_react72.default.createElement("div", { className: "hawa-text-muted-foreground" }, /* @__PURE__ */ import_react72.default.createElement("span", null, ((_d = props.texts) == null ? void 0 : _d.weSentCode) || "We've sent a code to "), /* @__PURE__ */ import_react72.default.createElement("span", null, props.phoneNumber))), /* @__PURE__ */ import_react72.default.createElement(
|
11581
11599
|
"form",
|
11582
11600
|
{
|
11583
11601
|
noValidate: true,
|
@@ -11591,26 +11609,25 @@ var CodeConfirmation = (props) => {
|
|
11591
11609
|
}
|
11592
11610
|
})
|
11593
11611
|
},
|
11594
|
-
/* @__PURE__ */
|
11612
|
+
/* @__PURE__ */ import_react72.default.createElement(
|
11595
11613
|
import_react_hook_form5.Controller,
|
11596
11614
|
{
|
11597
11615
|
control,
|
11598
11616
|
name: "otp_code",
|
11599
11617
|
render: ({ field }) => {
|
11600
11618
|
var _a2;
|
11601
|
-
return /* @__PURE__ */
|
11619
|
+
return /* @__PURE__ */ import_react72.default.createElement(
|
11602
11620
|
PinInput,
|
11603
11621
|
{
|
11604
|
-
|
11605
|
-
|
11606
|
-
|
11607
|
-
helperText: (_a2 = formState.errors.otp_code) == null ? void 0 : _a2.message
|
11622
|
+
maxLength: codeLength,
|
11623
|
+
helperText: (_a2 = formState.errors.otp_code) == null ? void 0 : _a2.message,
|
11624
|
+
...field
|
11608
11625
|
}
|
11609
11626
|
);
|
11610
11627
|
}
|
11611
11628
|
}
|
11612
11629
|
),
|
11613
|
-
showResendTimer ? /* @__PURE__ */
|
11630
|
+
showResendTimer ? /* @__PURE__ */ import_react72.default.createElement("div", { className: " hawa-py-2 hawa-text-center hawa-text-xs hawa-text-muted-foreground" }, (_e = props.texts) == null ? void 0 : _e.resendCodeTimer, " ", /* @__PURE__ */ import_react72.default.createElement("strong", null, remainingTime), " ", (_f = props.texts) == null ? void 0 : _f.seconds) : /* @__PURE__ */ import_react72.default.createElement("div", { className: " hawa-py-2 hawa-text-center hawa-text-xs hawa-text-muted-foreground" }, /* @__PURE__ */ import_react72.default.createElement("span", null, (_h = (_g = props.texts) == null ? void 0 : _g.didntGetCode) != null ? _h : "Didn't get the code?"), " ", /* @__PURE__ */ import_react72.default.createElement(
|
11614
11631
|
"span",
|
11615
11632
|
{
|
11616
11633
|
className: "clickable-link",
|
@@ -11621,12 +11638,12 @@ var CodeConfirmation = (props) => {
|
|
11621
11638
|
},
|
11622
11639
|
((_i = props.texts) == null ? void 0 : _i.resendCode) || "Click to resend"
|
11623
11640
|
)),
|
11624
|
-
/* @__PURE__ */
|
11641
|
+
/* @__PURE__ */ import_react72.default.createElement("div", { className: "hawa-mt-4 hawa-grid hawa-grid-cols-2 hawa-gap-2" }, /* @__PURE__ */ import_react72.default.createElement(Button, { variant: "outline" }, ((_j = props.texts) == null ? void 0 : _j.cancel) || "Cancel"), /* @__PURE__ */ import_react72.default.createElement(Button, { isLoading: props.confirmLoading }, ((_k = props.texts) == null ? void 0 : _k.confirm) || "Confirm"))
|
11625
11642
|
)));
|
11626
11643
|
};
|
11627
11644
|
|
11628
11645
|
// blocks/feedback/UserReferralSource.tsx
|
11629
|
-
var
|
11646
|
+
var import_react73 = __toESM(require("react"));
|
11630
11647
|
var import_react_hook_form6 = require("react-hook-form");
|
11631
11648
|
var import_zod6 = require("@hookform/resolvers/zod");
|
11632
11649
|
var z6 = __toESM(require("zod"));
|
@@ -11636,8 +11653,8 @@ var UserReferralSource = ({
|
|
11636
11653
|
...props
|
11637
11654
|
}) => {
|
11638
11655
|
var _a, _b;
|
11639
|
-
const [closed, setClosed] = (0,
|
11640
|
-
const popUpRef = (0,
|
11656
|
+
const [closed, setClosed] = (0, import_react73.useState)(false);
|
11657
|
+
const popUpRef = (0, import_react73.useRef)(null);
|
11641
11658
|
const formSchema = z6.object({
|
11642
11659
|
source: z6.string({ required_error: (_a = props.texts) == null ? void 0 : _a.pleaseSelectOption }),
|
11643
11660
|
feedback: z6.string().optional()
|
@@ -11657,7 +11674,7 @@ var UserReferralSource = ({
|
|
11657
11674
|
label: "Other"
|
11658
11675
|
}
|
11659
11676
|
];
|
11660
|
-
return /* @__PURE__ */
|
11677
|
+
return /* @__PURE__ */ import_react73.default.createElement(
|
11661
11678
|
"div",
|
11662
11679
|
{
|
11663
11680
|
className: cn(
|
@@ -11666,7 +11683,7 @@ var UserReferralSource = ({
|
|
11666
11683
|
),
|
11667
11684
|
ref: popUpRef
|
11668
11685
|
},
|
11669
|
-
/* @__PURE__ */
|
11686
|
+
/* @__PURE__ */ import_react73.default.createElement(
|
11670
11687
|
Card,
|
11671
11688
|
{
|
11672
11689
|
className: cn(
|
@@ -11675,7 +11692,7 @@ var UserReferralSource = ({
|
|
11675
11692
|
),
|
11676
11693
|
dir: props.direction
|
11677
11694
|
},
|
11678
|
-
/* @__PURE__ */
|
11695
|
+
/* @__PURE__ */ import_react73.default.createElement(
|
11679
11696
|
"button",
|
11680
11697
|
{
|
11681
11698
|
type: "button",
|
@@ -11694,7 +11711,7 @@ var UserReferralSource = ({
|
|
11694
11711
|
}, 200);
|
11695
11712
|
}
|
11696
11713
|
},
|
11697
|
-
/* @__PURE__ */
|
11714
|
+
/* @__PURE__ */ import_react73.default.createElement(
|
11698
11715
|
"svg",
|
11699
11716
|
{
|
11700
11717
|
"aria-hidden": "true",
|
@@ -11702,7 +11719,7 @@ var UserReferralSource = ({
|
|
11702
11719
|
fill: "currentColor",
|
11703
11720
|
viewBox: "0 0 20 20"
|
11704
11721
|
},
|
11705
|
-
/* @__PURE__ */
|
11722
|
+
/* @__PURE__ */ import_react73.default.createElement(
|
11706
11723
|
"path",
|
11707
11724
|
{
|
11708
11725
|
fillRule: "evenodd",
|
@@ -11712,7 +11729,7 @@ var UserReferralSource = ({
|
|
11712
11729
|
)
|
11713
11730
|
)
|
11714
11731
|
),
|
11715
|
-
/* @__PURE__ */
|
11732
|
+
/* @__PURE__ */ import_react73.default.createElement(CardContent, { headless: true }, /* @__PURE__ */ import_react73.default.createElement(
|
11716
11733
|
"form",
|
11717
11734
|
{
|
11718
11735
|
noValidate: true,
|
@@ -11724,7 +11741,7 @@ var UserReferralSource = ({
|
|
11724
11741
|
}
|
11725
11742
|
})
|
11726
11743
|
},
|
11727
|
-
/* @__PURE__ */
|
11744
|
+
/* @__PURE__ */ import_react73.default.createElement(
|
11728
11745
|
"div",
|
11729
11746
|
{
|
11730
11747
|
className: cn(
|
@@ -11732,15 +11749,15 @@ var UserReferralSource = ({
|
|
11732
11749
|
closed ? "hawa-opacity-0" : "hawa-opacity-100"
|
11733
11750
|
)
|
11734
11751
|
},
|
11735
|
-
/* @__PURE__ */
|
11736
|
-
/* @__PURE__ */
|
11752
|
+
/* @__PURE__ */ import_react73.default.createElement("div", { className: "hawa-mt-4 hawa-font-bold" }, props.question),
|
11753
|
+
/* @__PURE__ */ import_react73.default.createElement("div", { className: "hawa-flex hawa-w-full hawa-flex-row hawa-gap-1 hawa-rounded " }, /* @__PURE__ */ import_react73.default.createElement(
|
11737
11754
|
import_react_hook_form6.Controller,
|
11738
11755
|
{
|
11739
11756
|
control,
|
11740
11757
|
name: "source",
|
11741
11758
|
render: ({ field }) => {
|
11742
11759
|
var _a2, _b2;
|
11743
|
-
return /* @__PURE__ */
|
11760
|
+
return /* @__PURE__ */ import_react73.default.createElement(
|
11744
11761
|
Radio,
|
11745
11762
|
{
|
11746
11763
|
name: "source",
|
@@ -11755,14 +11772,14 @@ var UserReferralSource = ({
|
|
11755
11772
|
}
|
11756
11773
|
}
|
11757
11774
|
)),
|
11758
|
-
/* @__PURE__ */
|
11775
|
+
/* @__PURE__ */ import_react73.default.createElement("div", null, /* @__PURE__ */ import_react73.default.createElement(
|
11759
11776
|
import_react_hook_form6.Controller,
|
11760
11777
|
{
|
11761
11778
|
control,
|
11762
11779
|
name: "feedback",
|
11763
11780
|
render: ({ field }) => {
|
11764
11781
|
var _a2, _b2;
|
11765
|
-
return /* @__PURE__ */
|
11782
|
+
return /* @__PURE__ */ import_react73.default.createElement(
|
11766
11783
|
Textarea,
|
11767
11784
|
{
|
11768
11785
|
...field,
|
@@ -11777,28 +11794,28 @@ var UserReferralSource = ({
|
|
11777
11794
|
}
|
11778
11795
|
))
|
11779
11796
|
),
|
11780
|
-
/* @__PURE__ */
|
11797
|
+
/* @__PURE__ */ import_react73.default.createElement(Button, { type: "submit", className: "hawa-mt-4 hawa-w-full" }, ((_b = props.texts) == null ? void 0 : _b.submit) || "Submit")
|
11781
11798
|
))
|
11782
11799
|
)
|
11783
11800
|
);
|
11784
11801
|
};
|
11785
11802
|
|
11786
11803
|
// blocks/feedback/FeedbackRating.tsx
|
11787
|
-
var
|
11804
|
+
var import_react74 = __toESM(require("react"));
|
11788
11805
|
var FeedbackRating = ({
|
11789
11806
|
position = "bottom-right",
|
11790
11807
|
...props
|
11791
11808
|
}) => {
|
11792
|
-
const [closed, setClosed] = (0,
|
11793
|
-
const [answered, setAnswered] = (0,
|
11794
|
-
const [clickedOption, setClickedOption] = (0,
|
11795
|
-
const [closingTimer, setClosingTimer] = (0,
|
11796
|
-
const popUpRef = (0,
|
11809
|
+
const [closed, setClosed] = (0, import_react74.useState)(false);
|
11810
|
+
const [answered, setAnswered] = (0, import_react74.useState)(false);
|
11811
|
+
const [clickedOption, setClickedOption] = (0, import_react74.useState)(null);
|
11812
|
+
const [closingTimer, setClosingTimer] = (0, import_react74.useState)(5);
|
11813
|
+
const popUpRef = (0, import_react74.useRef)(null);
|
11797
11814
|
const boxPosition = {
|
11798
11815
|
"bottom-right": "hawa-right-4",
|
11799
11816
|
"bottom-left": "hawa-left-4"
|
11800
11817
|
};
|
11801
|
-
(0,
|
11818
|
+
(0, import_react74.useEffect)(() => {
|
11802
11819
|
const timeoutHide = setTimeout(() => {
|
11803
11820
|
if (closingTimer >= 0) {
|
11804
11821
|
setClosingTimer(closingTimer - 1);
|
@@ -11816,7 +11833,7 @@ var FeedbackRating = ({
|
|
11816
11833
|
}
|
11817
11834
|
}, 200);
|
11818
11835
|
};
|
11819
|
-
return /* @__PURE__ */
|
11836
|
+
return /* @__PURE__ */ import_react74.default.createElement(
|
11820
11837
|
"div",
|
11821
11838
|
{
|
11822
11839
|
ref: popUpRef,
|
@@ -11825,7 +11842,7 @@ var FeedbackRating = ({
|
|
11825
11842
|
boxPosition[position]
|
11826
11843
|
)
|
11827
11844
|
},
|
11828
|
-
/* @__PURE__ */
|
11845
|
+
/* @__PURE__ */ import_react74.default.createElement(
|
11829
11846
|
"div",
|
11830
11847
|
{
|
11831
11848
|
className: cn(
|
@@ -11834,8 +11851,8 @@ var FeedbackRating = ({
|
|
11834
11851
|
props.banner && "hawa-rounded-none hawa-px-4 md:hawa-rounded-t md:hawa-px-64"
|
11835
11852
|
)
|
11836
11853
|
},
|
11837
|
-
/* @__PURE__ */
|
11838
|
-
/* @__PURE__ */
|
11854
|
+
/* @__PURE__ */ import_react74.default.createElement("div", { className: "hawa-absolute hawa-left-2 hawa-top-2 hawa-p-1.5 hawa-text-sm" }, props.title),
|
11855
|
+
/* @__PURE__ */ import_react74.default.createElement(
|
11839
11856
|
"button",
|
11840
11857
|
{
|
11841
11858
|
type: "button",
|
@@ -11844,7 +11861,7 @@ var FeedbackRating = ({
|
|
11844
11861
|
"aria-label": "Close",
|
11845
11862
|
onClick: () => slowClose()
|
11846
11863
|
},
|
11847
|
-
/* @__PURE__ */
|
11864
|
+
/* @__PURE__ */ import_react74.default.createElement(
|
11848
11865
|
"svg",
|
11849
11866
|
{
|
11850
11867
|
"aria-hidden": "true",
|
@@ -11852,7 +11869,7 @@ var FeedbackRating = ({
|
|
11852
11869
|
fill: "currentColor",
|
11853
11870
|
viewBox: "0 0 20 20"
|
11854
11871
|
},
|
11855
|
-
/* @__PURE__ */
|
11872
|
+
/* @__PURE__ */ import_react74.default.createElement(
|
11856
11873
|
"path",
|
11857
11874
|
{
|
11858
11875
|
fillRule: "evenodd",
|
@@ -11862,8 +11879,8 @@ var FeedbackRating = ({
|
|
11862
11879
|
)
|
11863
11880
|
)
|
11864
11881
|
),
|
11865
|
-
/* @__PURE__ */
|
11866
|
-
/* @__PURE__ */
|
11882
|
+
/* @__PURE__ */ import_react74.default.createElement("div", { className: "hawa-mt-8" }, props.question),
|
11883
|
+
/* @__PURE__ */ import_react74.default.createElement("div", { className: "hawa-flex hawa-w-full hawa-flex-row hawa-gap-1 hawa-rounded" }, props.options && props.options.map((op, i) => /* @__PURE__ */ import_react74.default.createElement(
|
11867
11884
|
"span",
|
11868
11885
|
{
|
11869
11886
|
key: i,
|
@@ -11891,24 +11908,24 @@ var FeedbackRating = ({
|
|
11891
11908
|
},
|
11892
11909
|
op
|
11893
11910
|
))),
|
11894
|
-
props.texts && /* @__PURE__ */
|
11895
|
-
answered && /* @__PURE__ */
|
11911
|
+
props.texts && /* @__PURE__ */ import_react74.default.createElement("div", { className: " hawa-flex hawa-flex-row hawa-justify-between hawa-text-xs" }, /* @__PURE__ */ import_react74.default.createElement("span", null, props.texts.least), /* @__PURE__ */ import_react74.default.createElement("span", null, props.texts.most)),
|
11912
|
+
answered && /* @__PURE__ */ import_react74.default.createElement("div", { className: "hawa-absolute hawa-left-0 hawa-top-0 hawa-flex hawa-h-full hawa-w-full hawa-flex-col hawa-items-center hawa-justify-center hawa-gap-2 hawa-rounded hawa-bg-black hawa-bg-opacity-80 hawa-p-4 hawa-text-center hawa-transition-all" }, /* @__PURE__ */ import_react74.default.createElement("span", { className: "hawa-font-bold hawa-text-white" }, "Thank you for your answer. This box will disappear in", " " + closingTimer, " seconds"), /* @__PURE__ */ import_react74.default.createElement("div", { className: "hawa-flex hawa-flex-row hawa-gap-2" }, /* @__PURE__ */ import_react74.default.createElement(Button, { variant: "secondary", onClick: () => slowClose() }, "Close")))
|
11896
11913
|
)
|
11897
11914
|
);
|
11898
11915
|
};
|
11899
11916
|
|
11900
11917
|
// blocks/feedback/FeedbackEmoji.tsx
|
11901
|
-
var
|
11918
|
+
var import_react75 = __toESM(require("react"));
|
11902
11919
|
var FeedbackEmoji = (props) => {
|
11903
|
-
const [selectedEmoji, setSelectedEmoji] = (0,
|
11904
|
-
const [loadingSubmit, setLoadingSubmit] = (0,
|
11905
|
-
const [feedbackText, setFeedbackText] = (0,
|
11906
|
-
const [helperText, setHelperText] = (0,
|
11920
|
+
const [selectedEmoji, setSelectedEmoji] = (0, import_react75.useState)(null);
|
11921
|
+
const [loadingSubmit, setLoadingSubmit] = (0, import_react75.useState)(false);
|
11922
|
+
const [feedbackText, setFeedbackText] = (0, import_react75.useState)("");
|
11923
|
+
const [helperText, setHelperText] = (0, import_react75.useState)(false);
|
11907
11924
|
let emojis = [
|
11908
|
-
{ icon: /* @__PURE__ */
|
11909
|
-
{ icon: /* @__PURE__ */
|
11910
|
-
{ icon: /* @__PURE__ */
|
11911
|
-
{ icon: /* @__PURE__ */
|
11925
|
+
{ icon: /* @__PURE__ */ import_react75.default.createElement(VeryGoodEmoji, null), value: "very-good" },
|
11926
|
+
{ icon: /* @__PURE__ */ import_react75.default.createElement(GoodEmoji, null), value: "good" },
|
11927
|
+
{ icon: /* @__PURE__ */ import_react75.default.createElement(BadEmoji, null), value: "bad" },
|
11928
|
+
{ icon: /* @__PURE__ */ import_react75.default.createElement(VeryBadEmoji, null), value: "very-bad" }
|
11912
11929
|
];
|
11913
11930
|
const onFeedbackSubmit = async () => {
|
11914
11931
|
if (feedbackText) {
|
@@ -11928,7 +11945,7 @@ var FeedbackEmoji = (props) => {
|
|
11928
11945
|
setHelperText(true);
|
11929
11946
|
}
|
11930
11947
|
};
|
11931
|
-
return /* @__PURE__ */
|
11948
|
+
return /* @__PURE__ */ import_react75.default.createElement(
|
11932
11949
|
"div",
|
11933
11950
|
{
|
11934
11951
|
className: cn(
|
@@ -11936,7 +11953,7 @@ var FeedbackEmoji = (props) => {
|
|
11936
11953
|
selectedEmoji ? "hawa-h-[189px] hawa-min-w-fit" : "hawa-h-[44px] "
|
11937
11954
|
)
|
11938
11955
|
},
|
11939
|
-
/* @__PURE__ */
|
11956
|
+
/* @__PURE__ */ import_react75.default.createElement("div", { className: "hawa-flex hawa-flex-row hawa-items-center hawa-justify-center hawa-gap-2 " }, /* @__PURE__ */ import_react75.default.createElement("div", { className: "hawa-flex hawa-flex-row hawa-justify-center hawa-gap-0.5 " }, emojis.map((emoji, i) => /* @__PURE__ */ import_react75.default.createElement(
|
11940
11957
|
Button,
|
11941
11958
|
{
|
11942
11959
|
key: i,
|
@@ -11955,7 +11972,7 @@ var FeedbackEmoji = (props) => {
|
|
11955
11972
|
},
|
11956
11973
|
emoji.icon
|
11957
11974
|
)))),
|
11958
|
-
/* @__PURE__ */
|
11975
|
+
/* @__PURE__ */ import_react75.default.createElement(
|
11959
11976
|
"div",
|
11960
11977
|
{
|
11961
11978
|
className: cn(
|
@@ -11963,7 +11980,7 @@ var FeedbackEmoji = (props) => {
|
|
11963
11980
|
selectedEmoji ? "hawa-visible hawa-opacity-100" : "hawa-invisible hawa-opacity-0 "
|
11964
11981
|
)
|
11965
11982
|
},
|
11966
|
-
props.showSuccess ? /* @__PURE__ */
|
11983
|
+
props.showSuccess ? /* @__PURE__ */ import_react75.default.createElement("div", { className: "hawa-flex hawa-h-full hawa-flex-col hawa-items-center hawa-justify-center hawa-gap-2 hawa-pt-4" }, /* @__PURE__ */ import_react75.default.createElement("div", { className: "hawa-rounded hawa-bg-primary hawa-p-2 hawa-text-primary-foreground" }, /* @__PURE__ */ import_react75.default.createElement(
|
11967
11984
|
"svg",
|
11968
11985
|
{
|
11969
11986
|
stroke: "currentColor",
|
@@ -11973,13 +11990,13 @@ var FeedbackEmoji = (props) => {
|
|
11973
11990
|
height: "0.5em",
|
11974
11991
|
width: "0.5em"
|
11975
11992
|
},
|
11976
|
-
/* @__PURE__ */
|
11977
|
-
)), /* @__PURE__ */
|
11993
|
+
/* @__PURE__ */ import_react75.default.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" })
|
11994
|
+
)), /* @__PURE__ */ import_react75.default.createElement("div", { className: "hawa-flex hawa-flex-col hawa-text-center hawa-text-sm" }, /* @__PURE__ */ import_react75.default.createElement("span", null, "Your feedback has been received!"), /* @__PURE__ */ import_react75.default.createElement("span", null, "Thank you for your help"))) : /* @__PURE__ */ import_react75.default.createElement("div", { className: "hawa-flex hawa-flex-col hawa-gap-1 hawa-p-1" }, /* @__PURE__ */ import_react75.default.createElement(
|
11978
11995
|
Popover,
|
11979
11996
|
{
|
11980
11997
|
className: "hawa-select-none hawa-p-1 hawa-text-xs ",
|
11981
11998
|
open: helperText,
|
11982
|
-
trigger: /* @__PURE__ */
|
11999
|
+
trigger: /* @__PURE__ */ import_react75.default.createElement(
|
11983
12000
|
Textarea,
|
11984
12001
|
{
|
11985
12002
|
classNames: {
|
@@ -11997,8 +12014,8 @@ var FeedbackEmoji = (props) => {
|
|
11997
12014
|
}
|
11998
12015
|
)
|
11999
12016
|
},
|
12000
|
-
/* @__PURE__ */
|
12001
|
-
), /* @__PURE__ */
|
12017
|
+
/* @__PURE__ */ import_react75.default.createElement("span", { className: "hawa-m-0" }, "Please enter your feedback")
|
12018
|
+
), /* @__PURE__ */ import_react75.default.createElement(
|
12002
12019
|
Button,
|
12003
12020
|
{
|
12004
12021
|
isLoading: loadingSubmit,
|
@@ -12013,7 +12030,7 @@ var FeedbackEmoji = (props) => {
|
|
12013
12030
|
};
|
12014
12031
|
|
12015
12032
|
// blocks/feedback/FeedbackForm.tsx
|
12016
|
-
var
|
12033
|
+
var import_react76 = __toESM(require("react"));
|
12017
12034
|
var import_react_hook_form7 = require("react-hook-form");
|
12018
12035
|
var import_zod7 = require("@hookform/resolvers/zod");
|
12019
12036
|
var z7 = __toESM(require("zod"));
|
@@ -12027,7 +12044,7 @@ var FeedbackForm = (props) => {
|
|
12027
12044
|
resolver: (0, import_zod7.zodResolver)(formSchema),
|
12028
12045
|
defaultValues: { requestType: "", description: "" }
|
12029
12046
|
});
|
12030
|
-
return /* @__PURE__ */
|
12047
|
+
return /* @__PURE__ */ import_react76.default.createElement(
|
12031
12048
|
Card,
|
12032
12049
|
{
|
12033
12050
|
className: cn(
|
@@ -12035,7 +12052,7 @@ var FeedbackForm = (props) => {
|
|
12035
12052
|
),
|
12036
12053
|
style: props.cardless ? { boxShadow: "none" } : void 0
|
12037
12054
|
},
|
12038
|
-
/* @__PURE__ */
|
12055
|
+
/* @__PURE__ */ import_react76.default.createElement(CardContent, { headless: true, className: props.cardless ? "!hawa-p-0" : "" }, props.sent ? /* @__PURE__ */ import_react76.default.createElement("div", { className: "hawa-text-center hawa-min-h-[200px] hawa-flex hawa-flex-col hawa-justify-center" }, /* @__PURE__ */ import_react76.default.createElement("div", { className: "hawa-font-bold hawa-text-lg" }, props.texts.sentTitle || "Form submitted"), /* @__PURE__ */ import_react76.default.createElement("div", { className: "hawa-text-md" }, props.texts.sentSubtitle || "Thank you for your submission")) : /* @__PURE__ */ import_react76.default.createElement(
|
12039
12056
|
"form",
|
12040
12057
|
{
|
12041
12058
|
noValidate: true,
|
@@ -12048,15 +12065,15 @@ var FeedbackForm = (props) => {
|
|
12048
12065
|
}),
|
12049
12066
|
className: "hawa-flex hawa-flex-col hawa-gap-2"
|
12050
12067
|
},
|
12051
|
-
/* @__PURE__ */
|
12052
|
-
/* @__PURE__ */
|
12068
|
+
/* @__PURE__ */ import_react76.default.createElement(Label2, null),
|
12069
|
+
/* @__PURE__ */ import_react76.default.createElement(
|
12053
12070
|
import_react_hook_form7.Controller,
|
12054
12071
|
{
|
12055
12072
|
name: "requestType",
|
12056
12073
|
control,
|
12057
12074
|
render: ({ field }) => {
|
12058
12075
|
var _a2, _b2, _c2, _d2, _e2, _f2, _g2, _h2;
|
12059
|
-
return /* @__PURE__ */
|
12076
|
+
return /* @__PURE__ */ import_react76.default.createElement(
|
12060
12077
|
Select,
|
12061
12078
|
{
|
12062
12079
|
...field,
|
@@ -12074,14 +12091,14 @@ var FeedbackForm = (props) => {
|
|
12074
12091
|
}
|
12075
12092
|
}
|
12076
12093
|
),
|
12077
|
-
/* @__PURE__ */
|
12094
|
+
/* @__PURE__ */ import_react76.default.createElement(
|
12078
12095
|
import_react_hook_form7.Controller,
|
12079
12096
|
{
|
12080
12097
|
name: "description",
|
12081
12098
|
control,
|
12082
12099
|
render: ({ field }) => {
|
12083
12100
|
var _a2, _b2, _c2, _d2, _e2, _f2;
|
12084
|
-
return /* @__PURE__ */
|
12101
|
+
return /* @__PURE__ */ import_react76.default.createElement(
|
12085
12102
|
Textarea,
|
12086
12103
|
{
|
12087
12104
|
helperText: formState.errors.description && ((_b2 = (_a2 = formState.errors.description) == null ? void 0 : _a2.message) == null ? void 0 : _b2.toString()),
|
@@ -12099,15 +12116,15 @@ var FeedbackForm = (props) => {
|
|
12099
12116
|
}
|
12100
12117
|
}
|
12101
12118
|
),
|
12102
|
-
/* @__PURE__ */
|
12119
|
+
/* @__PURE__ */ import_react76.default.createElement(Button, { isLoading: props.loadingSubmission, type: "submit" }, (_i = props.texts) == null ? void 0 : _i.submit)
|
12103
12120
|
))
|
12104
12121
|
);
|
12105
12122
|
};
|
12106
12123
|
|
12107
12124
|
// blocks/misc/LegalTexts.tsx
|
12108
|
-
var
|
12125
|
+
var import_react77 = __toESM(require("react"));
|
12109
12126
|
var LegalTexts = ({ tabs, ...props }) => {
|
12110
|
-
return /* @__PURE__ */
|
12127
|
+
return /* @__PURE__ */ import_react77.default.createElement(
|
12111
12128
|
Tabs,
|
12112
12129
|
{
|
12113
12130
|
value: props.activeTab,
|
@@ -12115,8 +12132,8 @@ var LegalTexts = ({ tabs, ...props }) => {
|
|
12115
12132
|
defaultValue: props.defaultTab || tabs[0].value,
|
12116
12133
|
dir: props.direction
|
12117
12134
|
},
|
12118
|
-
/* @__PURE__ */
|
12119
|
-
tabs.map((tab, index) => /* @__PURE__ */
|
12135
|
+
/* @__PURE__ */ import_react77.default.createElement(TabsList, { className: "hawa-w-full" }, tabs.map((tab, index) => /* @__PURE__ */ import_react77.default.createElement(TabsTrigger, { key: index, value: tab.value }, tab.title))),
|
12136
|
+
tabs.map((tab, index) => /* @__PURE__ */ import_react77.default.createElement(TabsContent, { key: index, value: tab.value }, /* @__PURE__ */ import_react77.default.createElement(
|
12120
12137
|
ScrollArea,
|
12121
12138
|
{
|
12122
12139
|
className: cn(
|
@@ -12130,9 +12147,9 @@ var LegalTexts = ({ tabs, ...props }) => {
|
|
12130
12147
|
};
|
12131
12148
|
|
12132
12149
|
// blocks/misc/EmptyState.tsx
|
12133
|
-
var
|
12150
|
+
var import_react78 = __toESM(require("react"));
|
12134
12151
|
var EmptyState = ({ texts, onActionClick }) => {
|
12135
|
-
return /* @__PURE__ */
|
12152
|
+
return /* @__PURE__ */ import_react78.default.createElement(Card, null, /* @__PURE__ */ import_react78.default.createElement(CardContent, { headless: true }, /* @__PURE__ */ import_react78.default.createElement("div", { className: "hawa-flex hawa-flex-col hawa-items-center hawa-justify-center hawa-text-center " }, /* @__PURE__ */ import_react78.default.createElement("div", { className: "hawa-flex hawa-h-10 hawa-w-10 hawa-flex-col hawa-items-center hawa-justify-center hawa-rounded-3xl hawa-bg-primary hawa-text-6xl hawa-font-bold hawa-text-primary-foreground" }, /* @__PURE__ */ import_react78.default.createElement(
|
12136
12153
|
"svg",
|
12137
12154
|
{
|
12138
12155
|
stroke: "currentColor",
|
@@ -12142,30 +12159,30 @@ var EmptyState = ({ texts, onActionClick }) => {
|
|
12142
12159
|
height: "0.35em",
|
12143
12160
|
width: "0.35em"
|
12144
12161
|
},
|
12145
|
-
/* @__PURE__ */
|
12146
|
-
)), /* @__PURE__ */
|
12162
|
+
/* @__PURE__ */ import_react78.default.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" })
|
12163
|
+
)), /* @__PURE__ */ import_react78.default.createElement("div", { className: "hawa-m-2 hawa-text-xl hawa-font-bold" }, (texts == null ? void 0 : texts.youreCaughtUp) || "You're all caught up"))), /* @__PURE__ */ import_react78.default.createElement(CardFooter, null, /* @__PURE__ */ import_react78.default.createElement(Button, { className: "hawa-w-full", onClick: () => onActionClick() }, (texts == null ? void 0 : texts.actionText) || "Go Home")));
|
12147
12164
|
};
|
12148
12165
|
|
12149
12166
|
// blocks/misc/Testimonial.tsx
|
12150
|
-
var
|
12167
|
+
var import_react79 = __toESM(require("react"));
|
12151
12168
|
var Testimonial = () => {
|
12152
|
-
return /* @__PURE__ */
|
12169
|
+
return /* @__PURE__ */ import_react79.default.createElement(Card, null, /* @__PURE__ */ import_react79.default.createElement(CardContent, { headless: true }, /* @__PURE__ */ import_react79.default.createElement("div", null, /* @__PURE__ */ import_react79.default.createElement("p", { className: "mb-4 max-w-sm" }, "The team at Sikka Software is simply amazing. The tech is easy to follow, easy to work with, and infinitely flexible. The solution opportunities created by Tines are endless.")), /* @__PURE__ */ import_react79.default.createElement("div", { className: "flex flex-row gap-4" }, /* @__PURE__ */ import_react79.default.createElement("svg", { width: "48", height: "48", viewBox: "0 0 48 48", fill: "none" }, /* @__PURE__ */ import_react79.default.createElement("rect", { width: "48", height: "48", rx: "24", fill: "#45BE8B" }), /* @__PURE__ */ import_react79.default.createElement(
|
12153
12170
|
"path",
|
12154
12171
|
{
|
12155
12172
|
d: "M14.1412 22.4427L17.5803 16.5199C17.7671 16.1981 18.1112 16 18.4834 16H20.8581C21.653 16 22.1565 16.8528 21.7725 17.5488L19.3042 22.0225C19.2202 22.1747 19.1762 22.3458 19.1762 22.5196C19.1762 23.0879 19.6369 23.5486 20.2052 23.5486H21.5827C22.1594 23.5486 22.627 24.0162 22.627 24.5929V31.347C22.627 31.9237 22.1594 32.3913 21.5827 32.3913H15.0443C14.4676 32.3913 14 31.9237 14 31.347V22.9671C14 22.7829 14.0487 22.602 14.1412 22.4427Z",
|
12156
12173
|
fill: "#FFFFFF"
|
12157
12174
|
}
|
12158
|
-
), /* @__PURE__ */
|
12175
|
+
), /* @__PURE__ */ import_react79.default.createElement(
|
12159
12176
|
"path",
|
12160
12177
|
{
|
12161
12178
|
d: "M25.356 22.4427L28.7951 16.5199C28.982 16.1981 29.326 16 29.6982 16H32.0729C32.8679 16 33.3713 16.8528 32.9873 17.5488L30.5191 22.0225C30.4351 22.1747 30.391 22.3458 30.391 22.5196C30.391 23.0879 30.8518 23.5486 31.4201 23.5486H32.7975C33.3743 23.5486 33.8418 24.0162 33.8418 24.5929V31.347C33.8418 31.9237 33.3743 32.3913 32.7975 32.3913H26.2592C25.6824 32.3913 25.2148 31.9237 25.2148 31.347V22.9671C25.2148 22.7829 25.2636 22.602 25.356 22.4427Z",
|
12162
12179
|
fill: "#FFFFFF"
|
12163
12180
|
}
|
12164
|
-
)), /* @__PURE__ */
|
12181
|
+
)), /* @__PURE__ */ import_react79.default.createElement("span", { className: "border border-l " }), " ", /* @__PURE__ */ import_react79.default.createElement("div", null, /* @__PURE__ */ import_react79.default.createElement("strong", null, "Brent Lassi"), /* @__PURE__ */ import_react79.default.createElement("div", null, " Chief Information Security Officer")))));
|
12165
12182
|
};
|
12166
12183
|
|
12167
12184
|
// blocks/misc/LeadGenerator.tsx
|
12168
|
-
var
|
12185
|
+
var import_react80 = __toESM(require("react"));
|
12169
12186
|
var import_react_hook_form8 = require("react-hook-form");
|
12170
12187
|
var LeadGenerator = ({ texts, submitHandler }) => {
|
12171
12188
|
var _a;
|
@@ -12177,14 +12194,14 @@ var LeadGenerator = ({ texts, submitHandler }) => {
|
|
12177
12194
|
console.log("handleNewsletterSub props was not provided");
|
12178
12195
|
}
|
12179
12196
|
};
|
12180
|
-
return /* @__PURE__ */
|
12197
|
+
return /* @__PURE__ */ import_react80.default.createElement(Card, null, /* @__PURE__ */ import_react80.default.createElement(CardHeader, null, /* @__PURE__ */ import_react80.default.createElement(CardTitle, null, texts == null ? void 0 : texts.title), /* @__PURE__ */ import_react80.default.createElement(CardDescription, null, texts == null ? void 0 : texts.subtitle)), /* @__PURE__ */ import_react80.default.createElement(CardContent, null, /* @__PURE__ */ import_react80.default.createElement(
|
12181
12198
|
"form",
|
12182
12199
|
{
|
12183
12200
|
noValidate: true,
|
12184
12201
|
className: "hawa-flex hawa-flex-row hawa-gap-2",
|
12185
12202
|
onSubmit: handleSubmit(onSubmit)
|
12186
12203
|
},
|
12187
|
-
/* @__PURE__ */
|
12204
|
+
/* @__PURE__ */ import_react80.default.createElement(
|
12188
12205
|
import_react_hook_form8.Controller,
|
12189
12206
|
{
|
12190
12207
|
name: "email",
|
@@ -12197,27 +12214,27 @@ var LeadGenerator = ({ texts, submitHandler }) => {
|
|
12197
12214
|
}
|
12198
12215
|
},
|
12199
12216
|
defaultValue: "",
|
12200
|
-
render: ({ field }) => /* @__PURE__ */
|
12217
|
+
render: ({ field }) => /* @__PURE__ */ import_react80.default.createElement(Input, { ...field, type: "email", placeholder: "example@sikka.io" })
|
12201
12218
|
}
|
12202
12219
|
),
|
12203
|
-
/* @__PURE__ */
|
12220
|
+
/* @__PURE__ */ import_react80.default.createElement(Button, { type: "submit", disabled: !formState.isValid }, (_a = texts == null ? void 0 : texts.submit) != null ? _a : "Submit")
|
12204
12221
|
)));
|
12205
12222
|
};
|
12206
12223
|
|
12207
12224
|
// blocks/misc/Announcement.tsx
|
12208
|
-
var
|
12225
|
+
var import_react81 = __toESM(require("react"));
|
12209
12226
|
var Announcement = ({
|
12210
12227
|
onActionClick,
|
12211
12228
|
...props
|
12212
12229
|
}) => {
|
12213
|
-
return /* @__PURE__ */
|
12230
|
+
return /* @__PURE__ */ import_react81.default.createElement(Card, null, /* @__PURE__ */ import_react81.default.createElement(
|
12214
12231
|
CardContent,
|
12215
12232
|
{
|
12216
12233
|
headless: true,
|
12217
12234
|
className: "hawa-flex hawa-flex-row hawa-items-center hawa-justify-between"
|
12218
12235
|
},
|
12219
|
-
/* @__PURE__ */
|
12220
|
-
/* @__PURE__ */
|
12236
|
+
/* @__PURE__ */ import_react81.default.createElement("div", { className: "hawa-flex hawa-flex-col hawa-items-start hawa-justify-center " }, /* @__PURE__ */ import_react81.default.createElement("span", { className: "hawa-text-lg hawa-font-bold" }, props.title), /* @__PURE__ */ import_react81.default.createElement("span", { className: "hawa-text-sm" }, props.subtitle)),
|
12237
|
+
/* @__PURE__ */ import_react81.default.createElement(
|
12221
12238
|
Button,
|
12222
12239
|
{
|
12223
12240
|
onClick: () => onActionClick(),
|
@@ -12229,15 +12246,15 @@ var Announcement = ({
|
|
12229
12246
|
};
|
12230
12247
|
|
12231
12248
|
// blocks/misc/NotFound.tsx
|
12232
|
-
var
|
12249
|
+
var import_react82 = __toESM(require("react"));
|
12233
12250
|
var NotFound = ({ texts }) => {
|
12234
|
-
return /* @__PURE__ */
|
12251
|
+
return /* @__PURE__ */ import_react82.default.createElement(Card, null, /* @__PURE__ */ import_react82.default.createElement(CardContent, { headless: true }, /* @__PURE__ */ import_react82.default.createElement("div", { className: "hawa-flex hawa-flex-col hawa-items-center dark:hawa-text-white" }, /* @__PURE__ */ import_react82.default.createElement("div", { className: "hawa-text-center hawa-text-6xl hawa-font-bold " }, "404"), /* @__PURE__ */ import_react82.default.createElement("div", { className: "hawa-m-2 hawa-text-center hawa-text-xl hawa-font-bold " }, (texts == null ? void 0 : texts.pageNotFound) || "Page Not Found"), /* @__PURE__ */ import_react82.default.createElement("div", { className: "hawa-mb-4 hawa-text-center" }, (texts == null ? void 0 : texts.ifLost) || /* @__PURE__ */ import_react82.default.createElement(import_react82.default.Fragment, null, "If you're lost please contact us ", /* @__PURE__ */ import_react82.default.createElement("span", { className: "clickable-link" }, "help@sikka.io"))), /* @__PURE__ */ import_react82.default.createElement(Button, { className: "hawa-w-full" }, (texts == null ? void 0 : texts.home) || "Home"))));
|
12235
12252
|
};
|
12236
12253
|
|
12237
12254
|
// blocks/misc/NoPermission.tsx
|
12238
|
-
var
|
12255
|
+
var import_react83 = __toESM(require("react"));
|
12239
12256
|
var NoPermission = ({ texts }) => {
|
12240
|
-
return /* @__PURE__ */
|
12257
|
+
return /* @__PURE__ */ import_react83.default.createElement(Card, null, /* @__PURE__ */ import_react83.default.createElement(CardContent, { headless: true }, /* @__PURE__ */ import_react83.default.createElement("div", { className: "hawa-flex hawa-flex-col hawa-items-center hawa-justify-center hawa-text-center" }, /* @__PURE__ */ import_react83.default.createElement("div", { className: "hawa-flex hawa-h-10 hawa-w-10 hawa-flex-col hawa-items-center hawa-justify-center hawa-rounded-3xl hawa-bg-primary hawa-text-6xl hawa-font-bold hawa-text-primary-foreground" }, /* @__PURE__ */ import_react83.default.createElement(
|
12241
12258
|
"svg",
|
12242
12259
|
{
|
12243
12260
|
stroke: "currentColor",
|
@@ -12247,12 +12264,12 @@ var NoPermission = ({ texts }) => {
|
|
12247
12264
|
height: "0.35em",
|
12248
12265
|
width: "0.35em"
|
12249
12266
|
},
|
12250
|
-
/* @__PURE__ */
|
12251
|
-
)), /* @__PURE__ */
|
12267
|
+
/* @__PURE__ */ import_react83.default.createElement("path", { d: "M400 224h-24v-72C376 68.2 307.8 0 224 0S72 68.2 72 152v72H48c-26.5 0-48 21.5-48 48v192c0 26.5 21.5 48 48 48h352c26.5 0 48-21.5 48-48V272c0-26.5-21.5-48-48-48zm-104 0H152v-72c0-39.7 32.3-72 72-72s72 32.3 72 72v72z" })
|
12268
|
+
)), /* @__PURE__ */ import_react83.default.createElement("div", { className: "hawa-m-2 hawa-text-xl hawa-font-bold" }, (texts == null ? void 0 : texts.title) || "You don't have permission"), /* @__PURE__ */ import_react83.default.createElement("div", null, (texts == null ? void 0 : texts.subtitle) || "If you think this is a problem please contact your administrator or our customer support"))));
|
12252
12269
|
};
|
12253
12270
|
|
12254
12271
|
// blocks/misc/ContactForm.tsx
|
12255
|
-
var
|
12272
|
+
var import_react84 = __toESM(require("react"));
|
12256
12273
|
var import_react_hook_form9 = require("react-hook-form");
|
12257
12274
|
var import_zod8 = require("@hookform/resolvers/zod");
|
12258
12275
|
var z8 = __toESM(require("zod"));
|
@@ -12325,7 +12342,7 @@ var ContactForm = ({
|
|
12325
12342
|
console.log("Form is submitted but onSubmit prop is missing");
|
12326
12343
|
}
|
12327
12344
|
};
|
12328
|
-
return /* @__PURE__ */
|
12345
|
+
return /* @__PURE__ */ import_react84.default.createElement(
|
12329
12346
|
Card,
|
12330
12347
|
{
|
12331
12348
|
className: cn(
|
@@ -12334,7 +12351,7 @@ var ContactForm = ({
|
|
12334
12351
|
),
|
12335
12352
|
style: cardless ? { boxShadow: "none" } : void 0
|
12336
12353
|
},
|
12337
|
-
/* @__PURE__ */
|
12354
|
+
/* @__PURE__ */ import_react84.default.createElement(CardContent, { headless: true, className: cardless ? "!hawa-p-0" : "" }, props.showSuccess ? /* @__PURE__ */ import_react84.default.createElement(CardHeader, null, /* @__PURE__ */ import_react84.default.createElement(CardTitle, null, ((_d = texts == null ? void 0 : texts.success) == null ? void 0 : _d.title) || "Message Sent! \u{1F389}"), /* @__PURE__ */ import_react84.default.createElement(CardDescription, null, ((_e = texts == null ? void 0 : texts.success) == null ? void 0 : _e.description) || "Thank you for your submission, we will get back to you as soon as possible.")) : /* @__PURE__ */ import_react84.default.createElement(
|
12338
12355
|
"form",
|
12339
12356
|
{
|
12340
12357
|
noValidate: true,
|
@@ -12343,7 +12360,7 @@ var ContactForm = ({
|
|
12343
12360
|
id: formId,
|
12344
12361
|
autoComplete: formAutoComplete
|
12345
12362
|
},
|
12346
|
-
/* @__PURE__ */
|
12363
|
+
/* @__PURE__ */ import_react84.default.createElement(
|
12347
12364
|
"div",
|
12348
12365
|
{
|
12349
12366
|
className: cn(
|
@@ -12354,14 +12371,14 @@ var ContactForm = ({
|
|
12354
12371
|
}
|
12355
12372
|
)
|
12356
12373
|
},
|
12357
|
-
/* @__PURE__ */
|
12374
|
+
/* @__PURE__ */ import_react84.default.createElement(
|
12358
12375
|
import_react_hook_form9.Controller,
|
12359
12376
|
{
|
12360
12377
|
control,
|
12361
12378
|
name: "name",
|
12362
12379
|
render: ({ field }) => {
|
12363
12380
|
var _a2;
|
12364
|
-
return /* @__PURE__ */
|
12381
|
+
return /* @__PURE__ */ import_react84.default.createElement(
|
12365
12382
|
Input,
|
12366
12383
|
{
|
12367
12384
|
label: (texts == null ? void 0 : texts.name.label) || "Name",
|
@@ -12374,14 +12391,14 @@ var ContactForm = ({
|
|
12374
12391
|
}
|
12375
12392
|
}
|
12376
12393
|
),
|
12377
|
-
/* @__PURE__ */
|
12394
|
+
/* @__PURE__ */ import_react84.default.createElement(
|
12378
12395
|
import_react_hook_form9.Controller,
|
12379
12396
|
{
|
12380
12397
|
control,
|
12381
12398
|
name: "email",
|
12382
12399
|
render: ({ field }) => {
|
12383
12400
|
var _a2;
|
12384
|
-
return /* @__PURE__ */
|
12401
|
+
return /* @__PURE__ */ import_react84.default.createElement(
|
12385
12402
|
Input,
|
12386
12403
|
{
|
12387
12404
|
label: (texts == null ? void 0 : texts.email.label) || "Email",
|
@@ -12397,7 +12414,7 @@ var ContactForm = ({
|
|
12397
12414
|
),
|
12398
12415
|
customFields && customFields.map((customField) => {
|
12399
12416
|
console.log("custom", customField);
|
12400
|
-
return /* @__PURE__ */
|
12417
|
+
return /* @__PURE__ */ import_react84.default.createElement(
|
12401
12418
|
import_react_hook_form9.Controller,
|
12402
12419
|
{
|
12403
12420
|
control,
|
@@ -12407,7 +12424,7 @@ var ContactForm = ({
|
|
12407
12424
|
switch (type) {
|
12408
12425
|
case "text":
|
12409
12426
|
case "number":
|
12410
|
-
return /* @__PURE__ */
|
12427
|
+
return /* @__PURE__ */ import_react84.default.createElement(
|
12411
12428
|
Input,
|
12412
12429
|
{
|
12413
12430
|
id: customField.name,
|
@@ -12418,7 +12435,7 @@ var ContactForm = ({
|
|
12418
12435
|
}
|
12419
12436
|
);
|
12420
12437
|
case "select":
|
12421
|
-
return /* @__PURE__ */
|
12438
|
+
return /* @__PURE__ */ import_react84.default.createElement(
|
12422
12439
|
Select,
|
12423
12440
|
{
|
12424
12441
|
label,
|
@@ -12428,20 +12445,20 @@ var ContactForm = ({
|
|
12428
12445
|
}
|
12429
12446
|
);
|
12430
12447
|
default:
|
12431
|
-
return /* @__PURE__ */
|
12448
|
+
return /* @__PURE__ */ import_react84.default.createElement("div", null, "Unknown type");
|
12432
12449
|
}
|
12433
12450
|
}
|
12434
12451
|
}
|
12435
12452
|
);
|
12436
12453
|
}),
|
12437
|
-
/* @__PURE__ */
|
12454
|
+
/* @__PURE__ */ import_react84.default.createElement(
|
12438
12455
|
import_react_hook_form9.Controller,
|
12439
12456
|
{
|
12440
12457
|
control,
|
12441
12458
|
name: "message",
|
12442
12459
|
render: ({ field }) => {
|
12443
12460
|
var _a2;
|
12444
|
-
return /* @__PURE__ */
|
12461
|
+
return /* @__PURE__ */ import_react84.default.createElement(
|
12445
12462
|
Textarea,
|
12446
12463
|
{
|
12447
12464
|
label: (texts == null ? void 0 : texts.message.label) || "Message",
|
@@ -12458,19 +12475,19 @@ var ContactForm = ({
|
|
12458
12475
|
}
|
12459
12476
|
}
|
12460
12477
|
),
|
12461
|
-
/* @__PURE__ */
|
12478
|
+
/* @__PURE__ */ import_react84.default.createElement(Button, { type: "submit", className: "hawa-w-full" }, (texts == null ? void 0 : texts.submit) || "Submit")
|
12462
12479
|
))
|
12463
12480
|
);
|
12464
12481
|
};
|
12465
12482
|
|
12466
12483
|
// blocks/pricing/PricingPlans.tsx
|
12467
|
-
var
|
12484
|
+
var import_react90 = __toESM(require("react"));
|
12468
12485
|
|
12469
12486
|
// blocks/cards/ActionCard.tsx
|
12470
|
-
var
|
12487
|
+
var import_react85 = __toESM(require("react"));
|
12471
12488
|
var ActionCard = (props) => {
|
12472
|
-
const [hovered, setHovered] = (0,
|
12473
|
-
return /* @__PURE__ */
|
12489
|
+
const [hovered, setHovered] = (0, import_react85.useState)(false);
|
12490
|
+
return /* @__PURE__ */ import_react85.default.createElement("div", { className: "hawa-flex hawa-h-full hawa-w-full hawa-flex-col hawa-gap-1" }, /* @__PURE__ */ import_react85.default.createElement(
|
12474
12491
|
"div",
|
12475
12492
|
{
|
12476
12493
|
className: "hawa-group hawa-relative hawa-h-full hawa-w-full hawa-rounded hawa-border hawa-bg-background hawa-bg-cover hawa-bg-center hawa-transition-all hawa-duration-500 hover:hawa-drop-shadow-2xl",
|
@@ -12480,7 +12497,7 @@ var ActionCard = (props) => {
|
|
12480
12497
|
onMouseEnter: () => setHovered(true),
|
12481
12498
|
onMouseLeave: () => setHovered(false)
|
12482
12499
|
},
|
12483
|
-
props.blank ? /* @__PURE__ */
|
12500
|
+
props.blank ? /* @__PURE__ */ import_react85.default.createElement("div", { className: "hawa-flex hawa-h-full hawa-flex-col hawa-items-center hawa-justify-center " }, /* @__PURE__ */ import_react85.default.createElement(
|
12484
12501
|
"svg",
|
12485
12502
|
{
|
12486
12503
|
className: "hawa-h-10 hawa-w-10 hawa-text-foreground",
|
@@ -12492,11 +12509,11 @@ var ActionCard = (props) => {
|
|
12492
12509
|
width: "1em",
|
12493
12510
|
xmlns: "http://www.w3.org/2000/svg"
|
12494
12511
|
},
|
12495
|
-
/* @__PURE__ */
|
12496
|
-
)) : /* @__PURE__ */
|
12497
|
-
/* @__PURE__ */
|
12498
|
-
!props.blank && /* @__PURE__ */
|
12499
|
-
), /* @__PURE__ */
|
12512
|
+
/* @__PURE__ */ import_react85.default.createElement("path", { d: "M19 11h-6V5h-2v6H5v2h6v6h2v-6h6z" })
|
12513
|
+
)) : /* @__PURE__ */ import_react85.default.createElement("div", { className: "hawa-absolute hawa-inset-0 hawa-rounded hawa-bg-black hawa-opacity-50" }),
|
12514
|
+
/* @__PURE__ */ import_react85.default.createElement("div", { className: "hawa-absolute hawa-bottom-2 hawa-right-2 hawa-z-10 hawa-opacity-0 hawa-transition-all hawa-duration-200 group-hover:hawa-opacity-100" }, props.inCardActions),
|
12515
|
+
!props.blank && /* @__PURE__ */ import_react85.default.createElement("div", { className: "hawa-relative hawa-p-4" }, /* @__PURE__ */ import_react85.default.createElement("h1", { className: "hawa-text-white" }, props.title), /* @__PURE__ */ import_react85.default.createElement("p", { className: "hawa-text-white" }, props.subtitle))
|
12516
|
+
), /* @__PURE__ */ import_react85.default.createElement(
|
12500
12517
|
"div",
|
12501
12518
|
{
|
12502
12519
|
className: `hawa-flex hawa-flex-row hawa-justify-between hawa-text-sm hawa-transition-all hawa-duration-200 ${hovered ? "hawa-opacity-100" : "hawa-opacity-0"}`
|
@@ -12506,15 +12523,15 @@ var ActionCard = (props) => {
|
|
12506
12523
|
};
|
12507
12524
|
|
12508
12525
|
// blocks/cards/AdCard.tsx
|
12509
|
-
var
|
12526
|
+
var import_react86 = __toESM(require("react"));
|
12510
12527
|
var AdCard = ({
|
12511
12528
|
orientation = "vertical",
|
12512
12529
|
...props
|
12513
12530
|
}) => {
|
12514
|
-
const adRef = (0,
|
12515
|
-
const [closed, setClosed] = (0,
|
12531
|
+
const adRef = (0, import_react86.useRef)(null);
|
12532
|
+
const [closed, setClosed] = (0, import_react86.useState)(false);
|
12516
12533
|
let duration = 0;
|
12517
|
-
(0,
|
12534
|
+
(0, import_react86.useEffect)(() => {
|
12518
12535
|
if (duration) {
|
12519
12536
|
const timeoutHide = setTimeout(() => {
|
12520
12537
|
setClosed(true);
|
@@ -12539,21 +12556,21 @@ var AdCard = ({
|
|
12539
12556
|
horizontal: "hawa-w-auto hawa-h-full hawa-bg-blue-500 hawa-rounded-inner",
|
12540
12557
|
vertical: "hawa-bg-blue-500 hawa-rounded-inner hawa-w-auto "
|
12541
12558
|
};
|
12542
|
-
return /* @__PURE__ */
|
12559
|
+
return /* @__PURE__ */ import_react86.default.createElement("div", { ref: adRef }, /* @__PURE__ */ import_react86.default.createElement(
|
12543
12560
|
"div",
|
12544
12561
|
{
|
12545
12562
|
className: cn(cardStyles[orientation], props.className),
|
12546
12563
|
onClick: props.handleClick
|
12547
12564
|
},
|
12548
|
-
/* @__PURE__ */
|
12565
|
+
/* @__PURE__ */ import_react86.default.createElement("div", { className: "hawa-flex hawa-aspect-square hawa-w-full hawa-max-w-fit hawa-items-start " }, /* @__PURE__ */ import_react86.default.createElement(
|
12549
12566
|
"img",
|
12550
12567
|
{
|
12551
12568
|
src: props.imageURL ? props.imageURL : "https://via.placeholder.com/50",
|
12552
12569
|
className: imageStyles[orientation]
|
12553
12570
|
}
|
12554
12571
|
)),
|
12555
|
-
/* @__PURE__ */
|
12556
|
-
props.canHide && /* @__PURE__ */
|
12572
|
+
/* @__PURE__ */ import_react86.default.createElement("div", { className: "hawa-w-full hawa-text-xs" }, /* @__PURE__ */ import_react86.default.createElement("div", { className: "hawa-font-bold" }, props.title), /* @__PURE__ */ import_react86.default.createElement("div", { className: "hawa-text-[12px]" }, props.description)),
|
12573
|
+
props.canHide && /* @__PURE__ */ import_react86.default.createElement(
|
12557
12574
|
"span",
|
12558
12575
|
{
|
12559
12576
|
onClick: (e) => {
|
@@ -12579,7 +12596,7 @@ var AdCard = ({
|
|
12579
12596
|
};
|
12580
12597
|
|
12581
12598
|
// blocks/cards/PricingCard.tsx
|
12582
|
-
var
|
12599
|
+
var import_react87 = __toESM(require("react"));
|
12583
12600
|
var PricingCard = ({
|
12584
12601
|
size = "medium",
|
12585
12602
|
direction = "ltr",
|
@@ -12594,13 +12611,13 @@ var PricingCard = ({
|
|
12594
12611
|
medium: "hawa-w-full hawa-rounded hawa-min-w-fit hawa-border dark:hawa-border-gray-700 hawa-bg-background ",
|
12595
12612
|
large: "hawa-w-full hawa-max-w-lg hawa-rounded hawa-border dark:hawa-border-gray-700 hawa-bg-background "
|
12596
12613
|
};
|
12597
|
-
return /* @__PURE__ */
|
12614
|
+
return /* @__PURE__ */ import_react87.default.createElement(import_react87.default.Fragment, null, props.isLoadingCard ? /* @__PURE__ */ import_react87.default.createElement(
|
12598
12615
|
Skeleton,
|
12599
12616
|
{
|
12600
12617
|
className: cn(cardSizes[size], "hawa-h-[200px]"),
|
12601
12618
|
fade: "bottom"
|
12602
12619
|
}
|
12603
|
-
) : /* @__PURE__ */
|
12620
|
+
) : /* @__PURE__ */ import_react87.default.createElement(
|
12604
12621
|
Card,
|
12605
12622
|
{
|
12606
12623
|
dir: direction,
|
@@ -12611,7 +12628,7 @@ var PricingCard = ({
|
|
12611
12628
|
recommended ? "hawa-rounded hawa-rounded-t-none" : "hawa-rounded"
|
12612
12629
|
)
|
12613
12630
|
},
|
12614
|
-
recommended && /* @__PURE__ */
|
12631
|
+
recommended && /* @__PURE__ */ import_react87.default.createElement(
|
12615
12632
|
"div",
|
12616
12633
|
{
|
12617
12634
|
className: "hawa-absolute -hawa-left-[1px] hawa-top-0 -hawa-translate-y-full hawa-rounded-t hawa-border hawa-bg-primary hawa-p-2 hawa-text-center hawa-text-primary-foreground",
|
@@ -12619,7 +12636,7 @@ var PricingCard = ({
|
|
12619
12636
|
},
|
12620
12637
|
((_a = props.texts) == null ? void 0 : _a.recommended) || "RECOMMENDED"
|
12621
12638
|
),
|
12622
|
-
/* @__PURE__ */
|
12639
|
+
/* @__PURE__ */ import_react87.default.createElement("div", { className: "hawa-flex hawa-h-full hawa-flex-col hawa-gap-4" }, /* @__PURE__ */ import_react87.default.createElement("div", { className: "hawa-text-md hawa-relative hawa-flex hawa-flex-col hawa-justify-between hawa-font-bold hawa-text-primary/70" }, /* @__PURE__ */ import_react87.default.createElement("span", null, (_b = props.texts) == null ? void 0 : _b.title), /* @__PURE__ */ import_react87.default.createElement("h5", { className: "hawa-text-sm hawa-font-normal hawa-text-primary/70" }, (_c = props.texts) == null ? void 0 : _c.subtitle), props.discount && /* @__PURE__ */ import_react87.default.createElement("span", { className: "hawa-absolute hawa-end-0" }, /* @__PURE__ */ import_react87.default.createElement(Chip, { label: props.discount, size: "large", color: "hyper" }))), /* @__PURE__ */ import_react87.default.createElement("div", { className: " hawa-flex hawa-items-baseline hawa-text-primary" }, props.isLoadingPrice ? /* @__PURE__ */ import_react87.default.createElement(Skeleton, { className: "hawa-h-[48px] hawa-w-full hawa-max-w-[200px] hawa-p-0 " }) : /* @__PURE__ */ import_react87.default.createElement(import_react87.default.Fragment, null, props.noPrice ? /* @__PURE__ */ import_react87.default.createElement("div", { className: "hawa-text-5xl hawa-font-extrabold hawa-tracking-tight" }, ((_d = props.texts) == null ? void 0 : _d.priceless) || "Contact Us") : /* @__PURE__ */ import_react87.default.createElement(import_react87.default.Fragment, null, /* @__PURE__ */ import_react87.default.createElement(import_react87.default.Fragment, null, /* @__PURE__ */ import_react87.default.createElement("div", { className: "hawa-flex hawa-flex-row hawa-items-end hawa-gap-2" }, props.oldPrice && props.oldPrice > 0 && /* @__PURE__ */ import_react87.default.createElement("span", { className: "hawa-line-through hawa-opacity-70" }, props.oldPrice + " " + ((_e = props.texts) == null ? void 0 : _e.currencyText)), /* @__PURE__ */ import_react87.default.createElement("span", { className: "hawa-text-5xl hawa-font-extrabold hawa-tracking-tight" }, props.price)), /* @__PURE__ */ import_react87.default.createElement("span", { className: "hawa-mx-1 hawa-text-sm hawa-font-semibold" }, (_f = props.texts) == null ? void 0 : _f.currencyText)), /* @__PURE__ */ import_react87.default.createElement("span", { className: "hawa-ml-1 hawa-whitespace-nowrap hawa-text-xl hawa-font-normal hawa-text-primary/70" }, "/ ", (_g = props.texts) == null ? void 0 : _g.cycleText)))), endButton && /* @__PURE__ */ import_react87.default.createElement(Separator2, null), /* @__PURE__ */ import_react87.default.createElement(
|
12623
12640
|
"div",
|
12624
12641
|
{
|
12625
12642
|
className: cn(
|
@@ -12627,9 +12644,9 @@ var PricingCard = ({
|
|
12627
12644
|
endButton ? "hawa-flex-col" : "hawa-flex-col-reverse"
|
12628
12645
|
)
|
12629
12646
|
},
|
12630
|
-
props.features && /* @__PURE__ */
|
12647
|
+
props.features && /* @__PURE__ */ import_react87.default.createElement("ul", { role: "list", className: "hawa-space-y-0 hawa-overflow-x-auto" }, (_h = props.features) == null ? void 0 : _h.map((feature, o) => {
|
12631
12648
|
var _a2;
|
12632
|
-
return /* @__PURE__ */
|
12649
|
+
return /* @__PURE__ */ import_react87.default.createElement(
|
12633
12650
|
"li",
|
12634
12651
|
{
|
12635
12652
|
key: o,
|
@@ -12638,7 +12655,7 @@ var PricingCard = ({
|
|
12638
12655
|
!feature.included && "hawa-line-through"
|
12639
12656
|
)
|
12640
12657
|
},
|
12641
|
-
/* @__PURE__ */
|
12658
|
+
/* @__PURE__ */ import_react87.default.createElement("div", { className: "hawa-flex hawa-flex-row hawa-items-center" }, feature.included ? /* @__PURE__ */ import_react87.default.createElement(
|
12642
12659
|
"svg",
|
12643
12660
|
{
|
12644
12661
|
"aria-label": "Check Icon",
|
@@ -12647,7 +12664,7 @@ var PricingCard = ({
|
|
12647
12664
|
fill: "currentColor",
|
12648
12665
|
viewBox: "0 0 20 20"
|
12649
12666
|
},
|
12650
|
-
/* @__PURE__ */
|
12667
|
+
/* @__PURE__ */ import_react87.default.createElement(
|
12651
12668
|
"path",
|
12652
12669
|
{
|
12653
12670
|
fillRule: "evenodd",
|
@@ -12655,7 +12672,7 @@ var PricingCard = ({
|
|
12655
12672
|
clipRule: "evenodd"
|
12656
12673
|
}
|
12657
12674
|
)
|
12658
|
-
) : /* @__PURE__ */
|
12675
|
+
) : /* @__PURE__ */ import_react87.default.createElement("div", { className: "hawa-m-2 hawa-mx-2.5 hawa-h-4 hawa-w-4 hawa-rounded-full hawa-bg-primary/10" }), /* @__PURE__ */ import_react87.default.createElement("span", { className: "hawa-flex hawa-flex-row hawa-items-center hawa-gap-2 hawa-whitespace-nowrap hawa-text-start hawa-font-normal hawa-leading-tight hawa-text-primary/70 " }, feature.text, " ", feature.soon && feature.included && /* @__PURE__ */ import_react87.default.createElement(
|
12659
12676
|
Chip,
|
12660
12677
|
{
|
12661
12678
|
label: ((_a2 = props.texts) == null ? void 0 : _a2.soon) || "",
|
@@ -12663,13 +12680,13 @@ var PricingCard = ({
|
|
12663
12680
|
size: "small"
|
12664
12681
|
}
|
12665
12682
|
))),
|
12666
|
-
feature.hint && /* @__PURE__ */
|
12683
|
+
feature.hint && /* @__PURE__ */ import_react87.default.createElement(
|
12667
12684
|
Tooltip,
|
12668
12685
|
{
|
12669
12686
|
content: feature.hint,
|
12670
12687
|
side: feature.hintSide
|
12671
12688
|
},
|
12672
|
-
/* @__PURE__ */
|
12689
|
+
/* @__PURE__ */ import_react87.default.createElement(
|
12673
12690
|
"svg",
|
12674
12691
|
{
|
12675
12692
|
xmlns: "http://www.w3.org/2000/svg",
|
@@ -12681,14 +12698,14 @@ var PricingCard = ({
|
|
12681
12698
|
strokeLinecap: "round",
|
12682
12699
|
strokeLinejoin: "round"
|
12683
12700
|
},
|
12684
|
-
/* @__PURE__ */
|
12685
|
-
/* @__PURE__ */
|
12686
|
-
/* @__PURE__ */
|
12701
|
+
/* @__PURE__ */ import_react87.default.createElement("circle", { cx: "12", cy: "12", r: "10" }),
|
12702
|
+
/* @__PURE__ */ import_react87.default.createElement("path", { d: "M9.09 9a3 3 0 0 1 5.83 1c0 2-3 3-3 3" }),
|
12703
|
+
/* @__PURE__ */ import_react87.default.createElement("path", { d: "M12 17h.01" })
|
12687
12704
|
)
|
12688
12705
|
)
|
12689
12706
|
);
|
12690
12707
|
})),
|
12691
|
-
/* @__PURE__ */
|
12708
|
+
/* @__PURE__ */ import_react87.default.createElement(
|
12692
12709
|
Button,
|
12693
12710
|
{
|
12694
12711
|
onClick: props.onPlanClicked,
|
@@ -12702,7 +12719,7 @@ var PricingCard = ({
|
|
12702
12719
|
};
|
12703
12720
|
|
12704
12721
|
// blocks/cards/ItemCard.tsx
|
12705
|
-
var
|
12722
|
+
var import_react88 = __toESM(require("react"));
|
12706
12723
|
var ItemCard = ({
|
12707
12724
|
actions,
|
12708
12725
|
counts,
|
@@ -12731,12 +12748,12 @@ var ItemCard = ({
|
|
12731
12748
|
)
|
12732
12749
|
};
|
12733
12750
|
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";
|
12734
|
-
const [openActionHeader, setOpenActionHeader] = (0,
|
12751
|
+
const [openActionHeader, setOpenActionHeader] = (0, import_react88.useState)(false);
|
12735
12752
|
function handleOpenActionHeader(e) {
|
12736
12753
|
e.stopPropagation();
|
12737
12754
|
setOpenActionHeader(!openActionHeader);
|
12738
12755
|
}
|
12739
|
-
(0,
|
12756
|
+
(0, import_react88.useEffect)(() => {
|
12740
12757
|
window.onclick = () => {
|
12741
12758
|
if (openActionHeader) {
|
12742
12759
|
setOpenActionHeader(false);
|
@@ -12744,7 +12761,7 @@ var ItemCard = ({
|
|
12744
12761
|
};
|
12745
12762
|
return () => window.onclick = null;
|
12746
12763
|
}, [openActionHeader]);
|
12747
|
-
return /* @__PURE__ */
|
12764
|
+
return /* @__PURE__ */ import_react88.default.createElement(
|
12748
12765
|
"div",
|
12749
12766
|
{
|
12750
12767
|
className: cn(
|
@@ -12760,7 +12777,7 @@ var ItemCard = ({
|
|
12760
12777
|
}
|
12761
12778
|
}
|
12762
12779
|
},
|
12763
|
-
cardImage && /* @__PURE__ */
|
12780
|
+
cardImage && /* @__PURE__ */ import_react88.default.createElement("div", { className: "hawa-group hawa-relative hawa-overflow-clip" }, /* @__PURE__ */ import_react88.default.createElement(
|
12764
12781
|
"img",
|
12765
12782
|
{
|
12766
12783
|
src: cardImage,
|
@@ -12769,7 +12786,7 @@ var ItemCard = ({
|
|
12769
12786
|
clickableImage ? "hawa-overflow-clip hawa-transition-all group-hover:hawa-blur-lg" : ""
|
12770
12787
|
)
|
12771
12788
|
}
|
12772
|
-
), clickableImage && /* @__PURE__ */
|
12789
|
+
), clickableImage && /* @__PURE__ */ import_react88.default.createElement(StopPropagationWrapper, null, /* @__PURE__ */ import_react88.default.createElement("div", { className: "hawa-absolute hawa-left-0 hawa-top-0 hawa-flex hawa-h-full hawa-w-full hawa-items-center hawa-justify-center hawa-opacity-0 hawa-transition-all group-hover:hawa-opacity-100 " }, /* @__PURE__ */ import_react88.default.createElement(
|
12773
12790
|
Button,
|
12774
12791
|
{
|
12775
12792
|
variant: "secondary",
|
@@ -12779,19 +12796,19 @@ var ItemCard = ({
|
|
12779
12796
|
clickableImageActionIcon,
|
12780
12797
|
clickableImageActionText || "Click"
|
12781
12798
|
)))),
|
12782
|
-
/* @__PURE__ */
|
12799
|
+
/* @__PURE__ */ import_react88.default.createElement("div", { className: "hawa-relative hawa-flex hawa-h-full hawa-w-full hawa-flex-col hawa-justify-between hawa-p-4 xs:hawa-p-6 xs:hawa-px-2 xs:hawa-pb-2" }, headerActions && /* @__PURE__ */ import_react88.default.createElement("div", { className: "hawa-absolute hawa-end-0 hawa-top-0 hawa-flex hawa-justify-end hawa-pe-3 hawa-pt-3" }, /* @__PURE__ */ import_react88.default.createElement(StopPropagationWrapper, null, /* @__PURE__ */ import_react88.default.createElement(
|
12783
12800
|
DropdownMenu,
|
12784
12801
|
{
|
12785
12802
|
items: headerActions,
|
12786
|
-
trigger: /* @__PURE__ */
|
12803
|
+
trigger: /* @__PURE__ */ import_react88.default.createElement(
|
12787
12804
|
Button,
|
12788
12805
|
{
|
12789
12806
|
variant: "ghost",
|
12790
12807
|
size: "smallIcon",
|
12791
12808
|
onClick: handleOpenActionHeader
|
12792
12809
|
},
|
12793
|
-
/* @__PURE__ */
|
12794
|
-
/* @__PURE__ */
|
12810
|
+
/* @__PURE__ */ import_react88.default.createElement("span", { className: "hawa-sr-only" }, "Open dropdown"),
|
12811
|
+
/* @__PURE__ */ import_react88.default.createElement(
|
12795
12812
|
"svg",
|
12796
12813
|
{
|
12797
12814
|
className: "hawa-h-5 hawa-w-5",
|
@@ -12799,11 +12816,11 @@ var ItemCard = ({
|
|
12799
12816
|
fill: "currentColor",
|
12800
12817
|
viewBox: "0 0 20 20"
|
12801
12818
|
},
|
12802
|
-
/* @__PURE__ */
|
12819
|
+
/* @__PURE__ */ import_react88.default.createElement("path", { d: "M10 6a2 2 0 110-4 2 2 0 010 4zM10 12a2 2 0 110-4 2 2 0 010 4zM10 18a2 2 0 110-4 2 2 0 010 4z" })
|
12803
12820
|
)
|
12804
12821
|
)
|
12805
12822
|
}
|
12806
|
-
))), /* @__PURE__ */
|
12823
|
+
))), /* @__PURE__ */ import_react88.default.createElement("div", { className: " hawa-mx-2" }, header && /* @__PURE__ */ import_react88.default.createElement("h5", { className: "hawa-mb-2 hawa-text-2xl hawa-font-bold hawa-tracking-tight " }, header), content && /* @__PURE__ */ import_react88.default.createElement("span", { className: "hawa-w-full hawa-font-normal " }, content)), actions || counts ? /* @__PURE__ */ import_react88.default.createElement(
|
12807
12824
|
"div",
|
12808
12825
|
{
|
12809
12826
|
className: cn(
|
@@ -12813,15 +12830,15 @@ var ItemCard = ({
|
|
12813
12830
|
)
|
12814
12831
|
},
|
12815
12832
|
counts,
|
12816
|
-
/* @__PURE__ */
|
12833
|
+
/* @__PURE__ */ import_react88.default.createElement(StopPropagationWrapper, null, actions)
|
12817
12834
|
) : null)
|
12818
12835
|
);
|
12819
12836
|
};
|
12820
12837
|
|
12821
12838
|
// blocks/cards/LandingCard.tsx
|
12822
|
-
var
|
12839
|
+
var import_react89 = __toESM(require("react"));
|
12823
12840
|
var LandingCard = (props) => {
|
12824
|
-
return /* @__PURE__ */
|
12841
|
+
return /* @__PURE__ */ import_react89.default.createElement(Card, { className: props.className }, /* @__PURE__ */ import_react89.default.createElement(CardHeader, null, props.icon, /* @__PURE__ */ import_react89.default.createElement(CardTitle, null, props.title), /* @__PURE__ */ import_react89.default.createElement(CardDescription, null, props.subtitle)));
|
12825
12842
|
};
|
12826
12843
|
|
12827
12844
|
// blocks/pricing/PricingPlans.tsx
|
@@ -12830,7 +12847,7 @@ var PricingPlans = ({
|
|
12830
12847
|
cardsContainerProps,
|
12831
12848
|
...props
|
12832
12849
|
}) => {
|
12833
|
-
return /* @__PURE__ */
|
12850
|
+
return /* @__PURE__ */ import_react90.default.createElement("div", { ...mainContainerProps }, /* @__PURE__ */ import_react90.default.createElement("div", { className: "hawa-mb-2 hawa-flex hawa-w-full hawa-justify-between" }, /* @__PURE__ */ import_react90.default.createElement(
|
12834
12851
|
Radio,
|
12835
12852
|
{
|
12836
12853
|
name: "cycle",
|
@@ -12843,7 +12860,7 @@ var PricingPlans = ({
|
|
12843
12860
|
}
|
12844
12861
|
}
|
12845
12862
|
}
|
12846
|
-
), /* @__PURE__ */
|
12863
|
+
), /* @__PURE__ */ import_react90.default.createElement(
|
12847
12864
|
Radio,
|
12848
12865
|
{
|
12849
12866
|
name: "currency",
|
@@ -12856,7 +12873,7 @@ var PricingPlans = ({
|
|
12856
12873
|
}
|
12857
12874
|
}
|
12858
12875
|
}
|
12859
|
-
)), /* @__PURE__ */
|
12876
|
+
)), /* @__PURE__ */ import_react90.default.createElement(
|
12860
12877
|
"div",
|
12861
12878
|
{
|
12862
12879
|
className: "hawa-inline-grid hawa-w-full hawa-grid-cols-[repeat(auto-fit,_minmax(300px,_1fr))] hawa-gap-4",
|
@@ -12864,7 +12881,7 @@ var PricingPlans = ({
|
|
12864
12881
|
},
|
12865
12882
|
props.plans.map((plan, index) => {
|
12866
12883
|
var _a, _b;
|
12867
|
-
return /* @__PURE__ */
|
12884
|
+
return /* @__PURE__ */ import_react90.default.createElement(
|
12868
12885
|
PricingCard,
|
12869
12886
|
{
|
12870
12887
|
key: index,
|
@@ -12895,7 +12912,7 @@ var PricingPlans = ({
|
|
12895
12912
|
};
|
12896
12913
|
|
12897
12914
|
// blocks/pricing/ComparingPlans.tsx
|
12898
|
-
var
|
12915
|
+
var import_react91 = __toESM(require("react"));
|
12899
12916
|
var ComparingPlans = (props) => {
|
12900
12917
|
const uniqueFeatures = Array.from(
|
12901
12918
|
new Set(
|
@@ -12904,7 +12921,7 @@ var ComparingPlans = (props) => {
|
|
12904
12921
|
)
|
12905
12922
|
)
|
12906
12923
|
);
|
12907
|
-
return /* @__PURE__ */
|
12924
|
+
return /* @__PURE__ */ import_react91.default.createElement("div", { id: "detailed-pricing", className: "hawa-w-full" }, /* @__PURE__ */ import_react91.default.createElement("div", { className: "hawa-mb-2 hawa-flex hawa-w-full hawa-flex-col hawa-justify-between hawa-gap-2 sm:hawa-flex-row" }, /* @__PURE__ */ import_react91.default.createElement(
|
12908
12925
|
Radio,
|
12909
12926
|
{
|
12910
12927
|
name: "cycle",
|
@@ -12919,7 +12936,7 @@ var ComparingPlans = (props) => {
|
|
12919
12936
|
}
|
12920
12937
|
}
|
12921
12938
|
}
|
12922
|
-
), /* @__PURE__ */
|
12939
|
+
), /* @__PURE__ */ import_react91.default.createElement(
|
12923
12940
|
Radio,
|
12924
12941
|
{
|
12925
12942
|
name: "currency",
|
@@ -12934,7 +12951,7 @@ var ComparingPlans = (props) => {
|
|
12934
12951
|
}
|
12935
12952
|
}
|
12936
12953
|
}
|
12937
|
-
)), /* @__PURE__ */
|
12954
|
+
)), /* @__PURE__ */ import_react91.default.createElement(
|
12938
12955
|
"div",
|
12939
12956
|
{
|
12940
12957
|
className: cn(
|
@@ -12945,16 +12962,16 @@ var ComparingPlans = (props) => {
|
|
12945
12962
|
top: props.topPosition || 0
|
12946
12963
|
}
|
12947
12964
|
},
|
12948
|
-
/* @__PURE__ */
|
12949
|
-
props.plans.map((plan, i) => /* @__PURE__ */
|
12965
|
+
/* @__PURE__ */ import_react91.default.createElement("div", { className: "hawa-flex hawa-items-center" }),
|
12966
|
+
props.plans.map((plan, i) => /* @__PURE__ */ import_react91.default.createElement(
|
12950
12967
|
"div",
|
12951
12968
|
{
|
12952
12969
|
key: i,
|
12953
12970
|
className: "hawa-flex hawa-flex-col hawa-items-center hawa-justify-center hawa-gap-2"
|
12954
12971
|
},
|
12955
|
-
/* @__PURE__ */
|
12972
|
+
/* @__PURE__ */ import_react91.default.createElement("div", { className: "hawa-flex hawa-flex-col hawa-gap-2" }, /* @__PURE__ */ import_react91.default.createElement("div", { className: "hawa-flex hawa-flex-col" }, /* @__PURE__ */ import_react91.default.createElement("span", { className: "hawa-text-md hawa-font-bold " }, plan.texts.title), /* @__PURE__ */ import_react91.default.createElement("span", { className: "hawa-text-md hawa-font-normal hawa-text-muted-foreground " }, plan.texts.subtitle)), /* @__PURE__ */ import_react91.default.createElement("div", { className: " hawa-flex hawa-items-baseline " }, /* @__PURE__ */ import_react91.default.createElement(import_react91.default.Fragment, null, /* @__PURE__ */ import_react91.default.createElement("span", { className: "hawa-text-5xl hawa-font-extrabold hawa-tracking-tight" }, plan.price), /* @__PURE__ */ import_react91.default.createElement("span", { className: "hawa-mx-1 hawa-text-sm hawa-font-semibold" }, plan.texts.currencyText)), /* @__PURE__ */ import_react91.default.createElement("span", { className: "hawa-ml-1 hawa-text-xl hawa-font-normal " }, "/ ", plan.texts.cycleText)))
|
12956
12973
|
))
|
12957
|
-
), /* @__PURE__ */
|
12974
|
+
), /* @__PURE__ */ import_react91.default.createElement(
|
12958
12975
|
ScrollArea,
|
12959
12976
|
{
|
12960
12977
|
className: "hawa-h-fit hawa-rounded hawa-rounded-t-none hawa-border hawa-border-t-0 hawa-bg-background",
|
@@ -12962,7 +12979,7 @@ var ComparingPlans = (props) => {
|
|
12962
12979
|
},
|
12963
12980
|
uniqueFeatures.map((featureText, featureIndex) => {
|
12964
12981
|
var _a, _b, _c, _d;
|
12965
|
-
return /* @__PURE__ */
|
12982
|
+
return /* @__PURE__ */ import_react91.default.createElement(
|
12966
12983
|
"div",
|
12967
12984
|
{
|
12968
12985
|
key: featureIndex,
|
@@ -12971,11 +12988,11 @@ var ComparingPlans = (props) => {
|
|
12971
12988
|
featureIndex === 0 ? "" : "hawa-border-t"
|
12972
12989
|
)
|
12973
12990
|
},
|
12974
|
-
/* @__PURE__ */
|
12991
|
+
/* @__PURE__ */ import_react91.default.createElement("div", { className: "hawa-flex hawa-flex-row hawa-items-center hawa-gap-2 hawa-text-foreground" }, featureText, props.plans.some(
|
12975
12992
|
(plan) => plan.features.some(
|
12976
12993
|
(feature) => feature.text === featureText && feature.hint
|
12977
12994
|
)
|
12978
|
-
) && /* @__PURE__ */
|
12995
|
+
) && /* @__PURE__ */ import_react91.default.createElement(
|
12979
12996
|
Tooltip,
|
12980
12997
|
{
|
12981
12998
|
side: "right",
|
@@ -12990,7 +13007,7 @@ var ComparingPlans = (props) => {
|
|
12990
13007
|
(feature) => feature.text === featureText
|
12991
13008
|
)) == null ? void 0 : _b.hint
|
12992
13009
|
},
|
12993
|
-
/* @__PURE__ */
|
13010
|
+
/* @__PURE__ */ import_react91.default.createElement(
|
12994
13011
|
"svg",
|
12995
13012
|
{
|
12996
13013
|
stroke: "currentColor",
|
@@ -13000,13 +13017,13 @@ var ComparingPlans = (props) => {
|
|
13000
13017
|
height: "1em",
|
13001
13018
|
width: "1em"
|
13002
13019
|
},
|
13003
|
-
/* @__PURE__ */
|
13020
|
+
/* @__PURE__ */ import_react91.default.createElement("path", { d: "M16 8A8 8 0 1 1 0 8a8 8 0 0 1 16 0zM8 4a.905.905 0 0 0-.9.995l.35 3.507a.552.552 0 0 0 1.1 0l.35-3.507A.905.905 0 0 0 8 4zm.002 6a1 1 0 1 0 0 2 1 1 0 0 0 0-2z" })
|
13004
13021
|
)
|
13005
13022
|
), props.plans.some(
|
13006
13023
|
(plan) => plan.features.some(
|
13007
13024
|
(feature) => feature.text === featureText && feature.soon
|
13008
13025
|
)
|
13009
|
-
) && /* @__PURE__ */
|
13026
|
+
) && /* @__PURE__ */ import_react91.default.createElement(
|
13010
13027
|
Chip,
|
13011
13028
|
{
|
13012
13029
|
label: ((_d = (_c = props.plans.find(
|
@@ -13020,26 +13037,26 @@ var ComparingPlans = (props) => {
|
|
13020
13037
|
const feature = plan.features.find(
|
13021
13038
|
(f) => f.text === featureText
|
13022
13039
|
);
|
13023
|
-
return /* @__PURE__ */
|
13040
|
+
return /* @__PURE__ */ import_react91.default.createElement(
|
13024
13041
|
"div",
|
13025
13042
|
{
|
13026
13043
|
key: planIndex,
|
13027
13044
|
className: "hawa-flex hawa-flex-col hawa-items-center hawa-text-center"
|
13028
13045
|
},
|
13029
|
-
(feature == null ? void 0 : feature.included) ? /* @__PURE__ */
|
13046
|
+
(feature == null ? void 0 : feature.included) ? /* @__PURE__ */ import_react91.default.createElement(CheckMark, { className: "hawa-text-foreground" }) : /* @__PURE__ */ import_react91.default.createElement(UncheckMark, { className: "hawa-text-foreground" })
|
13030
13047
|
);
|
13031
13048
|
})
|
13032
13049
|
);
|
13033
13050
|
})
|
13034
|
-
), props.showButtons && /* @__PURE__ */
|
13051
|
+
), props.showButtons && /* @__PURE__ */ import_react91.default.createElement("div", { className: "hawa-grid hawa-grid-cols-[1fr_repeat(3,_minmax(0,_1fr))] hawa-gap-x-16 hawa-px-4 hawa-py-5" }, /* @__PURE__ */ import_react91.default.createElement("div", { className: "hawa-flex hawa-items-center" }), props.plans.map((plan, i) => {
|
13035
13052
|
var _a;
|
13036
|
-
return /* @__PURE__ */
|
13053
|
+
return /* @__PURE__ */ import_react91.default.createElement(
|
13037
13054
|
"div",
|
13038
13055
|
{
|
13039
13056
|
key: i,
|
13040
13057
|
className: "hawa-flex hawa-items-center hawa-justify-center"
|
13041
13058
|
},
|
13042
|
-
/* @__PURE__ */
|
13059
|
+
/* @__PURE__ */ import_react91.default.createElement(
|
13043
13060
|
Button,
|
13044
13061
|
{
|
13045
13062
|
className: "hawa-w-full hawa-max-w-xs",
|
@@ -13063,15 +13080,15 @@ var ComparingPlans = (props) => {
|
|
13063
13080
|
};
|
13064
13081
|
|
13065
13082
|
// blocks/pricing/HorizontalPricing.tsx
|
13066
|
-
var
|
13083
|
+
var import_react92 = __toESM(require("react"));
|
13067
13084
|
var HorizontalPricing = (props) => {
|
13068
|
-
const [selectedCard, setSelectedCard] = (0,
|
13085
|
+
const [selectedCard, setSelectedCard] = (0, import_react92.useState)("");
|
13069
13086
|
let data = [
|
13070
13087
|
{ title: "basic", price: "$49", cycle: "/mo" },
|
13071
13088
|
{ title: "business", price: "$99", cycle: "/mo" },
|
13072
13089
|
{ title: "enterprise", price: "$149", cycle: "/mo" }
|
13073
13090
|
];
|
13074
|
-
return /* @__PURE__ */
|
13091
|
+
return /* @__PURE__ */ import_react92.default.createElement("div", { className: "hawa-z-10 hawa-w-full hawa-max-w-screen-sm" }, /* @__PURE__ */ import_react92.default.createElement("div", { className: "hawa-max-w-2xl " }, /* @__PURE__ */ import_react92.default.createElement("div", { className: "hawa-flex hawa-flex-row hawa-justify-between" }, /* @__PURE__ */ import_react92.default.createElement(
|
13075
13092
|
Radio,
|
13076
13093
|
{
|
13077
13094
|
name: "currency",
|
@@ -13079,7 +13096,7 @@ var HorizontalPricing = (props) => {
|
|
13079
13096
|
options: props.currencies,
|
13080
13097
|
defaultValue: props.currentCurrency
|
13081
13098
|
}
|
13082
|
-
), /* @__PURE__ */
|
13099
|
+
), /* @__PURE__ */ import_react92.default.createElement(
|
13083
13100
|
Radio,
|
13084
13101
|
{
|
13085
13102
|
name: "cycle",
|
@@ -13087,7 +13104,7 @@ var HorizontalPricing = (props) => {
|
|
13087
13104
|
options: props.billingCycles,
|
13088
13105
|
defaultValue: props.currentCycle
|
13089
13106
|
}
|
13090
|
-
)), data.map((d, i) => /* @__PURE__ */
|
13107
|
+
)), data.map((d, i) => /* @__PURE__ */ import_react92.default.createElement(
|
13091
13108
|
"label",
|
13092
13109
|
{
|
13093
13110
|
key: i,
|
@@ -13095,7 +13112,7 @@ var HorizontalPricing = (props) => {
|
|
13095
13112
|
className: "",
|
13096
13113
|
onClick: () => setSelectedCard(d.title)
|
13097
13114
|
},
|
13098
|
-
/* @__PURE__ */
|
13115
|
+
/* @__PURE__ */ import_react92.default.createElement(
|
13099
13116
|
"input",
|
13100
13117
|
{
|
13101
13118
|
type: "radio",
|
@@ -13104,7 +13121,7 @@ var HorizontalPricing = (props) => {
|
|
13104
13121
|
className: "hawa-peer hawa-appearance-none"
|
13105
13122
|
}
|
13106
13123
|
),
|
13107
|
-
/* @__PURE__ */
|
13124
|
+
/* @__PURE__ */ import_react92.default.createElement(
|
13108
13125
|
"div",
|
13109
13126
|
{
|
13110
13127
|
className: cn(
|
@@ -13112,18 +13129,18 @@ var HorizontalPricing = (props) => {
|
|
13112
13129
|
"hawa-peer hawa-flex hawa-cursor-pointer hawa-items-center hawa-justify-between hawa-rounded-xl hawa-border hawa-bg-background hawa-px-5 hawa-py-4 hawa-shadow dark:hawa-text-white peer-checked:[&_.active]:hawa-block peer-checked:[&_.default]:hawa-hidden"
|
13113
13130
|
)
|
13114
13131
|
},
|
13115
|
-
/* @__PURE__ */
|
13132
|
+
/* @__PURE__ */ import_react92.default.createElement("div", { className: "hawa-peer hawa-flex hawa-items-center hawa-gap-4" }, /* @__PURE__ */ import_react92.default.createElement(CheckIcons, null), /* @__PURE__ */ import_react92.default.createElement(
|
13116
13133
|
CardText,
|
13117
13134
|
{
|
13118
13135
|
title: "Enterprise",
|
13119
13136
|
subtitle: "For startups and new businesses"
|
13120
13137
|
}
|
13121
13138
|
)),
|
13122
|
-
/* @__PURE__ */
|
13139
|
+
/* @__PURE__ */ import_react92.default.createElement(CardPrice, { amount: d.price, cycle: d.cycle })
|
13123
13140
|
)
|
13124
13141
|
))));
|
13125
13142
|
};
|
13126
|
-
var CheckIcons = () => /* @__PURE__ */
|
13143
|
+
var CheckIcons = () => /* @__PURE__ */ import_react92.default.createElement(import_react92.default.Fragment, null, /* @__PURE__ */ import_react92.default.createElement(
|
13127
13144
|
"svg",
|
13128
13145
|
{
|
13129
13146
|
fill: "none",
|
@@ -13132,7 +13149,7 @@ var CheckIcons = () => /* @__PURE__ */ import_react91.default.createElement(impo
|
|
13132
13149
|
stroke: "currentColor",
|
13133
13150
|
className: "hawa-default hawa-h-8 hawa-w-8 hawa-text-neutral-500"
|
13134
13151
|
},
|
13135
|
-
/* @__PURE__ */
|
13152
|
+
/* @__PURE__ */ import_react92.default.createElement(
|
13136
13153
|
"path",
|
13137
13154
|
{
|
13138
13155
|
strokeLinecap: "round",
|
@@ -13140,14 +13157,14 @@ var CheckIcons = () => /* @__PURE__ */ import_react91.default.createElement(impo
|
|
13140
13157
|
d: "M9 12.75L11.25 15 15 9.75M21 12a9 9 0 11-18 0 9 9 0 0118 0z"
|
13141
13158
|
}
|
13142
13159
|
)
|
13143
|
-
), /* @__PURE__ */
|
13160
|
+
), /* @__PURE__ */ import_react92.default.createElement(
|
13144
13161
|
"svg",
|
13145
13162
|
{
|
13146
13163
|
viewBox: "0 0 24 24",
|
13147
13164
|
fill: "currentColor",
|
13148
13165
|
className: "hawa-active hawa-hidden hawa-h-8 hawa-w-8 hawa-text-blue-500"
|
13149
13166
|
},
|
13150
|
-
/* @__PURE__ */
|
13167
|
+
/* @__PURE__ */ import_react92.default.createElement(
|
13151
13168
|
"path",
|
13152
13169
|
{
|
13153
13170
|
fillRule: "evenodd",
|
@@ -13156,14 +13173,14 @@ var CheckIcons = () => /* @__PURE__ */ import_react91.default.createElement(impo
|
|
13156
13173
|
}
|
13157
13174
|
)
|
13158
13175
|
));
|
13159
|
-
var CardText = (props) => /* @__PURE__ */
|
13160
|
-
var CardPrice = (props) => /* @__PURE__ */
|
13176
|
+
var CardText = (props) => /* @__PURE__ */ import_react92.default.createElement("div", { className: "hawa-peer hawa-flex hawa-flex-col hawa-items-start " }, /* @__PURE__ */ import_react92.default.createElement("h2", { className: "hawa-font-medium hawa-text-primary/90 sm:hawa-text-xl" }, props.title), /* @__PURE__ */ import_react92.default.createElement("p", { className: "hawa-text-sm hawa-text-primary/60" }, props.subtitle, " "));
|
13177
|
+
var CardPrice = (props) => /* @__PURE__ */ import_react92.default.createElement("h2", { className: "hawa-peer hawa-text-xl hawa-font-semibold hawa-text-primary sm:hawa-text-2xl" }, props.amount, /* @__PURE__ */ import_react92.default.createElement("span", { className: "hawa-text-base hawa-font-medium hawa-text-neutral-400" }, props.cycle));
|
13161
13178
|
|
13162
13179
|
// blocks/Usage.tsx
|
13163
|
-
var
|
13180
|
+
var import_react93 = __toESM(require("react"));
|
13164
13181
|
var Usage = (props) => {
|
13165
13182
|
var _a;
|
13166
|
-
return /* @__PURE__ */
|
13183
|
+
return /* @__PURE__ */ import_react93.default.createElement("div", { className: "hawa-flex hawa-w-full hawa-flex-col hawa-gap-1 hawa-rounded hawa-border hawa-bg-card hawa-p-4" }, /* @__PURE__ */ import_react93.default.createElement("div", { className: "hawa-flex hawa-flex-row hawa-items-center hawa-gap-2" }, /* @__PURE__ */ import_react93.default.createElement("span", { className: "hawa-bg-white-200" }, props.title), props.tooltip && /* @__PURE__ */ import_react93.default.createElement(Tooltip, { content: props.tooltip }, /* @__PURE__ */ import_react93.default.createElement(
|
13167
13184
|
"svg",
|
13168
13185
|
{
|
13169
13186
|
stroke: "currentColor",
|
@@ -13174,8 +13191,8 @@ var Usage = (props) => {
|
|
13174
13191
|
height: "1em",
|
13175
13192
|
width: "1em"
|
13176
13193
|
},
|
13177
|
-
/* @__PURE__ */
|
13178
|
-
))), /* @__PURE__ */
|
13194
|
+
/* @__PURE__ */ import_react93.default.createElement("path", { d: "M16 8A8 8 0 1 1 0 8a8 8 0 0 1 16 0zM8 4a.905.905 0 0 0-.9.995l.35 3.507a.552.552 0 0 0 1.1 0l.35-3.507A.905.905 0 0 0 8 4zm.002 6a1 1 0 1 0 0 2 1 1 0 0 0 0-2z" })
|
13195
|
+
))), /* @__PURE__ */ import_react93.default.createElement("div", { className: "hawa-bg-white-100 hawa-flex hawa-flex-row" }, /* @__PURE__ */ import_react93.default.createElement("div", null, props.currentUsage), /* @__PURE__ */ import_react93.default.createElement("div", null, " (", props.percent, "%)")), /* @__PURE__ */ import_react93.default.createElement(Progress, { value: (_a = props.percent) != null ? _a : 0 }));
|
13179
13196
|
};
|
13180
13197
|
// Annotate the CommonJS export names for ESM import in node:
|
13181
13198
|
0 && (module.exports = {
|
@@ -13315,6 +13332,10 @@ var Usage = (props) => {
|
|
13315
13332
|
PhoneInput,
|
13316
13333
|
PhoneMockup,
|
13317
13334
|
PinInput,
|
13335
|
+
PinInputGroup,
|
13336
|
+
PinInputRoot,
|
13337
|
+
PinInputSeperator,
|
13338
|
+
PinInputSlot,
|
13318
13339
|
Popover,
|
13319
13340
|
PopoverContent,
|
13320
13341
|
PopoverPortal,
|
@@ -13398,3 +13419,53 @@ var Usage = (props) => {
|
|
13398
13419
|
useToast,
|
13399
13420
|
useWindowSize
|
13400
13421
|
});
|
13422
|
+
/*! Bundled license information:
|
13423
|
+
|
13424
|
+
lucide-react/dist/esm/shared/src/utils.js:
|
13425
|
+
(**
|
13426
|
+
* @license lucide-react v0.379.0 - ISC
|
13427
|
+
*
|
13428
|
+
* This source code is licensed under the ISC license.
|
13429
|
+
* See the LICENSE file in the root directory of this source tree.
|
13430
|
+
*)
|
13431
|
+
|
13432
|
+
lucide-react/dist/esm/defaultAttributes.js:
|
13433
|
+
(**
|
13434
|
+
* @license lucide-react v0.379.0 - ISC
|
13435
|
+
*
|
13436
|
+
* This source code is licensed under the ISC license.
|
13437
|
+
* See the LICENSE file in the root directory of this source tree.
|
13438
|
+
*)
|
13439
|
+
|
13440
|
+
lucide-react/dist/esm/Icon.js:
|
13441
|
+
(**
|
13442
|
+
* @license lucide-react v0.379.0 - ISC
|
13443
|
+
*
|
13444
|
+
* This source code is licensed under the ISC license.
|
13445
|
+
* See the LICENSE file in the root directory of this source tree.
|
13446
|
+
*)
|
13447
|
+
|
13448
|
+
lucide-react/dist/esm/createLucideIcon.js:
|
13449
|
+
(**
|
13450
|
+
* @license lucide-react v0.379.0 - ISC
|
13451
|
+
*
|
13452
|
+
* This source code is licensed under the ISC license.
|
13453
|
+
* See the LICENSE file in the root directory of this source tree.
|
13454
|
+
*)
|
13455
|
+
|
13456
|
+
lucide-react/dist/esm/icons/dot.js:
|
13457
|
+
(**
|
13458
|
+
* @license lucide-react v0.379.0 - ISC
|
13459
|
+
*
|
13460
|
+
* This source code is licensed under the ISC license.
|
13461
|
+
* See the LICENSE file in the root directory of this source tree.
|
13462
|
+
*)
|
13463
|
+
|
13464
|
+
lucide-react/dist/esm/lucide-react.js:
|
13465
|
+
(**
|
13466
|
+
* @license lucide-react v0.379.0 - ISC
|
13467
|
+
*
|
13468
|
+
* This source code is licensed under the ISC license.
|
13469
|
+
* See the LICENSE file in the root directory of this source tree.
|
13470
|
+
*)
|
13471
|
+
*/
|