Element.prototype.matches||(Element.prototype.matches=Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector),Element.prototype.closest||(Element.prototype.closest=function(e){var t=this;do{if(t.matches(e))return t;t=t.parentElement||t.parentNode}while(null!==t&&1===t.nodeType);return null}),document.fonts&&document.body&&(document.body.classList.add("rz-icons-loading"),document.fonts.load("16px Material Symbols").then((()=>{document.body.classList.remove("rz-icons-loading")})));var radzenRecognition,resolveCallbacks=[],rejectCallbacks=[];window.Radzen={isRTL:function(e){return e&&"rtl"==getComputedStyle(e).direction},throttle:function(e,t){var n=null;return function(){var o=arguments,a=this;n||(n=setTimeout((function(){e.apply(a,o),n=null}),t))}},mask:function(e,t,n,o){var a=document.getElementById(e);if(a){void 0!==window.safari&&(a.onblur=function(e){a.dispatchEvent(new Event("change"))});var i=a.selectionStart!=a.value.length?a.selectionStart:-1,r=a.selectionEnd!=a.value.length?a.selectionEnd:-1;a.value=function(e,t,n,o){for(var a=o?e.match(new RegExp(o,"g")):e.replace(new RegExp(n,"g"),"").split(""),i=0,r="",l=0;le.value)).join("").trim();a.value=l,t.invokeMethodAsync("RadzenSecurityCode.OnValueChange",l),Radzen[e].inputs[Radzen[e].inputs.length-1].focus()}n.preventDefault()}},Radzen[e].keyPress=function(n){var i=n.data?n.data.charCodeAt(0):n.which,r=n.data||String.fromCharCode(n.which);if(!n.metaKey&&!n.ctrlKey&&9!=i&&8!=i&&13!=i)if(o&&(i<48||i>57))n.preventDefault();else if(n.currentTarget.value!=r){n.currentTarget.value=r;var l=Radzen[e].inputs.map((e=>e.value)).join("").trim();a.value=l,t.invokeMethodAsync("RadzenSecurityCode.OnValueChange",l);var d=Radzen[e].inputs.indexOf(n.currentTarget);de.value)).join("").trim();a.value=o,t.invokeMethodAsync("RadzenSecurityCode.OnValueChange",o);var i=Radzen[e].inputs.indexOf(n.currentTarget);i>0&&Radzen[e].inputs[i-1].focus()}};for(var i=0;i1?u=1:u<0&&(u=0);var m=u*(l-r)+r;t.canChange&&m>=r&&m<=l&&t.invokeMethodAsync("RadzenSlider.OnValueChange",m,!!t.isMin)}},Radzen[e].mouseDownHandler=function(s){if(!n.classList.contains("rz-state-disabled"))if(document.addEventListener("mousemove",Radzen[e].mouseMoveHandler),document.addEventListener("touchmove",Radzen[e].mouseMoveHandler,{passive:!1,capture:!0}),document.addEventListener("mouseup",Radzen[e].mouseUpHandler),document.addEventListener("touchend",Radzen[e].mouseUpHandler,{passive:!0}),a==s.target||i==s.target)t.canChange=!0,t.isMin=a==s.target;else{var c=(s.targetTouches&&s.targetTouches[0]?s.targetTouches[0].pageX-s.target.getBoundingClientRect().left:s.offsetX)/n.offsetWidth*(l-r)+r,u=o?d[t.isMin?0:1]:d;c>=r&&c<=l&&c!=u&&t.invokeMethodAsync("RadzenSlider.OnValueChange",c,!!t.isMin)}},Radzen[e].mouseUpHandler=function(n){t.canChange=!1,document.removeEventListener("mousemove",Radzen[e].mouseMoveHandler),document.removeEventListener("touchmove",Radzen[e].mouseMoveHandler,{passive:!1,capture:!0}),document.removeEventListener("mouseup",Radzen[e].mouseUpHandler),document.removeEventListener("touchend",Radzen[e].mouseUpHandler,{passive:!0})},n.addEventListener("mousedown",Radzen[e].mouseDownHandler),n.addEventListener("touchstart",Radzen[e].mouseDownHandler,{passive:!0})},destroySlider:function(e,t){Radzen[e]&&(Radzen[e].mouseMoveHandler&&(document.removeEventListener("mousemove",Radzen[e].mouseMoveHandler),document.removeEventListener("touchmove",Radzen[e].mouseMoveHandler),delete Radzen[e].mouseMoveHandler),Radzen[e].mouseUpHandler&&(document.removeEventListener("mouseup",Radzen[e].mouseUpHandler),document.removeEventListener("touchend",Radzen[e].mouseUpHandler),delete Radzen[e].mouseUpHandler),Radzen[e].mouseDownHandler&&(t.removeEventListener("mousedown",Radzen[e].mouseDownHandler),t.removeEventListener("touchstart",Radzen[e].mouseDownHandler),delete Radzen[e].mouseDownHandler),Radzen[e]=null)},prepareDrag:function(e){e&&(e.ondragover=function(e){e.preventDefault()},e.ondragstart=function(e){e.dataTransfer.setData("",e.target.id)})},focusElement:function(e){var t=document.getElementById(e);t&&t.focus()},scrollCarouselItem:function(e){e.parentElement.scroll(e.offsetLeft,0)},scrollIntoViewIfNeeded:function(e,t){var n=t?e.getElementsByClassName(t)[0]:e;n&&n.scrollIntoViewIfNeeded?n.scrollIntoViewIfNeeded():n&&n.scrollIntoView&&n.scrollIntoView()},selectListItem:function(e,t,n){if(e&&t){var o=t.getElementsByTagName("LI"),a=t.querySelectorAll(".rz-state-highlight");if(a.length)for(var i=0;i=0&&t.nextSelectedIndex<=o.length-1&&(o[t.nextSelectedIndex].classList.add("rz-state-highlight"),o[t.nextSelectedIndex].scrollIntoView({block:"nearest"}))}},focusListItem:function(e,t,n,o){if(e&&t){var a=t.getElementsByTagName("LI");if(a&&0!=a.length){if(null!=o&&null!=o||(o=-1),t.nextSelectedIndex=o,n)for(;t.nextSelectedIndex=0&&(t.nextSelectedIndex--,a[t.nextSelectedIndex]&&a[t.nextSelectedIndex].classList.contains("rz-state-disabled")););var i=t.querySelectorAll(".rz-state-highlight");if(i.length)for(var r=0;r=0&&t.nextSelectedIndex<=a.length-1&&(a[t.nextSelectedIndex].classList.add("rz-state-highlight"),Radzen.scrollIntoViewIfNeeded(a[t.nextSelectedIndex])),t.nextSelectedIndex}}},clearFocusedHeaderCell:function(e){var t=document.getElementById(e);if(t){var n=t.querySelector(".rz-grid-table").getElementsByTagName("thead")[0].querySelectorAll(".rz-state-focused");if(n.length)for(var o=0;o0&&(r.nextSelectedIndex--,s[r.nextSelectedIndex]&&s[r.nextSelectedIndex].classList.contains("rz-state-disabled")););else if("ArrowRight"==t)for(;r.nextSelectedCellIndex0&&(r.nextSelectedCellIndex--,s[r.nextSelectedIndex]&&s[r.nextSelectedIndex].cells[r.nextSelectedCellIndex]&&s[r.nextSelectedIndex].cells[r.nextSelectedCellIndex].classList.contains("rz-state-disabled")););else!a||"PageDown"!=t&&"End"!=t?!a||"PageUp"!=t&&"Home"!=t||(r.nextSelectedIndex=1):r.nextSelectedIndex=s.length-1;if("ArrowLeft"==t||"ArrowRight"==t||"ArrowUp"==t&&null!=o&&0==r.nextSelectedIndex&&0==r.parentNode.scrollTop){var v;if((v=s[r.nextSelectedIndex].querySelectorAll(".rz-state-focused")).length)for(c=0;c=0&&r.nextSelectedCellIndex<=s[r.nextSelectedIndex].cells.length-1){var p=s[r.nextSelectedIndex].cells[r.nextSelectedCellIndex];p.classList.contains("rz-state-focused")||(p.classList.add("rz-state-focused"),!a&&r.parentElement.scrollWidth>r.parentElement.clientWidth&&Radzen.scrollIntoViewIfNeeded(p))}}else if("ArrowDown"==t||"ArrowUp"==t){var g=r.querySelectorAll(".rz-state-focused");if(g.length)for(c=0;c=0&&r.nextSelectedIndex<=s.length-1){var f=s[r.nextSelectedIndex];f.classList.contains("rz-state-focused")||(f.classList.add("rz-state-focused"),!a&&r.parentElement.scrollHeight>r.parentElement.clientHeight&&Radzen.scrollIntoViewIfNeeded(f))}}return[r.nextSelectedIndex,r.nextSelectedCellIndex]}},uploadInputChange:function(e,t,n,o,a,i){n?(Radzen.upload(e.target,t,o,a,i),e.target.value=""):Radzen.uploadChange(e.target)},uploads:function(e,t){Radzen.uploadComponents||(Radzen.uploadComponents={}),Radzen.uploadComponents[t]=e},uploadChange:function(e){for(var t=[],n=0;n=200&&n<400?o.invokeMethodAsync("RadzenUpload.OnComplete",u.responseText,d):o.invokeMethodAsync("RadzenUpload.OnError",u.responseText))}},i.invokeMethodAsync("GetHeaders").then((function(e){for(var n in u.open("POST",t,!0),e)u.setRequestHeader(n,e[n]);u.send(r)}))}},getCookie:function(e){var t=("; "+decodeURIComponent(document.cookie)).split("; "+e+"=");if(2==t.length)return t.pop().split(";").shift()},getCulture:function(){var e=Radzen.getCookie(".AspNetCore.Culture");return(e?e.split("|").pop().split("=").pop():null)||"en-US"},numericOnPaste:function(e,t,n){if(e.clipboardData){var o=e.clipboardData.getData("text");if(o&&!isNaN(+o)){var a=+o;if(null!=t&&a>=t)return;if(null!=n&&a<=n)return}e.preventDefault()}},numericOnInput:function(e,t,n,o){var a=e.target.value;if(o||""!=a||null==t||(e.target.value=t),a&&!isNaN(+a)){var i=+a;null!=t&&!isNaN(+t)&&in&&(e.target.value=n)}},numericKeyPress:function(e,t,n){if(!e.metaKey&&!e.ctrlKey&&9!=e.keyCode&&8!=e.keyCode&&13!=e.keyCode){if("NumpadDecimal"===e.code&&!t){var o=e.target.selectionEnd;return e.target.value=[e.target.value.slice(0,e.target.selectionStart),n,e.target.value.slice(e.target.selectionEnd)].join(""),e.target.selectionStart=++o,e.target.selectionEnd=o,void e.preventDefault()}var a=String.fromCharCode(e.charCode);(t?/^[-\d]$/:/^[-\d,.]$/).test(a)||e.preventDefault()}},openContextMenu:function(e,t,n,o,a){Radzen.closePopup(n),Radzen.openPopup(null,n,!1,null,e,t,o,a),setTimeout((function(){var e=document.getElementById(n);if(e){var t=e.querySelector(".rz-menu");t&&t.focus()}}),500)},openTooltip:function(e,t,n,o,a,i,r,l){Radzen.closeTooltip(t),n?Radzen[t+"delay"]=setTimeout(Radzen.openPopup,n,e,t,!1,a,null,null,r,l,i):Radzen.openPopup(e,t,!1,a,null,null,r,l,i),o&&(Radzen[t+"duration"]=setTimeout(Radzen.closePopup,o,t,r,l))},closeTooltip(e){Radzen.activeElement=null,Radzen.closePopup(e),Radzen[e+"delay"]&&clearTimeout(Radzen[e+"delay"]),Radzen[e+"duration"]&&clearTimeout(Radzen[e+"duration"])},destroyDatePicker(e){var t=document.getElementById(e);if(t){var n=t.querySelector(".rz-datepicker-trigger");n&&(n.onclick=null);var o=t.querySelector(".rz-inputtext");o&&(o.onclick=null)}},createDatePicker(e,t){if(e){var n=function(e,n){n&&Radzen.togglePopup(e.currentTarget.parentNode,t,!1,null,null,!0,!1)},o=e.querySelector(".rz-inputtext"),a=e.querySelector(".rz-datepicker-trigger");a&&(a.onclick=function(e){n(e,!(e.currentTarget.classList.contains("rz-state-disabled")||o&&o.classList.contains("rz-readonly")))}),o&&(o.onclick=function(e){n(e,e.currentTarget.classList.contains("rz-input-trigger")&&!e.currentTarget.classList.contains("rz-readonly"))})}},findPopup:function(e){for(var t=[],n=0;nwindow.innerHeight+i&&a.top>o.height&&(r=a.top-o.height+i),n.style.top=r+"px"}},openPopup:function(e,t,n,o,a,i,r,l,d=!0,s=!1,c=!1){var u=document.getElementById(t);if(u){Radzen.activeElement=document.activeElement;var m=e?e.getBoundingClientRect():{top:i||0,bottom:0,left:a||0,right:0,width:0,height:0};if(/Edge/.test(navigator.userAgent))var v=document.body.scrollLeft,p=document.body.scrollTop;else v=document.documentElement.scrollLeft,p=document.documentElement.scrollTop;var g=i||m.bottom,f=a||m.left;if(n&&(u.style.width=m.width+"px",u.style.minWidth||(u.minWidth=!0,u.style.minWidth=m.width+"px")),window.chrome){var h=u.closest(".rz-frozen-cell");h&&(Radzen[t+"FZL"]={cell:h,left:h.style.left},h.style.left="")}u.style.display="block",u.onanimationend=null,u.classList.add("rz-open"),u.classList.remove("rz-close");var z=u.getBoundingClientRect();z.width=a?z.width+20:z.width,z.height=i?z.height+20:z.height;var R=!o||"bottom"==o;if(R&&g+z.height>window.innerHeight&&m.top>z.height&&(!0!==c&&(g=m.top-z.height),o)){g-=40;var y="rz-"+o+"-tooltip-content";if((E=u.children[0]).classList.contains(y)&&(E.classList.remove(y),E.classList.add("rz-top-tooltip-content"),o="top",r&&l))try{r.invokeMethodAsync(l,o)}catch{}}if(R&&f+z.width>window.innerWidth&&window.innerWidth>z.width&&(f=o?z.left:window.innerWidth-z.width,o)){g=i||m.top;var E;y="rz-"+o+"-tooltip-content";if((E=u.children[0]).classList.contains(y)&&(E.classList.remove(y),E.classList.add("rz-left-tooltip-content"),o="left",r&&l))try{r.invokeMethodAsync(l,o)}catch{}}R&&o&&(g+=20),"left"==o&&(f=m.left-z.width-5,g=m.top),"right"==o&&(f=m.right+10,g=m.top),"top"==o&&(g=m.top-z.height+5,f=m.left),u.style.zIndex=2e3,u.style.left=f+v+"px",u.style.top=g+p+"px",u.classList.contains("rz-overlaypanel")||u.classList.add("rz-popup"),Radzen[t]=function(e){var t=Radzen.popups&&Radzen.popups[Radzen.popups.length-1],n=null!=t&&document.getElementById(t.id)||u;if(t&&(n.instance=t.instance,n.callback=t.callback,n.parent=t.parent),"contextmenu"!=e.type&&e.target&&d)if(/Android/i.test(navigator.userAgent)||["input","textarea"].includes(document.activeElement?document.activeElement.tagName.toLowerCase():"")||"resize"!=e.type){var o=e.target.closest&&(e.target.closest(".rz-link")||e.target.closest(".rz-navigation-item-link"));"resize"!=e.type||/Android/i.test(navigator.userAgent)||(o&&o.closest&&o.closest("a")&&0==e.button?(o.closest("a").click(),Radzen.closeAllPopups()):Radzen.closeAllPopups()),n.parent?"mousedown"!=e.type||n.parent.contains(e.target)||n.contains(e.target)||Radzen.closePopup(n.id,n.instance,n.callback,e):e.target.nodeType&&!n.contains(e.target)&&Radzen.closePopup(n.id,n.instance,n.callback,e)}else Radzen.closePopup(n.id,n.instance,n.callback,e)},Radzen.popups||(Radzen.popups=[]),Radzen.popups.push({id:t,instance:r,callback:l,parent:e}),document.body.appendChild(u),document.removeEventListener("mousedown",Radzen[t]),document.addEventListener("mousedown",Radzen[t]),window.removeEventListener("resize",Radzen[t]),window.addEventListener("resize",Radzen[t]);for(var L=e;L&&L!=document.body;)(L.scrollWidth>L.clientWidth||L.scrollHeight>L.clientHeight)&&(L.removeEventListener("scroll",Radzen.closeAllPopups),L.addEventListener("scroll",Radzen.closeAllPopups)),L=L.parentElement;e||(document.removeEventListener("contextmenu",Radzen[t]),document.addEventListener("contextmenu",Radzen[t])),s&&setTimeout((function(){u.removeEventListener("keydown",Radzen.focusTrap),u.addEventListener("keydown",Radzen.focusTrap);var e=Radzen.getFocusableElements(u)[0];e&&e.focus()}),200)}},closeAllPopups:function(e,t){if(Radzen.popups){for(var n=e&&e.target||t&&documentElement.getElementById(t),o=Radzen.popups,a=0;a1))return;for(var r=0;rdocument.documentElement.clientHeight&&document.body.classList.add("no-scroll"),setTimeout((function(){var t=document.querySelectorAll(".rz-dialog-content");if(0!=t.length){var o=t[t.length-1];if(o){if(o.options=e,o.removeEventListener("keydown",Radzen.focusTrap),o.addEventListener("keydown",Radzen.focusTrap),e.resizable){n.offsetWidth=o.parentElement.offsetWidth,n.offsetHeight=o.parentElement.offsetHeight;Radzen.dialogResizer=new ResizeObserver((function(e){n&&(n.offsetWidth==e[0].target.offsetWidth&&n.offsetHeight==e[0].target.offsetHeight||(n.offsetWidth=e[0].target.offsetWidth,n.offsetHeight=e[0].target.offsetHeight,n.invokeMethodAsync("RadzenDialog.OnResize",e[0].target.offsetWidth,e[0].target.offsetHeight)))})).observe(o.parentElement)}if(e.draggable){var a=o.parentElement.querySelector(".rz-dialog-titlebar");a&&(Radzen[a]=function(e){var t=o.parentElement.getBoundingClientRect(),a=e.clientX-t.left,i=e.clientY-t.top,r=function(e){var t=e.clientX-a,r=e.clientY-i;o.parentElement.style.left=t+"px",o.parentElement.style.top=r+"px",n.invokeMethodAsync("RadzenDialog.OnDrag",r,t)},l=function(){document.removeEventListener("mousemove",r),document.removeEventListener("mouseup",l)};document.addEventListener("mousemove",r),document.addEventListener("mouseup",l)},a.addEventListener("mousedown",Radzen[a]))}e.autoFocusFirstElement&&Radzen.focusFirstFocusableElement(o)}}}),500),document.removeEventListener("keydown",Radzen.closePopupOrDialog),e.closeDialogOnEsc&&document.addEventListener("keydown",Radzen.closePopupOrDialog)},closeDialog:function(){Radzen.dialogResizer=null,document.body.classList.remove("no-scroll");var e=document.querySelectorAll(".rz-dialog-content"),t=e.length&&e[e.length-1];if(t){var n=t.parentElement.querySelector(".rz-dialog-titlebar");n&&(n.removeEventListener("mousedown",Radzen[n]),Radzen[n]=null,delete Radzen[n])}e.length<=1&&(document.removeEventListener("keydown",Radzen.closePopupOrDialog),delete Radzen.dialogService)},disableKeydown:function(e){(e=e||window.event).preventDefault()},getFocusableElements:function(e){return[...e.querySelectorAll("a, button, input, textarea, select, details, iframe, embed, object, summary dialog, audio[controls], video[controls], [contenteditable], [tabindex]")].filter((e=>e&&e.tabIndex>-1&&!e.hasAttribute("disabled")&&null!==e.offsetParent))},focusTrap:function(e){if("key"in(e=e||window.event)?"Tab"===e.key:9===e.keyCode){var t=Radzen.getFocusableElements(e.currentTarget),n=t[0],o=t[t.length-1];n&&o&&e.shiftKey&&document.activeElement===n?(e.preventDefault(),o.focus()):n&&o&&!e.shiftKey&&document.activeElement===o&&(e.preventDefault(),n.focus())}},closePopupOrDialog:function(e){if(("key"in(e=e||window.event)?"Escape"===e.key||"Esc"===e.key:27===e.keyCode)&&Radzen.dialogService){for(var t=document.querySelectorAll(".rz-popup,.rz-overlaypanel"),n=0;n0&&o>0){var t=document.createElement("img");t.onload=function(i){var r=document.createElement("canvas"),l=function(e){var t=e.width,a=e.height;return t>a?t>n&&(a*=n/t,t=n):a>o&&(t*=o/a,a=o),{width:t,height:a}}(t);r.width=l.width,r.height=l.height,r.getContext("2d").drawImage(t,0,0,l.width,l.height),a(r.toDataURL(e.type))},t.src=r.result}else a(r.result)}),!1);var l=e.files[0];l&&(l.size<=t?r.readAsDataURL(l):i("File too large."))}))}(e)},toggleMenuItem:function(e,t,n,o){var a=e.closest(".rz-navigation-item"),i=null!=n?n:!a.classList.contains("rz-navigation-item-active");function r(t){a.classList.toggle("rz-navigation-item-active",t),e.classList.toggle("rz-navigation-item-wrapper-active",t);var n=a.querySelector(".rz-navigation-menu");n&&(t?(n.onanimationend=null,n.style.display="",n.classList.add("rz-open"),n.classList.remove("rz-close")):(n.onanimationend=function(){n.style.display="none",n.onanimationend=null},n.classList.remove("rz-open"),n.classList.add("rz-close")));var o=a.querySelector(".rz-navigation-item-icon-children");o&&(o.classList.toggle("rz-state-expanded",t),o.classList.toggle("rz-state-collapsed",!t))}!1===o&&a.parentElement&&a.parentElement.closest(".rz-navigation-item")&&!n||(r(i),document.removeEventListener("click",e.clickHandler),e.clickHandler=function(e){if(a.contains(e.target)){var t=e.target.closest(".rz-navigation-item");if(t&&t.querySelector(".rz-navigation-menu"))return}r(!1)},document.addEventListener("click",e.clickHandler))},destroyChart:function(e){e&&(e.removeEventListener("mouseleave",e.mouseLeaveHandler),delete e.mouseLeaveHandler,e.removeEventListener("mouseenter",e.mouseEnterHandler),delete e.mouseEnterHandler,e.removeEventListener("mousemove",e.mouseMoveHandler),delete e.mouseMoveHandler,e.removeEventListener("click",e.clickHandler),delete e.clickHandler,this.destroyResizable(e))},destroyGauge:function(e){this.destroyResizable(e)},destroyResizable:function(e){e.resizeObserver&&(e.resizeObserver.disconnect(),delete e.resizeObserver),e.resizeHandler&&(window.removeEventListener("resize",e.resizeHandler),delete e.resizeHandler)},createResizable:function(e,t){e.resizeHandler=function(){var n=e.getBoundingClientRect();t.invokeMethodAsync("Resize",n.width,n.height)},window.ResizeObserver?(e.resizeObserver=new ResizeObserver(e.resizeHandler),e.resizeObserver.observe(e)):window.addEventListener("resize",e.resizeHandler);var n=e.getBoundingClientRect();return{width:n.width,height:n.height}},createChart:function(e,t){var n=!1;return e.mouseMoveHandler=this.throttle((function(o){if(n){var a=e.getBoundingClientRect(),i=o.clientX-a.left,r=o.clientY-a.top;t.invokeMethodAsync("MouseMove",i,r)}}),100),e.mouseEnterHandler=function(){n=!0},e.mouseLeaveHandler=function(e){e.relatedTarget&&(e.relatedTarget.matches(".rz-chart-tooltip")||e.relatedTarget.closest(".rz-chart-tooltip"))||(n=!1,t.invokeMethodAsync("MouseMove",-1,-1))},e.clickHandler=function(n){var o=e.getBoundingClientRect(),a=n.clientX-o.left,i=n.clientY-o.top;n.target.closest(".rz-marker")||t.invokeMethodAsync("Click",a,i)},e.addEventListener("mouseenter",e.mouseEnterHandler),e.addEventListener("mouseleave",e.mouseLeaveHandler),e.addEventListener("mousemove",e.mouseMoveHandler),e.addEventListener("click",e.clickHandler),this.createResizable(e,t)},createGauge:function(e,t){return this.createResizable(e,t)},destroyScheduler:function(e){e&&e.resizeHandler&&(window.removeEventListener("resize",e.resizeHandler),delete e.resizeHandler)},createScheduler:function(e,t){e.resizeHandler=function(){var n=e.getBoundingClientRect();t.invokeMethodAsync("Resize",n.width,n.height)},window.addEventListener("resize",e.resizeHandler);var n=e.getBoundingClientRect();return{width:n.width,height:n.height}},innerHTML:function(e,t){if(null==t)return e.innerHTML;null!=e&&(e.innerHTML=t)},execCommand:function(e,t,n){return document.activeElement!=e&&e&&e.focus(),document.execCommand(t,!1,n),this.queryCommands(e)},queryCommands:function(e){return{html:null!=e?e.innerHTML:null,fontName:document.queryCommandValue("fontName"),fontSize:document.queryCommandValue("fontSize"),formatBlock:document.queryCommandValue("formatBlock"),bold:document.queryCommandState("bold"),underline:document.queryCommandState("underline"),justifyRight:document.queryCommandState("justifyRight"),justifyLeft:document.queryCommandState("justifyLeft"),justifyCenter:document.queryCommandState("justifyCenter"),justifyFull:document.queryCommandState("justifyFull"),italic:document.queryCommandState("italic"),strikeThrough:document.queryCommandState("strikeThrough"),superscript:document.queryCommandState("superscript"),subscript:document.queryCommandState("subscript"),unlink:document.queryCommandEnabled("unlink"),undo:document.queryCommandEnabled("undo"),redo:document.queryCommandEnabled("redo")}},mediaQueries:{},mediaQuery:function(e,t){if(t){function n(e){t.invokeMethodAsync("OnChange",e.matches)}e=matchMedia(e);return this.mediaQueries[t._id]=function(){e.removeListener(n)},e.addListener(n),e.matches}t=e,this.mediaQueries[t._id]&&(this.mediaQueries[t._id](),delete this.mediaQueries[t._id])},createEditor:function(e,t,n,o,a){e.inputListener=function(){o.invokeMethodAsync("OnChange",e.innerHTML)},e.keydownListener=function(e){var t="";(e.ctrlKey||e.metaKey)&&(t+="Ctrl+"),e.altKey&&(t+="Alt+"),e.shiftKey&&(t+="Shift+"),t+=e.code.replace("Key","").replace("Digit","").replace("Numpad",""),a.includes(t)&&(e.preventDefault(),o.invokeMethodAsync("ExecuteShortcutAsync",t))},e.clickListener=function(t){if(t.target){for(var n of(t.target.matches("a,button")&&t.preventDefault(),e.querySelectorAll("img.rz-state-selected")))n.classList.remove("rz-state-selected");if(t.target.matches("img")){t.target.classList.add("rz-state-selected");var o=document.createRange();o.selectNode(t.target),getSelection().removeAllRanges(),getSelection().addRange(o)}}},e.selectionChangeListener=function(){document.activeElement==e&&o.invokeMethodAsync("OnSelectionChange")},e.pasteListener=function(e){var a=e.clipboardData.items[0];if("file"==a.kind){e.preventDefault();var i=a.getAsFile();if(t){var r=new XMLHttpRequest;(d=new FormData).append("file",i),r.onreadystatechange=function(e){if(r.readyState===XMLHttpRequest.DONE){var t=r.status;if(0===t||t>=200&&t<400){var a=JSON.parse(r.responseText),i='';n?o.invokeMethodAsync("OnPaste",i).then((function(e){document.execCommand("insertHTML",!1,e)})):document.execCommand("insertHTML",!1,''),o.invokeMethodAsync("OnUploadComplete",r.responseText)}else o.invokeMethodAsync("OnError",r.responseText)}},o.invokeMethodAsync("GetHeaders").then((function(e){for(var n in r.open("POST",t,!0),e)r.setRequestHeader(n,e[n]);r.send(d)}))}else{var l=new FileReader;l.onload=function(e){var t='';n?o.invokeMethodAsync("OnPaste",t).then((function(e){document.execCommand("insertHTML",!1,e)})):document.execCommand("insertHTML",!1,t)},l.readAsDataURL(i)}}else if(n){e.preventDefault();var d=e.clipboardData.getData("text/html")||e.clipboardData.getData("text/plain");o.invokeMethodAsync("OnPaste",d).then((function(e){document.execCommand("insertHTML",!1,e)}))}},e.addEventListener("input",e.inputListener),e.addEventListener("paste",e.pasteListener),e.addEventListener("keydown",e.keydownListener),e.addEventListener("click",e.clickListener),document.addEventListener("selectionchange",e.selectionChangeListener),document.execCommand("styleWithCSS",!1,!0)},saveSelection:function(e){if(document.activeElement==e){var t=getSelection();t.rangeCount>0&&(e.range=t.getRangeAt(0))}},restoreSelection:function(e){var t=e.range;if(t){delete e.range,e&&e.focus();var n=getSelection();n.removeAllRanges(),n.addRange(t)}},selectionAttributes:function(e,t,n){for(var o=getSelection(),a=o.rangeCount>0&&o.getRangeAt(0),i=a&&a.commonAncestorContainer,r=n.querySelector("img.rz-state-selected"),l=r&&"img"==e;i;){if(i==n){l=!0;break}i=i.parentNode}if(!l)return{};var d,s=o.focusNode;return r&&"img"==e?s=r:s&&(3==s.nodeType?s=s.parentElement:(s=s.childNodes[o.focusOffset])&&(d=s.outerHTML),s&&s.matches&&!s.matches(e)&&(s=s.closest(e))),t.reduce((function(e,t){return s&&(e[t]="innerText"==t?s[t]:s.getAttribute(t)),e}),{innerText:o.toString(),innerHTML:d})},destroyEditor:function(e){e&&(e.removeEventListener("input",e.inputListener),e.removeEventListener("paste",e.pasteListener),e.removeEventListener("keydown",e.keydownListener),e.removeEventListener("click",e.clickListener),document.removeEventListener("selectionchange",e.selectionChangeListener))},startDrag:function(e,t,n){return e?(e.mouseMoveHandler=function(e){t.invokeMethodAsync(n,{clientX:e.clientX,clientY:e.clientY})},e.touchMoveHandler=function(o){o.targetTouches[0]&&e.contains(o.targetTouches[0].target)&&t.invokeMethodAsync(n,{clientX:o.targetTouches[0].clientX,clientY:o.targetTouches[0].clientY})},e.mouseUpHandler=function(t){Radzen.endDrag(e)},document.addEventListener("mousemove",e.mouseMoveHandler),document.addEventListener("mouseup",e.mouseUpHandler),document.addEventListener("touchmove",e.touchMoveHandler,{passive:!0,capture:!0}),document.addEventListener("touchend",e.mouseUpHandler,{passive:!0}),Radzen.clientRect(e)):{left:0,top:0,width:0,height:0}},submit:function(e){e.submit()},clientRect:function(e){var t=(e instanceof Element||e instanceof HTMLDocument?e:document.getElementById(e)).getBoundingClientRect();return{left:t.left,top:t.top,width:t.width,height:t.height}},endDrag:function(e){document.removeEventListener("mousemove",e.mouseMoveHandler),document.removeEventListener("mouseup",e.mouseUpHandler),document.removeEventListener("touchmove",e.touchMoveHandler),document.removeEventListener("touchend",e.mouseUpHandler)},startColumnReorder:function(e){var t=document.getElementById(e+"-drag").parentNode.parentNode,n=document.createElement("th");n.className=t.className+" rz-column-draggable",n.style=t.style,n.style.display="none",n.style.position="absolute",n.style.height=t.offsetHeight+"px",n.style.width=t.offsetWidth+"px",n.style.zIndex=2e3,n.innerHTML=t.firstChild.outerHTML,n.id=e+"visual",document.body.appendChild(n);var o=t.parentNode.querySelectorAll(".rz-column-resizer");for(let e=0;eo&&(t=o);var s=t+"px";i&&(i.style.width=s),r&&(r.style.width=s),l&&(l.style.width=s),d&&(d.style.width=s)}},touchMoveHandler:function(e){e.targetTouches[0]&&Radzen[a].mouseMoveHandler(e.targetTouches[0])}},a.style.width="100%",document.addEventListener("mousemove",Radzen[a].mouseMoveHandler),document.addEventListener("mouseup",Radzen[a].mouseUpHandler),document.addEventListener("touchmove",Radzen[a].touchMoveHandler,{passive:!0}),document.addEventListener("touchend",Radzen[a].mouseUpHandler,{passive:!0})},startSplitterResize:function(e,t,n,o,a,i,r,l,d,s){var c,u,m,v,p=document.getElementById(e),g=document.getElementById(n),f=document.getElementById(o),h="Horizontal"==a,z=0;function R(e){if(!e)return null;if((e=e.trim().toLowerCase()).endsWith("%"))return z*parseFloat(e)/100;if(e.endsWith("px"))return parseFloat(e);throw"Invalid value"}Array.from(p.children).forEach((e=>{z+=h?e.getBoundingClientRect().width:e.getBoundingClientRect().height})),g&&(m=(c=h?g.getBoundingClientRect().width:g.getBoundingClientRect().height)/z*100+"%"),f&&(v=(u=h?f.getBoundingClientRect().width:f.getBoundingClientRect().height)/z*100+"%"),r=R(r),l=R(l),d=R(d),s=R(s),Radzen[p]={clientPos:i,panePerc:parseFloat(m),paneNextPerc:isFinite(parseFloat(v))?parseFloat(v):0,paneLength:c,paneNextLength:isFinite(u)?u:0,mouseUpHandler:function(e){Radzen[p]&&(t.invokeMethodAsync("RadzenSplitter.OnPaneResized",parseInt(g.getAttribute("data-index")),parseFloat(g.style.flexBasis),f?parseInt(f.getAttribute("data-index")):null,f?parseFloat(f.style.flexBasis):null),document.removeEventListener("pointerup",Radzen[p].mouseUpHandler),document.removeEventListener("pointermove",Radzen[p].mouseMoveHandler),p.removeEventListener("touchmove",y),Radzen[p]=null)},mouseMoveHandler:function(e){if(Radzen[p]){t.invokeMethodAsync("RadzenSplitter.OnPaneResizing");var n=Radzen[p].panePerc+Radzen[p].paneNextPerc,o=Radzen[p].paneLength+Radzen[p].paneNextLength,a=Radzen[p].paneLength-(h&&Radzen.isRTL(e.target)?-1:1)*(Radzen[p].clientPos-(h?e.clientX:e.clientY));if(a>o&&(a=o),r&&al&&(a=l),f){var i=o-a;d&&is&&(a=o+s)}var c=a/Radzen[p].paneLength;isFinite(c)||(c=1,Radzen[p].panePerc=.1,Radzen[p].paneLength=h?g.getBoundingClientRect().width:g.getBoundingClientRect().height);var u=Radzen[p].panePerc*c;u<0&&(u=0),u>100&&(u=100),g.style.flexBasis=u+"%",f&&(f.style.flexBasis=n-u+"%")}},touchMoveHandler:function(e){e.targetTouches[0]&&Radzen[p].mouseMoveHandler(e.targetTouches[0])}};const y=e=>{e.preventDefault(),e.stopPropagation()};document.addEventListener("pointerup",Radzen[p].mouseUpHandler),document.addEventListener("pointermove",Radzen[p].mouseMoveHandler),p.addEventListener("touchmove",y,{passive:!1})},resizeSplitter(e,t){var n=document.getElementById(e);n&&Radzen[n]&&(Radzen[n].mouseMoveHandler(t),Radzen[n].mouseUpHandler(t))},openWaiting:function(){document.documentElement.scrollHeight>document.documentElement.clientHeight&&document.body.classList.add("no-scroll"),null!=Radzen.WaitingIntervalId&&clearInterval(Radzen.WaitingIntervalId),setTimeout((function(){var e=document.getElementsByClassName("rz-waiting-timer");if(0!=e.length){var t=(new Date).getTime();Radzen.WaitingIntervalId=setInterval((function(){if(null==e||null==e[0])clearInterval(Radzen.WaitingIntervalId);else{var n=new Date((new Date).getTime()-t);e[0].innerHTML=Math.floor(n/1e3)+"."+Math.floor(n%1e3/100)}}),100)}}),100)},closeWaiting:function(){document.body.classList.remove("no-scroll"),null!=Radzen.WaitingIntervalId&&(clearInterval(Radzen.WaitingIntervalId),Radzen.WaitingIntervalId=null)},toggleDictation:function(e,t){function n(){const n=window.SpeechRecognition||window.webkitSpeechRecognition;n&&((radzenRecognition=new n).componentRef=e,radzenRecognition.continuous=!0,t&&(radzenRecognition.lang=t),radzenRecognition.onresult=function(t){if(t.results.length<1)return;let n=t.results[t.results.length-1][0].transcript;e.invokeMethodAsync("OnResult",n)},radzenRecognition.onend=function(t){e.invokeMethodAsync("StopRecording"),radzenRecognition=null},radzenRecognition.start())}radzenRecognition?(radzenRecognition.componentRef._id!=e._id&&radzenRecognition.addEventListener("end",n),radzenRecognition.stop()):n()},openChartTooltip:function(e,t,n,o,a,i){Radzen.closeTooltip(o);var r=e.getBoundingClientRect();t=Math.max(2,r.left+t),n=Math.max(2,r.top+n),Radzen.openPopup(e,o,!1,null,t,n,a,i,!0,!1,!1);var l=document.getElementById(o);if(l){var d=l.children[0],s="rz-top-chart-tooltip";n-d.getBoundingClientRect().height<0&&(s="rz-bottom-chart-tooltip"),d.classList.remove("rz-top-chart-tooltip"),d.classList.remove("rz-bottom-chart-tooltip"),d.classList.add(s)}},navigateTo:function(e,t){if(e.startsWith("#")&&history.replaceState(null,"",location.pathname+location.search+e),t){const t=document.querySelector(e);t&&t.scrollIntoView({behavior:"smooth",block:"center",inline:"start"})}},registerScrollListener:function(e,t,n,o){let a;const i=o?document.querySelector(o):document.documentElement,r=n.map(document.querySelector,document);this.unregisterScrollListener(e),e.scrollHandler=()=>{const e=("HTML"===i.tagName?0:i.getBoundingClientRect().top)+i.clientHeight/2;let o,l=Number.MAX_SAFE_INTEGER;for(let t=0;t=e||d