From a5f7c86a4b19207ee7850a95cfb82a9969656e61 Mon Sep 17 00:00:00 2001 From: stefanfeng Date: Fri, 7 Aug 2026 14:04:45 +0800 Subject: [PATCH] fix: avatar list table full-width and image fallback - Changed fixed width columns to min-width for elastic layout - Add @error handler on el-avatar to hide broken images and show emoji - Detail dialog avatar also handles image load errors --- frontend/src/views/Avatars.vue | 21 ++++++++++++++++----- 1 file changed, 16 insertions(+), 5 deletions(-) diff --git a/frontend/src/views/Avatars.vue b/frontend/src/views/Avatars.vue index 118a79e..fc2fd00 100644 --- a/frontend/src/views/Avatars.vue +++ b/frontend/src/views/Avatars.vue @@ -23,10 +23,13 @@ - + - + - + @@ -92,9 +95,12 @@
- + {{ detailAvatar.emoji || '🤖' }} + + {{ detailAvatar.emoji || '' }} +
{{ detailAvatar.name }}
{{ detailAvatar.display_name }}
@@ -249,6 +255,11 @@ function openDetail(row) { detailVisible.value = true } +function handleAvatarError(e) { + // 图片加载失败时隐藏 img,只保留 emoji fallback + e.target.style.display = 'none' +} + function rowClassName({ rowIndex }) { return rowIndex % 2 === 0 ? 'row-dark' : 'row-darker' }