diff --git a/web/src/pages/Auth.tsx b/web/src/pages/Auth.tsx index 2899861e..aede8569 100644 --- a/web/src/pages/Auth.tsx +++ b/web/src/pages/Auth.tsx @@ -47,7 +47,9 @@ const Auth = () => { setPassword(text); }; - const handleSigninBtnsClick = async () => { + const handleSigninBtnsClick = async (e: React.FormEvent) => { + e.preventDefault(); + if (actionBtnLoadingState.isLoading) { return; } @@ -80,7 +82,9 @@ const Auth = () => { actionBtnLoadingState.setFinish(); }; - const handleSignUpAsHostBtnsClick = async () => { + const handleSignUpAsHostBtnsClick = async (e: React.FormEvent) => { + e.preventDefault(); + if (actionBtnLoadingState.isLoading) { return; } @@ -120,7 +124,7 @@ const Auth = () => { return (
-
+
(siteHost ? handleSigninBtnsClick(e) : handleSignUpAsHostBtnsClick(e))}>
@@ -130,19 +134,16 @@ const Auth = () => {
{t("common.email")} - +
{t("common.password")} - +
{!pageLoadingState.isLoading && ( - @@ -151,7 +152,7 @@ const Auth = () => {

{siteHost || pageLoadingState.isLoading ? t("auth.not-host-tip") : t("auth.host-tip")}

-
+
handleLocaleItemClick("en")}>