Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature/#87361 delete all conversations in history #80

Merged
merged 57 commits into from
Mar 27, 2025

Conversation

vj-venkatesan
Copy link
Contributor

@vj-venkatesan vj-venkatesan commented Mar 18, 2025

Success criteria

  • Provide an option for users to delete all previous conversations directly in the webchat previous conversations.
  • Ensure a menu is provided to perform this operation
  • Ensure the menu icon is only visible when previous conversations exist for the session
  • New Previous Conversation options screen is visible when clicking the menu
  • Delete button is visible in this screen along with text
  • Ensure user confirmation alerts are displayed for the delete action.
  • Provide an option for users to delete their current conversation directly in the webchat.
  • Ensure user confirmation alerts are displayed for the action.
  • Comply with accessibility guidelines when introducing new actions (aria-labels, etc.).

How to test

Delete all Conversations

  1. Go to a webchat where previous conversations is enabled
  2. If previous conversations exists , the menu icon should appear
  3. Click that menu
  4. Verify the presence of the "Delete all conversations" button in the next screen with title Coversations Options.
  5. Click the "Delete all conversations" button and confirm the alert to ensure all previous conversations are deleted.
  6. Ensure the user lands on the previous conversation list after deleting all conversations.

Delete conversation

  1. Go to any chat options and verify the presence of the "Delete current conversation" button in the chat options.
  2. Click the "Delete current conversation" button and confirm the alert to ensure the current conversation is deleted.
  3. Ensure the user lands on the empty chat (conversation history) after deleting the current conversation.

Security

  • Possible injection vector
  • Authentication/Access controls touched
  • Sensitive Data could be exposed
  • XSS
  • Logging/Monitoring touched
  • Exchanges data with external systems
  • No security implications

Additional considerations

  • This PR might have performance implications

Documentation Considerations

Ensure documentation includes details on the new "Delete all conversations" button, user confirmation alerts, and compliance with accessibility guidelines.

@sushmi21

This comment was marked as resolved.

@sushmi21
Copy link
Contributor

When I click the 'delete all conversations' button, I do not see the list of previous conversations under the modal.

@vj-venkatesan
Copy link
Contributor Author

vj-venkatesan commented Mar 26, 2025

When I click the 'delete all conversations' button, I do not see the list of previous conversations under the modal.

Fixed it

@sushmi21
Copy link
Contributor

I see the delete button even when there are no previous conversations
Screenshot from 2025-03-26 10-11-23

@vj-venkatesan
Copy link
Contributor Author

vj-venkatesan commented Mar 26, 2025

The Delete icon color is not changed with 'deleteAllConversationIconColor'. I think we need to also apply the custom color to 'stroke' prop

Actually the path was using a default fill I have set the path color now

@kwinto
Copy link
Contributor

kwinto commented Mar 26, 2025

I have a single conversation. I delete it. Then I go to the Home screen and click "Start conversation". The conversation continues (the history is not erased). I would expect it to be empty.

You probably want to make sure the session is new in this case.

@sushmi21
Copy link
Contributor

The width of the Delete and Cancel buttons fit the content, like in figma.
Screenshot from 2025-03-26 10-44-25

@sushmi21
Copy link
Contributor

The button in the modal is not auto focused during keyboard navigation when re-opened. It does focus the first time though.

@vj-venkatesan
Copy link
Contributor Author

vj-venkatesan commented Mar 26, 2025

The button in the modal is not auto focused during keyboard navigation when re-opened. It does focus the first time though.

Just to confirm this is only when toggling delete all conversations dialog right ? coz the other modal seems fine

@vj-venkatesan
Copy link
Contributor Author

vj-venkatesan commented Mar 26, 2025

I have a single conversation. I delete it. Then I go to the Home screen and click "Start conversation". The conversation continues (the history is not erased). I would expect it to be empty.

You probably want to make sure the session is new in this case.

@kwinto I have fixed this one . Can you please check again .

  1. Upon deleting a single conversation , a new session is created and all the existing messages are cleared .
  2. Upon deleting all conversations in previous conversations screen, the current session is disconnected so if the current conversation if still sending messages won't appear again. A new session is created when you go back to home screen and try to start conversation again

@vj-venkatesan vj-venkatesan requested a review from sushmi21 March 26, 2025 13:00
@vj-venkatesan vj-venkatesan requested a review from kwinto March 26, 2025 14:12
Copy link
Contributor

@sushmi21 sushmi21 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good

@sushmi21 sushmi21 merged commit b77a79f into main Mar 27, 2025
5 checks passed
@vj-venkatesan vj-venkatesan mentioned this pull request Mar 28, 2025
8 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants