import {Button, Image, Input, Stack, Text} from "@chakra-ui/react"; import {snakeCase} from "change-case"; import React, {useState} from "react"; import {useNavigate} from "react-router-dom"; interface loginScreenProps { bg?: string, logo?: string, title?: string, redirectPath?: string, loginButtonColor?: string, } const LoginScreenComponent = (props: loginScreenProps) => { const navigate = useNavigate(); /** bg: string = image url * logo: string = image url * title: string = title of the login card * redirectPath: string (experimental) = to be passed to navigate() function * loginButtonColor: string = background color of the login button * @param {string} username: username of the user * @param {string} password: password of the user */ const { bg, logo, title, redirectPath = "/", loginButtonColor = "black" } = props; const [data, setData] = useState({ email: "", password: "" }) return ( {/* Login Form Card */} logo {title} Enter your email and password below setData({ ...data, email: e.target.value })} type="email" borderRadius={"none"} border="none" borderBottom={"1px solid #DFE0EB"} placeholder="Email" /> setData({ ...data, password: e.target.value })} type="password" borderRadius={"none"} border="none" borderBottom={"1px solid #DFE0EB"} placeholder="Password" /> {/* Forgot password link */} Forgot your password? ) } export default LoginScreenComponent;