ThatAIguyA world of ideas

THE CONSCIOUSNESS ATLAS
Read. Experiment. Follow the evidence.

ConsciousnessLearn · Explore · Joseph Anady

Janady13/llms-txt-hub / apps/web/components/ui/paginated-content.tsx

Source identity, revision, and recovered contents.

GitHub sourceSource text recovered

Source identity

FieldRecorded value
Source typeGitHub source
Original recordJanady13/llms-txt-hub / apps/web/components/ui/paginated-content.tsx
DateNot specified in source
RepositoryJanady13/llms-txt-hub
Revisione0f4bf978d4df168369c7601d9c5f5ea89e84377
Branchmain
Path or archive memberapps/web/components/ui/paginated-content.tsx
Original SHA-256e403356d778fbaad540c66675f546079f2a5866473f07dd56cf29a55d1bbe3ca
Git blob SHAb182be7e07a174a0cf9fec8c9796bf482f837082
Reading-copy SHA-256e403356d778fbaad540c66675f546079f2a5866473f07dd56cf29a55d1bbe3ca

Original source ↗

Recovered source transcript

'use client' import { useLoadMore } from '@/hooks/use-load-more' import { LoadMore } from './load-more' interface PaginatedContentProps<T> { items: T[] renderItem: (item: T, index: number) => React.ReactNode initialItemsPerPage?: number itemsPerLoad?: number loadMoreVariant?: 'button' | 'auto' | 'scroll' loadMoreText?: string noMoreText?: string containerClassName?: string itemsClassName?: string emptyState?: React.ReactNode threshold?: number } export function PaginatedContent<T>({ items, renderItem, initialItemsPerPage = 12, itemsPerLoad = 12, loadMoreVariant = 'button', loadMoreText = 'Load more', noMoreText = 'All items loaded', containerClassName = '', itemsClassName = 'grid grid-cols-1 sm:grid-cols-2 md:grid-cols-3 lg:grid-cols-4 gap-4', emptyState, threshold = 200 }: PaginatedContentProps<T>) { const { displayedItems, hasMore, isLoading, loadMore, showItemsCount, totalItemsCount } = useLoadMore({ items, initialItemsPerPage, itemsPerLoad }) if (items.length === 0 && emptyState) { return <div className={containerClassName}>{emptyState}</div> } return ( <div className={containerClassName}> {/* Items Grid/List */} <div className={itemsClassName}> {displayedItems.map((item, index) => renderItem(item, index))} </div> {/* Load More Component */} {(hasMore || loadMoreVariant !== 'scroll') && ( <LoadMore onLoadMore={loadMore} hasMore={hasMore} isLoading={isLoading} loadMoreText={loadMoreText} noMoreText={noMoreText} showItemsCount={showItemsCount} totalItemsCount={totalItemsCount} variant={loadMoreVariant} threshold={threshold} /> )} </div> ) } // Convenience wrapper for common website grid layout export function WebsitesPaginatedGrid<T>({ items, renderItem, ...props }: Omit<PaginatedContentProps<T>, 'itemsClassName'> & { items: T[] renderItem: (item: T, index: number) => React.ReactNode }) { return ( <PaginatedContent items={items} renderItem={renderItem} itemsClassName="grid grid-cols-1 sm:grid-cols-2 md:grid-cols-3 lg:grid-cols-4 xl:grid-cols-5 2xl:grid-cols-6 4xl:grid-cols-8 gap-4" {...props} /> ) }

Search equations, builds, manuscript text, and recovered sources.