From 559d5a34b1efdaf677f23330ba5e1b3d6aeefd8a Mon Sep 17 00:00:00 2001 From: InvisibleFuture Date: Sun, 31 Jul 2022 06:08:01 +0800 Subject: [PATCH] =?UTF-8?q?=E8=81=8A=E5=A4=A9=E5=AE=A4=E5=A4=B4=E5=83=8F?= =?UTF-8?q?=20=E4=BF=AE=E6=AD=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- components/DialogueList.vue | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/components/DialogueList.vue b/components/DialogueList.vue index 802f344..b64ebfd 100644 --- a/components/DialogueList.vue +++ b/components/DialogueList.vue @@ -2,7 +2,8 @@ .dialogue-list .post(v-for="item in data", :key="item._id") .left - img.avatar(:src="item.user.avatar") + div.avatar(v-if="item.user.name === '游客'") + img.avatar(v-else :src="item.user.avatar") .right .name {{ item.user.name }} .message {{ item.data }} @@ -25,7 +26,7 @@ export default { .avatar width: 2rem height: 2rem - background: #ccc + background: #dddddd border-radius: 50% margin: .5rem auto .right