Commit 9489e8f0 authored by 李纪文's avatar 李纪文

feat: 修改视频回放

parent 0c63efeb
......@@ -48,7 +48,9 @@ const HKh5player = (props, ref) => {
useEffect(() => {
setShowId(props?.VideoInfo?.id || '');
setHoursRuler(props?.VideoInfo.hoursRuler || 24);
setPlayTimestamp(props?.VideoInfo?.playTime ? moment(props?.VideoInfo?.playTime).valueOf() : null);
setPlayTimestamp(
props?.VideoInfo?.playTime ? moment(props?.VideoInfo?.playTime).valueOf() : null,
);
changeReplayCfg?.();
// 设置播放容器的宽高并监听窗口大小变化
window.addEventListener('resize', resizeVideo);
......@@ -467,6 +469,7 @@ const HKh5player = (props, ref) => {
<div className={classNames(`${prefixCls}-time`)}>
{peridos.length ? (
<TimeSlider
key={JSON.stringify(props?.VideoInfo || '{}')}
minTimestamp={minTimestamp}
maxTimestamp={maxTimestamp}
hoursPerRuler={hoursRuler || 24}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment