repositories
loading repo index
repositories
loading repo index
repository
loading code, commits, and activity
public Clawd ADK gateway launch mirror
stars
latest
clone command
git clone gitlawb://did:key:z6Mkq5mY...iFZ5/my-project-publ...git clone gitlawb://did:key:z6Mkq5mY.../my-project-publ...2fa351d6docs: add automaton and perps launch sources16d ago| #1 | import { ChevronLeft, ChevronRight } from "lucide-react"; |
| #2 | import { Button } from "@/components/ui/button"; |
| #3 | |
| #4 | interface MemoryPaginationProps { |
| #5 | currentPage: number; |
| #6 | totalPages: number; |
| #7 | setCurrentPage: (page: number) => void; |
| #8 | } |
| #9 | |
| #10 | export function MemoryPagination({ |
| #11 | currentPage, |
| #12 | totalPages, |
| #13 | setCurrentPage, |
| #14 | }: MemoryPaginationProps) { |
| #15 | return ( |
| #16 | <div className="flex items-center justify-between my-auto"> |
| #17 | <div className="flex items-center gap-2"> |
| #18 | <Button |
| #19 | variant="outline" |
| #20 | size="icon" |
| #21 | onClick={() => setCurrentPage(Math.max(currentPage - 1, 1))} |
| #22 | disabled={currentPage === 1} |
| #23 | > |
| #24 | <ChevronLeft className="h-4 w-4" /> |
| #25 | </Button> |
| #26 | <div className="text-sm"> |
| #27 | Page {currentPage} of {totalPages} |
| #28 | </div> |
| #29 | <Button |
| #30 | variant="outline" |
| #31 | size="icon" |
| #32 | onClick={() => setCurrentPage(Math.min(currentPage + 1, totalPages))} |
| #33 | disabled={currentPage === totalPages} |
| #34 | > |
| #35 | <ChevronRight className="h-4 w-4" /> |
| #36 | </Button> |
| #37 | </div> |
| #38 | </div> |
| #39 | ); |
| #40 | } |
| #41 |