From 7d471940cdc3b36c35e53082107788ab3aebb5b0 Mon Sep 17 00:00:00 2001 From: Kevin Stadler Date: Mon, 23 Sep 2024 11:47:23 +0200 Subject: [PATCH] fix: remove search result pagination (addresses #2) --- app/search/instantsearch.tsx | 22 +--------------------- 1 file changed, 1 insertion(+), 21 deletions(-) diff --git a/app/search/instantsearch.tsx b/app/search/instantsearch.tsx index 0fc034d..8ff1b1f 100644 --- a/app/search/instantsearch.tsx +++ b/app/search/instantsearch.tsx @@ -3,15 +3,7 @@ import type { StateMapping, UiState } from "instantsearch.js"; import { type MessageKeys, useTranslations } from "next-intl"; import type { ReactNode } from "react"; -import { - Configure, - Hits, - Pagination, - RefinementList, - SearchBox, - SortBy, - Stats, -} from "react-instantsearch"; +import { Configure, Hits, RefinementList, SearchBox, SortBy } from "react-instantsearch"; import { InstantSearchNext } from "react-instantsearch-nextjs"; import TypesenseInstantSearchAdapter, { type SearchClient } from "typesense-instantsearch-adapter"; @@ -86,7 +78,6 @@ const stateMapping: StateMapping = { const uiState = { [collectionName]: { query: routeState.q, - page: routeState.page, refinementList: {}, sortBy: routeState.sort ? `${collectionName}/sort/${routeState.sort}` : undefined, }, @@ -172,17 +163,6 @@ export function InstantSearch() { return ; }} /> -
- - -
);