当前位置:网站首页>Add other view components to the audio and video components of the applet
Add other view components to the audio and video components of the applet
2022-06-23 02:43:00 【A good man】
explain
Because the audio and video components live-pusher and live-player The default level is higher , You can't display other components when you add them . But it can be added by absolute positioning .
design sketch
Added view Related logic
wxml file
<view class="fold" wx:if="{{!isUserListShow}}" bindtap="_handFoldClick">
<image src="../../../static/images/fold.png" class="fold-img"></image>
</view>
<view wx:else class="unfold">
<image src="../../../static/images/unfold.png" class="fold-img" bindtap="_handFoldClick"></image>
<view class="member-list">
<view> Member list :</view>
<view>
<view wx:if="{{playerList.length}}">
<view wx:for="{{playerList}}" wx:key="streamID">
<view>{{item.userID}}</view>
</view>
</view>
<view>
{{_rtcConfig.userID}}
</view>
</view>
</view>
<view>
</view>
</view>wxss The style file
.fold {
position: absolute;
top: 50vh;
right: 10px;
z-index: 3;
}
.unfold {
position: absolute;
top: 50vh;
right: 10px;
z-index: 3;
display: flex;
flex-direction: row;
}
.unfold .member-list {
background-color: rgba(48, 40, 40, 0.7);
width: 160px;
display: flex;
flex-direction: column;
color: honeydew;
}
.fold-img {
height: 32px;
width: 32px;
}js file
_handFoldClick() {
this.setData({
isUserListShow: !this.data.isUserListShow
})
},The above is to add other audio and video components view Related logic of , Mainly view Absolute positioning is required .
边栏推荐
- Detailed explanation of various networking modes of video monitoring platform
- You must know the type and method of urllib
- "Return index" of live broadcast E-commerce
- How to store, manage and view family photos in an orderly manner?
- [data preparation and Feature Engineering] data cleaning
- My good brother gave me a difficult problem: retry mechanism
- Evolution history of mobile communication
- Goframe framework (RK boot): fast implementation of server-side JWT verification
- Interviewer: what is the difference between SSH and SSM frameworks? How to choose??
- Docker builds redis3 master-slave cluster and expands the capacity
猜你喜欢

Pywebio to quickly build web applications
![Buuctf misc-[actf freshman competition 2020]outline](/img/a4/ac9d14a69e0759d1e7c65740415bf7.jpg)
Buuctf misc-[actf freshman competition 2020]outline

Evolution history of mobile communication

5g core network and core network evolution

2021-11-11

Information theory and coding

How to make word notes beautiful

My good brother gave me a difficult problem: retry mechanism

Interviewer: what is the difference between SSH and SSM frameworks? How to choose??

Log a log4j2 vulnerability handling
随机推荐
What is a smart farm?
How to make keyword targeted layout based on search sources?
Docker installs mysql5.7 and mounts the configuration file
3. install and deploy Mgr cluster | explain Mgr in simple terms
Application and challenge of ten billion level map data in Kwai security intelligence
Pywebio to quickly build web applications
Circuit analysis (circuit principle)
How PHP uses redis
Detailed explanation of various networking modes of video monitoring platform
Markdown - mark above / below symbol (typora, latex)
Interviewer: with the for loop, why do you need foreach??
An article shows you the difference between high fidelity and low fidelity prototypes
Optimization method of live weak network
No error is reported when using the Gorm framework to create a table, but the data cannot be inserted successfully
Xgboost Guide
You must know the type and method of urllib
method
8 vertical centering methods
Goframe framework (RK boot): Based on cloud native environment, distinguish configuration files (config)
The commercial s2b2b e-commerce platform of aquatic industry improves the competitiveness of enterprises and creates a strong engine for industrial development