/** * @license * SPDX-License-Identifier: Apache-2.0 */ import React, { useState } from 'react'; import InitialInputForm from './InitialInputForm'; import AiCoPilotPanel from './AiCoPilotPanel'; import type { InitialInput, ActiveEditor } from '../lib/types'; interface ControlPanelProps { onGenerate: (formData: InitialInput) => void; onClear: () => void; activeEditor: ActiveEditor | null; onRefine: (instruction: string) => void; isGenerating: boolean; isRefining: boolean; } type Tab = 'setup' | 'copilot'; export default function ControlPanel({ onGenerate, onClear, activeEditor, onRefine, isGenerating, isRefining }: ControlPanelProps) { const [activeTab, setActiveTab] = useState('setup'); return (
{activeTab === 'setup' && ( )} {activeTab === 'copilot' && ( )}
); }