import { sanitizeComposedHostProps, type SafeComposedHostElementProps } from "../primitives/sanitize-composed-host-props";
import * as React from "react";
import { CaretLeftIcon, CaretRightIcon, DotsThreeIcon } from "@phosphor-icons/react";
import {
Anchor,
Button,
} from "../primitives";
import { cn } from "../../lib/utils";
function Pagination({ className, ...props }: SafeComposedHostElementProps<"nav">) {
return (
);
}
function PaginationContent({ className, ...props }: SafeComposedHostElementProps<"ul">) {
return (
);
}
function PaginationItem({ ...props }: SafeComposedHostElementProps<"li">) {
return ;
}
type PaginationLinkProps = {
isActive?: boolean;
size?: "default" | "icon";
} & Omit, "href"> & {
href: string;
};
function PaginationLink({
children,
className,
isActive,
ref,
size = "icon",
...props
}: PaginationLinkProps) {
return (
}
>
{children}
);
}
function PaginationPrevious({
className,
text = "Previous",
...props
}: React.ComponentProps & {
text?: string;
}) {
return (
{text}
);
}
function PaginationNext({
className,
text = "Next",
...props
}: React.ComponentProps & {
text?: string;
}) {
return (
{text}
);
}
function PaginationEllipsis({ className, ...props }: SafeComposedHostElementProps<"span">) {
return (
}
size="icon"
variant="ghost-muted"
>
More pages
);
}
export {
Pagination,
PaginationContent,
PaginationEllipsis,
PaginationItem,
PaginationLink,
PaginationNext,
PaginationPrevious,
};