@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.
Files changed (168) hide show
  1. package/dist/{Radio-y9uhxitu.d.ts → Radio-lgoClQrv.d.ts} +2 -2
  2. package/dist/{Radio-BCD7k628.d.mts → Radio-uQ7DtzcI.d.mts} +2 -2
  3. package/dist/alert/index.js +43 -19
  4. package/dist/alert/index.js.map +1 -1
  5. package/dist/alert/index.mjs +43 -19
  6. package/dist/alert/index.mjs.map +1 -1
  7. package/dist/appLayout/index.js +43 -19
  8. package/dist/appLayout/index.js.map +1 -1
  9. package/dist/appLayout/index.mjs +43 -19
  10. package/dist/appLayout/index.mjs.map +1 -1
  11. package/dist/backToTop/index.js +43 -19
  12. package/dist/backToTop/index.js.map +1 -1
  13. package/dist/backToTop/index.mjs +43 -19
  14. package/dist/backToTop/index.mjs.map +1 -1
  15. package/dist/blocks/auth/index.d.mts +1 -0
  16. package/dist/blocks/auth/index.d.ts +1 -0
  17. package/dist/blocks/auth/index.js +251 -143
  18. package/dist/blocks/auth/index.mjs +205 -102
  19. package/dist/blocks/feedback/index.js +47 -59
  20. package/dist/blocks/feedback/index.mjs +5 -5
  21. package/dist/blocks/index.d.mts +2 -1
  22. package/dist/blocks/index.d.ts +2 -1
  23. package/dist/blocks/index.js +501 -420
  24. package/dist/blocks/index.mjs +11 -9
  25. package/dist/blocks/misc/index.js +48 -51
  26. package/dist/blocks/misc/index.mjs +5 -5
  27. package/dist/blocks/pricing/index.js +47 -41
  28. package/dist/blocks/pricing/index.mjs +4 -4
  29. package/dist/button/index.d.mts +4 -0
  30. package/dist/button/index.d.ts +4 -0
  31. package/dist/button/index.js +43 -19
  32. package/dist/button/index.js.map +1 -1
  33. package/dist/button/index.mjs +43 -19
  34. package/dist/button/index.mjs.map +1 -1
  35. package/dist/calendar/index.js +43 -19
  36. package/dist/calendar/index.js.map +1 -1
  37. package/dist/calendar/index.mjs +43 -19
  38. package/dist/calendar/index.mjs.map +1 -1
  39. package/dist/checkbox/index.d.mts +1 -1
  40. package/dist/checkbox/index.d.ts +1 -1
  41. package/dist/checkbox/index.js.map +1 -1
  42. package/dist/checkbox/index.mjs.map +1 -1
  43. package/dist/{chunk-ZTUWU652.mjs → chunk-EZBHA2IL.mjs} +3 -3
  44. package/dist/{chunk-ODOCZAWC.mjs → chunk-F23GAE2P.mjs} +1 -1
  45. package/dist/{chunk-DS3AACQJ.mjs → chunk-IC5WYNKN.mjs} +1 -1
  46. package/dist/{chunk-QXH7ZDMN.mjs → chunk-RTK6REIK.mjs} +3 -11
  47. package/dist/{chunk-QYWOI3DO.mjs → chunk-UDJFVH2I.mjs} +204 -144
  48. package/dist/{chunk-BPHQFAWM.mjs → chunk-UJ5SXC3M.mjs} +3 -11
  49. package/dist/{chunk-PXGL7ZXQ.mjs → chunk-UMOBOCED.mjs} +44 -19
  50. package/dist/{chunk-RNFJAEEU.mjs → chunk-V7O5MQZQ.mjs} +44 -19
  51. package/dist/{chunk-BTDR3VAG.mjs → chunk-WDCKXU54.mjs} +4 -21
  52. package/dist/{chunk-MDHDHEPZ.mjs → chunk-XFSBC5VI.mjs} +3 -11
  53. package/dist/codeBlock/index.js +43 -19
  54. package/dist/codeBlock/index.js.map +1 -1
  55. package/dist/codeBlock/index.mjs +43 -19
  56. package/dist/codeBlock/index.mjs.map +1 -1
  57. package/dist/colorPicker/index.d.mts +1 -1
  58. package/dist/colorPicker/index.d.ts +1 -1
  59. package/dist/colorPicker/index.js +35 -31
  60. package/dist/colorPicker/index.js.map +1 -1
  61. package/dist/colorPicker/index.mjs +33 -29
  62. package/dist/colorPicker/index.mjs.map +1 -1
  63. package/dist/combobox/index.d.mts +1 -1
  64. package/dist/combobox/index.d.ts +1 -1
  65. package/dist/combobox/index.js +52 -48
  66. package/dist/combobox/index.js.map +1 -1
  67. package/dist/combobox/index.mjs +52 -48
  68. package/dist/combobox/index.mjs.map +1 -1
  69. package/dist/dataTable/index.js +44 -29
  70. package/dist/dataTable/index.js.map +1 -1
  71. package/dist/dataTable/index.mjs +44 -29
  72. package/dist/dataTable/index.mjs.map +1 -1
  73. package/dist/datePicker/index.d.mts +4 -0
  74. package/dist/datePicker/index.d.ts +4 -0
  75. package/dist/datePicker/index.js +44 -19
  76. package/dist/datePicker/index.js.map +1 -1
  77. package/dist/datePicker/index.mjs +44 -19
  78. package/dist/datePicker/index.mjs.map +1 -1
  79. package/dist/docsLayout/index.js +43 -19
  80. package/dist/docsLayout/index.js.map +1 -1
  81. package/dist/docsLayout/index.mjs +43 -19
  82. package/dist/docsLayout/index.mjs.map +1 -1
  83. package/dist/elements/index.d.mts +46 -21
  84. package/dist/elements/index.d.ts +46 -21
  85. package/dist/elements/index.js +378 -309
  86. package/dist/elements/index.mjs +14 -23
  87. package/dist/fileDropzone/index.js +43 -19
  88. package/dist/fileDropzone/index.js.map +1 -1
  89. package/dist/fileDropzone/index.mjs +43 -19
  90. package/dist/fileDropzone/index.mjs.map +1 -1
  91. package/dist/index.css +29 -3
  92. package/dist/index.d.mts +48 -22
  93. package/dist/index.d.ts +48 -22
  94. package/dist/index.js +808 -737
  95. package/dist/index.mjs +331 -264
  96. package/dist/input/index.d.mts +1 -1
  97. package/dist/input/index.d.ts +1 -1
  98. package/dist/input/index.js +46 -42
  99. package/dist/input/index.js.map +1 -1
  100. package/dist/input/index.mjs +45 -41
  101. package/dist/input/index.mjs.map +1 -1
  102. package/dist/interfaceSettings/index.js +64 -69
  103. package/dist/interfaceSettings/index.js.map +1 -1
  104. package/dist/interfaceSettings/index.mjs +57 -62
  105. package/dist/interfaceSettings/index.mjs.map +1 -1
  106. package/dist/layout/index.d.mts +1 -1
  107. package/dist/layout/index.d.ts +1 -1
  108. package/dist/layout/index.js +43 -19
  109. package/dist/layout/index.mjs +2 -2
  110. package/dist/passwordInput/index.js +70 -66
  111. package/dist/passwordInput/index.js.map +1 -1
  112. package/dist/passwordInput/index.mjs +59 -55
  113. package/dist/passwordInput/index.mjs.map +1 -1
  114. package/dist/phoneInput/index.js +50 -55
  115. package/dist/phoneInput/index.js.map +1 -1
  116. package/dist/phoneInput/index.mjs +47 -52
  117. package/dist/phoneInput/index.mjs.map +1 -1
  118. package/dist/pinInput/index.d.mts +37 -16
  119. package/dist/pinInput/index.d.ts +37 -16
  120. package/dist/pinInput/index.js +208 -78
  121. package/dist/pinInput/index.js.map +1 -1
  122. package/dist/pinInput/index.mjs +203 -77
  123. package/dist/pinInput/index.mjs.map +1 -1
  124. package/dist/radio/index.d.mts +1 -1
  125. package/dist/radio/index.d.ts +1 -1
  126. package/dist/radio/index.js +55 -60
  127. package/dist/radio/index.js.map +1 -1
  128. package/dist/radio/index.mjs +50 -55
  129. package/dist/radio/index.mjs.map +1 -1
  130. package/dist/scrollArea/index.js +2 -2
  131. package/dist/scrollArea/index.js.map +1 -1
  132. package/dist/scrollArea/index.mjs +2 -2
  133. package/dist/scrollArea/index.mjs.map +1 -1
  134. package/dist/select/index.d.mts +1 -1
  135. package/dist/select/index.d.ts +1 -1
  136. package/dist/select/index.js +43 -39
  137. package/dist/select/index.js.map +1 -1
  138. package/dist/select/index.mjs +43 -39
  139. package/dist/select/index.mjs.map +1 -1
  140. package/dist/signature/index.d.mts +1 -1
  141. package/dist/signature/index.d.ts +1 -1
  142. package/dist/signature/index.js.map +1 -1
  143. package/dist/signature/index.mjs.map +1 -1
  144. package/dist/sortButton/index.js +43 -19
  145. package/dist/sortButton/index.js.map +1 -1
  146. package/dist/sortButton/index.mjs +43 -19
  147. package/dist/sortButton/index.mjs.map +1 -1
  148. package/dist/splitButton/index.d.mts +4 -0
  149. package/dist/splitButton/index.d.ts +4 -0
  150. package/dist/splitButton/index.js +43 -19
  151. package/dist/splitButton/index.js.map +1 -1
  152. package/dist/splitButton/index.mjs +43 -19
  153. package/dist/splitButton/index.mjs.map +1 -1
  154. package/dist/stats/index.d.mts +1 -1
  155. package/dist/stats/index.d.ts +1 -1
  156. package/dist/stats/index.js.map +1 -1
  157. package/dist/stats/index.mjs.map +1 -1
  158. package/dist/tabs/index.js +2 -2
  159. package/dist/tabs/index.js.map +1 -1
  160. package/dist/tabs/index.mjs +2 -2
  161. package/dist/tabs/index.mjs.map +1 -1
  162. package/dist/textarea/index.d.mts +1 -1
  163. package/dist/textarea/index.d.ts +1 -1
  164. package/dist/textarea/index.js +34 -30
  165. package/dist/textarea/index.js.map +1 -1
  166. package/dist/textarea/index.mjs +34 -30
  167. package/dist/textarea/index.mjs.map +1 -1
  168. package/package.json +2 -1
