@@ -3,13 +3,16 @@ import Flex from "@/components/templates/flex"
33import { useTableState } from "../../provider"
44import Cell from "./cell"
55
6- const rerenderSelector = state => ( {
7- sizing : state . columnSizing ,
8- expanded : state . expanded ,
9- columnVisibility : state . columnVisibility ,
10- selectedRows : state . selectedRows ,
11- grouping : state . grouping ,
12- } )
6+ const rerenderSelector = state => {
7+ return {
8+ sizing : state . columnSizing ,
9+ expanded : state . expanded ,
10+ columnVisibility : state . columnVisibility ,
11+ selectedRows : state . selectedRows ,
12+ grouping : state . grouping ,
13+ columnsCount : state . table && state . table . getAllColumns ( ) . length ,
14+ }
15+ }
1316
1417const HeaderGroup = ( { headerGroup, testPrefix, ...rest } ) => (
1518 < Flex
@@ -39,6 +42,7 @@ const HeaderGroups = ({ groups, size, side, ...rest }) => {
3942 zIndex = { side ? 11 : undefined }
4043 width = { `${ size } px` }
4144 flex = "grow"
45+ column
4246 >
4347 { groups . map ( headerGroup => (
4448 < HeaderGroup headerGroup = { headerGroup } key = { headerGroup . id } { ...rest } />
0 commit comments