({
size = "md",
isBrand,
framed,
className,
}: {
size?: "md" | "lg";
isBrand?: boolean;
framed?: boolean;
className?: string;
})
| 5 | import { PaginationDot } from "@/components/application/pagination/pagination-dot"; |
| 6 | |
| 7 | export const CarouselIndicator = ({ |
| 8 | size = "md", |
| 9 | isBrand, |
| 10 | framed, |
| 11 | className, |
| 12 | }: { |
| 13 | size?: "md" | "lg"; |
| 14 | isBrand?: boolean; |
| 15 | framed?: boolean; |
| 16 | className?: string; |
| 17 | }) => { |
| 18 | const { selectedIndex, scrollSnaps, api } = useCarousel(); |
| 19 | |
| 20 | return ( |
| 21 | <PaginationDot |
| 22 | size={size} |
| 23 | framed={framed} |
| 24 | isBrand={isBrand} |
| 25 | page={selectedIndex + 1} |
| 26 | total={scrollSnaps.length} |
| 27 | className={className} |
| 28 | onPageChange={(page) => { |
| 29 | api?.scrollTo(page - 1); |
| 30 | }} |
| 31 | /> |
| 32 | ); |
| 33 | }; |
| 34 | |
| 35 | export const CarouselMd = () => { |
| 36 | return ( |
nothing calls this directly
no test coverage detected