feat(web): hide the composer while reading history on narrow screens - #17
feat(web): hide the composer while reading history on narrow screens#17Antisophy wants to merge 1 commit into
Conversation
iOS pins the composer above the on-screen keyboard, then lets the two drift apart as soon as the page scrolls: the box ends up floating over a gap, and only a drag that starts inside it puts them back together. The page cannot see that drift, so there is nothing to correct against. Scrolling up to read is also the moment neither the composer nor the keyboard is wanted, so leaving the bottom of the message list now hides the composer and blurs the field, which is what actually dismisses the keyboard. Returning to the bottom brings the box back; iOS will not raise the keyboard again without a tap, so that stays manual. Hiding is display:none on a component that stays mounted, so a draft in progress survives. Scoped to the same 768px breakpoint the rest of the mobile layout uses: wider screens have room for the composer and no keyboard to dismiss.
|
One of five independent changes for using cydo on a phone, split apart so each can be judged on its own:
They touch different code and can merge in any order. #15 and #17 both add rules inside the same |
I'm having a hard time picturing this, can you post a video or screenshots?
Strong disagree here - going over a long response esp. to cite it is a common use case where you exactly want both the composer and earlier history visible. Maybe one thing that can be refined here is the maximum composer height on small screens? |
iOS pins the composer above the on-screen keyboard, then lets the two drift apart as soon as the page scrolls: the box ends up floating over a gap between itself and the keyboard, and only a drag that starts inside the box puts them back together. The page cannot observe that drift, so there is nothing to correct against from script.
Scrolling up to read is also the moment when neither the composer nor the keyboard is wanted, so this leans into that: leaving the bottom of the message list hides the composer and blurs the field, which is what actually dismisses the keyboard. Returning to the bottom brings the box back.
Details worth knowing:
display: noneon a component that stays mounted, so a draft in progress survives being scrolled away from.MessageListgains anonAtBottomChangecallback, fired from the scroll listener it already runs foroverflow-anchor, with 24px of tolerance so momentum scrolling landing a pixel off zero does not toggle it.