mirror of
https://gh.wpcy.net/https://github.com/discourse/discourse.git
synced 2026-05-21 05:54:19 +08:00
When a user card is rendered, there are two phases: first, where a placeholder is created, then after the user card data is retrieved, the data is inserted into the user card structure. This causes an issue where, if the placeholder is too close to the bottom of the viewport, and there's a lot of data being inserted into the user card, then the user card will be partially rendered outside of the viewport, resulting in odd scrolling behaviour. To address this issue, this change makes use of float-kit's ability to auto-update the position of the user-card. There are three relevant UX changes from this: - When the avatar is close to the bottom of the viewport, the placeholder renders below the avatar, and the final user card is much bigger, the user card will jump from being below the avatar, to above the avatar. - The user card follows the avatar when the chat window scrolls. - When the avatar scrolls out of view, the user card is hidden. |
||
|---|---|---|
| .. | ||
| javascripts | ||
| stylesheets | ||