@sikka/hawa 0.27.19-next → 0.27.21-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.
@@ -3704,7 +3704,7 @@ var RegisterForm = ({
3704
3704
  showNewsletterOption = false,
3705
3705
  ...props
3706
3706
  }) => {
3707
- var _a, _b, _c, _d, _e, _f;
3707
+ var _a, _b, _c, _d, _e, _f, _g, _h;
3708
3708
  const [passwordVisible, setPasswordVisible] = (0, import_react15.useState)(false);
3709
3709
  const thirdPartyAuthTexts = {
3710
3710
  continueWithGoogle: texts == null ? void 0 : texts.continueWithGoogle,
@@ -3770,281 +3770,290 @@ var RegisterForm = ({
3770
3770
  const { handleSubmit, control, formState } = (0, import_react_hook_form2.useForm)({
3771
3771
  resolver: (0, import_zod2.zodResolver)(formSchema)
3772
3772
  });
3773
- return /* @__PURE__ */ import_react15.default.createElement("div", { className: "hawa-flex hawa-flex-col hawa-gap-4" }, /* @__PURE__ */ import_react15.default.createElement(Card, { dir: props.direction }, /* @__PURE__ */ import_react15.default.createElement(CardContent, { headless: true }, /* @__PURE__ */ import_react15.default.createElement("div", null, props.showError && /* @__PURE__ */ import_react15.default.createElement(
3774
- Alert,
3775
- {
3776
- title: props.errorTitle,
3777
- text: props.errorText,
3778
- severity: "error"
3779
- }
3780
- ), /* @__PURE__ */ import_react15.default.createElement(import_react_hook_form2.FormProvider, { ...methods }, /* @__PURE__ */ import_react15.default.createElement(
3781
- "form",
3773
+ return /* @__PURE__ */ import_react15.default.createElement(
3774
+ "div",
3782
3775
  {
3783
- noValidate: true,
3784
- onSubmit: handleSubmit((e) => {
3785
- if (props.onRegister) {
3786
- return props.onRegister(e);
3787
- } else {
3788
- console.log(
3789
- "Form is submitted but onRegister prop is missing"
3790
- );
3791
- }
3792
- }),
3793
- className: "hawa-flex hawa-flex-col hawa-gap-4"
3776
+ className: cn(
3777
+ "hawa-flex hawa-flex-col hawa-gap-4",
3778
+ (_g = props.classNames) == null ? void 0 : _g.root
3779
+ )
3794
3780
  },
3795
- /* @__PURE__ */ import_react15.default.createElement("div", { className: "hawa-flex hawa-flex-col hawa-gap-4" }, registerFields.map((fld, i) => {
3796
- if (fld === "fullname") {
3797
- return /* @__PURE__ */ import_react15.default.createElement(
3798
- import_react_hook_form2.Controller,
3799
- {
3800
- key: i,
3801
- control,
3802
- name: "fullName",
3803
- render: ({ field }) => {
3804
- var _a2, _b2, _c2;
3805
- return /* @__PURE__ */ import_react15.default.createElement(
3806
- Input,
3807
- {
3808
- width: "full",
3809
- label: ((_a2 = texts == null ? void 0 : texts.fullName) == null ? void 0 : _a2.label) || "Full Name",
3810
- placeholder: (_b2 = texts == null ? void 0 : texts.fullName) == null ? void 0 : _b2.placeholder,
3811
- helperText: (_c2 = formState.errors.fullName) == null ? void 0 : _c2.message,
3812
- ...field
3813
- }
3814
- );
3815
- }
3816
- }
3817
- );
3818
- }
3819
- if (fld === "email") {
3820
- return /* @__PURE__ */ import_react15.default.createElement(
3821
- import_react_hook_form2.Controller,
3822
- {
3823
- key: i,
3824
- control,
3825
- name: "email",
3826
- render: ({ field }) => {
3827
- var _a2, _b2, _c2;
3828
- return /* @__PURE__ */ import_react15.default.createElement(
3829
- Input,
3830
- {
3831
- dir: "ltr",
3832
- inputProps: {
3833
- className: props.direction === "rtl" ? "hawa-text-right" : "hawa-text-left"
3834
- },
3835
- width: "full",
3836
- autoComplete: "email",
3837
- label: ((_a2 = texts == null ? void 0 : texts.email) == null ? void 0 : _a2.label) || "Email",
3838
- helperText: (_b2 = formState.errors.email) == null ? void 0 : _b2.message,
3839
- placeholder: ((_c2 = texts == null ? void 0 : texts.email) == null ? void 0 : _c2.placeholder) || "Enter your email",
3840
- ...field
3841
- }
3842
- );
3843
- }
3844
- }
3845
- );
3846
- }
3847
- if (fld === "username") {
3848
- return /* @__PURE__ */ import_react15.default.createElement(
3849
- import_react_hook_form2.Controller,
3850
- {
3851
- key: i,
3852
- control,
3853
- name: "username",
3854
- render: ({ field }) => {
3855
- var _a2, _b2, _c2, _d2;
3856
- return /* @__PURE__ */ import_react15.default.createElement(
3857
- Input,
3858
- {
3859
- width: "full",
3860
- autoComplete: "username",
3861
- label: ((_a2 = texts == null ? void 0 : texts.username) == null ? void 0 : _a2.label) || "Username",
3862
- labelProps: {
3863
- ...(_b2 = props.usernameOptions) == null ? void 0 : _b2.label
3864
- },
3865
- helperText: (_c2 = formState.errors.username) == null ? void 0 : _c2.message,
3866
- placeholder: (_d2 = texts == null ? void 0 : texts.username) == null ? void 0 : _d2.placeholder,
3867
- ...field
3868
- }
3869
- );
3870
- }
3871
- }
3872
- );
3873
- }
3874
- })),
3875
- /* @__PURE__ */ import_react15.default.createElement(
3876
- import_react_hook_form2.Controller,
3781
+ /* @__PURE__ */ import_react15.default.createElement(Card, { dir: props.direction, className: cn((_h = props.classNames) == null ? void 0 : _h.card) }, /* @__PURE__ */ import_react15.default.createElement(CardContent, { headless: true }, /* @__PURE__ */ import_react15.default.createElement("div", null, props.showError && /* @__PURE__ */ import_react15.default.createElement(
3782
+ Alert,
3877
3783
  {
3878
- control,
3879
- name: "password",
3880
- render: ({ field }) => {
3881
- var _a2, _b2, _c2;
3882
- return /* @__PURE__ */ import_react15.default.createElement(
3883
- Input,
3884
- {
3885
- width: "full",
3886
- type: passwordVisible ? "text" : "password",
3887
- endIcon: /* @__PURE__ */ import_react15.default.createElement(
3888
- "div",
3889
- {
3890
- className: "hawa-cursor-pointer",
3891
- onClick: () => setPasswordVisible(!passwordVisible)
3892
- },
3893
- passwordVisible ? /* @__PURE__ */ import_react15.default.createElement(EyeIcon, { className: "hawa-text-gray-500" }) : /* @__PURE__ */ import_react15.default.createElement(HiddenEyeIcon, { className: "hawa-text-gray-500" }),
3894
- " "
3895
- ),
3896
- autoComplete: "new-password",
3897
- label: ((_a2 = texts == null ? void 0 : texts.password) == null ? void 0 : _a2.label) || "Password",
3898
- placeholder: (_b2 = texts == null ? void 0 : texts.password) == null ? void 0 : _b2.placeholder,
3899
- helperText: (_c2 = formState.errors.password) == null ? void 0 : _c2.message,
3900
- ...field
3901
- }
3902
- );
3903
- }
3784
+ title: props.errorTitle,
3785
+ text: props.errorText,
3786
+ severity: "error"
3904
3787
  }
3905
- ),
3906
- /* @__PURE__ */ import_react15.default.createElement(
3907
- import_react_hook_form2.Controller,
3788
+ ), /* @__PURE__ */ import_react15.default.createElement(import_react_hook_form2.FormProvider, { ...methods }, /* @__PURE__ */ import_react15.default.createElement(
3789
+ "form",
3908
3790
  {
3909
- control,
3910
- name: "confirm_password",
3911
- render: ({ field }) => {
3912
- var _a2, _b2, _c2;
3791
+ noValidate: true,
3792
+ onSubmit: handleSubmit((e) => {
3793
+ if (props.onRegister) {
3794
+ return props.onRegister(e);
3795
+ } else {
3796
+ console.log(
3797
+ "Form is submitted but onRegister prop is missing"
3798
+ );
3799
+ }
3800
+ }),
3801
+ className: "hawa-flex hawa-flex-col hawa-gap-4"
3802
+ },
3803
+ /* @__PURE__ */ import_react15.default.createElement("div", { className: "hawa-flex hawa-flex-col hawa-gap-4" }, registerFields.map((fld, i) => {
3804
+ if (fld === "fullname") {
3913
3805
  return /* @__PURE__ */ import_react15.default.createElement(
3914
- Input,
3806
+ import_react_hook_form2.Controller,
3915
3807
  {
3916
- width: "full",
3917
- type: "password",
3918
- autoComplete: "new-password",
3919
- label: ((_a2 = texts == null ? void 0 : texts.confirm) == null ? void 0 : _a2.label) || "Confirm Password",
3920
- placeholder: ((_b2 = texts == null ? void 0 : texts.confirm) == null ? void 0 : _b2.placeholder) || "Confirm your Password",
3921
- helperText: (_c2 = formState.errors.confirm_password) == null ? void 0 : _c2.message,
3922
- ...field
3808
+ key: i,
3809
+ control,
3810
+ name: "fullName",
3811
+ render: ({ field }) => {
3812
+ var _a2, _b2, _c2;
3813
+ return /* @__PURE__ */ import_react15.default.createElement(
3814
+ Input,
3815
+ {
3816
+ width: "full",
3817
+ label: ((_a2 = texts == null ? void 0 : texts.fullName) == null ? void 0 : _a2.label) || "Full Name",
3818
+ placeholder: (_b2 = texts == null ? void 0 : texts.fullName) == null ? void 0 : _b2.placeholder,
3819
+ helperText: (_c2 = formState.errors.fullName) == null ? void 0 : _c2.message,
3820
+ ...field
3821
+ }
3822
+ );
3823
+ }
3923
3824
  }
3924
3825
  );
3925
3826
  }
3926
- }
3927
- ),
3928
- props.additionalInputs,
3929
- props.showRefCode && /* @__PURE__ */ import_react15.default.createElement(
3930
- import_react_hook_form2.Controller,
3931
- {
3932
- control,
3933
- name: "refCode",
3934
- render: ({ field }) => {
3935
- var _a2;
3827
+ if (fld === "email") {
3936
3828
  return /* @__PURE__ */ import_react15.default.createElement(
3937
- Input,
3829
+ import_react_hook_form2.Controller,
3938
3830
  {
3939
- width: "full",
3940
- label: texts == null ? void 0 : texts.refCode,
3941
- placeholder: (texts == null ? void 0 : texts.refCodePlaceholder) || "Enter the referral code",
3942
- helperText: (_a2 = formState.errors.refCode) == null ? void 0 : _a2.message,
3943
- ...field
3831
+ key: i,
3832
+ control,
3833
+ name: "email",
3834
+ render: ({ field }) => {
3835
+ var _a2, _b2, _c2;
3836
+ return /* @__PURE__ */ import_react15.default.createElement(
3837
+ Input,
3838
+ {
3839
+ dir: "ltr",
3840
+ inputProps: {
3841
+ className: props.direction === "rtl" ? "hawa-text-right" : "hawa-text-left"
3842
+ },
3843
+ width: "full",
3844
+ autoComplete: "email",
3845
+ label: ((_a2 = texts == null ? void 0 : texts.email) == null ? void 0 : _a2.label) || "Email",
3846
+ helperText: (_b2 = formState.errors.email) == null ? void 0 : _b2.message,
3847
+ placeholder: ((_c2 = texts == null ? void 0 : texts.email) == null ? void 0 : _c2.placeholder) || "Enter your email",
3848
+ ...field
3849
+ }
3850
+ );
3851
+ }
3944
3852
  }
3945
3853
  );
3946
3854
  }
3947
- }
3948
- ),
3949
- props.showUserSource && /* @__PURE__ */ import_react15.default.createElement(
3950
- import_react_hook_form2.Controller,
3951
- {
3952
- control,
3953
- name: "reference",
3954
- render: ({ field }) => {
3955
- var _a2, _b2;
3855
+ if (fld === "username") {
3956
3856
  return /* @__PURE__ */ import_react15.default.createElement(
3957
- Select,
3857
+ import_react_hook_form2.Controller,
3958
3858
  {
3959
- label: ((_a2 = texts == null ? void 0 : texts.userReference) == null ? void 0 : _a2.label) || "How did you learn about us?",
3960
- placeholder: (_b2 = texts == null ? void 0 : texts.userReference) == null ? void 0 : _b2.placeholder,
3961
- isCreatable: false,
3962
- isMulti: false,
3963
- isSearchable: false,
3964
- isClearable: false,
3965
- options: props.userReferenceOptions,
3966
- onChange: (e) => {
3967
- field.onChange(e.value);
3859
+ key: i,
3860
+ control,
3861
+ name: "username",
3862
+ render: ({ field }) => {
3863
+ var _a2, _b2, _c2, _d2;
3864
+ return /* @__PURE__ */ import_react15.default.createElement(
3865
+ Input,
3866
+ {
3867
+ width: "full",
3868
+ autoComplete: "username",
3869
+ label: ((_a2 = texts == null ? void 0 : texts.username) == null ? void 0 : _a2.label) || "Username",
3870
+ labelProps: {
3871
+ ...(_b2 = props.usernameOptions) == null ? void 0 : _b2.label
3872
+ },
3873
+ helperText: (_c2 = formState.errors.username) == null ? void 0 : _c2.message,
3874
+ placeholder: (_d2 = texts == null ? void 0 : texts.username) == null ? void 0 : _d2.placeholder,
3875
+ ...field
3876
+ }
3877
+ );
3968
3878
  }
3969
3879
  }
3970
3880
  );
3971
3881
  }
3972
- }
3973
- ),
3974
- showTermsOption || showNewsletterOption ? /* @__PURE__ */ import_react15.default.createElement("div", { className: "hawa-flex hawa-flex-col hawa-gap-3 hawa-mb-2" }, showTermsOption && /* @__PURE__ */ import_react15.default.createElement(
3975
- import_react_hook_form2.Controller,
3976
- {
3977
- control,
3978
- name: "terms_accepted",
3979
- render: ({ field }) => {
3980
- var _a2, _b2;
3981
- return /* @__PURE__ */ import_react15.default.createElement(
3882
+ })),
3883
+ /* @__PURE__ */ import_react15.default.createElement(
3884
+ import_react_hook_form2.Controller,
3885
+ {
3886
+ control,
3887
+ name: "password",
3888
+ render: ({ field }) => {
3889
+ var _a2, _b2, _c2;
3890
+ return /* @__PURE__ */ import_react15.default.createElement(
3891
+ Input,
3892
+ {
3893
+ width: "full",
3894
+ type: passwordVisible ? "text" : "password",
3895
+ endIcon: /* @__PURE__ */ import_react15.default.createElement(
3896
+ "div",
3897
+ {
3898
+ className: "hawa-cursor-pointer",
3899
+ onClick: () => setPasswordVisible(!passwordVisible)
3900
+ },
3901
+ passwordVisible ? /* @__PURE__ */ import_react15.default.createElement(EyeIcon, { className: "hawa-text-gray-500" }) : /* @__PURE__ */ import_react15.default.createElement(HiddenEyeIcon, { className: "hawa-text-gray-500" }),
3902
+ " "
3903
+ ),
3904
+ autoComplete: "new-password",
3905
+ label: ((_a2 = texts == null ? void 0 : texts.password) == null ? void 0 : _a2.label) || "Password",
3906
+ placeholder: (_b2 = texts == null ? void 0 : texts.password) == null ? void 0 : _b2.placeholder,
3907
+ helperText: (_c2 = formState.errors.password) == null ? void 0 : _c2.message,
3908
+ ...field
3909
+ }
3910
+ );
3911
+ }
3912
+ }
3913
+ ),
3914
+ /* @__PURE__ */ import_react15.default.createElement(
3915
+ import_react_hook_form2.Controller,
3916
+ {
3917
+ control,
3918
+ name: "confirm_password",
3919
+ render: ({ field }) => {
3920
+ var _a2, _b2, _c2;
3921
+ return /* @__PURE__ */ import_react15.default.createElement(
3922
+ Input,
3923
+ {
3924
+ width: "full",
3925
+ type: "password",
3926
+ autoComplete: "new-password",
3927
+ label: ((_a2 = texts == null ? void 0 : texts.confirm) == null ? void 0 : _a2.label) || "Confirm Password",
3928
+ placeholder: ((_b2 = texts == null ? void 0 : texts.confirm) == null ? void 0 : _b2.placeholder) || "Confirm your Password",
3929
+ helperText: (_c2 = formState.errors.confirm_password) == null ? void 0 : _c2.message,
3930
+ ...field
3931
+ }
3932
+ );
3933
+ }
3934
+ }
3935
+ ),
3936
+ props.additionalInputs,
3937
+ props.showRefCode && /* @__PURE__ */ import_react15.default.createElement(
3938
+ import_react_hook_form2.Controller,
3939
+ {
3940
+ control,
3941
+ name: "refCode",
3942
+ render: ({ field }) => {
3943
+ var _a2;
3944
+ return /* @__PURE__ */ import_react15.default.createElement(
3945
+ Input,
3946
+ {
3947
+ width: "full",
3948
+ label: texts == null ? void 0 : texts.refCode,
3949
+ placeholder: (texts == null ? void 0 : texts.refCodePlaceholder) || "Enter the referral code",
3950
+ helperText: (_a2 = formState.errors.refCode) == null ? void 0 : _a2.message,
3951
+ ...field
3952
+ }
3953
+ );
3954
+ }
3955
+ }
3956
+ ),
3957
+ props.showUserSource && /* @__PURE__ */ import_react15.default.createElement(
3958
+ import_react_hook_form2.Controller,
3959
+ {
3960
+ control,
3961
+ name: "reference",
3962
+ render: ({ field }) => {
3963
+ var _a2, _b2;
3964
+ return /* @__PURE__ */ import_react15.default.createElement(
3965
+ Select,
3966
+ {
3967
+ label: ((_a2 = texts == null ? void 0 : texts.userReference) == null ? void 0 : _a2.label) || "How did you learn about us?",
3968
+ placeholder: (_b2 = texts == null ? void 0 : texts.userReference) == null ? void 0 : _b2.placeholder,
3969
+ isCreatable: false,
3970
+ isMulti: false,
3971
+ isSearchable: false,
3972
+ isClearable: false,
3973
+ options: props.userReferenceOptions,
3974
+ onChange: (e) => {
3975
+ field.onChange(e.value);
3976
+ }
3977
+ }
3978
+ );
3979
+ }
3980
+ }
3981
+ ),
3982
+ showTermsOption || showNewsletterOption ? /* @__PURE__ */ import_react15.default.createElement("div", { className: "hawa-flex hawa-flex-col hawa-gap-3 hawa-mb-2" }, showTermsOption && /* @__PURE__ */ import_react15.default.createElement(
3983
+ import_react_hook_form2.Controller,
3984
+ {
3985
+ control,
3986
+ name: "terms_accepted",
3987
+ render: ({ field }) => {
3988
+ var _a2, _b2;
3989
+ return /* @__PURE__ */ import_react15.default.createElement(
3990
+ Checkbox,
3991
+ {
3992
+ id: "terms_accepted",
3993
+ helperText: (_b2 = (_a2 = formState.errors.terms_accepted) == null ? void 0 : _a2.message) == null ? void 0 : _b2.toString(),
3994
+ onCheckedChange: (e) => field.onChange(e),
3995
+ label: /* @__PURE__ */ import_react15.default.createElement("div", { className: "hawa-flex hawa-flex-row hawa-gap-0.5" }, /* @__PURE__ */ import_react15.default.createElement("span", null, (texts == null ? void 0 : texts.iAcceptText) || "I accept the "), " ", /* @__PURE__ */ import_react15.default.createElement(StopPropagationWrapper, null, /* @__PURE__ */ import_react15.default.createElement(
3996
+ "a",
3997
+ {
3998
+ onClick: props.onRouteToTOS,
3999
+ className: "clickable-link"
4000
+ },
4001
+ (texts == null ? void 0 : texts.termsText) || "Terms of Service"
4002
+ )))
4003
+ }
4004
+ );
4005
+ }
4006
+ }
4007
+ ), showNewsletterOption && /* @__PURE__ */ import_react15.default.createElement(
4008
+ import_react_hook_form2.Controller,
4009
+ {
4010
+ control,
4011
+ name: "newsletter_accepted",
4012
+ render: ({ field }) => /* @__PURE__ */ import_react15.default.createElement(
3982
4013
  Checkbox,
3983
4014
  {
3984
- id: "terms_accepted",
3985
- helperText: (_b2 = (_a2 = formState.errors.terms_accepted) == null ? void 0 : _a2.message) == null ? void 0 : _b2.toString(),
3986
- onCheckedChange: (e) => field.onChange(e),
3987
- label: /* @__PURE__ */ import_react15.default.createElement("div", { className: "hawa-flex hawa-flex-row hawa-gap-0.5" }, /* @__PURE__ */ import_react15.default.createElement("span", null, (texts == null ? void 0 : texts.iAcceptText) || "I accept the "), " ", /* @__PURE__ */ import_react15.default.createElement(StopPropagationWrapper, null, /* @__PURE__ */ import_react15.default.createElement(
3988
- "a",
3989
- {
3990
- onClick: props.onRouteToTOS,
3991
- className: "clickable-link"
3992
- },
3993
- (texts == null ? void 0 : texts.termsText) || "Terms of Service"
3994
- )))
4015
+ id: "newsletter_accepted",
4016
+ label: (texts == null ? void 0 : texts.subscribeToNewsletter) || "Subscribe to our newsletter",
4017
+ onCheckedChange: field.onChange
3995
4018
  }
3996
- );
4019
+ )
3997
4020
  }
3998
- }
3999
- ), showNewsletterOption && /* @__PURE__ */ import_react15.default.createElement(
4000
- import_react_hook_form2.Controller,
4021
+ )) : null,
4022
+ /* @__PURE__ */ import_react15.default.createElement(
4023
+ Button,
4024
+ {
4025
+ className: " hawa-w-full",
4026
+ type: "submit",
4027
+ isLoading: props.isLoading,
4028
+ disabled: props.isLoading
4029
+ },
4030
+ (texts == null ? void 0 : texts.registerText) || "Register"
4031
+ ),
4032
+ props.additionalButtons
4033
+ )), /* @__PURE__ */ import_react15.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_react15.default.createElement("span", null, (texts == null ? void 0 : texts.existingUserText) || "Already have an account?"), /* @__PURE__ */ import_react15.default.createElement("span", { onClick: props.onRouteToLogin, className: "clickable-link" }, (texts == null ? void 0 : texts.loginText) || "Login")))), props.viaGithub || props.viaGoogle || props.viaTwitter ? /* @__PURE__ */ import_react15.default.createElement(
4034
+ CardFooter,
4001
4035
  {
4002
- control,
4003
- name: "newsletter_accepted",
4004
- render: ({ field }) => /* @__PURE__ */ import_react15.default.createElement(
4005
- Checkbox,
4006
- {
4007
- id: "newsletter_accepted",
4008
- label: (texts == null ? void 0 : texts.subscribeToNewsletter) || "Subscribe to our newsletter",
4009
- onCheckedChange: field.onChange
4010
- }
4036
+ className: cn(
4037
+ props.logosOnly ? "hawa-flex hawa-flex-row hawa-justify-center hawa-gap-2" : "hawa-grid hawa-grid-cols-1 hawa-gap-2"
4011
4038
  )
4012
- }
4013
- )) : null,
4014
- /* @__PURE__ */ import_react15.default.createElement(
4015
- Button,
4016
- {
4017
- className: " hawa-w-full",
4018
- type: "submit",
4019
- isLoading: props.isLoading,
4020
- disabled: props.isLoading
4021
4039
  },
4022
- (texts == null ? void 0 : texts.registerText) || "Register"
4023
- ),
4024
- props.additionalButtons
4025
- )), /* @__PURE__ */ import_react15.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_react15.default.createElement("span", null, (texts == null ? void 0 : texts.existingUserText) || "Already have an account?"), /* @__PURE__ */ import_react15.default.createElement("span", { onClick: props.onRouteToLogin, className: "clickable-link" }, (texts == null ? void 0 : texts.loginText) || "Login")))), props.viaGithub || props.viaGoogle || props.viaTwitter ? /* @__PURE__ */ import_react15.default.createElement(
4026
- CardFooter,
4027
- {
4028
- className: cn(
4029
- props.logosOnly ? "hawa-flex hawa-flex-row hawa-justify-center hawa-gap-2" : "hawa-grid hawa-grid-cols-1 hawa-gap-2"
4040
+ /* @__PURE__ */ import_react15.default.createElement(
4041
+ AuthButtons,
4042
+ {
4043
+ texts: thirdPartyAuthTexts,
4044
+ viaGoogle: props.viaGoogle,
4045
+ viaGithub: props.viaGithub,
4046
+ viaTwitter: props.viaTwitter,
4047
+ isGoogleLoading: props.isGoogleLoading,
4048
+ isGithubLoading: props.isGithubLoading,
4049
+ isTwitterLoading: props.isTwitterLoading,
4050
+ handleGoogle: props.onGoogleRegister,
4051
+ handleGithub: props.onGithubRegister,
4052
+ handleTwitter: props.onTwitterRegister
4053
+ }
4030
4054
  )
4031
- },
4032
- /* @__PURE__ */ import_react15.default.createElement(
4033
- AuthButtons,
4034
- {
4035
- texts: thirdPartyAuthTexts,
4036
- viaGoogle: props.viaGoogle,
4037
- viaGithub: props.viaGithub,
4038
- viaTwitter: props.viaTwitter,
4039
- isGoogleLoading: props.isGoogleLoading,
4040
- isGithubLoading: props.isGithubLoading,
4041
- isTwitterLoading: props.isTwitterLoading,
4042
- handleGoogle: props.onGoogleRegister,
4043
- handleGithub: props.onGithubRegister,
4044
- handleTwitter: props.onTwitterRegister
4045
- }
4046
- )
4047
- ) : null));
4055
+ ) : null)
4056
+ );
4048
4057
  };
4049
4058
 
4050
4059
  // blocks/auth/AppLanding.tsx
@@ -5585,7 +5594,7 @@ var ContactForm = ({
5585
5594
  size = "default",
5586
5595
  texts,
5587
5596
  formId,
5588
- formAutoComplete,
5597
+ formAutoComplete = "off",
5589
5598
  onSubmit,
5590
5599
  customFields
5591
5600
  }) => {
@@ -5612,9 +5621,11 @@ var ContactForm = ({
5612
5621
  )
5613
5622
  });
5614
5623
  const contactFormSchema = z8.object({
5615
- name: z8.string({ required_error: texts == null ? void 0 : texts.name.required }).min(1, texts == null ? void 0 : texts.name.required).default(""),
5616
- email: z8.string({ required_error: (_a = texts == null ? void 0 : texts.email) == null ? void 0 : _a.required }).min(1, { message: (_b = texts == null ? void 0 : texts.email) == null ? void 0 : _b.required }).email({ message: (_c = texts == null ? void 0 : texts.email) == null ? void 0 : _c.invalid }).default(""),
5617
- message: z8.string({ required_error: texts == null ? void 0 : texts.message.required }).min(10, texts == null ? void 0 : texts.message.invalid).default("")
5624
+ name: z8.string({ required_error: (texts == null ? void 0 : texts.name.required) || "Name is required" }).min(1, (texts == null ? void 0 : texts.name.required) || "Name is required").default(""),
5625
+ email: z8.string({ required_error: ((_a = texts == null ? void 0 : texts.email) == null ? void 0 : _a.required) || "Email is required" }).min(1, { message: ((_b = texts == null ? void 0 : texts.email) == null ? void 0 : _b.required) || "Email is required" }).email({ message: ((_c = texts == null ? void 0 : texts.email) == null ? void 0 : _c.invalid) || "Invalid email" }).default(""),
5626
+ message: z8.string({
5627
+ required_error: (texts == null ? void 0 : texts.message.required) || "Message is required"
5628
+ }).min(10, (texts == null ? void 0 : texts.message.invalid) || "Message is too short").default("")
5618
5629
  });
5619
5630
  const customFieldsDefaultValues = customFields == null ? void 0 : customFields.reduce(
5620
5631
  (acc, curr) => {
@@ -5685,7 +5696,7 @@ var ContactForm = ({
5685
5696
  return /* @__PURE__ */ import_react35.default.createElement(
5686
5697
  Input,
5687
5698
  {
5688
- label: texts == null ? void 0 : texts.name.label,
5699
+ label: (texts == null ? void 0 : texts.name.label) || "Name",
5689
5700
  id: texts == null ? void 0 : texts.name.label,
5690
5701
  ...field,
5691
5702
  placeholder: texts == null ? void 0 : texts.name.placeholder,
@@ -5705,7 +5716,7 @@ var ContactForm = ({
5705
5716
  return /* @__PURE__ */ import_react35.default.createElement(
5706
5717
  Input,
5707
5718
  {
5708
- label: texts == null ? void 0 : texts.email.label,
5719
+ label: (texts == null ? void 0 : texts.email.label) || "Email",
5709
5720
  id: texts == null ? void 0 : texts.email.label,
5710
5721
  ...field,
5711
5722
  placeholder: texts == null ? void 0 : texts.email.placeholder,
@@ -5765,7 +5776,7 @@ var ContactForm = ({
5765
5776
  return /* @__PURE__ */ import_react35.default.createElement(
5766
5777
  Textarea,
5767
5778
  {
5768
- label: texts == null ? void 0 : texts.message.label,
5779
+ label: (texts == null ? void 0 : texts.message.label) || "Message",
5769
5780
  id: texts == null ? void 0 : texts.message.label,
5770
5781
  textareaProps: {
5771
5782
  placeholder: texts == null ? void 0 : texts.message.placeholder,