Skip to content

Commit 89401a3

Browse files
author
shimh-develop
committed
调整文章详情样式
1 parent 7b9821a commit 89401a3

File tree

1 file changed

+8
-5
lines changed

1 file changed

+8
-5
lines changed

blog-app/src/views/blog/BlogView.vue

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@
7171
<img class="me-view-picture" :src="c.author.avatar"></img>
7272
</a>
7373
<div class="me-view-info">
74-
<span>{{c.author.nickname}}</span>
74+
<span class="me-view-nickname">{{c.author.nickname}}</span>
7575
<div class="me-view-meta">
7676
<span>{{comments.length - index}}楼</span>
7777
<span>{{c.createDate}}</span>
@@ -170,8 +170,8 @@ export default {
170170
171171
publishComment(that.comment).then(data => {
172172
that.$message({type: 'success', message: '评论成功',showClose: true})
173-
that.comments.push(data.data)
174-
173+
that.comments.unshift(data.data)
174+
that.comment.content = ''
175175
}).catch(error => {
176176
if(error !== 'error'){
177177
that.$message({type: 'error', message: '评论失败',showClose: true})
@@ -224,8 +224,8 @@ export default {
224224
vertical-align: middle;
225225
}
226226
.me-view-picture {
227-
width: 48px;
228-
height: 48px;
227+
width: 40px;
228+
height: 40px;
229229
border: 1px solid #ddd;
230230
border-radius: 50%;
231231
vertical-align: middle;
@@ -279,6 +279,9 @@ export default {
279279
margin: 10px 0;
280280
vertical-align: middle;
281281
}
282+
.me-view-nickname {
283+
font-size: 14px;
284+
}
282285
.me-view-comment-content {
283286
line-height: 1.5;
284287
}

0 commit comments

Comments
 (0)