|
Last change
on this file since badbc79 was badbc79, checked in by Luka Cheshlarov <luka.cheshlarov@…>, 20 months ago |
|
Initial commit
|
-
Property mode
set to
100644
|
|
File size:
1.0 KB
|
| Line | |
|---|
| 1 | import React from "react";
|
|---|
| 2 | import Potrosuvac from "../../assets/images/regularUser.jpg";
|
|---|
| 3 | import Menager from "../../assets/images/manager.jpg";
|
|---|
| 4 | import Vozac from "../../assets/images/food-driver.jpg";
|
|---|
| 5 | import Admin from "../../assets/images/admin.jpg";
|
|---|
| 6 | import {Card, CardContent, Typography} from "@mui/material";
|
|---|
| 7 | import {UserRole} from "../../services/user-service";
|
|---|
| 8 |
|
|---|
| 9 | const RoleCard = ({role}) => {
|
|---|
| 10 | return (
|
|---|
| 11 | <Card variant="outlined" className={"role-card"}>
|
|---|
| 12 | <CardContent className={"d-flex flex-column align-content-center justify-content-center"}>
|
|---|
| 13 | <img className={"centered-image"} src={role === UserRole.Potrosuvac ? Potrosuvac
|
|---|
| 14 | : role === UserRole.Menager ? Menager
|
|---|
| 15 | : role === UserRole.Vozac ? Vozac
|
|---|
| 16 | : Admin} alt={"team"} height={320}/>
|
|---|
| 17 | <Typography className={"text-center"} variant="h5">
|
|---|
| 18 | {role}
|
|---|
| 19 | </Typography>
|
|---|
| 20 | </CardContent>
|
|---|
| 21 | </Card>
|
|---|
| 22 | )
|
|---|
| 23 | }
|
|---|
| 24 |
|
|---|
| 25 | export default RoleCard; |
|---|
Note:
See
TracBrowser
for help on using the repository browser.