teneo-web-chat icon indicating copy to clipboard operation
teneo-web-chat copied to clipboard

Upload message shows IN_PROGRESS after chat minimize or refresh

Open sergey124 opened this issue 2 years ago • 0 comments

Summary

After chat window minimize, or page refresh, Upload Message shows as IN_PROGRESS, even though it was DELETED, FAILED or SUCCEEDED.

Steps to reproduce

  1. Open Chat window
  2. Hit Upload button
  3. Select a file
  4. Submit
  5. See Upload Message item
  6. Hit "Delete" on Upload Message 1_message_state_after_delete
  7. Minimize Chat window
  8. Restore Chat window
  9. See Upload Message item 1_message_state_after_minimize_chat

Expected behavior

Upload Message item is shown as DELETED

Actual behavior

Upload Message item is shown as IN_PROGRESS. It seems like the updating history on Upload Message state change is missing. History TeneoWebChat.get('chat_history') is:

[
  {
    "type": "upload",
    "author": "user",
    "data": {
      "itemId": "_3_llc1efz9_6rueogk065o",
      "fileName": "kitten.jpg",
      "fileSymbol": "jpg",
      "initialUploadState": {
        "status": "IN_PROGRESS",
        "controlAllowed": true
      }
    }
  }
]

sergey124 avatar Aug 15 '23 09:08 sergey124