var __extends=this&&this.__extends||function(){var n=function(t,i){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,t){n.__proto__=t}||function(n,t){for(var i in t)Object.prototype.hasOwnProperty.call(t,i)&&(n[i]=t[i])},n(t,i)};return function(t,i){function r(){this.constructor=t}if(typeof i!="function"&&i!==null)throw new TypeError("Class extends value "+String(i)+" is not a constructor or null");n(t,i);t.prototype=i===null?Object.create(i):(r.prototype=i.prototype,new r)}}(),SiteNotifications;(function(n){var t="dxMsg",e=function(){function n(){}return n}(),i=function(n){function t(){return n!==null&&n.apply(this,arguments)||this}return __extends(t,n),t}(Array),r=function(){function n(){}return n}(),u=function(){function n(n){this.Id=n.Id}return n}(),f=function(){function n(){this.resourcesRegistered=!1;this.GetAndShowMessage()}return n.prototype.HideWindow=function(n){var t=function(){n.removeEventListener("transitionend",t);n.classList.remove("Animating")};n.addEventListener("transitionend",t);window.requestAnimationFrame(function(){n.classList.add("Animating");window.requestAnimationFrame(function(){n.classList.remove("Shown")})})},n.prototype.ActionClick=function(n,t){this.ReportAction(n,"Action");t.getAttribute("data-hide-on-action")=="true"&&this.HideWindow(t);this.SaveMessageState(n);n.Url!=""&&document.location.assign(n.Url)},n.prototype.CloseButtonClick=function(n,t){this.ReportAction(n,"Dismiss");this.HideWindow(t);this.SaveMessageState(n)},n.prototype.ReportAction=function(n,t){var i=new XMLHttpRequest;i.withCredentials=!0;i.open("POST",this.GetApiUrl(t));i.setRequestHeader("Content-Type","application/json;charset=UTF-8");i.send(JSON.stringify(new u(n)))},n.prototype.SaveMessageState=function(n){var t=this.GetMessagesState();t.forEach(function(t){t.Id==n.Id&&(t.Processed=!0)});this.SaveState(t)},n.prototype.GetAndShowMessage=function(){var i=this,u,n,t;this.AreCookiesEnabled("permanent")&&window.self==window.top&&XMLHttpRequest&&(n=new XMLHttpRequest,n.withCredentials=!0,n.open("POST",this.GetApiUrl("GetMessage")),n.setRequestHeader("Content-Type","application/json;charset=UTF-8"),n.onreadystatechange=function(){if(n.readyState===XMLHttpRequest.DONE&&n.status===200){i.CleanupMessageState();var t=JSON.parse(n.response);if(t==null)return;i.EnsureResourcesLoaded(t,function(){i.SaveInitialMessageState(t);i.Show(t)})}},t=new r,t.RequestUrl=document.location.toString(),t.MessagesState=this.GetMessagesState(),t.Data=typeof supportCenter=="undefined"?null:supportCenter.model&&supportCenter.newScVersion?JSON.stringify(supportCenter.model):(u=supportCenter.model)!==null&&u!==void 0?u:null,n.send(JSON.stringify(t)))},n.prototype.EnsureResourcesLoaded=function(n,t){var i=this;this.resourcesRegistered||(n.Resources.filter(function(n){return n.Key=="Styles"}).forEach(function(n){document.head.insertAdjacentHTML("beforeend",n.Bundle);t!=null&&document.head.lastElementChild.addEventListener("load",t.bind(i))}),window.WebFont||n.Resources.filter(function(n){return n.Key=="Fonts"}).forEach(function(n){var u=document.createElement("div"),r,t;u.innerHTML=n.Bundle;r=u.querySelectorAll("script");t=function(n){if(n===void 0&&(n=0),!(n>=r.length)){var f=r[n],u=document.createElement("script");f.getAttributeNames().forEach(function(n){u.setAttribute(n,f.getAttribute(n))});u.innerText=f.innerText;u.addEventListener("load",t.bind(i,n+1));u.addEventListener("error",t.bind(i,n+1));try{document.head.appendChild(u)}catch(e){}}};t()}),this.resourcesRegistered=!0)},n.prototype.GetApiUrl=function(n){var i="",t=document.location.hostname,r="/",u=/[^.]*?\.?(devexpress\.[^.]+?)$/i;return t.match(u)&&!/.+?\.devx$/i.test(t)?t.match(/^preview\.devexpress\.com$/i)||(t=t.replace(u,"www.$1")):t.match(/.+?\.(com|net|io|devx)$/i)?t="www.devexpress.com":(t.toLowerCase()=="localhost"||document.location.port=="")&&(r="/DevExpress/"),i=document.location.protocol+"//"+t+r,i+"api/Notifications/"+n},n.prototype.Show=function(n){var t=this.GetMessageWindow(n),i,r;n.Important?t.classList.add("Important"):t.classList.remove("Important");t.setAttribute("msgId",n.Id);t.querySelector("div.Title").innerHTML=n.Title;t.querySelector("div.Text").innerHTML=n.Message;i=t.querySelector("div.Button > a");i.innerHTML=n.ButtonTitle;i.setAttribute("href",n.Url==""?"javascript:;":n.Url);t.setAttribute("data-hide-on-action",(n.Url=="").toString().toLowerCase());r=function(){t.removeEventListener("transitionend",r);t.classList.remove("Animating")};t.addEventListener("transitionend",r);window.requestAnimationFrame(function(){t.classList.add("Animating");window.requestAnimationFrame(function(){t.classList.add("Shown")})})},n.prototype.GetMessageWindow=function(n){var t=document.getElementById("wsMsgWnd"),i;return t!=null&&t.remove(),i='<div id="wsMsgWnd" class="wsMsgWnd"><div class="CloseButton"><\/div><div class="r-container"><div class="Content"><div class="Title"><\/div><div class="Text"><\/div><\/div><div class="Button"><a><\/a><\/div><\/div><\/div>',document.body.insertAdjacentHTML("beforeend",i),t=document.getElementById("wsMsgWnd"),t.querySelector("div.CloseButton").addEventListener("click",this.CloseButtonClick.bind(this,n,t)),t.querySelector("div.Button > a").addEventListener("click",this.ActionClick.bind(this,n,t)),t},n.prototype.SaveInitialMessageState=function(n){var t=this.GetMessagesState();t.filter(function(t){return t.Id==n.Id}).forEach(function(t){return t.Expires=n.Expires});t.filter(function(t){return t.Id==n.Id}).length==0&&t.push({Id:n.Id,Expires:n.Expires,Processed:!1});this.SaveState(t)},n.prototype.SaveState=function(n){var i=[t,"=",encodeURIComponent(JSON.stringify(n)),"; expires="+new Date(2038,1,1).toUTCString(),"; path=/","; Secure","; SameSite=Lax"],r=this.GetCookieDomain();r!=""&&i.push("; domain="+r);document.cookie=i.join("")},n.prototype.GetMessagesState=function(){try{var n=this.GetCookie(t)||"";return JSON.parse(n,function(n,t){return n==="Expires"?new Date(t):t})}catch(r){return new i(0)}},n.prototype.CleanupMessageState=function(){var n=this.GetMessagesState(),t=n.filter(function(n){return n.Expires>new Date});n.length!=t.length&&this.SaveState(t)},n.prototype.AreCookiesEnabled=function(n){var t=new Date,i,r;return(t.setTime(t.getTime()+864e5),document.cookie="dxTestSessionCookie=1; SameSite=Strict",document.cookie="dxTestPermanentCookie=1; SameSite=Strict; expires="+t.toUTCString(),i=document.cookie.indexOf("dxTestSessionCookie")>-1,r=document.cookie.indexOf("dxTestPermanentCookie")>-1,document.cookie="dxTestSessionCookie=; expires=Thu, 01 Jan 1970 00:00:00 UTC; SameSite=Strict",document.cookie="dxTestPermanentCookie=; expires=Thu, 01 Jan 1970 00:00:00 UTC; SameSite=Strict",typeof n!="undefined"&&n=="permanent")?r:i},n.prototype.GetCookieDomain=function(){var t=document.location.host,n;return t.indexOf(".")>=0&&(n=t.split("."),n.length>=2)?"."+n[n.length-2]+"."+n[n.length-1]:""},n.prototype.GetCookie=function(n){for(var r=document.cookie?document.cookie.split("; "):[],i=0,f=r.length;i<f;i++){var u=r[i].split("="),e=u.shift(),t=u.join("=");if(n&&n===e){t.indexOf('"')===0&&(t=t.slice(1,-1).replace(/\\"/g,'"').replace(/\\\\/g,"\\"));try{return decodeURIComponent(t.replace(/\+/g," "))}catch(o){return null}}}return null},n}();n.NotificationController=f})(SiteNotifications||(SiteNotifications={}));new SiteNotifications.NotificationController