Signup and login: link to eachother.

master
Tom Hacohen 4 years ago
parent 6970ebc503
commit 835367ba9f

@ -23,6 +23,7 @@ import { startTask } from "./helpers";
import { Switch, Route } from "react-router";
import { routeResolver } from "./App";
import SignupPage from "./SignupPage";
import { Link } from "react-router-dom";
export default function LoginGate() {
@ -78,7 +79,8 @@ export default function LoginGate() {
/>
<Route>
<Container style={{ maxWidth: "30rem" }}>
<h2>Please Log In</h2>
<h2 style={{ marginBottom: "0.1em" }}>Log In</h2>
<div style={{ fontSize: "90%" }}>or <Link to={routeResolver.getRoute("signup")}>create an account</Link></div>
<LoginForm
onSubmit={onFormSubmit}
loading={loading}

@ -23,6 +23,7 @@ import { useCredentials } from "./credentials";
import { useDispatch } from "react-redux";
import { startTask } from "./helpers";
import { login } from "./store/actions";
import { Link } from "react-router-dom";
interface FormErrors {
errorUsername?: string;
@ -147,7 +148,8 @@ export default function SignupPage() {
return (
<Container style={{ maxWidth: "30rem" }}>
<h2>Signup</h2>
<h2 style={{ marginBottom: "0.1em" }}>Signup</h2>
<div style={{ fontSize: "90%" }}>or <Link to={routeResolver.getRoute("home")}>log in to your account</Link></div>
<form style={styles.form} onSubmit={signup}>
<TextField
type="text"

Loading…
Cancel
Save