added chat functionality so enter button can be used to submit text to chat window