PageSourceSearch

https://www.bentleywashingtondc.com/wp-content/plugins/chaty/js/cht-front-script.js?=1723071072

js bentleywashingtondc.com collected 2026-10-05 22:25:23 UTC 79,448 bytes, 1,078 lines download raw bytes

1!function (t) {
2    var e = {};
3
4    function i(n) {
5        if (e[n]) return e[n].exports;
6        var o = e[n] = {i: n, l: !1, exports: {}};
7        return t[n].call(o.exports, o, o.exports, i), o.l = !0, o.exports
8    }
9
10    i.m = t, i.c = e, i.d = function (t, e, n) {
11        i.o(t, e) || Object.defineProperty(t, e, {configurable: !1, enumerable: !0, get: n})
12    }, i.n = function (t) {
13        var e = t && t.__esModule ? function () {
14            return t.default
15        } : function () {
16            return t
17        };
18        return i.d(e, "a", e), e
19    }, i.o = function (t, e) {
20        return Object.prototype.hasOwnProperty.call(t, e)
21    }, i.p = "/", i(i.s = 10)
22}({
23    10: function (t, e, i) {
24        i(11), t.exports = i(12)
25    }, 11: function (t, e) {
26        !function (t) {
27            var animationTimer;
28            var isWidgetEnabled = 0;
29            var e;
30            var animationClass = ".i-trigger .chaty-widget-i .svg, .i-trigger .chaty-widget-i .widget-img, .i-trigger .chaty-widget-i .facustom-icon";
31
32            var isChatyInMobile = false; //initiate as false
33            if (/(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)
34                || /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.
34substr(0, 4))) {
35                isChatyInMobile = true;
36            }
37
38
39            function i(t) {
40                if(get_cta_status() && chaty_settings.object_settings.click_setting == 'click') {
41                    return "none";
42                } else {
43                    return "";
44                }
45            }
46
47            var n = new Date;
48
49            function o() {
50                if(jQuery(".chaty-widget").hasClass("one_widget")) {
51                    jQuery(".chaty-widget").removeClass("chaty-widget-show");
52                }
53            }
54
55            jQuery(document).ready(function(){
56                if (isChatyInMobile) {
57                    jQuery("body").addClass("chaty-in-mobile");
58                } else {
59                    jQuery("body").addClass("chaty-in-desktop");
60                }
61                "" != i("display_cta"), token = "", jQuery(document).ready(function () {
62                    e = chaty_settings;
63                    "true" == e.object_settings.active && (function (e, n) {
64                        var o = e.object_settings.device, a = "";
65                        if ("right" == e.object_settings.position) a = "left: auto;bottom: 25px; right: 25px;"; else if ("left" == e.object_settings.position) a = "right: auto; bottom: 25px; left: 25px;"; else if ("custom" == e.object_settings.position) {
66                            var c = e.object_settings.pos_side, s = e.object_settings.bot, r = e.object_settings.side;
67                            a = "right" === c ? "left: auto; bottom: " + s + "px; right: " + r + "px" : "left: " + r + "px; bottom: " + s + "px; right: auto"
68                        }
69                        var g = e.object_settings.cta, d = "", l = e.object_settings.social;
70
71                        if (Object.keys(l).length >= 1 && (d = '<div class="chaty-widget hide-widget ' + n + " " + o + ' "   style="display:block; ' + a + '" dir="ltr">', d += '<div class="chaty-widget-is" id="transition_disabled">'), d += function (e) {
72                            var i = "", n = 0;
73                            return t.each(e.object_settings.social, function (t, o) {
74                                if (e.object_settings.isPRO && jQuery("body").addClass("has-pro-version"), !e.object_settings.isPRO && "3" == ++n) return !1;
75                                extra_class = "", "1" != e.object_settings.analytics && 1 != e.object_settings.analytics || (extra_class += " update-analytics ");
76                                var desktopClass = (e.object_settings.social[t].is_desktop == 1) ? "is-in-desktop" : "";
77                                var mobileClass = (e.object_settings.social[t].is_mobile == 1) ? "is-in-mobile" : "";
78                                var targetAction = (e.object_settings.is_mobile == 1) ? e.object_settings.social[t].mobile_target : e.object_settings.social[t].desktop_target;
79                                if (jQuery("body").hasClass("chaty-in-mobile")) {
80                                    e.object_settings.social[t].href_url = e.object_settings.social[t].mobile_url;
81                                }
82
83                                if (e.object_settings.social[t].social_channel == "viber") {
84                                    if (jQuery("body").hasClass("chaty-in-mobile")) {
85                                        var viberVal = e.object_settings.social[t].href_url;
86                                        if (!isNaN(viberVal)) {
87                                            viberVal = viberVal.replace("+", "");
88                                            if (navigator.userAgent.match(/(iPod|iPhone|iPad)/)) {
89                                                viberVal = "+" + viberVal;
90                                            }
91                                        }
92                                        e.object_settings.social[t].href_url = viberVal;
93                                    }
94                                    e.object_settings.social[t].href_url = "viber://chat?number=" + e.object_settings.social[t].href_url;
95                                }
96                                if(parseInt(e.object_settings.social[t].has_custom_popup) == 1) {
97                                    if(e.object_settings.social[t].channel_type == "whatsapp") {
98                                        if(e.object_settings.social[t].is_default_open) {
99                                            if(is_chaty_settings_expired("cht_whatsapp_window")) {
100                                                extra_class += " open-it-by-default";
101                                            }
102                                        }
103                                        targetAction = "";
104                                        e.object_settings.social[t].mobile_target = "";
105                                        e.object_settings.social[t].desktop_target = "";
106                                        extra_class += " has-custom-c
106haty-popup whatsapp-button";
107                                    } else if(e.object_settings.social[t].channel_type == "contact_us") {
108                                        extra_class += " has-custom-chaty-popup whatsapp-button";
109                                    }
110                                }
111                                var onclick_settings = "";
112                                if (e.object_settings.social[t].on_click != "") {
113                                    onclick_settings = ' onclick="' + e.object_settings.social[t].on_click + '"';
114                                }
115                                socialString = '<div data-popup="'+e.object_settings.social[t].popup_html+'" data-rgb="'+e.object_settings.social[t].rbg_color+'" class="chaty-widget-i chaty-main-widget ' + desktopClass + " " + mobileClass + " " + extra_class + " channel-" + e.object_settings.social[t].social_channel + '" data-title="' + e.object_settings.social[t].val + '" id="chaty-channel-' + e.object_settings.social[t].social_channel + '" data-channel="' + e.object_settings.social[t].social_channel + '" data-code="' + e.object_settings.social[t].qr_code_image + '">',
116                                    bgColor = "",
117                                "" != e.object_settings.social[t].bg_color && (socialString += "<style>#chaty-channel-" + e.object_settings.social[t].social_channel + " .color-element {fill: " + e.object_settings.social[t].bg_color + "; background: " + e.object_settings.social[t].bg_color + "}</style>", bgColor = "style='background-color: " + e.object_settings.social[t].bg_color + ";'"), socialString += "<a class='set-url-target' " + onclick_settings + " rel='noopener' data-mobile-target='" + e.object_settings.social[t].mobile_target + "' data-desktop-target='" + e.object_settings.social[t].desktop_target + "' target='" + targetAction + "' href='" + e.object_settings.social[t].href_url + "' >", socialString += "<span class='sr-only'>"+e.object_settings.social[t].title+"</span>", "" != e.object_settings.social[t].img_url ? socialString += "<span " + bgColor + " class='chaty-social-img'><img src='" + e.object_settings.social[t].img_url + "' alt='" + e.object_settings.social[t].title + "' /></span>" : socialString += e.object_settings.social[t].default_icon, socialString += "</a>", socialString += "<div class='chaty-widget-i-title'><p>" + e.object_settings.social[t].title + "</p></div>", socialString += "</div>";
118                                i += socialString;
119                            }), i
120                        }(e), l = e.object_settings.social, Object.keys(l).length >= 1) {
121                            d += "</div>", d += '<div class="i-trigger">';
122                            var h = i("display_cta");
123                            var CU = current_url = window.location.origin;
124                            CU = CU.replace("https://", "");
125                            CU = CU.replace("http://", "");
126                            if ("" != g && "none" != h) var p = "true"; else p = "no-tooltip";
127                            if (chaty_settings.object_settings.click_setting != 'click') {
128                                p = true;
129                            }
130                            p = true;
131                            d += '<div class="chaty-widget-i chaty-close-settings i-trigger-open ' + p + ' ">', d += function (t) {
132                                switch (t.object_settings.widget_type) {
133                                    case"chat-image":
134                                        if (t.object_settings.widget_img.length > 1) return '<div class="widget-img" style="background-color:' + t.object_settings.color + '"><img src="' + t.object_settings.widget_img + '"/></div>';
135                                    case"chat-smile":
136                                        return '<svg version="1.1" id="smile" 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:new -496.8 507.1 54 54;" xml:space="preserve"><style type="text/css">.sts1{fill:#FFFFFF;}  .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="' + t.object_settings.color + '"/></g><path class="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="sts2" d="M-476.5,537.3c2.5,1.1,8.5,2.1,13-2.7"/><path class="sts2" d="M-460.8,534.5c-0.1-1.2-0.8-3.4-3.3-2.8"/></svg>';
137                                    case"chat-bubble":
138                                        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:new -496.9 507.1 54 54;" xml:space="preserve"><style type="text/css">.sts1{fill:#FFFFFF;}</style><g><circle  cx="-469.9" cy="534.1" r="27" fill="' + t.object_settings.color + '"/></g><path class="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>';
139                                    case"chat-db":
140                                        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:new -496 507.1 54 54;" xml:space="preserve"><style type="text/css">.sts1{fill:#FFFFFF;}</style><g><circle  cx="-469" cy="534.1" r="27" fill="' + t.object_settings.color + '"/></g><path class="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="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>';
141                                    default:
142                                        return '<svg version="1.1" id="ch" 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:new -496 507.7 54 54;" xml:space="preserve"><style type="text/css">.sts1 {fill: #FFFFFF;}.st0{fill: #808080;}</style><g><circle cx="-469" cy="534.7" r="27" fill="' + t.object_settings.color + '"/></g><path class="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"/>
142<path class="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="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>'
143                                }
144                            }(e), h = i("display_cta"), "" != g && "none" != h && (d += ' <div class="chaty-widget-i-title true"> ', d += g, d += "</div>"), d += "</div>", d += '<div class="chaty-widget-i chaty-close-settings i-trigger-close" data-title="' + e.object_settings.close_text + '" style="background-color:' + e.object_settings.color + '">', "" == e.object_settings.close_img ? (d += '<svg viewBox="0 0 54 54" fill="none" xmlns="http://www.w3.org/2000/svg">', d += '<ellipse cx="26" cy="26" rx="26" ry="26" fill="' + e.object_settings.color + '"/>', d += '<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"/>', d += '<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"/>', d += "</svg>") : d += "<span class='chaty-social-img'><img alt='" + e.object_settings.close_text + "' src='" + e.object_settings.close_img + "' /></span>", d += '<div class="chaty-widget-i-title">', d += e.object_settings.close_text, d += "</div>", d += "</div>", d += " </div>", 0 === n.length && !e.object_settings.isPRO && (d += ''), d += "</div>"
145                        } else ;
146                        t("body").append(d);
147                    }(e, token)), function () {
148                        var n = t(".chaty-widget"),
149                            a = e.object_settings.widget_size ? e.object_settings.widget_size : 54,
150                            c = +e.object_settings.widget_size + 8;
151
152                        function s() {
153                            var t = n.position().top, e = n.find(".chaty-widget-is .chaty-widget-i").length;
154                            if (jQuery("body").hasClass("chaty-in-desktop")) {
155                                e = n.find(".chaty-widget-is .chaty-widget-i.is-in-desktop").length;
156                            } else {
157                                e = n.find(".chaty-widget-is .chaty-widget-i.is-in-mobile").length;
158                            }
159                            if (e * c > (jQuery(window).height() - (chaty_settings.object_settings.widget_size + 8))) {
160                                var i = Math.round(Math.sqrt(e)), o = Math.ceil(Math.sqrt(e));
161                                n.find(".chaty-widget-is").css({
162                                    height: o * c,
163                                    width: i * c
164                                }), g(o), n.find("span:not(.cht-pending-message)").css({
165                                    height: o * c,
166                                    width: i * c
167                                }), g(o), n.find("img").css({height: o * c, width: i * c}), g(o)
168                            } else g()
169                        }
170
171                        function r() {
172                            "left" === e.object_settings.position && n.addClass("chaty-widget-is-right"), "custom" === e.object_settings.position && "left" === e.object_settings.pos_side && n.addClass("chaty-widget-is-right")
173                        }
174
175                        function g(t) {
176                            var e;
177                            if (jQuery("body").hasClass("chaty-in-desktop")) {
178                                e = n.find(".chaty-widget-is .chaty-widget-i.is-in-desktop").length;
179                            } else {
180                                e = n.find(".chaty-widget-is .chaty-widget-i.is-in-mobile").length;
181                            }
182                            n.find(".chaty-widget-i").css({
183                                height: a + "px",
184                                width: a + "px"
185                            }), n.find("img").css({
186                                height: a + "px",
187                                width: a + "px"
188                            }), n.find("span:not(.cht-pending-message)").css({
189                                height: a + "px",
190                                width: a + "px"
191                            }), n.find(".chaty-widget-is").css({top: "-" + 100 * e + "%"});
192                            n.find(".chaty-widget-is").height(e * (parseInt(a) + 8));
193                            n.find(".chaty-widget-is").width(parseInt(a) + 8);
194
195                            if (chaty_settings.object_settings.mode == "horizontal") {
196                                n.find(".chaty-widget-is").css({top: "0"});
197                                n.find(".chaty-widget-is").width(e * (parseInt(a) + 8));
198                                n.find(".chaty-widget-is").height(parseInt(a) + 8);
199                            } else {
200                                n.find(".chaty-widget-is").height(e * (parseInt(a) + 8));
201                                n.find(".chaty-widget-is").width(parseInt(a) + 8);
202                            }
203                        }
204
205                        if(jQuery(".open-it-by-default").length) {
206                            jQuery(".open-it-by-default").trigger("click");
207                        }
208
209                        r(), s(), jQuery(window).resize(function () {
210                            s(), 1 == Object.keys(e.object_settings.social).length && (jQuery(".chaty-widget").addClass("chaty-widget-show"), jQuery(".chaty-widget-is").css("top", "auto"))
211                            if(jQuery(".chaty-widget").hasClass("one_widget")) {
212                                jQuery(".chaty-widget").removeClass("chaty-widget-show");
213                            }
214                        }), t(".chaty-widget-i.facebook").mouseenter(function () {
215                            t(".facebook_two_mess").css({opacity: "1", "z-index": "1"}), t(this).addClass("before")
216                        }), t(".chaty-widget-i.facebook").mouseleave(function () {
217                            t(".facebook_two_mess").css({opacity: "0", "z-index": "1"}), t(this).removeClass("before")
218                        }), t(".chaty-widget-i.facebook").on("click", function () {
219                            t(this).addClass("active"), t(".facebook_two_mess").hide(), jQuery(".chaty-widget .get a").hide(), t(this).children(".face_title").css({
220                                opacity: "1",
221                                "z-index": "2"
222                            }).show(), t(".chaty-widget").hasClass("one_widget") ? t(".chaty-widget").hasClass("chaty-widget-is-right") ? t(".face_title").css({
223                                top: "calc(100% - 447px)",
224                                left: "20px"
225                            }) : t(".face_title").css({
226                                top: "calc(100% - 447px)",
227                                left: "auto",
228                                right: "20px"
229                            }) : (t(".facebook_two_mess").css({
230                                opacity: "0",
231                                "z-index": "10001"
232                            }), t(".ico_d").hide(), t(".chaty-widget .chaty-widget-i").css({"box-shadow": "0px 3px 6px rgba(0,0,0,0)"}), t(".chaty-widget").hasClass("one_widget") || t(".i-trigger").hide())
233                        }), t(".i-trigger-close").on("click", function (e) {
234                            e.preventDefault(), t(".chaty-widget-i.facebook").hasClass("active") || (n.removeClass("chaty-widget-show"), n.addClass("none-widget-show"))
235                        }), t("body").on("click", ".close_facebook", function () {
236                            t(".facebook_two_mess").show(), jQuery(".chaty-widget .get a").show(), t(".chaty-widget-i.facebook").removeClass("active"), t(this).parent().parent().css({opacity: "1"}).hide(), t(".i-trigger").show(), t(".chaty-widget-is .chaty-widget-i svg").show()
237                        }), t(".i-trigger-close").on("click", function (e) {
238                            t(".i-trigger-open").addClass("active_clos"), e.preventDefault(), t(".chaty-widget-i.facebook").hasClass("active") || (n.removeClass("chaty-widget-show"), n.addClass("none-widget-show"))
239                        }), t("body").on("click", ".update-analytics", function (t) {
240                            if (channelName = jQuery(this).attr("data-channel"), null != channelName && "" != channelName) if (window.hasOwnProperty("gtag")) gtag("event", "chaty_" + channelName, {
241                                eventCategory: "chaty_" + channelName,
242                                event_action: "chaty_" + channelName
243                            }); else if (window.hasOwnProperty("ga")) {
244                                var e = window.ga.getAll()[0];
245                                e && e.send("event", "click", {
246                                    eventCategory: "chaty_" + channelName,
247                                    eventAction: "chaty_" + channelName
248                                })
249                            }
250                        }), t("body").on("click", ".wechat", function () {
251                            var t = jQuery(".chaty-widget .chaty-widget-i.wechat").attr("data-code");
252                            null != t && "" != t && (jQuery("#wechat-qr-code").length || (htmlString = "<div id='wechat-qr-code' class='wechat-qr-code'>", htmlString += '<div class="wechat-box-head">WeChat<svg xmlns="http://www.w3.org/2000/svg" class="close_facebook" xmlns:xlink="http://www.w3.org/1999/xlink" version="1.1" id="Capa_1" x="0px" y="0px" width="612px" height="612px" viewBox="0 0 612 612" style="fill: #fff;    float: right; margin-top: 4px;" xml:space="preserve"><path xmlns="http://www.w3.org/2000/svg" d="M268.064,256.75l138.593-138.593c3.124-3.124,3.124-8.189,0-11.313c-3.125-3.124-8.189-3.124-11.314,0L256.75,245.436   L118.157,106.843c-3.124-3.124-8.189-3.124-11.313,0c-3.125,3.124-3.125,8.189,0,11.313L245.436,256.75L106.843,395.343   c-3.125,3.125-3.125,8.189,0,11.314c1.562,1.562,3.609,2.343,5.657,2.343s4.095-0.781,5.657-2.343L256.75,268.064l138.593,138.593   c1.563,1.562,3.609,2.343,5.657,2.343s4.095-0.781,5.657-2.343c3.124-3.125,3.124-8.189,0-11.314L268.064,256.75z"></path></svg></div>', htmlString += "<div class='wechat-box'><img src='" + t + "' alt='QR Code' /><a href='javascript:;'>", htmlString += "</a></div></div>", jQuery("body").append(htmlString)), jQuery("#wechat-qr-code").show())
253                        });
254                        var d = i("display_cta");
255                        if (chaty_settings.object_settings.display_state == "hover") {
256                            n.find(".i-trigger-open").mouseenter(function (e) {
257                                e.stopPropagation();
258                                //removeAnimation();
259                                //t(this).removeClass("active_clos");
260                                o(), t(".chaty-widget-is").removeAttr("id"), t(this).hasClass("active_clos") || t(".chaty-widget-i.facebook").hasClass("active") || n.hasClass("one_widget") || (r(), t(n).hasClass("chaty-widget-show") || (n.addClass("chaty-widget-show"), n.removeClass("none-widget-show")));
261                                if(jQuery(".chaty-widget").hasClass("one_widget")) {
262                                    jQuery(".chaty-widget").removeClass("chaty-widget-show");
263                                }
264                                //o();
265                                if (chaty_settings.object_settings.click_setting == 'click') {
266                                    if(!jQuery(".i-trigger").hasClass("one-widget")) {
267                                        jQuery(this).closest(".chaty-widget-i").addClass("hide-chaty-arrow");
268                                        jQuery("body .chaty-widget-i-title.true").remove();
269                                    }
270                                }
271                            });
272                        } else {
273                            n.find(".i-trigger-open").click(function (e) {
274                                e.stopPropagation();
275                                removeAnimation();
276                                o(), t(".chaty-widget-is").removeAttr("id"), t(this).hasClass("active_clos") || t(".chaty-widget-i.facebook").hasClass("active") || n.hasClass("one_widget") || (r(), t(n).hasClass("chaty-widget-show") || (n.addClass("chaty-widget-show"), n.removeClass("none-widget-show")));
277                                o();
278                                if (chaty_settings.object_settings.click_setting == 'click') {
279                                    if(!jQuery(".i-trigger").hasClass("one-widget")) {
280                                        jQuery(this).closest(".chaty-widget-i").addClass("hide-chaty-arrow");
281                                        jQuery("body .chaty-widget-i-title.true").remove();
282                                    }
283                                }
284                                jQuery(".cht-pending-message").remove();
285                            });
286                        }
287                        t(".one_widget").on("click", function () {
288                            //t(".chaty-widget-i-title").hasClass("face_title") ? (t(".facebook_two_mess").detach(), t(".chaty-widget-i").addClass("bofore_del")) : (t(".chaty-widget-i-title").detach(), t(".chaty-widget-i").addClass("bofore_del"));
289                            removeAnimation();
290                            jQuery(".cht-pending-message").remove();
291                        }), n.find(".i-trigger-open").on("click", function () {
292                            jQuery(".cht-pending-message").remove();
293                            "none" != d && (t(".chaty-widget").hasClass(".one_widget") || t(".i-trigger-open .chaty-widget-i-title1").detach());
294                            if (chaty_settings.object_settings.click_setting == "click") {
295                                t(".i-trigger-open").addClass("no-tooltip")
296                            };
297                            t(this).hasClass("active_clos") || t(".chaty-widget-i.facebook").hasClass("active") || n.hasClass("one_widget") || (r(), t(n).hasClass("chaty-widget-show") || (n.addClass("chaty-widget-show"), n.removeClass("none-widget-show")));
298                            removeAnimation();
299                        }), n.find(".i-trigger-open").mouseenter(function () {
300                            if (chaty_settings.object_settings.click_setting == "click") {
301                                t(this).addClass("no-tooltip");
302                            }
303                            t(".i-trigger-open").removeClass("active_clos");
304                            s();
305                        }), n.find(".chaty-widget-is").mouseleave(function () {
306                            t(".i-trigger-open").removeClass("active_clos"), t(".chaty-widget-i.facebook").hasClass("active")
307                        }), 1 === Object.keys(e.object_settings.social).length && n.find(".i-trigger-open").on("touchstart", function (e) {
308                            "use strict";
309                            t(this).find(".chaty-widget-i").toggleClass("hover")
310                        }), 1 == Object.keys(e.object_settings.social).length && (jQuery(".chaty-widget").addClass("chaty-widget-show"), jQuery(".chaty-widget-is").css("top", "auto"), jQuery(".chaty-widget-is").css("z-index", "10001"), jQuery(".chaty-widget-i.i-trigger-close, .i-trigger.chaty-widget-i").remove(), jQuery(".chaty-widget .get a").css("top", "-10px"), jQuery(".chaty-widget").addClass("one_widget"), jQuery(document).on("click", ".chaty-widget-i", function () {
311                            if(!jQuery(".i-trigger").hasClass("one-widget")) {
312                                jQuery(".chaty-widget-i:first .chaty-widget-i-title:last").hide(), jQuery("body").addClass("hide-cht-widget")
313                            }
314                        }), jQuery("body").append("<style>.chaty-widget-is{top:0!important;}</style>"))
315                    }(), t(document).ready(function () {
316                        1 !== Object.keys(e.object_settings.social).length || !e.object
316_settings.social.snapchat && !e.object_settings.social.wechat || e.object_settings.cta || (t(".chaty-widget-i-1title").detach(), t(".chaty-widget-i").addClass("bofore_del")), t(".chaty-widget-i-title").hasClass("one_go") && (t(".chaty-widget-i-title p").html(t(".chaty-widget-i-title.one_go").html()), "none" == i("display_cta") && (t(".chaty-widget-i-title").hasClass("face_title") ? (t(".facebook_two_mess").detach(), t(".chaty-widget-i").addClass("bofore_del")) : (t(".chaty-widget-i-title11").detach(), t(".chaty-widget-i").addClass("bofore_del")))), window.matchMedia("only screen and (max-width: 760px)").matches && t(".i-trigger-open").addClass("active_clos"), jQuery(".chaty-widget-i-title").each(function () {
317                            "" == jQuery(this).text() && jQuery(this).remove()
318                        })
319                    }), t(document).ready(function () {
320                        var activeWidget = 0;
321                        if (jQuery("body").hasClass("chaty-in-desktop")) {
322                            activeWidget = jQuery(".chaty-widget-is .chaty-widget-i.is-in-desktop").length;
323                        } else {
324                            activeWidget = jQuery(".chaty-widget-is .chaty-widget-i.is-in-mobile").length;
325                        }
326                        if (activeWidget == 0) {
327                            jQuery(".chaty-widget").addClass("hide-widget").removeClass("desktop_active").removeClass("mobile_active");
328                        } else {
329                            if (jQuery("body").hasClass("chaty-in-desktop")) {
330                                jQuery(".chaty-widget").removeClass("hide-widget").addClass("desktop_active");
331                            } else {
332                                jQuery(".chaty-widget").removeClass("hide-widget").addClass("mobile_active");
333                            }
334                            if (activeWidget == 1) {
335                                jQuery(".chaty-close-settings").hide();
336                                if (jQuery("body").hasClass("chaty-in-desktop")) {
337                                    htmlToAdd = jQuery(".chaty-widget-is .chaty-widget-i.is-in-desktop:first").clone();
338                                    jQuery(".i-trigger").html(htmlToAdd);
339                                } else {
340                                    htmlToAdd = jQuery(".chaty-widget-is .chaty-widget-i.is-in-mobile:first").clone();
341                                    jQuery(".i-trigger").html(htmlToAdd);
342                                }
343                                if(!get_cta_status()) {
344                                    if(chaty_settings.object_settings['click_setting'] != "all_time") {
345                                        jQuery(".i-trigger").attr("data-title", jQuery(".chaty-widget-is .chaty-widget-i-title p").html());
346                                        jQuery(".i-trigger .chaty-widget-i-title p").html(chaty_settings.object_settings.cta);
347                                    }
348                                } else {
349                                    if(chaty_settings.object_settings['click_setting'] != "all_time") {
350                                        jQuery(".i-trigger").addClass("show-channel");
351                                        jQuery(".i-trigger").attr("data-title", jQuery(".chaty-widget-is .chaty-widget-i-title p").html());
352                                    } else {
353                                        jQuery(".i-trigger .chaty-widget-i-title p").html(chaty_settings.object_settings.cta);
354                                    }
355                                }
356                                jQuery(".chaty-widget").addClass("one_widget");
357
358                                jQuery(".chaty-widget.one_widget, .i-trigger, .chaty-widget-i").mouseenter(function () {
359                                    o();
360                                    if (chaty_settings.object_settings.click_setting == 'click') {
361                                        if(!jQuery(".i-trigger").hasClass("one-widget")) {
362                                            jQuery(".chaty-widget-i-title").remove();
363                                            jQuery(".chaty-widget").addClass("hide-tooltip-arrow");
364                                        }
365                                        jQuery(".chaty-widget").removeClass("chaty-widget-show");
366                                    }
367                                    if(!jQuery(".i-trigger").hasClass("one-widget")) {
368                                        set_cta_status();
369                                    }
370                                    //removeAnimation();
371                                });
372                                jQuery(".chaty-widget").removeClass("chaty-widget-show");
373                                jQuery(".i-trigger").addClass("one-widget");
374                                if(get_cta_status());
375
376                                setCSSKeyFrames(jQuery(".i-trigger .chaty-widget-i:first").data("rgb"));
377                            } else {
378                                jQuery(".chaty-widget").removeClass("one_widget");
379                                if (chaty_settings.object_settings.click_setting == 'click') {
380                                    jQuery(".i-trigger .chaty-main-widget").remove();
381                                }
382                                jQuery(".chaty-close-settings").show();
383                                jQuery(".chaty-widget-i-title").removeClass("hide-it");
384                                jQuery(".chaty-widget.one_widget, .i-trigger, .chaty-widget-i").mouseenter(function () {
385                                    o();
386                                    if(!jQuery(".i-trigger").hasClass("one-widget")) {
387                                        set_cta_status();
388                                        if(!jQuery(".i-trigger").hasClass("one-widget")) {
389                                            jQuery(".i-trigger .chaty-widget-i-title").addClass("hide-it");
390                                        }
391                                    }
392                                    // jQuery(".chaty-widget").addClass("hide-tooltip-arrow");
393                                    removeAnimation();
394                                });
395
396                                if (chaty_settings.object_settings.display_state == "open") {
397                                    t(".i-trigger-open").addClass("no-tooltip")
398                                }
399
400                                setCSSKeyFrames(chaty_settings.object_settings.rgb_color);
401                            }
402                        }
403
404                        jQuery(document).on("click", ".i-trigger.one-widget", function(){
405                            set_cta_status();
406                        });
407
408                        /* check for display rules */
409                        var displayStatus = 0;
410                        if (parseInt(chaty_settings.object_settings.display_conditions) == 1) {
411                            var displayRules = chaty_settings.object_settings.display_rules;
412
413                            if (displayRules.length > 0) {
414                                var localDate = new Date();
415                                localDate.setHours(localDate.getHours() + (chaty_settings.object_settings.gmt));
416                                var utcHours = localDate.getUTCHours();
417                                var utcMin = localDate.getUTCMinutes();
418                                var utcDay = localDate.getUTCDay();
419                                for (var rule = 0; rule < displayRules.length; rule++) {
420                                    var hourStatus = 0;
421                                    var minStatus = 0;
422                                    var checkForTime = 0;
423                                    if (displayRules[rule].days == -1) {
424                                        checkForTime = 1;
425                                    } else if (displayRules[rule].days >= 0 && displayRules[rule].days <= 6) {
426                                        if (displayRules[rule].days == utcDay) {
427                                            checkForTime = 1;
428                                        }
429                                    } else if (displayRules[rule].days == 7) {
430                                        if (utcDay >= 0 && utcDay <= 4) {
431                                            checkForTime = 1;
432                                        }
433                                    } else if (displayRules[rule].days == 8) {
434                                        if (utcDay >= 1 && utcDay <= 5) {
435                                            checkForTime = 1;
436                                        }
437                                    } else if (displayRules[rule].days == 9) {
438                                        if (utcDay == 5 || utcDay == 6) {
439                                            checkForTime = 1;
440                                        }
441                                    }
442                                    if (checkForTime == 1) {
443                                        if (utcHours > displayRules[rule].start_hours && utcHours < displayRules[rule].end_hours) {
444                                            hourStatus = 1;
445                                        } else if (utcHours == displayRules[rule].start_hours && utcHours < displayRules[rule].end_hours) {
446                                            if (utcMin >= displayRules[rule].start_min) {
447                                                hourStatus = 1;
448                                            }
449                                        } else if (utcHours > displayRules[rule].start_hours && utcHours == displayRules[rule].end_hours) {
450                                            if (utcMin <= displayRules[rule].end_min) {
451                                                hourStatus = 1;
452                                            }
453                                        } else if (utcHours == displayRules[rule].start_hours && utcHours == displayRules[rule].end_hours) {
454                                            if (utcMin >= displayRules[rule].start_min && utcMin <= displayRules[rule].end_min) {
455                                                hourStatus = 1;
456                                            }
457                                        }
458
459                                        if (hourStatus == 1) {
460                                            if (utcMin >= displayRules[rule].start_min && utcMin <= displayRules[rule].end_min) {
461                                                minStatus = 1;
462                                            }
463                                        }
464                                    }
465
466                                    if (hourStatus == 1 && checkForTime == 1) {
467                                        displayStatus = 1;
468                                    }
469                                    if (displayStatus == 1) {
470                                        rule = displayRules.length + 1;
471                                    }
472                                }
473                            } else {
474                                displayStatus = 1;
475                            }
476                        } else {
477                            displayStatus = 1;
478                        }
479
480                        if (activeWidget == 1) {
481                            if (i("display_cta") != "") {
482                                if (chaty_settings.object_settings.click_setting == 'click') {
483                                    if(!jQuery(".i-trigger").hasClass("one-widget")) {
484                                        jQuery(".chaty-widget-i-title").remove();
485                                        jQuery(".chaty-widget").addClass("hide-tooltip-arrow");
486                                    }
487                                }
488                                setInterval(function () {
489                                    //set_cta_status();
490                                }, 10000);
491                            }
492
493                            jQuery(".chaty-main-widget").addClass("i-trigger-open").addClass("single-button");
494
495                            jQuery(".chaty-widget-show .i-trigger-open svg").css("transform", "rotate(0deg)");
496
497                            jQuery(".chaty-widget").removeClass("chaty-widget-show");
498                        }
499
500                        if (chaty_settings.object_settings.animation_class != "") {
501                            if (chaty_settings.object_settings.animation_class != "sheen") {
502                                jQuery(".i-trigger .chaty-widget-i svg").wrap(function () {
503                                    return "<div class='svg'></div>";
504                                });
505                            } else {
506                                if (!jQuery(".i-trigger .chaty-widget-i .wrap-svg").length) {
507                                    jQuery(".i-trigger .chaty-widget-i svg").wrap(function () {
508                                        return "<div class='wrap-svg'></div>";
509                                    });
510                                }
511                            }
512                        }
513
514                        if (!get_cta_status()) {
515                            if (chaty_settings.object_settings.pending_messages == "on") {
516                                if (chaty_settings.object_settings.animation_class != "sheen") {
517                                    if(jQuery(".i-trigger .i-trigger-open .svg, .i-trigger .i-trigger-open.single-button .svg").length) {
518                                        jQuery(".i-trigger .i-trigger-open .svg, .i-trigger .i-trigger-open.single-button .svg").append("<span class='cht-pending-message'>" + chaty_settings.object_settings.number_of_messages + "</span>");
519                                    } else if(jQuery(".i-trigger .i-trigger-open.single-button svg").length) {
520                                        jQuery(".i-trigger .i-trigger-open.single-button svg").after("<span class='cht-pending-message'>" + chaty_settings.object_settings.number_of_messages + "</span>");
521                                    } else {
522                                        jQuery(".i-trigger .i-trigger-open, .i-trigger .i-trigger-open.single-button svg").after("<span class='cht-pending-message'>" + chaty_settings.object_settings.number_of_messages + "</span>");
523                                    }
524                                } else {
525                                    jQuery(".i-trigger .i-trigger-open, .i-trigger .i-trigger-open.single-button").after("<span class='cht-pending-message'>" + chaty_settings.object_settings.number_of_messages + "</span>");
526                                }
527                                jQuery(".cht-pending-message").css("color", chaty_settings.object_settings.number_color);
528                                jQuery(".cht-pending-message").css("background", chaty_settings.object_settings.number_bg_color);
529                            }
530
531                            jQuery(document).on("click", ".i-trigger .i-trigger-open, .i-trigger.one-widget", function () {
532                                jQuery(".cht-pending-message").remove();
533
534                                if(chaty_settings.object_settings['click_setting'] != "all_time" && jQuery(this).hasClass("one-widget")) {
535                                    jQuery(this).addClass("show-channel");
536                                    var tooltipText = jQuery(this).data("title");
537                                    jQuery(this).find(".chaty-widget-i-title").find("p").html(tooltipText);
538                                }
539                            });
540                        }
541
542                        jQuery(document).on("click", ".i-trigger.one-widget", function(){
543                            if(chaty_settings.object_settings['click_setting'] != "all_time" && jQuery(this).hasClass("one-widget")) {
544                                jQuery(this).addClass("show-channel");
545                                var tooltipText = jQuery(this).data("title");
546                                jQuery(this).find(".chaty-widget-i-title").find("p").html(tooltipText);
547                            }
548                        });
549
550                        jQuery("chaty-main-widget").mouseenter(function () {
551                            if(!jQuery(".i-trigger").hasClass("one-widget")) {
552                                set_cta_status();
553                            }
554                        });
555
556                        if (displayStatus == 1) {
557                            var widget_status = is_chaty_settings_expired("cta_widget_status");
558                            if (!widget_status) {
559                                jQuery(".chaty-widget").removeClass("hide-widget");
560                                show_chaty_widget();
561                            } else {
562                                /* set animation */
563                                if (chaty_settings.object_settings.time_trigger == "no" && chaty_settings.object_settings.exit_intent == "no" && chaty_settings.object_settings.on_page_scroll == "no") {
564                                    jQuery(".chaty-widget").removeClass("hide-widget");
565                                    if (chaty_settings.object_settings.display_state == "open" && chaty_settings.object_settings.has_close_button == "no") {
566                                        chaty_settings.object_settings.has_close_button = "no";
567                                    } else {
568                                        chaty_settings.object_settings.display_state = "hover";
569                                        chaty_settings.object_settings.has_close_button = "yes";
570                                    }
571                                    show_chaty_widget();
572                                } else {
573                                    jQuery(".chaty-widget").addClass("hide-widget");
574                                    if (chaty_settings.object_settings.time_trigger == "yes") {
575                                        if(parseInt(chaty_settings.object_settings.trigger_time) > 0) {
576                                            setTimeout(function () {
577                                                if (!isWidgetEnabled) {
578                                                    jQuery(".chaty-widget").removeClass("hide-widget");
579                                                    show_chaty_widget();
580                                                }
581                                            }, parseInt(chaty_settings.object_settings.trigger_time) * 1000);
582                                        } else {
583                                            jQuery(".chaty-widget").removeClass("hide-widget");
584                                            show_chaty_widget();
585                                        }
586                                    }
587                                    if (chaty_settings.object_settings.exit_intent == "yes") {
588                                        function addEvent(obj, evt, fn) {
589                                            if (obj.addEventListener) {
590                                                obj.addEventListener(evt, fn, false);
591                                            } else if (obj.attachEvent) {
592                                                obj.attachEvent("on" + evt, fn);
593                                            }
594                                        }
595
596                                        addEvent(document, 'mouseout', function (evt) {
597                                            if (evt.toElement == null && evt.relatedTarget == null) {
598                                                var widget_status = get_chaty_cookie("cta_exit_intent_shown");
599                                                if (widget_status == null) {
600                                                    set_chaty_cookie("cta_exit_intent_shown", "yes", 1);
601                                                    isWidgetEnabled = true;
602                                                    jQuery(".chaty-widget").removeClass("hide-widget");
603                                                    jQuery(".chaty-widget").addClass("chaty-animation-widget");
604                                                    jQuery(".chaty-animation-widget").append("<div class='chaty-nav'></div>");
605                                                    if (chaty_settings.object_settings.display_state == "open" && chaty_settings.object_settings.has_close_button == "no") {
606                                                        chaty_settings.object_settings.has_close_button = "no";
607                                                    } else {
608                                                        chaty_settings.object_settings.display_state = "open";
609                                                        chaty_settings.object_settings.has_close_button = "yes";
610                                                    }
611                                                    show_chaty_widget();
612                                                    if (chaty_settings.object_settings.position == "left") {
613                                                        jQuery(".chaty-widget").addClass("left-position");
614                                                    } else if (chaty_settings.object_settings.position == "right") {
615                                                        jQuery(".chaty-widget").addClass("right-position");
616                                                    } else if (chaty_settings.object_settings.position == "custom") {
617                                                        if (e.object_settings.pos_side == "left") {
618                                                            jQuery(".chaty-widget").addClass("left-position");
619                                                        } else {
620                                                            jQuery(".chaty-widget").addClass("right-position");
621                                                        }
622                                                    }
623                                                    removeAnimation();
624                                                    setTimeout(function () {
625                                                        jQuery(".chaty-animation-widget").addClass("active");
626                                                    }, 100);
627                                                    setTimeout(function () {
628                                                        jQuery(".chaty-nav").remove();
629                                                    }, 2500);
630                                                }
631                                            }
632                                        });
633                                    }
634                                    if (chaty_settings.object_settings.on_page_scroll == "yes") {
635                                        if (parseInt(chaty_settings.object_settings.page_scroll) > 0) {
636                                            jQuery(window).scroll(function () {
637                                                if (!isWidgetEnabled) {
638                                                    var scrollHeight = jQuery(document).height() - jQuery(window).height();
639                                                    var scrollPos = jQuery(window).scrollTop();
640                                                    if (scrollPos != 0) {
641                                                        if (((scrollPos / scrollHeight) * 100) >= parseInt(chaty_settings.object_settings.page_scroll)) {
642                                                            jQuery(".chaty-widget").removeClass("hide-widget");
643                                                            show_chaty_widget();
644                                                        }
645                                                    }
646                                                }
647                                            });
648                                        } else {
649                                            jQuery(".chaty-widget").removeClass("hide-widget");
650                                            show_chaty_widget();
651                                        }
652                                    }
653                                }
654                            }
655                        } else {
656                            jQuery(".chaty-widget").addClass("hide-widget");
657                        }
658
659                        if(jQuery(".chaty-widget-i-title").length) {
660                            jQuery(".chaty-widget-i-title").each(function(){
661                                if(jQuery.trim(jQuery(this).text()) == "") {
662                                    jQuery(this).closest(".chaty-widget-i").addClass("hide-chaty-arrow");
663                                    jQuery(this).remove();
664                                }
665                            });
666                        }
667
668                        if(!jQuery(".chaty-widget-i.true.chaty-widget-i-title").length) {
669                            if(jQuery(".chaty-widget-i-title").text() == "") {
670                                jQuery(".chaty-widget-i").addClass("hide-chaty-arrow");
671                            }
672                        }
673
674                        if(!jQuery(".i-trigger-open .chaty-widget-i-title").length) {
675                            jQuery(".i-trigger .i-trigger-open").addClass("hide-chaty-arrow");
676                        } else {
677                            if(jQuery(".i-trigger-open .chaty-widget-i-title").text() == "") {
678                                jQuery(".i-trigger-open").addClass("hide-chaty-arrow");
679                            }
680                        }
681                    });
682                    jQuery(".chaty-widget-i-title").each(function () {
683                        if (jQuery(this).text() == "") {
684                            jQuery(this).closest(".chaty-widget-i").addClass("hide-chaty-arrow");
685                            jQuery(this).remove();
686                        }
687                    });
688
689                    if (!jQuery(".chaty-widget").hasClass("one_widget")) {
690                        jQuery("body").append("<div class='trigger-chaty-button'></div>");
691                    }
692
693                    jQuery("body").addClass(chaty_settings.object_settings.mode + "-cht-menu");
694                    jQuery("body").addClass(chaty_settings.object_settings.position + "-cht-position");
695                });
696            });
697
698            jQuery(document).on("click", ".trigger-chaty-button", function(){
699                //chaty_settings.object_settings.display_state = "open";
700                jQuery(".chaty-widget").removeClass("hide-widget");
701                show_chaty_widget();
702                if(jQuery(".chaty-widget").hasClass("none-widget-show") || !jQuery(".chaty-widget").hasClass("chaty-widget-show")) {
703                    jQuery(".i-trigger-open").trigger("click");
704                }
705            });
706
707            jQuery(document).on("click", ".has-custom-chaty-popup.whatsapp-button", function(e){
708                var timeInterval = 0;
709                if(jQuery("#chaty-inline-popup").length) {
710                    var thisIndex = jQuery(this).data("data-index");
711                    jQuery("#chaty-widget-"+thisIndex).removeClass("chaty-popup-open");
712                    jQuery(".chaty-popup-open").removeClass("chaty-popup-open");
713                    jQuery(".chaty-widget.hide-block").removeClass("active");
714                }
715                if(jQuery(this).hasClass("open-it-by-default")) {
716                    e.preventDefault();
717                }
718                jQuery("#chaty-inline-popup").remove();
719                if(jQuery(this).attr("data-popup") != undefined && jQuery(this).attr("data-popup") != "") {
720                    var thisIndex = "";
721                    var widgetIndex = "";
722                    jQuery(".chaty-widget").addClass("hide-block");
723                    jQuery(".chaty-widget").addClass("chaty-popup-open");
724                    var htmlString = "<div data-index='"+thisIndex+"' id='chaty-inline-popup' class='chaty-inline-popup chaty-popup-form "+jQuery(this).data("channel")+"-channel'>";
725                    htmlString += jQuery(this).attr("data-popup");
726                    htmlString + "</div>";
727                    jQuery("body").append(htmlString);
728
729                    if(jQuery(".chaty-inline-popup .default-value").length) {
730
731                        thisHref = jQuery(".chaty-inline-popup .default-value").text();
732                        thisHref = decodeURI(thisHref);
733                        thisHref = thisHref.replace(/{title}/g, jQuery("title").text());
734                        thisHref = thisHref.replace(/{url}/g, window.location.href);
735
736                        jQuery(".chaty-whatsapp-msg").val(jQuery(".chaty-inline-popup .default-value").text());
737                        jQuery(".chaty-whatsapp-phone").val(jQuery(".chaty-inline-popup .default-msg-phone").text());
738
739                        chatyHtml = jQuery(".chaty-inline-popup .default-msg-value").html();
740                        chatyHtml = chatyHtml.replace(/{title}/g, jQuery("title").text());
741                        chatyHtml = chatyHtml.replace(/{url}/g, window.location.href);
742
743                        jQuery(".chaty-whatsapp-message").html(chatyHtml);
744                    }
745                    jQuery(".chaty-widget").addClass("active");
746                    setTimeout(function(){
747                        jQuery("#chaty-inline-popup").addClass("active");
748                    }, 150);
749                    if(!jQuery("body").hasClass("chaty-in-mobile")) {
750                        jQuery(".chaty-whatsapp-msg").focus();
751                    }
752                }
753                if(isChatyInMobile) {
754                    jQuery(".whatsapp-chaty-form").prop("target", "");
755                }
756            });
757
758            jQuery(document).on("click", ".close-chaty-popup, .close-chaty-box", function(){
759                if(jQuery(this).hasClass("is-whatsapp-btn")) {
760                    save_chaty_settings("cht_whatsapp_window");
761                }
762                jQuery("#chaty-inline-popup").removeClass("active");
763
764                jQuery(".chaty-widget").removeClass("chaty-popup-open");
765                setTimeout(function(){
766                    jQuery(".chaty-widget.hide-block").removeClass("active");
767                }, 250);
768            });
769
770            jQuery(document).on("submit", ".whatsapp-chaty-form", function(e){
771                save_chaty_settings("cht_whatsapp_window");
772                jQuery("#chaty-inline-popup").removeClass("active");
773                jQuery(".chaty-widget").removeClass("chaty-popup-open");
774                setTimeout(function(){
775                    jQuery(".chaty-widget.hide-block").removeClass("active");
776                }, 250);
777                if(jQuery("body").hasClass("chaty-in-mobile")) {
778                    e.preventDefault();
779                    window.location = "https://wa.me/"+jQuery(this).find(".chaty-whatsapp-phone").val()+"?text="+jQuery(this).find(".chaty-whatsapp-m
779sg").val();
780                    return false;
781                }
782            });
783
784
785            jQuery(document).on("submit", ".chaty-contact-form-data", function(e){
786                var inputErrorCounter = 0;
787                jQuery(".has-chaty-error").removeClass("has-chaty-error");
788                jQuery(".chaty-error-msg").remove();
789                jQuery(".chaty-ajax-error-message").remove();
790                jQuery(".chaty-ajax-success-message").remove();
791                jQuery(this).find(".is-required").each(function(){
792                    if(jQuery.trim(jQuery(this).val()) == "") {
793                        inputErrorCounter++;
794                        jQuery(this).addClass("has-chaty-error");
795                    }
796                });
797                if(inputErrorCounter == 0) {
798                    var $form = jQuery(this);
799                    jQuery(".chaty-contact-submit-btn").attr("disabled", true);
800                    jQuery.ajax({
801                        url: chaty_settings.ajax_url,
802                        data: {
803                            action: "chaty_front_form_save_data",
804                            name:   $form.find(".chaty-field-name").length?$form.find(".chaty-field-name").val():"",
805                            email:  $form.find(".chaty-field-email").length?$form.find(".chaty-field-email").val():"",
806                            phone:  $form.find(".chaty-field-phone").length?$form.find(".chaty-field-phone").val():"",
807                            message: $form.find(".chaty-field-message").length?$form.find(".chaty-field-message").val():"",
808                            nonce:  $form.find(".chaty-field-nonce").length?$form.find(".chaty-field-nonce").val():"",
809                            channel: $form.find(".chaty-field-channel").length?$form.find(".chaty-field-channel").val():"",
810                            widget: $form.find(".chaty-field-widget").length?$form.find(".chaty-field-widget").val():"",
811                            ref_url: window.location.href
812                        },
813                        type: 'post',
814                        async: true,
815                        defer: true,
816                        success: function (response) {
817                            response = jQuery.parseJSON(response);
818                            jQuery(".chaty-ajax-error-message").remove();
819                            jQuery(".chaty-ajax-success-message").remove();
820                            jQuery(".chaty-contact-submit-btn").attr("disabled", false);
821                            if(response.status == 1) {
822                                jQuery(".chaty-contact-footer").append("<div class='chaty-ajax-success-message'>"+response.message+"</div>");
823                                jQuery(".chaty-field-name, .chaty-field-email, .chaty-field-message").val("");
824                                if(response.redirect_action == "yes") {
825                                    if( response.link_in_new_tab == "yes" ) {
826                                        window.open( response.redirect_link, '_blank' );
827                                    } else {
828                                        window.location = response.redirect_link;
829                                    }
830                                }
831                                if(response.close_form_after == "yes") {
832                                    setTimeout(function(){
833                                        jQuery("#chaty-inline-popup").removeClass("active");
834                                        jQuery(".chaty-widget").removeClass("chaty-popup-open");
835                                        setTimeout(function(){
836                                            jQuery(".chaty-widget.hide-block").removeClass("active");
837                                        }, 250);
838                                    }, parseInt(response.close_form_after_seconds)*1000);
839                                }
840                            } else if(response.error == 1) {
841                                if(response.errors.length) {
842                                    for(var i=0; i<response.errors.length; i++) {
843                                        jQuery("."+response.errors[i].field).addClass("has-chaty-error");
844                                        jQuery("."+response.errors[i].field).after("<span class='chaty-error-msg'>"+response.errors[i].message+"</span>");
845                                    }
846                                }
847                            } else {
848                                jQuery(".chaty-contact-footer").append("<div class='chaty-ajax-error-message'>"+response.message+"</div>");
849                            }
850                        }
851                    });
852                } else {
853                    jQuery(".has-chaty-error:first").focus();
854                }
855                return false;
856            });
857
858            function setCSSKeyFrames(colorCode) {
859                var colorString = '@-webkit-keyframes chaty-animation-shockwave ' +
860                    '{ ' +
861                    '0% { transform: scale(1); box-shadow: 0 0 2px rgba('+colorCode+', 0.30), inset 0 0 1px rgba('+colorCode+', 0.30); } ' +
862                    '95% { box-shadow: 0 0 50px rgba('+colorCode+', 0), inset 0 0 30px rgba('+colorCode+', 0); } ' +
863                    '100% { transform: scale(2.25); } ' +
864                    '} ' +
865                    '' +
866                    '@keyframes chaty-animation-shockwave { ' +
867                    '0% { transform: scale(1); box-shadow: 0 0 2px rgba('+colorCode+', 0.30), inset 0 0 1px rgba('+colorCode+', 0.30); } ' +
868                    '95% { box-shadow: 0 0 50px rgba('+colorCode+', 0), inset 0 0 30px rgba('+colorCode+', 0); } ' +
869                    '100% { transform: scale(2.25); } ' +
870                    '}';
871                if(!jQuery("#chaty-advance-css").length) {
872                    jQuery("body").append("<div id='chaty-advance-css'></div>");
873                }
874                jQuery("#chaty-advance-css").append("<style>"+colorString+"</style>");
875            }
876
877            function get_cta_status() {
878                var cookieStr = "cta";
879                var cookieValue = check_for_chaty_settinigs(cookieStr);
880                if(cookieValue != null && cookieValue != "") {
881                    cookieValue = new Date(cookieValue);
882                    var diffTime = Math.abs(new Date() - cookieValue);
883                    var diffMin = Math.floor(diffTime / (1000 * 60));
884                    if(diffMin <= 10) {
885                        return true;
886                    } else {
887                        return false;
888                    }
889                }
890                return false;
891            }
892
893            function check_for_chaty_settinigs(cookieStr) {
894                var cookieString = get_chaty_cookie("chaty_settings");
895                var cookieArray = [];
896                if(cookieString != null && cookieString != "") {
897                    cookieArray = JSON.parse(cookieString);
898                }
899                if(cookieArray.length > 0) {
900                    for(var i=0; i<cookieArray.length; i++) {
901                        if(cookieArray[i]['k'] == cookieStr) {
902                            return cookieArray[i]['v'];
903                        }
904                    }
905                }
906                return null;
907            }
908
909            function save_chaty_settings(cookieStr) {
910                var cookieString = get_chaty_cookie("chaty_settings");
911                var cookieArray = [];
912                if(cookieString != null && cookieString != "") {
913                    cookieArray = JSON.parse(cookieString);
914                }
915                var cookieFound = false;
916                if(cookieArray.length > 0) {
917                    for(var i=0; i<cookieArray.length; i++) {
918                        if(cookieArray[i]['k'] == cookieStr) {
919                            cookieFound = true;
920                            cookieArray[i]['v'] = new Date();
921                        }
922                    }
923                }
924                if(!cookieFound) {
925                    cookieArray.push({"k": cookieStr, "v": new Date()});
926                }
927                cookieString = JSON.stringify(cookieArray);
928                set_chaty_cookie("chaty_settings", cookieString, "7");
929            }
930
931            function is_chaty_settings_expired(cookieStr) {
932                var cookieValue = check_for_chaty_settinigs(cookieStr);
933                if(cookieValue != null && cookieValue != "") {
934                    cookieValue = new Date(cookieValue);
935                    var diffTime = Math.abs(new Date() - cookieValue);
936                    var diffDays = Math.floor(diffTime / (1000 * 60 * 60 * 24));
937                    if(diffDays >= 1) {
938                        return true;
939                    } else {
940                        return false;
941                    }
942                }
943                return true;
944            }
945
946            function set_cta_status() {
947                var cookieStr = "cta";
948                var cookieString = get_chaty_cookie("chaty_settings");
949                var cookieArray = [];
950                if(cookieString != null && cookieString != "") {
951                    cookieArray = JSON.parse(cookieString);
952                }
953                var cookieFound = false;
954                if(cookieArray.length > 0) {
955                    for(var i=0; i<cookieArray.length; i++) {
956                        if(cookieArray[i]['k'] == cookieStr) {
957                            cookieFound = true;
958                            cookieArray[i]['v'] = new Date();
959                        }
960                    }
961                }
962                if(!cookieFound) {
963                    cookieArray.push({"k": cookieStr, "v": new Date()});
964                }
965                cookieString = JSON.stringify(cookieArray);
966                set_chaty_cookie("chaty_settings", cookieString, "7");
967            }
968
969            function set_chaty_cookie(name,value,days) {
970                var expires = "";
971                if (days) {
972                    var date = new Date();
973                    date.setTime(date.getTime() + (days * 24 * 60 * 60 * 1000));
974                    expires = "; expires=" + date.toUTCString();
975                }
976                document.cookie = name + "=" + (value || "") + expires + "; path=/";
977            }
978            function get_chaty_cookie(name) {
979                var nameEQ = name + "=";
980                var ca = document.cookie.split(';');
981                for(var i=0;i < ca.length;i++) {
982                    var c = ca[i];
983                    while (c.charAt(0)==' ') c = c.substring(1,c.length);
984                    if (c.indexOf(nameEQ) == 0) return c.substring(nameEQ.length,c.length);
985                }
986                return null;
987            }
988
989            function show_chaty_widget() {
990                save_chaty_settings("cta_widget_status");
991                isWidgetEnabled = 1;
992                var activeWidget = 0;
993                if(jQuery("body").hasClass("chaty-in-desktop")) {
994                    activeWidget = jQuery(".chaty-widget-is .chaty-widget-i.is-in-desktop").length;
995                } else {
996                    activeWidget = jQuery(".chaty-widget-is .chaty-widget-i.is-in-mobile").length;
997                }
998                var chatyAnimation = is_chaty_settings_expired("chaty-animation");
999                if(!chatyAnimation) {
1000                    chaty_settings.object_settings.animation_class = "";
1001                }
1002
1003                if(chaty_settings.object_settings.animation_class != "") {
1004                    // jQuery(".i-trigger .chaty-widget-i svg").wrap(function() {
1005                    //     return "<div class='svg'></div>";
1006                    // });
1007                    if(chaty_settings.object_settings.animation_class != "sheen") {
1008                        if (activeWidget > 1) {
1009                            jQuery(animationClass).addClass("chaty-animation-" + chaty_settings.object_settings.animation_class).addClass("start-now");
1010                        } else if (activeWidget == 1) {
1011                            animationClass = ".chaty-main-widget .svg, .chaty-main-widget img, .chaty-main-widget .facustom-icon";
1012                            jQuery(animationClass).removeClass("chaty-animation-" + chaty_settings.object_settings.animation_class).removeClass("start-now");
1013                            jQuery(animationClass).addClass("chaty-animation-" + chaty_settings.object_settings.animation_class).addClass("start-now");
1014                        }
1015                    } else {
1016                        animationClass = ".i-trigger .chaty-widget-i .wrap-svg";
1017                        if(!jQuery(".i-trigger .chaty-widget-i .wrap-svg").length) {
1018                            // jQuery(".i-trigger .chaty-widget-i svg").wrap(function() {
1019                            //     return "<div class='wrap-svg'></div>";
1020                            // });
1021                        }
1022                        jQuery(animationClass).removeClass("chaty-animation-sheen").removeClass("start-now");
1023                        jQuery(animationClass).addClass("chaty-animation-sheen").addClass("start-now");
1024                    }
1025                }
1026
1027                if(chaty_settings.object_settings.display_state == "open") {
1028                    if(chaty_settings.object_settings.has_close_button == "no") {
1029                        if(activeWidget > 1) {
1030                            removeAnimation();
1031                            jQuery(".chaty-widget").find(".i-trigger-open").removeClass("active_clos");
1032                            jQuery(".chaty-widget").find(".i-trigger-open").trigger("click");
1033                            jQuery(".chaty-widget-is").addClass("has-no-close-btn");
1034                            jQuery(".i-trigger").remove();
1035                        }
1036                    } else {
1037                        if(activeWidget > 1) {
1038                            removeAnimation();
1039                            jQuery(".chaty-widget").find(".i-trigger-open").removeClass("active_clos");
1040                            jQuery(".chaty-widget").find(".i-trigger-open").trigger("click");
1041                        }
1042                    }
1043                }
1044
1045                if(jQuery(".chaty-widget").hasClass("one_widget")) {
1046                    jQuery(".chaty-widget").removeClass("chaty-widget-show");
1047                }
1048            }
1049
1050            function removeAnimation() {
1051                save_chaty_settings("chaty-animation");
1052                jQuery(".chaty-animation-" + chaty_settings.object_settings.animation_class).removeClass("chaty-animation-" + chaty_settings.object_settings.animation_class).removeClass("start-now");
1053                jQuery(".start-now").removeClass("start-now");
1054                chaty_settings.object_settings.animation_class = "";
1055            }
1056        }(jQuery)
1057    }, 12: function (t, e) {
1058    }
1059});
1060
1061
1062function launch_chaty() {
1063    if(!jQuery(".chaty-widget").hasClass("one_widget")) {
1064        jQuery(".trigger-chaty-button").trigger("click");
1065    }
1066}
1067function close_chaty() {
1068    if(jQuery("#chaty-inline-popup").hasClass("active")) {
1069        jQuery("#chaty-inline-popup .close-chaty-popup").trigger("click");
1070    }
1071    if(jQuery(".chaty-widget.chaty-widget-show").length) {
1072        jQuery(".chaty-widget.chaty-widget-show").each(function(){
1073            if(jQuery(this).find(".chaty-close-settings").length) {
1074                jQuery(this).find(".chaty-close-settings").trigger("click");
1075            }
1076        });
1077    }
1078}

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.