chore: Remove favicon and enhance global styles
- Delete unused favicon.ico file to clean up project assets - Add smooth scrolling behavior to html element for improved user experience - Refactor box-shadow property in Toastify styles for better readability - Update button states in Contact Us and Inquiries forms to include hcaptchaToken validation
This commit is contained in:
@@ -90,9 +90,13 @@ const InquiresForm = ({
|
||||
}
|
||||
setIsLoading(true);
|
||||
try {
|
||||
const response = (await api.post("inquiries", { ...data })).data;
|
||||
const response = (
|
||||
await api.post("inquiries", { ...data, hcaptcha_token: hcaptchaToken })
|
||||
).data;
|
||||
toast.success(response.message);
|
||||
reset();
|
||||
setHcaptchaToken(null);
|
||||
captchaRef.current?.resetCaptcha();
|
||||
} catch (error) {
|
||||
handleApiError(error, setError, toast.error, formFieldNames);
|
||||
} finally {
|
||||
@@ -219,7 +223,7 @@ const InquiresForm = ({
|
||||
<div className={`${colSpanClass} flex justify-end`}>
|
||||
<button
|
||||
type="submit"
|
||||
disabled={!isValid || isLoading}
|
||||
disabled={!isValid || isLoading || !hcaptchaToken}
|
||||
className="bg-(--primary) cursor-pointer w-fit text-white rounded-full py-4 px-6 disabled:opacity-60 disabled:cursor-not-allowed">
|
||||
{isLoading ? <Loading /> : submitText}
|
||||
</button>
|
||||
|
||||
Reference in New Issue
Block a user