import { useState, type PropsWithChildren } from 'react'; const ThoughtBox = ({ title, children }: PropsWithChildren<{ title: string }>) => { const [isExpanded, setIsExpanded] = useState(false); return (
setIsExpanded(!isExpanded)} className={` bg-bolt-elements-background-depth-2 shadow-md rounded-lg cursor-pointer transition-all duration-300 ${isExpanded ? 'max-h-96' : 'max-h-13'} overflow-auto border border-bolt-elements-borderColor `} >
{title}{' '} {!isExpanded && - Click to expand}
{children}
); }; export default ThoughtBox;