[toc]
# 3.12 送礼物弹框组件(二) - 功能
## 3.12.1 实现关闭送礼物弹框效果
```
<view style="height: 100rpx;" class="flex justify-between align-center">
<text class="text-main font-md ml-3">礼物</text>
<view @click="closeGift" style="height:100rpx; width: 100rpx;" class="flex justify-center align-center">
<text class="iconfont"></text>
</view>
</view>
//关闭送礼物弹出层
closeGift(){
this.$refs.giftPopup.close()
},
```
## 3.12.3 创建礼物的模拟数据
1. 在项目的根目录下创建demo文件夹
2. 在demo文件夹内创建gift.js文件
3. 在gift.js文件内写模拟的礼物数据
```
export default [{
"image": "/static/gift/1.png",
"id": 1,
"name": "鸡蛋",
"coin": 1
}, {
"image": "/static/gift/2.png",
"id": 2,
"name": "666",
"coin": 2
}, {
"image": "/static/gift/3.png",
"id": 3,
"name": "雪糕",
"coin": 3
}, {
"image": "/static/gift/4.png",
"id": 4,
"name": "龙虾",
"coin": 4
}, {
"image": "/static/gift/5.png",
"id": 5,
"name": "精灵球",
"coin": 5
}, {
"image": "/static/gift/6.png",
"id": 6,
"name": "胶囊",
"coin": 6
}, {
"image": "/static/gift/7.png",
"id": 7,
"name": "爱心",
"coin": 7
}, {
"image": "/static/gift/8.png",
"id": 8,
"name": "花",
"coin": 8
}]
```
## 3.12.2 将模拟的礼物数据进行动态渲染
1. 引入模拟数据的js文件
2. 在data中定义gifts属性为数组,用来保存礼物的数据
3. 在页面加载的时候给gifts的数据为js文件内模拟的数据
4. 设置v-for遍历的属性为gifts,并对数据进行动态绑定
```
<template>
<view class="page">
<!-- 直播内容 -->
<video class="flex-1" src="http://ivi.bupt.edu.cn/hls/cctv1hd.m3u8" autoplay :controls="false"></video>
<!-- 头部 -->
<view style="position: fixed; left: 0; right: 0;" :style="{top : `${statusBarHeight}px`}">
<!-- 个人信息|观看详细信息 -->
<view class="px-2 flex justify-between" style="height:80rpx;">
<!-- 个人信息 -->
<view style="width: 325rpx; background-color: rgba(0,0,0,0.4);" class="flex align-center rounded-circle">
<view class="p">
<image src="../../static/tabbar/min.png" style="width: 70rpx; height: 70rpx;" class="rounded-circle"></image>
</view>
<!-- 昵称与浏览量 -->
<view class="flex-1 flex flex-column justify-center">
<text class="text-white font">昵称</text>
<text class="text-white font-sm">100</text>
</view>
<!-- 关注按钮 -->
<view class="rounded-circle flex align-center bg-danger justify-center" style="width: 70rpx; height: 70rpx;">
<text class="text-white">+</text>
</view>
</view>
<!-- 观看情况 -->
<view style="width: 325rpx; background-color: rgba(0,0,0,0.4);" class="flex align-center rounded-circle">
<!-- 观看的用户 -->
<scroll-view scroll-x="true" class="flex-1 flex">
<view class="p" v-for="(item,index) in 20" :key="index">
<image src="../../static/tabbar/min.png" style="width: 70rpx; height: 70rpx;" class="rounded-circle"></image>
</view>
</scroll-view>
<!-- 观看人数 -->
<view class="rounded-circle flex align-center bg-danger justify-center" style="width: 70rpx; height: 70rpx;">
<text class="text-white font-sm">1000</text>
</view>
</view>
</view>
<!--金币-->
<view class="px-2 my-2" style="height: 80rpx;">
<view style="width: 325rpx; background-color: rgba(0,0,0,0.4);" class="flex align-center rounded-circle">
<view class="p">
<text class="text-warning">金币</text>
</view>
<view class="flex-1 flex flex-column justify-center">
<text class="text-white font">100</text>
</view>
</view>
</view>
<!-- 礼物 -->
<f-gift ref="gift"></f-gift>
</view>
<!-- 弹幕 -->
<f-danmu ref="danmu"></f-danmu>
<!-- 底部评论..等 -->
<view class="position-fixed right-0 bottom-0 left-0 flex align-center justify-between" style="height: 120rpx;">
<view class="px-2" >
<view @click="openInput" style="height:80rpx;border-radius: 100rpx;background-color: rgba(255,255,255,0.12);" class="flex justify-center px-3 align-center">
<text class="text-white font">说点什么...</text>
</view>
</view>
<view class="flex align-center">
<view style="height:80rpx; width: 80rpx; background-color: rgba(255,255,255,0.12);" class="flex mr-1 justify-center rounded-circle align-center">
<text class="iconfont text-white" style="font-size: 40px; "></text>
</view>
<view @click="openGift" style="height:80rpx; width: 80rpx;" class="flex mr-1 justify-center rounded-circle align-center bg-warning">
<text class="iconfont"></text>
</view>
<view style="height:80rpx; width: 80rpx; background-color: rgba(255,255,255,0.12);" class="flex mr-1 justify-center rounded-circle align-center">
<text class="iconfont text-white"></text>
</view>
<view @click="back" style="height:80rpx; width: 80rpx; background-color: rgba(255,255,255,0.12);" class="flex mr-1 justify-center rounded-circle align-center">
<text class="iconfont text-white"></text>
</view>
</view>
</view>
<!-- 输入框弹出层 -->
<uni-popup type="bottom" ref="input">
<view class="bg-white flex align-center px-3" style="height: 120rpx;">
<input placeholder="说点什么呢..." v-model="content" type="text" style="height: 80rpx;" class="border rounded flex-1 px-3 font-md">
<view :class="content == '' ? 'bg-main-disabled' : 'bg-main'" class=" flex ml-3 align-center py-2 rounded px-2 justify-center" @click="submit">
<text class="font text-white">发送</text>
</view>
</view>
</uni-popup>
<!-- 送礼物弹出层 -->
<uni-popup type="bottom" ref="giftPopup">
<view style="width: 750rpx; height: 550rpx;" class="bg-white">
<view style="height: 100rpx;" class="flex justify-between align-center">
<text class="text-main font-md ml-3">礼物</text>
<view @click="closeGift" style="height:100rpx; width: 100rpx;" class="flex justify-center align-center">
<text class="iconfont"></text>
</view>
</view>
<swiper class="border-top border-bottom" :indicator-dots="true" style="height: 350rpx;" :duration="500">
<swiper-item>
<view class="flex flex-wrap">
<view v-for="(item,index) in gifts" :key="index" style="width: 187.5rpx; height: 175rpx;" class="flex flex-column justify-center align-center">
<image :src="item.image" style="width: 100rpx; height: 100rpx;"></image>
<view class="flex mt-1">
<text class="text-warning font mr-1">{{item.name}}</text>
<text class="text-secondary font">{{item.coin}}</text>
</view>
</view>
</view>
</swiper-item>
</swiper>
<view style="height: 100rpx;" class="flex align-center justify-end">
<view class="bg-warning flex mr-3 align-center py-2 rounded px-2 justify-center" >
<text class="font">充值</text>
</view>
<view class="bg-main flex mr-3 align-center py-2 rounded px-2 justify-center" >
<text class="font text-white">发送</text>
</view>
</view>
</view>
</uni-popup>
</view>
</template>
<script>
import fGift from "@/components/live/f-gift.vue"
import uniPopup from "@/components/uni-ui/uni-popup/uni-popup.vue"
import fDanmu from "@/components/live/f-danmu.vue"
import demoGifts from "@/demo/gifts.js"
export default {
data(){
return {
statusBarHeight : 0,
content : "",
gifts : []
}
},
components: {
fGift,
uniPopup,
fDanmu
},
onLoad(){
//获取通知栏的高度
let res = uni.getSystemInfoSync();
this.statusBarHeight = res.statusBarHeight;
//礼物数据
this.gifts = demoGifts;
},
mounted(){
//模拟发送礼物
setInterval(()=>{
this.$refs.gift.send({
username : "发送人",
avatar : "",
gift_name : "蛋糕",
gift_image : "/static/gift/3.png",
num : 1
})
},3000)
//模拟发送弹幕
// let id = 1;
// setInterval(()=>{
// this.$refs.danmu.send({
// id : id,
// name : "昵称" + id,
// content : "九月直播666"
// })
// id++;
// },3000)
},
methods:{
//关闭送礼物弹出层
closeGift(){
this.$refs.giftPopup.close()
},
//打开送礼物弹出层
openGift(){
this.$refs.giftPopup.open()
},
//关闭直播间,返回上一页
back(){
uni.navigateBack({
delta: 1
})
},
openInput(){
this.$refs.input.open()
},
submit(){
//发送内容为空,提示框不消失
if(this.content == ""){
return;
}
//发送弹幕
this.$refs.danmu.send({
id : Math.random()*100,
name : "昵称",
content : this.content
})
//清空输入的内容
this.content = "";
//关闭输入提示框
this.$refs.input.close()
}
}
}
</script>
<style>
.page{
flex : 1;
}
</style>
```
## 3.12.4 实现当点击礼物的时候显示对应的边框的效果
```
<template>
<view class="page">
<!-- 直播内容 -->
<video class="flex-1" src="http://ivi.bupt.edu.cn/hls/cctv1hd.m3u8" autoplay :controls="false"></video>
<!-- 头部 -->
<view style="position: fixed; left: 0; right: 0;" :style="{top : `${statusBarHeight}px`}">
<!-- 个人信息|观看详细信息 -->
<view class="px-2 flex justify-between" style="height:80rpx;">
<!-- 个人信息 -->
<view style="width: 325rpx; background-color: rgba(0,0,0,0.4);" class="flex align-center rounded-circle">
<view class="p">
<image src="../../static/tabbar/min.png" style="width: 70rpx; height: 70rpx;" class="rounded-circle"></image>
</view>
<!-- 昵称与浏览量 -->
<view class="flex-1 flex flex-column justify-center">
<text class="text-white font">昵称</text>
<text class="text-white font-sm">100</text>
</view>
<!-- 关注按钮 -->
<view class="rounded-circle flex align-center bg-danger justify-center" style="width: 70rpx; height: 70rpx;">
<text class="text-white">+</text>
</view>
</view>
<!-- 观看情况 -->
<view style="width: 325rpx; background-color: rgba(0,0,0,0.4);" class="flex align-center rounded-circle">
<!-- 观看的用户 -->
<scroll-view scroll-x="true" class="flex-1 flex">
<view class="p" v-for="(item,index) in 20" :key="index">
<image src="../../static/tabbar/min.png" style="width: 70rpx; height: 70rpx;" class="rounded-circle"></image>
</view>
</scroll-view>
<!-- 观看人数 -->
<view class="rounded-circle flex align-center bg-danger justify-center" style="width: 70rpx; height: 70rpx;">
<text class="text-white font-sm">1000</text>
</view>
</view>
</view>
<!--金币-->
<view class="px-2 my-2" style="height: 80rpx;">
<view style="width: 325rpx; background-color: rgba(0,0,0,0.4);" class="flex align-center rounded-circle">
<view class="p">
<text class="text-warning">金币</text>
</view>
<view class="flex-1 flex flex-column justify-center">
<text class="text-white font">100</text>
</view>
</view>
</view>
<!-- 礼物 -->
<f-gift ref="gift"></f-gift>
</view>
<!-- 弹幕 -->
<f-danmu ref="danmu"></f-danmu>
<!-- 底部评论..等 -->
<view class="position-fixed right-0 bottom-0 left-0 flex align-center justify-between" style="height: 120rpx;">
<view class="px-2" >
<view @click="openInput" style="height:80rpx;border-radius: 100rpx;background-color: rgba(255,255,255,0.12);" class="flex justify-center px-3 align-center">
<text class="text-white font">说点什么...</text>
</view>
</view>
<view class="flex align-center">
<view style="height:80rpx; width: 80rpx; background-color: rgba(255,255,255,0.12);" class="flex mr-1 justify-center rounded-circle align-center">
<text class="iconfont text-white" style="font-size: 40px; "></text>
</view>
<view @click="openGift" style="height:80rpx; width: 80rpx;" class="flex mr-1 justify-center rounded-circle align-center bg-warning">
<text class="iconfont"></text>
</view>
<view style="height:80rpx; width: 80rpx; background-color: rgba(255,255,255,0.12);" class="flex mr-1 justify-center rounded-circle align-center">
<text class="iconfont text-white"></text>
</view>
<view @click="back" style="height:80rpx; width: 80rpx; background-color: rgba(255,255,255,0.12);" class="flex mr-1 justify-center rounded-circle align-center">
<text class="iconfont text-white"></text>
</view>
</view>
</view>
<!-- 输入框弹出层 -->
<uni-popup type="bottom" ref="input">
<view class="bg-white flex align-center px-3" style="height: 120rpx;">
<input placeholder="说点什么呢..." v-model="content" type="text" style="height: 80rpx;" class="border rounded flex-1 px-3 font-md">
<view :class="content == '' ? 'bg-main-disabled' : 'bg-main'" class=" flex ml-3 align-center py-2 rounded px-2 justify-center" @click="submit">
<text class="font text-white">发送</text>
</view>
</view>
</uni-popup>
<!-- 送礼物弹出层 -->
<uni-popup type="bottom" ref="giftPopup">
<view style="width: 750rpx; height: 550rpx;" class="bg-white">
<view style="height: 100rpx;" class="flex justify-between align-center">
<text class="text-main font-md ml-3">礼物</text>
<view @click="closeGift" style="height:100rpx; width: 100rpx;" class="flex justify-center align-center">
<text class="iconfont"></text>
</view>
</view>
<swiper class="border-top border-bottom" :indicator-dots="true" style="height: 350rpx;" :duration="500">
<swiper-item>
<view class="flex flex-wrap">
<view @click="giftActiveId = item.id" :class="item.id == giftActiveId ? 'border boder-main' : ''" v-for="(item,index) in gifts" :key="index" style="width: 187.5rpx; height: 175rpx;" class="flex flex-column justify-center align-center">
<image :src="item.image" style="width: 100rpx; height: 100rpx;"></image>
<view class="flex mt-1">
<text class="text-warning font mr-1">{{item.name}}</text>
<text class="text-secondary font">{{item.coin}}</text>
</view>
</view>
</view>
</swiper-item>
</swiper>
<view style="height: 100rpx;" class="flex align-center justify-end">
<view class="bg-warning flex mr-3 align-center py-2 rounded px-2 justify-center" >
<text class="font">充值</text>
</view>
<view class="bg-main flex mr-3 align-center py-2 rounded px-2 justify-center" >
<text class="font text-white">发送</text>
</view>
</view>
</view>
</uni-popup>
</view>
</template>
<script>
import fGift from "@/components/live/f-gift.vue"
import uniPopup from "@/components/uni-ui/uni-popup/uni-popup.vue"
import fDanmu from "@/components/live/f-danmu.vue"
import demoGifts from "@/demo/gifts.js"
export default {
data(){
return {
statusBarHeight : 0,
content : "",
gifts : [],
giftActiveId : 0
}
},
components: {
fGift,
uniPopup,
fDanmu
},
onLoad(){
//获取通知栏的高度
let res = uni.getSystemInfoSync();
this.statusBarHeight = res.statusBarHeight;
//礼物数据
this.gifts = demoGifts;
},
mounted(){
//模拟发送礼物
setInterval(()=>{
this.$refs.gift.send({
username : "发送人",
avatar : "",
gift_name : "蛋糕",
gift_image : "/static/gift/3.png",
num : 1
})
},3000)
//模拟发送弹幕
// let id = 1;
// setInterval(()=>{
// this.$refs.danmu.send({
// id : id,
// name : "昵称" + id,
// content : "九月直播666"
// })
// id++;
// },3000)
},
methods:{
//关闭送礼物弹出层
closeGift(){
this.$refs.giftPopup.close()
},
//打开送礼物弹出层
openGift(){
this.$refs.giftPopup.open()
},
//关闭直播间,返回上一页
back(){
uni.navigateBack({
delta: 1
})
},
openInput(){
this.$refs.input.open()
},
submit(){
//发送内容为空,提示框不消失
if(this.content == ""){
return;
}
//发送弹幕
this.$refs.danmu.send({
id : Math.random()*100,
name : "昵称",
content : this.content
})
//清空输入的内容
this.content = "";
//关闭输入提示框
this.$refs.input.close()
}
}
}
</script>
<style>
.page{
flex : 1;
}
</style>
```
## 3.12.5 实现发送礼物功能
```
<template>
<view class="page">
<!-- 直播内容 -->
<video class="flex-1" src="http://ivi.bupt.edu.cn/hls/cctv1hd.m3u8" autoplay :controls="false"></video>
<!-- 头部 -->
<view style="position: fixed; left: 0; right: 0;" :style="{top : `${statusBarHeight}px`}">
<!-- 个人信息|观看详细信息 -->
<view class="px-2 flex justify-between" style="height:80rpx;">
<!-- 个人信息 -->
<view style="width: 325rpx; background-color: rgba(0,0,0,0.4);" class="flex align-center rounded-circle">
<view class="p">
<image src="../../static/tabbar/min.png" style="width: 70rpx; height: 70rpx;" class="rounded-circle"></image>
</view>
<!-- 昵称与浏览量 -->
<view class="flex-1 flex flex-column justify-center">
<text class="text-white font">昵称</text>
<text class="text-white font-sm">100</text>
</view>
<!-- 关注按钮 -->
<view class="rounded-circle flex align-center bg-danger justify-center" style="width: 70rpx; height: 70rpx;">
<text class="text-white">+</text>
</view>
</view>
<!-- 观看情况 -->
<view style="width: 325rpx; background-color: rgba(0,0,0,0.4);" class="flex align-center rounded-circle">
<!-- 观看的用户 -->
<scroll-view scroll-x="true" class="flex-1 flex">
<view class="p" v-for="(item,index) in 20" :key="index">
<image src="../../static/tabbar/min.png" style="width: 70rpx; height: 70rpx;" class="rounded-circle"></image>
</view>
</scroll-view>
<!-- 观看人数 -->
<view class="rounded-circle flex align-center bg-danger justify-center" style="width: 70rpx; height: 70rpx;">
<text class="text-white font-sm">1000</text>
</view>
</view>
</view>
<!--金币-->
<view class="px-2 my-2" style="height: 80rpx;">
<view style="width: 325rpx; background-color: rgba(0,0,0,0.4);" class="flex align-center rounded-circle">
<view class="p">
<text class="text-warning">金币</text>
</view>
<view class="flex-1 flex flex-column justify-center">
<text class="text-white font">100</text>
</view>
</view>
</view>
<!-- 礼物 -->
<f-gift ref="gift"></f-gift>
</view>
<!-- 弹幕 -->
<f-danmu ref="danmu"></f-danmu>
<!-- 底部评论..等 -->
<view class="position-fixed right-0 bottom-0 left-0 flex align-center justify-between" style="height: 120rpx;">
<view class="px-2" >
<view @click="openInput" style="height:80rpx;border-radius: 100rpx;background-color: rgba(255,255,255,0.12);" class="flex justify-center px-3 align-center">
<text class="text-white font">说点什么...</text>
</view>
</view>
<view class="flex align-center">
<view style="height:80rpx; width: 80rpx; background-color: rgba(255,255,255,0.12);" class="flex mr-1 justify-center rounded-circle align-center">
<text class="iconfont text-white" style="font-size: 40px; "></text>
</view>
<view @click="openGift" style="height:80rpx; width: 80rpx;" class="flex mr-1 justify-center rounded-circle align-center bg-warning">
<text class="iconfont"></text>
</view>
<view style="height:80rpx; width: 80rpx; background-color: rgba(255,255,255,0.12);" class="flex mr-1 justify-center rounded-circle align-center">
<text class="iconfont text-white"></text>
</view>
<view @click="back" style="height:80rpx; width: 80rpx; background-color: rgba(255,255,255,0.12);" class="flex mr-1 justify-center rounded-circle align-center">
<text class="iconfont text-white"></text>
</view>
</view>
</view>
<!-- 输入框弹出层 -->
<uni-popup type="bottom" ref="input">
<view class="bg-white flex align-center px-3" style="height: 120rpx;">
<input placeholder="说点什么呢..." v-model="content" type="text" style="height: 80rpx;" class="border rounded flex-1 px-3 font-md">
<view :class="content == '' ? 'bg-main-disabled' : 'bg-main'" class=" flex ml-3 align-center py-2 rounded px-2 justify-center" @click="submit">
<text class="font text-white">发送</text>
</view>
</view>
</uni-popup>
<!-- 送礼物弹出层 -->
<uni-popup type="bottom" ref="giftPopup">
<view style="width: 750rpx; height: 550rpx;" class="bg-white">
<view style="height: 100rpx;" class="flex justify-between align-center">
<text class="text-main font-md ml-3">礼物</text>
<view @click="closeGift" style="height:100rpx; width: 100rpx;" class="flex justify-center align-center">
<text class="iconfont"></text>
</view>
</view>
<swiper class="border-top border-bottom" :indicator-dots="true" style="height: 350rpx;" :duration="500">
<swiper-item>
<view class="flex flex-wrap">
<view @click="giftActiveId = item.id" :class="item.id == giftActiveId ? 'border boder-main' : ''" v-for="(item,index) in gifts" :key="index" style="width: 187.5rpx; height: 175rpx;" class="flex flex-column justify-center align-center">
<image :src="item.image" style="width: 100rpx; height: 100rpx;"></image>
<view class="flex mt-1">
<text class="text-warning font mr-1">{{item.name}}</text>
<text class="text-secondary font">{{item.coin}}</text>
</view>
</view>
</view>
</swiper-item>
</swiper>
<view style="height: 100rpx;" class="flex align-center justify-end">
<view class="bg-warning flex mr-3 align-center py-2 rounded px-2 justify-center" >
<text class="font">充值</text>
</view>
<view class="bg-main flex mr-3 align-center py-2 rounded px-2 justify-center" >
<text class="font text-white" @click="sendGift">发送</text>
</view>
</view>
</view>
</uni-popup>
</view>
</template>
<script>
import fGift from "@/components/live/f-gift.vue"
import uniPopup from "@/components/uni-ui/uni-popup/uni-popup.vue"
import fDanmu from "@/components/live/f-danmu.vue"
import demoGifts from "@/demo/gifts.js"
export default {
data(){
return {
statusBarHeight : 0,
content : "",
gifts : [],
giftActiveId : 0
}
},
components: {
fGift,
uniPopup,
fDanmu
},
onLoad(){
//获取通知栏的高度
let res = uni.getSystemInfoSync();
this.statusBarHeight = res.statusBarHeight;
//礼物数据
this.gifts = demoGifts;
},
mounted(){
// //模拟发送礼物
// setInterval(()=>{
// this.$refs.gift.send({
// username : "发送人",
// avatar : "",
// gift_name : "蛋糕",
// gift_image : "/static/gift/3.png",
// num : 1
// })
// },3000)
//模拟发送弹幕
// let id = 1;
// setInterval(()=>{
// this.$refs.danmu.send({
// id : id,
// name : "昵称" + id,
// content : "九月直播666"
// })
// id++;
// },3000)
},
methods:{
//发送礼物
sendGift(){
//如果要发送的礼物不存在,则不继续往下执行,并给一个提示
if(this.giftActiveId == 0){
return uni.showToast({
title: "请选择要发送的礼物",
icon : "none"
})
}
//查找出对应的礼物
let index = this.gifts.findIndex(item=> item.id == this.giftActiveId)
if(index == -1){
return;
}
let g = this.gifts[index];
//进行发送
this.$refs.gift.send({
username : "发送人",
avatar : "",
gift_name : g.name,
gift_image : g.image,
num : 1
})
//关闭送礼物弹出层
this.closeGift();
},
//关闭送礼物弹出层
closeGift(){
this.$refs.giftPopup.close()
},
//打开送礼物弹出层
openGift(){
this.$refs.giftPopup.open()
},
//关闭直播间,返回上一页
back(){
uni.navigateBack({
delta: 1
})
},
openInput(){
this.$refs.input.open()
},
submit(){
//发送内容为空,提示框不消失
if(this.content == ""){
return;
}
//发送弹幕
this.$refs.danmu.send({
id : Math.random()*100,
name : "昵称",
content : this.content
})
//清空输入的内容
this.content = "";
//关闭输入提示框
this.$refs.input.close()
}
}
}
</script>
<style>
.page{
flex : 1;
}
</style>
```
- 第一章 项目介绍和准备
- 1.1 课程介绍
- 1.2 环境搭建和项目创建
- 1.3 引入全局样式
- 1.4 引入图标库
- 1.5 底部导航和凸起按钮配置
- 第二章 首页开发
- 2.1 首页开发(一)
- 2.2 首页开发(二)
- 第三章 直播间(用户端)开发
- 3.1 基础布局开发(一)
- 3.2 基础布局开发(二)
- 3.3 个人信息和观看情况
- 3.4 接收礼物组件(一) - 布局
- 3.5 接收礼物组件(二) - 自动滚动
- 3.6 接收礼物组件(三) - 自动消失
- 3.7 底部操作条
- 3.8 弹幕组件开发(一) - 输入框弹出层
- 3.9 弹幕组件开发(二) - 置于底部功能
- 3.10 弹幕组件开发(三) - 发送弹幕
- 3.11 送礼物弹框组件(一) - 布局
- 3.12 送礼物弹框组件(二) - 功能
- 第四章 充值金币页开发
- 4.1 充值金币页开发(一)
- 4.2 充值金币页开发(二)
- 第五章 直播间(主播端)开发
- 5.1 创建直播页 - 推流组件
- 5.2 创建直播页 - 布局(一)
- 5.3 创建直播页 - 布局(二)
- 5.4 创建直播页 - 镜头反转
- 5.5 创建直播页 - 切换画质
- 5.6 创建直播页 - 美颜和美白
- 5.7 关于退出创建直播页黑边问题
- 5.8 主播直播间(一)
- 5.9 主播直播间(二)
- 第六章 个人中心页面开发
- 6.1 个人中心页
- 第七章 egg.js基础
- 第八章 后台管理系统开发
- 8.1 创建项目和基础配置
- 第九章 交互和部署上线
- 9.1 登录注册交互实现
- 9.2 个人中心交互实现
- 9.3 退出登录以及初始化用户信息
- 9.5 权限验证
- 9.6 首页交互 - 上拉加载与下拉刷新
- 9.7 创建订单和微信支付(一)
- 9.8 创建订单和微信支付(二)
- 9.9 微信支付调试和充值页交互
- 9.10 直播间交互
- 9.11 socket.io安装与通讯(一)
- 9.12 socket.io安装和通讯(二)
- 9.13 加入直播间(一)
- 9.14 加入直播间(二)
- 9.15 加入直播间(三)
- 9.16 离开直播间
- 9.17 直播间实时在线用户列表
- 9.18 直播间实时弹幕功能
- 9.19 直播间送礼物功能
- 9.20 创建直播功能交互(一)
- 9.21 创建直播功能交互(二)
- 9.22 优化前端部分问题(一)
- 9.23 优化前端部分问题(二)
- 第七章 登录注册页面开发