forked from phoenix/litellm-mirror
fix import and add fallback
This commit is contained in:
parent
c54f23f936
commit
8a45abb563
1 changed files with 36 additions and 36 deletions
|
@ -24,7 +24,7 @@ export default function SearchBarWrapper(props) {
|
|||
import("@getcanary/web/components/canary-content"),
|
||||
import("@getcanary/web/components/canary-search"),
|
||||
import("@getcanary/web/components/canary-search-input"),
|
||||
import("@getcanary/web/components/canary-search-results"),
|
||||
import("@getcanary/web/components/canary-search-results-group"),
|
||||
import("@getcanary/web/components/canary-footer"),
|
||||
import("@getcanary/web/components/canary-callout-calendly"),
|
||||
import("@getcanary/web/components/canary-callout-discord"),
|
||||
|
@ -33,10 +33,6 @@ export default function SearchBarWrapper(props) {
|
|||
.catch(console.error);
|
||||
}, []);
|
||||
|
||||
if (!loaded || !path) {
|
||||
return null;
|
||||
}
|
||||
|
||||
return (
|
||||
<div
|
||||
style={{
|
||||
|
@ -46,6 +42,9 @@ export default function SearchBarWrapper(props) {
|
|||
gap: "6px",
|
||||
}}
|
||||
>
|
||||
{!loaded || !path ? (
|
||||
<span style={{ fontSize: "2rem" }}>🐤</span>
|
||||
) : (
|
||||
<canary-root framework="docusaurus">
|
||||
<canary-provider-pagefind
|
||||
options={JSON.stringify({ ...options, path })}
|
||||
|
@ -77,6 +76,7 @@ export default function SearchBarWrapper(props) {
|
|||
</canary-modal>
|
||||
</canary-provider-pagefind>
|
||||
</canary-root>
|
||||
)}
|
||||
|
||||
<SearchBar {...props} />
|
||||
</div>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue