Fix avatar image placement in Chatbot (#9769)

* fix avatar images in chatbot

* add changeset

* revert comments

---------

Co-authored-by: gradio-pr-bot <gradio-pr-bot@users.noreply.github.com>
Co-authored-by: pngwn <hello@pngwn.io>
This commit is contained in:
Hannah 2024-10-22 21:55:48 +01:00 committed by GitHub
parent 6ba2e59ea7
commit 3b9ed299e9
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 7 additions and 6 deletions

View File

@ -0,0 +1,6 @@
---
"@gradio/chatbot": patch
"gradio": patch
---
fix:Fix avatar image placement in Chatbot

View File

@ -226,18 +226,13 @@
/* avatar styles */
.avatar-container {
flex-shrink: 0;
width: 35px;
height: 35px;
border-radius: 50%;
border: 1px solid var(--border-color-primary);
overflow: hidden;
}
.avatar-container :global(img) {
width: 100%;
height: 100%;
object-fit: cover;
padding: 6px;
}
/* message wrapper */
@ -264,7 +259,7 @@
border: none;
}
.message-row :global(img) {
.message-row :not(.avatar-container) :global(img) {
margin: var(--size-2);
max-height: 300px;
}