From 8ad043d735ef7f8179583b3c09f23402610e4681 Mon Sep 17 00:00:00 2001 From: king <2229249788@qq.com> Date: Mon, 28 Aug 2023 16:55:10 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E5=B0=8F=E7=A8=8B=E5=BA=8F?= =?UTF-8?q?=E8=80=83=E9=A2=98=E5=BC=80=E5=A7=8B=E5=92=8C=E7=BB=93=E6=9D=9F?= =?UTF-8?q?=E4=BA=8B=E4=BB=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/video/video.tsx | 4 +-- .../videoInfo/components/catalogue.tsx | 5 ++-- .../business/videoInfo/components/course.tsx | 26 +++++++++---------- 3 files changed, 15 insertions(+), 20 deletions(-) diff --git a/src/components/video/video.tsx b/src/components/video/video.tsx index 9924471..e324452 100644 --- a/src/components/video/video.tsx +++ b/src/components/video/video.tsx @@ -45,12 +45,10 @@ const HVideo: FC = (opt: HVideoOptions) => { opt.breakpoint.forEach(d => { if (time < d + deviation && time > d - deviation) { video?.pause() - video?.seek(d - deviation) if (process.env.TARO_ENV === 'h5') { try { document?.exitFullscreen().then() - } catch (e) { - } + } catch (e) {} } video?.exitFullScreen() opt.onBreakpoint(d) diff --git a/src/pages/business/videoInfo/components/catalogue.tsx b/src/pages/business/videoInfo/components/catalogue.tsx index 601d885..fd8df74 100644 --- a/src/pages/business/videoInfo/components/catalogue.tsx +++ b/src/pages/business/videoInfo/components/catalogue.tsx @@ -175,10 +175,9 @@ const Catalogue: FC = ({data, setHors, id, playId}) => { { - playing ? {JSON.stringify(playing)}暂停 - : {JSON.stringify(playing)}立即学习 + playing ? 暂停 + : 立即学习 } - setShow(true)}>... diff --git a/src/pages/business/videoInfo/components/course.tsx b/src/pages/business/videoInfo/components/course.tsx index b001118..b8df4c7 100644 --- a/src/pages/business/videoInfo/components/course.tsx +++ b/src/pages/business/videoInfo/components/course.tsx @@ -129,24 +129,22 @@ const Course: FC = ({id, courseId, preview, curEnd}) => { setTime={videoSeek} /> - + {formatMinute(time)}考题 - {examAll?.[time]?.slice(0, 1)?.map((d) => - - {d.question_type === 2 && - setRecord([isAnswer])} - />} - - )} + { + examAll?.[time]?.slice(0, 1)?.map((d) => + + {d.question_type === 2 && + setRecord([isAnswer])} + />} + ) + }