From 06c1f584e7bdae7a4992586d191de96215e5f98e Mon Sep 17 00:00:00 2001 From: tdari Date: Fri, 2 Feb 2024 18:26:58 +0300 Subject: [PATCH] refactor: update workspace card view --- .../workspaces/WorkspaceListItem.tsx | 116 ++++++++++++++---- 1 file changed, 89 insertions(+), 27 deletions(-) diff --git a/frontend/src/features/workspaces/components/workspaces/WorkspaceListItem.tsx b/frontend/src/features/workspaces/components/workspaces/WorkspaceListItem.tsx index 7992fe77..1d075bf5 100644 --- a/frontend/src/features/workspaces/components/workspaces/WorkspaceListItem.tsx +++ b/frontend/src/features/workspaces/components/workspaces/WorkspaceListItem.tsx @@ -1,3 +1,8 @@ +import CheckBoxOutlineBlankIcon from "@mui/icons-material/CheckBoxOutlineBlank"; +import CheckBoxOutlinedIcon from "@mui/icons-material/CheckBoxOutlined"; +import DeleteOutlineIcon from "@mui/icons-material/DeleteOutline"; +import LogoutIcon from "@mui/icons-material/Logout"; +import SettingsIcon from "@mui/icons-material/Settings"; import { Card, CardActionArea, @@ -7,7 +12,11 @@ import { CardActions, Button, Grid, + Divider, + Tooltip, + Chip, } from "@mui/material"; +import Stack from "@mui/material/Stack"; import { type IWorkspaceSummary } from "context/workspaces/types"; import { type FC } from "react"; import { useNavigate } from "react-router-dom"; @@ -43,7 +52,7 @@ export const WorkspaceListItem: FC<{ sx={{ display: "flex", flexDirection: "column", - borderColor: isSelected ? "darkgray" : "primary.main", + borderColor: isSelected ? "green" : "primary", }} > + + Selected + + ) : ( + + + Select + + ) + } + sx={{ py: 1, width: "100%" }} /> - - - - + + + + Permission: - {workspace.user_permission} + - - + + + + + Status: - - {workspace.status === "accepted" - ? "Collaborating" - : "Refused"} - + @@ -85,27 +138,36 @@ export const WorkspaceListItem: FC<{ - - -