diff --git a/src/app/document/view/[slug]/VersionChooser.tsx b/src/app/document/view/[slug]/VersionChooser.tsx index e3aee65..4ae62b3 100644 --- a/src/app/document/view/[slug]/VersionChooser.tsx +++ b/src/app/document/view/[slug]/VersionChooser.tsx @@ -27,7 +27,8 @@ const VersionChooser = ({ const fileEnding = file === 'other' ? '' : `.${file}` const [selectedRevision, setSelectedRevision] = useState(latest) // Initialize the selected revision with the latest revision - const notifyCopied = (content: string) => toast.success(`${content} copied to clipboard!`) + const notifyCopied = (content: string) => + toast.success(`${content} copied to clipboard!`) const handleClick = () => { const bibtex = `@article{ diff --git a/src/app/search/page.tsx b/src/app/search/page.tsx index e8f7d5c..3dbab29 100644 --- a/src/app/search/page.tsx +++ b/src/app/search/page.tsx @@ -74,7 +74,7 @@ export default function Page() { const router = useRouter() const searchParams = useSearchParams() const search = decodeURIComponent(searchParams.get('q') as string) - + let invalid = false if (search.toLowerCase().startsWith('eexiv')) { @@ -120,7 +120,7 @@ export default function Page() { {search} {`"`} - {(data.length === 0 || invalid) ? ( + {data.length === 0 || invalid ? (

No results found.

) : ( data.map((result) => ( diff --git a/src/app/utils/search.worker.ts b/src/app/utils/search.worker.ts index 67981fe..8a1f524 100644 --- a/src/app/utils/search.worker.ts +++ b/src/app/utils/search.worker.ts @@ -62,7 +62,7 @@ const serializeDoc = (key: string, value: Document) => ({ ) .join(' '), key: key, - doi: value.doi ? value.doi : undefined + doi: value.doi ? value.doi : undefined, }) onmessage = (e: MessageEvent) => { @@ -95,7 +95,9 @@ onmessage = (e: MessageEvent) => { } // converting the documents object into an array that can be index by minisearch - const docs = Object.entries(documents).map(([key, value]) => (serializeDoc(key, value))) + const docs = Object.entries(documents).map(([key, value]) => + serializeDoc(key, value) + ) miniSearch.addAll(docs) postMessage(miniSearch.search(e.data) as CustomSearchResult[])