Always use available width for grid items (#375)
In case a manga thumbnail was smaller than the set item width, the item didn't use all its available width. Thus, being smaller than the other items.
This commit is contained in:
@@ -34,7 +34,7 @@ const GridItemContainerWithDimension = (
|
|||||||
const columnsPerItem = gridLayout === GridLayout.List ? maxColumns : maxColumns / itemsPerRow;
|
const columnsPerItem = gridLayout === GridLayout.List ? maxColumns : maxColumns / itemsPerRow;
|
||||||
|
|
||||||
return ({ children, ...itemProps }: GridTypeMap['props'] & Partial<GridItemProps>) => (
|
return ({ children, ...itemProps }: GridTypeMap['props'] & Partial<GridItemProps>) => (
|
||||||
<Grid {...itemProps} item xs={columnsPerItem} sx={{ paddingTop: '8px', paddingLeft: '8px' }}>
|
<Grid {...itemProps} item xs={columnsPerItem} sx={{ width: '100%', paddingTop: '8px', paddingLeft: '8px' }}>
|
||||||
{children}
|
{children}
|
||||||
</Grid>
|
</Grid>
|
||||||
);
|
);
|
||||||
|
|||||||
Reference in New Issue
Block a user