Skip to content

Conversation

Artur-
Copy link
Member

@Artur- Artur- commented Sep 22, 2025

Implements scrollToColumn method to enable horizontal scrolling in Grid, particularly useful when columnRendering is set to lazy. This addresses the issue where cells return null when columns are out of view.

New features:

  • scrollToColumn(GridColumnElement) - scrolls to specific column
  • scrollToColumn(int columnIndex) - scrolls to column by index
  • isColumnInView(GridColumnElement) - checks if column is visible
  • Automatic column scrolling in getCell() method

This enhancement allows reliable testing of grids with many columns and lazy column rendering, fixing the issue where it was impossible to distinguish between genuinely null cells and cells not rendered due to being out of view.

Fixes #8046

Implements scrollToColumn method to enable horizontal scrolling in Grid,
particularly useful when columnRendering is set to lazy. This addresses
the issue where cells return null when columns are out of view.

New features:
- scrollToColumn(GridColumnElement) - scrolls to specific column
- scrollToColumn(int columnIndex) - scrolls to column by index
- isColumnInView(GridColumnElement) - checks if column is visible
- Automatic column scrolling in getCell() method

This enhancement allows reliable testing of grids with many columns
and lazy column rendering, fixing the issue where it was impossible
to distinguish between genuinely null cells and cells not rendered
due to being out of view.

Fixes #8046

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <[email protected]>
Artur- and others added 10 commits September 22, 2025 13:07
Fixed compilation error by using ColumnRendering.LAZY instead of
the non-existent Grid.ColumnRenderingMode.LAZY
The scrollToColumn method was using a non-existent grid.$.table.scrollToColumn(index) API.
Fixed to properly manipulate table.scrollLeft to scroll columns into view based on their
position relative to the table viewport.

This fix ensures horizontal scrolling works correctly with lazy column rendering,
allowing cells to be accessed reliably even when columns are initially out of view.

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <[email protected]>
Copy link

sonarqubecloud bot commented Oct 6, 2025

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

GridElement should provide a method to scroll to a specific column
1 participant