UNPKG

@payfit/unity-components

Version:

24 lines (23 loc) • 880 B
import { usePaginationContext as e } from "../PaginationContext.js"; import { forwardRef as t, useMemo as n } from "react"; import { uyTv as r } from "@payfit/unity-themes"; import { jsx as i } from "react/jsx-runtime"; import { useTranslation as a } from "react-i18next"; //#region src/core/components/pagination/parts/PaginationContent.tsx var o = r({ base: "uy:flex uy:gap-100 uy:list-none uy:m-0 uy:p-0" }), s = t(({ children: t, ...r }, s) => { let { t: c } = a("unity"), { pageCount: l, currentPage: u, a11yIds: d } = e(), f = c((e) => e.unity.component.pagination.pageList.label, { current: u, total: l }), p = n(() => o(), []); return /* @__PURE__ */ i("ul", { ...r, ref: s, id: d.pagesList, className: p, "aria-label": f, children: t }); }); s.displayName = "PaginationContent"; //#endregion export { s as PaginationContent, o as paginationContent };