This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script> | |
/* Hide Gist Messenger Launcher on page load */ | |
gist.chat('hideLauncher'); | |
/* open the Messenger when you receive a message */ | |
document.addEventListener("onGistUnreadCountChange", function(e) { | |
if(window.gistUnreadCount > 0) { | |
gist.chat('open'); | |
} | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<<!DOCTYPE html> | |
<html> | |
<head> | |
<title></title> | |
<style type="text/css"> | |
iframe { | |
width: 100%; | |
height: 100vh; | |
padding: 0; | |
margin: 0; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{% if subscriber.country == "United States"%} | |
Subscribers from USA will see this | |
{% elsif subscriber.country == "Italy" %} | |
Subscribers from Italy will see this | |
{% else %} | |
Subscribers from other countries will see this | |
{% endif %} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!-- place this script tag after the Gist & Segment tracking code --> | |
<script> | |
// sends logged-in user data to Gist when Segment's identify method is called | |
analytics.on('identify', function(event, properties, options) { | |
gist.identify(event ? event : '', properties); | |
}); | |
// sends events to Gist when Segment's track method is called | |
analytics.on('track', function(event, properties, options) { | |
gist.track(event, properties); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!-- place this script tag after the Gist tracking code --> | |
<script> | |
// open the Messenger widget when you receive a message | |
document.addEventListener('gistChatReady', function () { | |
document.addEventListener("onGistUnreadCountChange", function(e) { | |
if (window.gistUnreadCount > 0 || $('.gist-messenger-iframe').css('display') === 'block') { | |
gist.chat("showLauncher"); | |
} else { | |
gist.chat("hideLauncher"); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!-- start Gist JS code--> | |
<script type="text/javascript"> | |
//<![CDATA[ | |
var WORKSPACE_ID = "XXXXXXX" // Replace XXXXXXX with your Workspace ID | |
(function(d,h,w){var gist=w.gist=w.gist||[];gist.methods=['trackPageView','identify','track','setAppId'];gist.factory=function(t){return function(){var e=Array.prototype.slice.call(arguments);e.unshift(t);gist.push(e);return gist;}};for(var i=0;i<gist.methods.length;i++){var c=gist.methods[i];gist[c]=gist.factory(c)}s=d.createElement('script'),s.src="https://widget.getgist.com",s.async=!0,e=d.getElementsByTagName(h)[0],e.appendChild(s),s.addEventListener('load',function(e){},!1),gist.setAppId(WORKSPACE_ID),gist.trackPageView()})(document,'head',window); | |
//]]> | |
</script> | |
<!-- end Gist JS code--> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<head> | |
<meta charset="utf-8"> | |
<meta http-equiv="X-UA-Compatible" content="IE=edge"> | |
<meta name="x-apple-disable-message-reformatting"/> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0"> | |
<title>Gist</title> | |
<style> | |
.personal-email { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React from "react"; | |
import { useEffect } from "react"; | |
export default function App() { | |
useEffect(() => { | |
const script = document.createElement("script"); | |
script.src = "https://meeting-widget.getgist.com/"; | |
script.async = true; |