File tree Expand file tree Collapse file tree 1 file changed +18
-1
lines changed
apps/webapp/app/components Expand file tree Collapse file tree 1 file changed +18
-1
lines changed Original file line number Diff line number Diff line change @@ -30,6 +30,7 @@ import {
3030 TooltipProvider ,
3131 TooltipTrigger ,
3232} from "./primitives/Tooltip" ;
33+ import { ClientOnly } from "remix-utils/client-only" ;
3334
3435function useKapaWebsiteId ( ) {
3536 const routeMatch = useTypedRouteLoaderData < typeof loader > ( "root" ) ;
@@ -44,7 +45,23 @@ export function AskAI() {
4445 return null ;
4546 }
4647
47- return < AskAIProvider websiteId = { websiteId } /> ;
48+ return (
49+ < ClientOnly
50+ fallback = {
51+ < Button
52+ variant = "small-menu-item"
53+ data-action = "ask-ai"
54+ hideShortcutKey
55+ data-modal-override-open-class-ask-ai = "true"
56+ disabled
57+ >
58+ < AISparkleIcon className = "size-5" />
59+ </ Button >
60+ }
61+ >
62+ { ( ) => < AskAIProvider websiteId = { websiteId } /> }
63+ </ ClientOnly >
64+ ) ;
4865}
4966
5067type AskAIProviderProps = {
You can’t perform that action at this time.
0 commit comments