-
Notifications
You must be signed in to change notification settings - Fork 10
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Pagination on leaderboards #21
Comments
not sure what you mean by searching, since there is no current implementation of that anywhere? Searching is already implemented via the search game/user option, or do you have something different in mind? |
There's a few places. A combination of search, sort, pagination is in I'd rather use the same implementation everywhere. I'd be down to refactor everything to use some library that does everything as per #3, but that would be a big refactor |
i agree, in the end if theres one table with pagination that works really well it can be copied quite easily, so I want to look into creating one with an external library and then after that can look into refactoring all tables/or make the one under Just tell me what you prefer, honestly :D im down for both |
Those are to indicate there are more pages. But it appears to not work correctly when there are less than 5 pages. I'll investigate and make a seperate issue for that. As for now, I think it's best to keep it uniform, and then do a complete refactor after some proof of concept later. That should be handled in #3 and is out of scope for this issue. |
I just implemented it for the Event leaderboards, but in a way that it can be used everywhere basically, so kinda tackling #3 as well. All the functionality is there, searching, navigation, and working flawlessly, even debounced the search for 1s (so we dont permanently change the view, think #4 has this issue as well) The only thing im not too happy about is the positioning, cause I like it more if its under the table, but if the table gets too long its kinda annoying,
so maybe we can start a discussion what fits the best / what UI we want, but the functionality exists now 🤷 . |
https://github.com/christofkern/therun-frontend/tree/pagination_overhaul |
Hey! Thanks so much for the effort. Your code looks great! However, as I mentioned yesterday, I don't see the benefit in a new pagination solution. The point of this issue was to just reuse the current pagination logic that's used in other components, to avoid that there are simultaneously 2 seperate pagination solutions. Afterward, in #3, it's the idea to completely overhaul every table with new pagination/searching/sorting, but to use a prebuilt solution, for example something like https://www.npmjs.com/package/react-data-table-component, which has every functionality we'd ever need and more out of the box. Let me know your thoughts and how you view this :)! |
i agree, I just wasnt that aware of what is out there. Heres an implementation with the react data table component library. In general it looks quite clean, and was very easy to implement. so why not :D |
The leaderboards have no pagination, and are sometimes 200+ users long, so that becomes a bit of a mess. They could use searching and pagination. See other tables with pagination and searching (eg tournament runs) for examples
The text was updated successfully, but these errors were encountered: