diff --git a/apps/client/src/widgets/collections/table/tabulator.tsx b/apps/client/src/widgets/collections/table/tabulator.tsx index 57c90b59a..6301d5b38 100644 --- a/apps/client/src/widgets/collections/table/tabulator.tsx +++ b/apps/client/src/widgets/collections/table/tabulator.tsx @@ -16,7 +16,7 @@ interface TableProps extends Omit({ className, columns, data, modules, tabulatorRef: externalTabulatorRef, footerElement, events, index, ...restProps }: TableProps) { +export default function Tabulator({ className, columns, data, modules, tabulatorRef: externalTabulatorRef, footerElement, events, index, dataTree, ...restProps }: TableProps) { const parentComponent = useContext(ParentComponent); const containerRef = useRef(null); const tabulatorRef = useRef(null); @@ -36,6 +36,7 @@ export default function Tabulator({ className, columns, data, modules, tabula data, footerElement: (parentComponent && isValidElement(footerElement) ? renderReactWidget(parentComponent, footerElement)[0] : undefined), index: index as string | number | undefined, + dataTree, ...restProps }); @@ -45,7 +46,7 @@ export default function Tabulator({ className, columns, data, modules, tabula }); return () => tabulator.destroy(); - }, []); + }, [ dataTree ] ); useEffect(() => { const tabulator = tabulatorRef.current;