信达小程序
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

86 lines
3.3 KiB

<navbar fixed custom-style="background:{{background}};color:#fff">
<van-icon name="arrow-left" slot="left" size="18px" color="#fff" bind:tap="handleBack" />
<view slot="title" style="color: #fff">视频</view>
</navbar>
<view class="page">
<swiper class="swiper" vertical="{{true}}" current="{{current}}" bindchange="handleChange">
<swiper-item class="swiper-item" wx:for="{{videoList}}" wx:key="Id">
<video
id="video-{{item.attachmentId}}"
class="video"
src="{{item.videoUrl}}"
poster="{{item.imgUrl}}"
loop
title="{{item.title}}"
object-fit="contain"
enable-play-gesture
enable-progress-gesture
show-center-play-btn="{{false}}"
controls="{{item.fullScreen}}"
bindloadedmetadata="handleLoadedMetaData"
bindprogress="handleProgress"
bindplay="handlePlay"
bindpause="handlePause"
bindfullscreenchange="handleFullScreenChange"
bindtimeupdate="handleTimeUpdate"
data-index="{{index}}"
data-full="{{item.fullScreen}}"
></video>
<view
wx:if="{{item.offsetTop}}"
class="full-screen"
style="top:{{item.offsetTop}}px"
catch:tap="handelFullScreen"
data-id="video-{{item.attachmentId}}"
>
<image class="icon" src="{{imageUrl}}icon87.png?t={{Timestamp}}"></image>
全屏观看
</view>
<image
wx:if="{{!item.play}}"
class="play"
class="play"
src="{{imageUrl}}icon82.png?t={{Timestamp}}"
catch:tap="handleTogglePlay"
data-index="{{index}}"
></image>
<view class="swiper-item-footer">
<view class="title">{{item.title}}</view>
<view class="progress">
<van-slider
value="{{item.progress}}"
active-color="#fff"
bar-height="4"
inactive-color="rgba(255, 255, 255, 0.29)"
bind:drag-start="handleDragStart"
bind:change="handleDragEnd"
use-button-slot
data-index="{{index}}"
>
<view class="slider-btn" slot="button"></view>
</van-slider>
</view>
<view class="container">
<view class="user">
<image class="avatar" src="{{imageUrl}}logo1.png?t={{Timestamp}}"></image>
<view class="name">TED关爱小助手</view>
</view>
<view class="options">
<button class="o-item" open-type="share">
<image wx:if="{{item.IsShare}}" class="icon" src="{{imageUrl}}icon83.png?t={{Timestamp}}"></image>
<image wx:else class="icon" src="{{imageUrl}}icon85.png?t={{Timestamp}}"></image>
<view class="num {{item.IsShare && 'active'}}">{{item.ShareTimes}}</view>
</button>
<!-- <view class="o-item" bind:tap="handleLike" data-index="{{index}}"> -->
<!-- <image wx:if="{{item.IsLike}}" class="icon" src="{{imageUrl}}icon84.png?t={{Timestamp}}"></image> -->
<!-- <image wx:else class="icon" src="{{imageUrl}}icon86.png?t={{Timestamp}}"></image> -->
<!-- <view class="num {{item.IsLike && 'active'}}">{{item.LikeTimes}}</view> -->
<!-- </view> -->
</view>
</view>
</view>
</swiper-item>
</swiper>
</view>
<star id="animate" class="animate {{starShow&&'active'}}"></star>