@@ -1,17 +1,17 @@
1
1
  "use client";
2
2
  import {
3
3
  Input
4
- } from "../../chunk-MDHDHEPZ.mjs";
4
+ } from "../../chunk-XFSBC5VI.mjs";
5
5
  import {
6
6
  StopPropagationWrapper
7
7
  } from "../../chunk-47APBDKK.mjs";
8
8
  import {
9
9
  Select
10
- } from "../../chunk-QXH7ZDMN.mjs";
10
+ } from "../../chunk-RTK6REIK.mjs";
11
11
  import {
12
12
  EyeIcon,
13
13
  HiddenEyeIcon
14
- } from "../../chunk-DS3AACQJ.mjs";
14
+ } from "../../chunk-IC5WYNKN.mjs";
15
15
  import {
16
16
  Button,
17
17
  Card,
@@ -20,10 +20,11 @@ import {
20
20
  CardFooter,
21
21
  CardHeader,
22
22
  CardTitle,
23
+ HelperText,
23
24
  Label,
24
25
  Loading,
25
26
  cn
26
- } from "../../chunk-PXGL7ZXQ.mjs";
27
+ } from "../../chunk-UMOBOCED.mjs";
27
28
 
28
29
  // blocks/auth/AuthButtons.tsx
29
30
  import React2 from "react";
