Mint: A Fresh Look at your Site Minted
  1. 1 function launch_chaty(t){(void 0==t||"widget_index"==t)&&(t=1),jQuery("#chaty-widget-0").length&&jQuery("#chaty-widget-0 .chaty-cta-button .open-chaty").trigger("click")}function close_chaty(){jQuery(".chaty.active .chaty-open").length&&jQuery(".chaty.active .chaty-open").each(function(){jQuery(this).find(".chaty-cta-close").trigger("click")})}!function(t){"use strict";"function"==typeof define&&define.amd?define(["jquery"],t):"undefined"!=typeof module&&module.exports?module.exports=t(require("jquery")):t(jQuery)}(function(t,e){function a(a){if(t("#chaty-widget-"+a).data("animation")!=e&&"none"!=t("#chaty-widget-"+a).data("animation")){var n="chaty-animation-"+t("#chaty-widget-"+a).data("animation");t("#chaty-widget-"+a+" ."+n).removeClass(n)}}function n(){var e=!1;Y.length&&t.each(Y,function(t,a){P(a.triggers.has_countries)&&!_(a.triggers.countries)&&a.triggers.countries.length&&(e=!0)}),e?(Z=q(),""!=Z?i():c()):i()}function c(){var e="https://www.cloudflare.com/cdn-cgi/trace";t.get(e,function(t){var e=t.match("loc=(.*)");e.length>1&&(e=e[1],e&&(e=e.toUpperCase(),""==e&&(e="-"),L(e),i()))})}function i(){Y.length&&(t.each(Y,function(e,a){var n="",c="",i=0,r={},d=W(a);if(d=d&&N(a),d=d&&D(a),t.each(a.channels,function(t,e){var a=s(e);a&&(i++,r=e)}),d&&i>0&&!t("#chaty-widget-"+a.id).length){var g=C(a.settings);g="right"==g?"right":"left";var y=k(a),p="<div style='display: none' class='chaty chaty-id-"+a.id+" chaty-widget-"+a.id+" chaty-key-"+e+"' id='chaty-widget-"+a.id+"' data-key='"+e+"' data-id='"+a.id+"' data-identifier='"+a.identifier+"' data-nonce='"+a.settings.widget_token+"' ><div class='chaty-widget "+g+"-position'><div class='chaty-channels'><div class='chaty-channel-list'></div><div class='chaty-i-trigger'></div></div></div></div>";t("body").append(p),P(a.triggers.auto_hide_widget)&&parseInt(a.triggers.hide_after)>0&&(t("#chaty-widget-"+a.id).addClass("auto-hide-chaty"),t("#chaty-widget-"+a.id).attr("data-time",a.triggers.hide_after));var u=Q(a.id,"c-widget");if(t("#chaty-widget-"+a.id).addClass(a.settings.show_cta),1==i){"vertical"!=a.settings.icon_view&&(y="right"!=g?"right":"left");var f=l(r,a.id,y);t("#chaty-widget-"+a.id+" .chaty-i-trigger").html(f),t("#chaty-widget-"+a.id+" .chaty-i-trigger").addClass("single-channel"),t("#chaty-widget-"+a.id+" .chaty-i-trigger .chaty-channel").addClass("single"),t("#chaty-widget-"+a.id+" .chaty-widget").addClass("has-single");var m=a.settings.cta_text;"first_click"==a.settings.show_cta&&(u?(t("#chaty-widget-"+a.id+" .chaty-tooltip").removeClass("chaty-tooltip"),t("#chaty-widget-"+a.id+" .chaty-i-trigger .chaty-channel").addClass("active").addClass("chaty-tooltip").addClass("pos-"+y),t("#chaty-widget-"+a.id+" .chaty-i-trigger .chaty-channel").append("<span class='on-hover-text'>"+m+"</span>").addClass("active").addClass("has-on-hover"),t("#chaty-widget-"+a.id+" .chaty-i-trigger .chaty-channel a").append("<span class='on-hover-text'>"+m+"</span>").addClass("has-on-hover")):t("#chaty-widget-"+a.id+" .chaty-i-trigger .chaty-channel a").append("<span class='on-hover-text'>"+m+"</span>").removeClass("active").addClass("has-on-hover")),"all_time"==a.settings.show_cta&&t("#chaty-widget-"+a.id+" .chaty-i-trigger .chaty-tooltip").append("<span class='on-hover-text'>"+m+"</span>").addClass("active").addClass("has-on-hover");var v=r;("Instagram"!=v.channel_type||"#ffffff"!=v.icon_color&&"#fff"!=v.icon_color)&&(n+="#chaty-widget-"+a.id+" ."+v.channel_type+"-channel .color-element{ fill: "+v.icon_color+"; color: "+v.icon_color+";}",n+="#chaty-widget-"+a.id+" .channel-icon-"+v.channel_type+" .color-element{ fill: "+v.icon_color+"; color: "+v.icon_color+";}"),n+="#chaty-widget-"+a.id+" ."+v.channel_type+"-channel .chaty-custom-icon { background-color: "+v.icon_color+"; }",n+="#chaty-widget-"+a.id+" ."+v.channel_type+"-channel .chaty-svg { background-color: "+v.icon_color+";}",n+="#chaty-widget-"+a.id+" .channel-icon-"+v.channel_type+" .chaty-svg { background-color: "+v.icon_color+";}","Contact_Us"==v.channel_type&&(n+=".chaty-contact-form-box #chaty-submit-button-"+a.id+" {background-color: "+v.contact_form_settings.button_bg_color+"; color: "+v.contact_form_settings.button_text_color+";} ")}else{t.each(a.channels,function(e,c){var i=s(c);if(i){x(c.channel_type)&&(c.channel_type=c.channel);var o=l(c,a.id,y);t("#chaty-widget-"+a.id+" .chaty-channel-list").append(o),("Instagram"!=c.channel_type||"#ffffff"!=c.icon_color&&"#fff"!=c.icon_color)&&(n+="#chaty-widget-"+a.id+" ."+c.channel_type+"-channel .color-element{ fill: "+c.icon_color+"; color: "+c.icon_color+";}",n+="#chaty-widget-"+a.id+" .channel-icon-"+c.channel_type+" .color-element{ fill: "+c.icon_color+"; color: "+c.icon_color+";}"),n+="#chaty-widget-"+a.id+" ."+c.channel_type+"-channel .chaty-custom-icon { background-color: "+c.icon_color+"; }",n+="#chaty-widget-"+a.id+" ."+c.channel_type+"-channel .chaty-svg { background-color: "+c.icon_color+";}",n+="#chaty-widget-"+a.id+" .channel-icon-"+c.channel_type+" .chaty-svg { background-color: "+c.icon_color+";}","Contact_Us"==c.channel_type&&(n+=".chaty-contact-form-box #chaty-submit-button-"+a.id+" {background-color: "+c.contact_form_settings.button_bg_color+"; color: "+c.contact_form_settings.button_text_color+";} ")}});var w=F(a.settings,a.id),m=a.settings.cta_text;"first_click"==a.settings.show_cta&&(u||(m=""));var b=y;"horizontal"==a.settings.icon_view&&(b="left"==g?"right":"left");var I='<div class="chaty-channel chaty-cta-main chaty-tooltip has-on-hover pos-'+b+' active" data-widget="'+a.id+'" ><span class="on-hover-text">'+m+'</span><div class="chaty-cta-button"><button type="button" class="open-chaty">'+w+'</button><button type="button" class="open-chaty-channel"></button></div></div>';t("#chaty-widget-"+a.id+" .chaty-i-trigger").html(I);var j='<div class="chaty-channel chaty-cta-close chaty-tooltip pos-'+y+'" data-hover="'+a.settings.close_text+'"><div class="chaty-cta-button"><button type="button"><span class="chaty-svg"><svg viewBox="0 0 52 52" fill="none" xmlns="http://www.w3.org/2000/svg"><ellipse cx="26" cy="26" rx="26" ry="26" fill="'+a.settings.widget_color+'"></ellipse><rect width="27.1433" height="3.89857" rx="1.94928" transform="translate(18.35 15.6599) scale(0.998038 1.00196) rotate(45)" fill="white"></rect><rect width="27.1433" height="3.89857" rx="1.94928" transform="translate(37.5056 18.422) scale(0.998038 1.00196) rotate(135)" fill="white"></rect></svg></span></button></div></div>';t("#chaty-widget-"+a.id+" .chaty-i-trigger").append(j)}var u=Q(a.id,"c-widget");!u||"open"==a.settings.default_state&&1!=i||(U(a.settings,a.id),A(a.settings,a.id));var M=0;"open"!=a.settings.default_state||P(a.settings.show_close_button)||(t("#chaty-widget-"+a.id+" .chaty-widget").addClass("chaty-no-close-button").addClass("chaty-open"),M=1),P(a.settings.is_google_analytics_enabled)&&(t("#chaty-widget-"+a.id+" .chaty-channel-list .chaty-channel").addClass("has-gae"),t("#chaty-widget-"+a.id+" .chaty-i-trigger.single-channel .chaty-channel").addClass("has-gae"),t(".chaty-outer-forms.chaty-whatsapp-form.chaty-form-"+a.id+" form.add-analytics").addClass("form-google-analytics")),P(a.settings.has_custom_css)&&!_(a.settings.custom_css)&&(c+=a.settings.custom_css),"hover"==a.settings.default_state?t("#chaty-widget-"+a.id).addClass("open-on-hover"):"open"==a.settings.default_state&&(t("#chaty-widget-"+a.id+" .chaty-widget").addClass("default-open"),(u||!P(a.settings.show_close_button))&&t("#chaty-widget-"+a.id+" .chaty-widget").addClass("chaty-open"));var T=h(a.settings.widget_size,a.settings.custom_widget_size);if(T=parseInt(T),n+="#chaty-widget-"+a.id+" .chaty-channel {width: "+T+"px; height: "+T+"px; }",n+="#chaty-widget-"+a.id+" .chaty-channel > a {width: "+T+"px; height: "+T+"px; }",n+="#chaty-widget-"+a.id+" .chaty-channel > a .chaty-custom-icon {display:block; width: "+T+"px; height: "+T+"px; line-height: "+T+"px; font-size: "+parseInt(T/2)+"px; }",n+="#chaty-widget-"+a.id+" .chaty-channel button {width: "+T+"px; height: "+T+"px; margin: 0; padding:0; outline: none; border-radius: 50%;}",n+="#chaty-widget-"+a.id+" .chaty-channel .chaty-svg {width: "+T+"px; height: "+T+"px; }",n+="#chaty-widget-"+a.id+" .chaty-channel .chaty-svg img {width: "+T+"px; height: "+T+"px; }",n+="#chaty-widget-"+a.id+" .chaty-channel span.chaty-icon {width: "+T+"px; height: "+T+"px; }",n+="#chaty-widget-"+a.id+" .chaty-channel a {width: "+T+"px; height: "+T+"px; }",n+="#chaty-widget-"+a.id+" .chaty-channel .chaty-svg .chaty-custom-channel-icon {width: "+T+"px; height: "+T+"px; line-height: "+T+"px; display: block; font-size:"+parseInt(T/2)+"px; }",n+="#chaty-widget-"+a.id+" .chaty-i-trigger .chaty-cta-button {background-color: "+a.settings.widget_color+"; }",n+="#chaty-widget-"+a.id+" .chaty-i-trigger .chaty-cta-button button {background-color: "+a.settings.widget_color+"; }",n+="#chaty-widget-"+a.id+" .chaty-i-trigger .ch-pending-msg {background-color: "+a.settings.pending_mesg_count_bgcolor+"; color: "+a.settings.pending_mesg_count_color+"; }","vertical"==a.settings.icon_view){n+="#chaty-widget-"+a.id+" .chaty-channel-list {height: "+i*(T+8)+"px; }",n+="#chaty-widget-"+a.id+" .chaty-channel-list {width: "+(T+8)+"px; }";for(var z=0;i>=z;z++)n+="#chaty-widget-"+a.id+" .chaty-open .chaty-channel-list .chaty-channel:nth-child("+(z+1)+") {-webkit-transform: translateY(-"+(T+8)*(i-z-M)+"px); transform: translateY(-"+(T+8)*(i-z-M)+"px);}"}else{t("#chaty-widget-"+a.id+" .chaty-widget").addClass("hor-mode"),n+="#chaty-widget-"+a.id+" .chaty-channel-list {width: "+i*(T+8)+"px; }",n+="#chaty-widget-"+a.id+" .chaty-channel-list {height: "+T+"px; }";for(var z=0;i>=z;z++)n+="#chaty-widget-"+a.id+" .chaty-widget.left-position.hor-mode.chaty-open .chaty-channel-list .chaty-channel:nth-child("+(z+1)+") {-webkit-transform: translateX("+(T+8)*(i-z-M)+"px); transform: translateX("+(T+8)*(i-z-M)+"px);}",n+="#chaty-widget-"+a.id+" .chaty-widget.right-position.hor-mode.chaty-open .chaty-channel-list .chaty-channel:nth-child("+(z+1)+") {-webkit-transform: translateX(-"+(T+8)*(i-z-M)+"px); transform: translateX(-"+(T+8)*(i-z-M)+"px);}"}var B=a.settings.bottom_spacing,E=a.settings.side_spacing;n+="#chaty-widget-"+a.id+" .chaty-widget {bottom: "+B+"px}","left"==g?(n+="#chaty-widget-"+a.id+" .chaty-widget {left: "+E+"px; right: auto;}",n+=".chaty-outer-forms.pos-left.chaty-form-"+a.id+" {left: "+E+"px}",t(".chaty-form-"+a.id).addClass("pos-left")):(n+="#chaty-widget-"+a.id+" .chaty-widget {right: "+E+"px; left:auto;}",t(".chaty-form-"+a.id).addClass("pos-right"),n+=".chaty-outer-forms.pos-right.chaty-form-"+a.id+" {right: "+E+"px; left:auto;}"),t(".chaty-form-"+a.id).show();var q=T+15+parseInt(B);n+=".chaty-outer-forms.active.chaty-form-"+a.id+" {-webkit-transform: translateY(-"+q+"px); transform: translateY(-"+q+"px)} ",n+="#chaty-widget-"+a.id+" .chaty-tooltip:after {background-color: "+a.settings.cta_bg_color+"; color: "+a.settings.cta_text_color+"}",n+="#chaty-widget-"+a.id+" .chaty-tooltip.pos-top:before {border-top-color: "+a.settings.cta_bg_color+"; }",n+="#chaty-widget-"+a.id+" .chaty-tooltip.pos-left:before {border-left-color: "+a.settings.cta_bg_color+"; }",n+="#chaty-widget-"+a.id+" .chaty-tooltip.pos-right:before {border-right-color: "+a.settings.cta_bg_color+";}",n+="#chaty-widget-"+a.id+" .on-hover-text {background-color: "+a.settings.cta_bg_color+"; color: "+a.settings.cta_text_color+"}",n+="#chaty-widget-"+a.id+" .chaty-tooltip.pos-top .on-hover-text:before {border-top-color: "+a.settings.cta_bg_color+"; }",n+="#chaty-widget-"+a.id+" .chaty-tooltip.pos-left .on-hover-text:before {border-left-color: "+a.settings.cta_bg_color+"; }",n+="#chaty-widget-"+a.id+" .chaty-tooltip.pos-right .on-hover-text:before {border-right-color: "+a.settings.cta_bg_color+";}";var L=Q(a.id,"v-widget");if(L&&(P(a.triggers.exit_intent)||P(a.triggers.has_time_delay)&&parseInt(a.triggers.time_delay)>0||P(a.triggers.has_display_after_page_scroll)&&parseInt(a.triggers.display_after_page_scroll)>0)?(P(a.triggers.has_time_delay)&&parseInt(a.triggers.time_delay)>0&&(et=!0,parseInt(a.triggers.time_delay)>at&&(at=a.triggers.time_delay),t("#chaty-widget-"+a.id).addClass("on-chaty-delay"),t("#chaty-widget-"+a.id).addClass("delay-time-"+parseInt(a.triggers.time_delay)),t("#chaty-widget-"+a.id).attr("data-time",parseInt(a.triggers.time_delay))),P(a.triggers.has_display_after_page_scroll)&&parseInt(a.triggers.display_after_page_scroll)>0&&(nt=!0,t("#chaty-widget-"+a.id).addClass("on-chaty-scroll"),t("#chaty-widget-"+a.id).addClass("page-scroll-"+parseInt(a.triggers.display_after_page_scroll)),t("#chaty-widget-"+a.id).attr("data-scroll",parseInt(a.triggers.display_after_page_scroll))),P(a.triggers.exit_intent)&&(ct=!0,t("#chaty-widget-"+a.id).addClass("on-chaty-exit-intent"))):(o(a.id),t("#chaty-widget-"+a.id).addClass("active")),!_(a.settings.font_family)&&"none"!=a.settings.font_family){var O=a.settings.font_family;-1!=t.inArray(O,$)?"System Stack"==O&&(O="-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif"):(t("head").append('<link rel="preload" as="style" href="https://fonts.googleapis.com/css?family='+O+'&display=swap">'),t("head").append('<link rel="stylesheet" href="https://fonts.googleapis.com/css?family='+O+'&display=swap">')),n+="#chaty-widget-"+a.id+", #chaty-widget-"+a.id+" .chaty-tooltip:after {font-family: "+O+"}"}}ct&&S(),""!=n&&(t("#custom-chaty-css").length||t("head").append("<style id='custom-chaty-css'></style>"),t("#custom-chaty-css").append(n)),""!=c&&(t("#custom-advance-chaty-css").length||t("head").append("<style id='custom-advance-chaty-css'></style>"),t("#custom-advance-chaty-css").append(c)),e==Y.length-1}),t("#custom-advance-chaty-css").length||t("head").append("<style id='custom-advance-chaty-css'></style>"),t("#custom-advance-chaty-css").append(ht)),z(),I()}function s(t){if(P(t.is_agent)){if(t.agent_data.length&&(!K&&P(t.is_agent_desktop)||K&&P(t.is_agent_mobile)))return!0}else if((!K&&P(t.is_desktop)||K&&P(t.is_mobile))&&(""!=t.value||"Contact_Us"==t.channel))return!0;return!1}function o(n){if(t("#chaty-widget-"+n+" .chaty-channel.chaty-default-open").length){var c=t("#chaty-widget-"+n+" .chaty-channel.chaty-default-open a.chaty-whatsapp-form").data("form");if(!_(c)){var i=Q(n,"c-"+t("#chaty-widget-"+n+" .chaty-channel.chaty-default-open").data("channel"));if(i&&(t("#"+c).addClass("is-active"),t("#"+c).length)){var s=t("#chaty-widget-"+n+" .chaty-channel.chaty-default-open a.chaty-whatsapp-form").html();if(a(n),t("#chaty-widget-"+n).find(".ch-pending-msg").remove(),t("#chaty-widget-"+n+" .chaty-widget").removeClass("chaty-open"),t("#chaty-widget-"+n).addClass("form-open"),t("#"+c).addClass("active"),t("#chaty-widget-"+n+" .open-chaty-channel").html(s),t("#chaty-widget-"+n).addClass("active"),t("#chaty-widget-"+n).addClass("active"),t("#chaty-widget-"+n).hasClass("auto-hide-chaty")){var o=parseInt(t("#chaty-widget-"+n).data("time"));o>0&&(o+=rt,t("#chaty-widget-"+n).addClass("hide-after-"+o))}if("on"==chaty_settings.data_analytics_settings){var h=[],r=t("#chaty-widget-"+n+" .chaty-channel.chaty-default-open").data("channel"),l=Q(n,"v-"+r);if(l&&"undefined"!=typeof r&&(H(n,"v-"+r),h.push(r)),!tt&&h.length){var d=t("#chaty-widget-"+n).data("nonce");t.ajax({url:chaty_settings.ajax_url,data:{widgetId:n,channels:h,userId:n,isMobile:K,widgetNonce:d,action:"update_chaty_channel_views"},type:"post",success:function(t){},error:function(t,e,a){monitorErrorLog(t,e,a)}})}}return}}}if(t("#chaty-widget-"+n).addClass("active"),t("#chaty-widget-"+n).hasClass("auto-hide-chaty")){var o=parseInt(t("#chaty-widget-"+n).data("time"));o>0&&(o+=rt,t("#chaty-widget-"+n).addClass("hide-after-"+o))}var g=Q(n,"v-widget");if(g){H(n,"v-widget");var r,h=(t("#chaty-widget-"+n).data("user"),[]),y=0,p=0,u=t("#chaty-widget-"+n).data("key");if(typeof Y[u]!=e){var f=G("activechatyWidgets");null!=f?(f=f.split(","),-1==t.inArray(n,f)&&(f.push(n),f=f.join(","),R("activechatyWidgets",f,1))):(f=n,R("activechatyWidgets",f,1))}if(t("#chaty-widget-"+n+" .chaty-widget").hasClass("has-single")){y=1,r=t("#chaty-widget-"+n+" .chaty-channel").data("channel");var l=Q(n,"v-"+r);l&&"undefined"!=typeof r&&(H(n,"v-"+r),h.push(r))}else t("#chaty-widget-"+n+" .chaty-widget").hasClass("chaty-open")&&(p=1,t("#chaty-widget-"+n+" .chaty-channel-list .chaty-channel").each(function(){r=t(this).data("channel");var e=Q(n,"v-"+r);e&&"undefined"!=typeof r&&(H(n,"v-"+r),h.push(r))}));if(g&&!tt){var d=t("#chaty-widget-"+n).data("nonce");tt||t.ajax({url:chaty_settings.ajax_url,data:{widgetId:n,channels:h,userId:n,isMobile:K,isOpen:p,isSingle:y,widgetNonce:d,action:"update_chaty_widget_views"},type:"post",success:function(t){},error:function(t,e,a){monitorErrorLog(t,e,a)}})}}}function h(t,e){return t}function r(t,e){switch(t){case"chat-smile":return'<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" viewBox="-496.8 507.1 54 54" style="enable-background-color:new -496.8 507.1 54 54;" xml:space="preserve"><style type="text/css">.chaty-sts1{fill:#FFFFFF;} .chaty-sts2{fill:none;stroke:#808080;stroke-width:1.5;stroke-linecap:round;stroke-linejoin:round;}</style><g><circle cx="-469.8" cy="534.1" r="27" fill="'+e+'"/></g><path class="chaty-sts1" d="M-459.5,523.5H-482c-2.1,0-3.7,1.7-3.7,3.7v13.1c0,2.1,1.7,3.7,3.7,3.7h19.3l5.4,5.4c0.2,0.2,0.4,0.2,0.7,0.2c0.2,0,0.2,0,0.4,0c0.4-0.2,0.6-0.6,0.6-0.9v-21.5C-455.8,525.2-457.5,523.5-459.5,523.5z"/><path class="chaty-sts2" d="M-476.5,537.3c2.5,1.1,8.5,2.1,13-2.7"/><path class="chaty-sts2" d="M-460.8,534.5c-0.1-1.2-0.8-3.4-3.3-2.8"/></svg>';case"chat-bubble":return'<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" viewBox="-496.9 507.1 54 54" style="enable-background-color:new -496.9 507.1 54 54;" xml:space="preserve"><style type="text/css">.chaty-sts1{fill:#FFFFFF;}</style><g><circle cx="-469.9" cy="534.1" r="27" fill="'+e+'"/></g><path class="chaty-sts1" d="M-472.6,522.1h5.3c3,0,6,1.2,8.1,3.4c2.1,2.1,3.4,5.1,3.4,8.1c0,6-4.6,11-10.6,11.5v4.4c0,0.4-0.2,0.7-0.5,0.9 c-0.2,0-0.2,0-0.4,0c-0.2,0-0.5-0.2-0.7-0.4l-4.6-5c-3,0-6-1.2-8.1-3.4s-3.4-5.1-3.4-8.1C-484.1,527.2-478.9,522.1-472.6,522.1z M-462.9,535.3c1.1,0,1.8-0.7,1.8-1.8c0-1.1-0.7-1.8-1.8-1.8c-1.1,0-1.8,0.7-1.8,1.8C-464.6,534.6-463.9,535.3-462.9,535.3z M-469.9,535.3c1.1,0,1.8-0.7,1.8-1.8c0-1.1-0.7-1.8-1.8-1.8c-1.1,0-1.8,0.7-1.8,1.8C-471.7,534.6-471,535.3-469.9,535.3z M-477,535.3c1.1,0,1.8-0.7,1.8-1.8c0-1.1-0.7-1.8-1.8-1.8c-1.1,0-1.8,0.7-1.8,1.8C-478.8,534.6-478.1,535.3-477,535.3z"/></svg>';case"chat-db":return'<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" viewBox="-496 507.1 54 54" style="enable-background-color:new -496 507.1 54 54;" xml:space="preserve"><style type="text/css">.chaty-sts1{fill:#FFFFFF;}</style><g><circle cx="-469" cy="534.1" r="27" fill="'+e+'"/></g><path class="chaty-sts1" d="M-464.6,527.7h-15.6c-1.9,0-3.5,1.6-3.5,3.5v10.4c0,1.9,1.6,3.5,3.5,3.5h12.6l5,5c0.2,0.2,0.3,0.2,0.7,0.2c0.2,0,0.2,0,0.3,0c0.3-0.2,0.5-0.5,0.5-0.9v-18.2C-461.1,529.3-462.7,527.7-464.6,527.7z"/><path class="chaty-sts1" d="M-459.4,522.5H-475c-1.9,0-3.5,1.6-3.5,3.5h13.9c2.9,0,5.2,2.3,5.2,5.2v11.6l1.9,1.9c0.2,0.2,0.3,0.2,0.7,0.2c0.2,0,0.2,0,0.3,0c0.3-0.2,0.5-0.5,0.5-0.9v-18C-455.9,524.1-457.5,522.5-459.4,522.5z"/></svg>';default:return'<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" viewBox="-496 507.7 54 54" style="enable-background-color:new -496 507.7 54 54;" xml:space="preserve"><style type="text/css">.chaty-sts1{fill: #FFFFFF;}.chaty-st0{fill: #808080;}</style><g><circle cx="-469" cy="534.7" r="27" fill="'+e+'"/></g><path class="chaty-sts1" d="M-459.9,523.7h-20.3c-1.9,0-3.4,1.5-3.4,3.4v15.3c0,1.9,1.5,3.4,3.4,3.4h11.4l5.9,4.9c0.2,0.2,0.3,0.2,0.5,0.2 h0.3c0.3-0.2,0.5-0.5,0.5-0.8v-4.2h1.7c1.9,0,3.4-1.5,3.4-3.4v-15.3C-456.5,525.2-458,523.7-459.9,523.7z"/><path class="chaty-st0" d="M-477.7,530.5h11.9c0.5,0,0.8,0.4,0.8,0.8l0,0c0,0.5-0.4,0.8-0.8,0.8h-11.9c-0.5,0-0.8-0.4-0.8-0.8l0,0C-478.6,530.8-478.2,530.5-477.7,530.5z"/><path class="chaty-st0" d="M-477.7,533.5h7.9c0.5,0,0.8,0.4,0.8,0.8l0,0c0,0.5-0.4,0.8-0.8,0.8h-7.9c-0.5,0-0.8-0.4-0.8-0.8l0,0C-478.6,533.9-478.2,533.5-477.7,533.5z"/></svg>'}}function l(e,a,n){var c="";if(!P(e.is_agent)){x(e.channel_type)&&(e.channel_type=e.channel);var i=b(e,a),s=u(e,i,n,a);if("Contact_Us"==e.channel_type)c+=" has-chaty-box chaty-contact-form";else if("Whatsapp"==e.channel_type&&P(e.has_welcome_message)&&!_(e.chat_welcome_message)&&P(e.is_default_open)){var o=Q(a,"c-"+e.channel_type);o&&(c+=" chaty-default-open")}return"<div class='chaty-channel "+e.channel+"-channel"+c+"' id='"+e.channel+"-"+a+"-channel' data-id='"+e.channel_type+"-"+a+"' data-widget='"+a+"' data-channel='"+e.channel+"'>"+s+"</div>"}if(e.agent_data.length){var h=0,r=[];if(t.each(e.agent_data,function(t,e){""!=e.value&&(h++,r=e)}),h>0){var i,s,l=v(a);return null==l&&(l=-1),d(e,a),i=b(e,a),s=u(e,i,n,a),("Instagram"!=e.channel||"#ffffff"!=e.icon_color&&"#fff"!=e.icon_color)&&(ht+=".chaty-agent-"+a+"-"+e.channel+" .color-element {fill: "+e.icon_color+"; color: "+e.icon_color+";}"),ht+=".chaty-agent-"+a+"-"+e.channel+" .chaty-custom-icon { background-color: "+e.icon_color+";}",ht+=".chaty-agent-"+a+"-"+e.channel+" .chaty-svg-img { background-color: "+e.icon_color+";}","<div data-form='chaty-form-"+a+"-"+e.channel_type+"' class='chaty-channel chaty-agent-button chaty-agent-"+a+"-"+e.channel+" "+e.channel+"-channel"+c+"' id='"+e.channel+"-"+a+"-channel' data-id='"+e.channel_type+"-"+a+"' data-widget='"+a+"' data-channel='"+e.channel+"'>"+s+"</div>"}}}function d(e,a){var n="",c=v(a);null==c&&(c=-1),n+="<div style='display:none;' class='chaty-outer-forms chaty-agent-data chaty-agent-data-"+a+" chaty-form-"+a+"' data-channel='"+e.channel_type+"' id='chaty-form-"+a+"-"+e.channel_type+"' data-widget='"+a+"' data-index='"+c+"'>",n+="<div class='chaty-form'>",n+="<div class='chaty-form-body'>",n+="<div role='button' class='chaty-close-agent-list'><svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 330 330' xmlns:v='https://vecta.io/nano'><path d='M325.607 79.393c-5.857-5.857-15.355-5.858-21.213.001l-139.39 139.393L25.607 79.393c-5.857-5.857-15.355-5.858-21.213.001s-5.858 15.355 0 21.213l150.004 150a15 15 0 0 0 21.212-.001l149.996-150c5.859-5.857 5.859-15.355.001-21.213z'/></svg></div>",n+="<div class='chaty-agent-header agent-info-"+a+"-"+e.channel+"'>",_(e.header_text)||(n+="<div class='agent-main-header'>"+e.header_text+"</div>"),_(e.header_sub_text)||(n+="<div class='agent-sub-header'>"+e.header_sub_text+"</div>"),n+="</div>",t.each(e.agent_data,function(t,c){if(""!=c.value){var i=c.svg_icon;_(c.agent_image)||(i="<img class='chaty-agent-img' src='"+c.agent_image+"' alt='"+c.agent_title+"' />");var s=g(c,e,a,t,i,c.agent_title);n+="<div class='chaty-agent agent-info-"+a+"-"+e.channel+" agent-info-"+t+"'>"+s+"</div>"}ht+=".agent-info-"+a+"-"+e.channel+".agent-info-"+t+" .chaty-agent-icon img { background-color: "+c.agent_bg_color+"; } ",("Instagram"!=e.channel||"#ffffff"!=c.agent_bg_color&&"#fff"!=c.agent_bg_color)&&(ht+=".agent-info-"+a+"-"+e.channel+".agent-info-"+t+" .chaty-agent-icon .color-element { fill: "+c.agent_bg_color+"; } "),ht+=".agent-info-"+a+"-"+e.channel+".agent-info-"+t+" .chaty-custom-icon { background-color: "+c.agent_bg_color+"; } "}),n+="</div>",n+="</div>",n+="</div>",ht+=".chaty-agent-header.agent-info-"+a+"-"+e.channel+" { background-color: "+e.header_bg_color+"; color: "+e.header_text_color+" } ",ht+=".agent-info-"+a+"-"+e.channel+" .chaty-close-agent-list svg { fill: "+e.header_text_color+" } ",t("body").append(n)}function g(e,a,n,c,i,s){var o=e.value,h="_blank";if("Whatsapp"==a.channel_type){var r=y(e.value);K?(h="",o="https://wa.me/"+r):(h="_blank",o="https://web.whatsapp.com/send/?phone="+r)}else"WeChat"==a.channel_type?(h="",o="javascript:;"):"Email"==a.channel_type?(h="",o="mailto:"+e.value):"Facebook_Messenger"==a.channel_type?h=K?"":"_blank":"SMS"==a.channel_type?(h="",o="sms:"+e.value):"Telegram"==a.channel_type?(o=p(e.value,"@"),o="https://telegram.me/"+o,h="_blank"):"Twitter"==a.channel_type?o="https://twitter.com/"+t.trim(e.value):"Phone"==a.channel_type?(h="",o="tel:"+t.trim(e.value)):"Skype"==a.channel_type?(h="",o="skype:"+t.trim(e.value)+"?chat"):"Snapchat"==a.channel_type?o="https://www.snapchat.com/add/"+t.trim(e.value):"Vkontakte"==a.channel_type?o="https://vk.me/"+t.trim(e.value):"Linkedin"==a.channel_type?o="personal"==e.link_type?"https://www.linkedin.com/in/"+t.trim(e.value):"https://www.linkedin.com/company/"+t.trim(e.value):"Viber"==a.channel_type?(o=p(e.value,"+"),isNaN(o)||(o=o.replace("+",""),navigator.userAgent.match(/(iPod|iPhone|iPad)/)&&(o="+"+o),o="viber://chat?number="+o),h=""):"TikTok"==a.channel_type&&(o=p(t.trim(e.value),"@"),o="https://www.tiktok.com/@"+o,h="");return"<a href='"+o+"' target='"+h+"'><span class='chaty-agent-icon'>"+i+"</span><span class='chaty-agent-title'>"+s+"</span></a>"}function y(t){return t=p(t,"+"),t=t.replace(/ /g,""),t=t.replace(/-/g,""),t=t.replace(/_/g,"")}function p(e,a){for(e=t.trim(e);e.charAt(0)==a;)e=e.substring(1);for(;e.charAt(e.length-1)==a;)e=e.substring(0,e.length-1);return e}function u(e,a,n,c){var i="";if(P(e.is_agent))e.url="javascript:;",e.target="";else if("Whatsapp"==e.channel_type)if(P(e.has_welcome_message)&&!_(e.chat_welcome_message))e.url="javascript:;",e.target="",i+=" has-chaty-box chaty-whatsapp-form",m(e,c);else{var s="";if(!_(e.pre_set_message)){s=decodeURI(e.pre_set_message);var o=t("title").text();s=_(o)?s.replace(/{title}/g,""):s.replace(/{title}/g,o),s=s.replace(/{url}/g,window.location),s=encodeURIComponent(s)}K?(e.target="",e.url="https://wa.me/"+e.value+"?text="+s):(e.target="_blank",P(e.is_use_web_version)?e.url="https://wa.me/"+e.value+"?text="+s:e.url="https://web.whatsapp.com/?phone="+e.value+"&text="+s)}else if("WeChat"==e.channel_type)_(e.qr_code_image_url)||(w(e,c),e.url="javascript:;",e.target="",i+=" has-chaty-box chaty-qr-code-form");else if("Contact_Us"==e.channel_type)f(e,c),e.url="javascript:;",e.target="",i+=" has-chaty-box chaty-contact-us-form";else if("Email"==e.channel_type){if(!_(e.mail_subject)){var h=decodeURI(e.mail_subject),o=t("title").text();h=_(o)?h.replace(/{title}/g,""):h.replace(/{title}/g,o),h=h.replace(/{url}/g,window.location),h=encodeURIComponent(h),e.url+="?subject="+h}}else"Viber"==e.channel_type?(e.value=p(e.value,"+"),K&&!isNaN(e.value)&&navigator.userAgent.match(/(iPod|iPhone|iPad)/)&&(e.value="+"+e.value),e.url="viber://chat?number="+e.value,e.target=""):"Vkontakte"==e.channel_type&&(e.url="https://vk.me/"+t.trim(e.value));var r="";return _(e.click_event)||(r='onclick="'+e.click_event+'"',e.target="",e.url="javascript:;"),"<a href='"+e.url+"' "+r+" target='"+e.target+"' class='chaty-tooltip pos-"+n+i+"' data-form='chaty-form-"+c+"-"+e.channel_type+"' data-hover='"+e.hover_text+"'>"+a+"</a>"}function f(e,a){var n="",c=v(a);null==c&&(c=-1),n+="<div style='display:none;' class='chaty-outer-forms chaty-contact-form-box chaty-form-"+a+"' data-channel='"+e.channel_type+"' id='chaty-form-"+a+"-"+e.channel_type+"' data-widget='"+a+"' data-index='"+c+"'>",n+="<div class='chaty-form'>",n+="<div class='chaty-form-body'>",n+="<div role='button' class='close-chaty-form'><div class='chaty-close-button'></div></div>",n+="<form class='chaty-ajax-contact-form' id='chaty-ajax-contact-form-"+c+"' method='post' data-channel='"+e.channel_type+"' data-widget='"+a+"' data-token='"+e.widget_token+"' data-index='"+e.widget_index+"'>",n+="<div class='chaty-contact-form-body'>",n+="<div class='chaty-contact-form-title'>"+e.contact_form_settings.contact_form_title+"</div>",n+="<div class='chaty-contact-inputs'>",t.each(e.contact_fields,function(t,e){n+="<div class='chaty-contact-input'>";var c=P(e.is_required)?"is-required":"";n+="textarea"==e.type?"<textarea type='"+e.type+"' class='chaty-textarea-field "+c+" field-"+e.field+"' placeholder='"+e.placeholder+"' name='"+e.field+"' id='"+e.field+"-"+a+"' ></textarea>":"<input type='"+e.type+"' class='chaty-input-field "+c+" field-"+e.field+"' placeholder='"+e.placeholder+"' name='"+e.field+"' id='"+e.field+"-"+a+"' />",n+="</div>"}),n+="<div class='chaty-contact-form-button'><button type='submit' id='chaty-submit-button-"+a+"' class='chaty-submit-button'>"+e.contact_form_settings.button_text+"</button></div>",n+="</div>",n+="</div>",n+="</form>",n+="</div>",n+="</div>",n+="</div>",t("body").append(n)}function m(e,a){var n="",c=v(a);null==c&&(c=-1);var i="https://web.whatsapp.com/send",s="";if(K?i="https://wa.me/"+e.value:(i=P(e.is_use_web_version)?"https://web.whatsapp.com/send":"https://wa.me/"+e.value,s="_blank"),n+="<div style='display:none;' class='chaty-outer-forms chaty-whatsapp-form chaty-form-"+a+"' data-channel='"+e.channel_type+"' id='chaty-form-"+a+"-"+e.channel_type+"' data-widget='"+a+"' data-index='"+c+"'>",n+="<div class='chaty-whatsapp-form'>",n+="<div class='chaty-whatsapp-body'>",n+="<div role='button' class='close-chaty-form is-whatsapp-btn'><div class='chaty-close-button'></div></div>",n+="<div class='chaty-whatsapp-message'></div>",n+="</div>",n+="<div class='chaty-whatsapp-footer'>",n+="<form action='"+i+"' target='"+s+"' class='whatsapp-chaty-form "+(P(e.is_default_open)?"add-analytics":"")+"' data-widget='"+a+"' data-channel='"+e.channel_type+"'>",n+="<div class='chaty-whatsapp-data'>",n+="<div class='chaty-whatsapp-field'>",n+="<input name='text' type='text' class='csass-whatsapp-input' />",n+="</div>",n+="<div class='chaty-whatsapp-button'>",n+="<button type='submit' >",n+="<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'><path fill='#ffffff' d='M1.101 21.757L23.8 12.028 1.101 2.3l.011 7.912 13.623 1.816-13.623 1.817-.011 7.912z'></path></svg>",n+="</button>",n+="</div>",n+="</div>",!K&&P(e.is_use_web_version)&&(n+="<input type='hidden' name='phone' value='"+e.value+"' />"),n+="</form>",n+="</div>",n+="</div>",n+="</div>",t("body").append(n),t("#chaty-form-"+a+"-"+e.channel_type+" .chaty-whatsapp-message").html(e.chat_welcome_message),!_(e.pre_set_message)){var o=e.pre_set_message,h=t("title").text();o=_(h)?o.replace(/{title}/g,""):o.replace(/{title}/g,h),o=o.replace(/{url}/g,window.location),t("#chaty-form-"+a+"-"+e.channel_type+" .csass-whatsapp-input").val(o)}t("#chaty-form-"+a+"-"+e.channel_type).show()}function v(e){var a=null;return Y.length&&t.each(Y,function(t,n){n.id==e&&(a=t)}),a}function w(e,a){var n="",c=v(a);null==c&&(c=-1),n+="<div style='display:none;' class='chaty-outer-forms chaty-form-"+a+"' data-channel='"+e.channel_type+"' id='chaty-form-"+a+"-"+e.channel_type+"' data-widget='"+a+"' data-index='"+c+"'>",n+="<div class='chaty-form'>",n+="<div class='chaty-form-body'>",n+="<div role='button' class='close-chaty-form is-whatsapp-btn'><div class='chaty-close-button'></div></div>",n+="<div class='qr-code-image'><img src='"+e.qr_code_image_url+"' alt='"+e.title+"' /></div>",n+="</div>",n+="</div>",n+="</div>",t("body").append(n)}function _(e){return null==e||""==e||""==t.trim(e)?!0:!1}function b(t){return""!=t.custom_image_url&&"null"!=t.custom_image_url?"<span class='chaty-icon channel-icon-"+t.channel_type+"'><span class='chaty-svg chaty-svg-img'><img src='"+t.custom_image_url+"' alt='"+t.hover_text+"' /></span></span>":"<span class='chaty-icon channel-icon-"+t.channel_type+"'><span class='chaty-svg'>"+t.svg_icon+"</span></span>"}function x(e){return""==e||""==t.trim(e)||null==e||"null"==e?!0:!1}function C(t){return"custom"==t.position?t.custom_position:t.position}function k(t){if("vertical"!=t.settings.icon_view)return"top";var e=C(t.settings);return"right"==e?"left":"right"}function I(){if(t(".chaty.auto-hide-chaty").length&&(J=setInterval(function(){rt++;var e=rt;if(t(".chaty.auto-hide-chaty.hide-after-"+rt).length){var a=t(".chaty.auto-hide-chaty.hide-after-"+e).data("id");t(".chaty-form-"+a).removeClass("active"),t(".chaty.auto-hide-chaty.hide-after-"+e).removeClass("active"),t("#chaty-widget-0"+a).removeClass("auto-hide-chaty")}0==t(".chaty.auto-hide-chaty").length&&clearInterval(J)},1e3)),et&&(X=setInterval(function(){if(st++,t(".chaty.delay-time-"+st).length){var e=t(".chaty.delay-time-"+st).data("id");T(e)}},1e3)),nt){t(window).on("scroll",function(){if(nt){var e=t(document).height()-t(window).height(),a=t(window).scrollTop();if(0!=e){var n=parseInt(a/e*100);if(n>=ot){var c=ot;ot=n;for(var i=c;n>=i;i++)-1==t.inArray(i,it)&&t(".chaty.on-chaty-scroll.page-scroll-"+i).length&&t(".chaty.on-chaty-scroll.page-scroll-"+i).each(function(){var e=t(this).data("id");t(this).removeClass("on-chaty-scroll"),T(e)});ot=n}}}});window.innerWidth>document.documentElement.clientWidth}}function j(){function e(){if(ct){var t=location.hash,e=t.split("#!/"),a=e[1];if(""!==a){var n=window.location.hash;""===n&&M()}}}if(window.history&&window.history.pushState&&ct){var a=100;window.history.state&&window.history.state.page&&(a=window.history.state.page),window.history.pushState({page:a+1},""),window.history.pushState({page:a+2},""),window.onpopstate=function(){e()},window.history.onpopstate=function(){e()},window.addEventListener("popstate",function(){e()}),document.addEventListener("backbutton",function(){e()}),window.addEventListener("backbutton",function(){e()}),t(window).on("popstate",function(){e()})}}function S(){K?j():t(document).mouseleave(function(t){function e(t,e,a){t.addEventListener?(t.addEventListener(e,a,!1),M()):t.attachEvent&&t.attachEvent("on"+e,a)}e(document,"mouseout",function(t){null==t.toElement&&null==t.relatedTarget&&M()})})}function M(){ct&&t(".on-chaty-exit-intent").length&&t(".on-chaty-exit-intent").each(function(){var e=t(this).data("id");t(this).removeClass("on-chaty-exit-intent"),T(e),t("#chaty-widget-"+e+" .chaty-widget").append("<div class='chaty-exit-intent'></div>"),setTimeout(function(){t(".chaty-exit-intent").addClass("animate"),setTimeout(function(){t(".chaty-exit-intent").removeClass("animate")},2500)},500)})}function T(e){o(e),t(".chaty-widget-"+e).removeClass("on-chaty-delay"),t(".chaty-widget-"+e).removeClass("on-chaty-exit-intent"),t(".chaty-widget-"+e).removeClass("on-chaty-scroll"),t(".chaty.on-chaty-delay").length||(clearInterval(X),et=!1),t(".chaty.on-chaty-exit-intent").length||(ct=!1),t(".chaty.on-chaty-scroll").length||(nt=!1)}function z(){t(".chaty-tooltip").each(function(){""==t(this).data("hover")&&t(this).removeClass("left").removeClass("right").removeClass("top").removeClass("chaty-tooltip")})}function F(t,e){return""==t.widget_icon?t.widget_icon="chat-base":"chat-image"==t.widget_icon&&_(t.widget_icon_url)&&(t.widget_icon="chat-base"),"chat-image"==t.widget_icon?"<span class='chaty-svg' style='background-color: "+t.widget_color+"'><img src='"+t.widget_icon_url+"' alt='Chaty Widget' /></span>":'<span class="chaty-svg">'+r(t.widget_icon,t.widget_color)+"</span>"}function A(e,a){var n=Q(a,"c-widget");n&&"none"!=e.attention_effect&&""!=e.attention_effect&&(t("#chaty-widget-"+a).attr("data-animation",e.attention_effect),t("#chaty-widget-"+a+" .chaty-widget").hasClass("has-single")?t("#chaty-widget-"+a+" .chaty-i-trigger .chaty-channel .chaty-svg").addClass("chaty-animation-"+e.attention_effect):t("#chaty-widget-"+a+" .chaty-i-trigger .chaty-cta-main .chaty-cta-button").addClass("chaty-animation-"+e.attention_effect))}function U(e,a){var n=Q(a,"c-widget");n&&P(e.is_pending_mesg_enabled)&&parseInt(e.pending_mesg_count)>0&&(t("#chaty-widget-"+a+" .chaty-widget").hasClass("has-single")?"sheen"==e.attention_effect||"spin"==e.attention_effect||"pulse"==e.attention_effect?t("#chaty-widget-"+a+" .chaty-i-trigger .chaty-channel").append("<span class='ch-pending-msg'>"+e.pending_mesg_count+"</span>"):t("#chaty-widget-"+a+" .chaty-i-trigger .chaty-channel .chaty-svg").append("<span class='ch-pending-msg'>"+e.pending_mesg_count+"</span>"):"jump"==e.attention_effect||"waggle"==e.attention_effect||"blink"==e.attention_effect||"pulse-icon"==e.attention_effect?t("#chaty-widget-"+a+" .chaty-i-trigger .chaty-cta-main .chaty-cta-button").append("<span class='ch-pending-msg'>"+e.pending_mesg_count+"</span>"):t("#chaty-widget-"+a+" .chaty-i-trigger .chaty-cta-main").append("<span class='ch-pending-msg'>"+e.pending_mesg_count+"</span>"))}function B(t){for(t=t.toString();t.length<2;)t="0"+t;return t}function D(t){var e=!0;if(P(t.triggers.has_day_hours_scheduling_rules)&&t.triggers.day_hours_scheduling_rules.length>0){var a=t.triggers.day_hours_scheduling_rules;if(a.length>0){e=!1;var n=new Date;n=E(n,t.triggers.day_time_diff);for(var c=n.getHours(),i=n.getMinutes(),s=n.getDay(),o=0;o<a.length;o++){var h=0,r=0,l=0;-1==a[o].days?l=1:a[o].days>=0&&a[o].days<=6?a[o].days==s&&(l=1):7==a[o].days?s>=0&&4>=s&&(l=1):8==a[o].days?s>=1&&5>=s&&(l=1):9==a[o].days&&(5==s||6==s)&&(l=1),1==l&&(c>a[o].start_hours&&c<a[o].end_hours?h=1:c==a[o].start_hours&&c<a[o].end_hours?i>=a[o].start_min&&(h=1):c>a[o].start_hours&&c==a[o].end_hours?i<=a[o].end_min&&(h=1):c==a[o].start_hours&&c==a[o].end_hours&&i>=a[o].start_min&&i<=a[o].end_min&&(h=1),1==h&&i>=a[o].start_min&&i<=a[o].end_min&&(r=1)),1==h&&1==l&&(e=1),1==e&&(o=a.length+1)}}}return e}function P(t){return"1"==t||1==t||1==t||"true"==t||"yes"==t||"on"==t?!0:!1}function E(t,e){if(isNaN(e)){var a=new Date(t.toLocaleString("en-US",{timeZone:e})),n=t.getTime()-a.getTime();return new Date(t.getTime()-n)}var c=new Date;if(c=c.toLocaleString("en-US",{timeZone:"UTC"}),c=new Date(c),-1!=e.indexOf("+")){var i=e.replace("+",""),s=parseInt(i),o=60*parseFloat(i%s);o=c.getUTCMinutes()+o,o>59&&(s+=parseInt(o/60),o%=60),c.setUTCHours(c.getUTCHours()+s,o)}else if(-1!=e.indexOf("-")){var i=e.replace("-",""),s=parseInt(i),o=60*parseFloat(i%s);o=c.getUTCMinutes()-o,0>o&&(s-=parseInt(o/60),o%=60),c.setUTCHours(c.getUTCHours()-s,-o)}var n=t.getTime()-c.getTime();return new Date(t.getTime()-n)}function N(t){if(t.triggers.has_date_scheduling_rules){var e=t.triggers.date_scheduling_rules.start_date_time,a=t.triggers.date_scheduling_rules.end_date_time,n=new Date;n=E(n,t.triggers.time_diff);var c=n.getFullYear()+"-"+B(n.getMonth()+1)+"-"+B(n.getDate())+" "+B(n.getHours())+":"+B(n.getMinutes())+":"+B(n.getSeconds());return""==a&&c>=e?!0:""==e&&a>=c?!0:""!=e&&""!=a&&c>=e&&a>=c?!0:!1}return!0}function W(e){return P(e.triggers.has_countries)&&!_(e.triggers.countries)&&e.triggers.countries.length&&(Z=q(),"-"!=Z&&-1==t.inArray(Z,e.triggers.countries))?!1:!0}function q(){return Z="","undefined"!=typeof Storage&&null!=window.sessionStorage.getItem("chaty_user_country_code")?Z=window.sessionStorage.getItem("chaty_user_country_code"):V("chaty_user_country_code")&&(Z=G("chaty_user_country_code")),Z}function L(t){"undefined"!=typeof Storage?null==window.sessionStorage.getItem("chaty_user_country_code")&&window.sessionStorage.setItem("chaty_user_country_code",t):V("chaty_user_country_code")||R("chaty_user_country_code",t,365)}function O(t,e){var a=G("chatyWidget_"+t),n=[];if(null!=a&&""!=a&&(n=JSON.parse(a)),n.length>0)for(var c=0;c<n.length;c++)if(n[c].k==e)return n[c].v;return null}function H(t,e){var a=G("chatyWidget_"+t),n=[];null!=a&&""!=a&&(n=JSON.parse(a));var c=!1;if(n.length>0)for(var i=0;i<n.length;i++)n[i].k==e&&(c=!0,n[i].v=new Date);c||n.push({k:e,v:new Date}),a=JSON.stringify(n),R("chatyWidget_"+t,a,"7")}function Q(t,e){var a=O(t,e);if(null!=a&&""!=a){a=new Date(a);var n=Math.abs(new Date-a),c=Math.floor(n/864e5);return c>=2?!0:!1}return!0}function R(t,e,a){var n=new Date;n.setTime(n.getTime()+24*a*60*60*1e3);var c="expires="+n.toUTCString();document.cookie=t+"="+e+"; "+c+"; path=/; SameSite=Lax"}function G(t){for(var t=t+"=",e=document.cookie.split(";"),a=0;a<e.length;a++){for(var n=e[a];" "==n.charAt(0);)n=n.substring(1);if(0==n.indexOf(t))return n.substring(t.length,n.length)}return null}function V(t){var e=G(t);return""!=e&&null!==e?!0:!1}var X,J,Y=[],Z="",K=/(android|bb\d+|meego).+mobile|avantgo|bada\/|blackberry|blazer|compal|elaine|fennec|hiptop|iemobile|ip(hone|od)|ipad|iris|kindle|Android|Silk|lge |maemo|midp|mmp|netfront|opera m(ob|in)i|palm( os)?|phone|p(ixi|re)\/|plucker|pocket|psp|series(4|6)0|symbian|treo|up\.(browser|link)|vodafone|wap|windows (ce|phone)|xda|xiino/i.test(navigator.userAgent)||/1207|6310|6590|3gso|4thp|50[1-6]i|770s|802s|a wa|abac|ac(er|oo|s\-)|ai(ko|rn)|al(av|ca|co)|amoi|an(ex|ny|yw)|aptu|ar(ch|go)|as(te|us)|attw|au(di|\-m|r |s )|avan|be(ck|ll|nq)|bi(lb|rd)|bl(ac|az)|br(e|v)w|bumb|bw\-(n|u)|c55\/|capi|ccwa|cdm\-|cell|chtm|cldc|cmd\-|co(mp|nd)|craw|da(it|ll|ng)|dbte|dc\-s|devi|dica|dmob|do(c|p)o|ds(12|\-d)|el(49|ai)|em(l2|ul)|er(ic|k0)|esl8|ez([4-7]0|os|wa|ze)|fetc|fly(\-|_)|g1 u|g560|gene|gf\-5|g\-mo|go(\.w|od)|gr(ad|un)|haie|hcit|hd\-(m|p|t)|hei\-|hi(pt|ta)|hp( i|ip)|hs\-c|ht(c(\-| |_|a|g|p|s|t)|tp)|hu(aw|tc)|i\-(20|go|ma)|i230|iac( |\-|\/)|ibro|idea|ig01|ikom|im1k|inno|ipaq|iris|ja(t|v)a|jbro|jemu|jigs|kddi|keji|kgt( |\/)|klon|kpt |kwc\-|kyo(c|k)|le(no|xi)|lg( g|\/(k|l|u)|50|54|\-[a-w])|libw|lynx|m1\-w|m3ga|m50\/|ma(te|ui|xo)|mc(01|21|ca)|m\-cr|me(rc|ri)|mi(o8|oa|ts)|mmef|mo(01|02|bi|de|do|t(\-| |o|v)|zz)|mt(50|p1|v )|mwbp|mywa|n10[0-2]|n20[2-3]|n30(0|2)|n50(0|2|5)|n7(0(0|1)|10)|ne((c|m)\-|on|tf|wf|wg|wt)|nok(6|i)|nzph|o2im|op(ti|wv)|oran|owg1|p800|pan(a|d|t)|pdxg|pg(13|\-([1-8]|c))|phil|pire|pl(ay|uc)|pn\-2|po(ck|rt|se)|prox|psio|pt\-g|qa\-a|qc(07|12|21|32|60|\-[2-7]|i\-)|qtek|r380|r600|raks|rim9|ro(ve|zo)|s55\/|sa(ge|ma|mm|ms|ny|va)|sc(01|h\-|oo|p\-)|sdk\/|se(c(\-|0|1)|47|mc|nd|ri)|sgh\-|shar|sie(\-|m)|sk\-0|sl(45|id)|sm(al|ar|b3|it|t5)|so(ft|ny)|sp(01|h\-|v\-|v )|sy(01|mb)|t2(18|50)|t6(00|10|18)|ta(gt|lk)|tcl\-|tdg\-|tel(i|m)|tim\-|t\-mo|to(pl|sh)|ts(70|m\-|m3|m5)|tx\-9|up(\.b|g1|si)|utst|v400|v750|veri|vi(rg|te)|vk(40|5[0-3]|\-v)|vm40|voda|vulc|vx(52|53|60|61|70|80|81|83|85|98)|w3c(\-| )|webc|whit|wi(g |nc|nw)|wmlb|wonu|x700|yas\-|your|zeto|zte\-/i.test(navigator.userAgent.substr(0,4))?1:0,$=["System Stack","Arial","Tahoma","Verdana","Helvetica","Times New Roman","Trebuchet MS","Georgia"],tt=!1,et=!1,at=0,nt=!1,ct=!1,it=[],st=0,ot=0,ht="",rt=0;t(document).ready(function(){var c="(googlebot/|bot|Googlebot-Mobile|Googlebot-Image|Google favicon|Mediapartners-Google|bingbot|slurp|java|wget|curl|Commons-HttpClient|Python-urllib|libwww|httpunit|nutch|phpcrawl|msnbot|jyxobot|FAST-WebCrawler|FAST Enterprise Crawler|biglotron|teoma|convera|seekbot|gigablast|exabot|ngbot|ia_archiver|GingerCrawler|webmon |httrack|webcrawler|grub.org|UsineNouvelleCrawler|antibot|netresearchserver|speedy|fluffy|bibnum.bnf|findlink|msrbot|panscient|yacybot|AISearchBot|IOI|ips-agent|tagoobot|MJ12bot|dotbot|woriobot|yanga|buzzbot|mlbot|yandexbot|purebot|Linguee Bot|Voyager|CyberPatrol|voilabot|baiduspider|citeseerxbot|spbot|twengabot|postrank|turnitinbot|scribdbot|page2rss|sitebot|linkdex|Adidxbot|blekkobot|ezooms|dotbot|Mail.RU_Bot|discobot|heritrix|findthatfile|europarchive.org|NerdByNature.Bot|sistrix crawler|ahrefsbot|Aboundex|domaincrawler|wbsearchbot|summify|ccbot|edisterbot|seznambot|ec2linkfinder|gslfbot|aihitbot|intelium_bot|facebookexternalhit|yeti|RetrevoPageAnalyzer|lb-spider|sogou|lssbot|careerbot|wotbox|wocbot|ichiro|DuckDuckBot|lssrocketcrawler|drupact|webcompanycrawler|acoonbot|openindexspider|gnam gnam spider|web-archive-net.com.bot|backlinkcrawler|coccoc|integromedb|content crawler spider|toplistbot|seokicks-robot|it2media-domain-crawler|ip-web-crawler.com|siteexplorer.info|elisabot|proximic|changedetection|blexbot|arabot|WeSEE:Search|niki-bot|CrystalSemanticsBot|rogerbot|360Spider|psbot|InterfaxScanBot|Lipperhey SEO Service|CC Metadata Scaper|g00g1e.net|GrapeshotCrawler|urlappendbot|brainobot|fr-crawler|binlar|SimpleCrawler|Livelapbot|Twitterbot|cXensebot|smtbot|bnf.fr_bot|A6-Indexer|ADmantX|Facebot|Twitterbot|OrangeBot|memorybot|AdvBot|MegaIndex|SemanticScholarBot|ltx71|nerdybot|xovibot|BUbiNG|Qwantify|archive.org_bot|Applebot|TweetmemeBot|crawler4j|findxbot|SemrushBot|yoozBot|lipperhey|y!j-asr|Domain Re-Animator Bot|AddThis)",i=new RegExp(c,"i"),s=navigator.userAgent;i.test(s)&&(tt=!0),("on"!=chaty_settings.data_analytics_settings||"off"==chaty_settings.data_analytics_settings)&&(tt=!0),"undefined"==typeof chaty_settings||0==chaty_settings.chaty_widgets.length?console.log("Chaty settings doesn't exists"):(Y=chaty_settings.chaty_widgets,n()),t(document).on("click","html, body",function(e){t(".form-open").removeClass("form-open"),t(".chaty-outer-forms").removeClass("active"),t(".chaty .chaty-widget.chaty-no-close-button").addClass("chaty-open")}),t(document).on("click",".chaty, .chaty-outer-forms",function(t){t.stopPropagation()}),t(document).on("submit",".whatsapp-chaty-form",function(){if(t(this).hasClass("form-google-analytics")){var e="Whatsapp";if(window.hasOwnProperty("gtag")&&gtag("event","chaty_"+e,{eventCategory:"chaty_"+e,event_action:"chaty_"+e,method:"chaty_"+e}),window.hasOwnProperty("ga")){var a=window.ga.getAll()[0];a&&a.send("event","click",{eventCategory:"chaty_"+e,eventAction:"chaty_"+e,method:"chaty_"+e})}}var n=t(this).data("widget"),c=t(this).data("channel"),i=Q(n,"c-"+c);if((!_(n)||0==n)&&i){H(n,"c-"+c);var s=t("#chaty-widget-"+n).data("nonce");tt||t.ajax({url:chaty_settings.ajax_url,data:{widgetId:n,userId:n,isMobile:K,channel:c,nonce:s,action:"update_chaty_channel_click"},method:"post"})}t("#chaty-widget-"+n).length&&(t("#chaty-widget-"+n).removeClass("form-open"),t(this).closest(".chaty-outer-forms").removeClass("active"),t("#chaty-widget-"+n).find(".chaty-widget").hasClass("cssas-no-close-button")&&t("#chaty-widget-"+n).find(".chaty-widget").addClass("chaty-open"))}),t(document).on("click",".chaty-close-button, .chaty-close-agent-list",function(e){e.preventDefault(),e.stopPropagation();var a=t(this).closest(".chaty-outer-forms").data("widget");if((!_(a)||0==a)&&(t("#chaty-widget-"+a).length&&(t("#chaty-widget-"+a).removeClass("form-open"),t(this).closest(".chaty-outer-forms").removeClass("active"),t("#chaty-widget-"+a).find(".chaty-widget").hasClass("chaty-no-close-button")&&t("#chaty-widget-"+a).find(".chaty-widget").addClass("chaty-open")),t(this).closest(".chaty-whatsapp-form").length)){var n=t(this).closest(".chaty-outer-forms").data("channel");if(!_(n)){var c=Q(a,"c-"+n);c&&H(a,"c-"+n)}var i=Q(a,"v-widget");i&&o(a)}}),t(document).on("click","a.chaty-qr-code-form",function(e){e.preventDefault();var a=t(this).data("form");if(!_(a)&&t("#"+a).length){var n=t(this).html();t("#"+a).hasClass("active")?(t(this).closest(".chaty-widget").addClass("chaty-open"),t(this).closest(".chaty").removeClass("form-open"),t("#"+a).removeClass("active")):(t(this).closest(".chaty-widget").removeClass("chaty-open"),t(this).closest(".chaty").addClass("form-open"),t("#"+a).addClass("active"),t(this).closest(".chaty-widget").find(".open-chaty-channel").html(n))}}),t(document).on("click","a.chaty-contact-us-form",function(e){e.preventDefault();var a=t(this).data("form");if(!_(a)&&t("#"+a).length){var n=t(this).html();t("#"+a).hasClass("active")?(t(this).closest(".chaty-widget").addClass("chaty-open"),t(this).closest(".chaty").removeClass("form-open"),t("#"+a).removeClass("active")):(t(this).closest(".chaty-widget").removeClass("chaty-open"),t(this).closest(".chaty").addClass("form-open"),t("#"+a).addClass("active"),t("#"+a).find(".chaty-ajax-success-message").remove(),t("#"+a).find(".chaty-ajax-error-message").remove(),t("#"+a).find(".has-chaty-error").removeClass("has-chaty-error"),t(this).closest(".chaty-widget").find(".open-chaty-channel").html(n))}}),t(document).on("click","a.chaty-whatsapp-form",function(e){e.preventDefault();var a=t(this).data("form");if(!_(a)&&t("#"+a).length){var n=t(this).html();t("#"+a).addClass("is-active"),t("#"+a).hasClass("active")?(t(this).closest(".chaty-widget").addClass("chaty-open"),t(this).closest(".chaty").removeClass("form-open"),t("#"+a).removeClass("active")):(t(this).closest(".chaty-widget").removeClass("chaty-open"),t(this).closest(".chaty").addClass("form-open"),t("#"+a).addClass("active"),t(this).closest(".chaty-widget").find(".open-chaty-channel").html(n))}}),t(document).on("click",".chaty-channel.chaty-agent-button",function(e){e.preventDefault();var a=t(this).data("form");if(!_(a)&&t("#"+a).length)if(t(this).closest(".chaty-widget").hasClass("has-single"))if(t(this).closest(".chaty").hasClass("form-open"))t(this).closest(".chaty-widget").addClass("chaty-open"),t(this).closest(".chaty").removeClass("form-open"),t("#"+a).removeClass("active");else{var n=t(this).html();t("#"+a).addClass("is-active"),t(this).closest(".chaty-widget").removeClass("chaty-open"),t(this).closest(".chaty").addClass("form-open"),t("#"+a).addClass("active"),t(this).closest(".chaty-widget").find(".open-chaty-channel").html(n)}else{var n=t(this).html();t("#"+a).addClass("is-active"),t(this).closest(".chaty-widget").removeClass("chaty-open"),t(this).closest(".chaty").addClass("form-open"),t("#"+a).addClass("active"),t(this).closest(".chaty-widget").find(".open-chaty-channel").html(n)}}),t(document).on("click",".chaty-channel.has-gae",function(a){a.stopPropagation();var n=t(this).data("channel");if(n!==e&&""!=n&&null!=n&&(window.hasOwnProperty("gtag")&&gtag("event","chaty_"+n,{eventCategory:"chaty_"+n,event_action:"chaty_"+n,method:"chaty_"+n}),window.hasOwnProperty("ga"))){var c=window.ga.getAll()[0];c&&c.send("event","click",{eventCategory:"chaty_"+n,eventAction:"chaty_"+n,method:"chaty_"+n})}}),t(document).on("click",".chaty-i-trigger:not(.single-channel)",function(){t(this).closest(".chaty").hasClass("form-open")?(t(this).closest(".chaty").removeClass("form-open"),t(this).closest(".chaty-widget").addClass("chaty-open")):t(this).closest(".chaty-widget").toggleClass("chaty-open"),t(".chaty-outer-forms").removeClass("active"),t(this).closest(".chaty").find(".chaty-widget").hasClass("chaty-no-close-button")&&t(this).closest(".chaty").find(".chaty-widget").addClass("chaty-open")}),K||t(document).on("mouseover","body:not(.chaty-in-mobile) .chaty.open-on-hover .chaty-i-trigger:not(.single-channel)",function(){t(this).closest(".chaty-widget").hasClass("chaty-open")||t(this).closest(".chaty-widget").hasClass("on-chaty-widget")||(t(this).closest(".chaty-widget").addClass("on-chaty-widget"),t(this).find(".chaty-cta-main").trigger("click"))}).on("mouseleave","body:not(.chaty-in-mobile) .chaty.open-on-hover .chaty-i-trigger:not(.single-channel)",function(){t(this).closest(".chaty-widget").hasClass("chaty-open")||t(this).closest(".chaty-widget").removeClass("on-chaty-widget")}),t(document).on("click",".chaty-channel",function(e){var n,c,i,s=[],o=0,h=t(this).closest(".chaty").data("id");if("undefined"!=typeof h&&(i=t("#chaty-widget-"+h).data("identifier"),"undefined"!=typeof i)){var r=t("#chaty-widget-"+h).data("user");if(a(h),t(this).hasClass("chaty-cta-main")||t(this).hasClass("chaty-cta-close")){if(n=Q(h,"c-widget"),t("#chaty-widget-"+h).find(".ch-pending-msg").remove(),n&&(H(h,"c-widget"),t(this).hasClass("chaty-cta-main"))){s=[],t("#chaty-widget-"+h+" .chaty-channel-list").find(".chaty-channel").each(function(){c=t(this).data("channel"),n=Q(h,"v-"+c),n&&"undefined"!=typeof c&&(H(h,"v-"+c),s.push(c))});var l=t("#chaty-widget-"+h).data("nonce");tt||t.ajax({url:chaty_settings.ajax_url,data:{widgetId:h,userId:r,isMobile:K,channels:s,isSingle:0,nonce:l,action:"update_chaty_widget_click"},method:"post"})}t("#chaty-widget-"+h).hasClass("first_click")&&(t("#chaty-widget-"+h+" .chaty-cta-main").removeClass("active"),t("#chaty-widget-"+h+" .chaty-cta-main").removeClass("chaty-tooltip"))}else if(t(this).hasClass("single")){t("#chaty-widget-"+h).find(".ch-pending-msg").remove(),n=Q(h,"c-widget");var l=t("#chaty-widget-"+h).data("nonce");n&&(H(h,"c-widget"),o=0,s=[],c=t(this).data("channel"),n=Q(h,"c-"+c),n&&(s.push(c),o=1),tt||t.ajax({url:chaty_settings.ajax_url,data:{widgetId:h,userId:r,isMobile:K,channels:s,isSingle:o,nonce:l,action:"update_chaty_widget_click"},method:"post"})),t("#chaty-widget-"+h).hasClass("first_click")&&(t("#chaty-widget-"+h+" .chaty-tooltip").removeClass("chaty-tooltip"),t("#chaty-widget-"+h+" .single-channel a").addClass("chaty-tooltip"))}else if(t(this).hasClass("chaty-channel")&&(c=t(this).data("channel"),n=Q(h,"c-"+c))){H(h,"c-"+c);var l=t("#chaty-widget-"+h).data("nonce");tt||t.ajax({url:chaty_settings.ajax_url,data:{widgetId:h,userId:r,isMobile:K,channel:c,nonce:l,action:"update_chaty_channel_click"},method:"post"})}}}),t(document).on("submit",".chaty-ajax-contact-form",function(e){e.preventDefault();var a=0;if(t(this).find(".has-chaty-error").each(function(){t(this).removeClass("has-chaty-error")}),t(this).find(".chaty-error-msg").remove(),t(this).find(".chaty-ajax-error-message").remove(),t(this).find(".chaty-ajax-success-message").remove(),t(this).find(".is-required").each(function(){""==jQuery.trim(t(this).val())&&(a++,t(this).addClass("has-chaty-error"))}),0==a){var n=t(this);t(".chaty-contact-submit-btn").attr("disabled",!0),jQuery.ajax({url:chaty_settings.ajax_url,data:{action:"chaty_front_form_save_data",name:n.find(".field-name").length?n.find(".field-name").val():"",email:n.find(".field-email").length?n.find(".field-email").val():"",phone:n.find(".field-phone").length?n.find(".field-phone").val():"",message:n.find(".field-message").length?n.find(".field-message").val():"",nonce:n.data("token"),channel:n.data("channel"),widget:n.data("index"),ref_url:window.location.href},type:"post",async:!0,defer:!0,success:function(e){if(e=jQuery.parseJSON(e),t(".chaty-ajax-error-message").remove(),t(".chaty-ajax-success-message").remove(),t(".chaty-contact-submit-btn").attr("disabled",!1),1==e.status)t(".chaty-contact-inputs").append("<div class='chaty-ajax-success-message'>"+e.message+"</div>"),t(".field-name, .field-email, .field-message, .field-phone").val(""),"yes"==e.redirect_action&&("yes"==e.link_in_new_tab?window.open(e.redirect_link,"_blank"):window.location=e.redirect_link),"yes"==e.close_form_after&&setTimeout(function(){if(t(".chaty-outer-forms.active").length){var e=t(".chaty-outer-forms.active").data("widget");_(e)&&0!=e||t("#chaty-widget-"+e).length&&(t("#chaty-widget-"+e).removeClass("form-open"),t(".chaty-outer-forms.active").removeClass("active"),t("#chaty-widget-"+e).find(".chaty-widget").hasClass("chaty-no-close-button")&&t("#chaty-widget-"+e).find(".chaty-widget").addClass("chaty-open"))}},1e3*parseInt(e.close_form_after_seconds));else if(1==e.error){if(e.errors.length)for(var a=0;a<e.errors.length;a++)t("."+e.errors[a].field).addClass("has-chaty-error"),t("."+e.errors[a].field).after("<span class='chaty-error-msg'>"+e.errors[a].message+"</span>")}else t(".chaty-contact-inputs").append("<div class='chaty-ajax-error-message'>"+e.message+"</div>")}})}else t(".has-chaty-error:first").focus();return!1}),t(document).on("click",".chaty-widget.has-single .chaty-i-trigger .chaty-channel:not(.chaty-agent-button).Phone-channel",function(){window.location=t(this).find("a").prop("href")}),t(document).on("click",".chaty-widget.has-single .chaty-i-trigger .chaty-channel:not(.chaty-agent-button).Phone-channel a",function(t){t.stopPropagation(),t.stopImmediatePropagation()})})});
Bookmark: javascript:location='http://shauninman.com/vs/?url='+escape(location)