Fix linter errors

This commit is contained in:
Alex Gleason committed 2025-07-20 15:31:29 -05:00
1 parent b832c5c6fd
commit fcf779fe35
15 files changed
+93 -70

No files matched your search

+1 -1
View File
@@ -7,7 +7,7 @@ import { ScrollArea } from '@/components/ui/scroll-area';
import { Card } from '@/components/ui/card';
import { Send, Bot, User, Settings, Play } from 'lucide-react';
import { cn } from '@/lib/utils';
import { useAISettings } from '@/contexts/AISettingsContext';
import { useAISettings } from '@/hooks/useAISettings';
import { FsToolSet } from '@/lib/FsToolSet';
import { useFS } from '@/hooks/useFS';
+2 -2
View File
@@ -1,4 +1,4 @@
import { useState, useEffect, useCallback } from 'react';
import { useState, useEffect, useCallback, useMemo } from 'react';
import { ProjectsManager } from '@/lib/fs';
import { useFS } from '@/hooks/useFS';
import { ChevronRight, ChevronDown, File, Folder } from 'lucide-react';
@@ -22,7 +22,7 @@ export function FileTree({ projectId, onFileSelect, selectedFile }: FileTreeProp
const [tree, setTree] = useState<FileNode[]>([]);
const [isLoading, setIsLoading] = useState(true);
const { fs } = useFS();
const projectsManager = new ProjectsManager(fs);
const projectsManager = useMemo(() => new ProjectsManager(fs), [fs]);
const buildFileTree = useCallback(async (projectId: string, dirPath: string): Promise<FileNode[]> => {
const items = await projectsManager.listFiles(projectId, dirPath);
+2 -2
View File
@@ -1,4 +1,4 @@
import { useState, useEffect, useCallback, useRef } from 'react';
import { useState, useEffect, useCallback, useRef, useMemo } from 'react';
import { ProjectsManager } from '@/lib/fs';
import { useFS } from '@/hooks/useFS';
import { Tabs, TabsContent } from '@/components/ui/tabs';
@@ -51,7 +51,7 @@ export function PreviewPane({ projectId, activeTab }: PreviewPaneProps) {
const [hasBuiltProject, setHasBuiltProject] = useState(false);
const iframeRef = useRef<HTMLIFrameElement>(null);
const { fs } = useFS();
const projectsManager = new ProjectsManager(fs);
const projectsManager = useMemo(() => new ProjectsManager(fs), [fs]);
const loadFileContent = useCallback(async (filePath: string) => {
setIsLoading(true);