Components
Testimonial and review card component with author info, avatar, star rating, and quote styling. Perfect for displaying customer feedback and testimonials.
Loading preview...
import { ReviewCard, type Review } from "@/components/ui/review-card";
import * as React from "react"
const reviews: Review[] = [
{
author: "John Smith",
position: "Senior Developer",
company: "Tech Corp",
text: "Great communication skills and excellent code quality. Would definitely work with again.",
rating: 4,
avatar: "https://images.unsplash.com/photo-1507003211169-0a1dd7228f2d?w=150&h=150&fit=crop&crop=face",
},
{
author: "John Smith",
position: "CTO",
text: "Great communication skills and excellent code quality. Would definitely work with again.",
rating: 5,
avatar: "https://images.unsplash.com/photo-1472099645785-5658abf4ff4e?w=150&h=150&fit=crop&crop=face",
},
]
export default function ReviewCardDemo() {
return (
<div className="flex flex-col gap-6 p-6">
<h3 className="text-sm font-medium text-zinc-500">Review Cards</h3>
<div className="grid gap-6 md:grid-cols-2">
{reviews.map((review, index) => (
<ReviewCard key={index} review={review} />
))}
</div>
{/* Minimal Review */}
<h3 className="text-sm font-medium text-zinc-500 mt-4">Minimal</h3>
<ReviewCard
review={{
author: "Anonymous User",
text: "Simple and effective!",
rating: 4,
}}
className="max-w-sm"
/>
</div>
)
}