Skip to content

Commit

Permalink
Fix to much padding on table cell with add icon
Browse files Browse the repository at this point in the history
  • Loading branch information
TheZoker authored and sdirix committed Sep 16, 2019
1 parent 669ce76 commit c9edb1f
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
2 changes: 1 addition & 1 deletion packages/material/src/complex/MaterialTableControl.tsx
Expand Up @@ -262,7 +262,7 @@ const NonEmptyRow = React.memo(
<Grid
container
direction='row'
justify='center'
justify='flex-end'
alignItems='center'
>
{showSortButtons ? (
Expand Down
7 changes: 6 additions & 1 deletion packages/material/src/complex/TableToolbar.tsx
Expand Up @@ -49,6 +49,11 @@ export interface MaterialTableToolbarProps {
addItem(path: string, value: any): () => void;
}

const fixedCellSmall = {
paddingLeft: 0,
paddingRight: 0,
}

const TableToolbar = React.memo(
({
numColumns,
Expand Down Expand Up @@ -83,7 +88,7 @@ const TableToolbar = React.memo(
</Grid>
</NoBorderTableCell>
{enabled ? (
<NoBorderTableCell>
<NoBorderTableCell align='right' style={ fixedCellSmall }>
<Tooltip
id='tooltip-add'
title={`Add to ${label}`}
Expand Down

0 comments on commit c9edb1f

Please sign in to comment.