Final auth design

This commit is contained in:
Daniel Cojocea committed 2024-08-12 16:26:42 -04:00
1 parent e2522d2297
commit 16c19930c4
1 file changed
+26 -30
+26 -30
View File
@@ -11,7 +11,6 @@ import Check from "../../Components/Check/Check";
import ButtonSpinner from "../../Components/ButtonSpinner";
import Field from "../../Components/Inputs/Field";
import LockIcon from "../../assets/icons/lock-button-icon.svg?react";
import Button from "../../Components/Button";
import background from "../../assets/Images/background_pattern_decorative.png";
import Logo from "../../assets/icons/bwu-icon.svg?react";
import "./index.css";
@@ -140,29 +139,17 @@ const SetNewPassword = () => {
},
},
}}
></Stack>
<Box textAlign="center" p={theme.gap.large}>
<Typography display="inline-block">Go back to —</Typography>
<Typography
component="span"
ml={theme.gap.xs}
onClick={() => navigate("/login")}
sx={{ userSelect: "none" }}
>
Log In
</Typography>
</Box>
{/* <form className="set-new-password-form" onSubmit={handleSubmit}>
<Stack direction="column" alignItems="center" gap={theme.gap.small}>
<LockIcon alt="lock icon" style={{ fill: "white" }} />
<Typography component="h1" sx={{ mt: theme.gap.ml }}>
Set new password
</Typography>
<Typography sx={{ textAlign: "center" }}>
<Stack gap={theme.gap.large} textAlign="center">
<Box>
<LockIcon alt="lock icon" />
<Typography component="h1">Set new password</Typography>
<Typography>
Your new password must be different to previously used passwords.
</Typography>
</Stack>
<Stack gap={theme.gap.large} sx={{ mt: `calc(${theme.gap.ml}*2)` }}>
</Box>
<Box width="100%" textAlign="left">
<form noValidate spellCheck={false} onSubmit={handleSubmit}>
<Field
type="password"
id="register-password-input"
@@ -173,6 +160,8 @@ const SetNewPassword = () => {
onChange={handleChange}
error={errors.password}
/>
</form>
<form noValidate spellCheck={false} onSubmit={handleSubmit}>
<Field
type="password"
id="confirm-password-input"
@@ -183,7 +172,8 @@ const SetNewPassword = () => {
onChange={handleChange}
error={errors.confirm}
/>
<Stack gap={theme.gap.small}>
</form>
<Stack gap={theme.gap.small} mb={theme.gap.large}>
<Check
text="Must be at least 8 characters long"
variant={
@@ -223,22 +213,28 @@ const SetNewPassword = () => {
}
/>
</Stack>
</Box>
<ButtonSpinner
disabled={Object.keys(errors).length !== 0}
isLoading={isLoading}
onClick={handleSubmit}
level="primary"
label="Reset password"
/>
<Button
level="tertiary"
label="Back to log in"
img={<ArrowBackRoundedIcon />}
sx={{ alignSelf: "center", width: "fit-content" }}
onClick={() => navigate("/login")}
sx={{ width: "100%" }}
/>
</Stack>
</form> */}
</Stack>
<Box textAlign="center" p={theme.gap.large}>
<Typography display="inline-block">Go back to —</Typography>
<Typography
component="span"
ml={theme.gap.xs}
onClick={() => navigate("/login")}
sx={{ userSelect: "none" }}
>
Log In
</Typography>
</Box>
</Stack>
);
};