From 80473bcc063488132e4b4d33229ffff83b843dd4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=8C=97=E6=9E=B3?= <7854742+wang_rumeng@user.noreply.gitee.com> Date: Sat, 18 Oct 2025 16:20:01 +0800 Subject: [PATCH] =?UTF-8?q?overlay=E5=B1=9E=E6=80=A7=E5=BC=83=E7=94=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../create-video/CreateInput/ConfigPanel.tsx | 52 +++++++------- .../CreateInput/MobileConfigModal.tsx | 72 ++++++++++--------- .../CreateInput/PortraitAnimeSelector.tsx | 28 ++++---- .../CreateInput/VideoCreationForm.tsx | 50 +++++++------ 4 files changed, 103 insertions(+), 99 deletions(-) diff --git a/components/pages/create-video/CreateInput/ConfigPanel.tsx b/components/pages/create-video/CreateInput/ConfigPanel.tsx index a7d730d..0f8ceec 100644 --- a/components/pages/create-video/CreateInput/ConfigPanel.tsx +++ b/components/pages/create-video/CreateInput/ConfigPanel.tsx @@ -6,7 +6,7 @@ import { DownOutlined } from '@ant-design/icons'; import { WandSparkles, RectangleHorizontal, RectangleVertical } from 'lucide-react'; -import { Dropdown, Menu, Tooltip } from 'antd'; +import { Dropdown, Tooltip } from 'antd'; import { LanguageOptions, VideoDurationOptions } from './config-options'; import type { ConfigOptions, LanguageValue, VideoDurationValue } from './config-options'; import { PortraitAnimeSelector } from './PortraitAnimeSelector'; @@ -37,29 +37,17 @@ export const ConfigPanel = ({ isMobile = false, isDesktop = true, }: ConfigPanelProps) => { - /** Language dropdown menu */ - const languageMenu = ( - onConfigChange('language', key as LanguageValue)} - items={LanguageOptions.map((option) => ({ - key: option.value, - label: {option.label}, - }))} - /> - ); + /** Language dropdown menu items */ + const languageMenuItems = LanguageOptions.map((option) => ({ + key: option.value, + label: {option.label}, + })); - /** Duration dropdown menu */ - const durationMenu = ( - onConfigChange('videoDuration', key as VideoDurationValue)} - items={VideoDurationOptions.map((option) => ({ - key: option.value, - label: {option.label}, - }))} - /> - ); + /** Duration dropdown menu items */ + const durationMenuItems = VideoDurationOptions.map((option) => ({ + key: option.value, + label: {option.label}, + })); const currentLanguage = LanguageOptions.find((option) => option.value === configOptions.language); const currentDuration = configOptions.videoDuration === 'unlimited' ? 'auto' : configOptions.videoDuration; @@ -67,7 +55,14 @@ export const ConfigPanel = ({ return (
{/* Language selector */} - + onConfigChange('language', key as LanguageValue), + className: 'bg-[#1a1a1a] border border-white/10' + }} + trigger={['click']} + >
- + onConfigChange('language', key as LanguageValue), + className: 'bg-[#1a1a1a] border border-white/10 max-h-[300px] overflow-y-auto' + }} + trigger={['click']} + > @@ -239,7 +234,14 @@ export function MobileConfigModal({ > Portrait - + onConfigChange('pcode', key), + className: 'bg-[#1a1a1a] border border-white/10' + }} + trigger={['click']} + >
- } + menu={{ + items: [ + { + key: 'character', + icon: , + label: Character, + onClick: () => characterInputRef.current?.click(), + }, + { + key: 'scene', + icon: , + label: Scene, + onClick: () => sceneInputRef.current?.click(), + }, + { + key: 'prop', + icon: , + label: Prop, + onClick: () => propInputRef.current?.click(), + }, + ], + className: 'bg-[#1a1a1a] border border-white/10' + }} trigger={['click']} >