Advertisement
Guest User

Untitled

a guest
Jan 4th, 2021
190
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. <script>
  2. (function() {
  3. function onTidioChatApiReady() {
  4. window.tidioChatApi.hide();
  5. window.tidioChatApi.on("close", function() {
  6. window.tidioChatApi.hide();
  7. });
  8. }
  9. if (window.tidioChatApi) {
  10. window.tidioChatApi.on("ready", onTidioChatApiReady);
  11. } else {
  12. document.addEventListener("tidioChat-ready", onTidioChatApiReady);
  13. }
  14. document.querySelector(".chat-button").addEventListener("click", function() {
  15. window.tidioChatApi.show();
  16. window.tidioChatApi.open();
  17. });
  18. })();
  19. </script>
Advertisement
Advertisement
Advertisement
RAW Paste Data Copied
Advertisement