Skip to content

Build your personal knowledge base with Trilium Notes

ui/pager: add support for custom CSS class

Adorian Doran8edf5483a62e
diff --git a/apps/client/src/widgets/collections/Pagination.tsx b/apps/client/src/widgets/collections/Pagination.tsx
index 26d22215cb..f42b477e88 100644
--- a/apps/client/src/widgets/collections/Pagination.tsx
+++ b/apps/client/src/widgets/collections/Pagination.tsx
@@ -10,6 +10,7 @@ import "./Pagination.css";
import clsx from "clsx";
interface PaginationContext {
+ className?: string;
page: number;
setPage: Dispatch<StateUpdater<number>>;
pageNotes?: FNote[];
@@ -18,11 +19,11 @@ interface PaginationContext {
totalNotes: number;
}
-export function Pager({ page, pageSize, setPage, pageCount, totalNotes }: Omit<PaginationContext, "pageNotes">) {
+export function Pager({ className, page, pageSize, setPage, pageCount, totalNotes }: Omit<PaginationContext, "pageNotes">) {
if (pageCount < 2) return;
return (
- <div className="note-list-pager-container">
+ <div className={clsx("note-list-pager-container", className)}>
<div className="note-list-pager">
<ActionButton
icon="bx bx-chevron-left"