From ad8d1f8fdd41d178de1ee3bcb039fea73bbb1193 Mon Sep 17 00:00:00 2001 From: Wilaz Date: Tue, 26 Mar 2024 18:46:52 -0400 Subject: [PATCH] fix: :bug: Removed window.ai in the tauri build Removed window.ai as an option in the tauri build becuase it is based on a browser extention and as such is unusable in the tauri build --- src/components/settings/ChatbotBackendPage.tsx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/components/settings/ChatbotBackendPage.tsx b/src/components/settings/ChatbotBackendPage.tsx index deea5b1e..75cd23f7 100644 --- a/src/components/settings/ChatbotBackendPage.tsx +++ b/src/components/settings/ChatbotBackendPage.tsx @@ -3,12 +3,13 @@ import { useEffect, useState } from 'react'; import { getWindowAI } from "window.ai"; import { BasicPage, Link, FormRow, getLinkFromPage } from './common'; import { updateConfig } from "@/utils/config"; +import { isTauri } from "@/utils/isTauri"; const chatbotBackends = [ {key: "echo", label: "Echo"}, {key: "chatgpt", label: "ChatGPT"}, {key: "llamacpp", label: "LLama.cpp"}, - {key: "windowai", label: "Window.ai"}, + ...isTauri() ? [] : [{key: "windowai", label: "Window.ai"}], // Hides Window.ai when using the desktop app {key: "ollama", label: "Ollama"}, {key: "koboldai", label: "KoboldAI"}, ];