Carousel Item
DraftA carousel item component that displays individual slides within a carousel container, supporting content-based layouts and navigation.
Code
Install
npm install @fbin-web/neighborhood-core
Import
import { NbhdCarouselItem } from '@fbin-web/neighborhood-core';
Usage
<nbhd-carousel-item>
<nbhd-flex surface="secondary">
<nbhd-text
tag="h2"
variant="title"
>Slide 1</nbhd-text
>
<nbhd-text tag="p">This is the first slide.</nbhd-text>
<nbhd-link
href="go-to-this-link-1"
aria-label="Learn more about Slide 1"
>Learn More</nbhd-link
>
</nbhd-flex>
</nbhd-carousel-item>
Install
npm install @fbin-web/neighborhood-react
Import
import { NbhdCarouselItem } from '@fbin-web/neighborhood-react';
Usage
import { NbhdCarouselItem, NbhdFlex, NbhdText, NbhdLink } from '@fbin-web/neighborhood-react';
const App = () => (
<>
<NbhdCarouselItem>
<NbhdFlex surface="secondary">
<NbhdText
tag="h2"
variant="title">
Slide 1
</NbhdText>
<NbhdText tag="p">This is the first slide.</NbhdText>
<NbhdLink
href="go-to-this-link-1"
ariaLabel="Learn more about Slide 1">
Learn More
</NbhdLink>
</NbhdFlex>
</NbhdCarouselItem>
</>
);
Slots
| Name | Description |
|---|---|
(default) | The slide content passed through the carousel item wrapper. |