Skip to content

Commit

Permalink
debug: show search terms
Browse files Browse the repository at this point in the history
  • Loading branch information
drew-harris committed Dec 21, 2024
1 parent e699f32 commit c56ebe7
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions clients/search-component/src/TrieveModal/Search/PdfItem.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ import { FileDTO } from "trieve-ts-sdk";
import { useModalState } from "../../utils/hooks/modal-context";
import { cached } from "../../utils/cache";
import { PdfSpotlight } from "react-pdf-spotlight";
import { file } from "bun";

type Props = {
item: PdfChunk;
Expand Down Expand Up @@ -69,19 +68,20 @@ export const PdfItem = (props: Props) => {
}, []);

return (
<div>
<div className="flex gap-2 bg-red-500">
{presigned && (
<div className="max-w-[400px]">
<PdfSpotlight
padding={{
horizontal: 100,
}}
page={props.item.chunk.metadata.page}
searchFor={toHighlight}
searchFor={toHighlight.toLowerCase()}
url={presigned}
></PdfSpotlight>
</div>
)}
<div>{toHighlight.toLowerCase()}</div>
</div>
);
};

0 comments on commit c56ebe7

Please sign in to comment.