table height style changes

This commit is contained in:
Sonika 2023-12-22 21:11:04 +05:30
parent 28605753a1
commit b4edc35211
3 changed files with 31 additions and 29 deletions

View File

@ -27,3 +27,8 @@
background-color: #171716;
color: white;
}
.no-padding-cell {
padding-top: 6.5px !important;
padding-bottom: 6.5px !important;
}

View File

@ -128,20 +128,20 @@ export default function IntranetUsers(){
<Table>
<TableHead className="manageusers-table-header-style">
<TableRow>
<TableCell>
<TableCell className="no-padding-cell">
<Button variant="contained" sx={{bgcolor:'white',color:'#1e1e1e', fontWeight:600}} startIcon={<AddIcon />} onClick={handleOpen}>
New
</Button>
</TableCell>
<TableCell>Name</TableCell>
<TableCell>Role</TableCell>
<TableCell>Active</TableCell>
<TableCell className="no-padding-cell">Name</TableCell>
<TableCell className="no-padding-cell">Role</TableCell>
<TableCell className="no-padding-cell">Active</TableCell>
</TableRow>
</TableHead>
<TableBody>
{manageUsersResponse && manageUsersResponse.map((row:any) => (
<TableRow key={row.id} sx={{height:'20px'}}>
<TableCell>
<TableCell className="no-padding-cell">
<IconButton onClick={() => handleEdit(row)} aria-label="edit">
<EditIcon sx={{ color: 'white' }}/>
</IconButton>
@ -149,12 +149,12 @@ export default function IntranetUsers(){
<DeleteIcon sx={{ color: 'white' }}/>
</IconButton> */}
</TableCell>
<TableCell>{row.username}</TableCell>
<TableCell>{row.role}</TableCell>
<TableCell className="no-padding-cell">{row.username}</TableCell>
<TableCell className="no-padding-cell">{row.role}</TableCell>
{row.active==1?
<TableCell sx={{color:'green', backgroundColor:'#171716', borderBottom:'1px solid rgb(45 51 59)'}}>Active</TableCell>
<TableCell className="no-padding-cell" sx={{color:'green', backgroundColor:'#171716', borderBottom:'1px solid rgb(45 51 59)'}}>Active</TableCell>
:
<TableCell sx={{color:'red', backgroundColor:'#171716', borderBottom:'1px solid rgb(45 51 59)'}}>Inactive</TableCell>}
<TableCell className="no-padding-cell" sx={{color:'red', backgroundColor:'#171716', borderBottom:'1px solid rgb(45 51 59)'}}>Inactive</TableCell>}
</TableRow>
))}
</TableBody>

View File

@ -129,35 +129,32 @@ export default function ManageUsers(){
<Table>
<TableHead className="manageusers-table-header-style">
<TableRow >
<TableCell>
<TableCell className="no-padding-cell">
<Button variant="contained" sx={{bgcolor:'white',color:'#1e1e1e', fontWeight:600}} startIcon={<AddIcon />} onClick={handleOpen}>
New
</Button>
</TableCell>
<TableCell>Name</TableCell>
<TableCell>Email Id</TableCell>
<TableCell>Last Login</TableCell>
<TableCell>Active</TableCell>
<TableCell className="no-padding-cell">Name</TableCell>
<TableCell className="no-padding-cell">Email Id</TableCell>
<TableCell className="no-padding-cell">Last Login</TableCell>
<TableCell className="no-padding-cell">Active</TableCell>
</TableRow>
</TableHead>
<TableBody>
{manageUsersResponse && manageUsersResponse.map((row:any) => (
<TableRow key={row.id} sx={{height:'20px'}}>
<TableCell>
<TableRow key={row.id} >
<TableCell className="no-padding-cell">
<IconButton onClick={() => handleEdit(row)} aria-label="edit">
<EditIcon sx={{ color: 'white' }}/>
</IconButton>
{/* <IconButton onClick={() => handleDelete(row.id)} aria-label="delete">
<DeleteIcon sx={{ color: 'white' }}/>
</IconButton> */}
</TableCell>
<TableCell>{row.username}</TableCell>
<TableCell>{row.email_id}</TableCell>
<TableCell>{row.last_login}</TableCell>
<TableCell className="no-padding-cell">{row.username}</TableCell>
<TableCell className="no-padding-cell">{row.email_id}</TableCell>
<TableCell className="no-padding-cell">{row.last_login}</TableCell>
{row.active?
<TableCell sx={{color:'green', backgroundColor:'#171716', borderBottom:'1px solid rgb(45 51 59)'}}>Active</TableCell>
<TableCell className="no-padding-cell" sx={{color:'green', backgroundColor:'#171716', borderBottom:'1px solid rgb(45 51 59)'}}>Active</TableCell>
:
<TableCell sx={{color:'red', backgroundColor:'#171716', borderBottom:'1px solid rgb(45 51 59)'}}>Inactive</TableCell>}
<TableCell className="no-padding-cell" sx={{color:'red', backgroundColor:'#171716', borderBottom:'1px solid rgb(45 51 59)'}}>Inactive</TableCell>}
</TableRow>
))}
</TableBody>