Clean code
This commit is contained in:
		| @@ -1,6 +1,3 @@ | ||||
| import React, { useRef } from "react"; | ||||
| import { AsyncWidget } from "../widgets/AsyncWidget"; | ||||
| import { ReplacePasswordResponse, User, UserApi } from "../api/UserApi"; | ||||
| import { | ||||
|   Alert, | ||||
|   Box, | ||||
| @@ -9,15 +6,16 @@ import { | ||||
|   CardActions, | ||||
|   CardContent, | ||||
|   Checkbox, | ||||
|   CircularProgress, | ||||
|   FormControlLabel, | ||||
|   TextField, | ||||
|   Typography, | ||||
| } from "@mui/material"; | ||||
| import { TimeWidget, formatDate } from "../widgets/TimeWidget"; | ||||
| import React, { useRef } from "react"; | ||||
| import { ServerApi } from "../api/ServerApi"; | ||||
| import { ReplacePasswordResponse, User, UserApi } from "../api/UserApi"; | ||||
| import { AsyncWidget } from "../widgets/AsyncWidget"; | ||||
| import { PasswordInput } from "../widgets/PasswordInput"; | ||||
| import { normalize } from "path/win32"; | ||||
| import { formatDate } from "../widgets/TimeWidget"; | ||||
|  | ||||
| export function ProfileRoute(): React.ReactElement { | ||||
|   const [user, setUser] = React.useState<null | User>(null); | ||||
|   | ||||
| @@ -3,15 +3,13 @@ import { | ||||
|   Box, | ||||
|   Button, | ||||
|   CircularProgress, | ||||
|   Grid, | ||||
|   TextField, | ||||
|   Typography, | ||||
| } from "@mui/material"; | ||||
| import React from "react"; | ||||
| import { ServerApi } from "../../api/ServerApi"; | ||||
| import { Link } from "react-router-dom"; | ||||
| import { APIClient } from "../../api/ApiClient"; | ||||
| import { AuthApi } from "../../api/AuthApi"; | ||||
| import { ServerApi } from "../../api/ServerApi"; | ||||
|  | ||||
| export function PasswordForgottenRoute(): React.ReactElement { | ||||
|   const [loading, setLoading] = React.useState(false); | ||||
|   | ||||
| @@ -35,15 +35,6 @@ function Copyright(props: any) { | ||||
| } | ||||
|  | ||||
| export function BaseLoginPage() { | ||||
|   const handleSubmit = (event: React.FormEvent<HTMLFormElement>) => { | ||||
|     event.preventDefault(); | ||||
|     const data = new FormData(event.currentTarget); | ||||
|     console.log({ | ||||
|       email: data.get("email"), | ||||
|       password: data.get("password"), | ||||
|     }); | ||||
|   }; | ||||
|  | ||||
|   return ( | ||||
|     <Grid container component="main" sx={{ height: "100vh" }}> | ||||
|       <CssBaseline /> | ||||
|   | ||||
		Reference in New Issue
	
	Block a user