Hello,
Is there a good way to launch a popup chat with a button - this is what I mean:
Hello,
Is there a good way to launch a popup chat with a button - this is what I mean:
Best answer by mathio-tf
In your share page you can get embed snippet for popup:
Then add data-tf-chat to your embed code like this (part of the code truncated):
<button data-tf-chat data-tf-popup="<form-id>" ...>Launch me</button>
<script src="//embed.typeform.com/next/embed.js"></script>
If you want to build your own button from scratch you can use our Embed SDK. If you want full control over your embed you can build it in JavaScript. The code would look something like this:
<button id="my-awesome-button" class="my-awesome-class">open form</button>
<script src="//embed.typeform.com/next/embed.js"></script>
<link rel="stylesheet" href="//embed.typeform.com/next/css/popup.css" />
<script>
const { toggle } = window.tf.createPopup('<form-id>')
document.querySelector('#my-awesome-button').onclick = toggle
</script>
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.