File tree Expand file tree Collapse file tree 1 file changed +3
-2
lines changed
packages/main/src/components/AnalyticalTable Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change
1
+ import { useIsomorphicLayoutEffect } from '@ui5/webcomponents-react-base/lib/hooks' ;
1
2
import { StyleClassHelper } from '@ui5/webcomponents-react-base/lib/StyleClassHelper' ;
2
3
import { createComponentStyles } from '@ui5/webcomponents-react-base/lib/createComponentStyles' ;
3
4
import { usePassThroughHtmlProps } from '@ui5/webcomponents-react-base/lib/usePassThroughHtmlProps' ;
@@ -282,7 +283,7 @@ const AnalyticalTable: FC<TableProps> = forwardRef((props: TableProps, ref: Ref<
282
283
if ( tableRef . current ) {
283
284
dispatch ( { type : 'TABLE_RESIZE' , payload : { tableClientWidth : tableRef . current . clientWidth } } ) ;
284
285
}
285
- } , [ ] ) ;
286
+ } , [ tableRef . current ] ) ;
286
287
287
288
useEffect ( ( ) => {
288
289
// @ts -ignore
@@ -293,7 +294,7 @@ const AnalyticalTable: FC<TableProps> = forwardRef((props: TableProps, ref: Ref<
293
294
} ;
294
295
} , [ updateTableClientWidth ] ) ;
295
296
296
- useEffect ( ( ) => {
297
+ useIsomorphicLayoutEffect ( ( ) => {
297
298
updateTableClientWidth ( ) ;
298
299
} , [ updateTableClientWidth ] ) ;
299
300
You can’t perform that action at this time.
0 commit comments