Estazz commited on
Commit
f16af1f
·
verified ·
1 Parent(s): 9e15a05

Update styles.py

Browse files
Files changed (1) hide show
  1. styles.py +16 -35
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
- /* 1) 用容器来做圆形与描边,更不易错位 */
156
- /* === 统一放大头像到 72px(你可改成 64/80)=== */
157
- #poker_chat :is(.avatar, .avatar-wrap, .gr-avatar, [class*="avatar"]){
158
- width: 80px !important;
159
- height: 80px !important;
160
- min-width: 80px !important;
161
- min-height: 80px !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
- margin-top: 2px !important;
169
  }
170
 
171
- /* 图片填充容器,不变形不留白 */
172
- #poker_chat :is(.avatar-image, .gr-avatar > img, .avatar > img, [class*="avatar"] img){
 
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
- #poker_chat :is(.message, .wrap){
184
- align-items: flex-start !important;
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
  """