import clsx from "clsx"; import { Sparkles } from "lucide-react"; import { SHOW_COPILOT_MARQUEE } from "@/app/lib/feature_flags"; import Image from "next/image"; import mascot from "@/public/mascot.png"; export function ActionButton({ icon = null, children, onClick = undefined, disabled = false, primary = false, }: { icon?: React.ReactNode; children: React.ReactNode; onClick?: () => void | undefined; disabled?: boolean; primary?: boolean; }) { const onClickProp = onClick ? { onClick } : {}; return ; } interface PanelProps { title: React.ReactNode; subtitle?: string; icon?: React.ReactNode; rightActions?: React.ReactNode; actions?: React.ReactNode; children: React.ReactNode; maxHeight?: string; variant?: 'default' | 'copilot' | 'playground' | 'projects' | 'entity-list'; showWelcome?: boolean; className?: string; onClick?: () => void; tourTarget?: string; overflow?: 'hidden' | 'visible' | 'auto' | 'scroll' | undefined; } export function Panel({ title, subtitle, icon, rightActions, actions, children, maxHeight, variant = 'default', showWelcome = true, className, onClick, tourTarget, overflow, }: PanelProps) { const isEntityList = variant === 'entity-list'; return
{variant === 'projects' ? ( <>
{title}
{actions &&
{actions}
} ) : variant === 'copilot' ? (
{title}
{rightActions}
) : variant === 'playground' ? (
{title}
{rightActions}
) : isEntityList ? (
{title} {actions &&
{actions}
}
) : ( <> {title} {rightActions} )}
{(variant === 'projects' || isEntityList) ? (
{children}
) : ( children )}
; }