Skip to content

Commit

Permalink
Merge pull request #3059 from ClickHouse/mw-fix-search-crash
Browse files Browse the repository at this point in the history
Mw fix search crash
  • Loading branch information
gjones authored Jan 8, 2025
2 parents eb7dddb + 4aea657 commit f7cbb6e
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/theme/SearchBar/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,7 @@ import {DocSearchButton, useDocSearchKeyboardEvents} from '@docsearch/react';
import Head from '@docusaurus/Head';
import Link from '@docusaurus/Link';
import {useHistory} from '@docusaurus/router';
import {isRegexpStringMatch} from '@docusaurus/theme-common';
import {useSearchPage} from '@docusaurus/theme-common/internal';
import {isRegexpStringMatch, useSearchLinkCreator} from '@docusaurus/theme-common';
import {
useAlgoliaContextualFacetFilters,
useSearchResultUrlProcessor,
Expand All @@ -18,7 +17,7 @@ function Hit({hit, children}) {
return <Link to={hit.url}>{children}</Link>;
}
function ResultsFooter({state, onClose}) {
const {generateSearchPageLink} = useSearchPage();
const generateSearchPageLink = useSearchLinkCreator();
return (
<Link to={generateSearchPageLink(state.query)} onClick={onClose}>
<Translate
Expand Down

0 comments on commit f7cbb6e

Please sign in to comment.