File tree Expand file tree Collapse file tree 1 file changed +5
-6
lines changed
Expand file tree Collapse file tree 1 file changed +5
-6
lines changed Original file line number Diff line number Diff line change @@ -89,19 +89,18 @@ export function useColumnWidths<R, SR>(
8989 function handleColumnResize ( column : CalculatedColumn < R , SR > , nextWidth : ResizedWidth ) {
9090 const { key : resizingKey } = column ;
9191
92- setMeasuredColumnWidths ( ( measuredColumnWidths ) => {
93- if ( columnsCanFlex ) {
92+ if ( columnsCanFlex ) {
93+ // delete measured column widths for all other flex columns so they can be recalculated
94+ setMeasuredColumnWidths ( ( measuredColumnWidths ) => {
9495 const newMeasuredColumnWidths = new Map ( measuredColumnWidths ) ;
9596 for ( const { key, width } of viewportColumns ) {
9697 if ( resizingKey !== key && typeof width === 'string' && ! resizedColumnWidths . has ( key ) ) {
9798 newMeasuredColumnWidths . delete ( key ) ;
9899 }
99100 }
100101 return newMeasuredColumnWidths ;
101- }
102-
103- return measuredColumnWidths ;
104- } ) ;
102+ } ) ;
103+ }
105104
106105 setColumnToAutoResize ( {
107106 key : resizingKey ,
You can’t perform that action at this time.
0 commit comments