-
Notifications
You must be signed in to change notification settings - Fork 78
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
Sorting + Skeleton loading state #724
Conversation
This pull request is being automatically deployed with Vercel (learn more). 🔍 Inspect: https://vercel.com/metafam/the-game/6vJMvT6Neac1dLfd7czF7X1DYqaC |
Cool! Love the loading state. I did some testing on https://the-game-9t0xeliie-metafam.vercel.app/players and noticed a few things:
|
@alalonde please take a look at https://the-game-git-feat-sorting-metafam.vercel.app
This was something me and @davort came up with. Please suggest a better alternative if you have one in mind :)
This seems like an issue with caching. A refresh and it should work fine. Now it shows 1024 for both cases for me. |
Indeed, this was a low cost fix for showing seasonal XP, while still providing info on total XP in the same view. For the sake of clarity, we would have them show separately, and with accompanying text labels: And when sorted by total XP, show only If this isn't too much work, I'd suggest going with that. It will make the cards longer, since the XP metadata will most likely take up another row, if formatted like this. We may want to compensate by shortening the "ABOUT" text to three rows, so as to not elongate the cards further, and make scanning the page easier. Let me know your thoughts on this idea please, @alalonde and @dan13ram Finally, one thing I noticed, that happens for me at least, is that the cards in the same row aren't of the same height @dan13ram – is it just me or do you notice the same? If it's the same for you too, could you please take a look into that? |
Yup, this sounds good to me. Do we display what the current season is somewhere? A name, dates, etc |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good overall, I have some minor concerns about some of these shared components starting to do too much. Probably not worth blocking an approval / merge.
Apologies for the delay in review.
tagLabel = | ||
title.toLowerCase() === 'availability' ? `>${value.value}` : value.value; | ||
let title = selectTitle; | ||
if (title.toLowerCase() === 'availability' && value.length > 0) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This sort of logic should probably not be in a component in the design-system
package as those components are intended to be generic and reusable, no? Could you e.g. pass in the value of tagLabel
instead?
If I load the test site and click on "Sorted By" → "Seasonal XP", I get an error. 2021-08-09@06.08.11.mp4 |
The error comes up for all the sorting options when it's already checked. Also, can you make the dropdown close when selecting an option? |
I'll create a separate issue for the close on click. So this can be merged |
@alalonde @dysbulic @mquellhorst Thank you for your reviews! Apologies for taking this long to fix the PR. |
Closes #503