I spent a bit of time debugging why Firefox mobile is so annoying to use with the new Assistant. I believe the main problem is the logic that detects if the scroll-down button should be hidden doesn't take into account dynamic viewport resizing (e.g when the document is scrolled, the browser expands the viewport instead of scrolling the actual document):
The code that Kagi uses is basically this (in the scroll event handler):
1 <= document.documentElement.scrollHeight - document.documentElement.clientHeight - document.documentElement.scrollTop
Under mobile Firefox (with a device touch screen, this does not occur when emulating Firefox/the viewport), this calculation is off by 56px (on my device and pixel density). This number is coming from the difference between 100lvh
and 100svh
, or the size of the address bar on my setup (that is scrolled before the document is scrolled).
This causes the sources to be covered up by the sticky .bottom-box
:
Ideally, as on desktop or desktop emulating mobile/touch, the scroll down button (and friends) would be hidden, preventing touch inputs from being eaten by the wrong element.