@@ -2383,16 +2384,7 @@ var PhoneInput = ({
2383
2384
  ),
2384
2385
  ...inputProps
2385
2386
  }
2386
- ))), /* @__PURE__ */ React4.createElement(
2387
- "p",
2388
- {
2389
- className: cn(
2390
- "hawa-my-0 hawa-text-start hawa-text-xs hawa-text-helper-color hawa-transition-all",
2391
- props.helperText ? "hawa-h-4 hawa-opacity-100" : "hawa-h-0 hawa-opacity-0"
2392
- )
2393
- },
2394
- props.helperText
2395
- ));
2387
+ ))), /* @__PURE__ */ React4.createElement(HelperText, { helperText: props.helperText }));
2396
2388
  };
2397
2389
 
2398
2390
  // blocks/auth/LoginForm.tsx
@@ -2684,7 +2676,7 @@ var LoginForm = ({
2684
2676
  },
2685
2677
  (texts == null ? void 0 : texts.loginText) || "Login"
2686
2678
  ),
2687
- props.additionalButtons,
2679
+ props.additionalButtons && props.additionalButtons,
2688
2680
  props.allowRegister && /* @__PURE__ */ React5.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__ */ React5.createElement(
2689
2681
  "span",
2690
2682
  {
@@ -3493,106 +3485,168 @@ var ResetPasswordForm = ({
3493
3485
  };
3494
3486
 
3495
3487
  // blocks/auth/CodeConfirmation.tsx
3496
- import React13, { useEffect as useEffect4, useState as useState6 } from "react";
3488
+ import React13, { useEffect as useEffect3, useState as useState5 } from "react";
3497
3489
  import { Controller as Controller5, useForm as useForm5 } from "react-hook-form";
3498
3490
  import { zodResolver as zodResolver5 } from "@hookform/resolvers/zod";
3499
3491
  import * as z5 from "zod";
3500
3492
 
3501
3493
  // elements/pinInput/PinInput.tsx
3502
- import React12, { useEffect as useEffect3, useState as useState5 } from "react";
3503
- var PinInput = ({
3504
- label,
3505
- icon,
3506
- digits,
3507
- width = "normal",
3508
- getPins,
3509
- inputProps,
3510
- ...props
3511
- }) => {
3512
- const [pin, setPin] = useState5(Array.from(Array(digits)));
3513
- const handleKeyDown = (e, index) => {
3514
- let backTo = 0;
3515
- if (e.key === "Backspace") {
3516
- e.target.value.length === 0 ? backTo = index - 1 : backTo = index;
3517
- const previousInput = document.getElementById(`input-${backTo}`);
3518
- previousInput == null ? void 0 : previousInput.focus();
3519
- }
3520
- };
3521
- useEffect3(() => {
3522
- let unfilled = pin.includes(void 0);
3523
- if (!unfilled && getPins) {
3524
- getPins(pin);
3525
- }
3526
- });
3527
- const handleChange = (e, index) => {
3528
- if (!/^\d*$/.test(e.target.value)) {
3529
- const newPin = [...pin];
3530
- newPin[index] = "";
3531
- setPin(newPin);
3532
- return;
3533
- } else {
3534
- const newPin = [...pin];
3535
- newPin[index] = e.target.value;
3536
- setPin(newPin);
3537
- if (e.target.value.length === 1) {
3538
- const nextInput = document.getElementById(`input-${index + 1}`);
3539
- nextInput == null ? void 0 : nextInput.focus();
3540
- } else if (e.target.value.length === 0) {
3541
- const previousInput = document.getElementById(`input-${index - 1}`);
3542
- previousInput == null ? void 0 : previousInput.focus();
3543
- }
3544
- }
3545
- };
3546
- return /* @__PURE__ */ React12.createElement("div", { className: "hawa-flex hawa-flex-col hawa-gap-2" }, /* @__PURE__ */ React12.createElement(
3547
- "div",
3548
- {
3549
- className: "hawa-flex hawa-w-full hawa-flex-row hawa-justify-center hawa-gap-2",
3550
- dir: "ltr"
3551
- },
3552
- pin.map((value, index) => /* @__PURE__ */ React12.createElement(
3553
- "input",
3494
+ import * as React12 from "react";
3495
+ import { OTPInput, OTPInputContext } from "input-otp";
3496
+
3497
+ // ../../node_modules/.pnpm/lucide-react@0.379.0_react@18.3.1/node_modules/lucide-react/dist/esm/createLucideIcon.js
3498
+ import { forwardRef as forwardRef3, createElement as createElement3 } from "react";
3499
+
3500
+ // ../../node_modules/.pnpm/lucide-react@0.379.0_react@18.3.1/node_modules/lucide-react/dist/esm/shared/src/utils.js
3501
+ var toKebabCase = (string6) => string6.replace(/([a-z0-9])([A-Z])/g, "$1-$2").toLowerCase();
3502
+ var mergeClasses = (...classes) => classes.filter((className, index, array) => {
3503
+ return Boolean(className) && array.indexOf(className) === index;
3504
+ }).join(" ");
3505
+
3506
+ // ../../node_modules/.pnpm/lucide-react@0.379.0_react@18.3.1/node_modules/lucide-react/dist/esm/Icon.js
3507
+ import { forwardRef as forwardRef2, createElement as createElement2 } from "react";
3508
+
3509
+ // ../../node_modules/.pnpm/lucide-react@0.379.0_react@18.3.1/node_modules/lucide-react/dist/esm/defaultAttributes.js
3510
+ var defaultAttributes = {
3511
+ xmlns: "http://www.w3.org/2000/svg",
3512
+ width: 24,
3513
+ height: 24,
3514
+ viewBox: "0 0 24 24",
3515
+ fill: "none",
3516
+ stroke: "currentColor",
3517
+ strokeWidth: 2,
3518
+ strokeLinecap: "round",
3519
+ strokeLinejoin: "round"
3520
+ };
3521
+
3522
+ // ../../node_modules/.pnpm/lucide-react@0.379.0_react@18.3.1/node_modules/lucide-react/dist/esm/Icon.js
3523
+ var Icon = forwardRef2(
3524
+ ({
3525
+ color = "currentColor",
3526
+ size = 24,
3527
+ strokeWidth = 2,
3528
+ absoluteStrokeWidth,
3529
+ className = "",
3530
+ children,
3531
+ iconNode,
3532
+ ...rest
3533
+ }, ref) => {
3534
+ return createElement2(
3535
+ "svg",
3554
3536
  {
3555
- key: index,
3556
- type: "text",
3557
- maxLength: 1,
3558
- value,
3559
- inputMode: "numeric",
3560
- id: `input-${index}`,
3561
- pattern: "[0-9]*",
3562
- className: cn(
3563
- "hawa-h-10 hawa-rounded hawa-border hawa-bg-background hawa-text-center placeholder:hawa-text-muted-foreground",
3564
- width === "full" ? "hawa-w-full" : "hawa-w-10"
3565
- ),
3566
- onChange: (e) => handleChange(e, index),
3567
- onKeyDown: (e) => handleKeyDown(e, index),
3568
- onFocus: (e) => e.target.select(),
3569
- ...inputProps
3570
- }
3571
- ))
3572
- ), /* @__PURE__ */ React12.createElement(
3573
- "p",
3537
+ ref,
3538
+ ...defaultAttributes,
3539
+ width: size,
3540
+ height: size,
3541
+ stroke: color,
3542
+ strokeWidth: absoluteStrokeWidth ? Number(strokeWidth) * 24 / Number(size) : strokeWidth,
3543
+ className: mergeClasses("lucide", className),
3544
+ ...rest
3545
+ },
3546
+ [
3547
+ ...iconNode.map(([tag, attrs]) => createElement2(tag, attrs)),
3548
+ ...Array.isArray(children) ? children : [children]
3549
+ ]
3550
+ );
3551
+ }
3552
+ );
3553
+
3554
+ // ../../node_modules/.pnpm/lucide-react@0.379.0_react@18.3.1/node_modules/lucide-react/dist/esm/createLucideIcon.js
3555
+ var createLucideIcon = (iconName, iconNode) => {
3556
+ const Component = forwardRef3(
3557
+ ({ className, ...props }, ref) => createElement3(Icon, {
3558
+ ref,
3559
+ iconNode,
3560
+ className: mergeClasses(`lucide-${toKebabCase(iconName)}`, className),
3561
+ ...props
3562
+ })
3563
+ );
3564
+ Component.displayName = `${iconName}`;
3565
+ return Component;
3566
+ };
3567
+
3568
+ // ../../node_modules/.pnpm/lucide-react@0.379.0_react@18.3.1/node_modules/lucide-react/dist/esm/icons/dot.js
3569
+ var Dot = createLucideIcon("Dot", [
3570
+ ["circle", { cx: "12.1", cy: "12.1", r: "1", key: "18d7e5" }]
3571
+ ]);
3572
+
3573
+ // elements/pinInput/PinInput.tsx
3574
+ var PinInputRoot = React12.forwardRef(({ className, containerClassName, ...props }, ref) => /* @__PURE__ */ React12.createElement(
3575
+ OTPInput,
3576
+ {
3577
+ ref,
3578
+ containerClassName: cn(
3579
+ "hawa-flex hawa-items-center hawa-gap-2 has-[:disabled]:hawa-opacity-50",
3580
+ containerClassName
3581
+ ),
3582
+ className: cn("disabled:hawa-cursor-not-allowed", className),
3583
+ ...props
3584
+ }
3585
+ ));
3586
+ PinInputRoot.displayName = "PinInputRoot";
3587
+ var PinInputGroup = React12.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ React12.createElement(
3588
+ "div",
3589
+ {
3590
+ ref,
3591
+ className: cn("hawa-flex hawa-items-center", className),
3592
+ ...props
3593
+ }
3594
+ ));
3595
+ PinInputGroup.displayName = "PinInputGroup";
3596
+ var PinInputSlot = React12.forwardRef(({ index, className, ...props }, ref) => {
3597
+ const pinInputContext = React12.useContext(OTPInputContext);
3598
+ const { char, hasFakeCaret, isActive } = pinInputContext.slots[index];
3599
+ return /* @__PURE__ */ React12.createElement(
3600
+ "div",
3574
3601
  {
3602
+ ref,
3575
3603
  className: cn(
3576
- "hawa-my-0 hawa-text-start hawa-text-xs hawa-text-helper-color hawa-transition-all",
3577
- props.helperText ? "hawa-h-4 hawa-opacity-100" : "hawa-h-0 hawa-opacity-0"
3578
- )
3604
+ "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",
3605
+ isActive && "hawa-ring-ring hawa-ring-offset-background hawa-z-10 hawa-ring-2",
3606
+ className
3607
+ ),
3608
+ ...props
3579
3609
  },
3580
- props.helperText
3581
- ));
3610
+ char,
3611
+ hasFakeCaret && /* @__PURE__ */ React12.createElement("div", { className: "hawa-pointer-events-none hawa-absolute hawa-inset-0 hawa-flex hawa-items-center hawa-justify-center" }, /* @__PURE__ */ React12.createElement("div", { className: "hawa-animate-caret-blink hawa-bg-foreground hawa-h-4 hawa-w-px hawa-duration-1000" }))
3612
+ );
3613
+ });
3614
+ PinInputSlot.displayName = "PinInputSlot";
3615
+ var PinInputSeperator = React12.forwardRef(({ ...props }, ref) => /* @__PURE__ */ React12.createElement("div", { ref, role: "separator", ...props }, /* @__PURE__ */ React12.createElement(Dot, null)));
3616
+ PinInputSeperator.displayName = "PinInputSeperator";
3617
+ var PinInput = ({
3618
+ separatorPosition = 0,
3619
+ ...props
3620
+ }) => {
3621
+ const maxLength = props.maxLength || 6;
3622
+ const clampedSeparatorPosition = Math.min(separatorPosition, maxLength);
3623
+ const firstGroupLength = clampedSeparatorPosition > 0 ? clampedSeparatorPosition : 0;
3624
+ const secondGroupLength = maxLength - firstGroupLength;
3625
+ return /* @__PURE__ */ React12.createElement("div", { className: "hawa-flex hawa-flex-col hawa-gap-2" }, /* @__PURE__ */ React12.createElement(PinInputRoot, { ...props }, firstGroupLength > 0 && /* @__PURE__ */ React12.createElement(PinInputGroup, { className: "hawa-w-full" }, [...Array(firstGroupLength)].map((_, index) => /* @__PURE__ */ React12.createElement(PinInputSlot, { key: index, index, className: "hawa-w-full" }))), separatorPosition > 0 && separatorPosition < props.maxLength && /* @__PURE__ */ React12.createElement(PinInputSeperator, null), secondGroupLength > 0 && /* @__PURE__ */ React12.createElement(PinInputGroup, { className: "hawa-w-full" }, [...Array(secondGroupLength)].map((_, index) => /* @__PURE__ */ React12.createElement(
3626
+ PinInputSlot,
3627
+ {
3628
+ key: index + firstGroupLength,
3629
+ index: index + firstGroupLength,
3630
+ className: "hawa-w-full"
3631
+ }
3632
+ )))), /* @__PURE__ */ React12.createElement(HelperText, { helperText: props.helperText }));
3582
3633
  };
3583
3634
 
3584
3635
  // blocks/auth/CodeConfirmation.tsx
3585
- var CodeConfirmation = (props) => {
3636
+ var CodeConfirmation = ({
3637
+ codeLength = 6,
3638
+ ...props
3639
+ }) => {
3586
3640
  var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k;
3587
3641
  const formSchema = z5.object({
3588
- otp_code: z5.string({ required_error: (_a = props.texts) == null ? void 0 : _a.codeRequiredText }).min(6, { message: (_b = props.texts) == null ? void 0 : _b.codeTooShort })
3642
+ 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 })
3589
3643
  });
3590
3644
  const { handleSubmit, control, formState, setValue } = useForm5({
3591
3645
  resolver: zodResolver5(formSchema)
3592
3646
  });
3593
- const [resendTimer, setResendTimer] = useState6(null);
3594
- const [remainingTime, setRemainingTime] = useState6(0);
3595
- const [showResendTimer, setShowResendTimer] = useState6(false);
3647
+ const [resendTimer, setResendTimer] = useState5(null);
3648
+ const [remainingTime, setRemainingTime] = useState5(0);
3649
+ const [showResendTimer, setShowResendTimer] = useState5(false);
3596
3650
  const startResendTimer = () => {
3597
3651
  if (resendTimer !== null) {
3598
3652
  clearInterval(resendTimer);
@@ -3614,7 +3668,7 @@ var CodeConfirmation = (props) => {
3614
3668
  }, 1e3);
3615
3669
  setResendTimer(newTimer);
3616
3670
  };
3617
- useEffect4(() => {
3671
+ useEffect3(() => {
3618
3672
  return () => {
3619
3673
  if (resendTimer !== null) {
3620
3674
  clearInterval(resendTimer);
@@ -3652,10 +3706,9 @@ var CodeConfirmation = (props) => {
3652
3706
  return /* @__PURE__ */ React13.createElement(
3653
3707
  PinInput,
3654
3708
  {
3655
- width: "full",
3656
- digits: 6,
3657
- getPins: (e) => setValue("otp_code", e.join("")),
3658
- helperText: (_a2 = formState.errors.otp_code) == null ? void 0 : _a2.message
3709
+ maxLength: codeLength,
3710
+ helperText: (_a2 = formState.errors.otp_code) == null ? void 0 : _a2.message,
3711
+ ...field
3659
3712
  }
3660
3713
  );
3661
3714
  }
@@ -3685,3 +3738,53 @@ export {
3685
3738
  RegisterForm,
3686
3739
  ResetPasswordForm
3687
3740
  };
3741
+ /*! Bundled license information:
3742
+
3743
+ lucide-react/dist/esm/shared/src/utils.js:
3744
+ (**
3745
+ * @license lucide-react v0.379.0 - ISC
3746
+ *
3747
+ * This source code is licensed under the ISC license.
3748
+ * See the LICENSE file in the root directory of this source tree.
3749
+ *)
3750
+
3751
+ lucide-react/dist/esm/defaultAttributes.js:
3752
+ (**
3753
+ * @license lucide-react v0.379.0 - ISC
3754
+ *
3755
+ * This source code is licensed under the ISC license.
3756
+ * See the LICENSE file in the root directory of this source tree.
3757
+ *)
3758
+
3759
+ lucide-react/dist/esm/Icon.js:
3760
+ (**
3761
+ * @license lucide-react v0.379.0 - ISC
3762
+ *
3763
+ * This source code is licensed under the ISC license.
3764
+ * See the LICENSE file in the root directory of this source tree.
3765
+ *)
3766
+
3767
+ lucide-react/dist/esm/createLucideIcon.js:
3768
+ (**
3769
+ * @license lucide-react v0.379.0 - ISC
3770
+ *
3771
+ * This source code is licensed under the ISC license.
3772
+ * See the LICENSE file in the root directory of this source tree.
3773
+ *)
3774
+
3775
+ lucide-react/dist/esm/icons/dot.js:
3776
+ (**
3777
+ * @license lucide-react v0.379.0 - ISC
3778
+ *
3779
+ * This source code is licensed under the ISC license.
3780
+ * See the LICENSE file in the root directory of this source tree.
3781
+ *)
3782
+
3783
+ lucide-react/dist/esm/lucide-react.js:
3784
+ (**
3785
+ * @license lucide-react v0.379.0 - ISC
3786
+ *
3787
+ * This source code is licensed under the ISC license.
3788
+ * See the LICENSE file in the root directory of this source tree.
3789
+ *)
3790
+ */
@@ -447,30 +447,54 @@ var Button = React5.forwardRef(
447
447
  children,
448
448
  labelProps,
449
449
  showHelperText = false,
450
+ inForm = false,
450
451
  ...props
451
452
  }, ref) => {
452
453
  const Comp = "button";
453
454
  const loadingColor = variant === "outline" || variant === "ghost" || variant === "neoBrutalism" ? "hawa-bg-primary" : "hawa-bg-primary-foreground";
454
- return /* @__PURE__ */ React5.createElement("div", { className: "hawa-flex hawa-flex-col hawa-gap-2" }, label && /* @__PURE__ */ React5.createElement(Label, { ...labelProps }, label), /* @__PURE__ */ React5.createElement(
455
- Comp,
456
- {
457
- className: cn(
458
- buttonVariants({ variant, size, className }),
459
- centered && "hawa-justify-center"
460
- ),
461
- ref,
462
- ...props
463
- },
464
- isLoading ? /* @__PURE__ */ React5.createElement(
465
- Loading,
455
+ if (inForm) {
456
+ return /* @__PURE__ */ React5.createElement("div", { className: "hawa-flex hawa-flex-col hawa-gap-2" }, label && /* @__PURE__ */ React5.createElement(Label, { ...labelProps }, label), /* @__PURE__ */ React5.createElement(
457
+ Comp,
466
458
  {
467
- design: size === "icon" || size === "smallIcon" ? "spinner" : "dots-pulse",
468
- themeMode: variant === "outline" ? "light" : "dark",
469
- color: loadingColor,
470
- size: size === "sm" || size === "xs" ? "xs" : "button"
471
- }
472
- ) : children
473
- ), showHelperText && /* @__PURE__ */ React5.createElement(HelperText, { helperText: props.helperText }));
459
+ className: cn(
460
+ buttonVariants({ variant, size, className }),
461
+ centered && "hawa-justify-center"
462
+ ),
463
+ ref,
464
+ ...props
465
+ },
466
+ isLoading ? /* @__PURE__ */ React5.createElement(
467
+ Loading,
468
+ {
469
+ design: size === "icon" || size === "smallIcon" ? "spinner" : "dots-pulse",
470
+ themeMode: variant === "outline" ? "light" : "dark",
471
+ color: loadingColor,
472
+ size: size === "sm" || size === "xs" ? "xs" : "button"
473
+ }
474
+ ) : children
475
+ ), showHelperText && /* @__PURE__ */ React5.createElement(HelperText, { helperText: props.helperText }));
476
+ } else {
477
+ return /* @__PURE__ */ React5.createElement(
478
+ Comp,
479
+ {
480
+ className: cn(
481
+ buttonVariants({ variant, size, className }),
482
+ centered && "hawa-justify-center"
483
+ ),
484
+ ref,
485
+ ...props
486
+ },
487
+ isLoading ? /* @__PURE__ */ React5.createElement(
488
+ Loading,
489
+ {
490
+ design: size === "icon" || size === "smallIcon" ? "spinner" : "dots-pulse",
491
+ themeMode: variant === "outline" ? "light" : "dark",
492
+ color: loadingColor,
493
+ size: size === "sm" || size === "xs" ? "xs" : "button"
494
+ }
495
+ ) : children
496
+ );
497
+ }
474
498
  }
475
499
  );
476
500
  Button.displayName = "Button";
@@ -768,16 +792,7 @@ var Radio = (0, import_react4.forwardRef)(
768
792
  opt.label
769
793
  );
770
794
  })
771
- ), !forceHideHelperText && /* @__PURE__ */ import_react4.default.createElement(
772
- "p",
773
- {
774
- className: cn(
775
- "hawa-my-0 hawa-text-start hawa-text-xs hawa-text-helper-color hawa-transition-all",
776
- props.helperText ? "hawa-h-4 hawa-opacity-100" : "hawa-h-0 hawa-opacity-0"
777
- )
778
- },
779
- props.helperText
780
- ));
795
+ ), !forceHideHelperText && /* @__PURE__ */ import_react4.default.createElement(HelperText, { helperText: props.helperText }));
781
796
  case "bordered":
