-
Notifications
You must be signed in to change notification settings - Fork 51
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
Leader board UI #268
Leader board UI #268
Conversation
…ge as described in Figma
…con to notFoundJSX and some style fixes
Change direction he
Adding skeleton loading spinner in members page and Applying logic for member search in the input
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
@@ -26,6 +26,8 @@ async function fetchProjectsData({ | |||
}, | |||
body: JSON.stringify({ page, limit, filter }), | |||
}); | |||
console.log(); | |||
|
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.
Please remove this
<Monthly /> | ||
<h3 className=' text-left p-5'>Weekly Score </h3> | ||
<Weekly /> | ||
</div> |
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.
Can you insert the hard coded texts into our local files?
)} | ||
{members.length === 0 && searchTerm === '' && <SkeletonCards cards={6} />} | ||
{members.length === 0 && searchTerm !== '' && notFoundJSX} | ||
{members.length !== 0 && <MembersList members={members} />} |
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.
members.length === 0
and also searchTerm === ''
could be save into variables and from the value you could remove members.length !== 0
and searchTerm !== ''
(you can use ! operator on your variables)
// darkBg: colors.slate[950], | ||
// darkAccBg: colors.slate[800], | ||
// lightText: colors.slate[50], | ||
// discordDark: colors.white, |
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.
Remove comments
<div className='flex flex-col gap-10 '> | ||
<span>name: <span></span>{'roi'}</span> | ||
<span>additions: <><span className='text-green-500'>32</span></></span> | ||
<span>commits:</span> |
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.
Can you extract this as well to the translations file ?
export type Welcome = { | ||
data: Data; | ||
} | ||
|
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.
Cantyou use Data
instead of creating new type that using entire different type ?
additions?: number; | ||
deletions?: number; | ||
commits?: number; | ||
} |
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.
One question about this file :
Why are all the fields optional? don`t really make sense that no field in a type is a must.
> | ||
<Skeleton className="w-[30px] h-[30px] rounded-full bg-purple-100 dark:bg-slate-100/50" /> | ||
<Skeleton className="w-[30px] h-[30px] rounded-full bg-purple-100 dark:bg-slate-100/50" /> | ||
<Skeleton className="w-[30px] h-[30px] rounded-full bg-purple-100 dark:bg-slate-100/50" /> |
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.
I know its for testing but you can use map
to display lists based on array of data
<div className="flex mx-auto w-[90%] flex-wrap gap-4 mt-6 justify-between"> | ||
{cardsToRender.map(card => ( | ||
<SkeletonCard key={card} /> | ||
))} |
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.
Your key is the entire card object? can 2 cards be the same?
more work need to be done on leader board chart and and translate and connect translate light mod and dark mode adjustments