Skip to content

Fix scrollable list in modals and add pagination

Zach Oakes requested to merge oakes/soapbox:modal-scrollable-list into develop

Currently if you click "Likes" or "Reposts" on a popular status, the modal dialog looks broken. It expands beyond the screen, and there is a large amount of whitespace instead of showing all results. I'm guessing this is because ScrollableList / virtuoso is not playing well with the Modal component. I found that setting the height and turning off useWindowScroll made it much better.

I also added pagination to both modals. I tried my best to follow how it is done elsewhere: it uses the Link header and onLoadMore like other components.

Before:

Screen_Shot_2023-06-24_at_6.53.57_PM Screen_Shot_2023-06-24_at_6.54.33_PM

After:

Screen_Shot_2023-06-24_at_6.53.39_PM

Edited by Zach Oakes

Merge request reports

Loading