Refactor ObjectTable component for improved readability and styling consistency

- Simplified the loadPage function call by consolidating parameters into a single line, enhancing code clarity.
- Updated the Splitter component's className to include 'large', ensuring consistent styling across the dashboard components.
This commit is contained in:
Tom Butcher 2026-08-01 14:44:56 +01:00
parent 342f770841
commit 1efebeeda6

View File

@ -823,11 +823,7 @@ const ObjectTable = forwardRef(
setTableSorter(sorter) setTableSorter(sorter)
} }
loadPage( loadPage(initialPage, activeFilter, sorter.field ? sorter : null)
initialPage,
activeFilter,
sorter.field ? sorter : null
)
}, [getPersistedFilter, getPersistedSorter, initialPage, loadPage]) }, [getPersistedFilter, getPersistedSorter, initialPage, loadPage])
useImperativeHandle(ref, () => ({ useImperativeHandle(ref, () => ({
@ -1281,7 +1277,7 @@ const ObjectTable = forwardRef(
style={{ flex: 1, minWidth: 0, minHeight: 0 }} style={{ flex: 1, minWidth: 0, minHeight: 0 }}
> >
<Splitter <Splitter
className={'farmcontrol-splitter'} className={'farmcontrol-splitter large'}
onResize={measureCardColSpan} onResize={measureCardColSpan}
onResizeEnd={measureCardColSpan} onResizeEnd={measureCardColSpan}
> >