Browse Source
fix(useTableScroll): query paginationel every time to get the correct height (#355)
pull/388/head
ztw2010
5 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with
1 additions and
3 deletions
-
src/components/Table/src/hooks/useTableScroll.ts
|
|
|
@ -91,9 +91,7 @@ export function useTableScroll( |
|
|
|
// Pager height
|
|
|
|
let paginationHeight = 2; |
|
|
|
if (!isBoolean(pagination)) { |
|
|
|
if (!paginationEl) { |
|
|
|
paginationEl = tableEl.querySelector('.ant-pagination') as HTMLElement; |
|
|
|
} |
|
|
|
paginationEl = tableEl.querySelector('.ant-pagination') as HTMLElement; |
|
|
|
if (paginationEl) { |
|
|
|
const offsetHeight = paginationEl.offsetHeight; |
|
|
|
paginationHeight += offsetHeight || 0; |
|
|
|
|