I'll give you a bit of context, there are 2 different flows inside the same chatbot, one flow triggers if you have the localStorage key "triggerMode" the other one triggers if you dont have that key. You get assigned that key if you click a button inside the website, with that being said, i'll explain the problem.
- Steps to reproduce:
Click the bubble that opens the chatbot with the main flow
Click a button inside the website that listens for a click to execute the script
Once clicked the button, it should do this:
Close the chatbot
Unmount the current chatbot
Initiate the chatbot with a different flow given the apiHost & typebot
Then open the chatbot and continue with the flow
- What is happening, is that when you click the button inside the website, the chatbot closes & unmounts, but it wont mount again and the bubble disappears.
- I expect when clicking on the button, the bot would unmount, and mount again given the parameters provided.