Design comparison
SolutionDesign
Solution retrospective
To achieve the "staggering" effect on reviews and cards elements I just passed some styles conditionally like this, is there a better way?
<div className="flex w-full flex-col items-center gap-4 md:items-end">
{reviews.map((review, i) => (
<div
className={clsx("w-full", {
"lg:mr-[80px]": i === 0,
"lg:mr-[40px]": i === 1,
"lg:mr-0": i === 2,
})}
key={i}
>
<SocialProofReviewSummary {...review} />
</div>
))}
</div>
Community feedback
Please log in to post a comment
Log in with GitHubJoin our Discord community
Join thousands of Frontend Mentor community members taking the challenges, sharing resources, helping each other, and chatting about all things front-end!
Join our Discord