import { useEffect, useState } from "react" import type { CanvasBox } from "./types" const STYLE_OPTIONS = [ { id: "default", label: "Default" }, { id: "cinematic", label: "Cinematic" }, { id: "illustration", label: "Illustration" }, ] type PromptPanelProps = { box: CanvasBox | null defaultModel: string isGenerating?: boolean onPromptChange: (prompt: string) => void onModelChange: (modelId: string) => void onStyleChange: (styleId: string) => void onGenerate: () => void } export const PromptPanel = ({ box, defaultModel, isGenerating, onPromptChange, onModelChange, onStyleChange, onGenerate, }: PromptPanelProps) => { const [localPrompt, setLocalPrompt] = useState(box?.prompt ?? "") useEffect(() => { setLocalPrompt(box?.prompt ?? "") }, [box?.id, box?.prompt]) if (!box) { return (