Skip to content

Commit

Permalink
refactor: Remove unused code and console logs in useApiClient hook
Browse files Browse the repository at this point in the history
  • Loading branch information
epixieme committed Sep 24, 2024
1 parent e7b29d0 commit 8d74cd5
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions src/pages/UserBPages/UserBSignUpPage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ function UserBSignUpPage() {
const { sessionId, quizId } = useAppSelector((state) => state.auth.userB);
const { signUp } = useSignUp();
const [isLoading, setIsLoading] = useState(false);

const devMode = localStorage.getItem('devMode') === 'true';
async function signUpHandler(firstName: string, lastName: string, email: string, password: string) {
setIsLoading(true);
const success = await signUp(firstName, lastName, email, password, quizId);
Expand All @@ -47,13 +47,15 @@ function UserBSignUpPage() {
<CmTypography variant="h1">Welcome to Climate Mind</CmTypography>

<div style={{ display: 'flex' }}>
<CmTypography variant="body" style={{ textAlign: 'center' }}>Already have an account?</CmTypography>
<CmTypography variant="body" style={{ textAlign: 'center' }}>
Already have an account?
</CmTypography>
<CmButton variant="text" text="Login" onClick={() => navigate(ROUTES.LOGIN_PAGE)} style={styles.loginButton} />
</div>
<div style={{ display: 'flex', flexDirection: 'column', gap: 19, justifyContent: 'center', alignItems: 'center' }}>
<SignUpForm isLoading={isLoading} onSignUp={signUpHandler} />
<div style={{ borderBottom: '1px solid #0000001A', height: 1, width: 205 }}></div>
<GoogleLogin navigateAfterLogin={navigateAfterLogin} text="Continue With Google" />
{devMode && <GoogleLogin navigateAfterLogin={navigateAfterLogin} text="Continue With Google" />}
</div>
</PageContent>
</Page>
Expand Down

0 comments on commit 8d74cd5

Please sign in to comment.