Skip to content

Commit

Permalink
Merge pull request #844 from Jithmi004/main
Browse files Browse the repository at this point in the history
Fix property value overflow in publisher portal
  • Loading branch information
RakhithaRR authored Jan 7, 2025
2 parents 5f7d142 + 1b01654 commit 12ec30d
Showing 1 changed file with 24 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -34,17 +34,19 @@ import Box from '@mui/material/Box';
import Button from '@mui/material/Button';
import Typography from '@mui/material/Typography';
import VisibilityIcon from '@mui/icons-material/Visibility';
import Tooltip from '@mui/material/Tooltip';

const PREFIX = 'EditableRow';

const classes = {
link: `${PREFIX}-link`,
checkBoxStyles: `${PREFIX}-checkBoxStyles`,
colorPrimary: `${PREFIX}-colorPrimary`,
cancelButton: `${PREFIX}-cancelButton`
cancelButton: `${PREFIX}-cancelButton`,
tableCellStyles: `${PREFIX}-tableCellStyles`
};

const StyledTableRow = styled(TableRow)(() => ({
const StyledTableRow = styled(TableRow)(({theme}) => ({
[`& .${classes.link}`]: {
cursor: 'pointer',
},
Expand All @@ -62,6 +64,17 @@ const StyledTableRow = styled(TableRow)(() => ({

[`& .${classes.cancelButton}`]: {
marginLeft: 4,
},
[`& .${classes.tableCellStyles}`]: {
display: 'inline-block',
minWidth: '150px',
maxWidth: '600px',
whiteSpace: 'normal',
overflow: 'hidden',
textOverflow: 'ellipsis',
[theme.breakpoints.up('xl')]: {
maxWidth: '1000px',
},
}
}));

Expand Down Expand Up @@ -195,9 +208,15 @@ function EditableRow(props) {
) : (
<>
<TableCell>
<Box display='inline-block' minWidth={150}>
{oldValue}
</Box>
<Tooltip
placement='top'
interactive
title={oldValue}
>
<Box className={classes.tableCellStyles}>
{oldValue}
</Box>
</Tooltip>
</TableCell>
<TableCell>
{isVisibleInStore && (
Expand Down

0 comments on commit 12ec30d

Please sign in to comment.