mirror of
https://github.com/HKUDS/DeepTutor.git
synced 2026-12-02 07:10:15 +08:00
- Add visualize agent pipeline (analysis → code generation → review) - Add VisualizeCapability with request config and registry wiring - Add frontend VisualizeConfigPanel, VisualizationViewer components - Add chart.js and react-chartjs-2 dependencies - Improve math_animator YON_IMAGE anchor block prompts (en/zh) - Add minimax model override (supports_response_format: false) - Suppress noisy uvicorn WebSocket connection logs - Add selective HTTP access logging middleware (non-200 only) Made-with: Cursor
36 lines
1.0 KiB
TypeScript
36 lines
1.0 KiB
TypeScript
"use client";
|
|
|
|
import { useTranslation } from "react-i18next";
|
|
import type { VisualizeFormConfig } from "@/lib/visualize-types";
|
|
import { Field, INPUT_CLS } from "@/components/chat/home/composer-field";
|
|
|
|
interface VisualizeConfigPanelProps {
|
|
value: VisualizeFormConfig;
|
|
onChange: (next: VisualizeFormConfig) => void;
|
|
}
|
|
|
|
export default function VisualizeConfigPanel({
|
|
value,
|
|
onChange,
|
|
}: VisualizeConfigPanelProps) {
|
|
const { t } = useTranslation();
|
|
|
|
return (
|
|
<div className="flex flex-wrap items-end gap-x-3 gap-y-2 px-3.5 py-2.5">
|
|
<Field label="Render Mode" width="w-[120px]">
|
|
<select
|
|
value={value.render_mode}
|
|
onChange={(e) =>
|
|
onChange({ ...value, render_mode: e.target.value as VisualizeFormConfig["render_mode"] })
|
|
}
|
|
className={`${INPUT_CLS} w-full`}
|
|
>
|
|
<option value="auto">{t("Auto")}</option>
|
|
<option value="chartjs">{t("Chart.js")}</option>
|
|
<option value="svg">{t("SVG")}</option>
|
|
</select>
|
|
</Field>
|
|
</div>
|
|
);
|
|
}
|