Showcase

Pages people have made, each on a card with its picture and its name and category under it, on a carousel that loops round the one in the middle, the ones beside it running to the band's edges. With an interval it moves on by itself while it is on screen and no pointer or focus is on it.

Your headline goes here

A short line about the pages goes here.

The first site
Site 1
A line about it
The second site
Site 2
A line about it
The third site
Site 3
A line about it
The fourth site
Site 4
A line about it
The fifth site
Site 5
A line about it
import { Showcase, type ShowcaseItem } from "@produkto/ui/Showcase";

const items: ShowcaseItem[] = [
  {
    title: "Site 1",
    description: "A line about it",
    src: "https://picsum.photos/id/42/1200/1500",
    alt: "The first site",
  },
  {
    title: "Site 2",
    description: "A line about it",
    src: "https://picsum.photos/id/48/1200/1500",
    alt: "The second site",
  },
  {
    title: "Site 3",
    description: "A line about it",
    src: "https://picsum.photos/id/60/1200/1500",
    alt: "The third site",
  },
  {
    title: "Site 4",
    description: "A line about it",
    src: "https://picsum.photos/id/180/1200/1500",
    alt: "The fourth site",
  },
  {
    title: "Site 5",
    description: "A line about it",
    src: "https://picsum.photos/id/201/1200/1500",
    alt: "The fifth site",
  },
];

const Example = () => (
  <Showcase
    align="center"
    title="Your headline goes here"
    description="A short line about the pages goes here."
    items={items}
    interval={5000}
    className="w-full"
  />
);

export default Example;

Usage

import { Showcase, type ShowcaseItem } from "@produkto/ui/Showcase";
const items: ShowcaseItem[] = [
  { title: "Site 1", description: "A line about it", src: "/one.webp", alt: "The first site", link: "/one" },
  { title: "Site 2", src: "/two.webp", alt: "The second site" },
];

<Showcase align="center" title="Your headline goes here" items={items} interval={5000} />

API Reference

Showcase

ShowcaseProps · blocks/Showcase/Showcase.types.ts
PropTypeDefault
itemsShowcaseItem[]-
intervalnumber-
idstring-
eyebrowstring-
titleReactNode-
descriptionReactNode-
alignSectionAlign"start" | "center" | "end""start"
mutedboolean-
classNamestring-

ShowcaseItem

used by items
PropTypeDefault
titlerequiredstring-
descriptionstring-
srcrequiredstring-
altrequiredstring-
linkstring-