From 4acc0687324f42bab506e616f55ffcf2866bf13b Mon Sep 17 00:00:00 2001 From: Local Administrator Date: Fri, 26 Jun 2026 23:17:50 +0000 Subject: [PATCH] fix(forum): hide Ask AV Beat AI widget on Integration Room routes --- src/components/AskBBAI.tsx | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/components/AskBBAI.tsx b/src/components/AskBBAI.tsx index cd1316a..49d907f 100644 --- a/src/components/AskBBAI.tsx +++ b/src/components/AskBBAI.tsx @@ -1,6 +1,7 @@ "use client"; import { useEffect, useRef, useState } from "react"; +import { usePathname } from "next/navigation"; interface Msg { role: "user" | "assistant"; @@ -8,6 +9,7 @@ interface Msg { } export default function AskBBAI() { + const pathname = usePathname(); const [open, setOpen] = useState(false); const [input, setInput] = useState(""); const [busy, setBusy] = useState(false); @@ -32,6 +34,8 @@ export default function AskBBAI() { return () => document.removeEventListener("keydown", onKey); }, [open]); + if (pathname?.startsWith("/forum")) return null; + async function send() { const q = input.trim(); if (!q || busy) return;