DataTable (packages/client/src/components/DataTable.tsx) now seeds its virtualizer from the themed row geometry (useTableRowHeight('titled' | 'compact')) instead of canary's flat 48px. Rendered rows are measured through measureElement, so only the estimate for rows not yet rendered, and with it the initial scroll height, can be off. Two ways it still is:
- Breakpoints: below
sm, TableCell size="compact" renders dense padding and text-xs (about 24px), while the compact estimate is 36px. useTableRowHeight re-reads only on root style/class mutations, so crossing sm does not refresh the estimate.
- Column shape:
hasTitleColumn inspects top-level columns only. A grouped definition ({ columns: [{ accessorKey: 'title' }] }) gets the compact estimate although its leaf renders a 48px title cell, and a title column hidden through column visibility still selects the titled estimate.
Suggested fix: derive the title check from table.getVisibleLeafColumns(), and make the row-height read breakpoint-aware (subscribe to the sm media query as well as root mutations).
Raised by the local cross-family review on LibreChat-AI#16489 (local:744d1f2:L-001, L-002). Outside that change's contract (theme roles for table header, row rule and density); not a regression against canary, which used a constant estimate.
DataTable(packages/client/src/components/DataTable.tsx) now seeds its virtualizer from the themed row geometry (useTableRowHeight('titled' | 'compact')) instead of canary's flat 48px. Rendered rows are measured throughmeasureElement, so only the estimate for rows not yet rendered, and with it the initial scroll height, can be off. Two ways it still is:sm,TableCell size="compact"renders dense padding andtext-xs(about 24px), while the compact estimate is 36px.useTableRowHeightre-reads only on root style/class mutations, so crossingsmdoes not refresh the estimate.hasTitleColumninspects top-levelcolumnsonly. A grouped definition ({ columns: [{ accessorKey: 'title' }] }) gets the compact estimate although its leaf renders a 48px title cell, and a title column hidden through column visibility still selects the titled estimate.Suggested fix: derive the title check from
table.getVisibleLeafColumns(), and make the row-height read breakpoint-aware (subscribe to thesmmedia query as well as root mutations).Raised by the local cross-family review on LibreChat-AI#16489 (local:744d1f2:L-001, L-002). Outside that change's contract (theme roles for table header, row rule and density); not a regression against canary, which used a constant estimate.