Adding auto scrolling

If the scroll bar is at the bottom of the chatbox, messages will auto
scroll the scroll bar.
Removed unnecessary npm package
Refactoring