Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
M
mini-program-wepy
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
ui
mini-program-wepy
Commits
373350bd
Commit
373350bd
authored
May 21, 2020
by
付清曌
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'feature/uioptimize' into 'master'
Feature/uioptimize See merge request
!6
parents
4f5729a9
7d79aec0
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
21 additions
and
30 deletions
+21
-30
loading.wpy
src/components/custom/loading.wpy
+2
-2
videolist.wpy
src/components/custom/videolist.wpy
+19
-28
No files found.
src/components/custom/loading.wpy
View file @
373350bd
...
...
@@ -7,7 +7,7 @@
import wepy from '@wepy/core';
wepy.component({
});
</script>
<style lang="less">
...
...
@@ -15,7 +15,7 @@
position: absolute;
width: 100%;
height: 100%;
background:
#000
;
background:
rgba(0,0,0,0.7)
;
display: flex;
justify-content: center;
align-items: center;
...
...
src/components/custom/videolist.wpy
View file @
373350bd
<style lang="less">
.container{
.container
,.video-swiper
{
width:100%;
height:100%
}
.video-swiper{
width:100%;
height:100%
height:100%;
}
.video_item{
height:100%;
...
...
@@ -13,21 +9,13 @@
position: absolute;
z-index: 1;
}
.content{
position: absolute;
z-index: 9;
bottom: 405rpx;
width: 100%;
min-height:120rpx;
color: white;
clear: both;
}
.rightcont {
font-size: 24rpx;
display:inline-block;
float: right;
position: absolute;
z-index: 9;
bottom: 415rpx;
width:30%;
margin-
right: 30rpx;
right: 30rpx;
color: #fff;
.info {
line-height: 40rpx;
...
...
@@ -72,16 +60,6 @@
<!-- curQueue 循环会导致video重新插入,objectFit 不可变更 -->
<swiper-item wx:for="{{curQueue}}" wx:key="index">
<view class="video-wrapper">
<cover-view class="content">
<cover-view class="rightcont">
<cover-view class="info">奖品库存: 1/8</cover-view>
<cover-view class="info">中奖概率: {{item.id}}/3000</cover-view>
<cover-view class="progress">
<cover-view class="text">{{progress}}%</cover-view>
<cover-view class="orange" style="{{progressStyle}}"></cover-view>
</cover-view>
</cover-view>
</cover-view>
<video
id="video_{{index}}"
class="video_item"
...
...
@@ -100,6 +78,14 @@
>
<video-pause :pause="pause"></video-pause>
</video>
<view class="rightcont">
<view class="info">奖品库存: 1/8</view>
<view class="info">中奖概率: {{item.id}}/3000</view>
<view class="progress">
<view class="text">{{progress}}%</view>
<view class="orange" style="{{progressStyle}}"></view>
</view>
</view>
<video-loading v-if="item.time === 0"/>
</view>
</swiper-item>
...
...
@@ -245,6 +231,11 @@
playCurrent(current) {
this._videoContexts.forEach((ctx, index) => {
// console.log('playCurrent', current, index);
if (index !== current) {
ctx.pause();
} else {
ctx.play();
}
});
},
trigger(e, type) {
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment