Browse Source

一些优化

pull/19/head
zyronon 4 years ago
parent
commit
e0da8a0528
  1. 1
      src/components/Share.vue
  2. 2
      src/pages/home/Index2.vue
  3. 26
      src/pages/me/Uploader.vue

1
src/components/Share.vue

@ -380,6 +380,7 @@ export default {
} }
.create-chat { .create-chat {
font-size: 1.1rem;
margin: 1rem 0; margin: 1rem 0;
display: flex; display: flex;
align-items: center; align-items: center;

2
src/pages/home/Index2.vue

@ -107,6 +107,7 @@
</SlideItem> </SlideItem>
<SlideItem style="font-size: 40px;overflow:auto;"> <SlideItem style="font-size: 40px;overflow:auto;">
<Uploader <Uploader
ref="uploader"
:isOnThisPage="baseActiveIndex === 1" :isOnThisPage="baseActiveIndex === 1"
:author="this.videos[this.videoActiveIndex]?.author" :author="this.videos[this.videoActiveIndex]?.author"
@toggleCanMove="e => this.canMove = e" @toggleCanMove="e => this.canMove = e"
@ -154,6 +155,7 @@
<FollowSetting2 <FollowSetting2
@cancelFollow="$refs.uploader.cancelFollow()"
v-model="showFollowSetting2"/> v-model="showFollowSetting2"/>
<BlockDialog v-model="showBlockDialog"/> <BlockDialog v-model="showBlockDialog"/>

26
src/pages/me/Uploader.vue

@ -176,13 +176,15 @@
<SlideItem class="SlideItem" <SlideItem class="SlideItem"
@scroll="scroll" @scroll="scroll"
:style="SlideItemStyle"> :style="SlideItemStyle">
<div class="notice"> <div class="notice" v-if="localAuthor.is_private === 1">
<img src="../../assets/img/icon/me/lock-gray.png" alt=""> <img src="../../assets/img/icon/me/lock-gray.png" alt="">
<span>只有你能看到自己的喜欢列表</span> <span>喜欢内容不可见</span>
</div> </div>
<Posters v-if="videos.like.total !== -1" :list="videos.like.list"></Posters> <template v-else>
<Loading v-if="loadings.loading2" :is-full-screen="false"></Loading> <Posters v-if="videos.like.total !== -1" :list="videos.like.list"></Posters>
<no-more v-else/> <Loading v-if="loadings.loading2" :is-full-screen="false"></Loading>
<no-more v-else/>
</template>
</SlideItem> </SlideItem>
</SlideRowList> </SlideRowList>
</div> </div>
@ -233,7 +235,10 @@ export default {
onClick={e => this.changeIndicatorIndex(1)} onClick={e => this.changeIndicatorIndex(1)}
style="width:50%"> style="width:50%">
<span>喜欢</span> <span>喜欢</span>
<img src={require('../../assets/img/icon/components/follow/lock.png')} alt=""/> {
this.localAuthor.is_private === 1 &&
<img src={require('../../assets/img/icon/components/follow/lock.png')} alt=""/>
}
</div> </div>
</div> </div>
) )
@ -377,13 +382,16 @@ export default {
bus.on('baseSlide-end', () => this.canScroll = true) bus.on('baseSlide-end', () => this.canScroll = true)
}, },
methods: { methods: {
cancelFollow(){
this.localAuthor.is_follow = false
},
changeIndicatorIndex(index) { changeIndicatorIndex(index) {
this.$refs.Indicator.changeIndex(index) this.$refs.Indicator.changeIndex(index)
}, },
async getAuthor() { async getAuthor() {
this.changeIndex(0, null) this.changeIndex(0, null)
// let res = await this.$api.user.author({id: this.author.id}) let res = await this.$api.user.author({id: this.author.id})
let res = await this.$api.user.author({id: '54884802577'}) // let res = await this.$api.user.author({id: '54884802577'})
if (res.code === this.SUCCESS) { if (res.code === this.SUCCESS) {
this.localAuthor = {...this.localAuthor, ...res.data} this.localAuthor = {...this.localAuthor, ...res.data}
this.refreshDescHeight() this.refreshDescHeight()
@ -451,7 +459,7 @@ export default {
scrollAreaHeight += 60 scrollAreaHeight += 60
break break
case 1: case 1:
scrollAreaHeight += 60 + 40 scrollAreaHeight += 60 + this.localAuthor.is_private === 1 ? 0 : 40
break break
case 2: case 2:
scrollAreaHeight += 60 + 40 scrollAreaHeight += 60 + 40

Loading…
Cancel
Save