react-datasheet-grid icon indicating copy to clipboard operation
react-datasheet-grid copied to clipboard

Horizontal Scroll Issue

Open mass2527 opened this issue 3 years ago • 3 comments

#179

Hello Mr. Keller,

I really appreciate your reply. However, I think we are not on the same page.

To be more specific with my issue, When there are a lot of columns on the sheet, a horizontal scroll appears and it always comes with a vertical scroll as a default, even when it is unnecessary. Thus, that causes the problem, even though when I already assigned the innerHeight instead of the outerHeight.

FYI: My height calculation

<DataSheetGrid
  columns={config.columns}
  value={value}
  height={window.screen.availHeight / 2}
/>

Thanks a lot, Philly

mass2527 avatar Sep 05 '22 10:09 mass2527

I have this same issue. I am setting the height of the DataSheetGrid to use up all of the available space on the browser page. If I have a grid with a single row of data, and that data fits in the width of the browser page, it looks fine. If I add an additional column that causes the grid to be wider than the window, then the grid will be displayed with the horizontal scrollbar added, but the grid with the scrollbar takes up exactly the same space as the grid without the scrollbar. This results in space for the actual data not being enough to display the entire height of the row. I can scroll vertically, but it is not possible to see an entire row at once.

The issue is not the height property. In the screenshot here, the height is set to 533, and you can see that there is plenty of space available, but the horizontal scrollbar is covering up part of the data.

image

Here is the same row, with the last column removed:

image

kelbyers avatar Dec 08 '22 23:12 kelbyers

Thanks for the report. I don't have much time at the moment so feel free to send a PR. I am in the process of re-writing the virtualisation myself, which should solve a few issues and allow for more performance and more flexible API. But the ETA on this is very uncertain :/

nick-keller avatar Dec 16 '22 16:12 nick-keller