From 051f38c49c96360553704ac9901a5415d79f1745 Mon Sep 17 00:00:00 2001 From: Kamran Ahmed Date: Mon, 30 Jun 2025 22:50:20 +0100 Subject: [PATCH] Improve review carousel --- .../SQLCourseVariant/ReviewCarousel.tsx | 134 ++++++++++-------- 1 file changed, 78 insertions(+), 56 deletions(-) diff --git a/src/components/SQLCourseVariant/ReviewCarousel.tsx b/src/components/SQLCourseVariant/ReviewCarousel.tsx index 5533fbd3a..6412ad1de 100644 --- a/src/components/SQLCourseVariant/ReviewCarousel.tsx +++ b/src/components/SQLCourseVariant/ReviewCarousel.tsx @@ -24,8 +24,8 @@ type Review = { export function ReviewCarousel() { const reviews: Review[] = [ { - companyName: 'roadmapsh.sh', - companyLogo: 'https://roadmap.sh/images/brand.png', + companyName: 'Cloud Camping', + companyLogo: 'https://assets.roadmap.sh/guest/cloudcamping-mcpl6.jpeg', name: 'Robin Wieruch', role: 'Author - Multiple Best-Sellers', rating: 5, @@ -37,8 +37,8 @@ export function ReviewCarousel() { isProminent: true, }, { - companyName: 'Maily', - companyLogo: 'https://maily.to/brand/logo.png', + companyName: 'Hack Mamba', + companyLogo: 'https://assets.roadmap.sh/guest/hackmbamba-h0ivr.jpeg', name: 'William Imoh', role: 'Founder and Data Enthusiast', rating: 5, @@ -50,22 +50,42 @@ export function ReviewCarousel() { isProminent: true, }, { - companyName: 'roadmapsh.sh', - companyLogo: 'https://roadmap.sh/images/brand.png', - name: 'Tomáš Janků', + companyName: 'GlobalLogic', + companyLogo: + 'https://assets.roadmap.sh/guest/globallogic_logo-3m3ho.jpeg', + name: 'Martina Milagros', role: 'Software Engineer', rating: 5, + text: [ + 'Thanks to Kamran Ahmed for the **incredible Master SQL course!** I truly appreciate the way you break down complex topics with such clarity and ease.', + '**Highly recommend this course** to anyone looking to level up their SQL game!', + ], + avatarUrl: 'https://assets.roadmap.sh/guest/martina-awc4x.jpeg', + }, + { + companyName: 'Cisco', + companyLogo: 'https://assets.roadmap.sh/guest/cisco-gyw5b.jpeg', + name: 'Tomáš Janků', + role: 'Sr. Software Engineer', + rating: 5, text: "The course and it's interactivity is excellent and I'd honestly say it's **one of the best** on the SQL theme I've seen out there.", avatarUrl: 'https://assets.roadmap.sh/guest/tomas-janku-6bg89.jpeg', }, { + companyName: 'Beyond Works', + companyLogo: + 'https://assets.roadmap.sh/guest/beyondwordsio_logo-xia4m.jpeg', name: 'Gourav Khunger', role: 'Software Engineer', rating: 5, - text: 'This course was **absolutely brilliant!** The integrated database environment to practice what I learned was the best part.', + text: [ + 'This course was **absolutely brilliant!** The integrated database environment to practice what I learned was the best part. Being able to **run queries immediately** and see results in real-time made everything click so much faster than traditional learning methods.', + ], avatarUrl: 'https://assets.roadmap.sh/guest/gourav-h2f3a.png', }, { + companyName: 'xpertSea', + companyLogo: 'https://assets.roadmap.sh/guest/xpertsea-y24hu.jpeg', name: 'Meabed', role: 'CTO', rating: 5, @@ -73,6 +93,8 @@ export function ReviewCarousel() { avatarUrl: 'https://assets.roadmap.sh/guest/meabed-fu83q.jpeg', }, { + companyName: 'Powersoft19', + companyLogo: 'https://assets.roadmap.sh/guest/powersoft19-sk4t1.jpeg', name: 'Mohsin Aheer', role: 'Sr. Software Engineer', rating: 5, @@ -80,20 +102,27 @@ export function ReviewCarousel() { avatarUrl: 'https://assets.roadmap.sh/guest/mohsinaheer-szchu.jpeg', }, { - name: 'Reeve Tee', - role: 'Software Engineer', - rating: 5, - text: 'I found the course **highly comprehensive and incredibly valuable**. I would love to see more courses like this!', - avatarUrl: '', - }, - { + companyName: 'xpertSea', + companyLogo: 'https://assets.roadmap.sh/guest/xpertsea-y24hu.jpeg', name: 'Zeeshan', role: 'Sr. Software Engineer', rating: 5, - text: 'Loved the teaching style and the way the course was structured. The **AI tutor was a great help** when I got stuck.', + text: 'Loved the teaching style and the way the course was structured. The **AI tutor was a great help** when I wanted some extra help.', avatarUrl: 'https://assets.roadmap.sh/guest/ziishaned-qjepj.png', }, { + companyName: 'University of Regensburg', + companyLogo: + 'https://assets.roadmap.sh/guest/university_of_regensburg_logo-01784.jpeg', + name: 'Faisal Ahsan', + role: 'Software Engineer', + rating: 5, + text: 'The course and the learning experience was great. What I really liked was the **no-fluff explanations** and **practical examples**.', + avatarUrl: 'https://assets.roadmap.sh/guest/faisal-q78p2.jpeg', + }, + { + companyName: 'xpertSea', + companyLogo: 'https://assets.roadmap.sh/guest/xpertsea-y24hu.jpeg', name: 'Adnan Ahmed', role: 'Engineering Manager', rating: 5, @@ -107,13 +136,6 @@ export function ReviewCarousel() { text: "Best SQL course I've taken. The progression from basic to advanced concepts is **well thought out**, and the challenges are **excellent**.", avatarUrl: 'https://assets.roadmap.sh/guest/kalvin-d65ol.jpeg', }, - { - name: 'Faisal Ahsan', - role: 'Software Engineer', - rating: 5, - text: 'The course and the learning experience was great. What I really liked was the **no-fluff explanations** and **practical examples**.', - avatarUrl: 'https://assets.roadmap.sh/guest/faisal-q78p2.jpeg', - }, ]; const [batchSize, setBatchSize] = useState(3); @@ -185,48 +207,18 @@ export function ReviewCarousel() { /> -
+
{currentBatch.map((review, index) => (
- {review?.companyName && ( -
- {review?.companyLogo && ( - {review?.companyName} - )} - -
- {review?.companyName} -
-
- )} - -
- {(typeof review.text === 'string' - ? [review.text] - : review.text - ).map((text, index) => ( -

- ))} -

-
+
{review.avatarUrl && (
+ +
+ {(typeof review.text === 'string' + ? [review.text] + : review.text + ).map((text, index) => ( +

+ ))} +

+ + {review?.companyName && ( +
+ {review?.companyLogo && ( + {review?.companyName} + )} +
+ {review?.companyName} +
+
+ )}
))}