Skip to content
This repository has been archived by the owner on Aug 7, 2024. It is now read-only.

[Updated] UserTestimonial.js | Solved Issue #2444 #2503

Merged
merged 12 commits into from
Dec 30, 2022
Merged
12 changes: 4 additions & 8 deletions components/user/UserTestimonials.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,14 +12,12 @@ export default function UserTestimonials({ users, data, BASE_URL }) {
url: `${BASE_URL}/${testimonial.username}`,
};
}

return {
...testimonial,
url: `https://github.com/${testimonial.username}`,
eddiejaoude marked this conversation as resolved.
Show resolved Hide resolved
};
});

return (
return (
<>
{!data.testimonials && (
<Alert type="info" message="No testimonials found" />
Expand All @@ -31,11 +29,9 @@ export default function UserTestimonials({ users, data, BASE_URL }) {
key={key}
>
<div className="flex-none p-6">
<img
src={`https://github.com/${testimonial.username}.png`}
alt={testimonial.username}
className="h-20 w-20 rounded-full bg-gray-100"
/>
<a href={testimonial.url} target="_blank" rel="noreferrer">
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great 👍

<img src={`https://github.com/${testimonial.username}.png`} alt={testimonial.username} className="h-20 w-20 rounded-full bg-gray-100"/>
</a>
</div>
<div className="flex-1 p-6">
<h3 className="font-medium text-gray-900">{testimonial.title}</h3>
Expand Down