From fff358b2d88f696388fce0f525643102e6253f27 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: Tue, 14 Oct 2025 15:00:03 +0800 Subject: [PATCH] =?UTF-8?q?-=20[=20]=20H5=E7=94=9F=E6=88=90=E5=AE=8C?= =?UTF-8?q?=E6=88=90=E4=B8=8D=E6=98=BE=E7=A4=BA=E8=BF=9B=E5=BA=A6=E6=9D=A1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- components/pages/work-flow.tsx | 3 ++- components/pages/work-flow/H5MediaViewer.tsx | 24 ++++++++++++++++---- 2 files changed, 21 insertions(+), 6 deletions(-) diff --git a/components/pages/work-flow.tsx b/components/pages/work-flow.tsx index 8bf7ab5..2947e6a 100644 --- a/components/pages/work-flow.tsx +++ b/components/pages/work-flow.tsx @@ -139,7 +139,7 @@ Please process this video editing request.`; selectedView={selectedView} currentLoadingText={currentLoadingText} /> - {taskObject.currentStage !== 'init' && ( + {taskObject.currentStage !== 'init' && taskObject.status !== 'COMPLETED' && ( {['scene', 'character', 'video', 'final_video'].includes(taskObject.currentStage) && ( diff --git a/components/pages/work-flow/H5MediaViewer.tsx b/components/pages/work-flow/H5MediaViewer.tsx index c50e88d..d11adfe 100644 --- a/components/pages/work-flow/H5MediaViewer.tsx +++ b/components/pages/work-flow/H5MediaViewer.tsx @@ -53,6 +53,8 @@ interface H5MediaViewerProps { projectId?: string; /** 视频比例 */ aspectRatio?: string; + /** 是否显示进度条 */ + showProgress?: boolean; } /** @@ -79,7 +81,8 @@ export function H5MediaViewer({ enableVideoEdit, onVideoEditDescriptionSubmit, projectId, - aspectRatio + aspectRatio, + showProgress }: H5MediaViewerProps) { const carouselRef = useRef(null); const videoRefs = useRef>([]); @@ -103,15 +106,26 @@ export function H5MediaViewer({ /** 根据浏览器类型获取最大高度值 */ const maxHeight = useMemo(() => { + let h = 10.5; switch (browserType) { case 'Edge': - return 'calc(100vh - 10.5rem)'; + h = 10.5; + break; case 'Chrome': - return 'calc(100vh - 17rem)'; + h = 17; + break; + case 'Safari': + h = 15; + break; default: - return 'calc(100vh - 15rem)'; + h = 17; + break; } - }, [browserType]); + if (!showProgress) { + h = h - 1.5; + } + return `calc(100vh - ${h}rem)`; + }, [browserType, showProgress]); /** 视频轮播容器高度:按 aspectRatio 计算(基于视口宽度) */ const videoWrapperHeight = useMemo(() => {