fix(react-stately): set allowOverflow on TableLayout nodes for sticky columns - #10528
fix(react-stately): set allowOverflow on TableLayout nodes for sticky columns#10528sundeep8967 wants to merge 1 commit into
Conversation
|
Can you explain this in more depth?
When do those other layouts use isSticky? or why and when do they set allowOverflow true? Does it truly make sense for every node in TableLayout to now allowOverflow? |
… columns Fixes adobe#10518 by setting allowOverflow = true across TableLayout nodes (header, headerrow, column, row, cell), ensuring that columns marked as sticky via isStickyColumn() are not clipped during virtualized scroll. Signed-off-by: sundeep8967 <sundeep8967@gmail.com>
3f9e695 to
7c86e7f
Compare
|
Hi @snowystinger, Thanks for the question! Here is the exact mechanism and context: The
|
|
Hey, so AI is leading you a little astray here. The reason for the overflow being hidden is that it is a performance optimisation. That particular optimisation is a little dated now however, we're discussing if we still need this at all. |
Description
TableLayoutexposesisStickyColumn()as a protected extension point to configure sticky columns. While overriding it setsLayoutInfo.isStickyand maintains persisted indices,TableLayoutpreviously never setLayoutInfo.allowOverflow = trueon its layout nodes.As a result, in
VirtualizerItem(layoutInfoToStyle), sticky column cells were clipped and offset by parent scroll coordinates rather than remaining visually pinned in the viewport during virtualized horizontal scrolling.Solution
Updated
TableLayout.tsacrossbuildTableHeader,buildHeaderRow,buildColumn,buildRow, andbuildCellto setallowOverflow = true, bringingTableLayoutin line with sibling layouts (ListLayout,GridLayout,WaterfallLayout).Fixes #10518