Skip to content

Commit

Permalink
Enable adding custom providers in user settings
Browse files Browse the repository at this point in the history
  • Loading branch information
kliu57 committed Mar 30, 2024
1 parent 337f0f5 commit 5ee6dc5
Show file tree
Hide file tree
Showing 10 changed files with 743 additions and 184 deletions.
3 changes: 1 addition & 2 deletions src/components/Message/AppMessage/Instructions.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import {

import MessageBase, { type MessageBaseProps } from "../MessageBase";
import { ChatCraftAppMessage } from "../../../lib/ChatCraftMessage";
import { providerFromUrl, getSupportedProviders } from "../../../lib/providers";
import { providerFromUrl, supportedProviders } from "../../../lib/providers";
import { OpenRouterProvider } from "../../../lib/providers/OpenRouterProvider";
import RevealablePasswordInput from "../../RevealablePasswordInput";
import { useSettings } from "../../../hooks/use-settings";
Expand Down Expand Up @@ -57,7 +57,6 @@ function Instructions(props: MessageBaseProps) {
const { settings, setSettings } = useSettings();
const [isValidating, setIsValidating] = useState(false);
const [isInvalid, setIsInvalid] = useState(false);
const supportedProviders = getSupportedProviders();

// Override the text of the message
const message = new ChatCraftAppMessage({ ...props.message, text: ApiKeyInstructionsText });
Expand Down

0 comments on commit 5ee6dc5

Please sign in to comment.