@sikka/hawa 0.31.10-next → 0.31.11-next
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/appLayout/index.js +144 -132
- package/dist/appLayout/index.js.map +1 -1
- package/dist/appLayout/index.mjs +139 -127
- package/dist/appLayout/index.mjs.map +1 -1
- package/dist/blocks/index.js +199 -196
- package/dist/blocks/index.mjs +3 -3
- package/dist/blocks/misc/index.js +145 -142
- package/dist/blocks/misc/index.mjs +63 -60
- package/dist/{chunk-UDCDD66A.mjs → chunk-JU6Q4Q3T.mjs} +21 -1
- package/dist/{chunk-JXN2PVGT.mjs → chunk-VZNDYO6H.mjs} +1 -1
- package/dist/elements/index.js +253 -250
- package/dist/elements/index.mjs +3 -3
- package/dist/hooks/index.js +3 -0
- package/dist/hooks/index.mjs +2 -2
- package/dist/index.js +730 -718
- package/dist/index.mjs +660 -648
- package/dist/layout/index.js +252 -240
- package/dist/layout/index.mjs +9 -15
- package/dist/tabs/index.js +26 -23
- package/dist/tabs/index.js.map +1 -1
- package/dist/tabs/index.mjs +26 -23
- package/dist/tabs/index.mjs.map +1 -1
- package/package.json +12 -12
- /package/dist/{chunk-R2SKHHDK.mjs → chunk-OPYDG34F.mjs} +0 -0
@@ -43,7 +43,7 @@ __export(misc_exports, {
|
|
43
43
|
module.exports = __toCommonJS(misc_exports);
|
44
44
|
|
45
45
|
// blocks/misc/LegalTexts.tsx
|
46
|
-
var
|
46
|
+
var import_react18 = __toESM(require("react"));
|
47
47
|
|
48
48
|
// elements/scrollArea/ScrollArea.tsx
|
49
49
|
var React = __toESM(require("react"));
|
@@ -95,7 +95,7 @@ var ScrollBar = React.forwardRef(({ className, orientation = "vertical", ...prop
|
|
95
95
|
ScrollBar.displayName = ScrollAreaPrimitive.ScrollAreaScrollbar.displayName;
|
96
96
|
|
97
97
|
// elements/tabs/Tabs.tsx
|
98
|
-
var
|
98
|
+
var React13 = __toESM(require("react"));
|
99
99
|
|
100
100
|
// hooks/useIsomorphicEffect.ts
|
101
101
|
var import_react = require("react");
|
@@ -178,13 +178,16 @@ var useMeasureDirty = (ref) => {
|
|
178
178
|
return rect;
|
179
179
|
};
|
180
180
|
|
181
|
+
// hooks/useOutsideClick.ts
|
182
|
+
var import_react16 = __toESM(require("react"));
|
183
|
+
|
181
184
|
// elements/tabs/Tabs.tsx
|
182
185
|
var TabsPrimitive = __toESM(require("@radix-ui/react-tabs"));
|
183
186
|
var import_tailwind_variants = require("tailwind-variants");
|
184
187
|
|
185
188
|
// elements/chip/Chip.tsx
|
186
|
-
var
|
187
|
-
var Chip =
|
189
|
+
var import_react17 = __toESM(require("react"));
|
190
|
+
var Chip = import_react17.default.forwardRef(
|
188
191
|
({
|
189
192
|
label,
|
190
193
|
size = "normal",
|
@@ -226,7 +229,7 @@ var Chip = import_react16.default.forwardRef(
|
|
226
229
|
oceanic: "hawa-text-white hawa-bg-gradient-to-bl hawa-from-green-300 hawa-via-blue-500 hawa-to-purple-600"
|
227
230
|
};
|
228
231
|
if (label) {
|
229
|
-
return /* @__PURE__ */
|
232
|
+
return /* @__PURE__ */ import_react17.default.createElement(
|
230
233
|
"span",
|
231
234
|
{
|
232
235
|
...rest,
|
@@ -238,7 +241,7 @@ var Chip = import_react16.default.forwardRef(
|
|
238
241
|
color ? colorStyles[color] : "hawa-border hawa-bg-none"
|
239
242
|
)
|
240
243
|
},
|
241
|
-
dotType && /* @__PURE__ */
|
244
|
+
dotType && /* @__PURE__ */ import_react17.default.createElement(
|
242
245
|
"span",
|
243
246
|
{
|
244
247
|
className: cn(dotStyles[size], dotTypeStyles[dotType])
|
@@ -248,7 +251,7 @@ var Chip = import_react16.default.forwardRef(
|
|
248
251
|
label
|
249
252
|
);
|
250
253
|
} else {
|
251
|
-
return /* @__PURE__ */
|
254
|
+
return /* @__PURE__ */ import_react17.default.createElement(
|
252
255
|
"span",
|
253
256
|
{
|
254
257
|
...rest,
|
@@ -264,7 +267,7 @@ var Chip = import_react16.default.forwardRef(
|
|
264
267
|
);
|
265
268
|
|
266
269
|
// elements/floatBox/FloatBox.tsx
|
267
|
-
var
|
270
|
+
var React12 = __toESM(require("react"));
|
268
271
|
var FloatBox = ({
|
269
272
|
className,
|
270
273
|
open,
|
@@ -302,7 +305,7 @@ var FloatBox = ({
|
|
302
305
|
right: "hawa-arrow-default-left",
|
303
306
|
left: "hawa-arrow-default-right"
|
304
307
|
};
|
305
|
-
return /* @__PURE__ */
|
308
|
+
return /* @__PURE__ */ React12.createElement(
|
306
309
|
"div",
|
307
310
|
{
|
308
311
|
className: cn(
|
@@ -313,8 +316,8 @@ var FloatBox = ({
|
|
313
316
|
"data-side": side,
|
314
317
|
"data-floatbox-state": open ? "open" : "closed"
|
315
318
|
},
|
316
|
-
withArrow && /* @__PURE__ */
|
317
|
-
/* @__PURE__ */
|
319
|
+
withArrow && /* @__PURE__ */ React12.createElement("div", { className: cn(arrowDirection[side]) }),
|
320
|
+
/* @__PURE__ */ React12.createElement("span", null, props.children)
|
318
321
|
);
|
319
322
|
};
|
320
323
|
|
@@ -377,8 +380,8 @@ var tabsTriggerVariant = (0, import_tailwind_variants.tv)({
|
|
377
380
|
],
|
378
381
|
defaultVariants: { variant: "default", orientation: "horizontal" }
|
379
382
|
});
|
380
|
-
var TabsContext =
|
381
|
-
var Tabs =
|
383
|
+
var TabsContext = React13.createContext({ orientation: "horizontal", variant: "default" });
|
384
|
+
var Tabs = React13.forwardRef(({ className, orientation, variant = "default", ...props }, ref) => /* @__PURE__ */ React13.createElement(
|
382
385
|
TabsPrimitive.Root,
|
383
386
|
{
|
384
387
|
ref,
|
@@ -389,11 +392,11 @@ var Tabs = React12.forwardRef(({ className, orientation, variant = "default", ..
|
|
389
392
|
),
|
390
393
|
...props
|
391
394
|
},
|
392
|
-
/* @__PURE__ */
|
395
|
+
/* @__PURE__ */ React13.createElement(TabsContext.Provider, { value: { orientation, variant } }, props.children)
|
393
396
|
));
|
394
|
-
var TabsList =
|
395
|
-
const { orientation, variant } =
|
396
|
-
return /* @__PURE__ */
|
397
|
+
var TabsList = React13.forwardRef(({ className, ...props }, ref) => {
|
398
|
+
const { orientation, variant } = React13.useContext(TabsContext);
|
399
|
+
return /* @__PURE__ */ React13.createElement(
|
397
400
|
TabsPrimitive.List,
|
398
401
|
{
|
399
402
|
ref,
|
@@ -406,11 +409,11 @@ var TabsList = React12.forwardRef(({ className, ...props }, ref) => {
|
|
406
409
|
}
|
407
410
|
);
|
408
411
|
});
|
409
|
-
var TabsTrigger =
|
410
|
-
const { orientation, variant } =
|
411
|
-
const tabTriggerRef =
|
412
|
+
var TabsTrigger = React13.forwardRef(({ className, chipProps, ...props }, ref) => {
|
413
|
+
const { orientation, variant } = React13.useContext(TabsContext);
|
414
|
+
const tabTriggerRef = React13.useRef(null);
|
412
415
|
const { width } = useMeasureDirty(tabTriggerRef);
|
413
|
-
return /* @__PURE__ */
|
416
|
+
return /* @__PURE__ */ React13.createElement(
|
414
417
|
TabsPrimitive.Trigger,
|
415
418
|
{
|
416
419
|
ref: tabTriggerRef,
|
@@ -422,8 +425,8 @@ var TabsTrigger = React12.forwardRef(({ className, chipProps, ...props }, ref) =
|
|
422
425
|
...props
|
423
426
|
},
|
424
427
|
props.children,
|
425
|
-
chipProps && /* @__PURE__ */
|
426
|
-
/* @__PURE__ */
|
428
|
+
chipProps && /* @__PURE__ */ React13.createElement(Chip, { ...chipProps }),
|
429
|
+
/* @__PURE__ */ React13.createElement(
|
427
430
|
FloatBox,
|
428
431
|
{
|
429
432
|
withArrow: true,
|
@@ -436,7 +439,7 @@ var TabsTrigger = React12.forwardRef(({ className, chipProps, ...props }, ref) =
|
|
436
439
|
)
|
437
440
|
);
|
438
441
|
});
|
439
|
-
var TabsContent =
|
442
|
+
var TabsContent = React13.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ React13.createElement(
|
440
443
|
TabsPrimitive.Content,
|
441
444
|
{
|
442
445
|
ref,
|
@@ -454,7 +457,7 @@ TabsContent.displayName = TabsPrimitive.Content.displayName;
|
|
454
457
|
|
455
458
|
// blocks/misc/LegalTexts.tsx
|
456
459
|
var LegalTexts = ({ tabs, ...props }) => {
|
457
|
-
return /* @__PURE__ */
|
460
|
+
return /* @__PURE__ */ import_react18.default.createElement(
|
458
461
|
Tabs,
|
459
462
|
{
|
460
463
|
value: props.activeTab,
|
@@ -462,8 +465,8 @@ var LegalTexts = ({ tabs, ...props }) => {
|
|
462
465
|
defaultValue: props.defaultTab || tabs[0].value,
|
463
466
|
dir: props.direction
|
464
467
|
},
|
465
|
-
/* @__PURE__ */
|
466
|
-
tabs.map((tab, index) => /* @__PURE__ */
|
468
|
+
/* @__PURE__ */ import_react18.default.createElement(TabsList, { className: "hawa-w-full" }, tabs.map((tab, index) => /* @__PURE__ */ import_react18.default.createElement(TabsTrigger, { key: index, value: tab.value }, tab.title))),
|
469
|
+
tabs.map((tab, index) => /* @__PURE__ */ import_react18.default.createElement(TabsContent, { key: index, value: tab.value }, /* @__PURE__ */ import_react18.default.createElement(
|
467
470
|
ScrollArea,
|
468
471
|
{
|
469
472
|
className: cn(
|
@@ -477,14 +480,14 @@ var LegalTexts = ({ tabs, ...props }) => {
|
|
477
480
|
};
|
478
481
|
|
479
482
|
// blocks/misc/EmptyState.tsx
|
480
|
-
var
|
483
|
+
var import_react20 = __toESM(require("react"));
|
481
484
|
|
482
485
|
// elements/button/Button.tsx
|
483
|
-
var
|
486
|
+
var React16 = __toESM(require("react"));
|
484
487
|
var import_class_variance_authority = require("class-variance-authority");
|
485
488
|
|
486
489
|
// elements/loading/Loading.tsx
|
487
|
-
var
|
490
|
+
var import_react19 = __toESM(require("react"));
|
488
491
|
var Loading = ({
|
489
492
|
design = "spinner",
|
490
493
|
size = "normal",
|
@@ -515,7 +518,7 @@ var Loading = ({
|
|
515
518
|
};
|
516
519
|
switch (design.split("-")[0]) {
|
517
520
|
case "dots":
|
518
|
-
return /* @__PURE__ */
|
521
|
+
return /* @__PURE__ */ import_react19.default.createElement(
|
519
522
|
"div",
|
520
523
|
{
|
521
524
|
className: cn(
|
@@ -523,7 +526,7 @@ var Loading = ({
|
|
523
526
|
classNames == null ? void 0 : classNames.container
|
524
527
|
)
|
525
528
|
},
|
526
|
-
/* @__PURE__ */
|
529
|
+
/* @__PURE__ */ import_react19.default.createElement(
|
527
530
|
"div",
|
528
531
|
{
|
529
532
|
className: cn(
|
@@ -534,7 +537,7 @@ var Loading = ({
|
|
534
537
|
)
|
535
538
|
}
|
536
539
|
),
|
537
|
-
/* @__PURE__ */
|
540
|
+
/* @__PURE__ */ import_react19.default.createElement(
|
538
541
|
"div",
|
539
542
|
{
|
540
543
|
className: cn(
|
@@ -545,7 +548,7 @@ var Loading = ({
|
|
545
548
|
)
|
546
549
|
}
|
547
550
|
),
|
548
|
-
/* @__PURE__ */
|
551
|
+
/* @__PURE__ */ import_react19.default.createElement(
|
549
552
|
"div",
|
550
553
|
{
|
551
554
|
className: cn(
|
@@ -558,7 +561,7 @@ var Loading = ({
|
|
558
561
|
)
|
559
562
|
);
|
560
563
|
case "square":
|
561
|
-
return /* @__PURE__ */
|
564
|
+
return /* @__PURE__ */ import_react19.default.createElement(
|
562
565
|
"svg",
|
563
566
|
{
|
564
567
|
className: cn(
|
@@ -570,7 +573,7 @@ var Loading = ({
|
|
570
573
|
height: "35",
|
571
574
|
width: "35"
|
572
575
|
},
|
573
|
-
/* @__PURE__ */
|
576
|
+
/* @__PURE__ */ import_react19.default.createElement(
|
574
577
|
"rect",
|
575
578
|
{
|
576
579
|
className: "squircle-track",
|
@@ -582,7 +585,7 @@ var Loading = ({
|
|
582
585
|
height: "32.5"
|
583
586
|
}
|
584
587
|
),
|
585
|
-
/* @__PURE__ */
|
588
|
+
/* @__PURE__ */ import_react19.default.createElement(
|
586
589
|
"rect",
|
587
590
|
{
|
588
591
|
className: "square-car",
|
@@ -597,7 +600,7 @@ var Loading = ({
|
|
597
600
|
)
|
598
601
|
);
|
599
602
|
case "squircle":
|
600
|
-
return /* @__PURE__ */
|
603
|
+
return /* @__PURE__ */ import_react19.default.createElement(
|
601
604
|
"svg",
|
602
605
|
{
|
603
606
|
x: "0px",
|
@@ -612,7 +615,7 @@ var Loading = ({
|
|
612
615
|
classNames == null ? void 0 : classNames.container
|
613
616
|
)
|
614
617
|
},
|
615
|
-
/* @__PURE__ */
|
618
|
+
/* @__PURE__ */ import_react19.default.createElement(
|
616
619
|
"path",
|
617
620
|
{
|
618
621
|
className: cn("squircle-track", classNames == null ? void 0 : classNames.track),
|
@@ -622,7 +625,7 @@ var Loading = ({
|
|
622
625
|
d: "M0.37 18.5 C0.37 5.772 5.772 0.37 18.5 0.37 S36.63 5.772 36.63 18.5 S31.228 36.63 18.5 36.63 S0.37 31.228 0.37 18.5"
|
623
626
|
}
|
624
627
|
),
|
625
|
-
/* @__PURE__ */
|
628
|
+
/* @__PURE__ */ import_react19.default.createElement(
|
626
629
|
"path",
|
627
630
|
{
|
628
631
|
className: cn("squircle-car", classNames == null ? void 0 : classNames.car),
|
@@ -634,7 +637,7 @@ var Loading = ({
|
|
634
637
|
)
|
635
638
|
);
|
636
639
|
case "progress":
|
637
|
-
return /* @__PURE__ */
|
640
|
+
return /* @__PURE__ */ import_react19.default.createElement(
|
638
641
|
"div",
|
639
642
|
{
|
640
643
|
className: cn(
|
@@ -645,9 +648,9 @@ var Loading = ({
|
|
645
648
|
}
|
646
649
|
);
|
647
650
|
case "orbit":
|
648
|
-
return /* @__PURE__ */
|
651
|
+
return /* @__PURE__ */ import_react19.default.createElement("div", { className: cn("orbit-container", classNames == null ? void 0 : classNames.container) });
|
649
652
|
default:
|
650
|
-
return /* @__PURE__ */
|
653
|
+
return /* @__PURE__ */ import_react19.default.createElement(
|
651
654
|
"svg",
|
652
655
|
{
|
653
656
|
viewBox: "0 0 40 40",
|
@@ -659,7 +662,7 @@ var Loading = ({
|
|
659
662
|
classNames == null ? void 0 : classNames.container
|
660
663
|
)
|
661
664
|
},
|
662
|
-
/* @__PURE__ */
|
665
|
+
/* @__PURE__ */ import_react19.default.createElement(
|
663
666
|
"circle",
|
664
667
|
{
|
665
668
|
className: cn(
|
@@ -678,7 +681,7 @@ var Loading = ({
|
|
678
681
|
pathLength: "100"
|
679
682
|
}
|
680
683
|
),
|
681
|
-
/* @__PURE__ */
|
684
|
+
/* @__PURE__ */ import_react19.default.createElement(
|
682
685
|
"circle",
|
683
686
|
{
|
684
687
|
className: cn(
|
@@ -735,7 +738,7 @@ var buttonVariants = (0, import_class_variance_authority.cva)(
|
|
735
738
|
}
|
736
739
|
}
|
737
740
|
);
|
738
|
-
var Button =
|
741
|
+
var Button = React16.forwardRef(
|
739
742
|
({
|
740
743
|
className,
|
741
744
|
variant,
|
@@ -748,7 +751,7 @@ var Button = React15.forwardRef(
|
|
748
751
|
}, ref) => {
|
749
752
|
const Comp = "button";
|
750
753
|
const loadingColor = variant === "outline" || variant === "ghost" || variant === "neoBrutalism" ? "hawa-bg-primary" : "hawa-bg-primary-foreground";
|
751
|
-
return /* @__PURE__ */
|
754
|
+
return /* @__PURE__ */ React16.createElement(
|
752
755
|
Comp,
|
753
756
|
{
|
754
757
|
className: cn(
|
@@ -758,7 +761,7 @@ var Button = React15.forwardRef(
|
|
758
761
|
ref,
|
759
762
|
...props
|
760
763
|
},
|
761
|
-
isLoading ? /* @__PURE__ */
|
764
|
+
isLoading ? /* @__PURE__ */ React16.createElement(
|
762
765
|
Loading,
|
763
766
|
{
|
764
767
|
design: size === "icon" || size === "smallIcon" ? "spinner" : "dots-pulse",
|
@@ -773,8 +776,8 @@ var Button = React15.forwardRef(
|
|
773
776
|
Button.displayName = "Button";
|
774
777
|
|
775
778
|
// elements/card/Card.tsx
|
776
|
-
var
|
777
|
-
var Card =
|
779
|
+
var React17 = __toESM(require("react"));
|
780
|
+
var Card = React17.forwardRef(
|
778
781
|
({
|
779
782
|
className,
|
780
783
|
variant = "default",
|
@@ -793,7 +796,7 @@ var Card = React16.forwardRef(
|
|
793
796
|
clickable && "hawa-cursor-pointer active:hawa-translate-x-0.5 active:hawa-translate-y-0.5 active:hawa-shadow-color-primary-active active:translate-x-0.5 active:translate-y-0.5 active:shadow-color-primary-active"
|
794
797
|
)
|
795
798
|
};
|
796
|
-
return /* @__PURE__ */
|
799
|
+
return /* @__PURE__ */ React17.createElement(
|
797
800
|
"div",
|
798
801
|
{
|
799
802
|
ref,
|
@@ -803,7 +806,7 @@ var Card = React16.forwardRef(
|
|
803
806
|
);
|
804
807
|
}
|
805
808
|
);
|
806
|
-
var CardHeader =
|
809
|
+
var CardHeader = React17.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ React17.createElement(
|
807
810
|
"div",
|
808
811
|
{
|
809
812
|
ref,
|
@@ -814,7 +817,7 @@ var CardHeader = React16.forwardRef(({ className, ...props }, ref) => /* @__PURE
|
|
814
817
|
...props
|
815
818
|
}
|
816
819
|
));
|
817
|
-
var CardTitle =
|
820
|
+
var CardTitle = React17.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ React17.createElement(
|
818
821
|
"h3",
|
819
822
|
{
|
820
823
|
ref,
|
@@ -822,7 +825,7 @@ var CardTitle = React16.forwardRef(({ className, ...props }, ref) => /* @__PURE_
|
|
822
825
|
...props
|
823
826
|
}
|
824
827
|
));
|
825
|
-
var CardDescription =
|
828
|
+
var CardDescription = React17.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ React17.createElement(
|
826
829
|
"p",
|
827
830
|
{
|
828
831
|
ref,
|
@@ -830,8 +833,8 @@ var CardDescription = React16.forwardRef(({ className, ...props }, ref) => /* @_
|
|
830
833
|
...props
|
831
834
|
}
|
832
835
|
));
|
833
|
-
var CardContent =
|
834
|
-
({ headless, noPadding, className, ...props }, ref) => /* @__PURE__ */
|
836
|
+
var CardContent = React17.forwardRef(
|
837
|
+
({ headless, noPadding, className, ...props }, ref) => /* @__PURE__ */ React17.createElement(
|
835
838
|
"div",
|
836
839
|
{
|
837
840
|
ref,
|
@@ -844,7 +847,7 @@ var CardContent = React16.forwardRef(
|
|
844
847
|
}
|
845
848
|
)
|
846
849
|
);
|
847
|
-
var CardFooter =
|
850
|
+
var CardFooter = React17.forwardRef(({ className, noPadding, ...props }, ref) => /* @__PURE__ */ React17.createElement(
|
848
851
|
"div",
|
849
852
|
{
|
850
853
|
ref,
|
@@ -865,7 +868,7 @@ Card.displayName = "Card";
|
|
865
868
|
|
866
869
|
// blocks/misc/EmptyState.tsx
|
867
870
|
var EmptyState = ({ texts, onActionClick }) => {
|
868
|
-
return /* @__PURE__ */
|
871
|
+
return /* @__PURE__ */ import_react20.default.createElement(Card, null, /* @__PURE__ */ import_react20.default.createElement(CardContent, { headless: true }, /* @__PURE__ */ import_react20.default.createElement("div", { className: "hawa-flex hawa-flex-col hawa-items-center hawa-justify-center hawa-text-center " }, /* @__PURE__ */ import_react20.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_react20.default.createElement(
|
869
872
|
"svg",
|
870
873
|
{
|
871
874
|
stroke: "currentColor",
|
@@ -875,42 +878,42 @@ var EmptyState = ({ texts, onActionClick }) => {
|
|
875
878
|
height: "0.35em",
|
876
879
|
width: "0.35em"
|
877
880
|
},
|
878
|
-
/* @__PURE__ */
|
879
|
-
)), /* @__PURE__ */
|
881
|
+
/* @__PURE__ */ import_react20.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" })
|
882
|
+
)), /* @__PURE__ */ import_react20.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_react20.default.createElement(CardFooter, null, /* @__PURE__ */ import_react20.default.createElement(Button, { className: "hawa-w-full", onClick: () => onActionClick() }, (texts == null ? void 0 : texts.actionText) || "Go Home")));
|
880
883
|
};
|
881
884
|
|
882
885
|
// blocks/misc/Testimonial.tsx
|
883
|
-
var
|
886
|
+
var import_react21 = __toESM(require("react"));
|
884
887
|
var Testimonial = () => {
|
885
|
-
return /* @__PURE__ */
|
888
|
+
return /* @__PURE__ */ import_react21.default.createElement(Card, null, /* @__PURE__ */ import_react21.default.createElement(CardContent, { headless: true }, /* @__PURE__ */ import_react21.default.createElement("div", null, /* @__PURE__ */ import_react21.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_react21.default.createElement("div", { className: "flex flex-row gap-4" }, /* @__PURE__ */ import_react21.default.createElement("svg", { width: "48", height: "48", viewBox: "0 0 48 48", fill: "none" }, /* @__PURE__ */ import_react21.default.createElement("rect", { width: "48", height: "48", rx: "24", fill: "#45BE8B" }), /* @__PURE__ */ import_react21.default.createElement(
|
886
889
|
"path",
|
887
890
|
{
|
888
891
|
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",
|
889
892
|
fill: "#FFFFFF"
|
890
893
|
}
|
891
|
-
), /* @__PURE__ */
|
894
|
+
), /* @__PURE__ */ import_react21.default.createElement(
|
892
895
|
"path",
|
893
896
|
{
|
894
897
|
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",
|
895
898
|
fill: "#FFFFFF"
|
896
899
|
}
|
897
|
-
)), /* @__PURE__ */
|
900
|
+
)), /* @__PURE__ */ import_react21.default.createElement("span", { className: "border border-l " }), " ", /* @__PURE__ */ import_react21.default.createElement("div", null, /* @__PURE__ */ import_react21.default.createElement("strong", null, "Brent Lassi"), /* @__PURE__ */ import_react21.default.createElement("div", null, " Chief Information Security Officer")))));
|
898
901
|
};
|
899
902
|
|
900
903
|
// blocks/misc/LeadGenerator.tsx
|
901
|
-
var
|
904
|
+
var import_react25 = __toESM(require("react"));
|
902
905
|
var import_react_hook_form = require("react-hook-form");
|
903
906
|
|
904
907
|
// elements/input/Input.tsx
|
905
|
-
var
|
908
|
+
var import_react24 = __toESM(require("react"));
|
906
909
|
|
907
910
|
// elements/label/Label.tsx
|
908
|
-
var
|
911
|
+
var React21 = __toESM(require("react"));
|
909
912
|
|
910
913
|
// elements/tooltip/Tooltip.tsx
|
911
|
-
var
|
914
|
+
var import_react22 = __toESM(require("react"));
|
912
915
|
var TooltipPrimitive = __toESM(require("@radix-ui/react-tooltip"));
|
913
|
-
var TooltipContent =
|
916
|
+
var TooltipContent = import_react22.default.forwardRef(({ className, sideOffset = 4, size = "default", ...props }, ref) => /* @__PURE__ */ import_react22.default.createElement(
|
914
917
|
TooltipPrimitive.Content,
|
915
918
|
{
|
916
919
|
ref,
|
@@ -927,7 +930,7 @@ var TooltipContent = import_react21.default.forwardRef(({ className, sideOffset
|
|
927
930
|
}
|
928
931
|
));
|
929
932
|
TooltipContent.displayName = TooltipPrimitive.Content.displayName;
|
930
|
-
var TooltipArrow =
|
933
|
+
var TooltipArrow = import_react22.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ import_react22.default.createElement(TooltipPrimitive.Arrow, { ref, className: cn(className), ...props }));
|
931
934
|
TooltipArrow.displayName = TooltipPrimitive.Arrow.displayName;
|
932
935
|
var Tooltip = ({
|
933
936
|
side,
|
@@ -944,13 +947,13 @@ var Tooltip = ({
|
|
944
947
|
delayDuration = 300,
|
945
948
|
...props
|
946
949
|
}) => {
|
947
|
-
return /* @__PURE__ */
|
950
|
+
return /* @__PURE__ */ import_react22.default.createElement(
|
948
951
|
TooltipPrimitive.TooltipProvider,
|
949
952
|
{
|
950
953
|
delayDuration,
|
951
954
|
...providerProps
|
952
955
|
},
|
953
|
-
/* @__PURE__ */
|
956
|
+
/* @__PURE__ */ import_react22.default.createElement(
|
954
957
|
TooltipPrimitive.Root,
|
955
958
|
{
|
956
959
|
open: !disabled && open,
|
@@ -958,8 +961,8 @@ var Tooltip = ({
|
|
958
961
|
onOpenChange,
|
959
962
|
...props
|
960
963
|
},
|
961
|
-
/* @__PURE__ */
|
962
|
-
/* @__PURE__ */
|
964
|
+
/* @__PURE__ */ import_react22.default.createElement(TooltipPrimitive.Trigger, { ...triggerProps }, children),
|
965
|
+
/* @__PURE__ */ import_react22.default.createElement(
|
963
966
|
TooltipContent,
|
964
967
|
{
|
965
968
|
size,
|
@@ -979,7 +982,7 @@ var Tooltip = ({
|
|
979
982
|
};
|
980
983
|
|
981
984
|
// elements/label/Label.tsx
|
982
|
-
var Label =
|
985
|
+
var Label = React21.forwardRef(({ className, hint, hintSide, required, children, ...props }, ref) => /* @__PURE__ */ React21.createElement("div", { className: "hawa-flex hawa-flex-row hawa-items-center hawa-gap-1 hawa-transition-all" }, /* @__PURE__ */ React21.createElement(
|
983
986
|
"label",
|
984
987
|
{
|
985
988
|
ref,
|
@@ -990,8 +993,8 @@ var Label = React20.forwardRef(({ className, hint, hintSide, required, children,
|
|
990
993
|
...props
|
991
994
|
},
|
992
995
|
children,
|
993
|
-
required && /* @__PURE__ */
|
994
|
-
), hint && /* @__PURE__ */
|
996
|
+
required && /* @__PURE__ */ React21.createElement("span", { className: "hawa-mx-0.5 hawa-text-red-500" }, "*")
|
997
|
+
), hint && /* @__PURE__ */ React21.createElement(
|
995
998
|
Tooltip,
|
996
999
|
{
|
997
1000
|
content: hint,
|
@@ -1001,7 +1004,7 @@ var Label = React20.forwardRef(({ className, hint, hintSide, required, children,
|
|
1001
1004
|
onClick: (event) => event.preventDefault()
|
1002
1005
|
}
|
1003
1006
|
},
|
1004
|
-
/* @__PURE__ */
|
1007
|
+
/* @__PURE__ */ React21.createElement("div", null, /* @__PURE__ */ React21.createElement(
|
1005
1008
|
"svg",
|
1006
1009
|
{
|
1007
1010
|
xmlns: "http://www.w3.org/2000/svg",
|
@@ -1013,15 +1016,15 @@ var Label = React20.forwardRef(({ className, hint, hintSide, required, children,
|
|
1013
1016
|
strokeLinecap: "round",
|
1014
1017
|
strokeLinejoin: "round"
|
1015
1018
|
},
|
1016
|
-
/* @__PURE__ */
|
1017
|
-
/* @__PURE__ */
|
1018
|
-
/* @__PURE__ */
|
1019
|
+
/* @__PURE__ */ React21.createElement("circle", { cx: "12", cy: "12", r: "10" }),
|
1020
|
+
/* @__PURE__ */ React21.createElement("path", { d: "M9.09 9a3 3 0 0 1 5.83 1c0 2-3 3-3 3" }),
|
1021
|
+
/* @__PURE__ */ React21.createElement("path", { d: "M12 17h.01" })
|
1019
1022
|
))
|
1020
1023
|
)));
|
1021
1024
|
Label.displayName = "Label";
|
1022
1025
|
|
1023
1026
|
// elements/skeleton/Skeleton.tsx
|
1024
|
-
var
|
1027
|
+
var import_react23 = __toESM(require("react"));
|
1025
1028
|
function Skeleton({
|
1026
1029
|
className,
|
1027
1030
|
content,
|
@@ -1040,7 +1043,7 @@ function Skeleton({
|
|
1040
1043
|
right: "hawa-mask-fade-right",
|
1041
1044
|
left: "hawa-mask-fade-left "
|
1042
1045
|
};
|
1043
|
-
return /* @__PURE__ */
|
1046
|
+
return /* @__PURE__ */ import_react23.default.createElement(
|
1044
1047
|
"div",
|
1045
1048
|
{
|
1046
1049
|
className: cn(
|
@@ -1056,7 +1059,7 @@ function Skeleton({
|
|
1056
1059
|
}
|
1057
1060
|
|
1058
1061
|
// elements/input/Input.tsx
|
1059
|
-
var Input = (0,
|
1062
|
+
var Input = (0, import_react24.forwardRef)(
|
1060
1063
|
({
|
1061
1064
|
margin = "none",
|
1062
1065
|
width = "full",
|
@@ -1100,7 +1103,7 @@ var Input = (0, import_react23.forwardRef)(
|
|
1100
1103
|
props.onChange(newEvent);
|
1101
1104
|
}
|
1102
1105
|
};
|
1103
|
-
return /* @__PURE__ */
|
1106
|
+
return /* @__PURE__ */ import_react24.default.createElement(
|
1104
1107
|
"div",
|
1105
1108
|
{
|
1106
1109
|
className: cn(
|
@@ -1111,8 +1114,8 @@ var Input = (0, import_react23.forwardRef)(
|
|
1111
1114
|
"hawa-w-full hawa-gap-2"
|
1112
1115
|
)
|
1113
1116
|
},
|
1114
|
-
props.label && /* @__PURE__ */
|
1115
|
-
/* @__PURE__ */
|
1117
|
+
props.label && /* @__PURE__ */ import_react24.default.createElement(Label, { ...labelProps }, props.label),
|
1118
|
+
/* @__PURE__ */ import_react24.default.createElement("div", { className: "hawa-flex hawa-flex-row hawa-w-full hawa-items-center " }, props.outsidePrefix && /* @__PURE__ */ import_react24.default.createElement(
|
1116
1119
|
"span",
|
1117
1120
|
{
|
1118
1121
|
className: cn(
|
@@ -1121,7 +1124,7 @@ var Input = (0, import_react23.forwardRef)(
|
|
1121
1124
|
)
|
1122
1125
|
},
|
1123
1126
|
props.outsidePrefix
|
1124
|
-
), props.isLoading ? /* @__PURE__ */
|
1127
|
+
), props.isLoading ? /* @__PURE__ */ import_react24.default.createElement("div", { className: "hawa-pb-2" }, /* @__PURE__ */ import_react24.default.createElement(Skeleton, { className: "hawa-h-[40px] hawa-w-full" })) : /* @__PURE__ */ import_react24.default.createElement(import_react24.default.Fragment, null, !props.hideSeparator && /* @__PURE__ */ import_react24.default.createElement(
|
1125
1128
|
"div",
|
1126
1129
|
{
|
1127
1130
|
className: cn(
|
@@ -1129,7 +1132,7 @@ var Input = (0, import_react23.forwardRef)(
|
|
1129
1132
|
preview ? "hawa-opacity-100" : "hawa-opacity-0"
|
1130
1133
|
)
|
1131
1134
|
}
|
1132
|
-
), /* @__PURE__ */
|
1135
|
+
), /* @__PURE__ */ import_react24.default.createElement("div", { className: "hawa-flex hawa-flex-col hawa-w-full hawa-gap-2" }, /* @__PURE__ */ import_react24.default.createElement("div", { className: "hawa-relative" }, props.startIcon && /* @__PURE__ */ import_react24.default.createElement("div", { className: "hawa-absolute hawa-start-3 hawa-top-1/2 hawa--translate-y-1/2" }, props.startIcon), props.endIcon && /* @__PURE__ */ import_react24.default.createElement(
|
1133
1136
|
"div",
|
1134
1137
|
{
|
1135
1138
|
className: cn(
|
@@ -1138,7 +1141,7 @@ var Input = (0, import_react23.forwardRef)(
|
|
1138
1141
|
)
|
1139
1142
|
},
|
1140
1143
|
props.endIcon
|
1141
|
-
), /* @__PURE__ */
|
1144
|
+
), /* @__PURE__ */ import_react24.default.createElement(
|
1142
1145
|
"input",
|
1143
1146
|
{
|
1144
1147
|
required: true,
|
@@ -1164,7 +1167,7 @@ var Input = (0, import_react23.forwardRef)(
|
|
1164
1167
|
inputProps == null ? void 0 : inputProps.className
|
1165
1168
|
)
|
1166
1169
|
}
|
1167
|
-
)), !forceHideHelperText && /* @__PURE__ */
|
1170
|
+
)), !forceHideHelperText && /* @__PURE__ */ import_react24.default.createElement(
|
1168
1171
|
"p",
|
1169
1172
|
{
|
1170
1173
|
className: cn(
|
@@ -1173,7 +1176,7 @@ var Input = (0, import_react23.forwardRef)(
|
|
1173
1176
|
)
|
1174
1177
|
},
|
1175
1178
|
props.helperText
|
1176
|
-
), !props.disabled && forceHideHelperText && /* @__PURE__ */
|
1179
|
+
), !props.disabled && forceHideHelperText && /* @__PURE__ */ import_react24.default.createElement(
|
1177
1180
|
"div",
|
1178
1181
|
{
|
1179
1182
|
className: cn(
|
@@ -1182,7 +1185,7 @@ var Input = (0, import_react23.forwardRef)(
|
|
1182
1185
|
)
|
1183
1186
|
},
|
1184
1187
|
props.helperText
|
1185
|
-
), showCount && /* @__PURE__ */
|
1188
|
+
), showCount && /* @__PURE__ */ import_react24.default.createElement(
|
1186
1189
|
"div",
|
1187
1190
|
{
|
1188
1191
|
className: cn(
|
@@ -1213,14 +1216,14 @@ var LeadGenerator = ({ texts, submitHandler }) => {
|
|
1213
1216
|
console.log("handleNewsletterSub props was not provided");
|
1214
1217
|
}
|
1215
1218
|
};
|
1216
|
-
return /* @__PURE__ */
|
1219
|
+
return /* @__PURE__ */ import_react25.default.createElement(Card, null, /* @__PURE__ */ import_react25.default.createElement(CardHeader, null, /* @__PURE__ */ import_react25.default.createElement(CardTitle, null, texts == null ? void 0 : texts.title), /* @__PURE__ */ import_react25.default.createElement(CardDescription, null, texts == null ? void 0 : texts.subtitle)), /* @__PURE__ */ import_react25.default.createElement(CardContent, null, /* @__PURE__ */ import_react25.default.createElement(
|
1217
1220
|
"form",
|
1218
1221
|
{
|
1219
1222
|
noValidate: true,
|
1220
1223
|
className: "hawa-flex hawa-flex-row hawa-gap-2",
|
1221
1224
|
onSubmit: handleSubmit(onSubmit)
|
1222
1225
|
},
|
1223
|
-
/* @__PURE__ */
|
1226
|
+
/* @__PURE__ */ import_react25.default.createElement(
|
1224
1227
|
import_react_hook_form.Controller,
|
1225
1228
|
{
|
1226
1229
|
name: "email",
|
@@ -1233,27 +1236,27 @@ var LeadGenerator = ({ texts, submitHandler }) => {
|
|
1233
1236
|
}
|
1234
1237
|
},
|
1235
1238
|
defaultValue: "",
|
1236
|
-
render: ({ field }) => /* @__PURE__ */
|
1239
|
+
render: ({ field }) => /* @__PURE__ */ import_react25.default.createElement(Input, { ...field, type: "email", placeholder: "example@sikka.io" })
|
1237
1240
|
}
|
1238
1241
|
),
|
1239
|
-
/* @__PURE__ */
|
1242
|
+
/* @__PURE__ */ import_react25.default.createElement(Button, { type: "submit", disabled: !formState.isValid }, (_a = texts == null ? void 0 : texts.submit) != null ? _a : "Submit")
|
1240
1243
|
)));
|
1241
1244
|
};
|
1242
1245
|
|
1243
1246
|
// blocks/misc/Announcement.tsx
|
1244
|
-
var
|
1247
|
+
var import_react26 = __toESM(require("react"));
|
1245
1248
|
var Announcement = ({
|
1246
1249
|
onActionClick,
|
1247
1250
|
...props
|
1248
1251
|
}) => {
|
1249
|
-
return /* @__PURE__ */
|
1252
|
+
return /* @__PURE__ */ import_react26.default.createElement(Card, null, /* @__PURE__ */ import_react26.default.createElement(
|
1250
1253
|
CardContent,
|
1251
1254
|
{
|
1252
1255
|
headless: true,
|
1253
1256
|
className: "hawa-flex hawa-flex-row hawa-items-center hawa-justify-between"
|
1254
1257
|
},
|
1255
|
-
/* @__PURE__ */
|
1256
|
-
/* @__PURE__ */
|
1258
|
+
/* @__PURE__ */ import_react26.default.createElement("div", { className: "hawa-flex hawa-flex-col hawa-items-start hawa-justify-center " }, /* @__PURE__ */ import_react26.default.createElement("span", { className: "hawa-text-lg hawa-font-bold" }, props.title), /* @__PURE__ */ import_react26.default.createElement("span", { className: "hawa-text-sm" }, props.subtitle)),
|
1259
|
+
/* @__PURE__ */ import_react26.default.createElement(
|
1257
1260
|
Button,
|
1258
1261
|
{
|
1259
1262
|
onClick: () => onActionClick(),
|
@@ -1265,15 +1268,15 @@ var Announcement = ({
|
|
1265
1268
|
};
|
1266
1269
|
|
1267
1270
|
// blocks/misc/NotFound.tsx
|
1268
|
-
var
|
1271
|
+
var import_react27 = __toESM(require("react"));
|
1269
1272
|
var NotFound = ({ texts }) => {
|
1270
|
-
return /* @__PURE__ */
|
1273
|
+
return /* @__PURE__ */ import_react27.default.createElement(Card, null, /* @__PURE__ */ import_react27.default.createElement(CardContent, { headless: true }, /* @__PURE__ */ import_react27.default.createElement("div", { className: "hawa-flex hawa-flex-col hawa-items-center dark:hawa-text-white" }, /* @__PURE__ */ import_react27.default.createElement("div", { className: "hawa-text-center hawa-text-6xl hawa-font-bold " }, "404"), /* @__PURE__ */ import_react27.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_react27.default.createElement("div", { className: "hawa-mb-4 hawa-text-center" }, (texts == null ? void 0 : texts.ifLost) || /* @__PURE__ */ import_react27.default.createElement(import_react27.default.Fragment, null, "If you're lost please contact us ", /* @__PURE__ */ import_react27.default.createElement("span", { className: "clickable-link" }, "help@sikka.io"))), /* @__PURE__ */ import_react27.default.createElement(Button, { className: "hawa-w-full" }, (texts == null ? void 0 : texts.home) || "Home"))));
|
1271
1274
|
};
|
1272
1275
|
|
1273
1276
|
// blocks/misc/NoPermission.tsx
|
1274
|
-
var
|
1277
|
+
var import_react28 = __toESM(require("react"));
|
1275
1278
|
var NoPermission = ({ texts }) => {
|
1276
|
-
return /* @__PURE__ */
|
1279
|
+
return /* @__PURE__ */ import_react28.default.createElement(Card, null, /* @__PURE__ */ import_react28.default.createElement(CardContent, { headless: true }, /* @__PURE__ */ import_react28.default.createElement("div", { className: "hawa-flex hawa-flex-col hawa-items-center hawa-justify-center hawa-text-center" }, /* @__PURE__ */ import_react28.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_react28.default.createElement(
|
1277
1280
|
"svg",
|
1278
1281
|
{
|
1279
1282
|
stroke: "currentColor",
|
@@ -1283,18 +1286,18 @@ var NoPermission = ({ texts }) => {
|
|
1283
1286
|
height: "0.35em",
|
1284
1287
|
width: "0.35em"
|
1285
1288
|
},
|
1286
|
-
/* @__PURE__ */
|
1287
|
-
)), /* @__PURE__ */
|
1289
|
+
/* @__PURE__ */ import_react28.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" })
|
1290
|
+
)), /* @__PURE__ */ import_react28.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_react28.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"))));
|
1288
1291
|
};
|
1289
1292
|
|
1290
1293
|
// blocks/misc/ContactForm.tsx
|
1291
|
-
var
|
1294
|
+
var import_react30 = __toESM(require("react"));
|
1292
1295
|
var import_react_hook_form2 = require("react-hook-form");
|
1293
1296
|
var import_zod = require("@hookform/resolvers/zod");
|
1294
1297
|
var z = __toESM(require("zod"));
|
1295
1298
|
|
1296
1299
|
// elements/select/Select.tsx
|
1297
|
-
var
|
1300
|
+
var import_react29 = __toESM(require("react"));
|
1298
1301
|
var import_react_select = __toESM(require("react-select"));
|
1299
1302
|
var import_creatable = __toESM(require("react-select/creatable"));
|
1300
1303
|
var import_clsx2 = __toESM(require("clsx"));
|
@@ -1305,10 +1308,10 @@ var Select = ({
|
|
1305
1308
|
}) => {
|
1306
1309
|
const NoOption = () => {
|
1307
1310
|
var _a, _b;
|
1308
|
-
return /* @__PURE__ */
|
1311
|
+
return /* @__PURE__ */ import_react29.default.createElement("div", null, (_b = (_a = props.texts) == null ? void 0 : _a.noOptions) != null ? _b : "No Items Found");
|
1309
1312
|
};
|
1310
1313
|
const Control = ({ children, innerProps, innerRef }) => {
|
1311
|
-
return /* @__PURE__ */
|
1314
|
+
return /* @__PURE__ */ import_react29.default.createElement(
|
1312
1315
|
"div",
|
1313
1316
|
{
|
1314
1317
|
ref: innerRef,
|
@@ -1321,7 +1324,7 @@ var Select = ({
|
|
1321
1324
|
);
|
1322
1325
|
};
|
1323
1326
|
const Option = ({ children, innerProps, innerRef }) => {
|
1324
|
-
return /* @__PURE__ */
|
1327
|
+
return /* @__PURE__ */ import_react29.default.createElement(
|
1325
1328
|
"div",
|
1326
1329
|
{
|
1327
1330
|
ref: innerRef,
|
@@ -1342,7 +1345,7 @@ var Select = ({
|
|
1342
1345
|
...menuProps
|
1343
1346
|
}) => {
|
1344
1347
|
const menuOpen = menuProps.selectProps.menuIsOpen;
|
1345
|
-
return /* @__PURE__ */
|
1348
|
+
return /* @__PURE__ */ import_react29.default.createElement(
|
1346
1349
|
"div",
|
1347
1350
|
{
|
1348
1351
|
className: cn(
|
@@ -1356,7 +1359,7 @@ var Select = ({
|
|
1356
1359
|
children
|
1357
1360
|
);
|
1358
1361
|
};
|
1359
|
-
return /* @__PURE__ */
|
1362
|
+
return /* @__PURE__ */ import_react29.default.createElement(
|
1360
1363
|
"div",
|
1361
1364
|
{
|
1362
1365
|
className: cn(
|
@@ -1364,10 +1367,10 @@ var Select = ({
|
|
1364
1367
|
props.width === "fit" ? "hawa-w-fit" : "hawa-w-full"
|
1365
1368
|
)
|
1366
1369
|
},
|
1367
|
-
props.label && /* @__PURE__ */
|
1368
|
-
props.isLoading ? /* @__PURE__ */
|
1370
|
+
props.label && /* @__PURE__ */ import_react29.default.createElement(Label, { ...labelProps }, props.label),
|
1371
|
+
props.isLoading ? /* @__PURE__ */ import_react29.default.createElement(Skeleton, { className: "hawa-h-[40px] hawa-w-full" }) : !props.isCreatable ? (
|
1369
1372
|
// TODO: enable keyboard to go to the next item in the list
|
1370
|
-
/* @__PURE__ */
|
1373
|
+
/* @__PURE__ */ import_react29.default.createElement(
|
1371
1374
|
import_react_select.default,
|
1372
1375
|
{
|
1373
1376
|
noOptionsMessage: NoOption,
|
@@ -1406,7 +1409,7 @@ var Select = ({
|
|
1406
1409
|
// {...e}
|
1407
1410
|
// />
|
1408
1411
|
// ),
|
1409
|
-
ValueContainer: (e) => /* @__PURE__ */
|
1412
|
+
ValueContainer: (e) => /* @__PURE__ */ import_react29.default.createElement(
|
1410
1413
|
"div",
|
1411
1414
|
{
|
1412
1415
|
className: cn(
|
@@ -1416,7 +1419,7 @@ var Select = ({
|
|
1416
1419
|
...e
|
1417
1420
|
}
|
1418
1421
|
),
|
1419
|
-
MultiValueContainer: (e) => /* @__PURE__ */
|
1422
|
+
MultiValueContainer: (e) => /* @__PURE__ */ import_react29.default.createElement(
|
1420
1423
|
"div",
|
1421
1424
|
{
|
1422
1425
|
className: cn(
|
@@ -1438,7 +1441,7 @@ var Select = ({
|
|
1438
1441
|
isSearchable: props.isSearchable
|
1439
1442
|
}
|
1440
1443
|
)
|
1441
|
-
) : /* @__PURE__ */
|
1444
|
+
) : /* @__PURE__ */ import_react29.default.createElement(
|
1442
1445
|
import_creatable.default,
|
1443
1446
|
{
|
1444
1447
|
formatCreateLabel: (inputValue) => {
|
@@ -1468,7 +1471,7 @@ var Select = ({
|
|
1468
1471
|
onInputChange: (newValue, action) => props.onInputChange(newValue, action)
|
1469
1472
|
}
|
1470
1473
|
),
|
1471
|
-
!props.hideHelperText && /* @__PURE__ */
|
1474
|
+
!props.hideHelperText && /* @__PURE__ */ import_react29.default.createElement(
|
1472
1475
|
"p",
|
1473
1476
|
{
|
1474
1477
|
className: cn(
|
@@ -1482,8 +1485,8 @@ var Select = ({
|
|
1482
1485
|
};
|
1483
1486
|
|
1484
1487
|
// elements/textarea/Textarea.tsx
|
1485
|
-
var
|
1486
|
-
var Textarea =
|
1488
|
+
var React29 = __toESM(require("react"));
|
1489
|
+
var Textarea = React29.forwardRef(
|
1487
1490
|
({
|
1488
1491
|
className,
|
1489
1492
|
classNames,
|
@@ -1495,7 +1498,7 @@ var Textarea = React28.forwardRef(
|
|
1495
1498
|
isLoading,
|
1496
1499
|
...props
|
1497
1500
|
}, ref) => {
|
1498
|
-
return /* @__PURE__ */
|
1501
|
+
return /* @__PURE__ */ React29.createElement(
|
1499
1502
|
"div",
|
1500
1503
|
{
|
1501
1504
|
className: cn(
|
@@ -1504,7 +1507,7 @@ var Textarea = React28.forwardRef(
|
|
1504
1507
|
className
|
1505
1508
|
)
|
1506
1509
|
},
|
1507
|
-
/* @__PURE__ */
|
1510
|
+
/* @__PURE__ */ React29.createElement("div", { className: "hawa-flex hawa-flex-row hawa-justify-between" }, props.label && /* @__PURE__ */ React29.createElement(Label, { ...labelProps }, props.label), showCount && countPosition === "top" && /* @__PURE__ */ React29.createElement(
|
1508
1511
|
"div",
|
1509
1512
|
{
|
1510
1513
|
className: "hawa-text-start hawa-text-xs hawa-transition-all hawa-leading-none"
|
@@ -1513,7 +1516,7 @@ var Textarea = React28.forwardRef(
|
|
1513
1516
|
"/",
|
1514
1517
|
textareaProps == null ? void 0 : textareaProps.maxLength
|
1515
1518
|
)),
|
1516
|
-
isLoading ? /* @__PURE__ */
|
1519
|
+
isLoading ? /* @__PURE__ */ React29.createElement(Skeleton, { style: { height: 40 } }) : /* @__PURE__ */ React29.createElement(
|
1517
1520
|
"textarea",
|
1518
1521
|
{
|
1519
1522
|
...textareaProps,
|
@@ -1524,7 +1527,7 @@ var Textarea = React28.forwardRef(
|
|
1524
1527
|
ref
|
1525
1528
|
}
|
1526
1529
|
),
|
1527
|
-
/* @__PURE__ */
|
1530
|
+
/* @__PURE__ */ React29.createElement("div", { className: "hawa-flex hawa-flex-row hawa-justify-between" }, !forceHideHelperText && /* @__PURE__ */ React29.createElement(
|
1528
1531
|
"p",
|
1529
1532
|
{
|
1530
1533
|
className: cn(
|
@@ -1533,7 +1536,7 @@ var Textarea = React28.forwardRef(
|
|
1533
1536
|
)
|
1534
1537
|
},
|
1535
1538
|
props.helperText
|
1536
|
-
), showCount && countPosition === "bottom" && /* @__PURE__ */
|
1539
|
+
), 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))
|
1537
1540
|
);
|
1538
1541
|
}
|
1539
1542
|
);
|
@@ -1608,7 +1611,7 @@ var ContactForm = ({
|
|
1608
1611
|
console.log("Form is submitted but onSubmit prop is missing");
|
1609
1612
|
}
|
1610
1613
|
};
|
1611
|
-
return /* @__PURE__ */
|
1614
|
+
return /* @__PURE__ */ import_react30.default.createElement(
|
1612
1615
|
Card,
|
1613
1616
|
{
|
1614
1617
|
className: cn(
|
@@ -1617,7 +1620,7 @@ var ContactForm = ({
|
|
1617
1620
|
),
|
1618
1621
|
style: cardless ? { boxShadow: "none" } : void 0
|
1619
1622
|
},
|
1620
|
-
/* @__PURE__ */
|
1623
|
+
/* @__PURE__ */ import_react30.default.createElement(CardContent, { headless: true, className: cardless ? "!hawa-p-0" : "" }, /* @__PURE__ */ import_react30.default.createElement(
|
1621
1624
|
"form",
|
1622
1625
|
{
|
1623
1626
|
noValidate: true,
|
@@ -1626,7 +1629,7 @@ var ContactForm = ({
|
|
1626
1629
|
id: formId,
|
1627
1630
|
autoComplete: formAutoComplete
|
1628
1631
|
},
|
1629
|
-
/* @__PURE__ */
|
1632
|
+
/* @__PURE__ */ import_react30.default.createElement(
|
1630
1633
|
"div",
|
1631
1634
|
{
|
1632
1635
|
className: cn(
|
@@ -1637,14 +1640,14 @@ var ContactForm = ({
|
|
1637
1640
|
}
|
1638
1641
|
)
|
1639
1642
|
},
|
1640
|
-
/* @__PURE__ */
|
1643
|
+
/* @__PURE__ */ import_react30.default.createElement(
|
1641
1644
|
import_react_hook_form2.Controller,
|
1642
1645
|
{
|
1643
1646
|
control,
|
1644
1647
|
name: "name",
|
1645
1648
|
render: ({ field }) => {
|
1646
1649
|
var _a2;
|
1647
|
-
return /* @__PURE__ */
|
1650
|
+
return /* @__PURE__ */ import_react30.default.createElement(
|
1648
1651
|
Input,
|
1649
1652
|
{
|
1650
1653
|
label: (texts == null ? void 0 : texts.name.label) || "Name",
|
@@ -1657,14 +1660,14 @@ var ContactForm = ({
|
|
1657
1660
|
}
|
1658
1661
|
}
|
1659
1662
|
),
|
1660
|
-
/* @__PURE__ */
|
1663
|
+
/* @__PURE__ */ import_react30.default.createElement(
|
1661
1664
|
import_react_hook_form2.Controller,
|
1662
1665
|
{
|
1663
1666
|
control,
|
1664
1667
|
name: "email",
|
1665
1668
|
render: ({ field }) => {
|
1666
1669
|
var _a2;
|
1667
|
-
return /* @__PURE__ */
|
1670
|
+
return /* @__PURE__ */ import_react30.default.createElement(
|
1668
1671
|
Input,
|
1669
1672
|
{
|
1670
1673
|
label: (texts == null ? void 0 : texts.email.label) || "Email",
|
@@ -1680,7 +1683,7 @@ var ContactForm = ({
|
|
1680
1683
|
),
|
1681
1684
|
customFields && customFields.map((customField) => {
|
1682
1685
|
console.log("custom", customField);
|
1683
|
-
return /* @__PURE__ */
|
1686
|
+
return /* @__PURE__ */ import_react30.default.createElement(
|
1684
1687
|
import_react_hook_form2.Controller,
|
1685
1688
|
{
|
1686
1689
|
control,
|
@@ -1690,7 +1693,7 @@ var ContactForm = ({
|
|
1690
1693
|
switch (type) {
|
1691
1694
|
case "text":
|
1692
1695
|
case "number":
|
1693
|
-
return /* @__PURE__ */
|
1696
|
+
return /* @__PURE__ */ import_react30.default.createElement(
|
1694
1697
|
Input,
|
1695
1698
|
{
|
1696
1699
|
id: customField.name,
|
@@ -1701,7 +1704,7 @@ var ContactForm = ({
|
|
1701
1704
|
}
|
1702
1705
|
);
|
1703
1706
|
case "select":
|
1704
|
-
return /* @__PURE__ */
|
1707
|
+
return /* @__PURE__ */ import_react30.default.createElement(
|
1705
1708
|
Select,
|
1706
1709
|
{
|
1707
1710
|
label,
|
@@ -1711,20 +1714,20 @@ var ContactForm = ({
|
|
1711
1714
|
}
|
1712
1715
|
);
|
1713
1716
|
default:
|
1714
|
-
return /* @__PURE__ */
|
1717
|
+
return /* @__PURE__ */ import_react30.default.createElement("div", null, "Unknown type");
|
1715
1718
|
}
|
1716
1719
|
}
|
1717
1720
|
}
|
1718
1721
|
);
|
1719
1722
|
}),
|
1720
|
-
/* @__PURE__ */
|
1723
|
+
/* @__PURE__ */ import_react30.default.createElement(
|
1721
1724
|
import_react_hook_form2.Controller,
|
1722
1725
|
{
|
1723
1726
|
control,
|
1724
1727
|
name: "message",
|
1725
1728
|
render: ({ field }) => {
|
1726
1729
|
var _a2;
|
1727
|
-
return /* @__PURE__ */
|
1730
|
+
return /* @__PURE__ */ import_react30.default.createElement(
|
1728
1731
|
Textarea,
|
1729
1732
|
{
|
1730
1733
|
label: (texts == null ? void 0 : texts.message.label) || "Message",
|
@@ -1741,7 +1744,7 @@ var ContactForm = ({
|
|
1741
1744
|
}
|
1742
1745
|
}
|
1743
1746
|
),
|
1744
|
-
/* @__PURE__ */
|
1747
|
+
/* @__PURE__ */ import_react30.default.createElement(Button, { type: "submit", className: "hawa-w-full" }, (texts == null ? void 0 : texts.submit) || "Submit")
|
1745
1748
|
))
|
1746
1749
|
);
|
1747
1750
|
};
|