diff --git a/apps/web/src/pages/editing-planner/components/clip-properties/TitleSettingsSection.tsx b/apps/web/src/pages/editing-planner/components/clip-properties/TitleSettingsSection.tsx deleted file mode 100644 index 81e20b193..000000000 --- a/apps/web/src/pages/editing-planner/components/clip-properties/TitleSettingsSection.tsx +++ /dev/null @@ -1,136 +0,0 @@ -/** - * 标题设置区块 — #1789 - * 提供字号滑块、字体预设、位置、颜色等控制入口 - */ -import React from "react" -import type { TitleConfig } from "@/api/template-editor" -import { POSITION_OPTIONS, FONT_OPTIONS } from "@/pages/editing-planner/constants/clipProperties" - -interface TitleSettingsSectionProps { - config: TitleConfig - onChange: (config: TitleConfig | ((prev: TitleConfig) => TitleConfig)) => void -} - -const TITLE_COLOR_PRESETS = [ - "#ffffff", - "#000000", - "#ff4444", - "#ffaa00", - "#44ff44", - "#4488ff", - "#ff44ff", - "#ffff44", -] - -const TitleSettingsSection: React.FC = ({ config, onChange }) => { - const update = (partial: Partial) => { - onChange((prev: TitleConfig) => ({ ...prev, ...partial })) - } - - return ( -
-
- 📝 - 标题设置 -
- - {/* AI 自动选择开关 */} -
- AI 自动选择 -
update({ ai_auto_select: !config.ai_auto_select })} - > -
-
-
- - {!config.ai_auto_select && ( - <> - {/* 标题文本 */} -
- - update({ content: e.target.value })} - /> -
- - {/* 位置 */} -
- - -
- - {/* 字体预设 */} -
- - -
- - {/* 字号滑块 */} -
- -
- update({ font_size: Number(e.target.value) })} - /> - {config.font_size}px -
-
- - {/* 颜色 */} -
- -
- {TITLE_COLOR_PRESETS.map((color) => ( -
update({ font_color: color })} - /> - ))} - update({ font_color: e.target.value })} - /> -
-
- - )} -
- ) -} - -export default TitleSettingsSection