diff --git a/binary/package-lock.json b/binary/package-lock.json index 7f603ec07..5e864aaf7 100644 --- a/binary/package-lock.json +++ b/binary/package-lock.json @@ -74,6 +74,7 @@ "http-proxy-agent": "^7.0.1", "https-proxy-agent": "^7.0.3", "ignore": "^5.3.1", + "is-localhost-ip": "^2.0.0", "jinja-js": "0.1.8", "js-tiktoken": "^1.0.8", "jsdom": "^24.0.0", diff --git a/gui/src/components/mainInput/AtMentionDropdown/index.tsx b/gui/src/components/mainInput/AtMentionDropdown/index.tsx index 269e4b042..b03bf3096 100644 --- a/gui/src/components/mainInput/AtMentionDropdown/index.tsx +++ b/gui/src/components/mainInput/AtMentionDropdown/index.tsx @@ -4,8 +4,8 @@ import { ChatBubbleLeftIcon, PlusIcon, } from "@heroicons/react/24/outline"; -import { Editor } from "@tiptap/react"; -import { RangeInFile } from "core"; +import type { Editor } from "@tiptap/react"; +import type { RangeInFile } from "core"; import { forwardRef, useContext, @@ -32,7 +32,7 @@ import SafeImg from "../../SafeImg"; import AddDocsDialog from "../../dialogs/AddDocsDialog"; import HeaderButtonWithToolTip from "../../gui/HeaderButtonWithToolTip"; import { NAMED_ICONS } from "../icons"; -import { ComboBoxItem, ComboBoxItemType } from "../types"; +import type { ComboBoxItem, ComboBoxItemType } from "../types"; export function getIconFromDropdownItem( id: string | undefined, @@ -509,7 +509,9 @@ const AtMentionDropdown = forwardRef((props: AtMentionDropdownProps, ref) => { ) : ( )} - {item.title} + + {item.title} + {" "} { color: lightGray, float: "right", textAlign: "right", - opacity: isSelected ? 1 : 0, + opacity: + subMenuTitle || item.type !== "contextProvider" + ? 1 + : isSelected + ? 1 + : 0, minWidth: "30px", }} className="ml-2 flex items-center overflow-hidden overflow-ellipsis whitespace-nowrap" diff --git a/gui/src/components/modelSelection/platform/AssistantSelect.tsx b/gui/src/components/modelSelection/platform/AssistantSelect.tsx index e2d6bc456..dae2136df 100644 --- a/gui/src/components/modelSelection/platform/AssistantSelect.tsx +++ b/gui/src/components/modelSelection/platform/AssistantSelect.tsx @@ -30,7 +30,7 @@ import { Transition, } from "../../ui"; -import { ProfileDescription } from "core/config/ConfigHandler"; +import type { ProfileDescription } from "core/config/ConfigHandler"; import { useNavigate } from "react-router-dom"; import { vscCommandCenterInactiveBorder } from "../.."; import { cn } from "../../../util/cn"; @@ -158,7 +158,7 @@ export default function AssistantSelect() { const orgs = useAppSelector((store) => store.profiles.organizations); const ideMessenger = useContext(IdeMessengerContext); const { isToolbarExpanded } = useLump(); - const [loading, setLoading] = useState(false) + const [loading, setLoading] = useState(false); const { profiles, session, login } = useAuth(); const navigate = useNavigate(); @@ -287,19 +287,24 @@ export default function AssistantSelect() { -
+
Assistants
{ e.stopPropagation(); - setLoading(true) - await refreshProfiles() - setLoading(false) + setLoading(true); + await refreshProfiles(); + setLoading(false); buttonRef.current?.click(); }} > - +