(function ($) {
    $.widget('Conversion.ManagedButton', {
        options: {
            validation: false
        },
        _create: function () {
            this.$errorDiv = $('<div class="form__error-summary padding-small"></div>');

            this.BindEvents();
        },

        _destroy: function () { },

        _setOption: function (key, value) { },

        BindEvents: function () {

            var me = this;

            this.element.click(function (e) {

                if ($(this).hasClass('is-disabled')) {
                    e.preventDefault();
                    return false;
                }

                if (me.options.validation) {
                    if (!$(this).closest("form").valid()) {
                        //allow default (validation will show error messages and scroll to invalid field)
                        return true;
                    }
                }

                me._ShowSpinnerAndDisableButton();
                return true;
            });
        },

        ShowErrorMessage: function (errorMessage) {
            this._RemoveSpinnerAndEnableButton();
            this.$errorDiv.html('<p>' + errorMessage + '</p>');
            this.element.before(this.$errorDiv);
        },

        ShowSuccess: function () {
            this._RemoveSpinnerAndEnableButton();
            this.RemoveErrorMessage();
        },

        RemoveErrorMessage: function () {
            this.$errorDiv.remove();
        },

        _ShowSpinnerAndDisableButton: function () {
            this.RemoveErrorMessage();
            this.element.addClass('btn--waiting is-disabled');
        },

        _RemoveSpinnerAndEnableButton: function () {
            this.element.removeClass('btn--waiting is-disabled');
        }
    });
})(window.jQuery);;
(function ($) {
    $.widget("Conversion.conversionRecallForm", {
        options: {
            recallSubmitBtnClass: ".jq_recallFormButton",
            recallFormWrapperClass: ".jq_recallFormWrapper",
            recallErrorClass: ".jq_recallFormError",
            recallDeviceClass: ".jq_deviceType",
            recallFormContainerToRemoveClass: ".jq_recallContainer",
            guidPerView: ""
        },

        //_removeContainer: null,

        _wrapperElement: function () { return $(this.element).parents(this.options.recallFormWrapperClass); },

        _create: function () {

            //var container = $(this.element).parents(this.options.recallFormWrapperClass);
            //console.log(container);
            //console.log($(this.element).filter(this.options.recallDeviceClass));
            
            if (this.options.simpleInit) {

            }
            else {
                this.BindEvents();
                this.element.data('onSubmitTracking', new Array());

                //set deviceType in a hidden field, used to change partnery key on mobile device
                var agent = navigator.userAgent || navigator.vendor || window.opera;
                var device = "desktop";
                if (/Mobi/.test(agent)) {
                    device = "mobile";
                }

                $(this.element).find(this.options.recallDeviceClass).val(device);

                //$(this.options.recallDeviceClass).val(device);
            }            
        },

        HandleResult: function (data, xhr, status) {

            
            var Base64 = { _keyStr: "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=", encode: function (e) { var t = ""; var n, r, i, s, o, u, a; var f = 0; e = Base64._utf8_encode(e); while (f < e.length) { n = e.charCodeAt(f++); r = e.charCodeAt(f++); i = e.charCodeAt(f++); s = n >> 2; o = (n & 3) << 4 | r >> 4; u = (r & 15) << 2 | i >> 6; a = i & 63; if (isNaN(r)) { u = a = 64 } else if (isNaN(i)) { a = 64 } t = t + this._keyStr.charAt(s) + this._keyStr.charAt(o) + this._keyStr.charAt(u) + this._keyStr.charAt(a) } return t }, decode: function (e) { var t = ""; var n, r, i; var s, o, u, a; var f = 0; e = e.replace(/[^A-Za-z0-9+/=]/g, ""); while (f < e.length) { s = this._keyStr.indexOf(e.charAt(f++)); o = this._keyStr.indexOf(e.charAt(f++)); u = this._keyStr.indexOf(e.charAt(f++)); a = this._keyStr.indexOf(e.charAt(f++)); n = s << 2 | o >> 4; r = (o & 15) << 4 | u >> 2; i = (u & 3) << 6 | a; t = t + String.fromCharCode(n); if (u != 64) { t = t + String.fromCharCode(r) } if (a != 64) { t = t + String.fromCharCode(i) } } t = Base64._utf8_decode(t); return t }, _utf8_encode: function (e) { e = e.replace(/rn/g, "n"); var t = ""; for (var n = 0; n < e.length; n++) { var r = e.charCodeAt(n); if (r < 128) { t += String.fromCharCode(r) } else if (r > 127 && r < 2048) { t += String.fromCharCode(r >> 6 | 192); t += String.fromCharCode(r & 63 | 128) } else { t += String.fromCharCode(r >> 12 | 224); t += String.fromCharCode(r >> 6 & 63 | 128); t += String.fromCharCode(r & 63 | 128) } } return t }, _utf8_decode: function (e) { var t = ""; var n = 0; var r = 0; var c1 = 0; var c2 = 0; while (n < e.length) { r = e.charCodeAt(n); if (r < 128) { t += String.fromCharCode(r); n++ } else if (r > 191 && r < 224) { c2 = e.charCodeAt(n + 1); t += String.fromCharCode((r & 31) << 6 | c2 & 63); n += 2 } else { c2 = e.charCodeAt(n + 1); var c3 = e.charCodeAt(n + 2); t += String.fromCharCode((r & 15) << 12 | (c2 & 63) << 6 | c3 & 63); n += 3 } } return t } }

            var hasMessageTypeValue = String(data).includes("messageType");
            var messageTypeValue = "error";
            if (hasMessageTypeValue) {
                if (String(data).includes("messageType:confirmation")) {
                    messageTypeValue = "confirmation";
                }
                if (String(data).includes("messageType:download")) {
                    messageTypeValue = "download";
                }
            }
            //retrieve tracking info
            var tracking = this.element.data('onSubmitTracking');
               
            var gtmTrackingParams = this.element.data('GTMConversionTracking');

            if (gtmTrackingParams != null && gtmTrackingParams.length > 0) {
                var params = "";
                $.each(gtmTrackingParams[0], function (key, value) {
                    var val = value;
                    if (val.indexOf("form-id:") === 0) {
                        val = Base64.encode($("#" + value.replace("form-id:", "")).val());
                    }
                    params += '"' + key + '"' + ':"' + val + '",';
                });
                params += '"lp_recallResult"' + ':"' + messageTypeValue + '"';
                //params = params.slice(0, -1);
               
                var paramsJSON = JSON.parse("{" + params + "}");
                dataLayer.push( paramsJSON );
            }

            $(this.element).find(this.options.recallSubmitBtnClass).managedButton("ShowSuccess");
            //replace form with confirmation message
            //$(this.options.recallFormWrapperClass).html(data);
            $(this.element).parents(this.options.recallFormWrapperClass).html(data);
            //$(this.options.recallSubmitBtnClass).managedButton("ShowSuccess");
            

            //call submit trackings
            var self = this;
            $(tracking).each(function (index, element) {
                var trackingUrl = element.replace("{0}", $(self.options.guidPerView));
                
                //$(self.options.recallFormWrapperClass).append("<iframe frameborder='0' src='" + trackingUrl + "' width='1' height='1'></iframe>");
                $(self.element).parents(self.options.recallFormWrapperClass).append("<iframe frameborder='0' src='" + trackingUrl + "' width='1' height='1'></iframe>");
                

            });
        },

        OnError: function () {
            //$(this.options.recallSubmitBtnClass).managedButton("ShowErrorMessage", $(this.options.recallErrorClass).html());
            $(this.element).find(this.options.recallSubmitBtnClass).managedButton("ShowErrorMessage", $(this.options.recallErrorClass).html());
        },


        BindEvents: function () {
            //$(this.options.recallSubmitBtnClass).managedButton({ validation: true });
            $(this.element).find(this.options.recallSubmitBtnClass).managedButton({ validation: true });
        },

        RegisterSubmitTracking: function (urlTracker) {
            var tracking = this.element.data('onSubmitTracking');
            tracking.push(urlTracker);
            this.element.data('onSubmitTracking', tracking);
        },

        RegisterGTMSubmitTracking: function(parameters) {
            this.element.data('GTMConversionTracking', parameters);
        },

        /*RegisterRemoveContainerCallback: function(removeContainerCallback) {
            
            this._removeContainer = removeContainerCallback;
        },*/

        RemoveContainer: function () {

            $(this.element).find(this.options.recallSubmitBtnClass).remove();

        },

        Dummy: function (a) {
            //console.log(a);
        }

        


        
    });


})(window.jQuery);;
(function ($) {
    $.widget("Conversion.conversionRecallFormV2", {
        options: {
            recallSubmitBtnClass: ".jq_recallFormButton",
            recallFormWrapperClass: ".jq_recallFormWrapper",
            recallFormHideAfterSubmitOkClass:".jq_recallFormHideAfterSubmitOk",
            recallErrorClass: ".jq_recallFormError",
            recallDeviceClass: ".jq_deviceType",
            guidPerView: "",
            gtmTrackingParams: {},
            instanceKey: ""

        },

        //_removeContainer: null,

        _wrapperElement: function () { return $(this.element).parents(this.options.recallFormWrapperClass); },

        _create: function () {

            //var container = $(this.element).parents(this.options.recallFormWrapperClass);
            //console.log(container);
            //console.log($(this.element).filter(this.options.recallDeviceClass));
            
            if (this.options.simpleInit) {

            }
            else {
                this.BindEvents();
                //this.element.data('onSubmitTracking', new Array());

                //set deviceType in a hidden field, used to change partnery key on mobile device
                var agent = navigator.userAgent || navigator.vendor || window.opera;
                var device = "desktop";
                if (/Mobi/.test(agent)) {
                    device = "mobile";
                }

                $(this.element).find(this.options.recallDeviceClass).val(device);
                
            }

            $(window).trigger("recallForm:initCompleted", [this.options.instanceKey, "#jq_recall_form-" + this.options.instanceKey]);

        },

        HandleResult: function (data, xhr, status) {


            
            var Base64 = { _keyStr: "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=", encode: function (e) { var t = ""; var n, r, i, s, o, u, a; var f = 0; e = Base64._utf8_encode(e); while (f < e.length) { n = e.charCodeAt(f++); r = e.charCodeAt(f++); i = e.charCodeAt(f++); s = n >> 2; o = (n & 3) << 4 | r >> 4; u = (r & 15) << 2 | i >> 6; a = i & 63; if (isNaN(r)) { u = a = 64 } else if (isNaN(i)) { a = 64 } t = t + this._keyStr.charAt(s) + this._keyStr.charAt(o) + this._keyStr.charAt(u) + this._keyStr.charAt(a) } return t }, decode: function (e) { var t = ""; var n, r, i; var s, o, u, a; var f = 0; e = e.replace(/[^A-Za-z0-9+/=]/g, ""); while (f < e.length) { s = this._keyStr.indexOf(e.charAt(f++)); o = this._keyStr.indexOf(e.charAt(f++)); u = this._keyStr.indexOf(e.charAt(f++)); a = this._keyStr.indexOf(e.charAt(f++)); n = s << 2 | o >> 4; r = (o & 15) << 4 | u >> 2; i = (u & 3) << 6 | a; t = t + String.fromCharCode(n); if (u != 64) { t = t + String.fromCharCode(r) } if (a != 64) { t = t + String.fromCharCode(i) } } t = Base64._utf8_decode(t); return t }, _utf8_encode: function (e) { e = e.replace(/rn/g, "n"); var t = ""; for (var n = 0; n < e.length; n++) { var r = e.charCodeAt(n); if (r < 128) { t += String.fromCharCode(r) } else if (r > 127 && r < 2048) { t += String.fromCharCode(r >> 6 | 192); t += String.fromCharCode(r & 63 | 128) } else { t += String.fromCharCode(r >> 12 | 224); t += String.fromCharCode(r >> 6 & 63 | 128); t += String.fromCharCode(r & 63 | 128) } } return t }, _utf8_decode: function (e) { var t = ""; var n = 0; var r = 0; var c1 = 0; var c2 = 0; while (n < e.length) { r = e.charCodeAt(n); if (r < 128) { t += String.fromCharCode(r); n++ } else if (r > 191 && r < 224) { c2 = e.charCodeAt(n + 1); t += String.fromCharCode((r & 31) << 6 | c2 & 63); n += 2 } else { c2 = e.charCodeAt(n + 1); var c3 = e.charCodeAt(n + 2); t += String.fromCharCode((r & 15) << 12 | (c2 & 63) << 6 | c3 & 63); n += 3 } } return t } }

               
            var gtmTrackingParams = this.options.gtmTrackingParams;


            var element = this.element;

            $.each(gtmTrackingParams, function (key, value) {

                if (value.indexOf("form-id:") === 0) {
                    var formField = $(element).find("input[name = '" + value.replace("form-id:", "") + "']");
                    gtmTrackingParams[key] = Base64.encode($(formField).val());
                }

            });

            if (!(typeof dataLayer == "undefined"))
            {
                dataLayer.push(gtmTrackingParams);
            }
            

            

            $(this.element).find(this.options.recallSubmitBtnClass).managedButton("ShowSuccess");
            //replace form with confirmation message
            $(this.element).parents(this.options.recallFormWrapperClass).html(data);
            $(this.options.recallFormHideAfterSubmitOkClass).hide();


           
        },

        OnError: function () {
            $(this.element).find(this.options.recallSubmitBtnClass).managedButton("ShowErrorMessage", $(this.options.recallErrorClass).html());
        },


        BindEvents: function () {
            $(this.element).find(this.options.recallSubmitBtnClass).managedButton({ validation: true });
        },

        //RegisterSubmitTracking: function (urlTracker) {
        //    var tracking = this.element.data('onSubmitTracking');
        //    tracking.push(urlTracker);
        //    this.element.data('onSubmitTracking', tracking);
        //},

        //RegisterGTMSubmitTracking: function(parameters) {
        //    this.element.data('GTMConversionTracking', parameters);
        //},        

        RemoveContainer: function () {
            $(this.element).find(this.options.recallSubmitBtnClass).remove();
        },

        ChangePartnerKey: function (newPartnerKey) {
            $(this.element).find("input[name='PartnerKey']").val(newPartnerKey);
        },

        GetGTMParams: function() {
            return this.options.gtmTrackingParams;
        },

        SetGTMParams: function (params) {
            this.options.gtmTrackingParams = params;
        }

        //Dummy: function (a) { console.log(a); }

        


        
    });


})(window.jQuery);;
(function ($) {
    $.widget("Conversion.callMeBackAltitude", {
        options: {
            recallSubmitBtnClass: ".jq_recallFormButton",
            recallFormWrapperClass: ".jq_recallFormWrapper",
            recallFormHideAfterSubmitOkClass: ".jq_recallFormHideAfterSubmitOk",
            recallErrorClass: ".jq_recallFormError",
            recallDeviceClass: ".jq_deviceType",
            guidPerView: "",
            gtmTrackingParams: {},
            instanceKey: ""
        },

        _wrapperElement: function () { return $(this.element).parents(this.options.recallFormWrapperClass); },

        _create: function () {


            this.BindEvents();
            //set deviceType in a hidden field, used to change partnery key on mobile device
            var agent = navigator.userAgent || navigator.vendor || window.opera;
            var device = "desktop";
            if (/Mobi/.test(agent)) {
                device = "mobile";
            }

            $(this.element).find(this.options.recallDeviceClass).val(device);



            $(window).trigger("recallForm:initCompleted", [this.options.instanceKey, "#jq_recall_form-" + this.options.instanceKey]);

        },

        HandleResult: function (data, xhr, status) {

            var Base64 = { _keyStr: "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=", encode: function (e) { var t = ""; var n, r, i, s, o, u, a; var f = 0; e = Base64._utf8_encode(e); while (f < e.length) { n = e.charCodeAt(f++); r = e.charCodeAt(f++); i = e.charCodeAt(f++); s = n >> 2; o = (n & 3) << 4 | r >> 4; u = (r & 15) << 2 | i >> 6; a = i & 63; if (isNaN(r)) { u = a = 64 } else if (isNaN(i)) { a = 64 } t = t + this._keyStr.charAt(s) + this._keyStr.charAt(o) + this._keyStr.charAt(u) + this._keyStr.charAt(a) } return t }, decode: function (e) { var t = ""; var n, r, i; var s, o, u, a; var f = 0; e = e.replace(/[^A-Za-z0-9+/=]/g, ""); while (f < e.length) { s = this._keyStr.indexOf(e.charAt(f++)); o = this._keyStr.indexOf(e.charAt(f++)); u = this._keyStr.indexOf(e.charAt(f++)); a = this._keyStr.indexOf(e.charAt(f++)); n = s << 2 | o >> 4; r = (o & 15) << 4 | u >> 2; i = (u & 3) << 6 | a; t = t + String.fromCharCode(n); if (u != 64) { t = t + String.fromCharCode(r) } if (a != 64) { t = t + String.fromCharCode(i) } } t = Base64._utf8_decode(t); return t }, _utf8_encode: function (e) { e = e.replace(/rn/g, "n"); var t = ""; for (var n = 0; n < e.length; n++) { var r = e.charCodeAt(n); if (r < 128) { t += String.fromCharCode(r) } else if (r > 127 && r < 2048) { t += String.fromCharCode(r >> 6 | 192); t += String.fromCharCode(r & 63 | 128) } else { t += String.fromCharCode(r >> 12 | 224); t += String.fromCharCode(r >> 6 & 63 | 128); t += String.fromCharCode(r & 63 | 128) } } return t }, _utf8_decode: function (e) { var t = ""; var n = 0; var r = 0; var c1 = 0; var c2 = 0; while (n < e.length) { r = e.charCodeAt(n); if (r < 128) { t += String.fromCharCode(r); n++ } else if (r > 191 && r < 224) { c2 = e.charCodeAt(n + 1); t += String.fromCharCode((r & 31) << 6 | c2 & 63); n += 2 } else { c2 = e.charCodeAt(n + 1); var c3 = e.charCodeAt(n + 2); t += String.fromCharCode((r & 15) << 12 | (c2 & 63) << 6 | c3 & 63); n += 3 } } return t } }
            var gtmTrackingParams = this.options.gtmTrackingParams;
            var element = this.element;

            $.each(gtmTrackingParams, function (key, value) {

                if (value.indexOf("form-id:") === 0) {
                    var formField = $(element).find("input[name = '" + value.replace("form-id:", "") + "']");
                    gtmTrackingParams[key] = Base64.encode($(formField).val());
                }

            });

            if (typeof dataLayer != 'undefined')
                dataLayer.push(gtmTrackingParams);

            this.BindEvents();
            $(this.element).find(this.options.recallSubmitBtnClass).ManagedButton("ShowSuccess");
            $(this.element).html(data);
            $('.form__field--select').uniform({
                selectAutoWidth: true
            });

            $(this.options.recallFormHideAfterSubmitOkClass).hide();

        },

        OnError: function (xhr, status, error) {

            this.BindEvents();
            $(this.element).find(this.options.recallSubmitBtnClass).ManagedButton("ShowSuccess");
            $(this.element).html(xhr.responseText);
            $('.form__field--select').uniform({
                selectAutoWidth: true
            });

            //$(this.element).find(this.options.recallSubmitBtnClass).managedButton("ShowErrorMessage", $(this.options.recallErrorClass).html());
        },


        BindEvents: function () {
            $(this.element).find(this.options.recallSubmitBtnClass).ManagedButton({ validation: true });
        },


        RemoveContainer: function () {
            $(this.element).find(this.options.recallSubmitBtnClass).remove();
        },

        ChangePartnerKey: function (newPartnerKey) {
            $(this.element).find("input[name='PartnerKey']").val(newPartnerKey);
        },

        GetGTMParams: function () {
            return this.options.gtmTrackingParams;
        },

        SetGTMParams: function (params) {
            this.options.gtmTrackingParams = params;
        }

    });


})(window.jQuery);;
!function(t){"use strict";t.widget("ec.stickyElement",{options:{elementName:null,classPrefix:"sticky-",valueDefault:!0,valueOpen:"open",valueClosed:"closed",valueRemoved:null,triggerOpen:".js-sticky-open",triggerClose:".js-sticky-close",triggerRemove:".js-sticky-remove",watchList:[],addWatchedClasses:!0,globalObj:"EC.stickyElements",objUpdatedFn:function(e,n,t){},openFn:function(e,n){var t=e.data("ec-stickyElement");e.removeClass(t.options.classPrefix+"is-"+t.options.valueClosed).addClass(t.options.classPrefix+"is-"+t.options.valueOpen)},closeFn:function(e,n){var t=e.data("ec-stickyElement");e.removeClass(t.options.classPrefix+"is-"+t.options.valueOpen).addClass(t.options.classPrefix+"is-"+t.options.valueClosed)},removeFn:function(e,n){}},_create:function(){this.element.addClass("has-plugin");var n=this,e=t(this.element);if(n.options.elementName=n.options.elementName||e.data("element-name"),!n.options.elementName)return!1;n.options.watchList=t.isArray(n.options.watchList)?n.options.watchList:n.options.watchList.replace(" ","").split(","),n.options.globalObj=n.getFunctionByString(n.options.globalObj),n.options.globalObj[n.options.elementName]=n.options.valueDefault,t(document).on("stickyUpdate",function(){n.update()}),e.on("click",n.options.triggerOpen,function(e){e.preventDefault(),n.open()}),e.on("click",n.options.triggerClose,function(e){e.preventDefault(),n.close()}),e.on("click",n.options.triggerRemove,function(e){e.preventDefault(),n.remove()}),t(document).trigger("stickyUpdate")},update:function(){var e=this;e.evalCallback("objUpdatedFn",e.element,e.options.globalObj,e.options.watchList,e.options.globalObj._target),e.options.addWatchedClasses&&e.addWatchedClasses()},open:function(){var e=this;e.options.globalObj[e.options.elementName]=e.options.valueOpen,e.evalCallback("openFn",e.element,e.options.globalObj)},close:function(){var e=this;e.options.globalObj[e.options.elementName]=e.options.valueClosed,e.evalCallback("closeFn",e.element,e.options.globalObj)},remove:function(){var e=this;e.options.globalObj[e.options.elementName]=e.options.valueRemoved,e.evalCallback("removeFn",e.element,e.options.globalObj)},addWatchedClasses:function(){var i=this;t.each(i.options.watchList,function(){var o=this;i.element.removeClass(function(e,n){var t=new RegExp(i.options.classPrefix+o+"\\S+","g");return(n.match(t)||[]).join(" ")}),i.options.globalObj[this]&&i.element.addClass(i.options.classPrefix+this+"-is-"+i.options.globalObj[this])})},evalCallback:function(e){for(var n=this,t=arguments.length,o=new Array(1<t?t-1:0),i=1;i<t;i++)o[i-1]=arguments[i];null!=n.options[e]&&n.getFunctionByString(n.options[e]).apply(void 0,o)},getFunctionByString:function(e,n){if(!e)return!1;if("function"==typeof e)return e;n="undefined"==typeof window?n||global:n||window;for(var t=e.split("."),o=t.pop(),i=0;i<t.length;i++)n=n[t[i]];if(n){o=n[o];return void 0===o&&console.log("EC-stickyElements: Undefined function",e,"- Check for 1) typos on this widget instance JSON settings block (as set on data-plugin-settings attribute) 2) Missing JavaScript files or code."),o}console.log("EC-stickyElements: Undefined context")}})}(jQuery);var EC=EC||{};EC.stickyElements=EC.stickyElements||{},EC.onChangeFn||(EC.onChangeFn={},EC.onChangeFn.path_separator=".",EC.onChangeFn.isPrimitive=function(e){return null===e||"object"!=typeof e&&"function"!=typeof e},EC.onChangeFn.isBuiltinWithoutMutableMethods=function(e){return _instanceof(e,RegExp)||_instanceof(e,Number)},EC.onChangeFn.isBuiltinWithMutableMethods=function(e){return _instanceof(e,Date)},EC.onChangeFn.concatPath=function(e,n){return n&&n.toString&&(e&&(e+=EC.onChangeFn.path_separator),e+=n.toString()),e},EC.onChangeFn.walkPath=function(e,n){for(var t;e;)-1===(t=e.indexOf(EC.onChangeFn.path_separator))&&(t=e.length),n(e.slice(0,t)),e=e.slice(t+1)},EC.onChangeFn.shallowClone=function(e){return Array.isArray(e)?e.slice():Object.assign({},e)},EC.onChangeFn.onChange=function(e,a){function s(e,n,t,o){var i;p?(p&&r&&void 0!==t&&void 0!==o&&"length"!==n&&(i=r,e!==l&&(e=e.replace(l,"").slice(1),EC.onChangeFn.walkPath(e,function(e){i[e]=EC.onChangeFn.shallowClone(i[e]),i=i[e]})),i[n]=t),g=!0):a(EC.onChangeFn.concatPath(e,n),o,t)}function i(e,n){(e=f.get(e))&&e.delete(n)}var l,r,c=2<arguments.length&&void 0!==arguments[2]?arguments[2]:{},u=Symbol("ProxyTarget"),p=!1,g=!1,f=new WeakMap,C=new WeakMap,h=new WeakMap,d={get:function(e,n,t){if(n===u)return e;var o=Reflect.get(e,n,t);if(EC.onChangeFn.isPrimitive(o)||EC.onChangeFn.isBuiltinWithoutMutableMethods(o)||"constructor"===n||!0===c.isShallow)return o;t=function(e,n){var t=f.get(e);if(t)return t;t=new Map,f.set(e,t);var o=t.get(n);return o||(o=Reflect.getOwnPropertyDescriptor(e,n),t.set(n,o)),o}(e,n);if(t&&!t.configurable){if(t.set&&!t.get)return;if(!1===t.writable)return o}C.set(o,EC.onChangeFn.concatPath(C.get(e),n));n=h.get(o);return void 0===n&&(n=new Proxy(o,d),h.set(o,n)),n},set:function(e,n,t,o){e._target=n,t&&void 0!==t[u]&&(t=t[u]);var i=Reflect.get(e,n,o),o=Reflect.set(e[u]||e,n,t);return i!==t&&s(C.get(e),n,i,t),o},defineProperty:function(e,n,t){var o=Reflect.defineProperty(e,n,t);return i(e,n),s(C.get(e),n,void 0,t.value),o},deleteProperty:function(e,n){var t=Reflect.get(e,n),o=Reflect.deleteProperty(e,n);return i(e,n),s(C.get(e),n,t),o},apply:function(e,n,t){var o=EC.onChangeFn.isBuiltinWithMutableMethods(n);if(o&&(n=n[u]),p)return Reflect.apply(e,n,t);p=!0,o&&(r=n.valueOf()),!Array.isArray(n)&&"[object Object]"!==Object.prototype.toString.call(n)||(r=EC.onChangeFn.shallowClone(n[u])),l=(l=C.get(e)).slice(0,Math.max(l.lastIndexOf(EC.onChangeFn.path_separator),0));t=Reflect.apply(e,n,t);return p=!1,(g||o&&r!==n.valueOf())&&(s(l,"",r,n),r=null,g=!1),t}};C.set(e,"");var n=null;return function(){try{new Proxy(e,d)}catch(e){return}return 1}()&&(n=new Proxy(e,d),a=a.bind(n)),n},$(document).on("stickyUpdate",function(e,n,t){EC&&EC.stickyElements}),null!=EC.onChangeFn.onChange(EC.stickyElements,function(){})&&(EC.stickyElements=EC.onChangeFn.onChange(EC.stickyElements,function(){$(document).trigger("stickyUpdate")})));;
