Skip to content

Open-source Grok Bot alternative with a virtual machine that bots can use

test(find): type the onClose mock

hadan8977ba5c436d2cc2
diff --git a/src/components/ChatFindBar.ime.test.ts b/src/components/ChatFindBar.ime.test.ts
index 80623ad356..2e6c1e4642 100644
--- a/src/components/ChatFindBar.ime.test.ts
+++ b/src/components/ChatFindBar.ime.test.ts
@@ -19,12 +19,12 @@ import { ChatFindBar } from "./ChatFindBar";
let root: Root;
let host: HTMLDivElement;
-let onClose: ReturnType<typeof vi.fn>;
+let onClose: ReturnType<typeof vi.fn<() => void>>;
beforeEach(() => {
host = document.createElement("div");
document.body.append(host);
root = createRoot(host);
- onClose = vi.fn();
+ onClose = vi.fn<() => void>();
});
afterEach(() => {
flushSync(() => root.unmount());