Closed sanketjo96 closed 4 years ago
@marchaos Updated the sandbox to showcase the issue
Hey, just wanted to check, did you look at this. currentPos stays at same value during scrolling.
Hey, sorry for the late reply. I've been trying to fix this, but realised that the heights of your nodes don't look right, due to borders, which is confusing the library. When you specify the heights of nodes, this needs to include border height as well, unless you use box-sizing: border-box. So you can either specify the node height including borders, or make sure you're usng border-box syling for nodes.
I had a quick play with it and it does seem much better.
Sorry for late comment. I've removed borders, but still issue exists. Last node does not render 7 out of 10 times when you scroll to bottom.
https://codesandbox.io/s/frosty-shadow-nnghy?fontsize=14&hidenavigation=1&theme=dark
Can you see blank space in place of child 10 after scrolling ?
@marchaos Hey Marc, please have a look once you get chance. I know this has been closed. But wanted above example to run by you.
Observed the issue where last node does not render in DOM.
Sandbox - https://codesandbox.io/s/beautiful-flower-2r9l4 fontsize=14&hidenavigation=1&theme=dark
Steps to reproduce
As per my observation in spacial cases like above, during forwardSearch this.currentPos stays at same value which then prevents call to this.storeRenderTree to trigger re-render.
Things which are causing render of last node -
Not sure of any better way to handle this so that it will work for all cases. Please add your thoughts as well. It might be related to the issue [https://github.com/marchaos/react-virtualized-sticky-tree/issues/15]()