         position: position
 
     onAgentTypingStart: =>
+      if @stopTypingId
+        clearTimeout(@stopTypingId)
+      @stopTypingId = setTimeout(@onAgentTypingEnd, 3000)
+
       # never display two typing indicators
       return if @el.find('.zammad-chat-message--typing').size()
 

              when 'queue'
                @onQueue pipe.data.position
                @session_id = pipe.data.session_id
          when 'chat_status'
            switch pipe.data.state
              when 'online'
                @onReady()

          when 'chat_session_typing'
            return if pipe.data.self_written
            @onAgentTypingStart()
          when 'chat_session_start'
            switch pipe.data.state
              when 'ok'
