Skip to content

Commit

Permalink
Set min-width to scrollbar, fix align bug
Browse files Browse the repository at this point in the history
  • Loading branch information
afc163 committed Nov 29, 2019
1 parent 04de08d commit a294803
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/HeadTable.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,8 @@ export default function HeadTable(props: HeadTableProps, { table }) {
if (scrollbarWidthOfHeader > 0 && !fixed) {
headStyle.marginBottom = `-${scrollbarWidthOfHeader}px`;
headStyle.paddingBottom = '0px';
// https://github.com/ant-design/ant-design/pull/19986
headStyle.minWidth = `${scrollbarWidthOfHeader}px`;
// https://github.com/ant-design/ant-design/issues/17051
headStyle.overflowX = 'scroll';
headStyle.overflowY = scrollbarWidth === 0 ? 'hidden' : 'scroll';
Expand Down

0 comments on commit a294803

Please sign in to comment.