"use client"; import { memo } from "react"; import { useTranslation } from "react-i18next"; import { summarizeMathAnimatorConfig, type MathAnimatorFormConfig, } from "@/lib/math-animator-types"; import { CollapsibleConfigSection, Field, INPUT_CLS, } from "@/components/chat/home/composer-field"; interface MathAnimatorConfigPanelProps { value: MathAnimatorFormConfig; onChange: (next: MathAnimatorFormConfig) => void; collapsed: boolean; onToggleCollapsed: () => void; } export default memo(function MathAnimatorConfigPanel({ value, onChange, collapsed, onToggleCollapsed, }: MathAnimatorConfigPanelProps) { const { t } = useTranslation(); const update = ( key: K, val: MathAnimatorFormConfig[K], ) => onChange({ ...value, [key]: val }); return ( update("style_hint", e.target.value)} placeholder={t("Style, pacing, color...")} className={`${INPUT_CLS} w-full`} /> ); });