782
797
  return /* @__PURE__ */ import_react4.default.createElement("div", { className: cn(orientationStyle[orientation], "hawa-gap-4") }, props.options && props.options.map((opt, i) => /* @__PURE__ */ import_react4.default.createElement("div", { key: i, className: "hawa-w-full hawa-rounded hawa-border" }, /* @__PURE__ */ import_react4.default.createElement(
783
798
  "div",
@@ -866,16 +881,7 @@ var Radio = (0, import_react4.forwardRef)(
866
881
  },
867
882
  opt.label
868
883
  )
869
- ))), /* @__PURE__ */ import_react4.default.createElement(
870
- "p",
871
- {
872
- className: cn(
873
- "hawa-my-0 hawa-text-start hawa-text-xs hawa-text-helper-color hawa-transition-all",
874
- props.helperText ? "hawa-h-4 hawa-opacity-100" : "hawa-h-0 hawa-opacity-0"
875
- )
876
- },
877
- props.helperText
878
- ));
884
+ ))), /* @__PURE__ */ import_react4.default.createElement(HelperText, { helperText: props.helperText }));
879
885
  }
880
886
  }
881
887
  );
@@ -960,16 +966,7 @@ var Textarea = React10.forwardRef(
960
966
  ref
961
967
  }
962
968
  ),
