diff --git a/txclient/src/app/components/Home/Login/Login.tsx b/txclient/src/app/components/Home/Login/Login.tsx
index 9858ad5..12110ab 100644
--- a/txclient/src/app/components/Home/Login/Login.tsx
+++ b/txclient/src/app/components/Home/Login/Login.tsx
@@ -44,6 +44,7 @@ export default function Login(props: LoginProps) {
const [password, setPassword] = useState("");
const [verificationCode, setVerificationCode] = useState("");
const [checkReadTerms, setCheckReadTerms] = useState(false);
+ const [loginMethod, setLoginMethod] = useState<"google" | "password">("google");
const clientId = process.env.NEXT_PUBLIC_GOOGLE_CLIENT_ID || "";
@@ -323,102 +324,132 @@ export default function Login(props: LoginProps) {
>
)}
{!verification && !recovery && !recoveryCode && (
-
Ingresar
- )}
- {
- setEmail(e.target.value);
- }}
- onKeyUp={(e) => {
- if (!verification && !recovery && !recoveryCode) {
- if (e.key === "Enter") {
- document.getElementById("password")?.focus();
- }
- }
- }}
- />
- {!recovery && (
- {
- setPassword(e.target.value);
- }}
- onKeyUp={(e) => {
- if (!verification && !recovery && !recoveryCode) {
- if (e.key === "Enter") {
- iniciarSesion();
- }
- }
- }}
- />
+ <>
+ Ingresar
+
+
+ Elegí cómo querés acceder
+
+
+
+
+ >
)}
- {(verification || recoveryCode) && (
- {
- setVerificationCode(e.target.value);
- }}
- />
- )}
-
- {verification && (
-
- )}
-
- {recovery && (
-
- )}
-
- {recoveryCode && (
-
- )}
-
- {!verification && !recovery && !recoveryCode && (
-
- )}
-
- {!verification && !recovery && !recoveryCode && (
+ {!verification && !recovery && !recoveryCode && loginMethod === "google" && (
)}
+
+ {(!verification && !recovery && !recoveryCode
+ ? loginMethod === "password"
+ : true) && (
+ <>
+ {
+ setEmail(e.target.value);
+ }}
+ onKeyUp={(e) => {
+ if (!verification && !recovery && !recoveryCode) {
+ if (e.key === "Enter") {
+ document.getElementById("password")?.focus();
+ }
+ }
+ }}
+ />
+ {!recovery && (
+ {
+ setPassword(e.target.value);
+ }}
+ onKeyUp={(e) => {
+ if (!verification && !recovery && !recoveryCode) {
+ if (e.key === "Enter") {
+ iniciarSesion();
+ }
+ }
+ }}
+ />
+ )}
+
+ {(verification || recoveryCode) && (
+ {
+ setVerificationCode(e.target.value);
+ }}
+ />
+ )}
+
+ {verification && (
+
+ )}
+
+ {recovery && (
+
+ )}
+
+ {recoveryCode && (
+
+ )}
+
+ {!verification && !recovery && !recoveryCode && (
+
+ )}
+ >
+ )}
{!recoveryCode && (
No tienes una cuenta?
diff --git a/txclient/src/app/landing/signup/page.tsx b/txclient/src/app/landing/signup/page.tsx
index 2cd33ec..9a5c892 100644
--- a/txclient/src/app/landing/signup/page.tsx
+++ b/txclient/src/app/landing/signup/page.tsx
@@ -30,6 +30,7 @@ export default function RegisterPage() {
const [areaCode, setAreaCode] = useState("");
const [phone, setPhone] = useState("");
const [checkReadTerms, setCheckReadTerms] = useState(false);
+ const [registerMethod, setRegisterMethod] = useState<"google" | "manual">("google");
const registerUser = () => {
const validationPhoneResult = validatePhone(areaCode, phone);
@@ -100,91 +101,216 @@ export default function RegisterPage() {
Registrate Gratis
- {
- setEmail(e.target.value);
- }}
- />
- {
- setPassword(e.target.value);
- }}
- />
- {
- setFirstName(e.target.value);
- }}
- />
- {
- setLastName(e.target.value);
- }}
- />
-
- ) => {
- setAreaCode(e.target.value);
- }}
- onChangePhone={(
- e: React.ChangeEvent
- ) => {
- setPhone(e.target.value);
- }}
- />
-
- setCheckReadTerms(!checkReadTerms)
- }
- />
-
- Declaro que acepto los siguientes
-
- Términos y condiciones
- {" "}
- y{" "}
-
- Políticas de privacidad
-
-
+
+ Elegí cómo querés crear tu cuenta
+
+
+
-
+
+ {registerMethod === "google" && (
+