product-card-13-block
stackzero/product-card-13-blockFreeBlock
stackzero publishes no description for this item.
Install it
npx shadcn@latest add https://ui.stackzero.co/r/product-card-13-block.jsonSource
1"use client";23import ImageViewer from "@/components/commerce-ui/image-viewer-basic";4import PriceFormat_Sale from "@/components/commerce-ui/price-format-sale";5import StarRating_Fractions from "@/components/commerce-ui/star-rating-fractions";6import { Button } from "@/components/ui/button";7import {8 BadgeCheck,9 Calendar,10 Heart,11 MapPin,12 Shield,13 Users,14} from "lucide-react";15import { useState } from "react";1617const DEFAULT_IMAGE_URL =18 "https://raw.githubusercontent.com/stackzero-labs/ui/refs/heads/main/public/placeholders/family-01.jpg";1920interface ProductCard_13Props {21 imageUrl?: string;22 featuredProperty?: boolean;23 hotelName?: string;24 description?: string;25 pricePerNight?: number;26 originalPricePerNight?: number;27 availableRooms?: number;28 location?: string;29 distanceFromCenter?: string;30 rating?: number;31 reviewCount?: number;32 amenities?: string[];33 specialOffers?: string[];34 onBookNow?: () => void;35 onViewDetails?: () => void;36 currencyPrefix?: string;37 limitedDeal?: boolean;38 roomsAtCurrentPrice?: number;39}4041function ProductCard_13({42 amenities = [43 "Free Wi-Fi",44 "Breakfast included",45 "Swimming pool",46 "Fitness center",47 ],48 availableRooms = 5,49 currencyPrefix = "$",50 description = "Contemporary hotel featuring elegant rooms with city views, restaurant serving local cuisine, and a rooftop terrace with panoramic views. Located in the vibrant downtown area.",51 distanceFromCenter = "1.2 km from centre",52 featuredProperty = true,53 hotelName = "Grand Azure Hotel & Spa",54 imageUrl = DEFAULT_IMAGE_URL,55 limitedDeal = true,56 location = "Downtown, New York",57 onBookNow = () => {},58 onViewDetails = () => {},59 originalPricePerNight = 249,60 pricePerNight = 199,61 rating = 4.5,62 reviewCount = 386,63 roomsAtCurrentPrice = 2,64 specialOffers = ["Free cancellation", "Pay at the property"],65}: ProductCard_13Props = {}) {66 const [isFavorite, setIsFavorite] = useState(false);67 const isLowAvailability = availableRooms <= 3;68 const hasDiscount = originalPricePerNight > pricePerNight;6970 const toggleFavorite = (e: React.MouseEvent) => {71 e.stopPropagation();72 setIsFavorite(!isFavorite);73 };7475 return (76 <div className="group flex flex-col overflow-hidden rounded-xl border border-gray-200 bg-white shadow-sm transition-all duration-300 hover:shadow-md sm:flex-row dark:border-gray-800 dark:bg-gray-900">77 {/* Image section */}78// … truncated
What it pulls in
npm packages
Other registry items
Files it writes
More from stackzero
All 112 items| Component | Registry | Kind | Access | Installs | Command |
|---|---|---|---|---|---|
| address-01-blockaddress-01-block | stackzero | Blocks | Free | 4 deps | |
| address-02-blockaddress-02-block | stackzero | Blocks | Free | 4 deps | |
| address-03-blockaddress-03-block | stackzero | Blocks | Free | 4 deps | |
| banner-01-blockbanner-01-block | stackzero | Blocks | Free | no deps | |
| banner-02-blockbanner-02-block | stackzero | Blocks | Free | no deps | |
| banner-03-blockbanner-03-block | stackzero | Blocks | Free | no deps | |
| banner-04-blockbanner-04-block | stackzero | Blocks | Free | no deps | |
| banner-05-blockbanner-05-block | stackzero | Blocks | Free | no deps |
