Skip to content

Ability to have multiple separate widget instances on the same page #753

Description

@1AhmedYasser

AS A user
I WANT to be able to have multiple chats in the same page
SO THAT i can for example search and talk to chat widget and the same time

Acceptance Criteria

  • Separate local and session storage settings via name spaces
  • Add multi widget support for local development npm run start:multi-widget

Cookie collision

  • Modify chatId in chatJwt cookie to chatIds that holds all chats opened in that page
  • When chat starts, it should add the new chat id to chatIds array, so it would not overwrite the existing cookie
  • When chat ends, If chatId is specified, it will remove the uuid from the chatIds string array
  • When chat ends, If chatId is not specified, it will remove the cookie as it does now
  • On every api call, If chatId is specified, it will check against the chatJwt cookie chatIds string array, if the id exists, if not in array, we should deny any further action for security.
  • On every api call, If chatId is not specified, it will use the default chatId from the chatJwt cookie
  • chatId query parameter is not mandatory, because then we don’t need to pass it in case of one widget

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

v3.3.3Release v3.3.3

Type

Projects

Relationships

None yet

Development

No branches or pull requests

Issue actions