From ef38b031d1d633d38794607e2919225514c94092 Mon Sep 17 00:00:00 2001 From: Timothy Lin Date: Sat, 2 Nov 2024 12:10:47 +0800 Subject: [PATCH] fix: remove dependency on algolia internal type --- .changeset/olive-ladybugs-perform.md | 5 +++++ packages/pliny/src/search/Algolia.tsx | 3 +-- 2 files changed, 6 insertions(+), 2 deletions(-) create mode 100644 .changeset/olive-ladybugs-perform.md diff --git a/.changeset/olive-ladybugs-perform.md b/.changeset/olive-ladybugs-perform.md new file mode 100644 index 0000000..1e20260 --- /dev/null +++ b/.changeset/olive-ladybugs-perform.md @@ -0,0 +1,5 @@ +--- +'pliny': minor +--- + +remove dependency on internal types diff --git a/packages/pliny/src/search/Algolia.tsx b/packages/pliny/src/search/Algolia.tsx index 953166c..429adc9 100644 --- a/packages/pliny/src/search/Algolia.tsx +++ b/packages/pliny/src/search/Algolia.tsx @@ -10,7 +10,6 @@ import type { DocSearchProps, DocSearchModalProps, } from '@docsearch/react' -import type { InternalDocSearchHit, StoredDocSearchHit } from '@docsearch/react/dist/esm/types' export type AlgoliaSearchProps = { algoliaConfig: DocSearchProps @@ -51,7 +50,7 @@ function Hit({ hit, children, }: { - hit: InternalDocSearchHit | StoredDocSearchHit + hit: Parameters>[0]['hit'] children: React.ReactNode }) { return {children}