fix(avatar): chat avatar is centered instead of bottom aligned when using the cdn file by sulimanbenhalim · Pull Request #4728 · saadeghi/daisyui · GitHub
Skip to content

fix(avatar): chat avatar is centered instead of bottom aligned when using the cdn file - #4728

Open
sulimanbenhalim wants to merge 1 commit into
saadeghi:masterfrom
sulimanbenhalim:fix-avatar-align-layer
Open

fix(avatar): chat avatar is centered instead of bottom aligned when using the cdn file#4728
sulimanbenhalim wants to merge 1 commit into
saadeghi:masterfrom
sulimanbenhalim:fix-avatar-align-layer

Conversation

@sulimanbenhalim

Copy link
Copy Markdown
Contributor

if you load daisyui from the cdn file the avatar in a chat bubble floats to the middle instead of sitting at the bottom like the docs show. the plugin build is fine, which is why nobody noticed on daisyui.com.

turns out .avatar and .chat-image both set align-self at the same level, and in the packed css the avatar rule just happens to come last and win. this moves the avatar default one layer down so the chat one wins no matter the order.

repro with the cdn file, the second chat has the fix: https://play.tailwindcss.com/gqg4K0Ukhs

@github-actions

github-actions Bot commented Sep 3, 2026

Copy link
Copy Markdown

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant