// PromptBar.jsx — the §8.1 prompt-bar at the bottom of the center column. // // In discuss mode the contributor types to talk; in contribute mode the // model is told to lean toward concrete edits. A passage highlighted in // the editor surfaces here as a "scoped to selection" badge and travels // to the backend with the message. import { useState } from 'react' import ModelPicker from './ModelPicker.jsx' export default function PromptBar({ selection, onSubmit, disabled, models, selectedModel, onModelChange, discussMode = false, placeholder, }) { const [prompt, setPrompt] = useState('') const handleSubmit = () => { if (!prompt.trim() || disabled) return onSubmit(prompt.trim(), selection) setPrompt('') } return (