Skip to content

Commit

Permalink
modify commentPage
Browse files Browse the repository at this point in the history
  • Loading branch information
Elegenthus committed May 10, 2017
1 parent 1460338 commit 026a0f4
Show file tree
Hide file tree
Showing 6 changed files with 33 additions and 33 deletions.
4 changes: 2 additions & 2 deletions src/components/main/item.vue
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
<div :class = "$style.views_img" v-show ="item.kind != 1">
<svg viewBox="0 0 200 200" :class="$style.view_img"><use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="#view"></use></svg>
</div>
<div :class = "$style.tag">#{{item.tag}}#</div>
<div :class = "$style.tag" v-show = "item.tag">#{{item.tag}}#</div>
</div>
</div>
</template>
Expand Down Expand Up @@ -116,7 +116,7 @@ import Map from '../../common/keymap.js'
composes: space from 'sass-loader!../../scss/utility.scss';
}
.author{
width: 30%;
width: 50%;
padding-left: 15px;
float: left;
composes: common;
Expand Down
28 changes: 14 additions & 14 deletions src/components/profile/changeMessage.vue
Original file line number Diff line number Diff line change
Expand Up @@ -66,19 +66,19 @@ export default {
submitChange() {
if (!this.editChange) return
let promise1 = Fetch.FetchData('/api/v1.0/profile/' + this.profile.user_id + '/edit/', 'PUT', {
name: this.newName ? this.newName : this.profile.name,
introduction: this.newIntroduction ? this.newIntroduction : this.profile.introduction,
weibo: this.newWeibo ? this.newWeibo : this.profile.weibo,
img_url: this.pic_url ? this.pic_url : this.profile.weibo.img_url
}).then(value => {
this.profile = value
this.$parent.profile = value
this.$parent.changeMessage = false
this.editChange = false
this.newName = ""
this.newIntroduction = ""
this.newWeibo = ""
})
name: this.newName ? this.newName : this.profile.name,
introduction: this.newIntroduction ? this.newIntroduction : this.profile.introduction,
weibo: this.newWeibo ? this.newWeibo : this.profile.weibo,
img_url: this.pic_url ? this.pic_url : this.profile.weibo.img_url
}).then(value => {
this.profile = value
this.$parent.profile = value
this.$parent.changeMessage = false
this.editChange = false
this.newName = ""
this.newIntroduction = ""
this.newWeibo = ""
})
},
getName(e) {
this.changedImg = URL.createObjectURL(e.target.files[0])
Expand All @@ -100,7 +100,7 @@ export default {
}
}
</script>
<style lang ="sass" module>
<style lang="sass" module>
@import '../../scss/color.scss';
.suggestPage {
position: absolute;
Expand Down
2 changes: 1 addition & 1 deletion src/components/profile/exitPage.vue
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<template>
<div v-show="returnIt" :class="$style.suggestMask">
<div :class="$style.suggestMask">
<div :class="$style.returnCard" >
<div v-show = "flag">退出登录后,将不能发表评论和收藏内容。确认退出?</div>
<div :class="$style.returnButton" v-on:click="exit" v-show = "flag">退出</div>
Expand Down
16 changes: 4 additions & 12 deletions src/components/second/comment.vue
Original file line number Diff line number Diff line change
Expand Up @@ -95,9 +95,6 @@ export default {
"sharePage":SharePage,
"modal":Modal
},
mounted(){
console.log(this.articleInfo,"sf")
},
computed: {
BoxWidth: function () {
return {
Expand Down Expand Up @@ -164,16 +161,19 @@ export default {
closeComment: function () {
if (this.showComment) {
this.showComment = false
this.$parent.showComment = false
this.message = ""
}
},
activeComment: function (e) {
console.log("this.$parent",this.$parent)
if (!this.showComment) {
FETCH.FetchData(this.url, "GET")
.then(res => {
this.obj = res
})
this.showComment = true
this.$parent.showComment = true
}
},
ClickChangeColor: function () {
Expand Down Expand Up @@ -235,15 +235,6 @@ export default {
width: 100%;
}
.mask {
position: fixed;
width: 100%;
background-color: rgba(229, 233, 233, 0.85);
z-index: $Zindex2;
bottom: 50px;
top: 0;
}
.comment {
border-top: solid 1px $grey_l;
padding: 15px;
Expand Down Expand Up @@ -351,6 +342,7 @@ export default {
.commentPage {
position: absolute;
overflow: auto;
top: 0;
min-height:100%;
background-color: $white;
Expand Down
3 changes: 2 additions & 1 deletion src/components/second/info.vue
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ export default {
position: absolute;
width: 50px;
left: 20%;
top: 75px;
top: 20%;
}
.audio {
Expand All @@ -124,6 +124,7 @@ export default {
}
.musicBox {
position: relative;
composes: space from 'sass-loader!../../scss/utility.scss';
}
Expand Down
13 changes: 10 additions & 3 deletions src/components/second/second.vue
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
<template>
<div id="xxx">
<div id="xxx" :style = "stopScroll">
<articleInfo ref="articleInfo"></articleInfo>
<light ref = "light"></light>
<articleComments ref="articleComments"></articleComments>
<ad></ad>
<div :class="$style.recommend" v-show="list.length">
<div :class="$style.title" v-on:click="closeComment">相关推荐</div>
<item :item="item" v-for="item in list"></item>
</div>
<articleComments ref="articleComments"></articleComments>
<div :class="$style.occupy"></div>
</div>
</template>
Expand All @@ -30,14 +30,21 @@ export default {
return {
transform: 'translateX(' + this.x + 'px)'
}
},
stopScroll: function () {
return{
overflow: this.showComment ? 'hidden':'auto',
height:this.showComment?'90%':''
}
}
},
data() {
return {
closeCom: false,
x: 0,
foo: 0,
list: []
list: [],
showComment:false
}
},
mounted() {
Expand Down

0 comments on commit 026a0f4

Please sign in to comment.