!function(e,t){"use strict";var i=0,a=1,r=2;e.RumbleTalkChat||(e.RumbleTalkChat={defaultContent:"width=device-width, initial-scale=1, maximum-scale=1",adjustViewport:function(){var i=t.querySelector('[name="viewport"]');if(i){var a=i.getAttribute("content");if(a){var r=!1,n=a.split(",").map((function(e){return(e=e.trim()).startsWith("maximum-scale")&&(r=!0),e}));r||n.push("maximum-scale=1"),a=n.join(", ")}else a=e.RumbleTalkChat.defaultContent;i.setAttribute("content",a)}else(i=t.createElement("meta")).setAttribute("name","viewport"),i.setAttribute("content",e.RumbleTalkChat.defaultContent),t.head.insertBefore(i,t.head.firstChild)},init:function(n){if(e.RumbleTalkChat[n.hash])throw new Error("Trying to create a duplicate chat with code: "+n.hash);n.adjustViewport&&this.adjustViewport();var s,o="__rtc-"+(new Date).getTime();try{t.write('<div id="'+o+'"></div>'),s=t.getElementById(o)}catch(e){}var l=navigator.userAgent.toUpperCase(),u={mainDiv:null,parent:null,chatDiv:null,closeDiv:null,userCounterDiv:null,messageCounterDiv:null,iframe:null,protocol:"https://",server:"",hash:"",messageInterval:0,userCount:0,messageCount:0,embedType:0,width:0,height:0,image:"https://d1pfint8izqszg.cloudfront.net/images/toolbar/toolbar.png",closeImage:"https://d1pfint8izqszg.cloudfront.net/images/c.png",mobileFullscreen:!1,userCounter:!0,userCounterTop:14,userCounterLeft:23,userCounterWidth:28,userCounterPadding:"",userCounterColor:"#000",userCounterBgColor:"transparent",userCounterSize:12,userCounterBorderRadius:0,userCounterBoxShadow:"none",messageCounter:!0,messageCounterTop:0,messageCounterLeft:60,floatingToggleInterval:0,baseWebUrl:"https://rumbletalk.com/",serviceRelativeUrl:"client/service.php?hash=",mobile:-1!==l.indexOf("MOBILE")||-1!==l.indexOf("ANDROID")||-1!==l.indexOf("IOS"),cdn:"",init:function(e){switch(u.mainDiv=t.getElementById(e.divId),u.mainDiv?s&&s.parentNode.removeChild(s):u.mainDiv=s,u.parent=u.mainDiv.parentNode,e.baseWebUrl&&(u.baseWebUrl=e.baseWebUrl),u.server=e.server,u.hash=e.hash,u.cdn=e.cdn,u.embedType=e.embedType,u.width=e.width,u.height=e.height,u.image=e.image,u.userCounter=e.showDetails,u.side=0===e.side?"right":"left",u.parseDivData(),u.mobile||u.embedType!==r||(u.embedType=i),u.embedType){case i:u.mainDiv.className="rumbletalk-embed",u.buildIframe(u.mainDiv),u.size();break;case a:u.mainDiv.className="rumbletalk-floating rumbletalk-floating-"+u.side,u.drawFloatingImage(u.side),u.mobile&&!u.mobileFullscreen?u.openChat(u.mainDiv):(u.buildFloatingDiv(u.side),u.buildIframe(u.chatDiv));break;case r:u.mainDiv.className="rumbletalk-embed-image",u.drawImage(u.mainDiv),u.openChat(u.mainDiv)}u.addListeners()},parseDivData:function(){var e,t,i=["width","height"];for(e=0;e<i.length;e++)(t=u.mainDiv.getAttribute("data-"+i[e]))&&(u[i[e]]=t);null!==(t=u.mainDiv.getAttribute("data-floating"))&&"false"!==t&&(u.embedType=a,null!=(t=u.mainDiv.getAttribute("data-image"))&&(u.image=t),null!=(t=u.mainDiv.getAttribute("data-close-image"))&&(u.closeImage=t),null!=(t=u.mainDiv.getAttribute("data-side"))&&(u.side="left"===t?"left":"right"),null!=(t=u.mainDiv.getAttribute("data-mobile-fullscreen"))&&"true"===t&&(u.mobileFullscreen=!0),(t=u.mainDiv.getAttribute("data-user-counter"))&&"false"!==t?(u.userCounter=!0,-1!==t.indexOf(",")&&((t=t.split(","))[0]=Number(t[0]),isNaN(t[0])||(u.userCounterTop=t[0]),t[1]=Number(t[1]),isNaN(t[1])||(u.userCounterLeft=t[1])),(t=u.mainDiv.getAttribute("data-user-counter-width"))&&(u.userCounterWidth=t),((t=u.mainDiv.getAttribute("data-user-counter-padding"))||"0"===t||"0px"===t)&&(u.userCounterPadding=t),(t=u.mainDiv.getAttribute("data-user-counter-color"))&&(u.userCounterColor=t),(t=u.mainDiv.getAttribute("data-user-counter-bg-color"))&&(u.userCounterBgColor=t),(t=u.mainDiv.getAttribute("data-user-counter-size"))&&(u.userCounterSize=t),(t=u.mainDiv.getAttribute("data-user-counter-border-radius"))&&(u.userCounterBorderRadius=t),(t=u.mainDiv.getAttribute("data-user-counter-box-shadow"))&&(u.userCounterBoxShadow=t)):u.userCounter=!1,(t=u.mainDiv.getAttribute("data-message-counter"))&&"false"!==t?(u.messageCounter=!0,-1!==t.indexOf(",")&&((t=t.split(","))[0]=Number(t[0]),isNaN(t[0])||(u.messageCounterTop=t[0]),t[1]=Number(t[1]),isNaN(t[1])||(u.messageCounterLeft=t[1]))):u.userCounter=!1)},buildIframe:function(i){i.style.overflow="hidden",u.iframe=t.createElement("iframe"),u.iframe.src=u.protocol+u.server+"/"+u.hash+"/#"+e.location.href,u.iframe.setAttribute("allow","microphone; camera; fullscreen; autoplay; display-capture"),u.mobile&&u.mobileFullscreen?(u.iframe.style.width="100%",u.iframe.style.height="calc(100% - 30px)",u.iframe.style.top="30px"):(u.iframe.style.width=u.width+"px",u.iframe.style.height="100%"),u.iframe.style.overflow="hidden",u.iframe.style.border=0,u.iframe.style.backgroundColor="transparent",i.appendChild(u.iframe)},drawImage:function(e){var i=new Image,a="Click here to join the chat";e.style.textAlign="center",i.src=u.cdn+"images/mobile-redirect.png",i.style.cursor="pointer",i.alt=a,i.setAttribute("role","link"),e.appendChild(i);var r=t.createElement("h3");r.innerHTML=a,r.setAttribute("role","link"),e.appendChild(r)},drawFloatingImage:function(e){u.mainDiv.style.position="fixed",u.mainDiv.style.bottom="5px",u.mainDiv.style[e]="5px",u.mainDiv.style.zIndex=1e3;var i=new Image;if(i.onload=function(){u.mainDiv.style.height=i.height+"px",u.mainDiv.style.width=i.width+"px",u.mainDiv.style.maxWidth="100px",u.mainDiv.style.maxHeight="100px",u.mobile&&u.mobileFullscreen||(u.chatDiv.style.bottom=i.height+"px")},i.src=u.image,i.style.maxWidth="100px",i.style.maxHeight="100px",i.style.position="absolute",i.style.bottom=0,i.style[e]=0,i.alt="Click to join the conversation",i.title="Click to join the conversation",u.mainDiv.appendChild(i),u.userCounter){if(u.userCounterDiv=t.createElement("div"),u.userCounterDiv.style.position="absolute",u.userCounterDiv.style.top=u.userCounterTop+"px",u.userCounterDiv.style.left=u.userCounterLeft+"px",u.userCounterDiv.style.width=u.userCounterWidth+"px",u.userCounterDiv.style.padding=u.userCounterPadding,u.userCounterDiv.style.textAlign="center",u.userCounterDiv.style.font="bold 12px arial",u.userCounterDiv.style.fontSize=u.userCounterSize+"px",u.userCounterDiv.style.color=u.userCounterColor,u.userCounterDiv.style.backgroundColor=u.userCounterBgColor,u.userCounterDiv.style.borderRadius=u.userCounterBorderRadius+"%",u.userCounterDiv.style.boxShadow=u.userCounterBoxShadow,u.userCounterDiv.style.userSelect="none",!u.mobile){var a=new Image;a.src=u.cdn+"images/toolbar/mini_wait.gif",a.alt="loading",u.userCounterDiv.appendChild(a)}u.mainDiv.appendChild(u.userCounterDiv)}return u.messageCounter&&(u.messageCounterDiv=t.createElement("div"),u.messageCounterDiv.style.display="none",u.messageCounterDiv.style.position="absolute",u.messageCounterDiv.style.top=u.messageCounterTop+"px",u.messageCounterDiv.style.left=u.messageCounterLeft+"px",u.messageCounterDiv.style.width="24px",u.messageCounterDiv.style.textAlign="center",u.messageCounterDiv.style.font="bold 12px arial",u.messageCounterDiv.style.color="#fff",u.messageCounterDiv.style.backgroundColor="#C1272D",u.messageCounterDiv.style.borderRadius="50%",u.messageCounterDiv.style.borderRadius="50%",u.messageCounterDiv.style.padding="5px 1px",u.mainDiv.appendChild(u.messageCounterDiv)),i},buildFloatingDiv:function(e){if(u.chatDiv=t.createElement("div"),u.chatDiv.style.position="absolute",u.chatDiv.style.bottom="75px",u.chatDiv.style[e]=0,u.chatDiv.style.visibility="hidden",u.chatDiv.style.overflow="hidden",u.chatDiv.style.padding=0,u.chatDiv.style.height=0,u.mobile&&u.mobileFullscreen&&(u.chatDiv.style.position="fixed",u.chatDiv.style.width="100%",u.chatDiv.style.height="100%",u.chatDiv.style.top=0,u.chatDiv.style.right=0,u.chatDiv.style.bottom=0,u.chatDiv.style.left=0,u.chatDiv.style.zIndex=1e4),u.mainDiv.appendChild(u.chatDiv),u.mainDiv.onclick=u.mobile&&u.mobileFullscreen?u.toggleFloatingChatInFullScreen:u.toggleFloatingChatStart,u.mainDiv.style.cursor="pointer",u.mobile&&u.mobileFullscreen)u.closeDiv=t.createElement("div"),u.closeDiv.style.display="flex",u.closeDiv.style.alignItems="center",u.closeDiv.style.height="30px",u.closeDiv.style.width="100%",u.closeDiv.style.paddingLeft="0.5rem",u.closeDiv.style.color="#007bff",u.closeDiv.style.backgroundColor="#fff",u.closeDiv.style.textDecoration="underline",u.closeDiv.style.font="normal 1em arial",u.closeDiv.textContent="Close",u.closeDiv.onclick=u.toggleFloatingChatInFullScreen,u.chatDiv.appendChild(u.closeDiv);else{var i=new Image,a="right"===e?"left":"right";i.src=u.closeImage,i.style.cursor="pointer",i.style.position="absolute",i.style.top="-9px",i.style[a]="-8px",i.style.maxWidth="24px",i.style.maxHeight="24px",i.onclick=function(){u.toggleFloatingChatStart(!0)},u.chatDiv.appendChild(i)}},openChat:function(t){var i,a=u.baseWebUrl+"client/chat.php?"+u.hash;t.onclick=function(){u.iframe?u.iframe.focus():(u.iframe=e.open(a),u.iframe.addEventListener("load",u.load,!1),i=setInterval((function(){u.iframe.closed&&(clearInterval(i),"function"==typeof u.iframe.removeEventListener&&u.iframe.removeEventListener("load",u.load),delete u.iframe)}),100))}},summarizedStyleValues:function(t,i){var a,r,n=0;for(a=0;a<i.length;a+=1)r=e.getComputedStyle?e.getComputedStyle(t,"")[i[a]]:t.currentStyle[i[a]],isNaN(parseInt(r))&&(r=0),n+=parseInt(r);return n},size:function(){var i=0,a=0;if(u.iframe){if("rumbletalk-chat-fullscreen"===u.parent.id&&e.innerWidth>0&&e.innerHeight>0?(i=e.innerWidth,a=e.innerHeight):u.parent.clientWidth>0&&u.parent.clientHeight>0?(i=u.parent.clientWidth,a=u.parent.clientHeight):u.summarizedStyleValues(u.parent,["width"])>0&&u.summarizedStyleValues(u.parent,["height"])>0?(i=u.summarizedStyleValues(u.parent,["width"]),a=u.summarizedStyleValues(u.parent,["height"])):parseInt(u.parent.width)>0&&parseInt(u.parent.height)>0&&(i=parseInt(u.parent.width),a=parseInt(u.parent.height)),i>0&&a>0){var r="CSS1Compat"===t.compatMode?0:u.summarizedStyleValues(u.parent,["marginLeft","marginRight","paddingLeft","paddingRight"]);i=i-r+"px",r=u.mainDiv.childNodes.length>1?28:0,a=a-u.summarizedStyleValues(u.parent,["marginTop","marginBottom","paddingTop","paddingBottom"])-r+"px"}else i="100%",a="100%";u.iframe.style&&(u.iframe.style.width=i,u.iframe.style.height=a)}},query:function(){try{var e,t;u.iframe instanceof HTMLIFrameElement?(e=u.iframe.contentWindow,t=u.protocol+u.server):(e=u.iframe,t=u.baseWebUrl),e.postMessage("toolbar",t)}catch(e){}},info:function(e){u.validateOrigin(e.origin)&&(isFinite(e.data)?(clearInterval(u.messageInterval),u.userCount=e.data,u.userCounterDiv&&(u.userCounterDiv.innerHTML=u.userCount.toString())):"object"==typeof e.data&&(e.data.reload&&u.reload(),void 0!==e.data.pm&&(clearInterval(u.messageInterval),u.messageCount=e.data.pm,u.messageCounterDiv&&(u.messageCount>0?(u.messageCounterDiv.style.display="block",u.messageCounterDiv.textContent=u.messageCount.toString()):(u.messageCounterDiv.style.display="none",u.messageCounterDiv.textContent="")))))},reload:function(){var t=new XMLHttpRequest;t.open("GET",u.baseWebUrl+u.serviceRelativeUrl+u.hash,!0),t.onreadystatechange=function(){if(4===t.readyState)try{var i=JSON.parse(t.responseText);if(i.status){if(void 0!==e.rumbleTalkMessageQueueName)return void location.reload();u.server=i.address;var a=u.protocol+u.server+"/"+u.hash+"/#"+e.location.href;u.iframe instanceof HTMLIFrameElement?u.iframe.src===a?(u.iframe.src=u.cdn+"images/toolbar/mini_wait.gif",setTimeout((function(){u.iframe.src=a}),50)):u.iframe.src=a:u.iframe.location.href===a?(u.iframe.location.href=u.cdn+"images/toolbar/mini_wait.gif",setTimeout((function(){u.iframe.location.href=a}),50)):u.iframe.location.href=a}}catch(e){location.reload()}},t.send()},addListeners:function(){e.addEventListener("message",u.info,!1),u.embedType===i&&e.addEventListener("resize",u.size,!1),u.mobile||u.embedType!==a||e.addEventListener("keyup",u.escClose,!1),u.iframe&&u.iframe.addEventListener("load",u.load,!1)},toggleFloatingChatStart:function(e){clearInterval(u.floatingToggleInterval);var t=-100;"hidden"===u.chatDiv.style.visibility&&!0!==e&&(t*=-1,u.chatDiv.style.width=0,u.chatDiv.style.height=0,u.chatDiv.style.visibility="visible",u.chatDiv.style.overflow="visible"),u.floatingToggleInterval=setInterval((function(){u.toggleFloatingChat(t)}),1)},toggleFloatingChat:function(e){var t=u.chatDiv.offsetWidth+e,i=u.chatDiv.offsetHeight+e,a=0;t<0&&(t=0),i<0&&(i=0),t>=0&&i>=0&&(t<=u.width?a=1:t=u.width,i<=u.height?a=1:i=u.height,u.chatDiv.style.width=t+"px",u.chatDiv.style.height=i+"px"),(!a||t<=0||i<=0)&&(clearInterval(u.floatingToggleInterval),t<u.width&&(u.chatDiv.style.visibility="hidden",u.chatDiv.style.overflow="hidden"))},toggleFloatingChatInFullScreen:function(e){e.stopPropagation(),"hidden"===u.chatDiv.style.visibility?u.chatDiv.style.visibility="visible":u.chatDiv.style.visibility="hidden"},escClose:function(e){"Escape"===e.key&&u.toggleFloatingChatStart(!0)},validateOrigin:function(e){return/^https:\/\/.+\.rumbletalk\.(net|com)(:4433)?$/.test(e)},load:function(){u.messageInterval=setInterval(u.query,1e3)}};return u.init(n),u}})}(window,document);RumbleTalkChat['_Cmt0a6F'] = RumbleTalkChat.init({"hash":"_Cmt0a6F","adjustViewport":true,"server":"service22.rumbletalk.net","divId":"rt-ca0d62c947617bf96eff1ec56ab29369","side":0,"embedType":0,"cdn":"https:\/\/d1pfint8izqszg.cloudfront.net\/","baseWebUrl":"https:\/\/rumbletalk.com\/","width":750,"height":500,"bounce":4,"image":"https:\/\/d1pfint8izqszg.cloudfront.net\/images\/toolbar\/toolbar.png","showDetails":1});