-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Completing TCES-41 Added Create & Edit User pages
- Loading branch information
Showing
2 changed files
with
142 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
import { Box, TextField, Stack, Button, Card, CardHeader, CardContent, Typography } from "@mui/material"; | ||
|
||
const styles = { | ||
body: { | ||
height: "100vh", | ||
display: "flex", | ||
flexDirection: "column", | ||
alignItems: "center", | ||
justifyContent: "center", | ||
fontFamily: "Helvetica", | ||
backgroundColor: "#f0f3f8", | ||
}, | ||
heading: { | ||
display: "flex", | ||
width: "47.5rem", | ||
paddingRight: "0px", | ||
flexDirection: "column", | ||
alignItems: "flex-start", | ||
gap: "0.625rem", | ||
}, | ||
cancel: { | ||
marginRight: "auto", | ||
}, | ||
}; | ||
|
||
function Create() { | ||
return ( | ||
<section style={styles.body}> | ||
<Stack maxWidth="md" gap={4}> | ||
<Box style={styles.heading}> | ||
<Typography variant="h3">Create New User</Typography> | ||
<Typography variant="body1">Manually create a new user</Typography> | ||
</Box> | ||
|
||
<Card> | ||
<CardHeader title="User Information" /> | ||
<CardContent> | ||
<Stack gap={1.5}> | ||
<TextField | ||
id="firstname" | ||
label="First Name" | ||
helperText="*Required" | ||
/> | ||
<TextField | ||
id="lastname" | ||
label="Last Name" | ||
helperText="*Required" | ||
/> | ||
<TextField | ||
id="email" | ||
label="Email" | ||
helperText="*Required" | ||
/> | ||
<TextField | ||
id="password" | ||
label="Password" | ||
helperText="*Required" | ||
/> | ||
</Stack> | ||
</CardContent> | ||
</Card> | ||
<Stack direction="row"> | ||
<Button variant="outlined" size="large" style={styles.cancel}>Cancel</Button> | ||
<Button variant="contained" size="large">Submit</Button> | ||
</Stack> | ||
</Stack> | ||
</section > | ||
); | ||
} | ||
|
||
export default Create; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
import { Box, TextField, Stack, Button, Card, CardHeader, CardContent, Typography } from "@mui/material"; | ||
|
||
const styles = { | ||
body: { | ||
height: "100vh", | ||
display: "flex", | ||
flexDirection: "column", | ||
alignItems: "center", | ||
justifyContent: "center", | ||
fontFamily: "Helvetica", | ||
backgroundColor: "#f0f3f8", | ||
}, | ||
heading: { | ||
display: "flex", | ||
width: "47.5rem", | ||
paddingRight: "0px", | ||
flexDirection: "column", | ||
alignItems: "flex-start", | ||
gap: "0.625rem", | ||
}, | ||
cancel: { | ||
marginRight: "auto", | ||
}, | ||
}; | ||
|
||
function Edit() { | ||
return ( | ||
<section style={styles.body}> | ||
<Stack maxWidth="md" gap={4}> | ||
<Box style={styles.heading}> | ||
<Typography variant="h3">Edit User</Typography> | ||
<Typography variant="body1">Edit existing user information</Typography> | ||
</Box> | ||
|
||
<Card> | ||
<CardHeader title="User Information" /> | ||
<CardContent> | ||
<Stack gap={1.5}> | ||
<TextField | ||
id="firstname" | ||
label="First Name" | ||
helperText="*Required" | ||
/> | ||
<TextField | ||
id="lastname" | ||
label="Last Name" | ||
helperText="*Required" | ||
/> | ||
<TextField | ||
id="email" | ||
label="Email" | ||
helperText="*Required" | ||
/> | ||
<TextField | ||
id="password" | ||
label="Password" | ||
helperText="*Required" | ||
/> | ||
</Stack> | ||
</CardContent> | ||
</Card> | ||
<Stack direction="row"> | ||
<Button variant="outlined" size="large" style={styles.cancel}>Cancel</Button> | ||
<Button variant="contained" size="large">Save</Button> | ||
</Stack> | ||
</Stack> | ||
</section > | ||
); | ||
} | ||
|
||
export default Edit; |