Components
Destination Carousel This component displays a horizontally scrollable carousel of destination cards. It's designed to be easily populated with data and includes a title, a "view all" link, and interactive cards with hover and entrance animations.
Loading preview...
import { DestinationCarousel, Destination } from "@/components/ui/destination-carousel";
// Sample data for the demo
const popularDestinations: Destination[] = [
{
id: "prague",
name: "Prague",
country: "Czech Republic",
imageUrl: "https://images.unsplash.com/photo-1705994082718-f11e37517bc4?w=900&auto=format&fit=crop&q=60&ixlib=rb-4.1.0&ixid=M3wxMjA3fDB8MHxzZWFyY2h8NHx8cHJhZ3VlJTIwYXN0cm9ub21pY2FsJTIwY2xvY2t8ZW58MHx8MHx8fDA%3D?w=800&q=80",
avgTicketPrice: 53,
currency: "EUR",
isFavorite: true,
},
{
id: "budapest",
name: "Budapest",
country: "Hungary",
imageUrl: "https://images.unsplash.com/photo-1616432902940-b7a1acbc60b3?w=900&auto=format&fit=crop&q=60&ixlib=rb-4.1.0&ixid=M3wxMjA3fDB8MHxzZWFyY2h8M3x8SHVuZ2FyeXxlbnwwfHwwfHx8MA%3D%3D?w=800&q=80",
avgTicketPrice: 44,
currency: "EUR",
},
{
id: "bratislava",
name: "Bratislava",
country: "Slovakia",
imageUrl: "https://images.unsplash.com/photo-1594502645146-919ab24010e8?w=900&auto=format&fit=crop&q=60&ixlib=rb-4.1.0&ixid=M3wxMjA3fDB8MHxzZWFyY2h8Nnx8U2xvdmFraWF8ZW58MHx8MHx8fDA%3D?w=800&q=80",
avgTicketPrice: 21,
currency: "EUR",
},
{
id: "rome",
name: "Rome",
country: "Italy",
imageUrl: "https://images.unsplash.com/photo-1552832230-c0197dd311b5?w=800&q=80",
avgTicketPrice: 78,
currency: "EUR",
isFavorite: true,
},
{
id: "paris",
name: "Paris",
country: "France",
imageUrl: "https://images.unsplash.com/photo-1499856871958-5b9627545d1a?w=900&auto=format&fit=crop&q=60&ixlib=rb-4.1.0&ixid=M3wxMjA3fDB8MHxzZWFyY2h8M3x8UGFyaXN8ZW58MHx8MHx8fDA%3D?w=800&q=80",
avgTicketPrice: 85,
currency: "EUR",
},
];
/**
* A demo page to showcase the DestinationCarousel component.
*/
const DestinationCarouselDemo = () => {
return (
<div className="w-full bg-background flex items-center justify-center py-10">
<DestinationCarousel
title="Popular from Vienna"
destinations={popularDestinations}
/>
</div>
);
};
export default DestinationCarouselDemo;