diff --git a/superset-frontend/plugins/plugin-chart-table/src/DataTable/hooks/useSticky.tsx b/superset-frontend/plugins/plugin-chart-table/src/DataTable/hooks/useSticky.tsx index 240073210..9a98fee43 100644 --- a/superset-frontend/plugins/plugin-chart-table/src/DataTable/hooks/useSticky.tsx +++ b/superset-frontend/plugins/plugin-chart-table/src/DataTable/hooks/useSticky.tsx @@ -183,7 +183,9 @@ function StickyWrap({ .clientHeight; const ths = bodyThead.childNodes[0] .childNodes as NodeListOf; - const widths = Array.from(ths).map(th => th.clientWidth); + const widths = Array.from(ths).map( + th => th.getBoundingClientRect()?.width || th.clientWidth, + ); const [hasVerticalScroll, hasHorizontalScroll] = needScrollBar({ width: maxWidth, height: maxHeight - theadHeight - tfootHeight,