Repository navigation
fix(web): float and fade the jump-to-latest button without shrinking the composer - #21
Merged
Merged
Conversation
…the composer On narrow screens, the jump-to-latest button sat inline beside the composer and shrunk the message field when scrolled up, and it popped in and out instantly everywhere. Keep ScrollToEndButton mounted with a visibility attribute so its opacity transitions over 160ms ease-out (hiding with visibility: hidden and pointer-events: none when settled, and no transition under reduced motion). On narrow bot chats, remove the composer width-shrinking rules and float the button just above the composer at the right edge; wide screens keep the gutter placement outside the field.
This branch was successfully deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
When scrolling up in a phone chat, the jump-to-latest button popped in instantly and shrank the message field to sit inline beside it.
ScrollToEndButtonmounted with adata-visiblestate (andinert/aria-hidden/pointer-events: nonewhile hidden) so it fades in and out over160ms ease-out, hides withvisibility: hiddenonce settled so nothing repaints continuously, and switches immediately underprefers-reduced-motion: reduce.Each before/after grid shows before on the left and after on the right, using synthetic data.
Phone, 390x844 — dark (top: at the bottom with button hidden; bottom: scrolled up with button shown)
Phone, 390x844 — light (top: at the bottom with button hidden; bottom: scrolled up with button shown)
Phone, 390x844 — mid-fade frame (dark and light, captured mid-transition)
Desktop, 1440x900 — scrolled up (dark and light)