963
- /* @__PURE__ */ React10.createElement("div", { className: "hawa-flex hawa-flex-row hawa-justify-between" }, !forceHideHelperText && /* @__PURE__ */ React10.createElement(
964
- "p",
965
- {
966
- className: cn(
967
- "hawa-my-0 hawa-text-start hawa-text-xs hawa-text-helper-color hawa-transition-all",
968
- props.helperText ? "hawa-h-4 hawa-opacity-100" : "hawa-h-0 hawa-opacity-0"
969
- )
970
- },
971
- props.helperText
972
- ), showCount && countPosition === "bottom" && /* @__PURE__ */ React10.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))
969
+ /* @__PURE__ */ React10.createElement("div", { className: "hawa-flex hawa-flex-row hawa-justify-between" }, !forceHideHelperText && /* @__PURE__ */ React10.createElement(HelperText, { helperText: props.helperText }), showCount && countPosition === "bottom" && /* @__PURE__ */ React10.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))
973
970
  );
974
971
  }
975
972
  );
@@ -1636,16 +1633,7 @@ var Select = ({
1636
1633
  onInputChange: (newValue, action) => props.onInputChange(newValue, action)
1637
1634
  }
1638
1635
  ),
1639
- !props.hideHelperText && /* @__PURE__ */ import_react12.default.createElement(
1640
- "p",
1641
- {
1642
- className: cn(
1643
- "hawa-my-0 hawa-text-start hawa-text-xs hawa-text-helper-color hawa-transition-all",
1644
- props.helperText ? "hawa-h-4 hawa-opacity-100" : "hawa-h-0 hawa-opacity-0"
1645
- )
1646
- },
1647
- props.helperText
1648
- )
1636
+ !props.hideHelperText && /* @__PURE__ */ import_react12.default.createElement(HelperText, { helperText: props.helperText })
1649
1637
  );
