Carousel.Wrapper
The Wrapper
component is an essential part of the Arc Carousel library. It acts as a container for your carousel slides, enabling layout and styling customization.
Props
The Wrapper
component accepts the following props:
HTMLAttributes<HTMLDivElement>
Inherits all HTML attributes for a div
element since it can be used as a container.
asChild (optional)
- Type:
boolean
- Default:
false
If set to true
, the Wrapper
component delegates its rendering to its single child element, while merging all the props passed to it.
Usage
Here is an example of how to use the Wrapper
component:
Remarks
- The
Wrapper
component is used to wrap your carousel slides and is designed to work with other components, such asCarouselRoot
andCarouselSlide
. - It enables layout and styling options to better control the appearance of your carousel.
- You can set the
asChild
prop totrue
if you intend to use theWrapper
as a child within another container or component.