discourse/plugins/discourse-presence/assets
Kris 791908bf7b
DEV: unify presence avatar size to make layout shift less likely (#33844)
Concerns the presence indicator at the bottom of topics, "replying..."
seen here:

<img width="294" height="198" alt="image"
src="https://github.com/user-attachments/assets/3997ecee-eacd-4cf7-9754-4306434da1bc"
/>
 
 
Previously we've had cases where the min-height of this element had
regressed and ends up causing unwanted layout shift on appearance. (See
https://github.com/discourse/discourse/pull/33022)

Rather than relying on having the correct magic number here, I've
centralized the avatar size in a variable. This then gets translated to
a CSS variable and also passed to the component that renders the avatar.

This ensures that `min-height: calc(var(--avatar-min-height) + 1px);`
will be larger than the avatar and we won't have to worry about our CSS
falling out of sync.
2025-07-24 17:18:06 -04:00
..
javascripts/discourse DEV: unify presence avatar size to make layout shift less likely (#33844) 2025-07-24 17:18:06 -04:00
stylesheets DEV: unify presence avatar size to make layout shift less likely (#33844) 2025-07-24 17:18:06 -04:00