1650
1638
  };
1651
1639
 
@@ -1,27 +1,27 @@
1
1
  "use client";
2
2
  import {
3
3
  Textarea
4
- } from "../../chunk-BPHQFAWM.mjs";
4
+ } from "../../chunk-UJ5SXC3M.mjs";
5
5
  import {
6
6
  Select
7
- } from "../../chunk-QXH7ZDMN.mjs";
7
+ } from "../../chunk-RTK6REIK.mjs";
8
8
  import {
9
9
  Popover,
10
10
  Radio
11
- } from "../../chunk-BTDR3VAG.mjs";
11
+ } from "../../chunk-WDCKXU54.mjs";
12
12
  import {
13
13
  BadEmoji,
14
14
  GoodEmoji,
15
15
  VeryBadEmoji,
16
16
  VeryGoodEmoji
17
- } from "../../chunk-DS3AACQJ.mjs";
17
+ } from "../../chunk-IC5WYNKN.mjs";
18
18
  import {
19
19
  Button,
20
20
  Card,
21
21
  CardContent,
22
22
  Label,
23
23
  cn
24
- } from "../../chunk-PXGL7ZXQ.mjs";
24
+ } from "../../chunk-UMOBOCED.mjs";
25
25
 
26
26
  // blocks/feedback/UserReferralSource.tsx
27
27
  import React, { useRef, useState } from "react";
@@ -1,6 +1,6 @@
1
1
  import React__default, { FC, InputHTMLAttributes } from 'react';
2
2
  import { ThirdPartyAuthTextsTypes, LoginFormTextsTypes, RegisterFormTextsTypes, NewPasswordTextsTypes, ResetPasswordTextsTypes, BaseInputType, TextInputType, PricingCardProps, PlanFeature, PricingPlanTexts } from '../types/index.mjs';
3
- import { P as PhoneInputProps, S as SelectOptionProps, L as LabelProps, R as RadioOptionsTypes } from '../Radio-BCD7k628.mjs';
3
+ import { P as PhoneInputProps, S as SelectOptionProps, L as LabelProps, R as RadioOptionsTypes } from '../Radio-uQ7DtzcI.mjs';
4
4
  import { D as DirectionType, a as RadioOptionType, O as OrientationType } from '../commonTypes-C-g8nFFC.mjs';
5
5
  import { M as MenuItemType } from '../DropdownMenu-BYiPSEYy.mjs';
6
6
  import '@radix-ui/react-popover';
@@ -257,6 +257,7 @@ type TConfirmation = {
257
257
  confirmLoading?: boolean;
258
258
  handleConfirm?: any;
259
259
  handleResend?: any;
260
+ codeLength?: number;
260
261
  };
