chat-ui-kit-react icon indicating copy to clipboard operation
chat-ui-kit-react copied to clipboard

Widened Firefox scroll error range to 10px

Open nzayatz14 opened this issue 2 years ago • 0 comments

Hi @supersnager,

I believe I managed to patch the scrolling issue we were running into on Firefox with the MessageList component described here. All I did was widen the scrolling error to 10px. I thought this was reasonable because the perfect-scrollbar component you are using also used a 10px range:

if (e.deltaMode && e.deltaMode === 1) {
      // Firefox in deltaMode 1: Line scrolling
      deltaX *= 10;
      deltaY *= 10;
    }

This is not a permanent solution, but it should suffice until you get around to overhauling the scrolling logic like you said you would.

Hope this helps, Nick

nzayatz14 avatar Aug 16 '21 13:08 nzayatz14