mirror of
https://github.com/coder/coder.git
synced 2026-09-22 05:05:20 +08:00
This just implements a basic sign-in flow, using the new endpoints in #29 :  This brings over several dependencies that are necessary: - `formik` - `yep` Ports over some v1 code to bootstrap it: - `FormTextField` - `PasswordField` - `CoderIcon` And implements basic sign-in: Fixes #37 Fixes #43 This does not implement it navbar integration (importantly - there is no way to sign out yet, unless you manually delete your `session_token`). I'll do that in the next PR - figured this was big enough to get reviewed.
27 lines
546 B
TypeScript
27 lines
546 B
TypeScript
import CircularProgress from "@material-ui/core/CircularProgress"
|
|
import { makeStyles } from "@material-ui/core/styles"
|
|
import React from "react"
|
|
|
|
export const useStyles = makeStyles(() => ({
|
|
root: {
|
|
position: "absolute",
|
|
top: "0",
|
|
left: "0",
|
|
right: "0",
|
|
bottom: "0",
|
|
display: "flex",
|
|
justifyContent: "center",
|
|
alignItems: "center",
|
|
},
|
|
}))
|
|
|
|
export const FullScreenLoader: React.FC = () => {
|
|
const styles = useStyles()
|
|
|
|
return (
|
|
<div className={styles.root}>
|
|
<CircularProgress />
|
|
</div>
|
|
)
|
|
}
|