Spaces:
Sleeping
Sleeping
Update styles.py
Browse files
styles.py
CHANGED
|
@@ -152,55 +152,36 @@ position:absolute; right:16px; top:10px; font-weight:700; font-size:28px; letter
|
|
| 152 |
|
| 153 |
/* === Chatbot 头像尺寸 & 对齐(稳定版)=== */
|
| 154 |
|
| 155 |
-
/*
|
| 156 |
-
|
| 157 |
-
|
| 158 |
-
width:
|
| 159 |
-
height:
|
| 160 |
-
min-width:
|
| 161 |
-
min-height:
|
| 162 |
border-radius: 9999px !important;
|
| 163 |
overflow: hidden !important;
|
| 164 |
-
border: 2px solid #ffffffcc !important;
|
| 165 |
box-shadow: 0 2px 6px rgba(0,0,0,.25) !important;
|
| 166 |
flex-shrink: 0 !important;
|
| 167 |
-
align-self: flex-start !important;
|
| 168 |
-
margin-top: 2px !important;
|
| 169 |
}
|
| 170 |
|
| 171 |
-
/* 图片填充容器,不变形
|
| 172 |
-
|
|
|
|
| 173 |
width: 100% !important;
|
| 174 |
height: 100% !important;
|
| 175 |
-
object-fit: cover !important;
|
| 176 |
object-position: 50% 50% !important;
|
| 177 |
display: block !important;
|
| 178 |
border: 0 !important;
|
| 179 |
background: transparent !important;
|
| 180 |
}
|
| 181 |
|
| 182 |
-
/* 头像与气泡的间距
|
| 183 |
-
|
| 184 |
-
|
| 185 |
-
gap: 12px !important;
|
| 186 |
-
}
|
| 187 |
-
|
| 188 |
-
/* 兼容某些版本的栅格/列宽(保证头像列能放下 72px) */
|
| 189 |
-
#poker_chat [class*="grid"],
|
| 190 |
-
#poker_chat [class*="row"]{
|
| 191 |
-
--chatbot-avatar-size: 72px; /* 若新版本用到自定义变量,可利用 */
|
| 192 |
-
}
|
| 193 |
-
|
| 194 |
-
/* 移动端略微缩小 */
|
| 195 |
-
@media (max-width: 820px){
|
| 196 |
-
#poker_chat :is(.avatar, .avatar-wrap, .gr-avatar, [class*="avatar"]){
|
| 197 |
-
width: 56px !important;
|
| 198 |
-
height: 56px !important;
|
| 199 |
-
min-width: 56px !important;
|
| 200 |
-
min-height: 56px !important;
|
| 201 |
-
border-width: 1.5px !important;
|
| 202 |
-
}
|
| 203 |
-
}
|
| 204 |
|
| 205 |
|
| 206 |
"""
|
|
|
|
| 152 |
|
| 153 |
/* === Chatbot 头像尺寸 & 对齐(稳定版)=== */
|
| 154 |
|
| 155 |
+
/* 放大 Chatbot 头像(统一设置) */
|
| 156 |
+
.custom-chatbot .avatar,
|
| 157 |
+
.custom-chatbot .message .avatar{
|
| 158 |
+
width: 88px !important; /* ← 改这里:56/64/72 都可以 */
|
| 159 |
+
height: 88px !important;
|
| 160 |
+
min-width: 88px !important;
|
| 161 |
+
min-height: 88px !important;
|
| 162 |
border-radius: 9999px !important;
|
| 163 |
overflow: hidden !important;
|
| 164 |
+
border: 2px solid #ffffffcc !important; /* 可选描边 */
|
| 165 |
box-shadow: 0 2px 6px rgba(0,0,0,.25) !important;
|
| 166 |
flex-shrink: 0 !important;
|
| 167 |
+
align-self: flex-start !important; /* 与气泡顶部对齐 */
|
|
|
|
| 168 |
}
|
| 169 |
|
| 170 |
+
/* 头像图片填充容器,不变形 */
|
| 171 |
+
.custom-chatbot .avatar > img,
|
| 172 |
+
.custom-chatbot .avatar-image{
|
| 173 |
width: 100% !important;
|
| 174 |
height: 100% !important;
|
| 175 |
+
object-fit: cover !important; /* ▶ 若想完整显示头像不裁剪,改为 contain */
|
| 176 |
object-position: 50% 50% !important;
|
| 177 |
display: block !important;
|
| 178 |
border: 0 !important;
|
| 179 |
background: transparent !important;
|
| 180 |
}
|
| 181 |
|
| 182 |
+
/* 头像与气泡的间距与对齐(可选) */
|
| 183 |
+
.custom-chatbot .message{ gap: 12px !important; align-items: flex-start !important; }
|
| 184 |
+
.custom-chatbot .message .message-content{ margin-top: 2px !important; }
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 185 |
|
| 186 |
|
| 187 |
"""
|