diff --git a/app/components/chat/BaseChat.tsx b/app/components/chat/BaseChat.tsx
index f33114739..0421de126 100644
--- a/app/components/chat/BaseChat.tsx
+++ b/app/components/chat/BaseChat.tsx
@@ -24,16 +24,16 @@ const EXAMPLE_PROMPTS = [
{ text: 'How do I center a div?' },
];
-const providerList = [...new Set(MODEL_LIST.map((model) => model.provider))]
+const providerList = [...new Set(MODEL_LIST.map((model) => model.provider))];
const ModelSelector = ({ model, setModel, provider, setProvider, modelList, providerList }) => {
return (
-
);
@@ -81,10 +83,10 @@ interface BaseChatProps {
enhancingPrompt?: boolean;
promptEnhanced?: boolean;
input?: string;
- model: string;
- setModel: (model: string) => void;
+ model?: string;
+ setModel?: (model: string) => void;
provider: string;
- setProvider: (provider: string) => void;
+ setProvider?: (provider: string) => void;
handleStop?: () => void;
sendMessage?: (event: React.UIEvent, messageInput?: string) => void;
handleInputChange?: (event: React.ChangeEvent) => void;
@@ -144,7 +146,7 @@ export const BaseChat = React.forwardRef(
expires: 30, // 30 days
secure: true, // Only send over HTTPS
sameSite: 'strict', // Protect against CSRF
- path: '/' // Accessible across the site
+ path: '/', // Accessible across the site
});
} catch (error) {
console.error('Error saving API keys to cookies:', error);
@@ -281,7 +283,9 @@ export const BaseChat = React.forwardRef(
{input.length > 3 ? (
- Use Shift + Return for a new line
+ Use Shift +{' '}
+ Return for
+ a new line
) : null}
@@ -315,4 +319,4 @@ export const BaseChat = React.forwardRef(
);
},
-);
\ No newline at end of file
+);
diff --git a/app/lib/stores/workbench.ts b/app/lib/stores/workbench.ts
index 6a634897b..8589391c8 100644
--- a/app/lib/stores/workbench.ts
+++ b/app/lib/stores/workbench.ts
@@ -11,7 +11,7 @@ import { PreviewsStore } from './previews';
import { TerminalStore } from './terminal';
import JSZip from 'jszip';
import { saveAs } from 'file-saver';
-import { Octokit } from "@octokit/rest";
+import { Octokit, type RestEndpointMethodTypes } from "@octokit/rest";
import * as nodePath from 'node:path';
import type { WebContainerProcess } from '@webcontainer/api';
@@ -382,9 +382,10 @@ export class WorkbenchStore {
const octokit = new Octokit({ auth: githubToken });
// Check if the repository already exists before creating it
- let repo
+ let repo: RestEndpointMethodTypes["repos"]["get"]["response"]['data']
try {
- repo = await octokit.repos.get({ owner: owner, repo: repoName });
+ let resp = await octokit.repos.get({ owner: owner, repo: repoName });
+ repo = resp.data
} catch (error) {
if (error instanceof Error && 'status' in error && error.status === 404) {
// Repository doesn't exist, so create a new one