20 lines
1.3 KiB
Plaintext
20 lines
1.3 KiB
Plaintext
<!--pages/video_show/video_show.wxml-->
|
|
<view class="main">
|
|
<view class="close flexcenter" style="top: {{ screen_data.statusBarHeight + 'px' }};" bindtap="back">
|
|
<image class="icon" mode="widthFix" src="/img/close-f.png"></image>
|
|
</view>
|
|
<view class="header"
|
|
style="padding-top: {{ screen_data.statusBarHeight + 'px' }}; height: {{ screen_data.totalTopHeight }}px;">
|
|
{{ (swiperCurrent * 1 + 1) + " / " + list.length }}</view>
|
|
<swiper class="swiper" current="{{ swiperCurrent }}" bindanimationfinish="bindchangeSwiper" bindtap="back">
|
|
<swiper-item class="swiper-item flexcenter" wx:for="{{ list }}" wx:key="index">
|
|
<video catchtap="return" style="height: {{ videoHeight }}px;" loop="{{ true }}" id="video{{ index }}" class="video" wx:if="{{ item.type == 'video' }}"
|
|
src="{{ item.url }}" poster="{{ item.poster }}" autoplay="{{ swiperCurrent == index ? true : false }}"
|
|
bindplay="onVideoPlay" data-index="{{ index }}"></video>
|
|
<block wx:else>
|
|
<image wx:if="{{ index >= swiperCurrent - 1 && index <= swiperCurrent + 1 }}" class="icon"
|
|
mode="widthFix" show-menu-by-longpress src="{{ item.url }}"></image>
|
|
</block>
|
|
</swiper-item>
|
|
</swiper>
|
|
</view> |