261
262
  declare const CodeConfirmation: FC<TConfirmation>;
262
263
 
@@ -1,6 +1,6 @@
1
1
  import React__default, { FC, InputHTMLAttributes } from 'react';
2
2
  import { ThirdPartyAuthTextsTypes, LoginFormTextsTypes, RegisterFormTextsTypes, NewPasswordTextsTypes, ResetPasswordTextsTypes, BaseInputType, TextInputType, PricingCardProps, PlanFeature, PricingPlanTexts } from '../types/index.js';
3
- import { P as PhoneInputProps, S as SelectOptionProps, L as LabelProps, R as RadioOptionsTypes } from '../Radio-y9uhxitu.js';
3
+ import { P as PhoneInputProps, S as SelectOptionProps, L as LabelProps, R as RadioOptionsTypes } from '../Radio-lgoClQrv.js';
4
4
  import { D as DirectionType, a as RadioOptionType, O as OrientationType } from '../commonTypes-C-g8nFFC.js';
5
5
  import { M as MenuItemType } from '../DropdownMenu-ChxqadLu.js';
6
6
  import '@radix-ui/react-popover';
@@ -257,6 +257,7 @@ type TConfirmation = {
257
257
  confirmLoading?: boolean;
258
258
  handleConfirm?: any;
259
259
  handleResend?: any;
260
+ codeLength?: number;
260
261
  };
261
262
  declare const CodeConfirmation: FC<TConfirmation>;
262
263