Skip to content

Commit

Permalink
Changed the display property of the TableBody component to allow Auto…
Browse files Browse the repository at this point in the history
…Sizer to properly calculate height; Minor formatting
  • Loading branch information
wrigh393 committed Apr 19, 2021
1 parent e4ca2f8 commit 288fe58
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions src/components/ItemTable/ItemTable.js
Original file line number Diff line number Diff line change
Expand Up @@ -42,9 +42,10 @@ export default function ItemTable({ data, rowCanBeSelected, loading }) {
borderLeftStyle: "solid",
borderColor: theme.palette.type === "light" ? theme.palette.grey[300] : theme.palette.grey[500]
},
VirtualizedTableHeight: {
VirtualizedTableStyles: {
// The !important is placed here to enforce CSS specificity.
height: '82vh !important'
height: '82vh !important',
display:"table-row"
},
});
const classes = useStyles();
Expand Down Expand Up @@ -148,9 +149,9 @@ export default function ItemTable({ data, rowCanBeSelected, loading }) {
))}
</TableHead>

<TableBody {...getTableBodyProps()} classes={{ root: classes.VirtualizedTableHeight }} >
<TableBody {...getTableBodyProps()} classes={{ root: classes.VirtualizedTableStyles }}>
<AutoSizer disableWidth>
{({ height,width }) => (
{({ height, width }) => (
<FixedSizeList
className="Table"
height={height}
Expand Down

0 comments on commit 288fe58

Please sign in to comment.