From 9aec93d8561d3ab71d3f3591b919a0d6daaea254 Mon Sep 17 00:00:00 2001 From: Neil Kirsopp Date: Sun, 12 Jan 2025 12:35:46 +0530 Subject: [PATCH] Not found returns (0 0) for size and posn, use else ifs for switch The many if statements formed a quasi switch statement, and as there was no default, it worked fine. I know need a default and it's easier to avoid mistakes if we use else if statements. Don't crash on invalid IDs for size and pos, return [0, 0] as sentinel values. --- .../{index-6db537cd.js => index-ca98448a.js} | 624 +++++++++--------- dist/index.html | 2 +- src/App.jsx | 83 +-- src/utils/sizeposn.js | 3 + 4 files changed, 348 insertions(+), 364 deletions(-) rename dist/assets/{index-6db537cd.js => index-ca98448a.js} (57%) diff --git a/dist/assets/index-6db537cd.js b/dist/assets/index-ca98448a.js similarity index 57% rename from dist/assets/index-6db537cd.js rename to dist/assets/index-ca98448a.js index 157eb7f..a560b5f 100644 --- a/dist/assets/index-6db537cd.js +++ b/dist/assets/index-ca98448a.js @@ -1,4 +1,4 @@ -function YY(t,r){for(var n=0;ni[o]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}(function(){const r=document.createElement("link").relList;if(r&&r.supports&&r.supports("modulepreload"))return;for(const o of document.querySelectorAll('link[rel="modulepreload"]'))i(o);new MutationObserver(o=>{for(const a of o)if(a.type==="childList")for(const s of a.addedNodes)s.tagName==="LINK"&&s.rel==="modulepreload"&&i(s)}).observe(document,{childList:!0,subtree:!0});function n(o){const a={};return o.integrity&&(a.integrity=o.integrity),o.referrerPolicy&&(a.referrerPolicy=o.referrerPolicy),o.crossOrigin==="use-credentials"?a.credentials="include":o.crossOrigin==="anonymous"?a.credentials="omit":a.credentials="same-origin",a}function i(o){if(o.ep)return;o.ep=!0;const a=n(o);fetch(o.href,a)}})();var S3=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function _8(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var rI={exports:{}},k9={},iI={exports:{}},E1={};/** +function XY(t,r){for(var n=0;ni[o]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}(function(){const r=document.createElement("link").relList;if(r&&r.supports&&r.supports("modulepreload"))return;for(const o of document.querySelectorAll('link[rel="modulepreload"]'))i(o);new MutationObserver(o=>{for(const a of o)if(a.type==="childList")for(const s of a.addedNodes)s.tagName==="LINK"&&s.rel==="modulepreload"&&i(s)}).observe(document,{childList:!0,subtree:!0});function n(o){const a={};return o.integrity&&(a.integrity=o.integrity),o.referrerPolicy&&(a.referrerPolicy=o.referrerPolicy),o.crossOrigin==="use-credentials"?a.credentials="include":o.crossOrigin==="anonymous"?a.credentials="omit":a.credentials="same-origin",a}function i(o){if(o.ep)return;o.ep=!0;const a=n(o);fetch(o.href,a)}})();var S3=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function _8(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var iI={exports:{}},k9={},nI={exports:{}},_1={};/** * @license React * react.production.min.js * @@ -6,7 +6,7 @@ function YY(t,r){for(var n=0;n>>1,Mt=gt[bt];if(0>>1;bto(Bt,_t))Uto(Xt,Bt)?(gt[bt]=Xt,gt[Ut]=_t,bt=Ut):(gt[bt]=Bt,gt[Ft]=_t,bt=Ft);else if(Uto(Xt,_t))gt[bt]=Xt,gt[Ut]=_t,bt=Ut;else break t}}return kt}function o(gt,kt){var _t=gt.sortIndex-kt.sortIndex;return _t!==0?_t:gt.id-kt.id}if(typeof performance=="object"&&typeof performance.now=="function"){var a=performance;t.unstable_now=function(){return a.now()}}else{var s=Date,l=s.now();t.unstable_now=function(){return s.now()-l}}var h=[],p=[],f=1,g=null,b=3,z=!1,M=!1,I=!1,F=typeof setTimeout=="function"?setTimeout:null,H=typeof clearTimeout=="function"?clearTimeout:null,E=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function R(gt){for(var kt=n(p);kt!==null;){if(kt.callback===null)i(p);else if(kt.startTime<=gt)i(p),kt.sortIndex=kt.expirationTime,r(h,kt);else break;kt=n(p)}}function W(gt){if(I=!1,R(gt),!M)if(n(h)!==null)M=!0,yt($);else{var kt=n(p);kt!==null&&mt(W,kt.startTime-gt)}}function $(gt,kt){M=!1,I&&(I=!1,H(K),K=-1),z=!0;var _t=b;try{for(R(kt),g=n(h);g!==null&&(!(g.expirationTime>kt)||gt&&!tt());){var bt=g.callback;if(typeof bt=="function"){g.callback=null,b=g.priorityLevel;var Mt=bt(g.expirationTime<=kt);kt=t.unstable_now(),typeof Mt=="function"?g.callback=Mt:g===n(h)&&i(h),R(kt)}else i(h);g=n(h)}if(g!==null)var At=!0;else{var Ft=n(p);Ft!==null&&mt(W,Ft.startTime-kt),At=!1}return At}finally{g=null,b=_t,z=!1}}var G=!1,Z=null,K=-1,et=5,at=-1;function tt(){return!(t.unstable_now()-atgt||125bt?(gt.sortIndex=_t,r(p,gt),n(h)===null&>===n(p)&&(I?(H(K),K=-1):I=!0,mt(W,_t-bt))):(gt.sortIndex=Mt,r(h,gt),M||z||(M=!0,yt($))),gt},t.unstable_shouldYield=tt,t.unstable_wrapCallback=function(gt){var kt=b;return function(){var _t=b;b=kt;try{return gt.apply(this,arguments)}finally{b=_t}}}})(vI);fI.exports=vI;var gX=fI.exports;/** + */(function(t){function r(gt,_t){var At=gt.length;gt.push(_t);t:for(;0>>1,kt=gt[bt];if(0>>1;bto(Rt,At))Uto(Kt,Rt)?(gt[bt]=Kt,gt[Ut]=At,bt=Ut):(gt[bt]=Rt,gt[Vt]=At,bt=Vt);else if(Uto(Kt,At))gt[bt]=Kt,gt[Ut]=At,bt=Ut;else break t}}return _t}function o(gt,_t){var At=gt.sortIndex-_t.sortIndex;return At!==0?At:gt.id-_t.id}if(typeof performance=="object"&&typeof performance.now=="function"){var a=performance;t.unstable_now=function(){return a.now()}}else{var s=Date,l=s.now();t.unstable_now=function(){return s.now()-l}}var h=[],p=[],f=1,g=null,b=3,z=!1,M=!1,I=!1,F=typeof setTimeout=="function"?setTimeout:null,H=typeof clearTimeout=="function"?clearTimeout:null,E=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function R(gt){for(var _t=n(p);_t!==null;){if(_t.callback===null)i(p);else if(_t.startTime<=gt)i(p),_t.sortIndex=_t.expirationTime,r(h,_t);else break;_t=n(p)}}function W(gt){if(I=!1,R(gt),!M)if(n(h)!==null)M=!0,yt($);else{var _t=n(p);_t!==null&&mt(W,_t.startTime-gt)}}function $(gt,_t){M=!1,I&&(I=!1,H(K),K=-1),z=!0;var At=b;try{for(R(_t),g=n(h);g!==null&&(!(g.expirationTime>_t)||gt&&!tt());){var bt=g.callback;if(typeof bt=="function"){g.callback=null,b=g.priorityLevel;var kt=bt(g.expirationTime<=_t);_t=t.unstable_now(),typeof kt=="function"?g.callback=kt:g===n(h)&&i(h),R(_t)}else i(h);g=n(h)}if(g!==null)var Lt=!0;else{var Vt=n(p);Vt!==null&&mt(W,Vt.startTime-_t),Lt=!1}return Lt}finally{g=null,b=At,z=!1}}var G=!1,Z=null,K=-1,et=5,at=-1;function tt(){return!(t.unstable_now()-atgt||125bt?(gt.sortIndex=At,r(p,gt),n(h)===null&>===n(p)&&(I?(H(K),K=-1):I=!0,mt(W,At-bt))):(gt.sortIndex=kt,r(h,gt),M||z||(M=!0,yt($))),gt},t.unstable_shouldYield=tt,t.unstable_wrapCallback=function(gt){var _t=b;return function(){var At=b;b=_t;try{return gt.apply(this,arguments)}finally{b=At}}}})(gI);vI.exports=gI;var mX=vI.exports;/** * @license React * react-dom.production.min.js * @@ -30,14 +30,14 @@ function YY(t,r){for(var n=0;n"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),qv=Object.prototype.hasOwnProperty,yX=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,Wz={},jz={};function xX(t){return qv.call(jz,t)?!0:qv.call(Wz,t)?!1:yX.test(t)?jz[t]=!0:(Wz[t]=!0,!1)}function bX(t,r,n,i){if(n!==null&&n.type===0)return!1;switch(typeof r){case"function":case"symbol":return!0;case"boolean":return i?!1:n!==null?!n.acceptsBooleans:(t=t.toLowerCase().slice(0,5),t!=="data-"&&t!=="aria-");default:return!1}}function wX(t,r,n,i){if(r===null||typeof r>"u"||bX(t,r,n,i))return!0;if(i)return!1;if(n!==null)switch(n.type){case 3:return!r;case 4:return r===!1;case 5:return isNaN(r);case 6:return isNaN(r)||1>r}return!1}function wn(t,r,n,i,o,a,s){this.acceptsBooleans=r===2||r===3||r===4,this.attributeName=i,this.attributeNamespace=o,this.mustUseProperty=n,this.propertyName=t,this.type=r,this.sanitizeURL=a,this.removeEmptyString=s}var Fi={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(t){Fi[t]=new wn(t,0,!1,t,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(t){var r=t[0];Fi[r]=new wn(r,1,!1,t[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(t){Fi[t]=new wn(t,2,!1,t.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(t){Fi[t]=new wn(t,2,!1,t,null,!1,!1)});"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(t){Fi[t]=new wn(t,3,!1,t.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(t){Fi[t]=new wn(t,3,!0,t,null,!1,!1)});["capture","download"].forEach(function(t){Fi[t]=new wn(t,4,!1,t,null,!1,!1)});["cols","rows","size","span"].forEach(function(t){Fi[t]=new wn(t,6,!1,t,null,!1,!1)});["rowSpan","start"].forEach(function(t){Fi[t]=new wn(t,5,!1,t.toLowerCase(),null,!1,!1)});var Jy=/[\-:]([a-z])/g;function Qy(t){return t[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(t){var r=t.replace(Jy,Qy);Fi[r]=new wn(r,1,!1,t,null,!1,!1)});"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(t){var r=t.replace(Jy,Qy);Fi[r]=new wn(r,1,!1,t,"http://www.w3.org/1999/xlink",!1,!1)});["xml:base","xml:lang","xml:space"].forEach(function(t){var r=t.replace(Jy,Qy);Fi[r]=new wn(r,1,!1,t,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(t){Fi[t]=new wn(t,1,!1,t.toLowerCase(),null,!1,!1)});Fi.xlinkHref=new wn("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(t){Fi[t]=new wn(t,1,!1,t.toLowerCase(),null,!0,!0)});function tx(t,r,n,i){var o=Fi.hasOwnProperty(r)?Fi[r]:null;(o!==null?o.type!==0:i||!(2"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),qv=Object.prototype.hasOwnProperty,xX=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,jz={},Gz={};function bX(t){return qv.call(Gz,t)?!0:qv.call(jz,t)?!1:xX.test(t)?Gz[t]=!0:(jz[t]=!0,!1)}function wX(t,r,n,i){if(n!==null&&n.type===0)return!1;switch(typeof r){case"function":case"symbol":return!0;case"boolean":return i?!1:n!==null?!n.acceptsBooleans:(t=t.toLowerCase().slice(0,5),t!=="data-"&&t!=="aria-");default:return!1}}function CX(t,r,n,i){if(r===null||typeof r>"u"||wX(t,r,n,i))return!0;if(i)return!1;if(n!==null)switch(n.type){case 3:return!r;case 4:return r===!1;case 5:return isNaN(r);case 6:return isNaN(r)||1>r}return!1}function xn(t,r,n,i,o,a,s){this.acceptsBooleans=r===2||r===3||r===4,this.attributeName=i,this.attributeNamespace=o,this.mustUseProperty=n,this.propertyName=t,this.type=r,this.sanitizeURL=a,this.removeEmptyString=s}var Ti={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(t){Ti[t]=new xn(t,0,!1,t,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(t){var r=t[0];Ti[r]=new xn(r,1,!1,t[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(t){Ti[t]=new xn(t,2,!1,t.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(t){Ti[t]=new xn(t,2,!1,t,null,!1,!1)});"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(t){Ti[t]=new xn(t,3,!1,t.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(t){Ti[t]=new xn(t,3,!0,t,null,!1,!1)});["capture","download"].forEach(function(t){Ti[t]=new xn(t,4,!1,t,null,!1,!1)});["cols","rows","size","span"].forEach(function(t){Ti[t]=new xn(t,6,!1,t,null,!1,!1)});["rowSpan","start"].forEach(function(t){Ti[t]=new xn(t,5,!1,t.toLowerCase(),null,!1,!1)});var Qy=/[\-:]([a-z])/g;function tx(t){return t[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(t){var r=t.replace(Qy,tx);Ti[r]=new xn(r,1,!1,t,null,!1,!1)});"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(t){var r=t.replace(Qy,tx);Ti[r]=new xn(r,1,!1,t,"http://www.w3.org/1999/xlink",!1,!1)});["xml:base","xml:lang","xml:space"].forEach(function(t){var r=t.replace(Qy,tx);Ti[r]=new xn(r,1,!1,t,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(t){Ti[t]=new xn(t,1,!1,t.toLowerCase(),null,!1,!1)});Ti.xlinkHref=new xn("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(t){Ti[t]=new xn(t,1,!1,t.toLowerCase(),null,!0,!0)});function ex(t,r,n,i){var o=Ti.hasOwnProperty(r)?Ti[r]:null;(o!==null?o.type!==0:i||!(2l||o[s]!==a[l]){var h=` -`+o[s].replace(" at new "," at ");return t.displayName&&h.includes("")&&(h=h.replace("",t.displayName)),h}while(1<=s&&0<=l);break}}}finally{xf=!1,Error.prepareStackTrace=n}return(t=t?t.displayName||t.name:"")?K6(t):""}function CX(t){switch(t.tag){case 5:return K6(t.type);case 16:return K6("Lazy");case 13:return K6("Suspense");case 19:return K6("SuspenseList");case 0:case 2:case 15:return t=bf(t.type,!1),t;case 11:return t=bf(t.type.render,!1),t;case 1:return t=bf(t.type,!0),t;default:return""}}function tg(t){if(t==null)return null;if(typeof t=="function")return t.displayName||t.name||null;if(typeof t=="string")return t;switch(t){case E3:return"Fragment";case L3:return"Portal";case Zv:return"Profiler";case ex:return"StrictMode";case Jv:return"Suspense";case Qv:return"SuspenseList"}if(typeof t=="object")switch(t.$$typeof){case yI:return(t.displayName||"Context")+".Consumer";case mI:return(t._context.displayName||"Context")+".Provider";case rx:var r=t.render;return t=t.displayName,t||(t=r.displayName||r.name||"",t=t!==""?"ForwardRef("+t+")":"ForwardRef"),t;case ix:return r=t.displayName||null,r!==null?r:tg(t.type)||"Memo";case Es:r=t._payload,t=t._init;try{return tg(t(r))}catch{}}return null}function SX(t){var r=t.type;switch(t.tag){case 24:return"Cache";case 9:return(r.displayName||"Context")+".Consumer";case 10:return(r._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return t=r.render,t=t.displayName||t.name||"",r.displayName||(t!==""?"ForwardRef("+t+")":"ForwardRef");case 7:return"Fragment";case 5:return r;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return tg(r);case 8:return r===ex?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof r=="function")return r.displayName||r.name||null;if(typeof r=="string")return r}return null}function r4(t){switch(typeof t){case"boolean":case"number":case"string":case"undefined":return t;case"object":return t;default:return""}}function bI(t){var r=t.type;return(t=t.nodeName)&&t.toLowerCase()==="input"&&(r==="checkbox"||r==="radio")}function zX(t){var r=bI(t)?"checked":"value",n=Object.getOwnPropertyDescriptor(t.constructor.prototype,r),i=""+t[r];if(!t.hasOwnProperty(r)&&typeof n<"u"&&typeof n.get=="function"&&typeof n.set=="function"){var o=n.get,a=n.set;return Object.defineProperty(t,r,{configurable:!0,get:function(){return o.call(this)},set:function(s){i=""+s,a.call(this,s)}}),Object.defineProperty(t,r,{enumerable:n.enumerable}),{getValue:function(){return i},setValue:function(s){i=""+s},stopTracking:function(){t._valueTracker=null,delete t[r]}}}}function ch(t){t._valueTracker||(t._valueTracker=zX(t))}function wI(t){if(!t)return!1;var r=t._valueTracker;if(!r)return!0;var n=r.getValue(),i="";return t&&(i=bI(t)?t.checked?"true":"false":t.value),t=i,t!==n?(r.setValue(t),!0):!1}function eu(t){if(t=t||(typeof document<"u"?document:void 0),typeof t>"u")return null;try{return t.activeElement||t.body}catch{return t.body}}function eg(t,r){var n=r.checked;return Or({},r,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??t._wrapperState.initialChecked})}function Uz(t,r){var n=r.defaultValue==null?"":r.defaultValue,i=r.checked!=null?r.checked:r.defaultChecked;n=r4(r.value!=null?r.value:n),t._wrapperState={initialChecked:i,initialValue:n,controlled:r.type==="checkbox"||r.type==="radio"?r.checked!=null:r.value!=null}}function CI(t,r){r=r.checked,r!=null&&tx(t,"checked",r,!1)}function rg(t,r){CI(t,r);var n=r4(r.value),i=r.type;if(n!=null)i==="number"?(n===0&&t.value===""||t.value!=n)&&(t.value=""+n):t.value!==""+n&&(t.value=""+n);else if(i==="submit"||i==="reset"){t.removeAttribute("value");return}r.hasOwnProperty("value")?ig(t,r.type,n):r.hasOwnProperty("defaultValue")&&ig(t,r.type,r4(r.defaultValue)),r.checked==null&&r.defaultChecked!=null&&(t.defaultChecked=!!r.defaultChecked)}function Yz(t,r,n){if(r.hasOwnProperty("value")||r.hasOwnProperty("defaultValue")){var i=r.type;if(!(i!=="submit"&&i!=="reset"||r.value!==void 0&&r.value!==null))return;r=""+t._wrapperState.initialValue,n||r===t.value||(t.value=r),t.defaultValue=r}n=t.name,n!==""&&(t.name=""),t.defaultChecked=!!t._wrapperState.initialChecked,n!==""&&(t.name=n)}function ig(t,r,n){(r!=="number"||eu(t.ownerDocument)!==t)&&(n==null?t.defaultValue=""+t._wrapperState.initialValue:t.defaultValue!==""+n&&(t.defaultValue=""+n))}var q6=Array.isArray;function J3(t,r,n,i){if(t=t.options,r){r={};for(var o=0;o"+r.valueOf().toString()+"",r=hh.firstChild;t.firstChild;)t.removeChild(t.firstChild);for(;r.firstChild;)t.appendChild(r.firstChild)}});function Bc(t,r){if(r){var n=t.firstChild;if(n&&n===t.lastChild&&n.nodeType===3){n.nodeValue=r;return}}t.textContent=r}var wc={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},MX=["Webkit","ms","Moz","O"];Object.keys(wc).forEach(function(t){MX.forEach(function(r){r=r+t.charAt(0).toUpperCase()+t.substring(1),wc[r]=wc[t]})});function kI(t,r,n){return r==null||typeof r=="boolean"||r===""?"":n||typeof r!="number"||r===0||wc.hasOwnProperty(t)&&wc[t]?(""+r).trim():r+"px"}function _I(t,r){t=t.style;for(var n in r)if(r.hasOwnProperty(n)){var i=n.indexOf("--")===0,o=kI(n,r[n],i);n==="float"&&(n="cssFloat"),i?t.setProperty(n,o):t[n]=o}}var kX=Or({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function ag(t,r){if(r){if(kX[t]&&(r.children!=null||r.dangerouslySetInnerHTML!=null))throw Error(be(137,t));if(r.dangerouslySetInnerHTML!=null){if(r.children!=null)throw Error(be(60));if(typeof r.dangerouslySetInnerHTML!="object"||!("__html"in r.dangerouslySetInnerHTML))throw Error(be(61))}if(r.style!=null&&typeof r.style!="object")throw Error(be(62))}}function sg(t,r){if(t.indexOf("-")===-1)return typeof r.is=="string";switch(t){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var lg=null;function nx(t){return t=t.target||t.srcElement||window,t.correspondingUseElement&&(t=t.correspondingUseElement),t.nodeType===3?t.parentNode:t}var cg=null,Q3=null,tl=null;function qz(t){if(t=I8(t)){if(typeof cg!="function")throw Error(be(280));var r=t.stateNode;r&&(r=I9(r),cg(t.stateNode,t.type,r))}}function AI(t){Q3?tl?tl.push(t):tl=[t]:Q3=t}function LI(){if(Q3){var t=Q3,r=tl;if(tl=Q3=null,qz(t),r)for(t=0;t>>=0,t===0?32:31-(FX(t)/RX|0)|0}var uh=64,ph=4194304;function Z6(t){switch(t&-t){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return t&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return t}}function ou(t,r){var n=t.pendingLanes;if(n===0)return 0;var i=0,o=t.suspendedLanes,a=t.pingedLanes,s=n&268435455;if(s!==0){var l=s&~o;l!==0?i=Z6(l):(a&=s,a!==0&&(i=Z6(a)))}else s=n&~o,s!==0?i=Z6(s):a!==0&&(i=Z6(a));if(i===0)return 0;if(r!==0&&r!==i&&!(r&o)&&(o=i&-i,a=r&-r,o>=a||o===16&&(a&4194240)!==0))return r;if(i&4&&(i|=n&16),r=t.entangledLanes,r!==0)for(t=t.entanglements,r&=i;0n;n++)r.push(t);return r}function L8(t,r,n){t.pendingLanes|=r,r!==536870912&&(t.suspendedLanes=0,t.pingedLanes=0),t=t.eventTimes,r=31-vo(r),t[r]=n}function $X(t,r){var n=t.pendingLanes&~r;t.pendingLanes=r,t.suspendedLanes=0,t.pingedLanes=0,t.expiredLanes&=r,t.mutableReadLanes&=r,t.entangledLanes&=r,r=t.entanglements;var i=t.eventTimes;for(t=t.expirationTimes;0=Sc),oM=String.fromCharCode(32),aM=!1;function KI(t,r){switch(t){case"keyup":return gK.indexOf(r.keyCode)!==-1;case"keydown":return r.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function qI(t){return t=t.detail,typeof t=="object"&&"data"in t?t.data:null}var I3=!1;function yK(t,r){switch(t){case"compositionend":return qI(r);case"keypress":return r.which!==32?null:(aM=!0,oM);case"textInput":return t=r.data,t===oM&&aM?null:t;default:return null}}function xK(t,r){if(I3)return t==="compositionend"||!px&&KI(t,r)?(t=YI(),h7=cx=Fs=null,I3=!1,t):null;switch(t){case"paste":return null;case"keypress":if(!(r.ctrlKey||r.altKey||r.metaKey)||r.ctrlKey&&r.altKey){if(r.char&&1=r)return{node:n,offset:r-t};t=i}t:{for(;n;){if(n.nextSibling){n=n.nextSibling;break t}n=n.parentNode}n=void 0}n=hM(n)}}function tH(t,r){return t&&r?t===r?!0:t&&t.nodeType===3?!1:r&&r.nodeType===3?tH(t,r.parentNode):"contains"in t?t.contains(r):t.compareDocumentPosition?!!(t.compareDocumentPosition(r)&16):!1:!1}function eH(){for(var t=window,r=eu();r instanceof t.HTMLIFrameElement;){try{var n=typeof r.contentWindow.location.href=="string"}catch{n=!1}if(n)t=r.contentWindow;else break;r=eu(t.document)}return r}function dx(t){var r=t&&t.nodeName&&t.nodeName.toLowerCase();return r&&(r==="input"&&(t.type==="text"||t.type==="search"||t.type==="tel"||t.type==="url"||t.type==="password")||r==="textarea"||t.contentEditable==="true")}function AK(t){var r=eH(),n=t.focusedElem,i=t.selectionRange;if(r!==n&&n&&n.ownerDocument&&tH(n.ownerDocument.documentElement,n)){if(i!==null&&dx(n)){if(r=i.start,t=i.end,t===void 0&&(t=r),"selectionStart"in n)n.selectionStart=r,n.selectionEnd=Math.min(t,n.value.length);else if(t=(r=n.ownerDocument||document)&&r.defaultView||window,t.getSelection){t=t.getSelection();var o=n.textContent.length,a=Math.min(i.start,o);i=i.end===void 0?a:Math.min(i.end,o),!t.extend&&a>i&&(o=i,i=a,a=o),o=uM(n,a);var s=uM(n,i);o&&s&&(t.rangeCount!==1||t.anchorNode!==o.node||t.anchorOffset!==o.offset||t.focusNode!==s.node||t.focusOffset!==s.offset)&&(r=r.createRange(),r.setStart(o.node,o.offset),t.removeAllRanges(),a>i?(t.addRange(r),t.extend(s.node,s.offset)):(r.setEnd(s.node,s.offset),t.addRange(r)))}}for(r=[],t=n;t=t.parentNode;)t.nodeType===1&&r.push({element:t,left:t.scrollLeft,top:t.scrollTop});for(typeof n.focus=="function"&&n.focus(),n=0;n=document.documentMode,H3=null,vg=null,Mc=null,gg=!1;function pM(t,r,n){var i=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;gg||H3==null||H3!==eu(i)||(i=H3,"selectionStart"in i&&dx(i)?i={start:i.selectionStart,end:i.selectionEnd}:(i=(i.ownerDocument&&i.ownerDocument.defaultView||window).getSelection(),i={anchorNode:i.anchorNode,anchorOffset:i.anchorOffset,focusNode:i.focusNode,focusOffset:i.focusOffset}),Mc&&Uc(Mc,i)||(Mc=i,i=lu(vg,"onSelect"),0T3||(t.current=Cg[T3],Cg[T3]=null,T3--)}function Sr(t,r){T3++,Cg[T3]=t.current,t.current=r}var i4={},Ji=g4(i4),Tn=g4(!1),m0=i4;function hl(t,r){var n=t.type.contextTypes;if(!n)return i4;var i=t.stateNode;if(i&&i.__reactInternalMemoizedUnmaskedChildContext===r)return i.__reactInternalMemoizedMaskedChildContext;var o={},a;for(a in n)o[a]=r[a];return i&&(t=t.stateNode,t.__reactInternalMemoizedUnmaskedChildContext=r,t.__reactInternalMemoizedMaskedChildContext=o),o}function Vn(t){return t=t.childContextTypes,t!=null}function hu(){_r(Tn),_r(Ji)}function xM(t,r,n){if(Ji.current!==i4)throw Error(be(168));Sr(Ji,r),Sr(Tn,n)}function hH(t,r,n){var i=t.stateNode;if(r=r.childContextTypes,typeof i.getChildContext!="function")return n;i=i.getChildContext();for(var o in i)if(!(o in r))throw Error(be(108,SX(t)||"Unknown",o));return Or({},n,i)}function uu(t){return t=(t=t.stateNode)&&t.__reactInternalMemoizedMergedChildContext||i4,m0=Ji.current,Sr(Ji,t),Sr(Tn,Tn.current),!0}function bM(t,r,n){var i=t.stateNode;if(!i)throw Error(be(169));n?(t=hH(t,r,m0),i.__reactInternalMemoizedMergedChildContext=t,_r(Tn),_r(Ji),Sr(Ji,t)):_r(Tn),Sr(Tn,n)}var Aa=null,H9=!1,Pf=!1;function uH(t){Aa===null?Aa=[t]:Aa.push(t)}function BK(t){H9=!0,uH(t)}function m4(){if(!Pf&&Aa!==null){Pf=!0;var t=0,r=ur;try{var n=Aa;for(ur=1;t>=s,o-=s,Va=1<<32-vo(r)+o|n<K?(et=Z,Z=null):et=Z.sibling;var at=b(H,Z,R[K],W);if(at===null){Z===null&&(Z=et);break}t&&Z&&at.alternate===null&&r(H,Z),E=a(at,E,K),G===null?$=at:G.sibling=at,G=at,Z=et}if(K===R.length)return n(H,Z),Ir&&j4(H,K),$;if(Z===null){for(;KK?(et=Z,Z=null):et=Z.sibling;var tt=b(H,Z,at.value,W);if(tt===null){Z===null&&(Z=et);break}t&&Z&&tt.alternate===null&&r(H,Z),E=a(tt,E,K),G===null?$=tt:G.sibling=tt,G=tt,Z=et}if(at.done)return n(H,Z),Ir&&j4(H,K),$;if(Z===null){for(;!at.done;K++,at=R.next())at=g(H,at.value,W),at!==null&&(E=a(at,E,K),G===null?$=at:G.sibling=at,G=at);return Ir&&j4(H,K),$}for(Z=i(H,Z);!at.done;K++,at=R.next())at=z(Z,H,K,at.value,W),at!==null&&(t&&at.alternate!==null&&Z.delete(at.key===null?K:at.key),E=a(at,E,K),G===null?$=at:G.sibling=at,G=at);return t&&Z.forEach(function(ft){return r(H,ft)}),Ir&&j4(H,K),$}function F(H,E,R,W){if(typeof R=="object"&&R!==null&&R.type===E3&&R.key===null&&(R=R.props.children),typeof R=="object"&&R!==null){switch(R.$$typeof){case lh:t:{for(var $=R.key,G=E;G!==null;){if(G.key===$){if($=R.type,$===E3){if(G.tag===7){n(H,G.sibling),E=o(G,R.props.children),E.return=H,H=E;break t}}else if(G.elementType===$||typeof $=="object"&&$!==null&&$.$$typeof===Es&&SM($)===G.type){n(H,G.sibling),E=o(G,R.props),E.ref=V6(H,G,R),E.return=H,H=E;break t}n(H,G);break}else r(H,G);G=G.sibling}R.type===E3?(E=s0(R.props.children,H.mode,W,R.key),E.return=H,H=E):(W=y7(R.type,R.key,R.props,null,H.mode,W),W.ref=V6(H,E,R),W.return=H,H=W)}return s(H);case L3:t:{for(G=R.key;E!==null;){if(E.key===G)if(E.tag===4&&E.stateNode.containerInfo===R.containerInfo&&E.stateNode.implementation===R.implementation){n(H,E.sibling),E=o(E,R.children||[]),E.return=H,H=E;break t}else{n(H,E);break}else r(H,E);E=E.sibling}E=$f(R,H.mode,W),E.return=H,H=E}return s(H);case Es:return G=R._init,F(H,E,G(R._payload),W)}if(q6(R))return M(H,E,R,W);if(I6(R))return I(H,E,R,W);xh(H,R)}return typeof R=="string"&&R!==""||typeof R=="number"?(R=""+R,E!==null&&E.tag===6?(n(H,E.sibling),E=o(E,R),E.return=H,H=E):(n(H,E),E=Nf(R,H.mode,W),E.return=H,H=E),s(H)):n(H,E)}return F}var pl=vH(!0),gH=vH(!1),fu=g4(null),vu=null,R3=null,mx=null;function yx(){mx=R3=vu=null}function xx(t){var r=fu.current;_r(fu),t._currentValue=r}function Mg(t,r,n){for(;t!==null;){var i=t.alternate;if((t.childLanes&r)!==r?(t.childLanes|=r,i!==null&&(i.childLanes|=r)):i!==null&&(i.childLanes&r)!==r&&(i.childLanes|=r),t===n)break;t=t.return}}function rl(t,r){vu=t,mx=R3=null,t=t.dependencies,t!==null&&t.firstContext!==null&&(t.lanes&r&&(Dn=!0),t.firstContext=null)}function W2(t){var r=t._currentValue;if(mx!==t)if(t={context:t,memoizedValue:r,next:null},R3===null){if(vu===null)throw Error(be(308));R3=t,vu.dependencies={lanes:0,firstContext:t}}else R3=R3.next=t;return r}var J4=null;function bx(t){J4===null?J4=[t]:J4.push(t)}function mH(t,r,n,i){var o=r.interleaved;return o===null?(n.next=n,bx(r)):(n.next=o.next,o.next=n),r.interleaved=n,Ua(t,i)}function Ua(t,r){t.lanes|=r;var n=t.alternate;for(n!==null&&(n.lanes|=r),n=t,t=t.return;t!==null;)t.childLanes|=r,n=t.alternate,n!==null&&(n.childLanes|=r),n=t,t=t.return;return n.tag===3?n.stateNode:null}var Is=!1;function wx(t){t.updateQueue={baseState:t.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function yH(t,r){t=t.updateQueue,r.updateQueue===t&&(r.updateQueue={baseState:t.baseState,firstBaseUpdate:t.firstBaseUpdate,lastBaseUpdate:t.lastBaseUpdate,shared:t.shared,effects:t.effects})}function Oa(t,r){return{eventTime:t,lane:r,tag:0,payload:null,callback:null,next:null}}function Xs(t,r,n){var i=t.updateQueue;if(i===null)return null;if(i=i.shared,B1&2){var o=i.pending;return o===null?r.next=r:(r.next=o.next,o.next=r),i.pending=r,Ua(t,n)}return o=i.interleaved,o===null?(r.next=r,bx(i)):(r.next=o.next,o.next=r),i.interleaved=r,Ua(t,n)}function p7(t,r,n){if(r=r.updateQueue,r!==null&&(r=r.shared,(n&4194240)!==0)){var i=r.lanes;i&=t.pendingLanes,n|=i,r.lanes=n,ax(t,n)}}function zM(t,r){var n=t.updateQueue,i=t.alternate;if(i!==null&&(i=i.updateQueue,n===i)){var o=null,a=null;if(n=n.firstBaseUpdate,n!==null){do{var s={eventTime:n.eventTime,lane:n.lane,tag:n.tag,payload:n.payload,callback:n.callback,next:null};a===null?o=a=s:a=a.next=s,n=n.next}while(n!==null);a===null?o=a=r:a=a.next=r}else o=a=r;n={baseState:i.baseState,firstBaseUpdate:o,lastBaseUpdate:a,shared:i.shared,effects:i.effects},t.updateQueue=n;return}t=n.lastBaseUpdate,t===null?n.firstBaseUpdate=r:t.next=r,n.lastBaseUpdate=r}function gu(t,r,n,i){var o=t.updateQueue;Is=!1;var a=o.firstBaseUpdate,s=o.lastBaseUpdate,l=o.shared.pending;if(l!==null){o.shared.pending=null;var h=l,p=h.next;h.next=null,s===null?a=p:s.next=p,s=h;var f=t.alternate;f!==null&&(f=f.updateQueue,l=f.lastBaseUpdate,l!==s&&(l===null?f.firstBaseUpdate=p:l.next=p,f.lastBaseUpdate=h))}if(a!==null){var g=o.baseState;s=0,f=p=h=null,l=a;do{var b=l.lane,z=l.eventTime;if((i&b)===b){f!==null&&(f=f.next={eventTime:z,lane:0,tag:l.tag,payload:l.payload,callback:l.callback,next:null});t:{var M=t,I=l;switch(b=r,z=n,I.tag){case 1:if(M=I.payload,typeof M=="function"){g=M.call(z,g,b);break t}g=M;break t;case 3:M.flags=M.flags&-65537|128;case 0:if(M=I.payload,b=typeof M=="function"?M.call(z,g,b):M,b==null)break t;g=Or({},g,b);break t;case 2:Is=!0}}l.callback!==null&&l.lane!==0&&(t.flags|=64,b=o.effects,b===null?o.effects=[l]:b.push(l))}else z={eventTime:z,lane:b,tag:l.tag,payload:l.payload,callback:l.callback,next:null},f===null?(p=f=z,h=g):f=f.next=z,s|=b;if(l=l.next,l===null){if(l=o.shared.pending,l===null)break;b=l,l=b.next,b.next=null,o.lastBaseUpdate=b,o.shared.pending=null}}while(1);if(f===null&&(h=g),o.baseState=h,o.firstBaseUpdate=p,o.lastBaseUpdate=f,r=o.shared.interleaved,r!==null){o=r;do s|=o.lane,o=o.next;while(o!==r)}else a===null&&(o.shared.lanes=0);b0|=s,t.lanes=s,t.memoizedState=g}}function MM(t,r,n){if(t=r.effects,r.effects=null,t!==null)for(r=0;rn?n:4,t(!0);var i=Vf.transition;Vf.transition={};try{t(!1),r()}finally{ur=n,Vf.transition=i}}function TH(){return j2().memoizedState}function jK(t,r,n){var i=qs(t);if(n={lane:i,action:n,hasEagerState:!1,eagerState:null,next:null},VH(t))FH(r,n);else if(n=mH(t,r,n,i),n!==null){var o=gn();go(n,t,i,o),RH(n,r,i)}}function GK(t,r,n){var i=qs(t),o={lane:i,action:n,hasEagerState:!1,eagerState:null,next:null};if(VH(t))FH(r,o);else{var a=t.alternate;if(t.lanes===0&&(a===null||a.lanes===0)&&(a=r.lastRenderedReducer,a!==null))try{var s=r.lastRenderedState,l=a(s,n);if(o.hasEagerState=!0,o.eagerState=l,mo(l,s)){var h=r.interleaved;h===null?(o.next=o,bx(r)):(o.next=h.next,h.next=o),r.interleaved=o;return}}catch{}finally{}n=mH(t,r,o,i),n!==null&&(o=gn(),go(n,t,i,o),RH(n,r,i))}}function VH(t){var r=t.alternate;return t===Fr||r!==null&&r===Fr}function FH(t,r){kc=yu=!0;var n=t.pending;n===null?r.next=r:(r.next=n.next,n.next=r),t.pending=r}function RH(t,r,n){if(n&4194240){var i=r.lanes;i&=t.pendingLanes,n|=i,r.lanes=n,ax(t,n)}}var xu={readContext:W2,useCallback:Wi,useContext:Wi,useEffect:Wi,useImperativeHandle:Wi,useInsertionEffect:Wi,useLayoutEffect:Wi,useMemo:Wi,useReducer:Wi,useRef:Wi,useState:Wi,useDebugValue:Wi,useDeferredValue:Wi,useTransition:Wi,useMutableSource:Wi,useSyncExternalStore:Wi,useId:Wi,unstable_isNewReconciler:!1},UK={readContext:W2,useCallback:function(t,r){return Ro().memoizedState=[t,r===void 0?null:r],t},useContext:W2,useEffect:_M,useImperativeHandle:function(t,r,n){return n=n!=null?n.concat([t]):null,f7(4194308,4,EH.bind(null,r,t),n)},useLayoutEffect:function(t,r){return f7(4194308,4,t,r)},useInsertionEffect:function(t,r){return f7(4,2,t,r)},useMemo:function(t,r){var n=Ro();return r=r===void 0?null:r,t=t(),n.memoizedState=[t,r],t},useReducer:function(t,r,n){var i=Ro();return r=n!==void 0?n(r):r,i.memoizedState=i.baseState=r,t={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:t,lastRenderedState:r},i.queue=t,t=t.dispatch=jK.bind(null,Fr,t),[i.memoizedState,t]},useRef:function(t){var r=Ro();return t={current:t},r.memoizedState=t},useState:kM,useDebugValue:Lx,useDeferredValue:function(t){return Ro().memoizedState=t},useTransition:function(){var t=kM(!1),r=t[0];return t=WK.bind(null,t[1]),Ro().memoizedState=t,[r,t]},useMutableSource:function(){},useSyncExternalStore:function(t,r,n){var i=Fr,o=Ro();if(Ir){if(n===void 0)throw Error(be(407));n=n()}else{if(n=r(),zi===null)throw Error(be(349));x0&30||CH(i,r,n)}o.memoizedState=n;var a={value:n,getSnapshot:r};return o.queue=a,_M(zH.bind(null,i,a,t),[t]),i.flags|=2048,t8(9,SH.bind(null,i,a,n,r),void 0,null),n},useId:function(){var t=Ro(),r=zi.identifierPrefix;if(Ir){var n=Fa,i=Va;n=(i&~(1<<32-vo(i)-1)).toString(32)+n,r=":"+r+"R"+n,n=Jc++,0")&&(h=h.replace("",t.displayName)),h}while(1<=s&&0<=l);break}}}finally{xf=!1,Error.prepareStackTrace=n}return(t=t?t.displayName||t.name:"")?K6(t):""}function SX(t){switch(t.tag){case 5:return K6(t.type);case 16:return K6("Lazy");case 13:return K6("Suspense");case 19:return K6("SuspenseList");case 0:case 2:case 15:return t=bf(t.type,!1),t;case 11:return t=bf(t.type.render,!1),t;case 1:return t=bf(t.type,!0),t;default:return""}}function tg(t){if(t==null)return null;if(typeof t=="function")return t.displayName||t.name||null;if(typeof t=="string")return t;switch(t){case E3:return"Fragment";case L3:return"Portal";case Zv:return"Profiler";case rx:return"StrictMode";case Jv:return"Suspense";case Qv:return"SuspenseList"}if(typeof t=="object")switch(t.$$typeof){case xI:return(t.displayName||"Context")+".Consumer";case yI:return(t._context.displayName||"Context")+".Provider";case ix:var r=t.render;return t=t.displayName,t||(t=r.displayName||r.name||"",t=t!==""?"ForwardRef("+t+")":"ForwardRef"),t;case nx:return r=t.displayName||null,r!==null?r:tg(t.type)||"Memo";case Es:r=t._payload,t=t._init;try{return tg(t(r))}catch{}}return null}function zX(t){var r=t.type;switch(t.tag){case 24:return"Cache";case 9:return(r.displayName||"Context")+".Consumer";case 10:return(r._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return t=r.render,t=t.displayName||t.name||"",r.displayName||(t!==""?"ForwardRef("+t+")":"ForwardRef");case 7:return"Fragment";case 5:return r;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return tg(r);case 8:return r===rx?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof r=="function")return r.displayName||r.name||null;if(typeof r=="string")return r}return null}function r4(t){switch(typeof t){case"boolean":case"number":case"string":case"undefined":return t;case"object":return t;default:return""}}function wI(t){var r=t.type;return(t=t.nodeName)&&t.toLowerCase()==="input"&&(r==="checkbox"||r==="radio")}function MX(t){var r=wI(t)?"checked":"value",n=Object.getOwnPropertyDescriptor(t.constructor.prototype,r),i=""+t[r];if(!t.hasOwnProperty(r)&&typeof n<"u"&&typeof n.get=="function"&&typeof n.set=="function"){var o=n.get,a=n.set;return Object.defineProperty(t,r,{configurable:!0,get:function(){return o.call(this)},set:function(s){i=""+s,a.call(this,s)}}),Object.defineProperty(t,r,{enumerable:n.enumerable}),{getValue:function(){return i},setValue:function(s){i=""+s},stopTracking:function(){t._valueTracker=null,delete t[r]}}}}function ch(t){t._valueTracker||(t._valueTracker=MX(t))}function CI(t){if(!t)return!1;var r=t._valueTracker;if(!r)return!0;var n=r.getValue(),i="";return t&&(i=wI(t)?t.checked?"true":"false":t.value),t=i,t!==n?(r.setValue(t),!0):!1}function eu(t){if(t=t||(typeof document<"u"?document:void 0),typeof t>"u")return null;try{return t.activeElement||t.body}catch{return t.body}}function eg(t,r){var n=r.checked;return Fr({},r,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??t._wrapperState.initialChecked})}function Yz(t,r){var n=r.defaultValue==null?"":r.defaultValue,i=r.checked!=null?r.checked:r.defaultChecked;n=r4(r.value!=null?r.value:n),t._wrapperState={initialChecked:i,initialValue:n,controlled:r.type==="checkbox"||r.type==="radio"?r.checked!=null:r.value!=null}}function SI(t,r){r=r.checked,r!=null&&ex(t,"checked",r,!1)}function rg(t,r){SI(t,r);var n=r4(r.value),i=r.type;if(n!=null)i==="number"?(n===0&&t.value===""||t.value!=n)&&(t.value=""+n):t.value!==""+n&&(t.value=""+n);else if(i==="submit"||i==="reset"){t.removeAttribute("value");return}r.hasOwnProperty("value")?ig(t,r.type,n):r.hasOwnProperty("defaultValue")&&ig(t,r.type,r4(r.defaultValue)),r.checked==null&&r.defaultChecked!=null&&(t.defaultChecked=!!r.defaultChecked)}function Xz(t,r,n){if(r.hasOwnProperty("value")||r.hasOwnProperty("defaultValue")){var i=r.type;if(!(i!=="submit"&&i!=="reset"||r.value!==void 0&&r.value!==null))return;r=""+t._wrapperState.initialValue,n||r===t.value||(t.value=r),t.defaultValue=r}n=t.name,n!==""&&(t.name=""),t.defaultChecked=!!t._wrapperState.initialChecked,n!==""&&(t.name=n)}function ig(t,r,n){(r!=="number"||eu(t.ownerDocument)!==t)&&(n==null?t.defaultValue=""+t._wrapperState.initialValue:t.defaultValue!==""+n&&(t.defaultValue=""+n))}var q6=Array.isArray;function J3(t,r,n,i){if(t=t.options,r){r={};for(var o=0;o"+r.valueOf().toString()+"",r=hh.firstChild;t.firstChild;)t.removeChild(t.firstChild);for(;r.firstChild;)t.appendChild(r.firstChild)}});function Bc(t,r){if(r){var n=t.firstChild;if(n&&n===t.lastChild&&n.nodeType===3){n.nodeValue=r;return}}t.textContent=r}var wc={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},kX=["Webkit","ms","Moz","O"];Object.keys(wc).forEach(function(t){kX.forEach(function(r){r=r+t.charAt(0).toUpperCase()+t.substring(1),wc[r]=wc[t]})});function _I(t,r,n){return r==null||typeof r=="boolean"||r===""?"":n||typeof r!="number"||r===0||wc.hasOwnProperty(t)&&wc[t]?(""+r).trim():r+"px"}function AI(t,r){t=t.style;for(var n in r)if(r.hasOwnProperty(n)){var i=n.indexOf("--")===0,o=_I(n,r[n],i);n==="float"&&(n="cssFloat"),i?t.setProperty(n,o):t[n]=o}}var _X=Fr({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function ag(t,r){if(r){if(_X[t]&&(r.children!=null||r.dangerouslySetInnerHTML!=null))throw Error(be(137,t));if(r.dangerouslySetInnerHTML!=null){if(r.children!=null)throw Error(be(60));if(typeof r.dangerouslySetInnerHTML!="object"||!("__html"in r.dangerouslySetInnerHTML))throw Error(be(61))}if(r.style!=null&&typeof r.style!="object")throw Error(be(62))}}function sg(t,r){if(t.indexOf("-")===-1)return typeof r.is=="string";switch(t){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var lg=null;function ox(t){return t=t.target||t.srcElement||window,t.correspondingUseElement&&(t=t.correspondingUseElement),t.nodeType===3?t.parentNode:t}var cg=null,Q3=null,tl=null;function Zz(t){if(t=I8(t)){if(typeof cg!="function")throw Error(be(280));var r=t.stateNode;r&&(r=I9(r),cg(t.stateNode,t.type,r))}}function LI(t){Q3?tl?tl.push(t):tl=[t]:Q3=t}function EI(){if(Q3){var t=Q3,r=tl;if(tl=Q3=null,Zz(t),r)for(t=0;t>>=0,t===0?32:31-(RX(t)/OX|0)|0}var uh=64,ph=4194304;function Z6(t){switch(t&-t){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return t&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return t}}function ou(t,r){var n=t.pendingLanes;if(n===0)return 0;var i=0,o=t.suspendedLanes,a=t.pingedLanes,s=n&268435455;if(s!==0){var l=s&~o;l!==0?i=Z6(l):(a&=s,a!==0&&(i=Z6(a)))}else s=n&~o,s!==0?i=Z6(s):a!==0&&(i=Z6(a));if(i===0)return 0;if(r!==0&&r!==i&&!(r&o)&&(o=i&-i,a=r&-r,o>=a||o===16&&(a&4194240)!==0))return r;if(i&4&&(i|=n&16),r=t.entangledLanes,r!==0)for(t=t.entanglements,r&=i;0n;n++)r.push(t);return r}function L8(t,r,n){t.pendingLanes|=r,r!==536870912&&(t.suspendedLanes=0,t.pingedLanes=0),t=t.eventTimes,r=31-ho(r),t[r]=n}function WX(t,r){var n=t.pendingLanes&~r;t.pendingLanes=r,t.suspendedLanes=0,t.pingedLanes=0,t.expiredLanes&=r,t.mutableReadLanes&=r,t.entangledLanes&=r,r=t.entanglements;var i=t.eventTimes;for(t=t.expirationTimes;0=Sc),aM=String.fromCharCode(32),sM=!1;function qI(t,r){switch(t){case"keyup":return mK.indexOf(r.keyCode)!==-1;case"keydown":return r.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function ZI(t){return t=t.detail,typeof t=="object"&&"data"in t?t.data:null}var I3=!1;function xK(t,r){switch(t){case"compositionend":return ZI(r);case"keypress":return r.which!==32?null:(sM=!0,aM);case"textInput":return t=r.data,t===aM&&sM?null:t;default:return null}}function bK(t,r){if(I3)return t==="compositionend"||!dx&&qI(t,r)?(t=XI(),h7=hx=Fs=null,I3=!1,t):null;switch(t){case"paste":return null;case"keypress":if(!(r.ctrlKey||r.altKey||r.metaKey)||r.ctrlKey&&r.altKey){if(r.char&&1=r)return{node:n,offset:r-t};t=i}t:{for(;n;){if(n.nextSibling){n=n.nextSibling;break t}n=n.parentNode}n=void 0}n=uM(n)}}function eH(t,r){return t&&r?t===r?!0:t&&t.nodeType===3?!1:r&&r.nodeType===3?eH(t,r.parentNode):"contains"in t?t.contains(r):t.compareDocumentPosition?!!(t.compareDocumentPosition(r)&16):!1:!1}function rH(){for(var t=window,r=eu();r instanceof t.HTMLIFrameElement;){try{var n=typeof r.contentWindow.location.href=="string"}catch{n=!1}if(n)t=r.contentWindow;else break;r=eu(t.document)}return r}function fx(t){var r=t&&t.nodeName&&t.nodeName.toLowerCase();return r&&(r==="input"&&(t.type==="text"||t.type==="search"||t.type==="tel"||t.type==="url"||t.type==="password")||r==="textarea"||t.contentEditable==="true")}function LK(t){var r=rH(),n=t.focusedElem,i=t.selectionRange;if(r!==n&&n&&n.ownerDocument&&eH(n.ownerDocument.documentElement,n)){if(i!==null&&fx(n)){if(r=i.start,t=i.end,t===void 0&&(t=r),"selectionStart"in n)n.selectionStart=r,n.selectionEnd=Math.min(t,n.value.length);else if(t=(r=n.ownerDocument||document)&&r.defaultView||window,t.getSelection){t=t.getSelection();var o=n.textContent.length,a=Math.min(i.start,o);i=i.end===void 0?a:Math.min(i.end,o),!t.extend&&a>i&&(o=i,i=a,a=o),o=pM(n,a);var s=pM(n,i);o&&s&&(t.rangeCount!==1||t.anchorNode!==o.node||t.anchorOffset!==o.offset||t.focusNode!==s.node||t.focusOffset!==s.offset)&&(r=r.createRange(),r.setStart(o.node,o.offset),t.removeAllRanges(),a>i?(t.addRange(r),t.extend(s.node,s.offset)):(r.setEnd(s.node,s.offset),t.addRange(r)))}}for(r=[],t=n;t=t.parentNode;)t.nodeType===1&&r.push({element:t,left:t.scrollLeft,top:t.scrollTop});for(typeof n.focus=="function"&&n.focus(),n=0;n=document.documentMode,H3=null,vg=null,Mc=null,gg=!1;function dM(t,r,n){var i=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;gg||H3==null||H3!==eu(i)||(i=H3,"selectionStart"in i&&fx(i)?i={start:i.selectionStart,end:i.selectionEnd}:(i=(i.ownerDocument&&i.ownerDocument.defaultView||window).getSelection(),i={anchorNode:i.anchorNode,anchorOffset:i.anchorOffset,focusNode:i.focusNode,focusOffset:i.focusOffset}),Mc&&Uc(Mc,i)||(Mc=i,i=lu(vg,"onSelect"),0T3||(t.current=Cg[T3],Cg[T3]=null,T3--)}function Cr(t,r){T3++,Cg[T3]=t.current,t.current=r}var i4={},qi=g4(i4),Dn=g4(!1),m0=i4;function hl(t,r){var n=t.type.contextTypes;if(!n)return i4;var i=t.stateNode;if(i&&i.__reactInternalMemoizedUnmaskedChildContext===r)return i.__reactInternalMemoizedMaskedChildContext;var o={},a;for(a in n)o[a]=r[a];return i&&(t=t.stateNode,t.__reactInternalMemoizedUnmaskedChildContext=r,t.__reactInternalMemoizedMaskedChildContext=o),o}function Pn(t){return t=t.childContextTypes,t!=null}function hu(){Mr(Dn),Mr(qi)}function bM(t,r,n){if(qi.current!==i4)throw Error(be(168));Cr(qi,r),Cr(Dn,n)}function uH(t,r,n){var i=t.stateNode;if(r=r.childContextTypes,typeof i.getChildContext!="function")return n;i=i.getChildContext();for(var o in i)if(!(o in r))throw Error(be(108,zX(t)||"Unknown",o));return Fr({},n,i)}function uu(t){return t=(t=t.stateNode)&&t.__reactInternalMemoizedMergedChildContext||i4,m0=qi.current,Cr(qi,t),Cr(Dn,Dn.current),!0}function wM(t,r,n){var i=t.stateNode;if(!i)throw Error(be(169));n?(t=uH(t,r,m0),i.__reactInternalMemoizedMergedChildContext=t,Mr(Dn),Mr(qi),Cr(qi,t)):Mr(Dn),Cr(Dn,n)}var _a=null,H9=!1,Pf=!1;function pH(t){_a===null?_a=[t]:_a.push(t)}function NK(t){H9=!0,pH(t)}function m4(){if(!Pf&&_a!==null){Pf=!0;var t=0,r=cr;try{var n=_a;for(cr=1;t>=s,o-=s,Ta=1<<32-ho(r)+o|n<K?(et=Z,Z=null):et=Z.sibling;var at=b(H,Z,R[K],W);if(at===null){Z===null&&(Z=et);break}t&&Z&&at.alternate===null&&r(H,Z),E=a(at,E,K),G===null?$=at:G.sibling=at,G=at,Z=et}if(K===R.length)return n(H,Z),Lr&&j4(H,K),$;if(Z===null){for(;KK?(et=Z,Z=null):et=Z.sibling;var tt=b(H,Z,at.value,W);if(tt===null){Z===null&&(Z=et);break}t&&Z&&tt.alternate===null&&r(H,Z),E=a(tt,E,K),G===null?$=tt:G.sibling=tt,G=tt,Z=et}if(at.done)return n(H,Z),Lr&&j4(H,K),$;if(Z===null){for(;!at.done;K++,at=R.next())at=g(H,at.value,W),at!==null&&(E=a(at,E,K),G===null?$=at:G.sibling=at,G=at);return Lr&&j4(H,K),$}for(Z=i(H,Z);!at.done;K++,at=R.next())at=z(Z,H,K,at.value,W),at!==null&&(t&&at.alternate!==null&&Z.delete(at.key===null?K:at.key),E=a(at,E,K),G===null?$=at:G.sibling=at,G=at);return t&&Z.forEach(function(ft){return r(H,ft)}),Lr&&j4(H,K),$}function F(H,E,R,W){if(typeof R=="object"&&R!==null&&R.type===E3&&R.key===null&&(R=R.props.children),typeof R=="object"&&R!==null){switch(R.$$typeof){case lh:t:{for(var $=R.key,G=E;G!==null;){if(G.key===$){if($=R.type,$===E3){if(G.tag===7){n(H,G.sibling),E=o(G,R.props.children),E.return=H,H=E;break t}}else if(G.elementType===$||typeof $=="object"&&$!==null&&$.$$typeof===Es&&zM($)===G.type){n(H,G.sibling),E=o(G,R.props),E.ref=V6(H,G,R),E.return=H,H=E;break t}n(H,G);break}else r(H,G);G=G.sibling}R.type===E3?(E=s0(R.props.children,H.mode,W,R.key),E.return=H,H=E):(W=y7(R.type,R.key,R.props,null,H.mode,W),W.ref=V6(H,E,R),W.return=H,H=W)}return s(H);case L3:t:{for(G=R.key;E!==null;){if(E.key===G)if(E.tag===4&&E.stateNode.containerInfo===R.containerInfo&&E.stateNode.implementation===R.implementation){n(H,E.sibling),E=o(E,R.children||[]),E.return=H,H=E;break t}else{n(H,E);break}else r(H,E);E=E.sibling}E=$f(R,H.mode,W),E.return=H,H=E}return s(H);case Es:return G=R._init,F(H,E,G(R._payload),W)}if(q6(R))return M(H,E,R,W);if(I6(R))return I(H,E,R,W);xh(H,R)}return typeof R=="string"&&R!==""||typeof R=="number"?(R=""+R,E!==null&&E.tag===6?(n(H,E.sibling),E=o(E,R),E.return=H,H=E):(n(H,E),E=Nf(R,H.mode,W),E.return=H,H=E),s(H)):n(H,E)}return F}var pl=gH(!0),mH=gH(!1),fu=g4(null),vu=null,R3=null,yx=null;function xx(){yx=R3=vu=null}function bx(t){var r=fu.current;Mr(fu),t._currentValue=r}function Mg(t,r,n){for(;t!==null;){var i=t.alternate;if((t.childLanes&r)!==r?(t.childLanes|=r,i!==null&&(i.childLanes|=r)):i!==null&&(i.childLanes&r)!==r&&(i.childLanes|=r),t===n)break;t=t.return}}function rl(t,r){vu=t,yx=R3=null,t=t.dependencies,t!==null&&t.firstContext!==null&&(t.lanes&r&&(In=!0),t.firstContext=null)}function O2(t){var r=t._currentValue;if(yx!==t)if(t={context:t,memoizedValue:r,next:null},R3===null){if(vu===null)throw Error(be(308));R3=t,vu.dependencies={lanes:0,firstContext:t}}else R3=R3.next=t;return r}var J4=null;function wx(t){J4===null?J4=[t]:J4.push(t)}function yH(t,r,n,i){var o=r.interleaved;return o===null?(n.next=n,wx(r)):(n.next=o.next,o.next=n),r.interleaved=n,Ga(t,i)}function Ga(t,r){t.lanes|=r;var n=t.alternate;for(n!==null&&(n.lanes|=r),n=t,t=t.return;t!==null;)t.childLanes|=r,n=t.alternate,n!==null&&(n.childLanes|=r),n=t,t=t.return;return n.tag===3?n.stateNode:null}var Is=!1;function Cx(t){t.updateQueue={baseState:t.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function xH(t,r){t=t.updateQueue,r.updateQueue===t&&(r.updateQueue={baseState:t.baseState,firstBaseUpdate:t.firstBaseUpdate,lastBaseUpdate:t.lastBaseUpdate,shared:t.shared,effects:t.effects})}function Ra(t,r){return{eventTime:t,lane:r,tag:0,payload:null,callback:null,next:null}}function Xs(t,r,n){var i=t.updateQueue;if(i===null)return null;if(i=i.shared,R1&2){var o=i.pending;return o===null?r.next=r:(r.next=o.next,o.next=r),i.pending=r,Ga(t,n)}return o=i.interleaved,o===null?(r.next=r,wx(i)):(r.next=o.next,o.next=r),i.interleaved=r,Ga(t,n)}function p7(t,r,n){if(r=r.updateQueue,r!==null&&(r=r.shared,(n&4194240)!==0)){var i=r.lanes;i&=t.pendingLanes,n|=i,r.lanes=n,sx(t,n)}}function MM(t,r){var n=t.updateQueue,i=t.alternate;if(i!==null&&(i=i.updateQueue,n===i)){var o=null,a=null;if(n=n.firstBaseUpdate,n!==null){do{var s={eventTime:n.eventTime,lane:n.lane,tag:n.tag,payload:n.payload,callback:n.callback,next:null};a===null?o=a=s:a=a.next=s,n=n.next}while(n!==null);a===null?o=a=r:a=a.next=r}else o=a=r;n={baseState:i.baseState,firstBaseUpdate:o,lastBaseUpdate:a,shared:i.shared,effects:i.effects},t.updateQueue=n;return}t=n.lastBaseUpdate,t===null?n.firstBaseUpdate=r:t.next=r,n.lastBaseUpdate=r}function gu(t,r,n,i){var o=t.updateQueue;Is=!1;var a=o.firstBaseUpdate,s=o.lastBaseUpdate,l=o.shared.pending;if(l!==null){o.shared.pending=null;var h=l,p=h.next;h.next=null,s===null?a=p:s.next=p,s=h;var f=t.alternate;f!==null&&(f=f.updateQueue,l=f.lastBaseUpdate,l!==s&&(l===null?f.firstBaseUpdate=p:l.next=p,f.lastBaseUpdate=h))}if(a!==null){var g=o.baseState;s=0,f=p=h=null,l=a;do{var b=l.lane,z=l.eventTime;if((i&b)===b){f!==null&&(f=f.next={eventTime:z,lane:0,tag:l.tag,payload:l.payload,callback:l.callback,next:null});t:{var M=t,I=l;switch(b=r,z=n,I.tag){case 1:if(M=I.payload,typeof M=="function"){g=M.call(z,g,b);break t}g=M;break t;case 3:M.flags=M.flags&-65537|128;case 0:if(M=I.payload,b=typeof M=="function"?M.call(z,g,b):M,b==null)break t;g=Fr({},g,b);break t;case 2:Is=!0}}l.callback!==null&&l.lane!==0&&(t.flags|=64,b=o.effects,b===null?o.effects=[l]:b.push(l))}else z={eventTime:z,lane:b,tag:l.tag,payload:l.payload,callback:l.callback,next:null},f===null?(p=f=z,h=g):f=f.next=z,s|=b;if(l=l.next,l===null){if(l=o.shared.pending,l===null)break;b=l,l=b.next,b.next=null,o.lastBaseUpdate=b,o.shared.pending=null}}while(1);if(f===null&&(h=g),o.baseState=h,o.firstBaseUpdate=p,o.lastBaseUpdate=f,r=o.shared.interleaved,r!==null){o=r;do s|=o.lane,o=o.next;while(o!==r)}else a===null&&(o.shared.lanes=0);b0|=s,t.lanes=s,t.memoizedState=g}}function kM(t,r,n){if(t=r.effects,r.effects=null,t!==null)for(r=0;rn?n:4,t(!0);var i=Vf.transition;Vf.transition={};try{t(!1),r()}finally{cr=n,Vf.transition=i}}function VH(){return B2().memoizedState}function GK(t,r,n){var i=qs(t);if(n={lane:i,action:n,hasEagerState:!1,eagerState:null,next:null},FH(t))RH(r,n);else if(n=yH(t,r,n,i),n!==null){var o=fn();uo(n,t,i,o),OH(n,r,i)}}function UK(t,r,n){var i=qs(t),o={lane:i,action:n,hasEagerState:!1,eagerState:null,next:null};if(FH(t))RH(r,o);else{var a=t.alternate;if(t.lanes===0&&(a===null||a.lanes===0)&&(a=r.lastRenderedReducer,a!==null))try{var s=r.lastRenderedState,l=a(s,n);if(o.hasEagerState=!0,o.eagerState=l,po(l,s)){var h=r.interleaved;h===null?(o.next=o,wx(r)):(o.next=h.next,h.next=o),r.interleaved=o;return}}catch{}finally{}n=yH(t,r,o,i),n!==null&&(o=fn(),uo(n,t,i,o),OH(n,r,i))}}function FH(t){var r=t.alternate;return t===Tr||r!==null&&r===Tr}function RH(t,r){kc=yu=!0;var n=t.pending;n===null?r.next=r:(r.next=n.next,n.next=r),t.pending=r}function OH(t,r,n){if(n&4194240){var i=r.lanes;i&=t.pendingLanes,n|=i,r.lanes=n,sx(t,n)}}var xu={readContext:O2,useCallback:Ni,useContext:Ni,useEffect:Ni,useImperativeHandle:Ni,useInsertionEffect:Ni,useLayoutEffect:Ni,useMemo:Ni,useReducer:Ni,useRef:Ni,useState:Ni,useDebugValue:Ni,useDeferredValue:Ni,useTransition:Ni,useMutableSource:Ni,useSyncExternalStore:Ni,useId:Ni,unstable_isNewReconciler:!1},YK={readContext:O2,useCallback:function(t,r){return Vo().memoizedState=[t,r===void 0?null:r],t},useContext:O2,useEffect:AM,useImperativeHandle:function(t,r,n){return n=n!=null?n.concat([t]):null,f7(4194308,4,IH.bind(null,r,t),n)},useLayoutEffect:function(t,r){return f7(4194308,4,t,r)},useInsertionEffect:function(t,r){return f7(4,2,t,r)},useMemo:function(t,r){var n=Vo();return r=r===void 0?null:r,t=t(),n.memoizedState=[t,r],t},useReducer:function(t,r,n){var i=Vo();return r=n!==void 0?n(r):r,i.memoizedState=i.baseState=r,t={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:t,lastRenderedState:r},i.queue=t,t=t.dispatch=GK.bind(null,Tr,t),[i.memoizedState,t]},useRef:function(t){var r=Vo();return t={current:t},r.memoizedState=t},useState:_M,useDebugValue:Ex,useDeferredValue:function(t){return Vo().memoizedState=t},useTransition:function(){var t=_M(!1),r=t[0];return t=jK.bind(null,t[1]),Vo().memoizedState=t,[r,t]},useMutableSource:function(){},useSyncExternalStore:function(t,r,n){var i=Tr,o=Vo();if(Lr){if(n===void 0)throw Error(be(407));n=n()}else{if(n=r(),Si===null)throw Error(be(349));x0&30||SH(i,r,n)}o.memoizedState=n;var a={value:n,getSnapshot:r};return o.queue=a,AM(MH.bind(null,i,a,t),[t]),i.flags|=2048,t8(9,zH.bind(null,i,a,n,r),void 0,null),n},useId:function(){var t=Vo(),r=Si.identifierPrefix;if(Lr){var n=Va,i=Ta;n=(i&~(1<<32-ho(i)-1)).toString(32)+n,r=":"+r+"R"+n,n=Jc++,0<\/script>",t=t.removeChild(t.firstChild)):typeof i.is=="string"?t=s.createElement(n,{is:i.is}):(t=s.createElement(n),n==="select"&&(s=t,i.multiple?s.multiple=!0:i.size&&(s.size=i.size))):t=s.createElementNS(t,n),t[Oo]=r,t[Kc]=i,XH(t,r,!1,!1),r.stateNode=t;t:{switch(s=sg(n,i),n){case"dialog":kr("cancel",t),kr("close",t),o=i;break;case"iframe":case"object":case"embed":kr("load",t),o=i;break;case"video":case"audio":for(o=0;ovl&&(r.flags|=128,i=!0,F6(a,!1),r.lanes=4194304)}else{if(!i)if(t=mu(s),t!==null){if(r.flags|=128,i=!0,n=t.updateQueue,n!==null&&(r.updateQueue=n,r.flags|=4),F6(a,!0),a.tail===null&&a.tailMode==="hidden"&&!s.alternate&&!Ir)return ji(r),null}else 2*Jr()-a.renderingStartTime>vl&&n!==1073741824&&(r.flags|=128,i=!0,F6(a,!1),r.lanes=4194304);a.isBackwards?(s.sibling=r.child,r.child=s):(n=a.last,n!==null?n.sibling=s:r.child=s,a.last=s)}return a.tail!==null?(r=a.tail,a.rendering=r,a.tail=r.sibling,a.renderingStartTime=Jr(),r.sibling=null,n=Tr.current,Sr(Tr,i?n&1|2:n&1),r):(ji(r),null);case 22:case 23:return Tx(),i=r.memoizedState!==null,t!==null&&t.memoizedState!==null!==i&&(r.flags|=8192),i&&r.mode&1?Qn&1073741824&&(ji(r),r.subtreeFlags&6&&(r.flags|=8192)):ji(r),null;case 24:return null;case 25:return null}throw Error(be(156,r.tag))}function tq(t,r){switch(vx(r),r.tag){case 1:return Vn(r.type)&&hu(),t=r.flags,t&65536?(r.flags=t&-65537|128,r):null;case 3:return dl(),_r(Tn),_r(Ji),zx(),t=r.flags,t&65536&&!(t&128)?(r.flags=t&-65537|128,r):null;case 5:return Sx(r),null;case 13:if(_r(Tr),t=r.memoizedState,t!==null&&t.dehydrated!==null){if(r.alternate===null)throw Error(be(340));ul()}return t=r.flags,t&65536?(r.flags=t&-65537|128,r):null;case 19:return _r(Tr),null;case 4:return dl(),null;case 10:return xx(r.type._context),null;case 22:case 23:return Tx(),null;case 24:return null;default:return null}}var wh=!1,Yi=!1,eq=typeof WeakSet=="function"?WeakSet:Set,Be=null;function O3(t,r){var n=t.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(i){Wr(t,r,i)}else n.current=null}function Pg(t,r,n){try{n()}catch(i){Wr(t,r,i)}}var RM=!1;function rq(t,r){if(mg=au,t=eH(),dx(t)){if("selectionStart"in t)var n={start:t.selectionStart,end:t.selectionEnd};else t:{n=(n=t.ownerDocument)&&n.defaultView||window;var i=n.getSelection&&n.getSelection();if(i&&i.rangeCount!==0){n=i.anchorNode;var o=i.anchorOffset,a=i.focusNode;i=i.focusOffset;try{n.nodeType,a.nodeType}catch{n=null;break t}var s=0,l=-1,h=-1,p=0,f=0,g=t,b=null;e:for(;;){for(var z;g!==n||o!==0&&g.nodeType!==3||(l=s+o),g!==a||i!==0&&g.nodeType!==3||(h=s+i),g.nodeType===3&&(s+=g.nodeValue.length),(z=g.firstChild)!==null;)b=g,g=z;for(;;){if(g===t)break e;if(b===n&&++p===o&&(l=s),b===a&&++f===i&&(h=s),(z=g.nextSibling)!==null)break;g=b,b=g.parentNode}g=z}n=l===-1||h===-1?null:{start:l,end:h}}else n=null}n=n||{start:0,end:0}}else n=null;for(yg={focusedElem:t,selectionRange:n},au=!1,Be=r;Be!==null;)if(r=Be,t=r.child,(r.subtreeFlags&1028)!==0&&t!==null)t.return=r,Be=t;else for(;Be!==null;){r=Be;try{var M=r.alternate;if(r.flags&1024)switch(r.tag){case 0:case 11:case 15:break;case 1:if(M!==null){var I=M.memoizedProps,F=M.memoizedState,H=r.stateNode,E=H.getSnapshotBeforeUpdate(r.elementType===r.type?I:no(r.type,I),F);H.__reactInternalSnapshotBeforeUpdate=E}break;case 3:var R=r.stateNode.containerInfo;R.nodeType===1?R.textContent="":R.nodeType===9&&R.documentElement&&R.removeChild(R.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(be(163))}}catch(W){Wr(r,r.return,W)}if(t=r.sibling,t!==null){t.return=r.return,Be=t;break}Be=r.return}return M=RM,RM=!1,M}function _c(t,r,n){var i=r.updateQueue;if(i=i!==null?i.lastEffect:null,i!==null){var o=i=i.next;do{if((o.tag&t)===t){var a=o.destroy;o.destroy=void 0,a!==void 0&&Pg(r,n,a)}o=o.next}while(o!==i)}}function T9(t,r){if(r=r.updateQueue,r=r!==null?r.lastEffect:null,r!==null){var n=r=r.next;do{if((n.tag&t)===t){var i=n.create;n.destroy=i()}n=n.next}while(n!==r)}}function Tg(t){var r=t.ref;if(r!==null){var n=t.stateNode;switch(t.tag){case 5:t=n;break;default:t=n}typeof r=="function"?r(t):r.current=t}}function ZH(t){var r=t.alternate;r!==null&&(t.alternate=null,ZH(r)),t.child=null,t.deletions=null,t.sibling=null,t.tag===5&&(r=t.stateNode,r!==null&&(delete r[Oo],delete r[Kc],delete r[wg],delete r[RK],delete r[OK])),t.stateNode=null,t.return=null,t.dependencies=null,t.memoizedProps=null,t.memoizedState=null,t.pendingProps=null,t.stateNode=null,t.updateQueue=null}function JH(t){return t.tag===5||t.tag===3||t.tag===4}function OM(t){t:for(;;){for(;t.sibling===null;){if(t.return===null||JH(t.return))return null;t=t.return}for(t.sibling.return=t.return,t=t.sibling;t.tag!==5&&t.tag!==6&&t.tag!==18;){if(t.flags&2||t.child===null||t.tag===4)continue t;t.child.return=t,t=t.child}if(!(t.flags&2))return t.stateNode}}function Vg(t,r,n){var i=t.tag;if(i===5||i===6)t=t.stateNode,r?n.nodeType===8?n.parentNode.insertBefore(t,r):n.insertBefore(t,r):(n.nodeType===8?(r=n.parentNode,r.insertBefore(t,n)):(r=n,r.appendChild(t)),n=n._reactRootContainer,n!=null||r.onclick!==null||(r.onclick=cu));else if(i!==4&&(t=t.child,t!==null))for(Vg(t,r,n),t=t.sibling;t!==null;)Vg(t,r,n),t=t.sibling}function Fg(t,r,n){var i=t.tag;if(i===5||i===6)t=t.stateNode,r?n.insertBefore(t,r):n.appendChild(t);else if(i!==4&&(t=t.child,t!==null))for(Fg(t,r,n),t=t.sibling;t!==null;)Fg(t,r,n),t=t.sibling}var Hi=null,oo=!1;function zs(t,r,n){for(n=n.child;n!==null;)QH(t,r,n),n=n.sibling}function QH(t,r,n){if(Wo&&typeof Wo.onCommitFiberUnmount=="function")try{Wo.onCommitFiberUnmount(_9,n)}catch{}switch(n.tag){case 5:Yi||O3(n,r);case 6:var i=Hi,o=oo;Hi=null,zs(t,r,n),Hi=i,oo=o,Hi!==null&&(oo?(t=Hi,n=n.stateNode,t.nodeType===8?t.parentNode.removeChild(n):t.removeChild(n)):Hi.removeChild(n.stateNode));break;case 18:Hi!==null&&(oo?(t=Hi,n=n.stateNode,t.nodeType===8?Df(t.parentNode,n):t.nodeType===1&&Df(t,n),jc(t)):Df(Hi,n.stateNode));break;case 4:i=Hi,o=oo,Hi=n.stateNode.containerInfo,oo=!0,zs(t,r,n),Hi=i,oo=o;break;case 0:case 11:case 14:case 15:if(!Yi&&(i=n.updateQueue,i!==null&&(i=i.lastEffect,i!==null))){o=i=i.next;do{var a=o,s=a.destroy;a=a.tag,s!==void 0&&(a&2||a&4)&&Pg(n,r,s),o=o.next}while(o!==i)}zs(t,r,n);break;case 1:if(!Yi&&(O3(n,r),i=n.stateNode,typeof i.componentWillUnmount=="function"))try{i.props=n.memoizedProps,i.state=n.memoizedState,i.componentWillUnmount()}catch(l){Wr(n,r,l)}zs(t,r,n);break;case 21:zs(t,r,n);break;case 22:n.mode&1?(Yi=(i=Yi)||n.memoizedState!==null,zs(t,r,n),Yi=i):zs(t,r,n);break;default:zs(t,r,n)}}function BM(t){var r=t.updateQueue;if(r!==null){t.updateQueue=null;var n=t.stateNode;n===null&&(n=t.stateNode=new eq),r.forEach(function(i){var o=uq.bind(null,t,i);n.has(i)||(n.add(i),i.then(o,o))})}}function ro(t,r){var n=r.deletions;if(n!==null)for(var i=0;io&&(o=s),i&=~a}if(i=o,i=Jr()-i,i=(120>i?120:480>i?480:1080>i?1080:1920>i?1920:3e3>i?3e3:4320>i?4320:1960*nq(i/1960))-i,10t?16:t,Rs===null)var i=!1;else{if(t=Rs,Rs=null,Cu=0,B1&6)throw Error(be(331));var o=B1;for(B1|=4,Be=t.current;Be!==null;){var a=Be,s=a.child;if(Be.flags&16){var l=a.deletions;if(l!==null){for(var h=0;hJr()-Dx?a0(t,0):Hx|=n),Fn(t,r)}function sD(t,r){r===0&&(t.mode&1?(r=ph,ph<<=1,!(ph&130023424)&&(ph=4194304)):r=1);var n=gn();t=Ua(t,r),t!==null&&(L8(t,r,n),Fn(t,n))}function hq(t){var r=t.memoizedState,n=0;r!==null&&(n=r.retryLane),sD(t,n)}function uq(t,r){var n=0;switch(t.tag){case 13:var i=t.stateNode,o=t.memoizedState;o!==null&&(n=o.retryLane);break;case 19:i=t.stateNode;break;default:throw Error(be(314))}i!==null&&i.delete(r),sD(t,n)}var lD;lD=function(t,r,n){if(t!==null)if(t.memoizedProps!==r.pendingProps||Tn.current)Dn=!0;else{if(!(t.lanes&n)&&!(r.flags&128))return Dn=!1,JK(t,r,n);Dn=!!(t.flags&131072)}else Dn=!1,Ir&&r.flags&1048576&&pH(r,du,r.index);switch(r.lanes=0,r.tag){case 2:var i=r.type;v7(t,r),t=r.pendingProps;var o=hl(r,Ji.current);rl(r,n),o=kx(null,r,i,t,o,n);var a=_x();return r.flags|=1,typeof o=="object"&&o!==null&&typeof o.render=="function"&&o.$$typeof===void 0?(r.tag=1,r.memoizedState=null,r.updateQueue=null,Vn(i)?(a=!0,uu(r)):a=!1,r.memoizedState=o.state!==null&&o.state!==void 0?o.state:null,wx(r),o.updater=P9,r.stateNode=o,o._reactInternals=r,_g(r,i,t,n),r=Eg(null,r,i,!0,a,n)):(r.tag=0,Ir&&a&&fx(r),un(null,r,o,n),r=r.child),r;case 16:i=r.elementType;t:{switch(v7(t,r),t=r.pendingProps,o=i._init,i=o(i._payload),r.type=i,o=r.tag=dq(i),t=no(i,t),o){case 0:r=Lg(null,r,i,t,n);break t;case 1:r=TM(null,r,i,t,n);break t;case 11:r=DM(null,r,i,t,n);break t;case 14:r=PM(null,r,i,no(i.type,t),n);break t}throw Error(be(306,i,""))}return r;case 0:return i=r.type,o=r.pendingProps,o=r.elementType===i?o:no(i,o),Lg(t,r,i,o,n);case 1:return i=r.type,o=r.pendingProps,o=r.elementType===i?o:no(i,o),TM(t,r,i,o,n);case 3:t:{if(GH(r),t===null)throw Error(be(387));i=r.pendingProps,a=r.memoizedState,o=a.element,yH(t,r),gu(r,i,null,n);var s=r.memoizedState;if(i=s.element,a.isDehydrated)if(a={element:i,isDehydrated:!1,cache:s.cache,pendingSuspenseBoundaries:s.pendingSuspenseBoundaries,transitions:s.transitions},r.updateQueue.baseState=a,r.memoizedState=a,r.flags&256){o=fl(Error(be(423)),r),r=VM(t,r,i,n,o);break t}else if(i!==o){o=fl(Error(be(424)),r),r=VM(t,r,i,n,o);break t}else for(i2=Ys(r.stateNode.containerInfo.firstChild),s2=r,Ir=!0,lo=null,n=gH(r,null,i,n),r.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(ul(),i===o){r=Ya(t,r,n);break t}un(t,r,i,n)}r=r.child}return r;case 5:return xH(r),t===null&&zg(r),i=r.type,o=r.pendingProps,a=t!==null?t.memoizedProps:null,s=o.children,xg(i,o)?s=null:a!==null&&xg(i,a)&&(r.flags|=32),jH(t,r),un(t,r,s,n),r.child;case 6:return t===null&&zg(r),null;case 13:return UH(t,r,n);case 4:return Cx(r,r.stateNode.containerInfo),i=r.pendingProps,t===null?r.child=pl(r,null,i,n):un(t,r,i,n),r.child;case 11:return i=r.type,o=r.pendingProps,o=r.elementType===i?o:no(i,o),DM(t,r,i,o,n);case 7:return un(t,r,r.pendingProps,n),r.child;case 8:return un(t,r,r.pendingProps.children,n),r.child;case 12:return un(t,r,r.pendingProps.children,n),r.child;case 10:t:{if(i=r.type._context,o=r.pendingProps,a=r.memoizedProps,s=o.value,Sr(fu,i._currentValue),i._currentValue=s,a!==null)if(mo(a.value,s)){if(a.children===o.children&&!Tn.current){r=Ya(t,r,n);break t}}else for(a=r.child,a!==null&&(a.return=r);a!==null;){var l=a.dependencies;if(l!==null){s=a.child;for(var h=l.firstContext;h!==null;){if(h.context===i){if(a.tag===1){h=Oa(-1,n&-n),h.tag=2;var p=a.updateQueue;if(p!==null){p=p.shared;var f=p.pending;f===null?h.next=h:(h.next=f.next,f.next=h),p.pending=h}}a.lanes|=n,h=a.alternate,h!==null&&(h.lanes|=n),Mg(a.return,n,r),l.lanes|=n;break}h=h.next}}else if(a.tag===10)s=a.type===r.type?null:a.child;else if(a.tag===18){if(s=a.return,s===null)throw Error(be(341));s.lanes|=n,l=s.alternate,l!==null&&(l.lanes|=n),Mg(s,n,r),s=a.sibling}else s=a.child;if(s!==null)s.return=a;else for(s=a;s!==null;){if(s===r){s=null;break}if(a=s.sibling,a!==null){a.return=s.return,s=a;break}s=s.return}a=s}un(t,r,o.children,n),r=r.child}return r;case 9:return o=r.type,i=r.pendingProps.children,rl(r,n),o=W2(o),i=i(o),r.flags|=1,un(t,r,i,n),r.child;case 14:return i=r.type,o=no(i,r.pendingProps),o=no(i.type,o),PM(t,r,i,o,n);case 15:return $H(t,r,r.type,r.pendingProps,n);case 17:return i=r.type,o=r.pendingProps,o=r.elementType===i?o:no(i,o),v7(t,r),r.tag=1,Vn(i)?(t=!0,uu(r)):t=!1,rl(r,n),OH(r,i,o),_g(r,i,o,n),Eg(null,r,i,!0,t,n);case 19:return YH(t,r,n);case 22:return WH(t,r,n)}throw Error(be(156,r.tag))};function cD(t,r){return VI(t,r)}function pq(t,r,n,i){this.tag=t,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=r,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=i,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function T2(t,r,n,i){return new pq(t,r,n,i)}function Fx(t){return t=t.prototype,!(!t||!t.isReactComponent)}function dq(t){if(typeof t=="function")return Fx(t)?1:0;if(t!=null){if(t=t.$$typeof,t===rx)return 11;if(t===ix)return 14}return 2}function Zs(t,r){var n=t.alternate;return n===null?(n=T2(t.tag,r,t.key,t.mode),n.elementType=t.elementType,n.type=t.type,n.stateNode=t.stateNode,n.alternate=t,t.alternate=n):(n.pendingProps=r,n.type=t.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=t.flags&14680064,n.childLanes=t.childLanes,n.lanes=t.lanes,n.child=t.child,n.memoizedProps=t.memoizedProps,n.memoizedState=t.memoizedState,n.updateQueue=t.updateQueue,r=t.dependencies,n.dependencies=r===null?null:{lanes:r.lanes,firstContext:r.firstContext},n.sibling=t.sibling,n.index=t.index,n.ref=t.ref,n}function y7(t,r,n,i,o,a){var s=2;if(i=t,typeof t=="function")Fx(t)&&(s=1);else if(typeof t=="string")s=5;else t:switch(t){case E3:return s0(n.children,o,a,r);case ex:s=8,o|=8;break;case Zv:return t=T2(12,n,r,o|2),t.elementType=Zv,t.lanes=a,t;case Jv:return t=T2(13,n,r,o),t.elementType=Jv,t.lanes=a,t;case Qv:return t=T2(19,n,r,o),t.elementType=Qv,t.lanes=a,t;case xI:return F9(n,o,a,r);default:if(typeof t=="object"&&t!==null)switch(t.$$typeof){case mI:s=10;break t;case yI:s=9;break t;case rx:s=11;break t;case ix:s=14;break t;case Es:s=16,i=null;break t}throw Error(be(130,t==null?t:typeof t,""))}return r=T2(s,n,r,o),r.elementType=t,r.type=i,r.lanes=a,r}function s0(t,r,n,i){return t=T2(7,t,i,r),t.lanes=n,t}function F9(t,r,n,i){return t=T2(22,t,i,r),t.elementType=xI,t.lanes=n,t.stateNode={isHidden:!1},t}function Nf(t,r,n){return t=T2(6,t,null,r),t.lanes=n,t}function $f(t,r,n){return r=T2(4,t.children!==null?t.children:[],t.key,r),r.lanes=n,r.stateNode={containerInfo:t.containerInfo,pendingChildren:null,implementation:t.implementation},r}function fq(t,r,n,i,o){this.tag=r,this.containerInfo=t,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=Cf(0),this.expirationTimes=Cf(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Cf(0),this.identifierPrefix=i,this.onRecoverableError=o,this.mutableSourceEagerHydrationData=null}function Rx(t,r,n,i,o,a,s,l,h){return t=new fq(t,r,n,l,h),r===1?(r=1,a===!0&&(r|=8)):r=0,a=T2(3,null,null,r),t.current=a,a.stateNode=t,a.memoizedState={element:i,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},wx(a),t}function vq(t,r,n){var i=3"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(dD)}catch(t){console.error(t)}}dD(),dI.exports=d2;var Xa=dI.exports;const Q6=_8(Xa);var XM=Xa;Kv.createRoot=XM.createRoot,Kv.hydrateRoot=XM.hydrateRoot;const fD=_.createContext(),$9=(t,r,n)=>{var a,s,l,h,p;let i=null;const o=Qi();return t==0&&(i={backgroundImage:`url(${o}${(a=r==null?void 0:r.Properties)==null?void 0:a.File})`,position:"absolute",top:n&&n.Posn&&n.Posn.length?n.Posn[0]:0,left:n&&n.Posn&&n.Posn.length?n.Posn[1]:0,backgroundRepeat:"no-repeat",height:n&&n.Size&&n.Size.length?n.Size[0]:"100%",width:n&&n.Size&&n.Size.length?n.Size[1]:"100%"}),t==1&&(i={backgroundImage:`url(${o}${(s=r==null?void 0:r.Properties)==null?void 0:s.File})`,backgroundRepeat:"repeat"}),t==2&&(i={backgroundImage:`url(${o}${(l=r==null?void 0:r.Properties)==null?void 0:l.File})`,backgroundSize:"100% 100%",backgroundRepeat:"no-repeat",backgroundPosition:"center center",display:"flex",justifyContent:"center",alignItems:"center"}),t==3&&(i={backgroundImage:`url(${o}${(h=r==null?void 0:r.Properties)==null?void 0:h.File})`,backgroundPosition:"center center",display:"flex",justifyContent:"center",alignItems:"center",backgroundRepeat:"no-repeat"}),((p=r==null?void 0:r.Properties)==null?void 0:p.Type)=="Icon"&&(i={...i,height:"32px",width:"32px",backgroundSize:"cover"}),i},bq=t=>{var r;return`${Qi()}${(r=t==null?void 0:t.Properties)==null?void 0:r.File}`},wq=t=>{let r={};const n=Object.keys(t);return n==null||n.forEach(i=>{var o,a,s,l;(((a=(o=t[i])==null?void 0:o.Properties)==null?void 0:a.Type)!=="Form"||!((l=(s=t[i])==null?void 0:s.Properties)!=null&&l.Type))&&(r[t[i].ID]=t[i])}),r},j1=t=>{let r;Array.isArray(t)?r=t&&t[1]:r=t;const n=r&&(r==null?void 0:r.split(",").map(o=>o.trim())),i={};return n==null||n.forEach(o=>{const[a,s]=o==null?void 0:o.split(":").map(h=>h.trim()),l=a==null?void 0:a.replace(/-([a-z])/g,(h,p)=>p==null?void 0:p.toUpperCase());i[l]=isNaN(s)?s:parseFloat(s)}),i},gl=(t,r)=>{var a,s,l;const n=t;function i(h,p){if(typeof h=="object"){if(h.ID===p)return h;for(const f in h){const g=i(h[f],p);if(g)return g}}else if(Array.isArray(h))for(const f of h){const g=i(f,p);if(g)return g}return null}let o=i(n,r);return o?(o=JSON.stringify(o,null,2),o=JSON.parse(o),((a=o==null?void 0:o.Properties)==null?void 0:a.Type)=="Combo"?"select":((s=o==null?void 0:o.Properties)==null?void 0:s.Type)=="Edit"||((l=o==null?void 0:o.Properties)==null?void 0:l.Type)=="Button"?"input":"span"):null},Cq=t=>Object.keys(t).map(n=>{var i;if(((i=t[n])==null?void 0:i.Properties.Type)=="TabButton")return t[n].ID}).filter(n=>n!==void 0).pop(),KM=(t,r)=>{const n=r.split(".");let i=t;for(let o=0;o{const o=(t.shiftKey?1:0)+(t.ctrlKey?2:0),a=t.currentTarget.getBoundingClientRect(),s=Math.round(t.clientX-a.left),l=Math.round(t.clientY-a.top),h=t.button,p=JSON.stringify({Event:{EventName:"MouseDown",ID:i,Info:[l,s,h,o]}});n&&n.some(g=>g[0]==="MouseDown")&&(console.log(p),r.send(p))},rr=(t,r,n,i)=>{const o=(t.shiftKey?1:0)+(t.ctrlKey?2:0),a=t.currentTarget.getBoundingClientRect(),s=Math.round(t.clientX-a.left),l=Math.round(t.clientY-a.top),h=t.button,p=JSON.stringify({Event:{EventName:"MouseUp",ID:i,Info:[l,s,h,o]}});n&&n.some(g=>g[0]==="MouseUp")&&(console.log(p),r.send(p))},mr=(t,r,n,i)=>{const o=(t.shiftKey?1:0)+(t.ctrlKey?2:0),a=t.currentTarget.getBoundingClientRect(),s=Math.round(t.clientX-a.left),l=Math.round(t.clientY-a.top),h=t.button,p=JSON.stringify({Event:{EventName:"MouseDblClick",ID:i,Info:[l,s,h,o]}});n&&n.some(g=>g[0]==="MouseDblClick")&&(console.log(p),r.send(p))},ir=(t,r,n,i)=>{const o=t.relatedTarget?t.relatedTarget.id:"",a=JSON.stringify({Event:{EventName:"MouseEnter",ID:i,Info:[o]}});n&&n.some(l=>l[0]==="MouseEnter")&&(console.log("mouseEnter",a),r.send(a))},nr=(t,r,n,i)=>{const o=t.relatedTarget?t.relatedTarget.id:"",a=JSON.stringify({Event:{EventName:"MouseLeave",ID:i,Info:[o]}});n&&n.some(l=>l[0]==="MouseLeave")&&(console.log(a),r.send(a))},or=(t,r,n,i)=>{const o=(t.shiftKey?1:0)+(t.ctrlKey?2:0),a=t.currentTarget.getBoundingClientRect(),s=Math.round(t.clientX-a.left),l=Math.round(t.clientY-a.top),h=t.buttons,p=JSON.stringify({Event:{EventName:"MouseMove",ID:i,Info:[l,s,h,o]}});n&&n.some(g=>g[0]==="MouseMove")&&r.send(p)},hr=(t,r,n,i)=>{const o=(t.shiftKey?1:0)+(t.ctrlKey?2:0),a=t.currentTarget.getBoundingClientRect(),s=Math.round(t.clientX-a.left),l=Math.round(t.clientY-a.top),h=t.buttons,p=t.deltaY,f=t.deltaMode===1?t.deltaY:-1,g=Math.sign(t.deltaY),b=JSON.stringify({Event:{EventName:"MouseWheel",ID:i,Info:[l,s,h,o,p,f,g]}});n&&n.some(M=>M[0]==="MouseWheel")&&(console.log(b),r.send(b))},In=(t,r,n,i)=>{var g;const o=Ia(),a=t!=null&&t.altKey?4:0,s=t!=null&&t.ctrlKey?2:0,l=t!=null&&t.shiftKey?1:0,h=(g=t==null?void 0:t.key)==null?void 0:g.charCodeAt(0);let p=a+s+l;n&&n.some(b=>b[0]==="KeyPress")&&(console.log(JSON.stringify({Event:{EventName:"KeyPress",ID:i,EventID:o,Info:[t.key,h,t.keyCode,p]}})),r.send(JSON.stringify({Event:{EventName:"KeyPress",ID:i,EventID:o,Info:[t.key,h,t.keyCode,p]}})))},Yr=(t,r="absolute",n=0)=>n==2?{display:"flex",flex:1,height:"100vh"}:n==1?{display:"flex"}:n=="fill"?{display:"flex",height:"100vh",flexDirection:"column",flex:1}:n==="column"?{display:"flex",flexDirection:"column",margin:"5px"}:n==="row"?{flexDirection:"row",justifyContent:"space-between",flexWrap:"wrap",gap:"5px",alignItems:"end"}:{...t!=null&&t.hasOwnProperty("Posn")?{position:"absolute"}:{position:"relative"},...(t==null?void 0:t.Size)&&{height:(t==null?void 0:t.Size)&&(t==null?void 0:t.Size[0]),width:(t==null?void 0:t.Size)&&(t==null?void 0:t.Size[1])},...(t==null?void 0:t.Posn)&&{top:(t==null?void 0:t.Posn)&&(t==null?void 0:t.Posn[0]),left:(t==null?void 0:t.Posn)&&(t==null?void 0:t.Posn[1])}},ra=t=>{const r=["ID","Properties"],n={};for(const i in t)r.includes(i)||(n[i]=t[i]);return n},_q=t=>Object.keys(t).length===0,Y1=t=>{const r=t.lastIndexOf(".");return r!==-1?t.slice(0,r):t},Aq=t=>{const r=t.lastIndexOf(".");return r!==-1?t.slice(1+r):t},Lq=t=>{const r=[],n="ABCDEFGHIJKLMNOPQRSTUVWXYZ";let i="";for(;t>0;){r.push(i);let o=1;for(let a=i.length-1;a>=0&&o;a--){const s=i[a],l=n.indexOf(s);l===n.length-1?i=i.substring(0,a)+n[0]+i.substring(a+1):(i=i.substring(0,a)+n[l+1]+i.substring(a+1),o=0)}o&&(i="A"+i),t--}return r},Ui=(t,r)=>{const n=t;function i(a,s){if(typeof a=="object"){if(a.ID===s)return a;for(const l in a){const h=i(a[l],s);if(h)return h}}else if(Array.isArray(a))for(const l of a){const h=i(l,s);if(h)return h}return null}const o=i(n,r);return o?JSON.stringify(o,null,2):null};function Eq(t){let r=[];function n(i){i&&i.ID&&i.Properties&&r.push({ID:i.ID,Properties:i.Properties});for(let o in i)typeof i[o]=="object"&&i[o]!==null&&n(i[o])}return n(t),r}const Mh=t=>{if(t<=0)return"*";let r="";for(let n=0;n{const r=t==null?void 0:t.split(".");return(r==null?void 0:r.length)>1?r[1]:t},Iq=t=>{const r=t[0].split("-").map(Number);return r.length===2?r[0]+r[1]:null},Hq=(t,r)=>{let n=0,i=-1;for(let o=0;o{try{if(!Array.isArray(t)||t.length!==3&&!(Array.isArray(t[0])&&t[0].length===3))return null;Array.isArray(t[0])&&t[0].length===3&&(t=t[0]);const[r,n,i]=t;return[r,n,i].some(o=>o<0||o>255)?null:`rgb(${r}, ${n}, ${i})`}catch(r){return console.log("rgb error",r),null}},$g=t=>{var r=new Date(1900,0,1),n=new Date((r==null?void 0:r.getTime())+t*24*60*60*1e3),i=n==null?void 0:n.toISOString().split("T")[0];return i},Wg=t=>{const[r,n,i]=t.split("-"),o=new Date(r,n-1,i),a=new Date(1900,0,1,0,0,0,0),l=(o.getTime()-a.getTime())/(24*60*60*1e3);return Math.round(l)},_2=(t,r)=>{const n=r.filter(i=>!t.includes(i));return n.length>0?{NotSupported:n}:null},ZM=t=>Object.keys(t).find(n=>{const i=t[n];return i&&i.Properties&&i.Properties.Type==="Form"}),Dq=(t,r,n,i)=>r.map((a,s)=>({index:s+1,title:a,description:n&&n[s][0],image:t&&t[i[s]-1]||""})),Qi=()=>{const t=window.location.origin,r=window.location.pathname!=="/"?window.location.pathname:"";return t+r},gD=(t,r)=>{var n;if((n=t==null?void 0:t.Properties)!=null&&n.Files){const i=t.Properties.Files;if(i){const o=i[r-1],a=t.Properties.Size;return{imageUrl:o,imageSize:a}}}return null},Pq=({data:t})=>{const r=ra(t),{Visible:n,CSS:i}=t==null?void 0:t.Properties,o=j1(i),a=Yr(t.Properties);return vt.jsx("div",{style:{display:n==0?"none":"flex",...a,...o},children:Object.keys(r).map(s=>vt.jsx(E4,{data:r[s]}))})};const w1=()=>{const{socketData:t,dataRef:r,socket:n,handleData:i,focusedElement:o,reRender:a,proceed:s,setProceed:l,proceedEventArray:h,setProceedEventArray:p,colors:f,fontScale:g,nqEvents:b,setNqEvents:z,updateCurrentEvent:M,currentEventRef:I,isDesktop:F}=_.useContext(fD);return{socketData:t,findDesiredData:$=>t==null?void 0:t.find(Z=>Z.ID==$),getObjType:$=>{var Z;const G=t==null?void 0:t.find(K=>K.ID==$);return(Z=G==null?void 0:G.Properties)==null?void 0:Z.Type},dataRef:r,socket:n,handleData:i,focusedElement:o,reRender:a,proceed:s,setProceed:l,proceedEventArray:h,setProceedEventArray:p,colors:f,findAggregatedPropertiesData:$=>{const G=t.filter(K=>K.ID===$),Z={ID:$,Properties:{}};return G.forEach(K=>{Z.Properties={...Z.Properties,...K.Properties}}),Z},fontScale:g,nqEvents:b,setNqEvents:z,findCurrentData:$=>Eq(r.current).find(Z=>Z.ID==$),updateCurrentEvent:M,currentEventRef:I,isDesktop:F}},y4=t=>{const[r,n]=_.useState({width:t==null?void 0:t.clientWidth,height:t==null?void 0:t.clientHeight});return _.useEffect(()=>{if(!t)return;const i=new ResizeObserver(o=>{const{offsetWidth:a,offsetHeight:s}=o[0].target;n({width:a,height:s})});return i.observe(t),function(){i.disconnect()}},[t]),r},Tq=()=>{const{socket:t,isDesktop:r}=w1(),[n,i]=_.useState({width:window.innerWidth,height:window.innerHeight});console.log("New height is",n);const o=_.useRef(null);return _.useEffect(()=>{const a=()=>{const s={width:window.innerWidth,height:window.innerHeight};let l=Math.round(window.devicePixelRatio*100);i(s),o.current&&clearTimeout(o.current),o.current=setTimeout(()=>{let h=JSON.stringify({DeviceCapabilities:{ViewPort:[s.height,s.width],ScreenSize:[window.screen.height,window.screen.width],DPR:l/100,PPI:200}});console.log({event:h}),t.send(h)},1e3)};return window.addEventListener("resize",a),()=>{window.removeEventListener("resize",a),o.current&&clearTimeout(o.current)}},[]),n},Vq=({title:t,data:r,style:n,customStyles:i})=>{const{socket:o}=w1();_.useEffect(()=>{const s=document.createElement("style");return s.innerHTML=` +`+a.stack}return{value:t,source:r,stack:o,digest:null}}function Of(t,r,n){return{value:t,source:null,stack:n??null,digest:r??null}}function Ag(t,r){try{console.error(r.value)}catch(n){setTimeout(function(){throw n})}}var qK=typeof WeakMap=="function"?WeakMap:Map;function NH(t,r,n){n=Ra(-1,n),n.tag=3,n.payload={element:null};var i=r.value;return n.callback=function(){wu||(wu=!0,Rg=i),Ag(t,r)},n}function $H(t,r,n){n=Ra(-1,n),n.tag=3;var i=t.type.getDerivedStateFromError;if(typeof i=="function"){var o=r.value;n.payload=function(){return i(o)},n.callback=function(){Ag(t,r)}}var a=t.stateNode;return a!==null&&typeof a.componentDidCatch=="function"&&(n.callback=function(){Ag(t,r),typeof i!="function"&&(Ks===null?Ks=new Set([this]):Ks.add(this));var s=r.stack;this.componentDidCatch(r.value,{componentStack:s!==null?s:""})}),n}function IM(t,r,n){var i=t.pingCache;if(i===null){i=t.pingCache=new qK;var o=new Set;i.set(r,o)}else o=i.get(r),o===void 0&&(o=new Set,i.set(r,o));o.has(n)||(o.add(n),t=hq.bind(null,t,r,n),r.then(t,t))}function HM(t){do{var r;if((r=t.tag===13)&&(r=t.memoizedState,r=r!==null?r.dehydrated!==null:!0),r)return t;t=t.return}while(t!==null);return null}function DM(t,r,n,i,o){return t.mode&1?(t.flags|=65536,t.lanes=o,t):(t===r?t.flags|=65536:(t.flags|=128,n.flags|=131072,n.flags&=-52805,n.tag===1&&(n.alternate===null?n.tag=17:(r=Ra(-1,1),r.tag=2,Xs(n,r,1))),n.lanes|=1),t)}var ZK=rs.ReactCurrentOwner,In=!1;function cn(t,r,n,i){r.child=t===null?mH(r,null,n,i):pl(r,t.child,n,i)}function PM(t,r,n,i,o){n=n.render;var a=r.ref;return rl(r,o),i=_x(t,r,n,i,a,o),n=Ax(),t!==null&&!In?(r.updateQueue=t.updateQueue,r.flags&=-2053,t.lanes&=~o,Ua(t,r,o)):(Lr&&n&&vx(r),r.flags|=1,cn(t,r,i,o),r.child)}function TM(t,r,n,i,o){if(t===null){var a=n.type;return typeof a=="function"&&!Rx(a)&&a.defaultProps===void 0&&n.compare===null&&n.defaultProps===void 0?(r.tag=15,r.type=a,WH(t,r,a,i,o)):(t=y7(n.type,null,i,r,r.mode,o),t.ref=r.ref,t.return=r,r.child=t)}if(a=t.child,!(t.lanes&o)){var s=a.memoizedProps;if(n=n.compare,n=n!==null?n:Uc,n(s,i)&&t.ref===r.ref)return Ua(t,r,o)}return r.flags|=1,t=Zs(a,i),t.ref=r.ref,t.return=r,r.child=t}function WH(t,r,n,i,o){if(t!==null){var a=t.memoizedProps;if(Uc(a,i)&&t.ref===r.ref)if(In=!1,r.pendingProps=i=a,(t.lanes&o)!==0)t.flags&131072&&(In=!0);else return r.lanes=t.lanes,Ua(t,r,o)}return Lg(t,r,n,i,o)}function jH(t,r,n){var i=r.pendingProps,o=i.children,a=t!==null?t.memoizedState:null;if(i.mode==="hidden")if(!(r.mode&1))r.memoizedState={baseLanes:0,cachePool:null,transitions:null},Cr(B3,Kn),Kn|=n;else{if(!(n&1073741824))return t=a!==null?a.baseLanes|n:n,r.lanes=r.childLanes=1073741824,r.memoizedState={baseLanes:t,cachePool:null,transitions:null},r.updateQueue=null,Cr(B3,Kn),Kn|=t,null;r.memoizedState={baseLanes:0,cachePool:null,transitions:null},i=a!==null?a.baseLanes:n,Cr(B3,Kn),Kn|=i}else a!==null?(i=a.baseLanes|n,r.memoizedState=null):i=n,Cr(B3,Kn),Kn|=i;return cn(t,r,o,n),r.child}function GH(t,r){var n=r.ref;(t===null&&n!==null||t!==null&&t.ref!==n)&&(r.flags|=512,r.flags|=2097152)}function Lg(t,r,n,i,o){var a=Pn(n)?m0:qi.current;return a=hl(r,a),rl(r,o),n=_x(t,r,n,i,a,o),i=Ax(),t!==null&&!In?(r.updateQueue=t.updateQueue,r.flags&=-2053,t.lanes&=~o,Ua(t,r,o)):(Lr&&i&&vx(r),r.flags|=1,cn(t,r,n,o),r.child)}function VM(t,r,n,i,o){if(Pn(n)){var a=!0;uu(r)}else a=!1;if(rl(r,o),r.stateNode===null)v7(t,r),BH(r,n,i),_g(r,n,i,o),i=!0;else if(t===null){var s=r.stateNode,l=r.memoizedProps;s.props=l;var h=s.context,p=n.contextType;typeof p=="object"&&p!==null?p=O2(p):(p=Pn(n)?m0:qi.current,p=hl(r,p));var f=n.getDerivedStateFromProps,g=typeof f=="function"||typeof s.getSnapshotBeforeUpdate=="function";g||typeof s.UNSAFE_componentWillReceiveProps!="function"&&typeof s.componentWillReceiveProps!="function"||(l!==i||h!==p)&&EM(r,s,i,p),Is=!1;var b=r.memoizedState;s.state=b,gu(r,i,s,o),h=r.memoizedState,l!==i||b!==h||Dn.current||Is?(typeof f=="function"&&(kg(r,n,f,i),h=r.memoizedState),(l=Is||LM(r,n,l,i,b,h,p))?(g||typeof s.UNSAFE_componentWillMount!="function"&&typeof s.componentWillMount!="function"||(typeof s.componentWillMount=="function"&&s.componentWillMount(),typeof s.UNSAFE_componentWillMount=="function"&&s.UNSAFE_componentWillMount()),typeof s.componentDidMount=="function"&&(r.flags|=4194308)):(typeof s.componentDidMount=="function"&&(r.flags|=4194308),r.memoizedProps=i,r.memoizedState=h),s.props=i,s.state=h,s.context=p,i=l):(typeof s.componentDidMount=="function"&&(r.flags|=4194308),i=!1)}else{s=r.stateNode,xH(t,r),l=r.memoizedProps,p=r.type===r.elementType?l:to(r.type,l),s.props=p,g=r.pendingProps,b=s.context,h=n.contextType,typeof h=="object"&&h!==null?h=O2(h):(h=Pn(n)?m0:qi.current,h=hl(r,h));var z=n.getDerivedStateFromProps;(f=typeof z=="function"||typeof s.getSnapshotBeforeUpdate=="function")||typeof s.UNSAFE_componentWillReceiveProps!="function"&&typeof s.componentWillReceiveProps!="function"||(l!==g||b!==h)&&EM(r,s,i,h),Is=!1,b=r.memoizedState,s.state=b,gu(r,i,s,o);var M=r.memoizedState;l!==g||b!==M||Dn.current||Is?(typeof z=="function"&&(kg(r,n,z,i),M=r.memoizedState),(p=Is||LM(r,n,p,i,b,M,h)||!1)?(f||typeof s.UNSAFE_componentWillUpdate!="function"&&typeof s.componentWillUpdate!="function"||(typeof s.componentWillUpdate=="function"&&s.componentWillUpdate(i,M,h),typeof s.UNSAFE_componentWillUpdate=="function"&&s.UNSAFE_componentWillUpdate(i,M,h)),typeof s.componentDidUpdate=="function"&&(r.flags|=4),typeof s.getSnapshotBeforeUpdate=="function"&&(r.flags|=1024)):(typeof s.componentDidUpdate!="function"||l===t.memoizedProps&&b===t.memoizedState||(r.flags|=4),typeof s.getSnapshotBeforeUpdate!="function"||l===t.memoizedProps&&b===t.memoizedState||(r.flags|=1024),r.memoizedProps=i,r.memoizedState=M),s.props=i,s.state=M,s.context=h,i=p):(typeof s.componentDidUpdate!="function"||l===t.memoizedProps&&b===t.memoizedState||(r.flags|=4),typeof s.getSnapshotBeforeUpdate!="function"||l===t.memoizedProps&&b===t.memoizedState||(r.flags|=1024),i=!1)}return Eg(t,r,n,i,a,o)}function Eg(t,r,n,i,o,a){GH(t,r);var s=(r.flags&128)!==0;if(!i&&!s)return o&&wM(r,n,!1),Ua(t,r,a);i=r.stateNode,ZK.current=r;var l=s&&typeof n.getDerivedStateFromError!="function"?null:i.render();return r.flags|=1,t!==null&&s?(r.child=pl(r,t.child,null,a),r.child=pl(r,null,l,a)):cn(t,r,l,a),r.memoizedState=i.state,o&&wM(r,n,!0),r.child}function UH(t){var r=t.stateNode;r.pendingContext?bM(t,r.pendingContext,r.pendingContext!==r.context):r.context&&bM(t,r.context,!1),Sx(t,r.containerInfo)}function FM(t,r,n,i,o){return ul(),mx(o),r.flags|=256,cn(t,r,n,i),r.child}var Ig={dehydrated:null,treeContext:null,retryLane:0};function Hg(t){return{baseLanes:t,cachePool:null,transitions:null}}function YH(t,r,n){var i=r.pendingProps,o=Dr.current,a=!1,s=(r.flags&128)!==0,l;if((l=s)||(l=t!==null&&t.memoizedState===null?!1:(o&2)!==0),l?(a=!0,r.flags&=-129):(t===null||t.memoizedState!==null)&&(o|=1),Cr(Dr,o&1),t===null)return zg(r),t=r.memoizedState,t!==null&&(t=t.dehydrated,t!==null)?(r.mode&1?t.data==="$!"?r.lanes=8:r.lanes=1073741824:r.lanes=1,null):(s=i.children,t=i.fallback,a?(i=r.mode,a=r.child,s={mode:"hidden",children:s},!(i&1)&&a!==null?(a.childLanes=0,a.pendingProps=s):a=F9(s,i,0,null),t=s0(t,i,n,null),a.return=r,t.return=r,a.sibling=t,r.child=a,r.child.memoizedState=Hg(n),r.memoizedState=Ig,t):Ix(r,s));if(o=t.memoizedState,o!==null&&(l=o.dehydrated,l!==null))return JK(t,r,s,i,l,o,n);if(a){a=i.fallback,s=r.mode,o=t.child,l=o.sibling;var h={mode:"hidden",children:i.children};return!(s&1)&&r.child!==o?(i=r.child,i.childLanes=0,i.pendingProps=h,r.deletions=null):(i=Zs(o,h),i.subtreeFlags=o.subtreeFlags&14680064),l!==null?a=Zs(l,a):(a=s0(a,s,n,null),a.flags|=2),a.return=r,i.return=r,i.sibling=a,r.child=i,i=a,a=r.child,s=t.child.memoizedState,s=s===null?Hg(n):{baseLanes:s.baseLanes|n,cachePool:null,transitions:s.transitions},a.memoizedState=s,a.childLanes=t.childLanes&~n,r.memoizedState=Ig,i}return a=t.child,t=a.sibling,i=Zs(a,{mode:"visible",children:i.children}),!(r.mode&1)&&(i.lanes=n),i.return=r,i.sibling=null,t!==null&&(n=r.deletions,n===null?(r.deletions=[t],r.flags|=16):n.push(t)),r.child=i,r.memoizedState=null,i}function Ix(t,r){return r=F9({mode:"visible",children:r},t.mode,0,null),r.return=t,t.child=r}function bh(t,r,n,i){return i!==null&&mx(i),pl(r,t.child,null,n),t=Ix(r,r.pendingProps.children),t.flags|=2,r.memoizedState=null,t}function JK(t,r,n,i,o,a,s){if(n)return r.flags&256?(r.flags&=-257,i=Of(Error(be(422))),bh(t,r,s,i)):r.memoizedState!==null?(r.child=t.child,r.flags|=128,null):(a=i.fallback,o=r.mode,i=F9({mode:"visible",children:i.children},o,0,null),a=s0(a,o,s,null),a.flags|=2,i.return=r,a.return=r,i.sibling=a,r.child=i,r.mode&1&&pl(r,t.child,null,s),r.child.memoizedState=Hg(s),r.memoizedState=Ig,a);if(!(r.mode&1))return bh(t,r,s,null);if(o.data==="$!"){if(i=o.nextSibling&&o.nextSibling.dataset,i)var l=i.dgst;return i=l,a=Error(be(419)),i=Of(a,i,void 0),bh(t,r,s,i)}if(l=(s&t.childLanes)!==0,In||l){if(i=Si,i!==null){switch(s&-s){case 4:o=2;break;case 16:o=8;break;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:o=32;break;case 536870912:o=268435456;break;default:o=0}o=o&(i.suspendedLanes|s)?0:o,o!==0&&o!==a.retryLane&&(a.retryLane=o,Ga(t,o),uo(i,t,o,-1))}return Fx(),i=Of(Error(be(421))),bh(t,r,s,i)}return o.data==="$?"?(r.flags|=128,r.child=t.child,r=uq.bind(null,t),o._reactRetry=r,null):(t=a.treeContext,Qn=Ys(o.nextSibling),i2=r,Lr=!0,no=null,t!==null&&(A2[L2++]=Ta,A2[L2++]=Va,A2[L2++]=y0,Ta=t.id,Va=t.overflow,y0=r),r=Ix(r,i.children),r.flags|=4096,r)}function RM(t,r,n){t.lanes|=r;var i=t.alternate;i!==null&&(i.lanes|=r),Mg(t.return,r,n)}function Bf(t,r,n,i,o){var a=t.memoizedState;a===null?t.memoizedState={isBackwards:r,rendering:null,renderingStartTime:0,last:i,tail:n,tailMode:o}:(a.isBackwards=r,a.rendering=null,a.renderingStartTime=0,a.last=i,a.tail=n,a.tailMode=o)}function XH(t,r,n){var i=r.pendingProps,o=i.revealOrder,a=i.tail;if(cn(t,r,i.children,n),i=Dr.current,i&2)i=i&1|2,r.flags|=128;else{if(t!==null&&t.flags&128)t:for(t=r.child;t!==null;){if(t.tag===13)t.memoizedState!==null&&RM(t,n,r);else if(t.tag===19)RM(t,n,r);else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===r)break t;for(;t.sibling===null;){if(t.return===null||t.return===r)break t;t=t.return}t.sibling.return=t.return,t=t.sibling}i&=1}if(Cr(Dr,i),!(r.mode&1))r.memoizedState=null;else switch(o){case"forwards":for(n=r.child,o=null;n!==null;)t=n.alternate,t!==null&&mu(t)===null&&(o=n),n=n.sibling;n=o,n===null?(o=r.child,r.child=null):(o=n.sibling,n.sibling=null),Bf(r,!1,o,n,a);break;case"backwards":for(n=null,o=r.child,r.child=null;o!==null;){if(t=o.alternate,t!==null&&mu(t)===null){r.child=o;break}t=o.sibling,o.sibling=n,n=o,o=t}Bf(r,!0,n,null,a);break;case"together":Bf(r,!1,null,null,void 0);break;default:r.memoizedState=null}return r.child}function v7(t,r){!(r.mode&1)&&t!==null&&(t.alternate=null,r.alternate=null,r.flags|=2)}function Ua(t,r,n){if(t!==null&&(r.dependencies=t.dependencies),b0|=r.lanes,!(n&r.childLanes))return null;if(t!==null&&r.child!==t.child)throw Error(be(153));if(r.child!==null){for(t=r.child,n=Zs(t,t.pendingProps),r.child=n,n.return=r;t.sibling!==null;)t=t.sibling,n=n.sibling=Zs(t,t.pendingProps),n.return=r;n.sibling=null}return r.child}function QK(t,r,n){switch(r.tag){case 3:UH(r),ul();break;case 5:bH(r);break;case 1:Pn(r.type)&&uu(r);break;case 4:Sx(r,r.stateNode.containerInfo);break;case 10:var i=r.type._context,o=r.memoizedProps.value;Cr(fu,i._currentValue),i._currentValue=o;break;case 13:if(i=r.memoizedState,i!==null)return i.dehydrated!==null?(Cr(Dr,Dr.current&1),r.flags|=128,null):n&r.child.childLanes?YH(t,r,n):(Cr(Dr,Dr.current&1),t=Ua(t,r,n),t!==null?t.sibling:null);Cr(Dr,Dr.current&1);break;case 19:if(i=(n&r.childLanes)!==0,t.flags&128){if(i)return XH(t,r,n);r.flags|=128}if(o=r.memoizedState,o!==null&&(o.rendering=null,o.tail=null,o.lastEffect=null),Cr(Dr,Dr.current),i)break;return null;case 22:case 23:return r.lanes=0,jH(t,r,n)}return Ua(t,r,n)}var KH,Dg,qH,ZH;KH=function(t,r){for(var n=r.child;n!==null;){if(n.tag===5||n.tag===6)t.appendChild(n.stateNode);else if(n.tag!==4&&n.child!==null){n.child.return=n,n=n.child;continue}if(n===r)break;for(;n.sibling===null;){if(n.return===null||n.return===r)return;n=n.return}n.sibling.return=n.return,n=n.sibling}};Dg=function(){};qH=function(t,r,n,i){var o=t.memoizedProps;if(o!==i){t=r.stateNode,Q4($o.current);var a=null;switch(n){case"input":o=eg(t,o),i=eg(t,i),a=[];break;case"select":o=Fr({},o,{value:void 0}),i=Fr({},i,{value:void 0}),a=[];break;case"textarea":o=ng(t,o),i=ng(t,i),a=[];break;default:typeof o.onClick!="function"&&typeof i.onClick=="function"&&(t.onclick=cu)}ag(n,i);var s;n=null;for(p in o)if(!i.hasOwnProperty(p)&&o.hasOwnProperty(p)&&o[p]!=null)if(p==="style"){var l=o[p];for(s in l)l.hasOwnProperty(s)&&(n||(n={}),n[s]="")}else p!=="dangerouslySetInnerHTML"&&p!=="children"&&p!=="suppressContentEditableWarning"&&p!=="suppressHydrationWarning"&&p!=="autoFocus"&&(Oc.hasOwnProperty(p)?a||(a=[]):(a=a||[]).push(p,null));for(p in i){var h=i[p];if(l=o!=null?o[p]:void 0,i.hasOwnProperty(p)&&h!==l&&(h!=null||l!=null))if(p==="style")if(l){for(s in l)!l.hasOwnProperty(s)||h&&h.hasOwnProperty(s)||(n||(n={}),n[s]="");for(s in h)h.hasOwnProperty(s)&&l[s]!==h[s]&&(n||(n={}),n[s]=h[s])}else n||(a||(a=[]),a.push(p,n)),n=h;else p==="dangerouslySetInnerHTML"?(h=h?h.__html:void 0,l=l?l.__html:void 0,h!=null&&l!==h&&(a=a||[]).push(p,h)):p==="children"?typeof h!="string"&&typeof h!="number"||(a=a||[]).push(p,""+h):p!=="suppressContentEditableWarning"&&p!=="suppressHydrationWarning"&&(Oc.hasOwnProperty(p)?(h!=null&&p==="onScroll"&&zr("scroll",t),a||l===h||(a=[])):(a=a||[]).push(p,h))}n&&(a=a||[]).push("style",n);var p=a;(r.updateQueue=p)&&(r.flags|=4)}};ZH=function(t,r,n,i){n!==i&&(r.flags|=4)};function F6(t,r){if(!Lr)switch(t.tailMode){case"hidden":r=t.tail;for(var n=null;r!==null;)r.alternate!==null&&(n=r),r=r.sibling;n===null?t.tail=null:n.sibling=null;break;case"collapsed":n=t.tail;for(var i=null;n!==null;)n.alternate!==null&&(i=n),n=n.sibling;i===null?r||t.tail===null?t.tail=null:t.tail.sibling=null:i.sibling=null}}function $i(t){var r=t.alternate!==null&&t.alternate.child===t.child,n=0,i=0;if(r)for(var o=t.child;o!==null;)n|=o.lanes|o.childLanes,i|=o.subtreeFlags&14680064,i|=o.flags&14680064,o.return=t,o=o.sibling;else for(o=t.child;o!==null;)n|=o.lanes|o.childLanes,i|=o.subtreeFlags,i|=o.flags,o.return=t,o=o.sibling;return t.subtreeFlags|=i,t.childLanes=n,r}function tq(t,r,n){var i=r.pendingProps;switch(gx(r),r.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return $i(r),null;case 1:return Pn(r.type)&&hu(),$i(r),null;case 3:return i=r.stateNode,dl(),Mr(Dn),Mr(qi),Mx(),i.pendingContext&&(i.context=i.pendingContext,i.pendingContext=null),(t===null||t.child===null)&&(yh(r)?r.flags|=4:t===null||t.memoizedState.isDehydrated&&!(r.flags&256)||(r.flags|=1024,no!==null&&(Ng(no),no=null))),Dg(t,r),$i(r),null;case 5:zx(r);var o=Q4(Zc.current);if(n=r.type,t!==null&&r.stateNode!=null)qH(t,r,n,i,o),t.ref!==r.ref&&(r.flags|=512,r.flags|=2097152);else{if(!i){if(r.stateNode===null)throw Error(be(166));return $i(r),null}if(t=Q4($o.current),yh(r)){i=r.stateNode,n=r.type;var a=r.memoizedProps;switch(i[Fo]=r,i[Kc]=a,t=(r.mode&1)!==0,n){case"dialog":zr("cancel",i),zr("close",i);break;case"iframe":case"object":case"embed":zr("load",i);break;case"video":case"audio":for(o=0;o<\/script>",t=t.removeChild(t.firstChild)):typeof i.is=="string"?t=s.createElement(n,{is:i.is}):(t=s.createElement(n),n==="select"&&(s=t,i.multiple?s.multiple=!0:i.size&&(s.size=i.size))):t=s.createElementNS(t,n),t[Fo]=r,t[Kc]=i,KH(t,r,!1,!1),r.stateNode=t;t:{switch(s=sg(n,i),n){case"dialog":zr("cancel",t),zr("close",t),o=i;break;case"iframe":case"object":case"embed":zr("load",t),o=i;break;case"video":case"audio":for(o=0;ovl&&(r.flags|=128,i=!0,F6(a,!1),r.lanes=4194304)}else{if(!i)if(t=mu(s),t!==null){if(r.flags|=128,i=!0,n=t.updateQueue,n!==null&&(r.updateQueue=n,r.flags|=4),F6(a,!0),a.tail===null&&a.tailMode==="hidden"&&!s.alternate&&!Lr)return $i(r),null}else 2*Kr()-a.renderingStartTime>vl&&n!==1073741824&&(r.flags|=128,i=!0,F6(a,!1),r.lanes=4194304);a.isBackwards?(s.sibling=r.child,r.child=s):(n=a.last,n!==null?n.sibling=s:r.child=s,a.last=s)}return a.tail!==null?(r=a.tail,a.rendering=r,a.tail=r.sibling,a.renderingStartTime=Kr(),r.sibling=null,n=Dr.current,Cr(Dr,i?n&1|2:n&1),r):($i(r),null);case 22:case 23:return Vx(),i=r.memoizedState!==null,t!==null&&t.memoizedState!==null!==i&&(r.flags|=8192),i&&r.mode&1?Kn&1073741824&&($i(r),r.subtreeFlags&6&&(r.flags|=8192)):$i(r),null;case 24:return null;case 25:return null}throw Error(be(156,r.tag))}function eq(t,r){switch(gx(r),r.tag){case 1:return Pn(r.type)&&hu(),t=r.flags,t&65536?(r.flags=t&-65537|128,r):null;case 3:return dl(),Mr(Dn),Mr(qi),Mx(),t=r.flags,t&65536&&!(t&128)?(r.flags=t&-65537|128,r):null;case 5:return zx(r),null;case 13:if(Mr(Dr),t=r.memoizedState,t!==null&&t.dehydrated!==null){if(r.alternate===null)throw Error(be(340));ul()}return t=r.flags,t&65536?(r.flags=t&-65537|128,r):null;case 19:return Mr(Dr),null;case 4:return dl(),null;case 10:return bx(r.type._context),null;case 22:case 23:return Vx(),null;case 24:return null;default:return null}}var wh=!1,Gi=!1,rq=typeof WeakSet=="function"?WeakSet:Set,Be=null;function O3(t,r){var n=t.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(i){Nr(t,r,i)}else n.current=null}function Pg(t,r,n){try{n()}catch(i){Nr(t,r,i)}}var OM=!1;function iq(t,r){if(mg=au,t=rH(),fx(t)){if("selectionStart"in t)var n={start:t.selectionStart,end:t.selectionEnd};else t:{n=(n=t.ownerDocument)&&n.defaultView||window;var i=n.getSelection&&n.getSelection();if(i&&i.rangeCount!==0){n=i.anchorNode;var o=i.anchorOffset,a=i.focusNode;i=i.focusOffset;try{n.nodeType,a.nodeType}catch{n=null;break t}var s=0,l=-1,h=-1,p=0,f=0,g=t,b=null;e:for(;;){for(var z;g!==n||o!==0&&g.nodeType!==3||(l=s+o),g!==a||i!==0&&g.nodeType!==3||(h=s+i),g.nodeType===3&&(s+=g.nodeValue.length),(z=g.firstChild)!==null;)b=g,g=z;for(;;){if(g===t)break e;if(b===n&&++p===o&&(l=s),b===a&&++f===i&&(h=s),(z=g.nextSibling)!==null)break;g=b,b=g.parentNode}g=z}n=l===-1||h===-1?null:{start:l,end:h}}else n=null}n=n||{start:0,end:0}}else n=null;for(yg={focusedElem:t,selectionRange:n},au=!1,Be=r;Be!==null;)if(r=Be,t=r.child,(r.subtreeFlags&1028)!==0&&t!==null)t.return=r,Be=t;else for(;Be!==null;){r=Be;try{var M=r.alternate;if(r.flags&1024)switch(r.tag){case 0:case 11:case 15:break;case 1:if(M!==null){var I=M.memoizedProps,F=M.memoizedState,H=r.stateNode,E=H.getSnapshotBeforeUpdate(r.elementType===r.type?I:to(r.type,I),F);H.__reactInternalSnapshotBeforeUpdate=E}break;case 3:var R=r.stateNode.containerInfo;R.nodeType===1?R.textContent="":R.nodeType===9&&R.documentElement&&R.removeChild(R.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(be(163))}}catch(W){Nr(r,r.return,W)}if(t=r.sibling,t!==null){t.return=r.return,Be=t;break}Be=r.return}return M=OM,OM=!1,M}function _c(t,r,n){var i=r.updateQueue;if(i=i!==null?i.lastEffect:null,i!==null){var o=i=i.next;do{if((o.tag&t)===t){var a=o.destroy;o.destroy=void 0,a!==void 0&&Pg(r,n,a)}o=o.next}while(o!==i)}}function T9(t,r){if(r=r.updateQueue,r=r!==null?r.lastEffect:null,r!==null){var n=r=r.next;do{if((n.tag&t)===t){var i=n.create;n.destroy=i()}n=n.next}while(n!==r)}}function Tg(t){var r=t.ref;if(r!==null){var n=t.stateNode;switch(t.tag){case 5:t=n;break;default:t=n}typeof r=="function"?r(t):r.current=t}}function JH(t){var r=t.alternate;r!==null&&(t.alternate=null,JH(r)),t.child=null,t.deletions=null,t.sibling=null,t.tag===5&&(r=t.stateNode,r!==null&&(delete r[Fo],delete r[Kc],delete r[wg],delete r[OK],delete r[BK])),t.stateNode=null,t.return=null,t.dependencies=null,t.memoizedProps=null,t.memoizedState=null,t.pendingProps=null,t.stateNode=null,t.updateQueue=null}function QH(t){return t.tag===5||t.tag===3||t.tag===4}function BM(t){t:for(;;){for(;t.sibling===null;){if(t.return===null||QH(t.return))return null;t=t.return}for(t.sibling.return=t.return,t=t.sibling;t.tag!==5&&t.tag!==6&&t.tag!==18;){if(t.flags&2||t.child===null||t.tag===4)continue t;t.child.return=t,t=t.child}if(!(t.flags&2))return t.stateNode}}function Vg(t,r,n){var i=t.tag;if(i===5||i===6)t=t.stateNode,r?n.nodeType===8?n.parentNode.insertBefore(t,r):n.insertBefore(t,r):(n.nodeType===8?(r=n.parentNode,r.insertBefore(t,n)):(r=n,r.appendChild(t)),n=n._reactRootContainer,n!=null||r.onclick!==null||(r.onclick=cu));else if(i!==4&&(t=t.child,t!==null))for(Vg(t,r,n),t=t.sibling;t!==null;)Vg(t,r,n),t=t.sibling}function Fg(t,r,n){var i=t.tag;if(i===5||i===6)t=t.stateNode,r?n.insertBefore(t,r):n.appendChild(t);else if(i!==4&&(t=t.child,t!==null))for(Fg(t,r,n),t=t.sibling;t!==null;)Fg(t,r,n),t=t.sibling}var Ei=null,eo=!1;function zs(t,r,n){for(n=n.child;n!==null;)tD(t,r,n),n=n.sibling}function tD(t,r,n){if(No&&typeof No.onCommitFiberUnmount=="function")try{No.onCommitFiberUnmount(_9,n)}catch{}switch(n.tag){case 5:Gi||O3(n,r);case 6:var i=Ei,o=eo;Ei=null,zs(t,r,n),Ei=i,eo=o,Ei!==null&&(eo?(t=Ei,n=n.stateNode,t.nodeType===8?t.parentNode.removeChild(n):t.removeChild(n)):Ei.removeChild(n.stateNode));break;case 18:Ei!==null&&(eo?(t=Ei,n=n.stateNode,t.nodeType===8?Df(t.parentNode,n):t.nodeType===1&&Df(t,n),jc(t)):Df(Ei,n.stateNode));break;case 4:i=Ei,o=eo,Ei=n.stateNode.containerInfo,eo=!0,zs(t,r,n),Ei=i,eo=o;break;case 0:case 11:case 14:case 15:if(!Gi&&(i=n.updateQueue,i!==null&&(i=i.lastEffect,i!==null))){o=i=i.next;do{var a=o,s=a.destroy;a=a.tag,s!==void 0&&(a&2||a&4)&&Pg(n,r,s),o=o.next}while(o!==i)}zs(t,r,n);break;case 1:if(!Gi&&(O3(n,r),i=n.stateNode,typeof i.componentWillUnmount=="function"))try{i.props=n.memoizedProps,i.state=n.memoizedState,i.componentWillUnmount()}catch(l){Nr(n,r,l)}zs(t,r,n);break;case 21:zs(t,r,n);break;case 22:n.mode&1?(Gi=(i=Gi)||n.memoizedState!==null,zs(t,r,n),Gi=i):zs(t,r,n);break;default:zs(t,r,n)}}function NM(t){var r=t.updateQueue;if(r!==null){t.updateQueue=null;var n=t.stateNode;n===null&&(n=t.stateNode=new rq),r.forEach(function(i){var o=pq.bind(null,t,i);n.has(i)||(n.add(i),i.then(o,o))})}}function J2(t,r){var n=r.deletions;if(n!==null)for(var i=0;io&&(o=s),i&=~a}if(i=o,i=Kr()-i,i=(120>i?120:480>i?480:1080>i?1080:1920>i?1920:3e3>i?3e3:4320>i?4320:1960*oq(i/1960))-i,10t?16:t,Rs===null)var i=!1;else{if(t=Rs,Rs=null,Cu=0,R1&6)throw Error(be(331));var o=R1;for(R1|=4,Be=t.current;Be!==null;){var a=Be,s=a.child;if(Be.flags&16){var l=a.deletions;if(l!==null){for(var h=0;hKr()-Px?a0(t,0):Dx|=n),Tn(t,r)}function lD(t,r){r===0&&(t.mode&1?(r=ph,ph<<=1,!(ph&130023424)&&(ph=4194304)):r=1);var n=fn();t=Ga(t,r),t!==null&&(L8(t,r,n),Tn(t,n))}function uq(t){var r=t.memoizedState,n=0;r!==null&&(n=r.retryLane),lD(t,n)}function pq(t,r){var n=0;switch(t.tag){case 13:var i=t.stateNode,o=t.memoizedState;o!==null&&(n=o.retryLane);break;case 19:i=t.stateNode;break;default:throw Error(be(314))}i!==null&&i.delete(r),lD(t,n)}var cD;cD=function(t,r,n){if(t!==null)if(t.memoizedProps!==r.pendingProps||Dn.current)In=!0;else{if(!(t.lanes&n)&&!(r.flags&128))return In=!1,QK(t,r,n);In=!!(t.flags&131072)}else In=!1,Lr&&r.flags&1048576&&dH(r,du,r.index);switch(r.lanes=0,r.tag){case 2:var i=r.type;v7(t,r),t=r.pendingProps;var o=hl(r,qi.current);rl(r,n),o=_x(null,r,i,t,o,n);var a=Ax();return r.flags|=1,typeof o=="object"&&o!==null&&typeof o.render=="function"&&o.$$typeof===void 0?(r.tag=1,r.memoizedState=null,r.updateQueue=null,Pn(i)?(a=!0,uu(r)):a=!1,r.memoizedState=o.state!==null&&o.state!==void 0?o.state:null,Cx(r),o.updater=P9,r.stateNode=o,o._reactInternals=r,_g(r,i,t,n),r=Eg(null,r,i,!0,a,n)):(r.tag=0,Lr&&a&&vx(r),cn(null,r,o,n),r=r.child),r;case 16:i=r.elementType;t:{switch(v7(t,r),t=r.pendingProps,o=i._init,i=o(i._payload),r.type=i,o=r.tag=fq(i),t=to(i,t),o){case 0:r=Lg(null,r,i,t,n);break t;case 1:r=VM(null,r,i,t,n);break t;case 11:r=PM(null,r,i,t,n);break t;case 14:r=TM(null,r,i,to(i.type,t),n);break t}throw Error(be(306,i,""))}return r;case 0:return i=r.type,o=r.pendingProps,o=r.elementType===i?o:to(i,o),Lg(t,r,i,o,n);case 1:return i=r.type,o=r.pendingProps,o=r.elementType===i?o:to(i,o),VM(t,r,i,o,n);case 3:t:{if(UH(r),t===null)throw Error(be(387));i=r.pendingProps,a=r.memoizedState,o=a.element,xH(t,r),gu(r,i,null,n);var s=r.memoizedState;if(i=s.element,a.isDehydrated)if(a={element:i,isDehydrated:!1,cache:s.cache,pendingSuspenseBoundaries:s.pendingSuspenseBoundaries,transitions:s.transitions},r.updateQueue.baseState=a,r.memoizedState=a,r.flags&256){o=fl(Error(be(423)),r),r=FM(t,r,i,n,o);break t}else if(i!==o){o=fl(Error(be(424)),r),r=FM(t,r,i,n,o);break t}else for(Qn=Ys(r.stateNode.containerInfo.firstChild),i2=r,Lr=!0,no=null,n=mH(r,null,i,n),r.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(ul(),i===o){r=Ua(t,r,n);break t}cn(t,r,i,n)}r=r.child}return r;case 5:return bH(r),t===null&&zg(r),i=r.type,o=r.pendingProps,a=t!==null?t.memoizedProps:null,s=o.children,xg(i,o)?s=null:a!==null&&xg(i,a)&&(r.flags|=32),GH(t,r),cn(t,r,s,n),r.child;case 6:return t===null&&zg(r),null;case 13:return YH(t,r,n);case 4:return Sx(r,r.stateNode.containerInfo),i=r.pendingProps,t===null?r.child=pl(r,null,i,n):cn(t,r,i,n),r.child;case 11:return i=r.type,o=r.pendingProps,o=r.elementType===i?o:to(i,o),PM(t,r,i,o,n);case 7:return cn(t,r,r.pendingProps,n),r.child;case 8:return cn(t,r,r.pendingProps.children,n),r.child;case 12:return cn(t,r,r.pendingProps.children,n),r.child;case 10:t:{if(i=r.type._context,o=r.pendingProps,a=r.memoizedProps,s=o.value,Cr(fu,i._currentValue),i._currentValue=s,a!==null)if(po(a.value,s)){if(a.children===o.children&&!Dn.current){r=Ua(t,r,n);break t}}else for(a=r.child,a!==null&&(a.return=r);a!==null;){var l=a.dependencies;if(l!==null){s=a.child;for(var h=l.firstContext;h!==null;){if(h.context===i){if(a.tag===1){h=Ra(-1,n&-n),h.tag=2;var p=a.updateQueue;if(p!==null){p=p.shared;var f=p.pending;f===null?h.next=h:(h.next=f.next,f.next=h),p.pending=h}}a.lanes|=n,h=a.alternate,h!==null&&(h.lanes|=n),Mg(a.return,n,r),l.lanes|=n;break}h=h.next}}else if(a.tag===10)s=a.type===r.type?null:a.child;else if(a.tag===18){if(s=a.return,s===null)throw Error(be(341));s.lanes|=n,l=s.alternate,l!==null&&(l.lanes|=n),Mg(s,n,r),s=a.sibling}else s=a.child;if(s!==null)s.return=a;else for(s=a;s!==null;){if(s===r){s=null;break}if(a=s.sibling,a!==null){a.return=s.return,s=a;break}s=s.return}a=s}cn(t,r,o.children,n),r=r.child}return r;case 9:return o=r.type,i=r.pendingProps.children,rl(r,n),o=O2(o),i=i(o),r.flags|=1,cn(t,r,i,n),r.child;case 14:return i=r.type,o=to(i,r.pendingProps),o=to(i.type,o),TM(t,r,i,o,n);case 15:return WH(t,r,r.type,r.pendingProps,n);case 17:return i=r.type,o=r.pendingProps,o=r.elementType===i?o:to(i,o),v7(t,r),r.tag=1,Pn(i)?(t=!0,uu(r)):t=!1,rl(r,n),BH(r,i,o),_g(r,i,o,n),Eg(null,r,i,!0,t,n);case 19:return XH(t,r,n);case 22:return jH(t,r,n)}throw Error(be(156,r.tag))};function hD(t,r){return FI(t,r)}function dq(t,r,n,i){this.tag=t,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=r,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=i,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function I2(t,r,n,i){return new dq(t,r,n,i)}function Rx(t){return t=t.prototype,!(!t||!t.isReactComponent)}function fq(t){if(typeof t=="function")return Rx(t)?1:0;if(t!=null){if(t=t.$$typeof,t===ix)return 11;if(t===nx)return 14}return 2}function Zs(t,r){var n=t.alternate;return n===null?(n=I2(t.tag,r,t.key,t.mode),n.elementType=t.elementType,n.type=t.type,n.stateNode=t.stateNode,n.alternate=t,t.alternate=n):(n.pendingProps=r,n.type=t.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=t.flags&14680064,n.childLanes=t.childLanes,n.lanes=t.lanes,n.child=t.child,n.memoizedProps=t.memoizedProps,n.memoizedState=t.memoizedState,n.updateQueue=t.updateQueue,r=t.dependencies,n.dependencies=r===null?null:{lanes:r.lanes,firstContext:r.firstContext},n.sibling=t.sibling,n.index=t.index,n.ref=t.ref,n}function y7(t,r,n,i,o,a){var s=2;if(i=t,typeof t=="function")Rx(t)&&(s=1);else if(typeof t=="string")s=5;else t:switch(t){case E3:return s0(n.children,o,a,r);case rx:s=8,o|=8;break;case Zv:return t=I2(12,n,r,o|2),t.elementType=Zv,t.lanes=a,t;case Jv:return t=I2(13,n,r,o),t.elementType=Jv,t.lanes=a,t;case Qv:return t=I2(19,n,r,o),t.elementType=Qv,t.lanes=a,t;case bI:return F9(n,o,a,r);default:if(typeof t=="object"&&t!==null)switch(t.$$typeof){case yI:s=10;break t;case xI:s=9;break t;case ix:s=11;break t;case nx:s=14;break t;case Es:s=16,i=null;break t}throw Error(be(130,t==null?t:typeof t,""))}return r=I2(s,n,r,o),r.elementType=t,r.type=i,r.lanes=a,r}function s0(t,r,n,i){return t=I2(7,t,i,r),t.lanes=n,t}function F9(t,r,n,i){return t=I2(22,t,i,r),t.elementType=bI,t.lanes=n,t.stateNode={isHidden:!1},t}function Nf(t,r,n){return t=I2(6,t,null,r),t.lanes=n,t}function $f(t,r,n){return r=I2(4,t.children!==null?t.children:[],t.key,r),r.lanes=n,r.stateNode={containerInfo:t.containerInfo,pendingChildren:null,implementation:t.implementation},r}function vq(t,r,n,i,o){this.tag=r,this.containerInfo=t,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=Cf(0),this.expirationTimes=Cf(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Cf(0),this.identifierPrefix=i,this.onRecoverableError=o,this.mutableSourceEagerHydrationData=null}function Ox(t,r,n,i,o,a,s,l,h){return t=new vq(t,r,n,l,h),r===1?(r=1,a===!0&&(r|=8)):r=0,a=I2(3,null,null,r),t.current=a,a.stateNode=t,a.memoizedState={element:i,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},Cx(a),t}function gq(t,r,n){var i=3"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(fD)}catch(t){console.error(t)}}fD(),fI.exports=c2;var Ya=fI.exports;const Q6=_8(Ya);var KM=Ya;Kv.createRoot=KM.createRoot,Kv.hydrateRoot=KM.hydrateRoot;const vD=_.createContext(),$9=(t,r,n)=>{var a,s,l,h,p;let i=null;const o=Zi();return t==0&&(i={backgroundImage:`url(${o}${(a=r==null?void 0:r.Properties)==null?void 0:a.File})`,position:"absolute",top:n&&n.Posn&&n.Posn.length?n.Posn[0]:0,left:n&&n.Posn&&n.Posn.length?n.Posn[1]:0,backgroundRepeat:"no-repeat",height:n&&n.Size&&n.Size.length?n.Size[0]:"100%",width:n&&n.Size&&n.Size.length?n.Size[1]:"100%"}),t==1&&(i={backgroundImage:`url(${o}${(s=r==null?void 0:r.Properties)==null?void 0:s.File})`,backgroundRepeat:"repeat"}),t==2&&(i={backgroundImage:`url(${o}${(l=r==null?void 0:r.Properties)==null?void 0:l.File})`,backgroundSize:"100% 100%",backgroundRepeat:"no-repeat",backgroundPosition:"center center",display:"flex",justifyContent:"center",alignItems:"center"}),t==3&&(i={backgroundImage:`url(${o}${(h=r==null?void 0:r.Properties)==null?void 0:h.File})`,backgroundPosition:"center center",display:"flex",justifyContent:"center",alignItems:"center",backgroundRepeat:"no-repeat"}),((p=r==null?void 0:r.Properties)==null?void 0:p.Type)=="Icon"&&(i={...i,height:"32px",width:"32px",backgroundSize:"cover"}),i},wq=t=>{var r;return`${Zi()}${(r=t==null?void 0:t.Properties)==null?void 0:r.File}`},Cq=t=>{let r={};const n=Object.keys(t);return n==null||n.forEach(i=>{var o,a,s,l;(((a=(o=t[i])==null?void 0:o.Properties)==null?void 0:a.Type)!=="Form"||!((l=(s=t[i])==null?void 0:s.Properties)!=null&&l.Type))&&(r[t[i].ID]=t[i])}),r},$1=t=>{let r;Array.isArray(t)?r=t&&t[1]:r=t;const n=r&&(r==null?void 0:r.split(",").map(o=>o.trim())),i={};return n==null||n.forEach(o=>{const[a,s]=o==null?void 0:o.split(":").map(h=>h.trim()),l=a==null?void 0:a.replace(/-([a-z])/g,(h,p)=>p==null?void 0:p.toUpperCase());i[l]=isNaN(s)?s:parseFloat(s)}),i},gl=(t,r)=>{var a,s,l;const n=t;function i(h,p){if(typeof h=="object"){if(h.ID===p)return h;for(const f in h){const g=i(h[f],p);if(g)return g}}else if(Array.isArray(h))for(const f of h){const g=i(f,p);if(g)return g}return null}let o=i(n,r);return o?(o=JSON.stringify(o,null,2),o=JSON.parse(o),((a=o==null?void 0:o.Properties)==null?void 0:a.Type)=="Combo"?"select":((s=o==null?void 0:o.Properties)==null?void 0:s.Type)=="Edit"||((l=o==null?void 0:o.Properties)==null?void 0:l.Type)=="Button"?"input":"span"):null},Sq=t=>Object.keys(t).map(n=>{var i;if(((i=t[n])==null?void 0:i.Properties.Type)=="TabButton")return t[n].ID}).filter(n=>n!==void 0).pop(),qM=(t,r)=>{const n=r.split(".");let i=t;for(let o=0;o{const o=(t.shiftKey?1:0)+(t.ctrlKey?2:0),a=t.currentTarget.getBoundingClientRect(),s=Math.round(t.clientX-a.left),l=Math.round(t.clientY-a.top),h=t.button,p=JSON.stringify({Event:{EventName:"MouseDown",ID:i,Info:[l,s,h,o]}});n&&n.some(g=>g[0]==="MouseDown")&&(console.log(p),r.send(p))},tr=(t,r,n,i)=>{const o=(t.shiftKey?1:0)+(t.ctrlKey?2:0),a=t.currentTarget.getBoundingClientRect(),s=Math.round(t.clientX-a.left),l=Math.round(t.clientY-a.top),h=t.button,p=JSON.stringify({Event:{EventName:"MouseUp",ID:i,Info:[l,s,h,o]}});n&&n.some(g=>g[0]==="MouseUp")&&(console.log(p),r.send(p))},gr=(t,r,n,i)=>{const o=(t.shiftKey?1:0)+(t.ctrlKey?2:0),a=t.currentTarget.getBoundingClientRect(),s=Math.round(t.clientX-a.left),l=Math.round(t.clientY-a.top),h=t.button,p=JSON.stringify({Event:{EventName:"MouseDblClick",ID:i,Info:[l,s,h,o]}});n&&n.some(g=>g[0]==="MouseDblClick")&&(console.log(p),r.send(p))},er=(t,r,n,i)=>{const o=t.relatedTarget?t.relatedTarget.id:"",a=JSON.stringify({Event:{EventName:"MouseEnter",ID:i,Info:[o]}});n&&n.some(l=>l[0]==="MouseEnter")&&(console.log("mouseEnter",a),r.send(a))},rr=(t,r,n,i)=>{const o=t.relatedTarget?t.relatedTarget.id:"",a=JSON.stringify({Event:{EventName:"MouseLeave",ID:i,Info:[o]}});n&&n.some(l=>l[0]==="MouseLeave")&&(console.log(a),r.send(a))},ir=(t,r,n,i)=>{const o=(t.shiftKey?1:0)+(t.ctrlKey?2:0),a=t.currentTarget.getBoundingClientRect(),s=Math.round(t.clientX-a.left),l=Math.round(t.clientY-a.top),h=t.buttons,p=JSON.stringify({Event:{EventName:"MouseMove",ID:i,Info:[l,s,h,o]}});n&&n.some(g=>g[0]==="MouseMove")&&r.send(p)},lr=(t,r,n,i)=>{const o=(t.shiftKey?1:0)+(t.ctrlKey?2:0),a=t.currentTarget.getBoundingClientRect(),s=Math.round(t.clientX-a.left),l=Math.round(t.clientY-a.top),h=t.buttons,p=t.deltaY,f=t.deltaMode===1?t.deltaY:-1,g=Math.sign(t.deltaY),b=JSON.stringify({Event:{EventName:"MouseWheel",ID:i,Info:[l,s,h,o,p,f,g]}});n&&n.some(M=>M[0]==="MouseWheel")&&(console.log(b),r.send(b))},Ln=(t,r,n,i)=>{var g;const o=Ea(),a=t!=null&&t.altKey?4:0,s=t!=null&&t.ctrlKey?2:0,l=t!=null&&t.shiftKey?1:0,h=(g=t==null?void 0:t.key)==null?void 0:g.charCodeAt(0);let p=a+s+l;n&&n.some(b=>b[0]==="KeyPress")&&(console.log(JSON.stringify({Event:{EventName:"KeyPress",ID:i,EventID:o,Info:[t.key,h,t.keyCode,p]}})),r.send(JSON.stringify({Event:{EventName:"KeyPress",ID:i,EventID:o,Info:[t.key,h,t.keyCode,p]}})))},Gr=(t,r="absolute",n=0)=>n==2?{display:"flex",flex:1,height:"100vh"}:n==1?{display:"flex"}:n=="fill"?{display:"flex",height:"100vh",flexDirection:"column",flex:1}:n==="column"?{display:"flex",flexDirection:"column",margin:"5px"}:n==="row"?{flexDirection:"row",justifyContent:"space-between",flexWrap:"wrap",gap:"5px",alignItems:"end"}:{...t!=null&&t.hasOwnProperty("Posn")?{position:"absolute"}:{position:"relative"},...(t==null?void 0:t.Size)&&{height:(t==null?void 0:t.Size)&&(t==null?void 0:t.Size[0]),width:(t==null?void 0:t.Size)&&(t==null?void 0:t.Size[1])},...(t==null?void 0:t.Posn)&&{top:(t==null?void 0:t.Posn)&&(t==null?void 0:t.Posn[0]),left:(t==null?void 0:t.Posn)&&(t==null?void 0:t.Posn[1])}},ta=t=>{const r=["ID","Properties"],n={};for(const i in t)r.includes(i)||(n[i]=t[i]);return n},Aq=t=>Object.keys(t).length===0,G1=t=>{const r=t.lastIndexOf(".");return r!==-1?t.slice(0,r):t},Lq=t=>{const r=t.lastIndexOf(".");return r!==-1?t.slice(1+r):t},Eq=t=>{const r=[],n="ABCDEFGHIJKLMNOPQRSTUVWXYZ";let i="";for(;t>0;){r.push(i);let o=1;for(let a=i.length-1;a>=0&&o;a--){const s=i[a],l=n.indexOf(s);l===n.length-1?i=i.substring(0,a)+n[0]+i.substring(a+1):(i=i.substring(0,a)+n[l+1]+i.substring(a+1),o=0)}o&&(i="A"+i),t--}return r},ji=(t,r)=>{const n=t;function i(a,s){if(typeof a=="object"){if(a.ID===s)return a;for(const l in a){const h=i(a[l],s);if(h)return h}}else if(Array.isArray(a))for(const l of a){const h=i(l,s);if(h)return h}return null}const o=i(n,r);return o?JSON.stringify(o,null,2):null};function Iq(t){let r=[];function n(i){i&&i.ID&&i.Properties&&r.push({ID:i.ID,Properties:i.Properties});for(let o in i)typeof i[o]=="object"&&i[o]!==null&&n(i[o])}return n(t),r}const Mh=t=>{if(t<=0)return"*";let r="";for(let n=0;n{const r=t==null?void 0:t.split(".");return(r==null?void 0:r.length)>1?r[1]:t},Hq=t=>{const r=t[0].split("-").map(Number);return r.length===2?r[0]+r[1]:null},Dq=(t,r)=>{let n=0,i=-1;for(let o=0;o{try{if(!Array.isArray(t)||t.length!==3&&!(Array.isArray(t[0])&&t[0].length===3))return null;Array.isArray(t[0])&&t[0].length===3&&(t=t[0]);const[r,n,i]=t;return[r,n,i].some(o=>o<0||o>255)?null:`rgb(${r}, ${n}, ${i})`}catch(r){return console.log("rgb error",r),null}},$g=t=>{var r=new Date(1900,0,1),n=new Date((r==null?void 0:r.getTime())+t*24*60*60*1e3),i=n==null?void 0:n.toISOString().split("T")[0];return i},Wg=t=>{const[r,n,i]=t.split("-"),o=new Date(r,n-1,i),a=new Date(1900,0,1,0,0,0,0),l=(o.getTime()-a.getTime())/(24*60*60*1e3);return Math.round(l)},S2=(t,r)=>{const n=r.filter(i=>!t.includes(i));return n.length>0?{NotSupported:n}:null},JM=t=>Object.keys(t).find(n=>{const i=t[n];return i&&i.Properties&&i.Properties.Type==="Form"}),Pq=(t,r,n,i)=>r.map((a,s)=>({index:s+1,title:a,description:n&&n[s][0],image:t&&t[i[s]-1]||""})),Zi=()=>{const t=window.location.origin,r=window.location.pathname!=="/"?window.location.pathname:"";return t+r},mD=(t,r)=>{var n;if((n=t==null?void 0:t.Properties)!=null&&n.Files){const i=t.Properties.Files;if(i){const o=i[r-1],a=t.Properties.Size;return{imageUrl:o,imageSize:a}}}return null},Tq=({data:t})=>{const r=ta(t),{Visible:n,CSS:i}=t==null?void 0:t.Properties,o=$1(i),a=Gr(t.Properties);return vt.jsx("div",{style:{display:n==0?"none":"flex",...a,...o},children:Object.keys(r).map(s=>vt.jsx(E4,{data:r[s]}))})};const x1=()=>{const{socketData:t,dataRef:r,socket:n,handleData:i,focusedElement:o,reRender:a,proceed:s,setProceed:l,proceedEventArray:h,setProceedEventArray:p,colors:f,fontScale:g,nqEvents:b,setNqEvents:z,updateCurrentEvent:M,currentEventRef:I,isDesktop:F}=_.useContext(vD);return{socketData:t,findDesiredData:$=>t==null?void 0:t.find(Z=>Z.ID==$),getObjType:$=>{var Z;const G=t==null?void 0:t.find(K=>K.ID==$);return(Z=G==null?void 0:G.Properties)==null?void 0:Z.Type},dataRef:r,socket:n,handleData:i,focusedElement:o,reRender:a,proceed:s,setProceed:l,proceedEventArray:h,setProceedEventArray:p,colors:f,findAggregatedPropertiesData:$=>{const G=t.filter(K=>K.ID===$),Z={ID:$,Properties:{}};return G.forEach(K=>{Z.Properties={...Z.Properties,...K.Properties}}),Z},fontScale:g,nqEvents:b,setNqEvents:z,findCurrentData:$=>Iq(r.current).find(Z=>Z.ID==$),updateCurrentEvent:M,currentEventRef:I,isDesktop:F}},y4=t=>{const[r,n]=_.useState({width:t==null?void 0:t.clientWidth,height:t==null?void 0:t.clientHeight});return _.useEffect(()=>{if(!t)return;const i=new ResizeObserver(o=>{const{offsetWidth:a,offsetHeight:s}=o[0].target;n({width:a,height:s})});return i.observe(t),function(){i.disconnect()}},[t]),r},Vq=()=>{const{socket:t,isDesktop:r}=x1(),[n,i]=_.useState({width:window.innerWidth,height:window.innerHeight});console.log("New height is",n);const o=_.useRef(null);return _.useEffect(()=>{const a=()=>{const s={width:window.innerWidth,height:window.innerHeight};let l=Math.round(window.devicePixelRatio*100);i(s),o.current&&clearTimeout(o.current),o.current=setTimeout(()=>{let h=JSON.stringify({DeviceCapabilities:{ViewPort:[s.height,s.width],ScreenSize:[window.screen.height,window.screen.width],DPR:l/100,PPI:200}});console.log({event:h}),t.send(h)},1e3)};return window.addEventListener("resize",a),()=>{window.removeEventListener("resize",a),o.current&&clearTimeout(o.current)}},[]),n},Fq=({title:t,data:r,style:n,customStyles:i})=>{const{socket:o}=x1();_.useEffect(()=>{const s=document.createElement("style");return s.innerHTML=` .dropdown-item { display: flex; flex-direction: co⌈lumn; @@ -47,7 +47,7 @@ Error generating stack: `+a.message+` height: auto; } - `,document.head.appendChild(s),()=>{document.head.removeChild(s)}},[r]),_.useEffect(()=>{const s=l=>{Object.keys(r).forEach(h=>{var g,b,z,M;const p=(b=(g=r[h])==null?void 0:g.Properties)==null?void 0:b.Caption,f=p!=null&&p.includes("&")?p.charAt(p.indexOf("&")+1).toLowerCase():null;f&&l.altKey&&l.key.toLowerCase()===f&&a((z=r[h])==null?void 0:z.ID,(M=r[h])==null?void 0:M.Properties)})};return document.addEventListener("keydown",s),()=>document.removeEventListener("keydown",s)},[r]);const a=(s,l)=>{const{Event:h}=l,p=JSON.stringify({Event:{EventName:"Select",ID:s}});h&&h.some(g=>g[0]==="Select")&&(console.log(p),o.send(p))};return vt.jsxs("div",{style:{fontSize:"12px",marginLeft:"7px",cursor:"pointer",zIndex:"1000",...n,...i},className:"menu-item",children:[t,vt.jsx("div",{className:"dropdown",children:Object.keys(r).map(s=>{var l,h,p,f,g;return vt.jsx("div",{id:(l=r[s])==null?void 0:l.ID,className:"dropdown-item",onClick:()=>{var b,z;return a((b=r[s])==null?void 0:b.ID,(z=r[s])==null?void 0:z.Properties)},children:(f=(p=(h=r[s])==null?void 0:h.Properties)==null?void 0:p.Caption)==null?void 0:f.replace("&","")},(g=r[s])==null?void 0:g.ID)})})]})};const Fq=({data:t})=>{var s,l,h,p;const r=ra(t),n=Yr(t.Properties),{CSS:i}=t.Properties,o=j1(i);return _q(r)?vt.jsx("div",{style:{fontSize:"12px",marginLeft:"7px",cursor:"pointer",display:"inline-block",zIndex:"1000",...n,...o},className:"menu-item",children:(l=(s=t==null?void 0:t.Properties)==null?void 0:s.Caption)==null?void 0:l.replace("&","")}):vt.jsx(Vq,{data:r,style:n,customStyles:o,title:(p=(h=t==null?void 0:t.Properties)==null?void 0:h.Caption)==null?void 0:p.replace("&","")})};function mD(t,r){var n={};for(var i in t)Object.prototype.hasOwnProperty.call(t,i)&&r.indexOf(i)<0&&(n[i]=t[i]);if(t!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,i=Object.getOwnPropertySymbols(t);o=l?o=o+JM("0",s-l):o=(o.substring(0,s)||"0")+"."+o.substring(s),n+o}function QM(t,r,n){if(["","-"].indexOf(t)!==-1)return t;var i=(t.indexOf(".")!==-1||n)&&r,o=$x(t),a=o.beforeDecimal,s=o.afterDecimal,l=o.hasNegation,h=parseFloat("0."+(s||"0")),p=s.length<=r?"0."+s:h.toFixed(r),f=p.split("."),g=a;a&&Number(f[0])&&(g=a.split("").reverse().reduce(function(I,F,H){return I.length>H?(Number(I[0])+Number(F)).toString()+I.substring(1,I.length):F+I},f[0]));var b=bD(f[1]||"",r,n),z=l?"-":"",M=i?".":"";return""+z+g+M+b}function K4(t,r){if(t.value=t.value,t!==null){if(t.createTextRange){var n=t.createTextRange();return n.move("character",r),n.select(),!0}return t.selectionStart||t.selectionStart===0?(t.focus(),t.setSelectionRange(r,r),!0):(t.focus(),!1)}}var CD=Rq(function(t,r){for(var n=0,i=0,o=t.length,a=r.length;t[n]===r[n]&&nn&&o-i>n;)i++;return{from:{start:n,end:o-i},to:{start:n,end:a-i}}}),jq=function(t,r){var n=Math.min(t.selectionStart,r);return{from:{start:n,end:t.selectionEnd},to:{start:n,end:r}}};function Gq(t,r,n){return Math.min(Math.max(t,r),n)}function jf(t){return Math.max(t.selectionStart,t.selectionEnd)}function Uq(){return typeof navigator<"u"&&!(navigator.platform&&/iPhone|iPod/.test(navigator.platform))}function Yq(t){return{from:{start:0,end:0},to:{start:0,end:t.length},lastValue:""}}function Xq(t){var r=t.currentValue,n=t.formattedValue,i=t.currentValueIndex,o=t.formattedValueIndex;return r[i]===n[o]}function Kq(t,r,n,i,o,a,s){s===void 0&&(s=Xq);var l=o.findIndex(function(W){return W}),h=t.slice(0,l);!r&&!n.startsWith(h)&&(r=h,n=h+n,i=i+h.length);for(var p=n.length,f=t.length,g={},b=new Array(p),z=0;z0&&b[H]===-1;)H--;var R=H===-1||b[H]===-1?0:b[H]+1;return R>E?E:i-R=0&&!n[r];)r--;r===-1&&(r=n.indexOf(!0))}else{for(;r<=o&&!n[r];)r++;r>o&&(r=n.lastIndexOf(!0))}return r===-1&&(r=o),r}function qq(t){for(var r=Array.from({length:t.length+1}).map(function(){return!0}),n=0,i=r.length;nZ.length-s.length||Gtt||g>t.length-s.length)&&(at=g),t=t.substring(0,at),t=tZ(R?"-"+t:t,o),t=(t.match(eZ(M,!0))||[]).join("");var ft=t.indexOf(M);t=t.replace(new RegExp(xD(M),"g"),function(mt,gt){return gt===ft?".":""});var dt=$x(t,o),ht=dt.beforeDecimal,lt=dt.afterDecimal,yt=dt.addNegation;return p.end-p.start{document.head.removeChild(s)}},[r]),_.useEffect(()=>{const s=l=>{Object.keys(r).forEach(h=>{var g,b,z,M;const p=(b=(g=r[h])==null?void 0:g.Properties)==null?void 0:b.Caption,f=p!=null&&p.includes("&")?p.charAt(p.indexOf("&")+1).toLowerCase():null;f&&l.altKey&&l.key.toLowerCase()===f&&a((z=r[h])==null?void 0:z.ID,(M=r[h])==null?void 0:M.Properties)})};return document.addEventListener("keydown",s),()=>document.removeEventListener("keydown",s)},[r]);const a=(s,l)=>{const{Event:h}=l,p=JSON.stringify({Event:{EventName:"Select",ID:s}});h&&h.some(g=>g[0]==="Select")&&(console.log(p),o.send(p))};return vt.jsxs("div",{style:{fontSize:"12px",marginLeft:"7px",cursor:"pointer",zIndex:"1000",...n,...i},className:"menu-item",children:[t,vt.jsx("div",{className:"dropdown",children:Object.keys(r).map(s=>{var l,h,p,f,g;return vt.jsx("div",{id:(l=r[s])==null?void 0:l.ID,className:"dropdown-item",onClick:()=>{var b,z;return a((b=r[s])==null?void 0:b.ID,(z=r[s])==null?void 0:z.Properties)},children:(f=(p=(h=r[s])==null?void 0:h.Properties)==null?void 0:p.Caption)==null?void 0:f.replace("&","")},(g=r[s])==null?void 0:g.ID)})})]})};const Rq=({data:t})=>{var s,l,h,p;const r=ta(t),n=Gr(t.Properties),{CSS:i}=t.Properties,o=$1(i);return Aq(r)?vt.jsx("div",{style:{fontSize:"12px",marginLeft:"7px",cursor:"pointer",display:"inline-block",zIndex:"1000",...n,...o},className:"menu-item",children:(l=(s=t==null?void 0:t.Properties)==null?void 0:s.Caption)==null?void 0:l.replace("&","")}):vt.jsx(Fq,{data:r,style:n,customStyles:o,title:(p=(h=t==null?void 0:t.Properties)==null?void 0:h.Caption)==null?void 0:p.replace("&","")})};function yD(t,r){var n={};for(var i in t)Object.prototype.hasOwnProperty.call(t,i)&&r.indexOf(i)<0&&(n[i]=t[i]);if(t!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,i=Object.getOwnPropertySymbols(t);o=l?o=o+QM("0",s-l):o=(o.substring(0,s)||"0")+"."+o.substring(s),n+o}function tk(t,r,n){if(["","-"].indexOf(t)!==-1)return t;var i=(t.indexOf(".")!==-1||n)&&r,o=Wx(t),a=o.beforeDecimal,s=o.afterDecimal,l=o.hasNegation,h=parseFloat("0."+(s||"0")),p=s.length<=r?"0."+s:h.toFixed(r),f=p.split("."),g=a;a&&Number(f[0])&&(g=a.split("").reverse().reduce(function(I,F,H){return I.length>H?(Number(I[0])+Number(F)).toString()+I.substring(1,I.length):F+I},f[0]));var b=wD(f[1]||"",r,n),z=l?"-":"",M=i?".":"";return""+z+g+M+b}function K4(t,r){if(t.value=t.value,t!==null){if(t.createTextRange){var n=t.createTextRange();return n.move("character",r),n.select(),!0}return t.selectionStart||t.selectionStart===0?(t.focus(),t.setSelectionRange(r,r),!0):(t.focus(),!1)}}var SD=Oq(function(t,r){for(var n=0,i=0,o=t.length,a=r.length;t[n]===r[n]&&nn&&o-i>n;)i++;return{from:{start:n,end:o-i},to:{start:n,end:a-i}}}),Gq=function(t,r){var n=Math.min(t.selectionStart,r);return{from:{start:n,end:t.selectionEnd},to:{start:n,end:r}}};function Uq(t,r,n){return Math.min(Math.max(t,r),n)}function jf(t){return Math.max(t.selectionStart,t.selectionEnd)}function Yq(){return typeof navigator<"u"&&!(navigator.platform&&/iPhone|iPod/.test(navigator.platform))}function Xq(t){return{from:{start:0,end:0},to:{start:0,end:t.length},lastValue:""}}function Kq(t){var r=t.currentValue,n=t.formattedValue,i=t.currentValueIndex,o=t.formattedValueIndex;return r[i]===n[o]}function qq(t,r,n,i,o,a,s){s===void 0&&(s=Kq);var l=o.findIndex(function(W){return W}),h=t.slice(0,l);!r&&!n.startsWith(h)&&(r=h,n=h+n,i=i+h.length);for(var p=n.length,f=t.length,g={},b=new Array(p),z=0;z0&&b[H]===-1;)H--;var R=H===-1||b[H]===-1?0:b[H]+1;return R>E?E:i-R=0&&!n[r];)r--;r===-1&&(r=n.indexOf(!0))}else{for(;r<=o&&!n[r];)r++;r>o&&(r=n.lastIndexOf(!0))}return r===-1&&(r=o),r}function Zq(t){for(var r=Array.from({length:t.length+1}).map(function(){return!0}),n=0,i=r.length;nZ.length-s.length||Gtt||g>t.length-s.length)&&(at=g),t=t.substring(0,at),t=eZ(R?"-"+t:t,o),t=(t.match(rZ(M,!0))||[]).join("");var ft=t.indexOf(M);t=t.replace(new RegExp(bD(M),"g"),function(mt,gt){return gt===ft?".":""});var dt=Wx(t,o),ht=dt.beforeDecimal,lt=dt.afterDecimal,yt=dt.addNegation;return p.end-p.startbt?!1:_t>=Bt.start&&_t=lt?ht:""+Array(lt+1-mt.length).join(yt)+ht},W={s:R,z:function(ht){var lt=-ht.utcOffset(),yt=Math.abs(lt),mt=Math.floor(yt/60),gt=yt%60;return(lt<=0?"+":"-")+R(mt,2,"0")+":"+R(gt,2,"0")},m:function ht(lt,yt){if(lt.date()1)return ht(_t[0])}else{var bt=lt.name;G[bt]=lt,gt=bt}return!mt&>&&($=gt),gt||!mt&&$},at=function(ht,lt){if(K(ht))return ht.clone();var yt=typeof lt=="object"?lt:{};return yt.date=ht,yt.args=arguments,new ft(yt)},tt=W;tt.l=et,tt.i=K,tt.w=function(ht,lt){return at(ht,{locale:lt.$L,utc:lt.$u,x:lt.$x,$offset:lt.$offset})};var ft=function(){function ht(yt){this.$L=et(yt.locale,null,!0),this.parse(yt),this.$x=this.$x||yt.x||{},this[Z]=!0}var lt=ht.prototype;return lt.parse=function(yt){this.$d=function(mt){var gt=mt.date,kt=mt.utc;if(gt===null)return new Date(NaN);if(tt.u(gt))return new Date;if(gt instanceof Date)return new Date(gt);if(typeof gt=="string"&&!/Z$/i.test(gt)){var _t=gt.match(F);if(_t){var bt=_t[2]-1||0,Mt=(_t[7]||"0").substring(0,3);return kt?new Date(Date.UTC(_t[1],bt,_t[3]||1,_t[4]||0,_t[5]||0,_t[6]||0,Mt)):new Date(_t[1],bt,_t[3]||1,_t[4]||0,_t[5]||0,_t[6]||0,Mt)}}return new Date(gt)}(yt),this.init()},lt.init=function(){var yt=this.$d;this.$y=yt.getFullYear(),this.$M=yt.getMonth(),this.$D=yt.getDate(),this.$W=yt.getDay(),this.$H=yt.getHours(),this.$m=yt.getMinutes(),this.$s=yt.getSeconds(),this.$ms=yt.getMilliseconds()},lt.$utils=function(){return tt},lt.isValid=function(){return this.$d.toString()!==I},lt.isSame=function(yt,mt){var gt=at(yt);return this.startOf(mt)<=gt&><=this.endOf(mt)},lt.isAfter=function(yt,mt){return at(yt)bt?!1:At>=Rt.start&&At=lt?ht:""+Array(lt+1-mt.length).join(yt)+ht},W={s:R,z:function(ht){var lt=-ht.utcOffset(),yt=Math.abs(lt),mt=Math.floor(yt/60),gt=yt%60;return(lt<=0?"+":"-")+R(mt,2,"0")+":"+R(gt,2,"0")},m:function ht(lt,yt){if(lt.date()1)return ht(At[0])}else{var bt=lt.name;G[bt]=lt,gt=bt}return!mt&>&&($=gt),gt||!mt&&$},at=function(ht,lt){if(K(ht))return ht.clone();var yt=typeof lt=="object"?lt:{};return yt.date=ht,yt.args=arguments,new ft(yt)},tt=W;tt.l=et,tt.i=K,tt.w=function(ht,lt){return at(ht,{locale:lt.$L,utc:lt.$u,x:lt.$x,$offset:lt.$offset})};var ft=function(){function ht(yt){this.$L=et(yt.locale,null,!0),this.parse(yt),this.$x=this.$x||yt.x||{},this[Z]=!0}var lt=ht.prototype;return lt.parse=function(yt){this.$d=function(mt){var gt=mt.date,_t=mt.utc;if(gt===null)return new Date(NaN);if(tt.u(gt))return new Date;if(gt instanceof Date)return new Date(gt);if(typeof gt=="string"&&!/Z$/i.test(gt)){var At=gt.match(F);if(At){var bt=At[2]-1||0,kt=(At[7]||"0").substring(0,3);return _t?new Date(Date.UTC(At[1],bt,At[3]||1,At[4]||0,At[5]||0,At[6]||0,kt)):new Date(At[1],bt,At[3]||1,At[4]||0,At[5]||0,At[6]||0,kt)}}return new Date(gt)}(yt),this.init()},lt.init=function(){var yt=this.$d;this.$y=yt.getFullYear(),this.$M=yt.getMonth(),this.$D=yt.getDate(),this.$W=yt.getDay(),this.$H=yt.getHours(),this.$m=yt.getMinutes(),this.$s=yt.getSeconds(),this.$ms=yt.getMilliseconds()},lt.$utils=function(){return tt},lt.isValid=function(){return this.$d.toString()!==I},lt.isSame=function(yt,mt){var gt=at(yt);return this.startOf(mt)<=gt&><=this.endOf(mt)},lt.isAfter=function(yt,mt){return at(yt) * Copyright OpenJS Foundation and other contributors * Released under MIT license * Based on Underscore.js 1.8.3 * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - */Mu.exports;(function(t,r){(function(){var n,i="4.17.21",o=200,a="Unsupported core-js use. Try https://npms.io/search?q=ponyfill.",s="Expected a function",l="Invalid `variable` option passed into `_.template`",h="__lodash_hash_undefined__",p=500,f="__lodash_placeholder__",g=1,b=2,z=4,M=1,I=2,F=1,H=2,E=4,R=8,W=16,$=32,G=64,Z=128,K=256,et=512,at=30,tt="...",ft=800,dt=16,ht=1,lt=2,yt=3,mt=1/0,gt=9007199254740991,kt=17976931348623157e292,_t=0/0,bt=4294967295,Mt=bt-1,At=bt>>>1,Ft=[["ary",Z],["bind",F],["bindKey",H],["curry",R],["curryRight",W],["flip",et],["partial",$],["partialRight",G],["rearg",K]],Bt="[object Arguments]",Ut="[object Array]",Xt="[object AsyncFunction]",It="[object Boolean]",ae="[object Date]",$t="[object DOMException]",ue="[object Error]",Ot="[object Function]",we="[object GeneratorFunction]",Ht="[object Map]",se="[object Number]",Se="[object Null]",Kt="[object Object]",fe="[object Promise]",ne="[object Proxy]",ce="[object RegExp]",xe="[object Set]",Wt="[object String]",qt="[object Symbol]",Ee="[object Undefined]",Ie="[object WeakMap]",Pe="[object WeakSet]",Yt="[object ArrayBuffer]",st="[object DataView]",Et="[object Float32Array]",zt="[object Float64Array]",Rt="[object Int8Array]",Vt="[object Int16Array]",Qt="[object Int32Array]",ve="[object Uint8Array]",je="[object Uint8ClampedArray]",ke="[object Uint16Array]",c1="[object Uint32Array]",Oe=/\b__p \+= '';/g,Tt=/\b(__p \+=) '' \+/g,te=/(__e\(.*?\)|\b__t\)) \+\n'';/g,Ve=/&(?:amp|lt|gt|quot|#39);/g,He=/[&<>"']/g,d1=RegExp(Ve.source),Le=RegExp(He.source),ge=/<%-([\s\S]+?)%>/g,h1=/<%([\s\S]+?)%>/g,M1=/<%=([\s\S]+?)%>/g,Z1=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,zr=/^\w*$/,Xr=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,jn=/[\\^$.*+?()[\]{}|]/g,Gn=RegExp(jn.source),_i=/^\s+/,ps=/\s/,ds=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,m2=/\{\n\/\* \[wrapped with (.+)\] \*/,fs=/,? & /,f6=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,K0=/[()=,{}\[\]\/\s]/,ca=/\\(\\)?/g,q0=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,r1=/\w*$/,s1=/^[-+]0x[0-9a-f]+$/i,I1=/^0b[01]+$/i,Nr=/^\[object .+?Constructor\]$/,Cn=/^0o[0-7]+$/i,v6=/^(?:0|[1-9]\d*)$/,Q=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,c=/($^)/,u=/['\n\r\u2028\u2029\\]/g,d="\\ud800-\\udfff",v="\\u0300-\\u036f",m="\\ufe20-\\ufe2f",x="\\u20d0-\\u20ff",w=v+m+x,k="\\u2700-\\u27bf",L="a-z\\xdf-\\xf6\\xf8-\\xff",D="\\xac\\xb1\\xd7\\xf7",P="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",V="\\u2000-\\u206f",N=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",j="A-Z\\xc0-\\xd6\\xd8-\\xde",U="\\ufe0e\\ufe0f",q=D+P+V+N,J="['’]",rt="["+d+"]",A="["+q+"]",O="["+w+"]",X="\\d+",ot="["+k+"]",nt="["+L+"]",ct="[^"+d+q+X+k+L+j+"]",wt="\\ud83c[\\udffb-\\udfff]",xt="(?:"+O+"|"+wt+")",jt="[^"+d+"]",ee="(?:\\ud83c[\\udde6-\\uddff]){2}",Nt="[\\ud800-\\udbff][\\udc00-\\udfff]",Zt="["+j+"]",ze="\\u200d",Te="(?:"+nt+"|"+ct+")",Ge="(?:"+Zt+"|"+ct+")",Ye="(?:"+J+"(?:d|ll|m|re|s|t|ve))?",l1="(?:"+J+"(?:D|LL|M|RE|S|T|VE))?",i1=xt+"?",y1="["+U+"]?",xr="(?:"+ze+"(?:"+[jt,ee,Nt].join("|")+")"+y1+i1+")*",Lr="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",dr="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",Bi=y1+i1+xr,N1="(?:"+[ot,ee,Nt].join("|")+")"+Bi,O1="(?:"+[jt+O+"?",O,ee,Nt,rt].join("|")+")",G1=RegExp(J,"g"),mi=RegExp(O,"g"),ri=RegExp(wt+"(?="+wt+")|"+O1+Bi,"g"),y2=RegExp([Zt+"?"+nt+"+"+Ye+"(?="+[A,Zt,"$"].join("|")+")",Ge+"+"+l1+"(?="+[A,Zt+Te,"$"].join("|")+")",Zt+"?"+Te+"+"+Ye,Zt+"+"+l1,dr,Lr,X,N1].join("|"),"g"),I4=RegExp("["+ze+d+w+U+"]"),Ai=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,Z2=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],hd=-1,Mr={};Mr[Et]=Mr[zt]=Mr[Rt]=Mr[Vt]=Mr[Qt]=Mr[ve]=Mr[je]=Mr[ke]=Mr[c1]=!0,Mr[Bt]=Mr[Ut]=Mr[Yt]=Mr[It]=Mr[st]=Mr[ae]=Mr[ue]=Mr[Ot]=Mr[Ht]=Mr[se]=Mr[Kt]=Mr[ce]=Mr[xe]=Mr[Wt]=Mr[Ie]=!1;var br={};br[Bt]=br[Ut]=br[Yt]=br[st]=br[It]=br[ae]=br[Et]=br[zt]=br[Rt]=br[Vt]=br[Qt]=br[Ht]=br[se]=br[Kt]=br[ce]=br[xe]=br[Wt]=br[qt]=br[ve]=br[je]=br[ke]=br[c1]=!0,br[ue]=br[Ot]=br[Ie]=!1;var cN={À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"},hN={"&":"&","<":"<",">":">",'"':""","'":"'"},uN={"&":"&","<":"<",">":">",""":'"',"'":"'"},pN={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},dN=parseFloat,fN=parseInt,DC=typeof S3=="object"&&S3&&S3.Object===Object&&S3,vN=typeof self=="object"&&self&&self.Object===Object&&self,Li=DC||vN||Function("return this")(),ud=r&&!r.nodeType&&r,H4=ud&&!0&&t&&!t.nodeType&&t,PC=H4&&H4.exports===ud,pd=PC&&DC.process,x2=function(){try{var Dt=H4&&H4.require&&H4.require("util").types;return Dt||pd&&pd.binding&&pd.binding("util")}catch{}}(),TC=x2&&x2.isArrayBuffer,VC=x2&&x2.isDate,FC=x2&&x2.isMap,RC=x2&&x2.isRegExp,OC=x2&&x2.isSet,BC=x2&&x2.isTypedArray;function Un(Dt,re,Gt){switch(Gt.length){case 0:return Dt.call(re);case 1:return Dt.call(re,Gt[0]);case 2:return Dt.call(re,Gt[0],Gt[1]);case 3:return Dt.call(re,Gt[0],Gt[1],Gt[2])}return Dt.apply(re,Gt)}function gN(Dt,re,Gt,Re){for(var f1=-1,U1=Dt==null?0:Dt.length;++f1-1}function dd(Dt,re,Gt){for(var Re=-1,f1=Dt==null?0:Dt.length;++Re-1;);return Gt}function XC(Dt,re){for(var Gt=Dt.length;Gt--&&Z0(re,Dt[Gt],0)>-1;);return Gt}function MN(Dt,re){for(var Gt=Dt.length,Re=0;Gt--;)Dt[Gt]===re&&++Re;return Re}var kN=md(cN),_N=md(hN);function AN(Dt){return"\\"+pN[Dt]}function LN(Dt,re){return Dt==null?n:Dt[re]}function J0(Dt){return I4.test(Dt)}function EN(Dt){return Ai.test(Dt)}function IN(Dt){for(var re,Gt=[];!(re=Dt.next()).done;)Gt.push(re.value);return Gt}function wd(Dt){var re=-1,Gt=Array(Dt.size);return Dt.forEach(function(Re,f1){Gt[++re]=[f1,Re]}),Gt}function KC(Dt,re){return function(Gt){return Dt(re(Gt))}}function ms(Dt,re){for(var Gt=-1,Re=Dt.length,f1=0,U1=[];++Gt-1}function y$(y,S){var T=this.__data__,Y=O5(T,y);return Y<0?(++this.size,T.push([y,S])):T[Y][1]=S,this}ha.prototype.clear=f$,ha.prototype.delete=v$,ha.prototype.get=g$,ha.prototype.has=m$,ha.prototype.set=y$;function ua(y){var S=-1,T=y==null?0:y.length;for(this.clear();++S=S?y:S)),y}function S2(y,S,T,Y,it,pt){var Ct,Lt=S&g,Pt=S&b,he=S&z;if(T&&(Ct=it?T(y,Y,it,pt):T(y)),Ct!==n)return Ct;if(!Pr(y))return y;var pe=g1(y);if(pe){if(Ct=CW(y),!Lt)return Sn(y,Ct)}else{var me=$i(y),De=me==Ot||me==we;if(Ss(y))return IS(y,Lt);if(me==Kt||me==Bt||De&&!it){if(Ct=Pt||De?{}:qS(y),!Lt)return Pt?uW(y,P$(Ct,y)):hW(y,sS(Ct,y))}else{if(!br[me])return it?y:{};Ct=SW(y,me,Lt)}}pt||(pt=new Q2);var Ue=pt.get(y);if(Ue)return Ue;pt.set(y,Ct),Mz(y)?y.forEach(function(o1){Ct.add(S2(o1,S,T,o1,y,pt))}):Sz(y)&&y.forEach(function(o1,_1){Ct.set(_1,S2(o1,S,T,_1,y,pt))});var n1=he?Pt?Yd:Ud:Pt?Mn:yi,C1=pe?n:n1(y);return b2(C1||y,function(o1,_1){C1&&(_1=o1,o1=y[_1]),C6(Ct,_1,S2(o1,S,T,_1,y,pt))}),Ct}function T$(y){var S=yi(y);return function(T){return lS(T,y,S)}}function lS(y,S,T){var Y=T.length;if(y==null)return!Y;for(y=vr(y);Y--;){var it=T[Y],pt=S[it],Ct=y[it];if(Ct===n&&!(it in y)||!pt(Ct))return!1}return!0}function cS(y,S,T){if(typeof y!="function")throw new w2(s);return L6(function(){y.apply(n,T)},S)}function S6(y,S,T,Y){var it=-1,pt=C5,Ct=!0,Lt=y.length,Pt=[],he=S.length;if(!Lt)return Pt;T&&(S=Er(S,Yn(T))),Y?(pt=dd,Ct=!1):S.length>=o&&(pt=g6,Ct=!1,S=new T4(S));t:for(;++itit?0:it+T),Y=Y===n||Y>it?it:x1(Y),Y<0&&(Y+=it),Y=T>Y?0:_z(Y);T0&&T(Lt)?S>1?Ei(Lt,S-1,T,Y,it):gs(it,Lt):Y||(it[it.length]=Lt)}return it}var Ad=FS(),pS=FS(!0);function Lo(y,S){return y&&Ad(y,S,yi)}function Ld(y,S){return y&&pS(y,S,yi)}function N5(y,S){return vs(S,function(T){return ga(y[T])})}function F4(y,S){S=ws(S,y);for(var T=0,Y=S.length;y!=null&&TS}function R$(y,S){return y!=null&&sr.call(y,S)}function O$(y,S){return y!=null&&S in vr(y)}function B$(y,S,T){return y>=Ni(S,T)&&y=120&&pe.length>=120)?new T4(Ct&&pe):n}pe=y[0];var me=-1,De=Lt[0];t:for(;++me-1;)Lt!==y&&H5.call(Lt,Pt,1),H5.call(y,Pt,1);return y}function SS(y,S){for(var T=y?S.length:0,Y=T-1;T--;){var it=S[T];if(T==Y||it!==pt){var pt=it;va(it)?H5.call(y,it,1):Od(y,it)}}return y}function Vd(y,S){return y+T5(iS()*(S-y+1))}function Q$(y,S,T,Y){for(var it=-1,pt=ci(P5((S-y)/(T||1)),0),Ct=Gt(pt);pt--;)Ct[Y?pt:++it]=y,y+=T;return Ct}function Fd(y,S){var T="";if(!y||S<1||S>gt)return T;do S%2&&(T+=y),S=T5(S/2),S&&(y+=y);while(S);return T}function S1(y,S){return tf(QS(y,S,kn),y+"")}function tW(y){return aS(c3(y))}function eW(y,S){var T=c3(y);return J5(T,V4(S,0,T.length))}function k6(y,S,T,Y){if(!Pr(y))return y;S=ws(S,y);for(var it=-1,pt=S.length,Ct=pt-1,Lt=y;Lt!=null&&++itit?0:it+S),T=T>it?it:T,T<0&&(T+=it),it=S>T?0:T-S>>>0,S>>>=0;for(var pt=Gt(it);++Y>>1,Ct=y[pt];Ct!==null&&!Kn(Ct)&&(T?Ct<=S:Ct=o){var he=S?null:vW(y);if(he)return z5(he);Ct=!1,it=g6,Pt=new T4}else Pt=S?[]:Lt;t:for(;++Y=Y?y:z2(y,S,T)}var ES=UN||function(y){return Li.clearTimeout(y)};function IS(y,S){if(S)return y.slice();var T=y.length,Y=JC?JC(T):new y.constructor(T);return y.copy(Y),Y}function Wd(y){var S=new y.constructor(y.byteLength);return new E5(S).set(new E5(y)),S}function aW(y,S){var T=S?Wd(y.buffer):y.buffer;return new y.constructor(T,y.byteOffset,y.byteLength)}function sW(y){var S=new y.constructor(y.source,r1.exec(y));return S.lastIndex=y.lastIndex,S}function lW(y){return w6?vr(w6.call(y)):{}}function HS(y,S){var T=S?Wd(y.buffer):y.buffer;return new y.constructor(T,y.byteOffset,y.length)}function DS(y,S){if(y!==S){var T=y!==n,Y=y===null,it=y===y,pt=Kn(y),Ct=S!==n,Lt=S===null,Pt=S===S,he=Kn(S);if(!Lt&&!he&&!pt&&y>S||pt&&Ct&&Pt&&!Lt&&!he||Y&&Ct&&Pt||!T&&Pt||!it)return 1;if(!Y&&!pt&&!he&&y=Lt)return Pt;var he=T[Y];return Pt*(he=="desc"?-1:1)}}return y.index-S.index}function PS(y,S,T,Y){for(var it=-1,pt=y.length,Ct=T.length,Lt=-1,Pt=S.length,he=ci(pt-Ct,0),pe=Gt(Pt+he),me=!Y;++Lt1?T[it-1]:n,Ct=it>2?T[2]:n;for(pt=y.length>3&&typeof pt=="function"?(it--,pt):n,Ct&&sn(T[0],T[1],Ct)&&(pt=it<3?n:pt,it=1),S=vr(S);++Y-1?it[pt?S[Ct]:Ct]:n}}function BS(y){return fa(function(S){var T=S.length,Y=T,it=C2.prototype.thru;for(y&&S.reverse();Y--;){var pt=S[Y];if(typeof pt!="function")throw new w2(s);if(it&&!Ct&&q5(pt)=="wrapper")var Ct=new C2([],!0)}for(Y=Ct?Y:T;++Y1&&D1.reverse(),pe&&Pt<_1&&(D1.length=Pt),this&&this!==Li&&this instanceof o1&&(ya=C1||_6(ya)),ya.apply(eo,D1)}return o1}function NS(y,S){return function(T,Y){return N$(T,y,S(Y),{})}}function Y5(y,S){return function(T,Y){var it;if(T===n&&Y===n)return S;if(T!==n&&(it=T),Y!==n){if(it===n)return Y;typeof T=="string"||typeof Y=="string"?(T=Xn(T),Y=Xn(Y)):(T=kS(T),Y=kS(Y)),it=y(T,Y)}return it}}function jd(y){return fa(function(S){return S=Er(S,Yn(e1())),S1(function(T){var Y=this;return y(S,function(it){return Un(it,Y,T)})})})}function X5(y,S){S=S===n?" ":Xn(S);var T=S.length;if(T<2)return T?Fd(S,y):S;var Y=Fd(S,P5(y/Q0(S)));return J0(S)?Cs(J2(Y),0,y).join(""):Y.slice(0,y)}function fW(y,S,T,Y){var it=S&F,pt=_6(y);function Ct(){for(var Lt=-1,Pt=arguments.length,he=-1,pe=Y.length,me=Gt(pe+Pt),De=this&&this!==Li&&this instanceof Ct?pt:y;++heLt))return!1;var he=pt.get(y),pe=pt.get(S);if(he&&pe)return he==S&&pe==y;var me=-1,De=!0,Ue=T&I?new T4:n;for(pt.set(y,S),pt.set(S,y);++me1?"& ":"")+S[Y],S=S.join(T>2?", ":" "),y.replace(ds,`{ + */Mu.exports;(function(t,r){(function(){var n,i="4.17.21",o=200,a="Unsupported core-js use. Try https://npms.io/search?q=ponyfill.",s="Expected a function",l="Invalid `variable` option passed into `_.template`",h="__lodash_hash_undefined__",p=500,f="__lodash_placeholder__",g=1,b=2,z=4,M=1,I=2,F=1,H=2,E=4,R=8,W=16,$=32,G=64,Z=128,K=256,et=512,at=30,tt="...",ft=800,dt=16,ht=1,lt=2,yt=3,mt=1/0,gt=9007199254740991,_t=17976931348623157e292,At=0/0,bt=4294967295,kt=bt-1,Lt=bt>>>1,Vt=[["ary",Z],["bind",F],["bindKey",H],["curry",R],["curryRight",W],["flip",et],["partial",$],["partialRight",G],["rearg",K]],Rt="[object Arguments]",Ut="[object Array]",Kt="[object AsyncFunction]",It="[object Boolean]",le="[object Date]",Bt="[object DOMException]",de="[object Error]",Ft="[object Function]",we="[object GeneratorFunction]",Ht="[object Map]",ce="[object Number]",Se="[object Null]",qt="[object Object]",ge="[object Promise]",oe="[object Proxy]",ue="[object RegExp]",xe="[object Set]",Nt="[object String]",Jt="[object Symbol]",Ie="[object Undefined]",He="[object WeakMap]",Pe="[object WeakSet]",Xt="[object ArrayBuffer]",st="[object DataView]",Mt="[object Float32Array]",wt="[object Float64Array]",Pt="[object Int8Array]",Yt="[object Int16Array]",Zt="[object Int32Array]",ae="[object Uint8Array]",ee="[object Uint8ClampedArray]",jt="[object Uint16Array]",_e="[object Uint32Array]",ze=/\b__p \+= '';/g,Gt=/\b(__p \+=) '' \+/g,Re=/(__e\(.*?\)|\b__t\)) \+\n'';/g,je=/&(?:amp|lt|gt|quot|#39);/g,d1=/[&<>"']/g,K1=RegExp(je.source),Oe=RegExp(d1.source),Ae=/<%-([\s\S]+?)%>/g,E1=/<%([\s\S]+?)%>/g,ur=/<%=([\s\S]+?)%>/g,Qr=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,ti=/^\w*$/,us=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Mo=/[\\^$.*+?()[\]{}|]/g,ko=RegExp(Mo.source),sa=/^\s+/,ps=/\s/,ds=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,d2=/\{\n\/\* \[wrapped with (.+)\] \*/,fs=/,? & /,f6=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,K0=/[()=,{}\[\]\/\s]/,la=/\\(\\)?/g,q0=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,r1=/\w*$/,s1=/^[-+]0x[0-9a-f]+$/i,A1=/^0b[01]+$/i,Or=/^\[object .+?Constructor\]$/,bn=/^0o[0-7]+$/i,v6=/^(?:0|[1-9]\d*)$/,Q=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,c=/($^)/,u=/['\n\r\u2028\u2029\\]/g,d="\\ud800-\\udfff",v="\\u0300-\\u036f",m="\\ufe20-\\ufe2f",x="\\u20d0-\\u20ff",w=v+m+x,k="\\u2700-\\u27bf",L="a-z\\xdf-\\xf6\\xf8-\\xff",D="\\xac\\xb1\\xd7\\xf7",P="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",V="\\u2000-\\u206f",N=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",j="A-Z\\xc0-\\xd6\\xd8-\\xde",U="\\ufe0e\\ufe0f",q=D+P+V+N,J="['’]",rt="["+d+"]",A="["+q+"]",O="["+w+"]",X="\\d+",ot="["+k+"]",nt="["+L+"]",ct="[^"+d+q+X+k+L+j+"]",Ct="\\ud83c[\\udffb-\\udfff]",xt="(?:"+O+"|"+Ct+")",$t="[^"+d+"]",re="(?:\\ud83c[\\udde6-\\uddff]){2}",Ot="[\\ud800-\\udbff][\\udc00-\\udfff]",Qt="["+j+"]",Me="\\u200d",Te="(?:"+nt+"|"+ct+")",Ge="(?:"+Qt+"|"+ct+")",Ye="(?:"+J+"(?:d|ll|m|re|s|t|ve))?",l1="(?:"+J+"(?:D|LL|M|RE|S|T|VE))?",i1=xt+"?",g1="["+U+"]?",yr="(?:"+Me+"(?:"+[$t,re,Ot].join("|")+")"+g1+i1+")*",_r="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",pr="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",Ri=g1+i1+yr,O1="(?:"+[ot,re,Ot].join("|")+")"+Ri,F1="(?:"+[$t+O+"?",O,re,Ot,rt].join("|")+")",W1=RegExp(J,"g"),gi=RegExp(O,"g"),ei=RegExp(Ct+"(?="+Ct+")|"+F1+Ri,"g"),f2=RegExp([Qt+"?"+nt+"+"+Ye+"(?="+[A,Qt,"$"].join("|")+")",Ge+"+"+l1+"(?="+[A,Qt+Te,"$"].join("|")+")",Qt+"?"+Te+"+"+Ye,Qt+"+"+l1,pr,_r,X,O1].join("|"),"g"),I4=RegExp("["+Me+d+w+U+"]"),ki=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,Y2=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],hd=-1,Sr={};Sr[Mt]=Sr[wt]=Sr[Pt]=Sr[Yt]=Sr[Zt]=Sr[ae]=Sr[ee]=Sr[jt]=Sr[_e]=!0,Sr[Rt]=Sr[Ut]=Sr[Xt]=Sr[It]=Sr[st]=Sr[le]=Sr[de]=Sr[Ft]=Sr[Ht]=Sr[ce]=Sr[qt]=Sr[ue]=Sr[xe]=Sr[Nt]=Sr[He]=!1;var xr={};xr[Rt]=xr[Ut]=xr[Xt]=xr[st]=xr[It]=xr[le]=xr[Mt]=xr[wt]=xr[Pt]=xr[Yt]=xr[Zt]=xr[Ht]=xr[ce]=xr[qt]=xr[ue]=xr[xe]=xr[Nt]=xr[Jt]=xr[ae]=xr[ee]=xr[jt]=xr[_e]=!0,xr[de]=xr[Ft]=xr[He]=!1;var hN={À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"},uN={"&":"&","<":"<",">":">",'"':""","'":"'"},pN={"&":"&","<":"<",">":">",""":'"',"'":"'"},dN={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},fN=parseFloat,vN=parseInt,PC=typeof S3=="object"&&S3&&S3.Object===Object&&S3,gN=typeof self=="object"&&self&&self.Object===Object&&self,_i=PC||gN||Function("return this")(),ud=r&&!r.nodeType&&r,H4=ud&&!0&&t&&!t.nodeType&&t,TC=H4&&H4.exports===ud,pd=TC&&PC.process,v2=function(){try{var Dt=H4&&H4.require&&H4.require("util").types;return Dt||pd&&pd.binding&&pd.binding("util")}catch{}}(),VC=v2&&v2.isArrayBuffer,FC=v2&&v2.isDate,RC=v2&&v2.isMap,OC=v2&&v2.isRegExp,BC=v2&&v2.isSet,NC=v2&&v2.isTypedArray;function $n(Dt,ie,Wt){switch(Wt.length){case 0:return Dt.call(ie);case 1:return Dt.call(ie,Wt[0]);case 2:return Dt.call(ie,Wt[0],Wt[1]);case 3:return Dt.call(ie,Wt[0],Wt[1],Wt[2])}return Dt.apply(ie,Wt)}function mN(Dt,ie,Wt,Fe){for(var u1=-1,j1=Dt==null?0:Dt.length;++u1-1}function dd(Dt,ie,Wt){for(var Fe=-1,u1=Dt==null?0:Dt.length;++Fe-1;);return Wt}function KC(Dt,ie){for(var Wt=Dt.length;Wt--&&Z0(ie,Dt[Wt],0)>-1;);return Wt}function kN(Dt,ie){for(var Wt=Dt.length,Fe=0;Wt--;)Dt[Wt]===ie&&++Fe;return Fe}var _N=md(hN),AN=md(uN);function LN(Dt){return"\\"+dN[Dt]}function EN(Dt,ie){return Dt==null?n:Dt[ie]}function J0(Dt){return I4.test(Dt)}function IN(Dt){return ki.test(Dt)}function HN(Dt){for(var ie,Wt=[];!(ie=Dt.next()).done;)Wt.push(ie.value);return Wt}function wd(Dt){var ie=-1,Wt=Array(Dt.size);return Dt.forEach(function(Fe,u1){Wt[++ie]=[u1,Fe]}),Wt}function qC(Dt,ie){return function(Wt){return Dt(ie(Wt))}}function ms(Dt,ie){for(var Wt=-1,Fe=Dt.length,u1=0,j1=[];++Wt-1}function x$(y,S){var T=this.__data__,Y=O5(T,y);return Y<0?(++this.size,T.push([y,S])):T[Y][1]=S,this}ca.prototype.clear=v$,ca.prototype.delete=g$,ca.prototype.get=m$,ca.prototype.has=y$,ca.prototype.set=x$;function ha(y){var S=-1,T=y==null?0:y.length;for(this.clear();++S=S?y:S)),y}function x2(y,S,T,Y,it,pt){var St,Et=S&g,Tt=S&b,pe=S&z;if(T&&(St=it?T(y,Y,it,pt):T(y)),St!==n)return St;if(!Hr(y))return y;var fe=f1(y);if(fe){if(St=SW(y),!Et)return wn(y,St)}else{var me=Bi(y),De=me==Ft||me==we;if(Ss(y))return HS(y,Et);if(me==qt||me==Rt||De&&!it){if(St=Tt||De?{}:ZS(y),!Et)return Tt?pW(y,T$(St,y)):uW(y,lS(St,y))}else{if(!xr[me])return it?y:{};St=zW(y,me,Et)}}pt||(pt=new K2);var Ue=pt.get(y);if(Ue)return Ue;pt.set(y,St),kz(y)?y.forEach(function(o1){St.add(x2(o1,S,T,o1,y,pt))}):zz(y)&&y.forEach(function(o1,z1){St.set(z1,x2(o1,S,T,z1,y,pt))});var n1=pe?Tt?Yd:Ud:Tt?Sn:mi,b1=fe?n:n1(y);return g2(b1||y,function(o1,z1){b1&&(z1=o1,o1=y[z1]),C6(St,z1,x2(o1,S,T,z1,y,pt))}),St}function V$(y){var S=mi(y);return function(T){return cS(T,y,S)}}function cS(y,S,T){var Y=T.length;if(y==null)return!Y;for(y=fr(y);Y--;){var it=T[Y],pt=S[it],St=y[it];if(St===n&&!(it in y)||!pt(St))return!1}return!0}function hS(y,S,T){if(typeof y!="function")throw new m2(s);return L6(function(){y.apply(n,T)},S)}function S6(y,S,T,Y){var it=-1,pt=C5,St=!0,Et=y.length,Tt=[],pe=S.length;if(!Et)return Tt;T&&(S=Ar(S,Wn(T))),Y?(pt=dd,St=!1):S.length>=o&&(pt=g6,St=!1,S=new T4(S));t:for(;++itit?0:it+T),Y=Y===n||Y>it?it:m1(Y),Y<0&&(Y+=it),Y=T>Y?0:Az(Y);T0&&T(Et)?S>1?Ai(Et,S-1,T,Y,it):gs(it,Et):Y||(it[it.length]=Et)}return it}var Ad=RS(),dS=RS(!0);function _o(y,S){return y&&Ad(y,S,mi)}function Ld(y,S){return y&&dS(y,S,mi)}function N5(y,S){return vs(S,function(T){return va(y[T])})}function F4(y,S){S=ws(S,y);for(var T=0,Y=S.length;y!=null&&TS}function O$(y,S){return y!=null&&or.call(y,S)}function B$(y,S){return y!=null&&S in fr(y)}function N$(y,S,T){return y>=Oi(S,T)&&y=120&&fe.length>=120)?new T4(St&&fe):n}fe=y[0];var me=-1,De=Et[0];t:for(;++me-1;)Et!==y&&H5.call(Et,Tt,1),H5.call(y,Tt,1);return y}function zS(y,S){for(var T=y?S.length:0,Y=T-1;T--;){var it=S[T];if(T==Y||it!==pt){var pt=it;fa(it)?H5.call(y,it,1):Od(y,it)}}return y}function Vd(y,S){return y+T5(nS()*(S-y+1))}function tW(y,S,T,Y){for(var it=-1,pt=li(P5((S-y)/(T||1)),0),St=Wt(pt);pt--;)St[Y?pt:++it]=y,y+=T;return St}function Fd(y,S){var T="";if(!y||S<1||S>gt)return T;do S%2&&(T+=y),S=T5(S/2),S&&(y+=y);while(S);return T}function w1(y,S){return tf(tz(y,S,zn),y+"")}function eW(y){return sS(c3(y))}function rW(y,S){var T=c3(y);return J5(T,V4(S,0,T.length))}function k6(y,S,T,Y){if(!Hr(y))return y;S=ws(S,y);for(var it=-1,pt=S.length,St=pt-1,Et=y;Et!=null&&++itit?0:it+S),T=T>it?it:T,T<0&&(T+=it),it=S>T?0:T-S>>>0,S>>>=0;for(var pt=Wt(it);++Y>>1,St=y[pt];St!==null&&!Gn(St)&&(T?St<=S:St=o){var pe=S?null:gW(y);if(pe)return z5(pe);St=!1,it=g6,Tt=new T4}else Tt=S?[]:Et;t:for(;++Y=Y?y:b2(y,S,T)}var IS=YN||function(y){return _i.clearTimeout(y)};function HS(y,S){if(S)return y.slice();var T=y.length,Y=QC?QC(T):new y.constructor(T);return y.copy(Y),Y}function Wd(y){var S=new y.constructor(y.byteLength);return new E5(S).set(new E5(y)),S}function sW(y,S){var T=S?Wd(y.buffer):y.buffer;return new y.constructor(T,y.byteOffset,y.byteLength)}function lW(y){var S=new y.constructor(y.source,r1.exec(y));return S.lastIndex=y.lastIndex,S}function cW(y){return w6?fr(w6.call(y)):{}}function DS(y,S){var T=S?Wd(y.buffer):y.buffer;return new y.constructor(T,y.byteOffset,y.length)}function PS(y,S){if(y!==S){var T=y!==n,Y=y===null,it=y===y,pt=Gn(y),St=S!==n,Et=S===null,Tt=S===S,pe=Gn(S);if(!Et&&!pe&&!pt&&y>S||pt&&St&&Tt&&!Et&&!pe||Y&&St&&Tt||!T&&Tt||!it)return 1;if(!Y&&!pt&&!pe&&y=Et)return Tt;var pe=T[Y];return Tt*(pe=="desc"?-1:1)}}return y.index-S.index}function TS(y,S,T,Y){for(var it=-1,pt=y.length,St=T.length,Et=-1,Tt=S.length,pe=li(pt-St,0),fe=Wt(Tt+pe),me=!Y;++Et1?T[it-1]:n,St=it>2?T[2]:n;for(pt=y.length>3&&typeof pt=="function"?(it--,pt):n,St&&on(T[0],T[1],St)&&(pt=it<3?n:pt,it=1),S=fr(S);++Y-1?it[pt?S[St]:St]:n}}function NS(y){return da(function(S){var T=S.length,Y=T,it=y2.prototype.thru;for(y&&S.reverse();Y--;){var pt=S[Y];if(typeof pt!="function")throw new m2(s);if(it&&!St&&q5(pt)=="wrapper")var St=new y2([],!0)}for(Y=St?Y:T;++Y1&&I1.reverse(),fe&&TtEt))return!1;var pe=pt.get(y),fe=pt.get(S);if(pe&&fe)return pe==S&&fe==y;var me=-1,De=!0,Ue=T&I?new T4:n;for(pt.set(y,S),pt.set(S,y);++me1?"& ":"")+S[Y],S=S.join(T>2?", ":" "),y.replace(ds,`{ /* [wrapped with `+S+`] */ -`)}function MW(y){return g1(y)||B4(y)||!!(eS&&y&&y[eS])}function va(y,S){var T=typeof y;return S=S??gt,!!S&&(T=="number"||T!="symbol"&&v6.test(y))&&y>-1&&y%1==0&&y0){if(++S>=ft)return arguments[0]}else S=0;return y.apply(n,arguments)}}function J5(y,S){var T=-1,Y=y.length,it=Y-1;for(S=S===n?Y:S;++T1?y[S-1]:n;return T=typeof T=="function"?(y.pop(),T):n,uz(y,T)});function pz(y){var S=ut(y);return S.__chain__=!0,S}function Vj(y,S){return S(y),y}function Q5(y,S){return S(y)}var Fj=fa(function(y){var S=y.length,T=S?y[0]:0,Y=this.__wrapped__,it=function(pt){return _d(pt,y)};return S>1||this.__actions__.length||!(Y instanceof H1)||!va(T)?this.thru(it):(Y=Y.slice(T,+T+(S?1:0)),Y.__actions__.push({func:Q5,args:[it],thisArg:n}),new C2(Y,this.__chain__).thru(function(pt){return S&&!pt.length&&pt.push(n),pt}))});function Rj(){return pz(this)}function Oj(){return new C2(this.value(),this.__chain__)}function Bj(){this.__values__===n&&(this.__values__=kz(this.value()));var y=this.__index__>=this.__values__.length,S=y?n:this.__values__[this.__index__++];return{done:y,value:S}}function Nj(){return this}function $j(y){for(var S,T=this;T instanceof R5;){var Y=oz(T);Y.__index__=0,Y.__values__=n,S?it.__wrapped__=Y:S=Y;var it=Y;T=T.__wrapped__}return it.__wrapped__=y,S}function Wj(){var y=this.__wrapped__;if(y instanceof H1){var S=y;return this.__actions__.length&&(S=new H1(this)),S=S.reverse(),S.__actions__.push({func:Q5,args:[ef],thisArg:n}),new C2(S,this.__chain__)}return this.thru(ef)}function jj(){return AS(this.__wrapped__,this.__actions__)}var Gj=G5(function(y,S,T){sr.call(y,T)?++y[T]:pa(y,T,1)});function Uj(y,S,T){var Y=g1(y)?NC:V$;return T&&sn(y,S,T)&&(S=n),Y(y,e1(S,3))}function Yj(y,S){var T=g1(y)?vs:uS;return T(y,e1(S,3))}var Xj=OS(az),Kj=OS(sz);function qj(y,S){return Ei(th(y,S),1)}function Zj(y,S){return Ei(th(y,S),mt)}function Jj(y,S,T){return T=T===n?1:x1(T),Ei(th(y,S),T)}function dz(y,S){var T=g1(y)?b2:xs;return T(y,e1(S,3))}function fz(y,S){var T=g1(y)?mN:hS;return T(y,e1(S,3))}var Qj=G5(function(y,S,T){sr.call(y,T)?y[T].push(S):pa(y,T,[S])});function tG(y,S,T,Y){y=zn(y)?y:c3(y),T=T&&!Y?x1(T):0;var it=y.length;return T<0&&(T=ci(it+T,0)),oh(y)?T<=it&&y.indexOf(S,T)>-1:!!it&&Z0(y,S,T)>-1}var eG=S1(function(y,S,T){var Y=-1,it=typeof S=="function",pt=zn(y)?Gt(y.length):[];return xs(y,function(Ct){pt[++Y]=it?Un(S,Ct,T):z6(Ct,S,T)}),pt}),rG=G5(function(y,S,T){pa(y,T,S)});function th(y,S){var T=g1(y)?Er:mS;return T(y,e1(S,3))}function iG(y,S,T,Y){return y==null?[]:(g1(S)||(S=S==null?[]:[S]),T=Y?n:T,g1(T)||(T=T==null?[]:[T]),wS(y,S,T))}var nG=G5(function(y,S,T){y[T?0:1].push(S)},function(){return[[],[]]});function oG(y,S,T){var Y=g1(y)?fd:GC,it=arguments.length<3;return Y(y,e1(S,4),T,it,xs)}function aG(y,S,T){var Y=g1(y)?yN:GC,it=arguments.length<3;return Y(y,e1(S,4),T,it,hS)}function sG(y,S){var T=g1(y)?vs:uS;return T(y,ih(e1(S,3)))}function lG(y){var S=g1(y)?aS:tW;return S(y)}function cG(y,S,T){(T?sn(y,S,T):S===n)?S=1:S=x1(S);var Y=g1(y)?I$:eW;return Y(y,S)}function hG(y){var S=g1(y)?H$:iW;return S(y)}function uG(y){if(y==null)return 0;if(zn(y))return oh(y)?Q0(y):y.length;var S=$i(y);return S==Ht||S==xe?y.size:Dd(y).length}function pG(y,S,T){var Y=g1(y)?vd:nW;return T&&sn(y,S,T)&&(S=n),Y(y,e1(S,3))}var dG=S1(function(y,S){if(y==null)return[];var T=S.length;return T>1&&sn(y,S[0],S[1])?S=[]:T>2&&sn(S[0],S[1],S[2])&&(S=[S[0]]),wS(y,Ei(S,1),[])}),eh=YN||function(){return Li.Date.now()};function fG(y,S){if(typeof S!="function")throw new w2(s);return y=x1(y),function(){if(--y<1)return S.apply(this,arguments)}}function vz(y,S,T){return S=T?n:S,S=y&&S==null?y.length:S,da(y,Z,n,n,n,n,S)}function gz(y,S){var T;if(typeof S!="function")throw new w2(s);return y=x1(y),function(){return--y>0&&(T=S.apply(this,arguments)),y<=1&&(S=n),T}}var nf=S1(function(y,S,T){var Y=F;if(T.length){var it=ms(T,s3(nf));Y|=$}return da(y,Y,S,T,it)}),mz=S1(function(y,S,T){var Y=F|H;if(T.length){var it=ms(T,s3(mz));Y|=$}return da(S,Y,y,T,it)});function yz(y,S,T){S=T?n:S;var Y=da(y,R,n,n,n,n,n,S);return Y.placeholder=yz.placeholder,Y}function xz(y,S,T){S=T?n:S;var Y=da(y,W,n,n,n,n,n,S);return Y.placeholder=xz.placeholder,Y}function bz(y,S,T){var Y,it,pt,Ct,Lt,Pt,he=0,pe=!1,me=!1,De=!0;if(typeof y!="function")throw new w2(s);S=k2(S)||0,Pr(T)&&(pe=!!T.leading,me="maxWait"in T,pt=me?ci(k2(T.maxWait)||0,S):pt,De="trailing"in T?!!T.trailing:De);function Ue(qr){var eo=Y,ya=it;return Y=it=n,he=qr,Ct=y.apply(ya,eo),Ct}function n1(qr){return he=qr,Lt=L6(_1,S),pe?Ue(qr):Ct}function C1(qr){var eo=qr-Pt,ya=qr-he,Oz=S-eo;return me?Ni(Oz,pt-ya):Oz}function o1(qr){var eo=qr-Pt,ya=qr-he;return Pt===n||eo>=S||eo<0||me&&ya>=pt}function _1(){var qr=eh();if(o1(qr))return D1(qr);Lt=L6(_1,C1(qr))}function D1(qr){return Lt=n,De&&Y?Ue(qr):(Y=it=n,Ct)}function qn(){Lt!==n&&ES(Lt),he=0,Y=Pt=it=Lt=n}function ln(){return Lt===n?Ct:D1(eh())}function Zn(){var qr=eh(),eo=o1(qr);if(Y=arguments,it=this,Pt=qr,eo){if(Lt===n)return n1(Pt);if(me)return ES(Lt),Lt=L6(_1,S),Ue(Pt)}return Lt===n&&(Lt=L6(_1,S)),Ct}return Zn.cancel=qn,Zn.flush=ln,Zn}var vG=S1(function(y,S){return cS(y,1,S)}),gG=S1(function(y,S,T){return cS(y,k2(S)||0,T)});function mG(y){return da(y,et)}function rh(y,S){if(typeof y!="function"||S!=null&&typeof S!="function")throw new w2(s);var T=function(){var Y=arguments,it=S?S.apply(this,Y):Y[0],pt=T.cache;if(pt.has(it))return pt.get(it);var Ct=y.apply(this,Y);return T.cache=pt.set(it,Ct)||pt,Ct};return T.cache=new(rh.Cache||ua),T}rh.Cache=ua;function ih(y){if(typeof y!="function")throw new w2(s);return function(){var S=arguments;switch(S.length){case 0:return!y.call(this);case 1:return!y.call(this,S[0]);case 2:return!y.call(this,S[0],S[1]);case 3:return!y.call(this,S[0],S[1],S[2])}return!y.apply(this,S)}}function yG(y){return gz(2,y)}var xG=oW(function(y,S){S=S.length==1&&g1(S[0])?Er(S[0],Yn(e1())):Er(Ei(S,1),Yn(e1()));var T=S.length;return S1(function(Y){for(var it=-1,pt=Ni(Y.length,T);++it=S}),B4=fS(function(){return arguments}())?fS:function(y){return $r(y)&&sr.call(y,"callee")&&!tS.call(y,"callee")},g1=Gt.isArray,PG=TC?Yn(TC):$$;function zn(y){return y!=null&&nh(y.length)&&!ga(y)}function Kr(y){return $r(y)&&zn(y)}function TG(y){return y===!0||y===!1||$r(y)&&an(y)==It}var Ss=KN||gf,VG=VC?Yn(VC):W$;function FG(y){return $r(y)&&y.nodeType===1&&!E6(y)}function RG(y){if(y==null)return!0;if(zn(y)&&(g1(y)||typeof y=="string"||typeof y.splice=="function"||Ss(y)||l3(y)||B4(y)))return!y.length;var S=$i(y);if(S==Ht||S==xe)return!y.size;if(A6(y))return!Dd(y).length;for(var T in y)if(sr.call(y,T))return!1;return!0}function OG(y,S){return M6(y,S)}function BG(y,S,T){T=typeof T=="function"?T:n;var Y=T?T(y,S):n;return Y===n?M6(y,S,n,T):!!Y}function af(y){if(!$r(y))return!1;var S=an(y);return S==ue||S==$t||typeof y.message=="string"&&typeof y.name=="string"&&!E6(y)}function NG(y){return typeof y=="number"&&rS(y)}function ga(y){if(!Pr(y))return!1;var S=an(y);return S==Ot||S==we||S==Xt||S==ne}function Cz(y){return typeof y=="number"&&y==x1(y)}function nh(y){return typeof y=="number"&&y>-1&&y%1==0&&y<=gt}function Pr(y){var S=typeof y;return y!=null&&(S=="object"||S=="function")}function $r(y){return y!=null&&typeof y=="object"}var Sz=FC?Yn(FC):G$;function $G(y,S){return y===S||Hd(y,S,Kd(S))}function WG(y,S,T){return T=typeof T=="function"?T:n,Hd(y,S,Kd(S),T)}function jG(y){return zz(y)&&y!=+y}function GG(y){if(AW(y))throw new f1(a);return vS(y)}function UG(y){return y===null}function YG(y){return y==null}function zz(y){return typeof y=="number"||$r(y)&&an(y)==se}function E6(y){if(!$r(y)||an(y)!=Kt)return!1;var S=I5(y);if(S===null)return!0;var T=sr.call(S,"constructor")&&S.constructor;return typeof T=="function"&&T instanceof T&&_5.call(T)==WN}var sf=RC?Yn(RC):U$;function XG(y){return Cz(y)&&y>=-gt&&y<=gt}var Mz=OC?Yn(OC):Y$;function oh(y){return typeof y=="string"||!g1(y)&&$r(y)&&an(y)==Wt}function Kn(y){return typeof y=="symbol"||$r(y)&&an(y)==qt}var l3=BC?Yn(BC):X$;function KG(y){return y===n}function qG(y){return $r(y)&&$i(y)==Ie}function ZG(y){return $r(y)&&an(y)==Pe}var JG=K5(Pd),QG=K5(function(y,S){return y<=S});function kz(y){if(!y)return[];if(zn(y))return oh(y)?J2(y):Sn(y);if(m6&&y[m6])return IN(y[m6]());var S=$i(y),T=S==Ht?wd:S==xe?z5:c3;return T(y)}function ma(y){if(!y)return y===0?y:0;if(y=k2(y),y===mt||y===-mt){var S=y<0?-1:1;return S*kt}return y===y?y:0}function x1(y){var S=ma(y),T=S%1;return S===S?T?S-T:S:0}function _z(y){return y?V4(x1(y),0,bt):0}function k2(y){if(typeof y=="number")return y;if(Kn(y))return _t;if(Pr(y)){var S=typeof y.valueOf=="function"?y.valueOf():y;y=Pr(S)?S+"":S}if(typeof y!="string")return y===0?y:+y;y=UC(y);var T=I1.test(y);return T||Cn.test(y)?fN(y.slice(2),T?2:8):s1.test(y)?_t:+y}function Az(y){return Eo(y,Mn(y))}function tU(y){return y?V4(x1(y),-gt,gt):y===0?y:0}function J1(y){return y==null?"":Xn(y)}var eU=o3(function(y,S){if(A6(S)||zn(S)){Eo(S,yi(S),y);return}for(var T in S)sr.call(S,T)&&C6(y,T,S[T])}),Lz=o3(function(y,S){Eo(S,Mn(S),y)}),ah=o3(function(y,S,T,Y){Eo(S,Mn(S),y,Y)}),rU=o3(function(y,S,T,Y){Eo(S,yi(S),y,Y)}),iU=fa(_d);function nU(y,S){var T=n3(y);return S==null?T:sS(T,S)}var oU=S1(function(y,S){y=vr(y);var T=-1,Y=S.length,it=Y>2?S[2]:n;for(it&&sn(S[0],S[1],it)&&(Y=1);++T1),pt}),Eo(y,Yd(y),T),Y&&(T=S2(T,g|b|z,gW));for(var it=S.length;it--;)Od(T,S[it]);return T});function SU(y,S){return Iz(y,ih(e1(S)))}var zU=fa(function(y,S){return y==null?{}:Z$(y,S)});function Iz(y,S){if(y==null)return{};var T=Er(Yd(y),function(Y){return[Y]});return S=e1(S),CS(y,T,function(Y,it){return S(Y,it[0])})}function MU(y,S,T){S=ws(S,y);var Y=-1,it=S.length;for(it||(it=1,y=n);++YS){var Y=y;y=S,S=Y}if(T||y%1||S%1){var it=iS();return Ni(y+it*(S-y+dN("1e-"+((it+"").length-1))),S)}return Vd(y,S)}var VU=a3(function(y,S,T){return S=S.toLowerCase(),y+(T?Pz(S):S)});function Pz(y){return hf(J1(y).toLowerCase())}function Tz(y){return y=J1(y),y&&y.replace(Q,kN).replace(mi,"")}function FU(y,S,T){y=J1(y),S=Xn(S);var Y=y.length;T=T===n?Y:V4(x1(T),0,Y);var it=T;return T-=S.length,T>=0&&y.slice(T,it)==S}function RU(y){return y=J1(y),y&&Le.test(y)?y.replace(He,_N):y}function OU(y){return y=J1(y),y&&Gn.test(y)?y.replace(jn,"\\$&"):y}var BU=a3(function(y,S,T){return y+(T?"-":"")+S.toLowerCase()}),NU=a3(function(y,S,T){return y+(T?" ":"")+S.toLowerCase()}),$U=RS("toLowerCase");function WU(y,S,T){y=J1(y),S=x1(S);var Y=S?Q0(y):0;if(!S||Y>=S)return y;var it=(S-Y)/2;return X5(T5(it),T)+y+X5(P5(it),T)}function jU(y,S,T){y=J1(y),S=x1(S);var Y=S?Q0(y):0;return S&&Y>>0,T?(y=J1(y),y&&(typeof S=="string"||S!=null&&!sf(S))&&(S=Xn(S),!S&&J0(y))?Cs(J2(y),0,T):y.split(S,T)):[]}var ZU=a3(function(y,S,T){return y+(T?" ":"")+hf(S)});function JU(y,S,T){return y=J1(y),T=T==null?0:V4(x1(T),0,y.length),S=Xn(S),y.slice(T,T+S.length)==S}function QU(y,S,T){var Y=ut.templateSettings;T&&sn(y,S,T)&&(S=n),y=J1(y),S=ah({},S,Y,GS);var it=ah({},S.imports,Y.imports,GS),pt=yi(it),Ct=bd(it,pt),Lt,Pt,he=0,pe=S.interpolate||c,me="__p += '",De=Cd((S.escape||c).source+"|"+pe.source+"|"+(pe===M1?q0:c).source+"|"+(S.evaluate||c).source+"|$","g"),Ue="//# sourceURL="+(sr.call(S,"sourceURL")?(S.sourceURL+"").replace(/\s/g," "):"lodash.templateSources["+ ++hd+"]")+` -`;y.replace(De,function(o1,_1,D1,qn,ln,Zn){return D1||(D1=qn),me+=y.slice(he,Zn).replace(u,AN),_1&&(Lt=!0,me+=`' + -__e(`+_1+`) + -'`),ln&&(Pt=!0,me+=`'; -`+ln+`; -__p += '`),D1&&(me+=`' + -((__t = (`+D1+`)) == null ? '' : __t) + -'`),he=Zn+o1.length,o1}),me+=`'; -`;var n1=sr.call(S,"variable")&&S.variable;if(!n1)me=`with (obj) { +`)}function kW(y){return f1(y)||B4(y)||!!(rS&&y&&y[rS])}function fa(y,S){var T=typeof y;return S=S??gt,!!S&&(T=="number"||T!="symbol"&&v6.test(y))&&y>-1&&y%1==0&&y0){if(++S>=ft)return arguments[0]}else S=0;return y.apply(n,arguments)}}function J5(y,S){var T=-1,Y=y.length,it=Y-1;for(S=S===n?Y:S;++T1?y[S-1]:n;return T=typeof T=="function"?(y.pop(),T):n,pz(y,T)});function dz(y){var S=ut(y);return S.__chain__=!0,S}function Fj(y,S){return S(y),y}function Q5(y,S){return S(y)}var Rj=da(function(y){var S=y.length,T=S?y[0]:0,Y=this.__wrapped__,it=function(pt){return _d(pt,y)};return S>1||this.__actions__.length||!(Y instanceof L1)||!fa(T)?this.thru(it):(Y=Y.slice(T,+T+(S?1:0)),Y.__actions__.push({func:Q5,args:[it],thisArg:n}),new y2(Y,this.__chain__).thru(function(pt){return S&&!pt.length&&pt.push(n),pt}))});function Oj(){return dz(this)}function Bj(){return new y2(this.value(),this.__chain__)}function Nj(){this.__values__===n&&(this.__values__=_z(this.value()));var y=this.__index__>=this.__values__.length,S=y?n:this.__values__[this.__index__++];return{done:y,value:S}}function $j(){return this}function Wj(y){for(var S,T=this;T instanceof R5;){var Y=az(T);Y.__index__=0,Y.__values__=n,S?it.__wrapped__=Y:S=Y;var it=Y;T=T.__wrapped__}return it.__wrapped__=y,S}function jj(){var y=this.__wrapped__;if(y instanceof L1){var S=y;return this.__actions__.length&&(S=new L1(this)),S=S.reverse(),S.__actions__.push({func:Q5,args:[ef],thisArg:n}),new y2(S,this.__chain__)}return this.thru(ef)}function Gj(){return LS(this.__wrapped__,this.__actions__)}var Uj=G5(function(y,S,T){or.call(y,T)?++y[T]:ua(y,T,1)});function Yj(y,S,T){var Y=f1(y)?$C:F$;return T&&on(y,S,T)&&(S=n),Y(y,e1(S,3))}function Xj(y,S){var T=f1(y)?vs:pS;return T(y,e1(S,3))}var Kj=BS(sz),qj=BS(lz);function Zj(y,S){return Ai(th(y,S),1)}function Jj(y,S){return Ai(th(y,S),mt)}function Qj(y,S,T){return T=T===n?1:m1(T),Ai(th(y,S),T)}function fz(y,S){var T=f1(y)?g2:xs;return T(y,e1(S,3))}function vz(y,S){var T=f1(y)?yN:uS;return T(y,e1(S,3))}var tG=G5(function(y,S,T){or.call(y,T)?y[T].push(S):ua(y,T,[S])});function eG(y,S,T,Y){y=Cn(y)?y:c3(y),T=T&&!Y?m1(T):0;var it=y.length;return T<0&&(T=li(it+T,0)),oh(y)?T<=it&&y.indexOf(S,T)>-1:!!it&&Z0(y,S,T)>-1}var rG=w1(function(y,S,T){var Y=-1,it=typeof S=="function",pt=Cn(y)?Wt(y.length):[];return xs(y,function(St){pt[++Y]=it?$n(S,St,T):z6(St,S,T)}),pt}),iG=G5(function(y,S,T){ua(y,T,S)});function th(y,S){var T=f1(y)?Ar:yS;return T(y,e1(S,3))}function nG(y,S,T,Y){return y==null?[]:(f1(S)||(S=S==null?[]:[S]),T=Y?n:T,f1(T)||(T=T==null?[]:[T]),CS(y,S,T))}var oG=G5(function(y,S,T){y[T?0:1].push(S)},function(){return[[],[]]});function aG(y,S,T){var Y=f1(y)?fd:UC,it=arguments.length<3;return Y(y,e1(S,4),T,it,xs)}function sG(y,S,T){var Y=f1(y)?xN:UC,it=arguments.length<3;return Y(y,e1(S,4),T,it,uS)}function lG(y,S){var T=f1(y)?vs:pS;return T(y,ih(e1(S,3)))}function cG(y){var S=f1(y)?sS:eW;return S(y)}function hG(y,S,T){(T?on(y,S,T):S===n)?S=1:S=m1(S);var Y=f1(y)?H$:rW;return Y(y,S)}function uG(y){var S=f1(y)?D$:nW;return S(y)}function pG(y){if(y==null)return 0;if(Cn(y))return oh(y)?Q0(y):y.length;var S=Bi(y);return S==Ht||S==xe?y.size:Dd(y).length}function dG(y,S,T){var Y=f1(y)?vd:oW;return T&&on(y,S,T)&&(S=n),Y(y,e1(S,3))}var fG=w1(function(y,S){if(y==null)return[];var T=S.length;return T>1&&on(y,S[0],S[1])?S=[]:T>2&&on(S[0],S[1],S[2])&&(S=[S[0]]),CS(y,Ai(S,1),[])}),eh=XN||function(){return _i.Date.now()};function vG(y,S){if(typeof S!="function")throw new m2(s);return y=m1(y),function(){if(--y<1)return S.apply(this,arguments)}}function gz(y,S,T){return S=T?n:S,S=y&&S==null?y.length:S,pa(y,Z,n,n,n,n,S)}function mz(y,S){var T;if(typeof S!="function")throw new m2(s);return y=m1(y),function(){return--y>0&&(T=S.apply(this,arguments)),y<=1&&(S=n),T}}var nf=w1(function(y,S,T){var Y=F;if(T.length){var it=ms(T,s3(nf));Y|=$}return pa(y,Y,S,T,it)}),yz=w1(function(y,S,T){var Y=F|H;if(T.length){var it=ms(T,s3(yz));Y|=$}return pa(S,Y,y,T,it)});function xz(y,S,T){S=T?n:S;var Y=pa(y,R,n,n,n,n,n,S);return Y.placeholder=xz.placeholder,Y}function bz(y,S,T){S=T?n:S;var Y=pa(y,W,n,n,n,n,n,S);return Y.placeholder=bz.placeholder,Y}function wz(y,S,T){var Y,it,pt,St,Et,Tt,pe=0,fe=!1,me=!1,De=!0;if(typeof y!="function")throw new m2(s);S=C2(S)||0,Hr(T)&&(fe=!!T.leading,me="maxWait"in T,pt=me?li(C2(T.maxWait)||0,S):pt,De="trailing"in T?!!T.trailing:De);function Ue(Yr){var Z2=Y,ma=it;return Y=it=n,pe=Yr,St=y.apply(ma,Z2),St}function n1(Yr){return pe=Yr,Et=L6(z1,S),fe?Ue(Yr):St}function b1(Yr){var Z2=Yr-Tt,ma=Yr-pe,Bz=S-Z2;return me?Oi(Bz,pt-ma):Bz}function o1(Yr){var Z2=Yr-Tt,ma=Yr-pe;return Tt===n||Z2>=S||Z2<0||me&&ma>=pt}function z1(){var Yr=eh();if(o1(Yr))return I1(Yr);Et=L6(z1,b1(Yr))}function I1(Yr){return Et=n,De&&Y?Ue(Yr):(Y=it=n,St)}function Un(){Et!==n&&IS(Et),pe=0,Y=Tt=it=Et=n}function an(){return Et===n?St:I1(eh())}function Yn(){var Yr=eh(),Z2=o1(Yr);if(Y=arguments,it=this,Tt=Yr,Z2){if(Et===n)return n1(Tt);if(me)return IS(Et),Et=L6(z1,S),Ue(Tt)}return Et===n&&(Et=L6(z1,S)),St}return Yn.cancel=Un,Yn.flush=an,Yn}var gG=w1(function(y,S){return hS(y,1,S)}),mG=w1(function(y,S,T){return hS(y,C2(S)||0,T)});function yG(y){return pa(y,et)}function rh(y,S){if(typeof y!="function"||S!=null&&typeof S!="function")throw new m2(s);var T=function(){var Y=arguments,it=S?S.apply(this,Y):Y[0],pt=T.cache;if(pt.has(it))return pt.get(it);var St=y.apply(this,Y);return T.cache=pt.set(it,St)||pt,St};return T.cache=new(rh.Cache||ha),T}rh.Cache=ha;function ih(y){if(typeof y!="function")throw new m2(s);return function(){var S=arguments;switch(S.length){case 0:return!y.call(this);case 1:return!y.call(this,S[0]);case 2:return!y.call(this,S[0],S[1]);case 3:return!y.call(this,S[0],S[1],S[2])}return!y.apply(this,S)}}function xG(y){return mz(2,y)}var bG=aW(function(y,S){S=S.length==1&&f1(S[0])?Ar(S[0],Wn(e1())):Ar(Ai(S,1),Wn(e1()));var T=S.length;return w1(function(Y){for(var it=-1,pt=Oi(Y.length,T);++it=S}),B4=vS(function(){return arguments}())?vS:function(y){return Br(y)&&or.call(y,"callee")&&!eS.call(y,"callee")},f1=Wt.isArray,TG=VC?Wn(VC):W$;function Cn(y){return y!=null&&nh(y.length)&&!va(y)}function Ur(y){return Br(y)&&Cn(y)}function VG(y){return y===!0||y===!1||Br(y)&&nn(y)==It}var Ss=qN||gf,FG=FC?Wn(FC):j$;function RG(y){return Br(y)&&y.nodeType===1&&!E6(y)}function OG(y){if(y==null)return!0;if(Cn(y)&&(f1(y)||typeof y=="string"||typeof y.splice=="function"||Ss(y)||l3(y)||B4(y)))return!y.length;var S=Bi(y);if(S==Ht||S==xe)return!y.size;if(A6(y))return!Dd(y).length;for(var T in y)if(or.call(y,T))return!1;return!0}function BG(y,S){return M6(y,S)}function NG(y,S,T){T=typeof T=="function"?T:n;var Y=T?T(y,S):n;return Y===n?M6(y,S,n,T):!!Y}function af(y){if(!Br(y))return!1;var S=nn(y);return S==de||S==Bt||typeof y.message=="string"&&typeof y.name=="string"&&!E6(y)}function $G(y){return typeof y=="number"&&iS(y)}function va(y){if(!Hr(y))return!1;var S=nn(y);return S==Ft||S==we||S==Kt||S==oe}function Sz(y){return typeof y=="number"&&y==m1(y)}function nh(y){return typeof y=="number"&&y>-1&&y%1==0&&y<=gt}function Hr(y){var S=typeof y;return y!=null&&(S=="object"||S=="function")}function Br(y){return y!=null&&typeof y=="object"}var zz=RC?Wn(RC):U$;function WG(y,S){return y===S||Hd(y,S,Kd(S))}function jG(y,S,T){return T=typeof T=="function"?T:n,Hd(y,S,Kd(S),T)}function GG(y){return Mz(y)&&y!=+y}function UG(y){if(LW(y))throw new u1(a);return gS(y)}function YG(y){return y===null}function XG(y){return y==null}function Mz(y){return typeof y=="number"||Br(y)&&nn(y)==ce}function E6(y){if(!Br(y)||nn(y)!=qt)return!1;var S=I5(y);if(S===null)return!0;var T=or.call(S,"constructor")&&S.constructor;return typeof T=="function"&&T instanceof T&&_5.call(T)==jN}var sf=OC?Wn(OC):Y$;function KG(y){return Sz(y)&&y>=-gt&&y<=gt}var kz=BC?Wn(BC):X$;function oh(y){return typeof y=="string"||!f1(y)&&Br(y)&&nn(y)==Nt}function Gn(y){return typeof y=="symbol"||Br(y)&&nn(y)==Jt}var l3=NC?Wn(NC):K$;function qG(y){return y===n}function ZG(y){return Br(y)&&Bi(y)==He}function JG(y){return Br(y)&&nn(y)==Pe}var QG=K5(Pd),tU=K5(function(y,S){return y<=S});function _z(y){if(!y)return[];if(Cn(y))return oh(y)?X2(y):wn(y);if(m6&&y[m6])return HN(y[m6]());var S=Bi(y),T=S==Ht?wd:S==xe?z5:c3;return T(y)}function ga(y){if(!y)return y===0?y:0;if(y=C2(y),y===mt||y===-mt){var S=y<0?-1:1;return S*_t}return y===y?y:0}function m1(y){var S=ga(y),T=S%1;return S===S?T?S-T:S:0}function Az(y){return y?V4(m1(y),0,bt):0}function C2(y){if(typeof y=="number")return y;if(Gn(y))return At;if(Hr(y)){var S=typeof y.valueOf=="function"?y.valueOf():y;y=Hr(S)?S+"":S}if(typeof y!="string")return y===0?y:+y;y=YC(y);var T=A1.test(y);return T||bn.test(y)?vN(y.slice(2),T?2:8):s1.test(y)?At:+y}function Lz(y){return Ao(y,Sn(y))}function eU(y){return y?V4(m1(y),-gt,gt):y===0?y:0}function q1(y){return y==null?"":jn(y)}var rU=o3(function(y,S){if(A6(S)||Cn(S)){Ao(S,mi(S),y);return}for(var T in S)or.call(S,T)&&C6(y,T,S[T])}),Ez=o3(function(y,S){Ao(S,Sn(S),y)}),ah=o3(function(y,S,T,Y){Ao(S,Sn(S),y,Y)}),iU=o3(function(y,S,T,Y){Ao(S,mi(S),y,Y)}),nU=da(_d);function oU(y,S){var T=n3(y);return S==null?T:lS(T,S)}var aU=w1(function(y,S){y=fr(y);var T=-1,Y=S.length,it=Y>2?S[2]:n;for(it&&on(S[0],S[1],it)&&(Y=1);++T1),pt}),Ao(y,Yd(y),T),Y&&(T=x2(T,g|b|z,mW));for(var it=S.length;it--;)Od(T,S[it]);return T});function zU(y,S){return Hz(y,ih(e1(S)))}var MU=da(function(y,S){return y==null?{}:J$(y,S)});function Hz(y,S){if(y==null)return{};var T=Ar(Yd(y),function(Y){return[Y]});return S=e1(S),SS(y,T,function(Y,it){return S(Y,it[0])})}function kU(y,S,T){S=ws(S,y);var Y=-1,it=S.length;for(it||(it=1,y=n);++YS){var Y=y;y=S,S=Y}if(T||y%1||S%1){var it=nS();return Oi(y+it*(S-y+fN("1e-"+((it+"").length-1))),S)}return Vd(y,S)}var FU=a3(function(y,S,T){return S=S.toLowerCase(),y+(T?Tz(S):S)});function Tz(y){return hf(q1(y).toLowerCase())}function Vz(y){return y=q1(y),y&&y.replace(Q,_N).replace(gi,"")}function RU(y,S,T){y=q1(y),S=jn(S);var Y=y.length;T=T===n?Y:V4(m1(T),0,Y);var it=T;return T-=S.length,T>=0&&y.slice(T,it)==S}function OU(y){return y=q1(y),y&&Oe.test(y)?y.replace(d1,AN):y}function BU(y){return y=q1(y),y&&ko.test(y)?y.replace(Mo,"\\$&"):y}var NU=a3(function(y,S,T){return y+(T?"-":"")+S.toLowerCase()}),$U=a3(function(y,S,T){return y+(T?" ":"")+S.toLowerCase()}),WU=OS("toLowerCase");function jU(y,S,T){y=q1(y),S=m1(S);var Y=S?Q0(y):0;if(!S||Y>=S)return y;var it=(S-Y)/2;return X5(T5(it),T)+y+X5(P5(it),T)}function GU(y,S,T){y=q1(y),S=m1(S);var Y=S?Q0(y):0;return S&&Y>>0,T?(y=q1(y),y&&(typeof S=="string"||S!=null&&!sf(S))&&(S=jn(S),!S&&J0(y))?Cs(X2(y),0,T):y.split(S,T)):[]}var JU=a3(function(y,S,T){return y+(T?" ":"")+hf(S)});function QU(y,S,T){return y=q1(y),T=T==null?0:V4(m1(T),0,y.length),S=jn(S),y.slice(T,T+S.length)==S}function tY(y,S,T){var Y=ut.templateSettings;T&&on(y,S,T)&&(S=n),y=q1(y),S=ah({},S,Y,US);var it=ah({},S.imports,Y.imports,US),pt=mi(it),St=bd(it,pt),Et,Tt,pe=0,fe=S.interpolate||c,me="__p += '",De=Cd((S.escape||c).source+"|"+fe.source+"|"+(fe===ur?q0:c).source+"|"+(S.evaluate||c).source+"|$","g"),Ue="//# sourceURL="+(or.call(S,"sourceURL")?(S.sourceURL+"").replace(/\s/g," "):"lodash.templateSources["+ ++hd+"]")+` +`;y.replace(De,function(o1,z1,I1,Un,an,Yn){return I1||(I1=Un),me+=y.slice(pe,Yn).replace(u,LN),z1&&(Et=!0,me+=`' + +__e(`+z1+`) + +'`),an&&(Tt=!0,me+=`'; +`+an+`; +__p += '`),I1&&(me+=`' + +((__t = (`+I1+`)) == null ? '' : __t) + +'`),pe=Yn+o1.length,o1}),me+=`'; +`;var n1=or.call(S,"variable")&&S.variable;if(!n1)me=`with (obj) { `+me+` } -`;else if(K0.test(n1))throw new f1(l);me=(Pt?me.replace(Oe,""):me).replace(Tt,"$1").replace(te,"$1;"),me="function("+(n1||"obj")+`) { +`;else if(K0.test(n1))throw new u1(l);me=(Tt?me.replace(ze,""):me).replace(Gt,"$1").replace(Re,"$1;"),me="function("+(n1||"obj")+`) { `+(n1?"":`obj || (obj = {}); -`)+"var __t, __p = ''"+(Lt?", __e = _.escape":"")+(Pt?`, __j = Array.prototype.join; +`)+"var __t, __p = ''"+(Et?", __e = _.escape":"")+(Tt?`, __j = Array.prototype.join; function print() { __p += __j.call(arguments, '') } `:`; `)+me+`return __p -}`;var C1=Fz(function(){return U1(pt,Ue+"return "+me).apply(n,Ct)});if(C1.source=me,af(C1))throw C1;return C1}function tY(y){return J1(y).toLowerCase()}function eY(y){return J1(y).toUpperCase()}function rY(y,S,T){if(y=J1(y),y&&(T||S===n))return UC(y);if(!y||!(S=Xn(S)))return y;var Y=J2(y),it=J2(S),pt=YC(Y,it),Ct=XC(Y,it)+1;return Cs(Y,pt,Ct).join("")}function iY(y,S,T){if(y=J1(y),y&&(T||S===n))return y.slice(0,qC(y)+1);if(!y||!(S=Xn(S)))return y;var Y=J2(y),it=XC(Y,J2(S))+1;return Cs(Y,0,it).join("")}function nY(y,S,T){if(y=J1(y),y&&(T||S===n))return y.replace(_i,"");if(!y||!(S=Xn(S)))return y;var Y=J2(y),it=YC(Y,J2(S));return Cs(Y,it).join("")}function oY(y,S){var T=at,Y=tt;if(Pr(S)){var it="separator"in S?S.separator:it;T="length"in S?x1(S.length):T,Y="omission"in S?Xn(S.omission):Y}y=J1(y);var pt=y.length;if(J0(y)){var Ct=J2(y);pt=Ct.length}if(T>=pt)return y;var Lt=T-Q0(Y);if(Lt<1)return Y;var Pt=Ct?Cs(Ct,0,Lt).join(""):y.slice(0,Lt);if(it===n)return Pt+Y;if(Ct&&(Lt+=Pt.length-Lt),sf(it)){if(y.slice(Lt).search(it)){var he,pe=Pt;for(it.global||(it=Cd(it.source,J1(r1.exec(it))+"g")),it.lastIndex=0;he=it.exec(pe);)var me=he.index;Pt=Pt.slice(0,me===n?Lt:me)}}else if(y.indexOf(Xn(it),Lt)!=Lt){var De=Pt.lastIndexOf(it);De>-1&&(Pt=Pt.slice(0,De))}return Pt+Y}function aY(y){return y=J1(y),y&&d1.test(y)?y.replace(Ve,TN):y}var sY=a3(function(y,S,T){return y+(T?" ":"")+S.toUpperCase()}),hf=RS("toUpperCase");function Vz(y,S,T){return y=J1(y),S=T?n:S,S===n?EN(y)?RN(y):wN(y):y.match(S)||[]}var Fz=S1(function(y,S){try{return Un(y,n,S)}catch(T){return af(T)?T:new f1(T)}}),lY=fa(function(y,S){return b2(S,function(T){T=Io(T),pa(y,T,nf(y[T],y))}),y});function cY(y){var S=y==null?0:y.length,T=e1();return y=S?Er(y,function(Y){if(typeof Y[1]!="function")throw new w2(s);return[T(Y[0]),Y[1]]}):[],S1(function(Y){for(var it=-1;++itgt)return[];var T=bt,Y=Ni(y,bt);S=e1(S),y-=bt;for(var it=xd(Y,S);++T0||S<0)?new H1(T):(y<0?T=T.takeRight(-y):y&&(T=T.drop(y)),S!==n&&(S=x1(S),T=S<0?T.dropRight(-S):T.take(S-y)),T)},H1.prototype.takeRightWhile=function(y){return this.reverse().takeWhile(y).reverse()},H1.prototype.toArray=function(){return this.take(bt)},Lo(H1.prototype,function(y,S){var T=/^(?:filter|find|map|reject)|While$/.test(S),Y=/^(?:head|last)$/.test(S),it=ut[Y?"take"+(S=="last"?"Right":""):S],pt=Y||/^find/.test(S);it&&(ut.prototype[S]=function(){var Ct=this.__wrapped__,Lt=Y?[1]:arguments,Pt=Ct instanceof H1,he=Lt[0],pe=Pt||g1(Ct),me=function(_1){var D1=it.apply(ut,gs([_1],Lt));return Y&&De?D1[0]:D1};pe&&T&&typeof he=="function"&&he.length!=1&&(Pt=pe=!1);var De=this.__chain__,Ue=!!this.__actions__.length,n1=pt&&!De,C1=Pt&&!Ue;if(!pt&&pe){Ct=C1?Ct:new H1(this);var o1=y.apply(Ct,Lt);return o1.__actions__.push({func:Q5,args:[me],thisArg:n}),new C2(o1,De)}return n1&&C1?y.apply(this,Lt):(o1=this.thru(me),n1?Y?o1.value()[0]:o1.value():o1)})}),b2(["pop","push","shift","sort","splice","unshift"],function(y){var S=M5[y],T=/^(?:push|sort|unshift)$/.test(y)?"tap":"thru",Y=/^(?:pop|shift)$/.test(y);ut.prototype[y]=function(){var it=arguments;if(Y&&!this.__chain__){var pt=this.value();return S.apply(g1(pt)?pt:[],it)}return this[T](function(Ct){return S.apply(g1(Ct)?Ct:[],it)})}}),Lo(H1.prototype,function(y,S){var T=ut[S];if(T){var Y=T.name+"";sr.call(i3,Y)||(i3[Y]=[]),i3[Y].push({name:S,func:T})}}),i3[U5(n,H).name]=[{name:"wrapper",func:n}],H1.prototype.clone=a$,H1.prototype.reverse=s$,H1.prototype.value=l$,ut.prototype.at=Fj,ut.prototype.chain=Rj,ut.prototype.commit=Oj,ut.prototype.next=Bj,ut.prototype.plant=$j,ut.prototype.reverse=Wj,ut.prototype.toJSON=ut.prototype.valueOf=ut.prototype.value=jj,ut.prototype.first=ut.prototype.head,m6&&(ut.prototype[m6]=Nj),ut},t3=ON();H4?((H4.exports=t3)._=t3,ud._=t3):Li._=t3}).call(S3)})(Mu,Mu.exports);var lZ=Mu.exports;const cZ=({data:t,onKeyDown1:r})=>{var _t;const n=_.useRef(null),i=_.useRef(null),o=_.useRef(null),[a,s]=_.useState(!1),[l,h]=_.useState(!1),[p,f]=_.useState(t==null?void 0:t.value),{FieldType:g,Decimal:b,SelText:z,Event:M}=(_t=t==null?void 0:t.typeObj)==null?void 0:_t.Properties,{dataRef:I,findDesiredData:F,handleData:H,socket:E,socketData:R}=w1(),W=JSON.parse(Ui(I.current,"Locale")),{ShortDate:$,Thousand:G,Decimal:Z}=W==null?void 0:W.Properties,[K,et]=_.useState(g=="Date"?q4($g(t==null?void 0:t.value)).format($&&$):t==null?void 0:t.value),[at,tt]=_.useState(g=="Date"?q4($g(t==null?void 0:t.value)):new Date),[ft,dt]=_.useState(!1),ht=bt=>{const Mt=bt.trimStart();return bt.indexOf(Mt[0])};_.useEffect(()=>{if(!a&&o.current&&z&&z.length===2&&(t!=null&&t.focused)){const[bt,Mt]=z,At=o.current.firstChild;console.log({textNode:At});const Ft=At!=null&&At.nodeType?At:At==null?void 0:At.textNode;if((Ft==null?void 0:Ft.nodeType)===Node.TEXT_NODE){const Bt=document.createRange(),Ut=window.getSelection(),Xt=Math.min(Mt-1,Ft.length);if(Ft.parentNode.textContent.trim(),console.log("use effect",{content:t==null?void 0:t.formattedValue}),t!=null&&t.formattedValue){console.log("content",{index:ht(t==null?void 0:t.formattedValue)});const ae=ht(t==null?void 0:t.formattedValue);Bt.setStart(Ft,Math.min(bt-1+ae,Ft.length)),Bt.setEnd(Ft,Math.min(Mt-1+ae,Ft.length))}else Bt.setStart(Ft,Math.min(bt-1,Ft.length)),Bt.setEnd(Ft,Xt);Ut.removeAllRanges(),Ut.addRange(Bt)}}},[z,a,t.focused]);const lt=bt=>{var Ut,Xt,It,ae;console.log("select"),console.log({event:bt});const Mt=bt.target,At=Mt.selectionStart+1,Ft=Mt.selectionEnd+1,Bt=Mt.value.substring(At,Ft);console.log({data:t,input:Mt,start:At,end:Ft}),h(!!Bt),console.log("select",!!Bt),Bt?(localStorage.setItem((Ut=t==null?void 0:t.typeObj)==null?void 0:Ut.ID,JSON.stringify({Event:{Info:[At,Ft]}})),H({ID:(Xt=t==null?void 0:t.typeObj)==null?void 0:Xt.ID,Properties:{SelText:[At,Ft]}},"WS")):(localStorage.setItem((It=t==null?void 0:t.typeObj)==null?void 0:It.ID,JSON.stringify({Event:{Info:[1,1]}})),H({ID:(ae=t==null?void 0:t.typeObj)==null?void 0:ae.ID,Properties:{SelText:[1,1]}},"WS"))},yt=bt=>{var Bt;bt.stopPropagation();const Mt=bt.target,At=Mt.selectionStart,Ft=Mt.selectionEnd;if(console.log("Value of event key ",bt.key),bt.key==="Enter"){s(!1),console.log("Value of event key",ft),ft&&(dt(!1),E.send(JSON.stringify({Event:{EventName:"Change",ID:(Bt=t==null?void 0:t.typeObj)==null?void 0:Bt.ID,Info:[]}}))),r&&(console.log("On key down is "),r(bt),kt(bt));return}At!==Ft&&r&&(r(bt),kt(bt))},mt=()=>{const bt=t==null?void 0:t.gridValues;bt[(t==null?void 0:t.row)-1][t==null?void 0:t.column]=g=="Date"?p:K;const Mt=JSON.stringify({Event:{EventName:"CellChanged",ID:t==null?void 0:t.gridId,Row:t==null?void 0:t.row,Col:(t==null?void 0:t.column)+1,Value:g=="Date"?p:K}}),At=JSON.stringify({Event:{EventName:"CellChanged",Values:bt,CurCell:[t==null?void 0:t.row,(t==null?void 0:t.column)+1]}}),Ft=JSON.stringify({FormatCell:{Cell:[t==null?void 0:t.row,(t==null?void 0:t.column)+1],ID:t==null?void 0:t.gridId,Value:g=="Date"?p:K}});localStorage.setItem(t==null?void 0:t.gridId,At),t!=null&&t.gridEvent&&(t!=null&&t.gridEvent.some(Ut=>Ut[0]==="CellChanged"))&&(console.log(Mt),E.send(Mt),localStorage.setItem("isChanged",JSON.stringify({isChange:!0,value:g=="Date"?p:K})),t!=null&&t.formatString&&(console.log(Ft),E.send(Ft)))};_.useEffect(()=>{var bt;t.focused&&((bt=n==null?void 0:n.current)==null||bt.focus())},[t.focused]),_.useEffect(()=>{var bt,Mt;if(console.log("select useEffect",{selected:l}),!l)return console.log("select useEffect 2",{selected:l}),localStorage.setItem((bt=t==null?void 0:t.typeObj)==null?void 0:bt.ID,JSON.stringify({Event:{Info:[1,1]}})),H({ID:(Mt=t==null?void 0:t.typeObj)==null?void 0:Mt.ID,Properties:{SelText:[1,1]}},"WS"),()=>{console.log("select unmount")}},[t.focused]);const gt=()=>{if(g=="Date"){if((t==null?void 0:t.value)==p)return;mt()}else{if((t==null?void 0:t.value)==K)return;mt()}},kt=bt=>{var It,ae,$t,ue,Ot,we,Ht,se;const Mt=bt!=null&&bt.altKey?4:0,At=bt!=null&&bt.ctrlKey?2:0,Ft=bt!=null&&bt.shiftKey?1:0,Bt=(It=bt==null?void 0:bt.key)==null?void 0:It.charCodeAt(0);let Ut=Mt+At+Ft;const Xt=(ue=($t=(ae=t==null?void 0:t.typeObj)==null?void 0:ae.Properties)==null?void 0:$t.Event)==null?void 0:ue.some(Se=>Se[0]==="KeyPress");if(console.log("Value of event is as",Xt,(we=(Ot=t==null?void 0:t.typeObj)==null?void 0:Ot.Properties)==null?void 0:we.Event),!Xt){console.log("Coming here in exists");return}console.log(JSON.stringify({Event:{EventName:"KeyPress",ID:(Ht=t==null?void 0:t.typeObj)==null?void 0:Ht.ID,Info:[bt.key,Bt,bt.keyCode,Ut]}})),E.send(JSON.stringify({Event:{EventName:"KeyPress",ID:(se=t==null?void 0:t.typeObj)==null?void 0:se.ID,Info:[bt.key,Bt,bt.keyCode,Ut]}}))};if(g=="Date"){const bt=Bt=>{tt(Bt.target.value);const Ut=q4(Bt.target.value).format($);console.log("date picker",{input:Bt.target.value,ShortDate:$,selectedDate:Ut});let Xt=Wg(Bt.target.value)+1;et(Ut),f(Xt)},Mt=Bt=>{et(Bt.target.value)},At=()=>{n.current.showPicker()},Ft=()=>{const[Bt,Ut,Xt]=K.split("-"),It=`${Xt}-${Ut}-${Bt}`,ae=new Date(It),$t=q4(ae,$,!0);if($t.isValid()){const ue=$t.format("YYYY-MM-DD");tt(ue);const Ot=Wg(ue)+1;f(Ot)}else console.warn("Invalid date entered");s(!1),gt()};return vt.jsx(vt.Fragment,{children:a?vt.jsxs(vt.Fragment,{children:[vt.jsxs("div",{style:{display:"flex",alignItems:"center"},children:[vt.jsx("input",{ref:i,id:`${t==null?void 0:t.gridId}`,style:{border:0,outline:0,width:"100%",height:"100%",paddingLeft:"5px",paddingRight:"5px"},value:K,onChange:Mt,type:"text",onClick:Bt=>{},onBlur:Ft,onKeyDown:Bt=>{Bt.stopPropagation()}}),vt.jsx("button",{onClick:At,style:{border:"none",background:"transparent",cursor:"pointer",padding:0},children:"📅"})]}),vt.jsx("input",{id:`${t==null?void 0:t.gridId}`,type:"date",value:q4(new Date(at)).format("YYYY-MM-DD"),ref:n,onChange:bt,style:{display:"none"}})]}):vt.jsx("div",{onDoubleClick:Bt=>{s(!0)},style:{backgroundColor:t==null?void 0:t.backgroundColor,outline:0,paddingLeft:"5px",paddingRight:"5px"},children:t!=null&&t.formattedValue?t==null?void 0:t.formattedValue:K})})}return console.log("gridEdit",M,t),g=="LongNumeric"||g=="Numeric"?vt.jsx(vt.Fragment,{children:a?vt.jsx(jg,{className:"currency",allowLeadingZeros:!0,getInputRef:n,id:`${t==null?void 0:t.gridId}`,style:{width:"100%",border:0,outline:0,backgroundColor:t==null?void 0:t.backgroundColor,textAlign:"right",paddingRight:"5px",paddingLeft:"5px"},onValueChange:bt=>{if(!bt.value)return et(0);et(parseFloat(bt==null?void 0:bt.value))},decimalScale:b,value:K,onSelect:lt,decimalSeparator:Z,thousandSeparator:G,onBlur:bt=>{s(!1),gt()},onKeyDown:bt=>{bt.stopPropagation(),kt(bt)},onMouseDown:bt=>{var Mt;er(bt,E,M,(Mt=t==null?void 0:t.typeObj)==null?void 0:Mt.ID)},onMouseUp:bt=>{var Mt;rr(bt,E,M,(Mt=t==null?void 0:t.typeObj)==null?void 0:Mt.ID)},onMouseEnter:bt=>{var Mt;ir(bt,E,M,(Mt=t==null?void 0:t.typeObj)==null?void 0:Mt.ID)},onMouseMove:bt=>{var Mt;or(bt,E,M,(Mt=t==null?void 0:t.typeObj)==null?void 0:Mt.ID)},onMouseLeave:bt=>{var Mt;nr(bt,E,M,(Mt=t==null?void 0:t.typeObj)==null?void 0:Mt.ID)},onWheel:bt=>{var Mt;hr(bt,E,M,(Mt=t==null?void 0:t.typeObj)==null?void 0:Mt.ID)},onDoubleClick:bt=>{var Mt;mr(bt,E,M,(Mt=t==null?void 0:t.typeObj)==null?void 0:Mt.ID)}}):vt.jsx("div",{ref:o,onDoubleClick:bt=>{s(!0)},style:{backgroundColor:t==null?void 0:t.backgroundColor,outline:0,textAlign:"right",paddingRight:"5px"},children:t!=null&&t.formattedValue?t==null?void 0:t.formattedValue:vt.jsx(jg,{className:"currency",allowLeadingZeros:!0,id:`${t==null?void 0:t.gridId}`,style:{width:"100%",border:0,outline:0,backgroundColor:t==null?void 0:t.backgroundColor,textAlign:"right"},readOnly:!0,decimalScale:b,value:t==null?void 0:t.value,decimalSeparator:Z,thousandSeparator:G})})}):vt.jsx(vt.Fragment,{children:a?vt.jsx("input",{type:"text",id:`${t==null?void 0:t.gridId}`,ref:n,style:{outline:0,border:0,width:"100%",height:"100%",display:"flex",backgroundColor:t==null?void 0:t.backgroundColor,align:t==null?void 0:t.align,paddingLeft:"5px",paddingRight:"5px"},onSelect:lt,onDoubleClick:bt=>{var Mt;mr(bt,E,M,(Mt=t==null?void 0:t.typeObj)==null?void 0:Mt.ID),bt.stopPropagation()},value:K,onKeyDown:yt,onChange:bt=>{bt.stopPropagation(),dt(!0),et(bt.target.value)},onBlur:bt=>{s(!1),gt()},autoFocus:!0,onMouseDown:bt=>{var Mt;er(bt,E,M,(Mt=t==null?void 0:t.typeObj)==null?void 0:Mt.ID)},onMouseUp:bt=>{var Mt;rr(bt,E,M,(Mt=t==null?void 0:t.typeObj)==null?void 0:Mt.ID)},onMouseEnter:bt=>{var Mt;ir(bt,E,M,(Mt=t==null?void 0:t.typeObj)==null?void 0:Mt.ID)},onMouseMove:bt=>{var Mt;or(bt,E,M,(Mt=t==null?void 0:t.typeObj)==null?void 0:Mt.ID)},onMouseLeave:bt=>{var Mt;nr(bt,E,M,(Mt=t==null?void 0:t.typeObj)==null?void 0:Mt.ID)},onWheel:bt=>{var Mt;hr(bt,E,M,(Mt=t==null?void 0:t.typeObj)==null?void 0:Mt.ID)}}):vt.jsx("div",{ref:o,onDoubleClick:bt=>{s(!0)},autoFocus:!0,onKeyDown:bt=>console.log({e:bt}),style:{display:"flex",align:t==null?void 0:t.align,backgroundColor:t==null?void 0:t.backgroundColor,outline:0,height:"100%",width:"100%",paddingLeft:"5px",paddingRight:"5px"},children:t!=null&&t.formattedValue?t==null?void 0:t.formattedValue:t==null?void 0:t.value})})},hZ=({data:t})=>{var f,g;const r=_.useRef(null),{Items:n}=(f=t==null?void 0:t.typeObj)==null?void 0:f.Properties,[i,o]=_.useState(t==null?void 0:t.value),{findDesiredData:a,socket:s,handleData:l}=w1();_.useEffect(()=>{t.focused&&r.current.focus()},[t.focused]);const h=b=>{var E;const z=a(t==null?void 0:t.gridId),M=t==null?void 0:t.gridValues;M[(t==null?void 0:t.row)-1][t==null?void 0:t.column]=b,l({ID:t==null?void 0:t.gridId,Properties:{...z.Properties,Values:M,CurCell:[t==null?void 0:t.row,(t==null?void 0:t.column)+1]}},"WS");const I=JSON.stringify({Event:{EventName:"CellChanged",ID:t==null?void 0:t.gridId,Row:t==null?void 0:t.row,Col:(t==null?void 0:t.column)+1,Value:b}}),F=JSON.stringify({Event:{EventName:"CellChanged",Values:M,CurCell:[t==null?void 0:t.row,(t==null?void 0:t.column)+1]}});localStorage.setItem(t==null?void 0:t.gridId,F),(E=t==null?void 0:t.gridEvent)!=null&&E.some(R=>R[0]==="CellChanged")&&(console.log(I),s.send(I),localStorage.setItem("isChanged",JSON.stringify({isChange:!0,value:b})))},p=b=>{n.indexOf(b),h(b)};return vt.jsx("select",{onKeyDown:b=>b.preventDefault(),onClick:b=>console.log("click"),ref:r,value:i,style:{border:0,outline:0,width:"100%",height:"100%"},id:`${(g=t==null?void 0:t.typeObj)==null?void 0:g.ID}`,onChange:b=>{o(b.target.value),p(b.target.value)},children:n&&n.map((b,z)=>vt.jsx("option",{value:b,children:b}))})},uZ=({data:t})=>{var F,H;console.log("GridButton",t);const r=_.useRef(null),{handleData:n,socket:i,findDesiredData:o}=w1(),[a,s]=_.useState(t==null?void 0:t.value),[l,h]=_.useState(t==null?void 0:t.showInput),[p,f]=_.useState(!1);_.useEffect(()=>{var E;t.focused&&((E=r==null?void 0:r.current)==null||E.focus())},[t.focused,l]);const{Event:g}=(F=t==null?void 0:t.typeObj)==null?void 0:F.Properties,b=E=>{const R=o(t==null?void 0:t.gridId),W=t==null?void 0:t.gridValues;W[(t==null?void 0:t.row)-1][t==null?void 0:t.column]=E?1:0,n({ID:t==null?void 0:t.gridId,Properties:{...R.Properties,Values:W,CurCell:[t==null?void 0:t.row,(t==null?void 0:t.column)+1]}},"WS");const $=JSON.stringify({Event:{EventName:"CellChanged",ID:t==null?void 0:t.gridId,Row:t==null?void 0:t.row,Col:(t==null?void 0:t.column)+1,Value:E?1:0}}),G=JSON.stringify({Event:{EventName:"CellChanged",Values:W,CurCell:[t==null?void 0:t.row,(t==null?void 0:t.column)+1]}}),Z=JSON.stringify({FormatCell:{Cell:[t==null?void 0:t.row,(t==null?void 0:t.column)+1],ID:t==null?void 0:t.gridId,Value:E?1:0}});localStorage.setItem(t==null?void 0:t.gridId,G),console.log($),t!=null&&t.gridEvent&&(t!=null&&t.gridEvent.some(et=>et[0]==="CellChanged"))&&(t.formatString&&(i.send(Z),console.log(Z)),i.send($),localStorage.setItem("isChanged",JSON.stringify({isChange:!0,value:E?1:0})))},z=E=>{b(E)},M=(t==null?void 0:t.cellFont)&&((H=t==null?void 0:t.cellFont)==null?void 0:H.Properties);let I={fontFamily:M==null?void 0:M.PName,fontSize:(M!=null&&M.Size,"12px"),textDecoration:M!=null&&M.Underline&&(M==null?void 0:M.Underline)==1?"underline":"none",fontStyle:M!=null&&M.Italic&&(M==null?void 0:M.Italic)==1?"italic":"none",fontWeight:M!=null&&M.Weight?M==null?void 0:M.Weight:0};return vt.jsx(vt.Fragment,{children:l?vt.jsx("input",{ref:r,id:`${t==null?void 0:t.gridId}`,type:"checkbox",checked:a,onChange:E=>{s(E.target.checked),z(E.target.checked)},onBlur:()=>h(!1),style:{backgroundColor:t==null?void 0:t.backgroundColor,outline:0,marginTop:"3.5px",marginLeft:"5px"},onDoubleClick:E=>{var R;mr(E,i,g,(R=t==null?void 0:t.typeObj)==null?void 0:R.ID)},onMouseDown:E=>{var R;er(E,i,g,(R=t==null?void 0:t.typeObj)==null?void 0:R.ID)},onMouseUp:E=>{var R;rr(E,i,g,(R=t==null?void 0:t.typeObj)==null?void 0:R.ID)},onMouseEnter:E=>{var R;ir(E,i,g,(R=t==null?void 0:t.typeObj)==null?void 0:R.ID)},onMouseMove:E=>{var R;or(E,i,g,(R=t==null?void 0:t.typeObj)==null?void 0:R.ID)},onMouseLeave:E=>{var R;nr(E,i,g,(R=t==null?void 0:t.typeObj)==null?void 0:R.ID)},onWheel:E=>{var R;hr(E,i,g,(R=t==null?void 0:t.typeObj)==null?void 0:R.ID)}}):vt.jsx("div",{id:`${t==null?void 0:t.gridId}`,onDoubleClick:E=>{h(!0),f(!0)},ref:r,tabIndex:"1",style:{backgroundColor:t==null?void 0:t.backgroundColor,...I,outline:0,paddingRight:"5px"},children:t!=null&&t.formattedValue?t==null?void 0:t.formattedValue:vt.jsx("input",{ref:r,id:`${t==null?void 0:t.gridId}`,type:"checkbox",checked:a,onChange:E=>{s(E.target.checked),z(E.target.checked)},style:{backgroundColor:t==null?void 0:t.backgroundColor,outline:0,marginTop:"3.5px",marginLeft:"5px"}})})})},pZ=({data:t,keyPress:r})=>{var a,s;const n=_.useRef(null),[i,o]=_.useState(!1);return _.useEffect(()=>{var l;t.focused&&((l=n==null?void 0:n.current)==null||l.focus())},[t.focused]),vt.jsx(vt.Fragment,{children:i?vt.jsx("div",{style:{display:"flex",alignItems:"center",justifyContent:t==null?void 0:t.align,paddingLeft:"5px",paddingRight:"5px"},children:vt.jsx("div",{style:{outline:0,height:"100%",width:t.width*.9,textAlign:t==null?void 0:t.align,backgroundColor:t==null?void 0:t.backgroundColor,whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis"},onBlur:()=>o(!1),ref:n,id:`${t==null?void 0:t.row}-${t==null?void 0:t.column}`,tabIndex:"0",children:t==null?void 0:t.value})}):vt.jsx("div",{style:{backgroundColor:t==null?void 0:t.backgroundColor,outline:0,textAlign:(s=(a=t==null?void 0:t.typeObj)==null?void 0:a.Properties)==null?void 0:s.Justify,paddingRight:"5px",paddingLeft:"5px"},onDoubleClick:l=>o(!0),children:t!=null&&t.formattedValue?t==null?void 0:t.formattedValue:t.value})})},dZ=({data:t})=>lZ.isArray(t==null?void 0:t.value)?vt.jsx("div",{style:{backgroundColor:t==null?void 0:t.backgroundColor,color:t==null?void 0:t.color,display:"flex",justifyContent:"flex-end",alignItems:"center",flexDirection:"column",height:"100%",paddingBottom:"5px"},children:t==null?void 0:t.value.map((r,n)=>r===""?vt.jsx("br",{},n):vt.jsx("div",{style:{lineHeight:"96%"},children:r},n))}):vt.jsx("div",{style:{backgroundColor:t==null?void 0:t.backgroundColor,color:t==null?void 0:t.color},children:t==null?void 0:t.value}),fZ=({data:t})=>{var g,b,z,M,I,F;const r=_.useRef(),{socket:n}=w1(),[i,o]=_.useState(!1);_.useEffect(()=>{var H;t.focused&&((H=r==null?void 0:r.current)==null||H.focus())},[t.focused]),_.useEffect(()=>{},[i]);const{Event:a}=(g=t==null?void 0:t.typeObj)==null?void 0:g.Properties,s=(t==null?void 0:t.cellFont)&&((b=t==null?void 0:t.cellFont)==null?void 0:b.Properties),l=()=>{o(!1)},h=()=>{o(!0)};let p={fontFamily:s==null?void 0:s.PName,fontSize:(s!=null&&s.Size,"12px"),textDecoration:s!=null&&s.Underline&&(s==null?void 0:s.Underline)==1?"underline":"none",fontStyle:s!=null&&s.Italic&&(s==null?void 0:s.Italic)==1?"italic":"none",fontWeight:s!=null&&s.Weight?s==null?void 0:s.Weight:0};const f=H=>{var K,et,at,tt;const E=H!=null&&H.altKey?4:0,R=H!=null&&H.ctrlKey?2:0,W=H!=null&&H.shiftKey?1:0,$=(K=H==null?void 0:H.key)==null?void 0:K.charCodeAt(0);let G=E+R+W;(tt=(at=(et=t==null?void 0:t.typeObj)==null?void 0:et.Properties)==null?void 0:at.Event)!=null&&tt.some(ft=>ft[0]==="KeyPress")&&(console.log(JSON.stringify({Event:{EventName:"KeyPress",ID:t==null?void 0:t.ID,Info:[H.key,$,H.keyCode,G]}})),n.send(JSON.stringify({Event:{EventName:"KeyPress",ID:t==null?void 0:t.ID,Info:[H.key,$,H.keyCode,G]}})))};return vt.jsx(vt.Fragment,{children:i?vt.jsx("div",{style:{backgroundColor:t==null?void 0:t.backgroundColor,outline:0,...p,textAlign:(F=(I=t==null?void 0:t.typeObj)==null?void 0:I.Properties)==null?void 0:F.Justify,paddingRight:"5px"},onKeyDown:H=>{H.stopPropagation(),f(H)},onBlur:l,ref:r,onMouseDown:H=>{var E;er(H,n,a,(E=t==null?void 0:t.typeObj)==null?void 0:E.ID)},onMouseUp:H=>{var E;rr(H,n,a,(E=t==null?void 0:t.typeObj)==null?void 0:E.ID)},onMouseEnter:H=>{var E;ir(H,n,a,(E=t==null?void 0:t.typeObj)==null?void 0:E.ID)},onMouseMove:H=>{var E;or(H,n,a,(E=t==null?void 0:t.typeObj)==null?void 0:E.ID)},onMouseLeave:H=>{var E;nr(H,n,a,(E=t==null?void 0:t.typeObj)==null?void 0:E.ID)},onWheel:H=>{var E;hr(H,n,a,(E=t==null?void 0:t.typeObj)==null?void 0:E.ID)},onDoubleClick:H=>{var E;mr(H,n,a,(E=t==null?void 0:t.typeObj)==null?void 0:E.ID)},children:t!=null&&t.focused?t==null?void 0:t.value:t==null?void 0:t.formattedValue}):vt.jsx("div",{ref:r,style:{backgroundColor:t==null?void 0:t.backgroundColor,outline:0,...p,textAlign:(M=(z=t==null?void 0:t.typeObj)==null?void 0:z.Properties)==null?void 0:M.Justify,paddingRight:"5px"},onKeyDown:H=>{H.stopPropagation(),f(H)},onDoubleClick:h,onBlur:l,id:t.gridId,children:t==null?void 0:t.formattedValue})})},vZ=({data:t,onKeyDown1:r})=>{if((t==null?void 0:t.type)=="Edit")return vt.jsx(cZ,{data:t,onKeyDown1:r});if((t==null?void 0:t.type)=="Button")return vt.jsx(uZ,{data:t});if((t==null?void 0:t.type)=="cell"||(t==null?void 0:t.type)=="rowTitle")return vt.jsx(pZ,{data:t});if((t==null?void 0:t.type)=="header")return vt.jsx(dZ,{data:t});if((t==null?void 0:t.type)=="Combo")return vt.jsx(hZ,{data:t});if((t==null?void 0:t.type)=="Label")return vt.jsx(fZ,{data:t})},gZ=({data:t})=>{const r=t==null?void 0:t.ID,{findDesiredData:n,socket:i,proceed:o,setProceed:a,proceedEventArray:s,setProceedEventArray:l,findAggregatedPropertiesData:h,handleData:p,currentEventRef:f,updateCurrentEvent:g}=w1(),[b,z]=_.useState(null),M=y4(document.getElementById(Y1(t==null?void 0:t.ID))),I=_.useRef(null),{Size:F,Values:H,Input:E,ColTitles:R,RowTitles:W,CellWidths:$,CellHeights:G,Visible:Z,CurCell:K,CellTypes:et,ShowInput:at,FormattedValues:tt,BCol:ft,CellFonts:dt,ColTitleBCol:ht,ColTitleFCol:lt,TitleHeight:yt,TitleWidth:mt,FormatString:gt,VScroll:kt=0,HScroll:_t=0,Attach:bt,Event:Mt,CSS:At}=t==null?void 0:t.Properties,[Ft,Bt]=_.useState(F[0]),[Ut,Xt]=_.useState(F[1]),[It,ae]=_.useState(0),[$t,ue]=_.useState(0),[Ot,we]=_.useState(K?K[0]:(R==null?void 0:R.length)>0?1:0),[Ht,se]=_.useState(K?K[1]:mt===0?1:0),[Se,Kt]=_.useState({isClicked:!1,row:Ot,column:Ht});_.useEffect(()=>{if(I.current.focus(),K){let st,Et;I.current.focus(),st=K?K[0]:(W==null?void 0:W.length)>0?1:0,Et=K?K[1]:mt===0?1:0,we(zt=>zt!==K[0]?st:zt),se(zt=>zt!==K[1]?Et:zt)}},[K]),_.useEffect(()=>{if(s[f.eventID+"KeyPress"]==1){const st=f.keyEvent;xe(st),a(!1),l(Et=>({...Et,[f.eventID+"KeyPress"]:0}))}else if(s[f.eventID+"CellMove"]==1){if(Se.isClicked){Ie(Se.row,Se.column),Kt({isClicked:!1});return}const st=f.keyEvent;Wt(st)}},[Object.keys(s).length]);const fe=Yr(t==null?void 0:t.Properties);_.useEffect(()=>{bt&&(Xt((M==null?void 0:M.width)-73),Bt((M==null?void 0:M.height)-73))},[M]),_.useEffect(()=>{var st;ue(R?R==null?void 0:R.length:((st=H[0])==null?void 0:st.length)+1),H&&ae((H==null?void 0:H.length)+1)},[t]);const ne=(st,Et,zt)=>{if(Et>$t||Et<=0)return;const Rt=zt?0:1,Vt=Ia();z(Vt),g({curEvent:"CellMove",eventID:Vt,keyEvent:f.keyEvent});const Qt=JSON.parse(localStorage.getItem("isChanged")),ve=JSON.stringify({Event:{ID:t==null?void 0:t.ID,EventName:"CellMove",EventID:Vt,Info:[st,Et,Rt,0,zt,Qt&&Qt.isChange?1:0,Qt&&Qt?Qt.value:""]}});Mt&&(Mt==null?void 0:Mt.some(ke=>ke[0]==="CellMove"))?i.send(ve):p({ID:t==null?void 0:t.ID,Properties:{CurCell:[st,Et]}},"WS")},ce=st=>{var d1;const Et=st.altKey?4:0,zt=st.ctrlKey?2:0,Rt=st.shiftKey?1:0,Vt=st.key.charCodeAt(0),Qt=Ia();z(Qt),g({curEvent:"KeyPress",eventID:Qt,keyEvent:st.key});let ve=Et+zt+Rt;const je=Mt&&(Mt==null?void 0:Mt.some(Le=>Le[0].toLowerCase()==="keypress"));let ke=Object.keys(t),c1;const Tt=ke.reduce((Le,ge)=>{var h1,M1,Z1,zr,Xr,jn;return(Z1=(M1=(h1=t[ge])==null?void 0:h1.Properties)==null?void 0:M1.Event)!=null&&Z1.some(Gn=>Gn[0].toLowerCase()==="keypress")&&(c1=ge),[...Le,(jn=(Xr=(zr=t[ge])==null?void 0:zr.Properties)==null?void 0:Xr.Event)==null?void 0:jn.some(Gn=>Gn[0].toLowerCase()==="keypress")]},[]).some(Le=>Le===!0),te=JSON.stringify({Event:{EventName:"KeyPress",ID:t==null?void 0:t.ID,EventID:Qt,Info:[st.key,Vt,st.keyCode,ve]}}),Ve=JSON.stringify({Event:{EventName:"KeyPress",ID:(d1=t[c1])==null?void 0:d1.ID,EventID:Qt,Info:[st.key,Vt,st.keyCode,ve]}});je&&!Tt&&i.send(te),Tt&&i.send(Ve);const He=["ArrowRight","ArrowLeft","ArrowUp","ArrowDown"].some(Le=>st.key===Le);if(!je&&!Tt){Wt(st.key);return}He&&I.current.focus(),st.preventDefault()},xe=st=>{if(st==="ArrowRight"){const Et=Math.min(Ht+1,R?$t:$t-1);if(Ht===Et)return;ne(Ot,Et,0)}else if(st==="ArrowLeft"){const Et=Math.max(Ht-1,1);if(Ht===Et)return;ne(Ot,Et,0)}else if(st==="ArrowUp"){const Et=Math.max(Ot-1,1);if(Ot===Et)return;ne(Et,Ht,0)}else if(st==="ArrowDown"||st==="Enter"){const Et=Math.min(Ot+1,It-1);if(Ot==It-1||Ot===Et)return;ne(Et,Ht,0)}else if(st==="PageDown"){const Et=Math.min(Ot+9,It-1);ne(Et,Ht,0)}else if(st==="PageUp"){const Et=Math.max(Ot-9,1);if(Ot==Et)return;ne(Et,Ht,0)}},Wt=st=>{if(st==="ArrowRight"){const Et=Math.min(Ht+1,R?$t:$t-1);se(Et),p({ID:t==null?void 0:t.ID,Properties:{CurCell:[Ot,Et]}},"WS")}else if(st==="ArrowLeft"){const Et=Math.max(Ht-1,1);se(Et),p({ID:t==null?void 0:t.ID,Properties:{CurCell:[Ot,Et]}},"WS")}else if(st==="ArrowUp"){const Et=Math.max(Ot-1,1);we(Et),p({ID:t==null?void 0:t.ID,Properties:{CurCell:[Et,Ht]}},"WS")}else if(st==="ArrowDown"){const Et=Math.min(Ot+1,It-1);we(Et),p({ID:t==null?void 0:t.ID,Properties:{CurCell:[Et,Ht]}},"WS")}else if(st==="PageDown"){const Et=Math.min(Ot+9,It-1);we(Et),p({ID:t==null?void 0:t.ID,Properties:{CurCell:[Et,Ht]}},"WS")}else if(st==="PageUp"){const Et=Math.max(Ot-9,1);we(Et),p({ID:t==null?void 0:t.ID,Properties:{CurCell:[Et,Ht]}},"WS")}},qt=()=>{var Et,zt,Rt;let st=[];if(R){let Vt=[],Qt={value:"",type:"header",width:mt||100,height:yt||20};mt===0||Vt.push(Qt);for(let ve=0;ve<(R==null?void 0:R.length);ve++){let je={value:R[ve],type:"header",backgroundColor:Hr(ht),color:Hr(lt),width:$?Array.isArray($)?$[ve]:$:100,height:yt||20};Vt.push(je)}st.push(Vt)}else if(!R){let Vt=Lq($t).map(Qt=>({value:Qt,type:"header",width:mt||100,height:yt||20}));st.push(Vt)}if(E){if(E)for(let Vt=0;Vt<(H==null?void 0:H.length);Vt++){let Qt=[],ve=et&&et[Vt][0];const je=ft&&ft[ve-1];let ke={type:"rowTitle",value:W?W[Vt]:Vt+1,width:mt||100,height:G?Array.isArray(G)?G[Vt]:G:20,align:"end",backgroundColor:Hr(je)};mt==null?Qt.push(ke):mt==0||Qt.push(ke);for(let c1=0;c1<$t;c1++){let Oe=et&&et[Vt][c1];const Tt=h((E==null?void 0:E.length)>1?E&&E[Oe-1]:E[0]),te=((Et=st==null?void 0:st.Properties)==null?void 0:Et.Event)&&((zt=st==null?void 0:st.Properties)==null?void 0:zt.Event),Ve=ft&&ft[Oe-1],He=n(dt&&dt[Oe-1]);let d1={type:Tt?(Rt=Tt==null?void 0:Tt.Properties)==null?void 0:Rt.Type:"cell",value:H[Vt][c1],event:te,backgroundColor:Hr(Ve),cellFont:He,typeObj:Tt,formattedValue:tt&&tt[Vt][c1],formatString:gt&>[Oe-1],width:$?Array.isArray($)?$[c1]:$:100,height:G?Array.isArray(G)?G[Vt]:G:20};Qt.push(d1)}st.push(Qt)}}else for(let Vt=0;Vt<(H==null?void 0:H.length);Vt++){let Qt=et&&et[Vt][0];const ve=ft&&ft[Qt-1];let je=[],ke={type:"rowTitle",value:W?W[Vt]:Vt+1,width:W&&mt||100,height:G?Array.isArray(G)?G[Vt]:G:20,align:"end",backgroundColor:Hr(ve)};mt==null?je.push(ke):mt==0||je.push(ke);for(let c1=0;c1<=$t;c1++){if(H[Vt][c1]===void 0)continue;let Oe={type:"cell",value:H[Vt][c1],width:$?Array.isArray($)?$[c1]:$:100,height:G?Array.isArray(G)?G[c1]:G:20,align:isNaN(H[Vt][c1])?"start":"end",paddingLeft:isNaN(parseInt(H[Vt][c1]))?"5px":"0px"};je.push(Oe)}st.push(je)}return st},Ee=(st,Et)=>{Kt({isClicked:!0,row:st,column:Et}),!(st==Ot&&Et==Ht)&&ne(st,Et,1)},Ie=(st,Et)=>{se(Et),we(st),!(st==Ot&&Et==Ht)&&p({ID:t==null?void 0:t.ID,Properties:{CurCell:[st,Et]}},"WS")},Pe=qt(),Yt=j1(At);return vt.jsx(vt.Fragment,{children:vt.jsx("div",{tabIndex:0,ref:I,onKeyDown:ce,onMouseDown:st=>{er(st,i,Mt,t==null?void 0:t.ID)},onMouseUp:st=>{rr(st,i,Mt,t==null?void 0:t.ID)},onMouseEnter:st=>{ir(st,i,Mt,t==null?void 0:t.ID)},onMouseMove:st=>{or(st,i,Mt,t==null?void 0:t.ID)},onMouseLeave:st=>{nr(st,i,Mt,t==null?void 0:t.ID)},onWheel:st=>{hr(st,i,Mt,t==null?void 0:t.ID)},onDoubleClick:st=>{var Et;mr(st,i,Mt,(Et=t==null?void 0:t.typeObj)==null?void 0:Et.ID)},id:t==null?void 0:t.ID,style:{...fe,height:Ft,width:Ut,border:"1px solid black",overflow:R?"hidden":"auto",background:"white",display:Z==0?"none":"block",overflowX:_t==-3?"scroll":(_t==-1||_t==-2,"auto"),overflowY:kt==-3?"scroll":(kt==-1||_t==-2,"auto"),...Yt},children:Pe==null?void 0:Pe.map((st,Et)=>vt.jsx("div",{style:{display:"flex"},id:`row-${Et}-cell`,children:st.map((zt,Rt)=>{const Vt=Ot===Et&&Ht===(mt===0?Rt+1:Rt);return vt.jsx("div",{onClick:()=>{zt.type==="rowTitle"||zt.type==="header"||Ee(Et,mt===0?Rt+1:Rt)},id:`${r}`,style:{borderRight:Vt?"1px solid blue":"1px solid #EFEFEF",borderBottom:Vt?"1px solid blue":"1px solid #EFEFEF",fontSize:"12px",minHeight:`${zt==null?void 0:zt.height}px`,maxHeight:`${zt==null?void 0:zt.height}px`,minWidth:`${zt==null?void 0:zt.width}px`,maxWidth:`${zt==null?void 0:zt.width}px`,backgroundColor:Ot===Et&&zt.type=="rowTitle"||Ht===(mt===0?Rt+1:Rt)&&zt.type=="header"?"lightblue":Hr(zt==null?void 0:zt.backgroundColor),textAlign:zt.type=="header"?"center":zt==null?void 0:zt.align,overflow:"hidden",...(zt==null?void 0:zt.type)!=="header"&&!Array.isArray(zt==null?void 0:zt.value)&&{lineHeight:`${zt==null?void 0:zt.height}px`},paddingLeft:zt==null?void 0:zt.paddingLeft},children:vt.jsx(vZ,{data:{...zt,row:Et,column:mt===0?Rt+1:Rt,gridValues:H,gridEvent:Mt,showInput:at,gridId:r,focused:Vt,backgroundColor:zt==null?void 0:zt.backgroundColor}},zt==null?void 0:zt.type)})})}))})})},mZ=({data:t,value:r,event:n="",row:i="",column:o="",location:a="",values:s=[],T:l=""})=>{const{socket:h,dataRef:p,findDesiredData:f,handleData:g,addChangeEvent:b,fontScale:z}=w1(),M=JSON.parse(Ui(p.current,"Locale")),{ShortDate:I,Thousand:F,Decimal:H}=M==null?void 0:M.Properties;let E={...Yr(t==null?void 0:t.Properties)};const[R,W]=_.useState("text"),[$,G]=_.useState(""),[Z,K]=_.useState(""),[et,at]=_.useState(""),[tt,ft]=_.useState("⌈"),[dt,ht]=_.useState(null);_.useRef();const{FieldType:lt,MaxLength:yt,FCol:mt,Decimal:gt,Visible:kt,Event:_t,FontObj:bt,Size:Mt,EdgeStyle:At,Border:Ft=0,CSS:Bt,Active:Ut}=t==null?void 0:t.Properties,Xt=t==null?void 0:t.Properties.hasOwnProperty("Text"),It=t==null?void 0:t.Properties.hasOwnProperty("Value"),ae=t==null?void 0:t.Properties.hasOwnProperty("Password"),$t=_.useRef(null),ue=f(bt&&bt),Ot=ue&&(ue==null?void 0:ue.Properties),we=j1(Bt);console.log("291",{dateFormat:M,emitValue:Z,parse:parseInt(Z),data:t});const Ht=_.useCallback(()=>{var Yt,st,Et,zt,Rt,Vt,Qt,ve,je,ke,c1,Oe,Tt,te,Ve,He,d1,Le,ge,h1;if(a==="inGrid"){if(lt==="Date"){K(r),at(r);const M1=$g(r);return G(q4(M1).format(I))}return K(r),at(r),G(r)}if(!((st=(Yt=t==null?void 0:t.Properties)==null?void 0:Yt.FieldType)!=null&&st.includes("Numeric")))return ae?(at(Mh((zt=(Et=t==null?void 0:t.Properties)==null?void 0:Et.Text)==null?void 0:zt.length)),K((Rt=t==null?void 0:t.Properties)==null?void 0:Rt.Text),G(Mh((Qt=(Vt=t==null?void 0:t.Properties)==null?void 0:Vt.Text)==null?void 0:Qt.length))):(K((ve=t==null?void 0:t.Properties)==null?void 0:ve.Text),at((je=t==null?void 0:t.Properties)==null?void 0:je.Text),G((ke=t==null?void 0:t.Properties)==null?void 0:ke.Text));if((Oe=(c1=t==null?void 0:t.Properties)==null?void 0:c1.FieldType)!=null&&Oe.includes("Numeric"))return ae?(at(Mh((te=(Tt=t==null?void 0:t.Properties)==null?void 0:Tt.Value)==null?void 0:te.length)),K((Ve=t==null?void 0:t.Properties)==null?void 0:Ve.Value),G(Mh((d1=(He=t==null?void 0:t.Properties)==null?void 0:He.Value)==null?void 0:d1.length))):(at((Le=t==null?void 0:t.Properties)==null?void 0:Le.Value),K((ge=t==null?void 0:t.Properties)==null?void 0:ge.Value),G((h1=t==null?void 0:t.Properties)==null?void 0:h1.Value))},[a,lt,r,I,Xt,ae,t,It]),se=()=>{$t.current&&$t.current.select()},Se=_.useCallback(()=>{lt==="Numeric"?W("number"):lt==="Date"?W("date"):ae&&W("password")},[lt,ae]);_.useEffect(()=>{Se()},[Se]),_.useEffect(()=>{Ht()},[Ht]),a=="inGrid"?E={...E,border:"none",color:mt?Hr(mt):"black"}:E={...E,borderTop:0,borderLeft:0,borderRight:0,borderBottom:"1px solid black",color:mt?Hr(mt):"black"};const Kt=(Yt,st,Et,zt)=>{const Rt=Et?0:1,Vt=JSON.stringify({Event:{ID:Y1(t==null?void 0:t.ID),EventName:"CellMove",Info:[Yt,st,Rt,0,Et,zt]}});n&&n.some(ve=>ve[0]==="CellMove")&&(console.log(Vt),h.send(Vt))},fe=()=>{if(a!=="inGrid")return;const zt=$t.current.parentElement.parentElement.parentElement.nextSibling;Kt(parseInt(i)+1,parseInt(o),0,Z);const Rt=zt==null?void 0:zt.querySelectorAll("input");Rt&&Rt&&Rt.forEach(Vt=>{Vt.id===(t==null?void 0:t.ID)&&Vt.select()})},ne=()=>{var Vt,Qt;if(a!=="inGrid")return;const Et=$t.current.parentElement.parentElement.nextSibling,zt=gl(p.current,Et==null?void 0:Et.id);let Rt=Et==null?void 0:Et.querySelectorAll(zt);(Rt==null?void 0:Rt.length)==0&&(Rt=Et==null?void 0:Et.querySelectorAll("span")),Kt(parseInt(i),parseInt(o)+1,0,Z),Rt&&((Vt=Rt[0])==null||Vt.focus()),Rt&&((Qt=Rt[0])==null||Qt.select())},ce=()=>{var Vt;if(a!=="inGrid")return;const Et=$t.current.parentElement.parentElement.previousSibling,zt=gl(p.current,Et==null?void 0:Et.id),Rt=Et==null?void 0:Et.querySelectorAll(zt);if(Kt(parseInt(i),parseInt(o)+1,0,Z),!!Rt)return zt=="select"?Rt&&Rt[0].focus():Rt&&((Vt=Rt[0])==null?void 0:Vt.select())},xe=()=>{if(a!=="inGrid")return;const zt=$t.current.parentElement.parentElement.parentElement.previousSibling;Kt(parseInt(i)-1,parseInt(o),0,Z);const Rt=zt==null?void 0:zt.querySelectorAll("input");Rt&&Rt&&Rt.forEach(Vt=>{Vt.id===(t==null?void 0:t.ID)&&Vt.select()})},Wt=Yt=>{if(Yt.key=="ArrowRight"?ne():Yt.key=="ArrowLeft"?ce():Yt.key=="ArrowDown"||Yt.key=="Enter"?fe():Yt.key=="ArrowUp"&&xe(),!(_t&&_t.some(je=>je[0]==="KeyPress")))return;const Et=Ia();ht(Et);const zt=Yt.altKey?4:0,Rt=Yt.ctrlKey?2:0,Vt=Yt.shiftKey?1:0,Qt=Yt.key.charCodeAt(0);let ve=zt+Rt+Vt;console.log(JSON.stringify({Event:{EventName:"KeyPress",ID:t==null?void 0:t.ID,EventID:Et,Info:[Yt.key,Qt,Yt.keyCode,ve]}})),h.send(JSON.stringify({Event:{EventName:"KeyPress",ID:t==null?void 0:t.ID,EventID:Et,Info:[Yt.key,Qt,Yt.keyCode,ve]}}))},qt=()=>{var Rt,Vt;let Yt;lt==="Date"?(Yt=JSON.stringify({Event:{EventName:"Change",ID:t==null?void 0:t.ID,Info:Z}}),g({ID:t==null?void 0:t.ID,Properties:{Value:Z,Text:$}},"WS")):(Yt=JSON.stringify({Event:{EventName:"Change",ID:t==null?void 0:t.ID,Info:lt&<=="LongNumeric"||lt=="Numeric"?parseInt(Z):Z}}),g({ID:t==null?void 0:t.ID,Properties:{...lt==="LongNumeric"||lt==="Numeric"?{Value:parseInt(Z)}:{Text:Z}}},"WS")),localStorage.setItem(t==null?void 0:t.ID,Yt),localStorage.setItem("shouldChangeEvent",t.Properties.hasOwnProperty("Event"));const st=JSON.parse(localStorage.getItem(tt));if(t.Properties.hasOwnProperty("Event")){const Qt=JSON.stringify({Event:{EventName:"Change",ID:tt,Info:[t==null?void 0:t.ID]}}),ve=((Rt=t==null?void 0:t.Properties)==null?void 0:Rt.Text)||((Vt=t==null?void 0:t.Properties)==null?void 0:Vt.Value)||"";console.log("value focused",{value:r,emitValue:Z,originalValue:ve},st,st.Event.EventName!=="Select",ve!==Z),tt&&st.Event.EventName!=="Select"&&ve!==Z&&tt!==t.ID&&(console.log("focused",st,st.Event.EventName!=="Select",ve!==Z),h.send(Qt))}if(!(_t&&_t.some(Qt=>Qt[0]==="Change")))return;const zt=JSON.stringify({Event:{EventName:"Change",ID:t==null?void 0:t.ID,Info:[]}});localStorage.setItem("change-event",zt)},Ee=()=>{const Yt=f(Y1(t==null?void 0:t.ID));s[parseInt(i)-1][parseInt(o)-1]=Z,g({ID:Y1(t==null?void 0:t.ID),Properties:{...Yt.Properties,Values:s,CurCell:[parseInt(i),parseInt(o)]}},"WS");const st=JSON.stringify({Event:{EventName:"CellChanged",ID:Y1(t==null?void 0:t.ID),Row:parseInt(i),Col:parseInt(o),Value:Z}}),Et=JSON.stringify({Event:{EventName:"CellChanged",Values:s,CurCell:[i,o]}}),zt=JSON.stringify({FormatCell:{Cell:[i,o],ID:Y1(t==null?void 0:t.ID),Value:Z}});localStorage.setItem(Y1(t==null?void 0:t.ID),Et),n&&n.some(Vt=>Vt[0]==="CellChanged")&&(console.log(st),h.send(st),formatString&&(console.log(zt),h.send(zt)))},Ie=()=>{a=="inGrid"?r!=Z&&(qt(),Ee()):qt()},Pe=()=>{const Yt=localStorage.getItem("current-focus");ft(Yt);const st=JSON.stringify({Event:{EventName:"GotFocus",ID:t==null?void 0:t.ID,Info:Yt?[Yt]:[""]}});localStorage.setItem("current-focus",t==null?void 0:t.ID),!(!(_t&&_t.some(zt=>zt[0]==="GotFocus"))||Yt==(t==null?void 0:t.ID))&&(console.log(st),h.send(st))};if(E={...E,fontFamily:Ot==null?void 0:Ot.PName,fontSize:Ot!=null&&Ot.Size?`${Ot.Size*z}px`:`${12*z}px`,textDecoration:Ot!=null&&Ot.Underline&&(Ot==null?void 0:Ot.Underline)==1?"underline":"none",fontStyle:Ot!=null&&Ot.Italic&&(Ot==null?void 0:Ot.Italic)==1?"italic":"none",fontWeight:Ot!=null&&Ot.Weight?Ot==null?void 0:Ot.Weight:0},R=="date"){const Yt=()=>{$t.current.select(),$t.current.showPicker()},st=Et=>{const zt=q4(Et.target.value).format(I);let Rt=Wg(Et.target.value)+1;G(zt),K(Rt)};return vt.jsxs(vt.Fragment,{children:[vt.jsx("input",{id:t==null?void 0:t.ID,style:{...E,borderRadius:"2px",fontSize:"12px",zIndex:1,display:kt==0?"none":"block",paddingLeft:"5px",...we},value:$,type:"text",readOnly:!0,onClick:Yt,onBlur:()=>{Ie()},onKeyDown:Et=>Wt(Et),onMouseDown:Et=>{er(Et,h,_t,t==null?void 0:t.ID)},onMouseUp:Et=>{rr(Et,h,_t,t==null?void 0:t.ID)},onMouseEnter:Et=>{ir(Et,h,_t,t==null?void 0:t.ID)},onMouseMove:Et=>{or(Et,h,_t,t==null?void 0:t.ID)},onMouseLeave:Et=>{nr(Et,h,_t,t==null?void 0:t.ID)},onWheel:Et=>{hr(Et,h,_t,t==null?void 0:t.ID)},onDoubleClick:Et=>{mr(Et,h,_t,t==null?void 0:t.ID)}}),vt.jsx("input",{id:(t==null?void 0:t.ID)+".Picker",type:"date",ref:$t,onChange:st,disabled:Ut===0,style:{...E,position:"absolute",zIndex:1,display:"none"}})]})}return lt=="LongNumeric"||lt=="Numeric"?vt.jsx(jg,{className:"currency",allowLeadingZeros:!0,getInputRef:$t,onClick:se,id:t==null?void 0:t.ID,disabled:Ut===0,style:{...E,width:Mt?Mt[1]:"100%",zIndex:1,display:kt==0?"none":"block",border:Ft&&Ft=="1"||At&&At=="Ridge"?"1px solid #6A6A6A":"none",textAlign:"right",verticalAlign:"text-top",paddingBottom:"6px",paddingRight:"2px",...we},onValueChange:Yt=>{G(Yt.value),K(Yt.value)},decimalScale:gt,value:$,decimalSeparator:H,thousandSeparator:lt=="LongNumeric"&&F,onBlur:()=>Ie(),onKeyDown:Yt=>Wt(Yt),onFocus:Pe,onMouseDown:Yt=>{er(Yt,h,_t,t==null?void 0:t.ID)},onMouseUp:Yt=>{rr(Yt,h,_t,t==null?void 0:t.ID)},onMouseEnter:Yt=>{ir(Yt,h,_t,t==null?void 0:t.ID)},onMouseMove:Yt=>{or(Yt,h,_t,t==null?void 0:t.ID)},onMouseLeave:Yt=>{nr(Yt,h,_t,t==null?void 0:t.ID)},onWheel:Yt=>{hr(Yt,h,_t,t==null?void 0:t.ID)},onDoubleClick:Yt=>{mr(Yt,h,_t,t==null?void 0:t.ID)}}):vt.jsx("input",{id:t.ID,ref:$t,value:$,onClick:se,type:R,disabled:Ut===0,onChange:Yt=>{lt=="Char"&&(K(Yt.target.value),G(Yt.target.value)),lt||(K(Yt.target.value),G(Yt.target.value))},onBlur:()=>{Ie()},onKeyDown:Yt=>Wt(Yt),style:{...E,width:Mt?Mt[1]:"100%",borderRadius:"2px",zIndex:1,display:kt==0?"none":"block",paddingLeft:"5px",border:Ft&&Ft=="1"||At&&At=="Ridge"?"1px solid #6A6A6A":"none",...Ut===0?{backgroundColor:"field",color:"#838383"}:{},...we},maxLength:yt,onFocus:Pe,onMouseDown:Yt=>{er(Yt,h,_t,t==null?void 0:t.ID)},onMouseUp:Yt=>{rr(Yt,h,_t,t==null?void 0:t.ID)},onMouseEnter:Yt=>{ir(Yt,h,_t,t==null?void 0:t.ID)},onMouseMove:Yt=>{or(Yt,h,_t,t==null?void 0:t.ID)},onMouseLeave:Yt=>{nr(Yt,h,_t,t==null?void 0:t.ID)},onWheel:Yt=>{hr(Yt,h,_t,t==null?void 0:t.ID)},onDoubleClick:Yt=>{mr(Yt,h,_t,t==null?void 0:t.ID)}})},yZ=({data:t,inputValue:r,event:n="",row:i="",column:o="",location:a="",values:s=[]})=>{var ne,ce,xe,Wt,qt,Ee,Ie,Pe,Yt,st,Et;const l=JSON.parse(localStorage.getItem(Y1(t==null?void 0:t.ID))),h=Yr(t==null?void 0:t.Properties),{socket:p,findDesiredData:f,dataRef:g,handleData:b,reRender:z}=w1(),{Picture:M,State:I,Visible:F,Event:H,Caption:E,Align:R,Posn:W,Size:$,CSS:G,Active:Z}=t==null?void 0:t.Properties;console.log("data Button",t);const K=j1(G),et=_.useRef(),at=_.useRef(),tt=y4(document.getElementById(Y1(t==null?void 0:t.ID))),[ft,dt]=_.useState(),[ht,lt]=_.useState(I||0),yt=t.Properties.hasOwnProperty("Caption"),mt=((ne=t==null?void 0:t.Properties)==null?void 0:ne.Style)&&((ce=t==null?void 0:t.Properties)==null?void 0:ce.Style)=="Check",gt=((xe=t==null?void 0:t.Properties)==null?void 0:xe.Style)&&((Wt=t==null?void 0:t.Properties)==null?void 0:Wt.Style)=="Radio",kt=f(M&&M[0]),_t=t.Properties.Event&&((qt=t==null?void 0:t.Properties)==null?void 0:qt.Event[0]),bt=$9(M&&M[1],kt),[Mt,At]=_.useState({top:W&&W[0],left:W&&W[1]}),[Ft,Bt]=_.useState(l==null?void 0:l.Size),Ut=()=>{if(a=="inGrid")return dt(r);dt(I&&I)};_.useEffect(()=>{Ut(),At({top:W&&W[0],left:W&&W[1]})},[t]);const Xt=E!=null&&E.includes("&")?E==null?void 0:E.charAt(E.indexOf("&")+1).toLowerCase():null;_.useEffect(()=>{const zt=Rt=>{Xt&&Rt.altKey&&Rt.key.toLowerCase()===Xt&&It(e)};return document.addEventListener("keydown",zt),()=>document.removeEventListener("keydown",zt)},[Xt]),_.useEffect(()=>{var zt;if(((zt=t==null?void 0:t.Properties)==null?void 0:zt.Default)===1){const Rt=Vt=>{Vt.key==="Enter"&&It(Vt)};return document.addEventListener("keydown",Rt),()=>document.removeEventListener("keydown",Rt)}},[t,_t]);const It=zt=>{var Rt;if(Z===0){zt.preventDefault();return}(Rt=document.getElementById(localStorage.getItem("current-focus")))==null||Rt.blur(),_t&&(console.log(JSON.stringify({Event:{EventName:_t[0],ID:t==null?void 0:t.ID}})),localStorage.getItem("current-focus")&&localStorage.getItem("shouldChangeEvent")==="true"&&(console.log(JSON.stringify({Event:{EventName:"Change",ID:localStorage.getItem("current-focus"),Info:[t==null?void 0:t.ID]}})),p.send(JSON.stringify({Event:{EventName:"Change",ID:localStorage.getItem("current-focus"),Info:[t==null?void 0:t.ID]}}))),p.send(JSON.stringify({Event:{EventName:_t[0],ID:t==null?void 0:t.ID}})),fe())};_.useEffect(()=>{var Vt;if(!Mt||!Ft)return;let zt=Mt&&Mt.left&&Ft&&Ft[1]?Mt.left/Ft[1]*tt.width:0;zt=Math.max(0,Math.min(zt,tt.width));let Rt=Mt&&Mt.top&&Ft&&Ft[0]?Mt.top/Ft[0]*tt.height:0;if(Rt=Math.max(0,Math.min(Rt,tt.height)),At({top:Math.round(Rt),left:Math.round(zt)}),Bt([tt==null?void 0:tt.height,tt==null?void 0:tt.width]),b({ID:t==null?void 0:t.ID,Properties:{...(Vt=t==null?void 0:t.Properties)!=null&&Vt.hasOwnProperty("Posn")?{Posn:[Math.round(Rt),Math.round(zt)]}:{}}},"WS"),localStorage.getItem(t==null?void 0:t.ID)){const{Event:Qt}=JSON.parse(localStorage.getItem(t==null?void 0:t.ID)),{Value:ve}=Qt,je=JSON.stringify({Event:{EventName:"Select",ID:t==null?void 0:t.ID,Value:ve,Posn:[Math.round(Rt),Math.round(zt)],Size:[$&&$[0],$&&$[1]]}});localStorage.setItem(t==null?void 0:t.ID,je)}else{const Qt=JSON.stringify({Event:{EventName:"Select",ID:t==null?void 0:t.ID,Value:0,Posn:[Math.round(Rt),Math.round(zt)],Size:[$&&$[0],$&&$[1]]}});localStorage.setItem(t==null?void 0:t.ID,Qt)}Bt([tt==null?void 0:tt.height,tt==null?void 0:tt.width]),z()},[tt]);const ae=zt=>{const Rt=f(Y1(t==null?void 0:t.ID));s[parseInt(i)-1][parseInt(o)-1]=zt?1:0,b({ID:Y1(t==null?void 0:t.ID),Properties:{...Rt.Properties,Values:s,CurCell:[i,o]}},"WS");const Vt=JSON.stringify({Event:{EventName:"CellChanged",ID:Y1(t==null?void 0:t.ID),Row:parseInt(i),Col:parseInt(o),Value:zt?1:0}}),Qt=JSON.stringify({Event:{EventName:"CellChanged",Values:s,CurCell:[i,o]}}),ve=JSON.stringify({FormatCell:{Cell:[i,o],ID:Y1(t==null?void 0:t.ID),Value:zt?1:0}});localStorage.setItem(Y1(t==null?void 0:t.ID),Qt),n&&n.some(ke=>ke[0]==="CellChanged")&&(console.log(Vt),console.log(ve),p.send(ve),p.send(Vt))},$t=zt=>{const Rt=JSON.stringify({Event:{EventName:"Select",ID:t==null?void 0:t.ID,Value:zt?1:0,Posn:[Mt==null?void 0:Mt.top,Mt==null?void 0:Mt.left],Size:[$&&$[0],$&&$[1]]}});if(localStorage.setItem(t==null?void 0:t.ID,Rt),!(H&&H.some(ve=>ve[0]==="Select")))return;console.log(Rt);const Qt=JSON.stringify({Event:{EventName:"Select",ID:t==null?void 0:t.ID}});p.send(Qt)},ue=zt=>{a=="inGrid"?($t(zt),ae(zt)):$t(zt)},Ot=(zt,Rt,Vt)=>{const Qt=Vt?0:1,ve=JSON.stringify({Event:{ID:Y1(t==null?void 0:t.ID),EventName:"CellMove",Info:[zt,Rt,Qt,0,Vt,ft?1:0]}});n&&n.some(ke=>ke[0]==="CellMove")&&(console.log(ve),p.send(ve))},we=()=>{if(a!=="inGrid")return;const Qt=et.current.parentElement.parentElement.parentElement.nextSibling;Ot(i+1,o,0);const ve=Qt==null?void 0:Qt.querySelectorAll("input");ve&&ve.forEach(je=>{je.id===(t==null?void 0:t.ID)&&je.focus()})},Ht=()=>{if(a!=="inGrid")return;const Vt=et.current.parentElement.parentElement.nextSibling,Qt=gl(g.current,Vt==null?void 0:Vt.id);Ot(i,o+1,0);const ve=Vt==null?void 0:Vt.querySelectorAll(Qt);return Qt=="select"?ve&&ve[0].focus():ve&&ve[0].select()},se=()=>{var je,ke;if(a!=="inGrid")return;console.log(et);const Vt=et.current.parentElement.parentElement.previousSibling,Qt=gl(g.current,Vt==null?void 0:Vt.id);Ot(i,o-1,0);const ve=Vt==null?void 0:Vt.querySelectorAll(Qt);return ve&&((je=ve[0])==null||je.focus()),ve&&((ke=ve[0])==null?void 0:ke.select())},Se=()=>{if(a!=="inGrid")return;const Qt=et.current.parentElement.parentElement.parentElement.previousSibling;Ot(i-1,o,0);const ve=Qt==null?void 0:Qt.querySelectorAll("input");ve&&ve.forEach(je=>{je.id===(t==null?void 0:t.ID)&&je.focus()})},Kt=zt=>{In(zt,p,H,t==null?void 0:t.ID),zt.key=="Enter"?we():zt.key=="ArrowRight"?Ht():zt.key=="ArrowLeft"?se():zt.key=="ArrowDown"?we():zt.key=="ArrowUp"&&Se()},fe=()=>{const zt=localStorage.getItem("current-focus"),Rt=JSON.stringify({Event:{EventName:"GotFocus",ID:t==null?void 0:t.ID,Info:zt?[zt]:[""]}});localStorage.setItem("current-focus",t==null?void 0:t.ID),!(!(H&&H.some(Qt=>Qt[0]==="GotFocus"))||zt==(t==null?void 0:t.ID))&&(console.log(Rt),p.send(Rt))};if(mt){let zt=null;return R&&R=="Left"?zt={position:"absolute",right:0,top:3}:(!R||R=="Right")&&(zt={position:"absolute",left:0,top:3}),a=="inGrid"&&(zt={...zt,marginLeft:"5px"}),vt.jsxs("div",{id:t.ID+".$CONTAINER",onKeyDown:Rt=>Kt(Rt),style:{...h,zIndex:1,display:F==0?"none":"block"},children:[R&&R=="Left"?vt.jsx("div",{style:{fontSize:"12px",position:"absolute",top:0,left:0},children:E}):null,vt.jsx("input",{onFocus:fe,ref:et,onKeyDown:Rt=>Kt(Rt),id:t==null?void 0:t.ID,type:"checkbox",style:zt,checked:ft,disabled:Z===0,onChange:Rt=>{dt(Rt.target.checked),ue(Rt.target.checked)}}),!R||R=="Right"?vt.jsx("div",{style:{fontSize:"12px",position:"absolute",top:0,left:16,...K},children:E}):null]})}if(gt){const zt=Vt=>{const Qt=JSON.stringify({Event:{EventName:"Select",ID:t==null?void 0:t.ID,Value:Vt}});if(!(H&&H.some(ke=>ke[0]==="Select")))return;const je=JSON.stringify({Event:{EventName:"Select",ID:t==null?void 0:t.ID}});console.log(Qt),p.send(je)},Rt=(Vt,Qt)=>{for(var je=document.getElementById(Y1(t==null?void 0:t.ID)).getElementsByTagName("input"),ke=0;ke{lt(I)},[t]),vt.jsxs("div",{id:(t==null?void 0:t.ID)+".$CONTAINER",style:{...h,zIndex:1,display:F==0?"none":"block",...K},children:[R&&R=="Left"?vt.jsx("div",{style:{fontSize:"12px",position:"absolute",top:2,left:0,...K},children:E}):null,vt.jsx("input",{onFocus:fe,name:Y1(t==null?void 0:t.ID),id:t==null?void 0:t.ID,checked:ht,type:"radio",value:E,disabled:Z===0,onChange:Vt=>{Rt(t==null?void 0:t.ID,Vt.target.checked)}}),!R||R=="Right"?vt.jsx("div",{style:{fontSize:"12px",position:"absolute",top:2,left:16,...K},children:vt.jsx("label",{for:t==null?void 0:t.ID,children:E})}):null]})}return vt.jsxs("div",{id:t==null?void 0:t.ID,onMouseDown:zt=>{er(zt,p,H,t==null?void 0:t.ID)},onMouseUp:zt=>{rr(zt,p,H,t==null?void 0:t.ID)},onMouseEnter:zt=>{ir(zt,p,H,t==null?void 0:t.ID)},onMouseMove:zt=>{or(zt,p,H,t==null?void 0:t.ID)},onMouseLeave:zt=>{nr(zt,p,H,t==null?void 0:t.ID)},onWheel:zt=>{hr(zt,p,H,t==null?void 0:t.ID)},onDoubleClick:zt=>{mr(zt,p,H,t==null?void 0:t.ID)},ref:at,onClick:zt=>{It(zt)},style:{...h,border:"1px solid black",textAlign:"center",alignItems:"center",justifyContent:"center",background:"white",borderRadius:"4px",borderColor:"#ccc",fontSize:"12px",color:Z===0?"#838383":"black",cursor:"pointer",zIndex:1,paddingLeft:"3px",paddingRight:"3px",display:F==0?"none":"flex",...(Ee=t==null?void 0:t.Properties)!=null&&Ee.hasOwnProperty("Posn")?{top:Mt==null?void 0:Mt.top}:{},...(Ie=t==null?void 0:t.Properties)!=null&&Ie.hasOwnProperty("Posn")?{left:Mt==null?void 0:Mt.left}:{},...K},children:[kt?vt.jsx("div",{style:{...bt,width:"100%",height:"100%"}}):null,yt?(Yt=(Pe=t==null?void 0:t.Properties)==null?void 0:Pe.Caption)!=null&&Yt.includes("&")?vt.jsx("span",{dangerouslySetInnerHTML:{__html:(st=t==null?void 0:t.Properties)==null?void 0:st.Caption.replace(/&(\w)/,"$1")}}):vt.jsx("span",{children:(Et=t==null?void 0:t.Properties)==null?void 0:Et.Caption}):null]})},xZ=({data:t,value:r,event:n="",row:i="",column:o="",location:a="",values:s=[]})=>{const l=JSON.parse(localStorage.getItem(Y1(t==null?void 0:t.ID))),{CSS:h}=t.Properties,p=j1(h),f=_.useRef(),{socket:g,handleData:b,findDesiredData:z,reRender:M,dataRef:I}=w1(),F=Yr(t==null?void 0:t.Properties),{Items:H,SelItems:E,Event:R,Visible:W,Posn:$,Size:G}=t==null?void 0:t.Properties,Z=y4(document.getElementById(Y1(t==null?void 0:t.ID)));console.log("this event",{Event:R});const[K,et]=_.useState("+"),[at,tt]=_.useState({top:$&&$[0],left:$&&$[1]}),[ft,dt]=_.useState(l==null?void 0:l.Size);_.useEffect(()=>{const At=E==null?void 0:E.findIndex(Bt=>Bt==1);et(H[At]);const Ft=JSON.stringify({Event:{EventName:"Select",ID:t==null?void 0:t.ID,Info:At+1,Text:H&&H[At],Posn:[at==null?void 0:at.top,at==null?void 0:at.left],Size:[G&&G[0],G&&G[1]]}});localStorage.setItem(t==null?void 0:t.ID,Ft)},[t]);const ht=At=>{const Ft=z(Y1(t==null?void 0:t.ID));s[parseInt(i)-1][parseInt(o)-1]=At,b({ID:Y1(t==null?void 0:t.ID),Properties:{...Ft.Properties,Values:s,CurCell:[i,o]}},"WS");const Bt=JSON.stringify({Event:{EventName:"CellChanged",ID:Y1(t==null?void 0:t.ID),Row:parseInt(i),Col:parseInt(o),Value:At}}),Ut=JSON.stringify({Event:{EventName:"CellChanged",Values:s,CurCell:[i,o]}});localStorage.setItem(Y1(t==null?void 0:t.ID),Ut),n&&n.some(It=>It[0]==="CellChanged")&&(console.log(Bt),g.send(Bt))},lt=At=>{const Ft=new Array(H.length).fill(0);b({ID:t==null?void 0:t.ID,Properties:{...t==null?void 0:t.Properties,SelItems:Ft,Text:H&&H[At]}},"WS");const Bt=JSON.stringify({Event:{EventName:"Select",ID:t==null?void 0:t.ID,Info:parseInt(At+1),Text:H&&H[At],SelItems:Ft,Posn:[at==null?void 0:at.top,at==null?void 0:at.left],Size:[G&&G[0],G&&G[1]]}}),Ut=JSON.stringify({Event:{EventName:"Select",ID:t==null?void 0:t.ID}});localStorage.setItem(t==null?void 0:t.ID,Bt),R&&R.some(It=>It[0]==="Select")&&(console.log(Bt),g.send(Ut))},yt=At=>{const Ft=H.indexOf(At);a=="inGrid"?(lt(Ft),ht(At)):lt(Ft)};_.useEffect(()=>{if(!at||!ft)return;let At=at&&at.left&&ft&&ft[1]?at.left/ft[1]*Z.width:0;At=Math.max(0,Math.min(At,Z.width));let Ft=at&&at.top&&ft&&ft[0]?at.top/ft[0]*Z.height:0;Ft=Math.max(0,Math.min(Ft,Z.height)),tt({top:Ft,left:At}),b({ID:t==null?void 0:t.ID,Properties:{Posn:[Ft,At]}},"WS"),dt([Z==null?void 0:Z.height,Z==null?void 0:Z.width]),M()},[Z]);const mt=(At,Ft,Bt,Ut)=>{console.log("265 combo");const Xt=Bt?0:1,It=JSON.stringify({Event:{ID:Y1(t==null?void 0:t.ID),EventName:"CellMove",Info:[At,Ft,Xt,0,Bt,Ut]}});n&&n.some($t=>$t[0]==="CellMove")&&(console.log(It),g.send(It))},gt=At=>{if(a!=="inGrid")return;console.log(f);const Ut=f.current.parentElement.parentElement.nextSibling,Xt=gl(I.current,Ut==null?void 0:Ut.id);mt(i,o+1,0,At);const It=Ut==null?void 0:Ut.querySelectorAll(Xt);return console.log({element:It}),Xt=="select"?It&&It[0].focus():It&&It[0].select()},kt=At=>{if(a!=="inGrid")return;console.log(f);const Ut=f.current.parentElement.parentElement.previousSibling,Xt=gl(I.current,Ut==null?void 0:Ut.id);mt(i,o-1,0,At);const It=Ut==null?void 0:Ut.querySelectorAll(Xt);return Xt=="select"?It&&It[0].focus():It&&It[0].select()},_t=At=>{if(a!=="inGrid")return;const Xt=f.current.parentElement.parentElement.parentElement.previousSibling,It=Xt==null?void 0:Xt.querySelectorAll("select");mt(i-1,o,0,At),It&&It.forEach(ae=>{ae.id===(t==null?void 0:t.ID)&&ae.focus()})},bt=At=>{if(a!=="inGrid")return;const Xt=f.current.parentElement.parentElement.parentElement.nextSibling;mt(i+1,o,0,At);const It=Xt==null?void 0:Xt.querySelectorAll("select");It&&It.forEach(ae=>{ae.id===(t==null?void 0:t.ID)&&ae.focus()})},Mt=At=>{At.stopPropagation(),At.preventDefault(),In(At,g,R,t==null?void 0:t.ID),At.key=="ArrowRight"?gt(At.target.value):At.key=="ArrowLeft"?kt(At.target.value):At.key=="ArrowDown"?bt(At.target.value):At.key=="ArrowUp"&&_t(At.target.value)};return vt.jsx("div",{style:{...F,borderColor:"#ccc",display:W==0?"none":"block",top:at==null?void 0:at.top,left:at==null?void 0:at.left},onMouseDown:At=>{At.stopPropagation(),er(At,g,R,t==null?void 0:t.ID)},onMouseUp:At=>{At.stopPropagation(),rr(At,g,R,t==null?void 0:t.ID)},onMouseEnter:At=>{At.stopPropagation(),ir(At,g,R,t==null?void 0:t.ID)},onMouseMove:At=>{At.stopPropagation(),or(At,g,R,t==null?void 0:t.ID)},onMouseLeave:At=>{At.stopPropagation(),nr(At,g,R,t==null?void 0:t.ID)},onWheel:At=>{hr(At,g,R,t==null?void 0:t.ID)},onDoubleClick:At=>{At.stopPropagation(),mr(At,g,R,t==null?void 0:t.ID)},onKeyDown:At=>{In(At,g,R,t==null?void 0:t.ID)},children:vt.jsx("select",{ref:f,onKeyDown:At=>Mt(At),id:t==null?void 0:t.ID,value:r||K,style:{width:"100%",border:0,fontSize:"12px",height:a==="inGrid"?null:"100%",zIndex:1,...p},onChange:At=>{At.stopPropagation(),et(At.target.value),yt(At.target.value)},children:H&&H.map((At,Ft)=>vt.jsx("option",{value:At,children:At},Ft))})})};const bZ=({data:t,gridValue:r})=>{var F,H,E,R,W;let n=Yr(t==null?void 0:t.Properties);const{findDesiredData:i,fontScale:o,socket:a}=w1(),s=t==null?void 0:t.Properties.hasOwnProperty("FCol"),l=t==null?void 0:t.Properties.hasOwnProperty("Font"),{Visible:h,FontObj:p,Caption:f,Size:g,BCol:b,Event:z,CSS:M}=t==null?void 0:t.Properties;console.log("data Label",t);const I=j1(M);if(s&&(n={...n,color:`rgb(${(F=t==null?void 0:t.Properties)==null?void 0:F.FCol[0]},${(H=t==null?void 0:t.Properties)==null?void 0:H.FCol[1]},${(E=t==null?void 0:t.Properties)==null?void 0:E.FCol[2]})`}),l)n={...n,fontFamily:(R=t.Properties)==null?void 0:R.Font[0],fontSize:(W=t==null?void 0:t.Properties)==null?void 0:W.Font[1]};else{const $=i(p&&p),G=$&&($==null?void 0:$.Properties);n={...n,fontFamily:G==null?void 0:G.PName,fontSize:G!=null&&G.Size?`${G.Size*o}px`:`${12*o}px`,textDecoration:G!=null&&G.Underline&&(G==null?void 0:G.Underline)==1?"underline":"none",fontStyle:G!=null&&G.Italic&&(G==null?void 0:G.Italic)==1?"italic":"none",fontWeight:G!=null&&G.Weight?G==null?void 0:G.Weight:0,background:b&&Hr(b)}}return vt.jsx("div",{id:t==null?void 0:t.ID,style:{...n,display:h==0?"none":"block",...I},onMouseDown:$=>{er($,a,z,t==null?void 0:t.ID)},onMouseUp:$=>{rr($,a,z,t==null?void 0:t.ID)},onMouseEnter:$=>{ir($,a,z,t==null?void 0:t.ID)},onMouseMove:$=>{or($,a,z,t==null?void 0:t.ID)},onMouseLeave:$=>{nr($,a,z,t==null?void 0:t.ID)},children:f||vt.jsx("span",{style:{display:"flex",justifyContent:typeof r=="string"?"start":"end",fontSize:"12px",marginLeft:"5px"},children:r})})};function qi(){return qi=Object.assign?Object.assign.bind():function(t){for(var r=1;rt.length)&&(r=t.length);for(var n=0,i=new Array(r);n"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function kZ(t,r){if(r&&(tn(r)==="object"||typeof r=="function"))return r;if(r!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return _e(t)}function P8(t){var r=MZ();return function(){var i=_u(t),o;if(r){var a=_u(this).constructor;o=Reflect.construct(i,arguments,a)}else o=i.apply(this,arguments);return kZ(this,o)}}var _D={exports:{}};/*! +}`;var b1=Rz(function(){return j1(pt,Ue+"return "+me).apply(n,St)});if(b1.source=me,af(b1))throw b1;return b1}function eY(y){return q1(y).toLowerCase()}function rY(y){return q1(y).toUpperCase()}function iY(y,S,T){if(y=q1(y),y&&(T||S===n))return YC(y);if(!y||!(S=jn(S)))return y;var Y=X2(y),it=X2(S),pt=XC(Y,it),St=KC(Y,it)+1;return Cs(Y,pt,St).join("")}function nY(y,S,T){if(y=q1(y),y&&(T||S===n))return y.slice(0,ZC(y)+1);if(!y||!(S=jn(S)))return y;var Y=X2(y),it=KC(Y,X2(S))+1;return Cs(Y,0,it).join("")}function oY(y,S,T){if(y=q1(y),y&&(T||S===n))return y.replace(sa,"");if(!y||!(S=jn(S)))return y;var Y=X2(y),it=XC(Y,X2(S));return Cs(Y,it).join("")}function aY(y,S){var T=at,Y=tt;if(Hr(S)){var it="separator"in S?S.separator:it;T="length"in S?m1(S.length):T,Y="omission"in S?jn(S.omission):Y}y=q1(y);var pt=y.length;if(J0(y)){var St=X2(y);pt=St.length}if(T>=pt)return y;var Et=T-Q0(Y);if(Et<1)return Y;var Tt=St?Cs(St,0,Et).join(""):y.slice(0,Et);if(it===n)return Tt+Y;if(St&&(Et+=Tt.length-Et),sf(it)){if(y.slice(Et).search(it)){var pe,fe=Tt;for(it.global||(it=Cd(it.source,q1(r1.exec(it))+"g")),it.lastIndex=0;pe=it.exec(fe);)var me=pe.index;Tt=Tt.slice(0,me===n?Et:me)}}else if(y.indexOf(jn(it),Et)!=Et){var De=Tt.lastIndexOf(it);De>-1&&(Tt=Tt.slice(0,De))}return Tt+Y}function sY(y){return y=q1(y),y&&K1.test(y)?y.replace(je,VN):y}var lY=a3(function(y,S,T){return y+(T?" ":"")+S.toUpperCase()}),hf=OS("toUpperCase");function Fz(y,S,T){return y=q1(y),S=T?n:S,S===n?IN(y)?ON(y):CN(y):y.match(S)||[]}var Rz=w1(function(y,S){try{return $n(y,n,S)}catch(T){return af(T)?T:new u1(T)}}),cY=da(function(y,S){return g2(S,function(T){T=Lo(T),ua(y,T,nf(y[T],y))}),y});function hY(y){var S=y==null?0:y.length,T=e1();return y=S?Ar(y,function(Y){if(typeof Y[1]!="function")throw new m2(s);return[T(Y[0]),Y[1]]}):[],w1(function(Y){for(var it=-1;++itgt)return[];var T=bt,Y=Oi(y,bt);S=e1(S),y-=bt;for(var it=xd(Y,S);++T0||S<0)?new L1(T):(y<0?T=T.takeRight(-y):y&&(T=T.drop(y)),S!==n&&(S=m1(S),T=S<0?T.dropRight(-S):T.take(S-y)),T)},L1.prototype.takeRightWhile=function(y){return this.reverse().takeWhile(y).reverse()},L1.prototype.toArray=function(){return this.take(bt)},_o(L1.prototype,function(y,S){var T=/^(?:filter|find|map|reject)|While$/.test(S),Y=/^(?:head|last)$/.test(S),it=ut[Y?"take"+(S=="last"?"Right":""):S],pt=Y||/^find/.test(S);it&&(ut.prototype[S]=function(){var St=this.__wrapped__,Et=Y?[1]:arguments,Tt=St instanceof L1,pe=Et[0],fe=Tt||f1(St),me=function(z1){var I1=it.apply(ut,gs([z1],Et));return Y&&De?I1[0]:I1};fe&&T&&typeof pe=="function"&&pe.length!=1&&(Tt=fe=!1);var De=this.__chain__,Ue=!!this.__actions__.length,n1=pt&&!De,b1=Tt&&!Ue;if(!pt&&fe){St=b1?St:new L1(this);var o1=y.apply(St,Et);return o1.__actions__.push({func:Q5,args:[me],thisArg:n}),new y2(o1,De)}return n1&&b1?y.apply(this,Et):(o1=this.thru(me),n1?Y?o1.value()[0]:o1.value():o1)})}),g2(["pop","push","shift","sort","splice","unshift"],function(y){var S=M5[y],T=/^(?:push|sort|unshift)$/.test(y)?"tap":"thru",Y=/^(?:pop|shift)$/.test(y);ut.prototype[y]=function(){var it=arguments;if(Y&&!this.__chain__){var pt=this.value();return S.apply(f1(pt)?pt:[],it)}return this[T](function(St){return S.apply(f1(St)?St:[],it)})}}),_o(L1.prototype,function(y,S){var T=ut[S];if(T){var Y=T.name+"";or.call(i3,Y)||(i3[Y]=[]),i3[Y].push({name:S,func:T})}}),i3[U5(n,H).name]=[{name:"wrapper",func:n}],L1.prototype.clone=s$,L1.prototype.reverse=l$,L1.prototype.value=c$,ut.prototype.at=Rj,ut.prototype.chain=Oj,ut.prototype.commit=Bj,ut.prototype.next=Nj,ut.prototype.plant=Wj,ut.prototype.reverse=jj,ut.prototype.toJSON=ut.prototype.valueOf=ut.prototype.value=Gj,ut.prototype.first=ut.prototype.head,m6&&(ut.prototype[m6]=$j),ut},t3=BN();H4?((H4.exports=t3)._=t3,ud._=t3):_i._=t3}).call(S3)})(Mu,Mu.exports);var cZ=Mu.exports;const hZ=({data:t,onKeyDown1:r})=>{var At;const n=_.useRef(null),i=_.useRef(null),o=_.useRef(null),[a,s]=_.useState(!1),[l,h]=_.useState(!1),[p,f]=_.useState(t==null?void 0:t.value),{FieldType:g,Decimal:b,SelText:z,Event:M}=(At=t==null?void 0:t.typeObj)==null?void 0:At.Properties,{dataRef:I,findDesiredData:F,handleData:H,socket:E,socketData:R}=x1(),W=JSON.parse(ji(I.current,"Locale")),{ShortDate:$,Thousand:G,Decimal:Z}=W==null?void 0:W.Properties,[K,et]=_.useState(g=="Date"?q4($g(t==null?void 0:t.value)).format($&&$):t==null?void 0:t.value),[at,tt]=_.useState(g=="Date"?q4($g(t==null?void 0:t.value)):new Date),[ft,dt]=_.useState(!1),ht=bt=>{const kt=bt.trimStart();return bt.indexOf(kt[0])};_.useEffect(()=>{if(!a&&o.current&&z&&z.length===2&&(t!=null&&t.focused)){const[bt,kt]=z,Lt=o.current.firstChild;console.log({textNode:Lt});const Vt=Lt!=null&&Lt.nodeType?Lt:Lt==null?void 0:Lt.textNode;if((Vt==null?void 0:Vt.nodeType)===Node.TEXT_NODE){const Rt=document.createRange(),Ut=window.getSelection(),Kt=Math.min(kt-1,Vt.length);if(Vt.parentNode.textContent.trim(),console.log("use effect",{content:t==null?void 0:t.formattedValue}),t!=null&&t.formattedValue){console.log("content",{index:ht(t==null?void 0:t.formattedValue)});const le=ht(t==null?void 0:t.formattedValue);Rt.setStart(Vt,Math.min(bt-1+le,Vt.length)),Rt.setEnd(Vt,Math.min(kt-1+le,Vt.length))}else Rt.setStart(Vt,Math.min(bt-1,Vt.length)),Rt.setEnd(Vt,Kt);Ut.removeAllRanges(),Ut.addRange(Rt)}}},[z,a,t.focused]);const lt=bt=>{var Ut,Kt,It,le;console.log("select"),console.log({event:bt});const kt=bt.target,Lt=kt.selectionStart+1,Vt=kt.selectionEnd+1,Rt=kt.value.substring(Lt,Vt);console.log({data:t,input:kt,start:Lt,end:Vt}),h(!!Rt),console.log("select",!!Rt),Rt?(localStorage.setItem((Ut=t==null?void 0:t.typeObj)==null?void 0:Ut.ID,JSON.stringify({Event:{Info:[Lt,Vt]}})),H({ID:(Kt=t==null?void 0:t.typeObj)==null?void 0:Kt.ID,Properties:{SelText:[Lt,Vt]}},"WS")):(localStorage.setItem((It=t==null?void 0:t.typeObj)==null?void 0:It.ID,JSON.stringify({Event:{Info:[1,1]}})),H({ID:(le=t==null?void 0:t.typeObj)==null?void 0:le.ID,Properties:{SelText:[1,1]}},"WS"))},yt=bt=>{var Rt;bt.stopPropagation();const kt=bt.target,Lt=kt.selectionStart,Vt=kt.selectionEnd;if(console.log("Value of event key ",bt.key),bt.key==="Enter"){s(!1),console.log("Value of event key",ft),ft&&(dt(!1),E.send(JSON.stringify({Event:{EventName:"Change",ID:(Rt=t==null?void 0:t.typeObj)==null?void 0:Rt.ID,Info:[]}}))),r&&(console.log("On key down is "),r(bt),_t(bt));return}Lt!==Vt&&r&&(r(bt),_t(bt))},mt=()=>{const bt=t==null?void 0:t.gridValues;bt[(t==null?void 0:t.row)-1][t==null?void 0:t.column]=g=="Date"?p:K;const kt=JSON.stringify({Event:{EventName:"CellChanged",ID:t==null?void 0:t.gridId,Row:t==null?void 0:t.row,Col:(t==null?void 0:t.column)+1,Value:g=="Date"?p:K}}),Lt=JSON.stringify({Event:{EventName:"CellChanged",Values:bt,CurCell:[t==null?void 0:t.row,(t==null?void 0:t.column)+1]}}),Vt=JSON.stringify({FormatCell:{Cell:[t==null?void 0:t.row,(t==null?void 0:t.column)+1],ID:t==null?void 0:t.gridId,Value:g=="Date"?p:K}});localStorage.setItem(t==null?void 0:t.gridId,Lt),t!=null&&t.gridEvent&&(t!=null&&t.gridEvent.some(Ut=>Ut[0]==="CellChanged"))&&(console.log(kt),E.send(kt),localStorage.setItem("isChanged",JSON.stringify({isChange:!0,value:g=="Date"?p:K})),t!=null&&t.formatString&&(console.log(Vt),E.send(Vt)))};_.useEffect(()=>{var bt;t.focused&&((bt=n==null?void 0:n.current)==null||bt.focus())},[t.focused]),_.useEffect(()=>{var bt,kt;if(console.log("select useEffect",{selected:l}),!l)return console.log("select useEffect 2",{selected:l}),localStorage.setItem((bt=t==null?void 0:t.typeObj)==null?void 0:bt.ID,JSON.stringify({Event:{Info:[1,1]}})),H({ID:(kt=t==null?void 0:t.typeObj)==null?void 0:kt.ID,Properties:{SelText:[1,1]}},"WS"),()=>{console.log("select unmount")}},[t.focused]);const gt=()=>{if(g=="Date"){if((t==null?void 0:t.value)==p)return;mt()}else{if((t==null?void 0:t.value)==K)return;mt()}},_t=bt=>{var It,le,Bt,de,Ft,we,Ht,ce;const kt=bt!=null&&bt.altKey?4:0,Lt=bt!=null&&bt.ctrlKey?2:0,Vt=bt!=null&&bt.shiftKey?1:0,Rt=(It=bt==null?void 0:bt.key)==null?void 0:It.charCodeAt(0);let Ut=kt+Lt+Vt;const Kt=(de=(Bt=(le=t==null?void 0:t.typeObj)==null?void 0:le.Properties)==null?void 0:Bt.Event)==null?void 0:de.some(Se=>Se[0]==="KeyPress");if(console.log("Value of event is as",Kt,(we=(Ft=t==null?void 0:t.typeObj)==null?void 0:Ft.Properties)==null?void 0:we.Event),!Kt){console.log("Coming here in exists");return}console.log(JSON.stringify({Event:{EventName:"KeyPress",ID:(Ht=t==null?void 0:t.typeObj)==null?void 0:Ht.ID,Info:[bt.key,Rt,bt.keyCode,Ut]}})),E.send(JSON.stringify({Event:{EventName:"KeyPress",ID:(ce=t==null?void 0:t.typeObj)==null?void 0:ce.ID,Info:[bt.key,Rt,bt.keyCode,Ut]}}))};if(g=="Date"){const bt=Rt=>{tt(Rt.target.value);const Ut=q4(Rt.target.value).format($);console.log("date picker",{input:Rt.target.value,ShortDate:$,selectedDate:Ut});let Kt=Wg(Rt.target.value)+1;et(Ut),f(Kt)},kt=Rt=>{et(Rt.target.value)},Lt=()=>{n.current.showPicker()},Vt=()=>{const[Rt,Ut,Kt]=K.split("-"),It=`${Kt}-${Ut}-${Rt}`,le=new Date(It),Bt=q4(le,$,!0);if(Bt.isValid()){const de=Bt.format("YYYY-MM-DD");tt(de);const Ft=Wg(de)+1;f(Ft)}else console.warn("Invalid date entered");s(!1),gt()};return vt.jsx(vt.Fragment,{children:a?vt.jsxs(vt.Fragment,{children:[vt.jsxs("div",{style:{display:"flex",alignItems:"center"},children:[vt.jsx("input",{ref:i,id:`${t==null?void 0:t.gridId}`,style:{border:0,outline:0,width:"100%",height:"100%",paddingLeft:"5px",paddingRight:"5px"},value:K,onChange:kt,type:"text",onClick:Rt=>{},onBlur:Vt,onKeyDown:Rt=>{Rt.stopPropagation()}}),vt.jsx("button",{onClick:Lt,style:{border:"none",background:"transparent",cursor:"pointer",padding:0},children:"📅"})]}),vt.jsx("input",{id:`${t==null?void 0:t.gridId}`,type:"date",value:q4(new Date(at)).format("YYYY-MM-DD"),ref:n,onChange:bt,style:{display:"none"}})]}):vt.jsx("div",{onDoubleClick:Rt=>{s(!0)},style:{backgroundColor:t==null?void 0:t.backgroundColor,outline:0,paddingLeft:"5px",paddingRight:"5px"},children:t!=null&&t.formattedValue?t==null?void 0:t.formattedValue:K})})}return console.log("gridEdit",M,t),g=="LongNumeric"||g=="Numeric"?vt.jsx(vt.Fragment,{children:a?vt.jsx(jg,{className:"currency",allowLeadingZeros:!0,getInputRef:n,id:`${t==null?void 0:t.gridId}`,style:{width:"100%",border:0,outline:0,backgroundColor:t==null?void 0:t.backgroundColor,textAlign:"right",paddingRight:"5px",paddingLeft:"5px"},onValueChange:bt=>{if(!bt.value)return et(0);et(parseFloat(bt==null?void 0:bt.value))},decimalScale:b,value:K,onSelect:lt,decimalSeparator:Z,thousandSeparator:G,onBlur:bt=>{s(!1),gt()},onKeyDown:bt=>{bt.stopPropagation(),_t(bt)},onMouseDown:bt=>{var kt;Q1(bt,E,M,(kt=t==null?void 0:t.typeObj)==null?void 0:kt.ID)},onMouseUp:bt=>{var kt;tr(bt,E,M,(kt=t==null?void 0:t.typeObj)==null?void 0:kt.ID)},onMouseEnter:bt=>{var kt;er(bt,E,M,(kt=t==null?void 0:t.typeObj)==null?void 0:kt.ID)},onMouseMove:bt=>{var kt;ir(bt,E,M,(kt=t==null?void 0:t.typeObj)==null?void 0:kt.ID)},onMouseLeave:bt=>{var kt;rr(bt,E,M,(kt=t==null?void 0:t.typeObj)==null?void 0:kt.ID)},onWheel:bt=>{var kt;lr(bt,E,M,(kt=t==null?void 0:t.typeObj)==null?void 0:kt.ID)},onDoubleClick:bt=>{var kt;gr(bt,E,M,(kt=t==null?void 0:t.typeObj)==null?void 0:kt.ID)}}):vt.jsx("div",{ref:o,onDoubleClick:bt=>{s(!0)},style:{backgroundColor:t==null?void 0:t.backgroundColor,outline:0,textAlign:"right",paddingRight:"5px"},children:t!=null&&t.formattedValue?t==null?void 0:t.formattedValue:vt.jsx(jg,{className:"currency",allowLeadingZeros:!0,id:`${t==null?void 0:t.gridId}`,style:{width:"100%",border:0,outline:0,backgroundColor:t==null?void 0:t.backgroundColor,textAlign:"right"},readOnly:!0,decimalScale:b,value:t==null?void 0:t.value,decimalSeparator:Z,thousandSeparator:G})})}):vt.jsx(vt.Fragment,{children:a?vt.jsx("input",{type:"text",id:`${t==null?void 0:t.gridId}`,ref:n,style:{outline:0,border:0,width:"100%",height:"100%",display:"flex",backgroundColor:t==null?void 0:t.backgroundColor,align:t==null?void 0:t.align,paddingLeft:"5px",paddingRight:"5px"},onSelect:lt,onDoubleClick:bt=>{var kt;gr(bt,E,M,(kt=t==null?void 0:t.typeObj)==null?void 0:kt.ID),bt.stopPropagation()},value:K,onKeyDown:yt,onChange:bt=>{bt.stopPropagation(),dt(!0),et(bt.target.value)},onBlur:bt=>{s(!1),gt()},autoFocus:!0,onMouseDown:bt=>{var kt;Q1(bt,E,M,(kt=t==null?void 0:t.typeObj)==null?void 0:kt.ID)},onMouseUp:bt=>{var kt;tr(bt,E,M,(kt=t==null?void 0:t.typeObj)==null?void 0:kt.ID)},onMouseEnter:bt=>{var kt;er(bt,E,M,(kt=t==null?void 0:t.typeObj)==null?void 0:kt.ID)},onMouseMove:bt=>{var kt;ir(bt,E,M,(kt=t==null?void 0:t.typeObj)==null?void 0:kt.ID)},onMouseLeave:bt=>{var kt;rr(bt,E,M,(kt=t==null?void 0:t.typeObj)==null?void 0:kt.ID)},onWheel:bt=>{var kt;lr(bt,E,M,(kt=t==null?void 0:t.typeObj)==null?void 0:kt.ID)}}):vt.jsx("div",{ref:o,onDoubleClick:bt=>{s(!0)},autoFocus:!0,onKeyDown:bt=>console.log({e:bt}),style:{display:"flex",align:t==null?void 0:t.align,backgroundColor:t==null?void 0:t.backgroundColor,outline:0,height:"100%",width:"100%",paddingLeft:"5px",paddingRight:"5px"},children:t!=null&&t.formattedValue?t==null?void 0:t.formattedValue:t==null?void 0:t.value})})},uZ=({data:t})=>{var f,g;const r=_.useRef(null),{Items:n}=(f=t==null?void 0:t.typeObj)==null?void 0:f.Properties,[i,o]=_.useState(t==null?void 0:t.value),{findDesiredData:a,socket:s,handleData:l}=x1();_.useEffect(()=>{t.focused&&r.current.focus()},[t.focused]);const h=b=>{var E;const z=a(t==null?void 0:t.gridId),M=t==null?void 0:t.gridValues;M[(t==null?void 0:t.row)-1][t==null?void 0:t.column]=b,l({ID:t==null?void 0:t.gridId,Properties:{...z.Properties,Values:M,CurCell:[t==null?void 0:t.row,(t==null?void 0:t.column)+1]}},"WS");const I=JSON.stringify({Event:{EventName:"CellChanged",ID:t==null?void 0:t.gridId,Row:t==null?void 0:t.row,Col:(t==null?void 0:t.column)+1,Value:b}}),F=JSON.stringify({Event:{EventName:"CellChanged",Values:M,CurCell:[t==null?void 0:t.row,(t==null?void 0:t.column)+1]}});localStorage.setItem(t==null?void 0:t.gridId,F),(E=t==null?void 0:t.gridEvent)!=null&&E.some(R=>R[0]==="CellChanged")&&(console.log(I),s.send(I),localStorage.setItem("isChanged",JSON.stringify({isChange:!0,value:b})))},p=b=>{n.indexOf(b),h(b)};return vt.jsx("select",{onKeyDown:b=>b.preventDefault(),onClick:b=>console.log("click"),ref:r,value:i,style:{border:0,outline:0,width:"100%",height:"100%"},id:`${(g=t==null?void 0:t.typeObj)==null?void 0:g.ID}`,onChange:b=>{o(b.target.value),p(b.target.value)},children:n&&n.map((b,z)=>vt.jsx("option",{value:b,children:b}))})},pZ=({data:t})=>{var F,H;console.log("GridButton",t);const r=_.useRef(null),{handleData:n,socket:i,findDesiredData:o}=x1(),[a,s]=_.useState(t==null?void 0:t.value),[l,h]=_.useState(t==null?void 0:t.showInput),[p,f]=_.useState(!1);_.useEffect(()=>{var E;t.focused&&((E=r==null?void 0:r.current)==null||E.focus())},[t.focused,l]);const{Event:g}=(F=t==null?void 0:t.typeObj)==null?void 0:F.Properties,b=E=>{const R=o(t==null?void 0:t.gridId),W=t==null?void 0:t.gridValues;W[(t==null?void 0:t.row)-1][t==null?void 0:t.column]=E?1:0,n({ID:t==null?void 0:t.gridId,Properties:{...R.Properties,Values:W,CurCell:[t==null?void 0:t.row,(t==null?void 0:t.column)+1]}},"WS");const $=JSON.stringify({Event:{EventName:"CellChanged",ID:t==null?void 0:t.gridId,Row:t==null?void 0:t.row,Col:(t==null?void 0:t.column)+1,Value:E?1:0}}),G=JSON.stringify({Event:{EventName:"CellChanged",Values:W,CurCell:[t==null?void 0:t.row,(t==null?void 0:t.column)+1]}}),Z=JSON.stringify({FormatCell:{Cell:[t==null?void 0:t.row,(t==null?void 0:t.column)+1],ID:t==null?void 0:t.gridId,Value:E?1:0}});localStorage.setItem(t==null?void 0:t.gridId,G),console.log($),t!=null&&t.gridEvent&&(t!=null&&t.gridEvent.some(et=>et[0]==="CellChanged"))&&(t.formatString&&(i.send(Z),console.log(Z)),i.send($),localStorage.setItem("isChanged",JSON.stringify({isChange:!0,value:E?1:0})))},z=E=>{b(E)},M=(t==null?void 0:t.cellFont)&&((H=t==null?void 0:t.cellFont)==null?void 0:H.Properties);let I={fontFamily:M==null?void 0:M.PName,fontSize:(M!=null&&M.Size,"12px"),textDecoration:M!=null&&M.Underline&&(M==null?void 0:M.Underline)==1?"underline":"none",fontStyle:M!=null&&M.Italic&&(M==null?void 0:M.Italic)==1?"italic":"none",fontWeight:M!=null&&M.Weight?M==null?void 0:M.Weight:0};return vt.jsx(vt.Fragment,{children:l?vt.jsx("input",{ref:r,id:`${t==null?void 0:t.gridId}`,type:"checkbox",checked:a,onChange:E=>{s(E.target.checked),z(E.target.checked)},onBlur:()=>h(!1),style:{backgroundColor:t==null?void 0:t.backgroundColor,outline:0,marginTop:"3.5px",marginLeft:"5px"},onDoubleClick:E=>{var R;gr(E,i,g,(R=t==null?void 0:t.typeObj)==null?void 0:R.ID)},onMouseDown:E=>{var R;Q1(E,i,g,(R=t==null?void 0:t.typeObj)==null?void 0:R.ID)},onMouseUp:E=>{var R;tr(E,i,g,(R=t==null?void 0:t.typeObj)==null?void 0:R.ID)},onMouseEnter:E=>{var R;er(E,i,g,(R=t==null?void 0:t.typeObj)==null?void 0:R.ID)},onMouseMove:E=>{var R;ir(E,i,g,(R=t==null?void 0:t.typeObj)==null?void 0:R.ID)},onMouseLeave:E=>{var R;rr(E,i,g,(R=t==null?void 0:t.typeObj)==null?void 0:R.ID)},onWheel:E=>{var R;lr(E,i,g,(R=t==null?void 0:t.typeObj)==null?void 0:R.ID)}}):vt.jsx("div",{id:`${t==null?void 0:t.gridId}`,onDoubleClick:E=>{h(!0),f(!0)},ref:r,tabIndex:"1",style:{backgroundColor:t==null?void 0:t.backgroundColor,...I,outline:0,paddingRight:"5px"},children:t!=null&&t.formattedValue?t==null?void 0:t.formattedValue:vt.jsx("input",{ref:r,id:`${t==null?void 0:t.gridId}`,type:"checkbox",checked:a,onChange:E=>{s(E.target.checked),z(E.target.checked)},style:{backgroundColor:t==null?void 0:t.backgroundColor,outline:0,marginTop:"3.5px",marginLeft:"5px"}})})})},dZ=({data:t,keyPress:r})=>{var a,s;const n=_.useRef(null),[i,o]=_.useState(!1);return _.useEffect(()=>{var l;t.focused&&((l=n==null?void 0:n.current)==null||l.focus())},[t.focused]),vt.jsx(vt.Fragment,{children:i?vt.jsx("div",{style:{display:"flex",alignItems:"center",justifyContent:t==null?void 0:t.align,paddingLeft:"5px",paddingRight:"5px"},children:vt.jsx("div",{style:{outline:0,height:"100%",width:t.width*.9,textAlign:t==null?void 0:t.align,backgroundColor:t==null?void 0:t.backgroundColor,whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis"},onBlur:()=>o(!1),ref:n,id:`${t==null?void 0:t.row}-${t==null?void 0:t.column}`,tabIndex:"0",children:t==null?void 0:t.value})}):vt.jsx("div",{style:{backgroundColor:t==null?void 0:t.backgroundColor,outline:0,textAlign:(s=(a=t==null?void 0:t.typeObj)==null?void 0:a.Properties)==null?void 0:s.Justify,paddingRight:"5px",paddingLeft:"5px"},onDoubleClick:l=>o(!0),children:t!=null&&t.formattedValue?t==null?void 0:t.formattedValue:t.value})})},fZ=({data:t})=>cZ.isArray(t==null?void 0:t.value)?vt.jsx("div",{style:{backgroundColor:t==null?void 0:t.backgroundColor,color:t==null?void 0:t.color,display:"flex",justifyContent:"flex-end",alignItems:"center",flexDirection:"column",height:"100%",paddingBottom:"5px"},children:t==null?void 0:t.value.map((r,n)=>r===""?vt.jsx("br",{},n):vt.jsx("div",{style:{lineHeight:"96%"},children:r},n))}):vt.jsx("div",{style:{backgroundColor:t==null?void 0:t.backgroundColor,color:t==null?void 0:t.color},children:t==null?void 0:t.value}),vZ=({data:t})=>{var g,b,z,M,I,F;const r=_.useRef(),{socket:n}=x1(),[i,o]=_.useState(!1);_.useEffect(()=>{var H;t.focused&&((H=r==null?void 0:r.current)==null||H.focus())},[t.focused]),_.useEffect(()=>{},[i]);const{Event:a}=(g=t==null?void 0:t.typeObj)==null?void 0:g.Properties,s=(t==null?void 0:t.cellFont)&&((b=t==null?void 0:t.cellFont)==null?void 0:b.Properties),l=()=>{o(!1)},h=()=>{o(!0)};let p={fontFamily:s==null?void 0:s.PName,fontSize:(s!=null&&s.Size,"12px"),textDecoration:s!=null&&s.Underline&&(s==null?void 0:s.Underline)==1?"underline":"none",fontStyle:s!=null&&s.Italic&&(s==null?void 0:s.Italic)==1?"italic":"none",fontWeight:s!=null&&s.Weight?s==null?void 0:s.Weight:0};const f=H=>{var K,et,at,tt;const E=H!=null&&H.altKey?4:0,R=H!=null&&H.ctrlKey?2:0,W=H!=null&&H.shiftKey?1:0,$=(K=H==null?void 0:H.key)==null?void 0:K.charCodeAt(0);let G=E+R+W;(tt=(at=(et=t==null?void 0:t.typeObj)==null?void 0:et.Properties)==null?void 0:at.Event)!=null&&tt.some(ft=>ft[0]==="KeyPress")&&(console.log(JSON.stringify({Event:{EventName:"KeyPress",ID:t==null?void 0:t.ID,Info:[H.key,$,H.keyCode,G]}})),n.send(JSON.stringify({Event:{EventName:"KeyPress",ID:t==null?void 0:t.ID,Info:[H.key,$,H.keyCode,G]}})))};return vt.jsx(vt.Fragment,{children:i?vt.jsx("div",{style:{backgroundColor:t==null?void 0:t.backgroundColor,outline:0,...p,textAlign:(F=(I=t==null?void 0:t.typeObj)==null?void 0:I.Properties)==null?void 0:F.Justify,paddingRight:"5px"},onKeyDown:H=>{H.stopPropagation(),f(H)},onBlur:l,ref:r,onMouseDown:H=>{var E;Q1(H,n,a,(E=t==null?void 0:t.typeObj)==null?void 0:E.ID)},onMouseUp:H=>{var E;tr(H,n,a,(E=t==null?void 0:t.typeObj)==null?void 0:E.ID)},onMouseEnter:H=>{var E;er(H,n,a,(E=t==null?void 0:t.typeObj)==null?void 0:E.ID)},onMouseMove:H=>{var E;ir(H,n,a,(E=t==null?void 0:t.typeObj)==null?void 0:E.ID)},onMouseLeave:H=>{var E;rr(H,n,a,(E=t==null?void 0:t.typeObj)==null?void 0:E.ID)},onWheel:H=>{var E;lr(H,n,a,(E=t==null?void 0:t.typeObj)==null?void 0:E.ID)},onDoubleClick:H=>{var E;gr(H,n,a,(E=t==null?void 0:t.typeObj)==null?void 0:E.ID)},children:t!=null&&t.focused?t==null?void 0:t.value:t==null?void 0:t.formattedValue}):vt.jsx("div",{ref:r,style:{backgroundColor:t==null?void 0:t.backgroundColor,outline:0,...p,textAlign:(M=(z=t==null?void 0:t.typeObj)==null?void 0:z.Properties)==null?void 0:M.Justify,paddingRight:"5px"},onKeyDown:H=>{H.stopPropagation(),f(H)},onDoubleClick:h,onBlur:l,id:t.gridId,children:t==null?void 0:t.formattedValue})})},gZ=({data:t,onKeyDown1:r})=>{if((t==null?void 0:t.type)=="Edit")return vt.jsx(hZ,{data:t,onKeyDown1:r});if((t==null?void 0:t.type)=="Button")return vt.jsx(pZ,{data:t});if((t==null?void 0:t.type)=="cell"||(t==null?void 0:t.type)=="rowTitle")return vt.jsx(dZ,{data:t});if((t==null?void 0:t.type)=="header")return vt.jsx(fZ,{data:t});if((t==null?void 0:t.type)=="Combo")return vt.jsx(uZ,{data:t});if((t==null?void 0:t.type)=="Label")return vt.jsx(vZ,{data:t})},mZ=({data:t})=>{const r=t==null?void 0:t.ID,{findDesiredData:n,socket:i,proceed:o,setProceed:a,proceedEventArray:s,setProceedEventArray:l,findAggregatedPropertiesData:h,handleData:p,currentEventRef:f,updateCurrentEvent:g}=x1(),[b,z]=_.useState(null),M=y4(document.getElementById(G1(t==null?void 0:t.ID))),I=_.useRef(null),{Size:F,Values:H,Input:E,ColTitles:R,RowTitles:W,CellWidths:$,CellHeights:G,Visible:Z,CurCell:K,CellTypes:et,ShowInput:at,FormattedValues:tt,BCol:ft,CellFonts:dt,ColTitleBCol:ht,ColTitleFCol:lt,TitleHeight:yt,TitleWidth:mt,FormatString:gt,VScroll:_t=0,HScroll:At=0,Attach:bt,Event:kt,CSS:Lt}=t==null?void 0:t.Properties,[Vt,Rt]=_.useState(F[0]),[Ut,Kt]=_.useState(F[1]),[It,le]=_.useState(0),[Bt,de]=_.useState(0),[Ft,we]=_.useState(K?K[0]:(R==null?void 0:R.length)>0?1:0),[Ht,ce]=_.useState(K?K[1]:mt===0?1:0),[Se,qt]=_.useState({isClicked:!1,row:Ft,column:Ht});_.useEffect(()=>{if(I.current.focus(),K){let st,Mt;I.current.focus(),st=K?K[0]:(W==null?void 0:W.length)>0?1:0,Mt=K?K[1]:mt===0?1:0,we(wt=>wt!==K[0]?st:wt),ce(wt=>wt!==K[1]?Mt:wt)}},[K]),_.useEffect(()=>{if(s[f.eventID+"KeyPress"]==1){const st=f.keyEvent;xe(st),a(!1),l(Mt=>({...Mt,[f.eventID+"KeyPress"]:0}))}else if(s[f.eventID+"CellMove"]==1){if(Se.isClicked){He(Se.row,Se.column),qt({isClicked:!1});return}const st=f.keyEvent;Nt(st)}},[Object.keys(s).length]);const ge=Gr(t==null?void 0:t.Properties);_.useEffect(()=>{bt&&(Kt((M==null?void 0:M.width)-73),Rt((M==null?void 0:M.height)-73))},[M]),_.useEffect(()=>{var st;de(R?R==null?void 0:R.length:((st=H[0])==null?void 0:st.length)+1),H&&le((H==null?void 0:H.length)+1)},[t]);const oe=(st,Mt,wt)=>{if(Mt>Bt||Mt<=0)return;const Pt=wt?0:1,Yt=Ea();z(Yt),g({curEvent:"CellMove",eventID:Yt,keyEvent:f.keyEvent});const Zt=JSON.parse(localStorage.getItem("isChanged")),ae=JSON.stringify({Event:{ID:t==null?void 0:t.ID,EventName:"CellMove",EventID:Yt,Info:[st,Mt,Pt,0,wt,Zt&&Zt.isChange?1:0,Zt&&Zt?Zt.value:""]}});kt&&(kt==null?void 0:kt.some(jt=>jt[0]==="CellMove"))?i.send(ae):p({ID:t==null?void 0:t.ID,Properties:{CurCell:[st,Mt]}},"WS")},ue=st=>{var K1;const Mt=st.altKey?4:0,wt=st.ctrlKey?2:0,Pt=st.shiftKey?1:0,Yt=st.key.charCodeAt(0),Zt=Ea();z(Zt),g({curEvent:"KeyPress",eventID:Zt,keyEvent:st.key});let ae=Mt+wt+Pt;const ee=kt&&(kt==null?void 0:kt.some(Oe=>Oe[0].toLowerCase()==="keypress"));let jt=Object.keys(t),_e;const Gt=jt.reduce((Oe,Ae)=>{var E1,ur,Qr,ti,us,Mo;return(Qr=(ur=(E1=t[Ae])==null?void 0:E1.Properties)==null?void 0:ur.Event)!=null&&Qr.some(ko=>ko[0].toLowerCase()==="keypress")&&(_e=Ae),[...Oe,(Mo=(us=(ti=t[Ae])==null?void 0:ti.Properties)==null?void 0:us.Event)==null?void 0:Mo.some(ko=>ko[0].toLowerCase()==="keypress")]},[]).some(Oe=>Oe===!0),Re=JSON.stringify({Event:{EventName:"KeyPress",ID:t==null?void 0:t.ID,EventID:Zt,Info:[st.key,Yt,st.keyCode,ae]}}),je=JSON.stringify({Event:{EventName:"KeyPress",ID:(K1=t[_e])==null?void 0:K1.ID,EventID:Zt,Info:[st.key,Yt,st.keyCode,ae]}});ee&&!Gt&&i.send(Re),Gt&&i.send(je);const d1=["ArrowRight","ArrowLeft","ArrowUp","ArrowDown"].some(Oe=>st.key===Oe);if(!ee&&!Gt){Nt(st.key);return}d1&&I.current.focus(),st.preventDefault()},xe=st=>{if(st==="ArrowRight"){const Mt=Math.min(Ht+1,R?Bt:Bt-1);if(Ht===Mt)return;oe(Ft,Mt,0)}else if(st==="ArrowLeft"){const Mt=Math.max(Ht-1,1);if(Ht===Mt)return;oe(Ft,Mt,0)}else if(st==="ArrowUp"){const Mt=Math.max(Ft-1,1);if(Ft===Mt)return;oe(Mt,Ht,0)}else if(st==="ArrowDown"||st==="Enter"){const Mt=Math.min(Ft+1,It-1);if(Ft==It-1||Ft===Mt)return;oe(Mt,Ht,0)}else if(st==="PageDown"){const Mt=Math.min(Ft+9,It-1);oe(Mt,Ht,0)}else if(st==="PageUp"){const Mt=Math.max(Ft-9,1);if(Ft==Mt)return;oe(Mt,Ht,0)}},Nt=st=>{if(st==="ArrowRight"){const Mt=Math.min(Ht+1,R?Bt:Bt-1);ce(Mt),p({ID:t==null?void 0:t.ID,Properties:{CurCell:[Ft,Mt]}},"WS")}else if(st==="ArrowLeft"){const Mt=Math.max(Ht-1,1);ce(Mt),p({ID:t==null?void 0:t.ID,Properties:{CurCell:[Ft,Mt]}},"WS")}else if(st==="ArrowUp"){const Mt=Math.max(Ft-1,1);we(Mt),p({ID:t==null?void 0:t.ID,Properties:{CurCell:[Mt,Ht]}},"WS")}else if(st==="ArrowDown"){const Mt=Math.min(Ft+1,It-1);we(Mt),p({ID:t==null?void 0:t.ID,Properties:{CurCell:[Mt,Ht]}},"WS")}else if(st==="PageDown"){const Mt=Math.min(Ft+9,It-1);we(Mt),p({ID:t==null?void 0:t.ID,Properties:{CurCell:[Mt,Ht]}},"WS")}else if(st==="PageUp"){const Mt=Math.max(Ft-9,1);we(Mt),p({ID:t==null?void 0:t.ID,Properties:{CurCell:[Mt,Ht]}},"WS")}},Jt=()=>{var Mt,wt,Pt;let st=[];if(R){let Yt=[],Zt={value:"",type:"header",width:mt||100,height:yt||20};mt===0||Yt.push(Zt);for(let ae=0;ae<(R==null?void 0:R.length);ae++){let ee={value:R[ae],type:"header",backgroundColor:Er(ht),color:Er(lt),width:$?Array.isArray($)?$[ae]:$:100,height:yt||20};Yt.push(ee)}st.push(Yt)}else if(!R){let Yt=Eq(Bt).map(Zt=>({value:Zt,type:"header",width:mt||100,height:yt||20}));st.push(Yt)}if(E){if(E)for(let Yt=0;Yt<(H==null?void 0:H.length);Yt++){let Zt=[],ae=et&&et[Yt][0];const ee=ft&&ft[ae-1];let jt={type:"rowTitle",value:W?W[Yt]:Yt+1,width:mt||100,height:G?Array.isArray(G)?G[Yt]:G:20,align:"end",backgroundColor:Er(ee)};mt==null?Zt.push(jt):mt==0||Zt.push(jt);for(let _e=0;_e1?E&&E[ze-1]:E[0]),Re=((Mt=st==null?void 0:st.Properties)==null?void 0:Mt.Event)&&((wt=st==null?void 0:st.Properties)==null?void 0:wt.Event),je=ft&&ft[ze-1],d1=n(dt&&dt[ze-1]);let K1={type:Gt?(Pt=Gt==null?void 0:Gt.Properties)==null?void 0:Pt.Type:"cell",value:H[Yt][_e],event:Re,backgroundColor:Er(je),cellFont:d1,typeObj:Gt,formattedValue:tt&&tt[Yt][_e],formatString:gt&>[ze-1],width:$?Array.isArray($)?$[_e]:$:100,height:G?Array.isArray(G)?G[Yt]:G:20};Zt.push(K1)}st.push(Zt)}}else for(let Yt=0;Yt<(H==null?void 0:H.length);Yt++){let Zt=et&&et[Yt][0];const ae=ft&&ft[Zt-1];let ee=[],jt={type:"rowTitle",value:W?W[Yt]:Yt+1,width:W&&mt||100,height:G?Array.isArray(G)?G[Yt]:G:20,align:"end",backgroundColor:Er(ae)};mt==null?ee.push(jt):mt==0||ee.push(jt);for(let _e=0;_e<=Bt;_e++){if(H[Yt][_e]===void 0)continue;let ze={type:"cell",value:H[Yt][_e],width:$?Array.isArray($)?$[_e]:$:100,height:G?Array.isArray(G)?G[_e]:G:20,align:isNaN(H[Yt][_e])?"start":"end",paddingLeft:isNaN(parseInt(H[Yt][_e]))?"5px":"0px"};ee.push(ze)}st.push(ee)}return st},Ie=(st,Mt)=>{qt({isClicked:!0,row:st,column:Mt}),!(st==Ft&&Mt==Ht)&&oe(st,Mt,1)},He=(st,Mt)=>{ce(Mt),we(st),!(st==Ft&&Mt==Ht)&&p({ID:t==null?void 0:t.ID,Properties:{CurCell:[st,Mt]}},"WS")},Pe=Jt(),Xt=$1(Lt);return vt.jsx(vt.Fragment,{children:vt.jsx("div",{tabIndex:0,ref:I,onKeyDown:ue,onMouseDown:st=>{Q1(st,i,kt,t==null?void 0:t.ID)},onMouseUp:st=>{tr(st,i,kt,t==null?void 0:t.ID)},onMouseEnter:st=>{er(st,i,kt,t==null?void 0:t.ID)},onMouseMove:st=>{ir(st,i,kt,t==null?void 0:t.ID)},onMouseLeave:st=>{rr(st,i,kt,t==null?void 0:t.ID)},onWheel:st=>{lr(st,i,kt,t==null?void 0:t.ID)},onDoubleClick:st=>{var Mt;gr(st,i,kt,(Mt=t==null?void 0:t.typeObj)==null?void 0:Mt.ID)},id:t==null?void 0:t.ID,style:{...ge,height:Vt,width:Ut,border:"1px solid black",overflow:R?"hidden":"auto",background:"white",display:Z==0?"none":"block",overflowX:At==-3?"scroll":(At==-1||At==-2,"auto"),overflowY:_t==-3?"scroll":(_t==-1||At==-2,"auto"),...Xt},children:Pe==null?void 0:Pe.map((st,Mt)=>vt.jsx("div",{style:{display:"flex"},id:`row-${Mt}-cell`,children:st.map((wt,Pt)=>{const Yt=Ft===Mt&&Ht===(mt===0?Pt+1:Pt);return vt.jsx("div",{onClick:()=>{wt.type==="rowTitle"||wt.type==="header"||Ie(Mt,mt===0?Pt+1:Pt)},id:`${r}`,style:{borderRight:Yt?"1px solid blue":"1px solid #EFEFEF",borderBottom:Yt?"1px solid blue":"1px solid #EFEFEF",fontSize:"12px",minHeight:`${wt==null?void 0:wt.height}px`,maxHeight:`${wt==null?void 0:wt.height}px`,minWidth:`${wt==null?void 0:wt.width}px`,maxWidth:`${wt==null?void 0:wt.width}px`,backgroundColor:Ft===Mt&&wt.type=="rowTitle"||Ht===(mt===0?Pt+1:Pt)&&wt.type=="header"?"lightblue":Er(wt==null?void 0:wt.backgroundColor),textAlign:wt.type=="header"?"center":wt==null?void 0:wt.align,overflow:"hidden",...(wt==null?void 0:wt.type)!=="header"&&!Array.isArray(wt==null?void 0:wt.value)&&{lineHeight:`${wt==null?void 0:wt.height}px`},paddingLeft:wt==null?void 0:wt.paddingLeft},children:vt.jsx(gZ,{data:{...wt,row:Mt,column:mt===0?Pt+1:Pt,gridValues:H,gridEvent:kt,showInput:at,gridId:r,focused:Yt,backgroundColor:wt==null?void 0:wt.backgroundColor}},wt==null?void 0:wt.type)})})}))})})},yZ=({data:t,value:r,event:n="",row:i="",column:o="",location:a="",values:s=[],T:l=""})=>{const{socket:h,dataRef:p,findDesiredData:f,handleData:g,addChangeEvent:b,fontScale:z}=x1(),M=JSON.parse(ji(p.current,"Locale")),{ShortDate:I,Thousand:F,Decimal:H}=M==null?void 0:M.Properties;let E={...Gr(t==null?void 0:t.Properties)};const[R,W]=_.useState("text"),[$,G]=_.useState(""),[Z,K]=_.useState(""),[et,at]=_.useState(""),[tt,ft]=_.useState("⌈"),[dt,ht]=_.useState(null);_.useRef();const{FieldType:lt,MaxLength:yt,FCol:mt,Decimal:gt,Visible:_t,Event:At,FontObj:bt,Size:kt,EdgeStyle:Lt,Border:Vt=0,CSS:Rt,Active:Ut}=t==null?void 0:t.Properties,Kt=t==null?void 0:t.Properties.hasOwnProperty("Text"),It=t==null?void 0:t.Properties.hasOwnProperty("Value"),le=t==null?void 0:t.Properties.hasOwnProperty("Password"),Bt=_.useRef(null),de=f(bt&&bt),Ft=de&&(de==null?void 0:de.Properties),we=$1(Rt);console.log("291",{dateFormat:M,emitValue:Z,parse:parseInt(Z),data:t});const Ht=_.useCallback(()=>{var Xt,st,Mt,wt,Pt,Yt,Zt,ae,ee,jt,_e,ze,Gt,Re,je,d1,K1,Oe,Ae,E1;if(a==="inGrid"){if(lt==="Date"){K(r),at(r);const ur=$g(r);return G(q4(ur).format(I))}return K(r),at(r),G(r)}if(!((st=(Xt=t==null?void 0:t.Properties)==null?void 0:Xt.FieldType)!=null&&st.includes("Numeric")))return le?(at(Mh((wt=(Mt=t==null?void 0:t.Properties)==null?void 0:Mt.Text)==null?void 0:wt.length)),K((Pt=t==null?void 0:t.Properties)==null?void 0:Pt.Text),G(Mh((Zt=(Yt=t==null?void 0:t.Properties)==null?void 0:Yt.Text)==null?void 0:Zt.length))):(K((ae=t==null?void 0:t.Properties)==null?void 0:ae.Text),at((ee=t==null?void 0:t.Properties)==null?void 0:ee.Text),G((jt=t==null?void 0:t.Properties)==null?void 0:jt.Text));if((ze=(_e=t==null?void 0:t.Properties)==null?void 0:_e.FieldType)!=null&&ze.includes("Numeric"))return le?(at(Mh((Re=(Gt=t==null?void 0:t.Properties)==null?void 0:Gt.Value)==null?void 0:Re.length)),K((je=t==null?void 0:t.Properties)==null?void 0:je.Value),G(Mh((K1=(d1=t==null?void 0:t.Properties)==null?void 0:d1.Value)==null?void 0:K1.length))):(at((Oe=t==null?void 0:t.Properties)==null?void 0:Oe.Value),K((Ae=t==null?void 0:t.Properties)==null?void 0:Ae.Value),G((E1=t==null?void 0:t.Properties)==null?void 0:E1.Value))},[a,lt,r,I,Kt,le,t,It]),ce=()=>{Bt.current&&Bt.current.select()},Se=_.useCallback(()=>{lt==="Numeric"?W("number"):lt==="Date"?W("date"):le&&W("password")},[lt,le]);_.useEffect(()=>{Se()},[Se]),_.useEffect(()=>{Ht()},[Ht]),a=="inGrid"?E={...E,border:"none",color:mt?Er(mt):"black"}:E={...E,borderTop:0,borderLeft:0,borderRight:0,borderBottom:"1px solid black",color:mt?Er(mt):"black"};const qt=(Xt,st,Mt,wt)=>{const Pt=Mt?0:1,Yt=JSON.stringify({Event:{ID:G1(t==null?void 0:t.ID),EventName:"CellMove",Info:[Xt,st,Pt,0,Mt,wt]}});n&&n.some(ae=>ae[0]==="CellMove")&&(console.log(Yt),h.send(Yt))},ge=()=>{if(a!=="inGrid")return;const wt=Bt.current.parentElement.parentElement.parentElement.nextSibling;qt(parseInt(i)+1,parseInt(o),0,Z);const Pt=wt==null?void 0:wt.querySelectorAll("input");Pt&&Pt&&Pt.forEach(Yt=>{Yt.id===(t==null?void 0:t.ID)&&Yt.select()})},oe=()=>{var Yt,Zt;if(a!=="inGrid")return;const Mt=Bt.current.parentElement.parentElement.nextSibling,wt=gl(p.current,Mt==null?void 0:Mt.id);let Pt=Mt==null?void 0:Mt.querySelectorAll(wt);(Pt==null?void 0:Pt.length)==0&&(Pt=Mt==null?void 0:Mt.querySelectorAll("span")),qt(parseInt(i),parseInt(o)+1,0,Z),Pt&&((Yt=Pt[0])==null||Yt.focus()),Pt&&((Zt=Pt[0])==null||Zt.select())},ue=()=>{var Yt;if(a!=="inGrid")return;const Mt=Bt.current.parentElement.parentElement.previousSibling,wt=gl(p.current,Mt==null?void 0:Mt.id),Pt=Mt==null?void 0:Mt.querySelectorAll(wt);if(qt(parseInt(i),parseInt(o)+1,0,Z),!!Pt)return wt=="select"?Pt&&Pt[0].focus():Pt&&((Yt=Pt[0])==null?void 0:Yt.select())},xe=()=>{if(a!=="inGrid")return;const wt=Bt.current.parentElement.parentElement.parentElement.previousSibling;qt(parseInt(i)-1,parseInt(o),0,Z);const Pt=wt==null?void 0:wt.querySelectorAll("input");Pt&&Pt&&Pt.forEach(Yt=>{Yt.id===(t==null?void 0:t.ID)&&Yt.select()})},Nt=Xt=>{if(Xt.key=="ArrowRight"?oe():Xt.key=="ArrowLeft"?ue():Xt.key=="ArrowDown"||Xt.key=="Enter"?ge():Xt.key=="ArrowUp"&&xe(),!(At&&At.some(ee=>ee[0]==="KeyPress")))return;const Mt=Ea();ht(Mt);const wt=Xt.altKey?4:0,Pt=Xt.ctrlKey?2:0,Yt=Xt.shiftKey?1:0,Zt=Xt.key.charCodeAt(0);let ae=wt+Pt+Yt;console.log(JSON.stringify({Event:{EventName:"KeyPress",ID:t==null?void 0:t.ID,EventID:Mt,Info:[Xt.key,Zt,Xt.keyCode,ae]}})),h.send(JSON.stringify({Event:{EventName:"KeyPress",ID:t==null?void 0:t.ID,EventID:Mt,Info:[Xt.key,Zt,Xt.keyCode,ae]}}))},Jt=()=>{var Pt,Yt;let Xt;lt==="Date"?(Xt=JSON.stringify({Event:{EventName:"Change",ID:t==null?void 0:t.ID,Info:Z}}),g({ID:t==null?void 0:t.ID,Properties:{Value:Z,Text:$}},"WS")):(Xt=JSON.stringify({Event:{EventName:"Change",ID:t==null?void 0:t.ID,Info:lt&<=="LongNumeric"||lt=="Numeric"?parseInt(Z):Z}}),g({ID:t==null?void 0:t.ID,Properties:{...lt==="LongNumeric"||lt==="Numeric"?{Value:parseInt(Z)}:{Text:Z}}},"WS")),localStorage.setItem(t==null?void 0:t.ID,Xt),localStorage.setItem("shouldChangeEvent",t.Properties.hasOwnProperty("Event"));const st=JSON.parse(localStorage.getItem(tt));if(t.Properties.hasOwnProperty("Event")){const Zt=JSON.stringify({Event:{EventName:"Change",ID:tt,Info:[t==null?void 0:t.ID]}}),ae=((Pt=t==null?void 0:t.Properties)==null?void 0:Pt.Text)||((Yt=t==null?void 0:t.Properties)==null?void 0:Yt.Value)||"";console.log("value focused",{value:r,emitValue:Z,originalValue:ae},st,st.Event.EventName!=="Select",ae!==Z),tt&&st.Event.EventName!=="Select"&&ae!==Z&&tt!==t.ID&&(console.log("focused",st,st.Event.EventName!=="Select",ae!==Z),h.send(Zt))}if(!(At&&At.some(Zt=>Zt[0]==="Change")))return;const wt=JSON.stringify({Event:{EventName:"Change",ID:t==null?void 0:t.ID,Info:[]}});localStorage.setItem("change-event",wt)},Ie=()=>{const Xt=f(G1(t==null?void 0:t.ID));s[parseInt(i)-1][parseInt(o)-1]=Z,g({ID:G1(t==null?void 0:t.ID),Properties:{...Xt.Properties,Values:s,CurCell:[parseInt(i),parseInt(o)]}},"WS");const st=JSON.stringify({Event:{EventName:"CellChanged",ID:G1(t==null?void 0:t.ID),Row:parseInt(i),Col:parseInt(o),Value:Z}}),Mt=JSON.stringify({Event:{EventName:"CellChanged",Values:s,CurCell:[i,o]}}),wt=JSON.stringify({FormatCell:{Cell:[i,o],ID:G1(t==null?void 0:t.ID),Value:Z}});localStorage.setItem(G1(t==null?void 0:t.ID),Mt),n&&n.some(Yt=>Yt[0]==="CellChanged")&&(console.log(st),h.send(st),formatString&&(console.log(wt),h.send(wt)))},He=()=>{a=="inGrid"?r!=Z&&(Jt(),Ie()):Jt()},Pe=()=>{const Xt=localStorage.getItem("current-focus");ft(Xt);const st=JSON.stringify({Event:{EventName:"GotFocus",ID:t==null?void 0:t.ID,Info:Xt?[Xt]:[""]}});localStorage.setItem("current-focus",t==null?void 0:t.ID),!(!(At&&At.some(wt=>wt[0]==="GotFocus"))||Xt==(t==null?void 0:t.ID))&&(console.log(st),h.send(st))};if(E={...E,fontFamily:Ft==null?void 0:Ft.PName,fontSize:Ft!=null&&Ft.Size?`${Ft.Size*z}px`:`${12*z}px`,textDecoration:Ft!=null&&Ft.Underline&&(Ft==null?void 0:Ft.Underline)==1?"underline":"none",fontStyle:Ft!=null&&Ft.Italic&&(Ft==null?void 0:Ft.Italic)==1?"italic":"none",fontWeight:Ft!=null&&Ft.Weight?Ft==null?void 0:Ft.Weight:0},R=="date"){const Xt=()=>{Bt.current.select(),Bt.current.showPicker()},st=Mt=>{const wt=q4(Mt.target.value).format(I);let Pt=Wg(Mt.target.value)+1;G(wt),K(Pt)};return vt.jsxs(vt.Fragment,{children:[vt.jsx("input",{id:t==null?void 0:t.ID,style:{...E,borderRadius:"2px",fontSize:"12px",zIndex:1,display:_t==0?"none":"block",paddingLeft:"5px",...we},value:$,type:"text",readOnly:!0,onClick:Xt,onBlur:()=>{He()},onKeyDown:Mt=>Nt(Mt),onMouseDown:Mt=>{Q1(Mt,h,At,t==null?void 0:t.ID)},onMouseUp:Mt=>{tr(Mt,h,At,t==null?void 0:t.ID)},onMouseEnter:Mt=>{er(Mt,h,At,t==null?void 0:t.ID)},onMouseMove:Mt=>{ir(Mt,h,At,t==null?void 0:t.ID)},onMouseLeave:Mt=>{rr(Mt,h,At,t==null?void 0:t.ID)},onWheel:Mt=>{lr(Mt,h,At,t==null?void 0:t.ID)},onDoubleClick:Mt=>{gr(Mt,h,At,t==null?void 0:t.ID)}}),vt.jsx("input",{id:(t==null?void 0:t.ID)+".Picker",type:"date",ref:Bt,onChange:st,disabled:Ut===0,style:{...E,position:"absolute",zIndex:1,display:"none"}})]})}return lt=="LongNumeric"||lt=="Numeric"?vt.jsx(jg,{className:"currency",allowLeadingZeros:!0,getInputRef:Bt,onClick:ce,id:t==null?void 0:t.ID,disabled:Ut===0,style:{...E,width:kt?kt[1]:"100%",zIndex:1,display:_t==0?"none":"block",border:Vt&&Vt=="1"||Lt&&Lt=="Ridge"?"1px solid #6A6A6A":"none",textAlign:"right",verticalAlign:"text-top",paddingBottom:"6px",paddingRight:"2px",...we},onValueChange:Xt=>{G(Xt.value),K(Xt.value)},decimalScale:gt,value:$,decimalSeparator:H,thousandSeparator:lt=="LongNumeric"&&F,onBlur:()=>He(),onKeyDown:Xt=>Nt(Xt),onFocus:Pe,onMouseDown:Xt=>{Q1(Xt,h,At,t==null?void 0:t.ID)},onMouseUp:Xt=>{tr(Xt,h,At,t==null?void 0:t.ID)},onMouseEnter:Xt=>{er(Xt,h,At,t==null?void 0:t.ID)},onMouseMove:Xt=>{ir(Xt,h,At,t==null?void 0:t.ID)},onMouseLeave:Xt=>{rr(Xt,h,At,t==null?void 0:t.ID)},onWheel:Xt=>{lr(Xt,h,At,t==null?void 0:t.ID)},onDoubleClick:Xt=>{gr(Xt,h,At,t==null?void 0:t.ID)}}):vt.jsx("input",{id:t.ID,ref:Bt,value:$,onClick:ce,type:R,disabled:Ut===0,onChange:Xt=>{lt=="Char"&&(K(Xt.target.value),G(Xt.target.value)),lt||(K(Xt.target.value),G(Xt.target.value))},onBlur:()=>{He()},onKeyDown:Xt=>Nt(Xt),style:{...E,width:kt?kt[1]:"100%",borderRadius:"2px",zIndex:1,display:_t==0?"none":"block",paddingLeft:"5px",border:Vt&&Vt=="1"||Lt&&Lt=="Ridge"?"1px solid #6A6A6A":"none",...Ut===0?{backgroundColor:"field",color:"#838383"}:{},...we},maxLength:yt,onFocus:Pe,onMouseDown:Xt=>{Q1(Xt,h,At,t==null?void 0:t.ID)},onMouseUp:Xt=>{tr(Xt,h,At,t==null?void 0:t.ID)},onMouseEnter:Xt=>{er(Xt,h,At,t==null?void 0:t.ID)},onMouseMove:Xt=>{ir(Xt,h,At,t==null?void 0:t.ID)},onMouseLeave:Xt=>{rr(Xt,h,At,t==null?void 0:t.ID)},onWheel:Xt=>{lr(Xt,h,At,t==null?void 0:t.ID)},onDoubleClick:Xt=>{gr(Xt,h,At,t==null?void 0:t.ID)}})},xZ=({data:t,inputValue:r,event:n="",row:i="",column:o="",location:a="",values:s=[]})=>{var oe,ue,xe,Nt,Jt,Ie,He,Pe,Xt,st,Mt;const l=JSON.parse(localStorage.getItem(G1(t==null?void 0:t.ID))),h=Gr(t==null?void 0:t.Properties),{socket:p,findDesiredData:f,dataRef:g,handleData:b,reRender:z}=x1(),{Picture:M,State:I,Visible:F,Event:H,Caption:E,Align:R,Posn:W,Size:$,CSS:G,Active:Z}=t==null?void 0:t.Properties;console.log("data Button",t);const K=$1(G),et=_.useRef(),at=_.useRef(),tt=y4(document.getElementById(G1(t==null?void 0:t.ID))),[ft,dt]=_.useState(),[ht,lt]=_.useState(I||0),yt=t.Properties.hasOwnProperty("Caption"),mt=((oe=t==null?void 0:t.Properties)==null?void 0:oe.Style)&&((ue=t==null?void 0:t.Properties)==null?void 0:ue.Style)=="Check",gt=((xe=t==null?void 0:t.Properties)==null?void 0:xe.Style)&&((Nt=t==null?void 0:t.Properties)==null?void 0:Nt.Style)=="Radio",_t=f(M&&M[0]),At=t.Properties.Event&&((Jt=t==null?void 0:t.Properties)==null?void 0:Jt.Event[0]),bt=$9(M&&M[1],_t),[kt,Lt]=_.useState({top:W&&W[0],left:W&&W[1]}),[Vt,Rt]=_.useState(l==null?void 0:l.Size),Ut=()=>{if(a=="inGrid")return dt(r);dt(I&&I)};_.useEffect(()=>{Ut(),Lt({top:W&&W[0],left:W&&W[1]})},[t]);const Kt=E!=null&&E.includes("&")?E==null?void 0:E.charAt(E.indexOf("&")+1).toLowerCase():null;_.useEffect(()=>{const wt=Pt=>{Kt&&Pt.altKey&&Pt.key.toLowerCase()===Kt&&It(e)};return document.addEventListener("keydown",wt),()=>document.removeEventListener("keydown",wt)},[Kt]),_.useEffect(()=>{var wt;if(((wt=t==null?void 0:t.Properties)==null?void 0:wt.Default)===1){const Pt=Yt=>{Yt.key==="Enter"&&It(Yt)};return document.addEventListener("keydown",Pt),()=>document.removeEventListener("keydown",Pt)}},[t,At]);const It=wt=>{var Pt;if(Z===0){wt.preventDefault();return}(Pt=document.getElementById(localStorage.getItem("current-focus")))==null||Pt.blur(),At&&(console.log(JSON.stringify({Event:{EventName:At[0],ID:t==null?void 0:t.ID}})),localStorage.getItem("current-focus")&&localStorage.getItem("shouldChangeEvent")==="true"&&(console.log(JSON.stringify({Event:{EventName:"Change",ID:localStorage.getItem("current-focus"),Info:[t==null?void 0:t.ID]}})),p.send(JSON.stringify({Event:{EventName:"Change",ID:localStorage.getItem("current-focus"),Info:[t==null?void 0:t.ID]}}))),p.send(JSON.stringify({Event:{EventName:At[0],ID:t==null?void 0:t.ID}})),ge())};_.useEffect(()=>{var Yt;if(!kt||!Vt)return;let wt=kt&&kt.left&&Vt&&Vt[1]?kt.left/Vt[1]*tt.width:0;wt=Math.max(0,Math.min(wt,tt.width));let Pt=kt&&kt.top&&Vt&&Vt[0]?kt.top/Vt[0]*tt.height:0;if(Pt=Math.max(0,Math.min(Pt,tt.height)),Lt({top:Math.round(Pt),left:Math.round(wt)}),Rt([tt==null?void 0:tt.height,tt==null?void 0:tt.width]),b({ID:t==null?void 0:t.ID,Properties:{...(Yt=t==null?void 0:t.Properties)!=null&&Yt.hasOwnProperty("Posn")?{Posn:[Math.round(Pt),Math.round(wt)]}:{}}},"WS"),localStorage.getItem(t==null?void 0:t.ID)){const{Event:Zt}=JSON.parse(localStorage.getItem(t==null?void 0:t.ID)),{Value:ae}=Zt,ee=JSON.stringify({Event:{EventName:"Select",ID:t==null?void 0:t.ID,Value:ae,Posn:[Math.round(Pt),Math.round(wt)],Size:[$&&$[0],$&&$[1]]}});localStorage.setItem(t==null?void 0:t.ID,ee)}else{const Zt=JSON.stringify({Event:{EventName:"Select",ID:t==null?void 0:t.ID,Value:0,Posn:[Math.round(Pt),Math.round(wt)],Size:[$&&$[0],$&&$[1]]}});localStorage.setItem(t==null?void 0:t.ID,Zt)}Rt([tt==null?void 0:tt.height,tt==null?void 0:tt.width]),z()},[tt]);const le=wt=>{const Pt=f(G1(t==null?void 0:t.ID));s[parseInt(i)-1][parseInt(o)-1]=wt?1:0,b({ID:G1(t==null?void 0:t.ID),Properties:{...Pt.Properties,Values:s,CurCell:[i,o]}},"WS");const Yt=JSON.stringify({Event:{EventName:"CellChanged",ID:G1(t==null?void 0:t.ID),Row:parseInt(i),Col:parseInt(o),Value:wt?1:0}}),Zt=JSON.stringify({Event:{EventName:"CellChanged",Values:s,CurCell:[i,o]}}),ae=JSON.stringify({FormatCell:{Cell:[i,o],ID:G1(t==null?void 0:t.ID),Value:wt?1:0}});localStorage.setItem(G1(t==null?void 0:t.ID),Zt),n&&n.some(jt=>jt[0]==="CellChanged")&&(console.log(Yt),console.log(ae),p.send(ae),p.send(Yt))},Bt=wt=>{const Pt=JSON.stringify({Event:{EventName:"Select",ID:t==null?void 0:t.ID,Value:wt?1:0,Posn:[kt==null?void 0:kt.top,kt==null?void 0:kt.left],Size:[$&&$[0],$&&$[1]]}});if(localStorage.setItem(t==null?void 0:t.ID,Pt),!(H&&H.some(ae=>ae[0]==="Select")))return;console.log(Pt);const Zt=JSON.stringify({Event:{EventName:"Select",ID:t==null?void 0:t.ID}});p.send(Zt)},de=wt=>{a=="inGrid"?(Bt(wt),le(wt)):Bt(wt)},Ft=(wt,Pt,Yt)=>{const Zt=Yt?0:1,ae=JSON.stringify({Event:{ID:G1(t==null?void 0:t.ID),EventName:"CellMove",Info:[wt,Pt,Zt,0,Yt,ft?1:0]}});n&&n.some(jt=>jt[0]==="CellMove")&&(console.log(ae),p.send(ae))},we=()=>{if(a!=="inGrid")return;const Zt=et.current.parentElement.parentElement.parentElement.nextSibling;Ft(i+1,o,0);const ae=Zt==null?void 0:Zt.querySelectorAll("input");ae&&ae.forEach(ee=>{ee.id===(t==null?void 0:t.ID)&&ee.focus()})},Ht=()=>{if(a!=="inGrid")return;const Yt=et.current.parentElement.parentElement.nextSibling,Zt=gl(g.current,Yt==null?void 0:Yt.id);Ft(i,o+1,0);const ae=Yt==null?void 0:Yt.querySelectorAll(Zt);return Zt=="select"?ae&&ae[0].focus():ae&&ae[0].select()},ce=()=>{var ee,jt;if(a!=="inGrid")return;console.log(et);const Yt=et.current.parentElement.parentElement.previousSibling,Zt=gl(g.current,Yt==null?void 0:Yt.id);Ft(i,o-1,0);const ae=Yt==null?void 0:Yt.querySelectorAll(Zt);return ae&&((ee=ae[0])==null||ee.focus()),ae&&((jt=ae[0])==null?void 0:jt.select())},Se=()=>{if(a!=="inGrid")return;const Zt=et.current.parentElement.parentElement.parentElement.previousSibling;Ft(i-1,o,0);const ae=Zt==null?void 0:Zt.querySelectorAll("input");ae&&ae.forEach(ee=>{ee.id===(t==null?void 0:t.ID)&&ee.focus()})},qt=wt=>{Ln(wt,p,H,t==null?void 0:t.ID),wt.key=="Enter"?we():wt.key=="ArrowRight"?Ht():wt.key=="ArrowLeft"?ce():wt.key=="ArrowDown"?we():wt.key=="ArrowUp"&&Se()},ge=()=>{const wt=localStorage.getItem("current-focus"),Pt=JSON.stringify({Event:{EventName:"GotFocus",ID:t==null?void 0:t.ID,Info:wt?[wt]:[""]}});localStorage.setItem("current-focus",t==null?void 0:t.ID),!(!(H&&H.some(Zt=>Zt[0]==="GotFocus"))||wt==(t==null?void 0:t.ID))&&(console.log(Pt),p.send(Pt))};if(mt){let wt=null;return R&&R=="Left"?wt={position:"absolute",right:0,top:3}:(!R||R=="Right")&&(wt={position:"absolute",left:0,top:3}),a=="inGrid"&&(wt={...wt,marginLeft:"5px"}),vt.jsxs("div",{id:t.ID+".$CONTAINER",onKeyDown:Pt=>qt(Pt),style:{...h,zIndex:1,display:F==0?"none":"block"},children:[R&&R=="Left"?vt.jsx("div",{style:{fontSize:"12px",position:"absolute",top:0,left:0},children:vt.jsx("label",{for:t==null?void 0:t.ID,children:E})}):null,vt.jsx("input",{onFocus:ge,ref:et,onKeyDown:Pt=>qt(Pt),id:t==null?void 0:t.ID,type:"checkbox",style:wt,checked:ft,disabled:Z===0,onChange:Pt=>{dt(Pt.target.checked),de(Pt.target.checked)}}),!R||R=="Right"?vt.jsx("div",{style:{fontSize:"12px",position:"absolute",top:0,left:16,...K},children:vt.jsx("label",{for:t==null?void 0:t.ID,children:E})}):null]})}if(gt){const wt=Yt=>{const Zt=JSON.stringify({Event:{EventName:"Select",ID:t==null?void 0:t.ID,Value:Yt}});if(!(H&&H.some(jt=>jt[0]==="Select")))return;const ee=JSON.stringify({Event:{EventName:"Select",ID:t==null?void 0:t.ID}});console.log(Zt),p.send(ee)},Pt=(Yt,Zt)=>{for(var ee=document.getElementById(G1(t==null?void 0:t.ID)).getElementsByTagName("input"),jt=0;jt{lt(I)},[t]),vt.jsxs("div",{id:(t==null?void 0:t.ID)+".$CONTAINER",style:{...h,zIndex:1,display:F==0?"none":"block",...K},children:[R&&R=="Left"?vt.jsx("div",{style:{fontSize:"12px",position:"absolute",top:2,left:0,...K},children:E}):null,vt.jsx("input",{onFocus:ge,name:G1(t==null?void 0:t.ID),id:t==null?void 0:t.ID,checked:ht,type:"radio",value:E,disabled:Z===0,onChange:Yt=>{Pt(t==null?void 0:t.ID,Yt.target.checked)}}),!R||R=="Right"?vt.jsx("div",{style:{fontSize:"12px",position:"absolute",top:2,left:16,...K},children:vt.jsx("label",{for:t==null?void 0:t.ID,children:E})}):null]})}return vt.jsxs("div",{id:t==null?void 0:t.ID,onMouseDown:wt=>{Q1(wt,p,H,t==null?void 0:t.ID)},onMouseUp:wt=>{tr(wt,p,H,t==null?void 0:t.ID)},onMouseEnter:wt=>{er(wt,p,H,t==null?void 0:t.ID)},onMouseMove:wt=>{ir(wt,p,H,t==null?void 0:t.ID)},onMouseLeave:wt=>{rr(wt,p,H,t==null?void 0:t.ID)},onWheel:wt=>{lr(wt,p,H,t==null?void 0:t.ID)},onDoubleClick:wt=>{gr(wt,p,H,t==null?void 0:t.ID)},ref:at,onClick:wt=>{It(wt)},style:{...h,border:"1px solid black",textAlign:"center",alignItems:"center",justifyContent:"center",background:"white",borderRadius:"4px",borderColor:"#ccc",fontSize:"12px",color:Z===0?"#838383":"black",cursor:"pointer",zIndex:1,paddingLeft:"3px",paddingRight:"3px",display:F==0?"none":"flex",...(Ie=t==null?void 0:t.Properties)!=null&&Ie.hasOwnProperty("Posn")?{top:kt==null?void 0:kt.top}:{},...(He=t==null?void 0:t.Properties)!=null&&He.hasOwnProperty("Posn")?{left:kt==null?void 0:kt.left}:{},...K},children:[_t?vt.jsx("div",{style:{...bt,width:"100%",height:"100%"}}):null,yt?(Xt=(Pe=t==null?void 0:t.Properties)==null?void 0:Pe.Caption)!=null&&Xt.includes("&")?vt.jsx("span",{dangerouslySetInnerHTML:{__html:(st=t==null?void 0:t.Properties)==null?void 0:st.Caption.replace(/&(\w)/,"$1")}}):vt.jsx("span",{children:(Mt=t==null?void 0:t.Properties)==null?void 0:Mt.Caption}):null]})},bZ=({data:t,value:r,event:n="",row:i="",column:o="",location:a="",values:s=[]})=>{const l=JSON.parse(localStorage.getItem(G1(t==null?void 0:t.ID))),{CSS:h}=t.Properties,p=$1(h),f=_.useRef(),{socket:g,handleData:b,findDesiredData:z,reRender:M,dataRef:I}=x1(),F=Gr(t==null?void 0:t.Properties),{Items:H,SelItems:E,Event:R,Visible:W,Posn:$,Size:G}=t==null?void 0:t.Properties,Z=y4(document.getElementById(G1(t==null?void 0:t.ID)));console.log("this event",{Event:R});const[K,et]=_.useState("+"),[at,tt]=_.useState({top:$&&$[0],left:$&&$[1]}),[ft,dt]=_.useState(l==null?void 0:l.Size);_.useEffect(()=>{const Lt=E==null?void 0:E.findIndex(Rt=>Rt==1);et(H[Lt]);const Vt=JSON.stringify({Event:{EventName:"Select",ID:t==null?void 0:t.ID,Info:Lt+1,Text:H&&H[Lt],Posn:[at==null?void 0:at.top,at==null?void 0:at.left],Size:[G&&G[0],G&&G[1]]}});localStorage.setItem(t==null?void 0:t.ID,Vt)},[t]);const ht=Lt=>{const Vt=z(G1(t==null?void 0:t.ID));s[parseInt(i)-1][parseInt(o)-1]=Lt,b({ID:G1(t==null?void 0:t.ID),Properties:{...Vt.Properties,Values:s,CurCell:[i,o]}},"WS");const Rt=JSON.stringify({Event:{EventName:"CellChanged",ID:G1(t==null?void 0:t.ID),Row:parseInt(i),Col:parseInt(o),Value:Lt}}),Ut=JSON.stringify({Event:{EventName:"CellChanged",Values:s,CurCell:[i,o]}});localStorage.setItem(G1(t==null?void 0:t.ID),Ut),n&&n.some(It=>It[0]==="CellChanged")&&(console.log(Rt),g.send(Rt))},lt=Lt=>{const Vt=new Array(H.length).fill(0);b({ID:t==null?void 0:t.ID,Properties:{...t==null?void 0:t.Properties,SelItems:Vt,Text:H&&H[Lt]}},"WS");const Rt=JSON.stringify({Event:{EventName:"Select",ID:t==null?void 0:t.ID,Info:parseInt(Lt+1),Text:H&&H[Lt],SelItems:Vt,Posn:[at==null?void 0:at.top,at==null?void 0:at.left],Size:[G&&G[0],G&&G[1]]}}),Ut=JSON.stringify({Event:{EventName:"Select",ID:t==null?void 0:t.ID}});localStorage.setItem(t==null?void 0:t.ID,Rt),R&&R.some(It=>It[0]==="Select")&&(console.log(Rt),g.send(Ut))},yt=Lt=>{const Vt=H.indexOf(Lt);a=="inGrid"?(lt(Vt),ht(Lt)):lt(Vt)};_.useEffect(()=>{if(!at||!ft)return;let Lt=at&&at.left&&ft&&ft[1]?at.left/ft[1]*Z.width:0;Lt=Math.max(0,Math.min(Lt,Z.width));let Vt=at&&at.top&&ft&&ft[0]?at.top/ft[0]*Z.height:0;Vt=Math.max(0,Math.min(Vt,Z.height)),tt({top:Vt,left:Lt}),b({ID:t==null?void 0:t.ID,Properties:{Posn:[Vt,Lt]}},"WS"),dt([Z==null?void 0:Z.height,Z==null?void 0:Z.width]),M()},[Z]);const mt=(Lt,Vt,Rt,Ut)=>{console.log("265 combo");const Kt=Rt?0:1,It=JSON.stringify({Event:{ID:G1(t==null?void 0:t.ID),EventName:"CellMove",Info:[Lt,Vt,Kt,0,Rt,Ut]}});n&&n.some(Bt=>Bt[0]==="CellMove")&&(console.log(It),g.send(It))},gt=Lt=>{if(a!=="inGrid")return;console.log(f);const Ut=f.current.parentElement.parentElement.nextSibling,Kt=gl(I.current,Ut==null?void 0:Ut.id);mt(i,o+1,0,Lt);const It=Ut==null?void 0:Ut.querySelectorAll(Kt);return console.log({element:It}),Kt=="select"?It&&It[0].focus():It&&It[0].select()},_t=Lt=>{if(a!=="inGrid")return;console.log(f);const Ut=f.current.parentElement.parentElement.previousSibling,Kt=gl(I.current,Ut==null?void 0:Ut.id);mt(i,o-1,0,Lt);const It=Ut==null?void 0:Ut.querySelectorAll(Kt);return Kt=="select"?It&&It[0].focus():It&&It[0].select()},At=Lt=>{if(a!=="inGrid")return;const Kt=f.current.parentElement.parentElement.parentElement.previousSibling,It=Kt==null?void 0:Kt.querySelectorAll("select");mt(i-1,o,0,Lt),It&&It.forEach(le=>{le.id===(t==null?void 0:t.ID)&&le.focus()})},bt=Lt=>{if(a!=="inGrid")return;const Kt=f.current.parentElement.parentElement.parentElement.nextSibling;mt(i+1,o,0,Lt);const It=Kt==null?void 0:Kt.querySelectorAll("select");It&&It.forEach(le=>{le.id===(t==null?void 0:t.ID)&&le.focus()})},kt=Lt=>{Lt.stopPropagation(),Lt.preventDefault(),Ln(Lt,g,R,t==null?void 0:t.ID),Lt.key=="ArrowRight"?gt(Lt.target.value):Lt.key=="ArrowLeft"?_t(Lt.target.value):Lt.key=="ArrowDown"?bt(Lt.target.value):Lt.key=="ArrowUp"&&At(Lt.target.value)};return vt.jsx("div",{style:{...F,borderColor:"#ccc",display:W==0?"none":"block",top:at==null?void 0:at.top,left:at==null?void 0:at.left},onMouseDown:Lt=>{Lt.stopPropagation(),Q1(Lt,g,R,t==null?void 0:t.ID)},onMouseUp:Lt=>{Lt.stopPropagation(),tr(Lt,g,R,t==null?void 0:t.ID)},onMouseEnter:Lt=>{Lt.stopPropagation(),er(Lt,g,R,t==null?void 0:t.ID)},onMouseMove:Lt=>{Lt.stopPropagation(),ir(Lt,g,R,t==null?void 0:t.ID)},onMouseLeave:Lt=>{Lt.stopPropagation(),rr(Lt,g,R,t==null?void 0:t.ID)},onWheel:Lt=>{lr(Lt,g,R,t==null?void 0:t.ID)},onDoubleClick:Lt=>{Lt.stopPropagation(),gr(Lt,g,R,t==null?void 0:t.ID)},onKeyDown:Lt=>{Ln(Lt,g,R,t==null?void 0:t.ID)},children:vt.jsx("select",{ref:f,onKeyDown:Lt=>kt(Lt),id:t==null?void 0:t.ID,value:r||K,style:{width:"100%",border:0,fontSize:"12px",height:a==="inGrid"?null:"100%",zIndex:1,...p},onChange:Lt=>{Lt.stopPropagation(),et(Lt.target.value),yt(Lt.target.value)},children:H&&H.map((Lt,Vt)=>vt.jsx("option",{value:Lt,children:Lt},Vt))})})};const wZ=({data:t,gridValue:r})=>{var F,H,E,R,W;let n=Gr(t==null?void 0:t.Properties);const{findDesiredData:i,fontScale:o,socket:a}=x1(),s=t==null?void 0:t.Properties.hasOwnProperty("FCol"),l=t==null?void 0:t.Properties.hasOwnProperty("Font"),{Visible:h,FontObj:p,Caption:f,Size:g,BCol:b,Event:z,CSS:M}=t==null?void 0:t.Properties;console.log("data Label",t);const I=$1(M);if(s&&(n={...n,color:`rgb(${(F=t==null?void 0:t.Properties)==null?void 0:F.FCol[0]},${(H=t==null?void 0:t.Properties)==null?void 0:H.FCol[1]},${(E=t==null?void 0:t.Properties)==null?void 0:E.FCol[2]})`}),l)n={...n,fontFamily:(R=t.Properties)==null?void 0:R.Font[0],fontSize:(W=t==null?void 0:t.Properties)==null?void 0:W.Font[1]};else{const $=i(p&&p),G=$&&($==null?void 0:$.Properties);n={...n,fontFamily:G==null?void 0:G.PName,fontSize:G!=null&&G.Size?`${G.Size*o}px`:`${12*o}px`,textDecoration:G!=null&&G.Underline&&(G==null?void 0:G.Underline)==1?"underline":"none",fontStyle:G!=null&&G.Italic&&(G==null?void 0:G.Italic)==1?"italic":"none",fontWeight:G!=null&&G.Weight?G==null?void 0:G.Weight:0,background:b&&Er(b)}}return vt.jsx("div",{id:t==null?void 0:t.ID,style:{...n,display:h==0?"none":"block",...I},onMouseDown:$=>{Q1($,a,z,t==null?void 0:t.ID)},onMouseUp:$=>{tr($,a,z,t==null?void 0:t.ID)},onMouseEnter:$=>{er($,a,z,t==null?void 0:t.ID)},onMouseMove:$=>{ir($,a,z,t==null?void 0:t.ID)},onMouseLeave:$=>{rr($,a,z,t==null?void 0:t.ID)},children:f||vt.jsx("span",{style:{display:"flex",justifyContent:typeof r=="string"?"start":"end",fontSize:"12px",marginLeft:"5px"},children:r})})};function Xi(){return Xi=Object.assign?Object.assign.bind():function(t){for(var r=1;rt.length)&&(r=t.length);for(var n=0,i=new Array(r);n"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function _Z(t,r){if(r&&(Ji(r)==="object"||typeof r=="function"))return r;if(r!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Le(t)}function P8(t){var r=kZ();return function(){var i=_u(t),o;if(r){var a=_u(this).constructor;o=Reflect.construct(i,arguments,a)}else o=i.apply(this,arguments);return _Z(this,o)}}var AD={exports:{}};/*! Copyright (c) 2018 Jed Watson. Licensed under the MIT License (MIT), see http://jedwatson.github.io/classnames -*/(function(t){(function(){var r={}.hasOwnProperty;function n(){for(var i=[],o=0;o=Ze.F1&&n<=Ze.F12)return!1;switch(n){case Ze.ALT:case Ze.CAPS_LOCK:case Ze.CONTEXT_MENU:case Ze.CTRL:case Ze.DOWN:case Ze.END:case Ze.ESC:case Ze.HOME:case Ze.INSERT:case Ze.LEFT:case Ze.MAC_FF_META:case Ze.META:case Ze.NUMLOCK:case Ze.NUM_CENTER:case Ze.PAGE_DOWN:case Ze.PAGE_UP:case Ze.PAUSE:case Ze.PRINT_SCREEN:case Ze.RIGHT:case Ze.SHIFT:case Ze.UP:case Ze.WIN_KEY:case Ze.WIN_KEY_RIGHT:return!1;default:return!0}},isCharacterKey:function(r){if(r>=Ze.ZERO&&r<=Ze.NINE||r>=Ze.NUM_ZERO&&r<=Ze.NUM_MULTIPLY||r>=Ze.A&&r<=Ze.Z||window.navigator.userAgent.indexOf("WebKit")!==-1&&r===0)return!0;switch(r){case Ze.SPACE:case Ze.QUESTION_MARK:case Ze.NUM_PLUS:case Ze.NUM_MINUS:case Ze.NUM_PERIOD:case Ze.NUM_DIVISION:case Ze.SEMICOLON:case Ze.DASH:case Ze.EQUALS:case Ze.COMMA:case Ze.PERIOD:case Ze.SLASH:case Ze.APOSTROPHE:case Ze.SINGLE_QUOTE:case Ze.OPEN_SQUARE_BRACKET:case Ze.BACKSLASH:case Ze.CLOSE_SQUARE_BRACKET:return!0;default:return!1}}},AZ=`accept acceptCharset accessKey action allowFullScreen allowTransparency +*/(function(t){(function(){var r={}.hasOwnProperty;function n(){for(var i=[],o=0;o=Ze.F1&&n<=Ze.F12)return!1;switch(n){case Ze.ALT:case Ze.CAPS_LOCK:case Ze.CONTEXT_MENU:case Ze.CTRL:case Ze.DOWN:case Ze.END:case Ze.ESC:case Ze.HOME:case Ze.INSERT:case Ze.LEFT:case Ze.MAC_FF_META:case Ze.META:case Ze.NUMLOCK:case Ze.NUM_CENTER:case Ze.PAGE_DOWN:case Ze.PAGE_UP:case Ze.PAUSE:case Ze.PRINT_SCREEN:case Ze.RIGHT:case Ze.SHIFT:case Ze.UP:case Ze.WIN_KEY:case Ze.WIN_KEY_RIGHT:return!1;default:return!0}},isCharacterKey:function(r){if(r>=Ze.ZERO&&r<=Ze.NINE||r>=Ze.NUM_ZERO&&r<=Ze.NUM_MULTIPLY||r>=Ze.A&&r<=Ze.Z||window.navigator.userAgent.indexOf("WebKit")!==-1&&r===0)return!0;switch(r){case Ze.SPACE:case Ze.QUESTION_MARK:case Ze.NUM_PLUS:case Ze.NUM_MINUS:case Ze.NUM_PERIOD:case Ze.NUM_DIVISION:case Ze.SEMICOLON:case Ze.DASH:case Ze.EQUALS:case Ze.COMMA:case Ze.PERIOD:case Ze.SLASH:case Ze.APOSTROPHE:case Ze.SINGLE_QUOTE:case Ze.OPEN_SQUARE_BRACKET:case Ze.BACKSLASH:case Ze.CLOSE_SQUARE_BRACKET:return!0;default:return!1}}},LZ=`accept acceptCharset accessKey action allowFullScreen allowTransparency alt async autoComplete autoFocus autoPlay capture cellPadding cellSpacing challenge charSet checked classID className colSpan cols content contentEditable contextMenu controls coords crossOrigin data dateTime default defer dir disabled download draggable @@ -97,14 +97,14 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho optimum pattern placeholder poster preload radioGroup readOnly rel required reversed role rowSpan rows sandbox scope scoped scrolling seamless selected shape size sizes span spellCheck src srcDoc srcLang srcSet start step style - summary tabIndex target title type useMap value width wmode wrap`,LZ=`onCopy onCut onPaste onCompositionEnd onCompositionStart onCompositionUpdate onKeyDown + summary tabIndex target title type useMap value width wmode wrap`,EZ=`onCopy onCut onPaste onCompositionEnd onCompositionStart onCompositionUpdate onKeyDown onKeyPress onKeyUp onFocus onBlur onChange onInput onSubmit onClick onContextMenu onDoubleClick onDrag onDragEnd onDragEnter onDragExit onDragLeave onDragOver onDragStart onDrop onMouseDown onMouseEnter onMouseLeave onMouseMove onMouseOut onMouseOver onMouseUp onSelect onTouchCancel onTouchEnd onTouchMove onTouchStart onScroll onWheel onAbort onCanPlay onCanPlayThrough onDurationChange onEmptied onEncrypted onEnded onError onLoadedData onLoadedMetadata - onLoadStart onPause onPlay onPlaying onProgress onRateChange onSeeked onSeeking onStalled onSuspend onTimeUpdate onVolumeChange onWaiting onLoad onError`,EZ="".concat(AZ," ").concat(LZ).split(/[\s\n]+/),IZ="aria-",HZ="data-";function nk(t,r){return t.indexOf(r)===0}function AD(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,n;r===!1?n={aria:!0,data:!0,attr:!0}:r===!0?n={aria:!0}:n=Ke({},r);var i={};return Object.keys(t).forEach(function(o){(n.aria&&(o==="role"||nk(o,IZ))||n.data&&nk(o,HZ)||n.attr&&EZ.includes(o))&&(i[o]=t[o])}),i}var Ug={},DZ=function(r){};function PZ(t,r){}function TZ(t,r){}function VZ(){Ug={}}function LD(t,r,n){!r&&!Ug[n]&&(t(!1,n),Ug[n]=!0)}function co(t,r){LD(PZ,t,r)}function FZ(t,r){LD(TZ,t,r)}co.preMessage=DZ;co.resetWarned=VZ;co.noteOnce=FZ;var Wx=_.createContext(null);function RZ(t){var r=t.dropPosition,n=t.dropLevelOffset,i=t.indent,o={pointerEvents:"none",position:"absolute",right:0,backgroundColor:"red",height:2};switch(r){case-1:o.top=0,o.left=-n*i;break;case 1:o.bottom=0,o.left=-n*i;break;case 0:o.bottom=0,o.left=i;break}return _.createElement("div",{style:o})}function ED(t){if(t==null)throw new TypeError("Cannot destructure "+t)}function OZ(t){if(Array.isArray(t))return t}function BZ(t,r){var n=t==null?null:typeof Symbol<"u"&&t[Symbol.iterator]||t["@@iterator"];if(n!=null){var i,o,a,s,l=[],h=!0,p=!1;try{if(a=(n=n.call(t)).next,r===0){if(Object(n)!==n)return;h=!1}else for(;!(h=(i=a.call(n)).done)&&(l.push(i.value),l.length!==r);h=!0);}catch(f){p=!0,o=f}finally{try{if(!h&&n.return!=null&&(s=n.return(),Object(s)!==s))return}finally{if(p)throw o}}return l}}function NZ(){throw new TypeError(`Invalid attempt to destructure non-iterable instance. -In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function $1(t,r){return OZ(t)||BZ(t,r)||kD(t,r)||NZ()}function j9(t,r){if(t==null)return{};var n={},i=Object.keys(t),o,a;for(a=0;a=0)&&(n[o]=t[o]);return n}function C0(t,r){if(t==null)return{};var n=j9(t,r),i,o;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);for(o=0;o=0)&&Object.prototype.propertyIsEnumerable.call(t,i)&&(n[i]=t[i])}return n}function G9(){return!!(typeof window<"u"&&window.document&&window.document.createElement)}var ok=G9()?_.useLayoutEffect:_.useEffect,Ba=function(r,n){var i=_.useRef(!0);ok(function(){return r(i.current)},n),ok(function(){return i.current=!1,function(){i.current=!0}},[])},ID={exports:{}},pr={};/** + onLoadStart onPause onPlay onPlaying onProgress onRateChange onSeeked onSeeking onStalled onSuspend onTimeUpdate onVolumeChange onWaiting onLoad onError`,IZ="".concat(LZ," ").concat(EZ).split(/[\s\n]+/),HZ="aria-",DZ="data-";function ok(t,r){return t.indexOf(r)===0}function LD(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,n;r===!1?n={aria:!0,data:!0,attr:!0}:r===!0?n={aria:!0}:n=Ke({},r);var i={};return Object.keys(t).forEach(function(o){(n.aria&&(o==="role"||ok(o,HZ))||n.data&&ok(o,DZ)||n.attr&&IZ.includes(o))&&(i[o]=t[o])}),i}var Ug={},PZ=function(r){};function TZ(t,r){}function VZ(t,r){}function FZ(){Ug={}}function ED(t,r,n){!r&&!Ug[n]&&(t(!1,n),Ug[n]=!0)}function oo(t,r){ED(TZ,t,r)}function RZ(t,r){ED(VZ,t,r)}oo.preMessage=PZ;oo.resetWarned=FZ;oo.noteOnce=RZ;var jx=_.createContext(null);function OZ(t){var r=t.dropPosition,n=t.dropLevelOffset,i=t.indent,o={pointerEvents:"none",position:"absolute",right:0,backgroundColor:"red",height:2};switch(r){case-1:o.top=0,o.left=-n*i;break;case 1:o.bottom=0,o.left=-n*i;break;case 0:o.bottom=0,o.left=i;break}return _.createElement("div",{style:o})}function ID(t){if(t==null)throw new TypeError("Cannot destructure "+t)}function BZ(t){if(Array.isArray(t))return t}function NZ(t,r){var n=t==null?null:typeof Symbol<"u"&&t[Symbol.iterator]||t["@@iterator"];if(n!=null){var i,o,a,s,l=[],h=!0,p=!1;try{if(a=(n=n.call(t)).next,r===0){if(Object(n)!==n)return;h=!1}else for(;!(h=(i=a.call(n)).done)&&(l.push(i.value),l.length!==r);h=!0);}catch(f){p=!0,o=f}finally{try{if(!h&&n.return!=null&&(s=n.return(),Object(s)!==s))return}finally{if(p)throw o}}return l}}function $Z(){throw new TypeError(`Invalid attempt to destructure non-iterable instance. +In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function B1(t,r){return BZ(t)||NZ(t,r)||_D(t,r)||$Z()}function j9(t,r){if(t==null)return{};var n={},i=Object.keys(t),o,a;for(a=0;a=0)&&(n[o]=t[o]);return n}function C0(t,r){if(t==null)return{};var n=j9(t,r),i,o;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);for(o=0;o=0)&&Object.prototype.propertyIsEnumerable.call(t,i)&&(n[i]=t[i])}return n}function G9(){return!!(typeof window<"u"&&window.document&&window.document.createElement)}var ak=G9()?_.useLayoutEffect:_.useEffect,Oa=function(r,n){var i=_.useRef(!0);ak(function(){return r(i.current)},n),ak(function(){return i.current=!1,function(){i.current=!0}},[])},HD={exports:{}},hr={};/** * @license React * react-is.production.min.js * @@ -112,71 +112,71 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. - */var jx=Symbol.for("react.element"),Gx=Symbol.for("react.portal"),U9=Symbol.for("react.fragment"),Y9=Symbol.for("react.strict_mode"),X9=Symbol.for("react.profiler"),K9=Symbol.for("react.provider"),q9=Symbol.for("react.context"),$Z=Symbol.for("react.server_context"),Z9=Symbol.for("react.forward_ref"),J9=Symbol.for("react.suspense"),Q9=Symbol.for("react.suspense_list"),tp=Symbol.for("react.memo"),ep=Symbol.for("react.lazy"),WZ=Symbol.for("react.offscreen"),HD;HD=Symbol.for("react.module.reference");function Y2(t){if(typeof t=="object"&&t!==null){var r=t.$$typeof;switch(r){case jx:switch(t=t.type,t){case U9:case X9:case Y9:case J9:case Q9:return t;default:switch(t=t&&t.$$typeof,t){case $Z:case q9:case Z9:case ep:case tp:case K9:return t;default:return r}}case Gx:return r}}}pr.ContextConsumer=q9;pr.ContextProvider=K9;pr.Element=jx;pr.ForwardRef=Z9;pr.Fragment=U9;pr.Lazy=ep;pr.Memo=tp;pr.Portal=Gx;pr.Profiler=X9;pr.StrictMode=Y9;pr.Suspense=J9;pr.SuspenseList=Q9;pr.isAsyncMode=function(){return!1};pr.isConcurrentMode=function(){return!1};pr.isContextConsumer=function(t){return Y2(t)===q9};pr.isContextProvider=function(t){return Y2(t)===K9};pr.isElement=function(t){return typeof t=="object"&&t!==null&&t.$$typeof===jx};pr.isForwardRef=function(t){return Y2(t)===Z9};pr.isFragment=function(t){return Y2(t)===U9};pr.isLazy=function(t){return Y2(t)===ep};pr.isMemo=function(t){return Y2(t)===tp};pr.isPortal=function(t){return Y2(t)===Gx};pr.isProfiler=function(t){return Y2(t)===X9};pr.isStrictMode=function(t){return Y2(t)===Y9};pr.isSuspense=function(t){return Y2(t)===J9};pr.isSuspenseList=function(t){return Y2(t)===Q9};pr.isValidElementType=function(t){return typeof t=="string"||typeof t=="function"||t===U9||t===X9||t===Y9||t===J9||t===Q9||t===WZ||typeof t=="object"&&t!==null&&(t.$$typeof===ep||t.$$typeof===tp||t.$$typeof===K9||t.$$typeof===q9||t.$$typeof===Z9||t.$$typeof===HD||t.getModuleId!==void 0)};pr.typeOf=Y2;ID.exports=pr;var DD=ID.exports;function Au(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=[];return cr.Children.forEach(t,function(i){i==null&&!r.keepEmpty||(Array.isArray(i)?n=n.concat(Au(i)):DD.isFragment(i)&&i.props?n=n.concat(Au(i.props.children,r)):n.push(i))}),n}function PD(t,r){typeof t=="function"?t(r):tn(t)==="object"&&t&&"current"in t&&(t.current=r)}function jZ(){for(var t=arguments.length,r=new Array(t),n=0;n0},t.prototype.connect_=function(){!Yg||this.connected_||(document.addEventListener("transitionend",this.onTransitionEnd_),window.addEventListener("resize",this.refresh),ZZ?(this.mutationsObserver_=new MutationObserver(this.refresh),this.mutationsObserver_.observe(document,{attributes:!0,childList:!0,characterData:!0,subtree:!0})):(document.addEventListener("DOMSubtreeModified",this.refresh),this.mutationEventsAdded_=!0),this.connected_=!0)},t.prototype.disconnect_=function(){!Yg||!this.connected_||(document.removeEventListener("transitionend",this.onTransitionEnd_),window.removeEventListener("resize",this.refresh),this.mutationsObserver_&&this.mutationsObserver_.disconnect(),this.mutationEventsAdded_&&document.removeEventListener("DOMSubtreeModified",this.refresh),this.mutationsObserver_=null,this.mutationEventsAdded_=!1,this.connected_=!1)},t.prototype.onTransitionEnd_=function(r){var n=r.propertyName,i=n===void 0?"":n,o=qZ.some(function(a){return!!~i.indexOf(a)});o&&this.refresh()},t.getInstance=function(){return this.instance_||(this.instance_=new t),this.instance_},t.instance_=null,t}(),FD=function(t,r){for(var n=0,i=Object.keys(r);n"u"||!(Element instanceof Object))){if(!(r instanceof ml(r).Element))throw new TypeError('parameter 1 is not of type "Element".');var n=this.observations_;n.has(r)||(n.set(r,new aJ(r)),this.controller_.addObserver(this),this.controller_.refresh())}},t.prototype.unobserve=function(r){if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");if(!(typeof Element>"u"||!(Element instanceof Object))){if(!(r instanceof ml(r).Element))throw new TypeError('parameter 1 is not of type "Element".');var n=this.observations_;n.has(r)&&(n.delete(r),n.size||this.controller_.removeObserver(this))}},t.prototype.disconnect=function(){this.clearActive(),this.observations_.clear(),this.controller_.removeObserver(this)},t.prototype.gatherActive=function(){var r=this;this.clearActive(),this.observations_.forEach(function(n){n.isActive()&&r.activeObservations_.push(n)})},t.prototype.broadcastActive=function(){if(this.hasActive()){var r=this.callbackCtx_,n=this.activeObservations_.map(function(i){return new sJ(i.target,i.broadcastRect())});this.callback_.call(r,n,r),this.clearActive()}},t.prototype.clearActive=function(){this.activeObservations_.splice(0)},t.prototype.hasActive=function(){return this.activeObservations_.length>0},t}(),OD=typeof WeakMap<"u"?new WeakMap:new VD,BD=function(){function t(r){if(!(this instanceof t))throw new TypeError("Cannot call a class as a function.");if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");var n=JZ.getInstance(),i=new lJ(r,n,this);OD.set(this,i)}return t}();["observe","unobserve","disconnect"].forEach(function(t){BD.prototype[t]=function(){var r;return(r=OD.get(this))[t].apply(r,arguments)}});var cJ=function(){return typeof Eu.ResizeObserver<"u"?Eu.ResizeObserver:BD}(),Os=new Map;function hJ(t){t.forEach(function(r){var n,i=r.target;(n=Os.get(i))===null||n===void 0||n.forEach(function(o){return o(i)})})}var ND=new cJ(hJ);function uJ(t,r){Os.has(t)||(Os.set(t,new Set),ND.observe(t)),Os.get(t).add(r)}function pJ(t,r){Os.has(t)&&(Os.get(t).delete(r),Os.get(t).size||(ND.unobserve(t),Os.delete(t)))}var dJ=function(t){D8(n,t);var r=P8(n);function n(){return Ol(this,n),r.apply(this,arguments)}return Bl(n,[{key:"render",value:function(){return this.props.children}}]),n}(_.Component),Xg=_.createContext(null);function fJ(t){var r=t.children,n=t.onBatchResize,i=_.useRef(0),o=_.useRef([]),a=_.useContext(Xg),s=_.useCallback(function(l,h,p){i.current+=1;var f=i.current;o.current.push({size:l,element:h,data:p}),Promise.resolve().then(function(){f===i.current&&(n==null||n(o.current),o.current=[])}),a==null||a(l,h,p)},[n,a]);return _.createElement(Xg.Provider,{value:s},r)}function vJ(t,r){var n=t.children,i=t.disabled,o=_.useRef(null),a=_.useRef(null),s=_.useContext(Xg),l=typeof n=="function",h=l?n(o):n,p=_.useRef({width:-1,height:-1,offsetWidth:-1,offsetHeight:-1}),f=!l&&_.isValidElement(h)&&TD(h),g=f?h.ref:null,b=_.useMemo(function(){return jZ(g,o)},[g,o]),z=function(){return Lu(o.current)||Lu(a.current)};_.useImperativeHandle(r,function(){return z()});var M=_.useRef(t);M.current=t;var I=_.useCallback(function(F){var H=M.current,E=H.onResize,R=H.data,W=F.getBoundingClientRect(),$=W.width,G=W.height,Z=F.offsetWidth,K=F.offsetHeight,et=Math.floor($),at=Math.floor(G);if(p.current.width!==et||p.current.height!==at||p.current.offsetWidth!==Z||p.current.offsetHeight!==K){var tt={width:et,height:at,offsetWidth:Z,offsetHeight:K};p.current=tt;var ft=Z===Math.round($)?$:Z,dt=K===Math.round(G)?G:K,ht=Ke(Ke({},tt),{},{offsetWidth:ft,offsetHeight:dt});s==null||s(ht,F,R),E&&Promise.resolve().then(function(){E(ht,F)})}},[]);return _.useEffect(function(){var F=z();return F&&!i&&uJ(F,I),function(){return pJ(F,I)}},[o.current,i]),_.createElement(dJ,{ref:a},f?_.cloneElement(h,{ref:b}):h)}var gJ=_.forwardRef(vJ),mJ="rc-observer-key";function yJ(t,r){var n=t.children,i=typeof n=="function"?[n]:Au(n);return i.map(function(o,a){var s=(o==null?void 0:o.key)||"".concat(mJ,"-").concat(a);return _.createElement(gJ,qi({},t,{key:s,ref:a===0?r:void 0}),o)})}var Ux=_.forwardRef(yJ);Ux.Collection=fJ;var $D=_.forwardRef(function(t,r){var n=t.height,i=t.offsetY,o=t.offsetX,a=t.children,s=t.prefixCls,l=t.onInnerResize,h=t.innerProps,p=t.rtl,f=t.extra,g={},b={display:"flex",flexDirection:"column"};if(i!==void 0){var z;g={height:n,position:"relative",overflow:"hidden"},b=Ke(Ke({},b),{},(z={transform:"translateY(".concat(i,"px)")},oe(z,p?"marginRight":"marginLeft",-o),oe(z,"position","absolute"),oe(z,"left",0),oe(z,"right",0),oe(z,"top",0),z))}return _.createElement("div",{style:g},_.createElement(Ux,{onResize:function(I){var F=I.offsetHeight;F&&l&&l()}},_.createElement("div",qi({style:b,className:wi(oe({},"".concat(s,"-holder-inner"),s)),ref:r},h),a,f)))});$D.displayName="Filler";var WD=function(r){return+setTimeout(r,16)},jD=function(r){return clearTimeout(r)};typeof window<"u"&&"requestAnimationFrame"in window&&(WD=function(r){return window.requestAnimationFrame(r)},jD=function(r){return window.cancelAnimationFrame(r)});var sk=0,Yx=new Map;function GD(t){Yx.delete(t)}var n2=function(r){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1;sk+=1;var i=sk;function o(a){if(a===0)GD(i),r();else{var s=WD(function(){o(a-1)});Yx.set(i,s)}}return o(n),i};n2.cancel=function(t){var r=Yx.get(t);return GD(r),jD(r)};function lk(t,r){var n="touches"in t?t.touches[0]:t;return n[r?"pageX":"pageY"]}var ck=_.forwardRef(function(t,r){var n,i=t.prefixCls,o=t.rtl,a=t.scrollOffset,s=t.scrollRange,l=t.onStartMove,h=t.onStopMove,p=t.onScroll,f=t.horizontal,g=t.spinSize,b=t.containerSize,z=t.style,M=t.thumbStyle,I=_.useState(!1),F=$1(I,2),H=F[0],E=F[1],R=_.useState(null),W=$1(R,2),$=W[0],G=W[1],Z=_.useState(null),K=$1(Z,2),et=K[0],at=K[1],tt=!o,ft=_.useRef(),dt=_.useRef(),ht=_.useState(!1),lt=$1(ht,2),yt=lt[0],mt=lt[1],gt=_.useRef(),kt=function(){clearTimeout(gt.current),mt(!0),gt.current=setTimeout(function(){mt(!1)},3e3)},_t=s-b||0,bt=b-g||0,Mt=_t>0,At=_.useMemo(function(){if(a===0||_t===0)return 0;var Ot=a/_t;return Ot*bt},[a,_t,bt]),Ft=function(we){we.stopPropagation(),we.preventDefault()},Bt=_.useRef({top:At,dragging:H,pageY:$,startTop:et});Bt.current={top:At,dragging:H,pageY:$,startTop:et};var Ut=function(we){E(!0),G(lk(we,f)),at(Bt.current.top),l(),we.stopPropagation(),we.preventDefault()};_.useEffect(function(){var Ot=function(Se){Se.preventDefault()},we=ft.current,Ht=dt.current;return we.addEventListener("touchstart",Ot),Ht.addEventListener("touchstart",Ut),function(){we.removeEventListener("touchstart",Ot),Ht.removeEventListener("touchstart",Ut)}},[]);var Xt=_.useRef();Xt.current=_t;var It=_.useRef();It.current=bt,_.useEffect(function(){if(H){var Ot,we=function(Se){var Kt=Bt.current,fe=Kt.dragging,ne=Kt.pageY,ce=Kt.startTop;if(n2.cancel(Ot),fe){var xe=lk(Se,f)-ne,Wt=ce;!tt&&f?Wt-=xe:Wt+=xe;var qt=Xt.current,Ee=It.current,Ie=Ee?Wt/Ee:0,Pe=Math.ceil(Ie*qt);Pe=Math.max(Pe,0),Pe=Math.min(Pe,qt),Ot=n2(function(){p(Pe,f)})}},Ht=function(){E(!1),h()};return window.addEventListener("mousemove",we),window.addEventListener("touchmove",we),window.addEventListener("mouseup",Ht),window.addEventListener("touchend",Ht),function(){window.removeEventListener("mousemove",we),window.removeEventListener("touchmove",we),window.removeEventListener("mouseup",Ht),window.removeEventListener("touchend",Ht),n2.cancel(Ot)}}},[H]),_.useEffect(function(){kt()},[a]),_.useImperativeHandle(r,function(){return{delayHidden:kt}});var ae="".concat(i,"-scrollbar"),$t={position:"absolute",visibility:yt&&Mt?null:"hidden"},ue={position:"absolute",background:"rgba(0, 0, 0, 0.5)",borderRadius:99,cursor:"pointer",userSelect:"none"};return f?($t.height=8,$t.left=0,$t.right=0,$t.bottom=0,ue.height="100%",ue.width=g,tt?ue.left=At:ue.right=At):($t.width=8,$t.top=0,$t.bottom=0,tt?$t.right=0:$t.left=0,ue.width="100%",ue.height=g,ue.top=At),_.createElement("div",{ref:ft,className:wi(ae,(n={},oe(n,"".concat(ae,"-horizontal"),f),oe(n,"".concat(ae,"-vertical"),!f),oe(n,"".concat(ae,"-visible"),yt),n)),style:Ke(Ke({},$t),z),onMouseDown:Ft,onMouseMove:kt},_.createElement("div",{ref:dt,className:wi("".concat(ae,"-thumb"),oe({},"".concat(ae,"-thumb-moving"),H)),style:Ke(Ke({},ue),M),onMouseDown:Ut}))});function xJ(t){var r=t.children,n=t.setRef,i=_.useCallback(function(o){n(o)},[]);return _.cloneElement(r,{ref:i})}function bJ(t,r,n,i,o,a,s){var l=s.getKey;return t.slice(r,n+1).map(function(h,p){var f=r+p,g=a(h,f,{style:{width:i}}),b=l(h);return _.createElement(xJ,{key:b,setRef:function(M){return o(h,M)}},g)})}var wJ=function(){function t(){Ol(this,t),this.maps=void 0,this.id=0,this.maps=Object.create(null)}return Bl(t,[{key:"set",value:function(n,i){this.maps[n]=i,this.id+=1}},{key:"get",value:function(n){return this.maps[n]}}]),t}();function CJ(t,r,n){var i=_.useState(0),o=$1(i,2),a=o[0],s=o[1],l=_.useRef(new Map),h=_.useRef(new wJ),p=_.useRef();function f(){n2.cancel(p.current)}function g(){var z=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1;f();var M=function(){l.current.forEach(function(F,H){if(F&&F.offsetParent){var E=Lu(F),R=E.offsetHeight;h.current.get(H)!==R&&h.current.set(H,E.offsetHeight)}}),s(function(F){return F+1})};z?M():p.current=n2(M)}function b(z,M){var I=t(z),F=l.current.get(I);M?(l.current.set(I,M),g()):l.current.delete(I),!F!=!M&&(M?r==null||r(z):n==null||n(z))}return _.useEffect(function(){return f},[]),[b,g,h.current,a]}function hk(t){var r=_.useRef();r.current=t;var n=_.useCallback(function(){for(var i,o=arguments.length,a=new Array(o),s=0;s=0;ht-=1){var lt=o(r[ht]),yt=n.get(lt);if(yt===void 0){E=!0;break}if(dt-=yt,dt<=0)break}switch($){case"top":W=Z-F;break;case"bottom":W=K-H+F;break;default:{var mt=t.current.scrollTop,gt=mt+H;Zgt&&(R="bottom")}}W!==null&&s(W),W!==g.lastTop&&(E=!0)}E&&b(function(kt){return Ke(Ke({},kt),{},{times:kt.times+1,targetAlign:R,lastTop:W})})}},[g,t.current]),function(z){if(z==null){l();return}if(n2.cancel(h.current),typeof z=="number")s(z);else if(z&&tn(z)==="object"){var M,I=z.align;"index"in z?M=z.index:M=r.findIndex(function(E){return o(E)===z.key});var F=z.offset,H=F===void 0?0:F;b({times:0,index:M,offset:H,originAlign:I})}}}function MJ(t,r,n){var i=t.length,o=r.length,a,s;if(i===0&&o===0)return null;i"u"?"undefined":tn(navigator))==="object"&&/Firefox/i.test(navigator.userAgent);const UD=function(t,r){var n=_.useRef(!1),i=_.useRef(null);function o(){clearTimeout(i.current),n.current=!0,i.current=setTimeout(function(){n.current=!1},50)}var a=_.useRef({top:t,bottom:r});return a.current.top=t,a.current.bottom=r,function(s){var l=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,h=s<0&&a.current.top||s>0&&a.current.bottom;return l&&h?(clearTimeout(i.current),n.current=!1):(!h||n.current)&&o(),!n.current&&h}};function _J(t,r,n,i,o){var a=_.useRef(0),s=_.useRef(null),l=_.useRef(null),h=_.useRef(!1),p=UD(r,n);function f(F,H){n2.cancel(s.current),a.current+=H,l.current=H,!p(H)&&(uk||F.preventDefault(),s.current=n2(function(){var E=h.current?10:1;o(a.current*E),a.current=0}))}function g(F,H){o(H,!0),uk||F.preventDefault()}var b=_.useRef(null),z=_.useRef(null);function M(F){if(t){n2.cancel(z.current),z.current=n2(function(){b.current=null},2);var H=F.deltaX,E=F.deltaY,R=F.shiftKey,W=H,$=E;(b.current==="sx"||!b.current&&R&&E&&!H)&&(W=E,$=0,b.current="sx");var G=Math.abs(W),Z=Math.abs($);b.current===null&&(b.current=i&&G>Z?"x":"y"),b.current==="y"?f(F,$):g(F,W)}}function I(F){t&&(h.current=F.detail===l.current)}return[M,I]}var AJ=14/15;function LJ(t,r,n){var i=_.useRef(!1),o=_.useRef(0),a=_.useRef(null),s=_.useRef(null),l,h=function(b){if(i.current){var z=Math.ceil(b.touches[0].pageY),M=o.current-z;o.current=z,n(M)&&b.preventDefault(),clearInterval(s.current),s.current=setInterval(function(){M*=AJ,(!n(M,!0)||Math.abs(M)<=.1)&&clearInterval(s.current)},16)}},p=function(){i.current=!1,l()},f=function(b){l(),b.touches.length===1&&!i.current&&(i.current=!0,o.current=Math.ceil(b.touches[0].pageY),a.current=b.target,a.current.addEventListener("touchmove",h),a.current.addEventListener("touchend",p))};l=function(){a.current&&(a.current.removeEventListener("touchmove",h),a.current.removeEventListener("touchend",p))},Ba(function(){return t&&r.current.addEventListener("touchstart",f),function(){var g;(g=r.current)===null||g===void 0||g.removeEventListener("touchstart",f),l(),clearInterval(s.current)}},[t])}var EJ=20;function pk(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,n=t/r*100;return isNaN(n)&&(n=0),n=Math.max(n,EJ),n=Math.min(n,t/2),Math.floor(n)}function IJ(t,r,n,i){var o=_.useMemo(function(){return[new Map,[]]},[t,n.id,i]),a=$1(o,2),s=a[0],l=a[1],h=function(f){var g=arguments.length>1&&arguments[1]!==void 0?arguments[1]:f,b=s.get(f),z=s.get(g);if(b===void 0||z===void 0)for(var M=t.length,I=l.length;Ia||!!I),tt=M==="rtl",ft=wi(i,oe({},"".concat(i,"-rtl"),tt),o),dt=f||DJ,ht=_.useRef(),lt=_.useRef(),yt=_.useState(0),mt=$1(yt,2),gt=mt[0],kt=mt[1],_t=_.useState(0),bt=$1(_t,2),Mt=bt[0],At=bt[1],Ft=_.useState(!1),Bt=$1(Ft,2),Ut=Bt[0],Xt=Bt[1],It=function(){Xt(!0)},ae=function(){Xt(!1)},$t=_.useCallback(function(r1){return typeof b=="function"?b(r1):r1==null?void 0:r1[b]},[b]),ue={getKey:$t};function Ot(r1){kt(function(s1){var I1;typeof r1=="function"?I1=r1(s1):I1=r1;var Nr=te(I1);return ht.current.scrollTop=Nr,Nr})}var we=_.useRef({start:0,end:dt.length}),Ht=_.useRef(),se=kJ(dt,$t),Se=$1(se,1),Kt=Se[0];Ht.current=Kt;var fe=CJ($t,null,null),ne=$1(fe,4),ce=ne[0],xe=ne[1],Wt=ne[2],qt=ne[3],Ee=_.useMemo(function(){if(!et)return{scrollHeight:void 0,start:0,end:dt.length-1,offset:void 0};if(!at){var r1;return{scrollHeight:((r1=lt.current)===null||r1===void 0?void 0:r1.offsetHeight)||0,start:0,end:dt.length-1,offset:void 0}}for(var s1=0,I1,Nr,Cn,v6=dt.length,Q=0;Q=gt&&I1===void 0&&(I1=Q,Nr=s1),v>gt+a&&Cn===void 0&&(Cn=Q),s1=v}return I1===void 0&&(I1=0,Nr=0,Cn=Math.ceil(a/s)),Cn===void 0&&(Cn=dt.length-1),Cn=Math.min(Cn+1,dt.length-1),{scrollHeight:s1,start:I1,end:Cn,offset:Nr}},[at,et,gt,dt,qt,a]),Ie=Ee.scrollHeight,Pe=Ee.start,Yt=Ee.end,st=Ee.offset;we.current.start=Pe,we.current.end=Yt;var Et=_.useState({width:0,height:a}),zt=$1(Et,2),Rt=zt[0],Vt=zt[1],Qt=function(s1){Vt({width:s1.width||s1.offsetWidth,height:s1.height||s1.offsetHeight})},ve=_.useRef(),je=_.useRef(),ke=_.useMemo(function(){return pk(Rt.width,I)},[Rt.width,I]),c1=_.useMemo(function(){return pk(Rt.height,Ie)},[Rt.height,Ie]),Oe=Ie-a,Tt=_.useRef(Oe);Tt.current=Oe;function te(r1){var s1=r1;return Number.isNaN(Tt.current)||(s1=Math.min(s1,Tt.current)),s1=Math.max(s1,0),s1}var Ve=gt<=0,He=gt>=Oe,d1=UD(Ve,He),Le=function(){return{x:tt?-Mt:Mt,y:gt}},ge=_.useRef(Le()),h1=hk(function(){if(R){var r1=Le();(ge.current.x!==r1.x||ge.current.y!==r1.y)&&(R(r1),ge.current=r1)}});function M1(r1,s1){var I1=r1;s1?(Xa.flushSync(function(){At(I1)}),h1()):Ot(I1)}function Z1(r1){var s1=r1.currentTarget.scrollTop;s1!==gt&&Ot(s1),E==null||E(r1),h1()}var zr=function(s1){var I1=s1,Nr=I-Rt.width;return I1=Math.max(I1,0),I1=Math.min(I1,Nr),I1},Xr=hk(function(r1,s1){s1?(Xa.flushSync(function(){At(function(I1){var Nr=I1+(tt?-r1:r1);return zr(Nr)})}),h1()):Ot(function(I1){var Nr=I1+r1;return Nr})}),jn=_J(et,Ve,He,!!I,Xr),Gn=$1(jn,2),_i=Gn[0],ps=Gn[1];LJ(et,ht,function(r1,s1){return d1(r1,s1)?!1:(_i({preventDefault:function(){},deltaY:r1}),!0)}),Ba(function(){function r1(I1){et&&I1.preventDefault()}var s1=ht.current;return s1.addEventListener("wheel",_i),s1.addEventListener("DOMMouseScroll",ps),s1.addEventListener("MozMousePixelScroll",r1),function(){s1.removeEventListener("wheel",_i),s1.removeEventListener("DOMMouseScroll",ps),s1.removeEventListener("MozMousePixelScroll",r1)}},[et]),Ba(function(){I&&At(function(r1){return zr(r1)})},[Rt.width,I]);var ds=function(){var s1,I1;(s1=ve.current)===null||s1===void 0||s1.delayHidden(),(I1=je.current)===null||I1===void 0||I1.delayHidden()},m2=zJ(ht,dt,Wt,s,$t,function(){return xe(!0)},Ot,ds);_.useImperativeHandle(r,function(){return{getScrollInfo:Le,scrollTo:function(s1){function I1(Nr){return Nr&&tn(Nr)==="object"&&("left"in Nr||"top"in Nr)}I1(s1)?(s1.left!==void 0&&At(zr(s1.left)),m2(s1.top)):m2(s1)}}}),Ba(function(){if(W){var r1=dt.slice(Pe,Yt+1);W(r1,dt)}},[Pe,Yt,dt]);var fs=IJ(dt,$t,Wt,s),f6=G==null?void 0:G({start:Pe,end:Yt,virtual:at,offsetX:Mt,offsetY:st,rtl:tt,getSize:fs}),K0=bJ(dt,Pe,Yt,I,ce,g,ue),ca=null;a&&(ca=Ke(oe({},h?"height":"maxHeight",a),PJ),et&&(ca.overflowY="hidden",I&&(ca.overflowX="hidden"),Ut&&(ca.pointerEvents="none")));var q0={};return tt&&(q0.dir="rtl"),_.createElement("div",qi({style:Ke(Ke({},p),{},{position:"relative"}),className:ft},q0,K),_.createElement(Ux,{onResize:Qt},_.createElement(H,{className:"".concat(i,"-holder"),style:ca,ref:ht,onScroll:Z1,onMouseEnter:ds},_.createElement($D,{prefixCls:i,height:Ie,offsetX:Mt,offsetY:st,scrollWidth:I,onInnerResize:xe,ref:lt,innerProps:$,rtl:tt,extra:f6},K0))),at&&Ie>a&&_.createElement(ck,{ref:ve,prefixCls:i,scrollOffset:gt,scrollRange:Ie,rtl:tt,onScroll:M1,onStartMove:It,onStopMove:ae,spinSize:c1,containerSize:Rt.height,style:Z==null?void 0:Z.verticalScrollBar,thumbStyle:Z==null?void 0:Z.verticalScrollBarThumb}),at&&I&&_.createElement(ck,{ref:je,prefixCls:i,scrollOffset:Mt,scrollRange:I,rtl:tt,onScroll:M1,onStartMove:It,onStopMove:ae,spinSize:ke,containerSize:Rt.width,horizontal:!0,style:Z==null?void 0:Z.horizontalScrollBar,thumbStyle:Z==null?void 0:Z.horizontalScrollBarThumb}))}var YD=_.forwardRef(TJ);YD.displayName="List";var VJ=_.createContext({}),FJ=function(t){D8(n,t);var r=P8(n);function n(){return Ol(this,n),r.apply(this,arguments)}return Bl(n,[{key:"render",value:function(){return this.props.children}}]),n}(_.Component),U4="none",kh="appear",_h="enter",Ah="leave",dk="none",ao="prepare",N3="start",$3="active",Xx="end",XD="prepared";function fk(t,r){var n={};return n[t.toLowerCase()]=r.toLowerCase(),n["Webkit".concat(t)]="webkit".concat(r),n["Moz".concat(t)]="moz".concat(r),n["ms".concat(t)]="MS".concat(r),n["O".concat(t)]="o".concat(r.toLowerCase()),n}function RJ(t,r){var n={animationend:fk("Animation","AnimationEnd"),transitionend:fk("Transition","TransitionEnd")};return t&&("AnimationEvent"in r||delete n.animationend.animation,"TransitionEvent"in r||delete n.transitionend.transition),n}var OJ=RJ(G9(),typeof window<"u"?window:{}),KD={};if(G9()){var BJ=document.createElement("div");KD=BJ.style}var Lh={};function qD(t){if(Lh[t])return Lh[t];var r=OJ[t];if(r)for(var n=Object.keys(r),i=n.length,o=0;o1&&arguments[1]!==void 0?arguments[1]:2;r();var a=n2(function(){o<=1?i({isCanceled:function(){return a!==t.current}}):n(i,o-1)});t.current=a}return _.useEffect(function(){return function(){r()}},[]),[n,r]};var WJ=[ao,N3,$3,Xx],jJ=[ao,XD],eP=!1,GJ=!0;function rP(t){return t===$3||t===Xx}const UJ=function(t,r,n){var i=x7(dk),o=$1(i,2),a=o[0],s=o[1],l=$J(),h=$1(l,2),p=h[0],f=h[1];function g(){s(ao,!0)}var b=r?jJ:WJ;return tP(function(){if(a!==dk&&a!==Xx){var z=b.indexOf(a),M=b[z+1],I=n(a);I===eP?s(M,!0):M&&p(function(F){function H(){F.isCanceled()||s(M,!0)}I===!0?H():Promise.resolve(I).then(H)})}},[t,a]),_.useEffect(function(){return function(){f()}},[]),[g,a]};function YJ(t,r,n,i){var o=i.motionEnter,a=o===void 0?!0:o,s=i.motionAppear,l=s===void 0?!0:s,h=i.motionLeave,p=h===void 0?!0:h,f=i.motionDeadline,g=i.motionLeaveImmediately,b=i.onAppearPrepare,z=i.onEnterPrepare,M=i.onLeavePrepare,I=i.onAppearStart,F=i.onEnterStart,H=i.onLeaveStart,E=i.onAppearActive,R=i.onEnterActive,W=i.onLeaveActive,$=i.onAppearEnd,G=i.onEnterEnd,Z=i.onLeaveEnd,K=i.onVisibleChanged,et=x7(),at=$1(et,2),tt=at[0],ft=at[1],dt=x7(U4),ht=$1(dt,2),lt=ht[0],yt=ht[1],mt=x7(null),gt=$1(mt,2),kt=gt[0],_t=gt[1],bt=_.useRef(!1),Mt=_.useRef(null);function At(){return n()}var Ft=_.useRef(!1);function Bt(){yt(U4,!0),_t(null,!0)}function Ut(ne){var ce=At();if(!(ne&&!ne.deadline&&ne.target!==ce)){var xe=Ft.current,Wt;lt===kh&&xe?Wt=$==null?void 0:$(ce,ne):lt===_h&&xe?Wt=G==null?void 0:G(ce,ne):lt===Ah&&xe&&(Wt=Z==null?void 0:Z(ce,ne)),lt!==U4&&xe&&Wt!==!1&&Bt()}}var Xt=NJ(Ut),It=$1(Xt,1),ae=It[0],$t=function(ce){var xe,Wt,qt;switch(ce){case kh:return xe={},oe(xe,ao,b),oe(xe,N3,I),oe(xe,$3,E),xe;case _h:return Wt={},oe(Wt,ao,z),oe(Wt,N3,F),oe(Wt,$3,R),Wt;case Ah:return qt={},oe(qt,ao,M),oe(qt,N3,H),oe(qt,$3,W),qt;default:return{}}},ue=_.useMemo(function(){return $t(lt)},[lt]),Ot=UJ(lt,!t,function(ne){if(ne===ao){var ce=ue[ao];return ce?ce(At()):eP}if(se in ue){var xe;_t(((xe=ue[se])===null||xe===void 0?void 0:xe.call(ue,At(),null))||null)}return se===$3&&(ae(At()),f>0&&(clearTimeout(Mt.current),Mt.current=setTimeout(function(){Ut({deadline:!0})},f))),se===XD&&Bt(),GJ}),we=$1(Ot,2),Ht=we[0],se=we[1],Se=rP(se);Ft.current=Se,tP(function(){ft(r);var ne=bt.current;bt.current=!0;var ce;!ne&&r&&l&&(ce=kh),ne&&r&&a&&(ce=_h),(ne&&!r&&p||!ne&&g&&!r&&p)&&(ce=Ah);var xe=$t(ce);ce&&(t||xe[ao])?(yt(ce),Ht()):yt(U4)},[r]),_.useEffect(function(){(lt===kh&&!l||lt===_h&&!a||lt===Ah&&!p)&&yt(U4)},[l,a,p]),_.useEffect(function(){return function(){bt.current=!1,clearTimeout(Mt.current)}},[]);var Kt=_.useRef(!1);_.useEffect(function(){tt&&(Kt.current=!0),tt!==void 0&<===U4&&((Kt.current||tt)&&(K==null||K(tt)),Kt.current=!0)},[tt,lt]);var fe=kt;return ue[ao]&&se===N3&&(fe=Ke({transition:"none"},fe)),[lt,se,fe,tt??r]}function XJ(t){var r=t;tn(t)==="object"&&(r=t.transitionSupport);function n(o,a){return!!(o.motionName&&r&&a!==!1)}var i=_.forwardRef(function(o,a){var s=o.visible,l=s===void 0?!0:s,h=o.removeOnLeave,p=h===void 0?!0:h,f=o.forceRender,g=o.children,b=o.motionName,z=o.leavedClassName,M=o.eventProps,I=_.useContext(VJ),F=I.motion,H=n(o,F),E=_.useRef(),R=_.useRef();function W(){try{return E.current instanceof HTMLElement?E.current:Lu(R.current)}catch{return null}}var $=YJ(H,l,W,o),G=$1($,4),Z=G[0],K=G[1],et=G[2],at=G[3],tt=_.useRef(at);at&&(tt.current=!0);var ft=_.useCallback(function(_t){E.current=_t,PD(a,_t)},[a]),dt,ht=Ke(Ke({},M),{},{visible:l});if(!g)dt=null;else if(Z===U4)at?dt=g(Ke({},ht),ft):!p&&tt.current&&z?dt=g(Ke(Ke({},ht),{},{className:z}),ft):f||!p&&!z?dt=g(Ke(Ke({},ht),{},{style:{display:"none"}}),ft):dt=null;else{var lt,yt;K===ao?yt="prepare":rP(K)?yt="active":K===N3&&(yt="start");var mt=mk(b,"".concat(Z,"-").concat(yt));dt=g(Ke(Ke({},ht),{},{className:wi(mk(b,Z),(lt={},oe(lt,mt,mt&&yt),oe(lt,b,typeof b=="string"),lt)),style:et}),ft)}if(_.isValidElement(dt)&&TD(dt)){var gt=dt,kt=gt.ref;kt||(dt=_.cloneElement(dt,{ref:ft}))}return _.createElement(FJ,{ref:R},dt)});return i.displayName="CSSMotion",i}const iP=XJ(QD);var Kg="add",qg="keep",Zg="remove",Gf="removed";function KJ(t){var r;return t&&tn(t)==="object"&&"key"in t?r=t:r={key:t},Ke(Ke({},r),{},{key:String(r.key)})}function Jg(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];return t.map(KJ)}function qJ(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],n=[],i=0,o=r.length,a=Jg(t),s=Jg(r);a.forEach(function(p){for(var f=!1,g=i;g1});return h.forEach(function(p){n=n.filter(function(f){var g=f.key,b=f.status;return g!==p||b!==Zg}),n.forEach(function(f){f.key===p&&(f.status=qg)})}),n}var ZJ=["component","children","onVisibleChanged","onAllRemoved"],JJ=["status"],QJ=["eventProps","visible","children","motionName","motionAppear","motionEnter","motionLeave","motionLeaveImmediately","motionDeadline","removeOnLeave","leavedClassName","onAppearPrepare","onAppearStart","onAppearActive","onAppearEnd","onEnterStart","onEnterActive","onEnterEnd","onLeaveStart","onLeaveActive","onLeaveEnd"];function tQ(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:iP,n=function(i){D8(a,i);var o=P8(a);function a(){var s;Ol(this,a);for(var l=arguments.length,h=new Array(l),p=0;p1&&arguments[1]!==void 0?arguments[1]:null;return f.map(function(b,z){for(var M=nP(g?g.pos:"0",z),I=T8(b[a],M),F,H=0;H1&&arguments[1]!==void 0?arguments[1]:{},n=r.initWrapper,i=r.processEntity,o=r.onProcessFinished,a=r.externalGetKey,s=r.childrenPropName,l=r.fieldNames,h=arguments.length>2?arguments[2]:void 0,p=a||h,f={},g={},b={posEntities:f,keyEntities:g};return n&&(b=n(b)||b),sQ(t,function(z){var M=z.node,I=z.index,F=z.pos,H=z.key,E=z.parentPos,R=z.level,W=z.nodes,$={node:M,nodes:W,index:I,key:H,pos:F,level:R},G=T8(H,F);f[F]=$,g[G]=$,$.parent=f[E],$.parent&&($.parent.children=$.parent.children||[],$.parent.children.push($)),i&&i($,b)},{externalGetKey:p,childrenPropName:s,fieldNames:l}),o&&o(b),b}function Ec(t,r){var n=r.expandedKeys,i=r.selectedKeys,o=r.loadedKeys,a=r.loadingKeys,s=r.checkedKeys,l=r.halfCheckedKeys,h=r.dragOverNodeKey,p=r.dropPosition,f=r.keyEntities,g=Ln(f,t),b={eventKey:t,expanded:n.indexOf(t)!==-1,selected:i.indexOf(t)!==-1,loaded:o.indexOf(t)!==-1,loading:a.indexOf(t)!==-1,checked:s.indexOf(t)!==-1,halfChecked:l.indexOf(t)!==-1,pos:String(g?g.pos:""),dragOver:h===t&&p===0,dragOverGapTop:h===t&&p===-1,dragOverGapBottom:h===t&&p===1};return b}function ii(t){var r=t.data,n=t.expanded,i=t.selected,o=t.checked,a=t.loaded,s=t.loading,l=t.halfChecked,h=t.dragOver,p=t.dragOverGapTop,f=t.dragOverGapBottom,g=t.pos,b=t.active,z=t.eventKey,M=Ke(Ke({},r),{},{expanded:n,selected:i,checked:o,loaded:a,loading:s,halfChecked:l,dragOver:h,dragOverGapTop:p,dragOverGapBottom:f,pos:g,active:b,key:z});return"props"in M||Object.defineProperty(M,"props",{get:function(){return co(!1,"Second param return from event is node data instead of TreeNode instance. Please read value directly instead of reading from `props`."),t}}),M}var cQ=["eventKey","className","style","dragOver","dragOverGapTop","dragOverGapBottom","isLeaf","isStart","isEnd","expanded","selected","checked","halfChecked","loading","domRef","active","data","onMouseMove","selectable"],yk="open",xk="close",hQ="---",uQ=function(t){D8(n,t);var r=P8(n);function n(){var i;Ol(this,n);for(var o=arguments.length,a=new Array(o),s=0;s0&&arguments[0]!==void 0?arguments[0]:[],r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],n=t.length,i=r.length;if(Math.abs(n-i)!==1)return{add:!1,key:null};function o(a,s){var l=new Map;a.forEach(function(p){l.set(p,!0)});var h=s.filter(function(p){return!l.has(p)});return h.length===1?h[0]:null}return n ").concat(r);return r}var sP=_.forwardRef(function(t,r){var n=t.prefixCls,i=t.data;t.selectable,t.checkable;var o=t.expandedKeys,a=t.selectedKeys,s=t.checkedKeys,l=t.loadedKeys,h=t.loadingKeys,p=t.halfCheckedKeys,f=t.keyEntities,g=t.disabled,b=t.dragging,z=t.dragOverNodeKey,M=t.dropPosition,I=t.motion,F=t.height,H=t.itemHeight,E=t.virtual,R=t.focusable,W=t.activeItem,$=t.focused,G=t.tabIndex,Z=t.onKeyDown,K=t.onFocus,et=t.onBlur,at=t.onActiveChange,tt=t.onListChangeStart,ft=t.onListChangeEnd,dt=C0(t,gQ),ht=_.useRef(null),lt=_.useRef(null);_.useImperativeHandle(r,function(){return{scrollTo:function(xe){ht.current.scrollTo(xe)},getIndentWidth:function(){return lt.current.offsetWidth}}});var yt=_.useState(o),mt=$1(yt,2),gt=mt[0],kt=mt[1],_t=_.useState(i),bt=$1(_t,2),Mt=bt[0],At=bt[1],Ft=_.useState(i),Bt=$1(Ft,2),Ut=Bt[0],Xt=Bt[1],It=_.useState([]),ae=$1(It,2),$t=ae[0],ue=ae[1],Ot=_.useState(null),we=$1(Ot,2),Ht=we[0],se=we[1],Se=_.useRef(i);Se.current=i;function Kt(){var ce=Se.current;At(ce),Xt(ce),ue([]),se(null),ft()}Ba(function(){kt(o);var ce=vQ(gt,o);if(ce.key!==null)if(ce.add){var xe=Mt.findIndex(function(Yt){var st=Yt.key;return st===ce.key}),Wt=Sk(bk(Mt,i,ce.key),E,F,H),qt=Mt.slice();qt.splice(xe+1,0,Ck),Xt(qt),ue(Wt),se("show")}else{var Ee=i.findIndex(function(Yt){var st=Yt.key;return st===ce.key}),Ie=Sk(bk(i,Mt,ce.key),E,F,H),Pe=i.slice();Pe.splice(Ee+1,0,Ck),Xt(Pe),ue(Ie),se("hide")}else Mt!==i&&(At(i),Xt(i))},[o,i]),_.useEffect(function(){b||Kt()},[b]);var fe=I?Ut:i,ne={expandedKeys:o,selectedKeys:a,loadedKeys:l,loadingKeys:h,checkedKeys:s,halfCheckedKeys:p,dragOverNodeKey:z,dropPosition:M,keyEntities:f};return _.createElement(_.Fragment,null,$&&W&&_.createElement("span",{style:wk,"aria-live":"assertive"},yQ(W)),_.createElement("div",null,_.createElement("input",{style:wk,disabled:R===!1||g,tabIndex:R!==!1?G:null,onKeyDown:Z,onFocus:K,onBlur:et,value:"",onChange:mQ,"aria-label":"for screen reader"})),_.createElement("div",{className:"".concat(n,"-treenode"),"aria-hidden":!0,style:{position:"absolute",pointerEvents:"none",visibility:"hidden",height:0,overflow:"hidden",border:0,padding:0}},_.createElement("div",{className:"".concat(n,"-indent")},_.createElement("div",{ref:lt,className:"".concat(n,"-indent-unit")}))),_.createElement(YD,qi({},dt,{data:fe,itemKey:zk,height:F,fullHeight:!1,virtual:E,itemHeight:H,prefixCls:"".concat(n,"-list"),ref:ht,onVisibleChange:function(xe,Wt){var qt=new Set(xe),Ee=Wt.filter(function(Ie){return!qt.has(Ie)});Ee.some(function(Ie){return zk(Ie)===S0})&&Kt()}}),function(ce){var xe=ce.pos,Wt=Object.assign({},(ED(ce.data),ce.data)),qt=ce.title,Ee=ce.key,Ie=ce.isStart,Pe=ce.isEnd,Yt=T8(Ee,xe);delete Wt.key,delete Wt.children;var st=Ec(Yt,ne);return _.createElement(fQ,qi({},Wt,st,{title:qt,active:!!W&&Ee===W.key,pos:xe,data:ce.data,isStart:Ie,isEnd:Pe,motion:I,motionNodes:Ee===S0?$t:null,motionType:Ht,onMotionStart:tt,onMotionEnd:Kt,treeNodeRequiredProps:ne,onMouseMove:function(){at(null)}}))}))});sP.displayName="NodeList";function xa(t,r){if(!t)return[];var n=t.slice(),i=n.indexOf(r);return i>=0&&n.splice(i,1),n}function Ms(t,r){var n=(t||[]).slice();return n.indexOf(r)===-1&&n.push(r),n}function Kx(t){return t.split("-")}function xQ(t,r){var n=[],i=Ln(r,t);function o(){var a=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];a.forEach(function(s){var l=s.key,h=s.children;n.push(l),o(h)})}return o(i.children),n}function bQ(t){if(t.parent){var r=Kx(t.pos);return Number(r[r.length-1])===t.parent.children.length-1}return!1}function wQ(t){var r=Kx(t.pos);return Number(r[r.length-1])===0}function Mk(t,r,n,i,o,a,s,l,h,p){var f,g=t.clientX,b=t.clientY,z=t.target.getBoundingClientRect(),M=z.top,I=z.height,F=(p==="rtl"?-1:1)*(((o==null?void 0:o.x)||0)-g),H=(F-12)/i,E=h.filter(function(yt){var mt;return(mt=l[yt])===null||mt===void 0||(mt=mt.children)===null||mt===void 0?void 0:mt.length}),R=Ln(l,n.props.eventKey);if(b-1.5?a({dragNode:dt,dropNode:ht,dropPosition:1})?at=1:lt=!1:a({dragNode:dt,dropNode:ht,dropPosition:0})?at=0:a({dragNode:dt,dropNode:ht,dropPosition:1})?at=1:lt=!1:a({dragNode:dt,dropNode:ht,dropPosition:1})?at=1:lt=!1,{dropPosition:at,dropLevelOffset:tt,dropTargetKey:R.key,dropTargetPos:R.pos,dragOverNodeKey:et,dropContainerKey:at===0?null:((f=R.parent)===null||f===void 0?void 0:f.key)||null,dropAllowed:lt}}function kk(t,r){if(t){var n=r.multiple;return n?t.slice():t.length?[t[0]]:t}}function Yf(t){if(!t)return null;var r;if(Array.isArray(t))r={checkedKeys:t,halfCheckedKeys:void 0};else if(tn(t)==="object")r={checkedKeys:t.checked||void 0,halfCheckedKeys:t.halfChecked||void 0};else return co(!1,"`checkedKeys` is not an array or an object"),null;return r}function _k(t,r){var n=new Set;function i(o){if(!n.has(o)){var a=Ln(r,o);if(a){n.add(o);var s=a.parent,l=a.node;l.disabled||s&&i(s.key)}}}return(t||[]).forEach(function(o){i(o)}),l0(n)}function lP(t,r){var n=new Set;return t.forEach(function(i){r.has(i)||n.add(i)}),n}function CQ(t){var r=t||{},n=r.disabled,i=r.disableCheckbox,o=r.checkable;return!!(n||i)||o===!1}function SQ(t,r,n,i){for(var o=new Set(t),a=new Set,s=0;s<=n;s+=1){var l=r.get(s)||new Set;l.forEach(function(g){var b=g.key,z=g.node,M=g.children,I=M===void 0?[]:M;o.has(b)&&!i(z)&&I.filter(function(F){return!i(F.node)}).forEach(function(F){o.add(F.key)})})}for(var h=new Set,p=n;p>=0;p-=1){var f=r.get(p)||new Set;f.forEach(function(g){var b=g.parent,z=g.node;if(!(i(z)||!g.parent||h.has(g.parent.key))){if(i(g.parent.node)){h.add(b.key);return}var M=!0,I=!1;(b.children||[]).filter(function(F){return!i(F.node)}).forEach(function(F){var H=F.key,E=o.has(H);M&&!E&&(M=!1),!I&&(E||a.has(H))&&(I=!0)}),M&&o.add(b.key),I&&a.add(b.key),h.add(b.key)}})}return{checkedKeys:Array.from(o),halfCheckedKeys:Array.from(lP(a,o))}}function zQ(t,r,n,i,o){for(var a=new Set(t),s=new Set(r),l=0;l<=i;l+=1){var h=n.get(l)||new Set;h.forEach(function(b){var z=b.key,M=b.node,I=b.children,F=I===void 0?[]:I;!a.has(z)&&!s.has(z)&&!o(M)&&F.filter(function(H){return!o(H.node)}).forEach(function(H){a.delete(H.key)})})}s=new Set;for(var p=new Set,f=i;f>=0;f-=1){var g=n.get(f)||new Set;g.forEach(function(b){var z=b.parent,M=b.node;if(!(o(M)||!b.parent||p.has(b.parent.key))){if(o(b.parent.node)){p.add(z.key);return}var I=!0,F=!1;(z.children||[]).filter(function(H){return!o(H.node)}).forEach(function(H){var E=H.key,R=a.has(E);I&&!R&&(I=!1),!F&&(R||s.has(E))&&(F=!0)}),I||a.delete(z.key),F&&s.add(z.key),p.add(z.key)}})}return{checkedKeys:Array.from(a),halfCheckedKeys:Array.from(lP(s,a))}}function Xf(t,r,n,i){var o=[],a;i?a=i:a=CQ;var s=new Set(t.filter(function(f){var g=!!Ln(n,f);return g||o.push(f),g})),l=new Map,h=0;Object.keys(n).forEach(function(f){var g=n[f],b=g.level,z=l.get(b);z||(z=new Set,l.set(b,z)),z.add(g),h=Math.max(h,b)}),co(!o.length,"Tree missing follow keys: ".concat(o.slice(0,100).map(function(f){return"'".concat(f,"'")}).join(", ")));var p;return r===!0?p=SQ(s,l,h,a):p=zQ(s,r.halfCheckedKeys,l,h,a),p}var MQ=10,qx=function(t){D8(n,t);var r=P8(n);function n(){var i;Ol(this,n);for(var o=arguments.length,a=new Array(o),s=0;s2&&arguments[2]!==void 0?arguments[2]:!1,g=i.state,b=g.dragChildrenKeys,z=g.dropPosition,M=g.dropTargetKey,I=g.dropTargetPos,F=g.dropAllowed;if(F){var H=i.props.onDrop;if(i.setState({dragOverNodeKey:null}),i.cleanDragState(),M!==null){var E=Ke(Ke({},Ec(M,i.getTreeNodeRequiredProps())),{},{active:((p=i.getActiveItem())===null||p===void 0?void 0:p.key)===M,data:Ln(i.state.keyEntities,M).node}),R=b.indexOf(M)!==-1;co(!R,"Can not drop to dragNode's children node. This is a bug of rc-tree. Please report an issue.");var W=Kx(I),$={event:l,node:ii(E),dragNode:i.dragNode?ii(i.dragNode.props):null,dragNodesKeys:[i.dragNode.props.eventKey].concat(b),dropToGap:z!==0,dropPosition:z+Number(W[W.length-1])};f||H==null||H($),i.dragNode=null}}}),oe(_e(i),"cleanDragState",function(){var l=i.state.draggingNodeKey;l!==null&&i.setState({draggingNodeKey:null,dropPosition:null,dropContainerKey:null,dropTargetKey:null,dropLevelOffset:null,dropAllowed:!0,dragOverNodeKey:null}),i.dragStartMousePosition=null,i.currentMouseOverDroppableNodeKey=null}),oe(_e(i),"triggerExpandActionExpand",function(l,h){var p=i.state,f=p.expandedKeys,g=p.flattenNodes,b=h.expanded,z=h.key,M=h.isLeaf;if(!(M||l.shiftKey||l.metaKey||l.ctrlKey)){var I=g.filter(function(H){return H.key===z})[0],F=ii(Ke(Ke({},Ec(z,i.getTreeNodeRequiredProps())),{},{data:I.data}));i.setExpandedKeys(b?xa(f,z):Ms(f,z)),i.onNodeExpand(l,F)}}),oe(_e(i),"onNodeClick",function(l,h){var p=i.props,f=p.onClick,g=p.expandAction;g==="click"&&i.triggerExpandActionExpand(l,h),f==null||f(l,h)}),oe(_e(i),"onNodeDoubleClick",function(l,h){var p=i.props,f=p.onDoubleClick,g=p.expandAction;g==="doubleClick"&&i.triggerExpandActionExpand(l,h),f==null||f(l,h)}),oe(_e(i),"onNodeSelect",function(l,h){var p=i.state.selectedKeys,f=i.state,g=f.keyEntities,b=f.fieldNames,z=i.props,M=z.onSelect,I=z.multiple,F=h.selected,H=h[b.key],E=!F;E?I?p=Ms(p,H):p=[H]:p=xa(p,H);var R=p.map(function(W){var $=Ln(g,W);return $?$.node:null}).filter(function(W){return W});i.setUncontrolledState({selectedKeys:p}),M==null||M(p,{event:"select",selected:E,node:h,selectedNodes:R,nativeEvent:l.nativeEvent})}),oe(_e(i),"onNodeCheck",function(l,h,p){var f=i.state,g=f.keyEntities,b=f.checkedKeys,z=f.halfCheckedKeys,M=i.props,I=M.checkStrictly,F=M.onCheck,H=h.key,E,R={event:"check",node:h,checked:p,nativeEvent:l.nativeEvent};if(I){var W=p?Ms(b,H):xa(b,H),$=xa(z,H);E={checked:W,halfChecked:$},R.checkedNodes=W.map(function(tt){return Ln(g,tt)}).filter(function(tt){return tt}).map(function(tt){return tt.node}),i.setUncontrolledState({checkedKeys:W})}else{var G=Xf([].concat(l0(b),[H]),!0,g),Z=G.checkedKeys,K=G.halfCheckedKeys;if(!p){var et=new Set(Z);et.delete(H);var at=Xf(Array.from(et),{checked:!1,halfCheckedKeys:K},g);Z=at.checkedKeys,K=at.halfCheckedKeys}E=Z,R.checkedNodes=[],R.checkedNodesPositions=[],R.halfCheckedKeys=K,Z.forEach(function(tt){var ft=Ln(g,tt);if(ft){var dt=ft.node,ht=ft.pos;R.checkedNodes.push(dt),R.checkedNodesPositions.push({node:dt,pos:ht})}}),i.setUncontrolledState({checkedKeys:Z},!1,{halfCheckedKeys:K})}F==null||F(E,R)}),oe(_e(i),"onNodeLoad",function(l){var h,p=l.key,f=i.state.keyEntities,g=Ln(f,p);if(!(g!=null&&(h=g.children)!==null&&h!==void 0&&h.length)){var b=new Promise(function(z,M){i.setState(function(I){var F=I.loadedKeys,H=F===void 0?[]:F,E=I.loadingKeys,R=E===void 0?[]:E,W=i.props,$=W.loadData,G=W.onLoad;if(!$||H.indexOf(p)!==-1||R.indexOf(p)!==-1)return null;var Z=$(l);return Z.then(function(){var K=i.state.loadedKeys,et=Ms(K,p);G==null||G(et,{event:"load",node:l}),i.setUncontrolledState({loadedKeys:et}),i.setState(function(at){return{loadingKeys:xa(at.loadingKeys,p)}}),z()}).catch(function(K){if(i.setState(function(at){return{loadingKeys:xa(at.loadingKeys,p)}}),i.loadingRetryTimes[p]=(i.loadingRetryTimes[p]||0)+1,i.loadingRetryTimes[p]>=MQ){var et=i.state.loadedKeys;co(!1,"Retry for `loadData` many times but still failed. No more retry."),i.setUncontrolledState({loadedKeys:Ms(et,p)}),z()}M(K)}),{loadingKeys:Ms(R,p)}})});return b.catch(function(){}),b}}),oe(_e(i),"onNodeMouseEnter",function(l,h){var p=i.props.onMouseEnter;p==null||p({event:l,node:h})}),oe(_e(i),"onNodeMouseLeave",function(l,h){var p=i.props.onMouseLeave;p==null||p({event:l,node:h})}),oe(_e(i),"onNodeContextMenu",function(l,h){var p=i.props.onRightClick;p&&(l.preventDefault(),p({event:l,node:h}))}),oe(_e(i),"onFocus",function(){var l=i.props.onFocus;i.setState({focused:!0});for(var h=arguments.length,p=new Array(h),f=0;f1&&arguments[1]!==void 0?arguments[1]:!1,p=arguments.length>2&&arguments[2]!==void 0?arguments[2]:null;if(!i.destroyed){var f=!1,g=!0,b={};Object.keys(l).forEach(function(z){if(z in i.props){g=!1;return}f=!0,b[z]=l[z]}),f&&(!h||g)&&i.setState(Ke(Ke({},b),p))}}),oe(_e(i),"scrollTo",function(l){i.listRef.current.scrollTo(l)}),i}return Bl(n,[{key:"componentDidMount",value:function(){this.destroyed=!1,this.onUpdated()}},{key:"componentDidUpdate",value:function(){this.onUpdated()}},{key:"onUpdated",value:function(){var o=this.props,a=o.activeKey,s=o.itemScrollOffset,l=s===void 0?0:s;a!==void 0&&a!==this.state.activeKey&&(this.setState({activeKey:a}),a!==null&&this.scrollTo({key:a,offset:l}))}},{key:"componentWillUnmount",value:function(){window.removeEventListener("dragend",this.onWindowDragEnd),this.destroyed=!0}},{key:"resetDragState",value:function(){this.setState({dragOverNodeKey:null,dropPosition:null,dropLevelOffset:null,dropTargetKey:null,dropContainerKey:null,dropTargetPos:null,dropAllowed:!1})}},{key:"render",value:function(){var o=this.state,a=o.focused,s=o.flattenNodes,l=o.keyEntities,h=o.draggingNodeKey,p=o.activeKey,f=o.dropLevelOffset,g=o.dropContainerKey,b=o.dropTargetKey,z=o.dropPosition,M=o.dragOverNodeKey,I=o.indent,F=this.props,H=F.prefixCls,E=F.className,R=F.style,W=F.showLine,$=F.focusable,G=F.tabIndex,Z=G===void 0?0:G,K=F.selectable,et=F.showIcon,at=F.icon,tt=F.switcherIcon,ft=F.draggable,dt=F.checkable,ht=F.checkStrictly,lt=F.disabled,yt=F.motion,mt=F.loadData,gt=F.filterTreeNode,kt=F.height,_t=F.itemHeight,bt=F.virtual,Mt=F.titleRender,At=F.dropIndicatorRender,Ft=F.onContextMenu,Bt=F.onScroll,Ut=F.direction,Xt=F.rootClassName,It=F.rootStyle,ae=AD(this.props,{aria:!0,data:!0}),$t;return ft&&(tn(ft)==="object"?$t=ft:typeof ft=="function"?$t={nodeDraggable:ft}:$t={}),_.createElement(Wx.Provider,{value:{prefixCls:H,selectable:K,showIcon:et,icon:at,switcherIcon:tt,draggable:$t,draggingNodeKey:h,checkable:dt,checkStrictly:ht,disabled:lt,keyEntities:l,dropLevelOffset:f,dropContainerKey:g,dropTargetKey:b,dropPosition:z,dragOverNodeKey:M,indent:I,direction:Ut,dropIndicatorRender:At,loadData:mt,filterTreeNode:gt,titleRender:Mt,onNodeClick:this.onNodeClick,onNodeDoubleClick:this.onNodeDoubleClick,onNodeExpand:this.onNodeExpand,onNodeSelect:this.onNodeSelect,onNodeCheck:this.onNodeCheck,onNodeLoad:this.onNodeLoad,onNodeMouseEnter:this.onNodeMouseEnter,onNodeMouseLeave:this.onNodeMouseLeave,onNodeContextMenu:this.onNodeContextMenu,onNodeDragStart:this.onNodeDragStart,onNodeDragEnter:this.onNodeDragEnter,onNodeDragOver:this.onNodeDragOver,onNodeDragLeave:this.onNodeDragLeave,onNodeDragEnd:this.onNodeDragEnd,onNodeDrop:this.onNodeDrop}},_.createElement("div",{role:"tree",className:wi(H,E,Xt,oe(oe(oe({},"".concat(H,"-show-line"),W),"".concat(H,"-focused"),a),"".concat(H,"-active-focused"),p!==null)),style:It},_.createElement(sP,qi({ref:this.listRef,prefixCls:H,style:R,data:s,disabled:lt,selectable:K,checkable:!!dt,motion:yt,dragging:h!==null,height:kt,itemHeight:_t,virtual:bt,focusable:$,focused:a,tabIndex:Z,activeItem:this.getActiveItem(),onFocus:this.onFocus,onBlur:this.onBlur,onKeyDown:this.onKeyDown,onActiveChange:this.onActiveChange,onListChangeStart:this.onListChangeStart,onListChangeEnd:this.onListChangeEnd,onContextMenu:Ft,onScroll:Bt},this.getTreeNodeRequiredProps(),ae))))}}],[{key:"getDerivedStateFromProps",value:function(o,a){var s=a.prevProps,l={prevProps:o};function h(G){return!s&&G in o||s&&s[G]!==o[G]}var p,f=a.fieldNames;if(h("fieldNames")&&(f=Hu(o.fieldNames),l.fieldNames=f),h("treeData")?p=o.treeData:h("children")&&(co(!1,"`children` of Tree is deprecated. Please use `treeData` instead."),p=aQ(o.children)),p){l.treeData=p;var g=lQ(p,{fieldNames:f});l.keyEntities=Ke(oe({},S0,aP),g.keyEntities)}var b=l.keyEntities||a.keyEntities;if(h("expandedKeys")||s&&h("autoExpandParent"))l.expandedKeys=o.autoExpandParent||!s&&o.defaultExpandParent?_k(o.expandedKeys,b):o.expandedKeys;else if(!s&&o.defaultExpandAll){var z=Ke({},b);delete z[S0],l.expandedKeys=Object.keys(z).map(function(G){return z[G].key})}else!s&&o.defaultExpandedKeys&&(l.expandedKeys=o.autoExpandParent||o.defaultExpandParent?_k(o.defaultExpandedKeys,b):o.defaultExpandedKeys);if(l.expandedKeys||delete l.expandedKeys,p||l.expandedKeys){var M=Uf(p||a.treeData,l.expandedKeys||a.expandedKeys,f);l.flattenNodes=M}if(o.selectable&&(h("selectedKeys")?l.selectedKeys=kk(o.selectedKeys,o):!s&&o.defaultSelectedKeys&&(l.selectedKeys=kk(o.defaultSelectedKeys,o))),o.checkable){var I;if(h("checkedKeys")?I=Yf(o.checkedKeys)||{}:!s&&o.defaultCheckedKeys?I=Yf(o.defaultCheckedKeys)||{}:p&&(I=Yf(o.checkedKeys)||{checkedKeys:a.checkedKeys,halfCheckedKeys:a.halfCheckedKeys}),I){var F=I,H=F.checkedKeys,E=H===void 0?[]:H,R=F.halfCheckedKeys,W=R===void 0?[]:R;if(!o.checkStrictly){var $=Xf(E,!0,b);E=$.checkedKeys,W=$.halfCheckedKeys}l.checkedKeys=E,l.halfCheckedKeys=W}}return h("loadedKeys")&&(l.loadedKeys=o.loadedKeys),l}}]),n}(_.Component);oe(qx,"defaultProps",{prefixCls:"rc-tree",showLine:!1,showIcon:!0,selectable:!0,multiple:!1,checkable:!1,disabled:!1,checkStrictly:!1,draggable:!1,defaultExpandParent:!0,autoExpandParent:!1,defaultExpandAll:!1,defaultExpandedKeys:[],defaultCheckedKeys:[],defaultSelectedKeys:[],dropIndicatorRender:RZ,allowDrop:function(){return!0},expandAction:!1});oe(qx,"TreeNode",n8);const kQ=({data:t})=>{const{Depth:r,Items:n,ImageListObj:i,ImageIndex:o,Visible:a,Event:s,CSS:l}=t==null?void 0:t.Properties,h=j1(l),[p,f]=_.useState([]),{dataRef:g,socket:b,findDesiredData:z}=w1(),M=Yr(t==null?void 0:t.Properties),I=[];let F=0;const H=vD(i),E=JSON.parse(Ui(g.current,H)),R=(et,at)=>{const{node:tt}=at;if(et.length>p.length){et.filter(ht=>!p.includes(ht));const ft=JSON.stringify({Event:{EventName:"Expanding",ID:t==null?void 0:t.ID,Info:tt==null?void 0:tt.id}});if(!(s&&s.some(ht=>{var lt;return ht[0]==="Expanding"&&((lt=tt==null?void 0:tt.children)==null?void 0:lt.length)>0})))return;console.log(ft),b.send(ft)}else if(et.length!et.includes(lt));Hq(r,1+Iq(ft));const dt=JSON.stringify({Event:{EventName:"Retracting",ID:t==null?void 0:t.ID,Info:tt==null?void 0:tt.id}});if(!(s&&s.some(lt=>lt[0]==="Retracting")))return;console.log(dt),b.send(dt)}else console.log("Equal");f(et)},W=(et,at)=>{var tt;return at?vt.jsxs("div",{style:{display:"flex",alignItems:"center"},children:[vt.jsx("img",{src:`${Qi()}${(tt=E==null?void 0:E.Properties)==null?void 0:tt.Files[at-1]}`}),vt.jsx("div",{children:et})]}):vt.jsx("span",{onKeyDown:ft=>console.log({e:ft}),children:et})};for(let et=0;et=1){F++;const ft={id:F,title:tt};let dt=I[I.length-1];for(let ht=1;ht{const tt=JSON.stringify({Event:{EventName:"ItemDown",ID:t==null?void 0:t.ID,Info:[et,1,at,4]}}),ft=new Array(F).fill(0);ft[et-1]=1;const dt=JSON.stringify({Event:{SelItems:ft}});localStorage.setItem(t==null?void 0:t.ID,dt),s&&s.some(lt=>lt[0]==="ItemDown")&&(console.log(tt),b.send(tt))},G=(et,at)=>{var mt;const{selectedNodes:tt,nativeEvent:ft}=at,dt=ft.altKey?4:0,ht=ft.ctrlKey?2:0,lt=ft.shiftKey?1:0;ft.button;let yt=dt+ht+lt;tt.length!=0&&$((mt=tt[0])==null?void 0:mt.id,yt)},Z=(et,at)=>{const tt=JSON.stringify({Event:{EventName:"ItemDblClick",ID:t==null?void 0:t.ID,Info:[et,1,at,4]}}),ft=new Array(F).fill(0);ft[et-1]=1;const dt=JSON.stringify({Event:{SelItems:ft}});localStorage.setItem(t==null?void 0:t.ID,dt),s&&s.some(lt=>lt[0]==="ItemDblClick")&&(console.log(tt),b.send(tt))},K=(et,at)=>{const{nativeEvent:tt}=at,ft=tt!=null&&tt.altKey?4:0,dt=tt!=null&&tt.ctrlKey?2:0,ht=tt!=null&&tt.shiftKey?1:0;tt==null||tt.button;let lt=ft+dt+ht;Z(at.id,lt)};return _.useEffect(()=>{localStorage.setItem(t.ID,JSON.stringify({Event:{SelItems:new Array(n.length).fill(0)}}))},[]),vt.jsx("div",{id:t==null?void 0:t.ID,style:{...M,border:"1px solid black",background:"white",paddingLeft:"2px",paddingTop:"3px",display:a==0?"none":"block",overflowY:"scroll",...h},onMouseDown:et=>{er(et,b,s,t==null?void 0:t.ID)},onMouseUp:et=>{rr(et,b,s,t==null?void 0:t.ID)},onMouseEnter:et=>{ir(et,b,s,t==null?void 0:t.ID)},onMouseMove:et=>{or(et,b,s,t==null?void 0:t.ID)},onMouseLeave:et=>{nr(et,b,s,t==null?void 0:t.ID)},onWheel:et=>{hr(et,b,s,t==null?void 0:t.ID)},onDoubleClick:et=>{mr(et,b,s,t==null?void 0:t.ID)},children:vt.jsx(qx,{onDoubleClick:K,onSelect:G,onKeyDown:et=>In(et,b,s,t==null?void 0:t.ID),onExpand:R,expandAction:"click",treeData:I,showIcon:!1,showLine:!0,style:{fontSize:"12px",lineHeight:"15px",margin:0,padding:0}})})},_Q=({data:t})=>{const{socket:r}=w1(),n=Yr(t==null?void 0:t.Properties),{Items:i,SelItems:o,Visible:a,Size:s,Event:l,CSS:h}=t==null?void 0:t.Properties,p=j1(h),f=_.useRef(),[g,b]=_.useState(1),[z,M]=_.useState(o),I=y4(document.getElementById(Y1(t==null?void 0:t.ID))),[F,H]=_.useState(s[1]);_.useEffect(()=>{H((I==null?void 0:I.width)-50)},[I]);const E={background:"#1264FF",color:"white",cursor:"pointer"},R=W=>{const $=o.length;let G=Array($).fill(0);G[W]=1,localStorage.setItem(t==null?void 0:t.ID,JSON.stringify({Event:{ID:t==null?void 0:t.ID,SelItems:G}})),M(G)};return vt.jsx("div",{ref:f,style:{...n,width:F,border:"1px solid black",display:a==0?"none":"block"},onMouseDown:W=>{er(W,r,l,t==null?void 0:t.ID)},onMouseUp:W=>{rr(W,r,l,t==null?void 0:t.ID)},onMouseEnter:W=>{ir(W,r,l,t==null?void 0:t.ID)},onMouseMove:W=>{or(W,r,l,t==null?void 0:t.ID)},onMouseLeave:W=>{nr(W,r,l,t==null?void 0:t.ID)},onWheel:W=>{hr(W,r,l,t==null?void 0:t.ID)},onDoubleClick:W=>{mr(W,r,l,t==null?void 0:t.ID)},onKeyDown:W=>{In(W,r,l,t==null?void 0:t.ID)},children:i&&i.map((W,$)=>g==z[$]?vt.jsx("div",{style:{...E,fontSize:"12px",height:"14px",display:"flex",alignItems:"center",padding:"1px",...p},children:W}):vt.jsx("div",{onClick:()=>R($),style:{cursor:"pointer",fontSize:"12px",height:"14px",padding:"1px",display:"flex",alignItems:"center",...p},children:W}))})},AQ=({data:t})=>{const{Size:r}=JSON.parse(localStorage.getItem(Y1(t==null?void 0:t.ID))),{Posn:n,SplitObj1:i,SplitObj2:o,Event:a,CSS:s}=t==null?void 0:t.Properties,l=Yr(t.Properties),h=j1(s),[p,f]=_.useState({left:n&&n[1]}),[g,b]=_.useState(!1),{handleData:z,reRender:M,socket:I}=w1(),F=y4(document.getElementById(Y1(t==null?void 0:t.ID))),[H,E]=_.useState(r&&r);_.useEffect(()=>{if(!p||!H)return;let K=p&&p.left&&H&&H[1]?p.left/H[1]*F.width:0;K=Math.max(0,Math.min(K,F.width-3)),f({left:K});const et=F.width-(K+3);z({ID:i,Properties:{Posn:[0,0],Size:[F.height,Math.round(K)],BCol:[255,255,255]}},"WS"),z({ID:o,Properties:{Posn:[0,Math.round(K+3)],Size:[F==null?void 0:F.height,Math.round(et)],BCol:[255,255,255]}},"WS"),localStorage.setItem(t==null?void 0:t.ID,JSON.stringify({Event:{EventName:$&&$[0],ID:t.ID,Info:[0,Math.round(K)],Size:[W,3]}})),E([F==null?void 0:F.height,F==null?void 0:F.width]),M()},[F]);let R=F.width,W=F.height;const $=a&&a[0];let G={width:"3px",height:"100%",backgroundColor:"#F0F0F0",cursor:"col-resize",position:"absolute",top:n&&n[0],left:p==null?void 0:p.left,...l,...h};_.useEffect(()=>{const K=at=>{if(g){const tt=JSON.parse(localStorage.getItem("formPositions"));let ft=at.clientX-tt[1];ft=Math.max(0,Math.min(ft,R-3));const dt=R-(ft+3);localStorage.setItem(i,JSON.stringify({Posn:[0,0],Size:[W,ft]})),localStorage.setItem(o,JSON.stringify({Posn:[0,ft+3],Size:[W,dt]})),z({ID:i,Properties:{Posn:[0,0],Size:[W,ft],BCol:[255,255,255]}},"WS"),z({ID:o,Properties:{Posn:[0,ft+3],Size:[W,dt],BCol:[255,255,255]}},"WS"),localStorage.setItem(t==null?void 0:t.ID,JSON.stringify({Event:{EventName:$&&$[0],ID:t.ID,Info:[0,ft],Size:[W,3]}})),f({left:ft}),M()}},et=()=>{if(g){b(!1);const{Event:at}=JSON.parse(localStorage.getItem(t==null?void 0:t.ID)),{Size:tt,...ft}=at;if(!(a&&(a==null?void 0:a.some(ht=>ht[0]==="EndSplit"))))return;console.log(JSON.stringify({Event:{...ft}})),I.send(JSON.stringify({Event:{...ft}}))}};return document.addEventListener("mousemove",K),document.addEventListener("mouseup",et),()=>{document.removeEventListener("mousemove",K),document.removeEventListener("mouseup",et)}},[g]);const Z=K=>{K.preventDefault(),b(!0)};return vt.jsx("div",{id:t==null?void 0:t.ID,onClick:K=>K.preventDefault(),onMouseDown:Z,style:G})},LQ=({data:t})=>{const{Size:r,Posn:n}=JSON.parse(localStorage.getItem(Y1(t==null?void 0:t.ID))),{Posn:i,SplitObj1:o,SplitObj2:a,Event:s,Size:l,CSS:h}=t==null?void 0:t.Properties,p=Yr(t.Properties),f=j1(h),[g,b]=_.useState({top:i&&i[0]}),[z,M]=_.useState(!1),{handleData:I,reRender:F,socket:H}=w1(),E=y4(document.getElementById(Y1(t==null?void 0:t.ID))),[R,W]=_.useState(r&&r),[$,G]=_.useState(l&&l[0]);_.useEffect(()=>{if(g&&R){if($==E.height){const tt=JSON.parse(localStorage.getItem(o)),ft=JSON.parse(localStorage.getItem(a));if(!tt&&!ft)return;const{Size:dt,Posn:ht}=tt,{Size:lt,Posn:yt}=ft;localStorage.setItem(o,JSON.stringify({Size:[Math.round(dt&&dt[0]),E.width],Posn:ht})),localStorage.setItem(a,JSON.stringify({Size:[Math.round(lt&<[0]),E.width],Posn:yt})),I({ID:o,Properties:{Posn:ht,Size:[Math.round(dt&&dt[0]),E.width]}},"WS"),I({ID:a,Properties:{Posn:yt,Size:[Math.round(lt&<[0]),E.width]}},"WS")}else{let tt=g&&g.top&&R&&R[0]?g.top/R[0]*E.height:0;tt=Math.max(0,Math.min(tt,E.height-3)),b({top:Math.round(tt)}),I({ID:o,Properties:{Posn:[0,0],Size:[Math.round(tt),E.width]}},"WS"),I({ID:a,Properties:{Posn:[Math.round(tt+3),0],Size:[Math.round((E==null?void 0:E.height)-(tt+3)),E.width]}},"WS")}G(E.height),W([E==null?void 0:E.height,E==null?void 0:E.width]),F()}},[E]);let Z=E.height;const K=s&&s[0];_.useEffect(()=>{const tt=dt=>{if(z){const ht=JSON.parse(localStorage.getItem("formPositions"));let lt=dt.clientY-ht[1];const yt=JSON.parse(localStorage.getItem(Y1(t==null?void 0:t.ID))),{Size:mt}=yt;lt=Math.max(0,Math.min(lt,Z)),I({ID:o,Properties:{Posn:[0,0],Size:[lt,mt[1]]}},"WS"),I({ID:a,Properties:{Posn:[lt+3,0],Size:[Z-(lt+3),mt[1]]}},"WS"),localStorage.setItem(t==null?void 0:t.ID,JSON.stringify({Event:{EventName:K&&K[0],ID:t.ID,Info:[lt,0],Size:[3,Z]}})),b({top:lt}),F()}},ft=()=>{if(z){M(!1);const{Event:dt}=JSON.parse(localStorage.getItem(t==null?void 0:t.ID)),{Size:ht,...lt}=dt;if(!(s&&(s==null?void 0:s.some(mt=>mt[0]==="EndSplit"))))return;console.log(JSON.stringify({Event:{...lt}})),H.send(JSON.stringify({Event:{...lt}}))}};return document.addEventListener("mousemove",tt),document.addEventListener("mouseup",ft),()=>{document.removeEventListener("mousemove",tt),document.removeEventListener("mouseup",ft)}},[z]);const et=tt=>{tt.preventDefault(),M(!0)};let at={width:"100%",height:"3px",backgroundColor:"#F0F0F0",cursor:"row-resize",position:"absolute",top:g==null?void 0:g.top,left:0,...p,...f};return vt.jsx("div",{id:t==null?void 0:t.ID,style:at,onMouseDown:tt=>et(tt)})},EQ=({data:t})=>{const{Style:r,Posn:n,SplitObj1:i,SplitObj2:o,Event:a}=t==null?void 0:t.Properties,{handleData:s}=w1();let l=800,h=800;const p=a&&a[0],f=()=>{r&&r=="Horz"?Object.keys(localStorage).forEach(b=>{const z=b.split(".");if(z.length==2&&z.includes("RIGHT")){const M=JSON.parse(localStorage.getItem(b)),{Size:I}=M;localStorage.setItem(t==null?void 0:t.ID,JSON.stringify({Event:{EventName:p&&p[0],ID:t.ID,Info:n,Size:[3,I[1]]}})),localStorage.setItem(i,JSON.stringify({Size:[n[0],I[1]],Posn:[0,0]})),s({ID:i,Properties:{Posn:[0,0],Size:[n[0],I[1]],BCol:[255,255,255]}},"WS"),localStorage.setItem(o,JSON.stringify({Size:[h-(n[0]+3),I[1]],Posn:[n[0]+3,0]})),s({ID:o,Properties:{Posn:[n[0]+3,0],Size:[h-(n[0]+3),I[1]],BCol:[255,255,255]}},"WS")}}):(localStorage.setItem(t==null?void 0:t.ID,JSON.stringify({Event:{EventName:p&&p[0],ID:t.ID,Info:n,Size:[h,3]}})),localStorage.setItem(i,JSON.stringify({Size:[h,n[1]],Posn:[0,n[1]]})),localStorage.setItem(o,JSON.stringify({Size:[h,l-(n[1]+3)],Posn:[0,n[1]+3]})),s({ID:i,Properties:{BCol:[255,255,255]}},"WS"),s({ID:o,Properties:{BCol:[255,255,255]}},"WS"))};return _.useEffect(()=>{f()},[]),r&&r=="Horz"?vt.jsx(LQ,{data:t}):vt.jsx(AQ,{data:t})},IQ=({data:t})=>{var W,$;const{Visible:r,Picture:n,Border:i=1,Size:o,Flex:a=0,CSS:s,Event:l}=t==null?void 0:t.Properties,{findDesiredData:h,socket:p}=w1(),f=y4(document.getElementById(Y1(t==null?void 0:t.ID))),[g,b]=_.useState(o[1]),[z,M]=_.useState(o[0]);_.useEffect(()=>{o.length||(b((f==null?void 0:f.width)-47),M((f==null?void 0:f.height)-47))},[f]);const I=h(n&&n[0]),F=$9(n&&n[1],I),H=j1(s),E=ra(t),R=Yr(t==null?void 0:t.Properties,"absolute",a);return vt.jsxs("div",{style:{...R,width:g,height:z,border:i==0?"none":"1px solid #E9E9E9",display:r==0?"none":"block",...F,...H},id:t==null?void 0:t.ID,onMouseDown:G=>{er(G,p,l,t==null?void 0:t.ID)},onMouseUp:G=>{rr(G,p,l,t==null?void 0:t.ID)},onMouseEnter:G=>{ir(G,p,l,t==null?void 0:t.ID)},onMouseMove:G=>{or(G,p,l,t==null?void 0:t.ID)},onMouseLeave:G=>{nr(G,p,l,t==null?void 0:t.ID)},onWheel:G=>{hr(G,p,l,t==null?void 0:t.ID)},onDoubleClick:G=>{mr(G,p,l,t==null?void 0:t.ID)},onKeyDown:G=>{In(G,p,l,t==null?void 0:t.ID)},children:[((W=t==null?void 0:t.Properties)==null?void 0:W.Caption)!=""&&vt.jsx("span",{style:{fontSize:"12px",position:"relative",bottom:14,left:10,background:"#F1F1F1 "},children:($=t==null?void 0:t.Properties)==null?void 0:$.Caption}),Object.keys(E).map(G=>vt.jsx(E4,{data:E[G]}))]})};var cP={color:void 0,size:void 0,className:void 0,style:void 0,attr:void 0},Ak=cr.createContext&&cr.createContext(cP),Js=globalThis&&globalThis.__assign||function(){return Js=Object.assign||function(t){for(var r,n=1,i=arguments.length;nt?t<1?1:t>r?r:t:1,Ext=({data:t})=>{const{FA:r}=Axt,{Align:n,Type:i,Range:o,Event:a,Visible:s,Size:l,Posn:h,VScroll:p,HScroll:f,Attach:g,CSS:b,Thumb:z}=t==null?void 0:t.Properties,M=Lxt(z,o),I=i==="Scroll"&&(n==="Bottom"||f===-1),[F,H]=_.useState(M),[E,R]=_.useState(M);j1(b);const[W,$]=_.useState(!1),G=a&&a[0],Z=JSON.parse(localStorage.getItem("formDimension")),{socket:K,handleData:et,proceed:at,setProceed:tt,proceedEventArray:ft,setProceedEventArray:dt,nqEvents:ht,setNqEvents:lt}=w1(),yt=_.useRef(null),mt=_.useRef(null),gt=o;console.log("300 thumb",t,z,F),console.log("300 here",ft,ht);const kt=localStorage.getItem("keyPressEventId");_.useEffect(()=>{const Wt=kt+"ArrowClick";if(ft[Wt]||ft[Wt]===0){const qt=Ia();if(ht.length){const{Info:Ie,ID:Pe}=ht.shift();localStorage.setItem("current-event","CellMove"),localStorage.setItem("keyPressEventId",qt),K.send(JSON.stringify({Event:{EventName:"CellMove",EventID:qt,ID:Pe,Info:Ie}}))}H(M);const Ee=Ft(M);Ut(Ee),ae(Ee+io),tt(!1),dt(Ie=>({...Ie,[Wt]:0}))}},[ft[kt+"ArrowClick"]]);const _t=JSON.parse(localStorage.getItem("nqCurCell"));_.useEffect(()=>{const Wt=kt+"CellMove";if((ft[Wt]||ft[Wt]===0)&&_t){console.log("Inside curCell",Wt);const{Info:qt,ID:Ee}=_t;et({ID:Ee,Properties:{CurCell:[qt[0],qt[1]]}},"WS")}},[ft[kt+"CellMove"],M]);const bt=l?l&&l[0]:Z&&Z[0]-io,Mt=l?l&&l[1]:Z&&Z[1]-io,At=I?Mt-io*2-40:bt-io*2-40,Ft=Wt=>Wt/gt*At,[Bt,Ut]=_.useState(Ft(F)),Xt=Wt=>{$(!0),ir(Wt,K,a,t==null?void 0:t.ID)},It=Wt=>{$(!1),nr(Wt,K,a,t==null?void 0:t.ID)},ae=Wt=>{mt.current&&(mt.current.style[I?"left":"top"]=`${Wt}px`)},$t=Wt=>{Wt.preventDefault(),Wt.stopPropagation();const qt=I?Wt.clientX:Wt.clientY,Ee=Bt;let Ie=Ee;const Pe=st=>{const zt=(I?st.clientX:st.clientY)-qt;Ie=Ee+zt,Ie=Math.max(0,Math.min(At,Ie)),ae(Ie);const Rt=Ie/At*gt;R(Rt)},Yt=()=>{window.removeEventListener("mousemove",Pe),window.removeEventListener("mouseup",Yt);const st=Ie/At*gt,Et=Math.round(st)||1;Ut(Ie);const zt=Ia();localStorage.setItem("current-event","ArrowClick"),localStorage.setItem("keyPressEventId",zt);const Rt=JSON.stringify({Event:{EventName:"Scroll",ID:t==null?void 0:t.ID,EventID:zt,Info:[0,Et]}});localStorage.setItem(t.ID,Rt),a&&a.some(Qt=>Qt[0]==="Scroll")&&K.send(Rt)};window.addEventListener("mousemove",Pe),window.addEventListener("mouseup",Yt)},ue=h||[0,0],Ot=l||[20,20],we=Wt=>{if(!(mt.current&&(Wt.target===mt.current||mt.current.contains(Wt.target)))&&mt.current&&yt.current){const qt=yt.current.getBoundingClientRect(),Ee=I?Wt.clientX-qt.left:Wt.clientY-qt.top,Pe=Math.max(0,Math.min(At,Ee-20))/At*gt;R(Pe);const Yt=Ia();localStorage.setItem("current-event","ArrowClick"),localStorage.setItem("keyPressEventId",Yt);const st=JSON.stringify({Event:{EventName:G&&G[0],ID:t==null?void 0:t.ID,EventID:Yt,Info:[Math.round(E)zt[0]==="Scroll")&&K.send(st)}},Ht=()=>{const Wt=F+1;if(Wt<=gt){R(Wt);const qt=Ia();if(console.log("Event",JSON.stringify({Event:{EventName:G&&G[0],ID:t==null?void 0:t.ID,Info:[1,Math.round(Wt)]}})),I?localStorage.setItem("horizontalScroll",JSON.stringify({oldValue:Math.round(F),newValue:Math.round(Wt)})):localStorage.setItem("verticalScroll",JSON.stringify({oldValue:Math.round(F),newValue:Math.round(Wt)})),localStorage.setItem("current-event","ArrowClick"),localStorage.setItem("keyPressEventId",qt),!(a&&a.some(Ie=>Ie[0]==="Scroll")))return;K.send(JSON.stringify({Event:{EventName:"Scroll",EventID:qt,ID:t==null?void 0:t.ID,Info:[1,Math.round(Wt)]}}))}},se=()=>{const Wt=F-1;if(Wt>=1){R(Wt),console.log(JSON.stringify({Event:{EventName:G&&G[0],ID:t==null?void 0:t.ID,Info:[-1,Math.round(Wt)]}})),localStorage.setItem(t.ID,JSON.stringify({Event:{EventName:G&&G[0],ID:t==null?void 0:t.ID,Info:[-1,Math.round(Wt)]}})),I?localStorage.setItem("horizontalScroll",JSON.stringify({oldValue:Math.round(F),newValue:Math.round(Wt)})):localStorage.setItem("verticalScroll",JSON.stringify({oldValue:Math.round(F),newValue:Math.round(Wt)}));const qt=Ia();if(localStorage.setItem("current-event","ArrowClick"),localStorage.setItem("keyPressEventId",qt),!(a&&a.some(Ie=>Ie[0]==="Scroll")))return;K.send(JSON.stringify({Event:{EventName:"Scroll",EventID:qt,ID:t==null?void 0:t.ID,Info:[-1,Math.round(Wt)]}}))}};_.useEffect(()=>{I?localStorage.setItem("horizontalScroll",JSON.stringify({oldValue:M,newValue:M})):localStorage.setItem("verticalScroll",JSON.stringify({oldValue:M,newValue:M}))},[]),_.useEffect(()=>{H(Math.min(z,gt)),et({ID:t==null?void 0:t.ID,Properties:{Thumb:M}},"WS")},[z]);const Kt=(()=>{let Wt={};if(g){const[qt,Ee,Ie,Pe]=g;(qt==="Top"||qt==="Bottom")&&(Wt.top=`${ue[0]}px`),(Ee==="Left"||Ee==="Right")&&(Wt.left=`${ue[1]}px`),(Ie==="Bottom"||Ie==="Top")&&(Wt.bottom=`${ue[0]}px`),(Pe==="Right"||Pe==="Left")&&(Wt.right=`${ue[1]}px`)}return Wt})(),fe={width:I?`${Mt}px`:`${Ot[1]}px`,height:I?`${Ot[0]}px`:`${bt}px`,paddingLeft:I?`${io}px`:0,paddingRight:I?`${io}px`:0,paddingTop:I?0:`${io}px`,paddingBottom:I?0:`${io}px`},ne={width:I?"40px":`${Ot[1]-6}px`,height:I?`${Ot[0]-6}px`:"40px",backgroundColor:"#9E9E9E",position:"absolute",left:I?`${Bt+io}px`:"2px",top:I?"2px":`${Bt+io}px`,cursor:"pointer",borderRadius:"5px"},ce={position:"absolute",top:p===-1&&ue[0]!==void 0?ue[0]:0,...p===-1?{left:p===-1&&ue[1]!==void 0?ue[1]:0}:{right:0},display:s==0?"none":"block",...Kt},xe={position:"absolute",...f===-1?{top:f===-1&&ue[0]!==void 0?ue[0]:0}:{bottom:0},left:f===-1&&ue[1]!==void 0?ue[1]:0,width:Ot[1]+"px",height:Ot[0],display:s==0?"none":"block",...Kt};return vt.jsx("div",{id:t==null?void 0:t.ID,onMouseEnter:Xt,onMouseLeave:It,onWheel:Wt=>hr(Wt,K,a,t==null?void 0:t.ID),onMouseDown:Wt=>{er(Wt,K,a,t==null?void 0:t.ID)},onMouseUp:Wt=>{rr(Wt,K,a,t==null?void 0:t.ID)},onMouseMove:Wt=>{or(Wt,K,a,t==null?void 0:t.ID)},onDoubleClick:Wt=>{mr(Wt,K,a,t==null?void 0:t.ID)},onKeyDown:Wt=>{In(Wt,K,a,t==null?void 0:t.ID)},style:I?xe:ce,children:vt.jsxs("div",{children:[I&&W?vt.jsxs(vt.Fragment,{children:[vt.jsx("div",{className:"scroll-bar-icon scroll-bar-icon-horizontal icon-style",style:{left:"0",height:`${bt}px`},onClick:se,children:vt.jsx(r.FaCaretDown,{style:{position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)"}})}),vt.jsx("div",{className:"scroll-bar-icon scroll-bar-icon-horizontal icon-style",style:{right:"0",height:`${bt}px`},onClick:Ht,children:vt.jsx(r.FaCaretUp,{style:{position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)"}})})]}):W?vt.jsxs(vt.Fragment,{children:[vt.jsx("div",{className:"scroll-bar-icon icon-style",style:{top:"0",width:`${Ot[1]}px`},onClick:se,children:vt.jsx(r.FaCaretUp,{style:{position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)"}})}),vt.jsx("div",{className:"scroll-bar-icon icon-style",style:{bottom:"0",width:`${Ot[1]}px`},onClick:Ht,children:vt.jsx(r.FaCaretDown,{style:{position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)"}})})]}):null,vt.jsx("div",{className:`scroll-bar ${I?"horizontal":"vertical"}`,style:fe,onMouseDown:we,ref:yt,children:vt.jsx("div",{className:"thumb",style:ne,ref:mt,onMouseDown:$t,onKeyDown:()=>In(e,K,a,t==null?void 0:t.ID)})})]})})},uP=({data:t})=>{const{findDesiredData:r,socket:n,dataRef:i}=w1(),{Size:o,Posn:a,Picture:s,Visible:l,BCol:h,FlexDirection:p,JustifyContent:f,Display:g,Flex:b=0,CSS:z,Event:M}=t==null?void 0:t.Properties,I=_.useRef(null),F=Yr(t==null?void 0:t.Properties,"absolute",b),H=j1(z),E=ra(t),R=r(s&&s[0]),W=$9(s&&s[1],R,t==null?void 0:t.Properties);let $={...F,...W,...H};return console.log("App Subform",{styles:F,data:t,updatedStyles:$,flexStyles:H,Size:o,Posn:a}),_.useEffect(()=>{let G;t.ID==="F1.SCALE"?setTimeout(()=>{var Z,K,et,at,tt;G=JSON.parse(localStorage.getItem(t.ID)),G&&((Z=G.Event)==null?void 0:Z.ID)===t.ID&&(G.Event={...G.Event,Size:((K=t.Properties)==null?void 0:K.Size)||((et=G.Event)==null?void 0:et.Size),Posn:((at=t.Properties)==null?void 0:at.Posn)||((tt=G.Event)==null?void 0:tt.Posn)})},500):t.ID==="F1.BX"?localStorage.setItem(t.ID,JSON.stringify({Size:o||[600,400],Posn:a||[50,50]})):localStorage.setItem(t.ID,JSON.stringify({Size:o&&o,Posn:a&&a}))},[t]),vt.jsx("div",{id:t.ID,style:{display:l==0?"none":t!=null&&t.Properties.hasOwnProperty("Flex")?"flex":"block",background:h&&Hr(h),...$},ref:I,onMouseDown:G=>{er(G,n,M,t==null?void 0:t.ID)},onMouseUp:G=>{rr(G,n,M,t==null?void 0:t.ID)},onMouseEnter:G=>{ir(G,n,M,t==null?void 0:t.ID)},onMouseMove:G=>{or(G,n,M,t==null?void 0:t.ID)},onMouseLeave:G=>{nr(G,n,M,t==null?void 0:t.ID)},onWheel:G=>{hr(G,n,M,t==null?void 0:t.ID)},onDoubleClick:G=>{mr(G,n,M,t==null?void 0:t.ID)},onKeyDown:G=>{In(G,n,M,t==null?void 0:t.ID)},children:Object.keys(E).map(G=>vt.jsx(E4,{data:E[G]}))})},pP=({data:t,handleTabClick:r,activeTab:n,bgColor:i,fontColor:o,activebgColor:a})=>{const{socket:s}=w1(),{Caption:l,Event:h,CSS:p}=t==null?void 0:t.Properties,f=h&&h[0],g=j1(p),b=Yr(t.Properties);return vt.jsx("div",{id:t.ID,onMouseDown:z=>{er(z,s,h,t==null?void 0:t.ID)},onMouseUp:z=>{rr(z,s,h,t==null?void 0:t.ID)},onMouseEnter:z=>{ir(z,s,h,t==null?void 0:t.ID)},onMouseMove:z=>{or(z,s,h,t==null?void 0:t.ID)},onMouseLeave:z=>{nr(z,s,h,t==null?void 0:t.ID)},onWheel:z=>{hr(z,s,h,t==null?void 0:t.ID)},onDoubleClick:z=>{mr(z,s,h,t==null?void 0:t.ID)},style:{border:"1px solid #DFDFDF",fontSize:"12px",paddingTop:"2px",paddingBottom:"2px",paddingLeft:"4px",paddingRight:"4px",cursor:"pointer",borderRadius:"2px",background:n==(t==null?void 0:t.ID)?Hr(a||[255,255,255]):Hr(i),height:"20px",borderBottom:n==(t==null?void 0:t.ID)?"0px":"1px solid #DFDFDF",color:o?Hr(o):"black",fontWeight:600,...b,...g},onClick:()=>{console.log(JSON.stringify({Event:{EventName:f&&f[0],ID:t==null?void 0:t.ID,Info:[t==null?void 0:t.ID]}})),localStorage.setItem("lastEvent",JSON.stringify({Event:{EventName:f&&f[0],ID:t==null?void 0:t.ID,Info:[t==null?void 0:t.ID]}})),s.send(JSON.stringify({Event:{EventName:f&&f[0],ID:t==null?void 0:t.ID,Info:[t==null?void 0:t.ID]}})),r(t.ID)},children:l})},Ixt=({data:t})=>{const{BCol:r,FCol:n,ActiveBCol:i,CSS:o}=t==null?void 0:t.Properties;let a=Yr(t==null?void 0:t.Properties);const s=j1(o),l=ra(t),h=Cq(l),[p,f]=_.useState(h),{Visible:g}=t==null?void 0:t.Properties,b={...a,display:g==0?"none":"block"},z=M=>{f(M)};return vt.jsxs("div",{id:t==null?void 0:t.ID,style:{...b,...s},children:[vt.jsx("div",{style:{display:"flex",alignItems:"end",marginLeft:"3px"},children:Object.keys(l).map(M=>{var I;return((I=l[M])==null?void 0:I.Properties.Type)=="TabButton"?vt.jsx(pP,{bgColor:r,fontColor:n,activebgColor:i,activeTab:p||h,data:l[M],handleTabClick:z}):null})}),Object.keys(l).map(M=>{var F,H,E,R;const I=p||h;return((H=(F=l[M])==null?void 0:F.Properties)==null?void 0:H.Type)=="SubForm"&&I==((R=(E=l[M])==null?void 0:E.Properties)==null?void 0:R.TabObj)?vt.jsx(uP,{data:l[M]}):null})]})};const Hxt=({data:t})=>{var H;const{handleData:r,socket:n,dataRef:i}=w1(),o=_.useRef(null),a=()=>{var E;if((E=t==null?void 0:t.Properties)!=null&&E.Text)return Array.isArray(t.Properties.Text)?t.Properties.Text.join(` -`):t.Properties.Text;{const R=localStorage.getItem(t.ID);return R&&JSON.parse(R).Text||""}},[s,l]=_.useState(a);let h=Yr(t==null?void 0:t.Properties);const{Font:p,CSS:f,Event:g}=t==null?void 0:t.Properties,b=j1(f);_.useEffect(()=>{var E;if((E=t==null?void 0:t.Properties)!=null&&E.Text){localStorage.setItem(t.ID,JSON.stringify(t.Properties));const R=t==null?void 0:t.Properties.Text;r({ID:t.ID,Properties:{Text:R}},"WS");const W=Array.isArray(t.Properties.Text)?t.Properties.Text.join(` -`):t.Properties.Text;W!==s&&l(W)}},[(H=t==null?void 0:t.Properties)==null?void 0:H.Text]);let z={...h,scrollbarWidth:"thin",scrollbarColor:"transparent transparent",fontFamily:p&&p[0],fontSize:p&&`${p[1]}px`,...b};const M=E=>{const R=E.target.value;l(R),localStorage.setItem(t.ID,JSON.stringify({...t.Properties,Text:R})),r({ID:t.ID,Properties:{Text:R}},"WS")},I=s,F=(E,R)=>{switch(console.log("mousedown",g),R){case"mouseUp":rr(E,n,g,t==null?void 0:t.ID);break;case"mouseDown":er(E,n,g,t==null?void 0:t.ID);break;case"mouseLeave":nr(E,n,g,t==null?void 0:t.ID);break;case"mouseEnter":ir(E,n,g,t==null?void 0:t.ID);break;case"mouseMove":or(E,n,g,t==null?void 0:t.ID);break;case"mouseWheel":hr(E,n,g,t==null?void 0:t.ID);break;case"dblclick":mr(E,n,g,t==null?void 0:t.ID);break}const W=o.current;if(!W)return;const $=W.selectionStart,G=W.selectionEnd,Z=I.split(` -`),K=(ft,dt)=>{let ht=0;for(let mt=0;mtF(E,"mouseUp"),onMouseDown:E=>F(E,"mouseDown"),onMouseEnter:E=>F(E,"mouseEnter"),onMouseLeave:E=>F(E,"mouseLeave"),onMouseMove:E=>F(E,"mouseMove"),onWheel:E=>F(E,"mouseWheel"),onDoubleClick:E=>F(E,"dblclick"),spellCheck:!1})})};const Dxt=({data:t})=>{var b;const r=ra(t),{dataRef:n}=w1(),{Visible:i,Size:o,ImageListObj:a,CSS:s,FontObj:l}=t==null?void 0:t.Properties,h=JSON.parse(localStorage.getItem("formDimension")),p=j1(s),f=vD(a);console.log("Dtaatataat is as",(b=t==null?void 0:t.Properties)==null?void 0:b.BodyHeight);const g=f&&JSON.parse(Ui(n.current,f));return vt.jsx("div",{id:t==null?void 0:t.ID,className:"row",style:{backgroundColor:"rgb(134,171,220)",width:o?o&&o[1]:h&&h[1],display:i==0?"none":"flex",...p},children:Object.keys(r).map((z,M)=>vt.jsx(E4,{data:{...r[z],FontObj:l,id:M,ImageList:g}},M))})},Pxt=({data:t})=>{var R,W;const{findCurrentData:r,fontScale:n,handleData:i,dataRef:o}=w1();console.log("Dattatatatatatta",o.current.F1);const a=ra(t),{Size:s,Title:l,BorderCol:h,CSS:p}=t==null?void 0:t.Properties,f=j1(p),g=r(t.FontObj&&t.FontObj),b=g&&(g==null?void 0:g.Properties),[z,M]=_.useState("auto"),[I,F]=_.useState("auto"),[H,E]=_.useState(100);return _.useEffect(()=>{console.log("Coming hereeeeeeeeee in ss");const $=()=>{setTimeout(()=>{var yt,mt;const G=document.getElementById(t.ID+"-title"),Z=document.getElementById(`ribbon-item-height-${t.id}`),K=document.querySelectorAll(`[id^="ribbon-item-height-${t.id}"]`),et=document.querySelectorAll('[id^="ribbon-height"]');let at=0,tt=0,ft=0;K.forEach(gt=>{const kt=gt.getBoundingClientRect().height||0;at=Math.max(at,kt)}),K.forEach(gt=>{const kt=gt.getBoundingClientRect().width||0;tt+=kt}),K.forEach(gt=>{const kt=gt.getBoundingClientRect().height||0;ft+=kt});const dt=Math.max(tt,ft),ht=(G==null?void 0:G.getBoundingClientRect().width)||0,lt=(Z==null?void 0:Z.getBoundingClientRect().width)||0;K.length>1?M(`${Math.max(dt+lt,ht)}px`):M(`${Math.max(dt,ht)}px`),((mt=(yt=o.current.F1)==null?void 0:yt.Properties)==null?void 0:mt.Caption)==="Big Ribbon Test"||l==="DropDown"?E(50):E(gt=>Math.max(gt,at)),setTimeout(()=>{et.forEach(gt=>{const kt=(G==null?void 0:G.getBoundingClientRect().height)||0;gt.style.height=`${H+kt+20}px`,console.log("Maxxxx value seeeeettt",H,kt,gt.style.height,t.ID,t.id)})},100)},300)};return $(),window.addEventListener("resize",$),()=>window.removeEventListener("resize",$)},[t.ID,t.id,(W=(R=o.current.F1)==null?void 0:R.Properties)==null?void 0:W.Caption,H]),vt.jsx("div",{id:t==null?void 0:t.ID,style:{width:z},children:vt.jsxs("div",{style:{border:`1px solid ${Hr(h)}`,borderTop:0,position:"relative",height:I+18,justifyContent:"space-around",paddingTop:"3px",...f},id:"ribbon-height",className:"row",children:[Object.keys(a).map(($,G)=>vt.jsx(E4,{data:{...a[$],FontObj:t.FontObj,id:t.id,ImageList:t.ImageList}},G)),vt.jsx("div",{children:vt.jsx("p",{id:t.ID+"-title",style:{position:"absolute",bottom:0,backgroundColor:"rgb(204, 204, 204)",margin:0,fontWeight:"bolder",fontFamily:b==null?void 0:b.PName,fontSize:b!=null&&b.Size?`${b.Size*n}px`:`${12*n}px`,minWidth:"max-content",width:"100%",paddingLeft:"10px",paddingRight:"10px"},className:"text-center",children:l})})]})})},Txt=({data:t})=>{const r=ra(t),{CSS:n}=t==null?void 0:t.Properties,i=j1(n);return vt.jsx("div",{"data-alt-id":t==null?void 0:t.ID,id:`ribbon-item-height-${t.id}`,style:{display:"flex",justifyContent:"center",...i,width:"max-content"},children:Object.keys(r).map((o,a)=>vt.jsx(E4,{data:{...r[o],FontObj:t.FontObj,ImageList:t.ImageList}},a))})};function Vxt(t){return C({tag:"svg",attr:{version:"1",viewBox:"0 0 48 48",enableBackground:"new 0 0 48 48"},child:[{tag:"path",attr:{fill:"#CFD8DC",d:"M5,38V14h38v24c0,2.2-1.8,4-4,4H9C6.8,42,5,40.2,5,38z"}},{tag:"path",attr:{fill:"#F44336",d:"M43,10v6H5v-6c0-2.2,1.8-4,4-4h30C41.2,6,43,7.8,43,10z"}},{tag:"g",attr:{fill:"#B71C1C"},child:[{tag:"circle",attr:{cx:"33",cy:"10",r:"3"}},{tag:"circle",attr:{cx:"15",cy:"10",r:"3"}}]},{tag:"g",attr:{fill:"#B0BEC5"},child:[{tag:"path",attr:{d:"M33,3c-1.1,0-2,0.9-2,2v5c0,1.1,0.9,2,2,2s2-0.9,2-2V5C35,3.9,34.1,3,33,3z"}},{tag:"path",attr:{d:"M15,3c-1.1,0-2,0.9-2,2v5c0,1.1,0.9,2,2,2s2-0.9,2-2V5C17,3.9,16.1,3,15,3z"}}]},{tag:"g",attr:{fill:"#90A4AE"},child:[{tag:"rect",attr:{x:"13",y:"20",width:"4",height:"4"}},{tag:"rect",attr:{x:"19",y:"20",width:"4",height:"4"}},{tag:"rect",attr:{x:"25",y:"20",width:"4",height:"4"}},{tag:"rect",attr:{x:"31",y:"20",width:"4",height:"4"}},{tag:"rect",attr:{x:"13",y:"26",width:"4",height:"4"}},{tag:"rect",attr:{x:"19",y:"26",width:"4",height:"4"}},{tag:"rect",attr:{x:"25",y:"26",width:"4",height:"4"}},{tag:"rect",attr:{x:"31",y:"26",width:"4",height:"4"}},{tag:"rect",attr:{x:"13",y:"32",width:"4",height:"4"}},{tag:"rect",attr:{x:"19",y:"32",width:"4",height:"4"}},{tag:"rect",attr:{x:"25",y:"32",width:"4",height:"4"}},{tag:"rect",attr:{x:"31",y:"32",width:"4",height:"4"}}]}]})(t)}function Fxt(t){return C({tag:"svg",attr:{version:"1",viewBox:"0 0 48 48",enableBackground:"new 0 0 48 48"},child:[{tag:"path",attr:{fill:"#F44336",d:"M21.2,44.8l-18-18c-1.6-1.6-1.6-4.1,0-5.7l18-18c1.6-1.6,4.1-1.6,5.7,0l18,18c1.6,1.6,1.6,4.1,0,5.7l-18,18 C25.3,46.4,22.7,46.4,21.2,44.8z"}},{tag:"path",attr:{fill:"#fff",d:"M21.6,32.7c0-0.3,0.1-0.6,0.2-0.9c0.1-0.3,0.3-0.5,0.5-0.7c0.2-0.2,0.5-0.4,0.8-0.5s0.6-0.2,1-0.2 s0.7,0.1,1,0.2c0.3,0.1,0.6,0.3,0.8,0.5c0.2,0.2,0.4,0.4,0.5,0.7c0.1,0.3,0.2,0.6,0.2,0.9s-0.1,0.6-0.2,0.9s-0.3,0.5-0.5,0.7 c-0.2,0.2-0.5,0.4-0.8,0.5c-0.3,0.1-0.6,0.2-1,0.2s-0.7-0.1-1-0.2s-0.5-0.3-0.8-0.5c-0.2-0.2-0.4-0.4-0.5-0.7S21.6,33.1,21.6,32.7z M25.8,28.1h-3.6L21.7,13h4.6L25.8,28.1z"}}]})(t)}function Rxt(t){return C({tag:"svg",attr:{version:"1",viewBox:"0 0 48 48",enableBackground:"new 0 0 48 48"},child:[{tag:"polygon",attr:{fill:"#E8EAF6",points:"42,39 6,39 6,23 24,6 42,23"}},{tag:"g",attr:{fill:"#C5CAE9"},child:[{tag:"polygon",attr:{points:"39,21 34,16 34,9 39,9"}},{tag:"rect",attr:{x:"6",y:"39",width:"36",height:"5"}}]},{tag:"polygon",attr:{fill:"#B71C1C",points:"24,4.3 4,22.9 6,25.1 24,8.4 42,25.1 44,22.9"}},{tag:"rect",attr:{x:"18",y:"28",fill:"#D84315",width:"12",height:"16"}},{tag:"rect",attr:{x:"21",y:"17",fill:"#01579B",width:"6",height:"6"}},{tag:"path",attr:{fill:"#FF8A65",d:"M27.5,35.5c-0.3,0-0.5,0.2-0.5,0.5v2c0,0.3,0.2,0.5,0.5,0.5S28,38.3,28,38v-2C28,35.7,27.8,35.5,27.5,35.5z"}}]})(t)}function Oxt(t){return C({tag:"svg",attr:{version:"1",viewBox:"0 0 48 48",enableBackground:"new 0 0 48 48"},child:[{tag:"circle",attr:{fill:"#2196F3",cx:"24",cy:"24",r:"21"}},{tag:"rect",attr:{x:"22",y:"22",fill:"#fff",width:"4",height:"11"}},{tag:"circle",attr:{fill:"#fff",cx:"24",cy:"16.5",r:"2.5"}}]})(t)}function Bxt(t){return C({tag:"svg",attr:{version:"1",viewBox:"0 0 48 48",enableBackground:"new 0 0 48 48"},child:[{tag:"path",attr:{fill:"#37474F",d:"M8,41V7c0-2.2,1.8-4,4-4h24c2.2,0,4,1.8,4,4v34c0,2.2-1.8,4-4,4H12C9.8,45,8,43.2,8,41z"}},{tag:"path",attr:{fill:"#eee",d:"M35,6H13c-0.6,0-1,0.4-1,1v29c0,0.6,0.4,1,1,1h22c0.6,0,1-0.4,1-1V7C36,6.4,35.6,6,35,6z"}},{tag:"rect",attr:{x:"20",y:"40",fill:"#546E7A",width:"8",height:"2"}},{tag:"g",attr:{fill:"#A1A1A1"},child:[{tag:"rect",attr:{x:"16",y:"11",width:"16",height:"3"}},{tag:"rect",attr:{x:"16",y:"18",width:"16",height:"2"}},{tag:"rect",attr:{x:"16",y:"22",width:"12",height:"2"}},{tag:"rect",attr:{x:"16",y:"26",width:"16",height:"2"}},{tag:"rect",attr:{x:"16",y:"30",width:"12",height:"2"}}]}]})(t)}function Nxt(t){return C({tag:"svg",attr:{version:"1",viewBox:"0 0 48 48",enableBackground:"new 0 0 48 48"},child:[{tag:"g",attr:{fill:"#FF9800"},child:[{tag:"rect",attr:{x:"1",y:"38",width:"46",height:"2"}},{tag:"rect",attr:{x:"25",y:"18",width:"4",height:"16"}},{tag:"rect",attr:{x:"31",y:"18",width:"4",height:"16"}},{tag:"rect",attr:{x:"37",y:"18",width:"4",height:"16"}},{tag:"rect",attr:{x:"19",y:"18",width:"4",height:"16"}},{tag:"rect",attr:{x:"13",y:"18",width:"4",height:"16"}},{tag:"rect",attr:{x:"7",y:"18",width:"4",height:"16"}},{tag:"polygon",attr:{points:"43,16 5,16 5,13 24,4 43,13"}},{tag:"rect",attr:{x:"5",y:"34",width:"38",height:"2"}}]},{tag:"g",attr:{fill:"#EF6C00"},child:[{tag:"rect",attr:{x:"25",y:"16",width:"4",height:"2"}},{tag:"rect",attr:{x:"31",y:"16",width:"4",height:"2"}},{tag:"rect",attr:{x:"37",y:"16",width:"4",height:"2"}},{tag:"rect",attr:{x:"19",y:"16",width:"4",height:"2"}},{tag:"rect",attr:{x:"13",y:"16",width:"4",height:"2"}},{tag:"rect",attr:{x:"7",y:"16",width:"4",height:"2"}},{tag:"rect",attr:{x:"3",y:"36",width:"42",height:"2"}},{tag:"circle",attr:{cx:"24",cy:"11",r:"2"}}]}]})(t)}function $xt(t){return C({tag:"svg",attr:{version:"1",viewBox:"0 0 48 48",enableBackground:"new 0 0 48 48"},child:[{tag:"path",attr:{fill:"#424242",d:"M24,4c-5.5,0-10,4.5-10,10v4h4v-4c0-3.3,2.7-6,6-6s6,2.7,6,6v4h4v-4C34,8.5,29.5,4,24,4z"}},{tag:"path",attr:{fill:"#FB8C00",d:"M36,44H12c-2.2,0-4-1.8-4-4V22c0-2.2,1.8-4,4-4h24c2.2,0,4,1.8,4,4v18C40,42.2,38.2,44,36,44z"}},{tag:"circle",attr:{fill:"#C76E00",cx:"24",cy:"31",r:"3"}}]})(t)}function Wxt(t){return C({tag:"svg",attr:{version:"1",viewBox:"0 0 48 48",enableBackground:"new 0 0 48 48"},child:[{tag:"path",attr:{fill:"#78909C",d:"M40,41H8c-2.2,0-4-1.8-4-4l0-20.9c0-1.3,0.6-2.5,1.7-3.3L24,0l18.3,12.8c1.1,0.7,1.7,2,1.7,3.3V37 C44,39.2,42.2,41,40,41z"}},{tag:"rect",attr:{x:"14",y:"1",fill:"#AED581",width:"20",height:"31"}},{tag:"g",attr:{fill:"#558B2F"},child:[{tag:"path",attr:{d:"M13,0v33h22V0H13z M33,31H15V2h18V31z"}},{tag:"path",attr:{d:"M34,3c0,1.7-0.3,3-2,3c-1.7,0-3-1.3-3-3s1.3-2,3-2C33.7,1,34,1.3,34,3z"}},{tag:"path",attr:{d:"M16,1c1.7,0,3,0.3,3,2s-1.3,3-3,3s-2-1.3-2-3S14.3,1,16,1z"}},{tag:"circle",attr:{cx:"24",cy:"8",r:"2"}},{tag:"circle",attr:{cx:"24",cy:"20",r:"6"}}]},{tag:"path",attr:{fill:"#CFD8DC",d:"M40,41H8c-2.2,0-4-1.8-4-4l0-20l20,13l20-13v20C44,39.2,42.2,41,40,41z"}}]})(t)}function jxt(t){return C({tag:"svg",attr:{version:"1",viewBox:"0 0 48 48",enableBackground:"new 0 0 48 48"},child:[{tag:"path",attr:{fill:"#CFD8DC",d:"M5,38V14h38v24c0,2.2-1.8,4-4,4H9C6.8,42,5,40.2,5,38z"}},{tag:"path",attr:{fill:"#F44336",d:"M43,10v6H5v-6c0-2.2,1.8-4,4-4h30C41.2,6,43,7.8,43,10z"}},{tag:"g",attr:{fill:"#B71C1C"},child:[{tag:"circle",attr:{cx:"33",cy:"10",r:"3"}},{tag:"circle",attr:{cx:"15",cy:"10",r:"3"}}]},{tag:"g",attr:{fill:"#B0BEC5"},child:[{tag:"path",attr:{d:"M33,3c-1.1,0-2,0.9-2,2v5c0,1.1,0.9,2,2,2s2-0.9,2-2V5C35,3.9,34.1,3,33,3z"}},{tag:"path",attr:{d:"M15,3c-1.1,0-2,0.9-2,2v5c0,1.1,0.9,2,2,2s2-0.9,2-2V5C17,3.9,16.1,3,15,3z"}}]},{tag:"g",attr:{fill:"#B0BEC5"},child:[{tag:"rect",attr:{x:"13",y:"21",width:"6",height:"6"}},{tag:"rect",attr:{x:"21",y:"21",width:"6",height:"6"}},{tag:"rect",attr:{x:"29",y:"21",width:"6",height:"6"}},{tag:"rect",attr:{x:"13",y:"29",width:"6",height:"6"}},{tag:"rect",attr:{x:"21",y:"29",width:"6",height:"6"}}]},{tag:"rect",attr:{x:"29",y:"29",fill:"#F44336",width:"6",height:"6"}}]})(t)}function Gxt(t){return C({tag:"svg",attr:{version:"1",viewBox:"0 0 48 48",enableBackground:"new 0 0 48 48"},child:[{tag:"circle",attr:{fill:"#FFB74D",cx:"24",cy:"11",r:"6"}},{tag:"path",attr:{fill:"#607D8B",d:"M36,26.1c0,0-3.3-7.1-12-7.1s-12,7.1-12,7.1V30h24V26.1z"}},{tag:"polygon",attr:{fill:"#B0BEC5",points:"41,25 7,25 6,29 11,32 9,29 39,29 37,32 42,29"}},{tag:"polygon",attr:{fill:"#78909C",points:"9,29 39,29 35,41 13,41"}}]})(t)}function Uxt(t){return C({tag:"svg",attr:{version:"1",viewBox:"0 0 48 48",enableBackground:"new 0 0 48 48"},child:[{tag:"g",attr:{fill:"#616161"},child:[{tag:"rect",attr:{x:"34.6",y:"28.1",transform:"matrix(.707 -.707 .707 .707 -15.154 36.586)",width:"4",height:"17"}},{tag:"circle",attr:{cx:"20",cy:"20",r:"16"}}]},{tag:"rect",attr:{x:"36.2",y:"32.1",transform:"matrix(.707 -.707 .707 .707 -15.839 38.239)",fill:"#37474F",width:"4",height:"12.3"}},{tag:"circle",attr:{fill:"#64B5F6",cx:"20",cy:"20",r:"13"}},{tag:"path",attr:{fill:"#BBDEFB",d:"M26.9,14.2c-1.7-2-4.2-3.2-6.9-3.2s-5.2,1.2-6.9,3.2c-0.4,0.4-0.3,1.1,0.1,1.4c0.4,0.4,1.1,0.3,1.4-0.1 C16,13.9,17.9,13,20,13s4,0.9,5.4,2.5c0.2,0.2,0.5,0.4,0.8,0.4c0.2,0,0.5-0.1,0.6-0.2C27.2,15.3,27.2,14.6,26.9,14.2z"}}]})(t)}function Yxt(t){return C({tag:"svg",attr:{version:"1",viewBox:"0 0 48 48",enableBackground:"new 0 0 48 48"},child:[{tag:"path",attr:{fill:"#1976D2",d:"M38.1,31.2L19.4,24l18.7-7.2c1.5-0.6,2.3-2.3,1.7-3.9c-0.6-1.5-2.3-2.3-3.9-1.7l-26,10C8.8,21.6,8,22.8,8,24 s0.8,2.4,1.9,2.8l26,10c0.4,0.1,0.7,0.2,1.1,0.2c1.2,0,2.3-0.7,2.8-1.9C40.4,33.5,39.6,31.8,38.1,31.2z"}},{tag:"g",attr:{fill:"#1E88E5"},child:[{tag:"circle",attr:{cx:"11",cy:"24",r:"7"}},{tag:"circle",attr:{cx:"37",cy:"14",r:"7"}},{tag:"circle",attr:{cx:"37",cy:"34",r:"7"}}]}]})(t)}function Xxt(t){return C({tag:"svg",attr:{version:"1",viewBox:"0 0 48 48",enableBackground:"new 0 0 48 48"},child:[{tag:"polygon",attr:{fill:"#90CAF9",points:"36.9,13.8 35.1,10.2 7.5,24 35.1,37.8 36.9,34.2 16.5,24"}},{tag:"rect",attr:{x:"6",y:"18",fill:"#D81B60",width:"12",height:"12"}},{tag:"g",attr:{fill:"#2196F3"},child:[{tag:"rect",attr:{x:"30",y:"6",width:"12",height:"12"}},{tag:"rect",attr:{x:"30",y:"30",width:"12",height:"12"}}]}]})(t)}const c0=Object.freeze(Object.defineProperty({__proto__:null,FcCalendar:Vxt,FcHighPriority:Fxt,FcHome:Rxt,FcKindle:Bxt,FcLibrary:Nxt,FcLock:$xt,FcMoneyTransfer:Wxt,FcPlanner:jxt,FcPodiumWithSpeaker:Gxt,FcSearch:Uxt,FcShare:Yxt,FcTreeStructure:Xxt},Symbol.toStringTag,{value:"Module"}));var dP={exports:{}},Kxt="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED",qxt=Kxt,Zxt=qxt;function fP(){}function vP(){}vP.resetWarningCache=fP;var Jxt=function(){function t(i,o,a,s,l,h){if(h!==Zxt){var p=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw p.name="Invariant Violation",p}}t.isRequired=t;function r(){return t}var n={array:t,bigint:t,bool:t,func:t,number:t,object:t,string:t,symbol:t,any:t,arrayOf:r,element:t,elementType:t,instanceOf:r,node:t,objectOf:r,oneOf:r,oneOfType:r,shape:r,exact:r,checkPropTypes:vP,resetWarningCache:fP};return n.PropTypes=n,n};dP.exports=Jxt();var gP=dP.exports;const B=_8(gP);function Du(t){"@babel/helpers - typeof";return Du=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(r){return typeof r}:function(r){return r&&typeof Symbol=="function"&&r.constructor===Symbol&&r!==Symbol.prototype?"symbol":typeof r},Du(t)}var Qxt;function Zx(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"",r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Qxt;return r?t.split(" ").map(function(n){return r[n]||n}).join(" "):t}var Lk={};function tbt(t){Lk[t]||(typeof console<"u"&&console.error(t),Lk[t]=!0)}function ebt(t,r){return function(i,o,a){i[o]!==null&&typeof i[o]<"u"&&tbt('"'.concat(o,'" property of "').concat(a,`" has been deprecated. -`).concat(r));for(var s=arguments.length,l=new Array(s>3?s-3:0),h=3;h"u"?"undefined":Du(window))==="object"&&window.Element||function(){};function ibt(t,r,n){if(!(t[r]instanceof rbt))return new Error("Invalid prop `"+r+"` supplied to `"+n+"`. Expected prop to be an instance of Element. Validation failed.")}B.oneOfType([B.string,B.func,ibt,B.shape({current:B.any})]);var mP=B.oneOfType([B.func,B.string,B.shape({$$typeof:B.symbol,render:B.func}),B.arrayOf(B.oneOfType([B.func,B.string,B.shape({$$typeof:B.symbol,render:B.func})]))]);function nbt(t){var r=Du(t);return t!=null&&(r==="object"||r==="function")}var obt=["className","cssModule","noGutters","tag","widths"];function tm(){return tm=Object.assign?Object.assign.bind():function(t){for(var r=1;r=0)&&Object.prototype.propertyIsEnumerable.call(t,i)&&(n[i]=t[i])}return n}function sbt(t,r){if(t==null)return{};var n={},i=Object.keys(t),o,a;for(a=0;a=0)&&(n[o]=t[o]);return n}var lbt=["xs","sm","md","lg","xl","xxl"],u3=B.oneOfType([B.number,B.string]),cbt={tag:mP,noGutters:ebt(B.bool,"Please use Bootstrap 5 gutter utility classes. https://getbootstrap.com/docs/5.0/layout/gutters/"),className:B.string,cssModule:B.object,xs:u3,sm:u3,md:u3,lg:u3,xl:u3,xxl:u3,widths:B.array};function Jx(t){var r=t.className,n=t.cssModule,i=t.noGutters,o=t.tag,a=o===void 0?"div":o,s=t.widths,l=s===void 0?lbt:s,h=abt(t,obt),p=[];l.forEach(function(g,b){var z=t[g];if(delete h[g],!!z){var M=!b;p.push(M?"row-cols-".concat(z):"row-cols-".concat(g,"-").concat(z))}});var f=Zx(wi(r,i?"gx-0":null,"row",p),n);return cr.createElement(a,tm({},h,{className:f}))}Jx.propTypes=cbt;var hbt=["className","cssModule","widths","tag"];function em(){return em=Object.assign?Object.assign.bind():function(t){for(var r=1;r=0)&&Object.prototype.propertyIsEnumerable.call(t,i)&&(n[i]=t[i])}return n}function pbt(t,r){if(t==null)return{};var n={},i=Object.keys(t),o,a;for(a=0;a=0)&&(n[o]=t[o]);return n}function Kf(t,r,n){return r in t?Object.defineProperty(t,r,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[r]=n,t}var yP=["xs","sm","md","lg","xl","xxl"],Ek=B.oneOfType([B.number,B.string]),p3=B.oneOfType([B.bool,B.number,B.string,B.shape({size:B.oneOfType([B.bool,B.number,B.string]),order:Ek,offset:Ek})]),dbt={tag:mP,xs:p3,sm:p3,md:p3,lg:p3,xl:p3,xxl:p3,className:B.string,cssModule:B.object,widths:B.array},Ik=function(r,n,i){return i===!0||i===""?r?"col":"col-".concat(n):i==="auto"?r?"col-auto":"col-".concat(n,"-auto"):r?"col-".concat(i):"col-".concat(n,"-").concat(i)},fbt=function(r,n){var i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:yP,o=r,a=[];return i.forEach(function(s,l){var h=o[s];if(delete o[s],!(!h&&h!=="")){var p=!l;if(nbt(h)){var f,g=p?"-":"-".concat(s,"-"),b=Ik(p,s,h.size);a.push(Zx(wi((f={},Kf(f,b,h.size||h.size===""),Kf(f,"order".concat(g).concat(h.order),h.order||h.order===0),Kf(f,"offset".concat(g).concat(h.offset),h.offset||h.offset===0),f)),n))}else{var z=Ik(p,s,h);a.push(z)}}}),{colClasses:a,modifiedAttributes:o}};function ip(t){var r=t.className,n=t.cssModule,i=t.widths,o=i===void 0?yP:i,a=t.tag,s=a===void 0?"div":a,l=ubt(t,hbt),h=fbt(l,n,o),p=h.modifiedAttributes,f=h.colClasses;f.length||f.push("col");var g=Zx(wi(r,f),n);return cr.createElement(s,em({},p,{className:g}))}ip.propTypes=dbt;function Qx(t,r){t.prototype=Object.create(r.prototype),t.prototype.constructor=t,ku(t,r)}function vbt(t,r){return t.classList?!!r&&t.classList.contains(r):(" "+(t.className.baseVal||t.className)+" ").indexOf(" "+r+" ")!==-1}function gbt(t,r){t.classList?t.classList.add(r):vbt(t,r)||(typeof t.className=="string"?t.className=t.className+" "+r:t.setAttribute("class",(t.className&&t.className.baseVal||"")+" "+r))}function Hk(t,r){return t.replace(new RegExp("(^|\\s)"+r+"(?:\\s|$)","g"),"$1").replace(/\s+/g," ").replace(/^\s*|\s*$/g,"")}function mbt(t,r){t.classList?t.classList.remove(r):typeof t.className=="string"?t.className=Hk(t.className,r):t.setAttribute("class",Hk(t.className&&t.className.baseVal||"",r))}const Dk={disabled:!1},Pu=cr.createContext(null);var xP=function(r){return r.scrollTop},tc="unmounted",Y4="exited",X4="entering",z3="entered",rm="exiting",ns=function(t){Qx(r,t);function r(i,o){var a;a=t.call(this,i,o)||this;var s=o,l=s&&!s.isMounting?i.enter:i.appear,h;return a.appearStatus=null,i.in?l?(h=Y4,a.appearStatus=X4):h=z3:i.unmountOnExit||i.mountOnEnter?h=tc:h=Y4,a.state={status:h},a.nextCallback=null,a}r.getDerivedStateFromProps=function(o,a){var s=o.in;return s&&a.status===tc?{status:Y4}:null};var n=r.prototype;return n.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},n.componentDidUpdate=function(o){var a=null;if(o!==this.props){var s=this.state.status;this.props.in?s!==X4&&s!==z3&&(a=X4):(s===X4||s===z3)&&(a=rm)}this.updateStatus(!1,a)},n.componentWillUnmount=function(){this.cancelNextCallback()},n.getTimeouts=function(){var o=this.props.timeout,a,s,l;return a=s=l=o,o!=null&&typeof o!="number"&&(a=o.exit,s=o.enter,l=o.appear!==void 0?o.appear:s),{exit:a,enter:s,appear:l}},n.updateStatus=function(o,a){if(o===void 0&&(o=!1),a!==null)if(this.cancelNextCallback(),a===X4){if(this.props.unmountOnExit||this.props.mountOnEnter){var s=this.props.nodeRef?this.props.nodeRef.current:Q6.findDOMNode(this);s&&xP(s)}this.performEnter(o)}else this.performExit();else this.props.unmountOnExit&&this.state.status===Y4&&this.setState({status:tc})},n.performEnter=function(o){var a=this,s=this.props.enter,l=this.context?this.context.isMounting:o,h=this.props.nodeRef?[l]:[Q6.findDOMNode(this),l],p=h[0],f=h[1],g=this.getTimeouts(),b=l?g.appear:g.enter;if(!o&&!s||Dk.disabled){this.safeSetState({status:z3},function(){a.props.onEntered(p)});return}this.props.onEnter(p,f),this.safeSetState({status:X4},function(){a.props.onEntering(p,f),a.onTransitionEnd(b,function(){a.safeSetState({status:z3},function(){a.props.onEntered(p,f)})})})},n.performExit=function(){var o=this,a=this.props.exit,s=this.getTimeouts(),l=this.props.nodeRef?void 0:Q6.findDOMNode(this);if(!a||Dk.disabled){this.safeSetState({status:Y4},function(){o.props.onExited(l)});return}this.props.onExit(l),this.safeSetState({status:rm},function(){o.props.onExiting(l),o.onTransitionEnd(s.exit,function(){o.safeSetState({status:Y4},function(){o.props.onExited(l)})})})},n.cancelNextCallback=function(){this.nextCallback!==null&&(this.nextCallback.cancel(),this.nextCallback=null)},n.safeSetState=function(o,a){a=this.setNextCallback(a),this.setState(o,a)},n.setNextCallback=function(o){var a=this,s=!0;return this.nextCallback=function(l){s&&(s=!1,a.nextCallback=null,o(l))},this.nextCallback.cancel=function(){s=!1},this.nextCallback},n.onTransitionEnd=function(o,a){this.setNextCallback(a);var s=this.props.nodeRef?this.props.nodeRef.current:Q6.findDOMNode(this),l=o==null&&!this.props.addEndListener;if(!s||l){setTimeout(this.nextCallback,0);return}if(this.props.addEndListener){var h=this.props.nodeRef?[this.nextCallback]:[s,this.nextCallback],p=h[0],f=h[1];this.props.addEndListener(p,f)}o!=null&&setTimeout(this.nextCallback,o)},n.render=function(){var o=this.state.status;if(o===tc)return null;var a=this.props,s=a.children;a.in,a.mountOnEnter,a.unmountOnExit,a.appear,a.enter,a.exit,a.timeout,a.addEndListener,a.onEnter,a.onEntering,a.onEntered,a.onExit,a.onExiting,a.onExited,a.nodeRef;var l=j9(a,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]);return cr.createElement(Pu.Provider,{value:null},typeof s=="function"?s(o,l):cr.cloneElement(cr.Children.only(s),l))},r}(cr.Component);ns.contextType=Pu;ns.propTypes={};function d3(){}ns.defaultProps={in:!1,mountOnEnter:!1,unmountOnExit:!1,appear:!1,enter:!0,exit:!0,onEnter:d3,onEntering:d3,onEntered:d3,onExit:d3,onExiting:d3,onExited:d3};ns.UNMOUNTED=tc;ns.EXITED=Y4;ns.ENTERING=X4;ns.ENTERED=z3;ns.EXITING=rm;const ybt=ns;var xbt=function(r,n){return r&&n&&n.split(" ").forEach(function(i){return gbt(r,i)})},qf=function(r,n){return r&&n&&n.split(" ").forEach(function(i){return mbt(r,i)})},tb=function(t){Qx(r,t);function r(){for(var i,o=arguments.length,a=new Array(o),s=0;s{var R,W,$,G,Z;const r=t.ImageList,{socket:n,fontScale:i,findCurrentData:o}=w1(),{Icon:a,Caption:s,Event:l,ImageIndex:h,CSS:p,ImageListObj:f}=t==null?void 0:t.Properties,g=j1(p),b=o(t.FontObj&&t.FontObj),z=b&&(b==null?void 0:b.Properties),M=o(f),I=gD(M,h),F=()=>{const K=JSON.stringify({Event:{EventName:"Select",ID:t==null?void 0:t.ID}});l&&l.some(at=>at[0]==="Select")&&(console.log(K),n.send(K))},H=()=>{F()},E=c0[a]?c0[a]:ib;return vt.jsx("div",{style:{display:"flex",alignItems:"flex-start",height:"100%",marginTop:"5px"},children:vt.jsx(Jx,{children:vt.jsx(ip,{children:vt.jsxs("div",{id:t==null?void 0:t.ID,className:"d-flex align-items-center flex-column justify-content-center",onClick:H,style:{cursor:"pointer",...g},children:[I?vt.jsx("img",{style:{width:I.imageSize[1],height:I.imageSize[0]},src:`${Qi()}${I.imageUrl}`,alt:"Image"}):h?vt.jsx("img",{style:{width:((R=r==null?void 0:r.Properties)==null?void 0:R.Size)&&((W=r==null?void 0:r.Properties)==null?void 0:W.Size[1]),height:(($=r==null?void 0:r.Properties)==null?void 0:$.Size)&&((G=r==null?void 0:r.Properties)==null?void 0:G.Size[0])},src:`${Qi()}${(Z=r==null?void 0:r.Properties)==null?void 0:Z.Files[h-1]}`,alt:"Image"}):vt.jsx(E,{size:35}),vt.jsx("div",{className:"text-center",style:{fontFamily:z==null?void 0:z.PName,fontSize:z!=null&&z.Size?`${z.Size*i}px`:`${12*i}px`},children:s})]})})})})},Abt=({data:t})=>{const{socket:r,dataRef:n,findCurrentData:i,fontScale:o}=w1();let a=t.ImageList;const{Captions:s,Icons:l,Event:h,ImageIndex:p,ImageListObj:f,CSS:g}=t==null?void 0:t.Properties;console.log("Values reendered arw",s);const b=j1(g),z=i(t.FontObj&&t.FontObj),M=z&&(z==null?void 0:z.Properties),I=12,F=W=>{const $=JSON.stringify({Event:{EventName:"Select",ID:t==null?void 0:t.ID,Info:[W]}});h&&h.some(Z=>Z[0]==="Select")&&(console.log($),r.send($))},H=W=>{F(W)};let E;if(f)if(Array.isArray(f))E=f==null?void 0:f.map(W=>W&&JSON.parse(Ui(n.current,W)));else{const W=f.split(".")[1];a=W&&JSON.parse(Ui(n.current,W))}function R(W){var tt,ft,dt,ht,lt,yt;if(!E||!E.length)return;const $=(ft=(tt=t==null?void 0:t.Properties)==null?void 0:tt.Captions)==null?void 0:ft.indexOf(W);if($===-1)return null;const G=(dt=t==null?void 0:t.Properties)==null?void 0:dt.ImageListObj[$],Z=(ht=t==null?void 0:t.Properties)==null?void 0:ht.ImageIndex[$],K=E==null?void 0:E.find(mt=>(mt==null?void 0:mt.ID)===G);if(!K)return null;const et=(lt=K==null?void 0:K.Properties)==null?void 0:lt.Files[Z-1],at=(yt=K==null?void 0:K.Properties)==null?void 0:yt.Size;return{caption:W,imgIndex:Z,imgUrl:et,imgSize:at}}return vt.jsx("div",{className:"d-flex flex-column align-items-center justify-content-center ",style:{width:"fit-content"},children:s.map((W,$)=>{var tt,ft,dt,ht,lt,yt;const G=R(W),Z=$,K=G&&G.imgUrl?G.imgUrl:(E==null?void 0:E[Z])||a,et=(l==null?void 0:l[$])||"MdOutlineQuestionMark",at=(c0==null?void 0:c0[et])||ib;return vt.jsxs(ip,{id:`${t==null?void 0:t.ID}-${$}`,md:I,className:"d-flex align-items-center justify-content-left gap-1",style:{cursor:"pointer",...b},onClick:()=>H($+1),children:[G&&(G!=null&&G.imgUrl)?vt.jsx("img",{style:{width:G.imgSize[0],height:G.imgSize[1]},src:`${Qi()}${G.imgUrl}`,alt:W}):K?vt.jsx("img",{style:{width:(ft=(tt=a==null?void 0:a.Properties)==null?void 0:tt.Size)==null?void 0:ft[1],height:(ht=(dt=a==null?void 0:a.Properties)==null?void 0:dt.Size)==null?void 0:ht[0]},src:`${Qi()}${(yt=(lt=K==null?void 0:K.Properties)==null?void 0:lt.Files)==null?void 0:yt[Z]}`,alt:W}):vt.jsx(at,{size:25}),vt.jsx("div",{style:{textAlign:"left",textOverflow:"ellipsis",fontFamily:M==null?void 0:M.PName,fontSize:M!=null&&M.Size?`${M.Size*o}px`:`${12*o}px`},children:W})]},`col-${$}`)})})},Lbt=({data:t})=>{const{FCol:r,FillCol:n,LWidth:i,Points:o,FStyle:a,Visible:s,Event:l,CSS:h}=t==null?void 0:t.Properties,{socket:p}=w1(),f=j1(h),g=Yr(t.Properties),b=JSON.parse(localStorage.getItem("formDimension")),z=t==null?void 0:t.Properties.hasOwnProperty("FCol");return vt.jsx("div",{id:t==null?void 0:t.ID,style:{position:"absolute",display:s==0?"none":"block",...g,...f},onMouseDown:M=>{er(M,p,l,t==null?void 0:t.ID)},onMouseUp:M=>{rr(M,p,l,t==null?void 0:t.ID)},onMouseEnter:M=>{ir(M,p,l,t==null?void 0:t.ID)},onMouseMove:M=>{or(M,p,l,t==null?void 0:t.ID)},onMouseLeave:M=>{nr(M,p,l,t==null?void 0:t.ID)},onWheel:M=>{hr(M,p,l,t==null?void 0:t.ID)},onDoubleClick:M=>{mr(M,p,l,t==null?void 0:t.ID)},children:vt.jsx("svg",{height:b&&b[0],width:b&&b[1],children:o==null?void 0:o.map((M,I)=>{const F=M&&M[0].map((H,E)=>[M[1][E],H]);return vt.jsx("polygon",{id:I,points:F&&F.flat().join(" "),fill:a&&a[I]=="-1"?"none":n&&Hr(n[I]),stroke:z?r&&Hr(r[I]):"rgb(0,0,0)","stroke-width":i&&i[I]},I)})})})};var Ebt={en:{name:"en",identity:{version:{_unicodeVersion:"14.0.0",_cldrVersion:"41"},language:"en"},territory:"US",numbers:{symbols:{decimal:".",group:",",list:";",percentSign:"%",plusSign:"+",minusSign:"-",exponential:"E",superscriptingExponent:"×",perMille:"‰",infinity:"∞",nan:"NaN",timeSeparator:":",approximatelySign:"~"},decimal:{patterns:["n"],groupSize:[3]},scientific:{patterns:["nEn"],groupSize:[]},percent:{patterns:["n%"],groupSize:[3]},currency:{patterns:["$n"],groupSize:[3],"unitPattern-count-one":"n $","unitPattern-count-other":"n $"},currencies:{BGN:{displayName:"Bulgarian Lev","displayName-count-one":"Bulgarian lev","displayName-count-other":"Bulgarian leva",symbol:"BGN"},EUR:{displayName:"Euro","displayName-count-one":"euro","displayName-count-other":"euros",symbol:"€","symbol-alt-narrow":"€"},USD:{displayName:"US Dollar","displayName-count-one":"US dollar","displayName-count-other":"US dollars",symbol:"$","symbol-alt-narrow":"$"}},localeCurrency:"USD",accounting:{patterns:["$n","($n)"],groupSize:[3]}},calendar:{gmtFormat:"GMT{0}",gmtZeroFormat:"GMT",patterns:{d:"M/d/y",D:"EEEE, MMMM d, y",m:"MMM d",M:"MMMM d",y:"MMM y",Y:"MMMM y",F:"EEEE, MMMM d, y h:mm:ss a",g:"M/d/y h:mm a",G:"M/d/y h:mm:ss a",t:"h:mm a",T:"h:mm:ss a",s:"yyyy'-'MM'-'dd'T'HH':'mm':'ss",u:"yyyy'-'MM'-'dd HH':'mm':'ss'Z'"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{Bh:"h B",Bhm:"h:mm B",Bhms:"h:mm:ss B",d:"d",E:"ccc",EBhm:"E h:mm B",EBhms:"E h:mm:ss B",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMd:"M/d/y GGGGG",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",hmsv:"h:mm:ss a v",Hmsv:"HH:mm:ss v",hmv:"h:mm a v",Hmv:"HH:mm v",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d","MMMMW-count-one":"'week' W 'of' MMMM","MMMMW-count-other":"'week' W 'of' MMMM",ms:"mm:ss",y:"y",yM:"M/y",yMd:"M/d/y",yMEd:"E, M/d/y",yMMM:"MMM y",yMMMd:"MMM d, y",yMMMEd:"E, MMM d, y",yMMMM:"MMMM y",yQQQ:"QQQ y",yQQQQ:"QQQQ y","yw-count-one":"'week' w 'of' Y","yw-count-other":"'week' w 'of' Y"}},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateFormats:{full:"EEEE, MMMM d, y",long:"MMMM d, y",medium:"MMM d, y",short:"M/d/yy"},days:{format:{abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},"stand-alone":{abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]}},months:{format:{abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},"stand-alone":{abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]}},quarters:{format:{abbreviated:["Q1","Q2","Q3","Q4"],narrow:["1","2","3","4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},"stand-alone":{abbreviated:["Q1","Q2","Q3","Q4"],narrow:["1","2","3","4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]}},dayPeriods:{format:{abbreviated:{midnight:"midnight",am:"AM","am-alt-variant":"am",noon:"noon",pm:"PM","pm-alt-variant":"pm",morning1:"in the morning",afternoon1:"in the afternoon",evening1:"in the evening",night1:"at night"},narrow:{midnight:"mi",am:"a","am-alt-variant":"am",noon:"n",pm:"p","pm-alt-variant":"pm",morning1:"in the morning",afternoon1:"in the afternoon",evening1:"in the evening",night1:"at night"},wide:{midnight:"midnight",am:"AM","am-alt-variant":"am",noon:"noon",pm:"PM","pm-alt-variant":"pm",morning1:"in the morning",afternoon1:"in the afternoon",evening1:"in the evening",night1:"at night"}},"stand-alone":{abbreviated:{midnight:"midnight",am:"AM","am-alt-variant":"am",noon:"noon",pm:"PM","pm-alt-variant":"pm",morning1:"morning",afternoon1:"afternoon",evening1:"evening",night1:"night"},narrow:{midnight:"midnight",am:"AM","am-alt-variant":"am",noon:"noon",pm:"PM","pm-alt-variant":"pm",morning1:"morning",afternoon1:"afternoon",evening1:"evening",night1:"night"},wide:{midnight:"midnight",am:"AM","am-alt-variant":"am",noon:"noon",pm:"PM","pm-alt-variant":"pm",morning1:"morning",afternoon1:"afternoon",evening1:"evening",night1:"night"}}},eras:{format:{wide:{0:"Before Christ",1:"Anno Domini","0-alt-variant":"Before Common Era","1-alt-variant":"Common Era"},abbreviated:{0:"BC",1:"AD","0-alt-variant":"BCE","1-alt-variant":"CE"},narrow:{0:"B",1:"A","0-alt-variant":"BCE","1-alt-variant":"CE"}}},dateFields:{era:{wide:"era",short:"era",narrow:"era"},year:{wide:"year",short:"yr.",narrow:"yr."},quarter:{wide:"quarter",short:"qtr.",narrow:"qtr."},month:{wide:"month",short:"mo.",narrow:"mo."},week:{wide:"week",short:"wk.",narrow:"wk."},weekOfMonth:{wide:"week of month",short:"wk. of mo.",narrow:"wk. of mo."},day:{wide:"day",short:"day",narrow:"day"},dayOfYear:{wide:"day of year",short:"day of yr.",narrow:"day of yr."},weekday:{wide:"day of the week",short:"day of wk.",narrow:"day of wk."},weekdayOfMonth:{wide:"weekday of the month",short:"wkday. of mo.",narrow:"wkday. of mo."},dayperiod:{short:"AM/PM",wide:"AM/PM",narrow:"AM/PM"},hour:{wide:"hour",short:"hr.",narrow:"hr."},minute:{wide:"minute",short:"min.",narrow:"min."},second:{wide:"second",short:"sec.",narrow:"sec."},zone:{wide:"time zone",short:"zone",narrow:"zone"},millisecond:{narrow:"ms",short:"ms",wide:"millisecond"}}}},supplemental:{likelySubtags:{en:"en-Latn-US"},currencyData:{region:{US:[{USD:{_from:"1792-01-01"}}]}},weekData:{firstDay:{US:"sun"},weekendStart:{"001":"sat"},weekendEnd:{"001":"sun"}}}};function np(t){return typeof t=="string"}const Ibt={NoLocale:"Missing locale info for '{0}'",NoCurrency:"Cannot determine currency information. Please load the locale currencies data.",NoSupplementalCurrency:"Cannot determine currency. Please load the supplemental currencyData.",NoCurrencyRegion:"No currency data for region '{0}'",NoCurrencyDisplay:"Cannot determine currency display information. Please load the locale currencies data. The default culture does not include the all currencies data.",NoGMTInfo:"Cannot determine locale GMT format. Please load the locale timeZoneNames data.",NoWeekData:"Cannot determine locale first day of week. Please load the supplemental weekData.",NoFirstDay:"Cannot determine locale first day of week. Please load the supplemental weekData. The default culture includes only the 'en-US' first day info.",NoValidCurrency:"Cannot determine a default currency for the {0} locale. Please specify explicitly the currency with the format options.",NoDateFieldNames:"Cannot determine the locale date field names. Please load the locale dateFields data."};var Hbt=/\{(\d+)}?\}/g,nb=function(r){var n=r.name,i=r.message;if(!n||!i)throw new Error("{ name: string, message: string } object is required!");this.name=n,this.message=i};nb.prototype.formatMessage=function(){for(var r=[],n=arguments.length;n--;)r[n]=arguments[n];var i=Dbt(r),o=this.message.replace(Hbt,function(a,s){return i[parseInt(s,10)]});return this.name+": "+o};nb.prototype.error=function(){for(var r=[],n=arguments.length;n--;)r[n]=arguments[n];return new Error(this.formatMessage(r))};var Dbt=function(t){return t.reduce(function(r,n){return r.concat(n)},[])},Pbt=function(t){var r=function(n,i){return n[i]=new nb({name:i,message:t[i]}),n};return Object.keys(t).reduce(r,{})},So=Pbt(Ibt);function Tbt(t,r){var n=t.split("-"),i=n[0],o=n[1],a=n[2];return V2[t]||r.indexOf(a)!==-1&&V2[i+"-"+a]||r.indexOf(o)!==-1&&V2[i+"-"+o]||V2[i]}function Vbt(t,r){for(var n=V2.supplemental.likelySubtags,i=0;i=1;a--){var s=i[a];(s===r.variant||s===r.script)&&i.splice(a,1)}var l=i.length;if(l>1){var h=i[l-1];return h.toUpperCase()}}function SP(t){if(t.territory)return t.territory;var r=t.name,n=t.identity,i;return n&&n.territory?i=n.territory:i=Obt(r,n),t.territory=i,i}function Bbt(t,r){r===void 0&&(r=$l);var n=x4(r),i=n.calendar.dateFields;if(!i)throw So.NoDateFieldNames.error();var o=i[t.type]||{};return o[t.nameType]||o.wide}function Nbt(t){for(var r=[],n=0;n"u"||n!==1?s=a["displayName-count-other"]:s=a["displayName-count-one"],s}function twt(t){var r=Pk,n=Pk,i=((V2.supplemental.currencyData||{}).fractions||{})[t];return i&&i._digits&&(n=r=parseInt(i._digits,10)),{minimumFractionDigits:r,maximumFractionDigits:n}}function ewt(t,r){if(r===void 0&&(r=!0),Tk[t])return Tk[t];var n=V2.supplemental.currencyData;if(!n){if(r)throw Ubt.error();return}var i=n.region[t];if(!i){if(r)throw Ybt.error(t);return}var o=Zbt(i);return o}function ab(t,r){var n=V8(t),i=n.numbers;if(!i.localeCurrency){var o=ewt(SP(n),r);if(!o&&r)throw Xbt.error(n.name);i.localeCurrency=o}return i.localeCurrency}var rwt=["sun","mon","tue","wed","thu","fri","sat"],iwt="001",nwt=So.NoWeekData,owt=So.NoFirstDay;function kP(t){var r=V8(t);if(!isNaN(r.firstDay))return r.firstDay;var n=V2.supplemental.weekData;if(!n)throw nwt.error();var i=n.firstDay[SP(r)]||n.firstDay[iwt];if(!i)throw owt.error();return r.firstDay=rwt.indexOf(i),r.firstDay}So.NoWeekData;function awt(t){var r=V8(t);return r.numbers.symbols}function _P(t){return 1/t===-1/0}function AP(t,r){r===void 0&&(r={}),r.currency||(r.currency=ab(t,!0));var n=Qbt(t,r);return n}function LP(t,r,n,i,o){var a=o.numbers.symbols,s=t.indexOf(a.decimal),l=i.groupSize.slice(),h=l.shift(),p=s!==-1?s:n+1,f=t.substring(r,p),g=t,b=f.length;if(b>=h){for(var z=b,M=[];z>-1;){var I=f.substring(z-h,z);I&&M.push(I),z-=h;var F=l.shift();if(h=F!==void 0?F:h,h===0){I=f.substring(0,z),I&&M.push(I);break}}f=M.reverse().join(a.group),g=t.substring(0,r)+f+t.substring(p)}return g}function sb(t){return t===op||t===wP}function yn(t,r,n){r===void 0&&(r=2),n===void 0&&(n=!1);var i=r-String(t).length,o=t;if(i>0){var a=new Array(i+1).join("0");o=n?t+a:a+t}return o}var swt=20;function Ic(t,r){var n=t,i=r||0;return n=n.toString().split("e"),n=Math.round(+(n[0]+"e"+(n[1]?Number(n[1])+i:i))),n=n.toString().split("e"),n=+(n[0]+"e"+(n[1]?Number(n[1])-i:-i)),n.toFixed(Math.min(i,swt))}var lwt=3,cwt=0,hwt=/0+$/;function uwt(t){var r=t.minimumFractionDigits,n=t.maximumFractionDigits,i=t.style,o=sb(i),a;return o&&(a=twt(t.currency)),r===void 0&&(r=o?a.minimumFractionDigits:0),n===void 0&&(i===Nl?n=Math.max(r,cwt):o?n=Math.max(r,a.maximumFractionDigits):n=Math.max(r,lwt)),{minimumFractionDigits:r,maximumFractionDigits:n}}function pwt(t,r,n){for(var i=V1,o=0,a=r.length;o-1||r.indexOf('"')>-1||r.indexOf("\\")>-1){var n=t.literals=[];t.format=r.replace(vwt,function(i){var o=i.charAt(0).replace("\\",V1),a=i.slice(1).replace(o,V1);return n.push(a),EP})}}function gwt(t,r){var n=t;if(r)for(var i=r.length,o=0;o-1,l=a>-1,h=r.toString().split("e");h[1]?h=Ic(r,Math.abs(h[1])):h=h[0],h=h.split(n4)[1]||V1;var p=h.length,f=-1;!s&&!l?(t.format=n.substring(0,i)+n.substring(i+1),i=-1,p=0):s&&o>a?p=o:a>o&&(l&&p>a?p=a:s&&p-1&&(r=Ic(r,p),f>-1&&(r=bwt(r,f)))}else r=Ic(r);t.negative&&r*-1>=0&&!t.negativeZero&&(t.negative=!1),t.number=r,t.decimalIndex=i}function Cwt(t){return t.indexOf(o8)===-1&&t.indexOf(a8)===-1}function Swt(t){var r=t.number,n=t.format;if(n=n.split(Fbt),(t.negative||t.negativeZero)&&n[1])n=n[1],t.hasNegativeFormat=!0;else if(r===0){var i=n[2];n=i||n[0],i&&Cwt(i)&&(t.constant=i)}else n=n[0];t.format=n}function zwt(t){t.hasGroup=t.format.indexOf(Rbt)>-1,t.hasGroup&&(t.format=t.format.replace(xwt,V1))}function Vk(t,r,n){var i;return t===-1&&r!==-1?i=r:t!==-1&&r===-1?i=t:i=n?Math.min(t,r):Math.max(t,r),i}function Mwt(t){var r=t.format,n=r.indexOf(o8),i=r.indexOf(a8),o=Vk(n,i,!0);n=r.lastIndexOf(o8),i=r.lastIndexOf(a8);var a=Vk(n,i);o===r.length&&(a=o),t.start=o,t.end=a,t.lastZeroIndex=i}function kwt(t,r,n){var i=t;if(r===op||r===Nl){i=V1;for(var o=0,a=t.length;o-1&&(g+=M,E=l),l===E){g+=(I?r.numbers.symbols.decimal:V1)+I,E+=i-l+1;continue}R===a8?(g+=R,H=R):R===o8&&(g+=H)}return f&&(g=LP(g,n+(o&&!p?1:0),Math.max(i,F+n),r.numbers.decimal,r)),i>=n&&(g+=s.substring(i+1)),g}function Awt(t,r){var n=t.number;return t.start!==-1&&(n=_wt(t,r),n=kwt(n,t.style,t.symbol),n=gwt(n,t.literals)),n}function Lwt(t,r,n){var i={negative:t<0,number:Math.abs(t),negativeZero:_P(t),format:r};return Swt(i),i.constant?i.constant:(HP(i),IP(i,n),zwt(i),wwt(i),Mwt(i),Awt(i,n))}var Ewt=/^(n|c|p|e|a)(\d*)$/i;function Iwt(t){var r=Ewt.exec(t);if(r){var n={style:bP},i=r[1].toLowerCase();return i==="c"?n.style=op:i==="a"?n.style=wP:i==="p"?n.style=Nl:i==="e"&&(n.style=CP),r[2]&&(n.minimumFractionDigits=n.maximumFractionDigits=parseInt(r[2],10)),n}}function DP(t){var r;return np(t)?r=Iwt(t):r=t,r}function PP(t,r,n){if(r===void 0&&(r=yl),n===void 0&&(n=$l),t==null)return V1;if(!isFinite(t))return String(t);var i=x4(n),o=DP(r),a;if(o){var s=o.style||bP;a=fwt(t,Object.assign({},i.numbers[s],o),i)}else a=Lwt(t,r,i);return a}function lb(t){return typeof t=="number"}var Hwt=/[eE][-+]?[0-9]+/,Fk=/\u00A0/g;function Rk(t,r){if(r.length>1){var n=(r[1]||V1).replace(ap,V1).split(yl);if(t.indexOf(n[0])>-1&&t.indexOf(n[1])>-1)return t.replace(n[0],V1).replace(n[1],V1)}}function Dwt(t,r,n){var i=DP(n)||{},o=sb(i.style),a=t,s,l=i.currency||ab(r,o);if(l){var h=Jbt(r,l,o);if(h)for(var p=0;p-1)&&(a=a.replace(o.percentSign,V1),l=!0),Hwt.test(a))return a=parseFloat(a.replace(o.decimal,n4)),isNaN(a)?null:a;var h=Dwt(a,i,s),p=h.negative,f=h.number;a=String(f).trim();var g=a.indexOf("-");if(g>0)return null;var b=g>-1;return b=p!==void 0?p:b,a=a.replace("-",V1).replace(Fk," ").split(o.group.replace(Fk," ")).join(V1).replace(o.decimal,n4),a=parseFloat(a),isNaN(a)?a=null:b&&(a*=-1),a&&l&&(a=Twt(a)),a}var Fwt=/\{(\d+)}/g;function cb(t){var r=arguments;return t.replace(Fwt,function(n,i){var o=r[parseInt(i,10)+1];return o})}var Rwt=120,Owt=20,Ok=[2,1,5,3,4],Bwt=-2,Nwt=-1,$wt=1,Wwt=2,F8={};F8[Bwt.toString()]=8;F8[Nwt.toString()]=6;F8[Wwt.toString()]=6;F8[$wt.toString()]=3;var jwt={numeric:1,"2-digit":2,short:3,long:4,narrow:5},Gwt=/[hHmsSzZoOvVxX]/;function Uwt(t){return t.hour12?"h":"H"}var Bk=[{key:"era",specifier:"G"},{key:"year",specifier:"y"},{key:"month",specifier:"M"},{key:"day",specifier:"d"},{key:"weekday",specifier:"E"},{key:"hour",getSpecifier:Uwt},{key:"minute",specifier:"m"},{key:"second",specifier:"s"},{key:"timeZoneName",specifier:"z"}],Nk={e:"c",E:"c",M:"L",Q:"q"},Qf={},ol={};function tv(t){return Qf[t]||(Qf[t]=new RegExp(t+"+")),Qf[t]}function b7(t){for(var r=[],n=t.charAt(0),i=n,o=1;oi&&(i=p,o=l,a=r[s])}a=a.replace("v","z");for(var I=0;I0){var a=t.substr(0,i),s=t.substr(i);o=cb(r.calendar.dateTimeFormats.short,n[s]||ev(b7(s),n),n[a]||ev(b7(a),n))}else o=ev(b7(t),n);return Ywt(t,o,r.name),o}function Kwt(t){for(var r=[],n=0;n3,localizedName:r===4,zZeroOffset:r===5})};Br.x=function(t,r,n){return sp(t,n,{optionalMinutes:r===1,separator:r===3||r===5})};Br.X=function(t,r,n){return sp(t,n,{optionalMinutes:r===1,separator:r===3||r===5,zZeroOffset:!0})};Br.G=function(t,r,n){var i=t.getFullYear()>=0?1:0;return zo(n,"eras",r)[i]};Br.e=RP;Br.c=function(t,r,n){return RP(t,r,n,!0)};Br.q=function(t,r,n){return FP(t,r,n,!0)};Br.Q=FP;function OP(t,r,n){if(n===void 0&&(n=$l),!ub(t))return t??V1;var i=x4(n),o=hb(r,i);return o.replace(ec,function(a){var s=a.length,l;return a.includes("'")||a.includes('"')?l=a.slice(1,s-1):l=Br[a[0]](t,s,i),l})}function Gk(t,r,n){var i=t.getTimezoneOffset(),o=new Date(t.getTime()+(r-n)*6e4),a=o.getTimezoneOffset();return new Date(o.getTime()+(a-i)*6e4)}function Jwt(t,r){!r&&t.getHours()===23&&t.setHours(t.getHours()+2)}var Qwt=/([+|-]\d{1,2})(:?)(\d{2})?/,tCt=/^\/Date\((.*?)\)\/$/,eCt=/[+-]\d*/,rCt={2:/^\d{1,2}/,3:/^\d{1,3}/,4:/^\d{4}/},iCt=/\d+/,Uk="{0}",nCt=/^ */,oCt=/ *$/,aCt=["yyyy/MM/dd HH:mm:ss","yyyy/MM/dd HH:mm","yyyy/MM/dd","E MMM dd yyyy HH:mm:ss","yyyy-MM-ddTHH:mm:ss.SSSSSSSXXX","yyyy-MM-ddTHH:mm:ss.SSSXXX","yyyy-MM-ddTHH:mm:ss.SSXXX","yyyy-MM-ddTHH:mm:ssXXX","yyyy-MM-ddTHH:mm:ss.SSSSSSS","yyyy-MM-ddTHH:mm:ss.SSS","yyyy-MM-ddTHH:mmXXX","yyyy-MM-ddTHH:mmX","yyyy-MM-ddTHH:mm:ss","yyyy-MM-ddTHH:mm","yyyy-MM-dd HH:mm:ss","yyyy-MM-dd HH:mm","yyyy-MM-dd","HH:mm:ss","HH:mm"],Yk=["G","g","F","Y","y","M","m","D","d","y","T","t"],sCt=2029;function G2(t,r,n){return!(t>=r&&t<=n)}function ki(t,r){for(var n=r.format,i=r.idx,o=0;n[i]===t;)o++,i++;return o>0&&(i-=1),r.idx=i,o}function ia(t,r){var n=t?rCt[t]||new RegExp("^\\d{1,"+t+"}"):iCt,i=r.value.substr(r.valueIdx,t).match(n);return i?(i=i[0],r.valueIdx+=i.length,parseInt(i,10)):null}function z0(t,r,n){for(var i=0,o=t.length,a,s,l=0,h=0,p;il&&(l=s,h=i);return l?(r.valueIdx+=l,h+1):null}function iv(t){var r=!1;return t.value.charAt(t.valueIdx)===t.format[t.idx]&&(t.valueIdx++,r=!0),r}function lCt(t){var r=t.gmtFormat,n=t.gmtZeroFormat;if(!r)throw So.NoGMTInfo.error();return[r.replace(Uk,V1).toLowerCase(),n.replace(Uk,V1).toLowerCase()]}function lp(t,r,n){var i=n.shortHours,o=n.noSeparator,a=n.optionalMinutes,s=n.localizedName,l=n.zLiteral;if(t.UTC=!0,l&&t.value.charAt(t.valueIdx)==="Z")return t.valueIdx++,!1;if(s&&!z0(lCt(r.calendar),t,!0))return!0;var h=Qwt.exec(t.value.substr(t.valueIdx,6));if(!h)return!s;var p=h[1],f=h[3],g=parseInt(p,10),b=h[2],z=parseInt(f,10);if(isNaN(g)||!i&&p.length!==3||!a&&isNaN(z)||o&&b||(isNaN(z)&&(z=null),G2(g,-12,13)||z&&G2(z,0,59)))return!0;t.valueIdx+=h[0].length,t.hoursOffset=g,t.minutesOffset=z}function BP(t,r,n){var i=ki(t,r),o=zo(n,"months",i,t==="L",!0),a=i<3?ia(2,r):z0(o,r,!0);if(a===null||G2(a,1,12))return!0;r.month=a-1}function NP(t,r,n){var i=ki(t,r),o=zo(n,"days",i,t==="c",!0),a=i<3?ia(1,r):z0(o,r,!0);if(!a&&a!==0||G2(a,1,7))return!0}var Ur={};Ur.d=function(t){ki("d",t);var r=ia(2,t);if(r===null||G2(r,1,31))return!0;t.day===null&&(t.day=r)};Ur.E=function(t,r){var n=ki("E",t),i=z0(zo(r,"days",n,!1,!0),t,!0);if(i===null)return!0};Ur.M=function(t,r){return BP("M",t,r)};Ur.L=function(t,r){return BP("L",t,r)};Ur.y=function(t){var r=ki("y",t),n=ia(r===1?void 0:r,t);if(n===null)return!0;if(r===2){var i=new Date().getFullYear();n=i-i%100+n,n>sCt&&(n-=100)}t.year=n};Ur.h=function(t){ki("h",t);var r=ia(2,t);if(r===12&&(r=0),r===null||G2(r,0,11))return!0;t.hours=r};Ur.K=function(t){ki("K",t);var r=ia(2,t);if(r===null||G2(r,0,11))return!0;t.hours=r};Ur.a=function(t,r){var n=ki("a",t),i=zo(r,"dayPeriods",n,!1,!0),o=z0([i.pm],t,!0);if(!o&&!z0([i.am],t,!0))return!0;t.pmHour=o};Ur.H=function(t){ki("H",t);var r=ia(2,t);if(r===null||G2(r,0,23))return!0;t.hours=r};Ur.k=function(t){ki("k",t);var r=ia(2,t);if(r===null||G2(r,1,24))return!0;t.hours=r===24?0:r};Ur.m=function(t){ki("m",t);var r=ia(2,t);if(r===null||G2(r,0,59))return!0;t.minutes=r};Ur.s=function(t){ki("s",t);var r=ia(2,t);if(r===null||G2(r,0,59))return!0;t.seconds=r};Ur.S=function(t){var r=ki("S",t),n=t.value.substr(t.valueIdx,r),i=null;if(isNaN(parseInt(n,10))||(i=parseFloat("0."+n,10),i=Ic(i,3),i*=1e3,t.valueIdx+=r),i===null||G2(i,0,999))return!0;t.milliseconds=i};Ur.z=function(t,r){var n=ki("z",t),i=n<4,o=lp(t,r,{shortHours:i,optionalMinutes:i,localizedName:!0});if(o)return o};Ur.Z=function(t,r){var n=ki("Z",t),i=lp(t,r,{noSeparator:n<4,zLiteral:n===5,localizedName:n===4});if(i)return i};Ur.x=function(t,r){var n=ki("x",t),i=lp(t,r,{noSeparator:n!==3&&n!==5,optionalMinutes:n===1});if(i)return i};Ur.X=function(t,r){var n=ki("X",t),i=lp(t,r,{noSeparator:n!==3&&n!==5,optionalMinutes:n===1,zLiteral:!0});if(i)return i};Ur.G=function(t,r){var n=ki("G",t),i=zo(r,"eras",n,!1,!0),o=z0([i[0],i[1]],t,!0);if(o===null)return!0};Ur.e=function(t,r){return NP("e",t,r)};Ur.c=function(t,r){return NP("c",t,r)};function cCt(t){var r=t.year,n=t.month,i=t.day,o=t.hours,a=t.minutes,s=t.seconds,l=t.milliseconds,h=t.pmHour,p=t.UTC,f=t.hoursOffset,g=t.minutesOffset,b=o!==null||a!==null||s||null,z=new Date,M;return r===null&&n===null&&i===null&&b?(r=z.getFullYear(),n=z.getMonth(),i=z.getDate()):(r===null&&(r=z.getFullYear()),i===null&&(i=1)),h&&o<12&&(o+=12),p?(f&&(o+=-f),g&&(a+=-g*(f<0?-1:1)),M=new Date(Date.UTC(r,n,i,o,a,s,l))):(M=new Date(r,n,i,o,a,s,l),Jwt(M,o)),r<100&&M.setFullYear(r),M.getDate()!==i&&p===void 0?null:M}function hCt(t,r){var n=nCt.exec(r)[0],i=oCt.exec(r)[0];return""+n+t+i}function uCt(t,r,n){for(var i=hb(r,n).split(V1),o={format:i,idx:0,value:hCt(t,r),valueIdx:0,year:null,month:null,day:null,hours:null,minutes:null,seconds:null,milliseconds:null},a=i.length,s=!1;o.idx=b&&(f.names={type:g.type,nameType:TP(z),standAlone:g.standAlone===h})}o.push(f)}a=ec.lastIndex,s=ec.exec(i)}return a1&&arguments[1]!==void 0?arguments[1]:{},n=[];return sr.Children.forEach(t,function(i){i==null&&!r.keepEmpty||(Array.isArray(i)?n=n.concat(Au(i)):PD.isFragment(i)&&i.props?n=n.concat(Au(i.props.children,r)):n.push(i))}),n}function TD(t,r){typeof t=="function"?t(r):Ji(t)==="object"&&t&&"current"in t&&(t.current=r)}function GZ(){for(var t=arguments.length,r=new Array(t),n=0;n0},t.prototype.connect_=function(){!Yg||this.connected_||(document.addEventListener("transitionend",this.onTransitionEnd_),window.addEventListener("resize",this.refresh),JZ?(this.mutationsObserver_=new MutationObserver(this.refresh),this.mutationsObserver_.observe(document,{attributes:!0,childList:!0,characterData:!0,subtree:!0})):(document.addEventListener("DOMSubtreeModified",this.refresh),this.mutationEventsAdded_=!0),this.connected_=!0)},t.prototype.disconnect_=function(){!Yg||!this.connected_||(document.removeEventListener("transitionend",this.onTransitionEnd_),window.removeEventListener("resize",this.refresh),this.mutationsObserver_&&this.mutationsObserver_.disconnect(),this.mutationEventsAdded_&&document.removeEventListener("DOMSubtreeModified",this.refresh),this.mutationsObserver_=null,this.mutationEventsAdded_=!1,this.connected_=!1)},t.prototype.onTransitionEnd_=function(r){var n=r.propertyName,i=n===void 0?"":n,o=ZZ.some(function(a){return!!~i.indexOf(a)});o&&this.refresh()},t.getInstance=function(){return this.instance_||(this.instance_=new t),this.instance_},t.instance_=null,t}(),RD=function(t,r){for(var n=0,i=Object.keys(r);n"u"||!(Element instanceof Object))){if(!(r instanceof ml(r).Element))throw new TypeError('parameter 1 is not of type "Element".');var n=this.observations_;n.has(r)||(n.set(r,new sJ(r)),this.controller_.addObserver(this),this.controller_.refresh())}},t.prototype.unobserve=function(r){if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");if(!(typeof Element>"u"||!(Element instanceof Object))){if(!(r instanceof ml(r).Element))throw new TypeError('parameter 1 is not of type "Element".');var n=this.observations_;n.has(r)&&(n.delete(r),n.size||this.controller_.removeObserver(this))}},t.prototype.disconnect=function(){this.clearActive(),this.observations_.clear(),this.controller_.removeObserver(this)},t.prototype.gatherActive=function(){var r=this;this.clearActive(),this.observations_.forEach(function(n){n.isActive()&&r.activeObservations_.push(n)})},t.prototype.broadcastActive=function(){if(this.hasActive()){var r=this.callbackCtx_,n=this.activeObservations_.map(function(i){return new lJ(i.target,i.broadcastRect())});this.callback_.call(r,n,r),this.clearActive()}},t.prototype.clearActive=function(){this.activeObservations_.splice(0)},t.prototype.hasActive=function(){return this.activeObservations_.length>0},t}(),BD=typeof WeakMap<"u"?new WeakMap:new FD,ND=function(){function t(r){if(!(this instanceof t))throw new TypeError("Cannot call a class as a function.");if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");var n=QZ.getInstance(),i=new cJ(r,n,this);BD.set(this,i)}return t}();["observe","unobserve","disconnect"].forEach(function(t){ND.prototype[t]=function(){var r;return(r=BD.get(this))[t].apply(r,arguments)}});var hJ=function(){return typeof Eu.ResizeObserver<"u"?Eu.ResizeObserver:ND}(),Os=new Map;function uJ(t){t.forEach(function(r){var n,i=r.target;(n=Os.get(i))===null||n===void 0||n.forEach(function(o){return o(i)})})}var $D=new hJ(uJ);function pJ(t,r){Os.has(t)||(Os.set(t,new Set),$D.observe(t)),Os.get(t).add(r)}function dJ(t,r){Os.has(t)&&(Os.get(t).delete(r),Os.get(t).size||($D.unobserve(t),Os.delete(t)))}var fJ=function(t){D8(n,t);var r=P8(n);function n(){return Ol(this,n),r.apply(this,arguments)}return Bl(n,[{key:"render",value:function(){return this.props.children}}]),n}(_.Component),Xg=_.createContext(null);function vJ(t){var r=t.children,n=t.onBatchResize,i=_.useRef(0),o=_.useRef([]),a=_.useContext(Xg),s=_.useCallback(function(l,h,p){i.current+=1;var f=i.current;o.current.push({size:l,element:h,data:p}),Promise.resolve().then(function(){f===i.current&&(n==null||n(o.current),o.current=[])}),a==null||a(l,h,p)},[n,a]);return _.createElement(Xg.Provider,{value:s},r)}function gJ(t,r){var n=t.children,i=t.disabled,o=_.useRef(null),a=_.useRef(null),s=_.useContext(Xg),l=typeof n=="function",h=l?n(o):n,p=_.useRef({width:-1,height:-1,offsetWidth:-1,offsetHeight:-1}),f=!l&&_.isValidElement(h)&&VD(h),g=f?h.ref:null,b=_.useMemo(function(){return GZ(g,o)},[g,o]),z=function(){return Lu(o.current)||Lu(a.current)};_.useImperativeHandle(r,function(){return z()});var M=_.useRef(t);M.current=t;var I=_.useCallback(function(F){var H=M.current,E=H.onResize,R=H.data,W=F.getBoundingClientRect(),$=W.width,G=W.height,Z=F.offsetWidth,K=F.offsetHeight,et=Math.floor($),at=Math.floor(G);if(p.current.width!==et||p.current.height!==at||p.current.offsetWidth!==Z||p.current.offsetHeight!==K){var tt={width:et,height:at,offsetWidth:Z,offsetHeight:K};p.current=tt;var ft=Z===Math.round($)?$:Z,dt=K===Math.round(G)?G:K,ht=Ke(Ke({},tt),{},{offsetWidth:ft,offsetHeight:dt});s==null||s(ht,F,R),E&&Promise.resolve().then(function(){E(ht,F)})}},[]);return _.useEffect(function(){var F=z();return F&&!i&&pJ(F,I),function(){return dJ(F,I)}},[o.current,i]),_.createElement(fJ,{ref:a},f?_.cloneElement(h,{ref:b}):h)}var mJ=_.forwardRef(gJ),yJ="rc-observer-key";function xJ(t,r){var n=t.children,i=typeof n=="function"?[n]:Au(n);return i.map(function(o,a){var s=(o==null?void 0:o.key)||"".concat(yJ,"-").concat(a);return _.createElement(mJ,Xi({},t,{key:s,ref:a===0?r:void 0}),o)})}var Yx=_.forwardRef(xJ);Yx.Collection=vJ;var WD=_.forwardRef(function(t,r){var n=t.height,i=t.offsetY,o=t.offsetX,a=t.children,s=t.prefixCls,l=t.onInnerResize,h=t.innerProps,p=t.rtl,f=t.extra,g={},b={display:"flex",flexDirection:"column"};if(i!==void 0){var z;g={height:n,position:"relative",overflow:"hidden"},b=Ke(Ke({},b),{},(z={transform:"translateY(".concat(i,"px)")},se(z,p?"marginRight":"marginLeft",-o),se(z,"position","absolute"),se(z,"left",0),se(z,"right",0),se(z,"top",0),z))}return _.createElement("div",{style:g},_.createElement(Yx,{onResize:function(I){var F=I.offsetHeight;F&&l&&l()}},_.createElement("div",Xi({style:b,className:bi(se({},"".concat(s,"-holder-inner"),s)),ref:r},h),a,f)))});WD.displayName="Filler";var jD=function(r){return+setTimeout(r,16)},GD=function(r){return clearTimeout(r)};typeof window<"u"&&"requestAnimationFrame"in window&&(jD=function(r){return window.requestAnimationFrame(r)},GD=function(r){return window.cancelAnimationFrame(r)});var lk=0,Xx=new Map;function UD(t){Xx.delete(t)}var t2=function(r){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1;lk+=1;var i=lk;function o(a){if(a===0)UD(i),r();else{var s=jD(function(){o(a-1)});Xx.set(i,s)}}return o(n),i};t2.cancel=function(t){var r=Xx.get(t);return UD(r),GD(r)};function ck(t,r){var n="touches"in t?t.touches[0]:t;return n[r?"pageX":"pageY"]}var hk=_.forwardRef(function(t,r){var n,i=t.prefixCls,o=t.rtl,a=t.scrollOffset,s=t.scrollRange,l=t.onStartMove,h=t.onStopMove,p=t.onScroll,f=t.horizontal,g=t.spinSize,b=t.containerSize,z=t.style,M=t.thumbStyle,I=_.useState(!1),F=B1(I,2),H=F[0],E=F[1],R=_.useState(null),W=B1(R,2),$=W[0],G=W[1],Z=_.useState(null),K=B1(Z,2),et=K[0],at=K[1],tt=!o,ft=_.useRef(),dt=_.useRef(),ht=_.useState(!1),lt=B1(ht,2),yt=lt[0],mt=lt[1],gt=_.useRef(),_t=function(){clearTimeout(gt.current),mt(!0),gt.current=setTimeout(function(){mt(!1)},3e3)},At=s-b||0,bt=b-g||0,kt=At>0,Lt=_.useMemo(function(){if(a===0||At===0)return 0;var Ft=a/At;return Ft*bt},[a,At,bt]),Vt=function(we){we.stopPropagation(),we.preventDefault()},Rt=_.useRef({top:Lt,dragging:H,pageY:$,startTop:et});Rt.current={top:Lt,dragging:H,pageY:$,startTop:et};var Ut=function(we){E(!0),G(ck(we,f)),at(Rt.current.top),l(),we.stopPropagation(),we.preventDefault()};_.useEffect(function(){var Ft=function(Se){Se.preventDefault()},we=ft.current,Ht=dt.current;return we.addEventListener("touchstart",Ft),Ht.addEventListener("touchstart",Ut),function(){we.removeEventListener("touchstart",Ft),Ht.removeEventListener("touchstart",Ut)}},[]);var Kt=_.useRef();Kt.current=At;var It=_.useRef();It.current=bt,_.useEffect(function(){if(H){var Ft,we=function(Se){var qt=Rt.current,ge=qt.dragging,oe=qt.pageY,ue=qt.startTop;if(t2.cancel(Ft),ge){var xe=ck(Se,f)-oe,Nt=ue;!tt&&f?Nt-=xe:Nt+=xe;var Jt=Kt.current,Ie=It.current,He=Ie?Nt/Ie:0,Pe=Math.ceil(He*Jt);Pe=Math.max(Pe,0),Pe=Math.min(Pe,Jt),Ft=t2(function(){p(Pe,f)})}},Ht=function(){E(!1),h()};return window.addEventListener("mousemove",we),window.addEventListener("touchmove",we),window.addEventListener("mouseup",Ht),window.addEventListener("touchend",Ht),function(){window.removeEventListener("mousemove",we),window.removeEventListener("touchmove",we),window.removeEventListener("mouseup",Ht),window.removeEventListener("touchend",Ht),t2.cancel(Ft)}}},[H]),_.useEffect(function(){_t()},[a]),_.useImperativeHandle(r,function(){return{delayHidden:_t}});var le="".concat(i,"-scrollbar"),Bt={position:"absolute",visibility:yt&&kt?null:"hidden"},de={position:"absolute",background:"rgba(0, 0, 0, 0.5)",borderRadius:99,cursor:"pointer",userSelect:"none"};return f?(Bt.height=8,Bt.left=0,Bt.right=0,Bt.bottom=0,de.height="100%",de.width=g,tt?de.left=Lt:de.right=Lt):(Bt.width=8,Bt.top=0,Bt.bottom=0,tt?Bt.right=0:Bt.left=0,de.width="100%",de.height=g,de.top=Lt),_.createElement("div",{ref:ft,className:bi(le,(n={},se(n,"".concat(le,"-horizontal"),f),se(n,"".concat(le,"-vertical"),!f),se(n,"".concat(le,"-visible"),yt),n)),style:Ke(Ke({},Bt),z),onMouseDown:Vt,onMouseMove:_t},_.createElement("div",{ref:dt,className:bi("".concat(le,"-thumb"),se({},"".concat(le,"-thumb-moving"),H)),style:Ke(Ke({},de),M),onMouseDown:Ut}))});function bJ(t){var r=t.children,n=t.setRef,i=_.useCallback(function(o){n(o)},[]);return _.cloneElement(r,{ref:i})}function wJ(t,r,n,i,o,a,s){var l=s.getKey;return t.slice(r,n+1).map(function(h,p){var f=r+p,g=a(h,f,{style:{width:i}}),b=l(h);return _.createElement(bJ,{key:b,setRef:function(M){return o(h,M)}},g)})}var CJ=function(){function t(){Ol(this,t),this.maps=void 0,this.id=0,this.maps=Object.create(null)}return Bl(t,[{key:"set",value:function(n,i){this.maps[n]=i,this.id+=1}},{key:"get",value:function(n){return this.maps[n]}}]),t}();function SJ(t,r,n){var i=_.useState(0),o=B1(i,2),a=o[0],s=o[1],l=_.useRef(new Map),h=_.useRef(new CJ),p=_.useRef();function f(){t2.cancel(p.current)}function g(){var z=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1;f();var M=function(){l.current.forEach(function(F,H){if(F&&F.offsetParent){var E=Lu(F),R=E.offsetHeight;h.current.get(H)!==R&&h.current.set(H,E.offsetHeight)}}),s(function(F){return F+1})};z?M():p.current=t2(M)}function b(z,M){var I=t(z),F=l.current.get(I);M?(l.current.set(I,M),g()):l.current.delete(I),!F!=!M&&(M?r==null||r(z):n==null||n(z))}return _.useEffect(function(){return f},[]),[b,g,h.current,a]}function uk(t){var r=_.useRef();r.current=t;var n=_.useCallback(function(){for(var i,o=arguments.length,a=new Array(o),s=0;s=0;ht-=1){var lt=o(r[ht]),yt=n.get(lt);if(yt===void 0){E=!0;break}if(dt-=yt,dt<=0)break}switch($){case"top":W=Z-F;break;case"bottom":W=K-H+F;break;default:{var mt=t.current.scrollTop,gt=mt+H;Zgt&&(R="bottom")}}W!==null&&s(W),W!==g.lastTop&&(E=!0)}E&&b(function(_t){return Ke(Ke({},_t),{},{times:_t.times+1,targetAlign:R,lastTop:W})})}},[g,t.current]),function(z){if(z==null){l();return}if(t2.cancel(h.current),typeof z=="number")s(z);else if(z&&Ji(z)==="object"){var M,I=z.align;"index"in z?M=z.index:M=r.findIndex(function(E){return o(E)===z.key});var F=z.offset,H=F===void 0?0:F;b({times:0,index:M,offset:H,originAlign:I})}}}function kJ(t,r,n){var i=t.length,o=r.length,a,s;if(i===0&&o===0)return null;i"u"?"undefined":Ji(navigator))==="object"&&/Firefox/i.test(navigator.userAgent);const YD=function(t,r){var n=_.useRef(!1),i=_.useRef(null);function o(){clearTimeout(i.current),n.current=!0,i.current=setTimeout(function(){n.current=!1},50)}var a=_.useRef({top:t,bottom:r});return a.current.top=t,a.current.bottom=r,function(s){var l=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,h=s<0&&a.current.top||s>0&&a.current.bottom;return l&&h?(clearTimeout(i.current),n.current=!1):(!h||n.current)&&o(),!n.current&&h}};function AJ(t,r,n,i,o){var a=_.useRef(0),s=_.useRef(null),l=_.useRef(null),h=_.useRef(!1),p=YD(r,n);function f(F,H){t2.cancel(s.current),a.current+=H,l.current=H,!p(H)&&(pk||F.preventDefault(),s.current=t2(function(){var E=h.current?10:1;o(a.current*E),a.current=0}))}function g(F,H){o(H,!0),pk||F.preventDefault()}var b=_.useRef(null),z=_.useRef(null);function M(F){if(t){t2.cancel(z.current),z.current=t2(function(){b.current=null},2);var H=F.deltaX,E=F.deltaY,R=F.shiftKey,W=H,$=E;(b.current==="sx"||!b.current&&R&&E&&!H)&&(W=E,$=0,b.current="sx");var G=Math.abs(W),Z=Math.abs($);b.current===null&&(b.current=i&&G>Z?"x":"y"),b.current==="y"?f(F,$):g(F,W)}}function I(F){t&&(h.current=F.detail===l.current)}return[M,I]}var LJ=14/15;function EJ(t,r,n){var i=_.useRef(!1),o=_.useRef(0),a=_.useRef(null),s=_.useRef(null),l,h=function(b){if(i.current){var z=Math.ceil(b.touches[0].pageY),M=o.current-z;o.current=z,n(M)&&b.preventDefault(),clearInterval(s.current),s.current=setInterval(function(){M*=LJ,(!n(M,!0)||Math.abs(M)<=.1)&&clearInterval(s.current)},16)}},p=function(){i.current=!1,l()},f=function(b){l(),b.touches.length===1&&!i.current&&(i.current=!0,o.current=Math.ceil(b.touches[0].pageY),a.current=b.target,a.current.addEventListener("touchmove",h),a.current.addEventListener("touchend",p))};l=function(){a.current&&(a.current.removeEventListener("touchmove",h),a.current.removeEventListener("touchend",p))},Oa(function(){return t&&r.current.addEventListener("touchstart",f),function(){var g;(g=r.current)===null||g===void 0||g.removeEventListener("touchstart",f),l(),clearInterval(s.current)}},[t])}var IJ=20;function dk(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,n=t/r*100;return isNaN(n)&&(n=0),n=Math.max(n,IJ),n=Math.min(n,t/2),Math.floor(n)}function HJ(t,r,n,i){var o=_.useMemo(function(){return[new Map,[]]},[t,n.id,i]),a=B1(o,2),s=a[0],l=a[1],h=function(f){var g=arguments.length>1&&arguments[1]!==void 0?arguments[1]:f,b=s.get(f),z=s.get(g);if(b===void 0||z===void 0)for(var M=t.length,I=l.length;Ia||!!I),tt=M==="rtl",ft=bi(i,se({},"".concat(i,"-rtl"),tt),o),dt=f||PJ,ht=_.useRef(),lt=_.useRef(),yt=_.useState(0),mt=B1(yt,2),gt=mt[0],_t=mt[1],At=_.useState(0),bt=B1(At,2),kt=bt[0],Lt=bt[1],Vt=_.useState(!1),Rt=B1(Vt,2),Ut=Rt[0],Kt=Rt[1],It=function(){Kt(!0)},le=function(){Kt(!1)},Bt=_.useCallback(function(r1){return typeof b=="function"?b(r1):r1==null?void 0:r1[b]},[b]),de={getKey:Bt};function Ft(r1){_t(function(s1){var A1;typeof r1=="function"?A1=r1(s1):A1=r1;var Or=Re(A1);return ht.current.scrollTop=Or,Or})}var we=_.useRef({start:0,end:dt.length}),Ht=_.useRef(),ce=_J(dt,Bt),Se=B1(ce,1),qt=Se[0];Ht.current=qt;var ge=SJ(Bt,null,null),oe=B1(ge,4),ue=oe[0],xe=oe[1],Nt=oe[2],Jt=oe[3],Ie=_.useMemo(function(){if(!et)return{scrollHeight:void 0,start:0,end:dt.length-1,offset:void 0};if(!at){var r1;return{scrollHeight:((r1=lt.current)===null||r1===void 0?void 0:r1.offsetHeight)||0,start:0,end:dt.length-1,offset:void 0}}for(var s1=0,A1,Or,bn,v6=dt.length,Q=0;Q=gt&&A1===void 0&&(A1=Q,Or=s1),v>gt+a&&bn===void 0&&(bn=Q),s1=v}return A1===void 0&&(A1=0,Or=0,bn=Math.ceil(a/s)),bn===void 0&&(bn=dt.length-1),bn=Math.min(bn+1,dt.length-1),{scrollHeight:s1,start:A1,end:bn,offset:Or}},[at,et,gt,dt,Jt,a]),He=Ie.scrollHeight,Pe=Ie.start,Xt=Ie.end,st=Ie.offset;we.current.start=Pe,we.current.end=Xt;var Mt=_.useState({width:0,height:a}),wt=B1(Mt,2),Pt=wt[0],Yt=wt[1],Zt=function(s1){Yt({width:s1.width||s1.offsetWidth,height:s1.height||s1.offsetHeight})},ae=_.useRef(),ee=_.useRef(),jt=_.useMemo(function(){return dk(Pt.width,I)},[Pt.width,I]),_e=_.useMemo(function(){return dk(Pt.height,He)},[Pt.height,He]),ze=He-a,Gt=_.useRef(ze);Gt.current=ze;function Re(r1){var s1=r1;return Number.isNaN(Gt.current)||(s1=Math.min(s1,Gt.current)),s1=Math.max(s1,0),s1}var je=gt<=0,d1=gt>=ze,K1=YD(je,d1),Oe=function(){return{x:tt?-kt:kt,y:gt}},Ae=_.useRef(Oe()),E1=uk(function(){if(R){var r1=Oe();(Ae.current.x!==r1.x||Ae.current.y!==r1.y)&&(R(r1),Ae.current=r1)}});function ur(r1,s1){var A1=r1;s1?(Ya.flushSync(function(){Lt(A1)}),E1()):Ft(A1)}function Qr(r1){var s1=r1.currentTarget.scrollTop;s1!==gt&&Ft(s1),E==null||E(r1),E1()}var ti=function(s1){var A1=s1,Or=I-Pt.width;return A1=Math.max(A1,0),A1=Math.min(A1,Or),A1},us=uk(function(r1,s1){s1?(Ya.flushSync(function(){Lt(function(A1){var Or=A1+(tt?-r1:r1);return ti(Or)})}),E1()):Ft(function(A1){var Or=A1+r1;return Or})}),Mo=AJ(et,je,d1,!!I,us),ko=B1(Mo,2),sa=ko[0],ps=ko[1];EJ(et,ht,function(r1,s1){return K1(r1,s1)?!1:(sa({preventDefault:function(){},deltaY:r1}),!0)}),Oa(function(){function r1(A1){et&&A1.preventDefault()}var s1=ht.current;return s1.addEventListener("wheel",sa),s1.addEventListener("DOMMouseScroll",ps),s1.addEventListener("MozMousePixelScroll",r1),function(){s1.removeEventListener("wheel",sa),s1.removeEventListener("DOMMouseScroll",ps),s1.removeEventListener("MozMousePixelScroll",r1)}},[et]),Oa(function(){I&&Lt(function(r1){return ti(r1)})},[Pt.width,I]);var ds=function(){var s1,A1;(s1=ae.current)===null||s1===void 0||s1.delayHidden(),(A1=ee.current)===null||A1===void 0||A1.delayHidden()},d2=MJ(ht,dt,Nt,s,Bt,function(){return xe(!0)},Ft,ds);_.useImperativeHandle(r,function(){return{getScrollInfo:Oe,scrollTo:function(s1){function A1(Or){return Or&&Ji(Or)==="object"&&("left"in Or||"top"in Or)}A1(s1)?(s1.left!==void 0&&Lt(ti(s1.left)),d2(s1.top)):d2(s1)}}}),Oa(function(){if(W){var r1=dt.slice(Pe,Xt+1);W(r1,dt)}},[Pe,Xt,dt]);var fs=HJ(dt,Bt,Nt,s),f6=G==null?void 0:G({start:Pe,end:Xt,virtual:at,offsetX:kt,offsetY:st,rtl:tt,getSize:fs}),K0=wJ(dt,Pe,Xt,I,ue,g,de),la=null;a&&(la=Ke(se({},h?"height":"maxHeight",a),TJ),et&&(la.overflowY="hidden",I&&(la.overflowX="hidden"),Ut&&(la.pointerEvents="none")));var q0={};return tt&&(q0.dir="rtl"),_.createElement("div",Xi({style:Ke(Ke({},p),{},{position:"relative"}),className:ft},q0,K),_.createElement(Yx,{onResize:Zt},_.createElement(H,{className:"".concat(i,"-holder"),style:la,ref:ht,onScroll:Qr,onMouseEnter:ds},_.createElement(WD,{prefixCls:i,height:He,offsetX:kt,offsetY:st,scrollWidth:I,onInnerResize:xe,ref:lt,innerProps:$,rtl:tt,extra:f6},K0))),at&&He>a&&_.createElement(hk,{ref:ae,prefixCls:i,scrollOffset:gt,scrollRange:He,rtl:tt,onScroll:ur,onStartMove:It,onStopMove:le,spinSize:_e,containerSize:Pt.height,style:Z==null?void 0:Z.verticalScrollBar,thumbStyle:Z==null?void 0:Z.verticalScrollBarThumb}),at&&I&&_.createElement(hk,{ref:ee,prefixCls:i,scrollOffset:kt,scrollRange:I,rtl:tt,onScroll:ur,onStartMove:It,onStopMove:le,spinSize:jt,containerSize:Pt.width,horizontal:!0,style:Z==null?void 0:Z.horizontalScrollBar,thumbStyle:Z==null?void 0:Z.horizontalScrollBarThumb}))}var XD=_.forwardRef(VJ);XD.displayName="List";var FJ=_.createContext({}),RJ=function(t){D8(n,t);var r=P8(n);function n(){return Ol(this,n),r.apply(this,arguments)}return Bl(n,[{key:"render",value:function(){return this.props.children}}]),n}(_.Component),U4="none",kh="appear",_h="enter",Ah="leave",fk="none",ro="prepare",N3="start",$3="active",Kx="end",KD="prepared";function vk(t,r){var n={};return n[t.toLowerCase()]=r.toLowerCase(),n["Webkit".concat(t)]="webkit".concat(r),n["Moz".concat(t)]="moz".concat(r),n["ms".concat(t)]="MS".concat(r),n["O".concat(t)]="o".concat(r.toLowerCase()),n}function OJ(t,r){var n={animationend:vk("Animation","AnimationEnd"),transitionend:vk("Transition","TransitionEnd")};return t&&("AnimationEvent"in r||delete n.animationend.animation,"TransitionEvent"in r||delete n.transitionend.transition),n}var BJ=OJ(G9(),typeof window<"u"?window:{}),qD={};if(G9()){var NJ=document.createElement("div");qD=NJ.style}var Lh={};function ZD(t){if(Lh[t])return Lh[t];var r=BJ[t];if(r)for(var n=Object.keys(r),i=n.length,o=0;o1&&arguments[1]!==void 0?arguments[1]:2;r();var a=t2(function(){o<=1?i({isCanceled:function(){return a!==t.current}}):n(i,o-1)});t.current=a}return _.useEffect(function(){return function(){r()}},[]),[n,r]};var jJ=[ro,N3,$3,Kx],GJ=[ro,KD],rP=!1,UJ=!0;function iP(t){return t===$3||t===Kx}const YJ=function(t,r,n){var i=x7(fk),o=B1(i,2),a=o[0],s=o[1],l=WJ(),h=B1(l,2),p=h[0],f=h[1];function g(){s(ro,!0)}var b=r?GJ:jJ;return eP(function(){if(a!==fk&&a!==Kx){var z=b.indexOf(a),M=b[z+1],I=n(a);I===rP?s(M,!0):M&&p(function(F){function H(){F.isCanceled()||s(M,!0)}I===!0?H():Promise.resolve(I).then(H)})}},[t,a]),_.useEffect(function(){return function(){f()}},[]),[g,a]};function XJ(t,r,n,i){var o=i.motionEnter,a=o===void 0?!0:o,s=i.motionAppear,l=s===void 0?!0:s,h=i.motionLeave,p=h===void 0?!0:h,f=i.motionDeadline,g=i.motionLeaveImmediately,b=i.onAppearPrepare,z=i.onEnterPrepare,M=i.onLeavePrepare,I=i.onAppearStart,F=i.onEnterStart,H=i.onLeaveStart,E=i.onAppearActive,R=i.onEnterActive,W=i.onLeaveActive,$=i.onAppearEnd,G=i.onEnterEnd,Z=i.onLeaveEnd,K=i.onVisibleChanged,et=x7(),at=B1(et,2),tt=at[0],ft=at[1],dt=x7(U4),ht=B1(dt,2),lt=ht[0],yt=ht[1],mt=x7(null),gt=B1(mt,2),_t=gt[0],At=gt[1],bt=_.useRef(!1),kt=_.useRef(null);function Lt(){return n()}var Vt=_.useRef(!1);function Rt(){yt(U4,!0),At(null,!0)}function Ut(oe){var ue=Lt();if(!(oe&&!oe.deadline&&oe.target!==ue)){var xe=Vt.current,Nt;lt===kh&&xe?Nt=$==null?void 0:$(ue,oe):lt===_h&&xe?Nt=G==null?void 0:G(ue,oe):lt===Ah&&xe&&(Nt=Z==null?void 0:Z(ue,oe)),lt!==U4&&xe&&Nt!==!1&&Rt()}}var Kt=$J(Ut),It=B1(Kt,1),le=It[0],Bt=function(ue){var xe,Nt,Jt;switch(ue){case kh:return xe={},se(xe,ro,b),se(xe,N3,I),se(xe,$3,E),xe;case _h:return Nt={},se(Nt,ro,z),se(Nt,N3,F),se(Nt,$3,R),Nt;case Ah:return Jt={},se(Jt,ro,M),se(Jt,N3,H),se(Jt,$3,W),Jt;default:return{}}},de=_.useMemo(function(){return Bt(lt)},[lt]),Ft=YJ(lt,!t,function(oe){if(oe===ro){var ue=de[ro];return ue?ue(Lt()):rP}if(ce in de){var xe;At(((xe=de[ce])===null||xe===void 0?void 0:xe.call(de,Lt(),null))||null)}return ce===$3&&(le(Lt()),f>0&&(clearTimeout(kt.current),kt.current=setTimeout(function(){Ut({deadline:!0})},f))),ce===KD&&Rt(),UJ}),we=B1(Ft,2),Ht=we[0],ce=we[1],Se=iP(ce);Vt.current=Se,eP(function(){ft(r);var oe=bt.current;bt.current=!0;var ue;!oe&&r&&l&&(ue=kh),oe&&r&&a&&(ue=_h),(oe&&!r&&p||!oe&&g&&!r&&p)&&(ue=Ah);var xe=Bt(ue);ue&&(t||xe[ro])?(yt(ue),Ht()):yt(U4)},[r]),_.useEffect(function(){(lt===kh&&!l||lt===_h&&!a||lt===Ah&&!p)&&yt(U4)},[l,a,p]),_.useEffect(function(){return function(){bt.current=!1,clearTimeout(kt.current)}},[]);var qt=_.useRef(!1);_.useEffect(function(){tt&&(qt.current=!0),tt!==void 0&<===U4&&((qt.current||tt)&&(K==null||K(tt)),qt.current=!0)},[tt,lt]);var ge=_t;return de[ro]&&ce===N3&&(ge=Ke({transition:"none"},ge)),[lt,ce,ge,tt??r]}function KJ(t){var r=t;Ji(t)==="object"&&(r=t.transitionSupport);function n(o,a){return!!(o.motionName&&r&&a!==!1)}var i=_.forwardRef(function(o,a){var s=o.visible,l=s===void 0?!0:s,h=o.removeOnLeave,p=h===void 0?!0:h,f=o.forceRender,g=o.children,b=o.motionName,z=o.leavedClassName,M=o.eventProps,I=_.useContext(FJ),F=I.motion,H=n(o,F),E=_.useRef(),R=_.useRef();function W(){try{return E.current instanceof HTMLElement?E.current:Lu(R.current)}catch{return null}}var $=XJ(H,l,W,o),G=B1($,4),Z=G[0],K=G[1],et=G[2],at=G[3],tt=_.useRef(at);at&&(tt.current=!0);var ft=_.useCallback(function(At){E.current=At,TD(a,At)},[a]),dt,ht=Ke(Ke({},M),{},{visible:l});if(!g)dt=null;else if(Z===U4)at?dt=g(Ke({},ht),ft):!p&&tt.current&&z?dt=g(Ke(Ke({},ht),{},{className:z}),ft):f||!p&&!z?dt=g(Ke(Ke({},ht),{},{style:{display:"none"}}),ft):dt=null;else{var lt,yt;K===ro?yt="prepare":iP(K)?yt="active":K===N3&&(yt="start");var mt=yk(b,"".concat(Z,"-").concat(yt));dt=g(Ke(Ke({},ht),{},{className:bi(yk(b,Z),(lt={},se(lt,mt,mt&&yt),se(lt,b,typeof b=="string"),lt)),style:et}),ft)}if(_.isValidElement(dt)&&VD(dt)){var gt=dt,_t=gt.ref;_t||(dt=_.cloneElement(dt,{ref:ft}))}return _.createElement(RJ,{ref:R},dt)});return i.displayName="CSSMotion",i}const nP=KJ(tP);var Kg="add",qg="keep",Zg="remove",Gf="removed";function qJ(t){var r;return t&&Ji(t)==="object"&&"key"in t?r=t:r={key:t},Ke(Ke({},r),{},{key:String(r.key)})}function Jg(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];return t.map(qJ)}function ZJ(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],n=[],i=0,o=r.length,a=Jg(t),s=Jg(r);a.forEach(function(p){for(var f=!1,g=i;g1});return h.forEach(function(p){n=n.filter(function(f){var g=f.key,b=f.status;return g!==p||b!==Zg}),n.forEach(function(f){f.key===p&&(f.status=qg)})}),n}var JJ=["component","children","onVisibleChanged","onAllRemoved"],QJ=["status"],tQ=["eventProps","visible","children","motionName","motionAppear","motionEnter","motionLeave","motionLeaveImmediately","motionDeadline","removeOnLeave","leavedClassName","onAppearPrepare","onAppearStart","onAppearActive","onAppearEnd","onEnterStart","onEnterActive","onEnterEnd","onLeaveStart","onLeaveActive","onLeaveEnd"];function eQ(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:nP,n=function(i){D8(a,i);var o=P8(a);function a(){var s;Ol(this,a);for(var l=arguments.length,h=new Array(l),p=0;p1&&arguments[1]!==void 0?arguments[1]:null;return f.map(function(b,z){for(var M=oP(g?g.pos:"0",z),I=T8(b[a],M),F,H=0;H1&&arguments[1]!==void 0?arguments[1]:{},n=r.initWrapper,i=r.processEntity,o=r.onProcessFinished,a=r.externalGetKey,s=r.childrenPropName,l=r.fieldNames,h=arguments.length>2?arguments[2]:void 0,p=a||h,f={},g={},b={posEntities:f,keyEntities:g};return n&&(b=n(b)||b),lQ(t,function(z){var M=z.node,I=z.index,F=z.pos,H=z.key,E=z.parentPos,R=z.level,W=z.nodes,$={node:M,nodes:W,index:I,key:H,pos:F,level:R},G=T8(H,F);f[F]=$,g[G]=$,$.parent=f[E],$.parent&&($.parent.children=$.parent.children||[],$.parent.children.push($)),i&&i($,b)},{externalGetKey:p,childrenPropName:s,fieldNames:l}),o&&o(b),b}function Ec(t,r){var n=r.expandedKeys,i=r.selectedKeys,o=r.loadedKeys,a=r.loadingKeys,s=r.checkedKeys,l=r.halfCheckedKeys,h=r.dragOverNodeKey,p=r.dropPosition,f=r.keyEntities,g=_n(f,t),b={eventKey:t,expanded:n.indexOf(t)!==-1,selected:i.indexOf(t)!==-1,loaded:o.indexOf(t)!==-1,loading:a.indexOf(t)!==-1,checked:s.indexOf(t)!==-1,halfChecked:l.indexOf(t)!==-1,pos:String(g?g.pos:""),dragOver:h===t&&p===0,dragOverGapTop:h===t&&p===-1,dragOverGapBottom:h===t&&p===1};return b}function ri(t){var r=t.data,n=t.expanded,i=t.selected,o=t.checked,a=t.loaded,s=t.loading,l=t.halfChecked,h=t.dragOver,p=t.dragOverGapTop,f=t.dragOverGapBottom,g=t.pos,b=t.active,z=t.eventKey,M=Ke(Ke({},r),{},{expanded:n,selected:i,checked:o,loaded:a,loading:s,halfChecked:l,dragOver:h,dragOverGapTop:p,dragOverGapBottom:f,pos:g,active:b,key:z});return"props"in M||Object.defineProperty(M,"props",{get:function(){return oo(!1,"Second param return from event is node data instead of TreeNode instance. Please read value directly instead of reading from `props`."),t}}),M}var hQ=["eventKey","className","style","dragOver","dragOverGapTop","dragOverGapBottom","isLeaf","isStart","isEnd","expanded","selected","checked","halfChecked","loading","domRef","active","data","onMouseMove","selectable"],xk="open",bk="close",uQ="---",pQ=function(t){D8(n,t);var r=P8(n);function n(){var i;Ol(this,n);for(var o=arguments.length,a=new Array(o),s=0;s0&&arguments[0]!==void 0?arguments[0]:[],r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],n=t.length,i=r.length;if(Math.abs(n-i)!==1)return{add:!1,key:null};function o(a,s){var l=new Map;a.forEach(function(p){l.set(p,!0)});var h=s.filter(function(p){return!l.has(p)});return h.length===1?h[0]:null}return n ").concat(r);return r}var lP=_.forwardRef(function(t,r){var n=t.prefixCls,i=t.data;t.selectable,t.checkable;var o=t.expandedKeys,a=t.selectedKeys,s=t.checkedKeys,l=t.loadedKeys,h=t.loadingKeys,p=t.halfCheckedKeys,f=t.keyEntities,g=t.disabled,b=t.dragging,z=t.dragOverNodeKey,M=t.dropPosition,I=t.motion,F=t.height,H=t.itemHeight,E=t.virtual,R=t.focusable,W=t.activeItem,$=t.focused,G=t.tabIndex,Z=t.onKeyDown,K=t.onFocus,et=t.onBlur,at=t.onActiveChange,tt=t.onListChangeStart,ft=t.onListChangeEnd,dt=C0(t,mQ),ht=_.useRef(null),lt=_.useRef(null);_.useImperativeHandle(r,function(){return{scrollTo:function(xe){ht.current.scrollTo(xe)},getIndentWidth:function(){return lt.current.offsetWidth}}});var yt=_.useState(o),mt=B1(yt,2),gt=mt[0],_t=mt[1],At=_.useState(i),bt=B1(At,2),kt=bt[0],Lt=bt[1],Vt=_.useState(i),Rt=B1(Vt,2),Ut=Rt[0],Kt=Rt[1],It=_.useState([]),le=B1(It,2),Bt=le[0],de=le[1],Ft=_.useState(null),we=B1(Ft,2),Ht=we[0],ce=we[1],Se=_.useRef(i);Se.current=i;function qt(){var ue=Se.current;Lt(ue),Kt(ue),de([]),ce(null),ft()}Oa(function(){_t(o);var ue=gQ(gt,o);if(ue.key!==null)if(ue.add){var xe=kt.findIndex(function(Xt){var st=Xt.key;return st===ue.key}),Nt=zk(wk(kt,i,ue.key),E,F,H),Jt=kt.slice();Jt.splice(xe+1,0,Sk),Kt(Jt),de(Nt),ce("show")}else{var Ie=i.findIndex(function(Xt){var st=Xt.key;return st===ue.key}),He=zk(wk(i,kt,ue.key),E,F,H),Pe=i.slice();Pe.splice(Ie+1,0,Sk),Kt(Pe),de(He),ce("hide")}else kt!==i&&(Lt(i),Kt(i))},[o,i]),_.useEffect(function(){b||qt()},[b]);var ge=I?Ut:i,oe={expandedKeys:o,selectedKeys:a,loadedKeys:l,loadingKeys:h,checkedKeys:s,halfCheckedKeys:p,dragOverNodeKey:z,dropPosition:M,keyEntities:f};return _.createElement(_.Fragment,null,$&&W&&_.createElement("span",{style:Ck,"aria-live":"assertive"},xQ(W)),_.createElement("div",null,_.createElement("input",{style:Ck,disabled:R===!1||g,tabIndex:R!==!1?G:null,onKeyDown:Z,onFocus:K,onBlur:et,value:"",onChange:yQ,"aria-label":"for screen reader"})),_.createElement("div",{className:"".concat(n,"-treenode"),"aria-hidden":!0,style:{position:"absolute",pointerEvents:"none",visibility:"hidden",height:0,overflow:"hidden",border:0,padding:0}},_.createElement("div",{className:"".concat(n,"-indent")},_.createElement("div",{ref:lt,className:"".concat(n,"-indent-unit")}))),_.createElement(XD,Xi({},dt,{data:ge,itemKey:Mk,height:F,fullHeight:!1,virtual:E,itemHeight:H,prefixCls:"".concat(n,"-list"),ref:ht,onVisibleChange:function(xe,Nt){var Jt=new Set(xe),Ie=Nt.filter(function(He){return!Jt.has(He)});Ie.some(function(He){return Mk(He)===S0})&&qt()}}),function(ue){var xe=ue.pos,Nt=Object.assign({},(ID(ue.data),ue.data)),Jt=ue.title,Ie=ue.key,He=ue.isStart,Pe=ue.isEnd,Xt=T8(Ie,xe);delete Nt.key,delete Nt.children;var st=Ec(Xt,oe);return _.createElement(vQ,Xi({},Nt,st,{title:Jt,active:!!W&&Ie===W.key,pos:xe,data:ue.data,isStart:He,isEnd:Pe,motion:I,motionNodes:Ie===S0?Bt:null,motionType:Ht,onMotionStart:tt,onMotionEnd:qt,treeNodeRequiredProps:oe,onMouseMove:function(){at(null)}}))}))});lP.displayName="NodeList";function ya(t,r){if(!t)return[];var n=t.slice(),i=n.indexOf(r);return i>=0&&n.splice(i,1),n}function Ms(t,r){var n=(t||[]).slice();return n.indexOf(r)===-1&&n.push(r),n}function qx(t){return t.split("-")}function bQ(t,r){var n=[],i=_n(r,t);function o(){var a=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];a.forEach(function(s){var l=s.key,h=s.children;n.push(l),o(h)})}return o(i.children),n}function wQ(t){if(t.parent){var r=qx(t.pos);return Number(r[r.length-1])===t.parent.children.length-1}return!1}function CQ(t){var r=qx(t.pos);return Number(r[r.length-1])===0}function kk(t,r,n,i,o,a,s,l,h,p){var f,g=t.clientX,b=t.clientY,z=t.target.getBoundingClientRect(),M=z.top,I=z.height,F=(p==="rtl"?-1:1)*(((o==null?void 0:o.x)||0)-g),H=(F-12)/i,E=h.filter(function(yt){var mt;return(mt=l[yt])===null||mt===void 0||(mt=mt.children)===null||mt===void 0?void 0:mt.length}),R=_n(l,n.props.eventKey);if(b-1.5?a({dragNode:dt,dropNode:ht,dropPosition:1})?at=1:lt=!1:a({dragNode:dt,dropNode:ht,dropPosition:0})?at=0:a({dragNode:dt,dropNode:ht,dropPosition:1})?at=1:lt=!1:a({dragNode:dt,dropNode:ht,dropPosition:1})?at=1:lt=!1,{dropPosition:at,dropLevelOffset:tt,dropTargetKey:R.key,dropTargetPos:R.pos,dragOverNodeKey:et,dropContainerKey:at===0?null:((f=R.parent)===null||f===void 0?void 0:f.key)||null,dropAllowed:lt}}function _k(t,r){if(t){var n=r.multiple;return n?t.slice():t.length?[t[0]]:t}}function Yf(t){if(!t)return null;var r;if(Array.isArray(t))r={checkedKeys:t,halfCheckedKeys:void 0};else if(Ji(t)==="object")r={checkedKeys:t.checked||void 0,halfCheckedKeys:t.halfChecked||void 0};else return oo(!1,"`checkedKeys` is not an array or an object"),null;return r}function Ak(t,r){var n=new Set;function i(o){if(!n.has(o)){var a=_n(r,o);if(a){n.add(o);var s=a.parent,l=a.node;l.disabled||s&&i(s.key)}}}return(t||[]).forEach(function(o){i(o)}),l0(n)}function cP(t,r){var n=new Set;return t.forEach(function(i){r.has(i)||n.add(i)}),n}function SQ(t){var r=t||{},n=r.disabled,i=r.disableCheckbox,o=r.checkable;return!!(n||i)||o===!1}function zQ(t,r,n,i){for(var o=new Set(t),a=new Set,s=0;s<=n;s+=1){var l=r.get(s)||new Set;l.forEach(function(g){var b=g.key,z=g.node,M=g.children,I=M===void 0?[]:M;o.has(b)&&!i(z)&&I.filter(function(F){return!i(F.node)}).forEach(function(F){o.add(F.key)})})}for(var h=new Set,p=n;p>=0;p-=1){var f=r.get(p)||new Set;f.forEach(function(g){var b=g.parent,z=g.node;if(!(i(z)||!g.parent||h.has(g.parent.key))){if(i(g.parent.node)){h.add(b.key);return}var M=!0,I=!1;(b.children||[]).filter(function(F){return!i(F.node)}).forEach(function(F){var H=F.key,E=o.has(H);M&&!E&&(M=!1),!I&&(E||a.has(H))&&(I=!0)}),M&&o.add(b.key),I&&a.add(b.key),h.add(b.key)}})}return{checkedKeys:Array.from(o),halfCheckedKeys:Array.from(cP(a,o))}}function MQ(t,r,n,i,o){for(var a=new Set(t),s=new Set(r),l=0;l<=i;l+=1){var h=n.get(l)||new Set;h.forEach(function(b){var z=b.key,M=b.node,I=b.children,F=I===void 0?[]:I;!a.has(z)&&!s.has(z)&&!o(M)&&F.filter(function(H){return!o(H.node)}).forEach(function(H){a.delete(H.key)})})}s=new Set;for(var p=new Set,f=i;f>=0;f-=1){var g=n.get(f)||new Set;g.forEach(function(b){var z=b.parent,M=b.node;if(!(o(M)||!b.parent||p.has(b.parent.key))){if(o(b.parent.node)){p.add(z.key);return}var I=!0,F=!1;(z.children||[]).filter(function(H){return!o(H.node)}).forEach(function(H){var E=H.key,R=a.has(E);I&&!R&&(I=!1),!F&&(R||s.has(E))&&(F=!0)}),I||a.delete(z.key),F&&s.add(z.key),p.add(z.key)}})}return{checkedKeys:Array.from(a),halfCheckedKeys:Array.from(cP(s,a))}}function Xf(t,r,n,i){var o=[],a;i?a=i:a=SQ;var s=new Set(t.filter(function(f){var g=!!_n(n,f);return g||o.push(f),g})),l=new Map,h=0;Object.keys(n).forEach(function(f){var g=n[f],b=g.level,z=l.get(b);z||(z=new Set,l.set(b,z)),z.add(g),h=Math.max(h,b)}),oo(!o.length,"Tree missing follow keys: ".concat(o.slice(0,100).map(function(f){return"'".concat(f,"'")}).join(", ")));var p;return r===!0?p=zQ(s,l,h,a):p=MQ(s,r.halfCheckedKeys,l,h,a),p}var kQ=10,Zx=function(t){D8(n,t);var r=P8(n);function n(){var i;Ol(this,n);for(var o=arguments.length,a=new Array(o),s=0;s2&&arguments[2]!==void 0?arguments[2]:!1,g=i.state,b=g.dragChildrenKeys,z=g.dropPosition,M=g.dropTargetKey,I=g.dropTargetPos,F=g.dropAllowed;if(F){var H=i.props.onDrop;if(i.setState({dragOverNodeKey:null}),i.cleanDragState(),M!==null){var E=Ke(Ke({},Ec(M,i.getTreeNodeRequiredProps())),{},{active:((p=i.getActiveItem())===null||p===void 0?void 0:p.key)===M,data:_n(i.state.keyEntities,M).node}),R=b.indexOf(M)!==-1;oo(!R,"Can not drop to dragNode's children node. This is a bug of rc-tree. Please report an issue.");var W=qx(I),$={event:l,node:ri(E),dragNode:i.dragNode?ri(i.dragNode.props):null,dragNodesKeys:[i.dragNode.props.eventKey].concat(b),dropToGap:z!==0,dropPosition:z+Number(W[W.length-1])};f||H==null||H($),i.dragNode=null}}}),se(Le(i),"cleanDragState",function(){var l=i.state.draggingNodeKey;l!==null&&i.setState({draggingNodeKey:null,dropPosition:null,dropContainerKey:null,dropTargetKey:null,dropLevelOffset:null,dropAllowed:!0,dragOverNodeKey:null}),i.dragStartMousePosition=null,i.currentMouseOverDroppableNodeKey=null}),se(Le(i),"triggerExpandActionExpand",function(l,h){var p=i.state,f=p.expandedKeys,g=p.flattenNodes,b=h.expanded,z=h.key,M=h.isLeaf;if(!(M||l.shiftKey||l.metaKey||l.ctrlKey)){var I=g.filter(function(H){return H.key===z})[0],F=ri(Ke(Ke({},Ec(z,i.getTreeNodeRequiredProps())),{},{data:I.data}));i.setExpandedKeys(b?ya(f,z):Ms(f,z)),i.onNodeExpand(l,F)}}),se(Le(i),"onNodeClick",function(l,h){var p=i.props,f=p.onClick,g=p.expandAction;g==="click"&&i.triggerExpandActionExpand(l,h),f==null||f(l,h)}),se(Le(i),"onNodeDoubleClick",function(l,h){var p=i.props,f=p.onDoubleClick,g=p.expandAction;g==="doubleClick"&&i.triggerExpandActionExpand(l,h),f==null||f(l,h)}),se(Le(i),"onNodeSelect",function(l,h){var p=i.state.selectedKeys,f=i.state,g=f.keyEntities,b=f.fieldNames,z=i.props,M=z.onSelect,I=z.multiple,F=h.selected,H=h[b.key],E=!F;E?I?p=Ms(p,H):p=[H]:p=ya(p,H);var R=p.map(function(W){var $=_n(g,W);return $?$.node:null}).filter(function(W){return W});i.setUncontrolledState({selectedKeys:p}),M==null||M(p,{event:"select",selected:E,node:h,selectedNodes:R,nativeEvent:l.nativeEvent})}),se(Le(i),"onNodeCheck",function(l,h,p){var f=i.state,g=f.keyEntities,b=f.checkedKeys,z=f.halfCheckedKeys,M=i.props,I=M.checkStrictly,F=M.onCheck,H=h.key,E,R={event:"check",node:h,checked:p,nativeEvent:l.nativeEvent};if(I){var W=p?Ms(b,H):ya(b,H),$=ya(z,H);E={checked:W,halfChecked:$},R.checkedNodes=W.map(function(tt){return _n(g,tt)}).filter(function(tt){return tt}).map(function(tt){return tt.node}),i.setUncontrolledState({checkedKeys:W})}else{var G=Xf([].concat(l0(b),[H]),!0,g),Z=G.checkedKeys,K=G.halfCheckedKeys;if(!p){var et=new Set(Z);et.delete(H);var at=Xf(Array.from(et),{checked:!1,halfCheckedKeys:K},g);Z=at.checkedKeys,K=at.halfCheckedKeys}E=Z,R.checkedNodes=[],R.checkedNodesPositions=[],R.halfCheckedKeys=K,Z.forEach(function(tt){var ft=_n(g,tt);if(ft){var dt=ft.node,ht=ft.pos;R.checkedNodes.push(dt),R.checkedNodesPositions.push({node:dt,pos:ht})}}),i.setUncontrolledState({checkedKeys:Z},!1,{halfCheckedKeys:K})}F==null||F(E,R)}),se(Le(i),"onNodeLoad",function(l){var h,p=l.key,f=i.state.keyEntities,g=_n(f,p);if(!(g!=null&&(h=g.children)!==null&&h!==void 0&&h.length)){var b=new Promise(function(z,M){i.setState(function(I){var F=I.loadedKeys,H=F===void 0?[]:F,E=I.loadingKeys,R=E===void 0?[]:E,W=i.props,$=W.loadData,G=W.onLoad;if(!$||H.indexOf(p)!==-1||R.indexOf(p)!==-1)return null;var Z=$(l);return Z.then(function(){var K=i.state.loadedKeys,et=Ms(K,p);G==null||G(et,{event:"load",node:l}),i.setUncontrolledState({loadedKeys:et}),i.setState(function(at){return{loadingKeys:ya(at.loadingKeys,p)}}),z()}).catch(function(K){if(i.setState(function(at){return{loadingKeys:ya(at.loadingKeys,p)}}),i.loadingRetryTimes[p]=(i.loadingRetryTimes[p]||0)+1,i.loadingRetryTimes[p]>=kQ){var et=i.state.loadedKeys;oo(!1,"Retry for `loadData` many times but still failed. No more retry."),i.setUncontrolledState({loadedKeys:Ms(et,p)}),z()}M(K)}),{loadingKeys:Ms(R,p)}})});return b.catch(function(){}),b}}),se(Le(i),"onNodeMouseEnter",function(l,h){var p=i.props.onMouseEnter;p==null||p({event:l,node:h})}),se(Le(i),"onNodeMouseLeave",function(l,h){var p=i.props.onMouseLeave;p==null||p({event:l,node:h})}),se(Le(i),"onNodeContextMenu",function(l,h){var p=i.props.onRightClick;p&&(l.preventDefault(),p({event:l,node:h}))}),se(Le(i),"onFocus",function(){var l=i.props.onFocus;i.setState({focused:!0});for(var h=arguments.length,p=new Array(h),f=0;f1&&arguments[1]!==void 0?arguments[1]:!1,p=arguments.length>2&&arguments[2]!==void 0?arguments[2]:null;if(!i.destroyed){var f=!1,g=!0,b={};Object.keys(l).forEach(function(z){if(z in i.props){g=!1;return}f=!0,b[z]=l[z]}),f&&(!h||g)&&i.setState(Ke(Ke({},b),p))}}),se(Le(i),"scrollTo",function(l){i.listRef.current.scrollTo(l)}),i}return Bl(n,[{key:"componentDidMount",value:function(){this.destroyed=!1,this.onUpdated()}},{key:"componentDidUpdate",value:function(){this.onUpdated()}},{key:"onUpdated",value:function(){var o=this.props,a=o.activeKey,s=o.itemScrollOffset,l=s===void 0?0:s;a!==void 0&&a!==this.state.activeKey&&(this.setState({activeKey:a}),a!==null&&this.scrollTo({key:a,offset:l}))}},{key:"componentWillUnmount",value:function(){window.removeEventListener("dragend",this.onWindowDragEnd),this.destroyed=!0}},{key:"resetDragState",value:function(){this.setState({dragOverNodeKey:null,dropPosition:null,dropLevelOffset:null,dropTargetKey:null,dropContainerKey:null,dropTargetPos:null,dropAllowed:!1})}},{key:"render",value:function(){var o=this.state,a=o.focused,s=o.flattenNodes,l=o.keyEntities,h=o.draggingNodeKey,p=o.activeKey,f=o.dropLevelOffset,g=o.dropContainerKey,b=o.dropTargetKey,z=o.dropPosition,M=o.dragOverNodeKey,I=o.indent,F=this.props,H=F.prefixCls,E=F.className,R=F.style,W=F.showLine,$=F.focusable,G=F.tabIndex,Z=G===void 0?0:G,K=F.selectable,et=F.showIcon,at=F.icon,tt=F.switcherIcon,ft=F.draggable,dt=F.checkable,ht=F.checkStrictly,lt=F.disabled,yt=F.motion,mt=F.loadData,gt=F.filterTreeNode,_t=F.height,At=F.itemHeight,bt=F.virtual,kt=F.titleRender,Lt=F.dropIndicatorRender,Vt=F.onContextMenu,Rt=F.onScroll,Ut=F.direction,Kt=F.rootClassName,It=F.rootStyle,le=LD(this.props,{aria:!0,data:!0}),Bt;return ft&&(Ji(ft)==="object"?Bt=ft:typeof ft=="function"?Bt={nodeDraggable:ft}:Bt={}),_.createElement(jx.Provider,{value:{prefixCls:H,selectable:K,showIcon:et,icon:at,switcherIcon:tt,draggable:Bt,draggingNodeKey:h,checkable:dt,checkStrictly:ht,disabled:lt,keyEntities:l,dropLevelOffset:f,dropContainerKey:g,dropTargetKey:b,dropPosition:z,dragOverNodeKey:M,indent:I,direction:Ut,dropIndicatorRender:Lt,loadData:mt,filterTreeNode:gt,titleRender:kt,onNodeClick:this.onNodeClick,onNodeDoubleClick:this.onNodeDoubleClick,onNodeExpand:this.onNodeExpand,onNodeSelect:this.onNodeSelect,onNodeCheck:this.onNodeCheck,onNodeLoad:this.onNodeLoad,onNodeMouseEnter:this.onNodeMouseEnter,onNodeMouseLeave:this.onNodeMouseLeave,onNodeContextMenu:this.onNodeContextMenu,onNodeDragStart:this.onNodeDragStart,onNodeDragEnter:this.onNodeDragEnter,onNodeDragOver:this.onNodeDragOver,onNodeDragLeave:this.onNodeDragLeave,onNodeDragEnd:this.onNodeDragEnd,onNodeDrop:this.onNodeDrop}},_.createElement("div",{role:"tree",className:bi(H,E,Kt,se(se(se({},"".concat(H,"-show-line"),W),"".concat(H,"-focused"),a),"".concat(H,"-active-focused"),p!==null)),style:It},_.createElement(lP,Xi({ref:this.listRef,prefixCls:H,style:R,data:s,disabled:lt,selectable:K,checkable:!!dt,motion:yt,dragging:h!==null,height:_t,itemHeight:At,virtual:bt,focusable:$,focused:a,tabIndex:Z,activeItem:this.getActiveItem(),onFocus:this.onFocus,onBlur:this.onBlur,onKeyDown:this.onKeyDown,onActiveChange:this.onActiveChange,onListChangeStart:this.onListChangeStart,onListChangeEnd:this.onListChangeEnd,onContextMenu:Vt,onScroll:Rt},this.getTreeNodeRequiredProps(),le))))}}],[{key:"getDerivedStateFromProps",value:function(o,a){var s=a.prevProps,l={prevProps:o};function h(G){return!s&&G in o||s&&s[G]!==o[G]}var p,f=a.fieldNames;if(h("fieldNames")&&(f=Hu(o.fieldNames),l.fieldNames=f),h("treeData")?p=o.treeData:h("children")&&(oo(!1,"`children` of Tree is deprecated. Please use `treeData` instead."),p=sQ(o.children)),p){l.treeData=p;var g=cQ(p,{fieldNames:f});l.keyEntities=Ke(se({},S0,sP),g.keyEntities)}var b=l.keyEntities||a.keyEntities;if(h("expandedKeys")||s&&h("autoExpandParent"))l.expandedKeys=o.autoExpandParent||!s&&o.defaultExpandParent?Ak(o.expandedKeys,b):o.expandedKeys;else if(!s&&o.defaultExpandAll){var z=Ke({},b);delete z[S0],l.expandedKeys=Object.keys(z).map(function(G){return z[G].key})}else!s&&o.defaultExpandedKeys&&(l.expandedKeys=o.autoExpandParent||o.defaultExpandParent?Ak(o.defaultExpandedKeys,b):o.defaultExpandedKeys);if(l.expandedKeys||delete l.expandedKeys,p||l.expandedKeys){var M=Uf(p||a.treeData,l.expandedKeys||a.expandedKeys,f);l.flattenNodes=M}if(o.selectable&&(h("selectedKeys")?l.selectedKeys=_k(o.selectedKeys,o):!s&&o.defaultSelectedKeys&&(l.selectedKeys=_k(o.defaultSelectedKeys,o))),o.checkable){var I;if(h("checkedKeys")?I=Yf(o.checkedKeys)||{}:!s&&o.defaultCheckedKeys?I=Yf(o.defaultCheckedKeys)||{}:p&&(I=Yf(o.checkedKeys)||{checkedKeys:a.checkedKeys,halfCheckedKeys:a.halfCheckedKeys}),I){var F=I,H=F.checkedKeys,E=H===void 0?[]:H,R=F.halfCheckedKeys,W=R===void 0?[]:R;if(!o.checkStrictly){var $=Xf(E,!0,b);E=$.checkedKeys,W=$.halfCheckedKeys}l.checkedKeys=E,l.halfCheckedKeys=W}}return h("loadedKeys")&&(l.loadedKeys=o.loadedKeys),l}}]),n}(_.Component);se(Zx,"defaultProps",{prefixCls:"rc-tree",showLine:!1,showIcon:!0,selectable:!0,multiple:!1,checkable:!1,disabled:!1,checkStrictly:!1,draggable:!1,defaultExpandParent:!0,autoExpandParent:!1,defaultExpandAll:!1,defaultExpandedKeys:[],defaultCheckedKeys:[],defaultSelectedKeys:[],dropIndicatorRender:OZ,allowDrop:function(){return!0},expandAction:!1});se(Zx,"TreeNode",n8);const _Q=({data:t})=>{const{Depth:r,Items:n,ImageListObj:i,ImageIndex:o,Visible:a,Event:s,CSS:l}=t==null?void 0:t.Properties,h=$1(l),[p,f]=_.useState([]),{dataRef:g,socket:b,findDesiredData:z}=x1(),M=Gr(t==null?void 0:t.Properties),I=[];let F=0;const H=gD(i),E=JSON.parse(ji(g.current,H)),R=(et,at)=>{const{node:tt}=at;if(et.length>p.length){et.filter(ht=>!p.includes(ht));const ft=JSON.stringify({Event:{EventName:"Expanding",ID:t==null?void 0:t.ID,Info:tt==null?void 0:tt.id}});if(!(s&&s.some(ht=>{var lt;return ht[0]==="Expanding"&&((lt=tt==null?void 0:tt.children)==null?void 0:lt.length)>0})))return;console.log(ft),b.send(ft)}else if(et.length!et.includes(lt));Dq(r,1+Hq(ft));const dt=JSON.stringify({Event:{EventName:"Retracting",ID:t==null?void 0:t.ID,Info:tt==null?void 0:tt.id}});if(!(s&&s.some(lt=>lt[0]==="Retracting")))return;console.log(dt),b.send(dt)}else console.log("Equal");f(et)},W=(et,at)=>{var tt;return at?vt.jsxs("div",{style:{display:"flex",alignItems:"center"},children:[vt.jsx("img",{src:`${Zi()}${(tt=E==null?void 0:E.Properties)==null?void 0:tt.Files[at-1]}`}),vt.jsx("div",{children:et})]}):vt.jsx("span",{onKeyDown:ft=>console.log({e:ft}),children:et})};for(let et=0;et=1){F++;const ft={id:F,title:tt};let dt=I[I.length-1];for(let ht=1;ht{const tt=JSON.stringify({Event:{EventName:"ItemDown",ID:t==null?void 0:t.ID,Info:[et,1,at,4]}}),ft=new Array(F).fill(0);ft[et-1]=1;const dt=JSON.stringify({Event:{SelItems:ft}});localStorage.setItem(t==null?void 0:t.ID,dt),s&&s.some(lt=>lt[0]==="ItemDown")&&(console.log(tt),b.send(tt))},G=(et,at)=>{var mt;const{selectedNodes:tt,nativeEvent:ft}=at,dt=ft.altKey?4:0,ht=ft.ctrlKey?2:0,lt=ft.shiftKey?1:0;ft.button;let yt=dt+ht+lt;tt.length!=0&&$((mt=tt[0])==null?void 0:mt.id,yt)},Z=(et,at)=>{const tt=JSON.stringify({Event:{EventName:"ItemDblClick",ID:t==null?void 0:t.ID,Info:[et,1,at,4]}}),ft=new Array(F).fill(0);ft[et-1]=1;const dt=JSON.stringify({Event:{SelItems:ft}});localStorage.setItem(t==null?void 0:t.ID,dt),s&&s.some(lt=>lt[0]==="ItemDblClick")&&(console.log(tt),b.send(tt))},K=(et,at)=>{const{nativeEvent:tt}=at,ft=tt!=null&&tt.altKey?4:0,dt=tt!=null&&tt.ctrlKey?2:0,ht=tt!=null&&tt.shiftKey?1:0;tt==null||tt.button;let lt=ft+dt+ht;Z(at.id,lt)};return _.useEffect(()=>{localStorage.setItem(t.ID,JSON.stringify({Event:{SelItems:new Array(n.length).fill(0)}}))},[]),vt.jsx("div",{id:t==null?void 0:t.ID,style:{...M,border:"1px solid black",background:"white",paddingLeft:"2px",paddingTop:"3px",display:a==0?"none":"block",overflowY:"scroll",...h},onMouseDown:et=>{Q1(et,b,s,t==null?void 0:t.ID)},onMouseUp:et=>{tr(et,b,s,t==null?void 0:t.ID)},onMouseEnter:et=>{er(et,b,s,t==null?void 0:t.ID)},onMouseMove:et=>{ir(et,b,s,t==null?void 0:t.ID)},onMouseLeave:et=>{rr(et,b,s,t==null?void 0:t.ID)},onWheel:et=>{lr(et,b,s,t==null?void 0:t.ID)},onDoubleClick:et=>{gr(et,b,s,t==null?void 0:t.ID)},children:vt.jsx(Zx,{onDoubleClick:K,onSelect:G,onKeyDown:et=>Ln(et,b,s,t==null?void 0:t.ID),onExpand:R,expandAction:"click",treeData:I,showIcon:!1,showLine:!0,style:{fontSize:"12px",lineHeight:"15px",margin:0,padding:0}})})},AQ=({data:t})=>{const{socket:r}=x1(),n=Gr(t==null?void 0:t.Properties),{Items:i,SelItems:o,Visible:a,Size:s,Event:l,CSS:h}=t==null?void 0:t.Properties,p=$1(h),f=_.useRef(),[g,b]=_.useState(1),[z,M]=_.useState(o),I=y4(document.getElementById(G1(t==null?void 0:t.ID))),[F,H]=_.useState(s[1]);_.useEffect(()=>{H((I==null?void 0:I.width)-50)},[I]);const E={background:"#1264FF",color:"white",cursor:"pointer"},R=W=>{const $=o.length;let G=Array($).fill(0);G[W]=1,localStorage.setItem(t==null?void 0:t.ID,JSON.stringify({Event:{ID:t==null?void 0:t.ID,SelItems:G}})),M(G)};return vt.jsx("div",{ref:f,style:{...n,width:F,border:"1px solid black",display:a==0?"none":"block"},onMouseDown:W=>{Q1(W,r,l,t==null?void 0:t.ID)},onMouseUp:W=>{tr(W,r,l,t==null?void 0:t.ID)},onMouseEnter:W=>{er(W,r,l,t==null?void 0:t.ID)},onMouseMove:W=>{ir(W,r,l,t==null?void 0:t.ID)},onMouseLeave:W=>{rr(W,r,l,t==null?void 0:t.ID)},onWheel:W=>{lr(W,r,l,t==null?void 0:t.ID)},onDoubleClick:W=>{gr(W,r,l,t==null?void 0:t.ID)},onKeyDown:W=>{Ln(W,r,l,t==null?void 0:t.ID)},children:i&&i.map((W,$)=>g==z[$]?vt.jsx("div",{style:{...E,fontSize:"12px",height:"14px",display:"flex",alignItems:"center",padding:"1px",...p},children:W}):vt.jsx("div",{onClick:()=>R($),style:{cursor:"pointer",fontSize:"12px",height:"14px",padding:"1px",display:"flex",alignItems:"center",...p},children:W}))})},LQ=({data:t})=>{const{Size:r}=JSON.parse(localStorage.getItem(G1(t==null?void 0:t.ID))),{Posn:n,SplitObj1:i,SplitObj2:o,Event:a,CSS:s}=t==null?void 0:t.Properties,l=Gr(t.Properties),h=$1(s),[p,f]=_.useState({left:n&&n[1]}),[g,b]=_.useState(!1),{handleData:z,reRender:M,socket:I}=x1(),F=y4(document.getElementById(G1(t==null?void 0:t.ID))),[H,E]=_.useState(r&&r);_.useEffect(()=>{if(!p||!H)return;let K=p&&p.left&&H&&H[1]?p.left/H[1]*F.width:0;K=Math.max(0,Math.min(K,F.width-3)),f({left:K});const et=F.width-(K+3);z({ID:i,Properties:{Posn:[0,0],Size:[F.height,Math.round(K)],BCol:[255,255,255]}},"WS"),z({ID:o,Properties:{Posn:[0,Math.round(K+3)],Size:[F==null?void 0:F.height,Math.round(et)],BCol:[255,255,255]}},"WS"),localStorage.setItem(t==null?void 0:t.ID,JSON.stringify({Event:{EventName:$&&$[0],ID:t.ID,Info:[0,Math.round(K)],Size:[W,3]}})),E([F==null?void 0:F.height,F==null?void 0:F.width]),M()},[F]);let R=F.width,W=F.height;const $=a&&a[0];let G={width:"3px",height:"100%",backgroundColor:"#F0F0F0",cursor:"col-resize",position:"absolute",top:n&&n[0],left:p==null?void 0:p.left,...l,...h};_.useEffect(()=>{const K=at=>{if(g){const tt=JSON.parse(localStorage.getItem("formPositions"));let ft=at.clientX-tt[1];ft=Math.max(0,Math.min(ft,R-3));const dt=R-(ft+3);localStorage.setItem(i,JSON.stringify({Posn:[0,0],Size:[W,ft]})),localStorage.setItem(o,JSON.stringify({Posn:[0,ft+3],Size:[W,dt]})),z({ID:i,Properties:{Posn:[0,0],Size:[W,ft],BCol:[255,255,255]}},"WS"),z({ID:o,Properties:{Posn:[0,ft+3],Size:[W,dt],BCol:[255,255,255]}},"WS"),localStorage.setItem(t==null?void 0:t.ID,JSON.stringify({Event:{EventName:$&&$[0],ID:t.ID,Info:[0,ft],Size:[W,3]}})),f({left:ft}),M()}},et=()=>{if(g){b(!1);const{Event:at}=JSON.parse(localStorage.getItem(t==null?void 0:t.ID)),{Size:tt,...ft}=at;if(!(a&&(a==null?void 0:a.some(ht=>ht[0]==="EndSplit"))))return;console.log(JSON.stringify({Event:{...ft}})),I.send(JSON.stringify({Event:{...ft}}))}};return document.addEventListener("mousemove",K),document.addEventListener("mouseup",et),()=>{document.removeEventListener("mousemove",K),document.removeEventListener("mouseup",et)}},[g]);const Z=K=>{K.preventDefault(),b(!0)};return vt.jsx("div",{id:t==null?void 0:t.ID,onClick:K=>K.preventDefault(),onMouseDown:Z,style:G})},EQ=({data:t})=>{const{Size:r,Posn:n}=JSON.parse(localStorage.getItem(G1(t==null?void 0:t.ID))),{Posn:i,SplitObj1:o,SplitObj2:a,Event:s,Size:l,CSS:h}=t==null?void 0:t.Properties,p=Gr(t.Properties),f=$1(h),[g,b]=_.useState({top:i&&i[0]}),[z,M]=_.useState(!1),{handleData:I,reRender:F,socket:H}=x1(),E=y4(document.getElementById(G1(t==null?void 0:t.ID))),[R,W]=_.useState(r&&r),[$,G]=_.useState(l&&l[0]);_.useEffect(()=>{if(g&&R){if($==E.height){const tt=JSON.parse(localStorage.getItem(o)),ft=JSON.parse(localStorage.getItem(a));if(!tt&&!ft)return;const{Size:dt,Posn:ht}=tt,{Size:lt,Posn:yt}=ft;localStorage.setItem(o,JSON.stringify({Size:[Math.round(dt&&dt[0]),E.width],Posn:ht})),localStorage.setItem(a,JSON.stringify({Size:[Math.round(lt&<[0]),E.width],Posn:yt})),I({ID:o,Properties:{Posn:ht,Size:[Math.round(dt&&dt[0]),E.width]}},"WS"),I({ID:a,Properties:{Posn:yt,Size:[Math.round(lt&<[0]),E.width]}},"WS")}else{let tt=g&&g.top&&R&&R[0]?g.top/R[0]*E.height:0;tt=Math.max(0,Math.min(tt,E.height-3)),b({top:Math.round(tt)}),I({ID:o,Properties:{Posn:[0,0],Size:[Math.round(tt),E.width]}},"WS"),I({ID:a,Properties:{Posn:[Math.round(tt+3),0],Size:[Math.round((E==null?void 0:E.height)-(tt+3)),E.width]}},"WS")}G(E.height),W([E==null?void 0:E.height,E==null?void 0:E.width]),F()}},[E]);let Z=E.height;const K=s&&s[0];_.useEffect(()=>{const tt=dt=>{if(z){const ht=JSON.parse(localStorage.getItem("formPositions"));let lt=dt.clientY-ht[1];const yt=JSON.parse(localStorage.getItem(G1(t==null?void 0:t.ID))),{Size:mt}=yt;lt=Math.max(0,Math.min(lt,Z)),I({ID:o,Properties:{Posn:[0,0],Size:[lt,mt[1]]}},"WS"),I({ID:a,Properties:{Posn:[lt+3,0],Size:[Z-(lt+3),mt[1]]}},"WS"),localStorage.setItem(t==null?void 0:t.ID,JSON.stringify({Event:{EventName:K&&K[0],ID:t.ID,Info:[lt,0],Size:[3,Z]}})),b({top:lt}),F()}},ft=()=>{if(z){M(!1);const{Event:dt}=JSON.parse(localStorage.getItem(t==null?void 0:t.ID)),{Size:ht,...lt}=dt;if(!(s&&(s==null?void 0:s.some(mt=>mt[0]==="EndSplit"))))return;console.log(JSON.stringify({Event:{...lt}})),H.send(JSON.stringify({Event:{...lt}}))}};return document.addEventListener("mousemove",tt),document.addEventListener("mouseup",ft),()=>{document.removeEventListener("mousemove",tt),document.removeEventListener("mouseup",ft)}},[z]);const et=tt=>{tt.preventDefault(),M(!0)};let at={width:"100%",height:"3px",backgroundColor:"#F0F0F0",cursor:"row-resize",position:"absolute",top:g==null?void 0:g.top,left:0,...p,...f};return vt.jsx("div",{id:t==null?void 0:t.ID,style:at,onMouseDown:tt=>et(tt)})},IQ=({data:t})=>{const{Style:r,Posn:n,SplitObj1:i,SplitObj2:o,Event:a}=t==null?void 0:t.Properties,{handleData:s}=x1();let l=800,h=800;const p=a&&a[0],f=()=>{r&&r=="Horz"?Object.keys(localStorage).forEach(b=>{const z=b.split(".");if(z.length==2&&z.includes("RIGHT")){const M=JSON.parse(localStorage.getItem(b)),{Size:I}=M;localStorage.setItem(t==null?void 0:t.ID,JSON.stringify({Event:{EventName:p&&p[0],ID:t.ID,Info:n,Size:[3,I[1]]}})),localStorage.setItem(i,JSON.stringify({Size:[n[0],I[1]],Posn:[0,0]})),s({ID:i,Properties:{Posn:[0,0],Size:[n[0],I[1]],BCol:[255,255,255]}},"WS"),localStorage.setItem(o,JSON.stringify({Size:[h-(n[0]+3),I[1]],Posn:[n[0]+3,0]})),s({ID:o,Properties:{Posn:[n[0]+3,0],Size:[h-(n[0]+3),I[1]],BCol:[255,255,255]}},"WS")}}):(localStorage.setItem(t==null?void 0:t.ID,JSON.stringify({Event:{EventName:p&&p[0],ID:t.ID,Info:n,Size:[h,3]}})),localStorage.setItem(i,JSON.stringify({Size:[h,n[1]],Posn:[0,n[1]]})),localStorage.setItem(o,JSON.stringify({Size:[h,l-(n[1]+3)],Posn:[0,n[1]+3]})),s({ID:i,Properties:{BCol:[255,255,255]}},"WS"),s({ID:o,Properties:{BCol:[255,255,255]}},"WS"))};return _.useEffect(()=>{f()},[]),r&&r=="Horz"?vt.jsx(EQ,{data:t}):vt.jsx(LQ,{data:t})},HQ=({data:t})=>{var W,$;const{Visible:r,Picture:n,Border:i=1,Size:o,Flex:a=0,CSS:s,Event:l}=t==null?void 0:t.Properties,{findDesiredData:h,socket:p}=x1(),f=y4(document.getElementById(G1(t==null?void 0:t.ID))),[g,b]=_.useState(o[1]),[z,M]=_.useState(o[0]);_.useEffect(()=>{o.length||(b((f==null?void 0:f.width)-47),M((f==null?void 0:f.height)-47))},[f]);const I=h(n&&n[0]),F=$9(n&&n[1],I),H=$1(s),E=ta(t),R=Gr(t==null?void 0:t.Properties,"absolute",a);return vt.jsxs("div",{style:{...R,width:g,height:z,border:i==0?"none":"1px solid #E9E9E9",display:r==0?"none":"block",...F,...H},id:t==null?void 0:t.ID,onMouseDown:G=>{Q1(G,p,l,t==null?void 0:t.ID)},onMouseUp:G=>{tr(G,p,l,t==null?void 0:t.ID)},onMouseEnter:G=>{er(G,p,l,t==null?void 0:t.ID)},onMouseMove:G=>{ir(G,p,l,t==null?void 0:t.ID)},onMouseLeave:G=>{rr(G,p,l,t==null?void 0:t.ID)},onWheel:G=>{lr(G,p,l,t==null?void 0:t.ID)},onDoubleClick:G=>{gr(G,p,l,t==null?void 0:t.ID)},onKeyDown:G=>{Ln(G,p,l,t==null?void 0:t.ID)},children:[((W=t==null?void 0:t.Properties)==null?void 0:W.Caption)!=""&&vt.jsx("span",{style:{fontSize:"12px",position:"relative",bottom:14,left:10,background:"#F1F1F1 "},children:($=t==null?void 0:t.Properties)==null?void 0:$.Caption}),Object.keys(E).map(G=>vt.jsx(E4,{data:E[G]}))]})};var hP={color:void 0,size:void 0,className:void 0,style:void 0,attr:void 0},Lk=sr.createContext&&sr.createContext(hP),Js=globalThis&&globalThis.__assign||function(){return Js=Object.assign||function(t){for(var r,n=1,i=arguments.length;nt?t<1?1:t>r?r:t:1,Ixt=({data:t})=>{const{FA:r}=Lxt,{Align:n,Type:i,Range:o,Event:a,Visible:s,Size:l,Posn:h,VScroll:p,HScroll:f,Attach:g,CSS:b,Thumb:z}=t==null?void 0:t.Properties,M=Ext(z,o),I=i==="Scroll"&&(n==="Bottom"||f===-1),[F,H]=_.useState(M),[E,R]=_.useState(M);$1(b);const[W,$]=_.useState(!1),G=a&&a[0],Z=JSON.parse(localStorage.getItem("formDimension")),{socket:K,handleData:et,proceed:at,setProceed:tt,proceedEventArray:ft,setProceedEventArray:dt,nqEvents:ht,setNqEvents:lt}=x1(),yt=_.useRef(null),mt=_.useRef(null),gt=o;console.log("300 thumb",t,z,F),console.log("300 here",ft,ht);const _t=localStorage.getItem("keyPressEventId");_.useEffect(()=>{const Nt=_t+"ArrowClick";if(ft[Nt]||ft[Nt]===0){const Jt=Ea();if(ht.length){const{Info:He,ID:Pe}=ht.shift();localStorage.setItem("current-event","CellMove"),localStorage.setItem("keyPressEventId",Jt),K.send(JSON.stringify({Event:{EventName:"CellMove",EventID:Jt,ID:Pe,Info:He}}))}H(M);const Ie=Vt(M);Ut(Ie),le(Ie+Q2),tt(!1),dt(He=>({...He,[Nt]:0}))}},[ft[_t+"ArrowClick"]]);const At=JSON.parse(localStorage.getItem("nqCurCell"));_.useEffect(()=>{const Nt=_t+"CellMove";if((ft[Nt]||ft[Nt]===0)&&At){console.log("Inside curCell",Nt);const{Info:Jt,ID:Ie}=At;et({ID:Ie,Properties:{CurCell:[Jt[0],Jt[1]]}},"WS")}},[ft[_t+"CellMove"],M]);const bt=l?l&&l[0]:Z&&Z[0]-Q2,kt=l?l&&l[1]:Z&&Z[1]-Q2,Lt=I?kt-Q2*2-40:bt-Q2*2-40,Vt=Nt=>Nt/gt*Lt,[Rt,Ut]=_.useState(Vt(F)),Kt=Nt=>{$(!0),er(Nt,K,a,t==null?void 0:t.ID)},It=Nt=>{$(!1),rr(Nt,K,a,t==null?void 0:t.ID)},le=Nt=>{mt.current&&(mt.current.style[I?"left":"top"]=`${Nt}px`)},Bt=Nt=>{Nt.preventDefault(),Nt.stopPropagation();const Jt=I?Nt.clientX:Nt.clientY,Ie=Rt;let He=Ie;const Pe=st=>{const wt=(I?st.clientX:st.clientY)-Jt;He=Ie+wt,He=Math.max(0,Math.min(Lt,He)),le(He);const Pt=He/Lt*gt;R(Pt)},Xt=()=>{window.removeEventListener("mousemove",Pe),window.removeEventListener("mouseup",Xt);const st=He/Lt*gt,Mt=Math.round(st)||1;Ut(He);const wt=Ea();localStorage.setItem("current-event","ArrowClick"),localStorage.setItem("keyPressEventId",wt);const Pt=JSON.stringify({Event:{EventName:"Scroll",ID:t==null?void 0:t.ID,EventID:wt,Info:[0,Mt]}});localStorage.setItem(t.ID,Pt),a&&a.some(Zt=>Zt[0]==="Scroll")&&K.send(Pt)};window.addEventListener("mousemove",Pe),window.addEventListener("mouseup",Xt)},de=h||[0,0],Ft=l||[20,20],we=Nt=>{if(!(mt.current&&(Nt.target===mt.current||mt.current.contains(Nt.target)))&&mt.current&&yt.current){const Jt=yt.current.getBoundingClientRect(),Ie=I?Nt.clientX-Jt.left:Nt.clientY-Jt.top,Pe=Math.max(0,Math.min(Lt,Ie-20))/Lt*gt;R(Pe);const Xt=Ea();localStorage.setItem("current-event","ArrowClick"),localStorage.setItem("keyPressEventId",Xt);const st=JSON.stringify({Event:{EventName:G&&G[0],ID:t==null?void 0:t.ID,EventID:Xt,Info:[Math.round(E)wt[0]==="Scroll")&&K.send(st)}},Ht=()=>{const Nt=F+1;if(Nt<=gt){R(Nt);const Jt=Ea();if(console.log("Event",JSON.stringify({Event:{EventName:G&&G[0],ID:t==null?void 0:t.ID,Info:[1,Math.round(Nt)]}})),I?localStorage.setItem("horizontalScroll",JSON.stringify({oldValue:Math.round(F),newValue:Math.round(Nt)})):localStorage.setItem("verticalScroll",JSON.stringify({oldValue:Math.round(F),newValue:Math.round(Nt)})),localStorage.setItem("current-event","ArrowClick"),localStorage.setItem("keyPressEventId",Jt),!(a&&a.some(He=>He[0]==="Scroll")))return;K.send(JSON.stringify({Event:{EventName:"Scroll",EventID:Jt,ID:t==null?void 0:t.ID,Info:[1,Math.round(Nt)]}}))}},ce=()=>{const Nt=F-1;if(Nt>=1){R(Nt),console.log(JSON.stringify({Event:{EventName:G&&G[0],ID:t==null?void 0:t.ID,Info:[-1,Math.round(Nt)]}})),localStorage.setItem(t.ID,JSON.stringify({Event:{EventName:G&&G[0],ID:t==null?void 0:t.ID,Info:[-1,Math.round(Nt)]}})),I?localStorage.setItem("horizontalScroll",JSON.stringify({oldValue:Math.round(F),newValue:Math.round(Nt)})):localStorage.setItem("verticalScroll",JSON.stringify({oldValue:Math.round(F),newValue:Math.round(Nt)}));const Jt=Ea();if(localStorage.setItem("current-event","ArrowClick"),localStorage.setItem("keyPressEventId",Jt),!(a&&a.some(He=>He[0]==="Scroll")))return;K.send(JSON.stringify({Event:{EventName:"Scroll",EventID:Jt,ID:t==null?void 0:t.ID,Info:[-1,Math.round(Nt)]}}))}};_.useEffect(()=>{I?localStorage.setItem("horizontalScroll",JSON.stringify({oldValue:M,newValue:M})):localStorage.setItem("verticalScroll",JSON.stringify({oldValue:M,newValue:M}))},[]),_.useEffect(()=>{H(Math.min(z,gt)),et({ID:t==null?void 0:t.ID,Properties:{Thumb:M}},"WS")},[z]);const qt=(()=>{let Nt={};if(g){const[Jt,Ie,He,Pe]=g;(Jt==="Top"||Jt==="Bottom")&&(Nt.top=`${de[0]}px`),(Ie==="Left"||Ie==="Right")&&(Nt.left=`${de[1]}px`),(He==="Bottom"||He==="Top")&&(Nt.bottom=`${de[0]}px`),(Pe==="Right"||Pe==="Left")&&(Nt.right=`${de[1]}px`)}return Nt})(),ge={width:I?`${kt}px`:`${Ft[1]}px`,height:I?`${Ft[0]}px`:`${bt}px`,paddingLeft:I?`${Q2}px`:0,paddingRight:I?`${Q2}px`:0,paddingTop:I?0:`${Q2}px`,paddingBottom:I?0:`${Q2}px`},oe={width:I?"40px":`${Ft[1]-6}px`,height:I?`${Ft[0]-6}px`:"40px",backgroundColor:"#9E9E9E",position:"absolute",left:I?`${Rt+Q2}px`:"2px",top:I?"2px":`${Rt+Q2}px`,cursor:"pointer",borderRadius:"5px"},ue={position:"absolute",top:p===-1&&de[0]!==void 0?de[0]:0,...p===-1?{left:p===-1&&de[1]!==void 0?de[1]:0}:{right:0},display:s==0?"none":"block",...qt},xe={position:"absolute",...f===-1?{top:f===-1&&de[0]!==void 0?de[0]:0}:{bottom:0},left:f===-1&&de[1]!==void 0?de[1]:0,width:Ft[1]+"px",height:Ft[0],display:s==0?"none":"block",...qt};return vt.jsx("div",{id:t==null?void 0:t.ID,onMouseEnter:Kt,onMouseLeave:It,onWheel:Nt=>lr(Nt,K,a,t==null?void 0:t.ID),onMouseDown:Nt=>{Q1(Nt,K,a,t==null?void 0:t.ID)},onMouseUp:Nt=>{tr(Nt,K,a,t==null?void 0:t.ID)},onMouseMove:Nt=>{ir(Nt,K,a,t==null?void 0:t.ID)},onDoubleClick:Nt=>{gr(Nt,K,a,t==null?void 0:t.ID)},onKeyDown:Nt=>{Ln(Nt,K,a,t==null?void 0:t.ID)},style:I?xe:ue,children:vt.jsxs("div",{children:[I&&W?vt.jsxs(vt.Fragment,{children:[vt.jsx("div",{className:"scroll-bar-icon scroll-bar-icon-horizontal icon-style",style:{left:"0",height:`${bt}px`},onClick:ce,children:vt.jsx(r.FaCaretDown,{style:{position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)"}})}),vt.jsx("div",{className:"scroll-bar-icon scroll-bar-icon-horizontal icon-style",style:{right:"0",height:`${bt}px`},onClick:Ht,children:vt.jsx(r.FaCaretUp,{style:{position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)"}})})]}):W?vt.jsxs(vt.Fragment,{children:[vt.jsx("div",{className:"scroll-bar-icon icon-style",style:{top:"0",width:`${Ft[1]}px`},onClick:ce,children:vt.jsx(r.FaCaretUp,{style:{position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)"}})}),vt.jsx("div",{className:"scroll-bar-icon icon-style",style:{bottom:"0",width:`${Ft[1]}px`},onClick:Ht,children:vt.jsx(r.FaCaretDown,{style:{position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)"}})})]}):null,vt.jsx("div",{className:`scroll-bar ${I?"horizontal":"vertical"}`,style:ge,onMouseDown:we,ref:yt,children:vt.jsx("div",{className:"thumb",style:oe,ref:mt,onMouseDown:Bt,onKeyDown:()=>Ln(e,K,a,t==null?void 0:t.ID)})})]})})},pP=({data:t})=>{const{findDesiredData:r,socket:n,dataRef:i}=x1(),{Size:o,Posn:a,Picture:s,Visible:l,BCol:h,FlexDirection:p,JustifyContent:f,Display:g,Flex:b=0,CSS:z,Event:M}=t==null?void 0:t.Properties,I=_.useRef(null),F=Gr(t==null?void 0:t.Properties,"absolute",b),H=$1(z),E=ta(t),R=r(s&&s[0]),W=$9(s&&s[1],R,t==null?void 0:t.Properties);let $={...F,...W,...H};return console.log("App Subform",{styles:F,data:t,updatedStyles:$,flexStyles:H,Size:o,Posn:a}),_.useEffect(()=>{let G;t.ID==="F1.SCALE"?setTimeout(()=>{var Z,K,et,at,tt;G=JSON.parse(localStorage.getItem(t.ID)),G&&((Z=G.Event)==null?void 0:Z.ID)===t.ID&&(G.Event={...G.Event,Size:((K=t.Properties)==null?void 0:K.Size)||((et=G.Event)==null?void 0:et.Size),Posn:((at=t.Properties)==null?void 0:at.Posn)||((tt=G.Event)==null?void 0:tt.Posn)})},500):t.ID==="F1.BX"?localStorage.setItem(t.ID,JSON.stringify({Size:o||[600,400],Posn:a||[50,50]})):localStorage.setItem(t.ID,JSON.stringify({Size:o&&o,Posn:a&&a}))},[t]),vt.jsx("div",{id:t.ID,style:{display:l==0?"none":t!=null&&t.Properties.hasOwnProperty("Flex")?"flex":"block",background:h&&Er(h),...$},ref:I,onMouseDown:G=>{Q1(G,n,M,t==null?void 0:t.ID)},onMouseUp:G=>{tr(G,n,M,t==null?void 0:t.ID)},onMouseEnter:G=>{er(G,n,M,t==null?void 0:t.ID)},onMouseMove:G=>{ir(G,n,M,t==null?void 0:t.ID)},onMouseLeave:G=>{rr(G,n,M,t==null?void 0:t.ID)},onWheel:G=>{lr(G,n,M,t==null?void 0:t.ID)},onDoubleClick:G=>{gr(G,n,M,t==null?void 0:t.ID)},onKeyDown:G=>{Ln(G,n,M,t==null?void 0:t.ID)},children:Object.keys(E).map(G=>vt.jsx(E4,{data:E[G]}))})},dP=({data:t,handleTabClick:r,activeTab:n,bgColor:i,fontColor:o,activebgColor:a})=>{const{socket:s}=x1(),{Caption:l,Event:h,CSS:p}=t==null?void 0:t.Properties,f=h&&h[0],g=$1(p),b=Gr(t.Properties);return vt.jsx("div",{id:t.ID,onMouseDown:z=>{Q1(z,s,h,t==null?void 0:t.ID)},onMouseUp:z=>{tr(z,s,h,t==null?void 0:t.ID)},onMouseEnter:z=>{er(z,s,h,t==null?void 0:t.ID)},onMouseMove:z=>{ir(z,s,h,t==null?void 0:t.ID)},onMouseLeave:z=>{rr(z,s,h,t==null?void 0:t.ID)},onWheel:z=>{lr(z,s,h,t==null?void 0:t.ID)},onDoubleClick:z=>{gr(z,s,h,t==null?void 0:t.ID)},style:{border:"1px solid #DFDFDF",fontSize:"12px",paddingTop:"2px",paddingBottom:"2px",paddingLeft:"4px",paddingRight:"4px",cursor:"pointer",borderRadius:"2px",background:n==(t==null?void 0:t.ID)?Er(a||[255,255,255]):Er(i),height:"20px",borderBottom:n==(t==null?void 0:t.ID)?"0px":"1px solid #DFDFDF",color:o?Er(o):"black",fontWeight:600,...b,...g},onClick:()=>{console.log(JSON.stringify({Event:{EventName:f&&f[0],ID:t==null?void 0:t.ID,Info:[t==null?void 0:t.ID]}})),localStorage.setItem("lastEvent",JSON.stringify({Event:{EventName:f&&f[0],ID:t==null?void 0:t.ID,Info:[t==null?void 0:t.ID]}})),s.send(JSON.stringify({Event:{EventName:f&&f[0],ID:t==null?void 0:t.ID,Info:[t==null?void 0:t.ID]}})),r(t.ID)},children:l})},Hxt=({data:t})=>{const{BCol:r,FCol:n,ActiveBCol:i,CSS:o}=t==null?void 0:t.Properties;let a=Gr(t==null?void 0:t.Properties);const s=$1(o),l=ta(t),h=Sq(l),[p,f]=_.useState(h),{Visible:g}=t==null?void 0:t.Properties,b={...a,display:g==0?"none":"block"},z=M=>{f(M)};return vt.jsxs("div",{id:t==null?void 0:t.ID,style:{...b,...s},children:[vt.jsx("div",{style:{display:"flex",alignItems:"end",marginLeft:"3px"},children:Object.keys(l).map(M=>{var I;return((I=l[M])==null?void 0:I.Properties.Type)=="TabButton"?vt.jsx(dP,{bgColor:r,fontColor:n,activebgColor:i,activeTab:p||h,data:l[M],handleTabClick:z}):null})}),Object.keys(l).map(M=>{var F,H,E,R;const I=p||h;return((H=(F=l[M])==null?void 0:F.Properties)==null?void 0:H.Type)=="SubForm"&&I==((R=(E=l[M])==null?void 0:E.Properties)==null?void 0:R.TabObj)?vt.jsx(pP,{data:l[M]}):null})]})};const Dxt=({data:t})=>{var H;const{handleData:r,socket:n,dataRef:i}=x1(),o=_.useRef(null),a=()=>{var E;if((E=t==null?void 0:t.Properties)!=null&&E.Text)return Array.isArray(t.Properties.Text)?t.Properties.Text.join(` +`):t.Properties.Text;{const R=localStorage.getItem(t.ID);return R&&JSON.parse(R).Text||""}},[s,l]=_.useState(a);let h=Gr(t==null?void 0:t.Properties);const{Font:p,CSS:f,Event:g}=t==null?void 0:t.Properties,b=$1(f);_.useEffect(()=>{var E;if((E=t==null?void 0:t.Properties)!=null&&E.Text){localStorage.setItem(t.ID,JSON.stringify(t.Properties));const R=t==null?void 0:t.Properties.Text;r({ID:t.ID,Properties:{Text:R}},"WS");const W=Array.isArray(t.Properties.Text)?t.Properties.Text.join(` +`):t.Properties.Text;W!==s&&l(W)}},[(H=t==null?void 0:t.Properties)==null?void 0:H.Text]);let z={...h,scrollbarWidth:"thin",scrollbarColor:"transparent transparent",fontFamily:p&&p[0],fontSize:p&&`${p[1]}px`,...b};const M=E=>{const R=E.target.value;l(R),localStorage.setItem(t.ID,JSON.stringify({...t.Properties,Text:R})),r({ID:t.ID,Properties:{Text:R}},"WS")},I=s,F=(E,R)=>{switch(console.log("mousedown",g),R){case"mouseUp":tr(E,n,g,t==null?void 0:t.ID);break;case"mouseDown":Q1(E,n,g,t==null?void 0:t.ID);break;case"mouseLeave":rr(E,n,g,t==null?void 0:t.ID);break;case"mouseEnter":er(E,n,g,t==null?void 0:t.ID);break;case"mouseMove":ir(E,n,g,t==null?void 0:t.ID);break;case"mouseWheel":lr(E,n,g,t==null?void 0:t.ID);break;case"dblclick":gr(E,n,g,t==null?void 0:t.ID);break}const W=o.current;if(!W)return;const $=W.selectionStart,G=W.selectionEnd,Z=I.split(` +`),K=(ft,dt)=>{let ht=0;for(let mt=0;mtF(E,"mouseUp"),onMouseDown:E=>F(E,"mouseDown"),onMouseEnter:E=>F(E,"mouseEnter"),onMouseLeave:E=>F(E,"mouseLeave"),onMouseMove:E=>F(E,"mouseMove"),onWheel:E=>F(E,"mouseWheel"),onDoubleClick:E=>F(E,"dblclick"),spellCheck:!1})})};const Pxt=({data:t})=>{var b;const r=ta(t),{dataRef:n}=x1(),{Visible:i,Size:o,ImageListObj:a,CSS:s,FontObj:l}=t==null?void 0:t.Properties,h=JSON.parse(localStorage.getItem("formDimension")),p=$1(s),f=gD(a);console.log("Dtaatataat is as",(b=t==null?void 0:t.Properties)==null?void 0:b.BodyHeight);const g=f&&JSON.parse(ji(n.current,f));return vt.jsx("div",{id:t==null?void 0:t.ID,className:"row",style:{backgroundColor:"rgb(134,171,220)",width:o?o&&o[1]:h&&h[1],display:i==0?"none":"flex",...p},children:Object.keys(r).map((z,M)=>vt.jsx(E4,{data:{...r[z],FontObj:l,id:M,ImageList:g}},M))})},Txt=({data:t})=>{var R,W;const{findCurrentData:r,fontScale:n,handleData:i,dataRef:o}=x1();console.log("Dattatatatatatta",o.current.F1);const a=ta(t),{Size:s,Title:l,BorderCol:h,CSS:p}=t==null?void 0:t.Properties,f=$1(p),g=r(t.FontObj&&t.FontObj),b=g&&(g==null?void 0:g.Properties),[z,M]=_.useState("auto"),[I,F]=_.useState("auto"),[H,E]=_.useState(100);return _.useEffect(()=>{console.log("Coming hereeeeeeeeee in ss");const $=()=>{setTimeout(()=>{var yt,mt;const G=document.getElementById(t.ID+"-title"),Z=document.getElementById(`ribbon-item-height-${t.id}`),K=document.querySelectorAll(`[id^="ribbon-item-height-${t.id}"]`),et=document.querySelectorAll('[id^="ribbon-height"]');let at=0,tt=0,ft=0;K.forEach(gt=>{const _t=gt.getBoundingClientRect().height||0;at=Math.max(at,_t)}),K.forEach(gt=>{const _t=gt.getBoundingClientRect().width||0;tt+=_t}),K.forEach(gt=>{const _t=gt.getBoundingClientRect().height||0;ft+=_t});const dt=Math.max(tt,ft),ht=(G==null?void 0:G.getBoundingClientRect().width)||0,lt=(Z==null?void 0:Z.getBoundingClientRect().width)||0;K.length>1?M(`${Math.max(dt+lt,ht)}px`):M(`${Math.max(dt,ht)}px`),((mt=(yt=o.current.F1)==null?void 0:yt.Properties)==null?void 0:mt.Caption)==="Big Ribbon Test"||l==="DropDown"?E(50):E(gt=>Math.max(gt,at)),setTimeout(()=>{et.forEach(gt=>{const _t=(G==null?void 0:G.getBoundingClientRect().height)||0;gt.style.height=`${H+_t+20}px`,console.log("Maxxxx value seeeeettt",H,_t,gt.style.height,t.ID,t.id)})},100)},300)};return $(),window.addEventListener("resize",$),()=>window.removeEventListener("resize",$)},[t.ID,t.id,(W=(R=o.current.F1)==null?void 0:R.Properties)==null?void 0:W.Caption,H]),vt.jsx("div",{id:t==null?void 0:t.ID,style:{width:z},children:vt.jsxs("div",{style:{border:`1px solid ${Er(h)}`,borderTop:0,position:"relative",height:I+18,justifyContent:"space-around",paddingTop:"3px",...f},id:"ribbon-height",className:"row",children:[Object.keys(a).map(($,G)=>vt.jsx(E4,{data:{...a[$],FontObj:t.FontObj,id:t.id,ImageList:t.ImageList}},G)),vt.jsx("div",{children:vt.jsx("p",{id:t.ID+"-title",style:{position:"absolute",bottom:0,backgroundColor:"rgb(204, 204, 204)",margin:0,fontWeight:"bolder",fontFamily:b==null?void 0:b.PName,fontSize:b!=null&&b.Size?`${b.Size*n}px`:`${12*n}px`,minWidth:"max-content",width:"100%",paddingLeft:"10px",paddingRight:"10px"},className:"text-center",children:l})})]})})},Vxt=({data:t})=>{const r=ta(t),{CSS:n}=t==null?void 0:t.Properties,i=$1(n);return vt.jsx("div",{"data-alt-id":t==null?void 0:t.ID,id:`ribbon-item-height-${t.id}`,style:{display:"flex",justifyContent:"center",...i,width:"max-content"},children:Object.keys(r).map((o,a)=>vt.jsx(E4,{data:{...r[o],FontObj:t.FontObj,ImageList:t.ImageList}},a))})};function Fxt(t){return C({tag:"svg",attr:{version:"1",viewBox:"0 0 48 48",enableBackground:"new 0 0 48 48"},child:[{tag:"path",attr:{fill:"#CFD8DC",d:"M5,38V14h38v24c0,2.2-1.8,4-4,4H9C6.8,42,5,40.2,5,38z"}},{tag:"path",attr:{fill:"#F44336",d:"M43,10v6H5v-6c0-2.2,1.8-4,4-4h30C41.2,6,43,7.8,43,10z"}},{tag:"g",attr:{fill:"#B71C1C"},child:[{tag:"circle",attr:{cx:"33",cy:"10",r:"3"}},{tag:"circle",attr:{cx:"15",cy:"10",r:"3"}}]},{tag:"g",attr:{fill:"#B0BEC5"},child:[{tag:"path",attr:{d:"M33,3c-1.1,0-2,0.9-2,2v5c0,1.1,0.9,2,2,2s2-0.9,2-2V5C35,3.9,34.1,3,33,3z"}},{tag:"path",attr:{d:"M15,3c-1.1,0-2,0.9-2,2v5c0,1.1,0.9,2,2,2s2-0.9,2-2V5C17,3.9,16.1,3,15,3z"}}]},{tag:"g",attr:{fill:"#90A4AE"},child:[{tag:"rect",attr:{x:"13",y:"20",width:"4",height:"4"}},{tag:"rect",attr:{x:"19",y:"20",width:"4",height:"4"}},{tag:"rect",attr:{x:"25",y:"20",width:"4",height:"4"}},{tag:"rect",attr:{x:"31",y:"20",width:"4",height:"4"}},{tag:"rect",attr:{x:"13",y:"26",width:"4",height:"4"}},{tag:"rect",attr:{x:"19",y:"26",width:"4",height:"4"}},{tag:"rect",attr:{x:"25",y:"26",width:"4",height:"4"}},{tag:"rect",attr:{x:"31",y:"26",width:"4",height:"4"}},{tag:"rect",attr:{x:"13",y:"32",width:"4",height:"4"}},{tag:"rect",attr:{x:"19",y:"32",width:"4",height:"4"}},{tag:"rect",attr:{x:"25",y:"32",width:"4",height:"4"}},{tag:"rect",attr:{x:"31",y:"32",width:"4",height:"4"}}]}]})(t)}function Rxt(t){return C({tag:"svg",attr:{version:"1",viewBox:"0 0 48 48",enableBackground:"new 0 0 48 48"},child:[{tag:"path",attr:{fill:"#F44336",d:"M21.2,44.8l-18-18c-1.6-1.6-1.6-4.1,0-5.7l18-18c1.6-1.6,4.1-1.6,5.7,0l18,18c1.6,1.6,1.6,4.1,0,5.7l-18,18 C25.3,46.4,22.7,46.4,21.2,44.8z"}},{tag:"path",attr:{fill:"#fff",d:"M21.6,32.7c0-0.3,0.1-0.6,0.2-0.9c0.1-0.3,0.3-0.5,0.5-0.7c0.2-0.2,0.5-0.4,0.8-0.5s0.6-0.2,1-0.2 s0.7,0.1,1,0.2c0.3,0.1,0.6,0.3,0.8,0.5c0.2,0.2,0.4,0.4,0.5,0.7c0.1,0.3,0.2,0.6,0.2,0.9s-0.1,0.6-0.2,0.9s-0.3,0.5-0.5,0.7 c-0.2,0.2-0.5,0.4-0.8,0.5c-0.3,0.1-0.6,0.2-1,0.2s-0.7-0.1-1-0.2s-0.5-0.3-0.8-0.5c-0.2-0.2-0.4-0.4-0.5-0.7S21.6,33.1,21.6,32.7z M25.8,28.1h-3.6L21.7,13h4.6L25.8,28.1z"}}]})(t)}function Oxt(t){return C({tag:"svg",attr:{version:"1",viewBox:"0 0 48 48",enableBackground:"new 0 0 48 48"},child:[{tag:"polygon",attr:{fill:"#E8EAF6",points:"42,39 6,39 6,23 24,6 42,23"}},{tag:"g",attr:{fill:"#C5CAE9"},child:[{tag:"polygon",attr:{points:"39,21 34,16 34,9 39,9"}},{tag:"rect",attr:{x:"6",y:"39",width:"36",height:"5"}}]},{tag:"polygon",attr:{fill:"#B71C1C",points:"24,4.3 4,22.9 6,25.1 24,8.4 42,25.1 44,22.9"}},{tag:"rect",attr:{x:"18",y:"28",fill:"#D84315",width:"12",height:"16"}},{tag:"rect",attr:{x:"21",y:"17",fill:"#01579B",width:"6",height:"6"}},{tag:"path",attr:{fill:"#FF8A65",d:"M27.5,35.5c-0.3,0-0.5,0.2-0.5,0.5v2c0,0.3,0.2,0.5,0.5,0.5S28,38.3,28,38v-2C28,35.7,27.8,35.5,27.5,35.5z"}}]})(t)}function Bxt(t){return C({tag:"svg",attr:{version:"1",viewBox:"0 0 48 48",enableBackground:"new 0 0 48 48"},child:[{tag:"circle",attr:{fill:"#2196F3",cx:"24",cy:"24",r:"21"}},{tag:"rect",attr:{x:"22",y:"22",fill:"#fff",width:"4",height:"11"}},{tag:"circle",attr:{fill:"#fff",cx:"24",cy:"16.5",r:"2.5"}}]})(t)}function Nxt(t){return C({tag:"svg",attr:{version:"1",viewBox:"0 0 48 48",enableBackground:"new 0 0 48 48"},child:[{tag:"path",attr:{fill:"#37474F",d:"M8,41V7c0-2.2,1.8-4,4-4h24c2.2,0,4,1.8,4,4v34c0,2.2-1.8,4-4,4H12C9.8,45,8,43.2,8,41z"}},{tag:"path",attr:{fill:"#eee",d:"M35,6H13c-0.6,0-1,0.4-1,1v29c0,0.6,0.4,1,1,1h22c0.6,0,1-0.4,1-1V7C36,6.4,35.6,6,35,6z"}},{tag:"rect",attr:{x:"20",y:"40",fill:"#546E7A",width:"8",height:"2"}},{tag:"g",attr:{fill:"#A1A1A1"},child:[{tag:"rect",attr:{x:"16",y:"11",width:"16",height:"3"}},{tag:"rect",attr:{x:"16",y:"18",width:"16",height:"2"}},{tag:"rect",attr:{x:"16",y:"22",width:"12",height:"2"}},{tag:"rect",attr:{x:"16",y:"26",width:"16",height:"2"}},{tag:"rect",attr:{x:"16",y:"30",width:"12",height:"2"}}]}]})(t)}function $xt(t){return C({tag:"svg",attr:{version:"1",viewBox:"0 0 48 48",enableBackground:"new 0 0 48 48"},child:[{tag:"g",attr:{fill:"#FF9800"},child:[{tag:"rect",attr:{x:"1",y:"38",width:"46",height:"2"}},{tag:"rect",attr:{x:"25",y:"18",width:"4",height:"16"}},{tag:"rect",attr:{x:"31",y:"18",width:"4",height:"16"}},{tag:"rect",attr:{x:"37",y:"18",width:"4",height:"16"}},{tag:"rect",attr:{x:"19",y:"18",width:"4",height:"16"}},{tag:"rect",attr:{x:"13",y:"18",width:"4",height:"16"}},{tag:"rect",attr:{x:"7",y:"18",width:"4",height:"16"}},{tag:"polygon",attr:{points:"43,16 5,16 5,13 24,4 43,13"}},{tag:"rect",attr:{x:"5",y:"34",width:"38",height:"2"}}]},{tag:"g",attr:{fill:"#EF6C00"},child:[{tag:"rect",attr:{x:"25",y:"16",width:"4",height:"2"}},{tag:"rect",attr:{x:"31",y:"16",width:"4",height:"2"}},{tag:"rect",attr:{x:"37",y:"16",width:"4",height:"2"}},{tag:"rect",attr:{x:"19",y:"16",width:"4",height:"2"}},{tag:"rect",attr:{x:"13",y:"16",width:"4",height:"2"}},{tag:"rect",attr:{x:"7",y:"16",width:"4",height:"2"}},{tag:"rect",attr:{x:"3",y:"36",width:"42",height:"2"}},{tag:"circle",attr:{cx:"24",cy:"11",r:"2"}}]}]})(t)}function Wxt(t){return C({tag:"svg",attr:{version:"1",viewBox:"0 0 48 48",enableBackground:"new 0 0 48 48"},child:[{tag:"path",attr:{fill:"#424242",d:"M24,4c-5.5,0-10,4.5-10,10v4h4v-4c0-3.3,2.7-6,6-6s6,2.7,6,6v4h4v-4C34,8.5,29.5,4,24,4z"}},{tag:"path",attr:{fill:"#FB8C00",d:"M36,44H12c-2.2,0-4-1.8-4-4V22c0-2.2,1.8-4,4-4h24c2.2,0,4,1.8,4,4v18C40,42.2,38.2,44,36,44z"}},{tag:"circle",attr:{fill:"#C76E00",cx:"24",cy:"31",r:"3"}}]})(t)}function jxt(t){return C({tag:"svg",attr:{version:"1",viewBox:"0 0 48 48",enableBackground:"new 0 0 48 48"},child:[{tag:"path",attr:{fill:"#78909C",d:"M40,41H8c-2.2,0-4-1.8-4-4l0-20.9c0-1.3,0.6-2.5,1.7-3.3L24,0l18.3,12.8c1.1,0.7,1.7,2,1.7,3.3V37 C44,39.2,42.2,41,40,41z"}},{tag:"rect",attr:{x:"14",y:"1",fill:"#AED581",width:"20",height:"31"}},{tag:"g",attr:{fill:"#558B2F"},child:[{tag:"path",attr:{d:"M13,0v33h22V0H13z M33,31H15V2h18V31z"}},{tag:"path",attr:{d:"M34,3c0,1.7-0.3,3-2,3c-1.7,0-3-1.3-3-3s1.3-2,3-2C33.7,1,34,1.3,34,3z"}},{tag:"path",attr:{d:"M16,1c1.7,0,3,0.3,3,2s-1.3,3-3,3s-2-1.3-2-3S14.3,1,16,1z"}},{tag:"circle",attr:{cx:"24",cy:"8",r:"2"}},{tag:"circle",attr:{cx:"24",cy:"20",r:"6"}}]},{tag:"path",attr:{fill:"#CFD8DC",d:"M40,41H8c-2.2,0-4-1.8-4-4l0-20l20,13l20-13v20C44,39.2,42.2,41,40,41z"}}]})(t)}function Gxt(t){return C({tag:"svg",attr:{version:"1",viewBox:"0 0 48 48",enableBackground:"new 0 0 48 48"},child:[{tag:"path",attr:{fill:"#CFD8DC",d:"M5,38V14h38v24c0,2.2-1.8,4-4,4H9C6.8,42,5,40.2,5,38z"}},{tag:"path",attr:{fill:"#F44336",d:"M43,10v6H5v-6c0-2.2,1.8-4,4-4h30C41.2,6,43,7.8,43,10z"}},{tag:"g",attr:{fill:"#B71C1C"},child:[{tag:"circle",attr:{cx:"33",cy:"10",r:"3"}},{tag:"circle",attr:{cx:"15",cy:"10",r:"3"}}]},{tag:"g",attr:{fill:"#B0BEC5"},child:[{tag:"path",attr:{d:"M33,3c-1.1,0-2,0.9-2,2v5c0,1.1,0.9,2,2,2s2-0.9,2-2V5C35,3.9,34.1,3,33,3z"}},{tag:"path",attr:{d:"M15,3c-1.1,0-2,0.9-2,2v5c0,1.1,0.9,2,2,2s2-0.9,2-2V5C17,3.9,16.1,3,15,3z"}}]},{tag:"g",attr:{fill:"#B0BEC5"},child:[{tag:"rect",attr:{x:"13",y:"21",width:"6",height:"6"}},{tag:"rect",attr:{x:"21",y:"21",width:"6",height:"6"}},{tag:"rect",attr:{x:"29",y:"21",width:"6",height:"6"}},{tag:"rect",attr:{x:"13",y:"29",width:"6",height:"6"}},{tag:"rect",attr:{x:"21",y:"29",width:"6",height:"6"}}]},{tag:"rect",attr:{x:"29",y:"29",fill:"#F44336",width:"6",height:"6"}}]})(t)}function Uxt(t){return C({tag:"svg",attr:{version:"1",viewBox:"0 0 48 48",enableBackground:"new 0 0 48 48"},child:[{tag:"circle",attr:{fill:"#FFB74D",cx:"24",cy:"11",r:"6"}},{tag:"path",attr:{fill:"#607D8B",d:"M36,26.1c0,0-3.3-7.1-12-7.1s-12,7.1-12,7.1V30h24V26.1z"}},{tag:"polygon",attr:{fill:"#B0BEC5",points:"41,25 7,25 6,29 11,32 9,29 39,29 37,32 42,29"}},{tag:"polygon",attr:{fill:"#78909C",points:"9,29 39,29 35,41 13,41"}}]})(t)}function Yxt(t){return C({tag:"svg",attr:{version:"1",viewBox:"0 0 48 48",enableBackground:"new 0 0 48 48"},child:[{tag:"g",attr:{fill:"#616161"},child:[{tag:"rect",attr:{x:"34.6",y:"28.1",transform:"matrix(.707 -.707 .707 .707 -15.154 36.586)",width:"4",height:"17"}},{tag:"circle",attr:{cx:"20",cy:"20",r:"16"}}]},{tag:"rect",attr:{x:"36.2",y:"32.1",transform:"matrix(.707 -.707 .707 .707 -15.839 38.239)",fill:"#37474F",width:"4",height:"12.3"}},{tag:"circle",attr:{fill:"#64B5F6",cx:"20",cy:"20",r:"13"}},{tag:"path",attr:{fill:"#BBDEFB",d:"M26.9,14.2c-1.7-2-4.2-3.2-6.9-3.2s-5.2,1.2-6.9,3.2c-0.4,0.4-0.3,1.1,0.1,1.4c0.4,0.4,1.1,0.3,1.4-0.1 C16,13.9,17.9,13,20,13s4,0.9,5.4,2.5c0.2,0.2,0.5,0.4,0.8,0.4c0.2,0,0.5-0.1,0.6-0.2C27.2,15.3,27.2,14.6,26.9,14.2z"}}]})(t)}function Xxt(t){return C({tag:"svg",attr:{version:"1",viewBox:"0 0 48 48",enableBackground:"new 0 0 48 48"},child:[{tag:"path",attr:{fill:"#1976D2",d:"M38.1,31.2L19.4,24l18.7-7.2c1.5-0.6,2.3-2.3,1.7-3.9c-0.6-1.5-2.3-2.3-3.9-1.7l-26,10C8.8,21.6,8,22.8,8,24 s0.8,2.4,1.9,2.8l26,10c0.4,0.1,0.7,0.2,1.1,0.2c1.2,0,2.3-0.7,2.8-1.9C40.4,33.5,39.6,31.8,38.1,31.2z"}},{tag:"g",attr:{fill:"#1E88E5"},child:[{tag:"circle",attr:{cx:"11",cy:"24",r:"7"}},{tag:"circle",attr:{cx:"37",cy:"14",r:"7"}},{tag:"circle",attr:{cx:"37",cy:"34",r:"7"}}]}]})(t)}function Kxt(t){return C({tag:"svg",attr:{version:"1",viewBox:"0 0 48 48",enableBackground:"new 0 0 48 48"},child:[{tag:"polygon",attr:{fill:"#90CAF9",points:"36.9,13.8 35.1,10.2 7.5,24 35.1,37.8 36.9,34.2 16.5,24"}},{tag:"rect",attr:{x:"6",y:"18",fill:"#D81B60",width:"12",height:"12"}},{tag:"g",attr:{fill:"#2196F3"},child:[{tag:"rect",attr:{x:"30",y:"6",width:"12",height:"12"}},{tag:"rect",attr:{x:"30",y:"30",width:"12",height:"12"}}]}]})(t)}const c0=Object.freeze(Object.defineProperty({__proto__:null,FcCalendar:Fxt,FcHighPriority:Rxt,FcHome:Oxt,FcKindle:Nxt,FcLibrary:$xt,FcLock:Wxt,FcMoneyTransfer:jxt,FcPlanner:Gxt,FcPodiumWithSpeaker:Uxt,FcSearch:Yxt,FcShare:Xxt,FcTreeStructure:Kxt},Symbol.toStringTag,{value:"Module"}));var fP={exports:{}},qxt="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED",Zxt=qxt,Jxt=Zxt;function vP(){}function gP(){}gP.resetWarningCache=vP;var Qxt=function(){function t(i,o,a,s,l,h){if(h!==Jxt){var p=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw p.name="Invariant Violation",p}}t.isRequired=t;function r(){return t}var n={array:t,bigint:t,bool:t,func:t,number:t,object:t,string:t,symbol:t,any:t,arrayOf:r,element:t,elementType:t,instanceOf:r,node:t,objectOf:r,oneOf:r,oneOfType:r,shape:r,exact:r,checkPropTypes:gP,resetWarningCache:vP};return n.PropTypes=n,n};fP.exports=Qxt();var mP=fP.exports;const B=_8(mP);function Du(t){"@babel/helpers - typeof";return Du=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(r){return typeof r}:function(r){return r&&typeof Symbol=="function"&&r.constructor===Symbol&&r!==Symbol.prototype?"symbol":typeof r},Du(t)}var tbt;function Jx(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"",r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:tbt;return r?t.split(" ").map(function(n){return r[n]||n}).join(" "):t}var Ek={};function ebt(t){Ek[t]||(typeof console<"u"&&console.error(t),Ek[t]=!0)}function rbt(t,r){return function(i,o,a){i[o]!==null&&typeof i[o]<"u"&&ebt('"'.concat(o,'" property of "').concat(a,`" has been deprecated. +`).concat(r));for(var s=arguments.length,l=new Array(s>3?s-3:0),h=3;h"u"?"undefined":Du(window))==="object"&&window.Element||function(){};function nbt(t,r,n){if(!(t[r]instanceof ibt))return new Error("Invalid prop `"+r+"` supplied to `"+n+"`. Expected prop to be an instance of Element. Validation failed.")}B.oneOfType([B.string,B.func,nbt,B.shape({current:B.any})]);var yP=B.oneOfType([B.func,B.string,B.shape({$$typeof:B.symbol,render:B.func}),B.arrayOf(B.oneOfType([B.func,B.string,B.shape({$$typeof:B.symbol,render:B.func})]))]);function obt(t){var r=Du(t);return t!=null&&(r==="object"||r==="function")}var abt=["className","cssModule","noGutters","tag","widths"];function tm(){return tm=Object.assign?Object.assign.bind():function(t){for(var r=1;r=0)&&Object.prototype.propertyIsEnumerable.call(t,i)&&(n[i]=t[i])}return n}function lbt(t,r){if(t==null)return{};var n={},i=Object.keys(t),o,a;for(a=0;a=0)&&(n[o]=t[o]);return n}var cbt=["xs","sm","md","lg","xl","xxl"],u3=B.oneOfType([B.number,B.string]),hbt={tag:yP,noGutters:rbt(B.bool,"Please use Bootstrap 5 gutter utility classes. https://getbootstrap.com/docs/5.0/layout/gutters/"),className:B.string,cssModule:B.object,xs:u3,sm:u3,md:u3,lg:u3,xl:u3,xxl:u3,widths:B.array};function Qx(t){var r=t.className,n=t.cssModule,i=t.noGutters,o=t.tag,a=o===void 0?"div":o,s=t.widths,l=s===void 0?cbt:s,h=sbt(t,abt),p=[];l.forEach(function(g,b){var z=t[g];if(delete h[g],!!z){var M=!b;p.push(M?"row-cols-".concat(z):"row-cols-".concat(g,"-").concat(z))}});var f=Jx(bi(r,i?"gx-0":null,"row",p),n);return sr.createElement(a,tm({},h,{className:f}))}Qx.propTypes=hbt;var ubt=["className","cssModule","widths","tag"];function em(){return em=Object.assign?Object.assign.bind():function(t){for(var r=1;r=0)&&Object.prototype.propertyIsEnumerable.call(t,i)&&(n[i]=t[i])}return n}function dbt(t,r){if(t==null)return{};var n={},i=Object.keys(t),o,a;for(a=0;a=0)&&(n[o]=t[o]);return n}function Kf(t,r,n){return r in t?Object.defineProperty(t,r,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[r]=n,t}var xP=["xs","sm","md","lg","xl","xxl"],Ik=B.oneOfType([B.number,B.string]),p3=B.oneOfType([B.bool,B.number,B.string,B.shape({size:B.oneOfType([B.bool,B.number,B.string]),order:Ik,offset:Ik})]),fbt={tag:yP,xs:p3,sm:p3,md:p3,lg:p3,xl:p3,xxl:p3,className:B.string,cssModule:B.object,widths:B.array},Hk=function(r,n,i){return i===!0||i===""?r?"col":"col-".concat(n):i==="auto"?r?"col-auto":"col-".concat(n,"-auto"):r?"col-".concat(i):"col-".concat(n,"-").concat(i)},vbt=function(r,n){var i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:xP,o=r,a=[];return i.forEach(function(s,l){var h=o[s];if(delete o[s],!(!h&&h!=="")){var p=!l;if(obt(h)){var f,g=p?"-":"-".concat(s,"-"),b=Hk(p,s,h.size);a.push(Jx(bi((f={},Kf(f,b,h.size||h.size===""),Kf(f,"order".concat(g).concat(h.order),h.order||h.order===0),Kf(f,"offset".concat(g).concat(h.offset),h.offset||h.offset===0),f)),n))}else{var z=Hk(p,s,h);a.push(z)}}}),{colClasses:a,modifiedAttributes:o}};function ip(t){var r=t.className,n=t.cssModule,i=t.widths,o=i===void 0?xP:i,a=t.tag,s=a===void 0?"div":a,l=pbt(t,ubt),h=vbt(l,n,o),p=h.modifiedAttributes,f=h.colClasses;f.length||f.push("col");var g=Jx(bi(r,f),n);return sr.createElement(s,em({},p,{className:g}))}ip.propTypes=fbt;function tb(t,r){t.prototype=Object.create(r.prototype),t.prototype.constructor=t,ku(t,r)}function gbt(t,r){return t.classList?!!r&&t.classList.contains(r):(" "+(t.className.baseVal||t.className)+" ").indexOf(" "+r+" ")!==-1}function mbt(t,r){t.classList?t.classList.add(r):gbt(t,r)||(typeof t.className=="string"?t.className=t.className+" "+r:t.setAttribute("class",(t.className&&t.className.baseVal||"")+" "+r))}function Dk(t,r){return t.replace(new RegExp("(^|\\s)"+r+"(?:\\s|$)","g"),"$1").replace(/\s+/g," ").replace(/^\s*|\s*$/g,"")}function ybt(t,r){t.classList?t.classList.remove(r):typeof t.className=="string"?t.className=Dk(t.className,r):t.setAttribute("class",Dk(t.className&&t.className.baseVal||"",r))}const Pk={disabled:!1},Pu=sr.createContext(null);var bP=function(r){return r.scrollTop},tc="unmounted",Y4="exited",X4="entering",z3="entered",rm="exiting",is=function(t){tb(r,t);function r(i,o){var a;a=t.call(this,i,o)||this;var s=o,l=s&&!s.isMounting?i.enter:i.appear,h;return a.appearStatus=null,i.in?l?(h=Y4,a.appearStatus=X4):h=z3:i.unmountOnExit||i.mountOnEnter?h=tc:h=Y4,a.state={status:h},a.nextCallback=null,a}r.getDerivedStateFromProps=function(o,a){var s=o.in;return s&&a.status===tc?{status:Y4}:null};var n=r.prototype;return n.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},n.componentDidUpdate=function(o){var a=null;if(o!==this.props){var s=this.state.status;this.props.in?s!==X4&&s!==z3&&(a=X4):(s===X4||s===z3)&&(a=rm)}this.updateStatus(!1,a)},n.componentWillUnmount=function(){this.cancelNextCallback()},n.getTimeouts=function(){var o=this.props.timeout,a,s,l;return a=s=l=o,o!=null&&typeof o!="number"&&(a=o.exit,s=o.enter,l=o.appear!==void 0?o.appear:s),{exit:a,enter:s,appear:l}},n.updateStatus=function(o,a){if(o===void 0&&(o=!1),a!==null)if(this.cancelNextCallback(),a===X4){if(this.props.unmountOnExit||this.props.mountOnEnter){var s=this.props.nodeRef?this.props.nodeRef.current:Q6.findDOMNode(this);s&&bP(s)}this.performEnter(o)}else this.performExit();else this.props.unmountOnExit&&this.state.status===Y4&&this.setState({status:tc})},n.performEnter=function(o){var a=this,s=this.props.enter,l=this.context?this.context.isMounting:o,h=this.props.nodeRef?[l]:[Q6.findDOMNode(this),l],p=h[0],f=h[1],g=this.getTimeouts(),b=l?g.appear:g.enter;if(!o&&!s||Pk.disabled){this.safeSetState({status:z3},function(){a.props.onEntered(p)});return}this.props.onEnter(p,f),this.safeSetState({status:X4},function(){a.props.onEntering(p,f),a.onTransitionEnd(b,function(){a.safeSetState({status:z3},function(){a.props.onEntered(p,f)})})})},n.performExit=function(){var o=this,a=this.props.exit,s=this.getTimeouts(),l=this.props.nodeRef?void 0:Q6.findDOMNode(this);if(!a||Pk.disabled){this.safeSetState({status:Y4},function(){o.props.onExited(l)});return}this.props.onExit(l),this.safeSetState({status:rm},function(){o.props.onExiting(l),o.onTransitionEnd(s.exit,function(){o.safeSetState({status:Y4},function(){o.props.onExited(l)})})})},n.cancelNextCallback=function(){this.nextCallback!==null&&(this.nextCallback.cancel(),this.nextCallback=null)},n.safeSetState=function(o,a){a=this.setNextCallback(a),this.setState(o,a)},n.setNextCallback=function(o){var a=this,s=!0;return this.nextCallback=function(l){s&&(s=!1,a.nextCallback=null,o(l))},this.nextCallback.cancel=function(){s=!1},this.nextCallback},n.onTransitionEnd=function(o,a){this.setNextCallback(a);var s=this.props.nodeRef?this.props.nodeRef.current:Q6.findDOMNode(this),l=o==null&&!this.props.addEndListener;if(!s||l){setTimeout(this.nextCallback,0);return}if(this.props.addEndListener){var h=this.props.nodeRef?[this.nextCallback]:[s,this.nextCallback],p=h[0],f=h[1];this.props.addEndListener(p,f)}o!=null&&setTimeout(this.nextCallback,o)},n.render=function(){var o=this.state.status;if(o===tc)return null;var a=this.props,s=a.children;a.in,a.mountOnEnter,a.unmountOnExit,a.appear,a.enter,a.exit,a.timeout,a.addEndListener,a.onEnter,a.onEntering,a.onEntered,a.onExit,a.onExiting,a.onExited,a.nodeRef;var l=j9(a,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]);return sr.createElement(Pu.Provider,{value:null},typeof s=="function"?s(o,l):sr.cloneElement(sr.Children.only(s),l))},r}(sr.Component);is.contextType=Pu;is.propTypes={};function d3(){}is.defaultProps={in:!1,mountOnEnter:!1,unmountOnExit:!1,appear:!1,enter:!0,exit:!0,onEnter:d3,onEntering:d3,onEntered:d3,onExit:d3,onExiting:d3,onExited:d3};is.UNMOUNTED=tc;is.EXITED=Y4;is.ENTERING=X4;is.ENTERED=z3;is.EXITING=rm;const xbt=is;var bbt=function(r,n){return r&&n&&n.split(" ").forEach(function(i){return mbt(r,i)})},qf=function(r,n){return r&&n&&n.split(" ").forEach(function(i){return ybt(r,i)})},eb=function(t){tb(r,t);function r(){for(var i,o=arguments.length,a=new Array(o),s=0;s{var R,W,$,G,Z;const r=t.ImageList,{socket:n,fontScale:i,findCurrentData:o}=x1(),{Icon:a,Caption:s,Event:l,ImageIndex:h,CSS:p,ImageListObj:f}=t==null?void 0:t.Properties,g=$1(p),b=o(t.FontObj&&t.FontObj),z=b&&(b==null?void 0:b.Properties),M=o(f),I=mD(M,h),F=()=>{const K=JSON.stringify({Event:{EventName:"Select",ID:t==null?void 0:t.ID}});l&&l.some(at=>at[0]==="Select")&&(console.log(K),n.send(K))},H=()=>{F()},E=c0[a]?c0[a]:nb;return vt.jsx("div",{style:{display:"flex",alignItems:"flex-start",height:"100%",marginTop:"5px"},children:vt.jsx(Qx,{children:vt.jsx(ip,{children:vt.jsxs("div",{id:t==null?void 0:t.ID,className:"d-flex align-items-center flex-column justify-content-center",onClick:H,style:{cursor:"pointer",...g},children:[I?vt.jsx("img",{style:{width:I.imageSize[1],height:I.imageSize[0]},src:`${Zi()}${I.imageUrl}`,alt:"Image"}):h?vt.jsx("img",{style:{width:((R=r==null?void 0:r.Properties)==null?void 0:R.Size)&&((W=r==null?void 0:r.Properties)==null?void 0:W.Size[1]),height:(($=r==null?void 0:r.Properties)==null?void 0:$.Size)&&((G=r==null?void 0:r.Properties)==null?void 0:G.Size[0])},src:`${Zi()}${(Z=r==null?void 0:r.Properties)==null?void 0:Z.Files[h-1]}`,alt:"Image"}):vt.jsx(E,{size:35}),vt.jsx("div",{className:"text-center",style:{fontFamily:z==null?void 0:z.PName,fontSize:z!=null&&z.Size?`${z.Size*i}px`:`${12*i}px`},children:s})]})})})})},Lbt=({data:t})=>{const{socket:r,dataRef:n,findCurrentData:i,fontScale:o}=x1();let a=t.ImageList;const{Captions:s,Icons:l,Event:h,ImageIndex:p,ImageListObj:f,CSS:g}=t==null?void 0:t.Properties;console.log("Values reendered arw",s);const b=$1(g),z=i(t.FontObj&&t.FontObj),M=z&&(z==null?void 0:z.Properties),I=12,F=W=>{const $=JSON.stringify({Event:{EventName:"Select",ID:t==null?void 0:t.ID,Info:[W]}});h&&h.some(Z=>Z[0]==="Select")&&(console.log($),r.send($))},H=W=>{F(W)};let E;if(f)if(Array.isArray(f))E=f==null?void 0:f.map(W=>W&&JSON.parse(ji(n.current,W)));else{const W=f.split(".")[1];a=W&&JSON.parse(ji(n.current,W))}function R(W){var tt,ft,dt,ht,lt,yt;if(!E||!E.length)return;const $=(ft=(tt=t==null?void 0:t.Properties)==null?void 0:tt.Captions)==null?void 0:ft.indexOf(W);if($===-1)return null;const G=(dt=t==null?void 0:t.Properties)==null?void 0:dt.ImageListObj[$],Z=(ht=t==null?void 0:t.Properties)==null?void 0:ht.ImageIndex[$],K=E==null?void 0:E.find(mt=>(mt==null?void 0:mt.ID)===G);if(!K)return null;const et=(lt=K==null?void 0:K.Properties)==null?void 0:lt.Files[Z-1],at=(yt=K==null?void 0:K.Properties)==null?void 0:yt.Size;return{caption:W,imgIndex:Z,imgUrl:et,imgSize:at}}return vt.jsx("div",{className:"d-flex flex-column align-items-center justify-content-center ",style:{width:"fit-content"},children:s.map((W,$)=>{var tt,ft,dt,ht,lt,yt;const G=R(W),Z=$,K=G&&G.imgUrl?G.imgUrl:(E==null?void 0:E[Z])||a,et=(l==null?void 0:l[$])||"MdOutlineQuestionMark",at=(c0==null?void 0:c0[et])||nb;return vt.jsxs(ip,{id:`${t==null?void 0:t.ID}-${$}`,md:I,className:"d-flex align-items-center justify-content-left gap-1",style:{cursor:"pointer",...b},onClick:()=>H($+1),children:[G&&(G!=null&&G.imgUrl)?vt.jsx("img",{style:{width:G.imgSize[0],height:G.imgSize[1]},src:`${Zi()}${G.imgUrl}`,alt:W}):K?vt.jsx("img",{style:{width:(ft=(tt=a==null?void 0:a.Properties)==null?void 0:tt.Size)==null?void 0:ft[1],height:(ht=(dt=a==null?void 0:a.Properties)==null?void 0:dt.Size)==null?void 0:ht[0]},src:`${Zi()}${(yt=(lt=K==null?void 0:K.Properties)==null?void 0:lt.Files)==null?void 0:yt[Z]}`,alt:W}):vt.jsx(at,{size:25}),vt.jsx("div",{style:{textAlign:"left",textOverflow:"ellipsis",fontFamily:M==null?void 0:M.PName,fontSize:M!=null&&M.Size?`${M.Size*o}px`:`${12*o}px`},children:W})]},`col-${$}`)})})},Ebt=({data:t})=>{const{FCol:r,FillCol:n,LWidth:i,Points:o,FStyle:a,Visible:s,Event:l,CSS:h}=t==null?void 0:t.Properties,{socket:p}=x1(),f=$1(h),g=Gr(t.Properties),b=JSON.parse(localStorage.getItem("formDimension")),z=t==null?void 0:t.Properties.hasOwnProperty("FCol");return vt.jsx("div",{id:t==null?void 0:t.ID,style:{position:"absolute",display:s==0?"none":"block",...g,...f},onMouseDown:M=>{Q1(M,p,l,t==null?void 0:t.ID)},onMouseUp:M=>{tr(M,p,l,t==null?void 0:t.ID)},onMouseEnter:M=>{er(M,p,l,t==null?void 0:t.ID)},onMouseMove:M=>{ir(M,p,l,t==null?void 0:t.ID)},onMouseLeave:M=>{rr(M,p,l,t==null?void 0:t.ID)},onWheel:M=>{lr(M,p,l,t==null?void 0:t.ID)},onDoubleClick:M=>{gr(M,p,l,t==null?void 0:t.ID)},children:vt.jsx("svg",{height:b&&b[0],width:b&&b[1],children:o==null?void 0:o.map((M,I)=>{const F=M&&M[0].map((H,E)=>[M[1][E],H]);return vt.jsx("polygon",{id:I,points:F&&F.flat().join(" "),fill:a&&a[I]=="-1"?"none":n&&Er(n[I]),stroke:z?r&&Er(r[I]):"rgb(0,0,0)","stroke-width":i&&i[I]},I)})})})};var Ibt={en:{name:"en",identity:{version:{_unicodeVersion:"14.0.0",_cldrVersion:"41"},language:"en"},territory:"US",numbers:{symbols:{decimal:".",group:",",list:";",percentSign:"%",plusSign:"+",minusSign:"-",exponential:"E",superscriptingExponent:"×",perMille:"‰",infinity:"∞",nan:"NaN",timeSeparator:":",approximatelySign:"~"},decimal:{patterns:["n"],groupSize:[3]},scientific:{patterns:["nEn"],groupSize:[]},percent:{patterns:["n%"],groupSize:[3]},currency:{patterns:["$n"],groupSize:[3],"unitPattern-count-one":"n $","unitPattern-count-other":"n $"},currencies:{BGN:{displayName:"Bulgarian Lev","displayName-count-one":"Bulgarian lev","displayName-count-other":"Bulgarian leva",symbol:"BGN"},EUR:{displayName:"Euro","displayName-count-one":"euro","displayName-count-other":"euros",symbol:"€","symbol-alt-narrow":"€"},USD:{displayName:"US Dollar","displayName-count-one":"US dollar","displayName-count-other":"US dollars",symbol:"$","symbol-alt-narrow":"$"}},localeCurrency:"USD",accounting:{patterns:["$n","($n)"],groupSize:[3]}},calendar:{gmtFormat:"GMT{0}",gmtZeroFormat:"GMT",patterns:{d:"M/d/y",D:"EEEE, MMMM d, y",m:"MMM d",M:"MMMM d",y:"MMM y",Y:"MMMM y",F:"EEEE, MMMM d, y h:mm:ss a",g:"M/d/y h:mm a",G:"M/d/y h:mm:ss a",t:"h:mm a",T:"h:mm:ss a",s:"yyyy'-'MM'-'dd'T'HH':'mm':'ss",u:"yyyy'-'MM'-'dd HH':'mm':'ss'Z'"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{Bh:"h B",Bhm:"h:mm B",Bhms:"h:mm:ss B",d:"d",E:"ccc",EBhm:"E h:mm B",EBhms:"E h:mm:ss B",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMd:"M/d/y GGGGG",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",hmsv:"h:mm:ss a v",Hmsv:"HH:mm:ss v",hmv:"h:mm a v",Hmv:"HH:mm v",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d","MMMMW-count-one":"'week' W 'of' MMMM","MMMMW-count-other":"'week' W 'of' MMMM",ms:"mm:ss",y:"y",yM:"M/y",yMd:"M/d/y",yMEd:"E, M/d/y",yMMM:"MMM y",yMMMd:"MMM d, y",yMMMEd:"E, MMM d, y",yMMMM:"MMMM y",yQQQ:"QQQ y",yQQQQ:"QQQQ y","yw-count-one":"'week' w 'of' Y","yw-count-other":"'week' w 'of' Y"}},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateFormats:{full:"EEEE, MMMM d, y",long:"MMMM d, y",medium:"MMM d, y",short:"M/d/yy"},days:{format:{abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},"stand-alone":{abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]}},months:{format:{abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},"stand-alone":{abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]}},quarters:{format:{abbreviated:["Q1","Q2","Q3","Q4"],narrow:["1","2","3","4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},"stand-alone":{abbreviated:["Q1","Q2","Q3","Q4"],narrow:["1","2","3","4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]}},dayPeriods:{format:{abbreviated:{midnight:"midnight",am:"AM","am-alt-variant":"am",noon:"noon",pm:"PM","pm-alt-variant":"pm",morning1:"in the morning",afternoon1:"in the afternoon",evening1:"in the evening",night1:"at night"},narrow:{midnight:"mi",am:"a","am-alt-variant":"am",noon:"n",pm:"p","pm-alt-variant":"pm",morning1:"in the morning",afternoon1:"in the afternoon",evening1:"in the evening",night1:"at night"},wide:{midnight:"midnight",am:"AM","am-alt-variant":"am",noon:"noon",pm:"PM","pm-alt-variant":"pm",morning1:"in the morning",afternoon1:"in the afternoon",evening1:"in the evening",night1:"at night"}},"stand-alone":{abbreviated:{midnight:"midnight",am:"AM","am-alt-variant":"am",noon:"noon",pm:"PM","pm-alt-variant":"pm",morning1:"morning",afternoon1:"afternoon",evening1:"evening",night1:"night"},narrow:{midnight:"midnight",am:"AM","am-alt-variant":"am",noon:"noon",pm:"PM","pm-alt-variant":"pm",morning1:"morning",afternoon1:"afternoon",evening1:"evening",night1:"night"},wide:{midnight:"midnight",am:"AM","am-alt-variant":"am",noon:"noon",pm:"PM","pm-alt-variant":"pm",morning1:"morning",afternoon1:"afternoon",evening1:"evening",night1:"night"}}},eras:{format:{wide:{0:"Before Christ",1:"Anno Domini","0-alt-variant":"Before Common Era","1-alt-variant":"Common Era"},abbreviated:{0:"BC",1:"AD","0-alt-variant":"BCE","1-alt-variant":"CE"},narrow:{0:"B",1:"A","0-alt-variant":"BCE","1-alt-variant":"CE"}}},dateFields:{era:{wide:"era",short:"era",narrow:"era"},year:{wide:"year",short:"yr.",narrow:"yr."},quarter:{wide:"quarter",short:"qtr.",narrow:"qtr."},month:{wide:"month",short:"mo.",narrow:"mo."},week:{wide:"week",short:"wk.",narrow:"wk."},weekOfMonth:{wide:"week of month",short:"wk. of mo.",narrow:"wk. of mo."},day:{wide:"day",short:"day",narrow:"day"},dayOfYear:{wide:"day of year",short:"day of yr.",narrow:"day of yr."},weekday:{wide:"day of the week",short:"day of wk.",narrow:"day of wk."},weekdayOfMonth:{wide:"weekday of the month",short:"wkday. of mo.",narrow:"wkday. of mo."},dayperiod:{short:"AM/PM",wide:"AM/PM",narrow:"AM/PM"},hour:{wide:"hour",short:"hr.",narrow:"hr."},minute:{wide:"minute",short:"min.",narrow:"min."},second:{wide:"second",short:"sec.",narrow:"sec."},zone:{wide:"time zone",short:"zone",narrow:"zone"},millisecond:{narrow:"ms",short:"ms",wide:"millisecond"}}}},supplemental:{likelySubtags:{en:"en-Latn-US"},currencyData:{region:{US:[{USD:{_from:"1792-01-01"}}]}},weekData:{firstDay:{US:"sun"},weekendStart:{"001":"sat"},weekendEnd:{"001":"sun"}}}};function np(t){return typeof t=="string"}const Hbt={NoLocale:"Missing locale info for '{0}'",NoCurrency:"Cannot determine currency information. Please load the locale currencies data.",NoSupplementalCurrency:"Cannot determine currency. Please load the supplemental currencyData.",NoCurrencyRegion:"No currency data for region '{0}'",NoCurrencyDisplay:"Cannot determine currency display information. Please load the locale currencies data. The default culture does not include the all currencies data.",NoGMTInfo:"Cannot determine locale GMT format. Please load the locale timeZoneNames data.",NoWeekData:"Cannot determine locale first day of week. Please load the supplemental weekData.",NoFirstDay:"Cannot determine locale first day of week. Please load the supplemental weekData. The default culture includes only the 'en-US' first day info.",NoValidCurrency:"Cannot determine a default currency for the {0} locale. Please specify explicitly the currency with the format options.",NoDateFieldNames:"Cannot determine the locale date field names. Please load the locale dateFields data."};var Dbt=/\{(\d+)}?\}/g,ob=function(r){var n=r.name,i=r.message;if(!n||!i)throw new Error("{ name: string, message: string } object is required!");this.name=n,this.message=i};ob.prototype.formatMessage=function(){for(var r=[],n=arguments.length;n--;)r[n]=arguments[n];var i=Pbt(r),o=this.message.replace(Dbt,function(a,s){return i[parseInt(s,10)]});return this.name+": "+o};ob.prototype.error=function(){for(var r=[],n=arguments.length;n--;)r[n]=arguments[n];return new Error(this.formatMessage(r))};var Pbt=function(t){return t.reduce(function(r,n){return r.concat(n)},[])},Tbt=function(t){var r=function(n,i){return n[i]=new ob({name:i,message:t[i]}),n};return Object.keys(t).reduce(r,{})},xo=Tbt(Hbt);function Vbt(t,r){var n=t.split("-"),i=n[0],o=n[1],a=n[2];return H2[t]||r.indexOf(a)!==-1&&H2[i+"-"+a]||r.indexOf(o)!==-1&&H2[i+"-"+o]||H2[i]}function Fbt(t,r){for(var n=H2.supplemental.likelySubtags,i=0;i=1;a--){var s=i[a];(s===r.variant||s===r.script)&&i.splice(a,1)}var l=i.length;if(l>1){var h=i[l-1];return h.toUpperCase()}}function zP(t){if(t.territory)return t.territory;var r=t.name,n=t.identity,i;return n&&n.territory?i=n.territory:i=Bbt(r,n),t.territory=i,i}function Nbt(t,r){r===void 0&&(r=$l);var n=x4(r),i=n.calendar.dateFields;if(!i)throw xo.NoDateFieldNames.error();var o=i[t.type]||{};return o[t.nameType]||o.wide}function $bt(t){for(var r=[],n=0;n"u"||n!==1?s=a["displayName-count-other"]:s=a["displayName-count-one"],s}function ewt(t){var r=Tk,n=Tk,i=((H2.supplemental.currencyData||{}).fractions||{})[t];return i&&i._digits&&(n=r=parseInt(i._digits,10)),{minimumFractionDigits:r,maximumFractionDigits:n}}function rwt(t,r){if(r===void 0&&(r=!0),Vk[t])return Vk[t];var n=H2.supplemental.currencyData;if(!n){if(r)throw Ybt.error();return}var i=n.region[t];if(!i){if(r)throw Xbt.error(t);return}var o=Jbt(i);return o}function sb(t,r){var n=V8(t),i=n.numbers;if(!i.localeCurrency){var o=rwt(zP(n),r);if(!o&&r)throw Kbt.error(n.name);i.localeCurrency=o}return i.localeCurrency}var iwt=["sun","mon","tue","wed","thu","fri","sat"],nwt="001",owt=xo.NoWeekData,awt=xo.NoFirstDay;function _P(t){var r=V8(t);if(!isNaN(r.firstDay))return r.firstDay;var n=H2.supplemental.weekData;if(!n)throw owt.error();var i=n.firstDay[zP(r)]||n.firstDay[nwt];if(!i)throw awt.error();return r.firstDay=iwt.indexOf(i),r.firstDay}xo.NoWeekData;function swt(t){var r=V8(t);return r.numbers.symbols}function AP(t){return 1/t===-1/0}function LP(t,r){r===void 0&&(r={}),r.currency||(r.currency=sb(t,!0));var n=twt(t,r);return n}function EP(t,r,n,i,o){var a=o.numbers.symbols,s=t.indexOf(a.decimal),l=i.groupSize.slice(),h=l.shift(),p=s!==-1?s:n+1,f=t.substring(r,p),g=t,b=f.length;if(b>=h){for(var z=b,M=[];z>-1;){var I=f.substring(z-h,z);I&&M.push(I),z-=h;var F=l.shift();if(h=F!==void 0?F:h,h===0){I=f.substring(0,z),I&&M.push(I);break}}f=M.reverse().join(a.group),g=t.substring(0,r)+f+t.substring(p)}return g}function lb(t){return t===op||t===CP}function gn(t,r,n){r===void 0&&(r=2),n===void 0&&(n=!1);var i=r-String(t).length,o=t;if(i>0){var a=new Array(i+1).join("0");o=n?t+a:a+t}return o}var lwt=20;function Ic(t,r){var n=t,i=r||0;return n=n.toString().split("e"),n=Math.round(+(n[0]+"e"+(n[1]?Number(n[1])+i:i))),n=n.toString().split("e"),n=+(n[0]+"e"+(n[1]?Number(n[1])-i:-i)),n.toFixed(Math.min(i,lwt))}var cwt=3,hwt=0,uwt=/0+$/;function pwt(t){var r=t.minimumFractionDigits,n=t.maximumFractionDigits,i=t.style,o=lb(i),a;return o&&(a=ewt(t.currency)),r===void 0&&(r=o?a.minimumFractionDigits:0),n===void 0&&(i===Nl?n=Math.max(r,hwt):o?n=Math.max(r,a.maximumFractionDigits):n=Math.max(r,cwt)),{minimumFractionDigits:r,maximumFractionDigits:n}}function dwt(t,r,n){for(var i=P1,o=0,a=r.length;o-1||r.indexOf('"')>-1||r.indexOf("\\")>-1){var n=t.literals=[];t.format=r.replace(gwt,function(i){var o=i.charAt(0).replace("\\",P1),a=i.slice(1).replace(o,P1);return n.push(a),IP})}}function mwt(t,r){var n=t;if(r)for(var i=r.length,o=0;o-1,l=a>-1,h=r.toString().split("e");h[1]?h=Ic(r,Math.abs(h[1])):h=h[0],h=h.split(n4)[1]||P1;var p=h.length,f=-1;!s&&!l?(t.format=n.substring(0,i)+n.substring(i+1),i=-1,p=0):s&&o>a?p=o:a>o&&(l&&p>a?p=a:s&&p-1&&(r=Ic(r,p),f>-1&&(r=wwt(r,f)))}else r=Ic(r);t.negative&&r*-1>=0&&!t.negativeZero&&(t.negative=!1),t.number=r,t.decimalIndex=i}function Swt(t){return t.indexOf(o8)===-1&&t.indexOf(a8)===-1}function zwt(t){var r=t.number,n=t.format;if(n=n.split(Rbt),(t.negative||t.negativeZero)&&n[1])n=n[1],t.hasNegativeFormat=!0;else if(r===0){var i=n[2];n=i||n[0],i&&Swt(i)&&(t.constant=i)}else n=n[0];t.format=n}function Mwt(t){t.hasGroup=t.format.indexOf(Obt)>-1,t.hasGroup&&(t.format=t.format.replace(bwt,P1))}function Fk(t,r,n){var i;return t===-1&&r!==-1?i=r:t!==-1&&r===-1?i=t:i=n?Math.min(t,r):Math.max(t,r),i}function kwt(t){var r=t.format,n=r.indexOf(o8),i=r.indexOf(a8),o=Fk(n,i,!0);n=r.lastIndexOf(o8),i=r.lastIndexOf(a8);var a=Fk(n,i);o===r.length&&(a=o),t.start=o,t.end=a,t.lastZeroIndex=i}function _wt(t,r,n){var i=t;if(r===op||r===Nl){i=P1;for(var o=0,a=t.length;o-1&&(g+=M,E=l),l===E){g+=(I?r.numbers.symbols.decimal:P1)+I,E+=i-l+1;continue}R===a8?(g+=R,H=R):R===o8&&(g+=H)}return f&&(g=EP(g,n+(o&&!p?1:0),Math.max(i,F+n),r.numbers.decimal,r)),i>=n&&(g+=s.substring(i+1)),g}function Lwt(t,r){var n=t.number;return t.start!==-1&&(n=Awt(t,r),n=_wt(n,t.style,t.symbol),n=mwt(n,t.literals)),n}function Ewt(t,r,n){var i={negative:t<0,number:Math.abs(t),negativeZero:AP(t),format:r};return zwt(i),i.constant?i.constant:(DP(i),HP(i,n),Mwt(i),Cwt(i),kwt(i),Lwt(i,n))}var Iwt=/^(n|c|p|e|a)(\d*)$/i;function Hwt(t){var r=Iwt.exec(t);if(r){var n={style:wP},i=r[1].toLowerCase();return i==="c"?n.style=op:i==="a"?n.style=CP:i==="p"?n.style=Nl:i==="e"&&(n.style=SP),r[2]&&(n.minimumFractionDigits=n.maximumFractionDigits=parseInt(r[2],10)),n}}function PP(t){var r;return np(t)?r=Hwt(t):r=t,r}function TP(t,r,n){if(r===void 0&&(r=yl),n===void 0&&(n=$l),t==null)return P1;if(!isFinite(t))return String(t);var i=x4(n),o=PP(r),a;if(o){var s=o.style||wP;a=vwt(t,Object.assign({},i.numbers[s],o),i)}else a=Ewt(t,r,i);return a}function cb(t){return typeof t=="number"}var Dwt=/[eE][-+]?[0-9]+/,Rk=/\u00A0/g;function Ok(t,r){if(r.length>1){var n=(r[1]||P1).replace(ap,P1).split(yl);if(t.indexOf(n[0])>-1&&t.indexOf(n[1])>-1)return t.replace(n[0],P1).replace(n[1],P1)}}function Pwt(t,r,n){var i=PP(n)||{},o=lb(i.style),a=t,s,l=i.currency||sb(r,o);if(l){var h=Qbt(r,l,o);if(h)for(var p=0;p-1)&&(a=a.replace(o.percentSign,P1),l=!0),Dwt.test(a))return a=parseFloat(a.replace(o.decimal,n4)),isNaN(a)?null:a;var h=Pwt(a,i,s),p=h.negative,f=h.number;a=String(f).trim();var g=a.indexOf("-");if(g>0)return null;var b=g>-1;return b=p!==void 0?p:b,a=a.replace("-",P1).replace(Rk," ").split(o.group.replace(Rk," ")).join(P1).replace(o.decimal,n4),a=parseFloat(a),isNaN(a)?a=null:b&&(a*=-1),a&&l&&(a=Vwt(a)),a}var Rwt=/\{(\d+)}/g;function hb(t){var r=arguments;return t.replace(Rwt,function(n,i){var o=r[parseInt(i,10)+1];return o})}var Owt=120,Bwt=20,Bk=[2,1,5,3,4],Nwt=-2,$wt=-1,Wwt=1,jwt=2,F8={};F8[Nwt.toString()]=8;F8[$wt.toString()]=6;F8[jwt.toString()]=6;F8[Wwt.toString()]=3;var Gwt={numeric:1,"2-digit":2,short:3,long:4,narrow:5},Uwt=/[hHmsSzZoOvVxX]/;function Ywt(t){return t.hour12?"h":"H"}var Nk=[{key:"era",specifier:"G"},{key:"year",specifier:"y"},{key:"month",specifier:"M"},{key:"day",specifier:"d"},{key:"weekday",specifier:"E"},{key:"hour",getSpecifier:Ywt},{key:"minute",specifier:"m"},{key:"second",specifier:"s"},{key:"timeZoneName",specifier:"z"}],$k={e:"c",E:"c",M:"L",Q:"q"},Qf={},ol={};function tv(t){return Qf[t]||(Qf[t]=new RegExp(t+"+")),Qf[t]}function b7(t){for(var r=[],n=t.charAt(0),i=n,o=1;oi&&(i=p,o=l,a=r[s])}a=a.replace("v","z");for(var I=0;I0){var a=t.substr(0,i),s=t.substr(i);o=hb(r.calendar.dateTimeFormats.short,n[s]||ev(b7(s),n),n[a]||ev(b7(a),n))}else o=ev(b7(t),n);return Xwt(t,o,r.name),o}function qwt(t){for(var r=[],n=0;n3,localizedName:r===4,zZeroOffset:r===5})};Rr.x=function(t,r,n){return sp(t,n,{optionalMinutes:r===1,separator:r===3||r===5})};Rr.X=function(t,r,n){return sp(t,n,{optionalMinutes:r===1,separator:r===3||r===5,zZeroOffset:!0})};Rr.G=function(t,r,n){var i=t.getFullYear()>=0?1:0;return bo(n,"eras",r)[i]};Rr.e=OP;Rr.c=function(t,r,n){return OP(t,r,n,!0)};Rr.q=function(t,r,n){return RP(t,r,n,!0)};Rr.Q=RP;function BP(t,r,n){if(n===void 0&&(n=$l),!pb(t))return t??P1;var i=x4(n),o=ub(r,i);return o.replace(ec,function(a){var s=a.length,l;return a.includes("'")||a.includes('"')?l=a.slice(1,s-1):l=Rr[a[0]](t,s,i),l})}function Uk(t,r,n){var i=t.getTimezoneOffset(),o=new Date(t.getTime()+(r-n)*6e4),a=o.getTimezoneOffset();return new Date(o.getTime()+(a-i)*6e4)}function Qwt(t,r){!r&&t.getHours()===23&&t.setHours(t.getHours()+2)}var tCt=/([+|-]\d{1,2})(:?)(\d{2})?/,eCt=/^\/Date\((.*?)\)\/$/,rCt=/[+-]\d*/,iCt={2:/^\d{1,2}/,3:/^\d{1,3}/,4:/^\d{4}/},nCt=/\d+/,Yk="{0}",oCt=/^ */,aCt=/ *$/,sCt=["yyyy/MM/dd HH:mm:ss","yyyy/MM/dd HH:mm","yyyy/MM/dd","E MMM dd yyyy HH:mm:ss","yyyy-MM-ddTHH:mm:ss.SSSSSSSXXX","yyyy-MM-ddTHH:mm:ss.SSSXXX","yyyy-MM-ddTHH:mm:ss.SSXXX","yyyy-MM-ddTHH:mm:ssXXX","yyyy-MM-ddTHH:mm:ss.SSSSSSS","yyyy-MM-ddTHH:mm:ss.SSS","yyyy-MM-ddTHH:mmXXX","yyyy-MM-ddTHH:mmX","yyyy-MM-ddTHH:mm:ss","yyyy-MM-ddTHH:mm","yyyy-MM-dd HH:mm:ss","yyyy-MM-dd HH:mm","yyyy-MM-dd","HH:mm:ss","HH:mm"],Xk=["G","g","F","Y","y","M","m","D","d","y","T","t"],lCt=2029;function N2(t,r,n){return!(t>=r&&t<=n)}function Mi(t,r){for(var n=r.format,i=r.idx,o=0;n[i]===t;)o++,i++;return o>0&&(i-=1),r.idx=i,o}function ea(t,r){var n=t?iCt[t]||new RegExp("^\\d{1,"+t+"}"):nCt,i=r.value.substr(r.valueIdx,t).match(n);return i?(i=i[0],r.valueIdx+=i.length,parseInt(i,10)):null}function z0(t,r,n){for(var i=0,o=t.length,a,s,l=0,h=0,p;il&&(l=s,h=i);return l?(r.valueIdx+=l,h+1):null}function iv(t){var r=!1;return t.value.charAt(t.valueIdx)===t.format[t.idx]&&(t.valueIdx++,r=!0),r}function cCt(t){var r=t.gmtFormat,n=t.gmtZeroFormat;if(!r)throw xo.NoGMTInfo.error();return[r.replace(Yk,P1).toLowerCase(),n.replace(Yk,P1).toLowerCase()]}function lp(t,r,n){var i=n.shortHours,o=n.noSeparator,a=n.optionalMinutes,s=n.localizedName,l=n.zLiteral;if(t.UTC=!0,l&&t.value.charAt(t.valueIdx)==="Z")return t.valueIdx++,!1;if(s&&!z0(cCt(r.calendar),t,!0))return!0;var h=tCt.exec(t.value.substr(t.valueIdx,6));if(!h)return!s;var p=h[1],f=h[3],g=parseInt(p,10),b=h[2],z=parseInt(f,10);if(isNaN(g)||!i&&p.length!==3||!a&&isNaN(z)||o&&b||(isNaN(z)&&(z=null),N2(g,-12,13)||z&&N2(z,0,59)))return!0;t.valueIdx+=h[0].length,t.hoursOffset=g,t.minutesOffset=z}function NP(t,r,n){var i=Mi(t,r),o=bo(n,"months",i,t==="L",!0),a=i<3?ea(2,r):z0(o,r,!0);if(a===null||N2(a,1,12))return!0;r.month=a-1}function $P(t,r,n){var i=Mi(t,r),o=bo(n,"days",i,t==="c",!0),a=i<3?ea(1,r):z0(o,r,!0);if(!a&&a!==0||N2(a,1,7))return!0}var jr={};jr.d=function(t){Mi("d",t);var r=ea(2,t);if(r===null||N2(r,1,31))return!0;t.day===null&&(t.day=r)};jr.E=function(t,r){var n=Mi("E",t),i=z0(bo(r,"days",n,!1,!0),t,!0);if(i===null)return!0};jr.M=function(t,r){return NP("M",t,r)};jr.L=function(t,r){return NP("L",t,r)};jr.y=function(t){var r=Mi("y",t),n=ea(r===1?void 0:r,t);if(n===null)return!0;if(r===2){var i=new Date().getFullYear();n=i-i%100+n,n>lCt&&(n-=100)}t.year=n};jr.h=function(t){Mi("h",t);var r=ea(2,t);if(r===12&&(r=0),r===null||N2(r,0,11))return!0;t.hours=r};jr.K=function(t){Mi("K",t);var r=ea(2,t);if(r===null||N2(r,0,11))return!0;t.hours=r};jr.a=function(t,r){var n=Mi("a",t),i=bo(r,"dayPeriods",n,!1,!0),o=z0([i.pm],t,!0);if(!o&&!z0([i.am],t,!0))return!0;t.pmHour=o};jr.H=function(t){Mi("H",t);var r=ea(2,t);if(r===null||N2(r,0,23))return!0;t.hours=r};jr.k=function(t){Mi("k",t);var r=ea(2,t);if(r===null||N2(r,1,24))return!0;t.hours=r===24?0:r};jr.m=function(t){Mi("m",t);var r=ea(2,t);if(r===null||N2(r,0,59))return!0;t.minutes=r};jr.s=function(t){Mi("s",t);var r=ea(2,t);if(r===null||N2(r,0,59))return!0;t.seconds=r};jr.S=function(t){var r=Mi("S",t),n=t.value.substr(t.valueIdx,r),i=null;if(isNaN(parseInt(n,10))||(i=parseFloat("0."+n,10),i=Ic(i,3),i*=1e3,t.valueIdx+=r),i===null||N2(i,0,999))return!0;t.milliseconds=i};jr.z=function(t,r){var n=Mi("z",t),i=n<4,o=lp(t,r,{shortHours:i,optionalMinutes:i,localizedName:!0});if(o)return o};jr.Z=function(t,r){var n=Mi("Z",t),i=lp(t,r,{noSeparator:n<4,zLiteral:n===5,localizedName:n===4});if(i)return i};jr.x=function(t,r){var n=Mi("x",t),i=lp(t,r,{noSeparator:n!==3&&n!==5,optionalMinutes:n===1});if(i)return i};jr.X=function(t,r){var n=Mi("X",t),i=lp(t,r,{noSeparator:n!==3&&n!==5,optionalMinutes:n===1,zLiteral:!0});if(i)return i};jr.G=function(t,r){var n=Mi("G",t),i=bo(r,"eras",n,!1,!0),o=z0([i[0],i[1]],t,!0);if(o===null)return!0};jr.e=function(t,r){return $P("e",t,r)};jr.c=function(t,r){return $P("c",t,r)};function hCt(t){var r=t.year,n=t.month,i=t.day,o=t.hours,a=t.minutes,s=t.seconds,l=t.milliseconds,h=t.pmHour,p=t.UTC,f=t.hoursOffset,g=t.minutesOffset,b=o!==null||a!==null||s||null,z=new Date,M;return r===null&&n===null&&i===null&&b?(r=z.getFullYear(),n=z.getMonth(),i=z.getDate()):(r===null&&(r=z.getFullYear()),i===null&&(i=1)),h&&o<12&&(o+=12),p?(f&&(o+=-f),g&&(a+=-g*(f<0?-1:1)),M=new Date(Date.UTC(r,n,i,o,a,s,l))):(M=new Date(r,n,i,o,a,s,l),Qwt(M,o)),r<100&&M.setFullYear(r),M.getDate()!==i&&p===void 0?null:M}function uCt(t,r){var n=oCt.exec(r)[0],i=aCt.exec(r)[0];return""+n+t+i}function pCt(t,r,n){for(var i=ub(r,n).split(P1),o={format:i,idx:0,value:uCt(t,r),valueIdx:0,year:null,month:null,day:null,hours:null,minutes:null,seconds:null,milliseconds:null},a=i.length,s=!1;o.idx=b&&(f.names={type:g.type,nameType:VP(z),standAlone:g.standAlone===h})}o.push(f)}a=ec.lastIndex,s=ec.exec(i)}return atypeof document<"u"?document:{};let WP=class{constructor(){this.scrollbar=0}get scrollbarWidth(){const r=bCt();if(!this.scrollbar&&r&&r.createElement){const n=r.createElement("div");n.style.cssText="overflow:scroll;overflow-x:hidden;zoom:1;clear:both;display:block",n.innerHTML=" ",r.body.appendChild(n),this.scrollbar=n.offsetWidth-n.scrollWidth,r.body.removeChild(n)}return this.scrollbar}};/** + */const wCt=()=>typeof document<"u"?document:{};let jP=class{constructor(){this.scrollbar=0}get scrollbarWidth(){const r=wCt();if(!this.scrollbar&&r&&r.createElement){const n=r.createElement("div");n.style.cssText="overflow:scroll;overflow-x:hidden;zoom:1;clear:both;display:block",n.innerHTML=" ",r.body.appendChild(n),this.scrollbar=n.offsetWidth-n.scrollWidth,r.body.removeChild(n)}return this.scrollbar}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const ai=!!(typeof window<"u"&&window.document&&window.document.createElement);/** + */const oi=!!(typeof window<"u"&&window.document&&window.document.createElement);/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const Me=(...t)=>{const r={},n=o=>typeof o=="object"?Object.keys(o).forEach(a=>{r[a]=o[a]}):r[o]=!0,i=o=>o.filter(a=>a!==!0&&!!a).map(a=>Array.isArray(a)?i(a):n(a));return i(t),Object.keys(r).map(o=>r[o]&&o||null).filter(o=>o!==null).join(" ")};/** + */const ke=(...t)=>{const r={},n=o=>typeof o=="object"?Object.keys(o).forEach(a=>{r[a]=o[a]}):r[o]=!0,i=o=>o.filter(a=>a!==!0&&!!a).map(a=>Array.isArray(a)?i(a):n(a));return i(t),Object.keys(r).map(o=>r[o]&&o||null).filter(o=>o!==null).join(" ")};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const Jt={backspace:8,tab:9,enter:13,shift:16,esc:27,space:32,pageUp:33,pageDown:34,end:35,home:36,left:37,up:38,right:39,down:40,delete:46};/** + */const te={backspace:8,tab:9,enter:13,shift:16,esc:27,space:32,pageUp:33,pageDown:34,end:35,home:36,left:37,up:38,right:39,down:40,delete:46};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const wCt=/\[(?:(\d+)|['"](.*?)['"])\]|((?:(?!\[.*?\]|\.).)+)/g,db=":not(.k-dropdownlist button):not(.k-colorpicker button):not(.k-numerictextbox button):not(.k-split-button .k-split-button-arrow)",jP=":not(.k-dropdownlist select)",GP=["input:not([disabled]):not([type=hidden])","select:not([disabled]):not(.k-dropdownlist select)","textarea:not([disabled])",`button:not([disabled])${db}`,"a[href]","area[href]","summary","iframe","object","embed","audio[controls]","video[controls]","[contenteditable]"],T0=[...GP,`[tabindex]${db}${jP}`],cp=[...GP,`[tabindex]${db}${jP}`].map(t=>t+':not([tabindex="-1"])');/** + */const CCt=/\[(?:(\d+)|['"](.*?)['"])\]|((?:(?!\[.*?\]|\.).)+)/g,fb=":not(.k-dropdownlist button):not(.k-colorpicker button):not(.k-numerictextbox button):not(.k-split-button .k-split-button-arrow)",GP=":not(.k-dropdownlist select)",UP=["input:not([disabled]):not([type=hidden])","select:not([disabled]):not(.k-dropdownlist select)","textarea:not([disabled])",`button:not([disabled])${fb}`,"a[href]","area[href]","summary","iframe","object","embed","audio[controls]","video[controls]","[contenteditable]"],T0=[...UP,`[tabindex]${fb}${GP}`],cp=[...UP,`[tabindex]${fb}${GP}`].map(t=>t+':not([tabindex="-1"])');/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const hp=(t,r=T0)=>t.querySelectorAll(r.join(",")),UP=(t,r=T0)=>{if(t){const n=hp(t,r);if(n.length&&n[0].focus)return n[0]}},CCt=(t,r=T0)=>{if(t){const n=hp(t,r);if(n.length&&n[n.length-1].focus)return n[n.length-1]}},SCt=(t,r)=>{if(t){const n=UP(t,r);n&&n.focus()}},YP=(t,r,n)=>{if(!(!r||t.keyCode!==Jt.tab)&&r){const i=UP(r,n),o=CCt(r,n);i&&o&&!t.shiftKey&&t.target===o&&(t.preventDefault(),i.focus()),i&&o&&t.shiftKey&&t.target===i&&(t.preventDefault(),o.focus()),i||t.preventDefault()}},fb=(t,r)=>{const n=hp(t,r);n&&n.forEach(i=>{i.tabIndex=0})},vb=(t,r)=>{const n=hp(t,r);n&&n.forEach(i=>{i.tabIndex=-1})};/** + */const hp=(t,r=T0)=>t.querySelectorAll(r.join(",")),YP=(t,r=T0)=>{if(t){const n=hp(t,r);if(n.length&&n[0].focus)return n[0]}},SCt=(t,r=T0)=>{if(t){const n=hp(t,r);if(n.length&&n[n.length-1].focus)return n[n.length-1]}},zCt=(t,r)=>{if(t){const n=YP(t,r);n&&n.focus()}},XP=(t,r,n)=>{if(!(!r||t.keyCode!==te.tab)&&r){const i=YP(r,n),o=SCt(r,n);i&&o&&!t.shiftKey&&t.target===o&&(t.preventDefault(),i.focus()),i&&o&&t.shiftKey&&t.target===i&&(t.preventDefault(),o.focus()),i||t.preventDefault()}},vb=(t,r)=>{const n=hp(t,r);n&&n.forEach(i=>{i.tabIndex=0})},gb=(t,r)=>{const n=hp(t,r);n&&n.forEach(i=>{i.tabIndex=-1})};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const XP=(t,r,n)=>{const i=typeof t=="string"?parseInt(t):t;if(!Number.isNaN(i))return i!==void 0?i:r?n?void 0:-1:0};/** + */const KP=(t,r,n)=>{const i=typeof t=="string"?parseInt(t):t;if(!Number.isNaN(i))return i!==void 0?i:r?n?void 0:-1:0};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */function zCt(t){const r=[];return t.replace(wCt,function(n,i,o,a){r.push(i!==void 0?i:o||a)}),r}/** + */function MCt(t){const r=[];return t.replace(CCt,function(n,i,o,a){r.push(i!==void 0?i:o||a)}),r}/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const rc={};rc.undefined=()=>{};function MCt(t){if(rc[t])return rc[t];const r=zCt(t);return rc[t]=function(n){let i=n;for(let o=0;o{};function kCt(t){if(rc[t])return rc[t];const r=MCt(t);return rc[t]=function(n){let i=n;for(let o=0;o!ai||!document.body?!1:new WP().scrollbarWidth,Tu=t=>{if(!ai||!document.body)return!1;const r=t||new WP().scrollbarWidth;document.body.style.setProperty("--kendo-scrollbar-width",`${r}px`)};var qP=["z2v0vgLTzq==","ww91CIbSAwnLBNnLigv4CgLYzwqGB24G","zgf0yq==","uhjVz3jLC3mG","AgvmshG=","u2vLia==","ChjVzhvJDenVzgvZ","C2nYAxb0s2v5","D3rmuhm=","rKjcwKG=","tM8GBgLJzw5ZzsbMB3vUzc4k","CgfJA2fNzu5HBwu=","qvfYAMq=","CgfYC2u=","ChjVzhvJDhm=","igzVCIbTB3jLigLUzM9YBwf0Aw9UlGO=","sgr5sMW=","rg9iAwe=","zxDJr2C=","Du9wCuK=","z2v0rNvSBfLLyxi=","lcb0AguGCgfJA2fNzsb3yxmGChvIBgLZAgvKig9Uia==","C2v0","zxrNsxC=","C29YDa==","EeXMBLu=","AgfZ","s0XeCe8=","rM1Ttxy=","tNvstvG=","ww91CIb0CMLHBcbSAwnLBNnLigv4CgLYzwqGB24G","z2v0rgf0zq==","BgvUz3rO","txPHwe8=","BgLJzw5Zzuv4CgLYyxrPB25eyxrL","DhjPywW=","vejxq3K=","r2Ltv1q=","uhPWBva=","z2v0","vgHLihbYB2r1y3qGAxmGBM90igLUy2X1zgvKigLUihrOzsbSAwnLBNnLlGO=","z2v0tw9UDgG=","s2DnDfK=","DMvYC2LVBG==","rKj6sum=","DgLTzxn0yw1W","B2jQzwn0","DhLWzq==","BgLJzw5ZAw5Nrg9JC1vYBa==","BMfTzq==","DwTXAeq=","zg9JC1vYBa==","z3jVDxbfBMq=","z3jVDxa=","yuDyzhy=","zMLUza==","D2fYBG==","zNvUy3rPB24=","Dw5KzwzPBMvK","ChjVzhvJDe5HBwu=","y29Uy2f0","ChvIBgLZAerHDgu=","zxHWAxj5rgf0zq==","CeDhAfu=","y29Kzq==","Dg9mB2nHBgvtDhjPBMC=","tgLJzw5ZzsbHy3rPDMf0Aw9UigzHAwXLzcbMB3iG"];(function(t,r){var n=function(i){for(;--i;)t.push(t.shift())};n(++r)})(qP,439);var le=function(t,r){t=t-0;var n=qP[t];if(le.aWziBr===void 0){var i=function(a){for(var s="abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=",l=String(a).replace(/=+$/,""),h="",p=0,f,g,b=0;g=l.charAt(b++);~g&&(f=p%4?f*64+g:g,p++%4)?h+=String.fromCharCode(255&f>>(-2*p&6)):0)g=s.indexOf(g);return h};le.XjGMHe=function(a){for(var s=i(a),l=[],h=0,p=s.length;ho}/** + */const qP=()=>!oi||!document.body?!1:new jP().scrollbarWidth,Tu=t=>{if(!oi||!document.body)return!1;const r=t||new jP().scrollbarWidth;document.body.style.setProperty("--kendo-scrollbar-width",`${r}px`)};var ZP=["z2v0vgLTzq==","ww91CIbSAwnLBNnLigv4CgLYzwqGB24G","zgf0yq==","uhjVz3jLC3mG","AgvmshG=","u2vLia==","ChjVzhvJDenVzgvZ","C2nYAxb0s2v5","D3rmuhm=","rKjcwKG=","tM8GBgLJzw5ZzsbMB3vUzc4k","CgfJA2fNzu5HBwu=","qvfYAMq=","CgfYC2u=","ChjVzhvJDhm=","igzVCIbTB3jLigLUzM9YBwf0Aw9UlGO=","sgr5sMW=","rg9iAwe=","zxDJr2C=","Du9wCuK=","z2v0rNvSBfLLyxi=","lcb0AguGCgfJA2fNzsb3yxmGChvIBgLZAgvKig9Uia==","C2v0","zxrNsxC=","C29YDa==","EeXMBLu=","AgfZ","s0XeCe8=","rM1Ttxy=","tNvstvG=","ww91CIb0CMLHBcbSAwnLBNnLigv4CgLYzwqGB24G","z2v0rgf0zq==","BgvUz3rO","txPHwe8=","BgLJzw5Zzuv4CgLYyxrPB25eyxrL","DhjPywW=","vejxq3K=","r2Ltv1q=","uhPWBva=","z2v0","vgHLihbYB2r1y3qGAxmGBM90igLUy2X1zgvKigLUihrOzsbSAwnLBNnLlGO=","z2v0tw9UDgG=","s2DnDfK=","DMvYC2LVBG==","rKj6sum=","DgLTzxn0yw1W","B2jQzwn0","DhLWzq==","BgLJzw5ZAw5Nrg9JC1vYBa==","BMfTzq==","DwTXAeq=","zg9JC1vYBa==","z3jVDxbfBMq=","z3jVDxa=","yuDyzhy=","zMLUza==","D2fYBG==","zNvUy3rPB24=","Dw5KzwzPBMvK","ChjVzhvJDe5HBwu=","y29Uy2f0","ChvIBgLZAerHDgu=","zxHWAxj5rgf0zq==","CeDhAfu=","y29Kzq==","Dg9mB2nHBgvtDhjPBMC=","tgLJzw5ZzsbHy3rPDMf0Aw9UigzHAwXLzcbMB3iG"];(function(t,r){var n=function(i){for(;--i;)t.push(t.shift())};n(++r)})(ZP,439);var he=function(t,r){t=t-0;var n=ZP[t];if(he.aWziBr===void 0){var i=function(a){for(var s="abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=",l=String(a).replace(/=+$/,""),h="",p=0,f,g,b=0;g=l.charAt(b++);~g&&(f=p%4?f*64+g:g,p++%4)?h+=String.fromCharCode(255&f>>(-2*p&6)):0)g=s.indexOf(g);return h};he.XjGMHe=function(a){for(var s=i(a),l=[],h=0,p=s.length;ho}/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const ECt=["telerik.com","progress.com","stackblitz.io","csb.app"],gi=ZP;function gb(t){return!ECt.some(r=>{var n;return(n=globalThis.document)==null?void 0:n.location.hostname.endsWith(r)})&&!ZP(t)}/** + */const ICt=["telerik.com","progress.com","stackblitz.io","csb.app"],vi=JP;function mb(t){return!ICt.some(r=>{var n;return(n=globalThis.document)==null?void 0:n.location.hostname.endsWith(r)})&&!JP(t)}/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const ICt=t=>{if(!ai)return!1;const r=t?t.ownerDocument:document;if(!r||!r.body)return!1;const n=10,i=r.createElement("div");i.style.transform="matrix(10, 0, 0, 10, 0, 0)";const o=r.createElement("div");o.appendChild(r.createTextNode("child")),o.style.position="fixed",o.style.top=n+"px",i.appendChild(o),r.body.appendChild(i);const a=o.getBoundingClientRect().top!==n;return r.body.removeChild(i),a};/** + */const HCt=t=>{if(!oi)return!1;const r=t?t.ownerDocument:document;if(!r||!r.body)return!1;const n=10,i=r.createElement("div");i.style.transform="matrix(10, 0, 0, 10, 0, 0)";const o=r.createElement("div");o.appendChild(r.createTextNode("child")),o.style.position="fixed",o.style.top=n+"px",i.appendChild(o),r.body.appendChild(i);const a=o.getBoundingClientRect().top!==n;return r.body.removeChild(i),a};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const HCt="https://www.telerik.com/kendo-react-ui/components/my-license/?utm_medium=product&utm_source=kendoreact&utm_campaign=kendo-ui-react-purchase-license-keys-banner";let Zk=!1;const mb=()=>{const[t,r]=_.useState(!0),[n,i]=_.useState(!1);_.useEffect(()=>{Zk||(i(!0),Zk=!0)},[]);const o=()=>{r(!1)},a=_.createElement(_.Fragment,null,t&&_.createElement("div",{style:{display:"flex",justifyContent:"center",alignItems:"center",position:"fixed",top:"16px",right:"16px",padding:"12px",borderRadius:"4px",boxShadow:"0px 4px 5px 0px rgba(0, 0, 0, 0.04), 0px 2px 4px 0px rgba(0, 0, 0, 0.03)",fontSize:"14px",fontWeight:400,lineHeight:"20px",backgroundColor:"#FFC000",color:"#1E1E1E",zIndex:2e3}},_.createElement("span",{style:{display:"flex",alignSelf:"center",marginRight:"8px"}},_.createElement("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"},_.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M8 1L0 15H16L8 1ZM7 6V11H9V6H7ZM7 14V12H9V14H7Z",fill:"#1E1E1E"}))),_.createElement("span",null,"No valid license found for KendoReact. Learn how to activate your license."),_.createElement("div",{style:{display:"flex",alignItems:"center",marginLeft:"24px"}},_.createElement("a",{href:HCt,style:{marginRight:"8px",display:"flex"}},_.createElement("button",{title:"Learn More",style:{display:"inline-flex",position:"relative",border:"none",borderRadius:"4px",padding:"5px",backgroundColor:"transparent",transition:"color 0.2s ease-in-out",outline:"none",cursor:"pointer"}},_.createElement("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"},_.createElement("path",{d:"M15 8C15 11.8656 11.8656 15 8 15C4.13437 15 1 11.8656 1 8C1 4.13437 4.13437 1 8 1C11.8656 1 15 4.13437 15 8ZM14 8C14 4.6875 11.3125 2 8 2C4.6875 2 2 4.6875 2 8C2 11.3125 4.6875 14 8 14C11.3125 14 14 11.3125 14 8ZM11 6C11 7.4125 10.2687 8.05937 9.73125 8.53125C9.25937 8.94688 9 9.17813 9 10H7C7 8.275 7.84688 7.525 8.40938 7.03125C8.84062 6.65312 9 6.50938 9 6C9 5.45 8.55 5 8 5C7.45 5 7 5.45 7 6H5C5 4.34375 6.34375 3 8 3C9.65625 3 11 4.34375 11 6ZM9 13V11H7V13H9Z",fill:"#1E1E1E"})))),_.createElement("button",{title:"Close",style:{display:"inline-flex",position:"relative",border:"none",borderRadius:"4px",padding:"5px",backgroundColor:"transparent",transition:"color 0.2s ease-in-out",outline:"none",cursor:"pointer"},onClick:o},_.createElement("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"},_.createElement("path",{d:"M13 4.41562L9.41563 8L13 11.5844L11.5844 13L8 9.41563L4.41562 13L3 11.5844L6.58437 8L3 4.41562L4.41562 3L8 6.58437L11.5844 3L13 4.41562Z",fill:"#1E1E1E"}))))));return _.createElement(_.Fragment,null,_.createElement("div",{style:{position:"absolute",width:"100%",height:"100%",top:0,left:0,right:0,bottom:0,opacity:.12,zIndex:101,pointerEvents:"none",backgroundImage:"url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAQAAAAEACAYAAABccqhmAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAABVxSURBVHgB7Z3tVRtJE4WL9zgANgLLGRCCnAGOADmCxRGgDFAGYiOADKQMIAGO9J8ji42g37mjqlUjBgOanpn+uM85sjC2sKzbVd1dVV0tQgghhBBCCCGEEEIIKRPn3Gn1GAlJmmN1pP558J6OX9540ejh4WGlX09OTk7+EZIclXYXlY43+vVflY7PH3wd9c+AY/Wvvcb9/b0bjUYOz/hBQpICmh1oOPrEa6l/4rTR337AhIMgTSqtzg+0m8gnof7p0mD8EzmGhkFwJiR6np6e7luLL9Q/RTDTBzF+7wfWg2CxWOCHjYVET6XTdLPZrFuLL9Q/NeCkoVUQ4/d+6Ijev1yof1rAUVMvQgjJHebrSRu+CEmWo/O8hISgCjStKpgiGoDWed4AUP/hwGf++Pi4hQYyFHgDzBP3T7A8b0uo/zD4+sMBy1CwWKR/YjF+fS/Uv2di0t/eEAdBT0QnvlD/PolR/xoOgu4JUd7bFdS/e6I1foODoFuqz3M2mUziFF+of5dEb/xGwyAYCwmCVuPNYv5MqX94Yl75NWKD4PLyEm92KqQoqH9Y8Bnis0zC+A14LbxxVqiVCfUPh678plxNFYQe5pjRgAgpDAv4IOAHJyCEkDJoiPaeCyG5UA1oRIYWHNivSSbV0wLq/zbQXz+bS8kV/AeZJ35NCcYPqH8zvv4VS8kVFou8phTjB9T/NcVt+zgI9rjQDRwTgPrvKcn5v4CDYIfT/vtFiS/UHxRr/AYHwQ4t9DiVwihZ/+KN36ATKJsS9U+utr9r/EGQdQSUNFKa/geZkImQ/2rHlznnQDG7oX9b9Xwl5AUl6G9oLcSSxl8Q/p4P13YJIaQMisvzEkJ2lJjnJyQY3lnoJGfNUvP8oUhZf7c70s2eCG1wL7uhRJ0iQnCveiDIhzf7t/f9IvP8IUhJfx/b9rErUkvgRVPIE1fv6xrvbzweu7OzM3d7e4v3OhfSilT092HMJzCxF4u43eWctfFvt1uHu9nxXvF1CWmtroldfx9W+HVErINAjX+M65ngAPxnOAJ1AiMhrUjBCdD4Oya2QYBlPwx8vV47WwFg+a+XZbrz83NzANz/ByBmJ0Dj74lYBgECfrbnt6U/DB/vC7388L2rqyu8vzshwYjRCdD4e8YfBLidVgYA0X7M9jB8PGazmbu5ualnfiz9dSAsufwPTwz6+5jjp/H3CD5ofPB9343u9v3u6+U+0jyY7eEA8Hx3d4c/QjvvMyGdMZT+TeA9wBHR+DPHUn3T6bRe7uMxn89tn18v/TH7O17gQEheYM9vEX7M9hbsg/FbHED3/IPPSISQgNhyE0au+7x7PPtOQFcB3PMTMjTYf4cyRN3zL2DgMHgs/7XU99acgDIWEgUh9W/4uWMh8QKBvCh8qxSR7fmxt0eEv8kJ6MzP8/2REFL/g59bp/o0xsMAb6xAnBB5Yr+6D3X9KOpBxP/ACWA0jFnoEw+h9D/4mYd5/pGQeAlRLFK95tJy+35578PDQ+0E9LAPi3wixAUsFmKRT6I0DIIPzdJuf6R3i+UeZnsz/nqjPx47/fMpZ/54OVb/g5/BZi4pY4Pgo8s2d3CkF0Z/cXFRL/+Xy2W9BdBUH4/5JsBn9W94PZu5pI77QzMOjepiNp/j71hO//fv31sr7qmtfT73i3xWjnvAZHhH/4nquXrLwB2bueSJ27Vmvodhq4df4BmzvQb3IPxWl/zgRl/DwZA4GrhdYFUHfbHE1y0enXsJ2FLfCnggvjqBejDoTI8o38ocgJAscNq8BY4fv/Uf+J46gjkdQcbA+19fXzs7zQfR8TWcgH+kFw/u+fMDKz/o3OQETk9PLcWLPSBbeeWELd91eb+CcTc5gXr6r9J8PNKbF/7S3z+6DYcvDasBOv6M0GUduNDfv+cEYPhjIVmA+I3Vc4gaOQzfHAECvb4joAPICCzlrIJP93h/dAIYDBQ/L8wBNC37rXUblv5CB5AfGvi5h6F7Ed9GJ2CZP0b780O1vreVnnhOAFsBOoCMscg/HMBbTsCO+grJFkvvHmYCSnYA/5MMcbsiH6TykNgfr9fry58/f0oltFxcXMj379+l+h42gBcnJyfr6iXfq1nhJ56FZIeuAq+fn59Xv379Oq0CgVJNBEIydAAavLv98ePHeSX4bfX1OQSv9noQ/a7y9A8HTuAcTqB63FSPZyE5Mq3GwOW3b99kNpu9+5e/fv2Kp3+FpAW8vB3cwbLOOvZYfl9LfGdW9KOn+mZCskZXhCuL9vtLfjvshd97hWArpn8TxGn5rhZzOL/gB19DYBzzxcEeTQEtGfArB7c7xbmyVu4YExoTuNcYEL6eCkkTxHYOmna4wzQfvq8z/+o949e940hIkjTp5/ZXjm/1+VQfr856UP/EcLtqr9s/OQENDl5+wPhH3nHQZK6mJjucNvNo2w+A+icC0jaY4a2LT5MT+Mye3+l58JSupiY7XIA2XtQ/IZw2f7D9v+X6D53AZ/f8LqGrqckOF7CNF/VPAF3Or6xvv53r951Amx5+DYOAXWEjxXXQxov6R4zTSzusht8OfABE+r3U39y1iPbbIODVX3ED4/Tagk8kENQ/QiyaC1Fg7PX6frm0Mk6/wUOQ8l799+j9I0cDwcF1ov4R4Xbde2vjxi92ogsPzPrY92szD7buJiQn3K6+v17q2yxvlV1u3+TRAn4jIYTkAfbymOWx1AcwfHMEXp5/JISQ9PEDd867ohvGbvt+cwRe6+5ee7ltNpuVf7yYdA8+68fHxy0+exkY6t8RGnSxJX19yAd7fWvhjEs7NOCHb2D9/+AGqO3HQGSeuD/8PD/GggwM9e8IBPCwr7ciHnzA6NrqtW5+4QRkIByLRXrDRXhXH/XvCKRccEuPX8mHD9jr7Vc7AV32D9rJh4Oge2I0foP6d8QHnADO9kdxYw8HQXfEbPwG9e+It5yAlvdG1beNgyA8KRi/Qf07oskJIEYQw8x/SMMgGAs5CmR0UjF+g/oHwh00YzAn0OZgT1/YINBU5VTIUeCzw2eYivEb1L8l7o1mDm7X220a48x/iNtVLE4dC5OOxu2794wlMaj/kbgAzRwIIQmS4p6PEBKIp6enexo/IYWCPdNms1nnbPxat7BwvH/+P7Dt08/kUjKH+hcOxGeeeI8f86lYSuZQ/8JhsciehoBv9rMi9VdcwZcucBCkVeEXmuL1dy0vbciBkgdBycZvFKs/8/x7ShwENP49xelP8V9T0iBgncdritGfxv82/iDIORJ+EAGfCKnJXn8a//to7fgy51y45sCX1P812erPZR8hBVMZ/Ax9+2j8hBSIHumcpXikkxBCBsXtz8QnUyXndvfz8Sx8AFLUnwTEveyKE32KyAK+7IYThqT0V88/o+cPBz7TVPLEJdb2d00y+pv4elHHTEgwUigWYaq3O6LXn56/e2IeBDT+7olWf4rfHzEOAurfH9HpT/H7J6ZBQP37Jxr9Kf5w+IMAt9PKQOB6NurfP4Prjyg/jX9Y8JnDAHE/vQwE/m0MQOrfP4PqX/3jp15Dj4kQQspCK5SK7OZDCCGEEBIfbneH4kgCoT9vLCQJguqPaD8CDdXzlZDogaEuFotgKSLL9uBnYmAJiZqg+vupPlzbJSR6YKSh8sSODVyTI5j+LO9NlxDFIqzzSJfW+jPPnz4Ng+DDGRvqnz5t9GeePxNsEHx2+U798+BY/e3FzPNnwLE6Uv88oI6EEEIIIYQQQgghhBBCCCGEEEIIIYQQQkiRoHyQxz/T51gdqX8evKfjlzdeNHp4eFjp15OTk5N/hCQHjoFWOt7o139VOj5/8HXUPwOO1f+/02ApXEhJmmnTzIP6p49r28wlRFMJMgwhmnlQ/3RB854g/RwaBgF7wkVOyGYe1D9N0L4vWDMXGwTaFHIsJGpgpF5TyIm0hPqnR6XTdLPZrF2oZi7aVIDePxFgqCH1ov6EEEIIITHRtl7jixBCkuToPH8ocGMQrihmiqh/8Jnjau6hrwen/sPQOs8fAgxA5on7xxcfBigDQf2HIUSdR6g3wmKRnolGfKH+QxCT/vaGOAh6Ijrxhfr3SYz613AQdE+04gv174Ng5b1dwUHQHTEbv0H9u6X6PGeTySTu69oaBsFYSCui9/we1L87tBpzFv1naoPg8vISA2AqpBX4DPFZxm78BvUn9awF8R07yrRGPf80pdmU+hNCyJHoYa4ZHSghhWEBXwT84ASEEFIGDdmec8mJ6j+EyNAiu/9YACC+fjaXkinU/21SSPW2BuIzT/waX/yKpWQK9W+mCOMHLBZ5TfbLPg/q/5pijN/gINhTnPhC/X1cwAauScFBUKbxG9R/h9P7F0rTv6bkQVCy8Rt0Aju00OtUSqTEQZBSbX/X0AmQF4Mg5wi4cRAJn0jhlKY/aUBrx5c558ANzYUvafx7StAfqxv0UKyer4QQUg5+zAfXdgkhpAxKqvMghHgUm+cPhdufhU/Oa+qRTp6Jb0HK+oOi8/whcC+74SSTIrJlH7vitCMl/RHcqx4I8uHN/u19v9w8f1swi6aWJ+aeLxyp6F+9r2u8v/F47M7Oztzt7S3e61xIe1IqFmGFX3hi19/tLuesjX+73brFYlG/V3xdQlq7F1JwAjT+7ohVfzX+Ma5ngwPwn+EI1AmMhLQnZidA4++e2PTHsh8Gvl6vna0AsPzXy1Ld+fm5OQDu/0MRoxOg8fdHLPoj4Gd7flv6w/DxvtDLD9+7urrC+7sTEhZ/EOB2WhkYE57G3w8x6I9oP2Z7GD4es9nM3dzc1DM/lv46FpZc/ncEBgEMD7XVMjB4DxiINP7+GEp/t7/voF7uI0WJ2R4OAM93d3f4I7TzPhNCSD5Yqm86ndbLfTzm87nt8+ulP2Z/x+vQCMkL7Pktwo/Z3oJ9MH6LA+ief/AVKSEkILbdgJHr3v4ez74T0FUA9/wxgP1XF0Lozx0LiZqQ+uuefwEDh8Fj+a+lvrfmBJSxkOGBEF4UNliKyFJ9usdjgCdSQupve37s7RHhb3ICOvPzfH8swDhD54kb8vwjIVESSn+/ug91/SjqQcT/wAlgNhiz0CcyQhaLsMgnPULoX73m0nL7fnnvw8ND7QT0sA+LfGKlYRB82ks7NnNIlmP1d/sjvVtsJTDbm/HXG/3x2OmfTznzR44NgmOX7Y7NHJLms/q7gyO9MPqLi4t6+b9cLustgKb6eMw3FdwfmjFggKg3X71l4I7NHJLmHf3PVPs5/o7l9H///r214p7a2udzv8hn5RgDShsN3Czg1SE4lom6xKO4heB2rdnvYdi6QljgGbO9BvfgOLa65Ac3+hpOBinjtHkDhMdv/Qe+p45gTkeQL7bUtwIeaK5OoJ4MdKZHlG9lDkBIPsDzQ/QmJ3B6emopHqwB2corQzDDX19fOzvNh7GAr+EE/CO9eHDPnxH+0t8/ugnBpWE1QOHzwpbvurxfwbibnEA9/VdpPh7pzQjs3yyfK2rkMHxzBAj0+I6ADiAvdFsHLvT37zkBGP5YSB6YA2ha9lvrJiz9hQ4gO7CVswo+jfH80QlgMqD2GaKC35unF88JYCtAB5AnGvi9h6F7GZ9GJ2CZP0b7M8XSO4eZADqAvLHIPxzAW07AjvpKYfxPCkBngevn5+fVr1+/TqtAoFQDQUieuF2RD1J5SOyP1+v15c+fP6Vy9HJxcSHfv3+X6nsIAF2cnJysq5d8r1YAP/EshVGEA6iYVkZ/+e3bN5nNZu/+5a9fv+LpXyHJocG72x8/fpxXDv+2+vocDr+K9cDp31UrvYcDJ3AOJ1A9bqrHs5D80BlhZdF+f8lvhz3we68QZMX0T3pglWcHd6Cjdeyx/L6W+M6s6EdP9c2ElIHbneJaWStnFIRoTOBe94D4eiokSZyW72oxl/MLfvA1jB6642CPpoCXDPhljO79RwffG6kj2OrzqT5e1Xo3vZ7EC2K7B0073GGaD9/XmX/1nvFT/4Rx2syjbT+AIW+gIZ/D7ao9b//kBDQ4ePkB46f+qeICtPFy2g8gpavJSwZpW8zw1sWnyQl8Zs9P/RPFBWzj5RK6mrxkTCfb/1uu/9AJfHbPT/0Tw3XQxqthELArcETocn5lffvtXL/vBNr08KP+CQFxvLbQEwmEDQJe/RQXTi/tsBp+O/AFEOn3Un9z1yLaT/0TQgNBwb20Zg/o/SPBsjkwShh7vb5fLq2M22/wEqS8V/+9sRBChsXtuvfWxo1f7EQnHpj1se/XZh5s3U1ITrhdfX+91LdZ3io73b7JqwX8RkIIyQPs5THLY6kPYPjmCLw8/0hI3iAd8/j4uN1sNisZGLwH/3gpCYcfuHPeFd0wdtv3myPwWnf32suR+veMn+fHBy8DA0fEPHF4NOhmS/r6kA/2+tbCHZd2aMAP38D6/8ENUNtP/XvERXhXn2OxSCcggId9vRXx4LNF12avdfsLJyADQf17IkbjNzgIwoOUK27p8Sv58Nl6vf1qJ6DL/kE7+VD/jonZ+A0OgvB8wAngbH8UN/ZQ/45IwfgNDoLwvOUEtLw3qr6N1D8wiOimYvxGwyAYC2lFkxNAjCCGmf8Q6h8QRHeR7knF+A0bBJqqmgr5NO6gGYc5gTYHe/qC+gfC7bv3jCUx3K5ibepYmPJp3BvNXNyut+M0xpn/EOpPyBG4AM1cCCEJkmLMhxASiKenp3saf4Fg2Vc9FsjpSuZo3hr/115r1lMAe+bNZrPO2fip/wH+nq9iKZkD8ZknLhfq79EQ8MneK7JYpGyov5JShV9oOAjKvnSjeP1LNn6j5EHgWl7akgPF6k/j31PiIGCef09x+jPP+5qSBgGd/2uKcgIHEdCJkBp/EOSaCaHxv00J+tdoDnRJ8V+jtePLHGshaPzvk7P+pGC47SOkYCqDn6FvH42fkAJxuyPdaN01FlIGbnc/37TkFE8o3L4nAmvHCyQ5/S3gw24oYXAvuyKxbLgwktK/xNr+rsFqKpU8sa78Zlz5hSMZ/Znq6Y4UikVMf72oYyYkGNHrT+PvnpgHAVd+3ROt/jT+/ohxEFD//ohOf4rfPzENAurfP1E5AVzPRPH7xx8EuJ1WBoDGPxyH+ruhjlTjbnR9AxMhvYLPHA4YGkjPIMpP4x+WIfUnhYMZx2voMRFCSFlohVqR3XwIIaQc3O5OtrGQJFC9RkKKRCsyRxICi/YuFgvs986ERA3Eh1ahUkT4GQg0Vc9XQqInqP6ODRyTA046VJ7Y1x/XdgmJnmD6M8+bLiGKRVjemy6t9WeeN30aBsGHI/bUP33a6M88bybYIPjs9o3658Gx+tuLmefNgGN1pP55QB0JIYQQQgghhBBCCJGy+T9ftRg+rVNPfAAAAABJRU5ErkJggg==')"}}),n&&Xa.createPortal(a,document.body))};/** + */const DCt="https://www.telerik.com/kendo-react-ui/components/my-license/?utm_medium=product&utm_source=kendoreact&utm_campaign=kendo-ui-react-purchase-license-keys-banner";let Jk=!1;const yb=()=>{const[t,r]=_.useState(!0),[n,i]=_.useState(!1);_.useEffect(()=>{Jk||(i(!0),Jk=!0)},[]);const o=()=>{r(!1)},a=_.createElement(_.Fragment,null,t&&_.createElement("div",{style:{display:"flex",justifyContent:"center",alignItems:"center",position:"fixed",top:"16px",right:"16px",padding:"12px",borderRadius:"4px",boxShadow:"0px 4px 5px 0px rgba(0, 0, 0, 0.04), 0px 2px 4px 0px rgba(0, 0, 0, 0.03)",fontSize:"14px",fontWeight:400,lineHeight:"20px",backgroundColor:"#FFC000",color:"#1E1E1E",zIndex:2e3}},_.createElement("span",{style:{display:"flex",alignSelf:"center",marginRight:"8px"}},_.createElement("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"},_.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M8 1L0 15H16L8 1ZM7 6V11H9V6H7ZM7 14V12H9V14H7Z",fill:"#1E1E1E"}))),_.createElement("span",null,"No valid license found for KendoReact. Learn how to activate your license."),_.createElement("div",{style:{display:"flex",alignItems:"center",marginLeft:"24px"}},_.createElement("a",{href:DCt,style:{marginRight:"8px",display:"flex"}},_.createElement("button",{title:"Learn More",style:{display:"inline-flex",position:"relative",border:"none",borderRadius:"4px",padding:"5px",backgroundColor:"transparent",transition:"color 0.2s ease-in-out",outline:"none",cursor:"pointer"}},_.createElement("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"},_.createElement("path",{d:"M15 8C15 11.8656 11.8656 15 8 15C4.13437 15 1 11.8656 1 8C1 4.13437 4.13437 1 8 1C11.8656 1 15 4.13437 15 8ZM14 8C14 4.6875 11.3125 2 8 2C4.6875 2 2 4.6875 2 8C2 11.3125 4.6875 14 8 14C11.3125 14 14 11.3125 14 8ZM11 6C11 7.4125 10.2687 8.05937 9.73125 8.53125C9.25937 8.94688 9 9.17813 9 10H7C7 8.275 7.84688 7.525 8.40938 7.03125C8.84062 6.65312 9 6.50938 9 6C9 5.45 8.55 5 8 5C7.45 5 7 5.45 7 6H5C5 4.34375 6.34375 3 8 3C9.65625 3 11 4.34375 11 6ZM9 13V11H7V13H9Z",fill:"#1E1E1E"})))),_.createElement("button",{title:"Close",style:{display:"inline-flex",position:"relative",border:"none",borderRadius:"4px",padding:"5px",backgroundColor:"transparent",transition:"color 0.2s ease-in-out",outline:"none",cursor:"pointer"},onClick:o},_.createElement("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"},_.createElement("path",{d:"M13 4.41562L9.41563 8L13 11.5844L11.5844 13L8 9.41563L4.41562 13L3 11.5844L6.58437 8L3 4.41562L4.41562 3L8 6.58437L11.5844 3L13 4.41562Z",fill:"#1E1E1E"}))))));return _.createElement(_.Fragment,null,_.createElement("div",{style:{position:"absolute",width:"100%",height:"100%",top:0,left:0,right:0,bottom:0,opacity:.12,zIndex:101,pointerEvents:"none",backgroundImage:"url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAQAAAAEACAYAAABccqhmAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAABVxSURBVHgB7Z3tVRtJE4WL9zgANgLLGRCCnAGOADmCxRGgDFAGYiOADKQMIAGO9J8ji42g37mjqlUjBgOanpn+uM85sjC2sKzbVd1dVV0tQgghhBBCCCGEEEIIKRPn3Gn1GAlJmmN1pP558J6OX9540ejh4WGlX09OTk7+EZIclXYXlY43+vVflY7PH3wd9c+AY/Wvvcb9/b0bjUYOz/hBQpICmh1oOPrEa6l/4rTR337AhIMgTSqtzg+0m8gnof7p0mD8EzmGhkFwJiR6np6e7luLL9Q/RTDTBzF+7wfWg2CxWOCHjYVET6XTdLPZrFuLL9Q/NeCkoVUQ4/d+6Ijev1yof1rAUVMvQgjJHebrSRu+CEmWo/O8hISgCjStKpgiGoDWed4AUP/hwGf++Pi4hQYyFHgDzBP3T7A8b0uo/zD4+sMBy1CwWKR/YjF+fS/Uv2di0t/eEAdBT0QnvlD/PolR/xoOgu4JUd7bFdS/e6I1foODoFuqz3M2mUziFF+of5dEb/xGwyAYCwmCVuPNYv5MqX94Yl75NWKD4PLyEm92KqQoqH9Y8Bnis0zC+A14LbxxVqiVCfUPh678plxNFYQe5pjRgAgpDAv4IOAHJyCEkDJoiPaeCyG5UA1oRIYWHNivSSbV0wLq/zbQXz+bS8kV/AeZJ35NCcYPqH8zvv4VS8kVFou8phTjB9T/NcVt+zgI9rjQDRwTgPrvKcn5v4CDYIfT/vtFiS/UHxRr/AYHwQ4t9DiVwihZ/+KN36ATKJsS9U+utr9r/EGQdQSUNFKa/geZkImQ/2rHlznnQDG7oX9b9Xwl5AUl6G9oLcSSxl8Q/p4P13YJIaQMisvzEkJ2lJjnJyQY3lnoJGfNUvP8oUhZf7c70s2eCG1wL7uhRJ0iQnCveiDIhzf7t/f9IvP8IUhJfx/b9rErUkvgRVPIE1fv6xrvbzweu7OzM3d7e4v3OhfSilT092HMJzCxF4u43eWctfFvt1uHu9nxXvF1CWmtroldfx9W+HVErINAjX+M65ngAPxnOAJ1AiMhrUjBCdD4Oya2QYBlPwx8vV47WwFg+a+XZbrz83NzANz/ByBmJ0Dj74lYBgECfrbnt6U/DB/vC7388L2rqyu8vzshwYjRCdD4e8YfBLidVgYA0X7M9jB8PGazmbu5ualnfiz9dSAsufwPTwz6+5jjp/H3CD5ofPB9343u9v3u6+U+0jyY7eEA8Hx3d4c/QjvvMyGdMZT+TeA9wBHR+DPHUn3T6bRe7uMxn89tn18v/TH7O17gQEheYM9vEX7M9hbsg/FbHED3/IPPSISQgNhyE0au+7x7PPtOQFcB3PMTMjTYf4cyRN3zL2DgMHgs/7XU99acgDIWEgUh9W/4uWMh8QKBvCh8qxSR7fmxt0eEv8kJ6MzP8/2REFL/g59bp/o0xsMAb6xAnBB5Yr+6D3X9KOpBxP/ACWA0jFnoEw+h9D/4mYd5/pGQeAlRLFK95tJy+35578PDQ+0E9LAPi3wixAUsFmKRT6I0DIIPzdJuf6R3i+UeZnsz/nqjPx47/fMpZ/54OVb/g5/BZi4pY4Pgo8s2d3CkF0Z/cXFRL/+Xy2W9BdBUH4/5JsBn9W94PZu5pI77QzMOjepiNp/j71hO//fv31sr7qmtfT73i3xWjnvAZHhH/4nquXrLwB2bueSJ27Vmvodhq4df4BmzvQb3IPxWl/zgRl/DwZA4GrhdYFUHfbHE1y0enXsJ2FLfCnggvjqBejDoTI8o38ocgJAscNq8BY4fv/Uf+J46gjkdQcbA+19fXzs7zQfR8TWcgH+kFw/u+fMDKz/o3OQETk9PLcWLPSBbeeWELd91eb+CcTc5gXr6r9J8PNKbF/7S3z+6DYcvDasBOv6M0GUduNDfv+cEYPhjIVmA+I3Vc4gaOQzfHAECvb4joAPICCzlrIJP93h/dAIYDBQ/L8wBNC37rXUblv5CB5AfGvi5h6F7Ed9GJ2CZP0b780O1vreVnnhOAFsBOoCMscg/HMBbTsCO+grJFkvvHmYCSnYA/5MMcbsiH6TykNgfr9fry58/f0oltFxcXMj379+l+h42gBcnJyfr6iXfq1nhJ56FZIeuAq+fn59Xv379Oq0CgVJNBEIydAAavLv98ePHeSX4bfX1OQSv9noQ/a7y9A8HTuAcTqB63FSPZyE5Mq3GwOW3b99kNpu9+5e/fv2Kp3+FpAW8vB3cwbLOOvZYfl9LfGdW9KOn+mZCskZXhCuL9vtLfjvshd97hWArpn8TxGn5rhZzOL/gB19DYBzzxcEeTQEtGfArB7c7xbmyVu4YExoTuNcYEL6eCkkTxHYOmna4wzQfvq8z/+o949e940hIkjTp5/ZXjm/1+VQfr856UP/EcLtqr9s/OQENDl5+wPhH3nHQZK6mJjucNvNo2w+A+icC0jaY4a2LT5MT+Mye3+l58JSupiY7XIA2XtQ/IZw2f7D9v+X6D53AZ/f8LqGrqckOF7CNF/VPAF3Or6xvv53r951Amx5+DYOAXWEjxXXQxov6R4zTSzusht8OfABE+r3U39y1iPbbIODVX3ED4/Tagk8kENQ/QiyaC1Fg7PX6frm0Mk6/wUOQ8l799+j9I0cDwcF1ov4R4Xbde2vjxi92ogsPzPrY92szD7buJiQn3K6+v17q2yxvlV1u3+TRAn4jIYTkAfbymOWx1AcwfHMEXp5/JISQ9PEDd867ohvGbvt+cwRe6+5ee7ltNpuVf7yYdA8+68fHxy0+exkY6t8RGnSxJX19yAd7fWvhjEs7NOCHb2D9/+AGqO3HQGSeuD/8PD/GggwM9e8IBPCwr7ciHnzA6NrqtW5+4QRkIByLRXrDRXhXH/XvCKRccEuPX8mHD9jr7Vc7AV32D9rJh4Oge2I0foP6d8QHnADO9kdxYw8HQXfEbPwG9e+It5yAlvdG1beNgyA8KRi/Qf07oskJIEYQw8x/SMMgGAs5CmR0UjF+g/oHwh00YzAn0OZgT1/YINBU5VTIUeCzw2eYivEb1L8l7o1mDm7X220a48x/iNtVLE4dC5OOxu2794wlMaj/kbgAzRwIIQmS4p6PEBKIp6enexo/IYWCPdNms1nnbPxat7BwvH/+P7Dt08/kUjKH+hcOxGeeeI8f86lYSuZQ/8JhsciehoBv9rMi9VdcwZcucBCkVeEXmuL1dy0vbciBkgdBycZvFKs/8/x7ShwENP49xelP8V9T0iBgncdritGfxv82/iDIORJ+EAGfCKnJXn8a//to7fgy51y45sCX1P812erPZR8hBVMZ/Ax9+2j8hBSIHumcpXikkxBCBsXtz8QnUyXndvfz8Sx8AFLUnwTEveyKE32KyAK+7IYThqT0V88/o+cPBz7TVPLEJdb2d00y+pv4elHHTEgwUigWYaq3O6LXn56/e2IeBDT+7olWf4rfHzEOAurfH9HpT/H7J6ZBQP37Jxr9Kf5w+IMAt9PKQOB6NurfP4Prjyg/jX9Y8JnDAHE/vQwE/m0MQOrfP4PqX/3jp15Dj4kQQspCK5SK7OZDCCGEEBIfbneH4kgCoT9vLCQJguqPaD8CDdXzlZDogaEuFotgKSLL9uBnYmAJiZqg+vupPlzbJSR6YKSh8sSODVyTI5j+LO9NlxDFIqzzSJfW+jPPnz4Ng+DDGRvqnz5t9GeePxNsEHx2+U798+BY/e3FzPNnwLE6Uv88oI6EEEIIIYQQQgghhBBCCCGEEEIIIYQQQkiRoHyQxz/T51gdqX8evKfjlzdeNHp4eFjp15OTk5N/hCQHjoFWOt7o139VOj5/8HXUPwOO1f+/02ApXEhJmmnTzIP6p49r28wlRFMJMgwhmnlQ/3RB854g/RwaBgF7wkVOyGYe1D9N0L4vWDMXGwTaFHIsJGpgpF5TyIm0hPqnR6XTdLPZrF2oZi7aVIDePxFgqCH1ov6EEEIIITHRtl7jixBCkuToPH8ocGMQrihmiqh/8Jnjau6hrwen/sPQOs8fAgxA5on7xxcfBigDQf2HIUSdR6g3wmKRnolGfKH+QxCT/vaGOAh6Ijrxhfr3SYz613AQdE+04gv174Ng5b1dwUHQHTEbv0H9u6X6PGeTySTu69oaBsFYSCui9/we1L87tBpzFv1naoPg8vISA2AqpBX4DPFZxm78BvUn9awF8R07yrRGPf80pdmU+hNCyJHoYa4ZHSghhWEBXwT84ASEEFIGDdmec8mJ6j+EyNAiu/9YACC+fjaXkinU/21SSPW2BuIzT/waX/yKpWQK9W+mCOMHLBZ5TfbLPg/q/5pijN/gINhTnPhC/X1cwAauScFBUKbxG9R/h9P7F0rTv6bkQVCy8Rt0Aju00OtUSqTEQZBSbX/X0AmQF4Mg5wi4cRAJn0jhlKY/aUBrx5c558ANzYUvafx7StAfqxv0UKyer4QQUg5+zAfXdgkhpAxKqvMghHgUm+cPhdufhU/Oa+qRTp6Jb0HK+oOi8/whcC+74SSTIrJlH7vitCMl/RHcqx4I8uHN/u19v9w8f1swi6aWJ+aeLxyp6F+9r2u8v/F47M7Oztzt7S3e61xIe1IqFmGFX3hi19/tLuesjX+73brFYlG/V3xdQlq7F1JwAjT+7ohVfzX+Ma5ngwPwn+EI1AmMhLQnZidA4++e2PTHsh8Gvl6vna0AsPzXy1Ld+fm5OQDu/0MRoxOg8fdHLPoj4Gd7flv6w/DxvtDLD9+7urrC+7sTEhZ/EOB2WhkYE57G3w8x6I9oP2Z7GD4es9nM3dzc1DM/lv46FpZc/ncEBgEMD7XVMjB4DxiINP7+GEp/t7/voF7uI0WJ2R4OAM93d3f4I7TzPhNCSD5Yqm86ndbLfTzm87nt8+ulP2Z/x+vQCMkL7Pktwo/Z3oJ9MH6LA+ief/AVKSEkILbdgJHr3v4ez74T0FUA9/wxgP1XF0Lozx0LiZqQ+uuefwEDh8Fj+a+lvrfmBJSxkOGBEF4UNliKyFJ9usdjgCdSQupve37s7RHhb3ICOvPzfH8swDhD54kb8vwjIVESSn+/ug91/SjqQcT/wAlgNhiz0CcyQhaLsMgnPULoX73m0nL7fnnvw8ND7QT0sA+LfGKlYRB82ks7NnNIlmP1d/sjvVtsJTDbm/HXG/3x2OmfTznzR44NgmOX7Y7NHJLms/q7gyO9MPqLi4t6+b9cLustgKb6eMw3FdwfmjFggKg3X71l4I7NHJLmHf3PVPs5/o7l9H///r214p7a2udzv8hn5RgDShsN3Czg1SE4lom6xKO4heB2rdnvYdi6QljgGbO9BvfgOLa65Ac3+hpOBinjtHkDhMdv/Qe+p45gTkeQL7bUtwIeaK5OoJ4MdKZHlG9lDkBIPsDzQ/QmJ3B6emopHqwB2corQzDDX19fOzvNh7GAr+EE/CO9eHDPnxH+0t8/ugnBpWE1QOHzwpbvurxfwbibnEA9/VdpPh7pzQjs3yyfK2rkMHxzBAj0+I6ADiAvdFsHLvT37zkBGP5YSB6YA2ha9lvrJiz9hQ4gO7CVswo+jfH80QlgMqD2GaKC35unF88JYCtAB5AnGvi9h6F7GZ9GJ2CZP0b7M8XSO4eZADqAvLHIPxzAW07AjvpKYfxPCkBngevn5+fVr1+/TqtAoFQDQUieuF2RD1J5SOyP1+v15c+fP6Vy9HJxcSHfv3+X6nsIAF2cnJysq5d8r1YAP/EshVGEA6iYVkZ/+e3bN5nNZu/+5a9fv+LpXyHJocG72x8/fpxXDv+2+vocDr+K9cDp31UrvYcDJ3AOJ1A9bqrHs5D80BlhZdF+f8lvhz3we68QZMX0T3pglWcHd6Cjdeyx/L6W+M6s6EdP9c2ElIHbneJaWStnFIRoTOBe94D4eiokSZyW72oxl/MLfvA1jB6642CPpoCXDPhljO79RwffG6kj2OrzqT5e1Xo3vZ7EC2K7B0073GGaD9/XmX/1nvFT/4Rx2syjbT+AIW+gIZ/D7ao9b//kBDQ4ePkB46f+qeICtPFy2g8gpavJSwZpW8zw1sWnyQl8Zs9P/RPFBWzj5RK6mrxkTCfb/1uu/9AJfHbPT/0Tw3XQxqthELArcETocn5lffvtXL/vBNr08KP+CQFxvLbQEwmEDQJe/RQXTi/tsBp+O/AFEOn3Un9z1yLaT/0TQgNBwb20Zg/o/SPBsjkwShh7vb5fLq2M22/wEqS8V/+9sRBChsXtuvfWxo1f7EQnHpj1se/XZh5s3U1ITrhdfX+91LdZ3io73b7JqwX8RkIIyQPs5THLY6kPYPjmCLw8/0hI3iAd8/j4uN1sNisZGLwH/3gpCYcfuHPeFd0wdtv3myPwWnf32suR+veMn+fHBy8DA0fEPHF4NOhmS/r6kA/2+tbCHZd2aMAP38D6/8ENUNtP/XvERXhXn2OxSCcggId9vRXx4LNF12avdfsLJyADQf17IkbjNzgIwoOUK27p8Sv58Nl6vf1qJ6DL/kE7+VD/jonZ+A0OgvB8wAngbH8UN/ZQ/45IwfgNDoLwvOUEtLw3qr6N1D8wiOimYvxGwyAYC2lFkxNAjCCGmf8Q6h8QRHeR7knF+A0bBJqqmgr5NO6gGYc5gTYHe/qC+gfC7bv3jCUx3K5ibepYmPJp3BvNXNyut+M0xpn/EOpPyBG4AM1cCCEJkmLMhxASiKenp3saf4Fg2Vc9FsjpSuZo3hr/115r1lMAe+bNZrPO2fip/wH+nq9iKZkD8ZknLhfq79EQ8MneK7JYpGyov5JShV9oOAjKvnSjeP1LNn6j5EHgWl7akgPF6k/j31PiIGCef09x+jPP+5qSBgGd/2uKcgIHEdCJkBp/EOSaCaHxv00J+tdoDnRJ8V+jtePLHGshaPzvk7P+pGC47SOkYCqDn6FvH42fkAJxuyPdaN01FlIGbnc/37TkFE8o3L4nAmvHCyQ5/S3gw24oYXAvuyKxbLgwktK/xNr+rsFqKpU8sa78Zlz5hSMZ/Znq6Y4UikVMf72oYyYkGNHrT+PvnpgHAVd+3ROt/jT+/ohxEFD//ohOf4rfPzENAurfP1E5AVzPRPH7xx8EuJ1WBoDGPxyH+ruhjlTjbnR9AxMhvYLPHA4YGkjPIMpP4x+WIfUnhYMZx2voMRFCSFlohVqR3XwIIaQc3O5OtrGQJFC9RkKKRCsyRxICi/YuFgvs986ERA3Eh1ahUkT4GQg0Vc9XQqInqP6ODRyTA046VJ7Y1x/XdgmJnmD6M8+bLiGKRVjemy6t9WeeN30aBsGHI/bUP33a6M88bybYIPjs9o3658Gx+tuLmefNgGN1pP55QB0JIYQQQgghhBBCCJGy+T9ftRg+rVNPfAAAAABJRU5ErkJggg==')"}}),n&&Ya.createPortal(a,document.body))};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */function fn(t,r,n,i){if(t){const o={syntheticEvent:r,nativeEvent:r.nativeEvent,target:n};t.call(void 0,Object.assign(o,i))}}/** + */function pn(t,r,n,i){if(t){const o={syntheticEvent:r,nativeEvent:r.nativeEvent,target:n};t.call(void 0,Object.assign(o,i))}}/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */function JP({onFocus:t,onBlur:r,onSyncFocus:n,onSyncBlur:i}){const o=_.useRef(!1),a=_.useRef(0),s=_.useCallback(p=>{clearTimeout(a.current),a.current=window.setTimeout(()=>p())},[a]),l=_.useCallback((...p)=>{clearTimeout(a.current),n&&n.call(void 0,p[0]),!o.current&&(o.current=!0,t&&t.call(void 0,...p))},[o,t,n]),h=_.useCallback((...p)=>{i&&i.call(void 0,p[0]),s(()=>{o.current&&r&&(o.current=!1,r.call(void 0,...p))})},[o,s,r,i]);return _.useEffect(()=>()=>{clearTimeout(a.current)},[]),{onFocus:l,onBlur:h}}/** + */function QP({onFocus:t,onBlur:r,onSyncFocus:n,onSyncBlur:i}){const o=_.useRef(!1),a=_.useRef(0),s=_.useCallback(p=>{clearTimeout(a.current),a.current=window.setTimeout(()=>p())},[a]),l=_.useCallback((...p)=>{clearTimeout(a.current),n&&n.call(void 0,p[0]),!o.current&&(o.current=!0,t&&t.call(void 0,...p))},[o,t,n]),h=_.useCallback((...p)=>{i&&i.call(void 0,p[0]),s(()=>{o.current&&r&&(o.current=!1,r.call(void 0,...p))})},[o,s,r,i]);return _.useEffect(()=>()=>{clearTimeout(a.current)},[]),{onFocus:l,onBlur:h}}/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const QP=({children:t,onFocus:r,onBlur:n,onSyncFocus:i,onSyncBlur:o})=>{const a=JP({onFocus:r,onBlur:n,onSyncFocus:i,onSyncBlur:o});return _.createElement(_.Fragment,null,t.call(void 0,{...a}))};/** + */const tT=({children:t,onFocus:r,onBlur:n,onSyncFocus:i,onSyncBlur:o})=>{const a=QP({onFocus:r,onBlur:n,onSyncFocus:i,onSyncBlur:o});return _.createElement(_.Fragment,null,t.call(void 0,{...a}))};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const tT=(t,r)=>_.useContext(t)(r);/** + */const eT=(t,r)=>_.useContext(t)(r);/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const R8=()=>_.createContext(t=>t),up=(t,r)=>_.forwardRef((n,i)=>{const o=tT(t,n);return _.createElement(r,{...o,ref:i})});/** + */const R8=()=>_.createContext(t=>t),up=(t,r)=>_.forwardRef((n,i)=>{const o=eT(t,n);return _.createElement(r,{...o,ref:i})});/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const yb=typeof window<"u"?_.useLayoutEffect:_.useEffect;/** + */const xb=typeof window<"u"?_.useLayoutEffect:_.useEffect;/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */function pp(t){const[r,n]=_.useState(!1);_.useEffect(()=>{n(!0)},[]);const[i,o]=_.useState(()=>{if(t)return t;if(r)return w7()});yb(()=>{i===void 0&&o(w7())},[]);const a=cX[`useId${w7()}`.slice(0,5)];if(a!==void 0){const s=a();return t??s}return i}/** + */function pp(t){const[r,n]=_.useState(!1);_.useEffect(()=>{n(!0)},[]);const[i,o]=_.useState(()=>{if(t)return t;if(r)return w7()});xb(()=>{i===void 0&&o(w7())},[]);const a=hX[`useId${w7()}`.slice(0,5)];if(a!==void 0){const s=a();return t??s}return i}/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const na=t=>_.forwardRef((r,n)=>{const i=pp(r.id);return _.createElement(t,{...r,id:i,ref:n})});/** + */const ra=t=>_.forwardRef((r,n)=>{const i=pp(r.id);return _.createElement(t,{...r,id:i,ref:n})});/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const DCt=(t,r,n={})=>{const i=_.useCallback(b=>{n.onMouseDown&&n.onMouseDown.call(void 0,b),t.onMouseDown&&t.onMouseDown.call(void 0,{target:r.current,syntheticEvent:b})},[n.onMouseDown,t.onMouseDown,r]),o=_.useCallback(b=>{n.onMouseUp&&n.onMouseUp.call(void 0,b),t.onMouseUp&&t.onMouseUp.call(void 0,{target:r.current,syntheticEvent:b})},[n.onMouseUp,t.onMouseUp,r]),a=_.useCallback(b=>{n.onClick&&n.onClick.call(void 0,b),t.onClick&&t.onClick.call(void 0,{target:r.current,syntheticEvent:b})},[n.onClick,t.onClick,r]),s=_.useCallback(b=>{n.onDoubleClick&&n.onDoubleClick.call(void 0,b),t.onDoubleClick&&t.onDoubleClick.call(void 0,{target:r.current,syntheticEvent:b})},[n.onDoubleClick,t.onDoubleClick,r]),l=_.useCallback(b=>{n.onMouseEnter&&n.onMouseEnter.call(void 0,b),t.onMouseEnter&&t.onMouseEnter.call(void 0,{target:r.current,syntheticEvent:b})},[n.onMouseEnter,t.onMouseEnter,r]),h=_.useCallback(b=>{n.onMouseLeave&&n.onMouseLeave.call(void 0,b),t.onMouseLeave&&t.onMouseLeave.call(void 0,{target:r.current,syntheticEvent:b})},[n.onMouseLeave,t.onMouseLeave,r]),p=_.useCallback(b=>{n.onMouseMove&&n.onMouseMove.call(void 0,b),t.onMouseMove&&t.onMouseMove.call(void 0,{target:r.current,syntheticEvent:b})},[n.onMouseMove,t.onMouseMove,r]),f=_.useCallback(b=>{n.onMouseOut&&n.onMouseOut.call(void 0,b),t.onMouseOut&&t.onMouseOut.call(void 0,{target:r.current,syntheticEvent:b})},[n.onMouseOut,t.onMouseOut,r]),g=_.useCallback(b=>{n.onMouseOver&&n.onMouseOver.call(void 0,b),t.onMouseOver&&t.onMouseOver.call(void 0,{target:r.current,syntheticEvent:b})},[n.onMouseOver,t.onMouseOver,r]);return{onClick:a,onMouseUp:o,onMouseDown:i,onDoubleClick:s,onMouseEnter:l,onMouseLeave:h,onMouseMove:p,onMouseOut:f,onMouseOver:g}};/** + */const PCt=(t,r,n={})=>{const i=_.useCallback(b=>{n.onMouseDown&&n.onMouseDown.call(void 0,b),t.onMouseDown&&t.onMouseDown.call(void 0,{target:r.current,syntheticEvent:b})},[n.onMouseDown,t.onMouseDown,r]),o=_.useCallback(b=>{n.onMouseUp&&n.onMouseUp.call(void 0,b),t.onMouseUp&&t.onMouseUp.call(void 0,{target:r.current,syntheticEvent:b})},[n.onMouseUp,t.onMouseUp,r]),a=_.useCallback(b=>{n.onClick&&n.onClick.call(void 0,b),t.onClick&&t.onClick.call(void 0,{target:r.current,syntheticEvent:b})},[n.onClick,t.onClick,r]),s=_.useCallback(b=>{n.onDoubleClick&&n.onDoubleClick.call(void 0,b),t.onDoubleClick&&t.onDoubleClick.call(void 0,{target:r.current,syntheticEvent:b})},[n.onDoubleClick,t.onDoubleClick,r]),l=_.useCallback(b=>{n.onMouseEnter&&n.onMouseEnter.call(void 0,b),t.onMouseEnter&&t.onMouseEnter.call(void 0,{target:r.current,syntheticEvent:b})},[n.onMouseEnter,t.onMouseEnter,r]),h=_.useCallback(b=>{n.onMouseLeave&&n.onMouseLeave.call(void 0,b),t.onMouseLeave&&t.onMouseLeave.call(void 0,{target:r.current,syntheticEvent:b})},[n.onMouseLeave,t.onMouseLeave,r]),p=_.useCallback(b=>{n.onMouseMove&&n.onMouseMove.call(void 0,b),t.onMouseMove&&t.onMouseMove.call(void 0,{target:r.current,syntheticEvent:b})},[n.onMouseMove,t.onMouseMove,r]),f=_.useCallback(b=>{n.onMouseOut&&n.onMouseOut.call(void 0,b),t.onMouseOut&&t.onMouseOut.call(void 0,{target:r.current,syntheticEvent:b})},[n.onMouseOut,t.onMouseOut,r]),g=_.useCallback(b=>{n.onMouseOver&&n.onMouseOver.call(void 0,b),t.onMouseOver&&t.onMouseOver.call(void 0,{target:r.current,syntheticEvent:b})},[n.onMouseOver,t.onMouseOver,r]);return{onClick:a,onMouseUp:o,onMouseDown:i,onDoubleClick:s,onMouseEnter:l,onMouseLeave:h,onMouseMove:p,onMouseOut:f,onMouseOver:g}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const PCt=()=>null,TCt=({children:t})=>t,Vu=t=>{if(t){if(t===_.Fragment)return[TCt,{}];if(_.isValidElement(t))return[t.type,t.props]}else return[PCt,{}];return[t,{}]};/** + */const TCt=()=>null,VCt=({children:t})=>t,Vu=t=>{if(t){if(t===_.Fragment)return[VCt,{}];if(_.isValidElement(t))return[t.type,t.props]}else return[TCt,{}];return[t,{}]};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const VCt=t=>{const r=_.useCallback(()=>t.current&&t.current.element?t.current.element:t.current,[t]);return _.useCallback(()=>{const n=r();return n&&n.ownerDocument||document},[r])};/** + */const FCt=t=>{const r=_.useCallback(()=>t.current&&t.current.element?t.current.element:t.current,[t]);return _.useCallback(()=>{const n=r();return n&&n.ownerDocument||document},[r])};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const eT={default:"",xsmall:"k-icon-xs",small:"k-icon-sm",medium:"k-icon-md",large:"k-icon-lg",xlarge:"k-icon-xl",xxlarge:"k-icon-xxl",xxxlarge:"k-icon-xxxl"};/** + */const rT={default:"",xsmall:"k-icon-xs",small:"k-icon-sm",medium:"k-icon-md",large:"k-icon-lg",xlarge:"k-icon-xl",xxlarge:"k-icon-xxl",xxxlarge:"k-icon-xxxl"};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const FCt=t=>"k-i-"+t,dp=B.shape({name:B.string.isRequired,content:B.string.isRequired,viewBox:B.string.isRequired});/** + */const RCt=t=>"k-i-"+t,dp=B.shape({name:B.string.isRequired,content:B.string.isRequired,viewBox:B.string.isRequired});/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const xb=_.forwardRef((t,r)=>{const{className:n,name:i,themeColor:o,size:a,flip:s,style:l,id:h,tabIndex:p,...f}=t,g=_.useRef(null),b=_.useRef(null);_.useImperativeHandle(g,()=>({element:b.current})),_.useImperativeHandle(r,()=>g.current);const z=_.useMemo(()=>a||Jk.size,[a]),M=_.useMemo(()=>s||Jk.flip,[s]),I=_.useMemo(()=>Me("k-icon","k-font-icon",i&&FCt(i),{[`k-color-${o}`]:o,"k-flip-h":M==="horizontal"||M==="both","k-flip-v":M==="vertical"||M==="both"},eT[z],n),[i,o,z,M,n]),F=DCt(t,g);return _.createElement("span",{ref:b,...f,...F,className:I,id:h,tabIndex:p,style:l,role:"presentation"})});xb.propTypes={style:B.object,classNames:B.string,name:B.string,themeColor:B.oneOf(["inherit","primary","secondary","tertiary","info","success","error","warning","dark","light","inverse"]),size:B.oneOf(["default","xsmall","small","medium","large","xlarge","xxlarge","xxxlarge"]),flip:B.oneOf(["default","horizontal","vertical","both"])};const Jk={size:"default",flip:"default"};xb.displayName="KendoIcon";/** + */const bb=_.forwardRef((t,r)=>{const{className:n,name:i,themeColor:o,size:a,flip:s,style:l,id:h,tabIndex:p,...f}=t,g=_.useRef(null),b=_.useRef(null);_.useImperativeHandle(g,()=>({element:b.current})),_.useImperativeHandle(r,()=>g.current);const z=_.useMemo(()=>a||Qk.size,[a]),M=_.useMemo(()=>s||Qk.flip,[s]),I=_.useMemo(()=>ke("k-icon","k-font-icon",i&&RCt(i),{[`k-color-${o}`]:o,"k-flip-h":M==="horizontal"||M==="both","k-flip-v":M==="vertical"||M==="both"},rT[z],n),[i,o,z,M,n]),F=PCt(t,g);return _.createElement("span",{ref:b,...f,...F,className:I,id:h,tabIndex:p,style:l,role:"presentation"})});bb.propTypes={style:B.object,classNames:B.string,name:B.string,themeColor:B.oneOf(["inherit","primary","secondary","tertiary","info","success","error","warning","dark","light","inverse"]),size:B.oneOf(["default","xsmall","small","medium","large","xlarge","xxlarge","xxxlarge"]),flip:B.oneOf(["default","horizontal","vertical","both"])};const Qk={size:"default",flip:"default"};bb.displayName="KendoIcon";/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const bb=_.forwardRef((t,r)=>{const{children:n,className:i,svgClassName:o,icon:a,flip:s,id:l,tabIndex:h,size:p,style:f,svgStyle:g,themeColor:b,viewBox:z,name:M,onClick:I,...F}=t,H=_.useRef(null);_.useImperativeHandle(r,()=>({element:H.current}));const E=_.useMemo(()=>a?a.name:Hh.icon,[a]),R=_.useMemo(()=>p||Hh.size,[p]),W=_.useMemo(()=>s||Hh.flip,[s]),$=_.useMemo(()=>z||Hh.viewBox,[z]),G=_.useMemo(()=>Me("k-icon","k-svg-icon","k-svg-i-"+E,{[`k-color-${b}`]:b,"k-flip-h":W==="horizontal"||W==="both","k-flip-v":W==="vertical"||W==="both"},eT[R],i),[E,b,R,W,i]),Z=_.useMemo(()=>t.width&&t.height?{width:t.width,height:t.height,...f}:t.width?{width:t.width,height:t.width,...f}:t.height?{width:t.height,height:t.height,...f}:{...f},[t.width,t.height,f]);return _.createElement("span",{className:G,style:Z,ref:H,onClick:I,"aria-hidden":!0},_.createElement("svg",{id:l,className:o,style:g,"aria-hidden":!0,tabIndex:h,focusable:!1,xmlns:"http://www.w3.org/2000/svg",viewBox:a?a.viewBox:$,dangerouslySetInnerHTML:a?{__html:a.content}:void 0,...F},a?void 0:n))});bb.propTypes={style:B.object,classNames:B.string,children:B.any,icon:B.object,themeColor:B.oneOf(["inherit","primary","secondary","tertiary","info","success","error","warning","dark","light","inverse"]),size:B.oneOf(["default","xsmall","small","medium","large","xlarge","xxlarge","xxxlarge"]),flip:B.oneOf(["default","horizontal","vertical","both"])};const Hh={size:"default",flip:"default",icon:"",viewBox:"0 0 24 24"};bb.displayName="KendoSvgIcon";/** + */const wb=_.forwardRef((t,r)=>{const{children:n,className:i,svgClassName:o,icon:a,flip:s,id:l,tabIndex:h,size:p,style:f,svgStyle:g,themeColor:b,viewBox:z,name:M,onClick:I,...F}=t,H=_.useRef(null);_.useImperativeHandle(r,()=>({element:H.current}));const E=_.useMemo(()=>a?a.name:Hh.icon,[a]),R=_.useMemo(()=>p||Hh.size,[p]),W=_.useMemo(()=>s||Hh.flip,[s]),$=_.useMemo(()=>z||Hh.viewBox,[z]),G=_.useMemo(()=>ke("k-icon","k-svg-icon","k-svg-i-"+E,{[`k-color-${b}`]:b,"k-flip-h":W==="horizontal"||W==="both","k-flip-v":W==="vertical"||W==="both"},rT[R],i),[E,b,R,W,i]),Z=_.useMemo(()=>t.width&&t.height?{width:t.width,height:t.height,...f}:t.width?{width:t.width,height:t.width,...f}:t.height?{width:t.height,height:t.height,...f}:{...f},[t.width,t.height,f]);return _.createElement("span",{className:G,style:Z,ref:H,onClick:I,"aria-hidden":!0},_.createElement("svg",{id:l,className:o,style:g,"aria-hidden":!0,tabIndex:h,focusable:!1,xmlns:"http://www.w3.org/2000/svg",viewBox:a?a.viewBox:$,dangerouslySetInnerHTML:a?{__html:a.content}:void 0,...F},a?void 0:n))});wb.propTypes={style:B.object,classNames:B.string,children:B.any,icon:B.object,themeColor:B.oneOf(["inherit","primary","secondary","tertiary","info","success","error","warning","dark","light","inverse"]),size:B.oneOf(["default","xsmall","small","medium","large","xlarge","xxlarge","xxxlarge"]),flip:B.oneOf(["default","horizontal","vertical","both"])};const Hh={size:"default",flip:"default",icon:"",viewBox:"0 0 24 24"};wb.displayName="KendoSvgIcon";/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const rT=_.createContext({type:"svg"});rT.displayName="KendoReactIconsContext";/** + */const iT=_.createContext({type:"svg"});iT.displayName="KendoReactIconsContext";/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const en=_.forwardRef((t,r)=>{var n,i;const{type:o,icons:a}=_.useContext(rT),{icon:s,...l}=t;let h=o==="svg"?((n=t.icon)==null?void 0:n.name)||t.name:t.name||((i=t.icon)==null?void 0:i.name);h=h&&a&&a[h]&&typeof a[h]=="string"?a[h]:h;const p=h&&a&&a[h]&&typeof a[h]!="string"?a[h]:s;return o==="svg"&&p?_.createElement(bb,{...t,icon:p,ref:r}):_.createElement(xb,{...l,name:h,ref:r})});en.displayName="KendoIconWrap";/** + */const Qi=_.forwardRef((t,r)=>{var n,i;const{type:o,icons:a}=_.useContext(iT),{icon:s,...l}=t;let h=o==="svg"?((n=t.icon)==null?void 0:n.name)||t.name:t.name||((i=t.icon)==null?void 0:i.name);h=h&&a&&a[h]&&typeof a[h]=="string"?a[h]:h;const p=h&&a&&a[h]&&typeof a[h]!="string"?a[h]:s;return o==="svg"&&p?_.createElement(wb,{...t,icon:p,ref:r}):_.createElement(bb,{...l,name:h,ref:r})});Qi.displayName="KendoIconWrap";/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const RCt=_.createContext([void 0,Zr]),OCt=_.createContext([void 0,Zr]),BCt=_.createContext([[],Zr,Zr]),NCt=_.createContext([[],Zr,Zr]);var $Ct=function(t,r){var n=t.getBoundingClientRect(),i=r.getBoundingClientRect(),o=Math.max(i.top,n.top),a=Math.max(i.left,n.left),s=Math.min(i.left+i.width,n.left+n.width),l=Math.min(i.top+i.height,n.top+n.height),h=s-a,p=l-o;if(an&&(n=a,i=o)}}),i},jCt=function(){var t=window&&window.navigator.userAgent;if(!t)return!1;var r=!1,n=[],i={edge:/(edge)[ \/]([\w.]+)/i,webkit:/(chrome|crios)[ \/]([\w.]+)/i,safari:/(webkit)[ \/]([\w.]+)/i,opera:/(opera)(?:.*version|)[ \/]([\w.]+)/i,msie:/(msie\s|trident.*? rv:)([\w.]+)/i,mozilla:/(mozilla)(?:.*? rv:([\w.]+)|)/i};for(var o in i)if(i.hasOwnProperty(o)&&(n=t.match(i[o]),n)){r={},r[o]=!0,r[n[1].toLowerCase().split(" ")[0].split("/")[0]]=!0,r.version=parseInt(document.DOCUMENT_NODE||n[2],10);break}return r},wb=function(t){return t&&t.ownerDocument||window.document},GCt=function(t){var r=wb(t);return r&&r.defaultView||window},Cb=function(t){var r={browser:jCt()},n=wb(t);return r.browser.edge||r.browser.safari?n.body:n.documentElement},UCt=function(t){if(t&&t.className&&typeof t.className=="string"&&t.className.indexOf("k-auto-scrollable")>-1)return!0;var r=window.getComputedStyle(t,"overflow").overflow;return r.indexOf("auto")>-1||r.indexOf("scroll")>-1},W3=function(t){var r=Cb(t);if(!t||t===document.body||t===document.documentElement)return r;for(var n=t;n&&n!==document.body&&n.nodeType!==Node.DOCUMENT_FRAGMENT_NODE&&n.nodeType!==Node.DOCUMENT_NODE&&!UCt(n);)n=n.parentNode;return n&&(n===document.body||n.nodeType===Node.DOCUMENT_FRAGMENT_NODE)?r:n},YCt=function(t,r,n){var i={x:0,y:0},o=50;return t-n.left1||t.ignoreMouse)break;case gr.TOUCH_START:if(K.type===gr.TOUCH_START&&K.originalEvent.touches.length!==1)break;case gr.START:{var et=Z||W3(r.payload.element);E(et instanceof Window?{x:et.scrollX,y:et.scrollY}:{x:et.scrollLeft,y:et.scrollTop}),M({x:K.clientX,y:K.clientY}),b({x:K.pageX,y:K.pageY}),f({x:K.offsetX,y:K.offsetY}),o(!0),R.onPress&&R.onPress(K);break}case gr.SCROLL:if(K.type===gr.SCROLL&&!t.pressed)break;var at=Z||W3(W),tt=at instanceof Window?{x:at.scrollX,y:at.scrollY}:{x:at.scrollLeft,y:at.scrollTop};K.scrollX=tt.x-t.initialScrollOffset.x,K.scrollY=tt.y-t.initialScrollOffset.y,F({x:K.scrollX,y:K.scrollY});case gr.POINTER_MOVE:if(K.type===gr.POINTER_MOVE&&!K.originalEvent.isPrimary)break;case gr.MOUSE_MOVE:case gr.TOUCH_MOVE:if(K.type===gr.TOUCH_MOVE&&K.originalEvent.touches.length!==1)break;case gr.MOVE:{if(t.pressed){if(t.autoScroll&&K.originalEvent.type!=="scroll"&&W){var ft=wb(W),dt=Z||W3(ft.elementFromPoint(K.clientX,K.clientY)),ht=YCt(K.clientX,K.clientY,XCt(dt,GCt(W)));h({x:G&&G.horizontal===!1?0:ht.x,y:G&&G.vertical===!1?0:ht.y}),s(ht.y!==0||ht.x!==0)}!t.drag&&R.onDragStart&&R.onDragStart(K),R.onDrag&&R.onDrag(K);var lt=WCt($||W,t.drops.map(function(mt){return mt&&mt.element}).filter(function(mt){return mt!==($||W)})),yt=t.drops.find(function(mt){return mt.element===lt});yt&<&&KCt(K.clientX,K.clientY,Z||W3(lt))&<!==W?(t.drop&&t.drop.element)!==lt?(t.drop&&t.drop.onDragLeave&&t.drop.onDragLeave(K),yt.onDragEnter&&yt.onDragEnter(K)):yt.onDragOver&&yt.onDragOver(K):t.drop&&t.drop.onDragLeave&&t.drop.onDragLeave(K)}M({x:K.clientX,y:K.clientY}),b({x:K.pageX,y:K.pageY});break}case gr.POINTER_UP:if(K.type===gr.POINTER_UP&&!K.originalEvent.isPrimary)break;case gr.MOUSE_UP:case gr.TOUCH_END:if(K.type===gr.TOUCH_END&&K.originalEvent.touches.length!==1)break;case gr.END:{o(!1),s(!1),F({x:0,y:0}),R.onRelease&&R.onRelease(K),t.drop&&t.drop.onDrop&&t.drop.onDrop(K),t.drag&&R.onDragEnd&&R.onDragEnd(K);break}case gr.POINTER_CANCEL:case gr.CONTEXT_MENU:case gr.TOUCH_CANCEL:case gr.CANCEL:{o(!1),s(!1),F({x:0,y:0}),R.onDragEnd&&R.onDragEnd(K),t.drop&&t.drop.onDragLeave&&t.drop.onDragLeave(K);break}}},tSt=function(t,r){if(t){var n,i,o=t===Cb(t);o?(n=document.body.scrollHeight>window.innerHeight,i=document.body.scrollWidth>window.innerWidth):(n=t.offsetHeight<=t.scrollHeight,i=t.offsetWidth<=t.scrollWidth);var a=t.scrollTop+r.y,s=n&&a>0&&a0&&ln&&(n=a,i=o)}}),i},GCt=function(){var t=window&&window.navigator.userAgent;if(!t)return!1;var r=!1,n=[],i={edge:/(edge)[ \/]([\w.]+)/i,webkit:/(chrome|crios)[ \/]([\w.]+)/i,safari:/(webkit)[ \/]([\w.]+)/i,opera:/(opera)(?:.*version|)[ \/]([\w.]+)/i,msie:/(msie\s|trident.*? rv:)([\w.]+)/i,mozilla:/(mozilla)(?:.*? rv:([\w.]+)|)/i};for(var o in i)if(i.hasOwnProperty(o)&&(n=t.match(i[o]),n)){r={},r[o]=!0,r[n[1].toLowerCase().split(" ")[0].split("/")[0]]=!0,r.version=parseInt(document.DOCUMENT_NODE||n[2],10);break}return r},Cb=function(t){return t&&t.ownerDocument||window.document},UCt=function(t){var r=Cb(t);return r&&r.defaultView||window},Sb=function(t){var r={browser:GCt()},n=Cb(t);return r.browser.edge||r.browser.safari?n.body:n.documentElement},YCt=function(t){if(t&&t.className&&typeof t.className=="string"&&t.className.indexOf("k-auto-scrollable")>-1)return!0;var r=window.getComputedStyle(t,"overflow").overflow;return r.indexOf("auto")>-1||r.indexOf("scroll")>-1},W3=function(t){var r=Sb(t);if(!t||t===document.body||t===document.documentElement)return r;for(var n=t;n&&n!==document.body&&n.nodeType!==Node.DOCUMENT_FRAGMENT_NODE&&n.nodeType!==Node.DOCUMENT_NODE&&!YCt(n);)n=n.parentNode;return n&&(n===document.body||n.nodeType===Node.DOCUMENT_FRAGMENT_NODE)?r:n},XCt=function(t,r,n){var i={x:0,y:0},o=50;return t-n.left1||t.ignoreMouse)break;case vr.TOUCH_START:if(K.type===vr.TOUCH_START&&K.originalEvent.touches.length!==1)break;case vr.START:{var et=Z||W3(r.payload.element);E(et instanceof Window?{x:et.scrollX,y:et.scrollY}:{x:et.scrollLeft,y:et.scrollTop}),M({x:K.clientX,y:K.clientY}),b({x:K.pageX,y:K.pageY}),f({x:K.offsetX,y:K.offsetY}),o(!0),R.onPress&&R.onPress(K);break}case vr.SCROLL:if(K.type===vr.SCROLL&&!t.pressed)break;var at=Z||W3(W),tt=at instanceof Window?{x:at.scrollX,y:at.scrollY}:{x:at.scrollLeft,y:at.scrollTop};K.scrollX=tt.x-t.initialScrollOffset.x,K.scrollY=tt.y-t.initialScrollOffset.y,F({x:K.scrollX,y:K.scrollY});case vr.POINTER_MOVE:if(K.type===vr.POINTER_MOVE&&!K.originalEvent.isPrimary)break;case vr.MOUSE_MOVE:case vr.TOUCH_MOVE:if(K.type===vr.TOUCH_MOVE&&K.originalEvent.touches.length!==1)break;case vr.MOVE:{if(t.pressed){if(t.autoScroll&&K.originalEvent.type!=="scroll"&&W){var ft=Cb(W),dt=Z||W3(ft.elementFromPoint(K.clientX,K.clientY)),ht=XCt(K.clientX,K.clientY,KCt(dt,UCt(W)));h({x:G&&G.horizontal===!1?0:ht.x,y:G&&G.vertical===!1?0:ht.y}),s(ht.y!==0||ht.x!==0)}!t.drag&&R.onDragStart&&R.onDragStart(K),R.onDrag&&R.onDrag(K);var lt=jCt($||W,t.drops.map(function(mt){return mt&&mt.element}).filter(function(mt){return mt!==($||W)})),yt=t.drops.find(function(mt){return mt.element===lt});yt&<&&qCt(K.clientX,K.clientY,Z||W3(lt))&<!==W?(t.drop&&t.drop.element)!==lt?(t.drop&&t.drop.onDragLeave&&t.drop.onDragLeave(K),yt.onDragEnter&&yt.onDragEnter(K)):yt.onDragOver&&yt.onDragOver(K):t.drop&&t.drop.onDragLeave&&t.drop.onDragLeave(K)}M({x:K.clientX,y:K.clientY}),b({x:K.pageX,y:K.pageY});break}case vr.POINTER_UP:if(K.type===vr.POINTER_UP&&!K.originalEvent.isPrimary)break;case vr.MOUSE_UP:case vr.TOUCH_END:if(K.type===vr.TOUCH_END&&K.originalEvent.touches.length!==1)break;case vr.END:{o(!1),s(!1),F({x:0,y:0}),R.onRelease&&R.onRelease(K),t.drop&&t.drop.onDrop&&t.drop.onDrop(K),t.drag&&R.onDragEnd&&R.onDragEnd(K);break}case vr.POINTER_CANCEL:case vr.CONTEXT_MENU:case vr.TOUCH_CANCEL:case vr.CANCEL:{o(!1),s(!1),F({x:0,y:0}),R.onDragEnd&&R.onDragEnd(K),t.drop&&t.drop.onDragLeave&&t.drop.onDragLeave(K);break}}},eSt=function(t,r){if(t){var n,i,o=t===Sb(t);o?(n=document.body.scrollHeight>window.innerHeight,i=document.body.scrollWidth>window.innerWidth):(n=t.offsetHeight<=t.scrollHeight,i=t.offsetWidth<=t.scrollWidth);var a=t.scrollTop+r.y,s=n&&a>0&&a0&&l{const[n,i]=_.useContext(t),[o,a]=_.useState(r);return[n!==void 0?n:o,(...s)=>{n!==void 0?i(...s):a(s[0])}]};/** + */const t_=(t,r)=>{const[n,i]=_.useContext(t),[o,a]=_.useState(r);return[n!==void 0?n:o,(...s)=>{n!==void 0?i(...s):a(s[0])}]};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const eSt=2e3;function rSt(t,r,n={}){const{onPress:i=Zr,onRelease:o=Zr,onDragStart:a=Zr,onDrag:s=Zr,onDragEnd:l=Zr}=r,{hint:h=null,mouseOnly:p=!1,autoScroll:f=!0,scrollContainer:g=null}=n,[b,z]=_.useState(!1),[M,I]=_.useState(!1),[F]=Qk(OCt),[H,E]=Qk(RCt),[R]=_.useContext(NCt),[W,$,G]=_.useContext(BCt),Z=_.useRef({x:0,y:0}),K=_.useRef(),et=_.useRef(!1),at=_.useRef(),tt=_.useRef(null),ft=_.useRef(!1),dt=_.useRef({x:0,y:0}),ht=_.useRef({x:0,y:0}),lt=_.useRef({x:0,y:0}),yt=_.useRef({x:0,y:0}),mt=_.useRef({x:0,y:0}),gt=_.useRef({x:0,y:0}),kt=!!(typeof window<"u"&&window.PointerEvent),_t=!p&&kt,bt=_.useCallback(()=>t.current&&t.current.element?t.current.element:t.current,[t]),Mt=_.useCallback(()=>h&&h.current&&h.current.element?h.current.element:h?h.current:null,[h]),At=_.useCallback(()=>g&&g.current&&g.current.element?g.current.element:g?g.current:null,[g]),Ft=_.useCallback(()=>typeof f=="object"&&f.boundaryElementRef&&f.boundaryElementRef.current&&f.boundaryElementRef.current.element?f.boundaryElementRef.current.element:typeof f=="object"&&f.boundaryElementRef&&f.boundaryElementRef.current?f.boundaryElementRef.current:null,[f]),Bt=_.useRef(null);_.useImperativeHandle(Bt,()=>({element:bt(),hint:Mt(),onPress:fe,onDragStart:ce,onDrag:xe,onDragEnd:Wt,onRelease:ne,data:t.current}));const Ut=_.useCallback(()=>{const Tt=bt();return Tt&&Tt.ownerDocument||document},[bt]),Xt=_.useCallback(()=>{const Tt=Ut();return Tt&&Tt.defaultView||window},[Ut]),It=_.useCallback(()=>({drag:H?H.current:null,drop:F?F.current:null,drags:W.map(Tt=>Tt.current),drops:R.map(Tt=>Tt.current),pressed:b,ignoreMouse:et.current,scrollOffset:mt.current,offset:dt.current,pageOffset:ht.current,initialScrollOffset:gt.current,clientOffset:lt.current,initialClientOffset:yt.current,velocity:Z.current,autoScroll:!!(typeof f=="object"?f.enabled!==!1:f),scrollableParent:Ft(),autoScrollDirection:typeof f=="object"?f.direction:{horizontal:!0,vertical:!0},isScrolling:M}),[H,F,W,R,b,f,Ft,M]),ae=_.useCallback(Tt=>{z(Tt)},[]),$t=_.useCallback(Tt=>{I(Tt)},[]),ue=_.useCallback(Tt=>{Z.current=Tt},[]),Ot=_.useCallback(Tt=>{dt.current=Tt},[]),we=_.useCallback(Tt=>{lt.current=Tt},[]),Ht=_.useCallback(Tt=>{ht.current=Tt},[]),se=_.useCallback(Tt=>{yt.current=Tt},[]),Se=_.useCallback(Tt=>{mt.current=Tt},[]),Kt=_.useCallback(Tt=>{gt.current=Tt},[]),fe=_.useCallback(Tt=>{i(Tt)},[i]),ne=_.useCallback(Tt=>{o(Tt)},[o]),ce=_.useCallback(Tt=>{E(Bt,{target:t.current,event:Tt}),a(Tt)},[E,t,a]),xe=_.useCallback(Tt=>{s(Tt)},[s]),Wt=_.useCallback(Tt=>{ft.current||(E(null,{target:t.current,event:Tt}),l(Tt))},[l,E,t]),qt=_.useCallback(Tt=>{QCt(It(),{event:Tt,payload:Bt.current},{onVelocityChange:ue,onOffsetChange:Ot,onClientOffsetChange:we,onPageOffsetChange:Ht,onInitialClientOffsetChange:se,onScrollOffsetChange:Se,onInitialScrollOffsetChange:Kt,onIsPressedChange:ae,onIsScrollingChange:$t})},[It,ue,Ot,Ht,we,se,Kt,ae,Se,$t]),Ee=_.useCallback(Tt=>{qt(Tt)},[qt]),Ie=_.useCallback(Tt=>{qt(Tt)},[qt]),Pe=_.useCallback(Tt=>{qt(Tt)},[qt]),Yt=_.useCallback(Tt=>{qt(Tt)},[qt]),st=_.useCallback(Tt=>{qt(Tt)},[qt]),Et=_.useCallback(Tt=>{qt(Tt)},[qt]),zt=_.useCallback(Tt=>{qt(Tt)},[qt]),Rt=_.useCallback(Tt=>{Tt.preventDefault(),qt(Tt)},[qt]),Vt=_.useCallback(Tt=>{Tt.preventDefault(),qt(Tt)},[qt]),Qt=_.useCallback(Tt=>{Tt.preventDefault(),qt(Tt)},[qt]),ve=_.useCallback(Tt=>{if(Tt.touches.length===0&&Tt.changedTouches.length===1){const te=Xt();et.current=!0,at.current=te.setTimeout(()=>{et.current=!1},eSt)}qt(Tt)},[qt,Xt]),je=_.useCallback(Tt=>{qt(Tt)},[qt]),ke=_.useCallback(()=>{const Tt=bt();if(Tt){const te=Tt.style.touchAction;return Tt.style.touchAction="none",()=>{Tt.style.touchAction=te}}},[bt]),c1=_.useCallback(()=>($(Bt),()=>{G(Bt)}),[G,$]),Oe=()=>{const Tt=Xt(),te=bt(),Ve=Ut();return _t?(te&&(tt.current=W3(te),tt.current&&tt.current.addEventListener("scroll",je,{passive:!0}),te.addEventListener("pointerdown",Ee,{passive:!0})),b&&(Ve.addEventListener("pointermove",Ie),Ve.addEventListener("pointerup",Yt,!0),Ve.addEventListener("contextmenu",Rt),Ve.addEventListener("pointercancel",Pe,{passive:!0}))):(Tt.addEventListener("touchmove",Zr,{capture:!1,passive:!1}),te&&(te.addEventListener("mousedown",st,{passive:!0}),p||(te.addEventListener("touchstart",Vt,{passive:!0}),b&&(te.addEventListener("touchmove",Qt,{passive:!0}),te.addEventListener("touchend",ve,{passive:!0})))),b&&(Ve.addEventListener("mousemove",Et,{passive:!0}),Ve.addEventListener("mouseup",zt,{passive:!0}))),()=>{tt.current&&tt.current.removeEventListener("scroll",je),te&&(te.removeEventListener("pointerdown",Ee),te.removeEventListener("mousedown",st),te.removeEventListener("touchstart",Vt),te.removeEventListener("touchmove",Qt),te.removeEventListener("touchend",ve)),Ve.removeEventListener("pointermove",Ie),Ve.removeEventListener("pointerup",Yt,!0),Ve.removeEventListener("contextmenu",Rt),Ve.removeEventListener("pointercancel",Pe),Ve.removeEventListener("mousemove",Et),Ve.removeEventListener("mouseup",zt),Tt.removeEventListener("touchmove",Zr),Tt.clearTimeout(at.current)}};_.useEffect(()=>{const Tt=Xt();if(M){const te=At()||W3(document.elementFromPoint(lt.current.x,lt.current.y));Tt.clearInterval(K.current),K.current=Tt.setInterval(()=>{tSt(te,{x:Z.current.x,y:Z.current.y})},50)}return()=>{Tt.clearInterval(K.current)}},[bt,At,Xt,M]),_.useEffect(ke,[ke]),_.useEffect(Oe,[b,Xt,bt,Ut,p,_t,Rt,st,Et,zt,Pe,Ee,Ie,Yt,ve,Qt,Vt,je]),_.useEffect(()=>(ft.current=!1,()=>{ft.current=!0}),[]),yb(c1,[c1])}/** + */const rSt=2e3;function iSt(t,r,n={}){const{onPress:i=Xr,onRelease:o=Xr,onDragStart:a=Xr,onDrag:s=Xr,onDragEnd:l=Xr}=r,{hint:h=null,mouseOnly:p=!1,autoScroll:f=!0,scrollContainer:g=null}=n,[b,z]=_.useState(!1),[M,I]=_.useState(!1),[F]=t_(BCt),[H,E]=t_(OCt),[R]=_.useContext($Ct),[W,$,G]=_.useContext(NCt),Z=_.useRef({x:0,y:0}),K=_.useRef(),et=_.useRef(!1),at=_.useRef(),tt=_.useRef(null),ft=_.useRef(!1),dt=_.useRef({x:0,y:0}),ht=_.useRef({x:0,y:0}),lt=_.useRef({x:0,y:0}),yt=_.useRef({x:0,y:0}),mt=_.useRef({x:0,y:0}),gt=_.useRef({x:0,y:0}),_t=!!(typeof window<"u"&&window.PointerEvent),At=!p&&_t,bt=_.useCallback(()=>t.current&&t.current.element?t.current.element:t.current,[t]),kt=_.useCallback(()=>h&&h.current&&h.current.element?h.current.element:h?h.current:null,[h]),Lt=_.useCallback(()=>g&&g.current&&g.current.element?g.current.element:g?g.current:null,[g]),Vt=_.useCallback(()=>typeof f=="object"&&f.boundaryElementRef&&f.boundaryElementRef.current&&f.boundaryElementRef.current.element?f.boundaryElementRef.current.element:typeof f=="object"&&f.boundaryElementRef&&f.boundaryElementRef.current?f.boundaryElementRef.current:null,[f]),Rt=_.useRef(null);_.useImperativeHandle(Rt,()=>({element:bt(),hint:kt(),onPress:ge,onDragStart:ue,onDrag:xe,onDragEnd:Nt,onRelease:oe,data:t.current}));const Ut=_.useCallback(()=>{const Gt=bt();return Gt&&Gt.ownerDocument||document},[bt]),Kt=_.useCallback(()=>{const Gt=Ut();return Gt&&Gt.defaultView||window},[Ut]),It=_.useCallback(()=>({drag:H?H.current:null,drop:F?F.current:null,drags:W.map(Gt=>Gt.current),drops:R.map(Gt=>Gt.current),pressed:b,ignoreMouse:et.current,scrollOffset:mt.current,offset:dt.current,pageOffset:ht.current,initialScrollOffset:gt.current,clientOffset:lt.current,initialClientOffset:yt.current,velocity:Z.current,autoScroll:!!(typeof f=="object"?f.enabled!==!1:f),scrollableParent:Vt(),autoScrollDirection:typeof f=="object"?f.direction:{horizontal:!0,vertical:!0},isScrolling:M}),[H,F,W,R,b,f,Vt,M]),le=_.useCallback(Gt=>{z(Gt)},[]),Bt=_.useCallback(Gt=>{I(Gt)},[]),de=_.useCallback(Gt=>{Z.current=Gt},[]),Ft=_.useCallback(Gt=>{dt.current=Gt},[]),we=_.useCallback(Gt=>{lt.current=Gt},[]),Ht=_.useCallback(Gt=>{ht.current=Gt},[]),ce=_.useCallback(Gt=>{yt.current=Gt},[]),Se=_.useCallback(Gt=>{mt.current=Gt},[]),qt=_.useCallback(Gt=>{gt.current=Gt},[]),ge=_.useCallback(Gt=>{i(Gt)},[i]),oe=_.useCallback(Gt=>{o(Gt)},[o]),ue=_.useCallback(Gt=>{E(Rt,{target:t.current,event:Gt}),a(Gt)},[E,t,a]),xe=_.useCallback(Gt=>{s(Gt)},[s]),Nt=_.useCallback(Gt=>{ft.current||(E(null,{target:t.current,event:Gt}),l(Gt))},[l,E,t]),Jt=_.useCallback(Gt=>{tSt(It(),{event:Gt,payload:Rt.current},{onVelocityChange:de,onOffsetChange:Ft,onClientOffsetChange:we,onPageOffsetChange:Ht,onInitialClientOffsetChange:ce,onScrollOffsetChange:Se,onInitialScrollOffsetChange:qt,onIsPressedChange:le,onIsScrollingChange:Bt})},[It,de,Ft,Ht,we,ce,qt,le,Se,Bt]),Ie=_.useCallback(Gt=>{Jt(Gt)},[Jt]),He=_.useCallback(Gt=>{Jt(Gt)},[Jt]),Pe=_.useCallback(Gt=>{Jt(Gt)},[Jt]),Xt=_.useCallback(Gt=>{Jt(Gt)},[Jt]),st=_.useCallback(Gt=>{Jt(Gt)},[Jt]),Mt=_.useCallback(Gt=>{Jt(Gt)},[Jt]),wt=_.useCallback(Gt=>{Jt(Gt)},[Jt]),Pt=_.useCallback(Gt=>{Gt.preventDefault(),Jt(Gt)},[Jt]),Yt=_.useCallback(Gt=>{Gt.preventDefault(),Jt(Gt)},[Jt]),Zt=_.useCallback(Gt=>{Gt.preventDefault(),Jt(Gt)},[Jt]),ae=_.useCallback(Gt=>{if(Gt.touches.length===0&&Gt.changedTouches.length===1){const Re=Kt();et.current=!0,at.current=Re.setTimeout(()=>{et.current=!1},rSt)}Jt(Gt)},[Jt,Kt]),ee=_.useCallback(Gt=>{Jt(Gt)},[Jt]),jt=_.useCallback(()=>{const Gt=bt();if(Gt){const Re=Gt.style.touchAction;return Gt.style.touchAction="none",()=>{Gt.style.touchAction=Re}}},[bt]),_e=_.useCallback(()=>($(Rt),()=>{G(Rt)}),[G,$]),ze=()=>{const Gt=Kt(),Re=bt(),je=Ut();return At?(Re&&(tt.current=W3(Re),tt.current&&tt.current.addEventListener("scroll",ee,{passive:!0}),Re.addEventListener("pointerdown",Ie,{passive:!0})),b&&(je.addEventListener("pointermove",He),je.addEventListener("pointerup",Xt,!0),je.addEventListener("contextmenu",Pt),je.addEventListener("pointercancel",Pe,{passive:!0}))):(Gt.addEventListener("touchmove",Xr,{capture:!1,passive:!1}),Re&&(Re.addEventListener("mousedown",st,{passive:!0}),p||(Re.addEventListener("touchstart",Yt,{passive:!0}),b&&(Re.addEventListener("touchmove",Zt,{passive:!0}),Re.addEventListener("touchend",ae,{passive:!0})))),b&&(je.addEventListener("mousemove",Mt,{passive:!0}),je.addEventListener("mouseup",wt,{passive:!0}))),()=>{tt.current&&tt.current.removeEventListener("scroll",ee),Re&&(Re.removeEventListener("pointerdown",Ie),Re.removeEventListener("mousedown",st),Re.removeEventListener("touchstart",Yt),Re.removeEventListener("touchmove",Zt),Re.removeEventListener("touchend",ae)),je.removeEventListener("pointermove",He),je.removeEventListener("pointerup",Xt,!0),je.removeEventListener("contextmenu",Pt),je.removeEventListener("pointercancel",Pe),je.removeEventListener("mousemove",Mt),je.removeEventListener("mouseup",wt),Gt.removeEventListener("touchmove",Xr),Gt.clearTimeout(at.current)}};_.useEffect(()=>{const Gt=Kt();if(M){const Re=Lt()||W3(document.elementFromPoint(lt.current.x,lt.current.y));Gt.clearInterval(K.current),K.current=Gt.setInterval(()=>{eSt(Re,{x:Z.current.x,y:Z.current.y})},50)}return()=>{Gt.clearInterval(K.current)}},[bt,Lt,Kt,M]),_.useEffect(jt,[jt]),_.useEffect(ze,[b,Kt,bt,Ut,p,At,Pt,st,Mt,wt,Pe,Ie,He,Xt,ae,Zt,Yt,ee]),_.useEffect(()=>(ft.current=!1,()=>{ft.current=!0}),[]),xb(_e,[_e])}/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const O8=_.forwardRef((t,r)=>{const n=_.useRef(null),i=_.useRef(null),o=_.useCallback(()=>n.current&&n.current.element?n.current.element:n.current,[n]);_.useImperativeHandle(i,()=>({element:o()||null})),_.useImperativeHandle(r,()=>i.current),_.useImperativeHandle(t.childRef,()=>n.current);const a=_.useCallback(f=>{t.onPress&&t.onPress({element:o(),target:i.current,event:f})},[o,t.onPress]),s=_.useCallback(f=>{t.onRelease&&t.onRelease({element:o(),target:i.current,event:f})},[o,t.onRelease]),l=_.useCallback(f=>{t.onDragStart&&t.onDragStart({element:o(),target:i.current,event:f})},[t,o]),h=_.useCallback(f=>{t.onDrag&&t.onDrag({element:o(),target:i.current,event:f})},[o,t.onDrag]),p=_.useCallback(f=>{t.onDragEnd&&t.onDragEnd({element:o(),target:i.current,event:f})},[o,t.onDragEnd]);return rSt(n,{onPress:a,onRelease:s,onDragStart:l,onDrag:h,onDragEnd:p},{mouseOnly:t.mouseOnly,autoScroll:t.autoScroll,hint:t.hint,scrollContainer:t.scrollContainer}),t.children?_.cloneElement(_.Children.only(t.children),{ref:n}):null});O8.displayName="KendoReactDraggable";/** + */const O8=_.forwardRef((t,r)=>{const n=_.useRef(null),i=_.useRef(null),o=_.useCallback(()=>n.current&&n.current.element?n.current.element:n.current,[n]);_.useImperativeHandle(i,()=>({element:o()||null})),_.useImperativeHandle(r,()=>i.current),_.useImperativeHandle(t.childRef,()=>n.current);const a=_.useCallback(f=>{t.onPress&&t.onPress({element:o(),target:i.current,event:f})},[o,t.onPress]),s=_.useCallback(f=>{t.onRelease&&t.onRelease({element:o(),target:i.current,event:f})},[o,t.onRelease]),l=_.useCallback(f=>{t.onDragStart&&t.onDragStart({element:o(),target:i.current,event:f})},[t,o]),h=_.useCallback(f=>{t.onDrag&&t.onDrag({element:o(),target:i.current,event:f})},[o,t.onDrag]),p=_.useCallback(f=>{t.onDragEnd&&t.onDragEnd({element:o(),target:i.current,event:f})},[o,t.onDragEnd]);return iSt(n,{onPress:a,onRelease:s,onDragStart:l,onDrag:h,onDragEnd:p},{mouseOnly:t.mouseOnly,autoScroll:t.autoScroll,hint:t.hint,scrollContainer:t.scrollContainer}),t.children?_.cloneElement(_.Children.only(t.children),{ref:n}):null});O8.displayName="KendoReactDraggable";/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const Gr={sizeMap:{small:"sm",medium:"md",large:"lg"},roundedMap:{small:"sm",medium:"md",large:"lg"},orientationMap:{vertical:"vstack",horizontal:"hstack"}};/** + */const Wr={sizeMap:{small:"sm",medium:"md",large:"lg"},roundedMap:{small:"sm",medium:"md",large:"lg"},orientationMap:{vertical:"vstack",horizontal:"hstack"}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */function iSt(t,r){return t===r||Number.isNaN(t)&&Number.isNaN(r)}function nSt(t,r){if(t.length!==r.length)return!1;for(let n=0;n{},this.setFocusClass=n=>{n.target.classList.add(this.focusClass)},this.disableTabindexForRest=n=>{this.elements.forEach(i=>{i!==n&&i.setAttribute("tabindex","-1")})},this.focusNextIndex=(n,i,o)=>{const a=i===1?this.next(n,o):this.previous(n,o);return this.focusElement(a,n),a},this.tabIndex=r.tabIndex||0,this.root=r.root,this.selectors=r.selectors,this.focusOptions=r.focusOptions||{preventScroll:!0},this.rovingTabIndex=r.rovingTabIndex!==void 0?r.rovingTabIndex:!0,this.mouseEvents=r.mouseEvents||{},this.keyboardEvents=r.keyboardEvents||{},this.focusClass=r.focusClass,this.lastFocused=null}get elements(){return this.root.current?Array.from(this.root.current.querySelectorAll(this.selectors.join(","))):[]}get first(){return this.root.current&&this.root.current.querySelector(this.selectors.join(","))||null}get last(){const r=this.elements;return r[r.length-1]||null}get current(){return this.elements.find(r=>r.matches(":focus"))||null}next(r,n){const i=n?this.customElements(n):this.elements;let o=i.indexOf(r)+1;return o=o<0?i.length-1:o,i[o%i.length]}previous(r,n){const i=n?this.customElements(n):this.elements;let o=i.indexOf(r)-1;return o=o<0?i.length-1:o,i[o%i.length]}focusNext(r,n){return this.focusNextIndex(r,1,n)}focusPrevious(r,n){return this.focusNextIndex(r,-1,n)}triggerKeyboardEvent(r,n){const i=this.target(r.target),o=i&&i.closest(this.selectors.join(",")),a=r.key===" "?"Space":r.key,s=r.nativeEvent.type;o&&this.keyboardEvents[s][a]&&this.keyboardEvents[s][a].call(void 0,o,this,r,n)}triggerMouseEvent(r){const n=this.target(r.target),i=n&&n.closest(this.selectors.join(",")),o=r.nativeEvent.type;i&&this.mouseEvents[o].call(void 0,i,this,r)}focusElement(r,n){r&&(n&&(this.rovingTabIndex&&n.setAttribute("tabindex","-1"),this.focusClass&&(this.removeFocusClass(n),n.removeEventListener("focus",this.setFocusClass))),this.rovingTabIndex&&r.setAttribute("tabindex",String(this.tabIndex)),this.focusClass&&(r.classList.add(this.focusClass),r.addEventListener("focus",this.setFocusClass)),r.focus(this.focusOptions),this.lastFocused=r)}initializeRovingTab(r){const n=r?this.elements[r]:this.first;n&&(this.focusClass&&n.addEventListener("focus",this.setFocusClass),n.setAttribute("tabindex",String(this.tabIndex)),this.disableTabindexForRest(n))}removeFocusListener(){this.lastFocused&&this.lastFocused.removeEventListener("focus",this.setFocusClass)}removeFocusClass(r){this.focusClass&&r.classList.remove(this.focusClass)}customElements(r){return this.root.current?Array.from(this.root.current.querySelectorAll(r.join(","))):[]}target(r){var n;const i=r,o=i&&i.ownerDocument||null,a=o&&((n=o==null?void 0:o.defaultView)==null?void 0:n.Element)||Element;return r instanceof a?r:null}};/** + */let zb=class{constructor(r){this.rovingTabIndex=!0,this.update=()=>{},this.setFocusClass=n=>{n.target.classList.add(this.focusClass)},this.disableTabindexForRest=n=>{this.elements.forEach(i=>{i!==n&&i.setAttribute("tabindex","-1")})},this.focusNextIndex=(n,i,o)=>{const a=i===1?this.next(n,o):this.previous(n,o);return this.focusElement(a,n),a},this.tabIndex=r.tabIndex||0,this.root=r.root,this.selectors=r.selectors,this.focusOptions=r.focusOptions||{preventScroll:!0},this.rovingTabIndex=r.rovingTabIndex!==void 0?r.rovingTabIndex:!0,this.mouseEvents=r.mouseEvents||{},this.keyboardEvents=r.keyboardEvents||{},this.focusClass=r.focusClass,this.lastFocused=null}get elements(){return this.root.current?Array.from(this.root.current.querySelectorAll(this.selectors.join(","))):[]}get first(){return this.root.current&&this.root.current.querySelector(this.selectors.join(","))||null}get last(){const r=this.elements;return r[r.length-1]||null}get current(){return this.elements.find(r=>r.matches(":focus"))||null}next(r,n){const i=n?this.customElements(n):this.elements;let o=i.indexOf(r)+1;return o=o<0?i.length-1:o,i[o%i.length]}previous(r,n){const i=n?this.customElements(n):this.elements;let o=i.indexOf(r)-1;return o=o<0?i.length-1:o,i[o%i.length]}focusNext(r,n){return this.focusNextIndex(r,1,n)}focusPrevious(r,n){return this.focusNextIndex(r,-1,n)}triggerKeyboardEvent(r,n){const i=this.target(r.target),o=i&&i.closest(this.selectors.join(",")),a=r.key===" "?"Space":r.key,s=r.nativeEvent.type;o&&this.keyboardEvents[s][a]&&this.keyboardEvents[s][a].call(void 0,o,this,r,n)}triggerMouseEvent(r){const n=this.target(r.target),i=n&&n.closest(this.selectors.join(",")),o=r.nativeEvent.type;i&&this.mouseEvents[o].call(void 0,i,this,r)}focusElement(r,n){r&&(n&&(this.rovingTabIndex&&n.setAttribute("tabindex","-1"),this.focusClass&&(this.removeFocusClass(n),n.removeEventListener("focus",this.setFocusClass))),this.rovingTabIndex&&r.setAttribute("tabindex",String(this.tabIndex)),this.focusClass&&(r.classList.add(this.focusClass),r.addEventListener("focus",this.setFocusClass)),r.focus(this.focusOptions),this.lastFocused=r)}initializeRovingTab(r){const n=r?this.elements[r]:this.first;n&&(this.focusClass&&n.addEventListener("focus",this.setFocusClass),n.setAttribute("tabindex",String(this.tabIndex)),this.disableTabindexForRest(n))}removeFocusListener(){this.lastFocused&&this.lastFocused.removeEventListener("focus",this.setFocusClass)}removeFocusClass(r){this.focusClass&&r.classList.remove(this.focusClass)}customElements(r){return this.root.current?Array.from(this.root.current.querySelectorAll(r.join(","))):[]}target(r){var n;const i=r,o=i&&i.ownerDocument||null,a=o&&((n=o==null?void 0:o.defaultView)==null?void 0:n.Element)||Element;return r instanceof a?r:null}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const im=t=>{const r=t.shadowRoot,n=t.contentDocument;return r&&r.activeElement?im(r.activeElement):n&&n.activeElement?im(n.activeElement):t},Ki=t=>{if(!(!t||!t.activeElement))return im(t.activeElement)};/** + */const im=t=>{const r=t.shadowRoot,n=t.contentDocument;return r&&r.activeElement?im(r.activeElement):n&&n.activeElement?im(n.activeElement):t},Yi=t=>{if(!(!t||!t.activeElement))return im(t.activeElement)};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. @@ -377,13 +377,13 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const oSt={name:"@progress/kendo-react-intl",productName:"KendoReact",productCodes:["KENDOUIREACT","KENDOUICOMPLETE"],publishDate:1722843798,version:"",licensingDocsUrl:"https://www.telerik.com/kendo-react-ui/components/my-license/"};/** + */const aSt={name:"@progress/kendo-react-intl",productName:"KendoReact",productCodes:["KENDOUIREACT","KENDOUICOMPLETE"],publishDate:1722843798,version:"",licensingDocsUrl:"https://www.telerik.com/kendo-react-ui/components/my-license/"};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let iT=class{constructor(r){this.locale=r,gi(oSt)}format(r,...n){return n.length===1&&Array.isArray(n[0])?Kk(r,n[0],this.locale):Kk(r,n,this.locale)}formatDate(r,n){return OP(r,n,this.locale)}toString(r,n){return $P(r,n,this.locale)}parseNumber(r,n){return Vwt(r,this.locale,n)}parseDate(r,n){return vCt(r,n,this.locale)}formatNumber(r,n){return PP(r,n,this.locale)}dateFieldName(r){return Bbt(r,this.locale)}dateFormatNames(r){return zP(this.locale,r)}splitDateFormat(r){return yCt(r,this.locale)}numberSymbols(){return awt(this.locale)}firstDay(){return kP(this.locale)}localeInfo(){return x4(this.locale)}localeCurrency(){return ab(this.locale)}};/** + */let nT=class{constructor(r){this.locale=r,vi(aSt)}format(r,...n){return n.length===1&&Array.isArray(n[0])?qk(r,n[0],this.locale):qk(r,n,this.locale)}formatDate(r,n){return BP(r,n,this.locale)}toString(r,n){return WP(r,n,this.locale)}parseNumber(r,n){return Fwt(r,this.locale,n)}parseDate(r,n){return gCt(r,n,this.locale)}formatNumber(r,n){return TP(r,n,this.locale)}dateFieldName(r){return Nbt(r,this.locale)}dateFormatNames(r){return MP(this.locale,r)}splitDateFormat(r){return xCt(r,this.locale)}numberSymbols(){return swt(this.locale)}firstDay(){return _P(this.locale)}localeInfo(){return x4(this.locale)}localeCurrency(){return sb(this.locale)}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. @@ -395,208 +395,208 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let nT=class{constructor(r){this.language=r}toLanguageString(r,n){return this.language&&av[this.language]&&av[this.language].hasOwnProperty(r)?av[this.language][r]:n}};/** + */let oT=class{constructor(r){this.language=r}toLanguageString(r,n){return this.language&&av[this.language]&&av[this.language].hasOwnProperty(r)?av[this.language][r]:n}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const fp=_.createContext({intl:new iT("en"),localization:new nT});/** + */const fp=_.createContext({intl:new nT("en"),localization:new oT});/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */function Ka(t){const r=t.context;return r&&r.intl?r.intl:new iT("en")}function si(t){const r=t.context;return r&&r.localization?r.localization:new nT}function Wl(t){t.contextType=fp}function Ri(t){t.contextType=fp}/** + */function Xa(t){const r=t.context;return r&&r.intl?r.intl:new nT("en")}function ai(t){const r=t.context;return r&&r.localization?r.localization:new oT}function Wl(t){t.contextType=fp}function Vi(t){t.contextType=fp}/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const oT=()=>_.useContext(fp).intl;/** + */const aT=()=>_.useContext(fp).intl;/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const jl=()=>_.useContext(fp).localization;var Qs="arc",t_="ArrowUp",e_="ArrowDown",r_="ArrowLeft",i_="ArrowRight",aSt="Tab",xl="aria-activedescendant",sSt="axisLabelClick",Ar="#000",A1="bottom",a1="center",Nn="circle",di=3,zb="cross",Na="date",aT="12px sans-serif",sT=400,X1=10,Mb=600,s8="end",lSt="Enter",cSt="Escape",lT=/\{\d+:?/,Ru="height",cT=100,nm="inside",hT="inherit",v1="left",Rr=Number.MAX_VALUE,ti=-Number.MAX_VALUE,om="none",hSt="noteClick",uSt="noteHover",pSt="noteLeave",l8="object",S7="outside",k1="right",uT="roundedRect",Ou="start",kb="string",m1="top",dSt="triangle",fSt="square",vSt="rect",o2="value",z1="#fff",Bu="width",Ne="x",We="y",n_=1,am="pointer",sm="horizontal",gSt="vertical";function Mi(t){return Array.isArray(t)}function Dr(t,r){for(var n=Mi(r)?r:[r],i=0;i=0;s--)(a[s]===o||a[s].original===o)&&a.splice(s,1);else this._events[i]=[];return this},r}(Fe);function o_(t){return typeof t=="function"}function a_(t){return typeof t=="string"?[t]:t}function bSt(){this._defaultPrevented=!0}function wSt(){return this._defaultPrevented===!0}const CSt=xSt;var lm=function(t){var r=typeof window<"u"?window:{},n=r.requestAnimationFrame||r.webkitRequestAnimationFrame||r.mozRequestAnimationFrame||r.oRequestAnimationFrame||r.msRequestAnimationFrame||function(i){setTimeout(i,1e3/60)};lm=function(i){return n.call(r,i)},lm(t)};const pT=lm;var SSt=/&/g,zSt=//g;function e0(t){return String(t).replace(SSt,"&").replace(zSt,"<").replace(_St,">").replace(MSt,""").replace(kSt,"'")}function dT(t){var r=window.console;typeof r<"u"&&r.log&&r.log(t)}function ASt(t){var r={edge:/(edge)[ \/]([\w.]+)/i,webkit:/(chrome)[ \/]([\w.]+)/i,safari:/(webkit)[ \/]([\w.]+)/i,opera:/(opera)(?:.*version|)[ \/]([\w.]+)/i,msie:/(msie\s|trident.*? rv:)([\w.]+)/i,mozilla:/(mozilla)(?:.*? rv:([\w.]+))/i},n={};for(var i in r)if(r.hasOwnProperty(i)){var o=t.match(r[i]);if(o){n[i]=!0,n[o[1].toLowerCase().split(" ")[0].split("/")[0]]=!0,n.version=parseInt(document.documentMode||o[2],10);break}}return n}var Dh=null,LSt={get browser(){return typeof window>"u"||Dh||(Dh=ASt(window.navigator.userAgent)),Dh}};const bl=LSt;var ESt=Date.now||function(){return new Date().getTime()};const c8=ESt;function vp(t,r){var n=0,i;if(!r||r<=0)return t;var o=function(){var a=c8()-n,s=arguments,l=function(){t.apply(null,s),n=c8()};if(!n)return l();i&&clearTimeout(i),a>r?l():i=setTimeout(l,r-a)};return o.cancel=function(){clearTimeout(i)},o}var ISt={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"00ffff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000000",blanchedalmond:"ffebcd",blue:"0000ff",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"00ffff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgrey:"a9a9a9",darkgreen:"006400",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"ff00ff",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",grey:"808080",green:"008000",greenyellow:"adff2f",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgrey:"d3d3d3",lightgreen:"90ee90",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"778899",lightslategrey:"778899",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"00ff00",limegreen:"32cd32",linen:"faf0e6",magenta:"ff00ff",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370d8",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"d87093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",red:"ff0000",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"ffffff",whitesmoke:"f5f5f5",yellow:"ffff00",yellowgreen:"9acd32"};const Ab=ISt;var s_=bl.browser,fT=function(t){var r=Object.keys(Ab);r.push("transparent");var n=new RegExp("^("+r.join("|")+")(\\W|$)","i");return fT=function(i){return n.exec(i)},n.exec(t)},gp=function(t){function r(){t.call(this)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.toHSV=function(){return this},r.prototype.toRGB=function(){return this},r.prototype.toHex=function(i){return this.toBytes().toHex(i)},r.prototype.toBytes=function(){return this},r.prototype.toCss=function(i){return"#"+this.toHex(i)},r.prototype.toCssRgba=function(){var i=this.toBytes();return"rgba("+i.r+", "+i.g+", "+i.b+", "+parseFloat(Number(this.a).toFixed(3))+")"},r.prototype.toDisplay=function(){return s_.msie&&s_.version<9?this.toCss():this.toCssRgba()},r.prototype.equals=function(i){return i===this||i!=null&&this.toCssRgba()===mp(i).toCssRgba()},r.prototype.diff=function(i){if(i===null)return NaN;var o=this.toBytes(),a=i.toBytes();return Math.sqrt(Math.pow((o.r-a.r)*.3,2)+Math.pow((o.g-a.g)*.59,2)+Math.pow((o.b-a.b)*.11,2))},r.prototype.clone=function(){var i=this.toBytes();return i===this&&(i=new La(i.r,i.g,i.b,i.a)),i},r}(Fe),Bs=function(t){function r(n,i,o,a){t.call(this),this.r=n,this.g=i,this.b=o,this.a=a}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.toHSV=function(){var i=this,o=i.r,a=i.g,s=i.b,l=Math.min(o,a,s),h=Math.max(o,a,s),p=h-l,f=h,g,b;return p===0?new cm(0,0,f,this.a):(h!==0?(b=p/h,o===h?g=(a-s)/p:a===h?g=2+(s-o)/p:g=4+(o-a)/p,g*=60,g<0&&(g+=360)):(b=0,g=-1),new cm(g,b,f,this.a))},r.prototype.toHSL=function(){var i=this,o=i.r,a=i.g,s=i.b,l=Math.max(o,a,s),h=Math.min(o,a,s),p,f,g=(l+h)/2;if(l===h)p=f=0;else{var b=l-h;switch(f=g>.5?b/(2-l-h):b/(l+h),l){case o:p=(a-s)/b+(ai.length;)i=n+i;return i}var cm=function(t){function r(n,i,o,a){t.call(this),this.h=n,this.s=i,this.v=o,this.a=a}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.toRGB=function(){var i=this,o=i.h,a=i.s,s=i.v,l,h,p;if(a===0)l=h=p=s;else{o/=60;var f=Math.floor(o),g=o-f,b=s*(1-a),z=s*(1-a*g),M=s*(1-a*(1-g));switch(f){case 0:l=s,h=M,p=b;break;case 1:l=z,h=s,p=b;break;case 2:l=b,h=s,p=M;break;case 3:l=b,h=z,p=s;break;case 4:l=M,h=b,p=s;break;default:l=s,h=b,p=z;break}}return new Bs(l,h,p,this.a)},r.prototype.toHSL=function(){return this.toRGB().toHSL()},r.prototype.toBytes=function(){return this.toRGB().toBytes()},r}(gp),vT=function(t){function r(n,i,o,a){t.call(this),this.h=n,this.s=i,this.l=o,this.a=a}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.toRGB=function(){var i=this.h/360,o=this.s/100,a=this.l/100,s,l,h;if(o===0)s=l=h=a;else{var p=a<.5?a*(1+o):a+o-a*o,f=2*a-p;s=sv(f,p,i+1/3),l=sv(f,p,i),h=sv(f,p,i-1/3)}return new Bs(s,l,h,this.a)},r.prototype.toHSV=function(){return this.toRGB().toHSV()},r.prototype.toBytes=function(){return this.toRGB().toBytes()},r}(gp);function sv(t,r,n){var i=n;return i<0&&(i+=1),i>1&&(i-=1),i<1/6?t+(r-t)*6*i:i<1/2?r:i<2/3?t+(r-t)*(2/3-i)*6:t}function l_(t){return parseFloat(parseFloat(parseInt(t,16)/255).toFixed(3))}function mp(t,r){var n,i;if(t==null||t==="none")return null;if(t instanceof gp)return t;var o=t.toLowerCase();if(n=fT(o))return n[1]==="transparent"?o=new Bs(1,1,1,0):o=mp(Ab[n[1]],r),o.match=[n[1]],o;if((n=/^#?([0-9a-f]{2})([0-9a-f]{2})([0-9a-f]{2})\b/i.exec(o))?i=new La(parseInt(n[1],16),parseInt(n[2],16),parseInt(n[3],16),1):(n=/^#?([0-9a-f])([0-9a-f])([0-9a-f])\b/i.exec(o))?i=new La(parseInt(n[1]+n[1],16),parseInt(n[2]+n[2],16),parseInt(n[3]+n[3],16),1):(n=/^#?([0-9a-f])([0-9a-f])([0-9a-f])([0-9a-f])\b/i.exec(o))?i=new La(parseInt(n[1]+n[1],16),parseInt(n[2]+n[2],16),parseInt(n[3]+n[3],16),l_(n[4]+n[4])):(n=/^#?([0-9a-f]{2})([0-9a-f]{2})([0-9a-f]{2})([0-9a-f]{2})\b/i.exec(o))?i=new La(parseInt(n[1],16),parseInt(n[2],16),parseInt(n[3],16),l_(n[4])):(n=/^rgb\(\s*([0-9]+)\s*,\s*([0-9]+)\s*,\s*([0-9]+)\s*\)/.exec(o))?i=new La(parseInt(n[1],10),parseInt(n[2],10),parseInt(n[3],10),1):(n=/^rgba\(\s*([0-9]+)\s*,\s*([0-9]+)\s*,\s*([0-9]+)\s*,\s*([0-9.]+)\s*\)/.exec(o))?i=new La(parseInt(n[1],10),parseInt(n[2],10),parseInt(n[3],10),parseFloat(n[4])):(n=/^rgb\(\s*([0-9]*\.?[0-9]+)%\s*,\s*([0-9]*\.?[0-9]+)%\s*,\s*([0-9]*\.?[0-9]+)%\s*\)/.exec(o))?i=new Bs(parseFloat(n[1])/100,parseFloat(n[2])/100,parseFloat(n[3])/100,1):(n=/^rgba\(\s*([0-9]*\.?[0-9]+)%\s*,\s*([0-9]*\.?[0-9]+)%\s*,\s*([0-9]*\.?[0-9]+)%\s*,\s*([0-9.]+)\s*\)/.exec(o))?i=new Bs(parseFloat(n[1])/100,parseFloat(n[2])/100,parseFloat(n[3])/100,parseFloat(n[4])):(n=/^color\(\s*srgb\s*([0-9\.]+)\s*([0-9\.]+)\s*([0-9\.]+)\s*(\/\s+([0-9\.]*))?\)/.exec(o))&&(i=new Bs(parseFloat(n[1]),parseFloat(n[2]),parseFloat(n[3]),parseFloat(n[5]||"1"))),i)i.match=n;else if(!r)throw new Error("Cannot parse color: "+o);return i}var HSt=180,Lb=function(t){function r(n){var i=this;if(t.call(this),arguments.length===1)for(var o=r.formats,a=this.resolveColor(n),s=0;s255?255:i},r.prototype.padDigit=function(i){return i.length===1?"0"+i:i},r.prototype.brightness=function(i){var o=Math.round;return this.r=o(this.normalizeByte(this.r*i)),this.g=o(this.normalizeByte(this.g*i)),this.b=o(this.normalizeByte(this.b*i)),this},r.prototype.percBrightness=function(){return Math.sqrt(.241*this.r*this.r+.691*this.g*this.g+.068*this.b*this.b)},r.prototype.isDark=function(){return this.percBrightness()0;)t>>6),r+=Do(128|i&63)):i<65536?(r+=Do(224|i>>>12),r+=Do(128|i>>>6&63),r+=Do(128|i&63)):i<1114111&&(r+=Do(240|i>>>18),r+=Do(128|i>>>12&63),r+=Do(128|i>>>6&63),r+=Do(128|i&63))}return r}var Th="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";function OSt(t){for(var r="",n=0,i=RSt(t);n>2,h=(o&3)<<4|a>>4,p=(a&15)<<2|s>>6,f=s&63;isNaN(a)?p=f=64:isNaN(s)&&(f=64),r=r+Th.charAt(l)+Th.charAt(h)+Th.charAt(p)+Th.charAt(f)}return r}function gT(t){return qe((t.x||{}).location)?{x:t.x.location,y:t.y.location}:{x:t.pageX||t.clientX||0,y:t.pageY||t.clientY||0}}function mT(t){return t===void 0&&(t={}),t.touch?t.touch.initialTouch:t.target}function M0(t){return t===""||t===null||t==="none"||t==="transparent"||!qe(t)}function Ci(t){if(t)return t[t.length-1]}function Wu(t,r,n){return Math.max(Math.min(t,n),r)}function BSt(t,r){if(t.length<2)return t.slice();function n(i,o){for(var a=[],s=0,l=0,h=0;s=this._size?(a[this._head.key]=null,this._head=this._head.newer,this._head.older=null):this._length++},r.prototype.get=function(i){var o=this._map[i];if(o)return o===this._head&&o!==this._tail&&(this._head=o.newer,this._head.older=null),o!==this._tail&&(o.older&&(o.older.newer=o.newer,o.newer.older=o.older),o.older=this._tail,o.newer=null,this._tail.newer=o,this._tail=o),o.value},r}(Fe);const CT=jSt;var GSt=/\r?\n|\r|\t/g,USt=" ";function Db(t){return String(t).replace(GSt,USt)}function ST(t){var r=[];for(var n in t)r.push(n+t[n]);return r.sort().join("")}function zT(t){for(var r=2166136261,n=0;n>>0}function u_(){return{width:0,height:0,baseline:0}}var YSt={baselineMarkerSize:1},um;typeof document<"u"&&(um=document.createElement("div"),um.style.cssText="position: absolute !important; top: -4000px !important; width: auto !important; height: auto !important;padding: 0 !important; margin: 0 !important; border: 0 !important;line-height: normal !important; visibility: hidden !important; white-space: pre!important;");var pm=function(t){function r(n){t.call(this),this._cache=new CT(1e3),this.options=Object.assign({},YSt,n)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.measure=function(i,o,a){if(a===void 0&&(a={}),typeof i>"u"||i===null)return u_();var s=ST(o),l=zT(i+s),h=this._cache.get(l);if(h)return h;var p=u_(),f=a.box||um,g=this._baselineMarker().cloneNode(!1);for(var b in o){var z=o[b];typeof z<"u"&&(f.style[b]=z)}var M=a.normalizeText!==!1?Db(i):String(i);return f.textContent=M,f.appendChild(g),document.body.appendChild(f),M.length&&(p.width=f.offsetWidth-this.options.baselineMarkerSize,p.height=f.offsetHeight,p.baseline=g.offsetTop+this.options.baselineMarkerSize),p.width>0&&p.height>0&&this._cache.put(l,p),f.parentNode.removeChild(f),p},r.prototype._baselineMarker=function(){var i=document.createElement("div");return i.style.cssText="display: inline-block; vertical-align: baseline;width: "+this.options.baselineMarkerSize+"px; height: "+this.options.baselineMarkerSize+"px;overflow: hidden;",i},r}(Fe);pm.current=new pm;const MT=pm;function xp(t,r,n){return MT.current.measure(t,r,n)}const XSt=Object.freeze(Object.defineProperty({__proto__:null,DEG_TO_RAD:Eb,LRUCache:CT,MAX_NUM:j3,MIN_NUM:G3,TextMetrics:MT,append:h8,arabicToRoman:TSt,bindEvents:Ib,createPromise:Nu,defined:qe,definitionId:$u,deg:o4,elementOffset:xT,elementPadding:bT,elementScale:wT,elementSize:Hc,elementStyles:yp,encodeBase64:OSt,eventCoordinates:gT,eventElement:mT,hashKey:zT,isTransparent:M0,last:Ci,limitValue:Wu,measureText:xp,mergeSort:BSt,normalizeText:Db,now:c8,objectKey:ST,promiseAll:yT,rad:Bo,round:lr,unbindEvents:Hb,valueOrDefault:ju},Symbol.toStringTag,{value:"Module"}));var KSt={}.toString,qSt=function(t){function r(n,i){var o=this;i===void 0&&(i=""),t.call(this),this.prefix=i;for(var a in n){var s=n[a];s=o._wrap(s,a),o[a]=s}}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.get=function(i){for(var o=i.split("."),a=this;o.length&&a;){var s=o.shift();a=a[s]}return a},r.prototype.set=function(i,o){var a=this.get(i);a!==o&&(this._set(i,this._wrap(o,i)),this.optionsChange({field:this.prefix+i,value:o}))},r.prototype._set=function(i,o){var a=this,s=i.indexOf(".")>=0,l=this,h=i;if(s){for(var p=h.split("."),f=this.prefix;p.length>1;){h=p.shift(),f+=h+".";var g=l[h];g||(g=new r({},f),g.addObserver(a),l[h]=g),l=g}h=p[0]}l._clear(h),l[h]=o},r.prototype._clear=function(i){var o=this[i];o&&o.removeObserver&&o.removeObserver(this)},r.prototype._wrap=function(i,o){var a=KSt.call(i),s=i;return s!==null&&qe(s)&&a==="[object Object]"&&(!(i instanceof r)&&!(i instanceof Fe)&&(s=new r(s,this.prefix+o+".")),s.addObserver(this)),s},r}(X2);const kT=qSt;function ZSt(t){return function(r){return this[t]!==r&&(this[t]=r,this.geometryChange()),this}}function JSt(t){return function(){return this[t]}}function QSt(t,r){for(var n=0;n0&&!M0(o.color)},r.prototype._clippedBBox=function(o){return this.bbox(o)},Object.defineProperties(r.prototype,n),r}(X2);const a4=ozt;function _T(t,r,n,i){var o=0,a=0;return i&&(o=Math.atan2(i.c*n,i.a*r),i.b!==0&&(a=Math.atan2(i.d*n,i.b*r))),{x:o,y:a}}var d_=Math.PI/2,azt=function(t){function r(n,i){n===void 0&&(n=new ye),i===void 0&&(i=0),t.call(this),this.setCenter(n),this.setRadius(i)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.setCenter=function(i){return this._observerField("center",ye.create(i)),this.geometryChange(),this},r.prototype.getCenter=function(){return this.center},r.prototype.equals=function(i){return i&&i.center.equals(this.center)&&i.radius===this.radius},r.prototype.clone=function(){return new r(this.center.clone(),this.radius)},r.prototype.pointAt=function(i){return this._pointAt(Bo(i))},r.prototype.bbox=function(i){for(var o=this,a=_T(this.center,this.radius,this.radius,i),s=ye.maxPoint(),l=ye.minPoint(),h=0;h<4;h++){var p=o._pointAt(a.x+h*d_).transformCopy(i),f=o._pointAt(a.y+h*d_).transformCopy(i),g=new ye(p.x,f.y);s=ye.min(s,g),l=ye.max(l,g)}return L1.fromPoints(s,l)},r.prototype._pointAt=function(i){var o=this,a=o.center,s=o.radius;return new ye(a.x+s*Math.cos(i),a.y+s*Math.sin(i))},r.prototype.containsPoint=function(i){var o=this,a=o.center,s=o.radius,l=Math.pow(i.x-a.x,2)+Math.pow(i.y-a.y,2)<=Math.pow(s,2);return l},r.prototype._isOnPath=function(i,o){var a=this,s=a.center,l=a.radius,h=s.distanceTo(i);return l-o<=h&&h<=l+o},r}(bp(X2,["radius"]));const l2=azt;var szt="Gradient",lzt=function(t){return function(r){function n(){r.apply(this,arguments)}return r&&(n.__proto__=r),n.prototype=Object.create(r&&r.prototype),n.prototype.constructor=n,n.prototype.fill=function(o,a){var s=this.options;if(qe(o)){if(o&&o.nodeType!==szt){var l={color:o};qe(a)&&(l.opacity=a),s.set("fill",l)}else s.set("fill",o);return this}return s.get("fill")},n.prototype.stroke=function(o,a,s){return qe(o)?(this.options.set("stroke.color",o),qe(a)&&this.options.set("stroke.width",a),qe(s)&&this.options.set("stroke.opacity",s),this):this.options.get("stroke")},n}(t)};const B8=lzt;var czt=En.IDENTITY.toString(),hzt=function(t){return function(r){function n(){r.apply(this,arguments)}return r&&(n.__proto__=r),n.prototype=Object.create(r&&r.prototype),n.prototype.constructor=n,n.prototype.bbox=function(o){var a=k0(this.currentTransform(o)),s=a?a.toString():czt,l;this._bboxCache&&this._matrixHash===s?l=this._bboxCache.clone():(l=this._bbox(a),this._bboxCache=l?l.clone():null,this._matrixHash=s);var h=this.options.get("stroke.width");return h&&l&&l.expand(h/2),l},n.prototype.geometryChange=function(){delete this._bboxCache,this.trigger("geometryChange",{element:this})},n}(t)};const wp=hzt;function uzt(t){var r="_"+t;return function(n){return qe(n)?(this._observerField(r,n),this.geometryChange(),this):this[r]}}function pzt(t,r){for(var n=0;n=0&&g<=1&&b>=0&&b<=1)return new ye(t.x+b*o,t.y+b*s)}var mzt=45,Vh=Math.pow,yzt=["radiusX","radiusY","startAngle","endAngle","anticlockwise"],xzt=function(t){function r(n,i){n===void 0&&(n=new ye),i===void 0&&(i={}),t.call(this),this.setCenter(n),this.radiusX=i.radiusX,this.radiusY=i.radiusY||i.radiusX,this.startAngle=i.startAngle,this.endAngle=i.endAngle,this.anticlockwise=i.anticlockwise||!1,this.xRotation=i.xRotation}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.clone=function(){return new r(this.center,{radiusX:this.radiusX,radiusY:this.radiusY,startAngle:this.startAngle,endAngle:this.endAngle,anticlockwise:this.anticlockwise})},r.prototype.setCenter=function(i){return this._observerField("center",ye.create(i)),this.geometryChange(),this},r.prototype.getCenter=function(){return this.center},r.prototype.pointAt=function(i){var o=this.center,a=Bo(i);return new ye(o.x+this.radiusX*Math.cos(a),o.y+this.radiusY*Math.sin(a))},r.prototype.curvePoints=function(){var i=this,o=this.startAngle,a=this.anticlockwise?-1:1,s=[this.pointAt(o)],l=this._arcInterval(),h=l.endAngle-l.startAngle,p=Math.ceil(h/mzt),f=h/p,g=o,b;this.xRotation&&(b=ar().rotate(this.xRotation,this.center));for(var z=1;z<=p;z++){var M=g+a*f,I=i._intervalCurvePoints(g,M,b);s.push(I.cp1,I.cp2,I.p2),g=M}return s},r.prototype.bbox=function(i){for(var o=this,a=this._arcInterval(),s=a.startAngle,l=a.endAngle,h=_T(this.center,this.radiusX,this.radiusY,i),p=o4(h.x),f=o4(h.y),g=this.pointAt(l).transformCopy(i),b=v_(p,s),z=v_(f,s),M=this.pointAt(s).transformCopy(i),I=ye.min(M,g),F=ye.max(M,g);ba||s&&o===a)&&(a+=360),{startAngle:o,endAngle:a}},r.prototype._intervalCurvePoints=function(i,o,a){var s=this.pointAt(i),l=this.pointAt(o),h=this._derivativeAt(i),p=this._derivativeAt(o),f=(Bo(o)-Bo(i))/3,g=new ye(s.x+f*h.x,s.y+f*h.y),b=new ye(l.x-f*p.x,l.y-f*p.y);return a&&(s.transform(a),l.transform(a),g.transform(a),b.transform(a)),{p1:s,cp1:g,cp2:b,p2:l}},r.prototype._derivativeAt=function(i){var o=Bo(i);return new ye(-this.radiusX*Math.sin(o),this.radiusY*Math.cos(o))},r.prototype.containsPoint=function(i){var o=this._arcInterval(),a=o.endAngle-o.startAngle,s=this,l=s.center,h=s.radiusX,p=s.radiusY,f=l.distanceTo(i),g=Math.atan2(i.y-l.y,i.x-l.x),b=h*p/Math.sqrt(Vh(h,2)*Vh(Math.sin(g),2)+Vh(p,2)*Vh(Math.cos(g),2)),z=this.pointAt(this.startAngle).round($a),M=this.pointAt(this.endAngle).round($a),I=gzt(l,i.round($a),z,M),F;if(a<180)F=I&&lv(l.distanceTo(I),f)&&lv(f,b);else{var H=f_(l.x,l.y,h,p,i.x,i.y);H!==360&&(H=(360+H)%360);var E=o.startAngle<=H&&H<=o.endAngle;F=E&&lv(f,b)||!E&&(!I||I.equals(i))}return F},r.prototype._isOnPath=function(i,o){var a=this._arcInterval(),s=this.center,l=f_(s.x,s.y,this.radiusX,this.radiusY,i.x,i.y);l!==360&&(l=(360+l)%360);var h=a.startAngle<=l&&l<=a.endAngle;return h&&this.pointAt(l).distanceTo(i)<=o},r.fromPoints=function(i,o,a,s,l,h,p){var f=bzt({x1:i.x,y1:i.y,x2:o.x,y2:o.y,rx:a,ry:s,largeArc:l,swipe:h,rotation:p});return new r(f.center,{startAngle:f.startAngle,endAngle:f.endAngle,radiusX:f.radiusX,radiusY:f.radiusY,xRotation:f.xRotation,anticlockwise:h===0})},r}(bp(X2,yzt));function f_(t,r,n,i,o,a){var s=lr((o-t)/n,3),l=lr((a-r)/i,3);return lr(o4(Math.atan2(l,s)))}function bzt(t){var r=t.x1,n=t.y1,i=t.x2,o=t.y2,a=t.rx,s=t.ry,l=t.largeArc,h=t.swipe,p=t.rotation;p===void 0&&(p=0);var f=Bo(p),g=Math.cos(f),b=Math.sin(f),z=g*(r-i)/2+b*(n-o)/2,M=-b*(r-i)/2+g*(n-o)/2,I=l!==h?1:-1,F=Math.pow(z,2),H=Math.pow(M,2),E=Math.pow(a,2),R=Math.pow(s,2),W=F/E+H/R;W>1&&(W=Math.sqrt(F/E+H/R),a=W*a,E=Math.pow(a,2),s=W*s,R=Math.pow(s,2));var $=I*Math.sqrt((E*R-E*H-R*F)/(E*H+R*F));isNaN($)&&($=0);var G=$*(a*M)/s,Z=-$*(s*z)/a,K=g*G-b*Z+(r+i)/2,et=b*G+g*Z+(n+o)/2,at=(z-G)/a,tt=(M-Z)/s,ft=-(z+G)/a,dt=-(M+Z)/s,ht=(tt>=0?1:-1)*o4(Math.acos(at/Math.sqrt(at*at+tt*tt))),lt=lr((at*ft+tt*dt)/(Math.sqrt(at*at+tt*tt)*Math.sqrt(ft*ft+dt*dt)),10),yt=(at*dt-tt*ft>=0?1:-1)*o4(Math.acos(lt));!h&&yt>0&&(yt-=360),h&&yt<0&&(yt+=360);var mt=ht+yt,gt=mt>=0?1:-1;return mt=Math.abs(mt)%360*gt,{center:new ye(K,et),startAngle:ht,endAngle:mt,radiusX:a,radiusY:s,xRotation:p}}function v_(t,r){for(var n=t;nr.y,s&&((o[h]===0||o[h]===1)&&n.bottomRight().x>r.x||00?n.x-o:a-n.x)/(a-o)+s-n.y>=0}return i?1:0}function Izt(t){var r="_"+t;return function(n){return qe(n)?(this._observerField(r,ye.create(n)),this.geometryChange(),this):this[r]}}function Hzt(t,r){for(var n=0;n1)&&(z=0);var M=Math.min(Math.max(g,b),1);return(M>1||M<0)&&(M=1),{min:z,max:M}},r.prototype._intersectionsTo=function(i,o){var a;return this.controlOut()&&i.controlIn()?a=Ezt([this.anchor(),this.controlOut(),i.controlIn(),i.anchor()],o,this.bboxTo(i)):a=DT(this.anchor(),i.anchor(),o),a},r.prototype._isOnCurveTo=function(i,o,a,s){var l=this.bboxTo(i).expand(a,a);if(l.containsPoint(o)){var h=this.anchor(),p=this.controlOut(),f=i.controlIn(),g=i.anchor();if(s==="start"&&h.distanceTo(o)<=a)return!m_(h,p,o);if(s==="end"&&g.distanceTo(o)<=a)return!m_(g,f,o);var b=[h,p,f,g];if(Fh(b,o,"x","y",a)||Fh(b,o,"y","x",a))return!0;var z=ar().rotate(45,o),M=[h.transformCopy(z),p.transformCopy(z),f.transformCopy(z),g.transformCopy(z)];return Fh(M,o,"x","y",a)||Fh(M,o,"y","x",a)}},r.prototype._isOnLineTo=function(i,o,a){var s=this.anchor(),l=i.anchor(),h=o4(Math.atan2(l.y-s.y,l.x-s.x)),p=new L1([s.x,s.y-a/2],[s.distanceTo(l),a]);return p.containsPoint(o.transformCopy(ar().rotate(-h,s)))},r.prototype._isOnPathTo=function(i,o,a,s){var l;return this.controlOut()&&i.controlIn()?l=this._isOnCurveTo(i,o,a/2,s):l=this._isOnLineTo(i,o,a),l},r}(Cp(X2,Pzt));function x_(t){for(var r=t.length,n=j3,i=G3,o=0;o2&&(b_(0,n),o=n.length),o<2||o===2&&n[0].equals(n[1]))return i;var a=n[0],s=n[1],l=n[2];for(i.push(new Di(a));a.equals(n[o-1]);)r=!0,n.pop(),o--;if(o===2){var h=Dc(a,s,E2,I2);return Ci(i).controlOut(dm(h,a,s,E2,I2)),i.push(new Di(s,fm(h,a,s,E2,I2))),i}var p,f;if(r){a=n[o-1],s=n[0],l=n[1];var g=cv(a,s,l);p=g[1],f=g[0]}else{var b=Dc(a,s,E2,I2);p=dm(b,a,s,E2,I2)}for(var z=p,M=0;M<=o-3;M++)if(b_(M,n),o=n.length,M+3<=o){a=n[M],s=n[M+1],l=n[M+2];var I=cv(a,s,l);Ci(i).controlOut(z),z=I[1];var F=I[0];i.push(new Di(s,F))}if(r){a=n[o-2],s=n[o-1],l=n[0];var H=cv(a,s,l);Ci(i).controlOut(z),i.push(new Di(s,H[0])),Ci(i).controlOut(H[1]),i.push(new Di(l,f))}else{var E=Dc(s,l,E2,I2);Ci(i).controlOut(z),i.push(new Di(l,fm(E,s,l,E2,I2)))}return i}function b_(t,r){for(;r[t+1]&&(r[t].equals(r[t+1])||r[t+1].equals(r[t+2]));)r.splice(t+1,1)}function Rzt(t,r,n){var i=!1;if(t.x===r.x)i=!0;else if(r.x===n.x)(r.y=a)&&(i=!0)}return i}function Ozt(t,r,n){var i=TT(t,r),o=FT(i,n.x);return t.x===r.x&&r.x===n.x||lr(o,1)===lr(n.y,1)}function TT(t,r){var n=(r.y-t.y)/(r.x-t.x),i=t.y-n*t.x;return[i,n]}function cv(t,r,n){var i=E2,o=I2,a=!1,s=!1,l;if(Ozt(t,r,n))l=Dc(t,r,E2,I2);else{var h={x:C_(t,r,n,E2),y:C_(t,r,n,I2)};if(h.x&&h.y)l=Dc(t,n,E2,I2),a=!0;else if(Rzt(t,r,n)&&(i=I2,o=E2),h[i])l=0;else{var p;n[o]r[i]&&r[i]>t[i]||n[i]2&&(h="l",f.splice(0,2))),A_[h])A_[h](t,{parameters:f,position:n,isRelative:p,previousCommand:i}),l&&l.toLowerCase()===Wzt&&t.close();else if(h!==L_)throw new Error("Error while parsing SVG path. Unsupported command: "+h);i=h}),t}function Uu(t,r,n){for(var i,o=0;o0){var l=Ci(this.segments),h=new Di(s,a);this.suspend(),l.controlOut(o),this.resume(),this.segments.push(h)}return this},r.prototype.arc=function(o,a,s,l,h){if(this.segments.length>0){var p=Ci(this.segments),f=p.anchor(),g=Bo(o),b=new ye(f.x-s*Math.cos(g),f.y-l*Math.sin(g)),z=new s4(b,{startAngle:o,endAngle:a,radiusX:s,radiusY:l,anticlockwise:h});this._addArcSegments(z)}return this},r.prototype.arcTo=function(o,a,s,l,h,p){if(this.segments.length>0){var f=Ci(this.segments),g=f.anchor(),b=s4.fromPoints(g,ye.create(o),a,s,l,h,p);this._addArcSegments(b)}return this},r.prototype._addArcSegments=function(o){var a=this;this.suspend();for(var s=o.curvePoints(),l=1;l0){for(var h=[],p=Uzt(o),f,g=1;g1){if(s[0]._isOnPathTo(s[1],o,h,"start"))return!0;for(var p=2;p<=l-2;p++)if(s[p-1]._isOnPathTo(s[p],o,h))return!0;if(s[l-2]._isOnPathTo(s[l-1],o,h,"end"))return!0}return!1},r.prototype._bbox=function(o){var a=this.segments,s=a.length,l;if(s===1){var h=a[0].anchor().transformCopy(o);l=new L1(h,h0.ZERO)}else if(s>0)for(var p=1;p0){for(var l=[],h=0;h0&&Ci(this.paths).lineTo(o,a),this},r.prototype.curveTo=function(o,a,s){return this.paths.length>0&&Ci(this.paths).curveTo(o,a,s),this},r.prototype.arc=function(o,a,s,l,h){return this.paths.length>0&&Ci(this.paths).arc(o,a,s,l,h),this},r.prototype.arcTo=function(o,a,s,l,h,p){return this.paths.length>0&&Ci(this.paths).arcTo(o,a,s,l,h,p),this},r.prototype.close=function(){return this.paths.length>0&&Ci(this.paths).close(),this},r.prototype._bbox=function(o){return Uu(this.paths,!0,o)},r.prototype.rawBBox=function(){return Uu(this.paths,!1)},r.prototype._containsPoint=function(o){for(var a=this.paths,s=0;s0){o.moveTo(a[0].x,a[0].y);for(var s=1;s=0&&(this.children.splice(a,1),o.parent=null,this.childrenChange("remove",[o],a)),this},r.prototype.removeAt=function(o){if(0<=o&&o=0;i--)r(t[i],i)},cMt=function(t){function r(n,i){t.call(this,Object.assign({},aMt,i)),this._rect=n,this._fieldMap={}}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.rect=function(i){return i?(this._rect=i,this):this._rect},r.prototype._initMap=function(){var i=this.options,o=this._fieldMap;i.orientation==="horizontal"?(o.sizeField="width",o.groupsSizeField="height",o.groupAxis="x",o.groupsAxis="y"):(o.sizeField="height",o.groupsSizeField="width",o.groupAxis="y",o.groupsAxis="x"),i.reverse?(this.forEach=lMt,this.justifyAlign=oMt):(this.forEach=sMt,this.justifyAlign=Rh)},r.prototype.reflow=function(){var i=this;if(!(!this._rect||this.children.length===0)){this._initMap(),this.options.transform&&this.transform(null);for(var o=this.options,a=this._rect,s=this._initGroups(),l=s.groups,h=s.groupsSize,p=this._fieldMap,f=p.sizeField,g=p.groupsSizeField,b=p.groupAxis,z=p.groupsAxis,M=new ye,I=new ye,F=new h0,H=Rh(h,a,o.alignContent,z,g),E,R,W,$=function(ft,dt){var ht=R.elements[dt];I[b]=E,I[z]=Rh(ft.size[g],W,o.alignItems,z,g),nMt(I,ft,ht),E+=ft.size[f]+o.spacing},G=0;Ga.size[f]){var Z=a.size[f]/W.size[f],K=W.topLeft().scale(Z,Z),et=W.size[g]*Z,at=Rh(et,a,o.alignContent,z,g),tt=ar();b==="x"?tt.translate(a.origin.x-K.x,at-K.y):tt.translate(at-K.x,a.origin.y-K.y),tt.scale(Z,Z),this.transform(tt)}}},r.prototype._initGroups=function(){for(var i=this,o=this,a=o.options,s=o.children,l=a.lineSpacing,h=a.wrap,p=a.spacing,f=this._fieldMap.sizeField,g=this._newGroup(),b=[],z=function(){b.push(g),M+=g.lineSize+l},M=-l,I=0;Ii._rect.size[f]?g.bboxes.length===0?(i._addToGroup(g,H,F),z(),g=i._newGroup()):(z(),g=i._newGroup(),i._addToGroup(g,H,F)):i._addToGroup(g,H,F))}return g.bboxes.length&&z(),{groups:b,groupsSize:M}},r.prototype._addToGroup=function(i,o,a){i.size+=o.size[this._fieldMap.sizeField]+this.options.spacing,i.lineSize=Math.max(o.size[this._fieldMap.groupsSizeField],i.lineSize),i.bboxes.push(o),i.elements.push(a)},r.prototype._newGroup=function(){return{lineSize:0,size:-this.options.spacing,bboxes:[],elements:[]}},r}(P1);const hMt=cMt;var uMt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype._change=function(){this.optionsChange({field:"stops"})},r}(LT);const pMt=uMt;function dMt(t){return function(r){return qe(r)?(this.options.set(t,r),this):this.options.get(t)}}function fMt(t,r){for(var n=0;n1?o=new r(i[0],i[1],i[2]):o=new r(i.offset,i.color,i.opacity),o}},r}(gMt(X2,mMt));const E_=yMt;var xMt=function(t){function r(i){i===void 0&&(i={}),t.call(this),this.stops=new pMt(this._createStops(i.stops)),this.stops.addObserver(this),this._userSpace=i.userSpace,this.id=$u()}t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r;var n={nodeType:{configurable:!0}};return n.nodeType.get=function(){return"Gradient"},r.prototype.userSpace=function(o){return qe(o)?(this._userSpace=o,this.optionsChange(),this):this._userSpace},r.prototype._createStops=function(o){o===void 0&&(o=[]);for(var a=[],s=0;s=0&&this.stops.splice(a,1)},r.prototype.optionsChange=function(o){this.trigger("optionsChange",{field:"gradient"+(o?"."+o.field:""),value:this})},r.prototype.geometryChange=function(){this.optionsChange()},Object.defineProperties(r.prototype,n),r}(X2);const BT=xMt;var bMt=["start","end"],wMt=function(t){function r(n){n===void 0&&(n={}),t.call(this,n),this.start(n.start||new ye),this.end(n.end||new ye(1,0))}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r}(Cp(BT,bMt));const Vb=wMt;var CMt=function(t){function r(n){n===void 0&&(n={}),t.call(this,n),this.center(n.center||new ye),this._radius=qe(n.radius)?n.radius:1,this._fallbackFill=n.fallbackFill}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.radius=function(i){return qe(i)?(this._radius=i,this.geometryChange(),this):this._radius},r.prototype.fallbackFill=function(i){return qe(i)?(this._fallbackFill=i,this.optionsChange(),this):this._fallbackFill},r}(Cp(BT,["center"]));const Fb=CMt;function SMt(t){return .5-Math.cos(t*Math.PI)/2}function zMt(t){return t}function MMt(t,r,n,i){var o=1.70158,a=0,s=i;return t===0?n:t===1?n+i:(a||(a=.5),s0||o.height>0)&&(!a||o.width!==a.width||o.height!==a.height))&&(this.currentSize(o),this._resize(o,i),this.trigger("resize",o))},r.prototype.size=function(i){if(!i)return this.getSize();this.setSize(i)},r.prototype.suspendTracking=function(){this._suspendedTracking=!0},r.prototype.resumeTracking=function(){this._suspendedTracking=!1},r.prototype._enableTracking=function(){},r.prototype._resize=function(){},r.prototype._handler=function(i){var o=this;return function(a){var s=o.eventTarget(a);s&&!o._suspendedTracking&&o.trigger(i,{element:s,originalEvent:a,type:i})}},r.prototype._elementOffset=function(){var i=this.element,o=bT(i),a=xT(i),s=a.left,l=a.top;return{left:s+o.left,top:l+o.top}},r.prototype._surfacePoint=function(i){var o=this._elementOffset(),a=gT(i),s=a.x-o.left,l=a.y-o.top,h=wT(this.element).invert(),p=new ye(s,l).transform(h);return p},r}(CSt);const Rb=IMt;function _n(t,r){return qe(r)&&r!==null?" "+t+'="'+r+'" ':""}function _0(t){for(var r="",n=0;n",I_=document.createElement("div"),TMt=typeof DOMParser<"u";I_.innerHTML=PMt,TMt&&I_.firstChild.namespaceURI!==Xu&&(jT=function(t,r){var n=new DOMParser,i=n.parseFromString($T(r),"text/xml");WT(i);var o=document.adoptNode(i.documentElement);t.innerHTML="",t.appendChild(o)})}const GT=jT;var H_="transform",Oh={clip:"clip-path",fill:"fill"};function D_(t,r){return t==="clip"||t==="fill"&&(!r||r.nodeType==="Gradient")}function VMt(){var t=document.getElementsByTagName("base")[0],r=document.location.href,n="";if(t&&!(bl.browser||{}).msie){var i=r.indexOf("#");i!==-1&&(r=r.substring(0,i)),n=r}return n}var FMt=function(t){function r(n,i){t.call(this,n),this.definitions={},this.options=i}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.destroy=function(){this.element&&(this.element._kendoNode=null,this.element=null),this.clearDefinitions(),t.prototype.destroy.call(this)},r.prototype.load=function(i,o){for(var a=this,s=0;s0&&p.load(h);var f=a.element;f&&p.attachTo(f,o)}},r.prototype.root=function(){for(var i=this;i.parent;)i=i.parent;return i},r.prototype.attachTo=function(i,o){var a=document.createElement("div");GT(a,""+this.render()+"");var s=a.firstChild.firstChild;s&&(qe(o)?i.insertBefore(s,i.childNodes[o]||null):i.appendChild(s),this.setElement(s))},r.prototype.setElement=function(i){this.element&&(this.element._kendoNode=null),this.element=i,this.element._kendoNode=this;for(var o=this.childNodes,a=0;a"},r.prototype.renderOffset=function(){return _n("offset",this.srcElement.offset())},r.prototype.mapStyle=function(){var i=this.srcElement;return[["stop-color",i.color()],["stop-opacity",i.opacity()]]},r.prototype.optionsChange=function(i){i.field==="offset"?this.attr(i.field,i.value):(i.field==="color"||i.field==="opacity")&&this.css("stop-"+i.field,i.value)},r}(V0);const OMt=RMt;var BMt=function(t){function r(n){t.call(this,n),this.id=n.id,this.loadStops()}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.loadStops=function(){for(var i=this,o=this.srcElement.stops,a=this.element,s=0;s"+this.renderChildren()+""},r.prototype.mapCoordinates=function(){var i=this.srcElement,o=i.start(),a=i.end(),s=[["x1",o.x],["y1",o.y],["x2",a.x],["y2",a.y],this.mapSpace()];return s},r}(UT);const $Mt=NMt;var WMt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.template=function(){return""+this.renderChildren()+""},r.prototype.mapCoordinates=function(){var i=this.srcElement,o=i.center(),a=i.radius(),s=[["cx",o.x],["cy",o.y],["r",a],this.mapSpace()];return s},r}(UT);const jMt=WMt;var GMt=function(t){function r(n){t.call(this),this.srcElement=n,this.id=n.id,this.load([n])}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.renderClipRule=function(){return _n("clip-rule","evenodd")},r.prototype.template=function(){return""+this.renderChildren()+""},r}(V0);const UMt=GMt;var YMt=function(t){function r(){t.call(this),this.definitionMap={}}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.attachTo=function(i){this.element=i},r.prototype.template=function(){return""+this.renderChildren()+""},r.prototype.definitionChange=function(i){var o=i.definitions,a=i.action;a==="add"?this.addDefinitions(o):a==="remove"&&this.removeDefinitions(o)},r.prototype.createDefinition=function(i,o){var a;return i==="clip"?a=UMt:i==="fill"&&(o instanceof Vb?a=$Mt:o instanceof Fb&&(a=jMt)),new a(o)},r.prototype.addDefinitions=function(i){var o=this;for(var a in i)o.addDefinition(a,i[a])},r.prototype.addDefinition=function(i,o){var a=this,s=a.element,l=a.definitionMap,h=o.id,p=l[h];if(p)p.count++;else{var f=this.createDefinition(i,o);l[h]={element:f,count:1},this.append(f),s&&f.attachTo(this.element)}},r.prototype.removeDefinitions=function(i){var o=this;for(var a in i)o.removeDefinition(i[a])},r.prototype.removeDefinition=function(i){var o=this.definitionMap,a=i.id,s=o[a];s&&(s.count--,s.count===0&&(this.remove(this.childNodes.indexOf(s.element),1),delete o[a]))},r}(V0);const XMt=YMt;var KMt=function(t){function r(n){t.call(this),this.options=n,this.defs=new XMt}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.attachTo=function(i){this.element=i,this.defs.attachTo(i.firstElementChild)},r.prototype.clear=function(){Sp.prototype.clear.call(this)},r.prototype.template=function(){return this.defs.render()+this.renderChildren()},r.prototype.definitionChange=function(i){this.defs.definitionChange(i)},r}(V0);const qMt=KMt;var YT={dot:[1.5,3.5],dash:[4,3.5],longdash:[8,3.5],dashdot:[3.5,3.5,1.5,3.5],longdashdot:[8,3.5,1.5,3.5],longdashdotdot:[8,3.5,1.5,3.5,1.5,3.5]},vm="solid",XT="butt",ZMt={"fill.opacity":"fill-opacity","stroke.color":"stroke","stroke.width":"stroke-width","stroke.opacity":"stroke-opacity"},JMt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.geometryChange=function(){this.attr("d",this.renderData()),this.invalidate()},r.prototype.optionsChange=function(i){switch(i.field){case"fill":i.value?this.allAttr(this.mapFill(i.value)):this.removeAttr("fill");break;case"fill.color":this.allAttr(this.mapFill({color:i.value}));break;case"stroke":i.value?this.allAttr(this.mapStroke(i.value)):this.removeAttr("stroke");break;case"transform":this.transformChange(i.value);break;default:var o=ZMt[i.field];o&&this.attr(o,i.value);break}this.accessibilityOptionsChange(i),t.prototype.optionsChange.call(this,i)},r.prototype.content=function(){this.element&&(this.element.textContent=this.srcElement.content())},r.prototype.renderData=function(){return this.srcElement.toString(Ob)||void 0},r.prototype.mapStroke=function(i){var o=[];return i&&!M0(i.color)?(o.push(["stroke",i.color]),o.push(["stroke-width",i.width]),o.push(["stroke-linecap",this.renderLinecap(i)]),o.push(["stroke-linejoin",i.lineJoin]),qe(i.opacity)&&o.push(["stroke-opacity",i.opacity]),qe(i.dashType)&&o.push(["stroke-dasharray",this.renderDashType(i)])):o.push(["stroke",Ku]),o},r.prototype.renderStroke=function(){return _0(this.mapStroke(this.srcElement.options.stroke))},r.prototype.renderDashType=function(i){var o=i.dashType,a=i.width;if(a===void 0&&(a=1),o&&o!==vm){for(var s=YT[o.toLowerCase()],l=[],h=0;h"},r}(V0);const F0=JMt;var QMt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.renderData=function(){return this.srcElement.toPath().toString(Ob)},r}(F0);const tkt=QMt;var ekt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.geometryChange=function(){var i=this.center();this.attr("cx",i.x),this.attr("cy",i.y),this.attr("r",this.radius()),this.invalidate()},r.prototype.center=function(){return this.srcElement.geometry().center},r.prototype.radius=function(){return this.srcElement.geometry().radius},r.prototype.template=function(){return""},r}(F0);const rkt=ekt;var ikt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.template=function(){return""+this.renderChildren()+""},r.prototype.optionsChange=function(i){var o=i.field,a=i.value;o==="transform"&&this.transformChange(a),this.accessibilityOptionsChange(i),t.prototype.optionsChange.call(this,i)},r}(V0);const nkt=ikt;var okt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.geometryChange=function(){this.allAttr(this.mapPosition()),this.invalidate()},r.prototype.optionsChange=function(i){i.field==="src"&&this.allAttr(this.mapSource()),t.prototype.optionsChange.call(this,i)},r.prototype.mapPosition=function(){var i=this.srcElement.rect(),o=i.topLeft();return[["x",o.x],["y",o.y],["width",i.width()+"px"],["height",i.height()+"px"]]},r.prototype.renderPosition=function(){return _0(this.mapPosition())},r.prototype.mapSource=function(i){var o=this.srcElement.src();return i&&(o=e0(o)),[["xlink:href",o]]},r.prototype.renderSource=function(){return _0(this.mapSource(!0))},r.prototype.template=function(){return""},r}(F0);const akt=okt;var skt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.renderData=function(){return this.srcElement.toString(Ob)||"undefined"},r}(F0);const lkt=skt;var ckt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.geometryChange=function(){var i=this.srcElement.geometry();this.attr("x",i.origin.x),this.attr("y",i.origin.y),this.attr("width",i.size.width),this.attr("height",i.size.height),this.attr("rx",i.cornerRadius[0]),this.attr("ry",i.cornerRadius[1]),this.invalidate()},r.prototype.size=function(){return this.srcElement.geometry().size},r.prototype.origin=function(){return this.srcElement.geometry().origin},r.prototype.rx=function(){return this.srcElement.geometry().cornerRadius[0]},r.prototype.ry=function(){return this.srcElement.geometry().cornerRadius[1]},r.prototype.template=function(){return""},r}(F0);const hkt=ckt;var uv=/&(?:[a-zA-Z]+|#\d+);/g;function Bb(t){if(!t||typeof t!="string"||!uv.test(t))return t;var r=Bb._element;return uv.lastIndex=0,t.replace(uv,function(n){return r.innerHTML=n,r.textContent||r.innerText})}typeof document<"u"&&(Bb._element=document.createElement("span"));var ukt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.geometryChange=function(){var i=this.pos();this.attr("x",i.x),this.attr("y",i.y),this.invalidate()},r.prototype.optionsChange=function(i){i.field==="font"?(this.attr("style",NT(this.mapStyle())),this.geometryChange()):i.field==="content"&&t.prototype.content.call(this,this.srcElement.content()),t.prototype.optionsChange.call(this,i)},r.prototype.mapStyle=function(i){var o=t.prototype.mapStyle.call(this,i),a=this.srcElement.options.font;return i&&(a=e0(a)),o.push(["font",a],["white-space","pre"]),o},r.prototype.pos=function(){var i=this.srcElement.position(),o=this.srcElement.measure();return i.clone().setY(i.y+o.baseline)},r.prototype.renderContent=function(){var i=this.srcElement.content();return i=Bb(i),i=e0(i),Db(i)},r.prototype.renderTextAnchor=function(){var i;return(this.options||{}).rtl&&!(bl.browser.msie||bl.browser.edge)&&(i="end"),_n("text-anchor",i)},r.prototype.renderPaintOrder=function(){var i=this.srcElement.options.paintOrder;return i?_n("paint-order",i):""},r.prototype.template=function(){return""+this.renderContent()+""},r}(F0);const pkt=ukt;os.Arc=tkt;os.Circle=rkt;os.Group=nkt;os.Image=akt;os.MultiPath=lkt;os.Path=F0;os.Rect=hkt;os.Text=pkt;var dkt="rtl";function fkt(t){var r;try{r=t.getScreenCTM?t.getScreenCTM():null}catch{}if(r){var n=-r.e%1,i=-r.f%1,o=t.style;(n!==0||i!==0)&&(o.left=n+"px",o.top=i+"px")}}var vkt=function(t){function r(i,o){t.call(this,i,o),this._root=new qMt(Object.assign({rtl:yp(i,"direction").direction===dkt},this.options)),GT(this.element,this._template("")),this._rootElement=this.element.firstElementChild,this._rootElement.style.width="100%",this._rootElement.style.height="100%",this._rootElement.style.overflow="hidden",fkt(this._rootElement),this._root.attachTo(this._rootElement),Ib(this.element,{click:this._click,mouseover:this._mouseenter,mouseout:this._mouseleave,mousemove:this._mousemove}),this.resize()}t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r;var n={type:{configurable:!0}};return n.type.get=function(){return"svg"},r.prototype.destroy=function(){this._root&&(this._root.destroy(),this._root=null,this._rootElement=null,Hb(this.element,{click:this._click,mouseover:this._mouseenter,mouseout:this._mouseleave,mousemove:this._mousemove})),t.prototype.destroy.call(this)},r.prototype.translate=function(o){var a=Math.round(o.x)+" "+Math.round(o.y)+" "+this._size.width+" "+this._size.height;this._offset=o,this._rootElement.setAttribute("viewBox",a)},r.prototype.draw=function(o){t.prototype.draw.call(this,o),this._root.load([o])},r.prototype.clear=function(){t.prototype.clear.call(this),this._root.clear()},r.prototype.svg=function(){return""+this._template()},r.prototype.exportVisual=function(){var o=this,a=o._visual,s=o._offset;if(s){var l=new P1;l.children.push(a),l.transform(ar().translate(-s.x,-s.y)),a=l}return a},r.prototype._resize=function(){this._offset&&this.translate(this._offset)},r.prototype._template=function(o){var a=typeof o=="string"?o:"style='width: 100%; height: 100%; overflow: hidden;' ";return""+this._root.render()+""},Object.defineProperties(r.prototype,n),r}(Rb);const gkt=vkt;var mkt={};const Zo=mkt;var ykt=function(t){function r(n){t.call(this,n),n&&this.initClip()}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.initClip=function(){var i=this.srcElement.clip();i&&(this.clip=i,i.addObserver(this))},r.prototype.clear=function(){this.srcElement&&this.srcElement.removeObserver(this),this.clearClip(),t.prototype.clear.call(this)},r.prototype.clearClip=function(){this.clip&&(this.clip.removeObserver(this),delete this.clip)},r.prototype.setClip=function(i){if(this.clip){i.beginPath();var o=new Zo[this.clip.nodeType](this.clip);o.renderPoints(i,this.clip),i.clip("evenodd")}},r.prototype.optionsChange=function(i){i.field==="clip"&&(this.clearClip(),this.initClip()),t.prototype.optionsChange.call(this,i)},r.prototype.setTransform=function(i){if(this.srcElement){var o=this.srcElement.transform();o&&i.transform.apply(i,o.matrix().toArray(6))}},r.prototype.loadElements=function(i,o,a){for(var s=this,l=0;l0&&f.load(p,o,a),qe(o)?s.insertAt(f,o):s.append(f)}},r.prototype.load=function(i,o,a){this.loadElements(i,o,a),this.invalidate()},r.prototype.setOpacity=function(i){if(this.srcElement){var o=this.srcElement.opacity();qe(o)&&this.globalAlpha(i,o)}},r.prototype.globalAlpha=function(i,o){var a=o;a&&i.globalAlpha&&(a*=i.globalAlpha),i.globalAlpha=a},r.prototype.visible=function(){var i=this.srcElement;return!i||i&&i.options.visible!==!1},r}(Sp);const KT=ykt;var xkt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.renderTo=function(i){if(this.visible()){i.save(),this.setTransform(i),this.setClip(i),this.setOpacity(i);for(var o=this.childNodes,a=0;a0;)a=i.pop(),a.addObserver(o),a.nodeType==="Group"?h8(i,a.children):o._insertShape(a)},r.prototype._insertShape=function(i){var o=i.bbox();if(o){var a=this.getSectors(o),s=a[0][0],l=a[1][0];if(this.inRoot(a))this.root.insert(i,o);else{var h=this.rootMap;h[s]||(h[s]={}),h[s][l]||(h[s][l]=new Mkt(new L1([s*Po,l*Po],[Po,Po]))),h[s][l].insert(i,o)}}},r.prototype.remove=function(i){var o=this;if(i.removeObserver(this),i.nodeType==="Group")for(var a=i.children,s=0;s1||i[1].length>1},r.prototype.getSectors=function(i){for(var o=i.bottomRight(),a=Math.floor(o.x/Po),s=Math.floor(o.y/Po),l=[[],[]],h=Math.floor(i.origin.x/Po);h<=a;h++)l[0].push(h);for(var p=Math.floor(i.origin.y/Po);p<=s;p++)l[1].push(p);return l},r}(Fe);function Akt(t,r){return t._zIndexr._zIndex?-1:0}const T_=_kt;var as=function(r){r.bind("mouseenter",this._mouseenter.bind(this)),r.bind("mouseleave",this._mouseleave.bind(this)),this.element=r.element};as.prototype.clear=function(){this._resetCursor()};as.prototype.destroy=function(){this._resetCursor(),delete this.element};as.prototype._mouseenter=function(r){var n=this._shapeCursor(r);n?(this._current||(this._defaultCursor=this._getCursor()),this._setCursor(n)):this._resetCursor()};as.prototype._mouseleave=function(){this._resetCursor()};as.prototype._shapeCursor=function(r){for(var n=r.element;n&&!qe(n.options.cursor);)n=n.parent;if(n)return n.options.cursor};as.prototype._getCursor=function(){if(this.element)return this.element.style.cursor};as.prototype._setCursor=function(r){this.element&&(this.element.style.cursor=r,this._current=r)};as.prototype._resetCursor=function(){this._current&&(this._setCursor(this._defaultCursor||""),delete this._current)};const Lkt=as;function Nb(t,r){var n=r.segments;if(n.length!==0){var i=n[0],o=i.anchor();t.moveTo(o.x,o.y);for(var a=1;a0)return i.strokeStyle=o.color,i.lineWidth=ju(o.width,1),i.lineJoin=ju(o.lineJoin,i.lineJoin),i.save(),this.globalAlpha(i,o.opacity),i.stroke(),i.restore(),!0},r.prototype.dashType=function(){var i=this.srcElement.options.stroke;if(i&&i.dashType)return i.dashType.toLowerCase()},r.prototype.setLineDash=function(i){var o=this.dashType();if(o&&o!==vm){var a=YT[o];i.setLineDash?i.setLineDash(a):(i.mozDash=a,i.webkitLineDash=a)}},r.prototype.setLineCap=function(i){var o=this.dashType(),a=this.srcElement.options.stroke;o&&o!==vm?i.lineCap=XT:a&&a.lineCap&&(i.lineCap=a.lineCap)},r.prototype.setLineJoin=function(i){var o=this.srcElement.options.stroke;o&&o.lineJoin&&(i.lineJoin=o.lineJoin)},r.prototype.renderPoints=function(i,o){Nb(i,o)},r}(KT);const R0=Ikt;var Hkt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.renderPoints=function(i){var o=this.srcElement.toPath();Nb(i,o)},r}(R0);const Dkt=Hkt;var Pkt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.renderPoints=function(i){var o=this.srcElement.geometry(),a=o.center,s=o.radius;i.arc(a.x,a.y,s,0,Math.PI*2)},r}(R0);const Tkt=Pkt;var Vkt=function(t){function r(n,i){t.call(this,n),this.onLoad=this.onLoad.bind(this),this.onError=this.onError.bind(this),this.loading=Nu();var o=this.img=new Image,a=n.src();i&&!/^data:/i.test(a)&&(o.crossOrigin=i),a&&(o.src=a),o.complete?this.onLoad():(o.onload=this.onLoad,o.onerror=this.onError)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.renderTo=function(i){this.loading.state()==="resolved"&&(i.save(),this.setTransform(i),this.setClip(i),this.drawImage(i),i.restore())},r.prototype.optionsChange=function(i){i.field==="src"?(this.loading=Nu(),this.img.src=this.srcElement.src()):t.prototype.optionsChange.call(this,i)},r.prototype.onLoad=function(){this.loading.resolve(),this.invalidate()},r.prototype.onError=function(){this.loading.reject(new Error("Unable to load image '"+this.img.src+"'. Check for connectivity and verify CORS headers."))},r.prototype.drawImage=function(i){var o=this.srcElement.rect(),a=o.topLeft();i.drawImage(this.img,a.x,a.y,o.width(),o.height())},r}(R0);const Fkt=Vkt;var Rkt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.renderPoints=function(i){for(var o=this.srcElement.paths,a=0;a"},r.prototype._enableTracking=function(){this._searchTree=new T_,this._cursor=new Lkt(this),t.prototype._enableTracking.call(this)},r.prototype._trackMouse=function(o){if(!this._suspendedTracking){var a=this.eventTarget(o);if(o.type!=="click"){var s=this._currentShape;s&&s!==a&&this.trigger("mouseleave",{element:s,originalEvent:o,type:"mouseleave"}),a&&s!==a&&this.trigger("mouseenter",{element:a,originalEvent:o,type:"mouseenter"}),this.trigger("mousemove",{element:a,originalEvent:o,type:"mousemove"}),this._currentShape=a}else a&&this.trigger("click",{element:a,originalEvent:o,type:"click"})}},Object.defineProperties(r.prototype,n),r}(Rb);const Gkt=jkt;var pv,dv,JT=function(){return typeof document<"u"},Ukt=function(){return JT()&&document.createElement("canvas").getContext},Ykt=function(){return JT()&&document.implementation.hasFeature("http://www.w3.org/TR/SVG11/feature#BasicStructure","1.1")},Xkt=function(t){function r(){t.call(this),this._items=[{name:"svg",type:gkt},{name:"canvas",type:Gkt}]}t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r;var n={support:{configurable:!0},current:{configurable:!0}};return n.support.get=function(){return dv||(dv={canvas:Ukt(),svg:Ykt()}),dv},n.current.get=function(){return pv||(pv=new r),pv},r.prototype.create=function(o,a){var s=this._items,l=s[0];if(a&&a.type){for(var h=a.type.toLowerCase(),p=0;p=r?t%r:t}function yr(t){return typeof t=="function"}var B_="object",qkt="undefined";function tV(t,r){for(var n in r)if(!(n==="__proto__"||n==="constructor")){var i=r[n],o=typeof i,a=void 0;if(o===B_&&i!==null?a=i.constructor:a=null,a&&a!==Array)if(i instanceof Date)t[n]=new Date(i.getTime());else if(yr(i.clone))t[n]=i.clone();else{var s=t[n];typeof s===B_?t[n]=s||{}:t[n]={},tV(t[n],i)}else o!==qkt&&(t[n]=i)}return t}function St(t){for(var r=arguments,n=arguments.length,i=1;i0;)n[i]=arguments[i+1];return this.observer[r].apply(this.observer,n)};yo.prototype.requiresHandlers=function(r){var n=this;if(this.observer.requiresHandlers)return this.observer.requiresHandlers(r);for(var i=0;i0?Math.ceil(r):Math.floor(r),r}var nn=XSt,O0=nn.append,nc=nn.bindEvents,ie=nn.defined,Ns=nn.deg,wl=nn.elementOffset,Ha=nn.elementSize,nV=nn.eventCoordinates,xo=nn.eventElement,r_t=nn.hashKey,Vr=nn.last,Xe=nn.limitValue,i_t=nn.objectKey,Qr=nn.rad,Ae=nn.round,oc=nn.unbindEvents,t1=nn.valueOrDefault,u0=function(){};u0.fetchFonts=function(r,n,i){i===void 0&&(i={depth:0});var o=5;!r||i.depth>o||!document.fonts||Object.keys(r).forEach(function(a){var s=r[a];a==="dataSource"||a[0]==="$"||!s||(a==="font"?n.push(s):typeof s=="object"&&(i.depth++,u0.fetchFonts(s,n,i),i.depth--))})};u0.loadFonts=function(r,n){var i=[];if(r.length>0&&document.fonts){try{i=r.map(function(o){return document.fonts.load(o)})}catch(o){dT(o)}Promise.all(i).then(n,n)}else n()};u0.preloadFonts=function(r,n){var i=[];u0.fetchFonts(r,i),u0.loadFonts(i,n)};function de(t,r){var n=t.prototype;n.options?n.options=St({},n.options,r):n.options=r}var n_t="k-icon",fv="k-i-",o_t="k-font-icon",a_t="k-svg-icon",$_="k-svg-i-",Yl=function(r,n){this.element=r,this.options=St({},this.options,n),this.wrapper()};Yl.prototype.wrapper=function(){this.addClasses()};Yl.prototype.addClasses=function(){};Yl.prototype.html=function(){return this.element.outerHTML};de(Yl,{name:"",size:"none",themeColor:"none",flip:"default",iconClass:"",stylingOptions:["size","themeColor","fill"]});var oV=function(t){function r(n,i){t.call(this,n,i)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.wrapper=function(){var i=this.element.className.split(" ").find(function(a){return a.startsWith(fv)}),o=this.options.icon?""+(this.options.icon.startsWith(fv)?"":fv)+this.options.icon:"";this._className=o,Dr(this.element,n_t),Dr(this.element,o_t),_b(this.element,i),Dr(this.element,o),Dr(this.element,this.options.iconClass||""),t.prototype.wrapper.call(this)},r}(Yl);de(oV,{name:"HTMLFontIcon",icon:null});var aV=function(t){function r(n,i){n.innerHTML="",t.call(this,n,i)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.wrapper=function(){var i=this.options.icon,o=this.options.iconClass,a=this.element.className.split(" ").find(function(f){return f.startsWith($_)});if(!i&&o){var s=/k-i-(\w+(?:-\w+)*)/,l=o.match(s);l&&(i=l[1],o=o.replace(l[0],""))}$n(i)&&(i=i.replace("k-i-","").replace(/-./g,function(f){return f[1].toUpperCase()}),i=this.options.svgIcons[i]||this.options.svgIcons[i+"Icon"]);var h=i&&i.name?""+$_+i.name:"";if(this._className=h,Dr(this.element,a_t),_b(this.element,a),Dr(this.element,h),Dr(this.element,o||""),this.element.setAttribute("aria-hidden","true"),i&&t_t(i)){var p=document.createElementNS("http://www.w3.org/2000/svg","svg");p.setAttribute("viewBox",i.viewBox||""),p.setAttribute("focusable","false"),p.innerHTML=i.content||"",this.element.appendChild(p)}t.prototype.wrapper.call(this)},r}(Yl);de(aV,{name:"HTMLSvgIcon",icon:null,svgIcons:{}});var W_={svg:aV,font:oV};function U3(t,r){var n=t,i=r;return(!n||U2(n)&&!(n instanceof HTMLElement)||$n(n))&&(i=n,n=document.createElement("span")),$n(i)&&(i={icon:i}),i.type||(i.type="svg"),W_[i.type]?new W_[i.type](n,i).html():null}function gm(t){for(var r=Rr,n=ti,i=0,o=t.length;i=this.height&&(this.height=r+1),n>=this.width&&(this.width=n+1)};vi.prototype.each=function(r,n){for(var i=this,o=0;o=0;)for(var o=n[i]=new Array(r),a=r;--a>=0;)o[a]=i===a?1:0;return this};vi.prototype.multiply=function(r){for(var n=this,i=new vi,o=0;o=0;)for(var g=f;--g>=0;)if(i[g][f])for(var b=2*r;--b>=r;)i[g][b]-=i[f][b]*i[g][f];return n.slice(0,r,r,r)};vi.prototype.augment=function(r){var n=this.clone(),i=n.width;return r.each(function(o,a,s){n.set(a,s+i,o)}),n};vi.prototype.slice=function(r,n,i,o){for(var a=this,s=new vi,l=0;li&&(i=s,o=t)}return o}var X3={down:"pointerdown",move:"pointermove",up:"pointerup",cancel:"pointercancel pointerleave"};function p_t(t){return X3[t]||t}var To=function(t){var r=/([^ ]+)/g,n=t.replace(r,p_t);return n};function N8(){var t="",r,n;for(r=0;r<32;r++)n=Math.random()*16|0,(r===8||r===12||r===16||r===20)&&(t+="-"),t+=(r===12?4:r===16?n&3|8:n).toString(16);return t}var mm=new WeakMap,Qu=Symbol("id");function Hn(t,r,n,i,o){f_t(t,r,n,i,o)}function r2(t,r,n,i,o){g_t(t,r,n,i)}function d_t(t){return typeof t=="string"}function f_t(t,r,n,i,o){var a=Mi(r)?r:(r||"").split(" ");a.forEach(function(s){v_t(t,s,n,i,o)})}function v_t(t,r,n,i,o){var a=i,s;n&&yr(n)&&!i?a=n:n&&d_t(n)&&yr(a)&&(s=n);var l=function(p){var f=p.target?p.target.closest(s):null;if(!s||s&&p.target&&f){var g=s?f:p.currentTarget;Object.defineProperty(p,"currentTarget",{value:g}),Object.defineProperty(p,"delegateTarget",{value:t}),a(p)}};a[Qu]=N8();var h=mm.get(t);h||(h=new Map,mm.set(t,h)),h.set(a[Qu],l),t.addEventListener(r,l,!!o)}function g_t(t,r,n,i){var o=Mi(r)?r:(r||"").split(" ");o.forEach(function(a){m_t(t,a,n,i)})}function m_t(t,r,n,i){var o=mm.get(t);if(o&&n&&n[Qu]){var a=n[Qu],s=o.get(a);o.delete(a),s&&t.removeEventListener(r,s,!!i)}}function $8(){var t=y_t(navigator.userAgent),r={};return r.mobileOS=t,r}function y_t(t){var r=!1,n={wp:/(Windows Phone(?: OS)?)\s(\d+)\.(\d+(\.\d+)?)/,fire:/(Silk)\/(\d+)\.(\d+(\.\d+)?)/,android:/(Android|Android.*(?:Opera|Firefox).*?\/)\s*(\d+)\.?(\d+(\.\d+)?)?/,iphone:/(iPhone|iPod).*OS\s+(\d+)[\._]([\d\._]+)/,ipad:/(iPad).*OS\s+(\d+)[\._]([\d_]+)/,playbook:/(PlayBook).*?Tablet\s*OS\s*(\d+)\.(\d+(\.\d+)?)/,windows:/(MSIE)\s+(\d+)\.(\d+(\.\d+)?)/,tizen:/(tizen).*?Version\/(\d+)\.(\d+(\.\d+)?)/i,sailfish:/(sailfish).*rv:(\d+)\.(\d+(\.\d+)?).*firefox/i},i={ios:/^i(phone|pad|pod)$/i,android:/^android|fire$/i,windows:/windows/,wp:/wp/,flat:/sailfish|ffos|tizen/i};for(var o in n){var a=t.match(n[o]);if(a){if(o==="windows"&&"plugins"in navigator)return!1;r={},r.device=o,r.name=x_t(o,i),r[r.name]=!0;break}}return r}function x_t(t,r,n){for(var i in r)if(r[i].test(t))return i;return n!==void 0?n:t}function U_(){}function l4(){return new Date().getTime()}var Y_="string",X_="function",b_t=function(){this._defaultPrevented=!0},w_t=function(){return this._defaultPrevented===!0},q2=function(t){function r(){t.call(this),this._events={}}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.destroy=function(){this.unbind()},r.prototype.bind=function(i,o,a){var s=this,l,h=typeof i===Y_?[i]:i||[],p,f,g,b=typeof o===X_,z;if(o===void 0){for(l in i)s.bind(l,i[l]);return s}var M=function(){var I=h[l];g=b?o:o[I],g&&(a&&(f=g,g=function(){s.unbind(I,g),f.apply(s,arguments)},g.original=f),z=s._events[I]=s._events[I]||[],z.push(g))};for(l=0,p=h.length;l=0;l--)(s[l]===o||s[l].original===o)&&s.splice(l,1);else a._events[i]=[];return a},r.prototype._setEvents=function(i){for(var o=this,a=(this.events||[]).length,s=0;s1},r.prototype._maxTouchesReached=function(){return this.touches.length>=this._maxTouches},r.prototype._disposeAll=function(){for(var i=this.touches;i.length>0;)i.pop().dispose()},r.prototype._isMoved=function(){return h2(this.touches,function(i){return i.isMoved()}).length},r.prototype._select=function(i){(!this.allowSelection||this.trigger(Z_,{event:i}))&&i.preventDefault()},r.prototype._start=function(i){var o=this,a=0,s=o.filter,l,h=rA(i),p=h.length,f,g=i.which;if(!(g&&g>1||o._maxTouchesReached()))for(r.current=null,o.currentTarget=i.currentTarget,o.stopPropagation&&i.stopPropagation();a=this.x1&&i.x<=this.x2&&i.y>=this.y1&&i.y<=this.y2},r.prototype.points=function(){return[new Qe(this.x1,this.y1),new Qe(this.x2,this.y1),new Qe(this.x2,this.y2),new Qe(this.x1,this.y2)]},r.prototype.getHash=function(){return[this.x1,this.y1,this.x2,this.y2].join(",")},r.prototype.overlaps=function(i){return!(i.y2=a*a&&F<=s*s},r.prototype.getBBox=function(){var i=this,o=new Ce(Rr,Rr,ti,ti),a=Ae(this.startAngle%360),s=Ae((a+this.angle)%360),l=this.innerRadius,h=[0,90,180,270,a,s].sort(A_t),p=h.indexOf(a),f=h.indexOf(s),g;a===s?g=h:p0&&a===s)&&(s+=L_t);var l=new ye(i.center.x,i.center.y),h=Math.max(i.radius,0),p=Math.max(i.innerRadius,0),f=new s4(l,{startAngle:a,endAngle:s,radiusX:h,radiusY:h}),g=$e.fromArc(f,o).close();if(p){f.radiusX=f.radiusY=p;var b=f.pointAt(s);g.lineTo(b.x,b.y),g.arc(s,a,p,p,!0)}else g.lineTo(l.x,l.y);return g},r}(Fe);Cl.current=new Cl;var R1=function(t){function r(n){t.call(this),this.children=[],this.options=St({},this.options,this.initUserOptions(n))}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.initUserOptions=function(i){return i},r.prototype.reflow=function(i){for(var o=this.children,a,s=0;so)break}this.visual.insert(l,i)},r.prototype.traverse=function(i){for(var o=this.children,a=o.length,s=0;s0&&g.width()>0})[0]}var mV=function(t){function r(n){t.call(this,n);var i=this.options;i.width=parseInt(i.width,10),i.height=parseInt(i.height,10),this.gradients={}}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.reflow=function(){var i=this,o=i.options,a=i.children,s=new Ce(0,0,o.width,o.height);this.box=s.unpad(o.margin);for(var l=0;lg&&(z.push({groupElements:E,groupSize:M,groupElementsSize:I}),H=Math.max(H,I),F+=f+M,M=0,I=0,E=[]),M=Math.max(M,$[h]),I>0&&(I+=p),I+=$[l],E.push(W)}return z.push({groupElements:E,groupSize:M,groupElementsSize:I}),H=Math.max(H,I),F+=M,{groups:z,groupsSize:F,maxGroupElementsSize:H}},r.prototype.elementSize=function(i){return{width:i.box.width(),height:i.box.height()}},r.prototype.createVisual=function(){},r}(R1);de(Mp,{vertical:!0,wrap:!0,vSpacing:0,spacing:0});var P_t=OT,yV=function(t){function r(n,i){t.call(this,i),this.content=n,this.reflow(new Ce)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.reflow=function(i){var o=this.options,a=o.size=xp(this.content,{font:o.font});this.baseline=a.baseline,this.box=new Ce(i.x1,i.y1,i.x1+a.width,i.y1+a.height)},r.prototype.createVisual=function(){var i=this.options,o=i.font,a=i.color,s=i.opacity,l=i.cursor,h=i.stroke,p=i.paintOrder;this.visual=new P_t(this.content,this.box.toRect().topLeft(),{font:o,fill:{color:a,opacity:s},cursor:l,stroke:h,paintOrder:p})},r}(R1);de(yV,{font:aT,color:Ar});function Sl(t){var r=t.origin,n=t.bottomRight();return new Ce(r.x,r.y,n.x,n.y)}var T_t=/\n/m,Wn=function(t){function r(n,i,o){t.call(this,i),this.content=n,this.data=o,this._initContainer(),this.options._autoReflow!==!1&&this.reflow(new Ce)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype._initContainer=function(){var i=this.options,o=String(this.content).split(T_t),a=new Mp({vertical:!0,align:i.align,wrap:!1}),s=St({},i,{opacity:1,animation:null});this.container=a,this.append(a);for(var l=0;l0;)n[i]=arguments[i+1];var o=this.intl;return $n(r)&&r.match(lT)?o.format.apply(o,[r].concat(n)):o.toString(n[0],r)};_p.prototype.localeAuto=function(r,n,i){var o=this.intl,a;return $n(r)&&r.match(lT)?a=r.replace(R_t,function(s,l,h){var p=n[parseInt(l,10)];return o.toString(p,h?h.substring(1):"",i)}):a=o.toString(n[0],r,i),a};Object.defineProperties(_p.prototype,Yb);var Kl=function(r,n){n===void 0&&(n={}),this._intlService=n.intlService,this.sender=n.sender||r,this.format=new _p(n.intlService),this.chart=r,this.rtl=!!n.rtl},Xb={intl:{configurable:!0}};Xb.intl.get=function(){return this._intlService||kp.implementation};Xb.intl.set=function(t){this._intlService=t,this.format.intl=t};Kl.prototype.notify=function(r,n){this.chart&&this.chart.trigger(r,n)};Kl.prototype.isPannable=function(r){var n=((this.chart||{}).options||{}).pannable;return n&&n.lock!==r};Object.defineProperties(Kl.prototype,Xb);var bm,Ap=function(){};Ap.register=function(r){bm=r};Ap.create=function(r,n){var i;return bm?i=bm.create(r,n):i=new e9(r,Object.assign({},{multiTouch:!0},n)),i};function wV(t,r){var n=t.tickX,i=t.tickY,o=t.position,a=new $e({stroke:{width:r.width,color:r.color}});return t.vertical?a.moveTo(n,o).lineTo(n+r.size,o):a.moveTo(o,i).lineTo(o,i+r.size),c2(a),a}function CV(t,r){var n=t.lineStart,i=t.lineEnd,o=t.position,a=new $e({stroke:{width:r.width,color:r.color,dashType:r.dashType}});return t.vertical?a.moveTo(n,o).lineTo(i,o):a.moveTo(o,n).lineTo(o,i),c2(a),a}var ql=function(t){function r(n,i){i===void 0&&(i=new Kl),t.call(this,n),this.chartService=i,this.options.visible||(this.options=St({},this.options,{labels:{visible:!1},line:{visible:!1},margin:0,majorTickSize:0,minorTickSize:0})),this.options.minorTicks=St({},{color:this.options.line.color,width:this.options.line.width,visible:this.options.minorTickType!==om},this.options.minorTicks,{size:this.options.minorTickSize,align:this.options.minorTickType}),this.options.majorTicks=St({},{color:this.options.line.color,width:this.options.line.width,visible:this.options.majorTickType!==om},this.options.majorTicks,{size:this.options.majorTickSize,align:this.options.majorTickType}),this.initFields(),this.options._deferLabels||this.createLabels(),this.createTitle(),this.createNotes()}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.initFields=function(){},r.prototype.labelsRange=function(){return{min:this.options.labels.skip,max:this.labelsCount()}},r.prototype.normalizeLabelRotation=function(i){var o=i.rotation;U2(o)&&(i.alignRotation=o.align,i.rotation=o.angle)},r.prototype.createLabels=function(){var i=this,o=this.options,a=o.vertical?k1:a1,s=St({},o.labels,{align:a,zIndex:o.zIndex}),l=Math.max(1,s.step);if(this.clearLabels(),s.visible){this.normalizeLabelRotation(s),s.rotation==="auto"&&(s.rotation=0,o.autoRotateLabels=!0);for(var h=this.labelsRange(),p=h.min;p0&&o.visible){var s=new $e({stroke:{width:o.width,color:o.color,dashType:o.dashType}});s.moveTo(a.x1,a.y1).lineTo(a.x2,a.y2),i._alignLines&&c2(s);var l=this._lineGroup=new P1;l.append(s),this.visual.append(l),this.createTicks(l)}},r.prototype.getActualTickSize=function(){var i=this.options,o=0;return i.majorTicks.visible&&i.minorTicks.visible?o=Math.max(i.majorTicks.size,i.minorTicks.size):i.majorTicks.visible?o=i.majorTicks.size:i.minorTicks.visible&&(o=i.minorTicks.size),o},r.prototype.createBackground=function(){var i=this,o=i.options,a=i.box,s=o.background;s&&(this._backgroundPath=$e.fromRect(a.toRect(),{fill:{color:s},stroke:null}),this.visual.append(this._backgroundPath))},r.prototype.createPlotBands=function(){var i=this,o=this.options,a=o.plotBands||[],s=o.vertical,l=this.plotArea;if(a.length!==0){for(var h=this._plotbandGroup=new P1({zIndex:-1}),p=h2(this.pane.axes,function(E){return E.options.vertical!==i.options.vertical})[0],f=0;fo?-90:-45},r.prototype.autoRotateLabels=function(){var i=this;if(!this.options.autoRotateLabels||this.options.vertical)return!1;for(var o=this.getMajorTickPositions(),a=this.labels,s=Math.min(a.length,o.length-1),l=0,h=0;h0&&(!ie(h.max)||s<=h.max))return null;if(o0||ss&&l>0&&(g=Xe(o,a,s),f=Xe(o-p,a,s-p)),{min:f,max:g}},r.prototype.valueRange=function(){return{min:this.seriesMin,max:this.seriesMax}},r.prototype.lineDir=function(){var i=this.options,o=i.vertical,a=i.reverse;return(o?-1:1)*(a?-1:1)},r.prototype.lineInfo=function(){var i=this.options,o=i.vertical,a=this.lineBox(),s=o?a.height():a.width(),l=o?We:Ne,h=this.lineDir(),p=h===1?1:2,f=l+p.toString(),g=a[f];return{axis:l,axisOrigin:f,axisDir:h,lineBox:a,lineSize:s,lineStart:g}},r.prototype.pointOffset=function(i){var o=this.lineInfo(),a=o.axis,s=o.axisDir,l=o.axisOrigin,h=o.lineBox,p=o.lineSize,f=s>0?i[a]-h[l]:h[l]-i[a],g=f/p;return g},r.prototype.scaleToDelta=function(i,o){var a=.999,s=Xe(i,-a,a),l;return s>0?l=o*Math.min(1,s):l=o-o/(1+s),l},r.prototype.labelsBetweenTicks=function(){return!this.options.justified},r.prototype.prepareUserOptions=function(){},r}(R1);de(ql,{labels:{visible:!0,rotation:0,mirror:!1,step:1,skip:0},line:{width:1,color:Ar,visible:!0},title:{visible:!0,position:a1},majorTicks:{align:S7,size:4,skip:0,step:1},minorTicks:{align:S7,size:3,skip:0,step:1},axisCrossingValue:0,majorTickType:S7,minorTickType:om,majorGridLines:{skip:0,step:1},minorGridLines:{visible:!1,width:1,color:Ar,skip:0,step:1},margin:5,visible:!0,reverse:!1,justified:!0,notes:{label:{text:""}},_alignLines:!0,_deferLabels:!1});var r9="milliseconds",Kb="seconds",qb="minutes",j8="hours",Jo="days",G8="weeks",A0="months",qa="years",O_t=1,Zb=1e3,Zl=60*Zb,Lp=60*Zl,Za=24*Lp,Jb=7*Za,Qb=31*Za,tw=365*Za,No={years:tw,months:Qb,weeks:Jb,days:Za,hours:Lp,minutes:Zl,seconds:Zb,milliseconds:O_t};function ew(t,r){var n=t.getTime()-r,i=t.getTimezoneOffset()-r.getTimezoneOffset();return n-i*Zl}function hi(t,r){return new Date(t.getTime()+r)}function Q1(t){var r;return t instanceof Date?r=t:t&&(r=new Date(t)),r}function B_t(t,r){r===void 0&&(r=0);var n=0,i=t.getDay();if(!isNaN(i))for(;i!==r;)i===0?i=6:i--,n++;return hi(t,-n*Za)}function Nh(t,r){return r===0&&t.getHours()===23?(t.setHours(t.getHours()+2),!0):!1}function N_t(t,r){var n=new Date(t);n.setMinutes(0,0,0);var i=(t.getTimezoneOffset()-n.getTimezoneOffset())*Zl;return hi(n,i+r*Lp)}function Pi(t,r,n,i){var o=t;if(t){var a=Q1(t),s=a.getHours();n===qa?(o=new Date(a.getFullYear()+r,0,1),Nh(o,0)):n===A0?(o=new Date(a.getFullYear(),a.getMonth()+r,1),Nh(o,s)):n===G8?(o=Pi(B_t(a,i),r*7,Jo),Nh(o,s)):n===Jo?(o=new Date(a.getFullYear(),a.getMonth(),a.getDate()+r),Nh(o,s)):n===j8?o=N_t(a,r):n===qb?(o=hi(a,r*Zl),o.getSeconds()>0&&o.setSeconds(0)):n===Kb?o=hi(a,r*Zb):n===r9&&(o=hi(a,r)),n!==r9&&o.getMilliseconds()>0&&o.setMilliseconds(0)}return o}function rw(t,r,n){return Pi(Q1(t),0,r,n)}function SV(t,r,n){var i=Q1(t);return i&&rw(i,r,n).getTime()===i.getTime()?i:Pi(i,1,r,n)}function i9(t,r){return t&&r?t.getTime()-r.getTime():-1}function $o(t,r){return t.getTime()-r}function tr(t){if(Mi(t)){for(var r=[],n=0;n0){var s=this.options.vertical?We:Ne,l=o[s+1],h=o[s+2],p=a[0],f=Vr(a);(p.box[s+1]>h||p.box[s+2]h||f.box[s+2]=0;)p--;return i.slice(h,p+1)},r.prototype.lineInfo=function(){var i=this.options,o=i.vertical,a=i.reverse,s=this.lineBox(),l=o?s.height():s.width(),h=o?We:Ne,p=a?-1:1,f=p===1?1:2,g=h+f.toString(),b=s[g];return{axis:h,axisOrigin:g,axisDir:p,lineBox:s,lineSize:l,lineStart:b}},r.prototype.lineDir=function(){var i=this.options,o=i.reverse;return o?-1:1},r.prototype.getSlot=function(i,o,a){var s=this.options,l=s.reverse,h=s.justified,p=this.scaleOptions(),f=p.scale,g=p.box,b=p.min,z=this.lineInfo(),M=z.axis,I=z.lineStart,F=g.clone(),H=!ie(o),E=t1(i,0),R=t1(o,E);R=Math.max(R-1,E),R=Math.max(E,R);var W=I+(E-b)*f,$=I+(R+1-b)*f;return H&&h&&($=W),a&&(W=Xe(W,g[M+1],g[M+2]),$=Xe($,g[M+1],g[M+2])),F[M+1]=l?$:W,F[M+2]=l?W:$,F},r.prototype.limitSlot=function(i){var o=this.options.vertical,a=o?We:Ne,s=this.lineBox(),l=i.clone();return l[a+1]=Xe(i[a+1],s[a+1],s[a+2]),l[a+2]=Xe(i[a+2],s[a+1],s[a+2]),l},r.prototype.slot=function(i,o,a){var s=Math.floor(this.options.min||0),l=i,h=o;return typeof l=="string"?l=this.categoryIndex(l):b1(l)&&(l-=s),typeof h=="string"?h=this.categoryIndex(h):b1(h)&&(h-=s),t.prototype.slot.call(this,l,h,a)},r.prototype.pointCategoryIndex=function(i){var o=this.options,a=o.reverse,s=o.justified,l=o.vertical,h=l?We:Ne,p=this.scaleOptions(),f=p.scale,g=p.box,b=p.min,z=p.max,M=a?z:b,I=g[h+1],F=g[h+2],H=i[h];if(HF)return null;var E=M+(H-I)/f,R=E%1;return s?E=Math.round(E):R===0&&E>0&&E--,Math.floor(E)},r.prototype.getCategory=function(i){var o=this.pointCategoryIndex(i);return o===null?null:this.options.categories[o]},r.prototype.categoryIndex=function(i){return this.totalIndex(i)-Math.floor(this.options.min||0)},r.prototype.categoryAt=function(i,o){var a=this.options;return(o?a.srcCategories:a.categories)[i]},r.prototype.categoriesCount=function(){return(this.options.categories||[]).length},r.prototype.translateRange=function(i){var o=this.options,a=this.lineBox(),s=o.vertical?a.height():a.width(),l=o.categories.length,h=s/l,p=Ae(i/h,X1);return{min:p,max:l+p}},r.prototype.scaleRange=function(i,o){var a=Math.abs(this.pointOffset(o)),s=this.limitedRangeIndices(),l=s.max-s.min,h=this.scaleToDelta(i,l),p=a*h,f=(1-a)*h,g=s.min+p,b=s.max-f;return b-ga.skip?f=a.skip+a.step*Math.ceil((l-a.skip)/a.step):f=a.skip,{min:f-p,max:(i.categories.length?h+(o?1:0):0)-p}},r.prototype.createAxisLabel=function(i,o,a){var s=this.options,l=s.dataItems?s.dataItems[i]:null,h=t1(s.categories[i],"");a.dataItem=l;var p=this.axisLabelText(h,o,a);return new h4(h,p,i,l,o)},r.prototype.shouldRenderNote=function(i){var o=this.limitedRangeIndices();return Math.floor(o.min)<=i&&i<=Math.ceil(o.max)},r.prototype.noteSlot=function(i){var o=this.options,a=i-Math.floor(o.min||0);return this.getSlot(a)},r.prototype.arrangeNotes=function(){t.prototype.arrangeNotes.call(this),this.hideOutOfRangeNotes()},r.prototype.hideOutOfRangeNotes=function(){var i=this,o=i.notes,a=i.box;if(o&&o.length)for(var s=this.options.vertical?We:Ne,l=a[s+1],h=a[s+2],p=0;p=$_t)return{min:E,max:R}},r.prototype.valueRange=function(){return this.range()},r.prototype.totalIndex=function(i){var o=this.options,a=this._categoriesMap?this._categoriesMap.get(i):W_t(i,o.srcCategories);return a},r.prototype.currentRangeIndices=function(){var i=this.options,o=0;b1(i.min)&&(o=Math.floor(i.min));var a;return b1(i.max)?a=i.justified?Math.floor(i.max):Math.ceil(i.max)-1:a=this.totalCount()-1,{min:o,max:a}},r.prototype.limitedRangeIndices=function(i){var o=this.options,a=b1(o.min)?o.min:0,s;if(b1(o.max)?s=o.max:b1(o.min)?s=a+o.categories.length:s=this.totalRange().max||1,i){var l=this.totalRange();a=Xe(a,0,l.max),s=Xe(s,0,l.max)}return{min:a,max:s}},r.prototype.totalRangeIndices=function(){return{min:0,max:this.totalRange().max||1}},r.prototype.indexCategories=function(){if(!this._categoriesMap)for(var i=this._categoriesMap=new $b,o=this.options.srcCategories,a=0;a=s;){b=b||a[p].slice(0);do M=b.shift();while(M&&r===p&&Ms&&(z=Math.ceil(g/s));break}}t.baseUnitStep=z,t.baseUnit=p}function G_t(t){for(var r=t.categories,n=ie(r)?r.length:0,i=Rr,o,a,s=0;s=tw?a=qa:i>=Qb-Za*3?a=A0:i>=Jb?a=G8:i>=Za?a=Jo:i>=Lp?a=j8:i>=Zl?a=qb:a=Kb)}o=l}t.baseUnit=a||Jo}function U_t(t){var r=(t.baseUnit||"").toLowerCase(),n=r!==o9&&!u1(r,Da);return n&&G_t(t),(r===o9||t.baseUnitStep===j_t)&&AV(t),t}var U8=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.clone=function(){var i=new r(Object.assign({},this.options),this.chartService);return i.createLabels(),i},r.prototype.categoriesHash=function(){var i=this.dataRange.total().min;return this.options.baseUnit+this.options.baseUnitStep+i},r.prototype.initUserOptions=function(i){return i},r.prototype.initFields=function(){t.prototype.initFields.call(this);var i=this.chartService,o=i.intl,a=this.options,s=a.categories||[];if(s._parsed||(s=zV(o,s),s._parsed=!0),a=St({roundToBaseUnit:!0},a,{categories:s,min:Si(o,a.min),max:Si(o,a.max),weekStartDay:MV(a,o)}),i.panning&&i.isPannable(a.vertical?We:Ne)&&(a.roundToBaseUnit=!1),a.userSetBaseUnit=a.userSetBaseUnit||a.baseUnit,a.userSetBaseUnitStep=a.userSetBaseUnitStep||a.baseUnitStep,this.options=a,a.srcCategories=s,s.length>0){var l=k7(s,!0),h=a.maxDivisions,p=U_t(a),f=a._forecast;if(f&&(f.before>0&&(l.min=Pi(l.min,-f.before,p.baseUnit,p.weekStartDay)),f.after>0&&(l.max=Pi(l.max,f.after,p.baseUnit,p.weekStartDay))),this.dataRange=new mn(l.min,l.max,p),h){var g=this.dataRange.displayRange(),b=Object.assign({},a,{justified:!0,roundToBaseUnit:!1,baseUnit:"fit",min:g.min,max:g.max,maxDateGroups:h}),z=this.dataRange.options;AV(b,z.baseUnit,z.baseUnitStep),this.divisionRange=new mn(l.min,l.max,b)}else this.divisionRange=this.dataRange}else a.baseUnit=a.baseUnit||Jo,this.dataRange=this.divisionRange=new Mo(a);this.rangeLabels=[]},r.prototype.tickIndices=function(i){var o=this,a=o.dataRange,s=o.divisionRange,l=s.valuesCount();if(!this.options.maxDivisions||!l)return t.prototype.tickIndices.call(this,i);var h=[],p=s.values(),f=0;this.options.justified||(p=p.concat(s.dateAt(l)),f=.5);for(var g=0;g=1){var b=h.length-1;h.splice(g,0,h[b-1]+(h[b]-h[b-1])*i)}return h},r.prototype.shouldRenderNote=function(i){var o=this.range(),a=this.options.categories||[];return i9(i,o.min)>=0&&i9(i,o.max)<=0&&a.length},r.prototype.parseNoteValue=function(i){return Si(this.chartService.intl,i)},r.prototype.noteSlot=function(i){return this.getSlot(i)},r.prototype.translateRange=function(i){var o=this.options,a=o.baseUnit,s=o.weekStartDay,l=o.vertical,h=this.lineBox(),p=l?h.height():h.width(),f=this.range(),g=p/(f.max-f.min),b=Ae(i/g,X1);if(f.min&&f.max){var z=hi(o.min||f.min,b),M=hi(o.max||f.max,b);f={min:Pi(z,0,a,s),max:Pi(M,0,a,s)}}return f},r.prototype.labelsRange=function(){return{min:this.options.labels.skip,max:this.divisionRange.valuesCount()}},r.prototype.pan=function(i){if(this.isEmpty())return null;var o=this.options,a=this.lineBox(),s=o.vertical?a.height():a.width(),l=this.dataRange.displayRange(),h=l.min,p=l.max,f=this.dataRange.total(),g=s/(p-h),b=Ae(i/g,X1)*(o.reverse?-1:1),z=hi(h,b),M=hi(p,b),I=this.limitRange(tr(z),tr(M),tr(f.min),tr(f.max),b);if(I)return I.min=Q1(I.min),I.max=Q1(I.max),I.baseUnit=o.baseUnit,I.baseUnitStep=o.baseUnitStep||1,I.userSetBaseUnit=o.userSetBaseUnit,I.userSetBaseUnitStep=o.userSetBaseUnitStep,I},r.prototype.pointsRange=function(i,o){if(this.isEmpty())return null;var a=t.prototype.pointsRange.call(this,i,o),s=this.dataRange.displayRange(),l=this.dataRange.displayIndices(),h=$o(s.max,s.min)/(l.max-l.min),p=this.options,f=hi(s.min,a.min*h),g=hi(s.min,a.max*h);return{min:f,max:g,baseUnit:p.userSetBaseUnit||p.baseUnit,baseUnitStep:p.userSetBaseUnitStep||p.baseUnitStep}},r.prototype.scaleRange=function(i,o){if(this.isEmpty())return{};var a=this.options,s=a.userSetBaseUnit===o9,l=this.dataRange.total(),h=this.dataRange.displayRange(),p=h.min,f=h.max,g=Math.abs(this.pointOffset(o)),b=f-p,z=this.scaleToDelta(i,b),M=Math.round(g*z),I=Math.round((1-g)*z),F=this.dataRange.options,H=F.baseUnit,E=new Date(p.getTime()+M),R=new Date(f.getTime()-I);if(s){var W=a.autoBaseUnitSteps,$=a.maxDateGroups,G=Vr(W[H])*$*No[H],Z=$o(f,p),K=$o(R,E),et=Da.indexOf(H),at,tt;if(KG&&H!==qa){var ft=0;do{et++,H=Da[et],ft=0,tt=2*No[H];do at=W[H][ft],ft++;while(ft0&&(E=hi(p,-tt),R=hi(f,tt),E=hi(E,Xe(R,l.min,l.max)-R),R=hi(R,Xe(E,l.min,l.max)-E))}}if(E&&R&&$o(R,E)>0)return{min:E,max:R,baseUnit:a.userSetBaseUnit||a.baseUnit,baseUnitStep:a.userSetBaseUnitStep||a.baseUnitStep}},r.prototype.zoomRange=function(i,o){var a=this.dataRange.total(),s=this.scaleRange(i,o);return s&&(s.mina.max&&(s.max=a.max)),s},r.prototype.range=function(){return this.dataRange.displayRange()},r.prototype.createLabels=function(){t.prototype.createLabels.call(this),this.createRangeLabels()},r.prototype.clearLabels=function(){t.prototype.clearLabels.call(this),this.rangeLabels=[]},r.prototype.arrangeLabels=function(){this.arrangeRangeLabels(),t.prototype.arrangeLabels.call(this)},r.prototype.arrangeRangeLabels=function(){var i=this,o=i.options,a=i.rangeLabels;if(a.length!==0){var s=this.lineBox(),l=o.vertical,h=o.rangeLabels.mirror||o.labels.mirror,p=a[0];if(p){var f=l?s.y1-p.box.height()/2:s.x1;this.positionLabel(p,h,f)}var g=a[1];if(g){var b=l?s.y2-g.box.height()/2:s.x2;this.positionLabel(g,h,b)}}},r.prototype.autoRotateLabels=function(){t.prototype.autoRotateLabels.call(this),this.autoRotateRangeLabels()},r.prototype.hideOutOfRangeLabels=function(){t.prototype.hideOutOfRangeLabels.call(this),this.hideOverlappingLabels()},r.prototype.hideOverlappingLabels=function(){var i=this,o=i.rangeLabels,a=i.labels;if(o.length===0)return;function s(z,M){return!M.options.visible||M.box.overlaps(z.box)?(M.options.visible=!1,!0):!1}var l=o[0];if(l&&l.options.visible)for(var h=0;h0;--g){var b=s(f,a[g]);if(!b)break}},r.prototype.contentBox=function(){for(var i=t.prototype.contentBox.call(this),o=this.rangeLabels,a=0;a=0&&r>=0){var o=t===r?0:t,a=(r-o)/r;if(n===!1||!n&&a>_V)return 0;i=Math.max(0,o-(r-o)/2)}else i=t;return i}function X_t(t,r,n){if(!t&&!r)return 1;var i;if(t<=0&&r<=0){var o=t===r?0:r,a=Math.abs((o-t)/o);if(n===!1||!n&&a>_V)return 0;i=Math.min(0,o-(t-o)/2)}else i=r;return i}function LV(t,r){return Ae(Math.floor(t/r)*r,X1)}function a9(t,r){return Ae(Math.ceil(t/r)*r,X1)}function s9(t){return Math.max(Math.min(t,cA),-cA)}var vv=Math.pow(10,-X1+1),O2=function(t){function r(n,i,o,a){t.call(this,Object.assign({},o,{seriesMin:n,seriesMax:i}),a)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.initUserOptions=function(i){var o=K_t(i.seriesMin,i.seriesMax,i);return this.totalOptions=q_t(o,i),J_t(o,i)},r.prototype.initFields=function(){this.totalMin=this.totalOptions.min,this.totalMax=this.totalOptions.max,this.totalMajorUnit=this.totalOptions.majorUnit,this.seriesMin=this.options.seriesMin,this.seriesMax=this.options.seriesMax},r.prototype.clone=function(){return new r(this.seriesMin,this.seriesMax,Object.assign({},this.options),this.chartService)},r.prototype.startValue=function(){return 0},r.prototype.range=function(){var i=this.options;return{min:i.min,max:i.max}},r.prototype.getDivisions=function(i){if(i===0)return 1;var o=this.options,a=o.max-o.min;return Math.floor(Ae(a/i,di))+1},r.prototype.getTickPositions=function(i,o){var a=this.options,s=this.lineInfo(),l=s.axisDir,h=s.axisOrigin,p=s.lineBox,f=s.lineSize,g=a.max-a.min,b=f/g,z=i*b,M=this.getDivisions(i),I=[],F=p[h],H=0;o&&(H=o/i);for(var E=0;E0?F:H)),E[h+2]=s9(b+z*(p>0?H:F)),E},r.prototype.getValue=function(i){var o=this.options,a=Number(o.max),s=Number(o.min),l=this.pointOffset(i),h=l*(a-s);if(l<0||l>1)return null;var p=s+h;return Ae(p,X1)},r.prototype.translateRange=function(i){var o=this.options,a=o.vertical,s=o.reverse,l=o.max,h=o.min,p=this.lineInfo(),f=p.lineSize,g=l-h,b=f/g,z=Ae(i/b,X1);return(a||s)&&!(a&&s)&&(z=-z),{min:h+z,max:l+z,offset:z}},r.prototype.labelsCount=function(){return this.getDivisions(this.options.majorUnit)},r.prototype.createAxisLabel=function(i,o,a){var s=this.options,l=Ae(s.min+i*s.majorUnit,X1),h=this.axisLabelText(l,o,a);return new h4(l,h,i,null,o)},r.prototype.shouldRenderNote=function(i){var o=this.range();return o.min<=i&&i<=o.max},r.prototype.pan=function(i){var o=this.translateRange(i);return this.limitRange(o.min,o.max,this.totalMin,this.totalMax,o.offset)},r.prototype.pointsRange=function(i,o){var a=this.getValue(i),s=this.getValue(o),l=Math.min(a,s),h=Math.max(a,s);if(this.isValidRange(l,h))return{min:l,max:h}},r.prototype.scaleRange=function(i,o){var a=Math.abs(this.pointOffset(o)),s=this.options.max-this.options.min,l=this.scaleToDelta(i,s),h=a*l,p=(1-a)*l,f=Ae(this.options.min+h,X1),g=Ae(this.options.max-p,X1);return g-fvv},r}(ql);function K_t(t,r,n){var i=n.narrowRange,o=Y_t(t,r,i),a=X_t(t,r,i),s=Xl(o,a),l={majorUnit:s};return n.roundToMajorUnit!==!1&&(o<0&&hA(o,s,1/3)&&(o-=s),a>0&&hA(a,s,1/3)&&(a+=s)),l.min=LV(o,s),l.max=a9(a,s),l}function q_t(t,r){return{min:ie(r.min)?Math.min(t.min,r.min):t.min,max:ie(r.max)?Math.max(t.max,r.max):t.max,majorUnit:t.majorUnit}}function Z_t(t,r){for(var n=0;n0?r.min=0:r.max=1),r.majorUnit?(t.min=LV(t.min,r.majorUnit),t.max=a9(t.max,r.majorUnit)):a&&(n=St(t,r),t.majorUnit=Xl(n.min,n.max))}t.minorUnit=(n.majorUnit||t.majorUnit)/5;var s=St(t,n);return s.min>=s.max&&(i&&!o?s.max=s.min+s.majorUnit:!i&&o&&(s.min=s.max-s.majorUnit)),s}function hA(t,r,n){var i=Ae(Math.abs(t%r),X1),o=r*(1-n);return i===0||i>o}de(O2,{type:"numeric",min:0,max:1,vertical:!0,majorGridLines:{visible:!0,width:1,color:Ar},labels:{format:"#.####################"},zIndex:1});var uA=1e3,EV=function(t){function r(n,i,o,a){var s=Q1(n),l=Q1(i),h=a.intl,p=o||{};p=St(p||{},{min:Si(h,p.min),max:Si(h,p.max),axisCrossingValue:zV(h,p.axisCrossingValues||p.axisCrossingValue),weekStartDay:MV(p,h)}),p=tAt(s,l,p),t.call(this,p,a),this.intlService=h,this.seriesMin=s,this.seriesMax=l;var f=p.weekStartDay||0;this.totalMin=tr(rw(tr(s)-1,p.baseUnit,f)),this.totalMax=tr(SV(tr(l)+1,p.baseUnit,f))}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.clone=function(){return new r(this.seriesMin,this.seriesMax,Object.assign({},this.options),this.chartService)},r.prototype.range=function(){var i=this.options;return{min:i.min,max:i.max}},r.prototype.getDivisions=function(i){var o=this.options;return Math.floor(iw(o.min,o.max,o.baseUnit)/i+1)},r.prototype.getTickPositions=function(i){for(var o=this.options,a=this.lineInfo(),s=a.axisDir,l=a.lineSize,h=a.lineStart,p=this.getDivisions(i),f=$o(o.max,o.min),g=l/f,b=o.weekStartDay||0,z=[h],M=1;M0&&(p=Pi(p,l,s.baseUnit,h));var f=o.dateFormats[s.baseUnit];o.format=o.format||f;var g=this.axisLabelText(p,o,a);return new h4(p,g,i,null,o)},r.prototype.translateRange=function(i){var o=this.options,a=this.lineBox(),s=o.vertical,l=o.reverse,h=s?a.height():a.width(),p=this.range(),f=h/$o(p.max,p.min),g=Ae(i/f,X1);(s||l)&&!(s&&l)&&(g=-g);var b=hi(o.min,g),z=hi(o.max,g);return{min:b,max:z,offset:g}},r.prototype.shouldRenderNote=function(i){var o=this.range();return i9(i,o.min)>=0&&i9(i,o.max)<=0},r.prototype.pan=function(i){var o=this.translateRange(i,!0),a=this.limitRange(tr(o.min),tr(o.max),this.totalMin,this.totalMax,o.offset);if(a)return{min:Q1(a.min),max:Q1(a.max)}},r.prototype.pointsRange=function(i,o){var a=this.getValue(i),s=this.getValue(o),l=Math.min(a,s),h=Math.max(a,s);return{min:Q1(l),max:Q1(h)}},r.prototype.scaleRange=function(i,o){var a=Math.abs(this.pointOffset(o)),s=this.options.max-this.options.min,l=this.scaleToDelta(i,s),h=a*l,p=(1-a)*l,f=Q1(tr(this.options.min)+h),g=Q1(tr(this.options.max)-p);return g-f=tw?r=qa:t>=Qb?r=A0:t>=Jb?r=G8:t>=Za&&(r=Jo),r}function tAt(t,r,n){var i=n.min||t,o=n.max||r,a=n.baseUnit||(o&&i?Q_t(ew(o,i)):j8),s=No[a],l=n.weekStartDay||0,h=rw(tr(i)-1,a,l)||Q1(o),p=SV(tr(o)+1,a,l),f=n.majorUnit?n.majorUnit:void 0,g=f||a9(Xl(h.getTime(),p.getTime()),s)/s,b=iw(h,p,a),z=a9(b,g),M=z-b,I=Math.floor(M/2),F=M-I;return n.baseUnit||delete n.baseUnit,n.baseUnit=n.baseUnit||a,n.min=n.min||Pi(h,-I,a,l),n.max=n.max||Pi(p,F,a,l),n.minorUnit=n.minorUnit||g/5,n.majorUnit=g,n}de(EV,{type:Na,majorGridLines:{visible:!0,width:1,color:Ar},labels:{dateFormats:kV}});var IV=10,pA=1e-6,Ep=function(t){function r(n,i,o,a){var s=St({majorUnit:IV,min:n,max:i},o),l=s.majorUnit,h=iAt(i,l),p=rAt(n,i,s),f=eAt(p,h,s,o);s.max=f.max,s.min=f.min,s.minorUnit=o.minorUnit||Ae(l-1,X1),t.call(this,s,a),this.totalMin=ie(o.min)?Math.min(p,o.min):p,this.totalMax=ie(o.max)?Math.max(h,o.max):h,this.logMin=Ae(so(f.min,l),X1),this.logMax=Ae(so(f.max,l),X1),this.seriesMin=n,this.seriesMax=i,this.createLabels()}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.clone=function(){return new r(this.seriesMin,this.seriesMax,Object.assign({},this.options),this.chartService)},r.prototype.startValue=function(){return this.options.min},r.prototype.getSlot=function(i,o,a){var s=this,l=s.options,h=s.logMin,p=s.logMax,f=l.majorUnit,g=l.min,b=l.max,z=this.lineInfo(),M=z.axis,I=z.axisDir,F=z.lineBox,H=z.lineSize,E=z.lineStart,R=I*(H/(p-h)),W=t1(i,o||1),$=t1(o,i||1);if(W<=0||$<=0)return null;a&&(W=Xe(W,g,b),$=Xe($,g,b)),W=so(W,f),$=so($,f);var G=Math.min(W,$)-h,Z=Math.max(W,$)-h,K=new Ce(F.x1,F.y1,F.x1,F.y1);return K[M+1]=s9(E+R*(I>0?G:Z)),K[M+2]=s9(E+R*(I>0?Z:G)),K},r.prototype.getValue=function(i){var o=this,a=o.options,s=o.logMin,l=o.logMax,h=a.majorUnit,p=this.lineInfo(),f=p.axis,g=p.axisDir,b=p.lineStart,z=p.lineSize,M=(l-s)/z,I=g*(i[f]-b),F=I*M;if(I<0||I>z)return null;var H=s+F;return Ae(Math.pow(h,H),X1)},r.prototype.range=function(){var i=this.options;return{min:i.min,max:i.max}},r.prototype.translateRange=function(i){var o=this,a=o.options,s=o.logMin,l=o.logMax,h=a.reverse,p=a.vertical,f=a.majorUnit,g=this.lineBox(),b=p?g.height():g.width(),z=b/(l-s),M=Ae(i/z,X1);return(p||h)&&!(p&&h)&&(M=-M),{min:Math.pow(f,s+M),max:Math.pow(f,l+M),offset:M}},r.prototype.labelsCount=function(){var i=Math.floor(this.logMax),o=Math.floor(i-this.logMin)+1;return o},r.prototype.getMajorTickPositions=function(){var i=[];return this.traverseMajorTicksPositions(function(o){i.push(o)},{step:1,skip:0}),i},r.prototype.createTicks=function(i){var o=this.options,a=o.majorTicks,s=o.minorTicks,l=o.vertical,h=o.labels.mirror,p=this.lineBox(),f=[],g={vertical:l};function b(z,M){g.tickX=h?p.x2:p.x2-M.size,g.tickY=h?p.y1-M.size:p.y1,g.position=z,i.append(wV(g,M))}return a.visible&&this.traverseMajorTicksPositions(b,a),s.visible&&this.traverseMinorTicksPositions(b,s),f},r.prototype.createGridLines=function(i){var o=this.options,a=o.minorGridLines,s=o.majorGridLines,l=o.vertical,h=i.lineBox(),p={lineStart:h[l?"x1":"y1"],lineEnd:h[l?"x2":"y2"],vertical:l},f=[],g=this.gridLinesVisual();function b(z,M){u1(z,f)||(p.position=z,g.append(CV(p,M)),f.push(z))}return s.visible&&this.traverseMajorTicksPositions(b,s),a.visible&&this.traverseMinorTicksPositions(b,a),g.children},r.prototype.traverseMajorTicksPositions=function(i,o){for(var a=this.lineInfo(),s=a.lineStart,l=a.step,h=this,p=h.logMin,f=h.logMax,g=Math.ceil(p)+o.skip;g<=f;g+=o.step){var b=Ae(s+l*(g-p),X1);i(b,o)}},r.prototype.traverseMinorTicksPositions=function(i,o){for(var a=this,s=this.options,l=s.min,h=s.max,p=s.minorUnit,f=s.majorUnit,g=this.lineInfo(),b=g.lineStart,z=g.step,M=this,I=M.logMin,F=M.logMax,H=Math.floor(I),E=H;Eh)break;if($>=l){var G=Ae(b+z*(so($,f)-I),X1);i(G,o)}}},r.prototype.createAxisLabel=function(i,o,a){var s=Math.ceil(this.logMin+i),l=Math.pow(this.options.majorUnit,s),h=this.axisLabelText(l,o,a);return new h4(l,h,i,null,o)},r.prototype.shouldRenderNote=function(i){var o=this.range();return o.min<=i&&i<=o.max},r.prototype.pan=function(i){var o=this.translateRange(i);return this.limitRange(o.min,o.max,this.totalMin,this.totalMax,o.offset)},r.prototype.pointsRange=function(i,o){var a=this.getValue(i),s=this.getValue(o),l=Math.min(a,s),h=Math.max(a,s);return{min:l,max:h}},r.prototype.scaleRange=function(i,o){var a=this.options,s=a.majorUnit,l=so(this.options.min,s),h=so(this.options.max,s),p=Math.abs(this.pointOffset(o)),f=h-l,g=this.scaleToDelta(i,f),b=Math.pow(s,l+p*g),z=Math.pow(s,h-(1-p)*g);return z-b.9)?i=Math.pow(r,so(t,r)+.2):i=Math.pow(r,Math.ceil(so(t,r))),i}function gv(){throw new Error("Non positive values cannot be used for a logarithmic axis")}function so(t,r){return Math.log(t)/Math.log(r)}de(Ep,{type:"log",majorUnit:IV,minorUnit:1,axisCrossingValue:1,vertical:!0,majorGridLines:{visible:!0,width:1,color:Ar},zIndex:1,_deferLabels:!0});var HV={createGridLines:function(t){var r=this.options,n=Math.abs(this.box.center().y-t.lineBox().y1),i=[],o=!1,a,s;return r.majorGridLines.visible&&(a=this.majorGridLineAngles(t),o=!0,i=this.renderMajorGridLines(a,n,r.majorGridLines)),r.minorGridLines.visible&&(s=this.minorGridLineAngles(t,o),O0(i,this.renderMinorGridLines(s,n,r.minorGridLines,t,o))),i},renderMajorGridLines:function(t,r,n){return this.renderGridLines(t,r,n)},renderMinorGridLines:function(t,r,n,i,o){var a=this.radiusCallback&&this.radiusCallback(r,i,o);return this.renderGridLines(t,r,n,a)},renderGridLines:function(t,r,n,i){for(var o={stroke:{width:n.width,color:n.color,dashType:n.dashType}},a=this.box.center(),s=new l2([a.x,a.y],r),l=this.gridLinesVisual(),h=0;h0){var f=new l2([t.x,t.y],p);if(i.type===Qs)l.append(new Uo(f,o));else{for(var g=new $e(o),b=0;b1){var l=t.x-o.x,h=t.y-o.y,p=(Ns(Math.atan2(h,l))+540)%360;i.sort(function(M,I){return $h(M,p)-$h(I,p)});var f=$h(i[0],i[1])/2,g=$h(p,i[0]),b=90-f,z=180-g-b;s=a*(Math.sin(Qr(z))/Math.sin(Qr(b)))}return this.axisType().prototype.getValue.call(this,new Qe(r.x1,r.y2-s))}};function $h(t,r){return 180-Math.abs(Math.abs(t-r)-180)}var PV=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.radarMajorGridLinePositions=function(){return this.getTickPositions(this.options.majorUnit)},r.prototype.radarMinorGridLinePositions=function(){var i=this.options,o=0;return i.majorGridLines.visible&&(o=i.majorUnit),this.getTickPositions(i.minorUnit,o)},r.prototype.axisType=function(){return t},r}(O2);St(PV.prototype,DV);var TV=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.radarMajorGridLinePositions=function(){var i=[];return this.traverseMajorTicksPositions(function(o){i.push(o)},this.options.majorGridLines),i},r.prototype.radarMinorGridLinePositions=function(){var i=[];return this.traverseMinorTicksPositions(function(o){i.push(o)},this.options.minorGridLines),i},r.prototype.axisType=function(){return t},r}(Ep);St(TV.prototype,DV);var dA=.333,nAt=.01,Ip=function(t){function r(n){t.call(this),this.closed=n}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.process=function(i){var o=this,a=i.slice(0),s=[],l=this.closed,h=a.length;if(h>2&&(this.removeDuplicates(0,a),h=a.length),h<2||h===2&&a[0].equals(a[1]))return s;var p=a[0],f=a[1],g=a[2];for(s.push(new Di(p));p.equals(a[h-1]);)l=!0,a.pop(),h--;if(h===2){var b=this.tangent(p,f,Ne,We);return Vr(s).controlOut(this.firstControlPoint(b,p,f,Ne,We)),s.push(new Di(f,this.secondControlPoint(b,p,f,Ne,We))),s}var z,M;if(l){p=a[h-1],f=a[0],g=a[1];var I=this.controlPoints(p,f,g);z=I[1],M=I[0]}else{var F=this.tangent(p,f,Ne,We);z=this.firstControlPoint(F,p,f,Ne,We)}for(var H=z,E=0;E<=h-3;E++)if(o.removeDuplicates(E,a),h=a.length,E+3<=h){p=a[E],f=a[E+1],g=a[E+2];var R=o.controlPoints(p,f,g);Vr(s).controlOut(H),H=R[1];var W=R[0];s.push(new Di(f,W))}if(l){p=a[h-2],f=a[h-1],g=a[0];var $=this.controlPoints(p,f,g);Vr(s).controlOut(H),s.push(new Di(f,$[0])),Vr(s).controlOut($[1]),s.push(new Di(g,M))}else{var G=this.tangent(f,g,Ne,We);Vr(s).controlOut(H),s.push(new Di(g,this.secondControlPoint(G,f,g,Ne,We)))}return s},r.prototype.removeDuplicates=function(i,o){for(;o[i+1]&&(o[i].equals(o[i+1])||o[i+1].equals(o[i+2]));)o.splice(i+1,1)},r.prototype.invertAxis=function(i,o,a){var s=!1;if(i.x===o.x)s=!0;else if(o.x===a.x)(o.y=h)&&(s=!0)}return s},r.prototype.isLine=function(i,o,a){var s=this.lineFunction(i,o),l=this.calculateFunction(s,a.x);return i.x===o.x&&o.x===a.x||Ae(l,1)===Ae(a.y,1)},r.prototype.lineFunction=function(i,o){var a=(o.y-i.y)/(o.x-i.x),s=i.y-a*i.x;return[s,a]},r.prototype.controlPoints=function(i,o,a){var s=Ne,l=We,h=!1,p=!1,f;if(this.isLine(i,o,a))f=this.tangent(i,o,Ne,We);else{var g={x:this.isMonotonicByField(i,o,a,Ne),y:this.isMonotonicByField(i,o,a,We)};if(g.x&&g.y)f=this.tangent(i,a,Ne,We),h=!0;else if(this.invertAxis(i,o,a)&&(s=We,l=Ne),g[s])f=0;else{var b;a[l]o[s]&&o[s]>i[s]||a[s]0&&(n=Cm.sum(t)/r),n},first:function(t){for(var r=t.length,n=0;n=0){this.valueGetter=this.createValueGetter(o,a);var b=this.getStandardError(s,this.getAverage(s));this.globalRange=function(z){return{low:z-b,high:z+b}}}},r.prototype.createValueGetter=function(i,o){var a=i.data,s=q1.current,l=s.valueFields(i),h=ie(a[0])?a[0]:{},p;if(Mi(h)){var f=o?l.indexOf(o):0;p=t4("["+f+"]")}else if(b1(h))p=t4();else if(typeof h===l8){var g=s.sourceFields(i,l);p=t4(g[l.indexOf(o)])}return p},r.prototype.getErrorRange=function(i,o){var a,s,l;if(!ie(o))return null;if(this.globalRange)return this.globalRange(i);if(Mi(o))a=i-o[0],s=i+o[1];else if(b1(l=parseFloat(o)))a=i-l,s=i+l;else if(l=hAt.exec(o)){var h=i*(parseFloat(l[1])/100);a=i-Math.abs(h),s=i+Math.abs(h)}else throw new Error("Invalid ErrorBar value: "+o);return{low:a,high:s}},r.prototype.getStandardError=function(i,o){return this.getStandardDeviation(i,o,!0)/Math.sqrt(o.count)},r.prototype.getStandardDeviation=function(i,o,a){for(var s=this,l=i.length,h=a?o.count-1:o.count,p=0,f=0;fEAt)return null;for(var l in t)if(!u1(l,n.excluded)&&jb(t,l)){var h=t[l];yr(h)?(s=!0,i||(t[l]=t1(h(r),o[l]))):U2(h)&&(i||(n.defaults=o[l]),n.depth++,s=es(h,r,n,i)||s,n.depth--)}return s}function Cr(t,r){for(var n=[],i=[].concat(r),o=0;o0&&a0)return i.value/l}return i.value},r.prototype.plotRange=function(i,o){var a=this;o===void 0&&(o=0);var s=this.categoryPoints[i.categoryIx];if(this.options.isStacked){var l=this.plotValue(i),h=l>=0,p=o,f=!1,g=ie(i.series.stack)?i.series.stack:this.options.defaultStack,b=function(W){return W===!0||typeof W===l8&&!W.group};if(g)for(var z=0;z=0&&h||F<0&&!h)&&(o===0||F!==0)&&(p+=F,l+=F,f=!0,a.options.isStacked100&&(l=Math.min(l,1)))}}return f&&(p-=o),[p,l]}var H=i.series,E=this.seriesValueAxis(H),R=this.categoryAxisCrossingValue(E);return[R,QT(i.value)?i.value:R]},r.prototype.stackLimits=function(i,o){for(var a=this,s=Rr,l=ti,h=0;h0&&(this.errorTotals.positive[o]=Math.max(this.errorTotals.positive[o]||0,l)),{low:s,high:l}},r.prototype.addValue=function(i,o){var a=o.categoryIx,s=o.series,l=o.seriesIx,h=this.categoryPoints[a];h||(this.categoryPoints[a]=h=[]);var p=this.seriesPoints[l];p||(this.seriesPoints[l]=p=[]);var f=this.createPoint(i,o);f&&(Object.assign(f,o),f.owner=this,f.noteText=i.fields.noteText,ie(f.dataItem)||(f.dataItem=s.data[a]),this.addErrorBar(f,i,a)),this.points.push(f),p.push(f),h.push(f),this.updateRange(i.valueFields,o)},r.prototype.evalPointOptions=function(i,o,a){var s=a.categoryIx,l=a.category,h=a.series,p=a.seriesIx,f={defaults:h._defaults,excluded:["data","aggregate","_events","tooltip","content","template","visual","toggle","_outOfRangeMinPoint","_outOfRangeMaxPoint","drilldownSeriesFactory","ariaTemplate","ariaContent"]},g=this._evalSeries[p];ie(g)||(this._evalSeries[p]=g=es(i,{},f,!0));var b=i;return g&&(b=St({},b),es(b,{value:o,category:l,index:s,series:h,dataItem:h.data[s]},f)),b},r.prototype.updateRange=function(i,o){var a=o.series.axis,s=i.value,l=this.valueAxisRanges[a];isFinite(s)&&s!==null&&(l=this.valueAxisRanges[a]=l||{min:Rr,max:ti},l.min=Math.min(l.min,s),l.max=Math.max(l.max,s))},r.prototype.seriesValueAxis=function(i){var o=this.plotArea,a=i.axis,s=a?o.namedValueAxes[a]:o.valueAxis;if(!s)throw new Error("Unable to locate value axis with name "+a);return s},r.prototype.reflow=function(i){var o=this,a=this.categorySlots=[],s=this.points,l=this.categoryAxis,h=0;this.traverseDataPoints(function(p,f){var g=f.categoryIx,b=f.series,z=o.seriesValueAxis(b),M=s[h++],I=a[g];if(I||(a[g]=I=o.categorySlot(l,g,z)),M){var F=o.plotRange(M,z.startValue()),H=o.valueSlot(z,F);if(H){var E=o.pointSlot(I,H);M.aboveAxis=o.aboveAxis(M,z),M.stackValue=F[1],o.options.isStacked100&&(M.percentage=o.plotValue(M)),o.reflowPoint(M,E)}else M.visible=!1}}),this.reflowCategories(a),!this.options.clip&&this.options.limitPoints&&this.points.length&&this.limitPoints(),this.box=i},r.prototype.valueSlot=function(i,o){return i.getSlot(o[0],o[1],!this.options.clip)},r.prototype.limitPoints=function(){for(var i=this,o=this.categoryPoints,a=o[0].concat(Vr(o)),s=0;s=a},r.prototype.categoryAxisCrossingValue=function(i){var o=this.categoryAxis,a=i.options,s=[].concat(a.axisCrossingValues||a.axisCrossingValue);return s[o.axisIndex||0]||0},r.prototype.reflowPoint=function(i,o){i.reflow(o)},r.prototype.reflowCategories=function(){},r.prototype.pointSlot=function(i,o){var a=this.options,s=a.invertAxes,l=s?o:i,h=s?i:o;return new Ce(l.x1,h.y1,l.x2,h.y2)},r.prototype.categorySlot=function(i,o){return i.getSlot(o)},r.prototype.traverseDataPoints=function(i){for(var o=this,a=this.options.series,s=yw(a),l=a.length,h=0;h1&&(s=t.createSegment(g,h,l,s),t._addSegment(s)),g=[])}g.length>1&&(s=t.createSegment(g,h,l,s),t._addSegment(s))}this.children.unshift.apply(this.children,this._segments)},_addSegment:function(t){this._segments.push(t),t.parent=this},sortPoints:function(t){return t},seriesMissingValues:function(t){var r=t.missingValues,n=!r&&this.options.isStacked;return n?Ja:r||zl},getNearestPoint:function(t,r,n){for(var i=new Qe(t,r),o=this.seriesPoints[n],a=Rr,s,l=0;l0&&a.visible!==!1&&this.createStroke({stroke:St({color:s,opacity:i.opacity,lineCap:"butt"},a)})},r.prototype.strokeSegments=function(){var i=this._strokeSegments;return i||(i=this._strokeSegments=this.createStrokeSegments()),i},r.prototype.createStrokeSegments=function(){return this.segmentsFromPoints(this.points())},r.prototype.stackSegments=function(){return this.prevSegment?this.prevSegment.createStackSegments(this.stackPoints):this.createStackSegments(this.stackPoints)},r.prototype.createStackSegments=function(i){return this.segmentsFromPoints(this.toGeometryPoints(i)).reverse()},r.prototype.segmentsFromPoints=function(i){return i.map(function(o){return new Di(o)})},r.prototype.createStroke=function(i){var o=new $e(i);o.segments.push.apply(o.segments,this.strokeSegments()),this.visual.append(o)},r.prototype.hasStackSegment=function(){return this.prevSegment||this.stackPoints&&this.stackPoints.length},r.prototype.createFill=function(i){var o=this.strokeSegments(),a=o.slice(0),s=this.hasStackSegment();if(s){var l=this.stackSegments();O0(a,l)}var h=new $e(i);h.segments.push.apply(h.segments,a),!s&&o.length>1&&this.fillToAxes(h),this.visual.append(h)},r.prototype.fillToAxes=function(i){var o=this.parent,a=o.options.invertAxes,s=o.seriesValueAxis(this.series),l=o.categoryAxisCrossingValue(s),h=s.getSlot(l,l,!0),p=this.strokeSegments(),f=p[0].anchor(),g=Vr(p).anchor(),b=a?h.x1:h.y1;a?i.lineTo(b,g.y).lineTo(b,f.y):i.lineTo(g.x,b).lineTo(f.x,b)},r}($0),eF=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.createStrokeSegments=function(){return this.segmentsFromPoints(this.calculateStepPoints(this.linePoints))},r.prototype.createStackSegments=function(i){return this.segmentsFromPoints(this.calculateStepPoints(i)).reverse()},r}(n6);St(eF.prototype,bw);var zw=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.createStrokeSegments=function(){var i=new Ip(this.options.closed),o=this.points();return i.process(o)},r.prototype.createStackSegments=function(){for(var i=this.strokeSegments(),o=[],a=i.length-1;a>=0;a--){var s=i[a];o.push(new Di(s.anchor(),s.controlOut(),s.controlIn()))}return o},r}(n6),DAt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.createSegment=function(i,o,a,s){var l=this.options.isStacked,h=(o.line||{}).style,p,f;if(l&&a>0&&s){var g=this.seriesMissingValues(o);g!=="gap"?(f=s.linePoints,p=s):f=this._gapStackPoints(i,a,h)}var b;return h===Pc?b=eF:h===Jl?b=zw:b=n6,new b(i,o,a,p,f)},r.prototype.reflow=function(i){var o=this;t.prototype.reflow.call(this,i);var a=this._stackPoints;if(a)for(var s=0;s0&&!F);if(F)a!==Pc&&z>h&&!l[I][M-1]&&b.push(s._previousSegmentPoint(z,M,M-1,I)),b.push(F),a!==Pc&&z+10&&!p;)h--,p=l[h][a];return p?p=l[h][o]:(p=this._createGapStackPoint(i),this._stackPoints.push(p)),p},r.prototype._createGapStackPoint=function(i){var o=this.pointOptions({},0),a=new ta(0,o);return a.categoryIx=i,a.series={},a},r.prototype.seriesMissingValues=function(i){return i.missingValues||Ja},r.prototype.supportsPointInactiveOpacity=function(){return!1},r}(Tp),g9=function(t){function r(){t.call(this),this.axisRanges={}}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.update=function(i){var o=this.axisRanges;for(var a in i){var s=i[a],l=o[a];o[a]=l=l||{min:Rr,max:ti},l.min=Math.min(l.min,s.min),l.max=Math.max(l.max,s.max)}},r.prototype.reset=function(i){this.axisRanges[i]=void 0},r.prototype.query=function(i){return this.axisRanges[i]},r}(Fe),Mw=function(t){function r(n,i,o){t.call(this,i),this.textBox=new Wn(n,this.options,o),this.append(this.textBox)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.createVisual=function(){this.textBox.options.noclip=this.options.noclip},r.prototype.reflow=function(i){var o=this.options,a=o.vertical,s=o.aboveAxis,l=this.children[0],h=l.options,p=l.box,f=l.options.padding,g=i;h.align=a?a1:v1,h.vAlign=a?m1:a1,o.position===f9?a?(h.vAlign=m1,!s&&p.height()0&&a.height()>0&&this.createRect(this.visual)},r.prototype.createRect=function(i){var o=this.options,a=o.border,s=ie(a.opacity)?a.opacity:o.opacity,l=this.box.toRect();l.size.width=Math.round(l.size.width);var h=this.rectVisual=$e.fromRect(l,{fill:{color:this.color,opacity:o.opacity},stroke:{color:this.getBorderColor(),width:a.width,opacity:s,dashType:a.dashType}}),p=this.box.width(),f=this.box.height(),g=o.vertical?p:f;if(g>PAt&&(c2(h),(p<1||f<1)&&(h.options.stroke.lineJoin="round")),i.append(h),xw(o)){var b=this.createGradientOverlay(h,{baseColor:this.color},St({end:o.vertical?void 0:[0,1]},o.overlay));i.append(b)}},r.prototype.createHighlight=function(i){var o=$e.fromRect(this.box.toRect(),i);return c2(o)},r.prototype.highlightVisual=function(){return this.rectVisual},r.prototype.highlightVisualArgs=function(){return{options:this.options,rect:this.box.toRect(),visual:this.rectVisual}},r.prototype.createFocusHighlight=function(i){var o=this.options.accessibility.highlight.border.width,a=$e.fromRect(this.box.pad(o/2).toRect(),i);return c2(a)},r.prototype.getBorderColor=function(){var i=this.color,o=this.options.border,a=o._brightness||Hp,s=o.color;return ie(s)||(s=new Go(i).brightness(a).toHex()),s},r.prototype.tooltipAnchor=function(){var i=this,o=i.options,a=i.box,s=i.aboveAxis,l=this.owner.pane.clipBox()||a,h=v1,p=m1,f,g;if(o.vertical)f=Math.min(a.x2,l.x2)+ho,s?g=Math.max(a.y1,l.y1):(g=Math.min(a.y2,l.y2),p=A1);else{var b=Math.max(a.x1,l.x1),z=Math.min(a.x2,l.x2);o.isStacked?(p=A1,s?(h=k1,f=z):f=b,g=Math.max(a.y1,l.y1)-ho):(s?f=z+ho:(f=b-ho,h=k1),g=Math.max(a.y1,l.y1))}return{point:new Qe(f,g),align:{horizontal:h,vertical:p}}},r.prototype.overlapsBox=function(i){return this.box.overlaps(i)},r.prototype.pointData=function(){return{dataItem:this.dataItem,category:this.category,value:this.value,percentage:this.percentage,stackValue:this.stackValue,runningTotal:this.runningTotal,total:this.total,series:this.series}},r.prototype.getIndex=function(){return this.categoryIx},r}(R1);St(ls.prototype,_o);St(ls.prototype,i6);St(ls.prototype,o6);ls.prototype.defaults={border:{width:1},vertical:!0,overlay:{gradient:"glass"},labels:{visible:!1,format:"{0}"},opacity:1,notes:{label:{}},accessibility:{role:w4,className:C4,ariaRoleDescription:S4}};function rF(t,r){t.forEach(r)}function iF(t,r){for(var n=t.length,i=n-1;i>=0;i--)r(t[i],i-n-1)}var J8=function(t){function r(n){t.call(this,n),this.forEach=n.rtl?iF:rF}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.reflow=function(i){var o=this.options,a=o.vertical,s=o.gap,l=o.spacing,h=this.children,p=h.length,f=a?We:Ne,g=p+s+l*(p-1),b=(a?i.height():i.width())/g,z=i[f+1]+b*(s/2);this.forEach(h,function(M,I){var F=(M.box||i).clone();F[f+1]=z,F[f+2]=z+b,M.reflow(F),I0&&a.options.set("stroke",{color:this.getBorderColor(),width:o.border.width,dashType:o.border.dashType,opacity:t1(o.border.opacity,o.opacity)}),c2(a),i.append(a),xw(o)&&i.append(this.createGradientOverlay(a,{baseColor:this.color},St({end:o.vertical?void 0:[0,1]},o.overlay)))},r.prototype.createLines=function(i,o){this.drawLines(i,o,this.lines,o.line)},r.prototype.drawLines=function(i,o,a,s){if(a)for(var l={stroke:{color:s.color||this.color,opacity:t1(s.opacity,o.opacity),width:s.width,dashType:s.dashType,lineCap:"butt"}},h=0;h{4:d}Open:{0:C}High:{1:C}Low:{2:C}Close:{3:C}"},labels:{format:""},highlight:{opacity:1,border:{width:1,opacity:1},line:{width:1,opacity:1}},notes:{visible:!0,label:{}},accessibility:{role:w4,className:C4,ariaRoleDescription:S4}});St(M4.prototype,_o);St(M4.prototype,i6);St(M4.prototype,o6);var Vp=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.reflowCategories=function(i){for(var o=this.children,a=o.length,s=0;sl.close&&(p=i.fields.downColor||a.downColor||a.color),yr(a.color)&&(p=h.color),h.vertical=!this.options.invertAxes;var f=new s(l,h);return f.color=p,f},r.prototype.splitValue=function(i){return[i.low,i.open,i.close,i.high]},r.prototype.updateRange=function(i,o){var a=o.series.axis,s=this.splitValue(i),l=this.valueAxisRanges[a]||{min:Rr,max:ti};this.valueAxisRanges[a]={min:Math.min.apply(Math,s.concat([l.min])),max:Math.max.apply(Math,s.concat([l.max]))}},r.prototype.formatPointValue=function(i,o){var a=i.value;return this.chartService.format.auto(o,a.open,a.high,a.low,a.close,i.category)},r.prototype.animationPoints=function(){return this.points},r}(z4);St(Vp.prototype,Pp);var Fp=function(t){function r(n,i){t.call(this,n,i),this.createNote()}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.reflow=function(i){var o=this,a=o.options,s=o.value,l=o.owner,h=l.seriesValueAxis(a),p,f;this.boxSlot=f=h.getSlot(s.q1,s.q3),this.realBody=f,this.reflowBoxSlot(i),this.whiskerSlot=p=h.getSlot(s.lower,s.upper),this.reflowWhiskerSlot(i);var g=h.getSlot(s.median);if(s.mean){var b=h.getSlot(s.mean);this.meanPoints=this.calcMeanPoints(i,b)}this.whiskerPoints=this.calcWhiskerPoints(f,p),this.medianPoints=this.calcMedianPoints(i,g),this.box=p.clone().wrap(f),this.reflowNote()},r.prototype.reflowBoxSlot=function(i){this.boxSlot.x1=i.x1,this.boxSlot.x2=i.x2},r.prototype.reflowWhiskerSlot=function(i){this.whiskerSlot.x1=i.x1,this.whiskerSlot.x2=i.x2},r.prototype.calcMeanPoints=function(i,o){return[[[i.x1,o.y1],[i.x2,o.y1]]]},r.prototype.calcWhiskerPoints=function(i,o){var a=o.center().x;return[[[a-5,o.y1],[a+5,o.y1],[a,o.y1],[a,i.y1]],[[a-5,o.y2],[a+5,o.y2],[a,o.y2],[a,i.y2]]]},r.prototype.calcMedianPoints=function(i,o){return[[[i.x1,o.y1],[i.x2,o.y1]]]},r.prototype.renderOutliers=function(i){for(var o=this,a=this.value,s=a.outliers||[],l=Math.abs(a.q3-a.q1)*3,h=[],p=i.markers||{},f=0;fa.q1-l?p=i.outliers:p=i.extremes;var b=St({},p.border);ie(b.color)||(ie(o.color)?b.color=o.color:b.color=new Go(p.background).brightness(Hp).toHex());var z=new Rn({type:p.type,width:p.size,height:p.size,rotation:p.rotation,background:p.background,border:b,opacity:p.opacity});z.value=g,h.push(z)}return this.reflowOutliers(h),h},r.prototype.reflowOutliers=function(i){for(var o=this,a=this.owner.seriesValueAxis(this.options),s=this.box.center(),l=0;l{6:d}Lower:{0:C}Q1:{1:C}Median:{2:C}Mean:{5:C}Q3:{3:C}Upper:{4:C}"},highlight:{opacity:1,border:{width:1,opacity:1},line:{width:1,opacity:1}},notes:{visible:!0,label:{}},outliers:{visible:!0,size:c9,type:zb,background:z1,border:{width:2,opacity:1},opacity:0},extremes:{visible:!0,size:c9,type:Nn,background:z1,border:{width:2,opacity:1},opacity:0}});St(Fp.prototype,_o);var TAt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.reflowBoxSlot=function(i){this.boxSlot.y1=i.y1,this.boxSlot.y2=i.y2},r.prototype.reflowWhiskerSlot=function(i){this.whiskerSlot.y1=i.y1,this.whiskerSlot.y2=i.y2},r.prototype.calcMeanPoints=function(i,o){return[[[o.x1,i.y1],[o.x1,i.y2]]]},r.prototype.calcWhiskerPoints=function(i,o){var a=o.center().y;return[[[o.x1,a-5],[o.x1,a+5],[o.x1,a],[i.x1,a]],[[o.x2,a-5],[o.x2,a+5],[o.x2,a],[i.x2,a]]]},r.prototype.calcMedianPoints=function(i,o){return[[[o.x1,i.y1],[o.x1,i.y2]]]},r}(Fp),VAt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.addValue=function(i,o){var a=o.categoryIx,s=o.category,l=o.series,h=o.seriesIx,p=this,f=p.children,g=p.options,b=i.valueFields,z=this.splitValue(b),M=qV(z),I=l.data[a],F=this.categoryPoints[a],H;F||(this.categoryPoints[a]=F=[]),M&&(H=this.createPoint(i,o));var E=f[a];E||(E=new J8({vertical:g.invertAxes,gap:g.gap,spacing:g.spacing,rtl:!g.invertAxes&&(this.chartService||{}).rtl}),this.append(E)),H&&(this.updateRange(b,o),E.append(H),H.categoryIx=a,H.category=s,H.series=l,H.seriesIx=h,H.owner=this,H.dataItem=I),this.points.push(H),F.push(H)},r.prototype.pointType=function(){return this.options.invertAxes?TAt:Fp},r.prototype.splitValue=function(i){return[i.lower,i.q1,i.median,i.q3,i.upper]},r.prototype.updateRange=function(i,o){var a=o.series.axis,s=this.splitValue(i).concat(this.filterOutliers(i.outliers));ie(i.mean)&&(s=s.concat(i.mean));var l=this.valueAxisRanges[a]||{min:Rr,max:ti};this.valueAxisRanges[a]={min:Math.min.apply(Math,s.concat([l.min])),max:Math.max.apply(Math,s.concat([l.max]))}},r.prototype.formatPointValue=function(i,o){var a=i.value;return this.chartService.format.auto(o,a.lower,a.q1,a.median,a.q3,a.upper,a.mean,i.category)},r.prototype.filterOutliers=function(i){for(var o=(i||[]).length,a=[],s=0;s0||i.size<0&&o.series.negativeValues.visible)?(this._maxSize=Math.max(this._maxSize,Math.abs(i.size)),t.prototype.addValue.call(this,i,o)):(this.points.push(null),this.seriesPoints[o.seriesIx].push(null))},r.prototype.reflow=function(i){this.updateBubblesSize(i),t.prototype.reflow.call(this,i)},r.prototype.pointType=function(){return v8},r.prototype.createPoint=function(i,o){var a=o.series,s=a.data.length,l=o.pointIx*(B2/s),h={delay:l,duration:B2-l,type:Ql},p=o.color||a.color;i.size<0&&a.negativeValues.visible&&(p=t1(a.negativeValues.color,p));var f=St({labels:{animation:{delay:l,duration:B2-l}}},this.pointOptions(a,o.seriesIx),{markers:{type:Nn,border:a.border,opacity:a.opacity,animation:h}});f=this.evalPointOptions(f,i,o),yr(a.color)&&(p=f.color),f.markers.background=p;var g=new v8(i,f);return g.color=p,this.append(g),g},r.prototype.updateBubblesSize=function(i){for(var o=this,a=this,s=a.options.series,l=Math.min(i.width(),i.height()),h=0;h0&&o.options.set("stroke",{color:i.border.color||this.color,width:i.border.width,dashType:i.border.dashType,opacity:t1(i.border.opacity,i.opacity)}),this.bodyVisual=o,c2(o),this.visual.append(o)},r.prototype.createAnimation=function(){this.bodyVisual&&(this.animation=K2.create(this.bodyVisual,this.options.animation))},r.prototype.createHighlight=function(i){return $e.fromRect(this.box.toRect(),i)},r.prototype.highlightVisual=function(){return this.bodyVisual},r.prototype.highlightVisualArgs=function(){return{rect:this.box.toRect(),visual:this.bodyVisual,options:this.options}},r.prototype.formatValue=function(i){return this.owner.formatPointValue(this,i)},r.prototype.pointData=function(){return{dataItem:this.dataItem,category:this.category,value:this.value,series:this.series}},r.prototype.overlapsBox=function(i){return this.box.overlaps(i)},r.prototype.getIndex=function(){return this.categoryIx},r}(R1);W0.prototype.tooltipAnchor=ls.prototype.tooltipAnchor;W0.prototype.createFocusHighlight=ls.prototype.createFocusHighlight;de(W0,{border:{width:1},vertical:!1,opacity:1,target:{shape:"",border:{width:0,color:"green"},line:{width:2}},labels:{visible:!1},tooltip:{format:"Current: {0}
Target: {1}"},notes:{label:{}},accessibility:{role:w4,className:C4,ariaRoleDescription:S4}});St(W0.prototype,_o);St(W0.prototype,i6);St(W0.prototype,o6);var kw=function(t){function r(n,i){RAt(i),t.call(this,n,i)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.reflowCategories=function(i){for(var o=this.children,a=o.length,s=0;s0},r.prototype.createAnimation=function(){var i=this,o=this.points;this._setAnimationOptions();for(var a=0;a=0;s--)for(var l=0;l0&&(s=Math.max(s,a.width()-h.contentBox.width()))}if(s!==0)for(var p=0;p0){var f=bv(h),g=Math.max(p.y1-f.y1,p.y2-f.y2);a=Math.max(a,p.x1-f.x1);for(var b=0;b0&&a.y.length>0&&(this.alignAxes(a.x,a.y),this.shrinkAxisWidth(i),this.autoRotateAxisLabels(a),this.alignAxes(a.x,a.y),this.shrinkAxisWidth(i)&&this.alignAxes(a.x,a.y),this.shrinkAxisHeight(i),this.alignAxes(a.x,a.y),this.shrinkAxisHeight(i)&&this.alignAxes(a.x,a.y),this.fitAxes(i))},r.prototype.autoRotateAxisLabels=function(i){for(var o=this,a=this,s=a.panes,l=WAt(s),h,p=0;p0&&i.y.length>0&&(this.alignAxes(i.x,i.y),this.shrinkAxisWidth(s))}},r.prototype.reflowPaneAxes=function(i){var o=i.axes,a=o.length;if(a>0)for(var s=0;s=l.length?(l=f(1),l.at(0)):l[p]},r.prototype._pointsByVertical=function(i){return this.pointsByPointIndex(i.getIndex())},r.prototype._pointsByHorizontal=function(i,o){o===void 0&&(o=0);var a=qu(i.series.index+o,this.series.length);return this.pointsBySeriesIndex(a)},r}(R1);function NAt(t){return!t.pane.axes.some(function(r){return r.options.vertical===t.options.vertical&&r!==t&&r.options.visible!==!1})}function bv(t){for(var r=t.length,n,i=0;i-1){for(var a=t.split(".");a.length>1;)o=a.shift(),ie(i[o])||(i[o]={}),i=i[o];o=a.shift()}i[o]=n}var rs=function(t){function r(){t.call(this),this._defaults={}}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.register=function(i,o){for(var a=this,s=0;sl.to,a.reflow(i)),s&&(s.options.aboveAxis=l.to>l.from,s.reflow(i)),this.note&&this.note.reflow(i)},r}(ls);Am.prototype.defaults=St({},Am.prototype.defaults,{labels:{format:"{0} - {1}"},tooltip:{format:"{1}"}});var hF=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.pointType=function(){return Am},r.prototype.pointValue=function(i){return i.valueFields},r.prototype.formatPointValue=function(i,o){return i.value.from===null&&i.value.to===null?"":this.chartService.format.auto(o,i.value.from,i.value.to)},r.prototype.plotRange=function(i){return i?[i.value.from,i.value.to]:0},r.prototype.updateRange=function(i,o){var a=o.series.axis,s=i.from,l=i.to,h=this.valueAxisRanges[a];i!==null&&b1(s)&&b1(l)&&(h=this.valueAxisRanges[a]=h||{min:Rr,max:ti},h.min=Math.min(h.min,s),h.max=Math.max(h.max,s),h.min=Math.min(h.min,l),h.max=Math.max(h.max,l))},r.prototype.aboveAxis=function(i){var o=i.value;return o.from=0},r.prototype.plotRange=function(i){return[i.from,i.to]},r.prototype.createSegments=function(){for(var i=this,o=this.options.series,a=this.seriesPoints,s=this.segments=[],l=0;l0&&(l=(s*a-n*i)/(s*o-Math.pow(n,2)),h=(i-l*n)/s),{slope:l,intercept:h,count:s,xMin:p,xMax:f}}var t5=function(t,r){return t.every(function(n){var i=n.valueFields;return!Pn(i[r])||i[r]>0})};function e5(t,r){for(var n=[],i=r.totalRangeIndices(),o=r.currentRangeIndices(),a={min:Math.floor(Math.max(o.min-1,i.min)),max:Math.ceil(Math.min(o.max+2,i.max))},s=a.min;s0){var p=Math.exp(l),f=s;return e5(function(g){return p*Math.exp(f*g)},n)}return null}function eLt(t){var r=t.options,n=t.categoryAxis,i=t.seriesValues,o=iLt({seriesValues:i,categoryAxis:n,options:r});return o?Object.assign({},r,{type:"line",data:o,categoryField:"category",field:"value"}):null}var rLt=function(t){return function(r){var n=r.categoryIx,i=r.valueFields;return{xValue:n+1,yValue:i[t]}}};function iLt(t){var r=t.seriesValues,n=t.categoryAxis,i=t.options,o=k4(r(),rLt(i.field)),a=o.slope,s=o.intercept,l=o.count;return l>0?e5(function(h){return a*h+s},n):null}function nLt(t){var r=t.options,n=t.categoryAxis,i=t.seriesValues,o=aLt({seriesValues:i,categoryAxis:n,options:r});return o?Object.assign({},r,{type:"line",data:o,categoryField:"category",field:"value"}):null}var oLt=function(t){return function(r){var n=r.categoryIx,i=r.valueFields;return{xValue:Math.log(n+1),yValue:i[t]}}};function aLt(t){var r=t.seriesValues,n=t.categoryAxis,i=t.options,o=k4(r(),oLt(i.field)),a=o.slope,s=o.intercept,l=o.count;if(l>0){var h=a,p=s;return e5(function(f){return h*Math.log(f)+p},n)}return null}function gF(t,r,n){for(var i=[],o=[],a=Math.max(gw,n)-1,s=0,l=0,h=0;h=a){var z=o.filter(function(F){return F!==null}).length,M=o.shift()||0;if(z>0){var I=l/z;i.push([g,I]),l-=M;continue}}i.push([g,null])}return i.slice(0,s+1)}function sLt(t){var r=t.options,n=hLt(t);return n?Object.assign({},r,{type:"line",data:n,categoryField:"category",field:"value"}):null}var lLt=function(t){return function(r){var n=r.categoryIx,i=r.valueFields;return{xValue:n,yValue:i[t]}}};function cLt(t){var r=t.options,n=t.categoryAxis,i=t.seriesValues,o=(r.trendline||{}).period||gw,a=n.totalRangeIndices(),s=n.currentRangeIndices(),l={min:Math.floor(Math.max(s.min-o,a.min)),max:Math.ceil(Math.min(s.max+o+2,a.max))};return gF(i(l),lLt(r.field),o)}function hLt(t){var r=t.categoryAxis,n=cLt(t),i=[];return n.forEach(function(o){var a=o[0],s=o[1];i[a]={category:r.categoryAt(a,!0),value:s}}),i.length>0?i:null}var wA=1,uLt=6;function mF(t,r,n){for(var i=Math.min(Math.max(n||wA,wA),uLt)+1,o=new vi,a=new vi,s=0,l=Number.MAX_VALUE,h=Number.MIN_VALUE,p=function(H){return H},f=[],g=0;g0&&(f=pLt(o,a),p=function(H){return f.reduce(function(E,R,W){return E+R*Math.pow(H,W)},0)}),{coefficients:f,count:s,valueMapper:p,xMin:l,xMax:h}}function pLt(t,r){for(var n=t.transpose(),i=n.multiply(t).inverse().multiply(n).multiply(r),o=[],a=0;a0?e5(function(h){return l(h)},n):null}function gLt(t){var r=t.options,n=t.categoryAxis,i=t.seriesValues,o=yLt({seriesValues:i,categoryAxis:n,options:r});return o?Object.assign({},r,{type:"line",data:o,categoryField:"category",field:"value"}):null}var mLt=function(t){return function(r){var n=r.categoryIx,i=r.valueFields;return{xValue:Math.log(n+1),yValue:Math.log(i[t])}}};function yLt(t){var r=t.seriesValues,n=t.categoryAxis,i=t.options,o=r();if(!t5(o,i.field))return null;var a=k4(o,mLt(i.field)),s=a.slope,l=a.intercept,h=a.count;if(h>0){var p=Math.exp(l),f=s;return e5(function(g){return p*Math.pow(g,f)},n)}return null}var j0={};j0[hw]=JAt;j0[uw]=eLt;j0[pw]=nLt;j0[dw]=sLt;j0[fw]=dLt;j0[vw]=gLt;var Lm=[Qa,p0,_l,f0],CA=[ts,d0].concat(Lm),uo=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.initFields=function(i){var o=this;if(this.namedCategoryAxes={},this.namedValueAxes={},this.valueAxisRangeTracker=new g9,this._seriesPointsCache={},this._currentPointsCache={},i.length>0){this.invertAxes=u1(i[0].type,[N2,u4,d0,p0,f0,Al,Ml,Ll]);for(var a=0;a0)for(l=s.options.categories=s.options.categories.slice(0);h--;)l.push("");this.valueAxisRangeTracker.update(i.valueAxisRanges),t.prototype.appendChart.call(this,i,o)},r.prototype.seriesPaneName=function(i){var o=this.options,a=i.axis,s=[].concat(o.valueAxis),l=h2(s,function(g){return g.name===a})[0],h=o.panes||[{}],p=(h[0]||{}).name||"default",f=(l||{}).pane||p;return f},r.prototype.seriesCategoryAxis=function(i){var o=i.categoryAxis,a=o?this.namedCategoryAxes[o]:this.categoryAxis;if(!a)throw new Error("Unable to locate category axis with name "+o);return a},r.prototype.stackableChartOptions=function(i,o){var a=i.some(function(h){return h.stack}),s=i.some(function(h){return h.stack&&h.stack.type==="100%"}),l=o.options.clip;return{defaultStack:i[0].stack,isStacked:a,isStacked100:s,clip:l}},r.prototype.groupSeriesByCategoryAxis=function(i){for(var o=[],a={},s=0;s0&&f.length>0&&i.trigger(a,{element:xo(o),originalEvent:o,category:El(p),value:El(f)})}},r.prototype.pointPane=function(i){for(var o=this.panes,a=0;ao.x2&&(g=o.x2-a.x),so.y2&&(b=o.y2-a.y),l0},r.prototype.getItems=function(){return this.itemsContainer.children[0].children},r.prototype.reflow=function(i){var o=this.options,a=i.clone();if(!this.hasItems()){this.box=a;return}o.position===jh?(this.containerCustomReflow(a),this.box=a):this.containerReflow(a),this.hasTitle()&&this.title.reflow(new Ce(this.container.box.x1,this.title.box.y1,this.container.box.x2,this.title.box.y2))},r.prototype.containerReflow=function(i){var o=this,a=o.options,s=o.container,l=a.position,h=a.width,p=a.height,f=l===m1||l===A1?Ne:We,g=this.isVertical(),b=i.clone(),z=i.clone();(l===v1||l===k1)&&(z.y1=b.y1=0),g&&p?(z.y2=z.y1+p,z.align(b,We,s.options.vAlign)):!g&&h&&(z.x2=z.x1+h,z.align(b,Ne,s.options.align)),s.reflow(z),z=s.box;var M=z.clone();(a.offsetX||a.offsetY)&&(z.translate(a.offsetX,a.offsetY),s.reflow(z)),M[f+1]=i[f+1],M[f+2]=i[f+2],this.box=M},r.prototype.containerCustomReflow=function(i){var o=this,a=o.options,s=o.container,l=a.offsetX,h=a.offsetY,p=a.width,f=a.height,g=this.isVertical(),b=i.clone();g&&f?b.y2=b.y1+f:!g&&p&&(b.x2=b.x1+p),s.reflow(b),b=s.box,s.reflow(new Ce(l,h,l+b.width(),h+b.height()))},r.prototype.renderVisual=function(){this.hasItems()&&t.prototype.renderVisual.call(this)},r.prototype.createLegendTitle=function(i){var o=St({},{color:Ar,position:m1,align:a1},i),a=o.text;if(!(!i||i.visible===!1||!i.text)){if(ie(o)&&o.visible){var s=fi(o);s?a=s({text:a}):o.format&&(a=this.chartService.format.auto(o.format,a))}this.title=new Wn(a,o),this.createTitleLayout(),this.appendTitleLayoutContent()}},r.prototype.createTitleLayout=function(){this.layout=new Mp({vertical:!0,wrap:!1}),this.container.append(this.layout)},r.prototype.hasTitle=function(){return!!(this.options.title&&this.options.title.visible!==!1&&this.options.title.text)},r.prototype.appendTitleLayoutContent=function(){var i=this.options;i.title.position===A1?(this.layout.append(this.itemsContainer),this.layout.append(this.title)):(this.layout.append(this.title),this.layout.append(this.itemsContainer))},r}(R1);de(Iw,{position:k1,data:[],offsetX:0,offsetY:0,margin:F1(2),padding:F1(5),border:{color:Ar,width:0},item:{cursor:am,spacing:6},spacing:6,background:"",zIndex:1,markers:{},line:{width:20,height:2,cursor:am,opacity:1},area:{type:fSt,align:k1,width:15,height:15}});var bo=function(t){function r(){t.call(this),this._registry=[]}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.register=function(i,o){this._registry.push({type:i,seriesTypes:o})},r.prototype.create=function(i,o,a){for(var s=this._registry,l=s[0],h,p=0;p0){l=f;break}}return new l.type(h,o,a)},r}(Fe);bo.current=new bo;var ALt=3,LLt=.1;function ba(t){var r=document.createElement("div");return t&&(r.className=t),r}function zA(t){for(var r=t;r&&!Zu(r,"k-handle");)r=r.parentNode;return r}var Hw=function(t){function r(n,i,o,a){t.call(this);var s=n.element;this.options=St({},this.options,o),this.chart=n,this.observer=a,this.chartElement=s,this.categoryAxis=i,this._dateAxis=this.categoryAxis instanceof U8,this.initOptions(),this.visible=this.options.visible&&s.offsetHeight,this.visible&&(this.createElements(),this.set(this._index(this.options.from),this._index(this.options.to)),this.bindEvents())}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.onPane=function(i){return this.categoryAxis.pane===i},r.prototype.createElements=function(){var i=this.options,o=this.wrapper=ba("k-selector k-pointer-events-none");wr(o,{top:i.offset.top,left:i.offset.left,width:i.width,height:i.height,direction:"ltr"});var a=this.selection=ba("k-selection k-pointer-events-none");this.leftMask=ba("k-mask k-pointer-events-none"),this.rightMask=ba("k-mask k-pointer-events-none"),o.appendChild(this.leftMask),o.appendChild(this.rightMask),o.appendChild(a);var s=this.body=ba("k-selection-bg k-pointer-events-none");a.appendChild(s);var l=this.leftHandle=ba("k-handle k-left-handle k-pointer-events-auto"),h=this.rightHandle=ba("k-handle k-right-handle k-pointer-events-auto");l.appendChild(ba()),h.appendChild(ba()),a.appendChild(l),a.appendChild(h),this.chartElement.appendChild(o);var p=wr(a,["borderLeftWidth","borderRightWidth","height"]),f=wr(l,"height").height,g=wr(h,"height").height;i.selection={border:{left:p.borderLeftWidth,right:p.borderRightWidth}},wr(l,{top:(p.height-f)/2}),wr(h,{top:(p.height-g)/2}),o.style.cssText=o.style.cssText},r.prototype.bindEvents=function(){var i;this.options.mousewheel!==!1&&(this._mousewheelHandler=this._mousewheel.bind(this),nc(this.chartElement,(i={},i[v9]=this._mousewheelHandler,i))),this._domEvents=Ap.create(this.chartElement,{stopPropagation:!0,start:this._start.bind(this),move:this._move.bind(this),end:this._end.bind(this),tap:this._tap.bind(this),press:this._press.bind(this),gesturestart:this._gesturestart.bind(this),gesturechange:this._gesturechange.bind(this),gestureend:this._gestureend.bind(this)})},r.prototype.initOptions=function(){var i=this,o=i.options,a=i.categoryAxis,s=a.pane.chartsBox(),l=this.chart.chartService.intl;this._dateAxis&&St(o,{min:Si(l,o.min),max:Si(l,o.max),from:Si(l,o.from),to:Si(l,o.to)});var h=wr(this.chartElement,["paddingLeft","paddingTop"]),p=h.paddingLeft,f=h.paddingTop;this.options=St({},{width:s.width(),height:s.height()+LLt,padding:{left:p,top:f},offset:{left:s.x1+p,top:s.y1+f},from:o.min,to:o.max},o)},r.prototype.destroy=function(){var i;this._domEvents&&(this._domEvents.destroy(),delete this._domEvents),clearTimeout(this._mwTimeout),this._state=null,this.wrapper&&(this._mousewheelHandler&&(oc(this.chartElement,(i={},i[v9]=this._mousewheelHandler,i)),this._mousewheelHandler=null),this.chartElement.removeChild(this.wrapper),this.wrapper=null)},r.prototype._rangeEventArgs=function(i){return{axis:this.categoryAxis.options,from:this._value(i.from),to:this._value(i.to)}},r.prototype._pointInPane=function(i,o){var a=this.categoryAxis.pane.box,s=this.chart._toModelCoordinates(i,o);return a.containsPoint(s)},r.prototype._start=function(i){var o=this.options,a=xo(i);if(!(this._state||!a)){var s=nV(i),l=this._pointInPane(s.x,s.y);if(l){var h=zA(a),p=this.body.getBoundingClientRect(),f=!h&&s.x>=p.x&&s.x<=p.x+p.width&&s.y>=p.y&&s.y<=p.y+p.height;this.chart._unsetActivePoint(),this._state={moveTarget:h,startLocation:i.x?i.x.location:0,inBody:f,range:{from:this._index(o.from),to:this._index(o.to)}};var g=this._rangeEventArgs({from:this._index(o.from),to:this._index(o.to)});this.trigger(zm,g)&&(this._state=null)}}},r.prototype._press=function(i){var o;this._state?o=this._state.moveTarget:o=zA(xo(i)),o&&Dr(o,"k-handle-active")},r.prototype._move=function(i){if(this._state){var o=this,a=o._state,s=o.options,l=o.categoryAxis,h=a.range,p=a.moveTarget,f=l.options.reverse,g=this._index(s.from),b=this._index(s.to),z=this._index(s.min),M=this._index(s.max),I=a.startLocation-i.x.location,F={from:h.from,to:h.to},H=h.to-h.from,E=wr(this.wrapper,"width").width/(l.categoriesCount()-1),R=Math.round(I/E)*(f?-1:1);if(!(!p&&!a.inBody)){var W=p&&Zu(p,"k-left-handle"),$=p&&Zu(p,"k-right-handle");a.inBody?(h.from=Math.min(Math.max(z,g-R),M-H),h.to=Math.min(h.from+H,M)):W&&!f||$&&f?(h.from=Math.min(Math.max(z,g-R),M-1),h.to=Math.max(h.from+1,h.to)):(W&&f||$&&!f)&&(h.to=Math.min(Math.max(z+1,b-R),M),h.from=Math.min(h.to-1,h.from)),(h.from!==F.from||h.to!==F.to)&&(this.move(h.from,h.to),this.trigger(lc,this._rangeEventArgs(h)))}}},r.prototype._end=function(){if(this._state){var i=this._state.moveTarget;i&&_b(i,"k-handle-active");var o=this._state.range;this.set(o.from,o.to),this.trigger(Mm,this._rangeEventArgs(o)),delete this._state}},r.prototype._tap=function(i){var o=this,a=o.options,s=o.categoryAxis,l=this.chart._eventCoordinates(i),h=s.pointCategoryIndex(new Qe(l.x,s.box.y1)),p=this._index(a.from),f=this._index(a.to),g=this._index(a.min),b=this._index(a.max),z=f-p,M=p+z/2,I={},F=i.event.which===3,H=Math.round(M-h);this._state||F||(this.chart._unsetActivePoint(),s.options.justified||H--,I.from=Math.min(Math.max(g,p-H),b-z),I.to=Math.min(I.from+z,b),this._start(i),this._state&&(this._state.range=I,this.trigger(lc,this._rangeEventArgs(I)),this._end()))},r.prototype._mousewheel=function(i){var o=this,a=Wb(i);if(this._start(i),this._state){var s=this._state.range;i.preventDefault(),i.stopPropagation(),Math.abs(a)>1&&(a*=ALt),this.options.mousewheel.reverse&&(a*=-1),this.expand(a)&&this.trigger(lc,{axis:this.categoryAxis.options,delta:a,originalEvent:i,from:this._value(s.from),to:this._value(s.to)}),this._mwTimeout&&clearTimeout(this._mwTimeout),this._mwTimeout=setTimeout(function(){o._end()},km)}},r.prototype._gesturestart=function(i){var o=this.options,a=i.touches[0],s=this._pointInPane(a.pageX,a.pageY);if(s){this._state={range:{from:this._index(o.from),to:this._index(o.to)}};var l=this._rangeEventArgs(this._state.range);this.trigger(zm,l)?this._state=null:i.preventDefault()}},r.prototype._gestureend=function(){this._state&&(this.trigger(Mm,this._rangeEventArgs(this._state.range)),delete this._state)},r.prototype._gesturechange=function(i){if(this._state){var o=this,a=o.chart,s=o._state,l=o.options,h=o.categoryAxis,p=s.range,f=a._toModelCoordinates(i.touches[0].x.location).x,g=a._toModelCoordinates(i.touches[1].x.location).x,b=Math.min(f,g),z=Math.max(f,g);i.preventDefault(),p.from=h.pointCategoryIndex(new Qe(b))||l.min,p.to=h.pointCategoryIndex(new Qe(z))||l.max,this.move(p.from,p.to),this.trigger(lc,this._rangeEventArgs(p))}},r.prototype._index=function(i){var o=i;return i instanceof Date&&(o=this.categoryAxis.categoryIndex(i)),o},r.prototype._value=function(i){var o=i;return this._dateAxis&&(o=this.categoryAxis.categoryAt(i),o>this.options.max&&(o=this.options.max)),o},r.prototype._slot=function(i){var o=this.categoryAxis,a=this._index(i);return o.getSlot(a,a,!0)},r.prototype.move=function(i,o){var a=this.options,s=this.categoryAxis.options.reverse,l=a.offset,h=a.padding,p=a.selection.border,f=s?o:i,g=s?i:o,b="x"+(s?2:1),z=this._slot(f),M=Ae(z[b]-l.left+h.left);wr(this.leftMask,{width:M}),wr(this.selection,{left:M}),z=this._slot(g);var I=Ae(a.width-(z[b]-l.left+h.left));wr(this.rightMask,{width:I});var F=a.width-I;F!==a.width&&(F+=p.right),wr(this.rightMask,{left:F}),wr(this.selection,{width:Math.max(a.width-(M+I)-p.right,0)})},r.prototype.set=function(i,o){var a=this.options,s=this._index(a.min),l=this._index(a.max),h=Xe(this._index(i),s,l),p=Xe(this._index(o),h+1,l);a.visible&&this.move(h,p),a.from=this._value(h),a.to=this._value(p)},r.prototype.expand=function(i){var o=this.options,a=this._index(o.min),s=this._index(o.max),l=o.mousewheel.zoom,h=this._index(o.from),p=this._index(o.to),f={from:h,to:p},g=St({},f);if(this._state&&(f=this._state.range),l!==k1&&(f.from=Xe(Xe(h-i,0,p-1),a,s)),l!==v1&&(f.to=Xe(Xe(p+i,f.from+1,s),a,s)),f.from!==g.from||f.to!==g.to)return this.set(f.from,f.to),!0},r.prototype.zoom=function(i,o){var a=this.options,s=this._index(a.min),l=this._index(a.max),h=this._index(a.from),p=this._index(a.to),f={from:h,to:p},g=St({},f),b=this.categoryAxis.options,z=b.reverse,M=Ne+(z?"2":"1"),I=this.categoryAxis.lineBox(),F=Math.abs(I[M]-o[Ne]),H=I.width(),E=Ae(F/H,2),R=Ae(E*i),W=Ae((1-E)*i);if(this._state&&(f=this._state.range),f.from=Xe(Xe(h-R,0,p-1),s,l),f.to=Xe(Xe(p+W,f.from+1,l),s,l),f.from!==g.from||f.to!==g.to)return this.set(f.from,f.to),!0},r.prototype.trigger=function(i,o){return(this.observer||this.chart).trigger(i,o)},r}(Fe);de(Hw,{visible:!0,mousewheel:{zoom:"both"},min:ti,max:Rr});var ELt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.show=function(i){if(!(!i||!i.tooltipAnchor||this._current&&this._current===i)){var o=St({},this.options,i.options.tooltip),a=i.tooltipAnchor();a?(this._current=i,t.prototype.show.call(this,{point:i,anchor:a},o,i)):this.hide()}},r.prototype.hide=function(){delete this._current,t.prototype.hide.call(this)},r}(Rp),Dw=function(t){function r(n,i){t.call(this,n.chartService,i),this.plotArea=n,this.formatService=n.chartService.format}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.showAt=function(i,o){var a=h2(i,function(p){var f=p.series.tooltip,g=f&&f.visible===!1;return!g});if(a.length>0){var s=a[0],l=this.plotArea.categoryAxis.getSlot(s.categoryIx),h=o?this._slotAnchor(o,l):this._defaultAnchor(s,l);this.show({anchor:h,shared:!0,points:i,category:s.category,categoryText:this.formatService.auto(this.options.categoryFormat,s.category),series:this.plotArea.series},this.options)}},r.prototype._slotAnchor=function(i,o){var a=this.plotArea.categoryAxis,s={horizontal:"left",vertical:"center"};return a.options.vertical||(i.x=o.center().x),{point:i,align:s}},r.prototype._defaultAnchor=function(i,o){var a=i.owner.pane.chartsBox(),s=this.plotArea.categoryAxis.options.vertical,l=a.center(),h=o.center(),p={horizontal:"center",vertical:"center"},f;return s?f=new Qe(l.x,h.y):f=new Qe(h.x,l.y),{point:f,align:p}},r}(Rp);de(Dw,{categoryFormat:"{0:d}"});var MF=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.setup=function(){var i=this,o=i.element,a=i.options,s=o.bbox();if(s){this.origin=a.origin;var l=a.vertical?We:Ne,h=this.fromScale=new ye(1,1);h[l]=p8,o.transform(ar().scale(h.x,h.y))}else this.abort()},r.prototype.step=function(i){var o=F2(this.fromScale.x,1,i),a=F2(this.fromScale.y,1,i);this.element.transform(ar().scale(o,a,this.origin))},r.prototype.abort=function(){t.prototype.abort.call(this),this.element.transform(null)},r}(K2);de(MF,{duration:B2});oa.current.register(N2,MF);var kF=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.setup=function(){var i=this.center=this.element.bbox().center();this.element.transform(ar().scale(p8,p8,i))},r.prototype.step=function(i){this.element.transform(ar().scale(i,i,this.center))},r}(K2);de(kF,{easing:"easeOutElastic"});oa.current.register(Ql,kF);var _F=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.setup=function(){this.fadeTo=this.element.opacity(),this.element.opacity(0)},r.prototype.step=function(i){this.element.opacity(i*this.fadeTo)},r}(K2);de(_F,{duration:200,easing:"linear"});oa.current.register(b4,_F);var AF=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.setup=function(){this.element.transform(ar().scale(p8,p8,this.options.center))},r.prototype.step=function(i){this.element.transform(ar().scale(i,i,this.options.center))},r}(K2);de(AF,{easing:"easeOutElastic",duration:B2});oa.current.register(p4,AF);var Pw=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.render=function(){t.prototype.render.call(this),this.renderSegments()},r.prototype.createSegment=function(i,o,a){var s=o.style,l;return s===Jl?l=ww:l=$0,new l(i,o,a)},r.prototype.animationPoints=function(){var i=t.prototype.animationPoints.call(this);return i.concat(this._segments)},r.prototype.createMissingValue=function(i,o){if(o===Ja){var a={x:i.x,y:i.y};return Pn(a.x)||(a.x=0),Pn(a.y)||(a.y=0),a}},r}(s6);St(Pw.prototype,Cw);function r5(t,r,n){var i=[],o=r.xMin,a=r.xMax,s=(n||{}).forecast;s&&(s.before>0&&(o-=s.before),s.after>0&&(a+=s.after));var l=(n||{}).samplingInterval,h=t1(l,Xl(o,a)/10);l<=0&&(h=a-o);for(var p=o;p<=a;p+=h)i.push([p,t(p)]);return i}function ILt(t){var r=t.options,n=t.seriesValues,i=DLt({seriesValues:n,options:r});return i?Object.assign({},r,{type:"scatterLine",data:i}):null}var HLt=function(t){return function(r){var n=r.valueFields;return{xValue:n.x,yValue:Math.log(n[t])}}};function DLt(t){var r=t.seriesValues,n=t.options,i=r();if(!t5(i,n.field))return null;var o=k4(i,HLt(n.field)),a=o.slope,s=o.intercept,l=o.count,h=o.xMin,p=o.xMax,f={xMin:h,xMax:p};if(l>0){var g=Math.exp(s),b=a;return r5(function(z){return g*Math.exp(b*z)},f,n.trendline)}return null}var Op=function(t){return function(r){var n=r.valueFields;return{xValue:n.x,yValue:n[t]}}};function PLt(t){var r=t.options,n=t.seriesValues,i=TLt({seriesValues:n,options:r});return i?Object.assign({},r,{type:"scatterLine",data:i}):null}function TLt(t){var r=t.seriesValues,n=t.options,i=k4(r(),Op(n.field)),o=i.slope,a=i.intercept,s=i.count,l=i.xMin,h=i.xMax,p={xMin:l,xMax:h};return s>0?r5(function(f){return o*f+a},p,n.trendline):null}function LF(t,r){for(var n=Number.MAX_VALUE,i=Number.MIN_VALUE,o=0;o0){var p=a,f=s;return r5(function(g){return p*Math.log(g)+f},h,n.trendline)}return null}function BLt(t){var r=t.options,n=NLt(t);return n?Object.assign({},r,{type:"scatterLine",data:n}):null}function NLt(t){var r=t.options,n=t.seriesValues,i=(r.trendline||{}).period||gw,o={before:i,after:i},a=gF(n(o),Op(r.field),i);return a.length>0?a:null}function $Lt(t){var r=t.options,n=t.seriesValues,i=WLt({seriesValues:n,options:r});return i?Object.assign({},r,{type:"scatterLine",data:i}):null}function WLt(t){var r=t.seriesValues,n=t.options,i=(n.trendline||{}).order,o=Op(n.field),a=mF(r(),o,i),s=a.count,l=a.valueMapper,h=a.xMin,p=a.xMax,f={xMin:h,xMax:p};return s>0?r5(l,f,n.trendline):null}function jLt(t){var r=t.options,n=t.seriesValues,i=ULt({seriesValues:n,options:r});return i?Object.assign({},r,{type:"scatterLine",data:i}):null}var GLt=function(t){return function(r){var n=r.valueFields;return{xValue:Math.log(n.x),yValue:Math.log(n[t])}}};function ULt(t){var r=t.seriesValues,n=t.options,i=r();if(!t5(i,"x"))return null;var o=k4(i,GLt(n.field)),a=o.slope,s=o.intercept,l=o.count,h=LF(i,Op(n.field));if(l>0){var p=Math.exp(s),f=a;return r5(function(g){return p*Math.pow(g,f)},h,n.trendline)}return null}var G0={};G0[hw]=ILt;G0[uw]=PLt;G0[pw]=VLt;G0[dw]=BLt;G0[fw]=$Lt;G0[vw]=jLt;var i5=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.initFields=function(){this.namedXAxes={},this.namedYAxes={},this.xAxisRangeTracker=new g9,this.yAxisRangeTracker=new g9},r.prototype.render=function(i){var o=this;i===void 0&&(i=this.panes),this.series=[].concat(this.originalSeries),this.createTrendlineSeries();for(var a=this.groupSeriesByPane(),s=0;s0&&this.appendChart(new s6(this,{series:i,clip:o.options.clip}),o)},r.prototype.createScatterLineChart=function(i,o){i.length>0&&this.appendChart(new Pw(this,{series:i,clip:o.options.clip}),o)},r.prototype.createBubbleChart=function(i,o){i.length>0&&this.appendChart(new oF(this,{series:i,clip:o.options.clip}),o)},r.prototype.createXYAxis=function(i,o,a){for(var s=i.name,l=o?this.namedYAxes:this.namedXAxes,h=o?this.yAxisRangeTracker:this.xAxisRangeTracker,p=St({reverse:!o&&this.chartService.rtl},i,{vertical:o}),f=Pa(p.type,d9),g=h.query(),b=f?{min:.1,max:1}:{min:0,max:1},z=h.query(s)||g||b,M=[p.min,p.max],I=this.series,F=0;F0&&g.length>0&&i.trigger(a,{element:xo(o),originalEvent:o,x:El(f),y:El(g)})},r.prototype.updateAxisOptions=function(i,o){var a=i.options.vertical,s=this.groupAxes(this.panes),l=(a?s.y:s.x).indexOf(i);MA(this.options,l,a,o),MA(this.originalOptions,l,a,o)},r.prototype.trendlineFactory=function(i,o){var a=this.seriesValues.bind(this,o.index),s=vF(G0,i.type,{options:i,seriesValues:a});return s&&(s.xAxis=o.xAxis,s.yAxis=o.yAxis),s},r.prototype.seriesValues=function(i){for(var o=this,a=[],s=this.series[i],l=0;l=s.center.x?(b=g.x+f,a.orientation=k1):(b=g.x-f,a.orientation=v1),a.reflow(new Ce(b,g.y-p,g.x,g.y))}}},r.prototype.createVisual=function(){var i=this,o=this,a=o.sector,s=o.options;if(t.prototype.createVisual.call(this),this.addAccessibilityAttributesToVisual(),this.value)if(s.visual){var l=(a.startAngle+180)%360,h=s.visual({category:this.category,dataItem:this.dataItem,value:this.value,series:this.series,percentage:this.percentage,center:new ye(a.center.x,a.center.y),radius:a.radius,innerRadius:a.innerRadius,startAngle:l,endAngle:l+a.angle,options:s,sender:this.getSender(),createVisual:function(){var p=new P1;return i.createSegmentVisual(p),p}});h&&this.visual.append(h)}else this.createSegmentVisual(this.visual)},r.prototype.createSegmentVisual=function(i){var o=this,a=o.sector,s=o.options,l=s.border||{},h=l.width>0?{stroke:{color:l.color,width:l.width,opacity:l.opacity,dashType:l.dashType}}:{},p=s.color,f={color:p,opacity:s.opacity},g=this.createSegment(a,St({fill:f,stroke:{opacity:s.opacity},zIndex:s.zIndex},h));i.append(g),xw(s)&&i.append(this.createGradientOverlay(g,{baseColor:p,fallbackFill:f},St({center:[a.center.x,a.center.y],innerRadius:a.innerRadius,radius:a.radius,userSpace:!0},s.overlay)))},r.prototype.createSegment=function(i,o){return o.singleSegment?new Uo(new l2(new ye(i.center.x,i.center.y),i.radius),o):Cl.current.createRing(i,o)},r.prototype.createAnimation=function(){var i=this,o=i.options,a=i.sector.center;St(o,{animation:{center:[a.x,a.y],delay:this.animationDelay}}),t.prototype.createAnimation.call(this)},r.prototype.createHighlight=function(i){var o=this.options.highlight||{},a=o.border||{};return this.createSegment(this.sector,St({},i,{fill:{color:o.color,opacity:o.opacity},stroke:{opacity:a.opacity,width:a.width,color:a.color}}))},r.prototype.highlightVisual=function(){return this.visual.children[0]},r.prototype.highlightVisualArgs=function(){var i=this.sector;return{options:this.options,radius:i.radius,innerRadius:i.innerRadius,center:new ye(i.center.x,i.center.y),startAngle:i.startAngle,endAngle:i.angle+i.startAngle,visual:this.visual}},r.prototype.createFocusHighlight=function(i){var o=this.options.accessibility.highlight.border.width,a=this.createSegment(this.sector,St({},i,{stroke:{width:o*2}})),s=new qo;return s.paths.push($e.fromRect(a.bbox())),s.paths.push(this.createSegment(this.sector,{})),a.clip(s),a},r.prototype.tooltipAnchor=function(){var i=this.sector.clone().expand(ho),o=i.middle(),a=i.point(o);return{point:a,align:KLt(o+180)}},r.prototype.formatValue=function(i){return this.owner.formatPointValue(this,i)},r.prototype.pointData=function(){return{dataItem:this.dataItem,category:this.category,value:this.value,series:this.series,percentage:this.percentage}},r.prototype.getIndex=function(){return this.index},r}(R1),YLt=Ae(Qr(30),X1),XLt=Ae(Qr(60),X1);function KLt(t){var r=Qr(t),n=Ae(Math.sin(r),X1),i=Ae(Math.cos(r),X1),o;Math.abs(n)>XLt?o=a1:i<0?o=k1:o=v1;var a;return Math.abs(n)b-f?b-f:W,M.translate(F.x-I.x,F.y-I.y);for(var $=b-W,G=new Qe($+M.x1+W,$+M.y1+W),Z=0;Z0&&(E.sort(this.labelComparator(!0)),this.leftLabelsReflow(E)),R.length>0&&(R.sort(this.labelComparator(!1)),this.rightLabelsReflow(R)),this.box=M},r.prototype.leftLabelsReflow=function(i){var o=this.distanceBetweenLabels(i);this.distributeLabels(o,i)},r.prototype.rightLabelsReflow=function(i){var o=this.distanceBetweenLabels(i);this.distributeLabels(o,i)},r.prototype.distanceBetweenLabels=function(i){var o=Vr(this.points),a=o.sector,s=i.length-1,l=a.radius+o.options.labels.distance,h=[],p=i[0].box,f=Ae(p.y1-(a.center.y-l-p.height()-p.height()/2));h.push(f);for(var g=0;g0&&(l>=0||h0){var h=Math.min(i[a],l);l-=h,i[a]-=h,i[o]+=h}return l},r.prototype.reflowLabels=function(i,o){var a=this,s=Vr(this.points),l=s.sector,h=s.options.labels,p=o.length,f=h.distance,g=l.center.y-(l.radius+f)-o[0].box.height(),b;i[0]+=2;for(var z=0;zg.center.x?(W=g.center.x-g.radius-h,f.options.labels.align!==Qo?W>R.x?I.lineTo(W,E.y):I.lineTo(E.x-h*2,E.y):I.lineTo(W,E.y),I.lineTo(R.x,$.y)):(G.y=$.y,I.lineTo(G.x,G.y))),I.lineTo($.x,$.y),i._connectorLines.push(I),i.visual.append(I)}}}},r.prototype.renderVisual=function(){if(t.prototype.renderVisual.call(this),sV(this.options.series,function(h){return h.autoFit})){var i=this.targetBox,o=this.box.center(),a=this.visual.bbox();if(!a)return;var s=a.bottomRight(),l=Math.min((o.y-i.y1)/(o.y-a.origin.y),(i.y2-o.y)/(s.y-o.y),(o.x-i.x1)/(o.x-a.origin.x),(i.x2-o.x)/(s.x-o.x));l<1&&this.visual.transform(ar().scale(l,l,[o.x,o.y]))}},r.prototype.labelComparator=function(i){var o=i?-1:1;return function(a,s){var l=(a.parent.sector.middle()+270)%360,h=(s.parent.sector.middle()+270)%360;return(l-h)*o}},r.prototype.hAlignLabel=function(i,o,a,s,l){var h=o.radius,p=o.center,f=p.x,g=p.y,b=Math.min(Math.abs(g-a),Math.abs(g-s));return b>h?i:f+Math.sqrt(h*h-b*b)*(l?1:-1)},r.prototype.pointInCircle=function(i,o,a){return Math.pow(o.x-i.x,2)+Math.pow(o.y-i.y,2)p-l?p-l:z;for(var M=p-z,I=0,F,H=0;H1)for(var i=nEt(this._segments),o=0;o1){var s=a[0].linePoints[0],l=Vr(a),h=Vr(l.linePoints),p=s.categoryIx===0,f=h.categoryIx===h.categoriesCount-1;p&&f&&Vr(a).linePoints.push(s)}}},r.prototype.createSegment=function(i,o,a){var s=o.style,l;s===Jl?l=ww:l=$0;var h=new l(i,o,a),p=this.seriesMissingValues(o);return(i.length===o.data.length||p===zl)&&(h.options.closed=!0),h},r}(Tp);de(Fw,{clip:!1,limitPoints:!1});var oEt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.fillToAxes=function(){},r}(zw),aEt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.fillToAxes=function(){},r}(n6),sEt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.createSegment=function(i,o,a,s){var l=this.options.isStacked,h=(o.line||{}).style,p,f,g;return l&&a>0&&s&&(f=s.linePoints.slice(0),p=s),h===Jl?(g=new oEt(i,o,a,p,f),g.options.closed=!0):(i.push(i[0]),g=new aEt(i,o,a,p,f)),g},r.prototype.seriesMissingValues=function(i){return i.missingValues||Ja},r}(Fw),PF=function(t){function r(n,i){t.call(this,n,null,i)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.getIndex=function(){return this.categoryIx},r}(Bp);de(PF,{overlay:{gradient:"none"},labels:{distance:10}});var TF=function(t){function r(n){t.call(this,n),this.forEach=n.rtl?iF:rF}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.reflow=function(i){var o=this,a=o.options,s=o.children,l=a.gap,h=a.spacing,p=s.length,f=p+l+h*(p-1),g=i.angle/f,b=i.startAngle+g*(l/2);this.forEach(s,function(z){var M=i.clone();M.startAngle=b,M.angle=g,z.sector&&(M.radius=z.sector.radius),z.reflow(M),z.sector=M,b+=g+g*h})},r}(R1);de(TF,{gap:1,spacing:0});var lEt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.reflow=function(i){var o=this,a=o.options.reverse,s=o.children,l=s.length,h=a?l-1:0,p=a?-1:1;this.box=new Ce;for(var f=h;f>=0&&f1,o.isStacked100=l&&l.type==="100%"&&s.length>1,o.isStacked100&&(this._isStacked100=!0)}return o},r.prototype.createAreaChart=function(i,o){if(i.length!==0){var a=new sEt(this,this.chartOptions(i));this.appendChart(a,o)}},r.prototype.createLineChart=function(i,o){if(i.length!==0){var a=new Fw(this,this.chartOptions(i));this.appendChart(a,o)}},r.prototype.createBarChart=function(i,o){if(i.length!==0){var a=i[0],s=this.chartOptions(i),l=this.filterVisibleSeries(i),h=l.some(function(g){return g.stack}),p=l.some(function(g){return g.stack&&g.stack.type==="100%"});s.gap=a.gap,s.spacing=a.spacing,s.defaultStack=a.stack&&l.length>1,s.isStacked=h&&l.length>1,s.isStacked100=p&&l.length>1;var f=new Rw(this,s);this.appendChart(f,o),this._hasBarCharts=!0}},r.prototype.seriesCategoryAxis=function(){return this.categoryAxis},r.prototype._dispatchEvent=function(i,o,a){var s=i._eventCoordinates(o),l=new Qe(s.x,s.y),h=this.categoryAxis.getCategory(l),p=this.valueAxis.getValue(l);h!==null&&p!==null&&i.trigger(a,{element:xo(o),category:h,value:p})},r.prototype.createCrosshairs=function(){},r.prototype._pointsByVertical=function(i){return t.prototype._pointsByVertical.call(this,i).sort(this._getSeriesCompareFn())},r.prototype._getSeriesCompareFn=function(){return function(i,o){return o.value-i.value}},r}(DF);St(Ow.prototype,Q8,{appendChart:uo.prototype.appendChart,aggregateSeries:uo.prototype.aggregateSeries,seriesSourcePoints:uo.prototype.seriesSourcePoints,seriesValues:uo.prototype.seriesValues});de(Ow,{categoryAxis:{categories:[]},valueAxis:{}});var $p=function(t){function r(n,i,o){t.call(this,i),this.value=n,this.options.index=o.index}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.getLabelText=function(i){var o=fi(i);return o?o(this.pointData()):i.format?this.formatValue(i.format):this.value},r.prototype.reflow=function(i){var o=this.points,a=this.children[0],s=Math.min(o[0].x,o[3].x),l=Math.max(o[1].x,o[2].x);this.box=new Ce(s,o[0].y,l,o[2].y),a&&a.reflow(new Ce(i.x1,o[0].y,i.x2,o[2].y))},r.prototype.createVisual=function(){var i=this,o=this.options,a;t.prototype.createVisual.call(this),this.addAccessibilityAttributesToVisual(),o.visual?a=o.visual({category:this.category,dataItem:this.dataItem,value:this.value,series:this.series,percentage:this.percentage,points:this.points,options:o,sender:this.getSender(),createVisual:function(){return i.createPath()}}):a=this.createPath(),a&&this.visual.append(a)},r.prototype.createPath=function(){var i=this.options,o=i.border,a=$e.fromPoints(this.points,{fill:{color:i.color,opacity:i.opacity},stroke:{color:o.color,opacity:o.opacity,width:o.width}}).close();return a},r.prototype.createHighlight=function(i){return $e.fromPoints(this.points,i)},r.prototype.highlightVisual=function(){return this.visual.children[0]},r.prototype.highlightVisualArgs=function(){var i=$e.fromPoints(this.points).close();return{options:this.options,path:i}},r.prototype.createFocusHighlight=function(i){var o=this.options.accessibility.highlight.border.width,a=$e.fromPoints(this.points,St({},i,{stroke:{width:o*2}})).close(),s=new qo;return s.paths.push($e.fromRect(this.box.clone().pad(o).toRect())),s.paths.push($e.fromPoints(this.points)),a.clip(s),a},r.prototype.tooltipAnchor=function(){var i=this.box;return{point:new Qe(i.center().x,i.y1),align:{horizontal:"center",vertical:"top"}}},r.prototype.formatValue=function(i){var o=this;return o.owner.formatPointValue(o,i)},r.prototype.pointData=function(){return{dataItem:this.dataItem,category:this.category,value:this.value,series:this.series,percentage:this.percentage}},r.prototype.getIndex=function(){return this.index},r}(R1);de($p,{color:z1,border:{width:1},labels:{format:""},accessibility:{role:w4,className:C4,ariaRoleDescription:S4}});St($p.prototype,_o);St($p.prototype,o6);var Wp=function(t){function r(n,i){t.call(this,i),this.plotArea=n,this.chartService=n.chartService,this.points=[],this.labels=[],this.legendItems=[],this.render()}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.formatPointValue=function(i,o){return this.plotArea.chartService.format.auto(o,i.value)},r.prototype.render=function(){var i=this,o=0,a=this,s=a.options,l=a.plotArea.options.seriesColors;l===void 0&&(l=[]);var h=s.series[o],p=h.data;if(p)for(var f=ZV(h),g=f.total,b=f.points,z=0;zg.percentage&&(g=h[b]);for(var z=f.percentage/g.percentage*o,M=(o-z)/2,I=0,F=0;F0&&g.length>0&&i.trigger(a,{element:xo(o),originalEvent:o,x:El(f),y:El(g)})},r.prototype.updateAxisOptions=function(i,o){var a=i.options.vertical,s=this.groupAxes(this.panes),l=(a?s.y:s.x).indexOf(i);_A(this.options,l,a,o),_A(this.originalOptions,l,a,o)},r.prototype.crosshairOptions=function(i){return Object.assign({},i.options.crosshair,{zIndex:0})},r.prototype._pointsByVertical=function(i,o){var a=this;o===void 0&&(o=0);var s=this.axisX.options.reverse?o*-1:o,l=this.axisX.children,h=this._getPointAxisXIndex(i)+s;h=qu(h,l.length);var p=l[h].value,f=this.filterPoints(function(g){return wv(g.pointData().x,p)}).sort(function(g,b){return a._getPointAxisYIndex(g)-a._getPointAxisYIndex(b)});return this.axisY.options.reverse?f.reverse():f},r.prototype._pointsByHorizontal=function(i,o){var a=this;o===void 0&&(o=0);var s=this.axisY.options.reverse?o*-1:o,l=this.axisY.children,h=this._getPointAxisYIndex(i)+s;h=qu(h,l.length);var p=l[h].value,f=this.filterPoints(function(g){return wv(g.pointData().y,p)}).sort(function(g,b){return a._getPointAxisXIndex(g)-a._getPointAxisXIndex(b)});return this.axisX.options.reverse?f.reverse():f},r.prototype._getPointAxisXIndex=function(i){return this._getPointAxisIndex(this.axisX,i.pointData().x)},r.prototype._getPointAxisYIndex=function(i){return this._getPointAxisIndex(this.axisY,i.pointData().y)},r.prototype._getPointAxisIndex=function(i,o){return i.children.findIndex(function(a){return wv(o,a.value)})},r}(cs);function wv(t,r){return t instanceof Date&&r instanceof Date?n9(t,r):t===r}function _A(t,r,n,i){var o=[].concat(n?t.yAxis:t.xAxis)[r];St(o,i)}de(Bw,{xAxis:{},yAxis:{}});St(Bw.prototype,Q8);var v2="color",u2="first",dEt="from",dn="max",Nw="min",hs="noteText",fEt="summary",vEt="to";bo.current.register(uo,[N2,Qo,ts,d0,Qa,p0,t6,e6,u4,q8,Y8,Ll,K8,Al,Z8,Ml,_l,f0].concat(r6));bo.current.register(i5,[lw,cw,Ql].concat(r6));bo.current.register(IF,[p4]);bo.current.register(JLt,[u9]);bo.current.register(uEt,[d8,f8]);bo.current.register(Vw,[aw,p9,sw].concat(r6));bo.current.register(Ow,[X8,Dp,kl].concat(r6));bo.current.register(Bw,[ow]);q1.current.register([N2,Qo,ts,d0,Qa,p0],[o2],[ko,v2,hs,RV,OV,ss]);q1.current.register([K8,Al,_l,f0],[dEt,vEt],[ko,v2,hs,ss]);q1.current.register([Z8,Ml],[o2],[ko,v2,hs,fEt,ss]);q1.current.register([aw,p9,sw],[Ne,We],[v2,ss]);q1.current.register([X8,Dp,kl],[o2],[ko,v2,ss]);q1.current.register([d8,f8],[o2],[ko,v2,"visibleInLegend","visible",ss]);rs.current.register([N2,Qo,ts,d0,Qa,p0,Z8,Ml],{value:dn,color:u2,noteText:u2,errorLow:Nw,errorHigh:dn});rs.current.register([K8,Al,_l,f0],{from:Nw,to:dn,color:u2,noteText:u2});rs.current.register([X8,Dp,kl],{value:dn,color:u2});q1.current.register([lw,cw,Ql],[Ne,We],[v2,hs,dAt,fAt,vAt,gAt]);q1.current.register([Ql],[Ne,We,"size"],[v2,ko,hs]);q1.current.register([ow],[Ne,We,o2],[v2,hs]);q1.current.register([t6,e6],["open","high","low","close"],[ko,v2,"downColor",hs]);rs.current.register([t6,e6],{open:dn,high:dn,low:Nw,close:dn,color:u2,downColor:u2,noteText:u2});q1.current.register([Y8,Ll],["lower","q1","median","q3","upper","mean","outliers"],[ko,v2,hs,ss]);rs.current.register([Y8,Ll],{lower:dn,q1:dn,median:dn,q3:dn,upper:dn,mean:dn,outliers:u2,color:u2,noteText:u2});q1.current.register([u4,q8],["current","target"],[ko,v2,"visibleInLegend",hs,ss]);rs.current.register([u4,q8],{current:dn,target:dn,color:u2,noteText:u2});q1.current.register([p4,u9],[o2],[ko,v2,"explode","visibleInLegend","visible",ss]);var Em=[ko,o2,Ne,We],gEt="mousedown",N4="mousemove",AA="contextmenu",LA="mouseleave",EA="keydown",IA="focus",HA="blur",mEt=20,jp=function(t){function r(n,i,o,a){var s=this;a===void 0&&(a={}),t.call(this),this.observers=[],this.addObserver(a.observer),this.chartService=new Kl(this,a),this.chartService.theme=o,this._initElement(n);var l=St({},this.options,i);this._originalOptions=St({},l),this._theme=o,this._initTheme(l,o),this._focusState={},this._initHandlers(),this._initSurface(),this.bindCategories(),u0.preloadFonts(i,function(){s.fontLoaded=!0,s._destroyed||(s.trigger("init"),s._redraw(),s._attachEvents())})}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype._initElement=function(i){for(this._setElementClass(i),i.style.position="relative",i.tabIndex=i.getAttribute("tabindex")?i.getAttribute("tabindex"):0,i.setAttribute("role","graphics-document document");i.firstChild;)i.removeChild(i.firstChild);this.element=i},r.prototype._setElementClass=function(i){Dr(i,"k-chart")},r.prototype._initTheme=function(i,o){for(var a=[],s=i.series||[],l=0;l0||o.height>0;i||s&&(!a||o.width!==a.width||o.height!==a.height)?(this._size=o,this._resize(o,i),this.trigger("resize",o)):s&&this._selections&&sV(this._selections,function(l){return!l.visible})&&(this._destroySelections(),this._setupSelection())},r.prototype._resize=function(){this._noTransitionsRedraw()},r.prototype.redraw=function(i){if(this.applyDefaults(this.options),this.applySeriesColors(),i){var o=this._model._plotArea,a=o.findPane(i);o.redraw(a)}else this._redraw()},r.prototype.getAxis=function(i){return VV(i,this._plotArea.axes)},r.prototype.findAxisByName=function(i){return this.getAxis(i)},r.prototype.findPaneByName=function(i){for(var o=this._plotArea.panes,a=0;a=0){var f=this._plotArea.pointsByCategoryIndex(p);s.showAt(f)}}else h&&s.show(h)},r.prototype.hideTooltip=function(){this._tooltip.hide()},r.prototype._initSurface=function(){var i=this.surface,o=this._surfaceWrap(),a=this.options.chartArea||{};a.width&&Ha(o,{width:a.width}),a.height&&Ha(o,{height:a.height}),!i||i.options.type!==this.options.renderAs?(this._destroySurface(),this.surface=Gl.create(o,{type:this.options.renderAs}),this.surface.bind("mouseenter",this._surfaceMouseenterHandler),this.surface.bind("mouseleave",this._surfaceMouseleaveHandler)):(this.surface.clear(),this.surface.resize())},r.prototype._surfaceWrap=function(){return this.element},r.prototype._redraw=function(){var i=this._getModel();this._size={width:i.options.width,height:i.options.height},this._destroyView(),this._setElementAccessibilityAttributes(),this._model=i,this._plotArea=i._plotArea,this._legend=i._legend,i.renderVisual(),this.options.transitions!==!1&&i.traverse(function(o){o.animation&&o.animation.setup()}),this._initSurface(),this.surface.draw(i.visual),this.options.transitions!==!1&&i.traverse(function(o){o.animation&&o.animation.play()}),this._tooltip=this._createTooltip(),this._highlight=new bLt,this._setupSelection(),this._createPannable(),this._createZoomSelection(),this._createMousewheelZoom(),this.trigger(bAt),TA(this._plotArea.panes),this._navState||this._cancelDomEvents(),this._redrawFocusHighlight()},r.prototype._redrawFocusHighlight=function(){var i=this,o=i._focusState,a=o.legendInFocus,s=o.preserveHighlight;a&&s&&(this._focusElement(this._getFocusedLegendItem(),!1),this._focusState.preserveHighlight=!1)},r.prototype._setElementAccessibilityAttributes=function(){var i=this.options.title,o=$n(i)?i:i.description||i.text;o&&this.element.setAttribute("aria-roledescription",o)},r.prototype.exportVisual=function(i){var o;if(i&&(i.width||i.height||i.options)){var a=this.options,s=St({},i.options,{chartArea:{width:i.width,height:i.height}});Im(this._originalOptions,s),this.options=St({},this._originalOptions,s),this._initTheme(this.options,this._theme),this.bindCategories();var l=this._getModel();l.renderVisual(),TA(l._plotArea.panes),o=l.visual,this.options=a}else o=this.surface.exportVisual();return o},r.prototype._sharedTooltip=function(){return this._plotArea instanceof uo&&this.options.tooltip&&this.options.tooltip.shared},r.prototype._createPannable=function(){var i=this.options;i.pannable!==!1&&(this._pannable=new xF(this._plotArea,i.pannable))},r.prototype._createZoomSelection=function(){var i=this.options.zoomable,o=(i||{}).selection;i!==!1&&o!==!1&&(this._zoomSelection=new bF(this,o))},r.prototype._createMousewheelZoom=function(){var i=this.options.zoomable,o=(i||{}).mousewheel;i!==!1&&o!==!1&&(this._mousewheelZoom=new MLt(this,o))},r.prototype._toggleDragZoomEvents=function(){var i=this.options.pannable,o=this.options.zoomable,a=(o||{}).selection,s=(o||{}).mousewheel,l=!i&&(o===!1||a===!1)&&!this.requiresHandlers([yv,ac,sc]),h=(o===!1||s===!1)&&!this.requiresHandlers([N6,k3,_3]),p=this.element;this._dragZoomEnabled&&l&&h?(p.style.touchAction=this._touchAction||"",this._dragZoomEnabled=!1):!this._dragZoomEnabled&&!(l&&h)&&(p.style.touchAction="none",this._dragZoomEnabled=!0),this._toggleDomEvents(!l,!h)},r.prototype._toggleDomEvents=function(i,o){var a=this.domEvents;a&&(a.toggleDrag&&a.toggleDrag(i),a.toggleZoom&&a.toggleZoom(o))},r.prototype._createTooltip=function(){var i=this,o=i.options.tooltip,a;return this._sharedTooltip()?a=this._createSharedTooltip(o):a=new ELt(this.chartService,o),a},r.prototype._createSharedTooltip=function(i){return new Dw(this._plotArea,i)},r.prototype.applyDefaults=function(i,o){xEt(i,o),bEt(i,o)},r.prototype.applySeriesColors=function(){for(var i=this.options,o=i.series,a=i.seriesColors||[],s=0;s=0&&this.observers.splice(o,1)},r.prototype.requiresHandlers=function(i){for(var o=this.observers,a=0;a=.1){s=Math.round(s*10),this._gestureDistance=i.distance;var l={delta:s,axisRanges:$6(this._plotArea.axes),originalEvent:i};if(this._zooming||!this.trigger(N6,l)){var h=this._eventCoordinates(i);this._zooming||(this._zooming=!0);var p=l.axisRanges=o.updateRanges(s,h);p&&!this.trigger(k3,l)&&o.zoom()}}}},r.prototype._mouseout=function(i){if(i.element){var o=this._drawingChartElement(i.element,i);o&&o.leave&&o.leave(this,i.originalEvent)}},r.prototype._start=function(i){var o=this._eventCoordinates(i);this._stopChartHandlers(i)||!this._plotArea.backgroundContainsPoint(o)||(this.requiresHandlers([yv,ac,sc])&&this._startNavigation(i,o,yv),this._pannable&&this._pannable.start(i)&&(this.surface.suspendTracking(),this._unsetActivePoint(),this._clearFocusedElement(),this._suppressHover=!0,this.chartService.panning=!0),this._zoomSelection&&this._zoomSelection.start(i)&&this.trigger(N6,{axisRanges:$6(this._plotArea.axes),originalEvent:i}))},r.prototype._move=function(i){var o=this,a=o._navState,s=o._pannable;if(!this._stopChartHandlers(i)){if(s){var l=s.move(i);l&&!this.trigger(ac,{axisRanges:l,originalEvent:i})&&s.pan()}else if(a){for(var h={},p=a.axes,f=0;f1,a=this._hasInactiveOpacity();a?this._displayInactiveOpacity(i,o):this._highlight.show(i)},r.prototype._hideInactiveOpacity=function(i){var o=this._plotArea.series.length>1,a=this._hasInactiveOpacity();a&&(o&&this._activeChartInstance&&(this._updateSeriesOpacity(i,!0),this._applySeriesOpacity(this._activeChartInstance.children,null,!0),this._activeChartInstance=null),this._highlight&&this._highlight.hide(),this._activePoint=null)},r.prototype._hasInactiveOpacity=function(){var i=this.options.seriesDefaults.highlight.inactiveOpacity!==void 0,o=this.options.series.filter(function(a){return a.highlight.inactiveOpacity!==void 0}).length>0;return i||o},r.prototype._getInactiveOpacityForSeries=function(i){var o=this.options.seriesDefaults.highlight.inactiveOpacity,a=i.highlight.inactiveOpacity;return a||o||i.opacity||n_},r.prototype._getDefaultOpacityForSeries=function(i){return i.defaultOpacity||i.opacity||n_},r.prototype._mouseover=function(i){var o,a=this._startHover(i.element,i.originalEvent);a&&a.tooltipTracking&&!this._mouseMoveTrackHandler&&!this._sharedTooltip()&&(this._mouseMoveTrackHandler=this._mouseMoveTracking.bind(this),nc(document,(o={},o[N4]=this._mouseMoveTrackHandler,o)))},r.prototype._mouseMoveTracking=function(i){var o,a=this,s=a.options,l=a._tooltip,h=a._highlight,p=a._activePoint,f=this._eventCoordinates(i);if(this._plotArea.box.containsPoint(f)){if(p&&p.tooltipTracking&&p.series&&p.parent.getNearestPoint){var g=p.parent.getNearestPoint(f.x,f.y,p.seriesIx);if(g&&g!==p&&(this._activePoint=g,!g.hover(this,i))){var b=St({},s.tooltip,g.options.tooltip);b.visible&&l.show(g),h.show(g)}}}else oc(document,(o={},o[N4]=this._mouseMoveTrackHandler,o)),this._unsetActivePoint(),this._clearFocusedElement(),this._mouseMoveTrackHandler=null,this._hideInactiveOpacity(p)},r.prototype._mousemove=function(i){var o=this._eventCoordinates(i),a=this._plotArea;if(this._trackCrosshairs(o),a.hover){var s=a.backgroundContainsPoint(o);s?(this._plotAreaHovered=!0,this._plotArea.hover(this,i)):this._plotAreaHovered&&!s&&(this._plotAreaHovered=!1,this.trigger(mv))}this._sharedTooltip()&&this._trackSharedTooltip(o,i)},r.prototype._trackCrosshairs=function(i){for(var o=this._plotArea.crosshairs,a=0;a0&&!this.trigger(WV,I)?(l.visible&&f.showAt(z,i),g.show(z),this._sharedHighlight=!0):f.hide(),this._tooltipCategoryIx=b}else a&&this._sharedHighlight&&(g.hide(),f.hide(),this._sharedHighlight=!1)}else this._sharedHighlight&&(g.hide(),f.hide(),this._tooltipCategoryIx=null,this._sharedHighlight=!1)}},r.prototype.hideElements=function(i){var o=this._plotArea;this._mousemove.cancel(),o.hideCrosshairs(),this._unsetActivePoint(i)},r.prototype._unsetActivePoint=function(i){var o=this,a=o._highlight;this._activePoint=null,this._hoveredPoint=null,(!i||!i.keepTooltipOpen)&&this._hideTooltip(),this._tooltipCategoryIx=null,this._sharedHighlight=!1,a&&a.hide()},r.prototype._deferRedraw=function(){this._redraw()},r.prototype._clearRedrawTimeout=function(){this._redrawTimeout&&(clearInterval(this._redrawTimeout),this._redrawTimeout=null)},r.prototype.bindCategories=function(){for(var i=this,o=this.options,a=[].concat(o.categoryAxis),s=0;s0}),f=p.map(function(M){return q1.current.bindPoint(M,0).fields.category}),g=f.reduce(function(M,I){return M||QV(i,I)},!1),b=p.filter(function(M,I){return M.categoryField||ie(f[I])});if(b.forEach(function(M){return M.data.forEach(function(I,F){var H=q1.current.bindPoint(M,F).fields.category;if(g){var E=JV(H,I,a.chartService.intl);H=E?E.getTime():void 0}s.add(H)})}),s.size>0){var z=Array.from(s.values());g&&(z=z.sort().map(function(M){return M&&new Date(M)})),i.categories=z}else h&&(i.categories=[])},r.prototype._isBindable=function(i){for(var o=q1.current.valueFields(i),a=!0,s=0;s1,g=p.length?p[0]:p;this._displayInactiveOpacity(g,f,p)}else l.show(p)},r.prototype._shouldAttachMouseMove=function(){return this._plotArea.crosshairs.length||this._tooltip&&this._sharedTooltip()||this.requiresHandlers([UV,mv])},r.prototype.updateMouseMoveHandler=function(){var i,o;oc(this.element,(i={},i[N4]=this._mousemove,i)),this._shouldAttachMouseMove()&&nc(this.element,(o={},o[N4]=this._mousemove,o))},r.prototype.applyOptions=function(i,o){Im(this._originalOptions,i),this._originalOptions=St(this._originalOptions,i),this.options=St({},this._originalOptions),o&&(this._theme=o,this.chartService.theme=o),this._initTheme(this.options,this._theme),this._toggleDragZoomEvents()},r.prototype.setOptions=function(i,o){this.applyOptions(i,o),this.bindCategories(),this.redraw(),this.updateMouseMoveHandler()},r.prototype.setDirection=function(i){this.chartService.rtl=!!i,this.surface&&this.surface.type==="svg"&&this._destroySurface()},r.prototype.setIntlService=function(i){this.chartService.intl=i},r.prototype.noTransitionsRedraw=function(){this._noTransitionsRedraw()},r.prototype.destroy=function(){var i,o;this._destroyed=!0,oc(this.element,(i={},i[AA]=this._clickHandler,i[v9]=this._mousewheelHandler,i[N4]=this._mousemove,i[LA]=this._mouseleaveHandler,i[EA]=this._keydownHandler,i[IA]=this._focusHandler,i[HA]=this._blurHandler,i)),this.domEvents&&(this.domEvents.destroy(),delete this.domEvents),this._mouseMoveTrackHandler&&oc(document,(o={},o[N4]=this._mouseMoveTrackHandler,o)),this._focusState=null,this._destroyView(),this._destroySurface(),this._clearRedrawTimeout()},r.prototype._destroySurface=function(){var i=this.surface;i&&(i.unbind("mouseenter",this._surfaceMouseenterHandler),i.unbind("mouseleave",this._surfaceMouseleaveHandler),i.destroy(),this.surface=null)},r.prototype._destroySelections=function(){var i=this._selections;if(i)for(;i.length>0;)i.shift().destroy()},r.prototype._destroyView=function(){var i=this._model;i&&(i.destroy(),this._model=null),this._unsetActivePoint(),this._clearFocusedElement(),this._resetDrilldownPoint(),this._destroySelections(),this._tooltip&&this._tooltip.destroy(),this._highlight&&this._highlight.destroy(),this._zoomSelection&&(this._zoomSelection.destroy(),delete this._zoomSelection),this._pannable&&(this._pannable.destroy(),delete this._pannable),this._mousewheelZoom&&(this._mousewheelZoom.destroy(),delete this._mousewheelZoom)},r}(Fe);function yEt(t){for(var r=Em,n=0;n1?a:a[0]}function bEt(t,r){var n=t.series,i=n.length,o=t.seriesDefaults,a=St({},t.seriesDefaults),s=r?St({},r.seriesDefaults):{},l=St({},s);PA(a),PA(l);for(var h=0;h0&&(M+=a.left+a.right),M},r.prototype._createSharedTooltip=function(i){return new SEt(this._plotArea,i)},r.normalizeOptions=function(i){var o=OA(i);return Mi(o)?o={seriesDefaults:{data:o}}:o=St({},o),o.series||(o.series=[{data:OA(o.data)}]),St(o,{seriesDefaults:{type:o.type}}),(u1(o.series[0].type,VA)||u1(o.seriesDefaults.type,VA))&&(o=St({},{categoryAxis:{crosshair:{visible:!1}}},o)),o},r}(jp);de(kEt,{chartArea:{margin:2},axisDefaults:{visible:!1,majorGridLines:{visible:!1},valueAxis:{narrowRange:!0}},seriesDefaults:{type:"line",area:{line:{width:.5}},bar:{stack:!0},padding:2,width:.5,overlay:{gradient:null},highlight:{visible:!1},border:{width:0},markers:{size:2,visible:!1}},tooltip:{visible:!0,shared:!0},categoryAxis:{crosshair:{visible:!0,tooltip:{visible:!1}}},legend:{visible:!1},transitions:!1,pointWidth:5,panes:[{clip:!1}]});var _Et=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.setup=function(){this._initialOpacity=parseFloat(wr(this.element,"opacity").opacity)},r.prototype.step=function(i){wr(this.element,{opacity:String(F2(this._initialOpacity,0,i))})},r.prototype.abort=function(){t.prototype.abort.call(this),wr(this.element,{display:"none",opacity:String(this._initialOpacity)})},r.prototype.cancel=function(){t.prototype.abort.call(this),wr(this.element,{opacity:String(this._initialOpacity)})},r}(K2);function Cv(t,r){var n=document.createElement("div");return n.className=t,r&&(n.style.cssText=r),n}var FF=function(t){function r(n,i,o){t.call(this),this.options=St({},this.options,o),this.container=n,this.chartService=i;var a=wr(n,["paddingLeft","paddingTop"]);this.chartPadding={top:a.paddingTop,left:a.paddingLeft},this.createElements(),n.appendChild(this.element)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.createElements=function(){var i=this.element=Cv("k-navigator-hint","display: none; position: absolute; top: 1px; left: 1px;"),o=this.tooltip=Cv("k-tooltip k-chart-tooltip"),a=this.scroll=Cv("k-scroll");o.innerHTML=" ",i.appendChild(o),i.appendChild(a)},r.prototype.show=function(i,o,a){var s=this,l=s.element,h=s.options,p=s.scroll,f=s.tooltip,g=Q1(tr(i)+tr(o-i)/2),b=a.width()*.4,z=a.center().x-b,M=a.center().x,I=M-z,F=h.max-h.min,H=I/F,E=g-h.min,R=this.chartService.intl.format(h.format,i,o),W=fi(h);this.clearHideTimeout(),this._visible||(wr(l,{visibility:"hidden",display:"block"}),this._visible=!0),W&&(R=W({from:i,to:o})),f.innerHTML=R,wr(f,{left:a.center().x-f.offsetWidth/2,top:a.y1});var $=wr(f,["marginTop","borderTopWidth","height"]);wr(p,{width:b,left:z+E*H,top:a.y1+$.marginTop+$.borderTopWidth+$.height/2}),wr(l,{visibility:"visible"})},r.prototype.clearHideTimeout=function(){this._hideTimeout&&clearTimeout(this._hideTimeout),this._hideAnimation&&this._hideAnimation.cancel()},r.prototype.hide=function(){var i=this;this.clearHideTimeout(),this._hideTimeout=setTimeout(function(){i._visible=!1,i._hideAnimation=new _Et(i.element),i._hideAnimation.setup(),i._hideAnimation.play()},this.options.hideDelay)},r.prototype.destroy=function(){this.clearHideTimeout(),this.container&&this.container.removeChild(this.element),delete this.container,delete this.chartService,delete this.element,delete this.tooltip,delete this.scroll},r}(Fe);de(FF,{format:"{0:d} - {1:d}",hideDelay:500});var Ta="_navigator",Ma=Ta,BA="_default",AEt=3,NA=function(t){function r(n){var i;t.call(this),this.chart=n;var o=this.options=St({},this.options,n.options.navigator),a=o.select;a&&(a.from=this.parseDate(a.from),a.to=this.parseDate(a.to)),ie(o.hint.visible)||(o.hint.visible=o.visible),this.chartObserver=new yo(this,(i={},i[ac]="_drag",i[sc]="_dragEnd",i[k3]="_zoom",i[_3]="_zoomEnd",i)),n.addObserver(this.chartObserver)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.parseDate=function(i){return Si(this.chart.chartService.intl,i)},r.prototype.clean=function(){this.selection&&(this.selection.destroy(),this.selection=null),this.hint&&(this.hint.destroy(),this.hint=null)},r.prototype.destroy=function(){this.chart&&(this.chart.removeObserver(this.chartObserver),delete this.chart),this.clean()},r.prototype.redraw=function(){this._redrawSelf(),this.initSelection()},r.prototype.initSelection=function(){var i=this,o=i.chart,a=i.options,s=this.mainAxis(),l=s.roundedRange(),h=l.min,p=l.max,f=a.select,g=f.from,b=f.to,z=f.mousewheel,M=LEt(s);s.categoriesCount()!==0&&(this.clean(),M.box=s.box,this.selection=new Hw(o,M,{min:h,max:p,from:g||h,to:b||p,mousewheel:t1(z,{zoom:"left"}),visible:a.visible},new yo(this,{selectStart:"_selectStart",select:"_select",selectEnd:"_selectEnd"})),a.hint.visible&&(this.hint=new FF(o.element,o.chartService,{min:h,max:p,template:fi(a.hint),format:a.hint.format})))},r.prototype.setRange=function(){var i=this.chart._createPlotArea(!0),o=i.namedCategoryAxes[Ma],a=o.roundedRange(),s=a.min,l=a.max,h=this.options.select||{},p=h.from||s;pl&&(f=l),this.options.select=St({},h,{from:p,to:f}),this.filterAxes()},r.prototype._redrawSelf=function(i){var o=this.chart._plotArea;o&&o.redraw(Vr(o.panes),i)},r.prototype.redrawSlaves=function(){var i=this.chart,o=i._plotArea,a=o.panes.filter(function(s){return s.options.name!==Ta});o.srcSeries=i.options.series,o.options.categoryAxis=i.options.categoryAxis,o.clearSeriesPointsCache(),o.redraw(a)},r.prototype._drag=function(i){var o=this,a=o.chart,s=o.selection,l=a._eventCoordinates(i.originalEvent),h=this.mainAxis(),p=h.roundedRange(),f=h.pane.box.containsPoint(l),g=a._plotArea.categoryAxis,b=i.axisRanges[g.options.name],z=this.options.select,M;if(!(!b||f||!s)){z.from&&z.to?M=tr(z.to)-tr(z.from):M=tr(s.options.to)-tr(s.options.from);var I=Q1(Xe(tr(b.min),p.min,tr(p.max)-M)),F=Q1(Xe(tr(I)+M,tr(p.min)+M,p.max));this.options.select={from:I,to:F},this.options.liveDrag&&(this.filterAxes(),this.redrawSlaves()),s.set(I,F),this.showHint(I,F)}},r.prototype._dragEnd=function(){this.filterAxes(),this.filter(),this.redrawSlaves(),this.hint&&this.hint.hide()},r.prototype.readSelection=function(){var i=this,o=i.selection.options,a=o.from,s=o.to,l=i.options.select;l.from=a,l.to=s},r.prototype.filterAxes=function(){var i=this,o=i.options.select;o===void 0&&(o={});for(var a=i.chart,s=a.options.categoryAxis,l=o.from,h=o.to,p=0;p1&&(g*=AEt),z-b>1?(s.zoom(g,M),this.readSelection()):(a.options.min=h.from,h.from=a.scaleRange(-i.delta*this.chart._mousewheelZoomRate(),M).min),p&&(this.filterAxes(),this.redrawSlaves()),s.set(h.from,h.to),this.showHint(this.options.select.from,this.options.select.to)}},r.prototype._zoomEnd=function(i){this._dragEnd(i)},r.prototype.showHint=function(i,o){var a=this.chart._plotArea;this.hint&&this.hint.show(i,o,a.backgroundBox())},r.prototype._selectStart=function(i){return this.chart._selectStart(i)},r.prototype._select=function(i){return this.showHint(i.from,i.to),this.chart._select(i)},r.prototype._selectEnd=function(i){return this.hint&&this.hint.hide(),this.readSelection(),this.filterAxes(),this.filter(),this.redrawSlaves(),this.chart._selectEnd(i)},r.prototype.mainAxis=function(){var i=this.chart._plotArea;if(i)return i.namedCategoryAxes[Ma]},r.prototype.select=function(i,o){var a=this.options.select;return i&&o&&(a.from=this.parseDate(i),a.to=this.parseDate(o),this.filterAxes(),this.filter(),this.redrawSlaves(),this.selection.set(i,o)),{from:a.from,to:a.to}},r.setup=function(i,o){if(i===void 0&&(i={}),o===void 0&&(o={}),!i.__navi){i.__navi=!0;var a=St({},o.navigator,i.navigator),s=i.panes=[].concat(i.panes),l=St({},a.pane,{name:Ta});a.visible||(l.visible=!1,l.height=.1),i.navigator.position!=="top"?s.push(l):s.unshift(l),s.forEach(function(h){h.name=h.name||BA}),r.attachAxes(i,a),r.attachSeries(i,a,o)}},r.attachAxes=function(i,o){var a=o.series||[],s=i.categoryAxis=[].concat(i.categoryAxis),l=i.valueAxis=[].concat(i.valueAxis),h=s.concat(l);h.forEach(function(z){z.pane=z.pane||BA});var p=Cr(a,BV),f=p.length===0,g=St({type:"date",pane:Ta,roundToBaseUnit:!f,justified:f,_collapse:!1,majorTicks:{visible:!0},tooltip:{visible:!1},labels:{step:1},autoBind:o.autoBindElements,autoBaseUnitSteps:{minutes:[1],hours:[1,2],days:[1,2],weeks:[],months:[1],years:[1]}}),b=o.categoryAxis;s.push(St({},g,{maxDateGroups:200},b,{name:Ma,title:null,baseUnit:"fit",baseUnitStep:"auto",labels:{visible:!1},majorTicks:{visible:!1}}),St({},g,b,{name:Ma+"_labels",maxDateGroups:20,baseUnitStep:"auto",labels:{position:""},plotBands:[],autoBaseUnitSteps:{minutes:[]},_overlap:!0}),St({},g,b,{name:Ma+"_ticks",maxDateGroups:200,majorTicks:{width:.5},plotBands:[],title:null,labels:{visible:!1,mirror:!0},_overlap:!0})),l.push(St({name:Ma,pane:Ta,majorGridLines:{visible:!1},visible:!1},o.valueAxis))},r.attachSeries=function(i,o,a){for(var s=i.series=i.series||[],l=[].concat(o.series||[]),h=a.seriesColors,p=o.seriesDefaults,f=0;f0&&(s=jA(s,a.width));var l=VEt.fromRect(s,{stroke:{color:a.width?a.color:"",width:a.width,opacity:a.opacity,dashType:a.dashType,lineJoin:"round",lineCap:"round"},fill:{color:i.background}});return l},r.prototype._initSurface=function(){var i=this,o=i.options,a=i.surface,s=this._surfaceElement(),l=this._surfaceSize();Ha(s,l),!a||a.options.type!==o.renderAs?(a&&a.destroy(),this.surface=FEt.create(s,{type:o.renderAs})):(this.surface.clear(),this.surface.resize())},r.prototype._surfaceSize=function(){var i=this.options,o=this._getSize();return i.gaugeArea&&St(o,i.gaugeArea),o},r.prototype._surfaceElement=function(){return this.surfaceElement||(this.surfaceElement=document.createElement("div"),this.element.appendChild(this.surfaceElement)),this.surfaceElement},r.prototype.getSize=function(){return this._getSize()},r.prototype._getSize=function(){var i=this.element,o=this._defaultSize(),a=i.offsetWidth,s=i.offsetHeight;return a||(a=o.width),s||(s=o.height),{width:a,height:s}},r.prototype._defaultSize=function(){return{width:NF,height:BF}},r.prototype._toggleTransitions=function(i){var o=this;this.options.transitions=i;for(var a=0;a0&&i.visible){var s=new Hm({stroke:{color:i.color,dashType:i.dashType,width:i.width}});s.moveTo(o.x1,o.y1).lineTo(o.x2,o.y2),a.append(s)}return a},r.prototype.renderTicks=function(){var i=new W6,o=this.options,a=o.majorTicks.visible?o.majorUnit:0,s={vertical:o.vertical,mirror:o.labels.mirror,lineBox:this.lineBox()};return GA(i,this.getMajorTickPositions(),s,o.majorTicks),GA(i,this.getMinorTickPositions(),s,St({},{skipUnit:a/o.minorUnit},o.minorTicks)),i},r}(O2);de(XF,{min:0,max:50,majorTicks:{size:15,align:e4,color:Ar,width:sl,visible:!0},minorTicks:{size:10,align:e4,color:Ar,width:sl,visible:!0},line:{width:sl},labels:{position:e4,padding:2},mirror:!1,_alignLines:!1});var Up=function(t){function r(n,i){t.call(this);var o=n.options,a=o.min,s=o.max,l=this.options=St({},this.options,i);l.fill=l.color,this.scale=n,ie(l.value)?l.value=Xe(l.value,a,s):l.value=a}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.value=function(i){var o=this.options,a=o.value;if(arguments.length===0)return a;var s=this.scale.options,l=s.min,h=s.max;o._oldValue=ie(o._oldValue)?o.value:l,o.value=Xe(i,l,h),this.elements&&this.repaint()},r}(Fe);de(Up,{color:Ar});var Ww=function(t){function r(n,i){t.call(this,n,i),this.options=St({track:{visible:ie(i.track)}},this.options)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.reflow=function(){var i=this,o=i.options,a=i.scale,s=a.options,l=s.mirror,h=s.vertical,p=a.lineBox(),f=o.track.size||o.size,g=o.size/2,b=F1(o.margin),z=h?b[l?"left":"right"]:b[l?"bottom":"top"],M,I,F;z=l?-z:z,h?(F=new Ce(p.x1+z,p.y1,p.x1+z,p.y2),l?F.x1-=f:F.x2+=f,o.shape!==m8&&(I=new Ce(p.x2+z,p.y1-g,p.x2+z,p.y2+g),M=I)):(F=new Ce(p.x1,p.y1-z,p.x2,p.y1-z),l?F.y2+=f:F.y1-=f,o.shape!==m8&&(I=new Ce(p.x1-g,p.y1-z,p.x2+g,p.y1-z),M=I)),this.trackBox=F,this.pointerRangeBox=I,this.box=M||F.clone().pad(o.border.width)},r.prototype.getElementOptions=function(){var i=this.options;return{fill:{color:i.color,opacity:i.opacity},stroke:ie(i.border)?{color:i.border.width?i.border.color||i.color:"",width:i.border.width,dashType:i.border.dashType,opacity:i.opacity}:null}},r.prototype._margin=function(){var i=this,o=i.scale,a=i.options,s=o.options,l=s.mirror,h=s.vertical,p=F1(a.margin),f=h?p[l?"left":"right"]:p[l?"bottom":"top"];return f},r}(Up);de(Ww,{shape:m8,track:{border:{width:1}},color:Ar,border:{width:1},opacity:1,margin:F1(3),animation:{type:m8},visible:!0});var jw=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.setup=function(){var i=this.options,o=i.margin,a=i.from,s=i.to,l=i.vertical,h=l?"x1":"y1";i.mirror===l?(a[h]-=o,s[h]-=o):(a[h]+=o,s[h]+=o);var p=this.fromScale=new ye(a.x1,a.y1),f=this.toScale=new ye(s.x1,s.y1);i.duration!==0&&(i.duration=Math.max(p.distanceTo(f)/i.duration*1e3,1))},r.prototype.step=function(i){var o=F2(this.fromScale.x,this.toScale.x,i),a=F2(this.fromScale.y,this.toScale.y,i);this.element.transform(ar().translate(o,a))},r}(K2);de(jw,{easing:Gp,duration:RF});oa.current.register(OF,jw);var f3=ye,OEt=$e,BEt=function(t){function r(n,i){t.call(this,n,i),ie(this.options.size)||(this.options.size=this.scale.options.majorTicks.size*.6)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.pointerShape=function(){var i=this,o=i.scale,a=i.options.size,s=a/2,l=o.options.mirror?-1:1,h;return o.options.vertical?h=[new f3(0,0-s),new f3(0-l*a,0),new f3(0,0+s)]:h=[new f3(0-s,0),new f3(0,0+l*a),new f3(0+s,0)],h},r.prototype.repaint=function(){var i=this,o=i.scale,a=i.options,s=new jw(this.elements,St(a.animation,{vertical:o.options.vertical,mirror:o.options.mirror,margin:this._margin(a.margin),from:o.getSlot(a._oldValue),to:o.getSlot(a.value)}));a.animation.transitions===!1&&(s.options.duration=0),s.setup(),s.play()},r.prototype.render=function(){var i=this,o=i.scale,a=i.options,s=this.getElementOptions(),l=this.pointerShape(a.value);a.animation.type=OF;var h=new OEt({stroke:s.stroke,fill:s.fill}).moveTo(l[0]).lineTo(l[1]).lineTo(l[2]).close(),p=o.getSlot(a.value);return h.transform(ar().translate(p.x1,p.y1)),this.elements=h,h},r}(Ww),Gw=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.setup=function(){var i=this.options,o=this.axis=i.vertical?We:Ne,a=this.to=i.newPoints[0][o],s=this.from=i.oldPoints[0][o];i.duration!==0&&(i.duration=Math.max(Math.abs(a-s)/i.speed*1e3,1)),this._set(s)},r.prototype.step=function(i){var o=F2(this.from,this.to,i);this._set(o)},r.prototype._set=function(i){var o="set"+this.axis.toUpperCase(),a=this.options.newPoints;a[0][o](i),a[1][o](i)},r}(K2);de(Gw,{easing:Gp,speed:RF});oa.current.register(m8,Gw);var NEt=P1,UA=$e,$Et=function(t){function r(n,i){t.call(this,n,i),ie(this.options.size)||(this.options.size=this.scale.options.majorTicks.size*.3)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.pointerShape=function(i){var o=this,a=o.scale,s=o.options,l=a.options,h=l.mirror,p=l.vertical,f=h===p?-1:1,g=s.size*f,b=a.getSlot(a.options.min),z=a.getSlot(i),M=p?We:Ne,I=p?Ne:We,F=this._margin()*f,H=new ye;H[M]=b[M+"1"],H[I]=b[I+"1"];var E=new ye;E[M]=z[M+"1"],E[I]=z[I+"1"],p?(H.translate(F,0),E.translate(F,0)):(H.translate(0,F),E.translate(0,F));var R=E.clone(),W=H.clone();return p?(R.translate(g,0),W.translate(g,0)):(R.translate(0,g),W.translate(0,g)),[H,E,R,W]},r.prototype.repaint=function(){var i=this,o=i.scale,a=i.options,s=this.pointerShape(a.value),l=this.pointerPath,h=this.pointerShape(a._oldValue);l.moveTo(s[0]).lineTo(s[1]).lineTo(s[2]).lineTo(s[3]).close();var p=new Gw(l,St(a.animation,{reverse:o.options.reverse,vertical:o.options.vertical,oldPoints:[h[1],h[2]],newPoints:[s[1],s[2]]}));a.animation.transitions===!1&&(p.options.duration=0),p.setup(),p.play()},r.prototype.render=function(){var i=new NEt,o=this.getElementOptions();this.options.track.visible&&i.append(this.renderTrack());var a=this.pointerPath=new UA({stroke:o.stroke,fill:o.fill});return i.append(a),this.elements=i,i},r.prototype.renderTrack=function(){var i=this.options.track,o=i.border||{},a=this.trackBox.clone().pad(o.width||0);return new UA.fromRect(a.toRect(),{fill:{color:i.color,opacity:i.opacity},stroke:{color:o.width?o.color||i.color:"",width:o.width,dashType:o.dashType}})},r}(Ww),WEt=60,jEt=60,GEt=P1,UEt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.reflow=function(i){var o=this.pointers,a=i.origin.x,s=i.origin.y,l=new Ce(a,s,a+i.width(),s+i.height());this.scale.reflow(l),this._shrinkScaleWidth(l);for(var h=0;h0&&(a.box.shrink(s,0),a.box.alignTo(i,"center"),a.reflow(a.box))}},r.prototype._shrinkElements=function(){for(var i=this,o=this,a=o.scale,s=o.pointers,l=a.box.clone(),h=a.options.vertical?"y":"x",p=s[0].box,f=0;f=360&&o.max%o.majorUnit===0&&(i-=1),i},r.prototype.renderLabels=function(){var i=this,o=this.options,a=this.arc.clone(),s=a.getRadiusX(),l=this.tickAngles(a,o.majorUnit),h=o.rangeSize=o.rangeSize||s*.1,p=new A7,f=s*.05;ie(o.rangeDistance)?f=o.rangeDistance:o.rangeDistance=f;var g=o.labels,b=g.position===e4,z=ie(this.labelElements);b&&(s-=this.ticksSize(),this.hasRanges()&&!z&&(s-=h+f),a.setRadiusX(s).setRadiusY(s));for(var M=this.labels,I=M.length,F=F1(g.padding),H=(F.left+F.right)/2,E=(F.top+F.bottom)/2,R=0;R0){var o=this.options,a=o.rangeDistance,s=o.rangeSize,l=this.getRangeRadius();this.options.labels.position===e4&&(l+=s+a);for(var h=l+s/2,p=0;p=0;s--)s%a===0&&i.splice(s,1);return i},r.prototype.tickAngles=function(i,o){var a=this.options,s=a.reverse,l=a.max-a.min,h=i.endAngle-i.startAngle,p=l/o,f=i.startAngle,g=h/p;s&&(f+=h,g=-g),h>=360&&a.max%o===0&&(p-=1);for(var b=[],z=0;z5||h!==z&&(f=o.getPlotBox(h,i,a),0<=f&&f<=2)||p!==z&&(b=o.getPlotBox(p,i,a),0<=b&&b<=2)||(f>0&&b>0?z=h*2:f<0&&b<0?z=p*2:z=Ae((h+p)/2||1,di),g=o.getPlotBox(z,i,a),0<=g&&g<=2)));)M=b,g>0?(p=z,b=g):(h=z,f=g)},r.prototype.getPlotBox=function(i,o,a){var s=this,l=this.scale,h=this.pointers,p=a.getRadiusX(),f=a.clone();f.setRadiusX(p+i).setRadiusY(p+i),l.arc=f,l.reflow(o),this.plotBbox=l.bbox;for(var g=0;ga.width&&(l-=p-a.width)}if(og&&(h-=b-g)}return{left:l,top:h}},r}(qF),rIt=90;(function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype._createModel=function(){var i=this.options.scale;typeof i.startAngle!="number"&&(i.startAngle=rIt),i.endAngle=i.startAngle+360,t.prototype._createModel.call(this)},r})(eIt);var QF=10,U0=function(t){function r(n){t.call(this),this.setOptions(n),this.initProperties()}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.initProperties=function(){},r.prototype.setOptions=function(i){this.options=Object.assign({},this.options,i),this.quietZoneLength=this.options.addQuietZone?2*this.options.quietZoneLength:0},r.prototype.encode=function(i,o,a){var s=ie(i)?String(i):i;return this.initValue(s,o,a),this.options.addQuietZone&&this.addQuietZone(),this.addData(),this.options.addQuietZone&&this.addQuietZone(),{baseUnit:this.baseUnit,pattern:this.pattern}},r.prototype.initValue=function(){},r.prototype.addQuietZone=function(){this.pattern.push(this.options.quietZoneLength||QF)},r.prototype.addData=function(){},r.prototype.invalidCharacterError=function(i){throw new Error('Character "'+i+'" is not valid for symbology '+this.name+".")},r}(Fe);de(U0,{quietZoneLength:QF,addQuietZone:!0,addCheckSum:!0});var iIt=Object.assign,tR=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.initProperties=function(){t.prototype.initProperties.call(this),iIt(this,{name:"Code 11",characterMap:["111121","211121","121121","221111","112121","212111","122111","111221","211211","211111","112111"],cCheckSumTotal:10,kCheckSumTotal:9,kCheckSumMinLength:10,checkSumMod:11,DASH_VALUE:10,DASH:"-",START:"112211",STOP:"11221"})},r.prototype.initValue=function(i,o){this.pattern=[],this.value=i,this.width=o,this.totalUnits=0},r.prototype.addData=function(){var i=this,o=this.value;this.addPattern(this.START);for(var a=0;a=this.kCheckSumMinLength){var s=(a+this.getWeightedSum(i,o,this.kCheckSumTotal))%this.checkSumMod;this.checksum+=s,this.addPattern(this.characterMap[s])}},r.prototype.getWeightedSum=function(i,o,a){for(var s=this,l=0,h=0;ha;)h=parseFloat((h-.1).toFixed(1)),l=i.getBaseUnit(h);if(l127?this.invalidCharacterError(r):this.addExtended(r.charCodeAt(0))},addExtended:function(r){for(var n=this,i,o=0;o=0;p--)s+=i.weightedValue(o[p],a-p,i.cCheckSumTotal);for(l=s%this.checkSumMod,s=this.weightedValue(l,1,this.kCheckSumTotal),p=a-1;p>=0;p--)s+=i.weightedValue(o[p],a-p+1,i.kCheckSumTotal);return h=s%this.checkSumMod,[l,h]},r.prototype._findCharacterByValue=function(i){var o=this;for(var a in o.characterMap)if(o.characterMap[a].value===i)return a},r.prototype.weightedValue=function(i,o,a){return(o%a||a)*i},r.prototype.addPattern=function(i){for(var o=this,a,s=0;s=0&&this.isCode(h)&&i.index=i.value.length||this.encoding[this.shiftKey].is(i.value,i.index+1)))return this.encoding.addPattern(this.SHIFT),i.shifted=!0,!0},r.prototype._moveState=function(){return this.encoding.addPattern(this.MOVE),!0},r}(Yp),l6={};l6.A=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.initProperties=function(){t.prototype.initProperties.call(this),Ao(this,{key:"A",shiftKey:"B",MOVE:101,START:103})},r.prototype.isCode=function(i){return 0<=i&&i<96},r.prototype.getValue=function(i){return i<32?i+64:i-32},r}(oR);l6.B=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.initProperties=function(){t.prototype.initProperties.call(this),Ao(this,{key:"B",shiftKey:"A",MOVE:100,START:104})},r.prototype.isCode=function(i){return 32<=i&&i<128},r.prototype.getValue=function(i){return i-32},r}(oR);l6.C=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.initProperties=function(){t.prototype.initProperties.call(this),Ao(this,{key:"C",MOVE:99,START:105})},r.prototype.addStart=function(){this.encoding.addPattern(this.START)},r.prototype.is=function(i,o){var a=Pm(i,o,4);return(o+4<=i.length||i.length===2)&&Dm.test(a)},r.prototype.move=function(){this.encoding.addPattern(this.MOVE)},r.prototype.pushState=function(i){for(var o=this,a;(a=Pm(i.value,i.index,2))&&Dm.test(a)&&a.length===2;)o.encoding.addPattern(parseInt(a,10)),i.index+=2},r.prototype.getValue=function(i){return i},r}(Yp);l6.FNC4=function(t){function r(n,i){t.call(this,n),this._initSubStates(i)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.initProperties=function(){t.prototype.initProperties.call(this),Ao(this,{key:"FNC4",dependentStates:["A","B"]})},r.prototype.addStart=function(i){var o=i.value.charCodeAt(0)-128,a=this._getSubState(o);this.encoding[a].addStart()},r.prototype.is=function(i,o){var a=i.charCodeAt(o);return this.isCode(a)},r.prototype.isCode=function(i){return 128<=i&&i<256},r.prototype.pushState=function(i){var o=this,a=this._initSubState(i),s=this.encoding,l=a.value.length,h;if(i.index+=l,l<3)for(;a.index0?o.getBySeparator(s,h):o.getByLength(s,h),f.ai.length)g=h+b+f.id.length+f.ai.length;else if(g=s.indexOf(o.startAI,h+1),g<0){if(h+f.ai.max+f.id.length+b=s.length)break;h=g,p.state!==o.startState&&(a[o.startState].move(p),p.state=o.startState),f.ai.length||a.addPattern(o.START)}i.index=i.value.length},r.prototype.validate=function(i,o){var a=o.substr(i.id.length),s=i.ai;if(!s.type&&!Dm.test(a))throw new Error("Application identifier "+i.id+" is numeric only but contains non numeric character(s).");if(s.type==="alphanumeric"&&!hIt.test(a))throw new Error("Application identifier "+i.id+" is alphanumeric only but contains non alphanumeric character(s).");if(s.length&&s.length!==a.length)throw new Error("Application identifier "+i.id+" must be "+s.length+" characters long.");if(s.min&&s.min>a.length)throw new Error("Application identifier "+i.id+" must be at least "+s.min+" characters long.");if(s.max&&s.max=i.value.length));)if(!i.shifted)i.previousState=i.state,i.state=a.getNextState(i,o),a[i.state].move(i);else{var l=i.state;i.state=i.previousState,i.previousState=l,i.shifted=!1}},r.prototype.addStart=function(i){this[i.state].addStart(i),this.position=1},r.prototype.addCheckSum=function(){this.checksum=this.checkSum%103,this.addPattern(this.checksum)},r.prototype.addStop=function(){this.addPattern(this.STOP)},r.prototype.setBaseUnit=function(){this.baseUnit=this.width/(this.totalUnits+this.quietZoneLength)},r.prototype.addPattern=function(i){for(var o=this,a=this.characterMap[i].toString(),s,l=0;l0&&(a.width=o.width),o.height>0&&(a.height=o.height),this.options.width&&(a.width=this.options.width),this.options.height&&(a.height=this.options.height),a},r.prototype.value=function(i){if(!ie(i))return this.options.value;this.options.value=String(i),this.redraw()},r.prototype._getBands=function(i,o){for(var a=this,s=this.contentBox,l=s.x1,h,p,f=new P1,g=0;g=i.matrix.length)&&(i.dir=-i.dir,i.startColumn-=i.startColumn!==8?2:3,i.column=i.startColumn,i.row=i.dir<0?i.matrix.length-1:0);return{row:this.row,column:this.column}},r.prototype.getNextRemainderCell=function(){if(this.move(),this.matrix[this.row][this.column]===void 0)return{row:this.row,column:this.column}},r}(Fe),cR=function(t){function r(n,i){t.call(this),this.dataString=n,this.version=i}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r}(Fe),AIt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.getEncodingResult=function(i,o){var a=uHt(i),s=pHt(a),l=uR(s,o),h=dHt(a,l);return new cR(h,l)},r}(Fe),qw=function(t){function r(){t.call(this),this.initProperties()}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.initProperties=function(){c6(this,{modeIndicator:"",bitsInCharacterCount:[]})},r.prototype.getVersionIndex=function(i){return i<10?0:i>26?2:1},r.prototype.getBitsCharacterCount=function(i){return this.bitsInCharacterCount[this.getVersionIndex(i||40)]},r.prototype.getModeCountString=function(i,o){return this.modeIndicator+On(i,this.getBitsCharacterCount(o))},r.prototype.encode=function(){},r.prototype.getStringBitsLength=function(){},r.prototype.getValue=function(){},r}(Fe),LIt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.initProperties=function(){t.prototype.initProperties.call(this),c6(this,{bitsInCharacterCount:[10,12,14],modeIndicator:"0001"})},r.prototype.getValue=function(i){return parseInt(i,10)},r.prototype.encode=function(i,o){var a=this,s=lR(i,3),l=a.getModeCountString(i.length,o),h;for(h=0;h>h*6&63|128,8)+s;s=(i>>a*6|255>>l<0;){for(var l=0;l255&&(t=t^285),Vs[r]=t,Zw[t]=r;t=Vs[r-1]*2^285,Vs[r]=t,Vs[-1]=0}function oHt(t,r){for(var n=[],i=t.length-2,o=i;o>=0;o--)n[o]=t[o]^r[o];return n}function aHt(t,r){for(var n=[],i=0;i=0?r[o]:0))%255:n[i+o]=Zw[Vs[n[i+o]]^Vs[(t[i]+r[o])%255]];return n}function sHt(){for(var t=68,r=2;r<=t;r++){var n=Vm[r-1],i=[r,0];Vm[r]=aHt(n,i)}}nHt();sHt();function lHt(t,r){var n=[],i=t.length-1;do n[i]=Vs[(t[i]+r)%255],i--;while(t[i]!==void 0);return n}function cHt(t,r){var n=Vm[r-1],i=new Array(r).concat(t),o=new Array(i.length-n.length).concat(n),a=t.length,s=[],l,h;for(h=0;h=0;h--)s[r-1-h]=On(i[h],8);return s}function hHt(t,r){for(var n=0,i=[],o=[],a,s=r.groups,l,h,p,f,g=0;g=r||t.length===s.length||s.length>=n&&!qA.test(t.charAt(s.length)))?(g=FIt,b=s):f&&(t.length===f.length||f.length>=i||o===KA)?(g=KA,b=s||h):(g=RIt,f?b=f+ZA.exec(t.substring(f.length))[0]:b=ZA.exec(t)[0]),{mode:g,modeString:b}}function uHt(t){var r=[],n,i=0,o=t;for(r.push(QA(o,qIt,ZIt,JIt,n)),n=r[0].mode,o=o.substr(r[0].modeString.length);o.length>0;){var a=QA(o,QIt,tHt,eHt,n);a.mode!==n?(n=a.mode,r.push(a),i++):r[i].modeString+=a.modeString,o=o.substr(a.modeString.length)}return r}function pHt(t){for(var r=0,n,i=0;i1);return t<=cc[n][r].totalDataCodewords?o+1:i+1}function dHt(t,r){for(var n="",i,o=0;o=n);return o}function hc(t,r){return parseInt(t.charAt(r),10)}function gHt(t){for(var r=[],n=17+4*t,i=0;i=0;o--)o!==6&&vn(t,hc(r,s-1-a++),i,o);for(a=0,o=n.length-1,i=8;o>=n.length-8;o--)vn(t,hc(r,s-1-a++),i,o);for(vn(t,1,n.length-8,8),i=n.length-7,o=8;i=0&&o=0&&s[g+1][b]===n[z][h]&&s[g+1][b-1]===n[z][h]&&(r[z]+=3),rL(z,o,r,h,s[g][b]),rL(z,o,r,p,s[b][g]),iL(z,r,n,s[g][b],a,h),iL(z,r,n,s[b][g],a,p);var M=f*f,I,F=Number.MAX_VALUE;for(l=0;l=5&&(r[t]+=3+o[t][a]-5),o[t][a]=1)}function CHt(t,r){var n=Math.floor(t/r*100),i=n%5,o=Math.abs(n-i-50),a=Math.abs(n+5-i-50),s=10*Math.min(o/5,a/5);return s}function SHt(t){return t&&t.toLowerCase().indexOf("utf_8")>=0?new VIt:new AIt}function zHt(t,r,n){var i=SHt(n),o=i.getEncodingResult(t,r),a=o.version,s=cc[a-1][r],l=iHt(o.dataString,s.totalDataCodewords),h=hHt(l,s),p=gHt(a);yHt(p),xHt(p,a),bHt(p),a>=7&&eL(p,On(0,18)),tL(p,On(0,15)),rHt(p,h);var f=wHt(p),g=p[f];a>=7&&eL([g],mHt(a));var b=NIt[r]+On(f,3);return tL([g],fHt(b)),g}var j6=Math.round,MHt=[[0,1],[1,1],[1,2],[2,2],[2,1],[3,1],[3,0],[2,0],[2,-1],[1,-1],[1,0]],nL=[[0,1],[1,1],[1,0]],Ea={DEFAULT_SIZE:200,QUIET_ZONE_LENGTH:4,DEFAULT_ERROR_CORRECTION_LEVEL:"L",DEFAULT_BACKGROUND:"#fff",DEFAULT_DARK_MODULE_COLOR:"#000",MIN_BASE_UNIT_SIZE:1,DEFAULT_LOGO_SIZE:7},kHt=function(t){function r(n,i,o){o===void 0&&(o=uV),t.call(this),this.options=St({},this.options,i),this.element=n,this.wrapper=this.element,this.onError=o,this._initElement(),this._initSurface(),this.setOptions(i)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.destroy=function(){this._destroySurface()},r.prototype._initElement=function(){Dr(this.element,"k-qrcode")},r.prototype._initSurface=function(){var i=this,o=i.options,a=i.surface;(!a||a.options.type!==o.renderAs)&&(this._destroySurface(),this._initSurfaceElement(),this.surface=this._createSurface())},r.prototype._createSurface=function(){return Gl.create(this.surfaceElement,{type:this.options.renderAs})},r.prototype._destroySurface=function(){this.surface&&(this.surface.destroy(),this.surface=null,this._destroySurfaceElement())},r.prototype._initSurfaceElement=function(){this.surfaceElement||(this.surfaceElement=document.createElement("div"),this.surfaceElement.style.position="relative",this.element.appendChild(this.surfaceElement))},r.prototype._destroySurfaceElement=function(){this.surfaceElement&&this.surfaceElement.parentNode&&(this.surfaceElement.parentNode.removeChild(this.surfaceElement),this.surfaceElement=null)},r.prototype.redraw=function(){var i=this._getSize();this.surface.clear(),this.surface.setSize({width:i,height:i}),this.createVisual(),this.surface.draw(this.visual)},r.prototype.getSize=function(){var i=this.element,o=i.clientWidth,a=i.clientHeight,s={width:0,height:0};return o>0&&(s.width=o),a&&(s.height=a),s},r.prototype._resize=function(){this.redraw()},r.prototype.createVisual=function(){this.visual=this._render()},r.prototype.exportVisual=function(){return this._render()},r.prototype._render=function(){var i=this._value,o,a=this.options.border||{},s=this.options.padding||0,l=a.width||0,h,p,f,g,b;a.width=l;var z=new P1;try{i&&(p=zHt(i,this.options.errorCorrection,this.options.encoding),f=this._getSize(),b=f-2*(l+s),o=this._calculateBaseUnit(b,p.length),g=p.length*o,h=l+s+(b-g)/2,z.append(this._renderBackground(f,a)),z.append(this._renderMatrix(p,o,h)),this._hasCustomLogo()?z.append(this._renderLogo(f,o)):this._isSwiss()&&z.append(this._renderSwissCode(f,o)))}catch(M){this.onError(M)}return z},r.prototype._renderLogo=function(i,o){var a,s,l=j6(i/2),h=this._getLogoSize(o*Ea.DEFAULT_LOGO_SIZE),p=this.options.overlay.imageUrl,f={x:l-h.width/2,y:l-h.height/2};return s=new L1(new ye(f.x,f.y),new h0(h.width,h.height)),a=new eMt(p,s),a},r.prototype._renderSwissCode=function(i,o){var a=this._getLogoSize(o*Ea.DEFAULT_LOGO_SIZE);a=Math.max(a.width,a.height);var s=a/4,l=s/2,h=i/2,p={},f=new P1;return p.x=p.y=Math.ceil(h-o-a/2),f.append(this._renderShape(p,Math.ceil(a+o*2),nL,"#fff")),p.x=p.y=h-a/2,f.append(this._renderShape(p,a,nL,this.options.color)),p.x=h+l-a/2,p.y=h+l+s-a/2,f.append(this._renderShape(p,s,MHt,"#fff")),f},r.prototype._renderShape=function(i,o,a,s){var l=new qo({fill:{color:s},stroke:null});l.moveTo(i.x,i.y);for(var h=0;h0?i=s:i=Ea.DEFAULT_SIZE}return i},r.prototype._calculateBaseUnit=function(i,o){var a=Math.floor(i/o);if(a=i&&a-1>=Ea.MIN_BASE_UNIT_SIZE&&a--;return a},r.prototype._renderMatrix=function(i,o,a){for(var s=new qo({fill:{color:this.options.color},stroke:null}),l=0;l0;){G=wa(E),Z=_s(E),K=d4.sqrt(Vo(H*G)+Vo(M*F-z*H*Z)),at=z*F+M*H*Z,ft=Yh(K,at);var dt=M*H*G/K;et=1-Vo(dt),tt=0,et!==0&&(tt=at-2*z*F/et),R=E;var ht=f/16*et*(4+f*(4-3*et));E=g+(1-ht)*f*dt*(ft+ht*K*(tt+ht*at*(-1+2*Vo(tt)))),$=AHt(E-R)<=a.DISTANCE_CONVERGENCE}var lt=et*(Vo(h)-Vo(p))/Vo(p),yt=1+lt/16384*(4096+lt*(-768+lt*(320-175*lt))),mt=lt/1024*(256+lt*(-128+lt*(74-47*lt))),gt=mt*K*(tt+mt/4*(at*(-1+2*Vo(tt))-mt/6*tt*(-3+4*Vo(K))*(-3+4*Vo(tt)))),kt=Yh(H*G,M*F-z*H*Z),_t=Yh(M*G,-z*H+M*F*Z);return{distance:Ae(p*yt*(ft-gt),this.DISTANCE_PRECISION),azimuthFrom:Ns(kt),azimuthTo:Ns(_t)}},r.prototype.toString=function(){return String(this.lat)+","+String(this.lng)},r.fromLngLat=function(i){return new r(i[1],i[0])},r.fromLatLng=function(i){return new r(i[0],i[1])},r.create=function(i,o){if(ie(i))return i instanceof r?i.clone():arguments.length===1&&i.length===2?r.fromLatLng(i):new r(i,o)},r}(Fe),_4=Math,Rm=_4.atan,dR=_4.exp,sL=_4.pow,lL=_4.sin,fR=_4.log,vR=_4.tan,gR=ye,Kp=_4.PI,Om=Kp/2,mR=Kp/4,LHt=Kp/180,EHt=Fm.WGS84,Jw=function(t){function r(n){t.call(this),this.initProperties(),this._initOptions(n)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype._initOptions=function(i){this.options=St({},this.options,i)},r.prototype.initProperties=function(){St(this,{MAX_LNG:180,MAX_LAT:85.0840590501,INVERSE_ITERATIONS:15,INVERSE_CONVERGENCE:1e-12})},r.prototype.forward=function(i,o){var a=this,s=a.options,l=s.datum,h=l.a,p=s.centralMeridian,f=Xe(i.lat,-a.MAX_LAT,a.MAX_LAT),g=o?Xe(i.lng,-a.MAX_LNG,a.MAX_LNG):i.lng,b=Qr(g-p)*h,z=a._projectLat(f);return new gR(b,z)},r.prototype._projectLat=function(i){var o=this.options.datum,a=o.e,s=o.a,l=Qr(i),h=vR(mR+l/2),p=a*lL(l),f=sL((1-p)/(1+p),a/2);return s*fR(h*f)},r.prototype.inverse=function(i,o){var a=this,s=a.options,l=s.datum,h=l.a,p=s.centralMeridian,f=i.x/(LHt*h)+p,g=Xe(a._inverseY(i.y),-a.MAX_LAT,a.MAX_LAT);return o&&(f=Xe(f,-a.MAX_LNG,a.MAX_LNG)),new ni(g,f)},r.prototype._inverseY=function(i){var o=this,a=o.options.datum,s=a.a,l=a.e,h=l/2,p=dR(-i/s),f=Om-2*Rm(p),g;for(g=0;g<=o.INVERSE_ITERATIONS;g++){var b=l*lL(f),z=sL((1-b)/(1+b),h),M=Om-2*Rm(p*z)-f;if(f+=M,_4.abs(M)<=o.INVERSE_CONVERGENCE)break}return Ns(f)},r}(Fe);de(Jw,{centralMeridian:0,datum:EHt});var IHt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.initProperties=function(){t.prototype.initProperties.call(this),St(this,{MAX_LAT:85.0511287798})},r.prototype._projectLat=function(i){var o=this.options.datum.a,a=Qr(i),s=vR(mR+a/2);return o*fR(s)},r.prototype._inverseY=function(i){var o=this.options.datum.a,a=dR(-i/o);return Ns(Om-2*Rm(a))},r}(Jw),HHt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.forward=function(i){return new gR(i.lng,i.lat)},r.prototype.inverse=function(i){return new ni(i.y,i.x)},r}(Fe),DHt=function(t){function r(){t.call(this);var n=this,i=n._proj=new IHt,o=this.c=2*Kp*i.options.datum.a;this._tm=ar().translate(.5,.5).scale(1/o,-1/o),this._itm=ar().scale(o,-o).translate(-.5,-.5)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.toPoint=function(i,o,a){var s=this._proj.forward(i,a);return s.transform(this._tm).scale(o||1)},r.prototype.toLocation=function(i,o,a){var s=i.clone().scale(1/(o||1)).transform(this._itm);return this._proj.inverse(s,a)},r}(Fe);(function(t){function r(){t.call(this),this._proj=new Jw}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.toPoint=function(i){return this._proj.forward(i)},r.prototype.toLocation=function(i){return this._proj.inverse(i)},r})(Fe);(function(t){function r(){t.call(this),this._proj=new HHt}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.toPoint=function(i){return this._proj.forward(i)},r.prototype.toLocation=function(i){return this._proj.inverse(i)},r})(Fe);var jr=function(t,r){return t.bind(r)},E0=function(t){var r=document.createElement("div");return r.innerHTML=t,r.firstChild},PHt=function(t,r){var n=document.createElement("div");for(n.innerHTML=t;n.childNodes.length>0;)r.appendChild(n.childNodes[0])},y8=function(t){for(;t.firstChild;)t.removeChild(t.firstChild)},cL=function(t,r){r.insertBefore(t,r.firstChild)},THt=function(t,r){for(t.appendChild(r);t.firstChild!==r;)r.appendChild(t.firstChild)},yR=function(t){var r=t.replace(/([a-z][A-Z])/g,function(n){return n.charAt(0)+"-"+n.charAt(1).toLowerCase()});return r},hL=function(t){var r;return t&&String(t).endsWith("px")?r=t:r=String(t)+"px",r},VHt=function(t){var r=$8(),n=r.mobileOS;return n.ios||n.android},qp=function(t,r){var n=t.prototype;n.events?r.forEach(function(i){n.events.indexOf(i)<0&&n.events.push(i)}):n.events=r},FHt=function(t){var r=t.wheelDeltaY,n;return t.wheelDelta?(r===void 0||r)&&(n=t.wheelDelta):t.detail&&t.axis===t.VERTICAL_AXIS&&(n=-t.detail*10),n},uL=function(t){var r=[];if(t)for(var n=yR(t).split("-"),i=0;i0){y8(this.element);var h=o.join(this.options.separator);PHt(h,this.element),this.showElement()}else this.hideElement()},r.prototype.hideElement=function(){this.element.style.display="none"},r.prototype.showElement=function(){this.element.style.display=""},r.prototype._itemText=function(i){var o="",a=this._inZoomLevel(i.minZoom,i.maxZoom),s=this._inArea(i.extent);return a&&s&&(o+=i.text),o},r.prototype._inZoomLevel=function(i,o){var a=!0,s=t1(i,-Number.MAX_VALUE),l=t1(o,Number.MAX_VALUE);return a=this._zoom>s&&this._zoom'+U3({icon:"caret-alt-"+t,iconClass:"k-button-icon",svgIcons:r.svgIcons,type:r.type})+"";return E0(n)}var Qw=function(t){function r(n,i){t.call(this),this.element=n,this._initOptions(i);var o=Xh("up",i.icons),a=Xh("right",i.icons),s=Xh("down",i.icons),l=Xh("left",i.icons);this.element.appendChild(o),this.element.appendChild(a),this.element.appendChild(s),this.element.appendChild(l),Dr(this.element,"k-widget k-navigator"),Hn(this.element,"click",".k-button",jr(this._click,this));var h=this.element.parentNode.closest("[data-role]");this._keyroot=h||this.element,this._tabindex(this._keyroot),this._keydownHandler=jr(this._keydown,this),Hn(this._keyroot,"keydown",this._keydownHandler)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.destroy=function(){this.dispose()},r.prototype.dispose=function(){r2(this._keyroot,"keydown",this._keydownHandler)},r.prototype._tabindex=function(i){var o=i||this.wrapper||this.element,a=this.element,s="tabindex",l=o.getAttribute(s)||a.getAttribute(s);a.removeAttribute(s),o.setAttribute(s,isNaN(l)?0:l)},r.prototype._initOptions=function(i){this.options=St({},this.options,i)},r.prototype._pan=function(i,o){var a=this.options.panStep;this.trigger(bR,{x:i*a,y:o*a})},r.prototype._click=function(i){var o=0,a=0,s=i.currentTarget;s.matches(".k-navigator-n")?a=1:s.matches(".k-navigator-s")?a=-1:s.matches(".k-navigator-e")?o=1:s.matches(".k-navigator-w")&&(o=-1),this._pan(o,a),i.preventDefault()},r.prototype._keydown=function(i){switch(i.which){case Y3.UP:this._pan(0,1),i.preventDefault();break;case Y3.DOWN:this._pan(0,-1),i.preventDefault();break;case Y3.RIGHT:this._pan(1,0),i.preventDefault();break;case Y3.LEFT:this._pan(-1,0),i.preventDefault();break}},r}(q2);de(Qw,{name:"Navigator",panStep:1});qp(Qw,[bR]);function pL(t,r,n){var i='";return E0(i)}var OHt=187,BHt=189,NHt=61,$Ht=173,wR="change",tC=function(t){function r(n,i,o){t.call(this),this.element=n,this._initOptions(i);var a=pL("in","plus",o),s=pL("out","minus",o);this.element.appendChild(a),this.element.appendChild(s),this.element.setAttribute("role","group"),Dr(this.element,"k-widget k-zoom-control k-button-group k-group-horizontal"),this._clickHandler=this._click.bind(this),Hn(this.element,"click",".k-button",this._clickHandler);var l=this.element.parentNode.closest("[data-role]");this._keyroot=l||this.element,this._tabindex(this._keyroot),this._keydownHandler=this._keydown.bind(this),Hn(this._keyroot,"keydown",this._keydownHandler)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.destroy=function(){this.element&&r2(this.element,"click",this._clickHandler),this._keyroot&&r2(this._keyroot,"keydown",this._keydownHandler)},r.prototype._tabindex=function(i){var o=i||this.wrapper||this.element,a=this.element,s="tabindex",l=o.getAttribute(s)||a.getAttribute(s);a.removeAttribute(s),o.setAttribute(s,isNaN(l)?0:l)},r.prototype._initOptions=function(i){this.options=St({},this.options,i)},r.prototype._change=function(i){var o=this.options.zoomStep;this.trigger(wR,{delta:i*o})},r.prototype._click=function(i){var o=i.currentTarget,a=1;Zu(o,"k-zoom-out")&&(a=-1),this._change(a),i.preventDefault()},r.prototype._keydown=function(i){switch(i.which){case Y3.NUMPAD_PLUS:case OHt:case NHt:this._change(1);break;case Y3.NUMPAD_MINUS:case BHt:case $Ht:this._change(-1);break}},r}(q2);de(tC,{name:"ZoomControl",zoomStep:1});qp(tC,[wR]);var CR=Math,dL=CR.max,fL=CR.min,E7=function(t){function r(i,o){t.call(this);var a=ni.create(i),s=ni.create(o);a.lng+180>s.lng+180&&a.lat+90=a.lng+180&&l+180<=s.lng+180&&h+90>=s.lat+90&&h+90<=a.lat+90},r.prototype.center=function(){var o=this.nw,a=this.se,s=o.lng+(a.lng-o.lng)/2,l=o.lat+(a.lat-o.lat)/2;return new ni(l,s)},r.prototype.containsAny=function(o){for(var a=this,s=!1,l=0;l=i.minZoom,s=!ie(i.maxZoom)||o<=i.maxZoom,l=E7.create(i.extent),h=!l||l.overlaps(this.map.extent());this._setVisibility(a&&s&&h)},r.prototype._setVisibility=function(i){this.element.style.display=i?"":"none"},r.prototype._activate=function(){var i=this.map;this._deactivate(),i.bind("beforeReset",this._beforeReset),i.bind("reset",this._reset),i.bind("resize",this._resize),i.bind("panEnd",this._panEnd)},r.prototype._deactivate=function(){var i=this.map;i.unbind("beforeReset",this._beforeReset),i.unbind("reset",this._reset),i.unbind("resize",this._resize),i.unbind("panEnd",this._panEnd)},r.prototype._updateAttribution=function(){var i=this.map.attribution;i&&i.add(this.options.attribution)},r.prototype._readData=function(){var i=this.options.data||[];return i},r.prototype._hasData=function(){return this._data&&this._data.length>0},r.prototype._layerIndex=function(){var i=this.map.layers||[];return i.indexOf(this)},r}(Fe),As=Math,Bm=ye;function gL(t){return yr(t)?t:Ul.compile(t)}function YHt(t){return new Bm(Ae(t.x),Ae(t.y))}function mL(t){var r=t;return typeof t!="string"&&(r+="px"),r}var zR=function(t){function r(n,i){t.call(this,n,i),typeof this.options.subdomains=="string"&&(this.options.subdomains=this.options.subdomains.split(""));var o=this._viewType();this._view=new o(this.element,this.options)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.destroy=function(){t.prototype.destroy.call(this),this._view.destroy(),this._view=null},r.prototype._beforeReset=function(){var i=this.map,o=i.locationToLayer(i.extent().nw).round();this._view.viewOrigin(o)},r.prototype._reset=function(){t.prototype._reset.call(this),this._updateView(),this._view.reset()},r.prototype._viewType=function(){return XHt},r.prototype._activate=function(){t.prototype._activate.call(this),this.support.mobileOS||(this._pan||(this._pan=vp(this._render.bind(this),100)),this.map.bind("pan",this._pan))},r.prototype._deactivate=function(){t.prototype._deactivate.call(this),this._pan&&this.map.unbind("pan",this._pan)},r.prototype._updateView=function(){var i=this._view,o=this.map,a=o.extent(),s={nw:o.locationToLayer(a.nw).round(),se:o.locationToLayer(a.se).round()};i.center(o.locationToLayer(o.center())),i.extent(s),i.zoom(o.zoom())},r.prototype._resize=function(){this._render()},r.prototype._panEnd=function(i){t.prototype._panEnd.call(this,i),this._render()},r.prototype._render=function(){this._updateView(),this._view.render()},r}(eC);de(zR,{tileSize:256,subdomains:["a","b","c"],urlTemplate:"",zIndex:1});var XHt=function(t){function r(n,i){t.call(this),this.element=n,this._initOptions(i),this.pool=new kR}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype._initOptions=function(i){this.options=St({},this.options,i)},r.prototype.center=function(i){this._center=i},r.prototype.extent=function(i){this._extent=i},r.prototype.viewOrigin=function(i){this._viewOrigin=i},r.prototype.zoom=function(i){this._zoom=i},r.prototype.pointToTileIndex=function(i){return new Bm(As.floor(i.x/this.options.tileSize),As.floor(i.y/this.options.tileSize))},r.prototype.tileCount=function(){var i=this.size(),o=this.pointToTileIndex(this._extent.nw),a=this._extent.nw,s=this.indexToPoint(o).translate(-a.x,-a.y);return{x:As.ceil((As.abs(s.x)+i.width)/this.options.tileSize),y:As.ceil((As.abs(s.y)+i.height)/this.options.tileSize)}},r.prototype.size=function(){var i=this._extent.nw,o=this._extent.se,a=o.clone().translate(-i.x,-i.y);return{width:a.x,height:a.y}},r.prototype.indexToPoint=function(i){var o=i.x,a=i.y;return new Bm(o*this.options.tileSize,a*this.options.tileSize)},r.prototype.subdomainText=function(){var i=this.options.subdomains;return i[this.subdomainIndex++%i.length]},r.prototype.destroy=function(){y8(this.element),this.pool.empty()},r.prototype.reset=function(){this.pool.reset(),this.subdomainIndex=0,this.render()},r.prototype.render=function(){var i=this,o=this.tileCount(),a=this.pointToTileIndex(this._extent.nw),s,l,h;for(l=0;l=0?s=a:s=o-(a===0?o:a),s},r}(Fe),MR=function(t){function r(n,i){t.call(this),this.id=n,this.visible=!0,this._initOptions(i),this.createElement(),this.show()}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.destroy=function(){var i=this.element,o=i?i.parentNode:null;i&&(o&&o.removeChild(i),this.element=null)},r.prototype._initOptions=function(i){this.options=St({},this.options,i)},r.prototype.createElement=function(){var i=document.createElement("img"),o=this.options.size+"px";i.setAttribute("alt",""),i.style.position="absolute",i.style.display="block",i.style.width=i.style.maxWidth=o,i.style.height=i.style.maxHeight=o,this.element=i},r.prototype.show=function(){var i=this.element;i.style.top=mL(this.options.offset.y),i.style.left=mL(this.options.offset.x);var o=this.url();o&&i.setAttribute("src",o),i.style.visibility="visible",this.visible=!0},r.prototype.hide=function(){this.element.style.visibility="hidden",this.visible=!1},r.prototype.url=function(){var i=gL(this.options.urlTemplate);return i(this.urlOptions())},r.prototype.errorUrl=function(){var i=gL(this.options.errorUrlTemplate);return i(this.urlOptions())},r.prototype.urlOptions=function(){var i=this.options;return{zoom:i.zoom,subdomain:i.subdomain,z:i.zoom,x:i.index.x,y:i.index.y,s:i.subdomain,quadkey:i.quadkey,q:i.quadkey,culture:i.culture,c:i.culture}},r}(Fe);de(MR,{urlTemplate:"",errorUrlTemplate:""});var kR=function(t){function r(){t.call(this),this._items=[]}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.get=function(i,o){return this._items.length>=this.options.maxSize&&this._remove(i),this._create(o)},r.prototype.empty=function(){for(var i=this._items,o=0;oa&&!o[l].visible&&(s=l,a=h)}s!==-1&&(o[s].destroy(),o.splice(s,1))},r}(Fe);de(kR,{maxSize:100});var I0=Object.assign,x8="change",KHt=function(t){function r(n,i){t.call(this);var o=this,a=n[0]||n;o.capture=!1,a.addEventListener?(X3.down.split(" ").forEach(function(s){a.addEventListener(s,jr(o._press,o),!0)}),X3.up.split(" ").forEach(function(s){a.addEventListener(s,jr(o._release,o),!0)})):(X3.down.split(" ").forEach(function(s){a.attachEvent(s,jr(o._press,o))}),X3.up.split(" ").forEach(function(s){a.attachEvent(s,jr(o._release,o))})),o.bind(["press","release"],i||{})}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.captureNext=function(){this.capture=!0},r.prototype.cancelCapture=function(){this.capture=!1},r.prototype._press=function(i){var o=this;o.trigger("press"),o.capture&&i.preventDefault()},r.prototype._release=function(i){var o=this;o.trigger("release"),o.capture&&(i.preventDefault(),o.cancelCapture())},r}(q2),yL=function(t){function r(n){t.call(this);var i=this;i.forcedEnabled=!1,I0(i,n),i.scale=1,i.horizontal?(i.measure="offsetWidth",i.scrollSize="scrollWidth",i.axis="x"):(i.measure="offsetHeight",i.scrollSize="scrollHeight",i.axis="y")}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.makeVirtual=function(){I0(this,{virtual:!0,forcedEnabled:!0,_virtualMin:0,_virtualMax:0})},r.prototype.virtualSize=function(i,o){(this._virtualMin!==i||this._virtualMax!==o)&&(this._virtualMin=i,this._virtualMax=o,this.update())},r.prototype.outOfBounds=function(i){return i>this.max||il,i||o.trigger(x8,o))},r}(q2),qHt=function(t){function r(n){t.call(this);var i=this;i.x=new yL(I0({horizontal:!0},n)),i.y=new yL(I0({horizontal:!1},n)),i.container=n.container,i.forcedMinScale=n.minScale,i.maxScale=n.maxScale||100,i.bind(x8,n)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.rescale=function(i){this.x.rescale(i),this.y.rescale(i),this.refresh()},r.prototype.centerCoordinates=function(){return{x:Math.min(0,-this.x.centerOffset),y:Math.min(0,-this.y.centerOffset)}},r.prototype.refresh=function(){var i=this;i.x.update(),i.y.update(),i.enabled=i.x.enabled||i.y.enabled,i.minScale=i.forcedMinScale||Math.min(i.x.minScale,i.y.minScale),i.fitScale=Math.max(i.x.minScale,i.y.minScale),i.trigger(x8)},r}(q2),xL=function(t){function r(n){t.call(this),I0(this,n)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.outOfBounds=function(){return this.dimension.outOfBounds(this.movable[this.axis])},r.prototype.dragMove=function(i){var o=this,a=o.dimension,s=o.axis,l=o.movable,h=l[s]+i;if(a.enabled){var p=i;(ha.max&&i>0)&&(p*=o.resistance),l.translateAxis(s,p),o.trigger(x8,o)}},r}(q2),ZHt=function(t){function r(n){t.call(this);var i=this,o,a,s,l;I0(i,{elastic:!0},n),s=i.elastic?.5:0,l=i.movable,i.x=o=new xL({axis:"x",dimension:i.dimensions.x,resistance:s,movable:l}),i.y=a=new xL({axis:"y",dimension:i.dimensions.y,resistance:s,movable:l}),i.userEvents.bind(["press","move","end","gesturestart","gesturechange"],{gesturestart:function(p){i.gesture=p,i.offset=wl(i.dimensions.container)},press:function(p){var f=p.event.target.closest("a");f&&f.matches("[data-navigate-on-press=true]")&&p.sender.cancel()},gesturechange:function(p){var f=i.gesture,g=f.center,b=p.center,z=p.distance/f.distance,M=i.dimensions.minScale,I=i.dimensions.maxScale,F;l.scale<=M&&z<1&&(z+=(1-z)*.8),l.scale*z>=I&&(z=I/l.scale);var H=l.x+i.offset.left,E=l.y+i.offset.top;F={x:(H-g.x)*z+b.x-H,y:(E-g.y)*z+b.y-E},l.scaleWith(z),o.dragMove(F.x),a.dragMove(F.y),i.dimensions.rescale(l.scale),i.gesture=p,p.preventDefault()},move:function(p){p.event.target.tagName.match(/textarea|input/i)||(o.dimension.enabled||a.dimension.enabled?(o.dragMove(p.x.delta),a.dragMove(p.y.delta),p.preventDefault()):p.touch.skip())},end:function(p){p.preventDefault()}})}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r}(Fe),bL=function(t,r,n){return"translate3d("+t+"px,"+r+"px,0) scale("+n+")"},rC=function(t){function r(n){t.call(this);var i=this;i.element=n,i.element.style.transformOrigin="left top",i.x=0,i.y=0,i.scale=1;var o=bL(i.x,i.y,i.scale);i.element.style.transform=o,i._saveCoordinates(o)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.translateAxis=function(i,o){this[i]+=o,this.refresh()},r.prototype.scaleTo=function(i){this.scale=i,this.refresh()},r.prototype.scaleWith=function(i){this.scale*=i,this.refresh()},r.prototype.translate=function(i){this.x+=i.x,this.y+=i.y,this.refresh()},r.prototype.moveAxis=function(i,o){this[i]=o,this.refresh()},r.prototype.moveTo=function(i){I0(this,i),this.refresh()},r.prototype.refresh=function(){var i=this,o=i.x,a=i.y,s;i.round&&(o=Math.round(o),a=Math.round(a)),s=bL(o,a,i.scale),s!==i.coordinates&&(i.element.style.transform=s,i._saveCoordinates(s),i.trigger(x8))},r.prototype._saveCoordinates=function(i){this.coordinates=i},r}(q2),Nm=P1,iC=function(t){function r(n,i){t.call(this,n,i),this._pan=jr(this._pan,this),this.surface=Gl.create(this.element,{width:n.scrollElement.clientWidth,height:n.scrollElement.clientHeight}),this._initRoot(),this.movable=new rC(this.surface.element),this._markers=[],this._click=this._handler("shapeClick"),this.surface.bind("click",this._click),this._mouseleave=this._handler("shapeMouseLeave"),this.surface.bind("mouseleave",this._mouseleave),this.surface.bind("mouseenter",this._mouseenter.bind(this))}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.destroy=function(){t.prototype.destroy.call(this),this.surface.destroy()},r.prototype._reset=function(){t.prototype._reset.call(this),this._translateSurface(),this._data=this._readData(),this._hasData()&&this._load(this._data)},r.prototype._initRoot=function(){this._root=new Nm,this.surface.draw(this._root)},r.prototype._beforeReset=function(){this.surface.clear(),this._initRoot()},r.prototype._resize=function(){this.surface.size(this.map.size())},r.prototype._readData=function(){var i=t.prototype._readData.call(this);return i.type==="FeatureCollection"?i.features:i.type==="GeometryCollection"?i.geometries:i},r.prototype._load=function(i){var o=this;this._data=i,this._clearMarkers(),this._loader||(this._loader=new JHt(this.map,this.options.style,this));for(var a=new Nm,s=0;s1?qo:$e,s=new a(this.style),l=0;l-1&&this.items.splice(o,1)},r.prototype.clear=function(){for(var i=this,o=0;o=this.duration},r.prototype.timePassed=function(){return Math.min(this.duration,l4()-this.startDate)},r.prototype.moveTo=function(i){var o=this,a=o.movable;o.initial=a[o.axis],o.delta=i.location-o.initial,o.duration=typeof i.duration=="number"?i.duration:300,o.tick=o._easeProxy(i.ease),o.startDate=l4(),o.start()},r.prototype._easeProxy=function(i){var o=this;return function(){o.movable.moveAxis(o.axis,i(o.timePassed(),o.initial,o.delta,o.duration))}},r.easeOutExpo=function(i,o,a,s){return i===s?o+a:a*(-Math.pow(2,-10*i/s)+1)+o},r}(Zp),Hl=Object.assign,i0=Math.abs,nDt=500,oDt=.7,aDt=.96,sDt=10,_v=55,lDt=.5,_L=5,cDt="pull",I7="change",hDt="resize",LR="scroll",uDt=2,pDt=function(t){function r(n){t.call(this,n);var i=this;Hl(i,n),i.userEvents.bind("gestureend",i.start.bind(this)),i.tapCapture.bind("press",i.cancel.bind(this))}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.enabled=function(){return this.movable.scaleo.max?o.max:o.min;i._moveTo(a)},r.prototype._moveTo=function(i){this.transition.moveTo({location:i,duration:nDt,ease:kL.easeOutExpo})},r}(Zp),fDt=function(t){function r(n){t.call(this,n);var i=this;Hl(i,n,{origin:{},destination:{},offset:{}})}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.tick=function(){this._updateCoordinates(),this.moveTo(this.origin)},r.prototype.done=function(){return i0(this.offset.y)<_L&&i0(this.offset.x)<_L},r.prototype.onEnd=function(){this.moveTo(this.destination),this.callback&&this.callback.call()},r.prototype.setCoordinates=function(i,o){this.offset={},this.origin=i,this.destination=o},r.prototype.setCallback=function(i){i&&yr(i)?this.callback=i:i=void 0},r.prototype._updateCoordinates=function(){this.offset={x:(this.destination.x-this.origin.x)/4,y:(this.destination.y-this.origin.y)/4},this.origin={y:this.origin.y+this.offset.y,x:this.origin.x+this.offset.x}},r}(Zp),vDt=function(t){function r(n){t.call(this);var i=this,o=n.axis==="x",a=o?"horizontal":"vertical",s=E0('
');Hl(i,n,{element:s,elementSize:0,movable:new rC(s),scrollMovable:n.movable,alwaysVisible:n.alwaysVisible,size:o?"width":"height"}),i.scrollMovable.bind(I7,i.refresh.bind(i)),i.container.appendChild(s),n.alwaysVisible&&i.show()}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.refresh=function(){var i=this,o=i.axis,a=i.dimension,s=a.size,l=i.scrollMovable,h=s/a.total,p=Math.round(-l[o]*h),f=Math.round(s*h);h>=1?this.element.style.display="none":this.element.style.display="",p+f>s?f=s-p:p<0&&(f+=p,p=0),i.elementSize!==f&&(i.element.style[i.size]=f+"px",i.elementSize=f),i.movable.moveAxis(o,p)},r.prototype.show=function(){this.element.style.opacity=oDt,this.element.style.visibility="visible"},r.prototype.hide=function(){this.alwaysVisible||(this.element.style.opacity=0)},r}(Fe),oC=function(t){function r(n,i){t.call(this);var o=this;this.element=n,this._initOptions(i);var a=VHt();o._native=o.options.useNative&&a;var s=E0('
');if(o._native){Dr(n,"km-native-scroller"),cL(s,n),Hl(o,{scrollElement:n,fixedContainer:n.children[0]});return}n.style.overflow="hidden",Dr(n,"km-scroll-wrapper");var l=E0('
');THt(n,l),cL(s,n);var h=n.children[1],p=new KHt(n),f=new rC(h),g=new qHt({element:h,container:n,forcedEnabled:o.options.zoom}),b=this.options.avoidScrolling,z=new e9(n,{touchAction:"none",allowSelection:!0,preventDragEvent:!0,captureUpIfMoved:!0,multiTouch:o.options.zoom,supportDoubleTap:o.options.supportDoubleTap,start:function(E){g.refresh();var R=i0(E.x.velocity),W=i0(E.y.velocity),$=R*2>=W,G=o.fixedContainer.contains(E.event.target),Z=W*2>=R;!G&&!b(E)&&o.enabled&&(g.x.enabled&&$||g.y.enabled&&Z)?z.capture():z.cancel()}}),M=new ZHt({movable:f,dimensions:g,userEvents:z,elastic:o.options.elastic}),I=new pDt({movable:f,dimensions:g,userEvents:z,tapCapture:p}),F=new fDt({moveTo:function(E){o.scrollTo(E.x,E.y)}});f.bind(I7,function(){o.scrollTop=-f.y,o.scrollLeft=-f.x,o.trigger(LR,{scrollTop:o.scrollTop,scrollLeft:o.scrollLeft})}),o.options.mousewheelScrolling&&(this._wheelScrollHandler=this._wheelScroll.bind(this),Hn(n,"wheel",this._wheelScrollHandler)),Hl(o,{movable:f,dimensions:g,zoomSnapBack:I,animatedScroller:F,userEvents:z,pane:M,tapCapture:p,pulled:!1,enabled:!0,scrollElement:h,scrollTop:0,scrollLeft:0,fixedContainer:n.children[0]}),o._initAxis("x"),o._initAxis("y"),o._wheelEnd=function(){o._wheel=!1,o.userEvents.end(0,o._wheelY)},g.refresh(),o.options.pullToRefresh&&o._initPullToRefresh()}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype._initOptions=function(i){this.options=St({},this.options,i)},r.prototype._wheelScroll=function(i){if(!i.ctrlKey){this._wheel||(this._wheel=!0,this._wheelY=0,this.userEvents.press(0,this._wheelY)),clearTimeout(this._wheelTimeout),this._wheelTimeout=setTimeout(this._wheelEnd,50);var o=FHt(i);o&&(this._wheelY+=o,this.userEvents.move(0,this._wheelY)),i.preventDefault()}},r.prototype.makeVirtual=function(){this.dimensions.y.makeVirtual()},r.prototype.virtualSize=function(i,o){this.dimensions.y.virtualSize(i,o)},r.prototype.height=function(){return this.dimensions.y.size},r.prototype.scrollHeight=function(){return this.scrollElement.scrollHeight},r.prototype.scrollWidth=function(){return this.scrollElement.scrollWidth},r.prototype._resize=function(){this._native||this.contentResized()},r.prototype.setOptions=function(i){var o=this;this._initOptions(i),i.pullToRefresh&&o._initPullToRefresh()},r.prototype.reset=function(){this._native?this.scrollElement.scrollTop(0):(this.movable.moveTo({x:0,y:0}),this._scale(1))},r.prototype.contentResized=function(){this.dimensions.refresh(),this.pane.x.outOfBounds()&&this.movable.moveAxis("x",this.dimensions.x.min),this.pane.y.outOfBounds()&&this.movable.moveAxis("y",this.dimensions.y.min)},r.prototype.zoomOut=function(){var i=this.dimensions;i.refresh(),this._scale(i.fitScale),this.movable.moveTo(i.centerCoordinates())},r.prototype.enable=function(){this.enabled=!0},r.prototype.disable=function(){this.enabled=!1},r.prototype.scrollTo=function(i,o){this._native?(this.scrollElement.scrollLeft(i0(i)),this.scrollElement.scrollTop(i0(o))):(this.dimensions.refresh(),this.movable.moveTo({x:i,y:o}))},r.prototype.animatedScrollTo=function(i,o,a){var s,l;this._native?this.scrollTo(i,o):(s={x:this.movable.x,y:this.movable.y},l={x:i,y:o},this.animatedScroller.setCoordinates(s,l),this.animatedScroller.setCallback(a),this.animatedScroller.start())},r.prototype.pullHandled=function(){},r.prototype.destroy=function(){var i=this.element;r2(i,"wheel",this._wheelScrollHandler),this.userEvents&&this.userEvents.destroy()},r.prototype._scale=function(i){this.dimensions.rescale(i),this.movable.scaleTo(i)},r.prototype._initPullToRefresh=function(){},r.prototype._dragEnd=function(){},r.prototype._paneChange=function(){},r.prototype._initAxis=function(i){var o=this,a=o.movable,s=o.dimensions[i],l=o.tapCapture,h=o.pane[i],p=new vDt({axis:i,movable:a,dimension:s,container:o.element,alwaysVisible:o.options.visibleScrollHints});s.bind(I7,function(){p.refresh()}),h.bind(I7,function(){p.show()}),o[i+"inertia"]=new dDt({axis:i,paneAxis:h,movable:a,tapCapture:l,userEvents:o.userEvents,dimension:s,elastic:o.options.elastic,friction:o.options.friction||aDt,velocityMultiplier:o.options.velocityMultiplier||sDt,end:function(){p.hide(),o.trigger("scrollEnd",{axis:i,scrollTop:o.scrollTop,scrollLeft:o.scrollLeft})}})},r}(q2);de(oC,{name:"Scroller",zoom:!1,pullOffset:140,visibleScrollHints:!1,elastic:!0,useNative:!1,mousewheelScrolling:!0,avoidScrolling:function(){return!1},pullToRefresh:!1,messages:{pullTemplate:"Pull to refresh",releaseTemplate:"Release to refresh",refreshTemplate:"Refreshing"}});qp(oC,[cDt,LR,hDt]);var ER=function(r,n){n===void 0&&(n={}),this.sender=n.sender||r,this.widget=r,this.rtl=!!n.rtl};ER.prototype.notify=function(r,n){this.widget&&this.widget.trigger(r,n)};var Hs=Math,AL=Hs.min,Av=Hs.pow,LL=ye,H7="marker",Kh="location",gDt=.9,mDt=.93,EL="wheel",yDt=50,xDt=5,bDt=1,IR={bubble:_R,shape:iC,tile:zR};IR[H7]=nC;var HR=function(t){function r(n,i,o,a){i===void 0&&(i={}),o===void 0&&(o={}),a===void 0&&(a={}),t.call(this),this._init(n,i,o,a)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.destroy=function(){var i=this;this.scroller.destroy(),this._tooltip&&this._tooltip.destroy(),this.navigator&&this.navigator.destroy(),this.attribution&&this.attribution.destroy(),this.zoomControl&&this.zoomControl.destroy(),Mi(this.markers)?this.markers.forEach(function(a){a.destroy()}):this.markers.destroy();for(var o=0;o");this.element.appendChild(o)},r.prototype.initServices=function(i){i===void 0&&(i={}),this.widgetService=new ER(this,i)},r.prototype.initObserver=function(i){i===void 0&&(i={}),this.observers=[],this.addObserver(i.observer)},r.prototype.addObserver=function(i){i&&this.observers.push(i)},r.prototype.removeObserver=function(i){var o=this.observers.indexOf(i);o>=0&&this.observers.splice(o,1)},r.prototype.requiresHandlers=function(i){for(var o=this.observers,a=0;a0&&(s.lng=180+(180+s.lng));var l=new E7(a.nw,s);this.center(l.center());var h=this.element.clientWidth,p=this.element.clientHeight,f;for(f=this.options.maxZoom;f>=this.options.minZoom;f--){var g=o.locationToLayer(l.nw,f),b=o.locationToLayer(l.se,f),z=Hs.abs(b.x-g.x),M=Hs.abs(b.y-g.y);if(z<=h&&M<=p)break}this.zoom(f)},r.prototype._getExtent=function(){var i=this._getOrigin(),o=this.locationToLayer(i),a=this.viewSize();o.x+=a.width,o.y+=a.height;var s=this.layerToLocation(o);return new E7(i,s)},r.prototype._zoomAround=function(i,o){this._setOrigin(this.layerToLocation(i,o),o),this.zoom(o)},r.prototype._initControls=function(){var i=this.options.controls;i.attribution&&this._createAttribution(i.attribution),this.support.mobileOS||(i.navigator&&this._createNavigator(i.navigator),i.zoom&&this._createZoomControl(i.zoom))},r.prototype._createControlElement=function(i,o){var a=i.position||o,s="."+uL(a).replace(" ","."),l=this.element.querySelector(".k-map-controls"+s)||[];if(l.length===0){var h=document.createElement("div");Dr(h,"k-map-controls "+uL(a)),l=h,this.element.appendChild(l)}var p=document.createElement("div");return l.appendChild(p),p},r.prototype._createAttribution=function(i){var o=this._createControlElement(i,"bottomRight");this.attribution=new xR(o,i)},r.prototype._createNavigator=function(i){var o=this._createControlElement(i,"topLeft"),a=this.navigator=new Qw(o,St({},i,{icons:this.options.icons}));this._navigatorPan=this._navigatorPan.bind(this),a.bind("pan",this._navigatorPan),this._navigatorCenter=this._navigatorCenter.bind(this),a.bind("center",this._navigatorCenter)},r.prototype._navigatorPan=function(i){var o=this.scroller,a=o.scrollLeft+i.x,s=o.scrollTop-i.y,l=this._virtualSize,h=this.element.clientWidth,p=this.element.clientHeight;a=Xe(a,l.x.min,l.x.max-h),s=Xe(s,l.y.min,l.y.max-p),this.scroller.one("scroll",jr(this._scrollEnd,this)),this.scroller.scrollTo(-a,-s)},r.prototype._navigatorCenter=function(){this.center(this.options.center)},r.prototype._createZoomControl=function(i){var o=this._createControlElement(i,"topLeft"),a=this.zoomControl=new tC(o,i,this.options.icons);this._zoomControlChange=this._zoomControlChange.bind(this),a.bind("change",this._zoomControlChange)},r.prototype._zoomControlChange=function(i){this.trigger("zoomStart",{originalEvent:i})||(this.zoom(this.zoom()+i.delta),this.trigger("zoomEnd",{originalEvent:i}))},r.prototype._initScroller=function(){var i=this.support.mobileOS?mDt:gDt,o=this.options.zoomable!==!1,a=this.scroller=new oC(this.element.children[0],{friction:i,velocityMultiplier:xDt,zoom:o,mousewheelScrolling:!1,supportDoubleTap:!0});a.bind("scroll",jr(this._scroll,this)),a.bind("scrollEnd",jr(this._scrollEnd,this)),a.userEvents.bind("gesturestart",jr(this._scaleStart,this)),a.userEvents.bind("gestureend",jr(this._scale,this)),a.userEvents.bind("doubleTap",jr(this._doubleTap,this)),a.userEvents.bind("tap",jr(this._tap,this)),this.scrollElement=a.scrollElement},r.prototype._initLayers=function(){for(var i=this,o=this.options.layers,a=this.layers=[],s=0;s0||(this.markers=new nC(this,St({},this.options.markerDefaults,{icons:this.options.icons})),this.markers.add(this.options.markers))},r.prototype._scroll=function(i){var o=this.locationToLayer(this._viewOrigin).round(),a=i.sender.movable,s=new ye(a.x,a.y).scale(-1).scale(1/a.scale);o.x+=s.x,o.y+=s.y,this._scrollOffset=s,this._tooltip.offset=s,this.hideTooltip(),this._setOrigin(this.layerToLocation(o)),this.trigger("pan",{originalEvent:i,origin:this._getOrigin(),center:this.center()})},r.prototype._scrollEnd=function(i){!this._scrollOffset||!this._panComplete()||(this._scrollOffset=null,this._panEndTimestamp=l4(),this.trigger("panEnd",{originalEvent:i,origin:this._getOrigin(),center:this.center()}))},r.prototype._panComplete=function(){return l4()-(this._panEndTimestamp||0)>50},r.prototype._scaleStart=function(i){if(this.trigger("zoomStart",{originalEvent:i})){var o=i.touches[1];o&&o.cancel()}},r.prototype._scale=function(i){var o=this.scroller.movable.scale,a=this._scaleToZoom(o),s=new ye(i.center.x,i.center.y),l=this.viewToLocation(s,a),h=this.locationToLayer(l,a),p=h.translate(-s.x,-s.y);this._zoomAround(p,a),this.trigger("zoomEnd",{originalEvent:i})},r.prototype._scaleToZoom=function(i){var o=this._layerSize()*i,a=o/this.options.minSize,s=Hs.log(a)/Hs.log(2);return Hs.round(s)},r.prototype._reset=function(){this.attribution&&this.attribution.filter(this.center(),this.zoom()),this._viewOrigin=this._getOrigin(!0),this._resetScroller(),this.hideTooltip(),this.trigger("beforeReset"),this.trigger("reset")},r.prototype._resetScroller=function(){var i=this.scroller,o=i.dimensions.x,a=i.dimensions.y,s=this._layerSize(),l=this.extent().nw,h=this.locationToLayer(l).round();i.movable.round=!0,i.reset(),i.userEvents.cancel();var p=this.zoom();i.dimensions.forcedMinScale=Av(2,this.options.minZoom-p),i.dimensions.maxScale=Av(2,this.options.maxZoom-p);var f={min:-h.x,max:s-h.x},g={min:-h.y,max:s-h.y};if(this.options.wraparound&&(f.max=20*s,f.min=-f.max),this.options.pannable===!1){var b=this.viewSize();f.min=g.min=0,f.max=b.width,g.max=b.height}o.makeVirtual(),a.makeVirtual(),o.virtualSize(f.min,f.max),a.virtualSize(g.min,g.max),this._virtualSize={x:f,y:g}},r.prototype._renderLayers=function(){},r.prototype._layerSize=function(i){var o=t1(i,this.options.zoom);return this.options.minSize*Av(2,o)},r.prototype._tap=function(i){if(this._panComplete()){var o=this.eventOffset(i);this.hideTooltip(),this.trigger("click",{originalEvent:i,location:this.viewToLocation(o)})}},r.prototype._doubleTap=function(i){var o=this.options;if(o.zoomable!==!1&&!this.trigger("zoomStart",{originalEvent:i})){var a=this.zoom()+bDt,s=this.eventOffset(i),l=this.viewToLocation(s),h=this.locationToLayer(l,a),p=h.translate(-s.x,-s.y);this._zoomAround(p,a),this.trigger("zoomEnd",{originalEvent:i})}},r.prototype._mousewheel=function(i){var o=Wb(i)>0?-1:1,a=this.options,s=this.zoom(),l=Xe(s+o,a.minZoom,a.maxZoom);if(a.zoomable!==!1&&l!==s&&!this.trigger("zoomStart",{originalEvent:i})){var h=this.eventOffset(i),p=this.viewToLocation(h),f=this.locationToLayer(p,l),g=f.translate(-h.x,-h.y);this._zoomAround(g,l),this.trigger("zoomEnd",{originalEvent:i})}},r.prototype._toDocumentCoordinates=function(i){var o=wl(this.element);return{left:Ae(i.x+o.left),top:Ae(i.y+o.top)}},r}(q2);de(HR,{name:"Map",controls:{attribution:!0,navigator:{panStep:100},zoom:!0},layers:[],layerDefaults:{shape:{style:{fill:{color:"#fff"},stroke:{color:"#aaa",width:.5}}},bubble:{style:{fill:{color:"#fff",opacity:.5},stroke:{color:"#aaa",width:.5}}},marker:{shape:"pinTarget",tooltip:{position:"top"}}},center:[0,0],icons:{type:"font",svgIcons:{}},zoom:3,minSize:256,minZoom:1,maxZoom:19,markers:[],markerDefaults:{shape:"pinTarget",tooltip:{position:"top"}},wraparound:!0,renderPointsAsMarkers:!1});qp(HR,["beforeReset","click","markerActivate","markerClick","markerCreated","markerMouseEnter","markerMouseLeave","pan","panEnd","reset","shapeClick","shapeCreated","shapeFeatureCreated","shapeMouseEnter","shapeMouseLeave","zoomEnd","zoomStart"]);var wDt=function(t,r){return Math.max.apply(null,t.map(r))},CDt=function(t,r){return Math.min.apply(null,t.map(r))},Wm=function(t,r){return t.map(r).reduce(function(n,i){return n+i},0)},Jp=function(t,r){return t.y0===r.y0?t.index-r.index:t.y0+t.y1-r.y0-r.y1},SDt=function(t,r){return Jp(t.source,r.source)},zDt=function(t,r){return Jp(t.target,r.target)},jm=function(t){return t.value};function aC(t){t.forEach(function(r){r.targetLinks.forEach(function(n){n.source.sourceLinks.sort(zDt)}),r.sourceLinks.forEach(function(n){n.target.targetLinks.sort(SDt)})})}var MDt=function(t,r){return t.align==="left"?t.depth:t.align==="right"?r-t.height:t.sourceLinks.length?t.depth:r},Oi=function(r){var n=r.nodesOptions,i=n.offset;i===void 0&&(i={});var o=n.align;this.data={nodes:r.nodes.map(function(a){return St({},{offset:i,align:o},a)}),links:r.links.map(function(a){return St({},a)})},this.width=r.width,this.height=r.height,this.offsetX=r.offsetX||0,this.offsetY=r.offsetY||0,this.nodeWidth=r.nodesOptions.width,this.nodePadding=r.nodesOptions.padding,this.reverse=r.reverse,this.targetColumnIndex=r.targetColumnIndex,this.loops=r.loops,this.autoLayout=r.autoLayout};Oi.prototype.calculate=function(){var r=this.data,n=r.nodes,i=r.links;this.connectLinksToNodes(n,i),this.calculateNodeValues(n);var o=this.calculateNodeHeights(n);if(o)return{nodes:[],links:[],columns:[],circularLinks:o};this.calculateNodeDepths(n);var a=this.calculateNodeColumns(n);return this.calculateNodeBreadths(a),this.applyNodesOffset(n),this.calculateLinkBreadths(n),Object.assign({},this.data,{columns:a})};Oi.prototype.connectLinksToNodes=function(r,n){var i=new Map;r.forEach(function(o,a){o.index=a,o.sourceLinks=[],o.targetLinks=[],o.id=o.id!==void 0?o.id:o.label.text,i.set(o.id,o)}),n.forEach(function(o){o.source=i.get(o.sourceId),o.target=i.get(o.targetId),o.source.sourceLinks.push(o),o.target.targetLinks.push(o)})};Oi.prototype.calculateNodeValues=function(r){r.forEach(function(n){n.value=Math.max(Wm(n.sourceLinks,jm),Wm(n.targetLinks,jm))})};Oi.prototype.calculateNodeDepths=function(r){for(var n=new Set(r),i=new Set,o=0;n.size;){for(var a=Array.from(n),s=0;sn)return!0;i=o,o=new Set}return!1};Oi.prototype.calculateNodeColumns=function(r){for(var n=this,i=wDt(r,function(p){return p.depth}),o=(this.width-this.offsetX-this.nodeWidth)/i,a=new Array(i+1),s=0;s=0;s--){for(var l=r[s],h=function(f){var g=l[f],b=0,z=0;g.sourceLinks.forEach(function(I){var F=I.value*(I.target.layer-g.layer);b+=i.sourceTopPos(g,I.target)*F,z+=F});var M=b===0?0:b/z-g.y0;g.y0+=M,g.y1+=M,aC([g])},p=0;p=0;--s){var l=r[s],h=Math.max(0,l.y1-a);l.y0-=h,l.y1-=h,a=l.y0-o.nodePadding}};Oi.prototype.sourceTopPos=function(r,n){for(var i=this,o=n.y0-(n.targetLinks.length-1)*this.nodePadding/2,a=0;al?1:s===l?0:-1}function _Dt(t,r){var n=qh(t.x0,t.y0,t.x1,t.y1,r.x1,r.y1),i=qh(t.x0,t.y0,t.x1,t.y1,r.x0,r.y0),o=qh(t.x0,t.y0,r.x0,r.y0,r.x1,r.y1),a=qh(t.x1,t.y1,r.x0,r.y0,r.x1,r.y1);return n!==i&&o!==a}var c5=function(t){function r(n){t.call(this),this.options=St({},this.options,n),this.createVisual()}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.createVisual=function(){this.visual=this.createElement()},r.prototype.exportVisual=function(){return this.visual},r.prototype.createElement=function(){var i=this,o=this.options.visual,a;return o?a=o({sender:this.getSender(),options:this.visualOptions(),createVisual:function(){return i.getElement()}}):a=this.getElement(),a},r.prototype.getSender=function(){return this},r}(Fe),IL=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.getElement=function(){return $e.fromRect(this.getRect(),this.visualOptions())},r.prototype.getRect=function(){var i=this.options.node;return new L1([i.x0,i.y0],[i.x1-i.x0,i.y1-i.y0])},r.prototype.getLabelText=function(i){var o=i.labels.ariaTemplate;if(o)return o({node:i.node})},r.prototype.visualOptions=function(){var i=St({},this.options,this.options.node),o=this.getLabelText(i);return{fill:{color:i.color,opacity:i.opacity},stroke:{width:0},className:"k-sankey-node",role:"graphics-symbol",ariaRoleDescription:"Node",ariaLabel:o}},r.prototype.createFocusHighlight=function(){if(this.options.navigatable)return this._highlight=$e.fromRect(this.getRect(),{stroke:this.options.focusHighlight,visible:!1}),this._highlight},r.prototype.focus=function(i){if(this._highlight){var o=i||{},a=o.highlight;a===void 0&&(a=!0),a&&this._highlight.options.set("visible",!0);var s=this.options.node.id;this.visual.options.set("id",s),this.options.root()&&this.options.root().setAttribute(xl,s)}},r.prototype.blur=function(){this._highlight&&(this._highlight.options.set("visible",!1),this.visual.options.set("id",""),this.options.root()&&this.options.root().removeAttribute(xl))},r}(c5),ADt=function(t,r,n){return t.color||r[n%r.length]},HL=function(t,r,n,i){var o=St({},r,r.node);return St({},{color:ADt(t,n,i)},o,{node:t},{visual:t.visual,opacity:t.opacity,offset:t.offset,color:t.color})},LDt=function(t,r){var n=t[0],i=n[0],o=n[1],a=t[1],s=a[0],l=a[1],h=r[0],p=r[1];return Math.abs((s-i)*(p-o)-(h-i)*(l-o))/Math.sqrt(Math.pow(s-i,2)+Math.pow(l-o,2))},EDt=function(t,r,n,i,o){var a=1-o,s=a*a,l=o*o;return t*s*a+3*r*o*s+3*n*l*a+i*l*o},IDt=function(t,r){var n=t[0],i=n[0],o=n[1],a=t[1],s=a[0],l=a[1],h=r[0],p=h[0],f=h[1],g=r[1],b=g[0],z=g[1],M=Math.atan2(l-o,s-i),I=Math.atan2(z-f,b-p);return Math.abs(M-I)},HDt=function(t,r){var n=t.x0,i=t.x1,o=t.y0,a=t.y1,s=(n+i)/2,l=t.width,h=l/2,p=[[(n+s)/2,o-h],[(i+s)/2,a-h]],f=[s,EDt(o+h,o+h,a+h,a+h,.5)],g=LDt(p,f),b=(l-g)/2,z=IDt(p,[[n,o-h],[s,o-h]]),M=b,I=Math.sin(z)*M,F=Math.sqrt(M*M+I*I),H=o-a>0?-1:1;return r&&(H=-H),H*F},DDt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.getElement=function(){var i=this.options.link,o=i.x0,a=i.x1,s=i.y0,l=i.y1,h=(o+a)/2;return new $e(this.visualOptions()).moveTo(o,s).curveTo([h,s],[h,l],[a,l])},r.prototype.getLabelText=function(i){var o=i.labels.ariaTemplate;if(o)return o({link:i.link})},r.prototype.visualOptions=function(){var i=this.options,o=this.options.link,a=this.getLabelText(i);return{stroke:{width:i.link.width,color:o.color||i.color,opacity:ie(o.opacity)?o.opacity:i.opacity},role:"graphics-symbol",ariaRoleDescription:"Link",ariaLabel:a}},r.prototype.createFocusHighlight=function(){if(this.options.navigatable){var i=this.options,o=i.link,a=i.rtl,s=o.x0,l=o.x1,h=o.y0,p=o.y1,f=(s+l)/2,g=o.width/2,b=HDt(o,a);this._highlight=new $e({stroke:this.options.focusHighlight,visible:!1}).moveTo(s,h+g).lineTo(s,h-g).curveTo([f+b,h-g],[f+b,p-g],[l,p-g]).lineTo(l,p+g).curveTo([f-b,p+g],[f-b,h+g],[s,h+g])}},r.prototype.focus=function(i){if(this._highlight){var o=i||{},a=o.highlight;a===void 0&&(a=!0),a&&this._highlight.options.set("visible",!0);var s=this.options.link.sourceId+"->"+this.options.link.targetId;this.visual.options.set("id",s),this.options.root()&&this.options.root().setAttribute(xl,s)}},r.prototype.blur=function(){this._highlight&&(this._highlight.options.set("visible",!1),this.visual.options.set("id",""),this.options.root()&&this.options.root().removeAttribute(xl))},r}(c5),PDt=function(t,r,n,i){var o=St({},r,{link:t,opacity:t.opacity,color:t.color,colorType:t.colorType,visual:t.visual,highlight:t.highlight});return o.colorType==="source"?o.color=n.options.fill.color:o.colorType==="target"&&(o.color=i.options.fill.color),o},D7="inside",g3="before",Zh="after",Gm=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.getElement=function(){var i=St({},this.options,this.options.node.label),o=i.node,a=i.diagramMinX,s=i.diagramMaxX,l=i.text,h=i.offset,p=i.rtl,f=i.position;if(p&&f!==D7&&(f=f===g3?Zh:g3),!i.visible||!l)return null;var g=new Ce(o.x0,o.y0,o.x1,o.y1),b=this.visualOptions();p&&!b.align&&(b.align="right");var z=new Wn(l,b);z.reflow(new Ce);var M=z.box,I=g.center().y-M.height()/2,F=o.x1+M.width()>s,H=o.x0-M.width()F.width()?et.x2-F.width():0,lt-=et.y2>F.height()?et.y2-F.height():0,ft+=et.x1<0?-et.x1:0,dt+=et.y1<0?-et.y1:0,M===!1)return{sankey:v3(Object.assign({},i,{offsetX:ft,offsetY:dt,width:ht,height:lt,autoLayout:!1})),legendBox:W,titleBox:H};if(this.resize&&M&&this.permutation)return this.resize=!1,{sankey:v3(Object.assign({},i,{offsetX:ft,offsetY:dt,width:ht,height:lt},this.permutation)),legendBox:W,titleBox:H};for(var yt=1,mt=2,gt=v3(Object.assign({},i,{offsetX:ft,offsetY:dt,width:ht,height:lt,autoLayout:!1})).columns.length,kt=[],_t=function(Bt,Ut){var Xt=v3(Object.assign({},i,{offsetX:ft,offsetY:dt,width:ht,height:lt,loops:mt,targetColumnIndex:Bt,reverse:Ut})),It=kDt(Xt.links);return kt.push({crosses:It,reverse:Ut,targetColumnIndex:Bt}),It===0},bt=yt;bt<=gt-1&&!(_t(bt,!1)||_t(bt,!0));bt++);var Mt=Math.min.apply(null,kt.map(function(Bt){return Bt.crosses})),At=kt.find(function(Bt){return Bt.crosses===Mt});this.permutation={targetColumnIndex:At.targetColumnIndex,reverse:At.reverse};var Ft=v3(Object.assign({},i,{offsetX:ft,offsetY:dt,width:ht,height:lt},this.permutation));return{sankey:Ft,legendBox:W,titleBox:H}},r.prototype._render=function(i,o){var a=i||this.options,s=o||this,l=a.labels,h=a.nodes,p=a.links,f=a.nodeColors,g=a.title,b=a.legend,z=a.rtl,M=a.disableKeyboardNavigation,I=a.data,F=s.size,H=F.width,E=F.height,R=Object.assign({},I,{width:H,height:E,nodesOptions:h,title:g,legend:b}),W=this.calculateSankey(R,a),$=W.sankey,G=W.titleBox,Z=W.legendBox;z&&RDt($);var K=$.nodes,et=$.links,at=$.columns;s.columns=at.map(function(Ft){var Bt=Ft.slice();return Bt.sort(function(Ut,Xt){return Ut.y0-Xt.y0}),Bt});var tt=new P1({clip:$e.fromRect(new L1([0,0],[H,E]))});if(G){var ft=new Um(Object.assign({},g,{drawingRect:G})),dt=ft.exportVisual();tt.append(dt)}if($.circularLinks)return tt;var ht=new Map;s.nodesVisuals=ht;var lt={nodes:[],links:[],map:new Map};s.models=lt;var yt=[];K.forEach(function(Ft,Bt){var Ut=HL(Ft,h,f,Bt);Ut.root=function(){return s.element},Ut.navigatable=M!==!0;var Xt=new IL(Ut),It=Xt.exportVisual();It.links=[],It.type=m3,Ft.color=Ut.color,Ft.opacity=Ut.opacity,It.dataItem=Object.assign({},I.nodes[Bt],{color:Ut.color,opacity:Ut.opacity,sourceLinks:Ft.sourceLinks.map(function(ae){return{sourceId:ae.sourceId,targetId:ae.targetId,value:ae.value}}),targetLinks:Ft.targetLinks.map(function(ae){return{sourceId:ae.sourceId,targetId:ae.targetId,value:ae.value}})}),ht.set(Ft.id,It),lt.nodes.push(Xt),lt.map.set(Ft.id,Xt),tt.append(It),Xt.createFocusHighlight(),Xt._highlight&&yt.push(Xt._highlight)});var mt=et.slice().sort(function(Ft,Bt){return Bt.value-Ft.value}),gt=[];s.linksVisuals=gt,mt.forEach(function(Ft){var Bt=Ft.source,Ut=Ft.target,Xt=ht.get(Bt.id),It=ht.get(Ut.id),ae=PDt(Ft,p,Xt,It);ae.root=function(){return s.element},ae.navigatable=M!==!0,ae.rtl=z;var $t=new DDt(ae),ue=$t.exportVisual();ue.type=G6,ue.dataItem={source:Object.assign({},Xt.dataItem),target:Object.assign({},It.dataItem),value:Ft.value},ue.linkOptions=ae,gt.push(ue),Xt.links.push(ue),It.links.push(ue),lt.links.push($t),lt.map.set(Bt.id+"-"+Ut.id,$t),$t.createFocusHighlight(),$t._highlight&&yt.push($t._highlight),tt.append(ue)});var kt=K.reduce(function(Ft,Bt){return Math.min(Ft,Bt.x0)},1/0),_t=K.reduce(function(Ft,Bt){return Math.max(Ft,Bt.x1)},0);if(K.forEach(function(Ft){var Bt=DL(Ft,l,z,kt,_t),Ut=new Gm(Bt),Xt=Ut.exportVisual();Xt&&tt.append(Xt)}),Z){var bt=new P7(Object.assign({},b,{rtl:z,drawingRect:Z,nodes:K})),Mt=bt.exportVisual();tt.append(Mt)}if(yt.length!==0){var At=new P1;At.append.apply(At,yt),tt.append(At)}return tt},r.prototype.exportVisual=function(i){var o=i&&i.options?St({},this.options,i.options):this.options,a={size:{width:ie(i&&i.width)?i.width:this.size.width,height:ie(i&&i.height)?i.height:this.size.height}};return this._render(o,a)},r.prototype._setOptions=function(i){this.options=St({},this.options,i)},r}(q2),Ym={opacity:1,width:2,color:Ar};de(ODt,{title:{position:m1},labels:{visible:!0,margin:{left:8,right:8},padding:0,border:{width:0},paintOrder:"stroke",stroke:{lineJoin:"round",width:1},offset:{left:0,top:0}},nodes:{width:24,padding:16,opacity:1,align:"stretch",offset:{left:0,top:0},focusHighlight:Object.assign({},Ym),labels:{ariaTemplate:function(t){var r=t.node;return r.label.text}}},links:{colorType:"static",opacity:.4,highlight:{opacity:.8,inactiveOpacity:.2},focusHighlight:Object.assign({},Ym),labels:{ariaTemplate:function(t){var r=t.link;return r.source.label.text+" to "+r.target.label.text}}},tooltip:{followPointer:!1,delay:200}});var h5=1.5,u6=.4,DR="#000",sC="Arial, Helvetica, sans-serif",BDt="11px "+sC,Qp="12px "+sC,PR="16px "+sC,TR="transparent",VR="#fff",p6={type:ts},td={type:Qa},on=Object.assign({},td,{markers:{visible:!1},highlight:{visible:!1}}),FR=function(){return{icon:{border:{width:1}},label:{font:Qp,padding:3},line:{length:10,width:2},legendItem:on,visible:!0}},NDt=function(){return{labels:{font:Qp},notes:FR(),title:{font:PR,margin:5}}},PL=function(){return{highlight:{markers:{border:{}}},line:{opacity:1,width:0},markers:{size:6,visible:!1},legendItem:td,opacity:.4}},TL=function(){return{highlight:{markers:{border:{}}},line:{opacity:1,width:0},markers:{size:6,visible:!1},legendItem:td,opacity:.4}},$Dt=function(){return{gap:h5,spacing:u6,legendItem:on}},VL=function(){return{outliersField:"",meanField:"",border:{_brightness:.8,width:1},downColor:VR,gap:1,highlight:{border:{opacity:1,width:2},whiskers:{width:3},mean:{width:2},median:{width:2}},mean:{width:2},median:{width:2},spacing:.3,whiskers:{width:2},legendItem:on}},WDt=function(){return{border:{width:0},labels:{background:TR},legendItem:on,opacity:.6}},FL=function(){return{gap:h5,spacing:u6,target:{color:"#ff0000"},legendItem:on}},jDt=function(){return{border:{_brightness:.8,width:1},downColor:VR,gap:1,highlight:{border:{opacity:1,width:2},line:{width:2}},line:{color:DR,width:1},legendItem:on,spacing:.3}},GDt=function(){return{gap:h5,spacing:u6,legendItem:on}},UDt=function(){return{legendItem:on}},YDt=function(){return{legendItem:p6}},XDt=function(){return{legendItem:p6}},KDt=function(){return{margin:1,legendItem:on}},RL=function(){return{width:2,legendItem:p6}},qDt=function(){return{gap:1,highlight:{line:{opacity:1,width:3}},line:{width:1},legendItem:on,spacing:.3}},OL=function(){return{line:{opacity:1,width:0},markers:{size:6,visible:!1},legendItem:td,opacity:.5}},BL=function(){return{markers:{visible:!1},legendItem:p6,width:2}},ZDt=function(){return{gap:h5,spacing:u6,legendItem:on}},JDt=function(){return{gap:h5,spacing:u6,legendItem:on}},QDt=function(){return{width:1,legendItem:p6}},NL=function(){return{gap:.5,line:{color:DR,width:1},legendItem:on,spacing:u6}},tPt=function(){return{labels:{background:"",color:"",padding:{top:5,bottom:5,left:7,right:7}},legendItem:on}},RR=function(){return{labels:{background:"",color:"",padding:{top:5,bottom:5,left:7,right:7}},legendItem:on}},ePt=RR,rPt=function(){return{labels:{color:"",background:TR,visible:!0},highlight:{border:{width:0}},legendItem:on}},y3=function(t){return Object.assign({color:hT,trendline:{},markers:{visible:!1},width:1,dashType:"longDash",legendItem:p6},t)},iPt=function(t){return{visible:!0,labels:{font:BDt},overlay:t.gradients?{}:{gradient:"none"},area:PL(),rangeArea:TL(),verticalRangeArea:TL(),bar:$Dt(),boxPlot:VL(),bubble:WDt(),bullet:FL(),candlestick:jDt(),column:GDt(),heatmap:rPt(),pie:tPt(),donut:KDt(),funnel:RR(),pyramid:ePt(),horizontalWaterfall:NL(),line:RL(),notes:FR(),ohlc:qDt(),radarArea:OL(),radarLine:BL(),radarColumn:UDt(),polarArea:OL(),polarLine:BL(),polarScatter:YDt(),rangeBar:ZDt(),rangeColumn:JDt(),scatter:XDt(),scatterLine:QDt(),verticalArea:PL(),verticalBoxPlot:VL(),verticalBullet:FL(),verticalLine:RL(),waterfall:NL(),linearTrendline:y3(),exponentialTrendline:y3({style:"smooth"}),logarithmicTrendline:y3({style:"smooth"}),polynomialTrendline:y3({style:"smooth"}),powerTrendline:y3({style:"smooth"}),movingAverageTrendline:y3()}},nPt=function(){return{font:PR}},oPt=function(){return{font:Qp}},aPt=function(){return{labels:{font:Qp}}},$L=function(t){return t===void 0&&(t={}),{axisDefaults:NDt(),categoryAxis:{majorGridLines:{visible:!0}},navigator:{pane:{height:90,margin:{top:10}}},seriesDefaults:iPt(t),title:nPt(),subtitle:oPt(),legend:aPt()}};/** + */const jl=()=>_.useContext(fp).localization;var Qs="arc",e_="ArrowUp",r_="ArrowDown",i_="ArrowLeft",n_="ArrowRight",sSt="Tab",xl="aria-activedescendant",lSt="axisLabelClick",kr="#000",M1="bottom",a1="center",On="circle",pi=3,Mb="cross",Ba="date",sT="12px sans-serif",lT=400,U1=10,kb=600,s8="end",cSt="Enter",hSt="Escape",cT=/\{\d+:?/,Ru="height",hT=100,nm="inside",uT="inherit",p1="left",Vr=Number.MAX_VALUE,Zr=-Number.MAX_VALUE,om="none",uSt="noteClick",pSt="noteHover",dSt="noteLeave",l8="object",S7="outside",S1="right",pT="roundedRect",Ou="start",_b="string",v1="top",fSt="triangle",vSt="square",gSt="rect",e2="value",C1="#fff",Bu="width",Ne="x",We="y",o_=1,am="pointer",sm="horizontal",mSt="vertical";function zi(t){return Array.isArray(t)}function Ir(t,r){for(var n=zi(r)?r:[r],i=0;i=0;s--)(a[s]===o||a[s].original===o)&&a.splice(s,1);else this._events[i]=[];return this},r}(Ve);function a_(t){return typeof t=="function"}function s_(t){return typeof t=="string"?[t]:t}function wSt(){this._defaultPrevented=!0}function CSt(){return this._defaultPrevented===!0}const SSt=bSt;var lm=function(t){var r=typeof window<"u"?window:{},n=r.requestAnimationFrame||r.webkitRequestAnimationFrame||r.mozRequestAnimationFrame||r.oRequestAnimationFrame||r.msRequestAnimationFrame||function(i){setTimeout(i,1e3/60)};lm=function(i){return n.call(r,i)},lm(t)};const dT=lm;var zSt=/&/g,MSt=//g;function e0(t){return String(t).replace(zSt,"&").replace(MSt,"<").replace(ASt,">").replace(kSt,""").replace(_St,"'")}function fT(t){var r=window.console;typeof r<"u"&&r.log&&r.log(t)}function LSt(t){var r={edge:/(edge)[ \/]([\w.]+)/i,webkit:/(chrome)[ \/]([\w.]+)/i,safari:/(webkit)[ \/]([\w.]+)/i,opera:/(opera)(?:.*version|)[ \/]([\w.]+)/i,msie:/(msie\s|trident.*? rv:)([\w.]+)/i,mozilla:/(mozilla)(?:.*? rv:([\w.]+))/i},n={};for(var i in r)if(r.hasOwnProperty(i)){var o=t.match(r[i]);if(o){n[i]=!0,n[o[1].toLowerCase().split(" ")[0].split("/")[0]]=!0,n.version=parseInt(document.documentMode||o[2],10);break}}return n}var Dh=null,ESt={get browser(){return typeof window>"u"||Dh||(Dh=LSt(window.navigator.userAgent)),Dh}};const bl=ESt;var ISt=Date.now||function(){return new Date().getTime()};const c8=ISt;function vp(t,r){var n=0,i;if(!r||r<=0)return t;var o=function(){var a=c8()-n,s=arguments,l=function(){t.apply(null,s),n=c8()};if(!n)return l();i&&clearTimeout(i),a>r?l():i=setTimeout(l,r-a)};return o.cancel=function(){clearTimeout(i)},o}var HSt={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"00ffff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000000",blanchedalmond:"ffebcd",blue:"0000ff",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"00ffff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgrey:"a9a9a9",darkgreen:"006400",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"ff00ff",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",grey:"808080",green:"008000",greenyellow:"adff2f",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgrey:"d3d3d3",lightgreen:"90ee90",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"778899",lightslategrey:"778899",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"00ff00",limegreen:"32cd32",linen:"faf0e6",magenta:"ff00ff",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370d8",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"d87093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",red:"ff0000",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"ffffff",whitesmoke:"f5f5f5",yellow:"ffff00",yellowgreen:"9acd32"};const Lb=HSt;var l_=bl.browser,vT=function(t){var r=Object.keys(Lb);r.push("transparent");var n=new RegExp("^("+r.join("|")+")(\\W|$)","i");return vT=function(i){return n.exec(i)},n.exec(t)},gp=function(t){function r(){t.call(this)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.toHSV=function(){return this},r.prototype.toRGB=function(){return this},r.prototype.toHex=function(i){return this.toBytes().toHex(i)},r.prototype.toBytes=function(){return this},r.prototype.toCss=function(i){return"#"+this.toHex(i)},r.prototype.toCssRgba=function(){var i=this.toBytes();return"rgba("+i.r+", "+i.g+", "+i.b+", "+parseFloat(Number(this.a).toFixed(3))+")"},r.prototype.toDisplay=function(){return l_.msie&&l_.version<9?this.toCss():this.toCssRgba()},r.prototype.equals=function(i){return i===this||i!=null&&this.toCssRgba()===mp(i).toCssRgba()},r.prototype.diff=function(i){if(i===null)return NaN;var o=this.toBytes(),a=i.toBytes();return Math.sqrt(Math.pow((o.r-a.r)*.3,2)+Math.pow((o.g-a.g)*.59,2)+Math.pow((o.b-a.b)*.11,2))},r.prototype.clone=function(){var i=this.toBytes();return i===this&&(i=new Aa(i.r,i.g,i.b,i.a)),i},r}(Ve),Bs=function(t){function r(n,i,o,a){t.call(this),this.r=n,this.g=i,this.b=o,this.a=a}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.toHSV=function(){var i=this,o=i.r,a=i.g,s=i.b,l=Math.min(o,a,s),h=Math.max(o,a,s),p=h-l,f=h,g,b;return p===0?new cm(0,0,f,this.a):(h!==0?(b=p/h,o===h?g=(a-s)/p:a===h?g=2+(s-o)/p:g=4+(o-a)/p,g*=60,g<0&&(g+=360)):(b=0,g=-1),new cm(g,b,f,this.a))},r.prototype.toHSL=function(){var i=this,o=i.r,a=i.g,s=i.b,l=Math.max(o,a,s),h=Math.min(o,a,s),p,f,g=(l+h)/2;if(l===h)p=f=0;else{var b=l-h;switch(f=g>.5?b/(2-l-h):b/(l+h),l){case o:p=(a-s)/b+(ai.length;)i=n+i;return i}var cm=function(t){function r(n,i,o,a){t.call(this),this.h=n,this.s=i,this.v=o,this.a=a}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.toRGB=function(){var i=this,o=i.h,a=i.s,s=i.v,l,h,p;if(a===0)l=h=p=s;else{o/=60;var f=Math.floor(o),g=o-f,b=s*(1-a),z=s*(1-a*g),M=s*(1-a*(1-g));switch(f){case 0:l=s,h=M,p=b;break;case 1:l=z,h=s,p=b;break;case 2:l=b,h=s,p=M;break;case 3:l=b,h=z,p=s;break;case 4:l=M,h=b,p=s;break;default:l=s,h=b,p=z;break}}return new Bs(l,h,p,this.a)},r.prototype.toHSL=function(){return this.toRGB().toHSL()},r.prototype.toBytes=function(){return this.toRGB().toBytes()},r}(gp),gT=function(t){function r(n,i,o,a){t.call(this),this.h=n,this.s=i,this.l=o,this.a=a}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.toRGB=function(){var i=this.h/360,o=this.s/100,a=this.l/100,s,l,h;if(o===0)s=l=h=a;else{var p=a<.5?a*(1+o):a+o-a*o,f=2*a-p;s=sv(f,p,i+1/3),l=sv(f,p,i),h=sv(f,p,i-1/3)}return new Bs(s,l,h,this.a)},r.prototype.toHSV=function(){return this.toRGB().toHSV()},r.prototype.toBytes=function(){return this.toRGB().toBytes()},r}(gp);function sv(t,r,n){var i=n;return i<0&&(i+=1),i>1&&(i-=1),i<1/6?t+(r-t)*6*i:i<1/2?r:i<2/3?t+(r-t)*(2/3-i)*6:t}function c_(t){return parseFloat(parseFloat(parseInt(t,16)/255).toFixed(3))}function mp(t,r){var n,i;if(t==null||t==="none")return null;if(t instanceof gp)return t;var o=t.toLowerCase();if(n=vT(o))return n[1]==="transparent"?o=new Bs(1,1,1,0):o=mp(Lb[n[1]],r),o.match=[n[1]],o;if((n=/^#?([0-9a-f]{2})([0-9a-f]{2})([0-9a-f]{2})\b/i.exec(o))?i=new Aa(parseInt(n[1],16),parseInt(n[2],16),parseInt(n[3],16),1):(n=/^#?([0-9a-f])([0-9a-f])([0-9a-f])\b/i.exec(o))?i=new Aa(parseInt(n[1]+n[1],16),parseInt(n[2]+n[2],16),parseInt(n[3]+n[3],16),1):(n=/^#?([0-9a-f])([0-9a-f])([0-9a-f])([0-9a-f])\b/i.exec(o))?i=new Aa(parseInt(n[1]+n[1],16),parseInt(n[2]+n[2],16),parseInt(n[3]+n[3],16),c_(n[4]+n[4])):(n=/^#?([0-9a-f]{2})([0-9a-f]{2})([0-9a-f]{2})([0-9a-f]{2})\b/i.exec(o))?i=new Aa(parseInt(n[1],16),parseInt(n[2],16),parseInt(n[3],16),c_(n[4])):(n=/^rgb\(\s*([0-9]+)\s*,\s*([0-9]+)\s*,\s*([0-9]+)\s*\)/.exec(o))?i=new Aa(parseInt(n[1],10),parseInt(n[2],10),parseInt(n[3],10),1):(n=/^rgba\(\s*([0-9]+)\s*,\s*([0-9]+)\s*,\s*([0-9]+)\s*,\s*([0-9.]+)\s*\)/.exec(o))?i=new Aa(parseInt(n[1],10),parseInt(n[2],10),parseInt(n[3],10),parseFloat(n[4])):(n=/^rgb\(\s*([0-9]*\.?[0-9]+)%\s*,\s*([0-9]*\.?[0-9]+)%\s*,\s*([0-9]*\.?[0-9]+)%\s*\)/.exec(o))?i=new Bs(parseFloat(n[1])/100,parseFloat(n[2])/100,parseFloat(n[3])/100,1):(n=/^rgba\(\s*([0-9]*\.?[0-9]+)%\s*,\s*([0-9]*\.?[0-9]+)%\s*,\s*([0-9]*\.?[0-9]+)%\s*,\s*([0-9.]+)\s*\)/.exec(o))?i=new Bs(parseFloat(n[1])/100,parseFloat(n[2])/100,parseFloat(n[3])/100,parseFloat(n[4])):(n=/^color\(\s*srgb\s*([0-9\.]+)\s*([0-9\.]+)\s*([0-9\.]+)\s*(\/\s+([0-9\.]*))?\)/.exec(o))&&(i=new Bs(parseFloat(n[1]),parseFloat(n[2]),parseFloat(n[3]),parseFloat(n[5]||"1"))),i)i.match=n;else if(!r)throw new Error("Cannot parse color: "+o);return i}var DSt=180,Eb=function(t){function r(n){var i=this;if(t.call(this),arguments.length===1)for(var o=r.formats,a=this.resolveColor(n),s=0;s255?255:i},r.prototype.padDigit=function(i){return i.length===1?"0"+i:i},r.prototype.brightness=function(i){var o=Math.round;return this.r=o(this.normalizeByte(this.r*i)),this.g=o(this.normalizeByte(this.g*i)),this.b=o(this.normalizeByte(this.b*i)),this},r.prototype.percBrightness=function(){return Math.sqrt(.241*this.r*this.r+.691*this.g*this.g+.068*this.b*this.b)},r.prototype.isDark=function(){return this.percBrightness()0;)t>>6),r+=Io(128|i&63)):i<65536?(r+=Io(224|i>>>12),r+=Io(128|i>>>6&63),r+=Io(128|i&63)):i<1114111&&(r+=Io(240|i>>>18),r+=Io(128|i>>>12&63),r+=Io(128|i>>>6&63),r+=Io(128|i&63))}return r}var Th="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";function BSt(t){for(var r="",n=0,i=OSt(t);n>2,h=(o&3)<<4|a>>4,p=(a&15)<<2|s>>6,f=s&63;isNaN(a)?p=f=64:isNaN(s)&&(f=64),r=r+Th.charAt(l)+Th.charAt(h)+Th.charAt(p)+Th.charAt(f)}return r}function mT(t){return qe((t.x||{}).location)?{x:t.x.location,y:t.y.location}:{x:t.pageX||t.clientX||0,y:t.pageY||t.clientY||0}}function yT(t){return t===void 0&&(t={}),t.touch?t.touch.initialTouch:t.target}function M0(t){return t===""||t===null||t==="none"||t==="transparent"||!qe(t)}function wi(t){if(t)return t[t.length-1]}function Wu(t,r,n){return Math.max(Math.min(t,n),r)}function NSt(t,r){if(t.length<2)return t.slice();function n(i,o){for(var a=[],s=0,l=0,h=0;s=this._size?(a[this._head.key]=null,this._head=this._head.newer,this._head.older=null):this._length++},r.prototype.get=function(i){var o=this._map[i];if(o)return o===this._head&&o!==this._tail&&(this._head=o.newer,this._head.older=null),o!==this._tail&&(o.older&&(o.older.newer=o.newer,o.newer.older=o.older),o.older=this._tail,o.newer=null,this._tail.newer=o,this._tail=o),o.value},r}(Ve);const ST=GSt;var USt=/\r?\n|\r|\t/g,YSt=" ";function Pb(t){return String(t).replace(USt,YSt)}function zT(t){var r=[];for(var n in t)r.push(n+t[n]);return r.sort().join("")}function MT(t){for(var r=2166136261,n=0;n>>0}function p_(){return{width:0,height:0,baseline:0}}var XSt={baselineMarkerSize:1},um;typeof document<"u"&&(um=document.createElement("div"),um.style.cssText="position: absolute !important; top: -4000px !important; width: auto !important; height: auto !important;padding: 0 !important; margin: 0 !important; border: 0 !important;line-height: normal !important; visibility: hidden !important; white-space: pre!important;");var pm=function(t){function r(n){t.call(this),this._cache=new ST(1e3),this.options=Object.assign({},XSt,n)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.measure=function(i,o,a){if(a===void 0&&(a={}),typeof i>"u"||i===null)return p_();var s=zT(o),l=MT(i+s),h=this._cache.get(l);if(h)return h;var p=p_(),f=a.box||um,g=this._baselineMarker().cloneNode(!1);for(var b in o){var z=o[b];typeof z<"u"&&(f.style[b]=z)}var M=a.normalizeText!==!1?Pb(i):String(i);return f.textContent=M,f.appendChild(g),document.body.appendChild(f),M.length&&(p.width=f.offsetWidth-this.options.baselineMarkerSize,p.height=f.offsetHeight,p.baseline=g.offsetTop+this.options.baselineMarkerSize),p.width>0&&p.height>0&&this._cache.put(l,p),f.parentNode.removeChild(f),p},r.prototype._baselineMarker=function(){var i=document.createElement("div");return i.style.cssText="display: inline-block; vertical-align: baseline;width: "+this.options.baselineMarkerSize+"px; height: "+this.options.baselineMarkerSize+"px;overflow: hidden;",i},r}(Ve);pm.current=new pm;const kT=pm;function xp(t,r,n){return kT.current.measure(t,r,n)}const KSt=Object.freeze(Object.defineProperty({__proto__:null,DEG_TO_RAD:Ib,LRUCache:ST,MAX_NUM:j3,MIN_NUM:G3,TextMetrics:kT,append:h8,arabicToRoman:VSt,bindEvents:Hb,createPromise:Nu,defined:qe,definitionId:$u,deg:o4,elementOffset:bT,elementPadding:wT,elementScale:CT,elementSize:Hc,elementStyles:yp,encodeBase64:BSt,eventCoordinates:mT,eventElement:yT,hashKey:MT,isTransparent:M0,last:wi,limitValue:Wu,measureText:xp,mergeSort:NSt,normalizeText:Pb,now:c8,objectKey:zT,promiseAll:xT,rad:Ro,round:ar,unbindEvents:Db,valueOrDefault:ju},Symbol.toStringTag,{value:"Module"}));var qSt={}.toString,ZSt=function(t){function r(n,i){var o=this;i===void 0&&(i=""),t.call(this),this.prefix=i;for(var a in n){var s=n[a];s=o._wrap(s,a),o[a]=s}}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.get=function(i){for(var o=i.split("."),a=this;o.length&&a;){var s=o.shift();a=a[s]}return a},r.prototype.set=function(i,o){var a=this.get(i);a!==o&&(this._set(i,this._wrap(o,i)),this.optionsChange({field:this.prefix+i,value:o}))},r.prototype._set=function(i,o){var a=this,s=i.indexOf(".")>=0,l=this,h=i;if(s){for(var p=h.split("."),f=this.prefix;p.length>1;){h=p.shift(),f+=h+".";var g=l[h];g||(g=new r({},f),g.addObserver(a),l[h]=g),l=g}h=p[0]}l._clear(h),l[h]=o},r.prototype._clear=function(i){var o=this[i];o&&o.removeObserver&&o.removeObserver(this)},r.prototype._wrap=function(i,o){var a=qSt.call(i),s=i;return s!==null&&qe(s)&&a==="[object Object]"&&(!(i instanceof r)&&!(i instanceof Ve)&&(s=new r(s,this.prefix+o+".")),s.addObserver(this)),s},r}(j2);const _T=ZSt;function JSt(t){return function(r){return this[t]!==r&&(this[t]=r,this.geometryChange()),this}}function QSt(t){return function(){return this[t]}}function tzt(t,r){for(var n=0;n0&&!M0(o.color)},r.prototype._clippedBBox=function(o){return this.bbox(o)},Object.defineProperties(r.prototype,n),r}(j2);const a4=azt;function AT(t,r,n,i){var o=0,a=0;return i&&(o=Math.atan2(i.c*n,i.a*r),i.b!==0&&(a=Math.atan2(i.d*n,i.b*r))),{x:o,y:a}}var f_=Math.PI/2,szt=function(t){function r(n,i){n===void 0&&(n=new ye),i===void 0&&(i=0),t.call(this),this.setCenter(n),this.setRadius(i)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.setCenter=function(i){return this._observerField("center",ye.create(i)),this.geometryChange(),this},r.prototype.getCenter=function(){return this.center},r.prototype.equals=function(i){return i&&i.center.equals(this.center)&&i.radius===this.radius},r.prototype.clone=function(){return new r(this.center.clone(),this.radius)},r.prototype.pointAt=function(i){return this._pointAt(Ro(i))},r.prototype.bbox=function(i){for(var o=this,a=AT(this.center,this.radius,this.radius,i),s=ye.maxPoint(),l=ye.minPoint(),h=0;h<4;h++){var p=o._pointAt(a.x+h*f_).transformCopy(i),f=o._pointAt(a.y+h*f_).transformCopy(i),g=new ye(p.x,f.y);s=ye.min(s,g),l=ye.max(l,g)}return k1.fromPoints(s,l)},r.prototype._pointAt=function(i){var o=this,a=o.center,s=o.radius;return new ye(a.x+s*Math.cos(i),a.y+s*Math.sin(i))},r.prototype.containsPoint=function(i){var o=this,a=o.center,s=o.radius,l=Math.pow(i.x-a.x,2)+Math.pow(i.y-a.y,2)<=Math.pow(s,2);return l},r.prototype._isOnPath=function(i,o){var a=this,s=a.center,l=a.radius,h=s.distanceTo(i);return l-o<=h&&h<=l+o},r}(bp(j2,["radius"]));const n2=szt;var lzt="Gradient",czt=function(t){return function(r){function n(){r.apply(this,arguments)}return r&&(n.__proto__=r),n.prototype=Object.create(r&&r.prototype),n.prototype.constructor=n,n.prototype.fill=function(o,a){var s=this.options;if(qe(o)){if(o&&o.nodeType!==lzt){var l={color:o};qe(a)&&(l.opacity=a),s.set("fill",l)}else s.set("fill",o);return this}return s.get("fill")},n.prototype.stroke=function(o,a,s){return qe(o)?(this.options.set("stroke.color",o),qe(a)&&this.options.set("stroke.width",a),qe(s)&&this.options.set("stroke.opacity",s),this):this.options.get("stroke")},n}(t)};const B8=czt;var hzt=An.IDENTITY.toString(),uzt=function(t){return function(r){function n(){r.apply(this,arguments)}return r&&(n.__proto__=r),n.prototype=Object.create(r&&r.prototype),n.prototype.constructor=n,n.prototype.bbox=function(o){var a=k0(this.currentTransform(o)),s=a?a.toString():hzt,l;this._bboxCache&&this._matrixHash===s?l=this._bboxCache.clone():(l=this._bbox(a),this._bboxCache=l?l.clone():null,this._matrixHash=s);var h=this.options.get("stroke.width");return h&&l&&l.expand(h/2),l},n.prototype.geometryChange=function(){delete this._bboxCache,this.trigger("geometryChange",{element:this})},n}(t)};const wp=uzt;function pzt(t){var r="_"+t;return function(n){return qe(n)?(this._observerField(r,n),this.geometryChange(),this):this[r]}}function dzt(t,r){for(var n=0;n=0&&g<=1&&b>=0&&b<=1)return new ye(t.x+b*o,t.y+b*s)}var yzt=45,Vh=Math.pow,xzt=["radiusX","radiusY","startAngle","endAngle","anticlockwise"],bzt=function(t){function r(n,i){n===void 0&&(n=new ye),i===void 0&&(i={}),t.call(this),this.setCenter(n),this.radiusX=i.radiusX,this.radiusY=i.radiusY||i.radiusX,this.startAngle=i.startAngle,this.endAngle=i.endAngle,this.anticlockwise=i.anticlockwise||!1,this.xRotation=i.xRotation}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.clone=function(){return new r(this.center,{radiusX:this.radiusX,radiusY:this.radiusY,startAngle:this.startAngle,endAngle:this.endAngle,anticlockwise:this.anticlockwise})},r.prototype.setCenter=function(i){return this._observerField("center",ye.create(i)),this.geometryChange(),this},r.prototype.getCenter=function(){return this.center},r.prototype.pointAt=function(i){var o=this.center,a=Ro(i);return new ye(o.x+this.radiusX*Math.cos(a),o.y+this.radiusY*Math.sin(a))},r.prototype.curvePoints=function(){var i=this,o=this.startAngle,a=this.anticlockwise?-1:1,s=[this.pointAt(o)],l=this._arcInterval(),h=l.endAngle-l.startAngle,p=Math.ceil(h/yzt),f=h/p,g=o,b;this.xRotation&&(b=nr().rotate(this.xRotation,this.center));for(var z=1;z<=p;z++){var M=g+a*f,I=i._intervalCurvePoints(g,M,b);s.push(I.cp1,I.cp2,I.p2),g=M}return s},r.prototype.bbox=function(i){for(var o=this,a=this._arcInterval(),s=a.startAngle,l=a.endAngle,h=AT(this.center,this.radiusX,this.radiusY,i),p=o4(h.x),f=o4(h.y),g=this.pointAt(l).transformCopy(i),b=g_(p,s),z=g_(f,s),M=this.pointAt(s).transformCopy(i),I=ye.min(M,g),F=ye.max(M,g);ba||s&&o===a)&&(a+=360),{startAngle:o,endAngle:a}},r.prototype._intervalCurvePoints=function(i,o,a){var s=this.pointAt(i),l=this.pointAt(o),h=this._derivativeAt(i),p=this._derivativeAt(o),f=(Ro(o)-Ro(i))/3,g=new ye(s.x+f*h.x,s.y+f*h.y),b=new ye(l.x-f*p.x,l.y-f*p.y);return a&&(s.transform(a),l.transform(a),g.transform(a),b.transform(a)),{p1:s,cp1:g,cp2:b,p2:l}},r.prototype._derivativeAt=function(i){var o=Ro(i);return new ye(-this.radiusX*Math.sin(o),this.radiusY*Math.cos(o))},r.prototype.containsPoint=function(i){var o=this._arcInterval(),a=o.endAngle-o.startAngle,s=this,l=s.center,h=s.radiusX,p=s.radiusY,f=l.distanceTo(i),g=Math.atan2(i.y-l.y,i.x-l.x),b=h*p/Math.sqrt(Vh(h,2)*Vh(Math.sin(g),2)+Vh(p,2)*Vh(Math.cos(g),2)),z=this.pointAt(this.startAngle).round(Na),M=this.pointAt(this.endAngle).round(Na),I=mzt(l,i.round(Na),z,M),F;if(a<180)F=I&&lv(l.distanceTo(I),f)&&lv(f,b);else{var H=v_(l.x,l.y,h,p,i.x,i.y);H!==360&&(H=(360+H)%360);var E=o.startAngle<=H&&H<=o.endAngle;F=E&&lv(f,b)||!E&&(!I||I.equals(i))}return F},r.prototype._isOnPath=function(i,o){var a=this._arcInterval(),s=this.center,l=v_(s.x,s.y,this.radiusX,this.radiusY,i.x,i.y);l!==360&&(l=(360+l)%360);var h=a.startAngle<=l&&l<=a.endAngle;return h&&this.pointAt(l).distanceTo(i)<=o},r.fromPoints=function(i,o,a,s,l,h,p){var f=wzt({x1:i.x,y1:i.y,x2:o.x,y2:o.y,rx:a,ry:s,largeArc:l,swipe:h,rotation:p});return new r(f.center,{startAngle:f.startAngle,endAngle:f.endAngle,radiusX:f.radiusX,radiusY:f.radiusY,xRotation:f.xRotation,anticlockwise:h===0})},r}(bp(j2,xzt));function v_(t,r,n,i,o,a){var s=ar((o-t)/n,3),l=ar((a-r)/i,3);return ar(o4(Math.atan2(l,s)))}function wzt(t){var r=t.x1,n=t.y1,i=t.x2,o=t.y2,a=t.rx,s=t.ry,l=t.largeArc,h=t.swipe,p=t.rotation;p===void 0&&(p=0);var f=Ro(p),g=Math.cos(f),b=Math.sin(f),z=g*(r-i)/2+b*(n-o)/2,M=-b*(r-i)/2+g*(n-o)/2,I=l!==h?1:-1,F=Math.pow(z,2),H=Math.pow(M,2),E=Math.pow(a,2),R=Math.pow(s,2),W=F/E+H/R;W>1&&(W=Math.sqrt(F/E+H/R),a=W*a,E=Math.pow(a,2),s=W*s,R=Math.pow(s,2));var $=I*Math.sqrt((E*R-E*H-R*F)/(E*H+R*F));isNaN($)&&($=0);var G=$*(a*M)/s,Z=-$*(s*z)/a,K=g*G-b*Z+(r+i)/2,et=b*G+g*Z+(n+o)/2,at=(z-G)/a,tt=(M-Z)/s,ft=-(z+G)/a,dt=-(M+Z)/s,ht=(tt>=0?1:-1)*o4(Math.acos(at/Math.sqrt(at*at+tt*tt))),lt=ar((at*ft+tt*dt)/(Math.sqrt(at*at+tt*tt)*Math.sqrt(ft*ft+dt*dt)),10),yt=(at*dt-tt*ft>=0?1:-1)*o4(Math.acos(lt));!h&&yt>0&&(yt-=360),h&&yt<0&&(yt+=360);var mt=ht+yt,gt=mt>=0?1:-1;return mt=Math.abs(mt)%360*gt,{center:new ye(K,et),startAngle:ht,endAngle:mt,radiusX:a,radiusY:s,xRotation:p}}function g_(t,r){for(var n=t;nr.y,s&&((o[h]===0||o[h]===1)&&n.bottomRight().x>r.x||00?n.x-o:a-n.x)/(a-o)+s-n.y>=0}return i?1:0}function Hzt(t){var r="_"+t;return function(n){return qe(n)?(this._observerField(r,ye.create(n)),this.geometryChange(),this):this[r]}}function Dzt(t,r){for(var n=0;n1)&&(z=0);var M=Math.min(Math.max(g,b),1);return(M>1||M<0)&&(M=1),{min:z,max:M}},r.prototype._intersectionsTo=function(i,o){var a;return this.controlOut()&&i.controlIn()?a=Izt([this.anchor(),this.controlOut(),i.controlIn(),i.anchor()],o,this.bboxTo(i)):a=PT(this.anchor(),i.anchor(),o),a},r.prototype._isOnCurveTo=function(i,o,a,s){var l=this.bboxTo(i).expand(a,a);if(l.containsPoint(o)){var h=this.anchor(),p=this.controlOut(),f=i.controlIn(),g=i.anchor();if(s==="start"&&h.distanceTo(o)<=a)return!y_(h,p,o);if(s==="end"&&g.distanceTo(o)<=a)return!y_(g,f,o);var b=[h,p,f,g];if(Fh(b,o,"x","y",a)||Fh(b,o,"y","x",a))return!0;var z=nr().rotate(45,o),M=[h.transformCopy(z),p.transformCopy(z),f.transformCopy(z),g.transformCopy(z)];return Fh(M,o,"x","y",a)||Fh(M,o,"y","x",a)}},r.prototype._isOnLineTo=function(i,o,a){var s=this.anchor(),l=i.anchor(),h=o4(Math.atan2(l.y-s.y,l.x-s.x)),p=new k1([s.x,s.y-a/2],[s.distanceTo(l),a]);return p.containsPoint(o.transformCopy(nr().rotate(-h,s)))},r.prototype._isOnPathTo=function(i,o,a,s){var l;return this.controlOut()&&i.controlIn()?l=this._isOnCurveTo(i,o,a/2,s):l=this._isOnLineTo(i,o,a),l},r}(Cp(j2,Tzt));function b_(t){for(var r=t.length,n=j3,i=G3,o=0;o2&&(w_(0,n),o=n.length),o<2||o===2&&n[0].equals(n[1]))return i;var a=n[0],s=n[1],l=n[2];for(i.push(new Ii(a));a.equals(n[o-1]);)r=!0,n.pop(),o--;if(o===2){var h=Dc(a,s,k2,_2);return wi(i).controlOut(dm(h,a,s,k2,_2)),i.push(new Ii(s,fm(h,a,s,k2,_2))),i}var p,f;if(r){a=n[o-1],s=n[0],l=n[1];var g=cv(a,s,l);p=g[1],f=g[0]}else{var b=Dc(a,s,k2,_2);p=dm(b,a,s,k2,_2)}for(var z=p,M=0;M<=o-3;M++)if(w_(M,n),o=n.length,M+3<=o){a=n[M],s=n[M+1],l=n[M+2];var I=cv(a,s,l);wi(i).controlOut(z),z=I[1];var F=I[0];i.push(new Ii(s,F))}if(r){a=n[o-2],s=n[o-1],l=n[0];var H=cv(a,s,l);wi(i).controlOut(z),i.push(new Ii(s,H[0])),wi(i).controlOut(H[1]),i.push(new Ii(l,f))}else{var E=Dc(s,l,k2,_2);wi(i).controlOut(z),i.push(new Ii(l,fm(E,s,l,k2,_2)))}return i}function w_(t,r){for(;r[t+1]&&(r[t].equals(r[t+1])||r[t+1].equals(r[t+2]));)r.splice(t+1,1)}function Ozt(t,r,n){var i=!1;if(t.x===r.x)i=!0;else if(r.x===n.x)(r.y=a)&&(i=!0)}return i}function Bzt(t,r,n){var i=VT(t,r),o=RT(i,n.x);return t.x===r.x&&r.x===n.x||ar(o,1)===ar(n.y,1)}function VT(t,r){var n=(r.y-t.y)/(r.x-t.x),i=t.y-n*t.x;return[i,n]}function cv(t,r,n){var i=k2,o=_2,a=!1,s=!1,l;if(Bzt(t,r,n))l=Dc(t,r,k2,_2);else{var h={x:S_(t,r,n,k2),y:S_(t,r,n,_2)};if(h.x&&h.y)l=Dc(t,n,k2,_2),a=!0;else if(Ozt(t,r,n)&&(i=_2,o=k2),h[i])l=0;else{var p;n[o]r[i]&&r[i]>t[i]||n[i]2&&(h="l",f.splice(0,2))),L_[h])L_[h](t,{parameters:f,position:n,isRelative:p,previousCommand:i}),l&&l.toLowerCase()===jzt&&t.close();else if(h!==E_)throw new Error("Error while parsing SVG path. Unsupported command: "+h);i=h}),t}function Uu(t,r,n){for(var i,o=0;o0){var l=wi(this.segments),h=new Ii(s,a);this.suspend(),l.controlOut(o),this.resume(),this.segments.push(h)}return this},r.prototype.arc=function(o,a,s,l,h){if(this.segments.length>0){var p=wi(this.segments),f=p.anchor(),g=Ro(o),b=new ye(f.x-s*Math.cos(g),f.y-l*Math.sin(g)),z=new s4(b,{startAngle:o,endAngle:a,radiusX:s,radiusY:l,anticlockwise:h});this._addArcSegments(z)}return this},r.prototype.arcTo=function(o,a,s,l,h,p){if(this.segments.length>0){var f=wi(this.segments),g=f.anchor(),b=s4.fromPoints(g,ye.create(o),a,s,l,h,p);this._addArcSegments(b)}return this},r.prototype._addArcSegments=function(o){var a=this;this.suspend();for(var s=o.curvePoints(),l=1;l0){for(var h=[],p=Yzt(o),f,g=1;g1){if(s[0]._isOnPathTo(s[1],o,h,"start"))return!0;for(var p=2;p<=l-2;p++)if(s[p-1]._isOnPathTo(s[p],o,h))return!0;if(s[l-2]._isOnPathTo(s[l-1],o,h,"end"))return!0}return!1},r.prototype._bbox=function(o){var a=this.segments,s=a.length,l;if(s===1){var h=a[0].anchor().transformCopy(o);l=new k1(h,h0.ZERO)}else if(s>0)for(var p=1;p0){for(var l=[],h=0;h0&&wi(this.paths).lineTo(o,a),this},r.prototype.curveTo=function(o,a,s){return this.paths.length>0&&wi(this.paths).curveTo(o,a,s),this},r.prototype.arc=function(o,a,s,l,h){return this.paths.length>0&&wi(this.paths).arc(o,a,s,l,h),this},r.prototype.arcTo=function(o,a,s,l,h,p){return this.paths.length>0&&wi(this.paths).arcTo(o,a,s,l,h,p),this},r.prototype.close=function(){return this.paths.length>0&&wi(this.paths).close(),this},r.prototype._bbox=function(o){return Uu(this.paths,!0,o)},r.prototype.rawBBox=function(){return Uu(this.paths,!1)},r.prototype._containsPoint=function(o){for(var a=this.paths,s=0;s0){o.moveTo(a[0].x,a[0].y);for(var s=1;s=0&&(this.children.splice(a,1),o.parent=null,this.childrenChange("remove",[o],a)),this},r.prototype.removeAt=function(o){if(0<=o&&o=0;i--)r(t[i],i)},hMt=function(t){function r(n,i){t.call(this,Object.assign({},sMt,i)),this._rect=n,this._fieldMap={}}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.rect=function(i){return i?(this._rect=i,this):this._rect},r.prototype._initMap=function(){var i=this.options,o=this._fieldMap;i.orientation==="horizontal"?(o.sizeField="width",o.groupsSizeField="height",o.groupAxis="x",o.groupsAxis="y"):(o.sizeField="height",o.groupsSizeField="width",o.groupAxis="y",o.groupsAxis="x"),i.reverse?(this.forEach=cMt,this.justifyAlign=aMt):(this.forEach=lMt,this.justifyAlign=Rh)},r.prototype.reflow=function(){var i=this;if(!(!this._rect||this.children.length===0)){this._initMap(),this.options.transform&&this.transform(null);for(var o=this.options,a=this._rect,s=this._initGroups(),l=s.groups,h=s.groupsSize,p=this._fieldMap,f=p.sizeField,g=p.groupsSizeField,b=p.groupAxis,z=p.groupsAxis,M=new ye,I=new ye,F=new h0,H=Rh(h,a,o.alignContent,z,g),E,R,W,$=function(ft,dt){var ht=R.elements[dt];I[b]=E,I[z]=Rh(ft.size[g],W,o.alignItems,z,g),oMt(I,ft,ht),E+=ft.size[f]+o.spacing},G=0;Ga.size[f]){var Z=a.size[f]/W.size[f],K=W.topLeft().scale(Z,Z),et=W.size[g]*Z,at=Rh(et,a,o.alignContent,z,g),tt=nr();b==="x"?tt.translate(a.origin.x-K.x,at-K.y):tt.translate(at-K.x,a.origin.y-K.y),tt.scale(Z,Z),this.transform(tt)}}},r.prototype._initGroups=function(){for(var i=this,o=this,a=o.options,s=o.children,l=a.lineSpacing,h=a.wrap,p=a.spacing,f=this._fieldMap.sizeField,g=this._newGroup(),b=[],z=function(){b.push(g),M+=g.lineSize+l},M=-l,I=0;Ii._rect.size[f]?g.bboxes.length===0?(i._addToGroup(g,H,F),z(),g=i._newGroup()):(z(),g=i._newGroup(),i._addToGroup(g,H,F)):i._addToGroup(g,H,F))}return g.bboxes.length&&z(),{groups:b,groupsSize:M}},r.prototype._addToGroup=function(i,o,a){i.size+=o.size[this._fieldMap.sizeField]+this.options.spacing,i.lineSize=Math.max(o.size[this._fieldMap.groupsSizeField],i.lineSize),i.bboxes.push(o),i.elements.push(a)},r.prototype._newGroup=function(){return{lineSize:0,size:-this.options.spacing,bboxes:[],elements:[]}},r}(H1);const uMt=hMt;var pMt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype._change=function(){this.optionsChange({field:"stops"})},r}(ET);const dMt=pMt;function fMt(t){return function(r){return qe(r)?(this.options.set(t,r),this):this.options.get(t)}}function vMt(t,r){for(var n=0;n1?o=new r(i[0],i[1],i[2]):o=new r(i.offset,i.color,i.opacity),o}},r}(mMt(j2,yMt));const I_=xMt;var bMt=function(t){function r(i){i===void 0&&(i={}),t.call(this),this.stops=new dMt(this._createStops(i.stops)),this.stops.addObserver(this),this._userSpace=i.userSpace,this.id=$u()}t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r;var n={nodeType:{configurable:!0}};return n.nodeType.get=function(){return"Gradient"},r.prototype.userSpace=function(o){return qe(o)?(this._userSpace=o,this.optionsChange(),this):this._userSpace},r.prototype._createStops=function(o){o===void 0&&(o=[]);for(var a=[],s=0;s=0&&this.stops.splice(a,1)},r.prototype.optionsChange=function(o){this.trigger("optionsChange",{field:"gradient"+(o?"."+o.field:""),value:this})},r.prototype.geometryChange=function(){this.optionsChange()},Object.defineProperties(r.prototype,n),r}(j2);const NT=bMt;var wMt=["start","end"],CMt=function(t){function r(n){n===void 0&&(n={}),t.call(this,n),this.start(n.start||new ye),this.end(n.end||new ye(1,0))}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r}(Cp(NT,wMt));const Fb=CMt;var SMt=function(t){function r(n){n===void 0&&(n={}),t.call(this,n),this.center(n.center||new ye),this._radius=qe(n.radius)?n.radius:1,this._fallbackFill=n.fallbackFill}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.radius=function(i){return qe(i)?(this._radius=i,this.geometryChange(),this):this._radius},r.prototype.fallbackFill=function(i){return qe(i)?(this._fallbackFill=i,this.optionsChange(),this):this._fallbackFill},r}(Cp(NT,["center"]));const Rb=SMt;function zMt(t){return .5-Math.cos(t*Math.PI)/2}function MMt(t){return t}function kMt(t,r,n,i){var o=1.70158,a=0,s=i;return t===0?n:t===1?n+i:(a||(a=.5),s0||o.height>0)&&(!a||o.width!==a.width||o.height!==a.height))&&(this.currentSize(o),this._resize(o,i),this.trigger("resize",o))},r.prototype.size=function(i){if(!i)return this.getSize();this.setSize(i)},r.prototype.suspendTracking=function(){this._suspendedTracking=!0},r.prototype.resumeTracking=function(){this._suspendedTracking=!1},r.prototype._enableTracking=function(){},r.prototype._resize=function(){},r.prototype._handler=function(i){var o=this;return function(a){var s=o.eventTarget(a);s&&!o._suspendedTracking&&o.trigger(i,{element:s,originalEvent:a,type:i})}},r.prototype._elementOffset=function(){var i=this.element,o=wT(i),a=bT(i),s=a.left,l=a.top;return{left:s+o.left,top:l+o.top}},r.prototype._surfacePoint=function(i){var o=this._elementOffset(),a=mT(i),s=a.x-o.left,l=a.y-o.top,h=CT(this.element).invert(),p=new ye(s,l).transform(h);return p},r}(SSt);const Ob=HMt;function Mn(t,r){return qe(r)&&r!==null?" "+t+'="'+r+'" ':""}function _0(t){for(var r="",n=0;n",H_=document.createElement("div"),VMt=typeof DOMParser<"u";H_.innerHTML=TMt,VMt&&H_.firstChild.namespaceURI!==Xu&&(GT=function(t,r){var n=new DOMParser,i=n.parseFromString(WT(r),"text/xml");jT(i);var o=document.adoptNode(i.documentElement);t.innerHTML="",t.appendChild(o)})}const UT=GT;var D_="transform",Oh={clip:"clip-path",fill:"fill"};function P_(t,r){return t==="clip"||t==="fill"&&(!r||r.nodeType==="Gradient")}function FMt(){var t=document.getElementsByTagName("base")[0],r=document.location.href,n="";if(t&&!(bl.browser||{}).msie){var i=r.indexOf("#");i!==-1&&(r=r.substring(0,i)),n=r}return n}var RMt=function(t){function r(n,i){t.call(this,n),this.definitions={},this.options=i}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.destroy=function(){this.element&&(this.element._kendoNode=null,this.element=null),this.clearDefinitions(),t.prototype.destroy.call(this)},r.prototype.load=function(i,o){for(var a=this,s=0;s0&&p.load(h);var f=a.element;f&&p.attachTo(f,o)}},r.prototype.root=function(){for(var i=this;i.parent;)i=i.parent;return i},r.prototype.attachTo=function(i,o){var a=document.createElement("div");UT(a,""+this.render()+"");var s=a.firstChild.firstChild;s&&(qe(o)?i.insertBefore(s,i.childNodes[o]||null):i.appendChild(s),this.setElement(s))},r.prototype.setElement=function(i){this.element&&(this.element._kendoNode=null),this.element=i,this.element._kendoNode=this;for(var o=this.childNodes,a=0;a"},r.prototype.renderOffset=function(){return Mn("offset",this.srcElement.offset())},r.prototype.mapStyle=function(){var i=this.srcElement;return[["stop-color",i.color()],["stop-opacity",i.opacity()]]},r.prototype.optionsChange=function(i){i.field==="offset"?this.attr(i.field,i.value):(i.field==="color"||i.field==="opacity")&&this.css("stop-"+i.field,i.value)},r}(V0);const BMt=OMt;var NMt=function(t){function r(n){t.call(this,n),this.id=n.id,this.loadStops()}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.loadStops=function(){for(var i=this,o=this.srcElement.stops,a=this.element,s=0;s"+this.renderChildren()+""},r.prototype.mapCoordinates=function(){var i=this.srcElement,o=i.start(),a=i.end(),s=[["x1",o.x],["y1",o.y],["x2",a.x],["y2",a.y],this.mapSpace()];return s},r}(YT);const WMt=$Mt;var jMt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.template=function(){return""+this.renderChildren()+""},r.prototype.mapCoordinates=function(){var i=this.srcElement,o=i.center(),a=i.radius(),s=[["cx",o.x],["cy",o.y],["r",a],this.mapSpace()];return s},r}(YT);const GMt=jMt;var UMt=function(t){function r(n){t.call(this),this.srcElement=n,this.id=n.id,this.load([n])}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.renderClipRule=function(){return Mn("clip-rule","evenodd")},r.prototype.template=function(){return""+this.renderChildren()+""},r}(V0);const YMt=UMt;var XMt=function(t){function r(){t.call(this),this.definitionMap={}}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.attachTo=function(i){this.element=i},r.prototype.template=function(){return""+this.renderChildren()+""},r.prototype.definitionChange=function(i){var o=i.definitions,a=i.action;a==="add"?this.addDefinitions(o):a==="remove"&&this.removeDefinitions(o)},r.prototype.createDefinition=function(i,o){var a;return i==="clip"?a=YMt:i==="fill"&&(o instanceof Fb?a=WMt:o instanceof Rb&&(a=GMt)),new a(o)},r.prototype.addDefinitions=function(i){var o=this;for(var a in i)o.addDefinition(a,i[a])},r.prototype.addDefinition=function(i,o){var a=this,s=a.element,l=a.definitionMap,h=o.id,p=l[h];if(p)p.count++;else{var f=this.createDefinition(i,o);l[h]={element:f,count:1},this.append(f),s&&f.attachTo(this.element)}},r.prototype.removeDefinitions=function(i){var o=this;for(var a in i)o.removeDefinition(i[a])},r.prototype.removeDefinition=function(i){var o=this.definitionMap,a=i.id,s=o[a];s&&(s.count--,s.count===0&&(this.remove(this.childNodes.indexOf(s.element),1),delete o[a]))},r}(V0);const KMt=XMt;var qMt=function(t){function r(n){t.call(this),this.options=n,this.defs=new KMt}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.attachTo=function(i){this.element=i,this.defs.attachTo(i.firstElementChild)},r.prototype.clear=function(){Sp.prototype.clear.call(this)},r.prototype.template=function(){return this.defs.render()+this.renderChildren()},r.prototype.definitionChange=function(i){this.defs.definitionChange(i)},r}(V0);const ZMt=qMt;var XT={dot:[1.5,3.5],dash:[4,3.5],longdash:[8,3.5],dashdot:[3.5,3.5,1.5,3.5],longdashdot:[8,3.5,1.5,3.5],longdashdotdot:[8,3.5,1.5,3.5,1.5,3.5]},vm="solid",KT="butt",JMt={"fill.opacity":"fill-opacity","stroke.color":"stroke","stroke.width":"stroke-width","stroke.opacity":"stroke-opacity"},QMt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.geometryChange=function(){this.attr("d",this.renderData()),this.invalidate()},r.prototype.optionsChange=function(i){switch(i.field){case"fill":i.value?this.allAttr(this.mapFill(i.value)):this.removeAttr("fill");break;case"fill.color":this.allAttr(this.mapFill({color:i.value}));break;case"stroke":i.value?this.allAttr(this.mapStroke(i.value)):this.removeAttr("stroke");break;case"transform":this.transformChange(i.value);break;default:var o=JMt[i.field];o&&this.attr(o,i.value);break}this.accessibilityOptionsChange(i),t.prototype.optionsChange.call(this,i)},r.prototype.content=function(){this.element&&(this.element.textContent=this.srcElement.content())},r.prototype.renderData=function(){return this.srcElement.toString(Bb)||void 0},r.prototype.mapStroke=function(i){var o=[];return i&&!M0(i.color)?(o.push(["stroke",i.color]),o.push(["stroke-width",i.width]),o.push(["stroke-linecap",this.renderLinecap(i)]),o.push(["stroke-linejoin",i.lineJoin]),qe(i.opacity)&&o.push(["stroke-opacity",i.opacity]),qe(i.dashType)&&o.push(["stroke-dasharray",this.renderDashType(i)])):o.push(["stroke",Ku]),o},r.prototype.renderStroke=function(){return _0(this.mapStroke(this.srcElement.options.stroke))},r.prototype.renderDashType=function(i){var o=i.dashType,a=i.width;if(a===void 0&&(a=1),o&&o!==vm){for(var s=XT[o.toLowerCase()],l=[],h=0;h"},r}(V0);const F0=QMt;var tkt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.renderData=function(){return this.srcElement.toPath().toString(Bb)},r}(F0);const ekt=tkt;var rkt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.geometryChange=function(){var i=this.center();this.attr("cx",i.x),this.attr("cy",i.y),this.attr("r",this.radius()),this.invalidate()},r.prototype.center=function(){return this.srcElement.geometry().center},r.prototype.radius=function(){return this.srcElement.geometry().radius},r.prototype.template=function(){return""},r}(F0);const ikt=rkt;var nkt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.template=function(){return""+this.renderChildren()+""},r.prototype.optionsChange=function(i){var o=i.field,a=i.value;o==="transform"&&this.transformChange(a),this.accessibilityOptionsChange(i),t.prototype.optionsChange.call(this,i)},r}(V0);const okt=nkt;var akt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.geometryChange=function(){this.allAttr(this.mapPosition()),this.invalidate()},r.prototype.optionsChange=function(i){i.field==="src"&&this.allAttr(this.mapSource()),t.prototype.optionsChange.call(this,i)},r.prototype.mapPosition=function(){var i=this.srcElement.rect(),o=i.topLeft();return[["x",o.x],["y",o.y],["width",i.width()+"px"],["height",i.height()+"px"]]},r.prototype.renderPosition=function(){return _0(this.mapPosition())},r.prototype.mapSource=function(i){var o=this.srcElement.src();return i&&(o=e0(o)),[["xlink:href",o]]},r.prototype.renderSource=function(){return _0(this.mapSource(!0))},r.prototype.template=function(){return""},r}(F0);const skt=akt;var lkt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.renderData=function(){return this.srcElement.toString(Bb)||"undefined"},r}(F0);const ckt=lkt;var hkt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.geometryChange=function(){var i=this.srcElement.geometry();this.attr("x",i.origin.x),this.attr("y",i.origin.y),this.attr("width",i.size.width),this.attr("height",i.size.height),this.attr("rx",i.cornerRadius[0]),this.attr("ry",i.cornerRadius[1]),this.invalidate()},r.prototype.size=function(){return this.srcElement.geometry().size},r.prototype.origin=function(){return this.srcElement.geometry().origin},r.prototype.rx=function(){return this.srcElement.geometry().cornerRadius[0]},r.prototype.ry=function(){return this.srcElement.geometry().cornerRadius[1]},r.prototype.template=function(){return""},r}(F0);const ukt=hkt;var uv=/&(?:[a-zA-Z]+|#\d+);/g;function Nb(t){if(!t||typeof t!="string"||!uv.test(t))return t;var r=Nb._element;return uv.lastIndex=0,t.replace(uv,function(n){return r.innerHTML=n,r.textContent||r.innerText})}typeof document<"u"&&(Nb._element=document.createElement("span"));var pkt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.geometryChange=function(){var i=this.pos();this.attr("x",i.x),this.attr("y",i.y),this.invalidate()},r.prototype.optionsChange=function(i){i.field==="font"?(this.attr("style",$T(this.mapStyle())),this.geometryChange()):i.field==="content"&&t.prototype.content.call(this,this.srcElement.content()),t.prototype.optionsChange.call(this,i)},r.prototype.mapStyle=function(i){var o=t.prototype.mapStyle.call(this,i),a=this.srcElement.options.font;return i&&(a=e0(a)),o.push(["font",a],["white-space","pre"]),o},r.prototype.pos=function(){var i=this.srcElement.position(),o=this.srcElement.measure();return i.clone().setY(i.y+o.baseline)},r.prototype.renderContent=function(){var i=this.srcElement.content();return i=Nb(i),i=e0(i),Pb(i)},r.prototype.renderTextAnchor=function(){var i;return(this.options||{}).rtl&&!(bl.browser.msie||bl.browser.edge)&&(i="end"),Mn("text-anchor",i)},r.prototype.renderPaintOrder=function(){var i=this.srcElement.options.paintOrder;return i?Mn("paint-order",i):""},r.prototype.template=function(){return""+this.renderContent()+""},r}(F0);const dkt=pkt;ns.Arc=ekt;ns.Circle=ikt;ns.Group=okt;ns.Image=skt;ns.MultiPath=ckt;ns.Path=F0;ns.Rect=ukt;ns.Text=dkt;var fkt="rtl";function vkt(t){var r;try{r=t.getScreenCTM?t.getScreenCTM():null}catch{}if(r){var n=-r.e%1,i=-r.f%1,o=t.style;(n!==0||i!==0)&&(o.left=n+"px",o.top=i+"px")}}var gkt=function(t){function r(i,o){t.call(this,i,o),this._root=new ZMt(Object.assign({rtl:yp(i,"direction").direction===fkt},this.options)),UT(this.element,this._template("")),this._rootElement=this.element.firstElementChild,this._rootElement.style.width="100%",this._rootElement.style.height="100%",this._rootElement.style.overflow="hidden",vkt(this._rootElement),this._root.attachTo(this._rootElement),Hb(this.element,{click:this._click,mouseover:this._mouseenter,mouseout:this._mouseleave,mousemove:this._mousemove}),this.resize()}t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r;var n={type:{configurable:!0}};return n.type.get=function(){return"svg"},r.prototype.destroy=function(){this._root&&(this._root.destroy(),this._root=null,this._rootElement=null,Db(this.element,{click:this._click,mouseover:this._mouseenter,mouseout:this._mouseleave,mousemove:this._mousemove})),t.prototype.destroy.call(this)},r.prototype.translate=function(o){var a=Math.round(o.x)+" "+Math.round(o.y)+" "+this._size.width+" "+this._size.height;this._offset=o,this._rootElement.setAttribute("viewBox",a)},r.prototype.draw=function(o){t.prototype.draw.call(this,o),this._root.load([o])},r.prototype.clear=function(){t.prototype.clear.call(this),this._root.clear()},r.prototype.svg=function(){return""+this._template()},r.prototype.exportVisual=function(){var o=this,a=o._visual,s=o._offset;if(s){var l=new H1;l.children.push(a),l.transform(nr().translate(-s.x,-s.y)),a=l}return a},r.prototype._resize=function(){this._offset&&this.translate(this._offset)},r.prototype._template=function(o){var a=typeof o=="string"?o:"style='width: 100%; height: 100%; overflow: hidden;' ";return""+this._root.render()+""},Object.defineProperties(r.prototype,n),r}(Ob);const mkt=gkt;var ykt={};const Ko=ykt;var xkt=function(t){function r(n){t.call(this,n),n&&this.initClip()}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.initClip=function(){var i=this.srcElement.clip();i&&(this.clip=i,i.addObserver(this))},r.prototype.clear=function(){this.srcElement&&this.srcElement.removeObserver(this),this.clearClip(),t.prototype.clear.call(this)},r.prototype.clearClip=function(){this.clip&&(this.clip.removeObserver(this),delete this.clip)},r.prototype.setClip=function(i){if(this.clip){i.beginPath();var o=new Ko[this.clip.nodeType](this.clip);o.renderPoints(i,this.clip),i.clip("evenodd")}},r.prototype.optionsChange=function(i){i.field==="clip"&&(this.clearClip(),this.initClip()),t.prototype.optionsChange.call(this,i)},r.prototype.setTransform=function(i){if(this.srcElement){var o=this.srcElement.transform();o&&i.transform.apply(i,o.matrix().toArray(6))}},r.prototype.loadElements=function(i,o,a){for(var s=this,l=0;l0&&f.load(p,o,a),qe(o)?s.insertAt(f,o):s.append(f)}},r.prototype.load=function(i,o,a){this.loadElements(i,o,a),this.invalidate()},r.prototype.setOpacity=function(i){if(this.srcElement){var o=this.srcElement.opacity();qe(o)&&this.globalAlpha(i,o)}},r.prototype.globalAlpha=function(i,o){var a=o;a&&i.globalAlpha&&(a*=i.globalAlpha),i.globalAlpha=a},r.prototype.visible=function(){var i=this.srcElement;return!i||i&&i.options.visible!==!1},r}(Sp);const qT=xkt;var bkt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.renderTo=function(i){if(this.visible()){i.save(),this.setTransform(i),this.setClip(i),this.setOpacity(i);for(var o=this.childNodes,a=0;a0;)a=i.pop(),a.addObserver(o),a.nodeType==="Group"?h8(i,a.children):o._insertShape(a)},r.prototype._insertShape=function(i){var o=i.bbox();if(o){var a=this.getSectors(o),s=a[0][0],l=a[1][0];if(this.inRoot(a))this.root.insert(i,o);else{var h=this.rootMap;h[s]||(h[s]={}),h[s][l]||(h[s][l]=new kkt(new k1([s*Ho,l*Ho],[Ho,Ho]))),h[s][l].insert(i,o)}}},r.prototype.remove=function(i){var o=this;if(i.removeObserver(this),i.nodeType==="Group")for(var a=i.children,s=0;s1||i[1].length>1},r.prototype.getSectors=function(i){for(var o=i.bottomRight(),a=Math.floor(o.x/Ho),s=Math.floor(o.y/Ho),l=[[],[]],h=Math.floor(i.origin.x/Ho);h<=a;h++)l[0].push(h);for(var p=Math.floor(i.origin.y/Ho);p<=s;p++)l[1].push(p);return l},r}(Ve);function Lkt(t,r){return t._zIndexr._zIndex?-1:0}const V_=Akt;var os=function(r){r.bind("mouseenter",this._mouseenter.bind(this)),r.bind("mouseleave",this._mouseleave.bind(this)),this.element=r.element};os.prototype.clear=function(){this._resetCursor()};os.prototype.destroy=function(){this._resetCursor(),delete this.element};os.prototype._mouseenter=function(r){var n=this._shapeCursor(r);n?(this._current||(this._defaultCursor=this._getCursor()),this._setCursor(n)):this._resetCursor()};os.prototype._mouseleave=function(){this._resetCursor()};os.prototype._shapeCursor=function(r){for(var n=r.element;n&&!qe(n.options.cursor);)n=n.parent;if(n)return n.options.cursor};os.prototype._getCursor=function(){if(this.element)return this.element.style.cursor};os.prototype._setCursor=function(r){this.element&&(this.element.style.cursor=r,this._current=r)};os.prototype._resetCursor=function(){this._current&&(this._setCursor(this._defaultCursor||""),delete this._current)};const Ekt=os;function $b(t,r){var n=r.segments;if(n.length!==0){var i=n[0],o=i.anchor();t.moveTo(o.x,o.y);for(var a=1;a0)return i.strokeStyle=o.color,i.lineWidth=ju(o.width,1),i.lineJoin=ju(o.lineJoin,i.lineJoin),i.save(),this.globalAlpha(i,o.opacity),i.stroke(),i.restore(),!0},r.prototype.dashType=function(){var i=this.srcElement.options.stroke;if(i&&i.dashType)return i.dashType.toLowerCase()},r.prototype.setLineDash=function(i){var o=this.dashType();if(o&&o!==vm){var a=XT[o];i.setLineDash?i.setLineDash(a):(i.mozDash=a,i.webkitLineDash=a)}},r.prototype.setLineCap=function(i){var o=this.dashType(),a=this.srcElement.options.stroke;o&&o!==vm?i.lineCap=KT:a&&a.lineCap&&(i.lineCap=a.lineCap)},r.prototype.setLineJoin=function(i){var o=this.srcElement.options.stroke;o&&o.lineJoin&&(i.lineJoin=o.lineJoin)},r.prototype.renderPoints=function(i,o){$b(i,o)},r}(qT);const R0=Hkt;var Dkt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.renderPoints=function(i){var o=this.srcElement.toPath();$b(i,o)},r}(R0);const Pkt=Dkt;var Tkt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.renderPoints=function(i){var o=this.srcElement.geometry(),a=o.center,s=o.radius;i.arc(a.x,a.y,s,0,Math.PI*2)},r}(R0);const Vkt=Tkt;var Fkt=function(t){function r(n,i){t.call(this,n),this.onLoad=this.onLoad.bind(this),this.onError=this.onError.bind(this),this.loading=Nu();var o=this.img=new Image,a=n.src();i&&!/^data:/i.test(a)&&(o.crossOrigin=i),a&&(o.src=a),o.complete?this.onLoad():(o.onload=this.onLoad,o.onerror=this.onError)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.renderTo=function(i){this.loading.state()==="resolved"&&(i.save(),this.setTransform(i),this.setClip(i),this.drawImage(i),i.restore())},r.prototype.optionsChange=function(i){i.field==="src"?(this.loading=Nu(),this.img.src=this.srcElement.src()):t.prototype.optionsChange.call(this,i)},r.prototype.onLoad=function(){this.loading.resolve(),this.invalidate()},r.prototype.onError=function(){this.loading.reject(new Error("Unable to load image '"+this.img.src+"'. Check for connectivity and verify CORS headers."))},r.prototype.drawImage=function(i){var o=this.srcElement.rect(),a=o.topLeft();i.drawImage(this.img,a.x,a.y,o.width(),o.height())},r}(R0);const Rkt=Fkt;var Okt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.renderPoints=function(i){for(var o=this.srcElement.paths,a=0;a"},r.prototype._enableTracking=function(){this._searchTree=new V_,this._cursor=new Ekt(this),t.prototype._enableTracking.call(this)},r.prototype._trackMouse=function(o){if(!this._suspendedTracking){var a=this.eventTarget(o);if(o.type!=="click"){var s=this._currentShape;s&&s!==a&&this.trigger("mouseleave",{element:s,originalEvent:o,type:"mouseleave"}),a&&s!==a&&this.trigger("mouseenter",{element:a,originalEvent:o,type:"mouseenter"}),this.trigger("mousemove",{element:a,originalEvent:o,type:"mousemove"}),this._currentShape=a}else a&&this.trigger("click",{element:a,originalEvent:o,type:"click"})}},Object.defineProperties(r.prototype,n),r}(Ob);const Ukt=Gkt;var pv,dv,QT=function(){return typeof document<"u"},Ykt=function(){return QT()&&document.createElement("canvas").getContext},Xkt=function(){return QT()&&document.implementation.hasFeature("http://www.w3.org/TR/SVG11/feature#BasicStructure","1.1")},Kkt=function(t){function r(){t.call(this),this._items=[{name:"svg",type:mkt},{name:"canvas",type:Ukt}]}t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r;var n={support:{configurable:!0},current:{configurable:!0}};return n.support.get=function(){return dv||(dv={canvas:Ykt(),svg:Xkt()}),dv},n.current.get=function(){return pv||(pv=new r),pv},r.prototype.create=function(o,a){var s=this._items,l=s[0];if(a&&a.type){for(var h=a.type.toLowerCase(),p=0;p=r?t%r:t}function mr(t){return typeof t=="function"}var N_="object",Zkt="undefined";function eV(t,r){for(var n in r)if(!(n==="__proto__"||n==="constructor")){var i=r[n],o=typeof i,a=void 0;if(o===N_&&i!==null?a=i.constructor:a=null,a&&a!==Array)if(i instanceof Date)t[n]=new Date(i.getTime());else if(mr(i.clone))t[n]=i.clone();else{var s=t[n];typeof s===N_?t[n]=s||{}:t[n]={},eV(t[n],i)}else o!==Zkt&&(t[n]=i)}return t}function zt(t){for(var r=arguments,n=arguments.length,i=1;i0;)n[i]=arguments[i+1];return this.observer[r].apply(this.observer,n)};fo.prototype.requiresHandlers=function(r){var n=this;if(this.observer.requiresHandlers)return this.observer.requiresHandlers(r);for(var i=0;i0?Math.ceil(r):Math.floor(r),r}var en=KSt,O0=en.append,nc=en.bindEvents,ne=en.defined,Ns=en.deg,wl=en.elementOffset,Ia=en.elementSize,oV=en.eventCoordinates,vo=en.eventElement,i_t=en.hashKey,Pr=en.last,Xe=en.limitValue,n_t=en.objectKey,qr=en.rad,Ee=en.round,oc=en.unbindEvents,t1=en.valueOrDefault,u0=function(){};u0.fetchFonts=function(r,n,i){i===void 0&&(i={depth:0});var o=5;!r||i.depth>o||!document.fonts||Object.keys(r).forEach(function(a){var s=r[a];a==="dataSource"||a[0]==="$"||!s||(a==="font"?n.push(s):typeof s=="object"&&(i.depth++,u0.fetchFonts(s,n,i),i.depth--))})};u0.loadFonts=function(r,n){var i=[];if(r.length>0&&document.fonts){try{i=r.map(function(o){return document.fonts.load(o)})}catch(o){fT(o)}Promise.all(i).then(n,n)}else n()};u0.preloadFonts=function(r,n){var i=[];u0.fetchFonts(r,i),u0.loadFonts(i,n)};function ve(t,r){var n=t.prototype;n.options?n.options=zt({},n.options,r):n.options=r}var o_t="k-icon",fv="k-i-",a_t="k-font-icon",s_t="k-svg-icon",W_="k-svg-i-",Yl=function(r,n){this.element=r,this.options=zt({},this.options,n),this.wrapper()};Yl.prototype.wrapper=function(){this.addClasses()};Yl.prototype.addClasses=function(){};Yl.prototype.html=function(){return this.element.outerHTML};ve(Yl,{name:"",size:"none",themeColor:"none",flip:"default",iconClass:"",stylingOptions:["size","themeColor","fill"]});var aV=function(t){function r(n,i){t.call(this,n,i)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.wrapper=function(){var i=this.element.className.split(" ").find(function(a){return a.startsWith(fv)}),o=this.options.icon?""+(this.options.icon.startsWith(fv)?"":fv)+this.options.icon:"";this._className=o,Ir(this.element,o_t),Ir(this.element,a_t),Ab(this.element,i),Ir(this.element,o),Ir(this.element,this.options.iconClass||""),t.prototype.wrapper.call(this)},r}(Yl);ve(aV,{name:"HTMLFontIcon",icon:null});var sV=function(t){function r(n,i){n.innerHTML="",t.call(this,n,i)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.wrapper=function(){var i=this.options.icon,o=this.options.iconClass,a=this.element.className.split(" ").find(function(f){return f.startsWith(W_)});if(!i&&o){var s=/k-i-(\w+(?:-\w+)*)/,l=o.match(s);l&&(i=l[1],o=o.replace(l[0],""))}Bn(i)&&(i=i.replace("k-i-","").replace(/-./g,function(f){return f[1].toUpperCase()}),i=this.options.svgIcons[i]||this.options.svgIcons[i+"Icon"]);var h=i&&i.name?""+W_+i.name:"";if(this._className=h,Ir(this.element,s_t),Ab(this.element,a),Ir(this.element,h),Ir(this.element,o||""),this.element.setAttribute("aria-hidden","true"),i&&e_t(i)){var p=document.createElementNS("http://www.w3.org/2000/svg","svg");p.setAttribute("viewBox",i.viewBox||""),p.setAttribute("focusable","false"),p.innerHTML=i.content||"",this.element.appendChild(p)}t.prototype.wrapper.call(this)},r}(Yl);ve(sV,{name:"HTMLSvgIcon",icon:null,svgIcons:{}});var j_={svg:sV,font:aV};function U3(t,r){var n=t,i=r;return(!n||$2(n)&&!(n instanceof HTMLElement)||Bn(n))&&(i=n,n=document.createElement("span")),Bn(i)&&(i={icon:i}),i.type||(i.type="svg"),j_[i.type]?new j_[i.type](n,i).html():null}function gm(t){for(var r=Vr,n=Zr,i=0,o=t.length;i=this.height&&(this.height=r+1),n>=this.width&&(this.width=n+1)};fi.prototype.each=function(r,n){for(var i=this,o=0;o=0;)for(var o=n[i]=new Array(r),a=r;--a>=0;)o[a]=i===a?1:0;return this};fi.prototype.multiply=function(r){for(var n=this,i=new fi,o=0;o=0;)for(var g=f;--g>=0;)if(i[g][f])for(var b=2*r;--b>=r;)i[g][b]-=i[f][b]*i[g][f];return n.slice(0,r,r,r)};fi.prototype.augment=function(r){var n=this.clone(),i=n.width;return r.each(function(o,a,s){n.set(a,s+i,o)}),n};fi.prototype.slice=function(r,n,i,o){for(var a=this,s=new fi,l=0;li&&(i=s,o=t)}return o}var X3={down:"pointerdown",move:"pointermove",up:"pointerup",cancel:"pointercancel pointerleave"};function d_t(t){return X3[t]||t}var Do=function(t){var r=/([^ ]+)/g,n=t.replace(r,d_t);return n};function N8(){var t="",r,n;for(r=0;r<32;r++)n=Math.random()*16|0,(r===8||r===12||r===16||r===20)&&(t+="-"),t+=(r===12?4:r===16?n&3|8:n).toString(16);return t}var mm=new WeakMap,Qu=Symbol("id");function En(t,r,n,i,o){v_t(t,r,n,i,o)}function Jn(t,r,n,i,o){m_t(t,r,n,i)}function f_t(t){return typeof t=="string"}function v_t(t,r,n,i,o){var a=zi(r)?r:(r||"").split(" ");a.forEach(function(s){g_t(t,s,n,i,o)})}function g_t(t,r,n,i,o){var a=i,s;n&&mr(n)&&!i?a=n:n&&f_t(n)&&mr(a)&&(s=n);var l=function(p){var f=p.target?p.target.closest(s):null;if(!s||s&&p.target&&f){var g=s?f:p.currentTarget;Object.defineProperty(p,"currentTarget",{value:g}),Object.defineProperty(p,"delegateTarget",{value:t}),a(p)}};a[Qu]=N8();var h=mm.get(t);h||(h=new Map,mm.set(t,h)),h.set(a[Qu],l),t.addEventListener(r,l,!!o)}function m_t(t,r,n,i){var o=zi(r)?r:(r||"").split(" ");o.forEach(function(a){y_t(t,a,n,i)})}function y_t(t,r,n,i){var o=mm.get(t);if(o&&n&&n[Qu]){var a=n[Qu],s=o.get(a);o.delete(a),s&&t.removeEventListener(r,s,!!i)}}function $8(){var t=x_t(navigator.userAgent),r={};return r.mobileOS=t,r}function x_t(t){var r=!1,n={wp:/(Windows Phone(?: OS)?)\s(\d+)\.(\d+(\.\d+)?)/,fire:/(Silk)\/(\d+)\.(\d+(\.\d+)?)/,android:/(Android|Android.*(?:Opera|Firefox).*?\/)\s*(\d+)\.?(\d+(\.\d+)?)?/,iphone:/(iPhone|iPod).*OS\s+(\d+)[\._]([\d\._]+)/,ipad:/(iPad).*OS\s+(\d+)[\._]([\d_]+)/,playbook:/(PlayBook).*?Tablet\s*OS\s*(\d+)\.(\d+(\.\d+)?)/,windows:/(MSIE)\s+(\d+)\.(\d+(\.\d+)?)/,tizen:/(tizen).*?Version\/(\d+)\.(\d+(\.\d+)?)/i,sailfish:/(sailfish).*rv:(\d+)\.(\d+(\.\d+)?).*firefox/i},i={ios:/^i(phone|pad|pod)$/i,android:/^android|fire$/i,windows:/windows/,wp:/wp/,flat:/sailfish|ffos|tizen/i};for(var o in n){var a=t.match(n[o]);if(a){if(o==="windows"&&"plugins"in navigator)return!1;r={},r.device=o,r.name=b_t(o,i),r[r.name]=!0;break}}return r}function b_t(t,r,n){for(var i in r)if(r[i].test(t))return i;return n!==void 0?n:t}function Y_(){}function l4(){return new Date().getTime()}var X_="string",K_="function",w_t=function(){this._defaultPrevented=!0},C_t=function(){return this._defaultPrevented===!0},U2=function(t){function r(){t.call(this),this._events={}}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.destroy=function(){this.unbind()},r.prototype.bind=function(i,o,a){var s=this,l,h=typeof i===X_?[i]:i||[],p,f,g,b=typeof o===K_,z;if(o===void 0){for(l in i)s.bind(l,i[l]);return s}var M=function(){var I=h[l];g=b?o:o[I],g&&(a&&(f=g,g=function(){s.unbind(I,g),f.apply(s,arguments)},g.original=f),z=s._events[I]=s._events[I]||[],z.push(g))};for(l=0,p=h.length;l=0;l--)(s[l]===o||s[l].original===o)&&s.splice(l,1);else a._events[i]=[];return a},r.prototype._setEvents=function(i){for(var o=this,a=(this.events||[]).length,s=0;s1},r.prototype._maxTouchesReached=function(){return this.touches.length>=this._maxTouches},r.prototype._disposeAll=function(){for(var i=this.touches;i.length>0;)i.pop().dispose()},r.prototype._isMoved=function(){return a2(this.touches,function(i){return i.isMoved()}).length},r.prototype._select=function(i){(!this.allowSelection||this.trigger(J_,{event:i}))&&i.preventDefault()},r.prototype._start=function(i){var o=this,a=0,s=o.filter,l,h=iA(i),p=h.length,f,g=i.which;if(!(g&&g>1||o._maxTouchesReached()))for(r.current=null,o.currentTarget=i.currentTarget,o.stopPropagation&&i.stopPropagation();a=this.x1&&i.x<=this.x2&&i.y>=this.y1&&i.y<=this.y2},r.prototype.points=function(){return[new Qe(this.x1,this.y1),new Qe(this.x2,this.y1),new Qe(this.x2,this.y2),new Qe(this.x1,this.y2)]},r.prototype.getHash=function(){return[this.x1,this.y1,this.x2,this.y2].join(",")},r.prototype.overlaps=function(i){return!(i.y2=a*a&&F<=s*s},r.prototype.getBBox=function(){var i=this,o=new Ce(Vr,Vr,Zr,Zr),a=Ee(this.startAngle%360),s=Ee((a+this.angle)%360),l=this.innerRadius,h=[0,90,180,270,a,s].sort(L_t),p=h.indexOf(a),f=h.indexOf(s),g;a===s?g=h:p0&&a===s)&&(s+=E_t);var l=new ye(i.center.x,i.center.y),h=Math.max(i.radius,0),p=Math.max(i.innerRadius,0),f=new s4(l,{startAngle:a,endAngle:s,radiusX:h,radiusY:h}),g=$e.fromArc(f,o).close();if(p){f.radiusX=f.radiusY=p;var b=f.pointAt(s);g.lineTo(b.x,b.y),g.arc(s,a,p,p,!0)}else g.lineTo(l.x,l.y);return g},r}(Ve);Cl.current=new Cl;var V1=function(t){function r(n){t.call(this),this.children=[],this.options=zt({},this.options,this.initUserOptions(n))}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.initUserOptions=function(i){return i},r.prototype.reflow=function(i){for(var o=this.children,a,s=0;so)break}this.visual.insert(l,i)},r.prototype.traverse=function(i){for(var o=this.children,a=o.length,s=0;s0&&g.width()>0})[0]}var yV=function(t){function r(n){t.call(this,n);var i=this.options;i.width=parseInt(i.width,10),i.height=parseInt(i.height,10),this.gradients={}}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.reflow=function(){var i=this,o=i.options,a=i.children,s=new Ce(0,0,o.width,o.height);this.box=s.unpad(o.margin);for(var l=0;lg&&(z.push({groupElements:E,groupSize:M,groupElementsSize:I}),H=Math.max(H,I),F+=f+M,M=0,I=0,E=[]),M=Math.max(M,$[h]),I>0&&(I+=p),I+=$[l],E.push(W)}return z.push({groupElements:E,groupSize:M,groupElementsSize:I}),H=Math.max(H,I),F+=M,{groups:z,groupsSize:F,maxGroupElementsSize:H}},r.prototype.elementSize=function(i){return{width:i.box.width(),height:i.box.height()}},r.prototype.createVisual=function(){},r}(V1);ve(Mp,{vertical:!0,wrap:!0,vSpacing:0,spacing:0});var T_t=BT,xV=function(t){function r(n,i){t.call(this,i),this.content=n,this.reflow(new Ce)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.reflow=function(i){var o=this.options,a=o.size=xp(this.content,{font:o.font});this.baseline=a.baseline,this.box=new Ce(i.x1,i.y1,i.x1+a.width,i.y1+a.height)},r.prototype.createVisual=function(){var i=this.options,o=i.font,a=i.color,s=i.opacity,l=i.cursor,h=i.stroke,p=i.paintOrder;this.visual=new T_t(this.content,this.box.toRect().topLeft(),{font:o,fill:{color:a,opacity:s},cursor:l,stroke:h,paintOrder:p})},r}(V1);ve(xV,{font:sT,color:kr});function Sl(t){var r=t.origin,n=t.bottomRight();return new Ce(r.x,r.y,n.x,n.y)}var V_t=/\n/m,Nn=function(t){function r(n,i,o){t.call(this,i),this.content=n,this.data=o,this._initContainer(),this.options._autoReflow!==!1&&this.reflow(new Ce)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype._initContainer=function(){var i=this.options,o=String(this.content).split(V_t),a=new Mp({vertical:!0,align:i.align,wrap:!1}),s=zt({},i,{opacity:1,animation:null});this.container=a,this.append(a);for(var l=0;l0;)n[i]=arguments[i+1];var o=this.intl;return Bn(r)&&r.match(cT)?o.format.apply(o,[r].concat(n)):o.toString(n[0],r)};_p.prototype.localeAuto=function(r,n,i){var o=this.intl,a;return Bn(r)&&r.match(cT)?a=r.replace(O_t,function(s,l,h){var p=n[parseInt(l,10)];return o.toString(p,h?h.substring(1):"",i)}):a=o.toString(n[0],r,i),a};Object.defineProperties(_p.prototype,Xb);var Kl=function(r,n){n===void 0&&(n={}),this._intlService=n.intlService,this.sender=n.sender||r,this.format=new _p(n.intlService),this.chart=r,this.rtl=!!n.rtl},Kb={intl:{configurable:!0}};Kb.intl.get=function(){return this._intlService||kp.implementation};Kb.intl.set=function(t){this._intlService=t,this.format.intl=t};Kl.prototype.notify=function(r,n){this.chart&&this.chart.trigger(r,n)};Kl.prototype.isPannable=function(r){var n=((this.chart||{}).options||{}).pannable;return n&&n.lock!==r};Object.defineProperties(Kl.prototype,Kb);var bm,Ap=function(){};Ap.register=function(r){bm=r};Ap.create=function(r,n){var i;return bm?i=bm.create(r,n):i=new e9(r,Object.assign({},{multiTouch:!0},n)),i};function CV(t,r){var n=t.tickX,i=t.tickY,o=t.position,a=new $e({stroke:{width:r.width,color:r.color}});return t.vertical?a.moveTo(n,o).lineTo(n+r.size,o):a.moveTo(o,i).lineTo(o,i+r.size),o2(a),a}function SV(t,r){var n=t.lineStart,i=t.lineEnd,o=t.position,a=new $e({stroke:{width:r.width,color:r.color,dashType:r.dashType}});return t.vertical?a.moveTo(n,o).lineTo(i,o):a.moveTo(o,n).lineTo(o,i),o2(a),a}var ql=function(t){function r(n,i){i===void 0&&(i=new Kl),t.call(this,n),this.chartService=i,this.options.visible||(this.options=zt({},this.options,{labels:{visible:!1},line:{visible:!1},margin:0,majorTickSize:0,minorTickSize:0})),this.options.minorTicks=zt({},{color:this.options.line.color,width:this.options.line.width,visible:this.options.minorTickType!==om},this.options.minorTicks,{size:this.options.minorTickSize,align:this.options.minorTickType}),this.options.majorTicks=zt({},{color:this.options.line.color,width:this.options.line.width,visible:this.options.majorTickType!==om},this.options.majorTicks,{size:this.options.majorTickSize,align:this.options.majorTickType}),this.initFields(),this.options._deferLabels||this.createLabels(),this.createTitle(),this.createNotes()}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.initFields=function(){},r.prototype.labelsRange=function(){return{min:this.options.labels.skip,max:this.labelsCount()}},r.prototype.normalizeLabelRotation=function(i){var o=i.rotation;$2(o)&&(i.alignRotation=o.align,i.rotation=o.angle)},r.prototype.createLabels=function(){var i=this,o=this.options,a=o.vertical?S1:a1,s=zt({},o.labels,{align:a,zIndex:o.zIndex}),l=Math.max(1,s.step);if(this.clearLabels(),s.visible){this.normalizeLabelRotation(s),s.rotation==="auto"&&(s.rotation=0,o.autoRotateLabels=!0);for(var h=this.labelsRange(),p=h.min;p0&&o.visible){var s=new $e({stroke:{width:o.width,color:o.color,dashType:o.dashType}});s.moveTo(a.x1,a.y1).lineTo(a.x2,a.y2),i._alignLines&&o2(s);var l=this._lineGroup=new H1;l.append(s),this.visual.append(l),this.createTicks(l)}},r.prototype.getActualTickSize=function(){var i=this.options,o=0;return i.majorTicks.visible&&i.minorTicks.visible?o=Math.max(i.majorTicks.size,i.minorTicks.size):i.majorTicks.visible?o=i.majorTicks.size:i.minorTicks.visible&&(o=i.minorTicks.size),o},r.prototype.createBackground=function(){var i=this,o=i.options,a=i.box,s=o.background;s&&(this._backgroundPath=$e.fromRect(a.toRect(),{fill:{color:s},stroke:null}),this.visual.append(this._backgroundPath))},r.prototype.createPlotBands=function(){var i=this,o=this.options,a=o.plotBands||[],s=o.vertical,l=this.plotArea;if(a.length!==0){for(var h=this._plotbandGroup=new H1({zIndex:-1}),p=a2(this.pane.axes,function(E){return E.options.vertical!==i.options.vertical})[0],f=0;fo?-90:-45},r.prototype.autoRotateLabels=function(){var i=this;if(!this.options.autoRotateLabels||this.options.vertical)return!1;for(var o=this.getMajorTickPositions(),a=this.labels,s=Math.min(a.length,o.length-1),l=0,h=0;h0&&(!ne(h.max)||s<=h.max))return null;if(o0||ss&&l>0&&(g=Xe(o,a,s),f=Xe(o-p,a,s-p)),{min:f,max:g}},r.prototype.valueRange=function(){return{min:this.seriesMin,max:this.seriesMax}},r.prototype.lineDir=function(){var i=this.options,o=i.vertical,a=i.reverse;return(o?-1:1)*(a?-1:1)},r.prototype.lineInfo=function(){var i=this.options,o=i.vertical,a=this.lineBox(),s=o?a.height():a.width(),l=o?We:Ne,h=this.lineDir(),p=h===1?1:2,f=l+p.toString(),g=a[f];return{axis:l,axisOrigin:f,axisDir:h,lineBox:a,lineSize:s,lineStart:g}},r.prototype.pointOffset=function(i){var o=this.lineInfo(),a=o.axis,s=o.axisDir,l=o.axisOrigin,h=o.lineBox,p=o.lineSize,f=s>0?i[a]-h[l]:h[l]-i[a],g=f/p;return g},r.prototype.scaleToDelta=function(i,o){var a=.999,s=Xe(i,-a,a),l;return s>0?l=o*Math.min(1,s):l=o-o/(1+s),l},r.prototype.labelsBetweenTicks=function(){return!this.options.justified},r.prototype.prepareUserOptions=function(){},r}(V1);ve(ql,{labels:{visible:!0,rotation:0,mirror:!1,step:1,skip:0},line:{width:1,color:kr,visible:!0},title:{visible:!0,position:a1},majorTicks:{align:S7,size:4,skip:0,step:1},minorTicks:{align:S7,size:3,skip:0,step:1},axisCrossingValue:0,majorTickType:S7,minorTickType:om,majorGridLines:{skip:0,step:1},minorGridLines:{visible:!1,width:1,color:kr,skip:0,step:1},margin:5,visible:!0,reverse:!1,justified:!0,notes:{label:{text:""}},_alignLines:!0,_deferLabels:!1});var r9="milliseconds",qb="seconds",Zb="minutes",j8="hours",qo="days",G8="weeks",A0="months",Ka="years",B_t=1,Jb=1e3,Zl=60*Jb,Lp=60*Zl,qa=24*Lp,Qb=7*qa,tw=31*qa,ew=365*qa,Oo={years:ew,months:tw,weeks:Qb,days:qa,hours:Lp,minutes:Zl,seconds:Jb,milliseconds:B_t};function rw(t,r){var n=t.getTime()-r,i=t.getTimezoneOffset()-r.getTimezoneOffset();return n-i*Zl}function ci(t,r){return new Date(t.getTime()+r)}function Z1(t){var r;return t instanceof Date?r=t:t&&(r=new Date(t)),r}function N_t(t,r){r===void 0&&(r=0);var n=0,i=t.getDay();if(!isNaN(i))for(;i!==r;)i===0?i=6:i--,n++;return ci(t,-n*qa)}function Nh(t,r){return r===0&&t.getHours()===23?(t.setHours(t.getHours()+2),!0):!1}function $_t(t,r){var n=new Date(t);n.setMinutes(0,0,0);var i=(t.getTimezoneOffset()-n.getTimezoneOffset())*Zl;return ci(n,i+r*Lp)}function Hi(t,r,n,i){var o=t;if(t){var a=Z1(t),s=a.getHours();n===Ka?(o=new Date(a.getFullYear()+r,0,1),Nh(o,0)):n===A0?(o=new Date(a.getFullYear(),a.getMonth()+r,1),Nh(o,s)):n===G8?(o=Hi(N_t(a,i),r*7,qo),Nh(o,s)):n===qo?(o=new Date(a.getFullYear(),a.getMonth(),a.getDate()+r),Nh(o,s)):n===j8?o=$_t(a,r):n===Zb?(o=ci(a,r*Zl),o.getSeconds()>0&&o.setSeconds(0)):n===qb?o=ci(a,r*Jb):n===r9&&(o=ci(a,r)),n!==r9&&o.getMilliseconds()>0&&o.setMilliseconds(0)}return o}function iw(t,r,n){return Hi(Z1(t),0,r,n)}function zV(t,r,n){var i=Z1(t);return i&&iw(i,r,n).getTime()===i.getTime()?i:Hi(i,1,r,n)}function i9(t,r){return t&&r?t.getTime()-r.getTime():-1}function Bo(t,r){return t.getTime()-r}function J1(t){if(zi(t)){for(var r=[],n=0;n0){var s=this.options.vertical?We:Ne,l=o[s+1],h=o[s+2],p=a[0],f=Pr(a);(p.box[s+1]>h||p.box[s+2]h||f.box[s+2]=0;)p--;return i.slice(h,p+1)},r.prototype.lineInfo=function(){var i=this.options,o=i.vertical,a=i.reverse,s=this.lineBox(),l=o?s.height():s.width(),h=o?We:Ne,p=a?-1:1,f=p===1?1:2,g=h+f.toString(),b=s[g];return{axis:h,axisOrigin:g,axisDir:p,lineBox:s,lineSize:l,lineStart:b}},r.prototype.lineDir=function(){var i=this.options,o=i.reverse;return o?-1:1},r.prototype.getSlot=function(i,o,a){var s=this.options,l=s.reverse,h=s.justified,p=this.scaleOptions(),f=p.scale,g=p.box,b=p.min,z=this.lineInfo(),M=z.axis,I=z.lineStart,F=g.clone(),H=!ne(o),E=t1(i,0),R=t1(o,E);R=Math.max(R-1,E),R=Math.max(E,R);var W=I+(E-b)*f,$=I+(R+1-b)*f;return H&&h&&($=W),a&&(W=Xe(W,g[M+1],g[M+2]),$=Xe($,g[M+1],g[M+2])),F[M+1]=l?$:W,F[M+2]=l?W:$,F},r.prototype.limitSlot=function(i){var o=this.options.vertical,a=o?We:Ne,s=this.lineBox(),l=i.clone();return l[a+1]=Xe(i[a+1],s[a+1],s[a+2]),l[a+2]=Xe(i[a+2],s[a+1],s[a+2]),l},r.prototype.slot=function(i,o,a){var s=Math.floor(this.options.min||0),l=i,h=o;return typeof l=="string"?l=this.categoryIndex(l):y1(l)&&(l-=s),typeof h=="string"?h=this.categoryIndex(h):y1(h)&&(h-=s),t.prototype.slot.call(this,l,h,a)},r.prototype.pointCategoryIndex=function(i){var o=this.options,a=o.reverse,s=o.justified,l=o.vertical,h=l?We:Ne,p=this.scaleOptions(),f=p.scale,g=p.box,b=p.min,z=p.max,M=a?z:b,I=g[h+1],F=g[h+2],H=i[h];if(HF)return null;var E=M+(H-I)/f,R=E%1;return s?E=Math.round(E):R===0&&E>0&&E--,Math.floor(E)},r.prototype.getCategory=function(i){var o=this.pointCategoryIndex(i);return o===null?null:this.options.categories[o]},r.prototype.categoryIndex=function(i){return this.totalIndex(i)-Math.floor(this.options.min||0)},r.prototype.categoryAt=function(i,o){var a=this.options;return(o?a.srcCategories:a.categories)[i]},r.prototype.categoriesCount=function(){return(this.options.categories||[]).length},r.prototype.translateRange=function(i){var o=this.options,a=this.lineBox(),s=o.vertical?a.height():a.width(),l=o.categories.length,h=s/l,p=Ee(i/h,U1);return{min:p,max:l+p}},r.prototype.scaleRange=function(i,o){var a=Math.abs(this.pointOffset(o)),s=this.limitedRangeIndices(),l=s.max-s.min,h=this.scaleToDelta(i,l),p=a*h,f=(1-a)*h,g=s.min+p,b=s.max-f;return b-ga.skip?f=a.skip+a.step*Math.ceil((l-a.skip)/a.step):f=a.skip,{min:f-p,max:(i.categories.length?h+(o?1:0):0)-p}},r.prototype.createAxisLabel=function(i,o,a){var s=this.options,l=s.dataItems?s.dataItems[i]:null,h=t1(s.categories[i],"");a.dataItem=l;var p=this.axisLabelText(h,o,a);return new h4(h,p,i,l,o)},r.prototype.shouldRenderNote=function(i){var o=this.limitedRangeIndices();return Math.floor(o.min)<=i&&i<=Math.ceil(o.max)},r.prototype.noteSlot=function(i){var o=this.options,a=i-Math.floor(o.min||0);return this.getSlot(a)},r.prototype.arrangeNotes=function(){t.prototype.arrangeNotes.call(this),this.hideOutOfRangeNotes()},r.prototype.hideOutOfRangeNotes=function(){var i=this,o=i.notes,a=i.box;if(o&&o.length)for(var s=this.options.vertical?We:Ne,l=a[s+1],h=a[s+2],p=0;p=W_t)return{min:E,max:R}},r.prototype.valueRange=function(){return this.range()},r.prototype.totalIndex=function(i){var o=this.options,a=this._categoriesMap?this._categoriesMap.get(i):j_t(i,o.srcCategories);return a},r.prototype.currentRangeIndices=function(){var i=this.options,o=0;y1(i.min)&&(o=Math.floor(i.min));var a;return y1(i.max)?a=i.justified?Math.floor(i.max):Math.ceil(i.max)-1:a=this.totalCount()-1,{min:o,max:a}},r.prototype.limitedRangeIndices=function(i){var o=this.options,a=y1(o.min)?o.min:0,s;if(y1(o.max)?s=o.max:y1(o.min)?s=a+o.categories.length:s=this.totalRange().max||1,i){var l=this.totalRange();a=Xe(a,0,l.max),s=Xe(s,0,l.max)}return{min:a,max:s}},r.prototype.totalRangeIndices=function(){return{min:0,max:this.totalRange().max||1}},r.prototype.indexCategories=function(){if(!this._categoriesMap)for(var i=this._categoriesMap=new Wb,o=this.options.srcCategories,a=0;a=s;){b=b||a[p].slice(0);do M=b.shift();while(M&&r===p&&Ms&&(z=Math.ceil(g/s));break}}t.baseUnitStep=z,t.baseUnit=p}function U_t(t){for(var r=t.categories,n=ne(r)?r.length:0,i=Vr,o,a,s=0;s=ew?a=Ka:i>=tw-qa*3?a=A0:i>=Qb?a=G8:i>=qa?a=qo:i>=Lp?a=j8:i>=Zl?a=Zb:a=qb)}o=l}t.baseUnit=a||qo}function Y_t(t){var r=(t.baseUnit||"").toLowerCase(),n=r!==o9&&!c1(r,Ha);return n&&U_t(t),(r===o9||t.baseUnitStep===G_t)&&LV(t),t}var U8=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.clone=function(){var i=new r(Object.assign({},this.options),this.chartService);return i.createLabels(),i},r.prototype.categoriesHash=function(){var i=this.dataRange.total().min;return this.options.baseUnit+this.options.baseUnitStep+i},r.prototype.initUserOptions=function(i){return i},r.prototype.initFields=function(){t.prototype.initFields.call(this);var i=this.chartService,o=i.intl,a=this.options,s=a.categories||[];if(s._parsed||(s=MV(o,s),s._parsed=!0),a=zt({roundToBaseUnit:!0},a,{categories:s,min:Ci(o,a.min),max:Ci(o,a.max),weekStartDay:kV(a,o)}),i.panning&&i.isPannable(a.vertical?We:Ne)&&(a.roundToBaseUnit=!1),a.userSetBaseUnit=a.userSetBaseUnit||a.baseUnit,a.userSetBaseUnitStep=a.userSetBaseUnitStep||a.baseUnitStep,this.options=a,a.srcCategories=s,s.length>0){var l=k7(s,!0),h=a.maxDivisions,p=Y_t(a),f=a._forecast;if(f&&(f.before>0&&(l.min=Hi(l.min,-f.before,p.baseUnit,p.weekStartDay)),f.after>0&&(l.max=Hi(l.max,f.after,p.baseUnit,p.weekStartDay))),this.dataRange=new vn(l.min,l.max,p),h){var g=this.dataRange.displayRange(),b=Object.assign({},a,{justified:!0,roundToBaseUnit:!1,baseUnit:"fit",min:g.min,max:g.max,maxDateGroups:h}),z=this.dataRange.options;LV(b,z.baseUnit,z.baseUnitStep),this.divisionRange=new vn(l.min,l.max,b)}else this.divisionRange=this.dataRange}else a.baseUnit=a.baseUnit||qo,this.dataRange=this.divisionRange=new wo(a);this.rangeLabels=[]},r.prototype.tickIndices=function(i){var o=this,a=o.dataRange,s=o.divisionRange,l=s.valuesCount();if(!this.options.maxDivisions||!l)return t.prototype.tickIndices.call(this,i);var h=[],p=s.values(),f=0;this.options.justified||(p=p.concat(s.dateAt(l)),f=.5);for(var g=0;g=1){var b=h.length-1;h.splice(g,0,h[b-1]+(h[b]-h[b-1])*i)}return h},r.prototype.shouldRenderNote=function(i){var o=this.range(),a=this.options.categories||[];return i9(i,o.min)>=0&&i9(i,o.max)<=0&&a.length},r.prototype.parseNoteValue=function(i){return Ci(this.chartService.intl,i)},r.prototype.noteSlot=function(i){return this.getSlot(i)},r.prototype.translateRange=function(i){var o=this.options,a=o.baseUnit,s=o.weekStartDay,l=o.vertical,h=this.lineBox(),p=l?h.height():h.width(),f=this.range(),g=p/(f.max-f.min),b=Ee(i/g,U1);if(f.min&&f.max){var z=ci(o.min||f.min,b),M=ci(o.max||f.max,b);f={min:Hi(z,0,a,s),max:Hi(M,0,a,s)}}return f},r.prototype.labelsRange=function(){return{min:this.options.labels.skip,max:this.divisionRange.valuesCount()}},r.prototype.pan=function(i){if(this.isEmpty())return null;var o=this.options,a=this.lineBox(),s=o.vertical?a.height():a.width(),l=this.dataRange.displayRange(),h=l.min,p=l.max,f=this.dataRange.total(),g=s/(p-h),b=Ee(i/g,U1)*(o.reverse?-1:1),z=ci(h,b),M=ci(p,b),I=this.limitRange(J1(z),J1(M),J1(f.min),J1(f.max),b);if(I)return I.min=Z1(I.min),I.max=Z1(I.max),I.baseUnit=o.baseUnit,I.baseUnitStep=o.baseUnitStep||1,I.userSetBaseUnit=o.userSetBaseUnit,I.userSetBaseUnitStep=o.userSetBaseUnitStep,I},r.prototype.pointsRange=function(i,o){if(this.isEmpty())return null;var a=t.prototype.pointsRange.call(this,i,o),s=this.dataRange.displayRange(),l=this.dataRange.displayIndices(),h=Bo(s.max,s.min)/(l.max-l.min),p=this.options,f=ci(s.min,a.min*h),g=ci(s.min,a.max*h);return{min:f,max:g,baseUnit:p.userSetBaseUnit||p.baseUnit,baseUnitStep:p.userSetBaseUnitStep||p.baseUnitStep}},r.prototype.scaleRange=function(i,o){if(this.isEmpty())return{};var a=this.options,s=a.userSetBaseUnit===o9,l=this.dataRange.total(),h=this.dataRange.displayRange(),p=h.min,f=h.max,g=Math.abs(this.pointOffset(o)),b=f-p,z=this.scaleToDelta(i,b),M=Math.round(g*z),I=Math.round((1-g)*z),F=this.dataRange.options,H=F.baseUnit,E=new Date(p.getTime()+M),R=new Date(f.getTime()-I);if(s){var W=a.autoBaseUnitSteps,$=a.maxDateGroups,G=Pr(W[H])*$*Oo[H],Z=Bo(f,p),K=Bo(R,E),et=Ha.indexOf(H),at,tt;if(KG&&H!==Ka){var ft=0;do{et++,H=Ha[et],ft=0,tt=2*Oo[H];do at=W[H][ft],ft++;while(ft0&&(E=ci(p,-tt),R=ci(f,tt),E=ci(E,Xe(R,l.min,l.max)-R),R=ci(R,Xe(E,l.min,l.max)-E))}}if(E&&R&&Bo(R,E)>0)return{min:E,max:R,baseUnit:a.userSetBaseUnit||a.baseUnit,baseUnitStep:a.userSetBaseUnitStep||a.baseUnitStep}},r.prototype.zoomRange=function(i,o){var a=this.dataRange.total(),s=this.scaleRange(i,o);return s&&(s.mina.max&&(s.max=a.max)),s},r.prototype.range=function(){return this.dataRange.displayRange()},r.prototype.createLabels=function(){t.prototype.createLabels.call(this),this.createRangeLabels()},r.prototype.clearLabels=function(){t.prototype.clearLabels.call(this),this.rangeLabels=[]},r.prototype.arrangeLabels=function(){this.arrangeRangeLabels(),t.prototype.arrangeLabels.call(this)},r.prototype.arrangeRangeLabels=function(){var i=this,o=i.options,a=i.rangeLabels;if(a.length!==0){var s=this.lineBox(),l=o.vertical,h=o.rangeLabels.mirror||o.labels.mirror,p=a[0];if(p){var f=l?s.y1-p.box.height()/2:s.x1;this.positionLabel(p,h,f)}var g=a[1];if(g){var b=l?s.y2-g.box.height()/2:s.x2;this.positionLabel(g,h,b)}}},r.prototype.autoRotateLabels=function(){t.prototype.autoRotateLabels.call(this),this.autoRotateRangeLabels()},r.prototype.hideOutOfRangeLabels=function(){t.prototype.hideOutOfRangeLabels.call(this),this.hideOverlappingLabels()},r.prototype.hideOverlappingLabels=function(){var i=this,o=i.rangeLabels,a=i.labels;if(o.length===0)return;function s(z,M){return!M.options.visible||M.box.overlaps(z.box)?(M.options.visible=!1,!0):!1}var l=o[0];if(l&&l.options.visible)for(var h=0;h0;--g){var b=s(f,a[g]);if(!b)break}},r.prototype.contentBox=function(){for(var i=t.prototype.contentBox.call(this),o=this.rangeLabels,a=0;a=0&&r>=0){var o=t===r?0:t,a=(r-o)/r;if(n===!1||!n&&a>AV)return 0;i=Math.max(0,o-(r-o)/2)}else i=t;return i}function K_t(t,r,n){if(!t&&!r)return 1;var i;if(t<=0&&r<=0){var o=t===r?0:r,a=Math.abs((o-t)/o);if(n===!1||!n&&a>AV)return 0;i=Math.min(0,o-(t-o)/2)}else i=r;return i}function EV(t,r){return Ee(Math.floor(t/r)*r,U1)}function a9(t,r){return Ee(Math.ceil(t/r)*r,U1)}function s9(t){return Math.max(Math.min(t,hA),-hA)}var vv=Math.pow(10,-U1+1),T2=function(t){function r(n,i,o,a){t.call(this,Object.assign({},o,{seriesMin:n,seriesMax:i}),a)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.initUserOptions=function(i){var o=q_t(i.seriesMin,i.seriesMax,i);return this.totalOptions=Z_t(o,i),Q_t(o,i)},r.prototype.initFields=function(){this.totalMin=this.totalOptions.min,this.totalMax=this.totalOptions.max,this.totalMajorUnit=this.totalOptions.majorUnit,this.seriesMin=this.options.seriesMin,this.seriesMax=this.options.seriesMax},r.prototype.clone=function(){return new r(this.seriesMin,this.seriesMax,Object.assign({},this.options),this.chartService)},r.prototype.startValue=function(){return 0},r.prototype.range=function(){var i=this.options;return{min:i.min,max:i.max}},r.prototype.getDivisions=function(i){if(i===0)return 1;var o=this.options,a=o.max-o.min;return Math.floor(Ee(a/i,pi))+1},r.prototype.getTickPositions=function(i,o){var a=this.options,s=this.lineInfo(),l=s.axisDir,h=s.axisOrigin,p=s.lineBox,f=s.lineSize,g=a.max-a.min,b=f/g,z=i*b,M=this.getDivisions(i),I=[],F=p[h],H=0;o&&(H=o/i);for(var E=0;E0?F:H)),E[h+2]=s9(b+z*(p>0?H:F)),E},r.prototype.getValue=function(i){var o=this.options,a=Number(o.max),s=Number(o.min),l=this.pointOffset(i),h=l*(a-s);if(l<0||l>1)return null;var p=s+h;return Ee(p,U1)},r.prototype.translateRange=function(i){var o=this.options,a=o.vertical,s=o.reverse,l=o.max,h=o.min,p=this.lineInfo(),f=p.lineSize,g=l-h,b=f/g,z=Ee(i/b,U1);return(a||s)&&!(a&&s)&&(z=-z),{min:h+z,max:l+z,offset:z}},r.prototype.labelsCount=function(){return this.getDivisions(this.options.majorUnit)},r.prototype.createAxisLabel=function(i,o,a){var s=this.options,l=Ee(s.min+i*s.majorUnit,U1),h=this.axisLabelText(l,o,a);return new h4(l,h,i,null,o)},r.prototype.shouldRenderNote=function(i){var o=this.range();return o.min<=i&&i<=o.max},r.prototype.pan=function(i){var o=this.translateRange(i);return this.limitRange(o.min,o.max,this.totalMin,this.totalMax,o.offset)},r.prototype.pointsRange=function(i,o){var a=this.getValue(i),s=this.getValue(o),l=Math.min(a,s),h=Math.max(a,s);if(this.isValidRange(l,h))return{min:l,max:h}},r.prototype.scaleRange=function(i,o){var a=Math.abs(this.pointOffset(o)),s=this.options.max-this.options.min,l=this.scaleToDelta(i,s),h=a*l,p=(1-a)*l,f=Ee(this.options.min+h,U1),g=Ee(this.options.max-p,U1);return g-fvv},r}(ql);function q_t(t,r,n){var i=n.narrowRange,o=X_t(t,r,i),a=K_t(t,r,i),s=Xl(o,a),l={majorUnit:s};return n.roundToMajorUnit!==!1&&(o<0&&uA(o,s,1/3)&&(o-=s),a>0&&uA(a,s,1/3)&&(a+=s)),l.min=EV(o,s),l.max=a9(a,s),l}function Z_t(t,r){return{min:ne(r.min)?Math.min(t.min,r.min):t.min,max:ne(r.max)?Math.max(t.max,r.max):t.max,majorUnit:t.majorUnit}}function J_t(t,r){for(var n=0;n0?r.min=0:r.max=1),r.majorUnit?(t.min=EV(t.min,r.majorUnit),t.max=a9(t.max,r.majorUnit)):a&&(n=zt(t,r),t.majorUnit=Xl(n.min,n.max))}t.minorUnit=(n.majorUnit||t.majorUnit)/5;var s=zt(t,n);return s.min>=s.max&&(i&&!o?s.max=s.min+s.majorUnit:!i&&o&&(s.min=s.max-s.majorUnit)),s}function uA(t,r,n){var i=Ee(Math.abs(t%r),U1),o=r*(1-n);return i===0||i>o}ve(T2,{type:"numeric",min:0,max:1,vertical:!0,majorGridLines:{visible:!0,width:1,color:kr},labels:{format:"#.####################"},zIndex:1});var pA=1e3,IV=function(t){function r(n,i,o,a){var s=Z1(n),l=Z1(i),h=a.intl,p=o||{};p=zt(p||{},{min:Ci(h,p.min),max:Ci(h,p.max),axisCrossingValue:MV(h,p.axisCrossingValues||p.axisCrossingValue),weekStartDay:kV(p,h)}),p=eAt(s,l,p),t.call(this,p,a),this.intlService=h,this.seriesMin=s,this.seriesMax=l;var f=p.weekStartDay||0;this.totalMin=J1(iw(J1(s)-1,p.baseUnit,f)),this.totalMax=J1(zV(J1(l)+1,p.baseUnit,f))}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.clone=function(){return new r(this.seriesMin,this.seriesMax,Object.assign({},this.options),this.chartService)},r.prototype.range=function(){var i=this.options;return{min:i.min,max:i.max}},r.prototype.getDivisions=function(i){var o=this.options;return Math.floor(nw(o.min,o.max,o.baseUnit)/i+1)},r.prototype.getTickPositions=function(i){for(var o=this.options,a=this.lineInfo(),s=a.axisDir,l=a.lineSize,h=a.lineStart,p=this.getDivisions(i),f=Bo(o.max,o.min),g=l/f,b=o.weekStartDay||0,z=[h],M=1;M0&&(p=Hi(p,l,s.baseUnit,h));var f=o.dateFormats[s.baseUnit];o.format=o.format||f;var g=this.axisLabelText(p,o,a);return new h4(p,g,i,null,o)},r.prototype.translateRange=function(i){var o=this.options,a=this.lineBox(),s=o.vertical,l=o.reverse,h=s?a.height():a.width(),p=this.range(),f=h/Bo(p.max,p.min),g=Ee(i/f,U1);(s||l)&&!(s&&l)&&(g=-g);var b=ci(o.min,g),z=ci(o.max,g);return{min:b,max:z,offset:g}},r.prototype.shouldRenderNote=function(i){var o=this.range();return i9(i,o.min)>=0&&i9(i,o.max)<=0},r.prototype.pan=function(i){var o=this.translateRange(i,!0),a=this.limitRange(J1(o.min),J1(o.max),this.totalMin,this.totalMax,o.offset);if(a)return{min:Z1(a.min),max:Z1(a.max)}},r.prototype.pointsRange=function(i,o){var a=this.getValue(i),s=this.getValue(o),l=Math.min(a,s),h=Math.max(a,s);return{min:Z1(l),max:Z1(h)}},r.prototype.scaleRange=function(i,o){var a=Math.abs(this.pointOffset(o)),s=this.options.max-this.options.min,l=this.scaleToDelta(i,s),h=a*l,p=(1-a)*l,f=Z1(J1(this.options.min)+h),g=Z1(J1(this.options.max)-p);return g-f=ew?r=Ka:t>=tw?r=A0:t>=Qb?r=G8:t>=qa&&(r=qo),r}function eAt(t,r,n){var i=n.min||t,o=n.max||r,a=n.baseUnit||(o&&i?tAt(rw(o,i)):j8),s=Oo[a],l=n.weekStartDay||0,h=iw(J1(i)-1,a,l)||Z1(o),p=zV(J1(o)+1,a,l),f=n.majorUnit?n.majorUnit:void 0,g=f||a9(Xl(h.getTime(),p.getTime()),s)/s,b=nw(h,p,a),z=a9(b,g),M=z-b,I=Math.floor(M/2),F=M-I;return n.baseUnit||delete n.baseUnit,n.baseUnit=n.baseUnit||a,n.min=n.min||Hi(h,-I,a,l),n.max=n.max||Hi(p,F,a,l),n.minorUnit=n.minorUnit||g/5,n.majorUnit=g,n}ve(IV,{type:Ba,majorGridLines:{visible:!0,width:1,color:kr},labels:{dateFormats:_V}});var HV=10,dA=1e-6,Ep=function(t){function r(n,i,o,a){var s=zt({majorUnit:HV,min:n,max:i},o),l=s.majorUnit,h=nAt(i,l),p=iAt(n,i,s),f=rAt(p,h,s,o);s.max=f.max,s.min=f.min,s.minorUnit=o.minorUnit||Ee(l-1,U1),t.call(this,s,a),this.totalMin=ne(o.min)?Math.min(p,o.min):p,this.totalMax=ne(o.max)?Math.max(h,o.max):h,this.logMin=Ee(io(f.min,l),U1),this.logMax=Ee(io(f.max,l),U1),this.seriesMin=n,this.seriesMax=i,this.createLabels()}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.clone=function(){return new r(this.seriesMin,this.seriesMax,Object.assign({},this.options),this.chartService)},r.prototype.startValue=function(){return this.options.min},r.prototype.getSlot=function(i,o,a){var s=this,l=s.options,h=s.logMin,p=s.logMax,f=l.majorUnit,g=l.min,b=l.max,z=this.lineInfo(),M=z.axis,I=z.axisDir,F=z.lineBox,H=z.lineSize,E=z.lineStart,R=I*(H/(p-h)),W=t1(i,o||1),$=t1(o,i||1);if(W<=0||$<=0)return null;a&&(W=Xe(W,g,b),$=Xe($,g,b)),W=io(W,f),$=io($,f);var G=Math.min(W,$)-h,Z=Math.max(W,$)-h,K=new Ce(F.x1,F.y1,F.x1,F.y1);return K[M+1]=s9(E+R*(I>0?G:Z)),K[M+2]=s9(E+R*(I>0?Z:G)),K},r.prototype.getValue=function(i){var o=this,a=o.options,s=o.logMin,l=o.logMax,h=a.majorUnit,p=this.lineInfo(),f=p.axis,g=p.axisDir,b=p.lineStart,z=p.lineSize,M=(l-s)/z,I=g*(i[f]-b),F=I*M;if(I<0||I>z)return null;var H=s+F;return Ee(Math.pow(h,H),U1)},r.prototype.range=function(){var i=this.options;return{min:i.min,max:i.max}},r.prototype.translateRange=function(i){var o=this,a=o.options,s=o.logMin,l=o.logMax,h=a.reverse,p=a.vertical,f=a.majorUnit,g=this.lineBox(),b=p?g.height():g.width(),z=b/(l-s),M=Ee(i/z,U1);return(p||h)&&!(p&&h)&&(M=-M),{min:Math.pow(f,s+M),max:Math.pow(f,l+M),offset:M}},r.prototype.labelsCount=function(){var i=Math.floor(this.logMax),o=Math.floor(i-this.logMin)+1;return o},r.prototype.getMajorTickPositions=function(){var i=[];return this.traverseMajorTicksPositions(function(o){i.push(o)},{step:1,skip:0}),i},r.prototype.createTicks=function(i){var o=this.options,a=o.majorTicks,s=o.minorTicks,l=o.vertical,h=o.labels.mirror,p=this.lineBox(),f=[],g={vertical:l};function b(z,M){g.tickX=h?p.x2:p.x2-M.size,g.tickY=h?p.y1-M.size:p.y1,g.position=z,i.append(CV(g,M))}return a.visible&&this.traverseMajorTicksPositions(b,a),s.visible&&this.traverseMinorTicksPositions(b,s),f},r.prototype.createGridLines=function(i){var o=this.options,a=o.minorGridLines,s=o.majorGridLines,l=o.vertical,h=i.lineBox(),p={lineStart:h[l?"x1":"y1"],lineEnd:h[l?"x2":"y2"],vertical:l},f=[],g=this.gridLinesVisual();function b(z,M){c1(z,f)||(p.position=z,g.append(SV(p,M)),f.push(z))}return s.visible&&this.traverseMajorTicksPositions(b,s),a.visible&&this.traverseMinorTicksPositions(b,a),g.children},r.prototype.traverseMajorTicksPositions=function(i,o){for(var a=this.lineInfo(),s=a.lineStart,l=a.step,h=this,p=h.logMin,f=h.logMax,g=Math.ceil(p)+o.skip;g<=f;g+=o.step){var b=Ee(s+l*(g-p),U1);i(b,o)}},r.prototype.traverseMinorTicksPositions=function(i,o){for(var a=this,s=this.options,l=s.min,h=s.max,p=s.minorUnit,f=s.majorUnit,g=this.lineInfo(),b=g.lineStart,z=g.step,M=this,I=M.logMin,F=M.logMax,H=Math.floor(I),E=H;Eh)break;if($>=l){var G=Ee(b+z*(io($,f)-I),U1);i(G,o)}}},r.prototype.createAxisLabel=function(i,o,a){var s=Math.ceil(this.logMin+i),l=Math.pow(this.options.majorUnit,s),h=this.axisLabelText(l,o,a);return new h4(l,h,i,null,o)},r.prototype.shouldRenderNote=function(i){var o=this.range();return o.min<=i&&i<=o.max},r.prototype.pan=function(i){var o=this.translateRange(i);return this.limitRange(o.min,o.max,this.totalMin,this.totalMax,o.offset)},r.prototype.pointsRange=function(i,o){var a=this.getValue(i),s=this.getValue(o),l=Math.min(a,s),h=Math.max(a,s);return{min:l,max:h}},r.prototype.scaleRange=function(i,o){var a=this.options,s=a.majorUnit,l=io(this.options.min,s),h=io(this.options.max,s),p=Math.abs(this.pointOffset(o)),f=h-l,g=this.scaleToDelta(i,f),b=Math.pow(s,l+p*g),z=Math.pow(s,h-(1-p)*g);return z-b.9)?i=Math.pow(r,io(t,r)+.2):i=Math.pow(r,Math.ceil(io(t,r))),i}function gv(){throw new Error("Non positive values cannot be used for a logarithmic axis")}function io(t,r){return Math.log(t)/Math.log(r)}ve(Ep,{type:"log",majorUnit:HV,minorUnit:1,axisCrossingValue:1,vertical:!0,majorGridLines:{visible:!0,width:1,color:kr},zIndex:1,_deferLabels:!0});var DV={createGridLines:function(t){var r=this.options,n=Math.abs(this.box.center().y-t.lineBox().y1),i=[],o=!1,a,s;return r.majorGridLines.visible&&(a=this.majorGridLineAngles(t),o=!0,i=this.renderMajorGridLines(a,n,r.majorGridLines)),r.minorGridLines.visible&&(s=this.minorGridLineAngles(t,o),O0(i,this.renderMinorGridLines(s,n,r.minorGridLines,t,o))),i},renderMajorGridLines:function(t,r,n){return this.renderGridLines(t,r,n)},renderMinorGridLines:function(t,r,n,i,o){var a=this.radiusCallback&&this.radiusCallback(r,i,o);return this.renderGridLines(t,r,n,a)},renderGridLines:function(t,r,n,i){for(var o={stroke:{width:n.width,color:n.color,dashType:n.dashType}},a=this.box.center(),s=new n2([a.x,a.y],r),l=this.gridLinesVisual(),h=0;h0){var f=new n2([t.x,t.y],p);if(i.type===Qs)l.append(new jo(f,o));else{for(var g=new $e(o),b=0;b1){var l=t.x-o.x,h=t.y-o.y,p=(Ns(Math.atan2(h,l))+540)%360;i.sort(function(M,I){return $h(M,p)-$h(I,p)});var f=$h(i[0],i[1])/2,g=$h(p,i[0]),b=90-f,z=180-g-b;s=a*(Math.sin(qr(z))/Math.sin(qr(b)))}return this.axisType().prototype.getValue.call(this,new Qe(r.x1,r.y2-s))}};function $h(t,r){return 180-Math.abs(Math.abs(t-r)-180)}var TV=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.radarMajorGridLinePositions=function(){return this.getTickPositions(this.options.majorUnit)},r.prototype.radarMinorGridLinePositions=function(){var i=this.options,o=0;return i.majorGridLines.visible&&(o=i.majorUnit),this.getTickPositions(i.minorUnit,o)},r.prototype.axisType=function(){return t},r}(T2);zt(TV.prototype,PV);var VV=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.radarMajorGridLinePositions=function(){var i=[];return this.traverseMajorTicksPositions(function(o){i.push(o)},this.options.majorGridLines),i},r.prototype.radarMinorGridLinePositions=function(){var i=[];return this.traverseMinorTicksPositions(function(o){i.push(o)},this.options.minorGridLines),i},r.prototype.axisType=function(){return t},r}(Ep);zt(VV.prototype,PV);var fA=.333,oAt=.01,Ip=function(t){function r(n){t.call(this),this.closed=n}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.process=function(i){var o=this,a=i.slice(0),s=[],l=this.closed,h=a.length;if(h>2&&(this.removeDuplicates(0,a),h=a.length),h<2||h===2&&a[0].equals(a[1]))return s;var p=a[0],f=a[1],g=a[2];for(s.push(new Ii(p));p.equals(a[h-1]);)l=!0,a.pop(),h--;if(h===2){var b=this.tangent(p,f,Ne,We);return Pr(s).controlOut(this.firstControlPoint(b,p,f,Ne,We)),s.push(new Ii(f,this.secondControlPoint(b,p,f,Ne,We))),s}var z,M;if(l){p=a[h-1],f=a[0],g=a[1];var I=this.controlPoints(p,f,g);z=I[1],M=I[0]}else{var F=this.tangent(p,f,Ne,We);z=this.firstControlPoint(F,p,f,Ne,We)}for(var H=z,E=0;E<=h-3;E++)if(o.removeDuplicates(E,a),h=a.length,E+3<=h){p=a[E],f=a[E+1],g=a[E+2];var R=o.controlPoints(p,f,g);Pr(s).controlOut(H),H=R[1];var W=R[0];s.push(new Ii(f,W))}if(l){p=a[h-2],f=a[h-1],g=a[0];var $=this.controlPoints(p,f,g);Pr(s).controlOut(H),s.push(new Ii(f,$[0])),Pr(s).controlOut($[1]),s.push(new Ii(g,M))}else{var G=this.tangent(f,g,Ne,We);Pr(s).controlOut(H),s.push(new Ii(g,this.secondControlPoint(G,f,g,Ne,We)))}return s},r.prototype.removeDuplicates=function(i,o){for(;o[i+1]&&(o[i].equals(o[i+1])||o[i+1].equals(o[i+2]));)o.splice(i+1,1)},r.prototype.invertAxis=function(i,o,a){var s=!1;if(i.x===o.x)s=!0;else if(o.x===a.x)(o.y=h)&&(s=!0)}return s},r.prototype.isLine=function(i,o,a){var s=this.lineFunction(i,o),l=this.calculateFunction(s,a.x);return i.x===o.x&&o.x===a.x||Ee(l,1)===Ee(a.y,1)},r.prototype.lineFunction=function(i,o){var a=(o.y-i.y)/(o.x-i.x),s=i.y-a*i.x;return[s,a]},r.prototype.controlPoints=function(i,o,a){var s=Ne,l=We,h=!1,p=!1,f;if(this.isLine(i,o,a))f=this.tangent(i,o,Ne,We);else{var g={x:this.isMonotonicByField(i,o,a,Ne),y:this.isMonotonicByField(i,o,a,We)};if(g.x&&g.y)f=this.tangent(i,a,Ne,We),h=!0;else if(this.invertAxis(i,o,a)&&(s=We,l=Ne),g[s])f=0;else{var b;a[l]o[s]&&o[s]>i[s]||a[s]0&&(n=Cm.sum(t)/r),n},first:function(t){for(var r=t.length,n=0;n=0){this.valueGetter=this.createValueGetter(o,a);var b=this.getStandardError(s,this.getAverage(s));this.globalRange=function(z){return{low:z-b,high:z+b}}}},r.prototype.createValueGetter=function(i,o){var a=i.data,s=X1.current,l=s.valueFields(i),h=ne(a[0])?a[0]:{},p;if(zi(h)){var f=o?l.indexOf(o):0;p=t4("["+f+"]")}else if(y1(h))p=t4();else if(typeof h===l8){var g=s.sourceFields(i,l);p=t4(g[l.indexOf(o)])}return p},r.prototype.getErrorRange=function(i,o){var a,s,l;if(!ne(o))return null;if(this.globalRange)return this.globalRange(i);if(zi(o))a=i-o[0],s=i+o[1];else if(y1(l=parseFloat(o)))a=i-l,s=i+l;else if(l=uAt.exec(o)){var h=i*(parseFloat(l[1])/100);a=i-Math.abs(h),s=i+Math.abs(h)}else throw new Error("Invalid ErrorBar value: "+o);return{low:a,high:s}},r.prototype.getStandardError=function(i,o){return this.getStandardDeviation(i,o,!0)/Math.sqrt(o.count)},r.prototype.getStandardDeviation=function(i,o,a){for(var s=this,l=i.length,h=a?o.count-1:o.count,p=0,f=0;fIAt)return null;for(var l in t)if(!c1(l,n.excluded)&&Gb(t,l)){var h=t[l];mr(h)?(s=!0,i||(t[l]=t1(h(r),o[l]))):$2(h)&&(i||(n.defaults=o[l]),n.depth++,s=ts(h,r,n,i)||s,n.depth--)}return s}function wr(t,r){for(var n=[],i=[].concat(r),o=0;o0&&a0)return i.value/l}return i.value},r.prototype.plotRange=function(i,o){var a=this;o===void 0&&(o=0);var s=this.categoryPoints[i.categoryIx];if(this.options.isStacked){var l=this.plotValue(i),h=l>=0,p=o,f=!1,g=ne(i.series.stack)?i.series.stack:this.options.defaultStack,b=function(W){return W===!0||typeof W===l8&&!W.group};if(g)for(var z=0;z=0&&h||F<0&&!h)&&(o===0||F!==0)&&(p+=F,l+=F,f=!0,a.options.isStacked100&&(l=Math.min(l,1)))}}return f&&(p-=o),[p,l]}var H=i.series,E=this.seriesValueAxis(H),R=this.categoryAxisCrossingValue(E);return[R,tV(i.value)?i.value:R]},r.prototype.stackLimits=function(i,o){for(var a=this,s=Vr,l=Zr,h=0;h0&&(this.errorTotals.positive[o]=Math.max(this.errorTotals.positive[o]||0,l)),{low:s,high:l}},r.prototype.addValue=function(i,o){var a=o.categoryIx,s=o.series,l=o.seriesIx,h=this.categoryPoints[a];h||(this.categoryPoints[a]=h=[]);var p=this.seriesPoints[l];p||(this.seriesPoints[l]=p=[]);var f=this.createPoint(i,o);f&&(Object.assign(f,o),f.owner=this,f.noteText=i.fields.noteText,ne(f.dataItem)||(f.dataItem=s.data[a]),this.addErrorBar(f,i,a)),this.points.push(f),p.push(f),h.push(f),this.updateRange(i.valueFields,o)},r.prototype.evalPointOptions=function(i,o,a){var s=a.categoryIx,l=a.category,h=a.series,p=a.seriesIx,f={defaults:h._defaults,excluded:["data","aggregate","_events","tooltip","content","template","visual","toggle","_outOfRangeMinPoint","_outOfRangeMaxPoint","drilldownSeriesFactory","ariaTemplate","ariaContent"]},g=this._evalSeries[p];ne(g)||(this._evalSeries[p]=g=ts(i,{},f,!0));var b=i;return g&&(b=zt({},b),ts(b,{value:o,category:l,index:s,series:h,dataItem:h.data[s]},f)),b},r.prototype.updateRange=function(i,o){var a=o.series.axis,s=i.value,l=this.valueAxisRanges[a];isFinite(s)&&s!==null&&(l=this.valueAxisRanges[a]=l||{min:Vr,max:Zr},l.min=Math.min(l.min,s),l.max=Math.max(l.max,s))},r.prototype.seriesValueAxis=function(i){var o=this.plotArea,a=i.axis,s=a?o.namedValueAxes[a]:o.valueAxis;if(!s)throw new Error("Unable to locate value axis with name "+a);return s},r.prototype.reflow=function(i){var o=this,a=this.categorySlots=[],s=this.points,l=this.categoryAxis,h=0;this.traverseDataPoints(function(p,f){var g=f.categoryIx,b=f.series,z=o.seriesValueAxis(b),M=s[h++],I=a[g];if(I||(a[g]=I=o.categorySlot(l,g,z)),M){var F=o.plotRange(M,z.startValue()),H=o.valueSlot(z,F);if(H){var E=o.pointSlot(I,H);M.aboveAxis=o.aboveAxis(M,z),M.stackValue=F[1],o.options.isStacked100&&(M.percentage=o.plotValue(M)),o.reflowPoint(M,E)}else M.visible=!1}}),this.reflowCategories(a),!this.options.clip&&this.options.limitPoints&&this.points.length&&this.limitPoints(),this.box=i},r.prototype.valueSlot=function(i,o){return i.getSlot(o[0],o[1],!this.options.clip)},r.prototype.limitPoints=function(){for(var i=this,o=this.categoryPoints,a=o[0].concat(Pr(o)),s=0;s=a},r.prototype.categoryAxisCrossingValue=function(i){var o=this.categoryAxis,a=i.options,s=[].concat(a.axisCrossingValues||a.axisCrossingValue);return s[o.axisIndex||0]||0},r.prototype.reflowPoint=function(i,o){i.reflow(o)},r.prototype.reflowCategories=function(){},r.prototype.pointSlot=function(i,o){var a=this.options,s=a.invertAxes,l=s?o:i,h=s?i:o;return new Ce(l.x1,h.y1,l.x2,h.y2)},r.prototype.categorySlot=function(i,o){return i.getSlot(o)},r.prototype.traverseDataPoints=function(i){for(var o=this,a=this.options.series,s=xw(a),l=a.length,h=0;h1&&(s=t.createSegment(g,h,l,s),t._addSegment(s)),g=[])}g.length>1&&(s=t.createSegment(g,h,l,s),t._addSegment(s))}this.children.unshift.apply(this.children,this._segments)},_addSegment:function(t){this._segments.push(t),t.parent=this},sortPoints:function(t){return t},seriesMissingValues:function(t){var r=t.missingValues,n=!r&&this.options.isStacked;return n?Za:r||zl},getNearestPoint:function(t,r,n){for(var i=new Qe(t,r),o=this.seriesPoints[n],a=Vr,s,l=0;l0&&a.visible!==!1&&this.createStroke({stroke:zt({color:s,opacity:i.opacity,lineCap:"butt"},a)})},r.prototype.strokeSegments=function(){var i=this._strokeSegments;return i||(i=this._strokeSegments=this.createStrokeSegments()),i},r.prototype.createStrokeSegments=function(){return this.segmentsFromPoints(this.points())},r.prototype.stackSegments=function(){return this.prevSegment?this.prevSegment.createStackSegments(this.stackPoints):this.createStackSegments(this.stackPoints)},r.prototype.createStackSegments=function(i){return this.segmentsFromPoints(this.toGeometryPoints(i)).reverse()},r.prototype.segmentsFromPoints=function(i){return i.map(function(o){return new Ii(o)})},r.prototype.createStroke=function(i){var o=new $e(i);o.segments.push.apply(o.segments,this.strokeSegments()),this.visual.append(o)},r.prototype.hasStackSegment=function(){return this.prevSegment||this.stackPoints&&this.stackPoints.length},r.prototype.createFill=function(i){var o=this.strokeSegments(),a=o.slice(0),s=this.hasStackSegment();if(s){var l=this.stackSegments();O0(a,l)}var h=new $e(i);h.segments.push.apply(h.segments,a),!s&&o.length>1&&this.fillToAxes(h),this.visual.append(h)},r.prototype.fillToAxes=function(i){var o=this.parent,a=o.options.invertAxes,s=o.seriesValueAxis(this.series),l=o.categoryAxisCrossingValue(s),h=s.getSlot(l,l,!0),p=this.strokeSegments(),f=p[0].anchor(),g=Pr(p).anchor(),b=a?h.x1:h.y1;a?i.lineTo(b,g.y).lineTo(b,f.y):i.lineTo(g.x,b).lineTo(f.x,b)},r}($0),rF=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.createStrokeSegments=function(){return this.segmentsFromPoints(this.calculateStepPoints(this.linePoints))},r.prototype.createStackSegments=function(i){return this.segmentsFromPoints(this.calculateStepPoints(i)).reverse()},r}(n6);zt(rF.prototype,ww);var Mw=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.createStrokeSegments=function(){var i=new Ip(this.options.closed),o=this.points();return i.process(o)},r.prototype.createStackSegments=function(){for(var i=this.strokeSegments(),o=[],a=i.length-1;a>=0;a--){var s=i[a];o.push(new Ii(s.anchor(),s.controlOut(),s.controlIn()))}return o},r}(n6),PAt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.createSegment=function(i,o,a,s){var l=this.options.isStacked,h=(o.line||{}).style,p,f;if(l&&a>0&&s){var g=this.seriesMissingValues(o);g!=="gap"?(f=s.linePoints,p=s):f=this._gapStackPoints(i,a,h)}var b;return h===Pc?b=rF:h===Jl?b=Mw:b=n6,new b(i,o,a,p,f)},r.prototype.reflow=function(i){var o=this;t.prototype.reflow.call(this,i);var a=this._stackPoints;if(a)for(var s=0;s0&&!F);if(F)a!==Pc&&z>h&&!l[I][M-1]&&b.push(s._previousSegmentPoint(z,M,M-1,I)),b.push(F),a!==Pc&&z+10&&!p;)h--,p=l[h][a];return p?p=l[h][o]:(p=this._createGapStackPoint(i),this._stackPoints.push(p)),p},r.prototype._createGapStackPoint=function(i){var o=this.pointOptions({},0),a=new Jo(0,o);return a.categoryIx=i,a.series={},a},r.prototype.seriesMissingValues=function(i){return i.missingValues||Za},r.prototype.supportsPointInactiveOpacity=function(){return!1},r}(Tp),g9=function(t){function r(){t.call(this),this.axisRanges={}}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.update=function(i){var o=this.axisRanges;for(var a in i){var s=i[a],l=o[a];o[a]=l=l||{min:Vr,max:Zr},l.min=Math.min(l.min,s.min),l.max=Math.max(l.max,s.max)}},r.prototype.reset=function(i){this.axisRanges[i]=void 0},r.prototype.query=function(i){return this.axisRanges[i]},r}(Ve),kw=function(t){function r(n,i,o){t.call(this,i),this.textBox=new Nn(n,this.options,o),this.append(this.textBox)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.createVisual=function(){this.textBox.options.noclip=this.options.noclip},r.prototype.reflow=function(i){var o=this.options,a=o.vertical,s=o.aboveAxis,l=this.children[0],h=l.options,p=l.box,f=l.options.padding,g=i;h.align=a?a1:p1,h.vAlign=a?v1:a1,o.position===f9?a?(h.vAlign=v1,!s&&p.height()0&&a.height()>0&&this.createRect(this.visual)},r.prototype.createRect=function(i){var o=this.options,a=o.border,s=ne(a.opacity)?a.opacity:o.opacity,l=this.box.toRect();l.size.width=Math.round(l.size.width);var h=this.rectVisual=$e.fromRect(l,{fill:{color:this.color,opacity:o.opacity},stroke:{color:this.getBorderColor(),width:a.width,opacity:s,dashType:a.dashType}}),p=this.box.width(),f=this.box.height(),g=o.vertical?p:f;if(g>TAt&&(o2(h),(p<1||f<1)&&(h.options.stroke.lineJoin="round")),i.append(h),bw(o)){var b=this.createGradientOverlay(h,{baseColor:this.color},zt({end:o.vertical?void 0:[0,1]},o.overlay));i.append(b)}},r.prototype.createHighlight=function(i){var o=$e.fromRect(this.box.toRect(),i);return o2(o)},r.prototype.highlightVisual=function(){return this.rectVisual},r.prototype.highlightVisualArgs=function(){return{options:this.options,rect:this.box.toRect(),visual:this.rectVisual}},r.prototype.createFocusHighlight=function(i){var o=this.options.accessibility.highlight.border.width,a=$e.fromRect(this.box.pad(o/2).toRect(),i);return o2(a)},r.prototype.getBorderColor=function(){var i=this.color,o=this.options.border,a=o._brightness||Hp,s=o.color;return ne(s)||(s=new Wo(i).brightness(a).toHex()),s},r.prototype.tooltipAnchor=function(){var i=this,o=i.options,a=i.box,s=i.aboveAxis,l=this.owner.pane.clipBox()||a,h=p1,p=v1,f,g;if(o.vertical)f=Math.min(a.x2,l.x2)+ao,s?g=Math.max(a.y1,l.y1):(g=Math.min(a.y2,l.y2),p=M1);else{var b=Math.max(a.x1,l.x1),z=Math.min(a.x2,l.x2);o.isStacked?(p=M1,s?(h=S1,f=z):f=b,g=Math.max(a.y1,l.y1)-ao):(s?f=z+ao:(f=b-ao,h=S1),g=Math.max(a.y1,l.y1))}return{point:new Qe(f,g),align:{horizontal:h,vertical:p}}},r.prototype.overlapsBox=function(i){return this.box.overlaps(i)},r.prototype.pointData=function(){return{dataItem:this.dataItem,category:this.category,value:this.value,percentage:this.percentage,stackValue:this.stackValue,runningTotal:this.runningTotal,total:this.total,series:this.series}},r.prototype.getIndex=function(){return this.categoryIx},r}(V1);zt(ss.prototype,So);zt(ss.prototype,i6);zt(ss.prototype,o6);ss.prototype.defaults={border:{width:1},vertical:!0,overlay:{gradient:"glass"},labels:{visible:!1,format:"{0}"},opacity:1,notes:{label:{}},accessibility:{role:w4,className:C4,ariaRoleDescription:S4}};function iF(t,r){t.forEach(r)}function nF(t,r){for(var n=t.length,i=n-1;i>=0;i--)r(t[i],i-n-1)}var J8=function(t){function r(n){t.call(this,n),this.forEach=n.rtl?nF:iF}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.reflow=function(i){var o=this.options,a=o.vertical,s=o.gap,l=o.spacing,h=this.children,p=h.length,f=a?We:Ne,g=p+s+l*(p-1),b=(a?i.height():i.width())/g,z=i[f+1]+b*(s/2);this.forEach(h,function(M,I){var F=(M.box||i).clone();F[f+1]=z,F[f+2]=z+b,M.reflow(F),I0&&a.options.set("stroke",{color:this.getBorderColor(),width:o.border.width,dashType:o.border.dashType,opacity:t1(o.border.opacity,o.opacity)}),o2(a),i.append(a),bw(o)&&i.append(this.createGradientOverlay(a,{baseColor:this.color},zt({end:o.vertical?void 0:[0,1]},o.overlay)))},r.prototype.createLines=function(i,o){this.drawLines(i,o,this.lines,o.line)},r.prototype.drawLines=function(i,o,a,s){if(a)for(var l={stroke:{color:s.color||this.color,opacity:t1(s.opacity,o.opacity),width:s.width,dashType:s.dashType,lineCap:"butt"}},h=0;h{4:d}Open:{0:C}High:{1:C}Low:{2:C}Close:{3:C}"},labels:{format:""},highlight:{opacity:1,border:{width:1,opacity:1},line:{width:1,opacity:1}},notes:{visible:!0,label:{}},accessibility:{role:w4,className:C4,ariaRoleDescription:S4}});zt(M4.prototype,So);zt(M4.prototype,i6);zt(M4.prototype,o6);var Vp=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.reflowCategories=function(i){for(var o=this.children,a=o.length,s=0;sl.close&&(p=i.fields.downColor||a.downColor||a.color),mr(a.color)&&(p=h.color),h.vertical=!this.options.invertAxes;var f=new s(l,h);return f.color=p,f},r.prototype.splitValue=function(i){return[i.low,i.open,i.close,i.high]},r.prototype.updateRange=function(i,o){var a=o.series.axis,s=this.splitValue(i),l=this.valueAxisRanges[a]||{min:Vr,max:Zr};this.valueAxisRanges[a]={min:Math.min.apply(Math,s.concat([l.min])),max:Math.max.apply(Math,s.concat([l.max]))}},r.prototype.formatPointValue=function(i,o){var a=i.value;return this.chartService.format.auto(o,a.open,a.high,a.low,a.close,i.category)},r.prototype.animationPoints=function(){return this.points},r}(z4);zt(Vp.prototype,Pp);var Fp=function(t){function r(n,i){t.call(this,n,i),this.createNote()}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.reflow=function(i){var o=this,a=o.options,s=o.value,l=o.owner,h=l.seriesValueAxis(a),p,f;this.boxSlot=f=h.getSlot(s.q1,s.q3),this.realBody=f,this.reflowBoxSlot(i),this.whiskerSlot=p=h.getSlot(s.lower,s.upper),this.reflowWhiskerSlot(i);var g=h.getSlot(s.median);if(s.mean){var b=h.getSlot(s.mean);this.meanPoints=this.calcMeanPoints(i,b)}this.whiskerPoints=this.calcWhiskerPoints(f,p),this.medianPoints=this.calcMedianPoints(i,g),this.box=p.clone().wrap(f),this.reflowNote()},r.prototype.reflowBoxSlot=function(i){this.boxSlot.x1=i.x1,this.boxSlot.x2=i.x2},r.prototype.reflowWhiskerSlot=function(i){this.whiskerSlot.x1=i.x1,this.whiskerSlot.x2=i.x2},r.prototype.calcMeanPoints=function(i,o){return[[[i.x1,o.y1],[i.x2,o.y1]]]},r.prototype.calcWhiskerPoints=function(i,o){var a=o.center().x;return[[[a-5,o.y1],[a+5,o.y1],[a,o.y1],[a,i.y1]],[[a-5,o.y2],[a+5,o.y2],[a,o.y2],[a,i.y2]]]},r.prototype.calcMedianPoints=function(i,o){return[[[i.x1,o.y1],[i.x2,o.y1]]]},r.prototype.renderOutliers=function(i){for(var o=this,a=this.value,s=a.outliers||[],l=Math.abs(a.q3-a.q1)*3,h=[],p=i.markers||{},f=0;fa.q1-l?p=i.outliers:p=i.extremes;var b=zt({},p.border);ne(b.color)||(ne(o.color)?b.color=o.color:b.color=new Wo(p.background).brightness(Hp).toHex());var z=new Vn({type:p.type,width:p.size,height:p.size,rotation:p.rotation,background:p.background,border:b,opacity:p.opacity});z.value=g,h.push(z)}return this.reflowOutliers(h),h},r.prototype.reflowOutliers=function(i){for(var o=this,a=this.owner.seriesValueAxis(this.options),s=this.box.center(),l=0;l{6:d}Lower:{0:C}Q1:{1:C}Median:{2:C}Mean:{5:C}Q3:{3:C}Upper:{4:C}"},highlight:{opacity:1,border:{width:1,opacity:1},line:{width:1,opacity:1}},notes:{visible:!0,label:{}},outliers:{visible:!0,size:c9,type:Mb,background:C1,border:{width:2,opacity:1},opacity:0},extremes:{visible:!0,size:c9,type:On,background:C1,border:{width:2,opacity:1},opacity:0}});zt(Fp.prototype,So);var VAt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.reflowBoxSlot=function(i){this.boxSlot.y1=i.y1,this.boxSlot.y2=i.y2},r.prototype.reflowWhiskerSlot=function(i){this.whiskerSlot.y1=i.y1,this.whiskerSlot.y2=i.y2},r.prototype.calcMeanPoints=function(i,o){return[[[o.x1,i.y1],[o.x1,i.y2]]]},r.prototype.calcWhiskerPoints=function(i,o){var a=o.center().y;return[[[o.x1,a-5],[o.x1,a+5],[o.x1,a],[i.x1,a]],[[o.x2,a-5],[o.x2,a+5],[o.x2,a],[i.x2,a]]]},r.prototype.calcMedianPoints=function(i,o){return[[[o.x1,i.y1],[o.x1,i.y2]]]},r}(Fp),FAt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.addValue=function(i,o){var a=o.categoryIx,s=o.category,l=o.series,h=o.seriesIx,p=this,f=p.children,g=p.options,b=i.valueFields,z=this.splitValue(b),M=ZV(z),I=l.data[a],F=this.categoryPoints[a],H;F||(this.categoryPoints[a]=F=[]),M&&(H=this.createPoint(i,o));var E=f[a];E||(E=new J8({vertical:g.invertAxes,gap:g.gap,spacing:g.spacing,rtl:!g.invertAxes&&(this.chartService||{}).rtl}),this.append(E)),H&&(this.updateRange(b,o),E.append(H),H.categoryIx=a,H.category=s,H.series=l,H.seriesIx=h,H.owner=this,H.dataItem=I),this.points.push(H),F.push(H)},r.prototype.pointType=function(){return this.options.invertAxes?VAt:Fp},r.prototype.splitValue=function(i){return[i.lower,i.q1,i.median,i.q3,i.upper]},r.prototype.updateRange=function(i,o){var a=o.series.axis,s=this.splitValue(i).concat(this.filterOutliers(i.outliers));ne(i.mean)&&(s=s.concat(i.mean));var l=this.valueAxisRanges[a]||{min:Vr,max:Zr};this.valueAxisRanges[a]={min:Math.min.apply(Math,s.concat([l.min])),max:Math.max.apply(Math,s.concat([l.max]))}},r.prototype.formatPointValue=function(i,o){var a=i.value;return this.chartService.format.auto(o,a.lower,a.q1,a.median,a.q3,a.upper,a.mean,i.category)},r.prototype.filterOutliers=function(i){for(var o=(i||[]).length,a=[],s=0;s0||i.size<0&&o.series.negativeValues.visible)?(this._maxSize=Math.max(this._maxSize,Math.abs(i.size)),t.prototype.addValue.call(this,i,o)):(this.points.push(null),this.seriesPoints[o.seriesIx].push(null))},r.prototype.reflow=function(i){this.updateBubblesSize(i),t.prototype.reflow.call(this,i)},r.prototype.pointType=function(){return v8},r.prototype.createPoint=function(i,o){var a=o.series,s=a.data.length,l=o.pointIx*(V2/s),h={delay:l,duration:V2-l,type:Ql},p=o.color||a.color;i.size<0&&a.negativeValues.visible&&(p=t1(a.negativeValues.color,p));var f=zt({labels:{animation:{delay:l,duration:V2-l}}},this.pointOptions(a,o.seriesIx),{markers:{type:On,border:a.border,opacity:a.opacity,animation:h}});f=this.evalPointOptions(f,i,o),mr(a.color)&&(p=f.color),f.markers.background=p;var g=new v8(i,f);return g.color=p,this.append(g),g},r.prototype.updateBubblesSize=function(i){for(var o=this,a=this,s=a.options.series,l=Math.min(i.width(),i.height()),h=0;h0&&o.options.set("stroke",{color:i.border.color||this.color,width:i.border.width,dashType:i.border.dashType,opacity:t1(i.border.opacity,i.opacity)}),this.bodyVisual=o,o2(o),this.visual.append(o)},r.prototype.createAnimation=function(){this.bodyVisual&&(this.animation=G2.create(this.bodyVisual,this.options.animation))},r.prototype.createHighlight=function(i){return $e.fromRect(this.box.toRect(),i)},r.prototype.highlightVisual=function(){return this.bodyVisual},r.prototype.highlightVisualArgs=function(){return{rect:this.box.toRect(),visual:this.bodyVisual,options:this.options}},r.prototype.formatValue=function(i){return this.owner.formatPointValue(this,i)},r.prototype.pointData=function(){return{dataItem:this.dataItem,category:this.category,value:this.value,series:this.series}},r.prototype.overlapsBox=function(i){return this.box.overlaps(i)},r.prototype.getIndex=function(){return this.categoryIx},r}(V1);W0.prototype.tooltipAnchor=ss.prototype.tooltipAnchor;W0.prototype.createFocusHighlight=ss.prototype.createFocusHighlight;ve(W0,{border:{width:1},vertical:!1,opacity:1,target:{shape:"",border:{width:0,color:"green"},line:{width:2}},labels:{visible:!1},tooltip:{format:"Current: {0}
Target: {1}"},notes:{label:{}},accessibility:{role:w4,className:C4,ariaRoleDescription:S4}});zt(W0.prototype,So);zt(W0.prototype,i6);zt(W0.prototype,o6);var _w=function(t){function r(n,i){OAt(i),t.call(this,n,i)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.reflowCategories=function(i){for(var o=this.children,a=o.length,s=0;s0},r.prototype.createAnimation=function(){var i=this,o=this.points;this._setAnimationOptions();for(var a=0;a=0;s--)for(var l=0;l0&&(s=Math.max(s,a.width()-h.contentBox.width()))}if(s!==0)for(var p=0;p0){var f=bv(h),g=Math.max(p.y1-f.y1,p.y2-f.y2);a=Math.max(a,p.x1-f.x1);for(var b=0;b0&&a.y.length>0&&(this.alignAxes(a.x,a.y),this.shrinkAxisWidth(i),this.autoRotateAxisLabels(a),this.alignAxes(a.x,a.y),this.shrinkAxisWidth(i)&&this.alignAxes(a.x,a.y),this.shrinkAxisHeight(i),this.alignAxes(a.x,a.y),this.shrinkAxisHeight(i)&&this.alignAxes(a.x,a.y),this.fitAxes(i))},r.prototype.autoRotateAxisLabels=function(i){for(var o=this,a=this,s=a.panes,l=jAt(s),h,p=0;p0&&i.y.length>0&&(this.alignAxes(i.x,i.y),this.shrinkAxisWidth(s))}},r.prototype.reflowPaneAxes=function(i){var o=i.axes,a=o.length;if(a>0)for(var s=0;s=l.length?(l=f(1),l.at(0)):l[p]},r.prototype._pointsByVertical=function(i){return this.pointsByPointIndex(i.getIndex())},r.prototype._pointsByHorizontal=function(i,o){o===void 0&&(o=0);var a=qu(i.series.index+o,this.series.length);return this.pointsBySeriesIndex(a)},r}(V1);function $At(t){return!t.pane.axes.some(function(r){return r.options.vertical===t.options.vertical&&r!==t&&r.options.visible!==!1})}function bv(t){for(var r=t.length,n,i=0;i-1){for(var a=t.split(".");a.length>1;)o=a.shift(),ne(i[o])||(i[o]={}),i=i[o];o=a.shift()}i[o]=n}var es=function(t){function r(){t.call(this),this._defaults={}}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.register=function(i,o){for(var a=this,s=0;sl.to,a.reflow(i)),s&&(s.options.aboveAxis=l.to>l.from,s.reflow(i)),this.note&&this.note.reflow(i)},r}(ss);Am.prototype.defaults=zt({},Am.prototype.defaults,{labels:{format:"{0} - {1}"},tooltip:{format:"{1}"}});var uF=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.pointType=function(){return Am},r.prototype.pointValue=function(i){return i.valueFields},r.prototype.formatPointValue=function(i,o){return i.value.from===null&&i.value.to===null?"":this.chartService.format.auto(o,i.value.from,i.value.to)},r.prototype.plotRange=function(i){return i?[i.value.from,i.value.to]:0},r.prototype.updateRange=function(i,o){var a=o.series.axis,s=i.from,l=i.to,h=this.valueAxisRanges[a];i!==null&&y1(s)&&y1(l)&&(h=this.valueAxisRanges[a]=h||{min:Vr,max:Zr},h.min=Math.min(h.min,s),h.max=Math.max(h.max,s),h.min=Math.min(h.min,l),h.max=Math.max(h.max,l))},r.prototype.aboveAxis=function(i){var o=i.value;return o.from=0},r.prototype.plotRange=function(i){return[i.from,i.to]},r.prototype.createSegments=function(){for(var i=this,o=this.options.series,a=this.seriesPoints,s=this.segments=[],l=0;l0&&(l=(s*a-n*i)/(s*o-Math.pow(n,2)),h=(i-l*n)/s),{slope:l,intercept:h,count:s,xMin:p,xMax:f}}var t5=function(t,r){return t.every(function(n){var i=n.valueFields;return!Hn(i[r])||i[r]>0})};function e5(t,r){for(var n=[],i=r.totalRangeIndices(),o=r.currentRangeIndices(),a={min:Math.floor(Math.max(o.min-1,i.min)),max:Math.ceil(Math.min(o.max+2,i.max))},s=a.min;s0){var p=Math.exp(l),f=s;return e5(function(g){return p*Math.exp(f*g)},n)}return null}function rLt(t){var r=t.options,n=t.categoryAxis,i=t.seriesValues,o=nLt({seriesValues:i,categoryAxis:n,options:r});return o?Object.assign({},r,{type:"line",data:o,categoryField:"category",field:"value"}):null}var iLt=function(t){return function(r){var n=r.categoryIx,i=r.valueFields;return{xValue:n+1,yValue:i[t]}}};function nLt(t){var r=t.seriesValues,n=t.categoryAxis,i=t.options,o=k4(r(),iLt(i.field)),a=o.slope,s=o.intercept,l=o.count;return l>0?e5(function(h){return a*h+s},n):null}function oLt(t){var r=t.options,n=t.categoryAxis,i=t.seriesValues,o=sLt({seriesValues:i,categoryAxis:n,options:r});return o?Object.assign({},r,{type:"line",data:o,categoryField:"category",field:"value"}):null}var aLt=function(t){return function(r){var n=r.categoryIx,i=r.valueFields;return{xValue:Math.log(n+1),yValue:i[t]}}};function sLt(t){var r=t.seriesValues,n=t.categoryAxis,i=t.options,o=k4(r(),aLt(i.field)),a=o.slope,s=o.intercept,l=o.count;if(l>0){var h=a,p=s;return e5(function(f){return h*Math.log(f)+p},n)}return null}function mF(t,r,n){for(var i=[],o=[],a=Math.max(mw,n)-1,s=0,l=0,h=0;h=a){var z=o.filter(function(F){return F!==null}).length,M=o.shift()||0;if(z>0){var I=l/z;i.push([g,I]),l-=M;continue}}i.push([g,null])}return i.slice(0,s+1)}function lLt(t){var r=t.options,n=uLt(t);return n?Object.assign({},r,{type:"line",data:n,categoryField:"category",field:"value"}):null}var cLt=function(t){return function(r){var n=r.categoryIx,i=r.valueFields;return{xValue:n,yValue:i[t]}}};function hLt(t){var r=t.options,n=t.categoryAxis,i=t.seriesValues,o=(r.trendline||{}).period||mw,a=n.totalRangeIndices(),s=n.currentRangeIndices(),l={min:Math.floor(Math.max(s.min-o,a.min)),max:Math.ceil(Math.min(s.max+o+2,a.max))};return mF(i(l),cLt(r.field),o)}function uLt(t){var r=t.categoryAxis,n=hLt(t),i=[];return n.forEach(function(o){var a=o[0],s=o[1];i[a]={category:r.categoryAt(a,!0),value:s}}),i.length>0?i:null}var CA=1,pLt=6;function yF(t,r,n){for(var i=Math.min(Math.max(n||CA,CA),pLt)+1,o=new fi,a=new fi,s=0,l=Number.MAX_VALUE,h=Number.MIN_VALUE,p=function(H){return H},f=[],g=0;g0&&(f=dLt(o,a),p=function(H){return f.reduce(function(E,R,W){return E+R*Math.pow(H,W)},0)}),{coefficients:f,count:s,valueMapper:p,xMin:l,xMax:h}}function dLt(t,r){for(var n=t.transpose(),i=n.multiply(t).inverse().multiply(n).multiply(r),o=[],a=0;a0?e5(function(h){return l(h)},n):null}function mLt(t){var r=t.options,n=t.categoryAxis,i=t.seriesValues,o=xLt({seriesValues:i,categoryAxis:n,options:r});return o?Object.assign({},r,{type:"line",data:o,categoryField:"category",field:"value"}):null}var yLt=function(t){return function(r){var n=r.categoryIx,i=r.valueFields;return{xValue:Math.log(n+1),yValue:Math.log(i[t])}}};function xLt(t){var r=t.seriesValues,n=t.categoryAxis,i=t.options,o=r();if(!t5(o,i.field))return null;var a=k4(o,yLt(i.field)),s=a.slope,l=a.intercept,h=a.count;if(h>0){var p=Math.exp(l),f=s;return e5(function(g){return p*Math.pow(g,f)},n)}return null}var j0={};j0[uw]=QAt;j0[pw]=rLt;j0[dw]=oLt;j0[fw]=lLt;j0[vw]=fLt;j0[gw]=mLt;var Lm=[Ja,p0,_l,f0],SA=[Qa,d0].concat(Lm),so=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.initFields=function(i){var o=this;if(this.namedCategoryAxes={},this.namedValueAxes={},this.valueAxisRangeTracker=new g9,this._seriesPointsCache={},this._currentPointsCache={},i.length>0){this.invertAxes=c1(i[0].type,[F2,u4,d0,p0,f0,Al,Ml,Ll]);for(var a=0;a0)for(l=s.options.categories=s.options.categories.slice(0);h--;)l.push("");this.valueAxisRangeTracker.update(i.valueAxisRanges),t.prototype.appendChart.call(this,i,o)},r.prototype.seriesPaneName=function(i){var o=this.options,a=i.axis,s=[].concat(o.valueAxis),l=a2(s,function(g){return g.name===a})[0],h=o.panes||[{}],p=(h[0]||{}).name||"default",f=(l||{}).pane||p;return f},r.prototype.seriesCategoryAxis=function(i){var o=i.categoryAxis,a=o?this.namedCategoryAxes[o]:this.categoryAxis;if(!a)throw new Error("Unable to locate category axis with name "+o);return a},r.prototype.stackableChartOptions=function(i,o){var a=i.some(function(h){return h.stack}),s=i.some(function(h){return h.stack&&h.stack.type==="100%"}),l=o.options.clip;return{defaultStack:i[0].stack,isStacked:a,isStacked100:s,clip:l}},r.prototype.groupSeriesByCategoryAxis=function(i){for(var o=[],a={},s=0;s0&&f.length>0&&i.trigger(a,{element:vo(o),originalEvent:o,category:El(p),value:El(f)})}},r.prototype.pointPane=function(i){for(var o=this.panes,a=0;ao.x2&&(g=o.x2-a.x),so.y2&&(b=o.y2-a.y),l0},r.prototype.getItems=function(){return this.itemsContainer.children[0].children},r.prototype.reflow=function(i){var o=this.options,a=i.clone();if(!this.hasItems()){this.box=a;return}o.position===jh?(this.containerCustomReflow(a),this.box=a):this.containerReflow(a),this.hasTitle()&&this.title.reflow(new Ce(this.container.box.x1,this.title.box.y1,this.container.box.x2,this.title.box.y2))},r.prototype.containerReflow=function(i){var o=this,a=o.options,s=o.container,l=a.position,h=a.width,p=a.height,f=l===v1||l===M1?Ne:We,g=this.isVertical(),b=i.clone(),z=i.clone();(l===p1||l===S1)&&(z.y1=b.y1=0),g&&p?(z.y2=z.y1+p,z.align(b,We,s.options.vAlign)):!g&&h&&(z.x2=z.x1+h,z.align(b,Ne,s.options.align)),s.reflow(z),z=s.box;var M=z.clone();(a.offsetX||a.offsetY)&&(z.translate(a.offsetX,a.offsetY),s.reflow(z)),M[f+1]=i[f+1],M[f+2]=i[f+2],this.box=M},r.prototype.containerCustomReflow=function(i){var o=this,a=o.options,s=o.container,l=a.offsetX,h=a.offsetY,p=a.width,f=a.height,g=this.isVertical(),b=i.clone();g&&f?b.y2=b.y1+f:!g&&p&&(b.x2=b.x1+p),s.reflow(b),b=s.box,s.reflow(new Ce(l,h,l+b.width(),h+b.height()))},r.prototype.renderVisual=function(){this.hasItems()&&t.prototype.renderVisual.call(this)},r.prototype.createLegendTitle=function(i){var o=zt({},{color:kr,position:v1,align:a1},i),a=o.text;if(!(!i||i.visible===!1||!i.text)){if(ne(o)&&o.visible){var s=di(o);s?a=s({text:a}):o.format&&(a=this.chartService.format.auto(o.format,a))}this.title=new Nn(a,o),this.createTitleLayout(),this.appendTitleLayoutContent()}},r.prototype.createTitleLayout=function(){this.layout=new Mp({vertical:!0,wrap:!1}),this.container.append(this.layout)},r.prototype.hasTitle=function(){return!!(this.options.title&&this.options.title.visible!==!1&&this.options.title.text)},r.prototype.appendTitleLayoutContent=function(){var i=this.options;i.title.position===M1?(this.layout.append(this.itemsContainer),this.layout.append(this.title)):(this.layout.append(this.title),this.layout.append(this.itemsContainer))},r}(V1);ve(Hw,{position:S1,data:[],offsetX:0,offsetY:0,margin:T1(2),padding:T1(5),border:{color:kr,width:0},item:{cursor:am,spacing:6},spacing:6,background:"",zIndex:1,markers:{},line:{width:20,height:2,cursor:am,opacity:1},area:{type:vSt,align:S1,width:15,height:15}});var go=function(t){function r(){t.call(this),this._registry=[]}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.register=function(i,o){this._registry.push({type:i,seriesTypes:o})},r.prototype.create=function(i,o,a){for(var s=this._registry,l=s[0],h,p=0;p0){l=f;break}}return new l.type(h,o,a)},r}(Ve);go.current=new go;var LLt=3,ELt=.1;function xa(t){var r=document.createElement("div");return t&&(r.className=t),r}function MA(t){for(var r=t;r&&!Zu(r,"k-handle");)r=r.parentNode;return r}var Dw=function(t){function r(n,i,o,a){t.call(this);var s=n.element;this.options=zt({},this.options,o),this.chart=n,this.observer=a,this.chartElement=s,this.categoryAxis=i,this._dateAxis=this.categoryAxis instanceof U8,this.initOptions(),this.visible=this.options.visible&&s.offsetHeight,this.visible&&(this.createElements(),this.set(this._index(this.options.from),this._index(this.options.to)),this.bindEvents())}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.onPane=function(i){return this.categoryAxis.pane===i},r.prototype.createElements=function(){var i=this.options,o=this.wrapper=xa("k-selector k-pointer-events-none");br(o,{top:i.offset.top,left:i.offset.left,width:i.width,height:i.height,direction:"ltr"});var a=this.selection=xa("k-selection k-pointer-events-none");this.leftMask=xa("k-mask k-pointer-events-none"),this.rightMask=xa("k-mask k-pointer-events-none"),o.appendChild(this.leftMask),o.appendChild(this.rightMask),o.appendChild(a);var s=this.body=xa("k-selection-bg k-pointer-events-none");a.appendChild(s);var l=this.leftHandle=xa("k-handle k-left-handle k-pointer-events-auto"),h=this.rightHandle=xa("k-handle k-right-handle k-pointer-events-auto");l.appendChild(xa()),h.appendChild(xa()),a.appendChild(l),a.appendChild(h),this.chartElement.appendChild(o);var p=br(a,["borderLeftWidth","borderRightWidth","height"]),f=br(l,"height").height,g=br(h,"height").height;i.selection={border:{left:p.borderLeftWidth,right:p.borderRightWidth}},br(l,{top:(p.height-f)/2}),br(h,{top:(p.height-g)/2}),o.style.cssText=o.style.cssText},r.prototype.bindEvents=function(){var i;this.options.mousewheel!==!1&&(this._mousewheelHandler=this._mousewheel.bind(this),nc(this.chartElement,(i={},i[v9]=this._mousewheelHandler,i))),this._domEvents=Ap.create(this.chartElement,{stopPropagation:!0,start:this._start.bind(this),move:this._move.bind(this),end:this._end.bind(this),tap:this._tap.bind(this),press:this._press.bind(this),gesturestart:this._gesturestart.bind(this),gesturechange:this._gesturechange.bind(this),gestureend:this._gestureend.bind(this)})},r.prototype.initOptions=function(){var i=this,o=i.options,a=i.categoryAxis,s=a.pane.chartsBox(),l=this.chart.chartService.intl;this._dateAxis&&zt(o,{min:Ci(l,o.min),max:Ci(l,o.max),from:Ci(l,o.from),to:Ci(l,o.to)});var h=br(this.chartElement,["paddingLeft","paddingTop"]),p=h.paddingLeft,f=h.paddingTop;this.options=zt({},{width:s.width(),height:s.height()+ELt,padding:{left:p,top:f},offset:{left:s.x1+p,top:s.y1+f},from:o.min,to:o.max},o)},r.prototype.destroy=function(){var i;this._domEvents&&(this._domEvents.destroy(),delete this._domEvents),clearTimeout(this._mwTimeout),this._state=null,this.wrapper&&(this._mousewheelHandler&&(oc(this.chartElement,(i={},i[v9]=this._mousewheelHandler,i)),this._mousewheelHandler=null),this.chartElement.removeChild(this.wrapper),this.wrapper=null)},r.prototype._rangeEventArgs=function(i){return{axis:this.categoryAxis.options,from:this._value(i.from),to:this._value(i.to)}},r.prototype._pointInPane=function(i,o){var a=this.categoryAxis.pane.box,s=this.chart._toModelCoordinates(i,o);return a.containsPoint(s)},r.prototype._start=function(i){var o=this.options,a=vo(i);if(!(this._state||!a)){var s=oV(i),l=this._pointInPane(s.x,s.y);if(l){var h=MA(a),p=this.body.getBoundingClientRect(),f=!h&&s.x>=p.x&&s.x<=p.x+p.width&&s.y>=p.y&&s.y<=p.y+p.height;this.chart._unsetActivePoint(),this._state={moveTarget:h,startLocation:i.x?i.x.location:0,inBody:f,range:{from:this._index(o.from),to:this._index(o.to)}};var g=this._rangeEventArgs({from:this._index(o.from),to:this._index(o.to)});this.trigger(zm,g)&&(this._state=null)}}},r.prototype._press=function(i){var o;this._state?o=this._state.moveTarget:o=MA(vo(i)),o&&Ir(o,"k-handle-active")},r.prototype._move=function(i){if(this._state){var o=this,a=o._state,s=o.options,l=o.categoryAxis,h=a.range,p=a.moveTarget,f=l.options.reverse,g=this._index(s.from),b=this._index(s.to),z=this._index(s.min),M=this._index(s.max),I=a.startLocation-i.x.location,F={from:h.from,to:h.to},H=h.to-h.from,E=br(this.wrapper,"width").width/(l.categoriesCount()-1),R=Math.round(I/E)*(f?-1:1);if(!(!p&&!a.inBody)){var W=p&&Zu(p,"k-left-handle"),$=p&&Zu(p,"k-right-handle");a.inBody?(h.from=Math.min(Math.max(z,g-R),M-H),h.to=Math.min(h.from+H,M)):W&&!f||$&&f?(h.from=Math.min(Math.max(z,g-R),M-1),h.to=Math.max(h.from+1,h.to)):(W&&f||$&&!f)&&(h.to=Math.min(Math.max(z+1,b-R),M),h.from=Math.min(h.to-1,h.from)),(h.from!==F.from||h.to!==F.to)&&(this.move(h.from,h.to),this.trigger(lc,this._rangeEventArgs(h)))}}},r.prototype._end=function(){if(this._state){var i=this._state.moveTarget;i&&Ab(i,"k-handle-active");var o=this._state.range;this.set(o.from,o.to),this.trigger(Mm,this._rangeEventArgs(o)),delete this._state}},r.prototype._tap=function(i){var o=this,a=o.options,s=o.categoryAxis,l=this.chart._eventCoordinates(i),h=s.pointCategoryIndex(new Qe(l.x,s.box.y1)),p=this._index(a.from),f=this._index(a.to),g=this._index(a.min),b=this._index(a.max),z=f-p,M=p+z/2,I={},F=i.event.which===3,H=Math.round(M-h);this._state||F||(this.chart._unsetActivePoint(),s.options.justified||H--,I.from=Math.min(Math.max(g,p-H),b-z),I.to=Math.min(I.from+z,b),this._start(i),this._state&&(this._state.range=I,this.trigger(lc,this._rangeEventArgs(I)),this._end()))},r.prototype._mousewheel=function(i){var o=this,a=jb(i);if(this._start(i),this._state){var s=this._state.range;i.preventDefault(),i.stopPropagation(),Math.abs(a)>1&&(a*=LLt),this.options.mousewheel.reverse&&(a*=-1),this.expand(a)&&this.trigger(lc,{axis:this.categoryAxis.options,delta:a,originalEvent:i,from:this._value(s.from),to:this._value(s.to)}),this._mwTimeout&&clearTimeout(this._mwTimeout),this._mwTimeout=setTimeout(function(){o._end()},km)}},r.prototype._gesturestart=function(i){var o=this.options,a=i.touches[0],s=this._pointInPane(a.pageX,a.pageY);if(s){this._state={range:{from:this._index(o.from),to:this._index(o.to)}};var l=this._rangeEventArgs(this._state.range);this.trigger(zm,l)?this._state=null:i.preventDefault()}},r.prototype._gestureend=function(){this._state&&(this.trigger(Mm,this._rangeEventArgs(this._state.range)),delete this._state)},r.prototype._gesturechange=function(i){if(this._state){var o=this,a=o.chart,s=o._state,l=o.options,h=o.categoryAxis,p=s.range,f=a._toModelCoordinates(i.touches[0].x.location).x,g=a._toModelCoordinates(i.touches[1].x.location).x,b=Math.min(f,g),z=Math.max(f,g);i.preventDefault(),p.from=h.pointCategoryIndex(new Qe(b))||l.min,p.to=h.pointCategoryIndex(new Qe(z))||l.max,this.move(p.from,p.to),this.trigger(lc,this._rangeEventArgs(p))}},r.prototype._index=function(i){var o=i;return i instanceof Date&&(o=this.categoryAxis.categoryIndex(i)),o},r.prototype._value=function(i){var o=i;return this._dateAxis&&(o=this.categoryAxis.categoryAt(i),o>this.options.max&&(o=this.options.max)),o},r.prototype._slot=function(i){var o=this.categoryAxis,a=this._index(i);return o.getSlot(a,a,!0)},r.prototype.move=function(i,o){var a=this.options,s=this.categoryAxis.options.reverse,l=a.offset,h=a.padding,p=a.selection.border,f=s?o:i,g=s?i:o,b="x"+(s?2:1),z=this._slot(f),M=Ee(z[b]-l.left+h.left);br(this.leftMask,{width:M}),br(this.selection,{left:M}),z=this._slot(g);var I=Ee(a.width-(z[b]-l.left+h.left));br(this.rightMask,{width:I});var F=a.width-I;F!==a.width&&(F+=p.right),br(this.rightMask,{left:F}),br(this.selection,{width:Math.max(a.width-(M+I)-p.right,0)})},r.prototype.set=function(i,o){var a=this.options,s=this._index(a.min),l=this._index(a.max),h=Xe(this._index(i),s,l),p=Xe(this._index(o),h+1,l);a.visible&&this.move(h,p),a.from=this._value(h),a.to=this._value(p)},r.prototype.expand=function(i){var o=this.options,a=this._index(o.min),s=this._index(o.max),l=o.mousewheel.zoom,h=this._index(o.from),p=this._index(o.to),f={from:h,to:p},g=zt({},f);if(this._state&&(f=this._state.range),l!==S1&&(f.from=Xe(Xe(h-i,0,p-1),a,s)),l!==p1&&(f.to=Xe(Xe(p+i,f.from+1,s),a,s)),f.from!==g.from||f.to!==g.to)return this.set(f.from,f.to),!0},r.prototype.zoom=function(i,o){var a=this.options,s=this._index(a.min),l=this._index(a.max),h=this._index(a.from),p=this._index(a.to),f={from:h,to:p},g=zt({},f),b=this.categoryAxis.options,z=b.reverse,M=Ne+(z?"2":"1"),I=this.categoryAxis.lineBox(),F=Math.abs(I[M]-o[Ne]),H=I.width(),E=Ee(F/H,2),R=Ee(E*i),W=Ee((1-E)*i);if(this._state&&(f=this._state.range),f.from=Xe(Xe(h-R,0,p-1),s,l),f.to=Xe(Xe(p+W,f.from+1,l),s,l),f.from!==g.from||f.to!==g.to)return this.set(f.from,f.to),!0},r.prototype.trigger=function(i,o){return(this.observer||this.chart).trigger(i,o)},r}(Ve);ve(Dw,{visible:!0,mousewheel:{zoom:"both"},min:Zr,max:Vr});var ILt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.show=function(i){if(!(!i||!i.tooltipAnchor||this._current&&this._current===i)){var o=zt({},this.options,i.options.tooltip),a=i.tooltipAnchor();a?(this._current=i,t.prototype.show.call(this,{point:i,anchor:a},o,i)):this.hide()}},r.prototype.hide=function(){delete this._current,t.prototype.hide.call(this)},r}(Rp),Pw=function(t){function r(n,i){t.call(this,n.chartService,i),this.plotArea=n,this.formatService=n.chartService.format}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.showAt=function(i,o){var a=a2(i,function(p){var f=p.series.tooltip,g=f&&f.visible===!1;return!g});if(a.length>0){var s=a[0],l=this.plotArea.categoryAxis.getSlot(s.categoryIx),h=o?this._slotAnchor(o,l):this._defaultAnchor(s,l);this.show({anchor:h,shared:!0,points:i,category:s.category,categoryText:this.formatService.auto(this.options.categoryFormat,s.category),series:this.plotArea.series},this.options)}},r.prototype._slotAnchor=function(i,o){var a=this.plotArea.categoryAxis,s={horizontal:"left",vertical:"center"};return a.options.vertical||(i.x=o.center().x),{point:i,align:s}},r.prototype._defaultAnchor=function(i,o){var a=i.owner.pane.chartsBox(),s=this.plotArea.categoryAxis.options.vertical,l=a.center(),h=o.center(),p={horizontal:"center",vertical:"center"},f;return s?f=new Qe(l.x,h.y):f=new Qe(h.x,l.y),{point:f,align:p}},r}(Rp);ve(Pw,{categoryFormat:"{0:d}"});var kF=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.setup=function(){var i=this,o=i.element,a=i.options,s=o.bbox();if(s){this.origin=a.origin;var l=a.vertical?We:Ne,h=this.fromScale=new ye(1,1);h[l]=p8,o.transform(nr().scale(h.x,h.y))}else this.abort()},r.prototype.step=function(i){var o=D2(this.fromScale.x,1,i),a=D2(this.fromScale.y,1,i);this.element.transform(nr().scale(o,a,this.origin))},r.prototype.abort=function(){t.prototype.abort.call(this),this.element.transform(null)},r}(G2);ve(kF,{duration:V2});ia.current.register(F2,kF);var _F=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.setup=function(){var i=this.center=this.element.bbox().center();this.element.transform(nr().scale(p8,p8,i))},r.prototype.step=function(i){this.element.transform(nr().scale(i,i,this.center))},r}(G2);ve(_F,{easing:"easeOutElastic"});ia.current.register(Ql,_F);var AF=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.setup=function(){this.fadeTo=this.element.opacity(),this.element.opacity(0)},r.prototype.step=function(i){this.element.opacity(i*this.fadeTo)},r}(G2);ve(AF,{duration:200,easing:"linear"});ia.current.register(b4,AF);var LF=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.setup=function(){this.element.transform(nr().scale(p8,p8,this.options.center))},r.prototype.step=function(i){this.element.transform(nr().scale(i,i,this.options.center))},r}(G2);ve(LF,{easing:"easeOutElastic",duration:V2});ia.current.register(p4,LF);var Tw=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.render=function(){t.prototype.render.call(this),this.renderSegments()},r.prototype.createSegment=function(i,o,a){var s=o.style,l;return s===Jl?l=Cw:l=$0,new l(i,o,a)},r.prototype.animationPoints=function(){var i=t.prototype.animationPoints.call(this);return i.concat(this._segments)},r.prototype.createMissingValue=function(i,o){if(o===Za){var a={x:i.x,y:i.y};return Hn(a.x)||(a.x=0),Hn(a.y)||(a.y=0),a}},r}(s6);zt(Tw.prototype,Sw);function r5(t,r,n){var i=[],o=r.xMin,a=r.xMax,s=(n||{}).forecast;s&&(s.before>0&&(o-=s.before),s.after>0&&(a+=s.after));var l=(n||{}).samplingInterval,h=t1(l,Xl(o,a)/10);l<=0&&(h=a-o);for(var p=o;p<=a;p+=h)i.push([p,t(p)]);return i}function HLt(t){var r=t.options,n=t.seriesValues,i=PLt({seriesValues:n,options:r});return i?Object.assign({},r,{type:"scatterLine",data:i}):null}var DLt=function(t){return function(r){var n=r.valueFields;return{xValue:n.x,yValue:Math.log(n[t])}}};function PLt(t){var r=t.seriesValues,n=t.options,i=r();if(!t5(i,n.field))return null;var o=k4(i,DLt(n.field)),a=o.slope,s=o.intercept,l=o.count,h=o.xMin,p=o.xMax,f={xMin:h,xMax:p};if(l>0){var g=Math.exp(s),b=a;return r5(function(z){return g*Math.exp(b*z)},f,n.trendline)}return null}var Op=function(t){return function(r){var n=r.valueFields;return{xValue:n.x,yValue:n[t]}}};function TLt(t){var r=t.options,n=t.seriesValues,i=VLt({seriesValues:n,options:r});return i?Object.assign({},r,{type:"scatterLine",data:i}):null}function VLt(t){var r=t.seriesValues,n=t.options,i=k4(r(),Op(n.field)),o=i.slope,a=i.intercept,s=i.count,l=i.xMin,h=i.xMax,p={xMin:l,xMax:h};return s>0?r5(function(f){return o*f+a},p,n.trendline):null}function EF(t,r){for(var n=Number.MAX_VALUE,i=Number.MIN_VALUE,o=0;o0){var p=a,f=s;return r5(function(g){return p*Math.log(g)+f},h,n.trendline)}return null}function NLt(t){var r=t.options,n=$Lt(t);return n?Object.assign({},r,{type:"scatterLine",data:n}):null}function $Lt(t){var r=t.options,n=t.seriesValues,i=(r.trendline||{}).period||mw,o={before:i,after:i},a=mF(n(o),Op(r.field),i);return a.length>0?a:null}function WLt(t){var r=t.options,n=t.seriesValues,i=jLt({seriesValues:n,options:r});return i?Object.assign({},r,{type:"scatterLine",data:i}):null}function jLt(t){var r=t.seriesValues,n=t.options,i=(n.trendline||{}).order,o=Op(n.field),a=yF(r(),o,i),s=a.count,l=a.valueMapper,h=a.xMin,p=a.xMax,f={xMin:h,xMax:p};return s>0?r5(l,f,n.trendline):null}function GLt(t){var r=t.options,n=t.seriesValues,i=YLt({seriesValues:n,options:r});return i?Object.assign({},r,{type:"scatterLine",data:i}):null}var ULt=function(t){return function(r){var n=r.valueFields;return{xValue:Math.log(n.x),yValue:Math.log(n[t])}}};function YLt(t){var r=t.seriesValues,n=t.options,i=r();if(!t5(i,"x"))return null;var o=k4(i,ULt(n.field)),a=o.slope,s=o.intercept,l=o.count,h=EF(i,Op(n.field));if(l>0){var p=Math.exp(s),f=a;return r5(function(g){return p*Math.pow(g,f)},h,n.trendline)}return null}var G0={};G0[uw]=HLt;G0[pw]=TLt;G0[dw]=FLt;G0[fw]=NLt;G0[vw]=WLt;G0[gw]=GLt;var i5=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.initFields=function(){this.namedXAxes={},this.namedYAxes={},this.xAxisRangeTracker=new g9,this.yAxisRangeTracker=new g9},r.prototype.render=function(i){var o=this;i===void 0&&(i=this.panes),this.series=[].concat(this.originalSeries),this.createTrendlineSeries();for(var a=this.groupSeriesByPane(),s=0;s0&&this.appendChart(new s6(this,{series:i,clip:o.options.clip}),o)},r.prototype.createScatterLineChart=function(i,o){i.length>0&&this.appendChart(new Tw(this,{series:i,clip:o.options.clip}),o)},r.prototype.createBubbleChart=function(i,o){i.length>0&&this.appendChart(new aF(this,{series:i,clip:o.options.clip}),o)},r.prototype.createXYAxis=function(i,o,a){for(var s=i.name,l=o?this.namedYAxes:this.namedXAxes,h=o?this.yAxisRangeTracker:this.xAxisRangeTracker,p=zt({reverse:!o&&this.chartService.rtl},i,{vertical:o}),f=Da(p.type,d9),g=h.query(),b=f?{min:.1,max:1}:{min:0,max:1},z=h.query(s)||g||b,M=[p.min,p.max],I=this.series,F=0;F0&&g.length>0&&i.trigger(a,{element:vo(o),originalEvent:o,x:El(f),y:El(g)})},r.prototype.updateAxisOptions=function(i,o){var a=i.options.vertical,s=this.groupAxes(this.panes),l=(a?s.y:s.x).indexOf(i);kA(this.options,l,a,o),kA(this.originalOptions,l,a,o)},r.prototype.trendlineFactory=function(i,o){var a=this.seriesValues.bind(this,o.index),s=gF(G0,i.type,{options:i,seriesValues:a});return s&&(s.xAxis=o.xAxis,s.yAxis=o.yAxis),s},r.prototype.seriesValues=function(i){for(var o=this,a=[],s=this.series[i],l=0;l=s.center.x?(b=g.x+f,a.orientation=S1):(b=g.x-f,a.orientation=p1),a.reflow(new Ce(b,g.y-p,g.x,g.y))}}},r.prototype.createVisual=function(){var i=this,o=this,a=o.sector,s=o.options;if(t.prototype.createVisual.call(this),this.addAccessibilityAttributesToVisual(),this.value)if(s.visual){var l=(a.startAngle+180)%360,h=s.visual({category:this.category,dataItem:this.dataItem,value:this.value,series:this.series,percentage:this.percentage,center:new ye(a.center.x,a.center.y),radius:a.radius,innerRadius:a.innerRadius,startAngle:l,endAngle:l+a.angle,options:s,sender:this.getSender(),createVisual:function(){var p=new H1;return i.createSegmentVisual(p),p}});h&&this.visual.append(h)}else this.createSegmentVisual(this.visual)},r.prototype.createSegmentVisual=function(i){var o=this,a=o.sector,s=o.options,l=s.border||{},h=l.width>0?{stroke:{color:l.color,width:l.width,opacity:l.opacity,dashType:l.dashType}}:{},p=s.color,f={color:p,opacity:s.opacity},g=this.createSegment(a,zt({fill:f,stroke:{opacity:s.opacity},zIndex:s.zIndex},h));i.append(g),bw(s)&&i.append(this.createGradientOverlay(g,{baseColor:p,fallbackFill:f},zt({center:[a.center.x,a.center.y],innerRadius:a.innerRadius,radius:a.radius,userSpace:!0},s.overlay)))},r.prototype.createSegment=function(i,o){return o.singleSegment?new jo(new n2(new ye(i.center.x,i.center.y),i.radius),o):Cl.current.createRing(i,o)},r.prototype.createAnimation=function(){var i=this,o=i.options,a=i.sector.center;zt(o,{animation:{center:[a.x,a.y],delay:this.animationDelay}}),t.prototype.createAnimation.call(this)},r.prototype.createHighlight=function(i){var o=this.options.highlight||{},a=o.border||{};return this.createSegment(this.sector,zt({},i,{fill:{color:o.color,opacity:o.opacity},stroke:{opacity:a.opacity,width:a.width,color:a.color}}))},r.prototype.highlightVisual=function(){return this.visual.children[0]},r.prototype.highlightVisualArgs=function(){var i=this.sector;return{options:this.options,radius:i.radius,innerRadius:i.innerRadius,center:new ye(i.center.x,i.center.y),startAngle:i.startAngle,endAngle:i.angle+i.startAngle,visual:this.visual}},r.prototype.createFocusHighlight=function(i){var o=this.options.accessibility.highlight.border.width,a=this.createSegment(this.sector,zt({},i,{stroke:{width:o*2}})),s=new Xo;return s.paths.push($e.fromRect(a.bbox())),s.paths.push(this.createSegment(this.sector,{})),a.clip(s),a},r.prototype.tooltipAnchor=function(){var i=this.sector.clone().expand(ao),o=i.middle(),a=i.point(o);return{point:a,align:qLt(o+180)}},r.prototype.formatValue=function(i){return this.owner.formatPointValue(this,i)},r.prototype.pointData=function(){return{dataItem:this.dataItem,category:this.category,value:this.value,series:this.series,percentage:this.percentage}},r.prototype.getIndex=function(){return this.index},r}(V1),XLt=Ee(qr(30),U1),KLt=Ee(qr(60),U1);function qLt(t){var r=qr(t),n=Ee(Math.sin(r),U1),i=Ee(Math.cos(r),U1),o;Math.abs(n)>KLt?o=a1:i<0?o=S1:o=p1;var a;return Math.abs(n)b-f?b-f:W,M.translate(F.x-I.x,F.y-I.y);for(var $=b-W,G=new Qe($+M.x1+W,$+M.y1+W),Z=0;Z0&&(E.sort(this.labelComparator(!0)),this.leftLabelsReflow(E)),R.length>0&&(R.sort(this.labelComparator(!1)),this.rightLabelsReflow(R)),this.box=M},r.prototype.leftLabelsReflow=function(i){var o=this.distanceBetweenLabels(i);this.distributeLabels(o,i)},r.prototype.rightLabelsReflow=function(i){var o=this.distanceBetweenLabels(i);this.distributeLabels(o,i)},r.prototype.distanceBetweenLabels=function(i){var o=Pr(this.points),a=o.sector,s=i.length-1,l=a.radius+o.options.labels.distance,h=[],p=i[0].box,f=Ee(p.y1-(a.center.y-l-p.height()-p.height()/2));h.push(f);for(var g=0;g0&&(l>=0||h0){var h=Math.min(i[a],l);l-=h,i[a]-=h,i[o]+=h}return l},r.prototype.reflowLabels=function(i,o){var a=this,s=Pr(this.points),l=s.sector,h=s.options.labels,p=o.length,f=h.distance,g=l.center.y-(l.radius+f)-o[0].box.height(),b;i[0]+=2;for(var z=0;zg.center.x?(W=g.center.x-g.radius-h,f.options.labels.align!==Zo?W>R.x?I.lineTo(W,E.y):I.lineTo(E.x-h*2,E.y):I.lineTo(W,E.y),I.lineTo(R.x,$.y)):(G.y=$.y,I.lineTo(G.x,G.y))),I.lineTo($.x,$.y),i._connectorLines.push(I),i.visual.append(I)}}}},r.prototype.renderVisual=function(){if(t.prototype.renderVisual.call(this),lV(this.options.series,function(h){return h.autoFit})){var i=this.targetBox,o=this.box.center(),a=this.visual.bbox();if(!a)return;var s=a.bottomRight(),l=Math.min((o.y-i.y1)/(o.y-a.origin.y),(i.y2-o.y)/(s.y-o.y),(o.x-i.x1)/(o.x-a.origin.x),(i.x2-o.x)/(s.x-o.x));l<1&&this.visual.transform(nr().scale(l,l,[o.x,o.y]))}},r.prototype.labelComparator=function(i){var o=i?-1:1;return function(a,s){var l=(a.parent.sector.middle()+270)%360,h=(s.parent.sector.middle()+270)%360;return(l-h)*o}},r.prototype.hAlignLabel=function(i,o,a,s,l){var h=o.radius,p=o.center,f=p.x,g=p.y,b=Math.min(Math.abs(g-a),Math.abs(g-s));return b>h?i:f+Math.sqrt(h*h-b*b)*(l?1:-1)},r.prototype.pointInCircle=function(i,o,a){return Math.pow(o.x-i.x,2)+Math.pow(o.y-i.y,2)p-l?p-l:z;for(var M=p-z,I=0,F,H=0;H1)for(var i=oEt(this._segments),o=0;o1){var s=a[0].linePoints[0],l=Pr(a),h=Pr(l.linePoints),p=s.categoryIx===0,f=h.categoryIx===h.categoriesCount-1;p&&f&&Pr(a).linePoints.push(s)}}},r.prototype.createSegment=function(i,o,a){var s=o.style,l;s===Jl?l=Cw:l=$0;var h=new l(i,o,a),p=this.seriesMissingValues(o);return(i.length===o.data.length||p===zl)&&(h.options.closed=!0),h},r}(Tp);ve(Rw,{clip:!1,limitPoints:!1});var aEt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.fillToAxes=function(){},r}(Mw),sEt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.fillToAxes=function(){},r}(n6),lEt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.createSegment=function(i,o,a,s){var l=this.options.isStacked,h=(o.line||{}).style,p,f,g;return l&&a>0&&s&&(f=s.linePoints.slice(0),p=s),h===Jl?(g=new aEt(i,o,a,p,f),g.options.closed=!0):(i.push(i[0]),g=new sEt(i,o,a,p,f)),g},r.prototype.seriesMissingValues=function(i){return i.missingValues||Za},r}(Rw),TF=function(t){function r(n,i){t.call(this,n,null,i)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.getIndex=function(){return this.categoryIx},r}(Bp);ve(TF,{overlay:{gradient:"none"},labels:{distance:10}});var VF=function(t){function r(n){t.call(this,n),this.forEach=n.rtl?nF:iF}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.reflow=function(i){var o=this,a=o.options,s=o.children,l=a.gap,h=a.spacing,p=s.length,f=p+l+h*(p-1),g=i.angle/f,b=i.startAngle+g*(l/2);this.forEach(s,function(z){var M=i.clone();M.startAngle=b,M.angle=g,z.sector&&(M.radius=z.sector.radius),z.reflow(M),z.sector=M,b+=g+g*h})},r}(V1);ve(VF,{gap:1,spacing:0});var cEt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.reflow=function(i){var o=this,a=o.options.reverse,s=o.children,l=s.length,h=a?l-1:0,p=a?-1:1;this.box=new Ce;for(var f=h;f>=0&&f1,o.isStacked100=l&&l.type==="100%"&&s.length>1,o.isStacked100&&(this._isStacked100=!0)}return o},r.prototype.createAreaChart=function(i,o){if(i.length!==0){var a=new lEt(this,this.chartOptions(i));this.appendChart(a,o)}},r.prototype.createLineChart=function(i,o){if(i.length!==0){var a=new Rw(this,this.chartOptions(i));this.appendChart(a,o)}},r.prototype.createBarChart=function(i,o){if(i.length!==0){var a=i[0],s=this.chartOptions(i),l=this.filterVisibleSeries(i),h=l.some(function(g){return g.stack}),p=l.some(function(g){return g.stack&&g.stack.type==="100%"});s.gap=a.gap,s.spacing=a.spacing,s.defaultStack=a.stack&&l.length>1,s.isStacked=h&&l.length>1,s.isStacked100=p&&l.length>1;var f=new Ow(this,s);this.appendChart(f,o),this._hasBarCharts=!0}},r.prototype.seriesCategoryAxis=function(){return this.categoryAxis},r.prototype._dispatchEvent=function(i,o,a){var s=i._eventCoordinates(o),l=new Qe(s.x,s.y),h=this.categoryAxis.getCategory(l),p=this.valueAxis.getValue(l);h!==null&&p!==null&&i.trigger(a,{element:vo(o),category:h,value:p})},r.prototype.createCrosshairs=function(){},r.prototype._pointsByVertical=function(i){return t.prototype._pointsByVertical.call(this,i).sort(this._getSeriesCompareFn())},r.prototype._getSeriesCompareFn=function(){return function(i,o){return o.value-i.value}},r}(PF);zt(Bw.prototype,Q8,{appendChart:so.prototype.appendChart,aggregateSeries:so.prototype.aggregateSeries,seriesSourcePoints:so.prototype.seriesSourcePoints,seriesValues:so.prototype.seriesValues});ve(Bw,{categoryAxis:{categories:[]},valueAxis:{}});var $p=function(t){function r(n,i,o){t.call(this,i),this.value=n,this.options.index=o.index}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.getLabelText=function(i){var o=di(i);return o?o(this.pointData()):i.format?this.formatValue(i.format):this.value},r.prototype.reflow=function(i){var o=this.points,a=this.children[0],s=Math.min(o[0].x,o[3].x),l=Math.max(o[1].x,o[2].x);this.box=new Ce(s,o[0].y,l,o[2].y),a&&a.reflow(new Ce(i.x1,o[0].y,i.x2,o[2].y))},r.prototype.createVisual=function(){var i=this,o=this.options,a;t.prototype.createVisual.call(this),this.addAccessibilityAttributesToVisual(),o.visual?a=o.visual({category:this.category,dataItem:this.dataItem,value:this.value,series:this.series,percentage:this.percentage,points:this.points,options:o,sender:this.getSender(),createVisual:function(){return i.createPath()}}):a=this.createPath(),a&&this.visual.append(a)},r.prototype.createPath=function(){var i=this.options,o=i.border,a=$e.fromPoints(this.points,{fill:{color:i.color,opacity:i.opacity},stroke:{color:o.color,opacity:o.opacity,width:o.width}}).close();return a},r.prototype.createHighlight=function(i){return $e.fromPoints(this.points,i)},r.prototype.highlightVisual=function(){return this.visual.children[0]},r.prototype.highlightVisualArgs=function(){var i=$e.fromPoints(this.points).close();return{options:this.options,path:i}},r.prototype.createFocusHighlight=function(i){var o=this.options.accessibility.highlight.border.width,a=$e.fromPoints(this.points,zt({},i,{stroke:{width:o*2}})).close(),s=new Xo;return s.paths.push($e.fromRect(this.box.clone().pad(o).toRect())),s.paths.push($e.fromPoints(this.points)),a.clip(s),a},r.prototype.tooltipAnchor=function(){var i=this.box;return{point:new Qe(i.center().x,i.y1),align:{horizontal:"center",vertical:"top"}}},r.prototype.formatValue=function(i){var o=this;return o.owner.formatPointValue(o,i)},r.prototype.pointData=function(){return{dataItem:this.dataItem,category:this.category,value:this.value,series:this.series,percentage:this.percentage}},r.prototype.getIndex=function(){return this.index},r}(V1);ve($p,{color:C1,border:{width:1},labels:{format:""},accessibility:{role:w4,className:C4,ariaRoleDescription:S4}});zt($p.prototype,So);zt($p.prototype,o6);var Wp=function(t){function r(n,i){t.call(this,i),this.plotArea=n,this.chartService=n.chartService,this.points=[],this.labels=[],this.legendItems=[],this.render()}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.formatPointValue=function(i,o){return this.plotArea.chartService.format.auto(o,i.value)},r.prototype.render=function(){var i=this,o=0,a=this,s=a.options,l=a.plotArea.options.seriesColors;l===void 0&&(l=[]);var h=s.series[o],p=h.data;if(p)for(var f=JV(h),g=f.total,b=f.points,z=0;zg.percentage&&(g=h[b]);for(var z=f.percentage/g.percentage*o,M=(o-z)/2,I=0,F=0;F0&&g.length>0&&i.trigger(a,{element:vo(o),originalEvent:o,x:El(f),y:El(g)})},r.prototype.updateAxisOptions=function(i,o){var a=i.options.vertical,s=this.groupAxes(this.panes),l=(a?s.y:s.x).indexOf(i);AA(this.options,l,a,o),AA(this.originalOptions,l,a,o)},r.prototype.crosshairOptions=function(i){return Object.assign({},i.options.crosshair,{zIndex:0})},r.prototype._pointsByVertical=function(i,o){var a=this;o===void 0&&(o=0);var s=this.axisX.options.reverse?o*-1:o,l=this.axisX.children,h=this._getPointAxisXIndex(i)+s;h=qu(h,l.length);var p=l[h].value,f=this.filterPoints(function(g){return wv(g.pointData().x,p)}).sort(function(g,b){return a._getPointAxisYIndex(g)-a._getPointAxisYIndex(b)});return this.axisY.options.reverse?f.reverse():f},r.prototype._pointsByHorizontal=function(i,o){var a=this;o===void 0&&(o=0);var s=this.axisY.options.reverse?o*-1:o,l=this.axisY.children,h=this._getPointAxisYIndex(i)+s;h=qu(h,l.length);var p=l[h].value,f=this.filterPoints(function(g){return wv(g.pointData().y,p)}).sort(function(g,b){return a._getPointAxisXIndex(g)-a._getPointAxisXIndex(b)});return this.axisX.options.reverse?f.reverse():f},r.prototype._getPointAxisXIndex=function(i){return this._getPointAxisIndex(this.axisX,i.pointData().x)},r.prototype._getPointAxisYIndex=function(i){return this._getPointAxisIndex(this.axisY,i.pointData().y)},r.prototype._getPointAxisIndex=function(i,o){return i.children.findIndex(function(a){return wv(o,a.value)})},r}(ls);function wv(t,r){return t instanceof Date&&r instanceof Date?n9(t,r):t===r}function AA(t,r,n,i){var o=[].concat(n?t.yAxis:t.xAxis)[r];zt(o,i)}ve(Nw,{xAxis:{},yAxis:{}});zt(Nw.prototype,Q8);var u2="color",s2="first",fEt="from",un="max",$w="min",cs="noteText",vEt="summary",gEt="to";go.current.register(so,[F2,Zo,Qa,d0,Ja,p0,t6,e6,u4,q8,Y8,Ll,K8,Al,Z8,Ml,_l,f0].concat(r6));go.current.register(i5,[cw,hw,Ql].concat(r6));go.current.register(HF,[p4]);go.current.register(QLt,[u9]);go.current.register(pEt,[d8,f8]);go.current.register(Fw,[sw,p9,lw].concat(r6));go.current.register(Bw,[X8,Dp,kl].concat(r6));go.current.register(Nw,[aw]);X1.current.register([F2,Zo,Qa,d0,Ja,p0],[e2],[Co,u2,cs,OV,BV,as]);X1.current.register([K8,Al,_l,f0],[fEt,gEt],[Co,u2,cs,as]);X1.current.register([Z8,Ml],[e2],[Co,u2,cs,vEt,as]);X1.current.register([sw,p9,lw],[Ne,We],[u2,as]);X1.current.register([X8,Dp,kl],[e2],[Co,u2,as]);X1.current.register([d8,f8],[e2],[Co,u2,"visibleInLegend","visible",as]);es.current.register([F2,Zo,Qa,d0,Ja,p0,Z8,Ml],{value:un,color:s2,noteText:s2,errorLow:$w,errorHigh:un});es.current.register([K8,Al,_l,f0],{from:$w,to:un,color:s2,noteText:s2});es.current.register([X8,Dp,kl],{value:un,color:s2});X1.current.register([cw,hw,Ql],[Ne,We],[u2,cs,fAt,vAt,gAt,mAt]);X1.current.register([Ql],[Ne,We,"size"],[u2,Co,cs]);X1.current.register([aw],[Ne,We,e2],[u2,cs]);X1.current.register([t6,e6],["open","high","low","close"],[Co,u2,"downColor",cs]);es.current.register([t6,e6],{open:un,high:un,low:$w,close:un,color:s2,downColor:s2,noteText:s2});X1.current.register([Y8,Ll],["lower","q1","median","q3","upper","mean","outliers"],[Co,u2,cs,as]);es.current.register([Y8,Ll],{lower:un,q1:un,median:un,q3:un,upper:un,mean:un,outliers:s2,color:s2,noteText:s2});X1.current.register([u4,q8],["current","target"],[Co,u2,"visibleInLegend",cs,as]);es.current.register([u4,q8],{current:un,target:un,color:s2,noteText:s2});X1.current.register([p4,u9],[e2],[Co,u2,"explode","visibleInLegend","visible",as]);var Em=[Co,e2,Ne,We],mEt="mousedown",N4="mousemove",LA="contextmenu",EA="mouseleave",IA="keydown",HA="focus",DA="blur",yEt=20,jp=function(t){function r(n,i,o,a){var s=this;a===void 0&&(a={}),t.call(this),this.observers=[],this.addObserver(a.observer),this.chartService=new Kl(this,a),this.chartService.theme=o,this._initElement(n);var l=zt({},this.options,i);this._originalOptions=zt({},l),this._theme=o,this._initTheme(l,o),this._focusState={},this._initHandlers(),this._initSurface(),this.bindCategories(),u0.preloadFonts(i,function(){s.fontLoaded=!0,s._destroyed||(s.trigger("init"),s._redraw(),s._attachEvents())})}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype._initElement=function(i){for(this._setElementClass(i),i.style.position="relative",i.tabIndex=i.getAttribute("tabindex")?i.getAttribute("tabindex"):0,i.setAttribute("role","graphics-document document");i.firstChild;)i.removeChild(i.firstChild);this.element=i},r.prototype._setElementClass=function(i){Ir(i,"k-chart")},r.prototype._initTheme=function(i,o){for(var a=[],s=i.series||[],l=0;l0||o.height>0;i||s&&(!a||o.width!==a.width||o.height!==a.height)?(this._size=o,this._resize(o,i),this.trigger("resize",o)):s&&this._selections&&lV(this._selections,function(l){return!l.visible})&&(this._destroySelections(),this._setupSelection())},r.prototype._resize=function(){this._noTransitionsRedraw()},r.prototype.redraw=function(i){if(this.applyDefaults(this.options),this.applySeriesColors(),i){var o=this._model._plotArea,a=o.findPane(i);o.redraw(a)}else this._redraw()},r.prototype.getAxis=function(i){return FV(i,this._plotArea.axes)},r.prototype.findAxisByName=function(i){return this.getAxis(i)},r.prototype.findPaneByName=function(i){for(var o=this._plotArea.panes,a=0;a=0){var f=this._plotArea.pointsByCategoryIndex(p);s.showAt(f)}}else h&&s.show(h)},r.prototype.hideTooltip=function(){this._tooltip.hide()},r.prototype._initSurface=function(){var i=this.surface,o=this._surfaceWrap(),a=this.options.chartArea||{};a.width&&Ia(o,{width:a.width}),a.height&&Ia(o,{height:a.height}),!i||i.options.type!==this.options.renderAs?(this._destroySurface(),this.surface=Gl.create(o,{type:this.options.renderAs}),this.surface.bind("mouseenter",this._surfaceMouseenterHandler),this.surface.bind("mouseleave",this._surfaceMouseleaveHandler)):(this.surface.clear(),this.surface.resize())},r.prototype._surfaceWrap=function(){return this.element},r.prototype._redraw=function(){var i=this._getModel();this._size={width:i.options.width,height:i.options.height},this._destroyView(),this._setElementAccessibilityAttributes(),this._model=i,this._plotArea=i._plotArea,this._legend=i._legend,i.renderVisual(),this.options.transitions!==!1&&i.traverse(function(o){o.animation&&o.animation.setup()}),this._initSurface(),this.surface.draw(i.visual),this.options.transitions!==!1&&i.traverse(function(o){o.animation&&o.animation.play()}),this._tooltip=this._createTooltip(),this._highlight=new wLt,this._setupSelection(),this._createPannable(),this._createZoomSelection(),this._createMousewheelZoom(),this.trigger(wAt),VA(this._plotArea.panes),this._navState||this._cancelDomEvents(),this._redrawFocusHighlight()},r.prototype._redrawFocusHighlight=function(){var i=this,o=i._focusState,a=o.legendInFocus,s=o.preserveHighlight;a&&s&&(this._focusElement(this._getFocusedLegendItem(),!1),this._focusState.preserveHighlight=!1)},r.prototype._setElementAccessibilityAttributes=function(){var i=this.options.title,o=Bn(i)?i:i.description||i.text;o&&this.element.setAttribute("aria-roledescription",o)},r.prototype.exportVisual=function(i){var o;if(i&&(i.width||i.height||i.options)){var a=this.options,s=zt({},i.options,{chartArea:{width:i.width,height:i.height}});Im(this._originalOptions,s),this.options=zt({},this._originalOptions,s),this._initTheme(this.options,this._theme),this.bindCategories();var l=this._getModel();l.renderVisual(),VA(l._plotArea.panes),o=l.visual,this.options=a}else o=this.surface.exportVisual();return o},r.prototype._sharedTooltip=function(){return this._plotArea instanceof so&&this.options.tooltip&&this.options.tooltip.shared},r.prototype._createPannable=function(){var i=this.options;i.pannable!==!1&&(this._pannable=new bF(this._plotArea,i.pannable))},r.prototype._createZoomSelection=function(){var i=this.options.zoomable,o=(i||{}).selection;i!==!1&&o!==!1&&(this._zoomSelection=new wF(this,o))},r.prototype._createMousewheelZoom=function(){var i=this.options.zoomable,o=(i||{}).mousewheel;i!==!1&&o!==!1&&(this._mousewheelZoom=new kLt(this,o))},r.prototype._toggleDragZoomEvents=function(){var i=this.options.pannable,o=this.options.zoomable,a=(o||{}).selection,s=(o||{}).mousewheel,l=!i&&(o===!1||a===!1)&&!this.requiresHandlers([yv,ac,sc]),h=(o===!1||s===!1)&&!this.requiresHandlers([N6,k3,_3]),p=this.element;this._dragZoomEnabled&&l&&h?(p.style.touchAction=this._touchAction||"",this._dragZoomEnabled=!1):!this._dragZoomEnabled&&!(l&&h)&&(p.style.touchAction="none",this._dragZoomEnabled=!0),this._toggleDomEvents(!l,!h)},r.prototype._toggleDomEvents=function(i,o){var a=this.domEvents;a&&(a.toggleDrag&&a.toggleDrag(i),a.toggleZoom&&a.toggleZoom(o))},r.prototype._createTooltip=function(){var i=this,o=i.options.tooltip,a;return this._sharedTooltip()?a=this._createSharedTooltip(o):a=new ILt(this.chartService,o),a},r.prototype._createSharedTooltip=function(i){return new Pw(this._plotArea,i)},r.prototype.applyDefaults=function(i,o){bEt(i,o),wEt(i,o)},r.prototype.applySeriesColors=function(){for(var i=this.options,o=i.series,a=i.seriesColors||[],s=0;s=0&&this.observers.splice(o,1)},r.prototype.requiresHandlers=function(i){for(var o=this.observers,a=0;a=.1){s=Math.round(s*10),this._gestureDistance=i.distance;var l={delta:s,axisRanges:$6(this._plotArea.axes),originalEvent:i};if(this._zooming||!this.trigger(N6,l)){var h=this._eventCoordinates(i);this._zooming||(this._zooming=!0);var p=l.axisRanges=o.updateRanges(s,h);p&&!this.trigger(k3,l)&&o.zoom()}}}},r.prototype._mouseout=function(i){if(i.element){var o=this._drawingChartElement(i.element,i);o&&o.leave&&o.leave(this,i.originalEvent)}},r.prototype._start=function(i){var o=this._eventCoordinates(i);this._stopChartHandlers(i)||!this._plotArea.backgroundContainsPoint(o)||(this.requiresHandlers([yv,ac,sc])&&this._startNavigation(i,o,yv),this._pannable&&this._pannable.start(i)&&(this.surface.suspendTracking(),this._unsetActivePoint(),this._clearFocusedElement(),this._suppressHover=!0,this.chartService.panning=!0),this._zoomSelection&&this._zoomSelection.start(i)&&this.trigger(N6,{axisRanges:$6(this._plotArea.axes),originalEvent:i}))},r.prototype._move=function(i){var o=this,a=o._navState,s=o._pannable;if(!this._stopChartHandlers(i)){if(s){var l=s.move(i);l&&!this.trigger(ac,{axisRanges:l,originalEvent:i})&&s.pan()}else if(a){for(var h={},p=a.axes,f=0;f1,a=this._hasInactiveOpacity();a?this._displayInactiveOpacity(i,o):this._highlight.show(i)},r.prototype._hideInactiveOpacity=function(i){var o=this._plotArea.series.length>1,a=this._hasInactiveOpacity();a&&(o&&this._activeChartInstance&&(this._updateSeriesOpacity(i,!0),this._applySeriesOpacity(this._activeChartInstance.children,null,!0),this._activeChartInstance=null),this._highlight&&this._highlight.hide(),this._activePoint=null)},r.prototype._hasInactiveOpacity=function(){var i=this.options.seriesDefaults.highlight.inactiveOpacity!==void 0,o=this.options.series.filter(function(a){return a.highlight.inactiveOpacity!==void 0}).length>0;return i||o},r.prototype._getInactiveOpacityForSeries=function(i){var o=this.options.seriesDefaults.highlight.inactiveOpacity,a=i.highlight.inactiveOpacity;return a||o||i.opacity||o_},r.prototype._getDefaultOpacityForSeries=function(i){return i.defaultOpacity||i.opacity||o_},r.prototype._mouseover=function(i){var o,a=this._startHover(i.element,i.originalEvent);a&&a.tooltipTracking&&!this._mouseMoveTrackHandler&&!this._sharedTooltip()&&(this._mouseMoveTrackHandler=this._mouseMoveTracking.bind(this),nc(document,(o={},o[N4]=this._mouseMoveTrackHandler,o)))},r.prototype._mouseMoveTracking=function(i){var o,a=this,s=a.options,l=a._tooltip,h=a._highlight,p=a._activePoint,f=this._eventCoordinates(i);if(this._plotArea.box.containsPoint(f)){if(p&&p.tooltipTracking&&p.series&&p.parent.getNearestPoint){var g=p.parent.getNearestPoint(f.x,f.y,p.seriesIx);if(g&&g!==p&&(this._activePoint=g,!g.hover(this,i))){var b=zt({},s.tooltip,g.options.tooltip);b.visible&&l.show(g),h.show(g)}}}else oc(document,(o={},o[N4]=this._mouseMoveTrackHandler,o)),this._unsetActivePoint(),this._clearFocusedElement(),this._mouseMoveTrackHandler=null,this._hideInactiveOpacity(p)},r.prototype._mousemove=function(i){var o=this._eventCoordinates(i),a=this._plotArea;if(this._trackCrosshairs(o),a.hover){var s=a.backgroundContainsPoint(o);s?(this._plotAreaHovered=!0,this._plotArea.hover(this,i)):this._plotAreaHovered&&!s&&(this._plotAreaHovered=!1,this.trigger(mv))}this._sharedTooltip()&&this._trackSharedTooltip(o,i)},r.prototype._trackCrosshairs=function(i){for(var o=this._plotArea.crosshairs,a=0;a0&&!this.trigger(jV,I)?(l.visible&&f.showAt(z,i),g.show(z),this._sharedHighlight=!0):f.hide(),this._tooltipCategoryIx=b}else a&&this._sharedHighlight&&(g.hide(),f.hide(),this._sharedHighlight=!1)}else this._sharedHighlight&&(g.hide(),f.hide(),this._tooltipCategoryIx=null,this._sharedHighlight=!1)}},r.prototype.hideElements=function(i){var o=this._plotArea;this._mousemove.cancel(),o.hideCrosshairs(),this._unsetActivePoint(i)},r.prototype._unsetActivePoint=function(i){var o=this,a=o._highlight;this._activePoint=null,this._hoveredPoint=null,(!i||!i.keepTooltipOpen)&&this._hideTooltip(),this._tooltipCategoryIx=null,this._sharedHighlight=!1,a&&a.hide()},r.prototype._deferRedraw=function(){this._redraw()},r.prototype._clearRedrawTimeout=function(){this._redrawTimeout&&(clearInterval(this._redrawTimeout),this._redrawTimeout=null)},r.prototype.bindCategories=function(){for(var i=this,o=this.options,a=[].concat(o.categoryAxis),s=0;s0}),f=p.map(function(M){return X1.current.bindPoint(M,0).fields.category}),g=f.reduce(function(M,I){return M||tF(i,I)},!1),b=p.filter(function(M,I){return M.categoryField||ne(f[I])});if(b.forEach(function(M){return M.data.forEach(function(I,F){var H=X1.current.bindPoint(M,F).fields.category;if(g){var E=QV(H,I,a.chartService.intl);H=E?E.getTime():void 0}s.add(H)})}),s.size>0){var z=Array.from(s.values());g&&(z=z.sort().map(function(M){return M&&new Date(M)})),i.categories=z}else h&&(i.categories=[])},r.prototype._isBindable=function(i){for(var o=X1.current.valueFields(i),a=!0,s=0;s1,g=p.length?p[0]:p;this._displayInactiveOpacity(g,f,p)}else l.show(p)},r.prototype._shouldAttachMouseMove=function(){return this._plotArea.crosshairs.length||this._tooltip&&this._sharedTooltip()||this.requiresHandlers([YV,mv])},r.prototype.updateMouseMoveHandler=function(){var i,o;oc(this.element,(i={},i[N4]=this._mousemove,i)),this._shouldAttachMouseMove()&&nc(this.element,(o={},o[N4]=this._mousemove,o))},r.prototype.applyOptions=function(i,o){Im(this._originalOptions,i),this._originalOptions=zt(this._originalOptions,i),this.options=zt({},this._originalOptions),o&&(this._theme=o,this.chartService.theme=o),this._initTheme(this.options,this._theme),this._toggleDragZoomEvents()},r.prototype.setOptions=function(i,o){this.applyOptions(i,o),this.bindCategories(),this.redraw(),this.updateMouseMoveHandler()},r.prototype.setDirection=function(i){this.chartService.rtl=!!i,this.surface&&this.surface.type==="svg"&&this._destroySurface()},r.prototype.setIntlService=function(i){this.chartService.intl=i},r.prototype.noTransitionsRedraw=function(){this._noTransitionsRedraw()},r.prototype.destroy=function(){var i,o;this._destroyed=!0,oc(this.element,(i={},i[LA]=this._clickHandler,i[v9]=this._mousewheelHandler,i[N4]=this._mousemove,i[EA]=this._mouseleaveHandler,i[IA]=this._keydownHandler,i[HA]=this._focusHandler,i[DA]=this._blurHandler,i)),this.domEvents&&(this.domEvents.destroy(),delete this.domEvents),this._mouseMoveTrackHandler&&oc(document,(o={},o[N4]=this._mouseMoveTrackHandler,o)),this._focusState=null,this._destroyView(),this._destroySurface(),this._clearRedrawTimeout()},r.prototype._destroySurface=function(){var i=this.surface;i&&(i.unbind("mouseenter",this._surfaceMouseenterHandler),i.unbind("mouseleave",this._surfaceMouseleaveHandler),i.destroy(),this.surface=null)},r.prototype._destroySelections=function(){var i=this._selections;if(i)for(;i.length>0;)i.shift().destroy()},r.prototype._destroyView=function(){var i=this._model;i&&(i.destroy(),this._model=null),this._unsetActivePoint(),this._clearFocusedElement(),this._resetDrilldownPoint(),this._destroySelections(),this._tooltip&&this._tooltip.destroy(),this._highlight&&this._highlight.destroy(),this._zoomSelection&&(this._zoomSelection.destroy(),delete this._zoomSelection),this._pannable&&(this._pannable.destroy(),delete this._pannable),this._mousewheelZoom&&(this._mousewheelZoom.destroy(),delete this._mousewheelZoom)},r}(Ve);function xEt(t){for(var r=Em,n=0;n1?a:a[0]}function wEt(t,r){var n=t.series,i=n.length,o=t.seriesDefaults,a=zt({},t.seriesDefaults),s=r?zt({},r.seriesDefaults):{},l=zt({},s);TA(a),TA(l);for(var h=0;h0&&(M+=a.left+a.right),M},r.prototype._createSharedTooltip=function(i){return new zEt(this._plotArea,i)},r.normalizeOptions=function(i){var o=BA(i);return zi(o)?o={seriesDefaults:{data:o}}:o=zt({},o),o.series||(o.series=[{data:BA(o.data)}]),zt(o,{seriesDefaults:{type:o.type}}),(c1(o.series[0].type,FA)||c1(o.seriesDefaults.type,FA))&&(o=zt({},{categoryAxis:{crosshair:{visible:!1}}},o)),o},r}(jp);ve(_Et,{chartArea:{margin:2},axisDefaults:{visible:!1,majorGridLines:{visible:!1},valueAxis:{narrowRange:!0}},seriesDefaults:{type:"line",area:{line:{width:.5}},bar:{stack:!0},padding:2,width:.5,overlay:{gradient:null},highlight:{visible:!1},border:{width:0},markers:{size:2,visible:!1}},tooltip:{visible:!0,shared:!0},categoryAxis:{crosshair:{visible:!0,tooltip:{visible:!1}}},legend:{visible:!1},transitions:!1,pointWidth:5,panes:[{clip:!1}]});var AEt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.setup=function(){this._initialOpacity=parseFloat(br(this.element,"opacity").opacity)},r.prototype.step=function(i){br(this.element,{opacity:String(D2(this._initialOpacity,0,i))})},r.prototype.abort=function(){t.prototype.abort.call(this),br(this.element,{display:"none",opacity:String(this._initialOpacity)})},r.prototype.cancel=function(){t.prototype.abort.call(this),br(this.element,{opacity:String(this._initialOpacity)})},r}(G2);function Cv(t,r){var n=document.createElement("div");return n.className=t,r&&(n.style.cssText=r),n}var RF=function(t){function r(n,i,o){t.call(this),this.options=zt({},this.options,o),this.container=n,this.chartService=i;var a=br(n,["paddingLeft","paddingTop"]);this.chartPadding={top:a.paddingTop,left:a.paddingLeft},this.createElements(),n.appendChild(this.element)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.createElements=function(){var i=this.element=Cv("k-navigator-hint","display: none; position: absolute; top: 1px; left: 1px;"),o=this.tooltip=Cv("k-tooltip k-chart-tooltip"),a=this.scroll=Cv("k-scroll");o.innerHTML=" ",i.appendChild(o),i.appendChild(a)},r.prototype.show=function(i,o,a){var s=this,l=s.element,h=s.options,p=s.scroll,f=s.tooltip,g=Z1(J1(i)+J1(o-i)/2),b=a.width()*.4,z=a.center().x-b,M=a.center().x,I=M-z,F=h.max-h.min,H=I/F,E=g-h.min,R=this.chartService.intl.format(h.format,i,o),W=di(h);this.clearHideTimeout(),this._visible||(br(l,{visibility:"hidden",display:"block"}),this._visible=!0),W&&(R=W({from:i,to:o})),f.innerHTML=R,br(f,{left:a.center().x-f.offsetWidth/2,top:a.y1});var $=br(f,["marginTop","borderTopWidth","height"]);br(p,{width:b,left:z+E*H,top:a.y1+$.marginTop+$.borderTopWidth+$.height/2}),br(l,{visibility:"visible"})},r.prototype.clearHideTimeout=function(){this._hideTimeout&&clearTimeout(this._hideTimeout),this._hideAnimation&&this._hideAnimation.cancel()},r.prototype.hide=function(){var i=this;this.clearHideTimeout(),this._hideTimeout=setTimeout(function(){i._visible=!1,i._hideAnimation=new AEt(i.element),i._hideAnimation.setup(),i._hideAnimation.play()},this.options.hideDelay)},r.prototype.destroy=function(){this.clearHideTimeout(),this.container&&this.container.removeChild(this.element),delete this.container,delete this.chartService,delete this.element,delete this.tooltip,delete this.scroll},r}(Ve);ve(RF,{format:"{0:d} - {1:d}",hideDelay:500});var Pa="_navigator",za=Pa,NA="_default",LEt=3,$A=function(t){function r(n){var i;t.call(this),this.chart=n;var o=this.options=zt({},this.options,n.options.navigator),a=o.select;a&&(a.from=this.parseDate(a.from),a.to=this.parseDate(a.to)),ne(o.hint.visible)||(o.hint.visible=o.visible),this.chartObserver=new fo(this,(i={},i[ac]="_drag",i[sc]="_dragEnd",i[k3]="_zoom",i[_3]="_zoomEnd",i)),n.addObserver(this.chartObserver)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.parseDate=function(i){return Ci(this.chart.chartService.intl,i)},r.prototype.clean=function(){this.selection&&(this.selection.destroy(),this.selection=null),this.hint&&(this.hint.destroy(),this.hint=null)},r.prototype.destroy=function(){this.chart&&(this.chart.removeObserver(this.chartObserver),delete this.chart),this.clean()},r.prototype.redraw=function(){this._redrawSelf(),this.initSelection()},r.prototype.initSelection=function(){var i=this,o=i.chart,a=i.options,s=this.mainAxis(),l=s.roundedRange(),h=l.min,p=l.max,f=a.select,g=f.from,b=f.to,z=f.mousewheel,M=EEt(s);s.categoriesCount()!==0&&(this.clean(),M.box=s.box,this.selection=new Dw(o,M,{min:h,max:p,from:g||h,to:b||p,mousewheel:t1(z,{zoom:"left"}),visible:a.visible},new fo(this,{selectStart:"_selectStart",select:"_select",selectEnd:"_selectEnd"})),a.hint.visible&&(this.hint=new RF(o.element,o.chartService,{min:h,max:p,template:di(a.hint),format:a.hint.format})))},r.prototype.setRange=function(){var i=this.chart._createPlotArea(!0),o=i.namedCategoryAxes[za],a=o.roundedRange(),s=a.min,l=a.max,h=this.options.select||{},p=h.from||s;pl&&(f=l),this.options.select=zt({},h,{from:p,to:f}),this.filterAxes()},r.prototype._redrawSelf=function(i){var o=this.chart._plotArea;o&&o.redraw(Pr(o.panes),i)},r.prototype.redrawSlaves=function(){var i=this.chart,o=i._plotArea,a=o.panes.filter(function(s){return s.options.name!==Pa});o.srcSeries=i.options.series,o.options.categoryAxis=i.options.categoryAxis,o.clearSeriesPointsCache(),o.redraw(a)},r.prototype._drag=function(i){var o=this,a=o.chart,s=o.selection,l=a._eventCoordinates(i.originalEvent),h=this.mainAxis(),p=h.roundedRange(),f=h.pane.box.containsPoint(l),g=a._plotArea.categoryAxis,b=i.axisRanges[g.options.name],z=this.options.select,M;if(!(!b||f||!s)){z.from&&z.to?M=J1(z.to)-J1(z.from):M=J1(s.options.to)-J1(s.options.from);var I=Z1(Xe(J1(b.min),p.min,J1(p.max)-M)),F=Z1(Xe(J1(I)+M,J1(p.min)+M,p.max));this.options.select={from:I,to:F},this.options.liveDrag&&(this.filterAxes(),this.redrawSlaves()),s.set(I,F),this.showHint(I,F)}},r.prototype._dragEnd=function(){this.filterAxes(),this.filter(),this.redrawSlaves(),this.hint&&this.hint.hide()},r.prototype.readSelection=function(){var i=this,o=i.selection.options,a=o.from,s=o.to,l=i.options.select;l.from=a,l.to=s},r.prototype.filterAxes=function(){var i=this,o=i.options.select;o===void 0&&(o={});for(var a=i.chart,s=a.options.categoryAxis,l=o.from,h=o.to,p=0;p1&&(g*=LEt),z-b>1?(s.zoom(g,M),this.readSelection()):(a.options.min=h.from,h.from=a.scaleRange(-i.delta*this.chart._mousewheelZoomRate(),M).min),p&&(this.filterAxes(),this.redrawSlaves()),s.set(h.from,h.to),this.showHint(this.options.select.from,this.options.select.to)}},r.prototype._zoomEnd=function(i){this._dragEnd(i)},r.prototype.showHint=function(i,o){var a=this.chart._plotArea;this.hint&&this.hint.show(i,o,a.backgroundBox())},r.prototype._selectStart=function(i){return this.chart._selectStart(i)},r.prototype._select=function(i){return this.showHint(i.from,i.to),this.chart._select(i)},r.prototype._selectEnd=function(i){return this.hint&&this.hint.hide(),this.readSelection(),this.filterAxes(),this.filter(),this.redrawSlaves(),this.chart._selectEnd(i)},r.prototype.mainAxis=function(){var i=this.chart._plotArea;if(i)return i.namedCategoryAxes[za]},r.prototype.select=function(i,o){var a=this.options.select;return i&&o&&(a.from=this.parseDate(i),a.to=this.parseDate(o),this.filterAxes(),this.filter(),this.redrawSlaves(),this.selection.set(i,o)),{from:a.from,to:a.to}},r.setup=function(i,o){if(i===void 0&&(i={}),o===void 0&&(o={}),!i.__navi){i.__navi=!0;var a=zt({},o.navigator,i.navigator),s=i.panes=[].concat(i.panes),l=zt({},a.pane,{name:Pa});a.visible||(l.visible=!1,l.height=.1),i.navigator.position!=="top"?s.push(l):s.unshift(l),s.forEach(function(h){h.name=h.name||NA}),r.attachAxes(i,a),r.attachSeries(i,a,o)}},r.attachAxes=function(i,o){var a=o.series||[],s=i.categoryAxis=[].concat(i.categoryAxis),l=i.valueAxis=[].concat(i.valueAxis),h=s.concat(l);h.forEach(function(z){z.pane=z.pane||NA});var p=wr(a,NV),f=p.length===0,g=zt({type:"date",pane:Pa,roundToBaseUnit:!f,justified:f,_collapse:!1,majorTicks:{visible:!0},tooltip:{visible:!1},labels:{step:1},autoBind:o.autoBindElements,autoBaseUnitSteps:{minutes:[1],hours:[1,2],days:[1,2],weeks:[],months:[1],years:[1]}}),b=o.categoryAxis;s.push(zt({},g,{maxDateGroups:200},b,{name:za,title:null,baseUnit:"fit",baseUnitStep:"auto",labels:{visible:!1},majorTicks:{visible:!1}}),zt({},g,b,{name:za+"_labels",maxDateGroups:20,baseUnitStep:"auto",labels:{position:""},plotBands:[],autoBaseUnitSteps:{minutes:[]},_overlap:!0}),zt({},g,b,{name:za+"_ticks",maxDateGroups:200,majorTicks:{width:.5},plotBands:[],title:null,labels:{visible:!1,mirror:!0},_overlap:!0})),l.push(zt({name:za,pane:Pa,majorGridLines:{visible:!1},visible:!1},o.valueAxis))},r.attachSeries=function(i,o,a){for(var s=i.series=i.series||[],l=[].concat(o.series||[]),h=a.seriesColors,p=o.seriesDefaults,f=0;f0&&(s=GA(s,a.width));var l=FEt.fromRect(s,{stroke:{color:a.width?a.color:"",width:a.width,opacity:a.opacity,dashType:a.dashType,lineJoin:"round",lineCap:"round"},fill:{color:i.background}});return l},r.prototype._initSurface=function(){var i=this,o=i.options,a=i.surface,s=this._surfaceElement(),l=this._surfaceSize();Ia(s,l),!a||a.options.type!==o.renderAs?(a&&a.destroy(),this.surface=REt.create(s,{type:o.renderAs})):(this.surface.clear(),this.surface.resize())},r.prototype._surfaceSize=function(){var i=this.options,o=this._getSize();return i.gaugeArea&&zt(o,i.gaugeArea),o},r.prototype._surfaceElement=function(){return this.surfaceElement||(this.surfaceElement=document.createElement("div"),this.element.appendChild(this.surfaceElement)),this.surfaceElement},r.prototype.getSize=function(){return this._getSize()},r.prototype._getSize=function(){var i=this.element,o=this._defaultSize(),a=i.offsetWidth,s=i.offsetHeight;return a||(a=o.width),s||(s=o.height),{width:a,height:s}},r.prototype._defaultSize=function(){return{width:$F,height:NF}},r.prototype._toggleTransitions=function(i){var o=this;this.options.transitions=i;for(var a=0;a0&&i.visible){var s=new Hm({stroke:{color:i.color,dashType:i.dashType,width:i.width}});s.moveTo(o.x1,o.y1).lineTo(o.x2,o.y2),a.append(s)}return a},r.prototype.renderTicks=function(){var i=new W6,o=this.options,a=o.majorTicks.visible?o.majorUnit:0,s={vertical:o.vertical,mirror:o.labels.mirror,lineBox:this.lineBox()};return UA(i,this.getMajorTickPositions(),s,o.majorTicks),UA(i,this.getMinorTickPositions(),s,zt({},{skipUnit:a/o.minorUnit},o.minorTicks)),i},r}(T2);ve(KF,{min:0,max:50,majorTicks:{size:15,align:e4,color:kr,width:sl,visible:!0},minorTicks:{size:10,align:e4,color:kr,width:sl,visible:!0},line:{width:sl},labels:{position:e4,padding:2},mirror:!1,_alignLines:!1});var Up=function(t){function r(n,i){t.call(this);var o=n.options,a=o.min,s=o.max,l=this.options=zt({},this.options,i);l.fill=l.color,this.scale=n,ne(l.value)?l.value=Xe(l.value,a,s):l.value=a}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.value=function(i){var o=this.options,a=o.value;if(arguments.length===0)return a;var s=this.scale.options,l=s.min,h=s.max;o._oldValue=ne(o._oldValue)?o.value:l,o.value=Xe(i,l,h),this.elements&&this.repaint()},r}(Ve);ve(Up,{color:kr});var jw=function(t){function r(n,i){t.call(this,n,i),this.options=zt({track:{visible:ne(i.track)}},this.options)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.reflow=function(){var i=this,o=i.options,a=i.scale,s=a.options,l=s.mirror,h=s.vertical,p=a.lineBox(),f=o.track.size||o.size,g=o.size/2,b=T1(o.margin),z=h?b[l?"left":"right"]:b[l?"bottom":"top"],M,I,F;z=l?-z:z,h?(F=new Ce(p.x1+z,p.y1,p.x1+z,p.y2),l?F.x1-=f:F.x2+=f,o.shape!==m8&&(I=new Ce(p.x2+z,p.y1-g,p.x2+z,p.y2+g),M=I)):(F=new Ce(p.x1,p.y1-z,p.x2,p.y1-z),l?F.y2+=f:F.y1-=f,o.shape!==m8&&(I=new Ce(p.x1-g,p.y1-z,p.x2+g,p.y1-z),M=I)),this.trackBox=F,this.pointerRangeBox=I,this.box=M||F.clone().pad(o.border.width)},r.prototype.getElementOptions=function(){var i=this.options;return{fill:{color:i.color,opacity:i.opacity},stroke:ne(i.border)?{color:i.border.width?i.border.color||i.color:"",width:i.border.width,dashType:i.border.dashType,opacity:i.opacity}:null}},r.prototype._margin=function(){var i=this,o=i.scale,a=i.options,s=o.options,l=s.mirror,h=s.vertical,p=T1(a.margin),f=h?p[l?"left":"right"]:p[l?"bottom":"top"];return f},r}(Up);ve(jw,{shape:m8,track:{border:{width:1}},color:kr,border:{width:1},opacity:1,margin:T1(3),animation:{type:m8},visible:!0});var Gw=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.setup=function(){var i=this.options,o=i.margin,a=i.from,s=i.to,l=i.vertical,h=l?"x1":"y1";i.mirror===l?(a[h]-=o,s[h]-=o):(a[h]+=o,s[h]+=o);var p=this.fromScale=new ye(a.x1,a.y1),f=this.toScale=new ye(s.x1,s.y1);i.duration!==0&&(i.duration=Math.max(p.distanceTo(f)/i.duration*1e3,1))},r.prototype.step=function(i){var o=D2(this.fromScale.x,this.toScale.x,i),a=D2(this.fromScale.y,this.toScale.y,i);this.element.transform(nr().translate(o,a))},r}(G2);ve(Gw,{easing:Gp,duration:OF});ia.current.register(BF,Gw);var f3=ye,BEt=$e,NEt=function(t){function r(n,i){t.call(this,n,i),ne(this.options.size)||(this.options.size=this.scale.options.majorTicks.size*.6)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.pointerShape=function(){var i=this,o=i.scale,a=i.options.size,s=a/2,l=o.options.mirror?-1:1,h;return o.options.vertical?h=[new f3(0,0-s),new f3(0-l*a,0),new f3(0,0+s)]:h=[new f3(0-s,0),new f3(0,0+l*a),new f3(0+s,0)],h},r.prototype.repaint=function(){var i=this,o=i.scale,a=i.options,s=new Gw(this.elements,zt(a.animation,{vertical:o.options.vertical,mirror:o.options.mirror,margin:this._margin(a.margin),from:o.getSlot(a._oldValue),to:o.getSlot(a.value)}));a.animation.transitions===!1&&(s.options.duration=0),s.setup(),s.play()},r.prototype.render=function(){var i=this,o=i.scale,a=i.options,s=this.getElementOptions(),l=this.pointerShape(a.value);a.animation.type=BF;var h=new BEt({stroke:s.stroke,fill:s.fill}).moveTo(l[0]).lineTo(l[1]).lineTo(l[2]).close(),p=o.getSlot(a.value);return h.transform(nr().translate(p.x1,p.y1)),this.elements=h,h},r}(jw),Uw=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.setup=function(){var i=this.options,o=this.axis=i.vertical?We:Ne,a=this.to=i.newPoints[0][o],s=this.from=i.oldPoints[0][o];i.duration!==0&&(i.duration=Math.max(Math.abs(a-s)/i.speed*1e3,1)),this._set(s)},r.prototype.step=function(i){var o=D2(this.from,this.to,i);this._set(o)},r.prototype._set=function(i){var o="set"+this.axis.toUpperCase(),a=this.options.newPoints;a[0][o](i),a[1][o](i)},r}(G2);ve(Uw,{easing:Gp,speed:OF});ia.current.register(m8,Uw);var $Et=H1,YA=$e,WEt=function(t){function r(n,i){t.call(this,n,i),ne(this.options.size)||(this.options.size=this.scale.options.majorTicks.size*.3)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.pointerShape=function(i){var o=this,a=o.scale,s=o.options,l=a.options,h=l.mirror,p=l.vertical,f=h===p?-1:1,g=s.size*f,b=a.getSlot(a.options.min),z=a.getSlot(i),M=p?We:Ne,I=p?Ne:We,F=this._margin()*f,H=new ye;H[M]=b[M+"1"],H[I]=b[I+"1"];var E=new ye;E[M]=z[M+"1"],E[I]=z[I+"1"],p?(H.translate(F,0),E.translate(F,0)):(H.translate(0,F),E.translate(0,F));var R=E.clone(),W=H.clone();return p?(R.translate(g,0),W.translate(g,0)):(R.translate(0,g),W.translate(0,g)),[H,E,R,W]},r.prototype.repaint=function(){var i=this,o=i.scale,a=i.options,s=this.pointerShape(a.value),l=this.pointerPath,h=this.pointerShape(a._oldValue);l.moveTo(s[0]).lineTo(s[1]).lineTo(s[2]).lineTo(s[3]).close();var p=new Uw(l,zt(a.animation,{reverse:o.options.reverse,vertical:o.options.vertical,oldPoints:[h[1],h[2]],newPoints:[s[1],s[2]]}));a.animation.transitions===!1&&(p.options.duration=0),p.setup(),p.play()},r.prototype.render=function(){var i=new $Et,o=this.getElementOptions();this.options.track.visible&&i.append(this.renderTrack());var a=this.pointerPath=new YA({stroke:o.stroke,fill:o.fill});return i.append(a),this.elements=i,i},r.prototype.renderTrack=function(){var i=this.options.track,o=i.border||{},a=this.trackBox.clone().pad(o.width||0);return new YA.fromRect(a.toRect(),{fill:{color:i.color,opacity:i.opacity},stroke:{color:o.width?o.color||i.color:"",width:o.width,dashType:o.dashType}})},r}(jw),jEt=60,GEt=60,UEt=H1,YEt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.reflow=function(i){var o=this.pointers,a=i.origin.x,s=i.origin.y,l=new Ce(a,s,a+i.width(),s+i.height());this.scale.reflow(l),this._shrinkScaleWidth(l);for(var h=0;h0&&(a.box.shrink(s,0),a.box.alignTo(i,"center"),a.reflow(a.box))}},r.prototype._shrinkElements=function(){for(var i=this,o=this,a=o.scale,s=o.pointers,l=a.box.clone(),h=a.options.vertical?"y":"x",p=s[0].box,f=0;f=360&&o.max%o.majorUnit===0&&(i-=1),i},r.prototype.renderLabels=function(){var i=this,o=this.options,a=this.arc.clone(),s=a.getRadiusX(),l=this.tickAngles(a,o.majorUnit),h=o.rangeSize=o.rangeSize||s*.1,p=new A7,f=s*.05;ne(o.rangeDistance)?f=o.rangeDistance:o.rangeDistance=f;var g=o.labels,b=g.position===e4,z=ne(this.labelElements);b&&(s-=this.ticksSize(),this.hasRanges()&&!z&&(s-=h+f),a.setRadiusX(s).setRadiusY(s));for(var M=this.labels,I=M.length,F=T1(g.padding),H=(F.left+F.right)/2,E=(F.top+F.bottom)/2,R=0;R0){var o=this.options,a=o.rangeDistance,s=o.rangeSize,l=this.getRangeRadius();this.options.labels.position===e4&&(l+=s+a);for(var h=l+s/2,p=0;p=0;s--)s%a===0&&i.splice(s,1);return i},r.prototype.tickAngles=function(i,o){var a=this.options,s=a.reverse,l=a.max-a.min,h=i.endAngle-i.startAngle,p=l/o,f=i.startAngle,g=h/p;s&&(f+=h,g=-g),h>=360&&a.max%o===0&&(p-=1);for(var b=[],z=0;z5||h!==z&&(f=o.getPlotBox(h,i,a),0<=f&&f<=2)||p!==z&&(b=o.getPlotBox(p,i,a),0<=b&&b<=2)||(f>0&&b>0?z=h*2:f<0&&b<0?z=p*2:z=Ee((h+p)/2||1,pi),g=o.getPlotBox(z,i,a),0<=g&&g<=2)));)M=b,g>0?(p=z,b=g):(h=z,f=g)},r.prototype.getPlotBox=function(i,o,a){var s=this,l=this.scale,h=this.pointers,p=a.getRadiusX(),f=a.clone();f.setRadiusX(p+i).setRadiusY(p+i),l.arc=f,l.reflow(o),this.plotBbox=l.bbox;for(var g=0;ga.width&&(l-=p-a.width)}if(og&&(h-=b-g)}return{left:l,top:h}},r}(ZF),iIt=90;(function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype._createModel=function(){var i=this.options.scale;typeof i.startAngle!="number"&&(i.startAngle=iIt),i.endAngle=i.startAngle+360,t.prototype._createModel.call(this)},r})(rIt);var tR=10,U0=function(t){function r(n){t.call(this),this.setOptions(n),this.initProperties()}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.initProperties=function(){},r.prototype.setOptions=function(i){this.options=Object.assign({},this.options,i),this.quietZoneLength=this.options.addQuietZone?2*this.options.quietZoneLength:0},r.prototype.encode=function(i,o,a){var s=ne(i)?String(i):i;return this.initValue(s,o,a),this.options.addQuietZone&&this.addQuietZone(),this.addData(),this.options.addQuietZone&&this.addQuietZone(),{baseUnit:this.baseUnit,pattern:this.pattern}},r.prototype.initValue=function(){},r.prototype.addQuietZone=function(){this.pattern.push(this.options.quietZoneLength||tR)},r.prototype.addData=function(){},r.prototype.invalidCharacterError=function(i){throw new Error('Character "'+i+'" is not valid for symbology '+this.name+".")},r}(Ve);ve(U0,{quietZoneLength:tR,addQuietZone:!0,addCheckSum:!0});var nIt=Object.assign,eR=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.initProperties=function(){t.prototype.initProperties.call(this),nIt(this,{name:"Code 11",characterMap:["111121","211121","121121","221111","112121","212111","122111","111221","211211","211111","112111"],cCheckSumTotal:10,kCheckSumTotal:9,kCheckSumMinLength:10,checkSumMod:11,DASH_VALUE:10,DASH:"-",START:"112211",STOP:"11221"})},r.prototype.initValue=function(i,o){this.pattern=[],this.value=i,this.width=o,this.totalUnits=0},r.prototype.addData=function(){var i=this,o=this.value;this.addPattern(this.START);for(var a=0;a=this.kCheckSumMinLength){var s=(a+this.getWeightedSum(i,o,this.kCheckSumTotal))%this.checkSumMod;this.checksum+=s,this.addPattern(this.characterMap[s])}},r.prototype.getWeightedSum=function(i,o,a){for(var s=this,l=0,h=0;ha;)h=parseFloat((h-.1).toFixed(1)),l=i.getBaseUnit(h);if(l127?this.invalidCharacterError(r):this.addExtended(r.charCodeAt(0))},addExtended:function(r){for(var n=this,i,o=0;o=0;p--)s+=i.weightedValue(o[p],a-p,i.cCheckSumTotal);for(l=s%this.checkSumMod,s=this.weightedValue(l,1,this.kCheckSumTotal),p=a-1;p>=0;p--)s+=i.weightedValue(o[p],a-p+1,i.kCheckSumTotal);return h=s%this.checkSumMod,[l,h]},r.prototype._findCharacterByValue=function(i){var o=this;for(var a in o.characterMap)if(o.characterMap[a].value===i)return a},r.prototype.weightedValue=function(i,o,a){return(o%a||a)*i},r.prototype.addPattern=function(i){for(var o=this,a,s=0;s=0&&this.isCode(h)&&i.index=i.value.length||this.encoding[this.shiftKey].is(i.value,i.index+1)))return this.encoding.addPattern(this.SHIFT),i.shifted=!0,!0},r.prototype._moveState=function(){return this.encoding.addPattern(this.MOVE),!0},r}(Yp),l6={};l6.A=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.initProperties=function(){t.prototype.initProperties.call(this),zo(this,{key:"A",shiftKey:"B",MOVE:101,START:103})},r.prototype.isCode=function(i){return 0<=i&&i<96},r.prototype.getValue=function(i){return i<32?i+64:i-32},r}(aR);l6.B=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.initProperties=function(){t.prototype.initProperties.call(this),zo(this,{key:"B",shiftKey:"A",MOVE:100,START:104})},r.prototype.isCode=function(i){return 32<=i&&i<128},r.prototype.getValue=function(i){return i-32},r}(aR);l6.C=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.initProperties=function(){t.prototype.initProperties.call(this),zo(this,{key:"C",MOVE:99,START:105})},r.prototype.addStart=function(){this.encoding.addPattern(this.START)},r.prototype.is=function(i,o){var a=Pm(i,o,4);return(o+4<=i.length||i.length===2)&&Dm.test(a)},r.prototype.move=function(){this.encoding.addPattern(this.MOVE)},r.prototype.pushState=function(i){for(var o=this,a;(a=Pm(i.value,i.index,2))&&Dm.test(a)&&a.length===2;)o.encoding.addPattern(parseInt(a,10)),i.index+=2},r.prototype.getValue=function(i){return i},r}(Yp);l6.FNC4=function(t){function r(n,i){t.call(this,n),this._initSubStates(i)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.initProperties=function(){t.prototype.initProperties.call(this),zo(this,{key:"FNC4",dependentStates:["A","B"]})},r.prototype.addStart=function(i){var o=i.value.charCodeAt(0)-128,a=this._getSubState(o);this.encoding[a].addStart()},r.prototype.is=function(i,o){var a=i.charCodeAt(o);return this.isCode(a)},r.prototype.isCode=function(i){return 128<=i&&i<256},r.prototype.pushState=function(i){var o=this,a=this._initSubState(i),s=this.encoding,l=a.value.length,h;if(i.index+=l,l<3)for(;a.index0?o.getBySeparator(s,h):o.getByLength(s,h),f.ai.length)g=h+b+f.id.length+f.ai.length;else if(g=s.indexOf(o.startAI,h+1),g<0){if(h+f.ai.max+f.id.length+b=s.length)break;h=g,p.state!==o.startState&&(a[o.startState].move(p),p.state=o.startState),f.ai.length||a.addPattern(o.START)}i.index=i.value.length},r.prototype.validate=function(i,o){var a=o.substr(i.id.length),s=i.ai;if(!s.type&&!Dm.test(a))throw new Error("Application identifier "+i.id+" is numeric only but contains non numeric character(s).");if(s.type==="alphanumeric"&&!uIt.test(a))throw new Error("Application identifier "+i.id+" is alphanumeric only but contains non alphanumeric character(s).");if(s.length&&s.length!==a.length)throw new Error("Application identifier "+i.id+" must be "+s.length+" characters long.");if(s.min&&s.min>a.length)throw new Error("Application identifier "+i.id+" must be at least "+s.min+" characters long.");if(s.max&&s.max=i.value.length));)if(!i.shifted)i.previousState=i.state,i.state=a.getNextState(i,o),a[i.state].move(i);else{var l=i.state;i.state=i.previousState,i.previousState=l,i.shifted=!1}},r.prototype.addStart=function(i){this[i.state].addStart(i),this.position=1},r.prototype.addCheckSum=function(){this.checksum=this.checkSum%103,this.addPattern(this.checksum)},r.prototype.addStop=function(){this.addPattern(this.STOP)},r.prototype.setBaseUnit=function(){this.baseUnit=this.width/(this.totalUnits+this.quietZoneLength)},r.prototype.addPattern=function(i){for(var o=this,a=this.characterMap[i].toString(),s,l=0;l0&&(a.width=o.width),o.height>0&&(a.height=o.height),this.options.width&&(a.width=this.options.width),this.options.height&&(a.height=this.options.height),a},r.prototype.value=function(i){if(!ne(i))return this.options.value;this.options.value=String(i),this.redraw()},r.prototype._getBands=function(i,o){for(var a=this,s=this.contentBox,l=s.x1,h,p,f=new H1,g=0;g=i.matrix.length)&&(i.dir=-i.dir,i.startColumn-=i.startColumn!==8?2:3,i.column=i.startColumn,i.row=i.dir<0?i.matrix.length-1:0);return{row:this.row,column:this.column}},r.prototype.getNextRemainderCell=function(){if(this.move(),this.matrix[this.row][this.column]===void 0)return{row:this.row,column:this.column}},r}(Ve),hR=function(t){function r(n,i){t.call(this),this.dataString=n,this.version=i}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r}(Ve),LIt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.getEncodingResult=function(i,o){var a=pHt(i),s=dHt(a),l=pR(s,o),h=fHt(a,l);return new hR(h,l)},r}(Ve),Zw=function(t){function r(){t.call(this),this.initProperties()}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.initProperties=function(){c6(this,{modeIndicator:"",bitsInCharacterCount:[]})},r.prototype.getVersionIndex=function(i){return i<10?0:i>26?2:1},r.prototype.getBitsCharacterCount=function(i){return this.bitsInCharacterCount[this.getVersionIndex(i||40)]},r.prototype.getModeCountString=function(i,o){return this.modeIndicator+Fn(i,this.getBitsCharacterCount(o))},r.prototype.encode=function(){},r.prototype.getStringBitsLength=function(){},r.prototype.getValue=function(){},r}(Ve),EIt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.initProperties=function(){t.prototype.initProperties.call(this),c6(this,{bitsInCharacterCount:[10,12,14],modeIndicator:"0001"})},r.prototype.getValue=function(i){return parseInt(i,10)},r.prototype.encode=function(i,o){var a=this,s=cR(i,3),l=a.getModeCountString(i.length,o),h;for(h=0;h>h*6&63|128,8)+s;s=(i>>a*6|255>>l<0;){for(var l=0;l255&&(t=t^285),Vs[r]=t,Jw[t]=r;t=Vs[r-1]*2^285,Vs[r]=t,Vs[-1]=0}function aHt(t,r){for(var n=[],i=t.length-2,o=i;o>=0;o--)n[o]=t[o]^r[o];return n}function sHt(t,r){for(var n=[],i=0;i=0?r[o]:0))%255:n[i+o]=Jw[Vs[n[i+o]]^Vs[(t[i]+r[o])%255]];return n}function lHt(){for(var t=68,r=2;r<=t;r++){var n=Vm[r-1],i=[r,0];Vm[r]=sHt(n,i)}}oHt();lHt();function cHt(t,r){var n=[],i=t.length-1;do n[i]=Vs[(t[i]+r)%255],i--;while(t[i]!==void 0);return n}function hHt(t,r){var n=Vm[r-1],i=new Array(r).concat(t),o=new Array(i.length-n.length).concat(n),a=t.length,s=[],l,h;for(h=0;h=0;h--)s[r-1-h]=Fn(i[h],8);return s}function uHt(t,r){for(var n=0,i=[],o=[],a,s=r.groups,l,h,p,f,g=0;g=r||t.length===s.length||s.length>=n&&!ZA.test(t.charAt(s.length)))?(g=RIt,b=s):f&&(t.length===f.length||f.length>=i||o===qA)?(g=qA,b=s||h):(g=OIt,f?b=f+JA.exec(t.substring(f.length))[0]:b=JA.exec(t)[0]),{mode:g,modeString:b}}function pHt(t){var r=[],n,i=0,o=t;for(r.push(tL(o,ZIt,JIt,QIt,n)),n=r[0].mode,o=o.substr(r[0].modeString.length);o.length>0;){var a=tL(o,tHt,eHt,rHt,n);a.mode!==n?(n=a.mode,r.push(a),i++):r[i].modeString+=a.modeString,o=o.substr(a.modeString.length)}return r}function dHt(t){for(var r=0,n,i=0;i1);return t<=cc[n][r].totalDataCodewords?o+1:i+1}function fHt(t,r){for(var n="",i,o=0;o=n);return o}function hc(t,r){return parseInt(t.charAt(r),10)}function mHt(t){for(var r=[],n=17+4*t,i=0;i=0;o--)o!==6&&dn(t,hc(r,s-1-a++),i,o);for(a=0,o=n.length-1,i=8;o>=n.length-8;o--)dn(t,hc(r,s-1-a++),i,o);for(dn(t,1,n.length-8,8),i=n.length-7,o=8;i=0&&o=0&&s[g+1][b]===n[z][h]&&s[g+1][b-1]===n[z][h]&&(r[z]+=3),iL(z,o,r,h,s[g][b]),iL(z,o,r,p,s[b][g]),nL(z,r,n,s[g][b],a,h),nL(z,r,n,s[b][g],a,p);var M=f*f,I,F=Number.MAX_VALUE;for(l=0;l=5&&(r[t]+=3+o[t][a]-5),o[t][a]=1)}function SHt(t,r){var n=Math.floor(t/r*100),i=n%5,o=Math.abs(n-i-50),a=Math.abs(n+5-i-50),s=10*Math.min(o/5,a/5);return s}function zHt(t){return t&&t.toLowerCase().indexOf("utf_8")>=0?new FIt:new LIt}function MHt(t,r,n){var i=zHt(n),o=i.getEncodingResult(t,r),a=o.version,s=cc[a-1][r],l=nHt(o.dataString,s.totalDataCodewords),h=uHt(l,s),p=mHt(a);xHt(p),bHt(p,a),wHt(p),a>=7&&rL(p,Fn(0,18)),eL(p,Fn(0,15)),iHt(p,h);var f=CHt(p),g=p[f];a>=7&&rL([g],yHt(a));var b=$It[r]+Fn(f,3);return eL([g],vHt(b)),g}var j6=Math.round,kHt=[[0,1],[1,1],[1,2],[2,2],[2,1],[3,1],[3,0],[2,0],[2,-1],[1,-1],[1,0]],oL=[[0,1],[1,1],[1,0]],La={DEFAULT_SIZE:200,QUIET_ZONE_LENGTH:4,DEFAULT_ERROR_CORRECTION_LEVEL:"L",DEFAULT_BACKGROUND:"#fff",DEFAULT_DARK_MODULE_COLOR:"#000",MIN_BASE_UNIT_SIZE:1,DEFAULT_LOGO_SIZE:7},_Ht=function(t){function r(n,i,o){o===void 0&&(o=pV),t.call(this),this.options=zt({},this.options,i),this.element=n,this.wrapper=this.element,this.onError=o,this._initElement(),this._initSurface(),this.setOptions(i)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.destroy=function(){this._destroySurface()},r.prototype._initElement=function(){Ir(this.element,"k-qrcode")},r.prototype._initSurface=function(){var i=this,o=i.options,a=i.surface;(!a||a.options.type!==o.renderAs)&&(this._destroySurface(),this._initSurfaceElement(),this.surface=this._createSurface())},r.prototype._createSurface=function(){return Gl.create(this.surfaceElement,{type:this.options.renderAs})},r.prototype._destroySurface=function(){this.surface&&(this.surface.destroy(),this.surface=null,this._destroySurfaceElement())},r.prototype._initSurfaceElement=function(){this.surfaceElement||(this.surfaceElement=document.createElement("div"),this.surfaceElement.style.position="relative",this.element.appendChild(this.surfaceElement))},r.prototype._destroySurfaceElement=function(){this.surfaceElement&&this.surfaceElement.parentNode&&(this.surfaceElement.parentNode.removeChild(this.surfaceElement),this.surfaceElement=null)},r.prototype.redraw=function(){var i=this._getSize();this.surface.clear(),this.surface.setSize({width:i,height:i}),this.createVisual(),this.surface.draw(this.visual)},r.prototype.getSize=function(){var i=this.element,o=i.clientWidth,a=i.clientHeight,s={width:0,height:0};return o>0&&(s.width=o),a&&(s.height=a),s},r.prototype._resize=function(){this.redraw()},r.prototype.createVisual=function(){this.visual=this._render()},r.prototype.exportVisual=function(){return this._render()},r.prototype._render=function(){var i=this._value,o,a=this.options.border||{},s=this.options.padding||0,l=a.width||0,h,p,f,g,b;a.width=l;var z=new H1;try{i&&(p=MHt(i,this.options.errorCorrection,this.options.encoding),f=this._getSize(),b=f-2*(l+s),o=this._calculateBaseUnit(b,p.length),g=p.length*o,h=l+s+(b-g)/2,z.append(this._renderBackground(f,a)),z.append(this._renderMatrix(p,o,h)),this._hasCustomLogo()?z.append(this._renderLogo(f,o)):this._isSwiss()&&z.append(this._renderSwissCode(f,o)))}catch(M){this.onError(M)}return z},r.prototype._renderLogo=function(i,o){var a,s,l=j6(i/2),h=this._getLogoSize(o*La.DEFAULT_LOGO_SIZE),p=this.options.overlay.imageUrl,f={x:l-h.width/2,y:l-h.height/2};return s=new k1(new ye(f.x,f.y),new h0(h.width,h.height)),a=new rMt(p,s),a},r.prototype._renderSwissCode=function(i,o){var a=this._getLogoSize(o*La.DEFAULT_LOGO_SIZE);a=Math.max(a.width,a.height);var s=a/4,l=s/2,h=i/2,p={},f=new H1;return p.x=p.y=Math.ceil(h-o-a/2),f.append(this._renderShape(p,Math.ceil(a+o*2),oL,"#fff")),p.x=p.y=h-a/2,f.append(this._renderShape(p,a,oL,this.options.color)),p.x=h+l-a/2,p.y=h+l+s-a/2,f.append(this._renderShape(p,s,kHt,"#fff")),f},r.prototype._renderShape=function(i,o,a,s){var l=new Xo({fill:{color:s},stroke:null});l.moveTo(i.x,i.y);for(var h=0;h0?i=s:i=La.DEFAULT_SIZE}return i},r.prototype._calculateBaseUnit=function(i,o){var a=Math.floor(i/o);if(a=i&&a-1>=La.MIN_BASE_UNIT_SIZE&&a--;return a},r.prototype._renderMatrix=function(i,o,a){for(var s=new Xo({fill:{color:this.options.color},stroke:null}),l=0;l0;){G=ba(E),Z=_s(E),K=d4.sqrt(Po(H*G)+Po(M*F-z*H*Z)),at=z*F+M*H*Z,ft=Yh(K,at);var dt=M*H*G/K;et=1-Po(dt),tt=0,et!==0&&(tt=at-2*z*F/et),R=E;var ht=f/16*et*(4+f*(4-3*et));E=g+(1-ht)*f*dt*(ft+ht*K*(tt+ht*at*(-1+2*Po(tt)))),$=LHt(E-R)<=a.DISTANCE_CONVERGENCE}var lt=et*(Po(h)-Po(p))/Po(p),yt=1+lt/16384*(4096+lt*(-768+lt*(320-175*lt))),mt=lt/1024*(256+lt*(-128+lt*(74-47*lt))),gt=mt*K*(tt+mt/4*(at*(-1+2*Po(tt))-mt/6*tt*(-3+4*Po(K))*(-3+4*Po(tt)))),_t=Yh(H*G,M*F-z*H*Z),At=Yh(M*G,-z*H+M*F*Z);return{distance:Ee(p*yt*(ft-gt),this.DISTANCE_PRECISION),azimuthFrom:Ns(_t),azimuthTo:Ns(At)}},r.prototype.toString=function(){return String(this.lat)+","+String(this.lng)},r.fromLngLat=function(i){return new r(i[1],i[0])},r.fromLatLng=function(i){return new r(i[0],i[1])},r.create=function(i,o){if(ne(i))return i instanceof r?i.clone():arguments.length===1&&i.length===2?r.fromLatLng(i):new r(i,o)},r}(Ve),_4=Math,Rm=_4.atan,fR=_4.exp,lL=_4.pow,cL=_4.sin,vR=_4.log,gR=_4.tan,mR=ye,Kp=_4.PI,Om=Kp/2,yR=Kp/4,EHt=Kp/180,IHt=Fm.WGS84,Qw=function(t){function r(n){t.call(this),this.initProperties(),this._initOptions(n)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype._initOptions=function(i){this.options=zt({},this.options,i)},r.prototype.initProperties=function(){zt(this,{MAX_LNG:180,MAX_LAT:85.0840590501,INVERSE_ITERATIONS:15,INVERSE_CONVERGENCE:1e-12})},r.prototype.forward=function(i,o){var a=this,s=a.options,l=s.datum,h=l.a,p=s.centralMeridian,f=Xe(i.lat,-a.MAX_LAT,a.MAX_LAT),g=o?Xe(i.lng,-a.MAX_LNG,a.MAX_LNG):i.lng,b=qr(g-p)*h,z=a._projectLat(f);return new mR(b,z)},r.prototype._projectLat=function(i){var o=this.options.datum,a=o.e,s=o.a,l=qr(i),h=gR(yR+l/2),p=a*cL(l),f=lL((1-p)/(1+p),a/2);return s*vR(h*f)},r.prototype.inverse=function(i,o){var a=this,s=a.options,l=s.datum,h=l.a,p=s.centralMeridian,f=i.x/(EHt*h)+p,g=Xe(a._inverseY(i.y),-a.MAX_LAT,a.MAX_LAT);return o&&(f=Xe(f,-a.MAX_LNG,a.MAX_LNG)),new ii(g,f)},r.prototype._inverseY=function(i){var o=this,a=o.options.datum,s=a.a,l=a.e,h=l/2,p=fR(-i/s),f=Om-2*Rm(p),g;for(g=0;g<=o.INVERSE_ITERATIONS;g++){var b=l*cL(f),z=lL((1-b)/(1+b),h),M=Om-2*Rm(p*z)-f;if(f+=M,_4.abs(M)<=o.INVERSE_CONVERGENCE)break}return Ns(f)},r}(Ve);ve(Qw,{centralMeridian:0,datum:IHt});var HHt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.initProperties=function(){t.prototype.initProperties.call(this),zt(this,{MAX_LAT:85.0511287798})},r.prototype._projectLat=function(i){var o=this.options.datum.a,a=qr(i),s=gR(yR+a/2);return o*vR(s)},r.prototype._inverseY=function(i){var o=this.options.datum.a,a=fR(-i/o);return Ns(Om-2*Rm(a))},r}(Qw),DHt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.forward=function(i){return new mR(i.lng,i.lat)},r.prototype.inverse=function(i){return new ii(i.y,i.x)},r}(Ve),PHt=function(t){function r(){t.call(this);var n=this,i=n._proj=new HHt,o=this.c=2*Kp*i.options.datum.a;this._tm=nr().translate(.5,.5).scale(1/o,-1/o),this._itm=nr().scale(o,-o).translate(-.5,-.5)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.toPoint=function(i,o,a){var s=this._proj.forward(i,a);return s.transform(this._tm).scale(o||1)},r.prototype.toLocation=function(i,o,a){var s=i.clone().scale(1/(o||1)).transform(this._itm);return this._proj.inverse(s,a)},r}(Ve);(function(t){function r(){t.call(this),this._proj=new Qw}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.toPoint=function(i){return this._proj.forward(i)},r.prototype.toLocation=function(i){return this._proj.inverse(i)},r})(Ve);(function(t){function r(){t.call(this),this._proj=new DHt}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.toPoint=function(i){return this._proj.forward(i)},r.prototype.toLocation=function(i){return this._proj.inverse(i)},r})(Ve);var $r=function(t,r){return t.bind(r)},E0=function(t){var r=document.createElement("div");return r.innerHTML=t,r.firstChild},THt=function(t,r){var n=document.createElement("div");for(n.innerHTML=t;n.childNodes.length>0;)r.appendChild(n.childNodes[0])},y8=function(t){for(;t.firstChild;)t.removeChild(t.firstChild)},hL=function(t,r){r.insertBefore(t,r.firstChild)},VHt=function(t,r){for(t.appendChild(r);t.firstChild!==r;)r.appendChild(t.firstChild)},xR=function(t){var r=t.replace(/([a-z][A-Z])/g,function(n){return n.charAt(0)+"-"+n.charAt(1).toLowerCase()});return r},uL=function(t){var r;return t&&String(t).endsWith("px")?r=t:r=String(t)+"px",r},FHt=function(t){var r=$8(),n=r.mobileOS;return n.ios||n.android},qp=function(t,r){var n=t.prototype;n.events?r.forEach(function(i){n.events.indexOf(i)<0&&n.events.push(i)}):n.events=r},RHt=function(t){var r=t.wheelDeltaY,n;return t.wheelDelta?(r===void 0||r)&&(n=t.wheelDelta):t.detail&&t.axis===t.VERTICAL_AXIS&&(n=-t.detail*10),n},pL=function(t){var r=[];if(t)for(var n=xR(t).split("-"),i=0;i0){y8(this.element);var h=o.join(this.options.separator);THt(h,this.element),this.showElement()}else this.hideElement()},r.prototype.hideElement=function(){this.element.style.display="none"},r.prototype.showElement=function(){this.element.style.display=""},r.prototype._itemText=function(i){var o="",a=this._inZoomLevel(i.minZoom,i.maxZoom),s=this._inArea(i.extent);return a&&s&&(o+=i.text),o},r.prototype._inZoomLevel=function(i,o){var a=!0,s=t1(i,-Number.MAX_VALUE),l=t1(o,Number.MAX_VALUE);return a=this._zoom>s&&this._zoom'+U3({icon:"caret-alt-"+t,iconClass:"k-button-icon",svgIcons:r.svgIcons,type:r.type})+"";return E0(n)}var tC=function(t){function r(n,i){t.call(this),this.element=n,this._initOptions(i);var o=Xh("up",i.icons),a=Xh("right",i.icons),s=Xh("down",i.icons),l=Xh("left",i.icons);this.element.appendChild(o),this.element.appendChild(a),this.element.appendChild(s),this.element.appendChild(l),Ir(this.element,"k-widget k-navigator"),En(this.element,"click",".k-button",$r(this._click,this));var h=this.element.parentNode.closest("[data-role]");this._keyroot=h||this.element,this._tabindex(this._keyroot),this._keydownHandler=$r(this._keydown,this),En(this._keyroot,"keydown",this._keydownHandler)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.destroy=function(){this.dispose()},r.prototype.dispose=function(){Jn(this._keyroot,"keydown",this._keydownHandler)},r.prototype._tabindex=function(i){var o=i||this.wrapper||this.element,a=this.element,s="tabindex",l=o.getAttribute(s)||a.getAttribute(s);a.removeAttribute(s),o.setAttribute(s,isNaN(l)?0:l)},r.prototype._initOptions=function(i){this.options=zt({},this.options,i)},r.prototype._pan=function(i,o){var a=this.options.panStep;this.trigger(wR,{x:i*a,y:o*a})},r.prototype._click=function(i){var o=0,a=0,s=i.currentTarget;s.matches(".k-navigator-n")?a=1:s.matches(".k-navigator-s")?a=-1:s.matches(".k-navigator-e")?o=1:s.matches(".k-navigator-w")&&(o=-1),this._pan(o,a),i.preventDefault()},r.prototype._keydown=function(i){switch(i.which){case Y3.UP:this._pan(0,1),i.preventDefault();break;case Y3.DOWN:this._pan(0,-1),i.preventDefault();break;case Y3.RIGHT:this._pan(1,0),i.preventDefault();break;case Y3.LEFT:this._pan(-1,0),i.preventDefault();break}},r}(U2);ve(tC,{name:"Navigator",panStep:1});qp(tC,[wR]);function dL(t,r,n){var i='";return E0(i)}var BHt=187,NHt=189,$Ht=61,WHt=173,CR="change",eC=function(t){function r(n,i,o){t.call(this),this.element=n,this._initOptions(i);var a=dL("in","plus",o),s=dL("out","minus",o);this.element.appendChild(a),this.element.appendChild(s),this.element.setAttribute("role","group"),Ir(this.element,"k-widget k-zoom-control k-button-group k-group-horizontal"),this._clickHandler=this._click.bind(this),En(this.element,"click",".k-button",this._clickHandler);var l=this.element.parentNode.closest("[data-role]");this._keyroot=l||this.element,this._tabindex(this._keyroot),this._keydownHandler=this._keydown.bind(this),En(this._keyroot,"keydown",this._keydownHandler)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.destroy=function(){this.element&&Jn(this.element,"click",this._clickHandler),this._keyroot&&Jn(this._keyroot,"keydown",this._keydownHandler)},r.prototype._tabindex=function(i){var o=i||this.wrapper||this.element,a=this.element,s="tabindex",l=o.getAttribute(s)||a.getAttribute(s);a.removeAttribute(s),o.setAttribute(s,isNaN(l)?0:l)},r.prototype._initOptions=function(i){this.options=zt({},this.options,i)},r.prototype._change=function(i){var o=this.options.zoomStep;this.trigger(CR,{delta:i*o})},r.prototype._click=function(i){var o=i.currentTarget,a=1;Zu(o,"k-zoom-out")&&(a=-1),this._change(a),i.preventDefault()},r.prototype._keydown=function(i){switch(i.which){case Y3.NUMPAD_PLUS:case BHt:case $Ht:this._change(1);break;case Y3.NUMPAD_MINUS:case NHt:case WHt:this._change(-1);break}},r}(U2);ve(eC,{name:"ZoomControl",zoomStep:1});qp(eC,[CR]);var SR=Math,fL=SR.max,vL=SR.min,E7=function(t){function r(i,o){t.call(this);var a=ii.create(i),s=ii.create(o);a.lng+180>s.lng+180&&a.lat+90=a.lng+180&&l+180<=s.lng+180&&h+90>=s.lat+90&&h+90<=a.lat+90},r.prototype.center=function(){var o=this.nw,a=this.se,s=o.lng+(a.lng-o.lng)/2,l=o.lat+(a.lat-o.lat)/2;return new ii(l,s)},r.prototype.containsAny=function(o){for(var a=this,s=!1,l=0;l=i.minZoom,s=!ne(i.maxZoom)||o<=i.maxZoom,l=E7.create(i.extent),h=!l||l.overlaps(this.map.extent());this._setVisibility(a&&s&&h)},r.prototype._setVisibility=function(i){this.element.style.display=i?"":"none"},r.prototype._activate=function(){var i=this.map;this._deactivate(),i.bind("beforeReset",this._beforeReset),i.bind("reset",this._reset),i.bind("resize",this._resize),i.bind("panEnd",this._panEnd)},r.prototype._deactivate=function(){var i=this.map;i.unbind("beforeReset",this._beforeReset),i.unbind("reset",this._reset),i.unbind("resize",this._resize),i.unbind("panEnd",this._panEnd)},r.prototype._updateAttribution=function(){var i=this.map.attribution;i&&i.add(this.options.attribution)},r.prototype._readData=function(){var i=this.options.data||[];return i},r.prototype._hasData=function(){return this._data&&this._data.length>0},r.prototype._layerIndex=function(){var i=this.map.layers||[];return i.indexOf(this)},r}(Ve),As=Math,Bm=ye;function mL(t){return mr(t)?t:Ul.compile(t)}function XHt(t){return new Bm(Ee(t.x),Ee(t.y))}function yL(t){var r=t;return typeof t!="string"&&(r+="px"),r}var MR=function(t){function r(n,i){t.call(this,n,i),typeof this.options.subdomains=="string"&&(this.options.subdomains=this.options.subdomains.split(""));var o=this._viewType();this._view=new o(this.element,this.options)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.destroy=function(){t.prototype.destroy.call(this),this._view.destroy(),this._view=null},r.prototype._beforeReset=function(){var i=this.map,o=i.locationToLayer(i.extent().nw).round();this._view.viewOrigin(o)},r.prototype._reset=function(){t.prototype._reset.call(this),this._updateView(),this._view.reset()},r.prototype._viewType=function(){return KHt},r.prototype._activate=function(){t.prototype._activate.call(this),this.support.mobileOS||(this._pan||(this._pan=vp(this._render.bind(this),100)),this.map.bind("pan",this._pan))},r.prototype._deactivate=function(){t.prototype._deactivate.call(this),this._pan&&this.map.unbind("pan",this._pan)},r.prototype._updateView=function(){var i=this._view,o=this.map,a=o.extent(),s={nw:o.locationToLayer(a.nw).round(),se:o.locationToLayer(a.se).round()};i.center(o.locationToLayer(o.center())),i.extent(s),i.zoom(o.zoom())},r.prototype._resize=function(){this._render()},r.prototype._panEnd=function(i){t.prototype._panEnd.call(this,i),this._render()},r.prototype._render=function(){this._updateView(),this._view.render()},r}(rC);ve(MR,{tileSize:256,subdomains:["a","b","c"],urlTemplate:"",zIndex:1});var KHt=function(t){function r(n,i){t.call(this),this.element=n,this._initOptions(i),this.pool=new _R}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype._initOptions=function(i){this.options=zt({},this.options,i)},r.prototype.center=function(i){this._center=i},r.prototype.extent=function(i){this._extent=i},r.prototype.viewOrigin=function(i){this._viewOrigin=i},r.prototype.zoom=function(i){this._zoom=i},r.prototype.pointToTileIndex=function(i){return new Bm(As.floor(i.x/this.options.tileSize),As.floor(i.y/this.options.tileSize))},r.prototype.tileCount=function(){var i=this.size(),o=this.pointToTileIndex(this._extent.nw),a=this._extent.nw,s=this.indexToPoint(o).translate(-a.x,-a.y);return{x:As.ceil((As.abs(s.x)+i.width)/this.options.tileSize),y:As.ceil((As.abs(s.y)+i.height)/this.options.tileSize)}},r.prototype.size=function(){var i=this._extent.nw,o=this._extent.se,a=o.clone().translate(-i.x,-i.y);return{width:a.x,height:a.y}},r.prototype.indexToPoint=function(i){var o=i.x,a=i.y;return new Bm(o*this.options.tileSize,a*this.options.tileSize)},r.prototype.subdomainText=function(){var i=this.options.subdomains;return i[this.subdomainIndex++%i.length]},r.prototype.destroy=function(){y8(this.element),this.pool.empty()},r.prototype.reset=function(){this.pool.reset(),this.subdomainIndex=0,this.render()},r.prototype.render=function(){var i=this,o=this.tileCount(),a=this.pointToTileIndex(this._extent.nw),s,l,h;for(l=0;l=0?s=a:s=o-(a===0?o:a),s},r}(Ve),kR=function(t){function r(n,i){t.call(this),this.id=n,this.visible=!0,this._initOptions(i),this.createElement(),this.show()}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.destroy=function(){var i=this.element,o=i?i.parentNode:null;i&&(o&&o.removeChild(i),this.element=null)},r.prototype._initOptions=function(i){this.options=zt({},this.options,i)},r.prototype.createElement=function(){var i=document.createElement("img"),o=this.options.size+"px";i.setAttribute("alt",""),i.style.position="absolute",i.style.display="block",i.style.width=i.style.maxWidth=o,i.style.height=i.style.maxHeight=o,this.element=i},r.prototype.show=function(){var i=this.element;i.style.top=yL(this.options.offset.y),i.style.left=yL(this.options.offset.x);var o=this.url();o&&i.setAttribute("src",o),i.style.visibility="visible",this.visible=!0},r.prototype.hide=function(){this.element.style.visibility="hidden",this.visible=!1},r.prototype.url=function(){var i=mL(this.options.urlTemplate);return i(this.urlOptions())},r.prototype.errorUrl=function(){var i=mL(this.options.errorUrlTemplate);return i(this.urlOptions())},r.prototype.urlOptions=function(){var i=this.options;return{zoom:i.zoom,subdomain:i.subdomain,z:i.zoom,x:i.index.x,y:i.index.y,s:i.subdomain,quadkey:i.quadkey,q:i.quadkey,culture:i.culture,c:i.culture}},r}(Ve);ve(kR,{urlTemplate:"",errorUrlTemplate:""});var _R=function(t){function r(){t.call(this),this._items=[]}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.get=function(i,o){return this._items.length>=this.options.maxSize&&this._remove(i),this._create(o)},r.prototype.empty=function(){for(var i=this._items,o=0;oa&&!o[l].visible&&(s=l,a=h)}s!==-1&&(o[s].destroy(),o.splice(s,1))},r}(Ve);ve(_R,{maxSize:100});var I0=Object.assign,x8="change",qHt=function(t){function r(n,i){t.call(this);var o=this,a=n[0]||n;o.capture=!1,a.addEventListener?(X3.down.split(" ").forEach(function(s){a.addEventListener(s,$r(o._press,o),!0)}),X3.up.split(" ").forEach(function(s){a.addEventListener(s,$r(o._release,o),!0)})):(X3.down.split(" ").forEach(function(s){a.attachEvent(s,$r(o._press,o))}),X3.up.split(" ").forEach(function(s){a.attachEvent(s,$r(o._release,o))})),o.bind(["press","release"],i||{})}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.captureNext=function(){this.capture=!0},r.prototype.cancelCapture=function(){this.capture=!1},r.prototype._press=function(i){var o=this;o.trigger("press"),o.capture&&i.preventDefault()},r.prototype._release=function(i){var o=this;o.trigger("release"),o.capture&&(i.preventDefault(),o.cancelCapture())},r}(U2),xL=function(t){function r(n){t.call(this);var i=this;i.forcedEnabled=!1,I0(i,n),i.scale=1,i.horizontal?(i.measure="offsetWidth",i.scrollSize="scrollWidth",i.axis="x"):(i.measure="offsetHeight",i.scrollSize="scrollHeight",i.axis="y")}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.makeVirtual=function(){I0(this,{virtual:!0,forcedEnabled:!0,_virtualMin:0,_virtualMax:0})},r.prototype.virtualSize=function(i,o){(this._virtualMin!==i||this._virtualMax!==o)&&(this._virtualMin=i,this._virtualMax=o,this.update())},r.prototype.outOfBounds=function(i){return i>this.max||il,i||o.trigger(x8,o))},r}(U2),ZHt=function(t){function r(n){t.call(this);var i=this;i.x=new xL(I0({horizontal:!0},n)),i.y=new xL(I0({horizontal:!1},n)),i.container=n.container,i.forcedMinScale=n.minScale,i.maxScale=n.maxScale||100,i.bind(x8,n)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.rescale=function(i){this.x.rescale(i),this.y.rescale(i),this.refresh()},r.prototype.centerCoordinates=function(){return{x:Math.min(0,-this.x.centerOffset),y:Math.min(0,-this.y.centerOffset)}},r.prototype.refresh=function(){var i=this;i.x.update(),i.y.update(),i.enabled=i.x.enabled||i.y.enabled,i.minScale=i.forcedMinScale||Math.min(i.x.minScale,i.y.minScale),i.fitScale=Math.max(i.x.minScale,i.y.minScale),i.trigger(x8)},r}(U2),bL=function(t){function r(n){t.call(this),I0(this,n)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.outOfBounds=function(){return this.dimension.outOfBounds(this.movable[this.axis])},r.prototype.dragMove=function(i){var o=this,a=o.dimension,s=o.axis,l=o.movable,h=l[s]+i;if(a.enabled){var p=i;(ha.max&&i>0)&&(p*=o.resistance),l.translateAxis(s,p),o.trigger(x8,o)}},r}(U2),JHt=function(t){function r(n){t.call(this);var i=this,o,a,s,l;I0(i,{elastic:!0},n),s=i.elastic?.5:0,l=i.movable,i.x=o=new bL({axis:"x",dimension:i.dimensions.x,resistance:s,movable:l}),i.y=a=new bL({axis:"y",dimension:i.dimensions.y,resistance:s,movable:l}),i.userEvents.bind(["press","move","end","gesturestart","gesturechange"],{gesturestart:function(p){i.gesture=p,i.offset=wl(i.dimensions.container)},press:function(p){var f=p.event.target.closest("a");f&&f.matches("[data-navigate-on-press=true]")&&p.sender.cancel()},gesturechange:function(p){var f=i.gesture,g=f.center,b=p.center,z=p.distance/f.distance,M=i.dimensions.minScale,I=i.dimensions.maxScale,F;l.scale<=M&&z<1&&(z+=(1-z)*.8),l.scale*z>=I&&(z=I/l.scale);var H=l.x+i.offset.left,E=l.y+i.offset.top;F={x:(H-g.x)*z+b.x-H,y:(E-g.y)*z+b.y-E},l.scaleWith(z),o.dragMove(F.x),a.dragMove(F.y),i.dimensions.rescale(l.scale),i.gesture=p,p.preventDefault()},move:function(p){p.event.target.tagName.match(/textarea|input/i)||(o.dimension.enabled||a.dimension.enabled?(o.dragMove(p.x.delta),a.dragMove(p.y.delta),p.preventDefault()):p.touch.skip())},end:function(p){p.preventDefault()}})}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r}(Ve),wL=function(t,r,n){return"translate3d("+t+"px,"+r+"px,0) scale("+n+")"},iC=function(t){function r(n){t.call(this);var i=this;i.element=n,i.element.style.transformOrigin="left top",i.x=0,i.y=0,i.scale=1;var o=wL(i.x,i.y,i.scale);i.element.style.transform=o,i._saveCoordinates(o)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.translateAxis=function(i,o){this[i]+=o,this.refresh()},r.prototype.scaleTo=function(i){this.scale=i,this.refresh()},r.prototype.scaleWith=function(i){this.scale*=i,this.refresh()},r.prototype.translate=function(i){this.x+=i.x,this.y+=i.y,this.refresh()},r.prototype.moveAxis=function(i,o){this[i]=o,this.refresh()},r.prototype.moveTo=function(i){I0(this,i),this.refresh()},r.prototype.refresh=function(){var i=this,o=i.x,a=i.y,s;i.round&&(o=Math.round(o),a=Math.round(a)),s=wL(o,a,i.scale),s!==i.coordinates&&(i.element.style.transform=s,i._saveCoordinates(s),i.trigger(x8))},r.prototype._saveCoordinates=function(i){this.coordinates=i},r}(U2),Nm=H1,nC=function(t){function r(n,i){t.call(this,n,i),this._pan=$r(this._pan,this),this.surface=Gl.create(this.element,{width:n.scrollElement.clientWidth,height:n.scrollElement.clientHeight}),this._initRoot(),this.movable=new iC(this.surface.element),this._markers=[],this._click=this._handler("shapeClick"),this.surface.bind("click",this._click),this._mouseleave=this._handler("shapeMouseLeave"),this.surface.bind("mouseleave",this._mouseleave),this.surface.bind("mouseenter",this._mouseenter.bind(this))}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.destroy=function(){t.prototype.destroy.call(this),this.surface.destroy()},r.prototype._reset=function(){t.prototype._reset.call(this),this._translateSurface(),this._data=this._readData(),this._hasData()&&this._load(this._data)},r.prototype._initRoot=function(){this._root=new Nm,this.surface.draw(this._root)},r.prototype._beforeReset=function(){this.surface.clear(),this._initRoot()},r.prototype._resize=function(){this.surface.size(this.map.size())},r.prototype._readData=function(){var i=t.prototype._readData.call(this);return i.type==="FeatureCollection"?i.features:i.type==="GeometryCollection"?i.geometries:i},r.prototype._load=function(i){var o=this;this._data=i,this._clearMarkers(),this._loader||(this._loader=new QHt(this.map,this.options.style,this));for(var a=new Nm,s=0;s1?Xo:$e,s=new a(this.style),l=0;l-1&&this.items.splice(o,1)},r.prototype.clear=function(){for(var i=this,o=0;o=this.duration},r.prototype.timePassed=function(){return Math.min(this.duration,l4()-this.startDate)},r.prototype.moveTo=function(i){var o=this,a=o.movable;o.initial=a[o.axis],o.delta=i.location-o.initial,o.duration=typeof i.duration=="number"?i.duration:300,o.tick=o._easeProxy(i.ease),o.startDate=l4(),o.start()},r.prototype._easeProxy=function(i){var o=this;return function(){o.movable.moveAxis(o.axis,i(o.timePassed(),o.initial,o.delta,o.duration))}},r.easeOutExpo=function(i,o,a,s){return i===s?o+a:a*(-Math.pow(2,-10*i/s)+1)+o},r}(Zp),Hl=Object.assign,i0=Math.abs,oDt=500,aDt=.7,sDt=.96,lDt=10,_v=55,cDt=.5,AL=5,hDt="pull",I7="change",uDt="resize",ER="scroll",pDt=2,dDt=function(t){function r(n){t.call(this,n);var i=this;Hl(i,n),i.userEvents.bind("gestureend",i.start.bind(this)),i.tapCapture.bind("press",i.cancel.bind(this))}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.enabled=function(){return this.movable.scaleo.max?o.max:o.min;i._moveTo(a)},r.prototype._moveTo=function(i){this.transition.moveTo({location:i,duration:oDt,ease:_L.easeOutExpo})},r}(Zp),vDt=function(t){function r(n){t.call(this,n);var i=this;Hl(i,n,{origin:{},destination:{},offset:{}})}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.tick=function(){this._updateCoordinates(),this.moveTo(this.origin)},r.prototype.done=function(){return i0(this.offset.y)');Hl(i,n,{element:s,elementSize:0,movable:new iC(s),scrollMovable:n.movable,alwaysVisible:n.alwaysVisible,size:o?"width":"height"}),i.scrollMovable.bind(I7,i.refresh.bind(i)),i.container.appendChild(s),n.alwaysVisible&&i.show()}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.refresh=function(){var i=this,o=i.axis,a=i.dimension,s=a.size,l=i.scrollMovable,h=s/a.total,p=Math.round(-l[o]*h),f=Math.round(s*h);h>=1?this.element.style.display="none":this.element.style.display="",p+f>s?f=s-p:p<0&&(f+=p,p=0),i.elementSize!==f&&(i.element.style[i.size]=f+"px",i.elementSize=f),i.movable.moveAxis(o,p)},r.prototype.show=function(){this.element.style.opacity=aDt,this.element.style.visibility="visible"},r.prototype.hide=function(){this.alwaysVisible||(this.element.style.opacity=0)},r}(Ve),aC=function(t){function r(n,i){t.call(this);var o=this;this.element=n,this._initOptions(i);var a=FHt();o._native=o.options.useNative&&a;var s=E0('
');if(o._native){Ir(n,"km-native-scroller"),hL(s,n),Hl(o,{scrollElement:n,fixedContainer:n.children[0]});return}n.style.overflow="hidden",Ir(n,"km-scroll-wrapper");var l=E0('
');VHt(n,l),hL(s,n);var h=n.children[1],p=new qHt(n),f=new iC(h),g=new ZHt({element:h,container:n,forcedEnabled:o.options.zoom}),b=this.options.avoidScrolling,z=new e9(n,{touchAction:"none",allowSelection:!0,preventDragEvent:!0,captureUpIfMoved:!0,multiTouch:o.options.zoom,supportDoubleTap:o.options.supportDoubleTap,start:function(E){g.refresh();var R=i0(E.x.velocity),W=i0(E.y.velocity),$=R*2>=W,G=o.fixedContainer.contains(E.event.target),Z=W*2>=R;!G&&!b(E)&&o.enabled&&(g.x.enabled&&$||g.y.enabled&&Z)?z.capture():z.cancel()}}),M=new JHt({movable:f,dimensions:g,userEvents:z,elastic:o.options.elastic}),I=new dDt({movable:f,dimensions:g,userEvents:z,tapCapture:p}),F=new vDt({moveTo:function(E){o.scrollTo(E.x,E.y)}});f.bind(I7,function(){o.scrollTop=-f.y,o.scrollLeft=-f.x,o.trigger(ER,{scrollTop:o.scrollTop,scrollLeft:o.scrollLeft})}),o.options.mousewheelScrolling&&(this._wheelScrollHandler=this._wheelScroll.bind(this),En(n,"wheel",this._wheelScrollHandler)),Hl(o,{movable:f,dimensions:g,zoomSnapBack:I,animatedScroller:F,userEvents:z,pane:M,tapCapture:p,pulled:!1,enabled:!0,scrollElement:h,scrollTop:0,scrollLeft:0,fixedContainer:n.children[0]}),o._initAxis("x"),o._initAxis("y"),o._wheelEnd=function(){o._wheel=!1,o.userEvents.end(0,o._wheelY)},g.refresh(),o.options.pullToRefresh&&o._initPullToRefresh()}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype._initOptions=function(i){this.options=zt({},this.options,i)},r.prototype._wheelScroll=function(i){if(!i.ctrlKey){this._wheel||(this._wheel=!0,this._wheelY=0,this.userEvents.press(0,this._wheelY)),clearTimeout(this._wheelTimeout),this._wheelTimeout=setTimeout(this._wheelEnd,50);var o=RHt(i);o&&(this._wheelY+=o,this.userEvents.move(0,this._wheelY)),i.preventDefault()}},r.prototype.makeVirtual=function(){this.dimensions.y.makeVirtual()},r.prototype.virtualSize=function(i,o){this.dimensions.y.virtualSize(i,o)},r.prototype.height=function(){return this.dimensions.y.size},r.prototype.scrollHeight=function(){return this.scrollElement.scrollHeight},r.prototype.scrollWidth=function(){return this.scrollElement.scrollWidth},r.prototype._resize=function(){this._native||this.contentResized()},r.prototype.setOptions=function(i){var o=this;this._initOptions(i),i.pullToRefresh&&o._initPullToRefresh()},r.prototype.reset=function(){this._native?this.scrollElement.scrollTop(0):(this.movable.moveTo({x:0,y:0}),this._scale(1))},r.prototype.contentResized=function(){this.dimensions.refresh(),this.pane.x.outOfBounds()&&this.movable.moveAxis("x",this.dimensions.x.min),this.pane.y.outOfBounds()&&this.movable.moveAxis("y",this.dimensions.y.min)},r.prototype.zoomOut=function(){var i=this.dimensions;i.refresh(),this._scale(i.fitScale),this.movable.moveTo(i.centerCoordinates())},r.prototype.enable=function(){this.enabled=!0},r.prototype.disable=function(){this.enabled=!1},r.prototype.scrollTo=function(i,o){this._native?(this.scrollElement.scrollLeft(i0(i)),this.scrollElement.scrollTop(i0(o))):(this.dimensions.refresh(),this.movable.moveTo({x:i,y:o}))},r.prototype.animatedScrollTo=function(i,o,a){var s,l;this._native?this.scrollTo(i,o):(s={x:this.movable.x,y:this.movable.y},l={x:i,y:o},this.animatedScroller.setCoordinates(s,l),this.animatedScroller.setCallback(a),this.animatedScroller.start())},r.prototype.pullHandled=function(){},r.prototype.destroy=function(){var i=this.element;Jn(i,"wheel",this._wheelScrollHandler),this.userEvents&&this.userEvents.destroy()},r.prototype._scale=function(i){this.dimensions.rescale(i),this.movable.scaleTo(i)},r.prototype._initPullToRefresh=function(){},r.prototype._dragEnd=function(){},r.prototype._paneChange=function(){},r.prototype._initAxis=function(i){var o=this,a=o.movable,s=o.dimensions[i],l=o.tapCapture,h=o.pane[i],p=new gDt({axis:i,movable:a,dimension:s,container:o.element,alwaysVisible:o.options.visibleScrollHints});s.bind(I7,function(){p.refresh()}),h.bind(I7,function(){p.show()}),o[i+"inertia"]=new fDt({axis:i,paneAxis:h,movable:a,tapCapture:l,userEvents:o.userEvents,dimension:s,elastic:o.options.elastic,friction:o.options.friction||sDt,velocityMultiplier:o.options.velocityMultiplier||lDt,end:function(){p.hide(),o.trigger("scrollEnd",{axis:i,scrollTop:o.scrollTop,scrollLeft:o.scrollLeft})}})},r}(U2);ve(aC,{name:"Scroller",zoom:!1,pullOffset:140,visibleScrollHints:!1,elastic:!0,useNative:!1,mousewheelScrolling:!0,avoidScrolling:function(){return!1},pullToRefresh:!1,messages:{pullTemplate:"Pull to refresh",releaseTemplate:"Release to refresh",refreshTemplate:"Refreshing"}});qp(aC,[hDt,ER,uDt]);var IR=function(r,n){n===void 0&&(n={}),this.sender=n.sender||r,this.widget=r,this.rtl=!!n.rtl};IR.prototype.notify=function(r,n){this.widget&&this.widget.trigger(r,n)};var Hs=Math,LL=Hs.min,Av=Hs.pow,EL=ye,H7="marker",Kh="location",mDt=.9,yDt=.93,IL="wheel",xDt=50,bDt=5,wDt=1,HR={bubble:AR,shape:nC,tile:MR};HR[H7]=oC;var DR=function(t){function r(n,i,o,a){i===void 0&&(i={}),o===void 0&&(o={}),a===void 0&&(a={}),t.call(this),this._init(n,i,o,a)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.destroy=function(){var i=this;this.scroller.destroy(),this._tooltip&&this._tooltip.destroy(),this.navigator&&this.navigator.destroy(),this.attribution&&this.attribution.destroy(),this.zoomControl&&this.zoomControl.destroy(),zi(this.markers)?this.markers.forEach(function(a){a.destroy()}):this.markers.destroy();for(var o=0;o");this.element.appendChild(o)},r.prototype.initServices=function(i){i===void 0&&(i={}),this.widgetService=new IR(this,i)},r.prototype.initObserver=function(i){i===void 0&&(i={}),this.observers=[],this.addObserver(i.observer)},r.prototype.addObserver=function(i){i&&this.observers.push(i)},r.prototype.removeObserver=function(i){var o=this.observers.indexOf(i);o>=0&&this.observers.splice(o,1)},r.prototype.requiresHandlers=function(i){for(var o=this.observers,a=0;a0&&(s.lng=180+(180+s.lng));var l=new E7(a.nw,s);this.center(l.center());var h=this.element.clientWidth,p=this.element.clientHeight,f;for(f=this.options.maxZoom;f>=this.options.minZoom;f--){var g=o.locationToLayer(l.nw,f),b=o.locationToLayer(l.se,f),z=Hs.abs(b.x-g.x),M=Hs.abs(b.y-g.y);if(z<=h&&M<=p)break}this.zoom(f)},r.prototype._getExtent=function(){var i=this._getOrigin(),o=this.locationToLayer(i),a=this.viewSize();o.x+=a.width,o.y+=a.height;var s=this.layerToLocation(o);return new E7(i,s)},r.prototype._zoomAround=function(i,o){this._setOrigin(this.layerToLocation(i,o),o),this.zoom(o)},r.prototype._initControls=function(){var i=this.options.controls;i.attribution&&this._createAttribution(i.attribution),this.support.mobileOS||(i.navigator&&this._createNavigator(i.navigator),i.zoom&&this._createZoomControl(i.zoom))},r.prototype._createControlElement=function(i,o){var a=i.position||o,s="."+pL(a).replace(" ","."),l=this.element.querySelector(".k-map-controls"+s)||[];if(l.length===0){var h=document.createElement("div");Ir(h,"k-map-controls "+pL(a)),l=h,this.element.appendChild(l)}var p=document.createElement("div");return l.appendChild(p),p},r.prototype._createAttribution=function(i){var o=this._createControlElement(i,"bottomRight");this.attribution=new bR(o,i)},r.prototype._createNavigator=function(i){var o=this._createControlElement(i,"topLeft"),a=this.navigator=new tC(o,zt({},i,{icons:this.options.icons}));this._navigatorPan=this._navigatorPan.bind(this),a.bind("pan",this._navigatorPan),this._navigatorCenter=this._navigatorCenter.bind(this),a.bind("center",this._navigatorCenter)},r.prototype._navigatorPan=function(i){var o=this.scroller,a=o.scrollLeft+i.x,s=o.scrollTop-i.y,l=this._virtualSize,h=this.element.clientWidth,p=this.element.clientHeight;a=Xe(a,l.x.min,l.x.max-h),s=Xe(s,l.y.min,l.y.max-p),this.scroller.one("scroll",$r(this._scrollEnd,this)),this.scroller.scrollTo(-a,-s)},r.prototype._navigatorCenter=function(){this.center(this.options.center)},r.prototype._createZoomControl=function(i){var o=this._createControlElement(i,"topLeft"),a=this.zoomControl=new eC(o,i,this.options.icons);this._zoomControlChange=this._zoomControlChange.bind(this),a.bind("change",this._zoomControlChange)},r.prototype._zoomControlChange=function(i){this.trigger("zoomStart",{originalEvent:i})||(this.zoom(this.zoom()+i.delta),this.trigger("zoomEnd",{originalEvent:i}))},r.prototype._initScroller=function(){var i=this.support.mobileOS?yDt:mDt,o=this.options.zoomable!==!1,a=this.scroller=new aC(this.element.children[0],{friction:i,velocityMultiplier:bDt,zoom:o,mousewheelScrolling:!1,supportDoubleTap:!0});a.bind("scroll",$r(this._scroll,this)),a.bind("scrollEnd",$r(this._scrollEnd,this)),a.userEvents.bind("gesturestart",$r(this._scaleStart,this)),a.userEvents.bind("gestureend",$r(this._scale,this)),a.userEvents.bind("doubleTap",$r(this._doubleTap,this)),a.userEvents.bind("tap",$r(this._tap,this)),this.scrollElement=a.scrollElement},r.prototype._initLayers=function(){for(var i=this,o=this.options.layers,a=this.layers=[],s=0;s0||(this.markers=new oC(this,zt({},this.options.markerDefaults,{icons:this.options.icons})),this.markers.add(this.options.markers))},r.prototype._scroll=function(i){var o=this.locationToLayer(this._viewOrigin).round(),a=i.sender.movable,s=new ye(a.x,a.y).scale(-1).scale(1/a.scale);o.x+=s.x,o.y+=s.y,this._scrollOffset=s,this._tooltip.offset=s,this.hideTooltip(),this._setOrigin(this.layerToLocation(o)),this.trigger("pan",{originalEvent:i,origin:this._getOrigin(),center:this.center()})},r.prototype._scrollEnd=function(i){!this._scrollOffset||!this._panComplete()||(this._scrollOffset=null,this._panEndTimestamp=l4(),this.trigger("panEnd",{originalEvent:i,origin:this._getOrigin(),center:this.center()}))},r.prototype._panComplete=function(){return l4()-(this._panEndTimestamp||0)>50},r.prototype._scaleStart=function(i){if(this.trigger("zoomStart",{originalEvent:i})){var o=i.touches[1];o&&o.cancel()}},r.prototype._scale=function(i){var o=this.scroller.movable.scale,a=this._scaleToZoom(o),s=new ye(i.center.x,i.center.y),l=this.viewToLocation(s,a),h=this.locationToLayer(l,a),p=h.translate(-s.x,-s.y);this._zoomAround(p,a),this.trigger("zoomEnd",{originalEvent:i})},r.prototype._scaleToZoom=function(i){var o=this._layerSize()*i,a=o/this.options.minSize,s=Hs.log(a)/Hs.log(2);return Hs.round(s)},r.prototype._reset=function(){this.attribution&&this.attribution.filter(this.center(),this.zoom()),this._viewOrigin=this._getOrigin(!0),this._resetScroller(),this.hideTooltip(),this.trigger("beforeReset"),this.trigger("reset")},r.prototype._resetScroller=function(){var i=this.scroller,o=i.dimensions.x,a=i.dimensions.y,s=this._layerSize(),l=this.extent().nw,h=this.locationToLayer(l).round();i.movable.round=!0,i.reset(),i.userEvents.cancel();var p=this.zoom();i.dimensions.forcedMinScale=Av(2,this.options.minZoom-p),i.dimensions.maxScale=Av(2,this.options.maxZoom-p);var f={min:-h.x,max:s-h.x},g={min:-h.y,max:s-h.y};if(this.options.wraparound&&(f.max=20*s,f.min=-f.max),this.options.pannable===!1){var b=this.viewSize();f.min=g.min=0,f.max=b.width,g.max=b.height}o.makeVirtual(),a.makeVirtual(),o.virtualSize(f.min,f.max),a.virtualSize(g.min,g.max),this._virtualSize={x:f,y:g}},r.prototype._renderLayers=function(){},r.prototype._layerSize=function(i){var o=t1(i,this.options.zoom);return this.options.minSize*Av(2,o)},r.prototype._tap=function(i){if(this._panComplete()){var o=this.eventOffset(i);this.hideTooltip(),this.trigger("click",{originalEvent:i,location:this.viewToLocation(o)})}},r.prototype._doubleTap=function(i){var o=this.options;if(o.zoomable!==!1&&!this.trigger("zoomStart",{originalEvent:i})){var a=this.zoom()+wDt,s=this.eventOffset(i),l=this.viewToLocation(s),h=this.locationToLayer(l,a),p=h.translate(-s.x,-s.y);this._zoomAround(p,a),this.trigger("zoomEnd",{originalEvent:i})}},r.prototype._mousewheel=function(i){var o=jb(i)>0?-1:1,a=this.options,s=this.zoom(),l=Xe(s+o,a.minZoom,a.maxZoom);if(a.zoomable!==!1&&l!==s&&!this.trigger("zoomStart",{originalEvent:i})){var h=this.eventOffset(i),p=this.viewToLocation(h),f=this.locationToLayer(p,l),g=f.translate(-h.x,-h.y);this._zoomAround(g,l),this.trigger("zoomEnd",{originalEvent:i})}},r.prototype._toDocumentCoordinates=function(i){var o=wl(this.element);return{left:Ee(i.x+o.left),top:Ee(i.y+o.top)}},r}(U2);ve(DR,{name:"Map",controls:{attribution:!0,navigator:{panStep:100},zoom:!0},layers:[],layerDefaults:{shape:{style:{fill:{color:"#fff"},stroke:{color:"#aaa",width:.5}}},bubble:{style:{fill:{color:"#fff",opacity:.5},stroke:{color:"#aaa",width:.5}}},marker:{shape:"pinTarget",tooltip:{position:"top"}}},center:[0,0],icons:{type:"font",svgIcons:{}},zoom:3,minSize:256,minZoom:1,maxZoom:19,markers:[],markerDefaults:{shape:"pinTarget",tooltip:{position:"top"}},wraparound:!0,renderPointsAsMarkers:!1});qp(DR,["beforeReset","click","markerActivate","markerClick","markerCreated","markerMouseEnter","markerMouseLeave","pan","panEnd","reset","shapeClick","shapeCreated","shapeFeatureCreated","shapeMouseEnter","shapeMouseLeave","zoomEnd","zoomStart"]);var CDt=function(t,r){return Math.max.apply(null,t.map(r))},SDt=function(t,r){return Math.min.apply(null,t.map(r))},Wm=function(t,r){return t.map(r).reduce(function(n,i){return n+i},0)},Jp=function(t,r){return t.y0===r.y0?t.index-r.index:t.y0+t.y1-r.y0-r.y1},zDt=function(t,r){return Jp(t.source,r.source)},MDt=function(t,r){return Jp(t.target,r.target)},jm=function(t){return t.value};function sC(t){t.forEach(function(r){r.targetLinks.forEach(function(n){n.source.sourceLinks.sort(MDt)}),r.sourceLinks.forEach(function(n){n.target.targetLinks.sort(zDt)})})}var kDt=function(t,r){return t.align==="left"?t.depth:t.align==="right"?r-t.height:t.sourceLinks.length?t.depth:r},Fi=function(r){var n=r.nodesOptions,i=n.offset;i===void 0&&(i={});var o=n.align;this.data={nodes:r.nodes.map(function(a){return zt({},{offset:i,align:o},a)}),links:r.links.map(function(a){return zt({},a)})},this.width=r.width,this.height=r.height,this.offsetX=r.offsetX||0,this.offsetY=r.offsetY||0,this.nodeWidth=r.nodesOptions.width,this.nodePadding=r.nodesOptions.padding,this.reverse=r.reverse,this.targetColumnIndex=r.targetColumnIndex,this.loops=r.loops,this.autoLayout=r.autoLayout};Fi.prototype.calculate=function(){var r=this.data,n=r.nodes,i=r.links;this.connectLinksToNodes(n,i),this.calculateNodeValues(n);var o=this.calculateNodeHeights(n);if(o)return{nodes:[],links:[],columns:[],circularLinks:o};this.calculateNodeDepths(n);var a=this.calculateNodeColumns(n);return this.calculateNodeBreadths(a),this.applyNodesOffset(n),this.calculateLinkBreadths(n),Object.assign({},this.data,{columns:a})};Fi.prototype.connectLinksToNodes=function(r,n){var i=new Map;r.forEach(function(o,a){o.index=a,o.sourceLinks=[],o.targetLinks=[],o.id=o.id!==void 0?o.id:o.label.text,i.set(o.id,o)}),n.forEach(function(o){o.source=i.get(o.sourceId),o.target=i.get(o.targetId),o.source.sourceLinks.push(o),o.target.targetLinks.push(o)})};Fi.prototype.calculateNodeValues=function(r){r.forEach(function(n){n.value=Math.max(Wm(n.sourceLinks,jm),Wm(n.targetLinks,jm))})};Fi.prototype.calculateNodeDepths=function(r){for(var n=new Set(r),i=new Set,o=0;n.size;){for(var a=Array.from(n),s=0;sn)return!0;i=o,o=new Set}return!1};Fi.prototype.calculateNodeColumns=function(r){for(var n=this,i=CDt(r,function(p){return p.depth}),o=(this.width-this.offsetX-this.nodeWidth)/i,a=new Array(i+1),s=0;s=0;s--){for(var l=r[s],h=function(f){var g=l[f],b=0,z=0;g.sourceLinks.forEach(function(I){var F=I.value*(I.target.layer-g.layer);b+=i.sourceTopPos(g,I.target)*F,z+=F});var M=b===0?0:b/z-g.y0;g.y0+=M,g.y1+=M,sC([g])},p=0;p=0;--s){var l=r[s],h=Math.max(0,l.y1-a);l.y0-=h,l.y1-=h,a=l.y0-o.nodePadding}};Fi.prototype.sourceTopPos=function(r,n){for(var i=this,o=n.y0-(n.targetLinks.length-1)*this.nodePadding/2,a=0;al?1:s===l?0:-1}function ADt(t,r){var n=qh(t.x0,t.y0,t.x1,t.y1,r.x1,r.y1),i=qh(t.x0,t.y0,t.x1,t.y1,r.x0,r.y0),o=qh(t.x0,t.y0,r.x0,r.y0,r.x1,r.y1),a=qh(t.x1,t.y1,r.x0,r.y0,r.x1,r.y1);return n!==i&&o!==a}var c5=function(t){function r(n){t.call(this),this.options=zt({},this.options,n),this.createVisual()}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.createVisual=function(){this.visual=this.createElement()},r.prototype.exportVisual=function(){return this.visual},r.prototype.createElement=function(){var i=this,o=this.options.visual,a;return o?a=o({sender:this.getSender(),options:this.visualOptions(),createVisual:function(){return i.getElement()}}):a=this.getElement(),a},r.prototype.getSender=function(){return this},r}(Ve),HL=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.getElement=function(){return $e.fromRect(this.getRect(),this.visualOptions())},r.prototype.getRect=function(){var i=this.options.node;return new k1([i.x0,i.y0],[i.x1-i.x0,i.y1-i.y0])},r.prototype.getLabelText=function(i){var o=i.labels.ariaTemplate;if(o)return o({node:i.node})},r.prototype.visualOptions=function(){var i=zt({},this.options,this.options.node),o=this.getLabelText(i);return{fill:{color:i.color,opacity:i.opacity},stroke:{width:0},className:"k-sankey-node",role:"graphics-symbol",ariaRoleDescription:"Node",ariaLabel:o}},r.prototype.createFocusHighlight=function(){if(this.options.navigatable)return this._highlight=$e.fromRect(this.getRect(),{stroke:this.options.focusHighlight,visible:!1}),this._highlight},r.prototype.focus=function(i){if(this._highlight){var o=i||{},a=o.highlight;a===void 0&&(a=!0),a&&this._highlight.options.set("visible",!0);var s=this.options.node.id;this.visual.options.set("id",s),this.options.root()&&this.options.root().setAttribute(xl,s)}},r.prototype.blur=function(){this._highlight&&(this._highlight.options.set("visible",!1),this.visual.options.set("id",""),this.options.root()&&this.options.root().removeAttribute(xl))},r}(c5),LDt=function(t,r,n){return t.color||r[n%r.length]},DL=function(t,r,n,i){var o=zt({},r,r.node);return zt({},{color:LDt(t,n,i)},o,{node:t},{visual:t.visual,opacity:t.opacity,offset:t.offset,color:t.color})},EDt=function(t,r){var n=t[0],i=n[0],o=n[1],a=t[1],s=a[0],l=a[1],h=r[0],p=r[1];return Math.abs((s-i)*(p-o)-(h-i)*(l-o))/Math.sqrt(Math.pow(s-i,2)+Math.pow(l-o,2))},IDt=function(t,r,n,i,o){var a=1-o,s=a*a,l=o*o;return t*s*a+3*r*o*s+3*n*l*a+i*l*o},HDt=function(t,r){var n=t[0],i=n[0],o=n[1],a=t[1],s=a[0],l=a[1],h=r[0],p=h[0],f=h[1],g=r[1],b=g[0],z=g[1],M=Math.atan2(l-o,s-i),I=Math.atan2(z-f,b-p);return Math.abs(M-I)},DDt=function(t,r){var n=t.x0,i=t.x1,o=t.y0,a=t.y1,s=(n+i)/2,l=t.width,h=l/2,p=[[(n+s)/2,o-h],[(i+s)/2,a-h]],f=[s,IDt(o+h,o+h,a+h,a+h,.5)],g=EDt(p,f),b=(l-g)/2,z=HDt(p,[[n,o-h],[s,o-h]]),M=b,I=Math.sin(z)*M,F=Math.sqrt(M*M+I*I),H=o-a>0?-1:1;return r&&(H=-H),H*F},PDt=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.getElement=function(){var i=this.options.link,o=i.x0,a=i.x1,s=i.y0,l=i.y1,h=(o+a)/2;return new $e(this.visualOptions()).moveTo(o,s).curveTo([h,s],[h,l],[a,l])},r.prototype.getLabelText=function(i){var o=i.labels.ariaTemplate;if(o)return o({link:i.link})},r.prototype.visualOptions=function(){var i=this.options,o=this.options.link,a=this.getLabelText(i);return{stroke:{width:i.link.width,color:o.color||i.color,opacity:ne(o.opacity)?o.opacity:i.opacity},role:"graphics-symbol",ariaRoleDescription:"Link",ariaLabel:a}},r.prototype.createFocusHighlight=function(){if(this.options.navigatable){var i=this.options,o=i.link,a=i.rtl,s=o.x0,l=o.x1,h=o.y0,p=o.y1,f=(s+l)/2,g=o.width/2,b=DDt(o,a);this._highlight=new $e({stroke:this.options.focusHighlight,visible:!1}).moveTo(s,h+g).lineTo(s,h-g).curveTo([f+b,h-g],[f+b,p-g],[l,p-g]).lineTo(l,p+g).curveTo([f-b,p+g],[f-b,h+g],[s,h+g])}},r.prototype.focus=function(i){if(this._highlight){var o=i||{},a=o.highlight;a===void 0&&(a=!0),a&&this._highlight.options.set("visible",!0);var s=this.options.link.sourceId+"->"+this.options.link.targetId;this.visual.options.set("id",s),this.options.root()&&this.options.root().setAttribute(xl,s)}},r.prototype.blur=function(){this._highlight&&(this._highlight.options.set("visible",!1),this.visual.options.set("id",""),this.options.root()&&this.options.root().removeAttribute(xl))},r}(c5),TDt=function(t,r,n,i){var o=zt({},r,{link:t,opacity:t.opacity,color:t.color,colorType:t.colorType,visual:t.visual,highlight:t.highlight});return o.colorType==="source"?o.color=n.options.fill.color:o.colorType==="target"&&(o.color=i.options.fill.color),o},D7="inside",g3="before",Zh="after",Gm=function(t){function r(){t.apply(this,arguments)}return t&&(r.__proto__=t),r.prototype=Object.create(t&&t.prototype),r.prototype.constructor=r,r.prototype.getElement=function(){var i=zt({},this.options,this.options.node.label),o=i.node,a=i.diagramMinX,s=i.diagramMaxX,l=i.text,h=i.offset,p=i.rtl,f=i.position;if(p&&f!==D7&&(f=f===g3?Zh:g3),!i.visible||!l)return null;var g=new Ce(o.x0,o.y0,o.x1,o.y1),b=this.visualOptions();p&&!b.align&&(b.align="right");var z=new Nn(l,b);z.reflow(new Ce);var M=z.box,I=g.center().y-M.height()/2,F=o.x1+M.width()>s,H=o.x0-M.width()F.width()?et.x2-F.width():0,lt-=et.y2>F.height()?et.y2-F.height():0,ft+=et.x1<0?-et.x1:0,dt+=et.y1<0?-et.y1:0,M===!1)return{sankey:v3(Object.assign({},i,{offsetX:ft,offsetY:dt,width:ht,height:lt,autoLayout:!1})),legendBox:W,titleBox:H};if(this.resize&&M&&this.permutation)return this.resize=!1,{sankey:v3(Object.assign({},i,{offsetX:ft,offsetY:dt,width:ht,height:lt},this.permutation)),legendBox:W,titleBox:H};for(var yt=1,mt=2,gt=v3(Object.assign({},i,{offsetX:ft,offsetY:dt,width:ht,height:lt,autoLayout:!1})).columns.length,_t=[],At=function(Rt,Ut){var Kt=v3(Object.assign({},i,{offsetX:ft,offsetY:dt,width:ht,height:lt,loops:mt,targetColumnIndex:Rt,reverse:Ut})),It=_Dt(Kt.links);return _t.push({crosses:It,reverse:Ut,targetColumnIndex:Rt}),It===0},bt=yt;bt<=gt-1&&!(At(bt,!1)||At(bt,!0));bt++);var kt=Math.min.apply(null,_t.map(function(Rt){return Rt.crosses})),Lt=_t.find(function(Rt){return Rt.crosses===kt});this.permutation={targetColumnIndex:Lt.targetColumnIndex,reverse:Lt.reverse};var Vt=v3(Object.assign({},i,{offsetX:ft,offsetY:dt,width:ht,height:lt},this.permutation));return{sankey:Vt,legendBox:W,titleBox:H}},r.prototype._render=function(i,o){var a=i||this.options,s=o||this,l=a.labels,h=a.nodes,p=a.links,f=a.nodeColors,g=a.title,b=a.legend,z=a.rtl,M=a.disableKeyboardNavigation,I=a.data,F=s.size,H=F.width,E=F.height,R=Object.assign({},I,{width:H,height:E,nodesOptions:h,title:g,legend:b}),W=this.calculateSankey(R,a),$=W.sankey,G=W.titleBox,Z=W.legendBox;z&&ODt($);var K=$.nodes,et=$.links,at=$.columns;s.columns=at.map(function(Vt){var Rt=Vt.slice();return Rt.sort(function(Ut,Kt){return Ut.y0-Kt.y0}),Rt});var tt=new H1({clip:$e.fromRect(new k1([0,0],[H,E]))});if(G){var ft=new Um(Object.assign({},g,{drawingRect:G})),dt=ft.exportVisual();tt.append(dt)}if($.circularLinks)return tt;var ht=new Map;s.nodesVisuals=ht;var lt={nodes:[],links:[],map:new Map};s.models=lt;var yt=[];K.forEach(function(Vt,Rt){var Ut=DL(Vt,h,f,Rt);Ut.root=function(){return s.element},Ut.navigatable=M!==!0;var Kt=new HL(Ut),It=Kt.exportVisual();It.links=[],It.type=m3,Vt.color=Ut.color,Vt.opacity=Ut.opacity,It.dataItem=Object.assign({},I.nodes[Rt],{color:Ut.color,opacity:Ut.opacity,sourceLinks:Vt.sourceLinks.map(function(le){return{sourceId:le.sourceId,targetId:le.targetId,value:le.value}}),targetLinks:Vt.targetLinks.map(function(le){return{sourceId:le.sourceId,targetId:le.targetId,value:le.value}})}),ht.set(Vt.id,It),lt.nodes.push(Kt),lt.map.set(Vt.id,Kt),tt.append(It),Kt.createFocusHighlight(),Kt._highlight&&yt.push(Kt._highlight)});var mt=et.slice().sort(function(Vt,Rt){return Rt.value-Vt.value}),gt=[];s.linksVisuals=gt,mt.forEach(function(Vt){var Rt=Vt.source,Ut=Vt.target,Kt=ht.get(Rt.id),It=ht.get(Ut.id),le=TDt(Vt,p,Kt,It);le.root=function(){return s.element},le.navigatable=M!==!0,le.rtl=z;var Bt=new PDt(le),de=Bt.exportVisual();de.type=G6,de.dataItem={source:Object.assign({},Kt.dataItem),target:Object.assign({},It.dataItem),value:Vt.value},de.linkOptions=le,gt.push(de),Kt.links.push(de),It.links.push(de),lt.links.push(Bt),lt.map.set(Rt.id+"-"+Ut.id,Bt),Bt.createFocusHighlight(),Bt._highlight&&yt.push(Bt._highlight),tt.append(de)});var _t=K.reduce(function(Vt,Rt){return Math.min(Vt,Rt.x0)},1/0),At=K.reduce(function(Vt,Rt){return Math.max(Vt,Rt.x1)},0);if(K.forEach(function(Vt){var Rt=PL(Vt,l,z,_t,At),Ut=new Gm(Rt),Kt=Ut.exportVisual();Kt&&tt.append(Kt)}),Z){var bt=new P7(Object.assign({},b,{rtl:z,drawingRect:Z,nodes:K})),kt=bt.exportVisual();tt.append(kt)}if(yt.length!==0){var Lt=new H1;Lt.append.apply(Lt,yt),tt.append(Lt)}return tt},r.prototype.exportVisual=function(i){var o=i&&i.options?zt({},this.options,i.options):this.options,a={size:{width:ne(i&&i.width)?i.width:this.size.width,height:ne(i&&i.height)?i.height:this.size.height}};return this._render(o,a)},r.prototype._setOptions=function(i){this.options=zt({},this.options,i)},r}(U2),Ym={opacity:1,width:2,color:kr};ve(BDt,{title:{position:v1},labels:{visible:!0,margin:{left:8,right:8},padding:0,border:{width:0},paintOrder:"stroke",stroke:{lineJoin:"round",width:1},offset:{left:0,top:0}},nodes:{width:24,padding:16,opacity:1,align:"stretch",offset:{left:0,top:0},focusHighlight:Object.assign({},Ym),labels:{ariaTemplate:function(t){var r=t.node;return r.label.text}}},links:{colorType:"static",opacity:.4,highlight:{opacity:.8,inactiveOpacity:.2},focusHighlight:Object.assign({},Ym),labels:{ariaTemplate:function(t){var r=t.link;return r.source.label.text+" to "+r.target.label.text}}},tooltip:{followPointer:!1,delay:200}});var h5=1.5,u6=.4,PR="#000",lC="Arial, Helvetica, sans-serif",NDt="11px "+lC,Qp="12px "+lC,TR="16px "+lC,VR="transparent",FR="#fff",p6={type:Qa},td={type:Ja},rn=Object.assign({},td,{markers:{visible:!1},highlight:{visible:!1}}),RR=function(){return{icon:{border:{width:1}},label:{font:Qp,padding:3},line:{length:10,width:2},legendItem:rn,visible:!0}},$Dt=function(){return{labels:{font:Qp},notes:RR(),title:{font:TR,margin:5}}},TL=function(){return{highlight:{markers:{border:{}}},line:{opacity:1,width:0},markers:{size:6,visible:!1},legendItem:td,opacity:.4}},VL=function(){return{highlight:{markers:{border:{}}},line:{opacity:1,width:0},markers:{size:6,visible:!1},legendItem:td,opacity:.4}},WDt=function(){return{gap:h5,spacing:u6,legendItem:rn}},FL=function(){return{outliersField:"",meanField:"",border:{_brightness:.8,width:1},downColor:FR,gap:1,highlight:{border:{opacity:1,width:2},whiskers:{width:3},mean:{width:2},median:{width:2}},mean:{width:2},median:{width:2},spacing:.3,whiskers:{width:2},legendItem:rn}},jDt=function(){return{border:{width:0},labels:{background:VR},legendItem:rn,opacity:.6}},RL=function(){return{gap:h5,spacing:u6,target:{color:"#ff0000"},legendItem:rn}},GDt=function(){return{border:{_brightness:.8,width:1},downColor:FR,gap:1,highlight:{border:{opacity:1,width:2},line:{width:2}},line:{color:PR,width:1},legendItem:rn,spacing:.3}},UDt=function(){return{gap:h5,spacing:u6,legendItem:rn}},YDt=function(){return{legendItem:rn}},XDt=function(){return{legendItem:p6}},KDt=function(){return{legendItem:p6}},qDt=function(){return{margin:1,legendItem:rn}},OL=function(){return{width:2,legendItem:p6}},ZDt=function(){return{gap:1,highlight:{line:{opacity:1,width:3}},line:{width:1},legendItem:rn,spacing:.3}},BL=function(){return{line:{opacity:1,width:0},markers:{size:6,visible:!1},legendItem:td,opacity:.5}},NL=function(){return{markers:{visible:!1},legendItem:p6,width:2}},JDt=function(){return{gap:h5,spacing:u6,legendItem:rn}},QDt=function(){return{gap:h5,spacing:u6,legendItem:rn}},tPt=function(){return{width:1,legendItem:p6}},$L=function(){return{gap:.5,line:{color:PR,width:1},legendItem:rn,spacing:u6}},ePt=function(){return{labels:{background:"",color:"",padding:{top:5,bottom:5,left:7,right:7}},legendItem:rn}},OR=function(){return{labels:{background:"",color:"",padding:{top:5,bottom:5,left:7,right:7}},legendItem:rn}},rPt=OR,iPt=function(){return{labels:{color:"",background:VR,visible:!0},highlight:{border:{width:0}},legendItem:rn}},y3=function(t){return Object.assign({color:uT,trendline:{},markers:{visible:!1},width:1,dashType:"longDash",legendItem:p6},t)},nPt=function(t){return{visible:!0,labels:{font:NDt},overlay:t.gradients?{}:{gradient:"none"},area:TL(),rangeArea:VL(),verticalRangeArea:VL(),bar:WDt(),boxPlot:FL(),bubble:jDt(),bullet:RL(),candlestick:GDt(),column:UDt(),heatmap:iPt(),pie:ePt(),donut:qDt(),funnel:OR(),pyramid:rPt(),horizontalWaterfall:$L(),line:OL(),notes:RR(),ohlc:ZDt(),radarArea:BL(),radarLine:NL(),radarColumn:YDt(),polarArea:BL(),polarLine:NL(),polarScatter:XDt(),rangeBar:JDt(),rangeColumn:QDt(),scatter:KDt(),scatterLine:tPt(),verticalArea:TL(),verticalBoxPlot:FL(),verticalBullet:RL(),verticalLine:OL(),waterfall:$L(),linearTrendline:y3(),exponentialTrendline:y3({style:"smooth"}),logarithmicTrendline:y3({style:"smooth"}),polynomialTrendline:y3({style:"smooth"}),powerTrendline:y3({style:"smooth"}),movingAverageTrendline:y3()}},oPt=function(){return{font:TR}},aPt=function(){return{font:Qp}},sPt=function(){return{labels:{font:Qp}}},WL=function(t){return t===void 0&&(t={}),{axisDefaults:$Dt(),categoryAxis:{majorGridLines:{visible:!0}},navigator:{pane:{height:90,margin:{top:10}}},seriesDefaults:nPt(t),title:oPt(),subtitle:aPt(),legend:sPt()}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */function OR(t,r){let n=t;for(;n&&n!==r;)n=n.parentNode;return!!n}function sPt(t,r,n,i){const o=t[r];if(o&&Array.isArray(o)){for(let a of o)if(!a.type||a.type!==i)return new Error(`${n} children should be Array of type ${i.displayName}.`)}return null}const WL=t=>t===void 0?!1:!t;/** + */function BR(t,r){let n=t;for(;n&&n!==r;)n=n.parentNode;return!!n}function lPt(t,r,n,i){const o=t[r];if(o&&Array.isArray(o)){for(let a of o)if(!a.type||a.type!==i)return new Error(`${n} children should be Array of type ${i.displayName}.`)}return null}const jL=t=>t===void 0?!1:!t;/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let g2=class{constructor(r){this.target=r}};/** + */let p2=class{constructor(r){this.target=r}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let lPt=class extends g2{constructor(r,n){super(n),this.axis=r.axis,this.dataItem=r.dataItem,this.index=r.index,this.text=r.text,this.value=r.value}};/** + */let cPt=class extends p2{constructor(r,n){super(n),this.axis=r.axis,this.dataItem=r.dataItem,this.index=r.index,this.text=r.text,this.value=r.value}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let aa=class extends g2{constructor(){super(...arguments),this.prevented=!1}preventDefault(){this.prevented=!0}isDefaultPrevented(){return this.prevented}};/** + */let na=class extends p2{constructor(){super(...arguments),this.prevented=!1}preventDefault(){this.prevented=!0}isDefaultPrevented(){return this.prevented}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let cPt=class extends aa{constructor(r,n){super(n),this.axisRanges=r.axisRanges,this.nativeEvent=r.originalEvent}};/** + */let hPt=class extends na{constructor(r,n){super(n),this.axisRanges=r.axisRanges,this.nativeEvent=r.originalEvent}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let hPt=class extends g2{constructor(r,n){super(n),this.axisRanges=r.axisRanges,this.nativeEvent=r.originalEvent}};/** + */let uPt=class extends p2{constructor(r,n){super(n),this.axisRanges=r.axisRanges,this.nativeEvent=r.originalEvent}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let uPt=class extends aa{constructor(r,n){super(n),this.axisRanges=r.axisRanges,this.nativeEvent=r.originalEvent}};/** + */let pPt=class extends na{constructor(r,n){super(n),this.axisRanges=r.axisRanges,this.nativeEvent=r.originalEvent}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let BR=class extends g2{constructor(r,n){super(n),this.value=r.value,this.point=r.point,this.series=r.series,this.currentState=r.currentState,this.nextState=r.nextState}};/** + */let NR=class extends p2{constructor(r,n){super(n),this.value=r.value,this.point=r.point,this.series=r.series,this.currentState=r.currentState,this.nextState=r.nextState}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let pPt=class extends aa{constructor(r,n){super(n),this.series=r.series,this.seriesIndex=r.seriesIndex,this.pointIndex=r.pointIndex,this.text=r.text}preventDefault(){super.preventDefault()}};/** + */let dPt=class extends na{constructor(r,n){super(n),this.series=r.series,this.seriesIndex=r.seriesIndex,this.pointIndex=r.pointIndex,this.text=r.text}preventDefault(){super.preventDefault()}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let dPt=class extends aa{constructor(r,n){super(n),this.series=r.series,this.seriesIndex=r.seriesIndex,this.pointIndex=r.pointIndex,this.text=r.text}preventDefault(){super.preventDefault()}};/** + */let fPt=class extends na{constructor(r,n){super(n),this.series=r.series,this.seriesIndex=r.seriesIndex,this.pointIndex=r.pointIndex,this.text=r.text}preventDefault(){super.preventDefault()}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let fPt=class extends aa{constructor(r,n){super(n),this.series=r.series,this.seriesIndex=r.seriesIndex,this.pointIndex=r.pointIndex,this.text=r.text}preventDefault(){super.preventDefault()}};/** + */let vPt=class extends na{constructor(r,n){super(n),this.series=r.series,this.seriesIndex=r.seriesIndex,this.pointIndex=r.pointIndex,this.text=r.text}preventDefault(){super.preventDefault()}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let vPt=class extends g2{constructor(r,n){super(n),this.from=r.from,this.to=r.to}};/** + */let gPt=class extends p2{constructor(r,n){super(n),this.from=r.from,this.to=r.to}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let gPt=class extends g2{constructor(r,n){super(n),this.category=r.category,this.dataItem=r.dataItem,this.series=r.series,this.value=r.value,this.visual=r.visual}};/** + */let mPt=class extends p2{constructor(r,n){super(n),this.category=r.category,this.dataItem=r.dataItem,this.series=r.series,this.value=r.value,this.visual=r.visual}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let mPt=class extends g2{constructor(r,n){super(n),this.category=r.category,this.dataItem=r.dataItem,this.series=r.series,this.value=r.value,this.visual=r.visual}};/** + */let yPt=class extends p2{constructor(r,n){super(n),this.category=r.category,this.dataItem=r.dataItem,this.series=r.series,this.value=r.value,this.visual=r.visual}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let yPt=class extends g2{constructor(r,n){super(n),this.category=r.category,this.nativeEvent=r.originalEvent,this.value=r.value,this.x=r.x,this.y=r.y}};/** + */let xPt=class extends p2{constructor(r,n){super(n),this.category=r.category,this.nativeEvent=r.originalEvent,this.value=r.value,this.x=r.x,this.y=r.y}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let xPt=class extends g2{constructor(r,n){super(n),this.category=r.category,this.nativeEvent=r.originalEvent,this.value=r.value,this.x=r.x,this.y=r.y}};/** + */let bPt=class extends p2{constructor(r,n){super(n),this.category=r.category,this.nativeEvent=r.originalEvent,this.value=r.value,this.x=r.x,this.y=r.y}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let bPt=class extends g2{constructor(r,n){super(n)}};/** + */let wPt=class extends p2{constructor(r,n){super(n)}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let wPt=class extends aa{constructor(r,n){super(n),this.axis=r.axis,this.from=r.from,this.to=r.to}};/** + */let CPt=class extends na{constructor(r,n){super(n),this.axis=r.axis,this.from=r.from,this.to=r.to}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let CPt=class extends g2{constructor(r,n){super(n),this.axis=r.axis,this.from=r.from,this.to=r.to}};/** + */let SPt=class extends p2{constructor(r,n){super(n),this.axis=r.axis,this.from=r.from,this.to=r.to}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let SPt=class extends aa{constructor(r,n){super(n),this.axis=r.axis,this.from=r.from,this.to=r.to}};/** + */let zPt=class extends na{constructor(r,n){super(n),this.axis=r.axis,this.from=r.from,this.to=r.to}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let zPt=class extends g2{constructor(r,n){super(n),this.category=r.category,this.dataItem=r.dataItem,this.nativeEvent=r.originalEvent,this.percentage=r.percentage,this.point=r.point,this.series=r.series,this.stackValue=r.stackValue,this.value=r.value}};/** + */let MPt=class extends p2{constructor(r,n){super(n),this.category=r.category,this.dataItem=r.dataItem,this.nativeEvent=r.originalEvent,this.percentage=r.percentage,this.point=r.point,this.series=r.series,this.stackValue=r.stackValue,this.value=r.value}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let MPt=class extends aa{constructor(r,n){super(n),this.category=r.category,this.categoryPoints=r.categoryPoints,this.dataItem=r.dataItem,this.nativeEvent=r.originalEvent,this.percentage=r.percentage,this.point=r.point,this.series=r.series,this.stackValue=r.stackValue,this.value=r.value}};/** + */let kPt=class extends na{constructor(r,n){super(n),this.category=r.category,this.categoryPoints=r.categoryPoints,this.dataItem=r.dataItem,this.nativeEvent=r.originalEvent,this.percentage=r.percentage,this.point=r.point,this.series=r.series,this.stackValue=r.stackValue,this.value=r.value}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let kPt=class extends aa{constructor(r,n){super(n),this.axisRanges=r.axisRanges,this.delta=r.delta,this.nativeEvent=r.originalEvent}};/** + */let _Pt=class extends na{constructor(r,n){super(n),this.axisRanges=r.axisRanges,this.delta=r.delta,this.nativeEvent=r.originalEvent}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let _Pt=class extends g2{constructor(r,n){super(n),this.axisRanges=r.axisRanges,this.nativeEvent=r.originalEvent}};/** + */let APt=class extends p2{constructor(r,n){super(n),this.axisRanges=r.axisRanges,this.nativeEvent=r.originalEvent}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let APt=class extends aa{constructor(r,n){super(n),this.axisRanges=r.axisRanges,this.nativeEvent=r.originalEvent}};/** + */let LPt=class extends na{constructor(r,n){super(n),this.axisRanges=r.axisRanges,this.nativeEvent=r.originalEvent}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const jL={axisLabelClick:lPt,drag:cPt,dragEnd:hPt,dragStart:uPt,drilldownEvent:BR,legendItemHover:pPt,legendItemClick:dPt,legendItemLeave:fPt,navigatorFilter:vPt,noteClick:gPt,noteHover:mPt,plotAreaClick:yPt,plotAreaHover:xPt,render:bPt,select:wPt,selectEnd:CPt,selectStart:SPt,seriesClick:zPt,seriesHover:MPt,zoom:kPt,zoomEnd:_Pt,zoomStart:APt};function LPt(t,r,n){if(jL[t])return new jL[t](r,n)}/** + */const GL={axisLabelClick:cPt,drag:hPt,dragEnd:uPt,dragStart:pPt,drilldownEvent:NR,legendItemHover:dPt,legendItemClick:fPt,legendItemLeave:vPt,navigatorFilter:gPt,noteClick:mPt,noteHover:yPt,plotAreaClick:xPt,plotAreaHover:bPt,render:wPt,select:CPt,selectEnd:SPt,selectStart:zPt,seriesClick:MPt,seriesHover:kPt,zoom:_Pt,zoomEnd:APt,zoomStart:LPt};function EPt(t,r,n){if(GL[t])return new GL[t](r,n)}/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let EPt=class{constructor(r,n){this.sender=r,this.syntheticEvent=n}};function NR(t,r){return new EPt(t,r)}/** + */let IPt=class{constructor(r,n){this.sender=r,this.syntheticEvent=n}};function $R(t,r){return new IPt(t,r)}/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const Jh=t=>`${t.fontWeight} ${t.fontSize} ${t.fontFamily}`,GL=t=>window.getComputedStyle(t).backgroundColor,IPt=t=>t.toLowerCase().charCodeAt(0)-97,HPt=t=>{const r=t.match(/series-([a-z])$/);if(r!==null)return IPt(r[1]);const n=t.split("--series-")[1];return parseInt(n,10)-1},DPt=30,PPt=()=>{let t=` + */const Jh=t=>`${t.fontWeight} ${t.fontSize} ${t.fontFamily}`,UL=t=>window.getComputedStyle(t).backgroundColor,HPt=t=>t.toLowerCase().charCodeAt(0)-97,DPt=t=>{const r=t.match(/series-([a-z])$/);if(r!==null)return HPt(r[1]);const n=t.split("--series-")[1];return parseInt(n,10)-1},PPt=30,TPt=()=>{let t=`
-`;for(let r=0;r
`;return t},TPt=` +`;for(let r=0;r
`;return t},VPt=`
@@ -629,207 +629,207 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
- ${PPt()} + ${TPt()}
-`;let VPt=class{constructor(r){this.store=r}setStyle(r,n){this.store.dispatch({type:"set",payload:{field:r,value:n}})}setColors(){this.mapColor("axisDefaults.crosshair.color","chart-crosshair-background"),this.mapColor("axisDefaults.labels.color","normal-text-color"),this.mapColor("axisDefaults.line.color","chart-major-lines"),this.mapColor("axisDefaults.majorGridLines.color","chart-major-lines"),this.mapColor("axisDefaults.minorGridLines.color","chart-minor-lines"),this.mapColor("axisDefaults.notes.icon.background","chart-notes-background"),this.mapColor("axisDefaults.notes.icon.border.color","chart-notes-border"),this.mapColor("axisDefaults.notes.line.color","chart-notes-lines"),this.mapColor("axisDefaults.title.color","normal-text-color"),this.mapColor("chartArea.background","background"),this.mapColor("legend.inactiveItems.labels.color","chart-inactive"),this.mapColor("legend.inactiveItems.markers.color","chart-inactive"),this.mapColor("legend.labels.color","normal-text-color"),this.mapColor("seriesDefaults.boxPlot.downColor","chart-major-lines"),this.mapColor("seriesDefaults.boxPlot.mean.color","base"),this.mapColor("seriesDefaults.boxPlot.median.color","base"),this.mapColor("seriesDefaults.boxPlot.whiskers.color","primary"),this.mapColor("seriesDefaults.bullet.target.color","normal-text-color"),this.mapColor("seriesDefaults.candlestick.downColor","normal-text-color"),this.mapColor("seriesDefaults.candlestick.line.color","normal-text-color"),this.mapColor("seriesDefaults.errorBars.color","chart-error-bars-background"),this.mapColor("seriesDefaults.horizontalWaterfall.line.color","chart-major-lines"),this.mapColor("seriesDefaults.icon.border.color","chart-major-lines"),this.mapColor("seriesDefaults.labels.background","background"),this.mapColor("seriesDefaults.labels.color","normal-text-color"),this.mapColor("seriesDefaults.notes.icon.background","chart-notes-background"),this.mapColor("seriesDefaults.notes.icon.border.color","chart-notes-border"),this.mapColor("seriesDefaults.notes.line.color","chart-notes-lines"),this.mapColor("seriesDefaults.verticalBoxPlot.downColor","chart-major-lines"),this.mapColor("seriesDefaults.verticalBoxPlot.mean.color","base"),this.mapColor("seriesDefaults.verticalBoxPlot.median.color","base"),this.mapColor("seriesDefaults.verticalBoxPlot.whiskers.color","primary"),this.mapColor("seriesDefaults.verticalBullet.target.color","normal-text-color"),this.mapColor("seriesDefaults.waterfall.line.color","chart-major-lines"),this.mapColor("title.color","normal-text-color"),this.mapColor("subtitle.color","normal-text-color");const r=parseFloat(this.queryStyle("chart-area-opacity").opacity);isNaN(r)||(this.setStyle("seriesDefaults.area.opacity",r),this.setStyle("seriesDefaults.radarArea.opacity",r),this.setStyle("seriesDefaults.verticalArea.opacity",r),this.setStyle("seriesDefaults.labels.opacity",r)),this.setInactiveOpacity(["area","verticalArea"],"chart-area-inactive-opacity"),this.setInactiveOpacity(["line","verticalLine"],"chart-line-inactive-opacity")}setFonts(){const r=Jh(this.queryStyle("chart-font")),n=Jh(this.queryStyle("chart-title-font")),i=Jh(this.queryStyle("chart-pane-title-font")),o=Jh(this.queryStyle("chart-label-font"));this.setStyle("axisDefaults.labels.font",o),this.setStyle("axisDefaults.notes.label.font",r),this.setStyle("axisDefaults.title.font",r),this.setStyle("legend.labels.font",r),this.setStyle("seriesDefaults.labels.font",o),this.setStyle("seriesDefaults.notes.label.font",r),this.setStyle("title.font",n),this.setStyle("subtitle.font",i),this.setStyle("paneDefaults.title.font",i)}setSeriesColors(){const r=this.element,n=[].slice.call(r.querySelectorAll(".k-var--series div")),i=GL(r.querySelector(".k-var--series-unset")),o=n.reduce((a,s)=>{const l=HPt(s.className),h=GL(s);return h!==i&&(a[l]=h),a},[]);this.setStyle("seriesColors",o)}mapColor(r,n){this.setStyle(r,this.queryStyle(n).backgroundColor)}queryStyle(r){const n=this.element;return window.getComputedStyle(n.querySelector(`.k-var--${r}`))}setInactiveOpacity(r,n){const i=parseFloat(this.queryStyle(n).opacity);!isNaN(i)&&i<1&&r.forEach(o=>this.setStyle(`seriesDefaults.${o}.highlight.inactiveOpacity`,i))}};const FPt=(t,r,n)=>{const i=new VPt(t);if(typeof n>"u"){t.dispatch({type:"push",payload:$L()});return}const o=i.element=n.createElement("div");o.style.display="none",o.innerHTML=TPt,n.body.appendChild(o);try{t.dispatch({type:"push",payload:$L()}),i.setColors(),i.setFonts(),i.setSeriesColors()}finally{n.body.removeChild(i.element),delete i.element,r()}};/** +`;let FPt=class{constructor(r){this.store=r}setStyle(r,n){this.store.dispatch({type:"set",payload:{field:r,value:n}})}setColors(){this.mapColor("axisDefaults.crosshair.color","chart-crosshair-background"),this.mapColor("axisDefaults.labels.color","normal-text-color"),this.mapColor("axisDefaults.line.color","chart-major-lines"),this.mapColor("axisDefaults.majorGridLines.color","chart-major-lines"),this.mapColor("axisDefaults.minorGridLines.color","chart-minor-lines"),this.mapColor("axisDefaults.notes.icon.background","chart-notes-background"),this.mapColor("axisDefaults.notes.icon.border.color","chart-notes-border"),this.mapColor("axisDefaults.notes.line.color","chart-notes-lines"),this.mapColor("axisDefaults.title.color","normal-text-color"),this.mapColor("chartArea.background","background"),this.mapColor("legend.inactiveItems.labels.color","chart-inactive"),this.mapColor("legend.inactiveItems.markers.color","chart-inactive"),this.mapColor("legend.labels.color","normal-text-color"),this.mapColor("seriesDefaults.boxPlot.downColor","chart-major-lines"),this.mapColor("seriesDefaults.boxPlot.mean.color","base"),this.mapColor("seriesDefaults.boxPlot.median.color","base"),this.mapColor("seriesDefaults.boxPlot.whiskers.color","primary"),this.mapColor("seriesDefaults.bullet.target.color","normal-text-color"),this.mapColor("seriesDefaults.candlestick.downColor","normal-text-color"),this.mapColor("seriesDefaults.candlestick.line.color","normal-text-color"),this.mapColor("seriesDefaults.errorBars.color","chart-error-bars-background"),this.mapColor("seriesDefaults.horizontalWaterfall.line.color","chart-major-lines"),this.mapColor("seriesDefaults.icon.border.color","chart-major-lines"),this.mapColor("seriesDefaults.labels.background","background"),this.mapColor("seriesDefaults.labels.color","normal-text-color"),this.mapColor("seriesDefaults.notes.icon.background","chart-notes-background"),this.mapColor("seriesDefaults.notes.icon.border.color","chart-notes-border"),this.mapColor("seriesDefaults.notes.line.color","chart-notes-lines"),this.mapColor("seriesDefaults.verticalBoxPlot.downColor","chart-major-lines"),this.mapColor("seriesDefaults.verticalBoxPlot.mean.color","base"),this.mapColor("seriesDefaults.verticalBoxPlot.median.color","base"),this.mapColor("seriesDefaults.verticalBoxPlot.whiskers.color","primary"),this.mapColor("seriesDefaults.verticalBullet.target.color","normal-text-color"),this.mapColor("seriesDefaults.waterfall.line.color","chart-major-lines"),this.mapColor("title.color","normal-text-color"),this.mapColor("subtitle.color","normal-text-color");const r=parseFloat(this.queryStyle("chart-area-opacity").opacity);isNaN(r)||(this.setStyle("seriesDefaults.area.opacity",r),this.setStyle("seriesDefaults.radarArea.opacity",r),this.setStyle("seriesDefaults.verticalArea.opacity",r),this.setStyle("seriesDefaults.labels.opacity",r)),this.setInactiveOpacity(["area","verticalArea"],"chart-area-inactive-opacity"),this.setInactiveOpacity(["line","verticalLine"],"chart-line-inactive-opacity")}setFonts(){const r=Jh(this.queryStyle("chart-font")),n=Jh(this.queryStyle("chart-title-font")),i=Jh(this.queryStyle("chart-pane-title-font")),o=Jh(this.queryStyle("chart-label-font"));this.setStyle("axisDefaults.labels.font",o),this.setStyle("axisDefaults.notes.label.font",r),this.setStyle("axisDefaults.title.font",r),this.setStyle("legend.labels.font",r),this.setStyle("seriesDefaults.labels.font",o),this.setStyle("seriesDefaults.notes.label.font",r),this.setStyle("title.font",n),this.setStyle("subtitle.font",i),this.setStyle("paneDefaults.title.font",i)}setSeriesColors(){const r=this.element,n=[].slice.call(r.querySelectorAll(".k-var--series div")),i=UL(r.querySelector(".k-var--series-unset")),o=n.reduce((a,s)=>{const l=DPt(s.className),h=UL(s);return h!==i&&(a[l]=h),a},[]);this.setStyle("seriesColors",o)}mapColor(r,n){this.setStyle(r,this.queryStyle(n).backgroundColor)}queryStyle(r){const n=this.element;return window.getComputedStyle(n.querySelector(`.k-var--${r}`))}setInactiveOpacity(r,n){const i=parseFloat(this.queryStyle(n).opacity);!isNaN(i)&&i<1&&r.forEach(o=>this.setStyle(`seriesDefaults.${o}.highlight.inactiveOpacity`,i))}};const RPt=(t,r,n)=>{const i=new FPt(t);if(typeof n>"u"){t.dispatch({type:"push",payload:WL()});return}const o=i.element=n.createElement("div");o.style.display="none",o.innerHTML=VPt,n.body.appendChild(o);try{t.dispatch({type:"push",payload:WL()}),i.setColors(),i.setFonts(),i.setSeriesColors()}finally{n.body.removeChild(i.element),delete i.element,r()}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const RPt=1e3/60,T7=t=>{let r,n,i=[];const o=()=>r,a=l=>{r=t(r,l),ai&&(window.clearTimeout(n),n=window.setTimeout(()=>i.forEach(h=>h()),RPt))},s=l=>(i.push(l),()=>i=i.filter(h=>h!==l));return a({}),{getState:o,dispatch:a,subscribe:s}};/** + */const OPt=1e3/60,T7=t=>{let r,n,i=[];const o=()=>r,a=l=>{r=t(r,l),oi&&(window.clearTimeout(n),n=window.setTimeout(()=>i.forEach(h=>h()),OPt))},s=l=>(i.push(l),()=>i=i.filter(h=>h!==l));return a({}),{getState:o,dispatch:a,subscribe:s}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const $R=(t,r)=>r.chartCollectionIdxKey?Xm.collectionConfigurationItem(t,r):r.chartKey?Xm.configurationItem(t,r):{},OPt=(t,r)=>{if(r.type)switch(r.type){case"set":return Xm.themeItem(t,r);case"push":return Object.assign(t,r.payload);default:return t}else return{}},BPt=(t,r)=>{if(r.type)switch(r.type){case"add":return[...t,r.payload];case"remove":return t.filter(n=>n!==r.payload);default:return t}else return[]},Xm={configurationItem(t,r){return Object.assign(t,{[r.chartKey]:r.payload})},collectionConfigurationItem(t,r){let n=!1;const[i,o]=r.chartCollectionIdxKey.split("_"),a=t[i].map((s,l)=>parseInt(o,10)===l?(n=!0,r.payload):s);return n===!1&&a.splice(parseInt(o,10),0,r.payload),Object.assign(t,{[i]:a})},themeItem(t,r){let n={},i=Object.assign(n,t);const{field:o,value:a}=r.payload,s=o.split(".");let l=s.shift();for(;s.length>0;)n=n[l]=n[l]||{},l=s.shift();return n[l]=a,i}};/** + */const WR=(t,r)=>r.chartCollectionIdxKey?Xm.collectionConfigurationItem(t,r):r.chartKey?Xm.configurationItem(t,r):{},BPt=(t,r)=>{if(r.type)switch(r.type){case"set":return Xm.themeItem(t,r);case"push":return Object.assign(t,r.payload);default:return t}else return{}},NPt=(t,r)=>{if(r.type)switch(r.type){case"add":return[...t,r.payload];case"remove":return t.filter(n=>n!==r.payload);default:return t}else return[]},Xm={configurationItem(t,r){return Object.assign(t,{[r.chartKey]:r.payload})},collectionConfigurationItem(t,r){let n=!1;const[i,o]=r.chartCollectionIdxKey.split("_"),a=t[i].map((s,l)=>parseInt(o,10)===l?(n=!0,r.payload):s);return n===!1&&a.splice(parseInt(o,10),0,r.payload),Object.assign(t,{[i]:a})},themeItem(t,r){let n={},i=Object.assign(n,t);const{field:o,value:a}=r.payload,s=o.split(".");let l=s.shift();for(;s.length>0;)n=n[l]=n[l]||{},l=s.shift();return n[l]=a,i}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let UL=class{constructor(r,n){this.value=r.value,this.category=r.category,this.categoryIndex=r.categoryIx,this.series=r.series,this.dataItem=r.dataItem,this.percentage=r.percentage,this.runningTotal=r.runningTotal,this.total=r.total,this.low=r.low,this.high=r.high,this.xLow=r.xLow,this.xHigh=r.xHigh,this.yLow=r.yLow,this.yHigh=r.yHigh,this.point=r,this.format=((r.options||{}).tooltip||{}).format||n}get formattedValue(){return this.format?this.point.formatValue(this.format):String(this.value)}};/** + */let YL=class{constructor(r,n){this.value=r.value,this.category=r.category,this.categoryIndex=r.categoryIx,this.series=r.series,this.dataItem=r.dataItem,this.percentage=r.percentage,this.runningTotal=r.runningTotal,this.total=r.total,this.low=r.low,this.high=r.high,this.xLow=r.xLow,this.xHigh=r.xHigh,this.yLow=r.yLow,this.yHigh=r.yHigh,this.point=r,this.format=((r.options||{}).tooltip||{}).format||n}get formattedValue(){return this.format?this.point.formatValue(this.format):String(this.value)}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const NPt="k-chart-shared-tooltip-marker",$Pt=t=>{const{categoryText:r,colorMarker:n,colspan:i,nameColumn:o,points:a}=t,s=(l,h)=>_.createElement("tr",{key:h},n&&_.createElement("td",null,_.createElement("span",{className:NPt,style:{backgroundColor:l.series.color}})),o&&_.createElement("td",null,l.series.name),_.createElement("td",{dangerouslySetInnerHTML:{__html:l.formattedValue}}));return _.createElement("table",null,_.createElement("thead",null,_.createElement("tr",null,_.createElement("th",{colSpan:i},r))),_.createElement("tbody",null,a.map(s)))};/** + */const $Pt="k-chart-shared-tooltip-marker",WPt=t=>{const{categoryText:r,colorMarker:n,colspan:i,nameColumn:o,points:a}=t,s=(l,h)=>_.createElement("tr",{key:h},n&&_.createElement("td",null,_.createElement("span",{className:$Pt,style:{backgroundColor:l.series.color}})),o&&_.createElement("td",null,l.series.name),_.createElement("td",{dangerouslySetInnerHTML:{__html:l.formattedValue}}));return _.createElement("table",null,_.createElement("thead",null,_.createElement("tr",null,_.createElement("th",{colSpan:i},r))),_.createElement("tbody",null,a.map(s)))};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const YL=t=>{t.style.transitionDuration="",Array.from(t.classList).forEach(r=>{r.startsWith("k-slide-")&&t.classList.remove(r)})},WPt=typeof window<"u"&&/Firefox/.test(window.navigator.userAgent),jPt=(t,r,n,i,o)=>{if(n===0)return o();const a="k-slide-"+r+"-"+i,s=a+"-active",l=g=>{g.target===t&&(t.removeEventListener("transitionend",l),YL(t),i==="exit"?t.style.display="none":t.style.display="",o())};t.addEventListener("transitionend",l);const h=t.ownerDocument;if(!h)return;const p=h.defaultView;if(!p)return;const f=()=>{YL(t),t.classList.add(a),p.requestAnimationFrame(()=>{t.style.transitionDuration=n+"ms",t.classList.add(s)})};WPt?p.requestAnimationFrame(f):f()},T1={bottom:"bottom",center:"center",middle:"middle",left:"left",right:"right",top:"top"};var GPt=function(t){var r=t.anchorRect,n=t.anchorAlign,i=t.elementRect,o=t.elementAlign,a=t.margin;a===void 0&&(a={});var s=n.horizontal,l=n.vertical,h=o.horizontal,p=o.vertical,f=a.horizontal||0,g=a.vertical||0,b=r.top,z=r.left;return l===T1.bottom&&(b+=r.height),(l===T1.center||l===T1.middle)&&(b+=Math.round(r.height/2)),p===T1.bottom&&(b-=i.height,g*=-1),(p===T1.center||p===T1.middle)&&(b-=Math.round(i.height/2),g*=-1),s===T1.right&&(z+=r.width),(s===T1.center||s===T1.middle)&&(z+=Math.round(r.width/2)),h===T1.right&&(z-=i.width,f*=-1),(h===T1.center||h===T1.middle)&&(z-=Math.round(i.width/2),f*=-1),{top:b+g,left:z+f}};function UPt(t,r){return{top:t.top+r.y,left:t.left+r.x,height:t.height,width:t.width}}function WR(t){return t.ownerDocument||t.document||t}var lC=function(t){return WR(t).defaultView},cC=function(t){return WR(t).documentElement},Lv=0;function YPt(){if(!Lv&&typeof document<"u"){var t=document.createElement("div");t.style.cssText="overflow:scroll;overflow-x:hidden;zoom:1;clear:both;display:block",t.innerHTML=" ",document.body.appendChild(t),Lv=t.offsetWidth-t.scrollWidth,document.body.removeChild(t)}return Lv}function jR(t){var r=lC(t),n=cC(t),i={height:r.innerHeight,width:r.innerWidth};return n.scrollHeight-n.clientHeight>0&&(i.width-=YPt()),i}var XPt=function(t){if(!t.getBoundingClientRect){var r=jR(t);return{bottom:r.height,left:0,right:r.width,top:0}}var n=t.getBoundingClientRect(),i=n.bottom,o=n.left,a=n.right,s=n.top;return{bottom:i,left:o,right:a,top:s}},hC=function(t){for(var r=t.offsetParent;r&&r.style.position==="static";)r=r.offsetParent;return r||cC(t)},KPt=function(t){var r=t.style,n=r.display,i=r.left,o=r.position;t.style.display="",t.style.left="-10000px",t.style.position="absolute";var a=t.getBoundingClientRect();return t.style.display=n,t.style.left=i,t.style.position=o,a},b8=function(t){var r=t.getBoundingClientRect(),n=r.left,i=r.top;return!r.height&&!r.width&&(r=KPt(t)),{top:i,left:n,height:r.height,width:r.width}};function GR(t,r){for(var n=[],i=t.parentNode;i&&(n.push(i),i!==r);)i=i.parentNode;return n}function UR(t){var r=cC(t),n=lC(t);return{x:n.pageXOffset||r.scrollLeft||0,y:n.pageYOffset||r.scrollTop||0}}function YR(t){return t===(t.ownerDocument||{}).body?UR(t):{x:t.scrollLeft,y:t.scrollTop}}function qPt(t){var r=hC(t);return r?YR(r):{x:0,y:0}}var ZPt=function(t,r){var n=lC(t),i=n.getComputedStyle(t),o=b8(t),a=r||hC(t),s=t.ownerDocument,l=a!==s.body&&a!==s.documentElement,h={top:0,left:0};if(i.position!=="fixed"&&l){var p=n.getComputedStyle(a);h=b8(a),h.top+=parseInt(p.borderTopWidth,10),h.left+=parseInt(p.borderLeftWidth,10)}return{top:o.top-h.top,left:o.left-h.left,height:o.height,width:o.width}};function JPt(t,r){return t?YR(t):qPt(r)}function QPt(t,r,n){n===void 0&&(n=1);var i=r?hC(r):null,o=ZPt(t,i),a=o.top,s=o.left,l=o.height,h=o.width,p=JPt(i,t),f=p.x,g=p.y,b=t.ownerDocument,z=i===b.body||i===b.documentElement?1:n;return{top:a+g*z,left:s+f*z,height:l,width:h}}function tTt(t,r){return{top:t.top-r.y,left:t.left-r.x,height:t.height,width:t.width}}const L2={fit:"fit",flip:"flip",none:"none"};var XL=function(t,r,n){var i=0;return t+r>n&&(i=n-(t+r)),t<0&&(i=-t),i},KL=function(t){var r=t.offset,n=t.size,i=t.anchorSize,o=t.viewPortSize,a=t.anchorAlignPoint,s=t.elementAlignPoint,l=t.margin,h=0,p=s===T1.center||s===T1.middle,f=a===T1.center||a===T1.middle,g=2*l;if(s!==a&&!p&&!f){var b=a===T1.top||a===T1.left;r<0&&b?(h=n+i+g,r+h+n>o&&(h=0)):r>=0&&!b&&(r+n>o&&(h+=-(i+n+g)),r+h<0&&(h=0))}return h},eTt=function(t){var r=t.anchorRect,n=t.anchorAlign,i=t.elementRect,o=t.elementAlign,a=t.collisions,s=t.viewPort,l=t.margin;l===void 0&&(l={});var h=i.top,p=i.left,f=i.height,g=i.width,b=s.height,z=s.width,M=l.horizontal||0,I=l.vertical||0,F=0,H=0,E=a.vertical===L2.fit,R=a.horizontal===L2.fit,W=a.vertical===L2.flip,$=a.horizontal===L2.flip;E&&(H+=XL(h,f,b)),R&&(F+=XL(p,g,z)),W&&(H+=KL({margin:I,offset:h,size:f,anchorSize:r.height,viewPortSize:b,anchorAlignPoint:n.vertical,elementAlignPoint:o.vertical})),$&&(F+=KL({margin:M,offset:p,size:g,anchorSize:r.width,viewPortSize:z,anchorAlignPoint:n.horizontal,elementAlignPoint:o.horizontal}));var G=W&&H!==0,Z=$&&F!==0,K=E&&H!==0,et=R&&F!==0;return{flipped:Z||G,fitted:K||et,flip:{horizontal:Z,vertical:G},fit:{horizontal:et,vertical:K},offset:{left:F,top:H}}};function rTt(t){for(var r=[],n=t.parentNode.firstElementChild;n;)n!==t&&r.push(n),n=n.nextElementSibling;return r}function iTt(t,r){for(var n=GR(t),i=r,o,a;i&&(o=rTt(i),a=n.reduce(function(s,l){return s.concat(o.filter(function(h){return h===l}))},[])[0],!a);)i=i.parentElement;return a}var nTt=function(t,r){return t||{height:0,left:r.left,top:r.top,width:0}},oTt=function(t,r){return!t||r===1?t:{height:t.height/r,left:t.left/r,top:t.top/r,width:t.width/r}},aTt=function(t,r){if(!r)return t;var n={height:t.height,left:t.left-r.left,top:t.top-r.top,width:t.width};return n};function sTt(t){var r,n=!1;return function(){for(var i=[],o=arguments.length;o--;)i[o]=arguments[o];return n||(r=t.apply(void 0,i),n=!0),r}}var lTt=sTt(function(t){if(!XR())return!1;var r=t?t.ownerDocument:document;if(!r||!r.body)return!1;var n=10,i=r.createElement("div");i.style.transform="matrix(10, 0, 0, 10, 0, 0)",i.innerHTML='
child
',r.body.appendChild(i);var o=i.children[0].getBoundingClientRect().top!==n;return r.body.removeChild(i),o}),XR=function(){return!!(typeof window<"u"&&window.document&&window.document.createElement)},Bn={eitherRect:nTt,scaleRect:oTt,removeStackingOffset:aTt,hasRelativeStackingContext:lTt,canUseDOM:XR},cTt=["font-size","font-family","font-stretch","font-style","font-weight","line-height"],hTt=function(t,r){return{left:t.left+r.left,top:t.top+r.top}},KR=function(){return Bn.canUseDOM()?window:null},uTt=function(t){var r=KR();if(!r||!t)return[];var n=r.getComputedStyle(t);return cTt.map(function(i){return{key:i,value:n[i]}})},pTt=function(t){return t?!!t.offsetParent:!1},dTt=function(t){return t?b8(t):null},fTt=function(t,r){if(!t)return null;var n=t.style,i=n.left,o=n.top,a=n.transition;t.style.transition="none",t.style.left=r.left+"px",t.style.top=r.top+"px";var s=b8(t);return t.style.left=i,t.style.top=o,t.offsetHeight,t.style.transition=a,s},vTt=function(t,r,n){if(!t||!r)return null;var i=n||1;return QPt(t,r,i)},gTt=/auto|scroll/,mTt=function(t){return""+t.style.overflow+t.style.overflowX+t.style.overflowY},yTt=function(t){var r=window.getComputedStyle(t);return""+r.overflow+r.overflowX+r.overflowY},xTt=function(t){return mTt(t)||yTt(t)},bTt=function(t){var r=[];if(!Bn.canUseDOM())return r;for(var n=t.parentElement;n;)(gTt.test(xTt(n))||n.hasAttribute("data-scrollable"))&&r.push(n),n=n.parentElement;return r.push(window),r},u5=function(t){if(!t||!Bn.hasRelativeStackingContext())return null;for(var r=t.parentElement;r;){if(window.getComputedStyle(r).transform!=="none")return r;r=r.parentElement}return null},wTt=function(t){var r=u5(t);return r?b8(r):null},CTt=function(t){var r=u5(t);return r?{x:r.scrollLeft,y:r.scrollTop}:{x:0,y:0}},STt=function(t){var r=u5(t);return r?{height:r.scrollHeight,width:r.scrollWidth}:null},zTt=function(t){return!!u5(t)},qR=function(){return Bn.canUseDOM()&&parseFloat((document.documentElement.clientWidth/window.innerWidth).toFixed(2))||1},MTt=function(){return qR()>1},kTt=function(t,r){if(!t||!Bn.canUseDOM())return null;var n=iTt(t,r);if(!n)return null;var i=[t].concat(GR(t,n)).reduce(function(o,a){var s=a.style.zIndex||window.getComputedStyle(a).zIndex,l=parseInt(s,10);return l>o?l:o},0);return i?i+1:null},Xi={addOffset:hTt,addScroll:UPt,align:GPt,boundingOffset:XPt,getFontStyles:uTt,getWindow:KR,hasOffsetParent:pTt,offset:dTt,offsetAtPoint:fTt,position:vTt,removeScroll:tTt,restrictToView:eTt,scrollPosition:UR,scrollableParents:bTt,getRelativeContextElement:u5,stackingElementOffset:wTt,stackingElementScroll:CTt,stackingElementViewPort:STt,useRelativePosition:zTt,windowViewPort:jR,zoomLevel:qR,isZoomed:MTt,zIndex:kTt},_Tt=function(t,r,n,i){var o=LTt(t,r),a=Bn.eitherRect(Xi.offset(t),n),s=2*i,l=Xi.stackingElementScroll(r);i!==1&&l&&(l.x/=s,l.y/=s);var h=Xi.stackingElementOffset(r);return i!==1&&h&&(h.left/=s,h.top/=s),Xi.removeScroll(Xi.addScroll(Bn.removeStackingOffset(Bn.scaleRect(a,i),h),l),o)},ATt=function(t,r,n,i){var o=Bn.eitherRect(Xi.position(t,r,i),n);return Bn.scaleRect(o,i)},LTt=function(t,r){return t?{x:0,y:0}:Xi.scrollPosition(r)},ETt=function(t){var r=t.anchor,n=t.element,i=t.anchorAlign,o=t.elementAlign,a=t.margin,s=t.offset,l=t.positionMode,h=t.scale,p=h||1,f=l==="fixed"||!Xi.hasOffsetParent(n),g=f?_Tt(r,n,s,p):ATt(r,n,s,p),b=Bn.scaleRect(Xi.offset(n),p),z=Xi.align({anchorAlign:i,anchorRect:g,elementAlign:o,elementRect:b,margin:a});return z},ITt=function(t){var r=t.anchor,n=t.currentLocation,i=t.element,o=t.anchorAlign,a=t.elementAlign,s=t.collisions,l=t.margin,h=t.scale,p=h||1,f=Xi.offsetAtPoint(i,n),g=Bn.scaleRect(f,p),b=Bn.scaleRect(Xi.offset(r),p),z=Bn.eitherRect(b,n),M=t.viewPort||Xi.windowViewPort(i);M.width=M.width/p,M.height=M.height/p;var I=Xi.restrictToView({anchorAlign:o,anchorRect:z,collisions:s,elementAlign:a,elementRect:g,margin:l,viewPort:M}),F=Xi.addOffset(n,I.offset);return{flip:I.flip,flipped:I.flipped,fit:I.fit,fitted:I.fitted,offset:F}};/** + */const XL=t=>{t.style.transitionDuration="",Array.from(t.classList).forEach(r=>{r.startsWith("k-slide-")&&t.classList.remove(r)})},jPt=typeof window<"u"&&/Firefox/.test(window.navigator.userAgent),GPt=(t,r,n,i,o)=>{if(n===0)return o();const a="k-slide-"+r+"-"+i,s=a+"-active",l=g=>{g.target===t&&(t.removeEventListener("transitionend",l),XL(t),i==="exit"?t.style.display="none":t.style.display="",o())};t.addEventListener("transitionend",l);const h=t.ownerDocument;if(!h)return;const p=h.defaultView;if(!p)return;const f=()=>{XL(t),t.classList.add(a),p.requestAnimationFrame(()=>{t.style.transitionDuration=n+"ms",t.classList.add(s)})};jPt?p.requestAnimationFrame(f):f()},D1={bottom:"bottom",center:"center",middle:"middle",left:"left",right:"right",top:"top"};var UPt=function(t){var r=t.anchorRect,n=t.anchorAlign,i=t.elementRect,o=t.elementAlign,a=t.margin;a===void 0&&(a={});var s=n.horizontal,l=n.vertical,h=o.horizontal,p=o.vertical,f=a.horizontal||0,g=a.vertical||0,b=r.top,z=r.left;return l===D1.bottom&&(b+=r.height),(l===D1.center||l===D1.middle)&&(b+=Math.round(r.height/2)),p===D1.bottom&&(b-=i.height,g*=-1),(p===D1.center||p===D1.middle)&&(b-=Math.round(i.height/2),g*=-1),s===D1.right&&(z+=r.width),(s===D1.center||s===D1.middle)&&(z+=Math.round(r.width/2)),h===D1.right&&(z-=i.width,f*=-1),(h===D1.center||h===D1.middle)&&(z-=Math.round(i.width/2),f*=-1),{top:b+g,left:z+f}};function YPt(t,r){return{top:t.top+r.y,left:t.left+r.x,height:t.height,width:t.width}}function jR(t){return t.ownerDocument||t.document||t}var cC=function(t){return jR(t).defaultView},hC=function(t){return jR(t).documentElement},Lv=0;function XPt(){if(!Lv&&typeof document<"u"){var t=document.createElement("div");t.style.cssText="overflow:scroll;overflow-x:hidden;zoom:1;clear:both;display:block",t.innerHTML=" ",document.body.appendChild(t),Lv=t.offsetWidth-t.scrollWidth,document.body.removeChild(t)}return Lv}function GR(t){var r=cC(t),n=hC(t),i={height:r.innerHeight,width:r.innerWidth};return n.scrollHeight-n.clientHeight>0&&(i.width-=XPt()),i}var KPt=function(t){if(!t.getBoundingClientRect){var r=GR(t);return{bottom:r.height,left:0,right:r.width,top:0}}var n=t.getBoundingClientRect(),i=n.bottom,o=n.left,a=n.right,s=n.top;return{bottom:i,left:o,right:a,top:s}},uC=function(t){for(var r=t.offsetParent;r&&r.style.position==="static";)r=r.offsetParent;return r||hC(t)},qPt=function(t){var r=t.style,n=r.display,i=r.left,o=r.position;t.style.display="",t.style.left="-10000px",t.style.position="absolute";var a=t.getBoundingClientRect();return t.style.display=n,t.style.left=i,t.style.position=o,a},b8=function(t){var r=t.getBoundingClientRect(),n=r.left,i=r.top;return!r.height&&!r.width&&(r=qPt(t)),{top:i,left:n,height:r.height,width:r.width}};function UR(t,r){for(var n=[],i=t.parentNode;i&&(n.push(i),i!==r);)i=i.parentNode;return n}function YR(t){var r=hC(t),n=cC(t);return{x:n.pageXOffset||r.scrollLeft||0,y:n.pageYOffset||r.scrollTop||0}}function XR(t){return t===(t.ownerDocument||{}).body?YR(t):{x:t.scrollLeft,y:t.scrollTop}}function ZPt(t){var r=uC(t);return r?XR(r):{x:0,y:0}}var JPt=function(t,r){var n=cC(t),i=n.getComputedStyle(t),o=b8(t),a=r||uC(t),s=t.ownerDocument,l=a!==s.body&&a!==s.documentElement,h={top:0,left:0};if(i.position!=="fixed"&&l){var p=n.getComputedStyle(a);h=b8(a),h.top+=parseInt(p.borderTopWidth,10),h.left+=parseInt(p.borderLeftWidth,10)}return{top:o.top-h.top,left:o.left-h.left,height:o.height,width:o.width}};function QPt(t,r){return t?XR(t):ZPt(r)}function tTt(t,r,n){n===void 0&&(n=1);var i=r?uC(r):null,o=JPt(t,i),a=o.top,s=o.left,l=o.height,h=o.width,p=QPt(i,t),f=p.x,g=p.y,b=t.ownerDocument,z=i===b.body||i===b.documentElement?1:n;return{top:a+g*z,left:s+f*z,height:l,width:h}}function eTt(t,r){return{top:t.top-r.y,left:t.left-r.x,height:t.height,width:t.width}}const M2={fit:"fit",flip:"flip",none:"none"};var KL=function(t,r,n){var i=0;return t+r>n&&(i=n-(t+r)),t<0&&(i=-t),i},qL=function(t){var r=t.offset,n=t.size,i=t.anchorSize,o=t.viewPortSize,a=t.anchorAlignPoint,s=t.elementAlignPoint,l=t.margin,h=0,p=s===D1.center||s===D1.middle,f=a===D1.center||a===D1.middle,g=2*l;if(s!==a&&!p&&!f){var b=a===D1.top||a===D1.left;r<0&&b?(h=n+i+g,r+h+n>o&&(h=0)):r>=0&&!b&&(r+n>o&&(h+=-(i+n+g)),r+h<0&&(h=0))}return h},rTt=function(t){var r=t.anchorRect,n=t.anchorAlign,i=t.elementRect,o=t.elementAlign,a=t.collisions,s=t.viewPort,l=t.margin;l===void 0&&(l={});var h=i.top,p=i.left,f=i.height,g=i.width,b=s.height,z=s.width,M=l.horizontal||0,I=l.vertical||0,F=0,H=0,E=a.vertical===M2.fit,R=a.horizontal===M2.fit,W=a.vertical===M2.flip,$=a.horizontal===M2.flip;E&&(H+=KL(h,f,b)),R&&(F+=KL(p,g,z)),W&&(H+=qL({margin:I,offset:h,size:f,anchorSize:r.height,viewPortSize:b,anchorAlignPoint:n.vertical,elementAlignPoint:o.vertical})),$&&(F+=qL({margin:M,offset:p,size:g,anchorSize:r.width,viewPortSize:z,anchorAlignPoint:n.horizontal,elementAlignPoint:o.horizontal}));var G=W&&H!==0,Z=$&&F!==0,K=E&&H!==0,et=R&&F!==0;return{flipped:Z||G,fitted:K||et,flip:{horizontal:Z,vertical:G},fit:{horizontal:et,vertical:K},offset:{left:F,top:H}}};function iTt(t){for(var r=[],n=t.parentNode.firstElementChild;n;)n!==t&&r.push(n),n=n.nextElementSibling;return r}function nTt(t,r){for(var n=UR(t),i=r,o,a;i&&(o=iTt(i),a=n.reduce(function(s,l){return s.concat(o.filter(function(h){return h===l}))},[])[0],!a);)i=i.parentElement;return a}var oTt=function(t,r){return t||{height:0,left:r.left,top:r.top,width:0}},aTt=function(t,r){return!t||r===1?t:{height:t.height/r,left:t.left/r,top:t.top/r,width:t.width/r}},sTt=function(t,r){if(!r)return t;var n={height:t.height,left:t.left-r.left,top:t.top-r.top,width:t.width};return n};function lTt(t){var r,n=!1;return function(){for(var i=[],o=arguments.length;o--;)i[o]=arguments[o];return n||(r=t.apply(void 0,i),n=!0),r}}var cTt=lTt(function(t){if(!KR())return!1;var r=t?t.ownerDocument:document;if(!r||!r.body)return!1;var n=10,i=r.createElement("div");i.style.transform="matrix(10, 0, 0, 10, 0, 0)",i.innerHTML='
child
',r.body.appendChild(i);var o=i.children[0].getBoundingClientRect().top!==n;return r.body.removeChild(i),o}),KR=function(){return!!(typeof window<"u"&&window.document&&window.document.createElement)},Rn={eitherRect:oTt,scaleRect:aTt,removeStackingOffset:sTt,hasRelativeStackingContext:cTt,canUseDOM:KR},hTt=["font-size","font-family","font-stretch","font-style","font-weight","line-height"],uTt=function(t,r){return{left:t.left+r.left,top:t.top+r.top}},qR=function(){return Rn.canUseDOM()?window:null},pTt=function(t){var r=qR();if(!r||!t)return[];var n=r.getComputedStyle(t);return hTt.map(function(i){return{key:i,value:n[i]}})},dTt=function(t){return t?!!t.offsetParent:!1},fTt=function(t){return t?b8(t):null},vTt=function(t,r){if(!t)return null;var n=t.style,i=n.left,o=n.top,a=n.transition;t.style.transition="none",t.style.left=r.left+"px",t.style.top=r.top+"px";var s=b8(t);return t.style.left=i,t.style.top=o,t.offsetHeight,t.style.transition=a,s},gTt=function(t,r,n){if(!t||!r)return null;var i=n||1;return tTt(t,r,i)},mTt=/auto|scroll/,yTt=function(t){return""+t.style.overflow+t.style.overflowX+t.style.overflowY},xTt=function(t){var r=window.getComputedStyle(t);return""+r.overflow+r.overflowX+r.overflowY},bTt=function(t){return yTt(t)||xTt(t)},wTt=function(t){var r=[];if(!Rn.canUseDOM())return r;for(var n=t.parentElement;n;)(mTt.test(bTt(n))||n.hasAttribute("data-scrollable"))&&r.push(n),n=n.parentElement;return r.push(window),r},u5=function(t){if(!t||!Rn.hasRelativeStackingContext())return null;for(var r=t.parentElement;r;){if(window.getComputedStyle(r).transform!=="none")return r;r=r.parentElement}return null},CTt=function(t){var r=u5(t);return r?b8(r):null},STt=function(t){var r=u5(t);return r?{x:r.scrollLeft,y:r.scrollTop}:{x:0,y:0}},zTt=function(t){var r=u5(t);return r?{height:r.scrollHeight,width:r.scrollWidth}:null},MTt=function(t){return!!u5(t)},ZR=function(){return Rn.canUseDOM()&&parseFloat((document.documentElement.clientWidth/window.innerWidth).toFixed(2))||1},kTt=function(){return ZR()>1},_Tt=function(t,r){if(!t||!Rn.canUseDOM())return null;var n=nTt(t,r);if(!n)return null;var i=[t].concat(UR(t,n)).reduce(function(o,a){var s=a.style.zIndex||window.getComputedStyle(a).zIndex,l=parseInt(s,10);return l>o?l:o},0);return i?i+1:null},Ui={addOffset:uTt,addScroll:YPt,align:UPt,boundingOffset:KPt,getFontStyles:pTt,getWindow:qR,hasOffsetParent:dTt,offset:fTt,offsetAtPoint:vTt,position:gTt,removeScroll:eTt,restrictToView:rTt,scrollPosition:YR,scrollableParents:wTt,getRelativeContextElement:u5,stackingElementOffset:CTt,stackingElementScroll:STt,stackingElementViewPort:zTt,useRelativePosition:MTt,windowViewPort:GR,zoomLevel:ZR,isZoomed:kTt,zIndex:_Tt},ATt=function(t,r,n,i){var o=ETt(t,r),a=Rn.eitherRect(Ui.offset(t),n),s=2*i,l=Ui.stackingElementScroll(r);i!==1&&l&&(l.x/=s,l.y/=s);var h=Ui.stackingElementOffset(r);return i!==1&&h&&(h.left/=s,h.top/=s),Ui.removeScroll(Ui.addScroll(Rn.removeStackingOffset(Rn.scaleRect(a,i),h),l),o)},LTt=function(t,r,n,i){var o=Rn.eitherRect(Ui.position(t,r,i),n);return Rn.scaleRect(o,i)},ETt=function(t,r){return t?{x:0,y:0}:Ui.scrollPosition(r)},ITt=function(t){var r=t.anchor,n=t.element,i=t.anchorAlign,o=t.elementAlign,a=t.margin,s=t.offset,l=t.positionMode,h=t.scale,p=h||1,f=l==="fixed"||!Ui.hasOffsetParent(n),g=f?ATt(r,n,s,p):LTt(r,n,s,p),b=Rn.scaleRect(Ui.offset(n),p),z=Ui.align({anchorAlign:i,anchorRect:g,elementAlign:o,elementRect:b,margin:a});return z},HTt=function(t){var r=t.anchor,n=t.currentLocation,i=t.element,o=t.anchorAlign,a=t.elementAlign,s=t.collisions,l=t.margin,h=t.scale,p=h||1,f=Ui.offsetAtPoint(i,n),g=Rn.scaleRect(f,p),b=Rn.scaleRect(Ui.offset(r),p),z=Rn.eitherRect(b,n),M=t.viewPort||Ui.windowViewPort(i);M.width=M.width/p,M.height=M.height/p;var I=Ui.restrictToView({anchorAlign:o,anchorRect:z,collisions:s,elementAlign:a,elementRect:g,margin:l,viewPort:M}),F=Ui.addOffset(n,I.offset);return{flip:I.flip,flipped:I.flipped,fit:I.fit,fitted:I.fitted,offset:F}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const HTt=16.666666666666668,DTt=function(t,r,n={}){let i,o,a,s,l=0;n=n||{};const h=function(){l=n.leading===!1?0:new Date().getTime(),i=void 0,s=t.apply(o,a),i||(o=a=null)};return function(){const p=new Date().getTime();!l&&n.leading===!1&&(l=p);const f=r-(p-l);return o=void 0,a=arguments,f<=0||f>r?(i&&(clearTimeout(i),i=void 0),l=p,s=t.apply(o,a),i||(o=a=null)):!i&&n.trailing!==!1&&(i=window.setTimeout(h,f)),s}};/** + */const DTt=16.666666666666668,PTt=function(t,r,n={}){let i,o,a,s,l=0;n=n||{};const h=function(){l=n.leading===!1?0:new Date().getTime(),i=void 0,s=t.apply(o,a),i||(o=a=null)};return function(){const p=new Date().getTime();!l&&n.leading===!1&&(l=p);const f=r-(p-l);return o=void 0,a=arguments,f<=0||f>r?(i&&(clearTimeout(i),i=void 0),l=p,s=t.apply(o,a),i||(o=a=null)):!i&&n.trailing!==!1&&(i=window.setTimeout(h,f)),s}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const PTt={name:"@progress/kendo-react-popup",productName:"KendoReact",productCodes:["KENDOUIREACT","KENDOUICOMPLETE"],publishDate:1722843798,version:"",licensingDocsUrl:"https://www.telerik.com/kendo-react-ui/components/my-license/"};/** + */const TTt={name:"@progress/kendo-react-popup",productName:"KendoReact",productCodes:["KENDOUIREACT","KENDOUICOMPLETE"],publishDate:1722843798,version:"",licensingDocsUrl:"https://www.telerik.com/kendo-react-ui/components/my-license/"};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const TTt=100,VTt=1;function x3(t,r){if(t===r)return!0;if(!!t!=!!r)return!1;const n=Object.getOwnPropertyNames(t),i=Object.getOwnPropertyNames(r);if(n.length!==i.length)return!1;for(let o=0;o{this.setPosition(n),this.animate(n.firstChild,"enter",this.onOpened),this.setState({current:"shown",previous:this.state.current})},this.setPosition=n=>{let{anchorAlign:i,popupAlign:o,collision:a,offset:s,anchor:l,margin:h,scale:p,positionMode:f}=this.props;const{width:g,height:b}=n.style;n.style.width=n.offsetWidth+"px",n.style.height=n.offsetHeight+"px";const z=ETt({anchor:l,anchorAlign:i,element:n,elementAlign:o,offset:s,margin:h,positionMode:f,scale:p}),M=ITt({anchor:l,anchorAlign:i,element:n,elementAlign:o,collisions:a,currentLocation:z,margin:this.props.margin});if(n.style.top=M.offset.top+"px",n.style.left=M.offset.left+"px",n.style.width=g,n.style.height=b,this._collisions={fit:M.fit,fitted:M.fitted,flip:M.flip,flipped:M.flipped},this.props.onPosition){const I={target:this,flipped:M.flipped,fitted:M.fitted};this.props.onPosition.call(void 0,I)}},this.onOpened=()=>{const n=this._popup;n&&(this.props.show&&n.classList.add(qL),this.attachRepositionHandlers(n),this.props.onOpen&&this.props.onOpen.call(void 0,{target:this}))},this.animate=(n,i,o)=>{if(!this.props.popupAlign)return;let a;const{horizontal:s,vertical:l}=this.props.popupAlign;s==="left"&&l==="center"?a="right":s==="right"&&l==="center"?a="left":l==="top"?a="down":a="up";const h={down:"up",up:"down",left:"right",right:"left"};this._collisions&&this._collisions.flipped&&(a=h[a]),jPt(n,a,this.animationDuration[i],i,o)},this.onClosing=n=>{this.props.show||n.classList.remove(qL),this.detachRepositionHandlers()},this.onClosed=()=>{this.state.current==="hiding"&&this.state.previous==="shown"&&this.setState({current:"hidden",previous:this.state.current}),this.props.onClose&&this.props.onClose.call(void 0,{target:this})},this.getCurrentZIndex=()=>this.context?this.context+VTt:TTt,gi(PTt),this.reposition=DTt(this.reposition.bind(this),HTt)}get element(){return this._popup}static getDerivedStateFromProps(r,n){const{show:i,anchor:o,anchorAlign:a,appendTo:s,collision:l,popupAlign:h,className:p,popupClass:f,style:g,offset:b,contentKey:z}=r,M={...n,props:{show:i,anchor:o,anchorAlign:a,appendTo:s,collision:l,popupAlign:h,className:p,popupClass:f,style:g,offset:b,contentKey:z}};return r.show?n.current==="hidden"||n.current==="hiding"?{...M,current:"showing",previous:n.current}:n.current==="showing"?{...M,current:"shown",previous:n.current}:n.current==="shown"&&(!x3(b,n.props.offset)||!x3(a,n.props.anchorAlign)||!x3(s,n.props.appendTo)||!x3(l,n.props.collision)||!x3(h,n.props.popupAlign)||!x3(g,n.props.style)||o!==n.props.anchor||f!==n.props.popupClass||p!==n.props.className)?{...M,current:"reposition",previous:n.current}:M:n.current==="hiding"||n.current==="hidden"?{...M,current:"hidden",previous:n.current}:{...M,current:"hiding",previous:n.current}}componentDidUpdate(r){this.state.current==="showing"&&this._popup?this.show(this._popup):this.state.current==="hiding"&&this._popup?(this.onClosing(this._popup),this.animate(this._popup.firstChild,"exit",this.onClosed)):this.state.current==="reposition"&&this.state.previous==="shown"?setTimeout(()=>{this.setState({current:"shown",previous:this.state.current})},0):this.state.current==="shown"&&r.contentKey!==this.props.contentKey&&this._popup&&this.setPosition(this._popup)}componentDidMount(){this.state.current==="showing"&&this._popup&&this.show(this._popup)}componentWillUnmount(){this.detachRepositionHandlers()}render(){const{children:r,className:n,popupClass:i,show:o,id:a,positionMode:s}=this.props,l=this.props.appendTo?this.props.appendTo:ai?this.props.anchor&&this.props.anchor.ownerDocument?this.props.anchor.ownerDocument.body:document.body:void 0;this.state.current==="reposition"&&this.state.previous==="shown"&&this._popup&&this.setPosition(this._popup);const h=Object.assign({},{position:s,top:0,left:-1e4},this.props.style||{}),p=this.state.current==="hiding";if((o||p)&&l){const f=this.getCurrentZIndex(),g=_.createElement(pb.Provider,{value:f},_.createElement("div",{onKeyDown:this.props.onKeyDown,className:Me(RTt,n),id:a,ref:b=>this._popup=b,style:{zIndex:f,...h}},_.createElement("div",{className:Me(OTt),style:{transitionDelay:"0ms"}},_.createElement("div",{role:this.props.role,className:Me(BTt,i)},r))));return this.props.appendTo!==null?Xa.createPortal(g,l):g}return null}get animationDuration(){const r=this.props.animate;let n=0,i=0;return r&&(r===!0?n=i=300:(n=r.openDuration||0,i=r.closeDuration||0)),{enter:n,exit:i}}attachRepositionHandlers(r){this.detachRepositionHandlers(),this._scrollableParents=Xi.scrollableParents(this.props.anchor||r),this._scrollableParents&&this._scrollableParents.map(n=>n.addEventListener("scroll",this.reposition)),window.addEventListener("resize",this.reposition)}detachRepositionHandlers(){this._scrollableParents&&(this._scrollableParents.map(r=>r.removeEventListener("scroll",this.reposition)),this._scrollableParents=void 0),window.removeEventListener("resize",this.reposition)}reposition(){this.setState({current:"reposition",previous:this.state.current})}};uc.propTypes={anchor:function(t){const r=t.anchor;return r&&typeof r.nodeType!="number"?new Error("Invalid prop `anchor` supplied to `Kendo React Popup`. Validation failed."):null},appendTo:function(t){const r=t.appendTo;return r&&typeof r.nodeType!="number"?new Error("Invalid prop `appendTo` supplied to `Kendo React Popup`. Validation failed."):null},className:B.oneOfType([B.string,B.arrayOf(B.string),B.object]),id:B.string,popupClass:B.oneOfType([B.string,B.arrayOf(B.string),B.object]),collision:B.shape({horizontal:B.oneOf([L2.fit,L2.flip,L2.none]),vertical:B.oneOf([L2.fit,L2.flip,L2.none])}),anchorAlign:B.shape({horizontal:B.oneOf([T1.left,T1.center,T1.right]),vertical:B.oneOf([T1.top,T1.center,T1.bottom])}),popupAlign:B.shape({horizontal:B.oneOf([T1.left,T1.center,T1.right]),vertical:B.oneOf([T1.top,T1.center,T1.bottom])}),offset:B.shape({left:B.number,top:B.number}),children:B.oneOfType([B.element,B.node]),show:B.bool,animate:B.oneOfType([B.bool,B.shape({openDuration:B.number,closeDuration:B.number})]),margin:B.shape({horizontal:B.number,vertical:B.number}),positionMode:B.oneOf(["fixed","absolute"]),scale:B.number,style:B.object,onClose:B.func,onPosition:B.func,onOpen:B.func,onKeyPress:B.func},uc.defaultProps={collision:{horizontal:L2.fit,vertical:L2.flip},anchorAlign:{horizontal:T1.left,vertical:T1.bottom},popupAlign:{horizontal:T1.left,vertical:T1.top},offset:FTt,animate:!0,show:!1,margin:{horizontal:0,vertical:0},positionMode:"absolute"},uc.contextType=pb,uc.displayName="PopupComponent";let NTt=uc;/** + */const VTt=100,FTt=1;function x3(t,r){if(t===r)return!0;if(!!t!=!!r)return!1;const n=Object.getOwnPropertyNames(t),i=Object.getOwnPropertyNames(r);if(n.length!==i.length)return!1;for(let o=0;o{this.setPosition(n),this.animate(n.firstChild,"enter",this.onOpened),this.setState({current:"shown",previous:this.state.current})},this.setPosition=n=>{let{anchorAlign:i,popupAlign:o,collision:a,offset:s,anchor:l,margin:h,scale:p,positionMode:f}=this.props;const{width:g,height:b}=n.style;n.style.width=n.offsetWidth+"px",n.style.height=n.offsetHeight+"px";const z=ITt({anchor:l,anchorAlign:i,element:n,elementAlign:o,offset:s,margin:h,positionMode:f,scale:p}),M=HTt({anchor:l,anchorAlign:i,element:n,elementAlign:o,collisions:a,currentLocation:z,margin:this.props.margin});if(n.style.top=M.offset.top+"px",n.style.left=M.offset.left+"px",n.style.width=g,n.style.height=b,this._collisions={fit:M.fit,fitted:M.fitted,flip:M.flip,flipped:M.flipped},this.props.onPosition){const I={target:this,flipped:M.flipped,fitted:M.fitted};this.props.onPosition.call(void 0,I)}},this.onOpened=()=>{const n=this._popup;n&&(this.props.show&&n.classList.add(ZL),this.attachRepositionHandlers(n),this.props.onOpen&&this.props.onOpen.call(void 0,{target:this}))},this.animate=(n,i,o)=>{if(!this.props.popupAlign)return;let a;const{horizontal:s,vertical:l}=this.props.popupAlign;s==="left"&&l==="center"?a="right":s==="right"&&l==="center"?a="left":l==="top"?a="down":a="up";const h={down:"up",up:"down",left:"right",right:"left"};this._collisions&&this._collisions.flipped&&(a=h[a]),GPt(n,a,this.animationDuration[i],i,o)},this.onClosing=n=>{this.props.show||n.classList.remove(ZL),this.detachRepositionHandlers()},this.onClosed=()=>{this.state.current==="hiding"&&this.state.previous==="shown"&&this.setState({current:"hidden",previous:this.state.current}),this.props.onClose&&this.props.onClose.call(void 0,{target:this})},this.getCurrentZIndex=()=>this.context?this.context+FTt:VTt,vi(TTt),this.reposition=PTt(this.reposition.bind(this),DTt)}get element(){return this._popup}static getDerivedStateFromProps(r,n){const{show:i,anchor:o,anchorAlign:a,appendTo:s,collision:l,popupAlign:h,className:p,popupClass:f,style:g,offset:b,contentKey:z}=r,M={...n,props:{show:i,anchor:o,anchorAlign:a,appendTo:s,collision:l,popupAlign:h,className:p,popupClass:f,style:g,offset:b,contentKey:z}};return r.show?n.current==="hidden"||n.current==="hiding"?{...M,current:"showing",previous:n.current}:n.current==="showing"?{...M,current:"shown",previous:n.current}:n.current==="shown"&&(!x3(b,n.props.offset)||!x3(a,n.props.anchorAlign)||!x3(s,n.props.appendTo)||!x3(l,n.props.collision)||!x3(h,n.props.popupAlign)||!x3(g,n.props.style)||o!==n.props.anchor||f!==n.props.popupClass||p!==n.props.className)?{...M,current:"reposition",previous:n.current}:M:n.current==="hiding"||n.current==="hidden"?{...M,current:"hidden",previous:n.current}:{...M,current:"hiding",previous:n.current}}componentDidUpdate(r){this.state.current==="showing"&&this._popup?this.show(this._popup):this.state.current==="hiding"&&this._popup?(this.onClosing(this._popup),this.animate(this._popup.firstChild,"exit",this.onClosed)):this.state.current==="reposition"&&this.state.previous==="shown"?setTimeout(()=>{this.setState({current:"shown",previous:this.state.current})},0):this.state.current==="shown"&&r.contentKey!==this.props.contentKey&&this._popup&&this.setPosition(this._popup)}componentDidMount(){this.state.current==="showing"&&this._popup&&this.show(this._popup)}componentWillUnmount(){this.detachRepositionHandlers()}render(){const{children:r,className:n,popupClass:i,show:o,id:a,positionMode:s}=this.props,l=this.props.appendTo?this.props.appendTo:oi?this.props.anchor&&this.props.anchor.ownerDocument?this.props.anchor.ownerDocument.body:document.body:void 0;this.state.current==="reposition"&&this.state.previous==="shown"&&this._popup&&this.setPosition(this._popup);const h=Object.assign({},{position:s,top:0,left:-1e4},this.props.style||{}),p=this.state.current==="hiding";if((o||p)&&l){const f=this.getCurrentZIndex(),g=_.createElement(db.Provider,{value:f},_.createElement("div",{onKeyDown:this.props.onKeyDown,className:ke(OTt,n),id:a,ref:b=>this._popup=b,style:{zIndex:f,...h}},_.createElement("div",{className:ke(BTt),style:{transitionDelay:"0ms"}},_.createElement("div",{role:this.props.role,className:ke(NTt,i)},r))));return this.props.appendTo!==null?Ya.createPortal(g,l):g}return null}get animationDuration(){const r=this.props.animate;let n=0,i=0;return r&&(r===!0?n=i=300:(n=r.openDuration||0,i=r.closeDuration||0)),{enter:n,exit:i}}attachRepositionHandlers(r){this.detachRepositionHandlers(),this._scrollableParents=Ui.scrollableParents(this.props.anchor||r),this._scrollableParents&&this._scrollableParents.map(n=>n.addEventListener("scroll",this.reposition)),window.addEventListener("resize",this.reposition)}detachRepositionHandlers(){this._scrollableParents&&(this._scrollableParents.map(r=>r.removeEventListener("scroll",this.reposition)),this._scrollableParents=void 0),window.removeEventListener("resize",this.reposition)}reposition(){this.setState({current:"reposition",previous:this.state.current})}};uc.propTypes={anchor:function(t){const r=t.anchor;return r&&typeof r.nodeType!="number"?new Error("Invalid prop `anchor` supplied to `Kendo React Popup`. Validation failed."):null},appendTo:function(t){const r=t.appendTo;return r&&typeof r.nodeType!="number"?new Error("Invalid prop `appendTo` supplied to `Kendo React Popup`. Validation failed."):null},className:B.oneOfType([B.string,B.arrayOf(B.string),B.object]),id:B.string,popupClass:B.oneOfType([B.string,B.arrayOf(B.string),B.object]),collision:B.shape({horizontal:B.oneOf([M2.fit,M2.flip,M2.none]),vertical:B.oneOf([M2.fit,M2.flip,M2.none])}),anchorAlign:B.shape({horizontal:B.oneOf([D1.left,D1.center,D1.right]),vertical:B.oneOf([D1.top,D1.center,D1.bottom])}),popupAlign:B.shape({horizontal:B.oneOf([D1.left,D1.center,D1.right]),vertical:B.oneOf([D1.top,D1.center,D1.bottom])}),offset:B.shape({left:B.number,top:B.number}),children:B.oneOfType([B.element,B.node]),show:B.bool,animate:B.oneOfType([B.bool,B.shape({openDuration:B.number,closeDuration:B.number})]),margin:B.shape({horizontal:B.number,vertical:B.number}),positionMode:B.oneOf(["fixed","absolute"]),scale:B.number,style:B.object,onClose:B.func,onPosition:B.func,onOpen:B.func,onKeyPress:B.func},uc.defaultProps={collision:{horizontal:M2.fit,vertical:M2.flip},anchorAlign:{horizontal:D1.left,vertical:D1.bottom},popupAlign:{horizontal:D1.left,vertical:D1.top},offset:RTt,animate:!0,show:!1,margin:{horizontal:0,vertical:0},positionMode:"absolute"},uc.contextType=db,uc.displayName="PopupComponent";let $Tt=uc;/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const $Tt=_.createContext(t=>t),A4=_.forwardRef((t,r)=>{const n=_.useContext($Tt).call(void 0,t);return _.createElement(NTt,{ref:r,...n})});A4.displayName="Popup";/** + */const WTt=_.createContext(t=>t),A4=_.forwardRef((t,r)=>{const n=_.useContext(WTt).call(void 0,t);return _.createElement($Tt,{ref:r,...n})});A4.displayName="Popup";/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const sa=_.createContext(null);sa.displayName="ChartContext";/** + */const oa=_.createContext(null);oa.displayName="ChartContext";/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const WTt={horizontal:"fit",vertical:"fit"},jTt="k-chart-tooltip",GTt="k-chart-tooltip-wrapper",ZR=class extends _.Component{constructor(r,n){super(r,n),this.context=null,this.element=null,this.onChartMouseLeave=i=>{const{syntheticEvent:o}=i;return!!OR(o.relatedTarget,this.element)},this.onMouseLeave=i=>{const o=NR(this,i);this.context.childrenObserver.trigger("onMouseLeave",o)&&i.preventDefault()},this.popupRef=i=>{this.element=i;const o=i&&i.closest(".k-animation-container");o&&(o.style.transition="initial")},this.chartObserver=new yo(this,{onMouseLeave:"onChartMouseLeave"}),n.observersStore.dispatch({type:"add",payload:this.chartObserver})}render(){const{popupShown:r,popupAlign:n,popupOffset:i,popupStyles:o,popupContent:a,className:s}=this.props,l=[jTt,s].join(" ").trim();return _.createElement(A4,{animate:!1,popupAlign:n,offset:i,show:r,collision:WTt,className:GTt},_.createElement("div",{className:l,style:o,onMouseLeave:this.onMouseLeave,ref:this.popupRef},a()))}componentWillUnmount(){this.context.observersStore.dispatch({type:"remove",payload:this.chartObserver})}};ZR.contextType=sa;let JR=ZR;/** + */const jTt={horizontal:"fit",vertical:"fit"},GTt="k-chart-tooltip",UTt="k-chart-tooltip-wrapper",JR=class extends _.Component{constructor(r,n){super(r,n),this.context=null,this.element=null,this.onChartMouseLeave=i=>{const{syntheticEvent:o}=i;return!!BR(o.relatedTarget,this.element)},this.onMouseLeave=i=>{const o=$R(this,i);this.context.childrenObserver.trigger("onMouseLeave",o)&&i.preventDefault()},this.popupRef=i=>{this.element=i;const o=i&&i.closest(".k-animation-container");o&&(o.style.transition="initial")},this.chartObserver=new fo(this,{onMouseLeave:"onChartMouseLeave"}),n.observersStore.dispatch({type:"add",payload:this.chartObserver})}render(){const{popupShown:r,popupAlign:n,popupOffset:i,popupStyles:o,popupContent:a,className:s}=this.props,l=[GTt,s].join(" ").trim();return _.createElement(A4,{animate:!1,popupAlign:n,offset:i,show:r,collision:jTt,className:UTt},_.createElement("div",{className:l,style:o,onMouseLeave:this.onMouseLeave,ref:this.popupRef},a()))}componentWillUnmount(){this.context.observersStore.dispatch({type:"remove",payload:this.chartObserver})}};JR.contextType=oa;let QR=JR;/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const UTt="k-chart-shared-tooltip",YTt="k-chart-tooltip-inverse",QR=class extends _.Component{constructor(){super(...arguments),this.context=null,this.state={popupShown:!1},this.chartObserver=null}componentDidMount(){this.chartObserver=new yo(this,{showTooltip:"onShowTooltip",hideTooltip:"onHideTooltip"}),this.context.observersStore.dispatch({type:"add",payload:this.chartObserver})}render(){const{popupContext:r,shared:n,className:i,...o}=this.state,a=this.state.popupShown?()=>{const l=this.findRenderFunction();if(n)return l!==null?l(r):_.createElement($Pt,{...r});{const h=r.point,p=this.findRenderFunctionByIndex(h.series.index);return p!==null?p(r):l!==null?l(r):_.createElement("span",{dangerouslySetInnerHTML:{__html:r.point.formattedValue}})}}:Function.prototype,s=Me({[UTt]:n,[YTt]:!!i});return _.createElement(JR,{...o,popupContent:a,className:s})}componentWillUnmount(){this.context.observersStore.dispatch({type:"remove",payload:this.chartObserver})}onShowTooltip(r){const{anchor:n,style:i,shared:o,className:a,crosshair:s}=r;let l;s||(o?l=this.createSharedTooltipContext(r):l=this.createTooltipContext(r),this.setState({popupShown:!0,popupAlign:n.align,popupOffset:n.point,popupContext:l,popupStyles:i,className:a,shared:o}))}onHideTooltip(){this.setState({popupShown:!1,popupStyles:{},className:void 0})}createSharedTooltipContext(r){const{points:n,categoryText:i}=r,o=n.filter(l=>typeof l.series.name<"u").length>0,a=r.series.length>1;let s=1;return o&&s++,a&&s++,{categoryText:i,colorMarker:a,colspan:s,nameColumn:o,points:r.points.map(l=>new UL(l,r.format))}}createTooltipContext(r){const{point:n,format:i}=r;return{point:new UL(n,i)}}findRenderFunctionByIndex(r){const n=this.context.optionsStore.getState().series;return n!==void 0&&Array.isArray(n)&&n[r]!==void 0&&n[r].hasOwnProperty("tooltip")&&n[r].tooltip.hasOwnProperty("render")?n[r].tooltip.render:null}findRenderFunction(){const r=this.context.optionsStore.getState().tooltip;return r!==void 0&&r.hasOwnProperty("render")?r.render:null}};QR.contextType=sa;let XTt=QR;/** + */const YTt="k-chart-shared-tooltip",XTt="k-chart-tooltip-inverse",tO=class extends _.Component{constructor(){super(...arguments),this.context=null,this.state={popupShown:!1},this.chartObserver=null}componentDidMount(){this.chartObserver=new fo(this,{showTooltip:"onShowTooltip",hideTooltip:"onHideTooltip"}),this.context.observersStore.dispatch({type:"add",payload:this.chartObserver})}render(){const{popupContext:r,shared:n,className:i,...o}=this.state,a=this.state.popupShown?()=>{const l=this.findRenderFunction();if(n)return l!==null?l(r):_.createElement(WPt,{...r});{const h=r.point,p=this.findRenderFunctionByIndex(h.series.index);return p!==null?p(r):l!==null?l(r):_.createElement("span",{dangerouslySetInnerHTML:{__html:r.point.formattedValue}})}}:Function.prototype,s=ke({[YTt]:n,[XTt]:!!i});return _.createElement(QR,{...o,popupContent:a,className:s})}componentWillUnmount(){this.context.observersStore.dispatch({type:"remove",payload:this.chartObserver})}onShowTooltip(r){const{anchor:n,style:i,shared:o,className:a,crosshair:s}=r;let l;s||(o?l=this.createSharedTooltipContext(r):l=this.createTooltipContext(r),this.setState({popupShown:!0,popupAlign:n.align,popupOffset:n.point,popupContext:l,popupStyles:i,className:a,shared:o}))}onHideTooltip(){this.setState({popupShown:!1,popupStyles:{},className:void 0})}createSharedTooltipContext(r){const{points:n,categoryText:i}=r,o=n.filter(l=>typeof l.series.name<"u").length>0,a=r.series.length>1;let s=1;return o&&s++,a&&s++,{categoryText:i,colorMarker:a,colspan:s,nameColumn:o,points:r.points.map(l=>new YL(l,r.format))}}createTooltipContext(r){const{point:n,format:i}=r;return{point:new YL(n,i)}}findRenderFunctionByIndex(r){const n=this.context.optionsStore.getState().series;return n!==void 0&&Array.isArray(n)&&n[r]!==void 0&&n[r].hasOwnProperty("tooltip")&&n[r].tooltip.hasOwnProperty("render")?n[r].tooltip.render:null}findRenderFunction(){const r=this.context.optionsStore.getState().tooltip;return r!==void 0&&r.hasOwnProperty("render")?r.render:null}};tO.contextType=oa;let KTt=tO;/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const tO=t=>t.children;tO.displayName="Container";/** + */const eO=t=>t.children;eO.displayName="Container";/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const KTt="k-chart-crosshair-tooltip",qTt="k-chart-tooltip-inverse",eO=class extends _.Component{constructor(r,n){super(r,n),this.context=null,this.state={popupShown:!1},this.chartObserver=new yo(this,{showTooltip:"onShowTooltip",hideTooltip:"onHideTooltip"}),n.observersStore.dispatch({type:"add",payload:this.chartObserver})}render(){const{popupContend:r,className:n,...i}=this.state,o=this.state.popupShown?()=>r:Function.prototype,a=Me({[KTt]:!0,[qTt]:!!n});return _.createElement(JR,{...i,popupContent:o,className:a})}componentWillUnmount(){var r;(r=this.context)==null||r.observersStore.dispatch({type:"remove",payload:this.chartObserver})}onShowTooltip(r){const{anchor:n,style:i,className:o,crosshair:a,axisName:s,axisIndex:l,value:h}=r,{name:p,index:f}=this.props;a&&s===p&&l===f&&this.setState({popupShown:!0,popupAlign:n.align,popupOffset:n.point,popupContend:h,popupStyles:i,className:o})}onHideTooltip(){this.setState({popupShown:!1,popupStyles:{},className:void 0})}};eO.contextType=sa;let ZTt=eO;/** + */const qTt="k-chart-crosshair-tooltip",ZTt="k-chart-tooltip-inverse",rO=class extends _.Component{constructor(r,n){super(r,n),this.context=null,this.state={popupShown:!1},this.chartObserver=new fo(this,{showTooltip:"onShowTooltip",hideTooltip:"onHideTooltip"}),n.observersStore.dispatch({type:"add",payload:this.chartObserver})}render(){const{popupContend:r,className:n,...i}=this.state,o=this.state.popupShown?()=>r:Function.prototype,a=ke({[qTt]:!0,[ZTt]:!!n});return _.createElement(QR,{...i,popupContent:o,className:a})}componentWillUnmount(){var r;(r=this.context)==null||r.observersStore.dispatch({type:"remove",payload:this.chartObserver})}onShowTooltip(r){const{anchor:n,style:i,className:o,crosshair:a,axisName:s,axisIndex:l,value:h}=r,{name:p,index:f}=this.props;a&&s===p&&l===f&&this.setState({popupShown:!0,popupAlign:n.align,popupOffset:n.point,popupContend:h,popupStyles:i,className:o})}onHideTooltip(){this.setState({popupShown:!1,popupStyles:{},className:void 0})}};rO.contextType=oa;let JTt=rO;/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const ZL=["categoryAxis","valueAxis","xAxis","yAxis"];function JTt(t){const r={};for(let n=0;n{var r;this.setState({tooltips:JTt((r=this.context)==null?void 0:r.optionsStore.getState())})}}componentDidMount(){this.storeUnsubscriber=this.context.optionsStore.subscribe(this.subscriber)}render(){const{tooltips:r}=this.state,n=Object.keys(r).map(i=>_.createElement(ZTt,{...r[i],key:i}));return _.createElement(tO,null,n)}componentWillUnmount(){this.storeUnsubscriber()}};rO.contextType=sa;let tVt=rO;/** + */const JL=["categoryAxis","valueAxis","xAxis","yAxis"];function QTt(t){const r={};for(let n=0;n{var r;this.setState({tooltips:QTt((r=this.context)==null?void 0:r.optionsStore.getState())})}}componentDidMount(){this.storeUnsubscriber=this.context.optionsStore.subscribe(this.subscriber)}render(){const{tooltips:r}=this.state,n=Object.keys(r).map(i=>_.createElement(JTt,{...r[i],key:i}));return _.createElement(eO,null,n)}componentWillUnmount(){this.storeUnsubscriber()}};iO.contextType=oa;let eVt=iO;/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const JL={name:"@progress/kendo-react-charts",productName:"KendoReact",productCodes:["KENDOUIREACT","KENDOUICOMPLETE"],publishDate:1722844145,version:"",licensingDocsUrl:"https://www.telerik.com/kendo-react-ui/components/my-license/"};/** + */const QL={name:"@progress/kendo-react-charts",productName:"KendoReact",productCodes:["KENDOUIREACT","KENDOUICOMPLETE"],publishDate:1722844145,version:"",licensingDocsUrl:"https://www.telerik.com/kendo-react-ui/components/my-license/"};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const Km=class extends _.Component{constructor(r){super(r),this.chartInstance=null,this.surface=null,this._element=null,this.optionsStore={},this.optionsUnsubscriber=Function.prototype,this.themeStore={},this.themeUnsubscriber=Function.prototype,this.observersStore={},this.suppressTransitions=!1,this.showLicenseWatermark=!1,this.onRender=n=>{this.chartInstance!==null&&(this.surface=n.sender.surface,this.trigger("render",n))},this.onDrilldown=n=>{var i;const{series:o}=this.optionsStore.getState(),a=o.find(l=>l.name===n.series.name);if(!a.drilldownSeriesFactory)return!0;const s="onDrilldown";if(this.props.hasOwnProperty(s)){const l={seriesName:a.name,drilldownValue:n.value},h=[...((i=this.props.drilldownState)==null?void 0:i.steps)||[],l],p=this.props.getTarget(),f={...n,currentState:this.props.drilldownState,nextState:{steps:h}},g=new BR(f,p);this.props[s].call(void 0,g)}return!0},this.onLegendItemClick=n=>{if(this.chartInstance!==null)if(this.props.onLegendItemClick)this.trigger("legendItemClick",n);else{const{series:i}=this.optionsStore.getState();if(!i)return;let o={};const{seriesIndex:a,pointIndex:s}=n,l=i[a];if(s===void 0)o=Object.assign({},l,{visible:WL(l.visible)});else{const h=l.pointVisibility=l.pointVisibility||[];h[s]=WL(h[s]),o=Object.assign({},l)}this.optionsStore.dispatch({chartCollectionIdxKey:`series_${a}`,payload:o}),this.suppressTransitions=!0}},this.onWindowResize=()=>{this.chartInstance!==null&&this.chartInstance.resize()},this.onChartMouseLeave=n=>{const i=NR(this,n);this.triggerDomEvent("onMouseLeave",i)?n.preventDefault():this.chartInstance!==null&&this.chartInstance.hideElements()},this.onChildMouseLeave=n=>{const{syntheticEvent:i}=n;return this.chartInstance&&!OR(i.relatedTarget,this.element)&&this.chartInstance.hideElements(),!1},gi(JL),this.showLicenseWatermark=gb(JL),this.optionsStore=T7($R),this.observersStore=T7(BPt),this.childrenObserver=new yo(this,{onMouseLeave:"onChildMouseLeave"}),this.state={optionsStore:this.optionsStore,observersStore:this.observersStore,childrenObserver:this.childrenObserver,drilldownState:{steps:[]}},this.themeStore=T7(OPt),this.chartObserver=new yo(this,{render:"onRender",legendItemClick:"onLegendItemClick",drilldown:"onDrilldown"})}get element(){return this._element}static getDerivedStateFromProps(r,n){return{...n,drilldownState:r.drilldownState||[]}}componentDidMount(){var r;const n=((r=this._element)==null?void 0:r.ownerDocument)||document;FPt(this.themeStore,this.instantiateCoreChart.bind(this),n),this.optionsUnsubscriber=this.optionsStore.subscribe(this.refresh.bind(this)),this.themeUnsubscriber=this.themeStore.subscribe(this.refresh.bind(this)),window.addEventListener("resize",this.onWindowResize)}componentWillUnmount(){this.optionsUnsubscriber(),this.themeUnsubscriber(),this.chartInstance!==null&&(this.chartInstance.destroy(),this.chartInstance=null),window.removeEventListener("resize",this.onWindowResize)}componentDidUpdate(r){const{dir:n,children:i,...o}=this.props;if(this.chartInstance!==null){const a=Ka(this),s=this.chartInstance.chartService,l=a.locale!==s._intlService.locale,h=Object.entries(r).filter(p=>p[0]!=="dir"&&p[0]!=="children").some(p=>{const[f,g]=p;return!(o.hasOwnProperty(f)&&o[f]===g)});l&&(this.chartInstance.chartService._intlService=a,this.chartInstance.chartService.format._intlService=a,h||this.chartInstance.noTransitionsRedraw()),h&&this.refresh(),r.dir!==n&&this.chartInstance.setDirection(this.getDirection(n))}}render(){const{style:r={},className:n,wrapper:i,children:o}=this.props,a=Object.assign({},r,{position:"relative"}),s=_.createElement(i,{className:n,style:a,key:"chartElement"},_.createElement("div",{onMouseLeave:this.onChartMouseLeave,ref:l=>this._element=l,className:"k-chart-surface"},o),_.createElement(_.Fragment,null,this.showLicenseWatermark&&_.createElement(mb,null)));return _.createElement(sa.Provider,{value:this.state},_.createElement(XTt,{key:"seriesTooltip"}),_.createElement(tVt,{key:"crosshairTooltips"}),s)}getDirection(r){return(r!==void 0?r:ai&&window.getComputedStyle(this.element).direction||"ltr")==="rtl"}getChartOptions(){const{renderAs:r,pannable:n,zoomable:i,paneDefaults:o,panes:a,transitions:s,seriesColors:l,seriesDefaults:h,axisDefaults:p,deriveOptionsFromParent:f}=this.props;let g={};return r!==void 0&&(g.renderAs=r),n!==void 0&&(g.pannable=n),i!==void 0&&(g.zoomable=i),o!==void 0&&(g.paneDefaults=o),a!==void 0&&(g.panes=a),s!==void 0&&(g.transitions=s),l!==void 0&&(g.seriesColors=l),h!==void 0&&(g.seriesDefaults=h),p!==void 0&&(g.axisDefaults=p),g=Object.assign(g,this.optionsStore.getState()),f&&(g=f(g)),g}refresh(){if(this.chartInstance!==null){const r=this.themeStore.getState(),n=this.getChartOptions(),i=n.transitions;this.suppressTransitions&&(n.transitions=!1),this.props.onRefresh?this.props.onRefresh.call(void 0,n,r,this.chartInstance):this.chartInstance.setOptions(n,r),this.suppressTransitions&&(n.transitions=i,this.suppressTransitions=!1)}}instantiateCoreChart(){const{dir:r,chartConstructor:n}=this.props,i=this.getChartOptions();this.chartInstance=new n(this.element,i,this.themeStore.getState(),{rtl:this.getDirection(r),intlService:Ka(this),observer:this.chartObserver,sender:this})}trigger(r,n){const i=this.props.getTarget(),o=LPt(r,n,i),a="on"+r.charAt(0).toUpperCase()+r.slice(1),s=this.observersStore.getState();let l=!1;for(let h=0;h{this.chartInstance!==null&&(this.surface=n.sender.surface,this.trigger("render",n))},this.onDrilldown=n=>{var i;const{series:o}=this.optionsStore.getState(),a=o.find(l=>l.name===n.series.name);if(!a.drilldownSeriesFactory)return!0;const s="onDrilldown";if(this.props.hasOwnProperty(s)){const l={seriesName:a.name,drilldownValue:n.value},h=[...((i=this.props.drilldownState)==null?void 0:i.steps)||[],l],p=this.props.getTarget(),f={...n,currentState:this.props.drilldownState,nextState:{steps:h}},g=new NR(f,p);this.props[s].call(void 0,g)}return!0},this.onLegendItemClick=n=>{if(this.chartInstance!==null)if(this.props.onLegendItemClick)this.trigger("legendItemClick",n);else{const{series:i}=this.optionsStore.getState();if(!i)return;let o={};const{seriesIndex:a,pointIndex:s}=n,l=i[a];if(s===void 0)o=Object.assign({},l,{visible:jL(l.visible)});else{const h=l.pointVisibility=l.pointVisibility||[];h[s]=jL(h[s]),o=Object.assign({},l)}this.optionsStore.dispatch({chartCollectionIdxKey:`series_${a}`,payload:o}),this.suppressTransitions=!0}},this.onWindowResize=()=>{this.chartInstance!==null&&this.chartInstance.resize()},this.onChartMouseLeave=n=>{const i=$R(this,n);this.triggerDomEvent("onMouseLeave",i)?n.preventDefault():this.chartInstance!==null&&this.chartInstance.hideElements()},this.onChildMouseLeave=n=>{const{syntheticEvent:i}=n;return this.chartInstance&&!BR(i.relatedTarget,this.element)&&this.chartInstance.hideElements(),!1},vi(QL),this.showLicenseWatermark=mb(QL),this.optionsStore=T7(WR),this.observersStore=T7(NPt),this.childrenObserver=new fo(this,{onMouseLeave:"onChildMouseLeave"}),this.state={optionsStore:this.optionsStore,observersStore:this.observersStore,childrenObserver:this.childrenObserver,drilldownState:{steps:[]}},this.themeStore=T7(BPt),this.chartObserver=new fo(this,{render:"onRender",legendItemClick:"onLegendItemClick",drilldown:"onDrilldown"})}get element(){return this._element}static getDerivedStateFromProps(r,n){return{...n,drilldownState:r.drilldownState||[]}}componentDidMount(){var r;const n=((r=this._element)==null?void 0:r.ownerDocument)||document;RPt(this.themeStore,this.instantiateCoreChart.bind(this),n),this.optionsUnsubscriber=this.optionsStore.subscribe(this.refresh.bind(this)),this.themeUnsubscriber=this.themeStore.subscribe(this.refresh.bind(this)),window.addEventListener("resize",this.onWindowResize)}componentWillUnmount(){this.optionsUnsubscriber(),this.themeUnsubscriber(),this.chartInstance!==null&&(this.chartInstance.destroy(),this.chartInstance=null),window.removeEventListener("resize",this.onWindowResize)}componentDidUpdate(r){const{dir:n,children:i,...o}=this.props;if(this.chartInstance!==null){const a=Xa(this),s=this.chartInstance.chartService,l=a.locale!==s._intlService.locale,h=Object.entries(r).filter(p=>p[0]!=="dir"&&p[0]!=="children").some(p=>{const[f,g]=p;return!(o.hasOwnProperty(f)&&o[f]===g)});l&&(this.chartInstance.chartService._intlService=a,this.chartInstance.chartService.format._intlService=a,h||this.chartInstance.noTransitionsRedraw()),h&&this.refresh(),r.dir!==n&&this.chartInstance.setDirection(this.getDirection(n))}}render(){const{style:r={},className:n,wrapper:i,children:o}=this.props,a=Object.assign({},r,{position:"relative"}),s=_.createElement(i,{className:n,style:a,key:"chartElement"},_.createElement("div",{onMouseLeave:this.onChartMouseLeave,ref:l=>this._element=l,className:"k-chart-surface"},o),_.createElement(_.Fragment,null,this.showLicenseWatermark&&_.createElement(yb,null)));return _.createElement(oa.Provider,{value:this.state},_.createElement(KTt,{key:"seriesTooltip"}),_.createElement(eVt,{key:"crosshairTooltips"}),s)}getDirection(r){return(r!==void 0?r:oi&&window.getComputedStyle(this.element).direction||"ltr")==="rtl"}getChartOptions(){const{renderAs:r,pannable:n,zoomable:i,paneDefaults:o,panes:a,transitions:s,seriesColors:l,seriesDefaults:h,axisDefaults:p,deriveOptionsFromParent:f}=this.props;let g={};return r!==void 0&&(g.renderAs=r),n!==void 0&&(g.pannable=n),i!==void 0&&(g.zoomable=i),o!==void 0&&(g.paneDefaults=o),a!==void 0&&(g.panes=a),s!==void 0&&(g.transitions=s),l!==void 0&&(g.seriesColors=l),h!==void 0&&(g.seriesDefaults=h),p!==void 0&&(g.axisDefaults=p),g=Object.assign(g,this.optionsStore.getState()),f&&(g=f(g)),g}refresh(){if(this.chartInstance!==null){const r=this.themeStore.getState(),n=this.getChartOptions(),i=n.transitions;this.suppressTransitions&&(n.transitions=!1),this.props.onRefresh?this.props.onRefresh.call(void 0,n,r,this.chartInstance):this.chartInstance.setOptions(n,r),this.suppressTransitions&&(n.transitions=i,this.suppressTransitions=!1)}}instantiateCoreChart(){const{dir:r,chartConstructor:n}=this.props,i=this.getChartOptions();this.chartInstance=new n(this.element,i,this.themeStore.getState(),{rtl:this.getDirection(r),intlService:Xa(this),observer:this.chartObserver,sender:this})}trigger(r,n){const i=this.props.getTarget(),o=EPt(r,n,i),a="on"+r.charAt(0).toUpperCase()+r.slice(1),s=this.observersStore.getState();let l=!1;for(let h=0;hthis}get chartInstance(){return this._baseChart!==null?this._baseChart.chartInstance:null}get surface(){return this._baseChart!==null?this._baseChart.surface:null}get element(){return this._baseChart!==null?this._baseChart.element:null}render(){const{donutCenterRender:r,children:n,className:i,...o}=this.props;return _.createElement(iO,{...o,ref:a=>this._baseChart=a,chartConstructor:jp,getTarget:this.getTarget,wrapper:"div",className:Me("k-chart k-widget",i)},n,_.createElement(eVt,{render:r}))}};/** + */let iVt=class extends _.Component{constructor(){super(...arguments),this._baseChart=null,this.getTarget=()=>this}get chartInstance(){return this._baseChart!==null?this._baseChart.chartInstance:null}get surface(){return this._baseChart!==null?this._baseChart.surface:null}get element(){return this._baseChart!==null?this._baseChart.element:null}render(){const{donutCenterRender:r,children:n,className:i,...o}=this.props;return _.createElement(nO,{...o,ref:a=>this._baseChart=a,chartConstructor:jp,getTarget:this.getTarget,wrapper:"div",className:ke("k-chart k-widget",i)},n,_.createElement(rVt,{render:r}))}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const oO=class extends _.Component{constructor(r,n){super(r,n),this.optionsStore=n.optionsStore}renderChildren(r,n){const{children:i}=r.props,{_chartKey:o,_parentStore:a}=this.props,s={...r.props,_chartCollectionIdxKey:`${o}_${n}`,_parentStore:a};return _.cloneElement(r,s,i)}render(){const{_chartKey:r,_parentStore:n,children:i}=this.props;return(n||this.optionsStore).dispatch({chartKey:r,payload:[]}),_.Children.map(i,(o,a)=>_.isValidElement(o)?this.renderChildren(o,a):o)}};oO.contextType=sa;let iVt=oO;/** + */const aO=class extends _.Component{constructor(r,n){super(r,n),this.optionsStore=n.optionsStore}renderChildren(r,n){const{children:i}=r.props,{_chartKey:o,_parentStore:a}=this.props,s={...r.props,_chartCollectionIdxKey:`${o}_${n}`,_parentStore:a};return _.cloneElement(r,s,i)}render(){const{_chartKey:r,_parentStore:n,children:i}=this.props;return(n||this.optionsStore).dispatch({chartKey:r,payload:[]}),_.Children.map(i,(o,a)=>_.isValidElement(o)?this.renderChildren(o,a):o)}};aO.contextType=oa;let nVt=aO;/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const aO=class extends _.Component{constructor(r,n){super(r,n),this.optionsStore=n.optionsStore,this.childStore=T7($R)}render(){const{children:r}=this.props;return r!==void 0?_.Children.map(r,n=>_.isValidElement(n)?this.renderChildren(n):n):null}componentDidMount(){this.dispatch()}componentDidUpdate(){this.dispatch()}dispatch(){const{_chartKey:r,_chartCollectionIdxKey:n,_parentStore:i,children:o,...a}=this.props;(i||this.optionsStore).dispatch({chartKey:r,chartCollectionIdxKey:n,payload:Object.assign({},a,this.childStore.getState())})}renderChildren(r){const{children:n}=r.props,i={...r.props,_parentStore:this.childStore};return _.cloneElement(r,i,n)}};aO.contextType=sa;let nVt=aO;/** + */const sO=class extends _.Component{constructor(r,n){super(r,n),this.optionsStore=n.optionsStore,this.childStore=T7(WR)}render(){const{children:r}=this.props;return r!==void 0?_.Children.map(r,n=>_.isValidElement(n)?this.renderChildren(n):n):null}componentDidMount(){this.dispatch()}componentDidUpdate(){this.dispatch()}dispatch(){const{_chartKey:r,_chartCollectionIdxKey:n,_parentStore:i,children:o,...a}=this.props;(i||this.optionsStore).dispatch({chartKey:r,chartCollectionIdxKey:n,payload:Object.assign({},a,this.childStore.getState())})}renderChildren(r){const{children:n}=r.props,i={...r.props,_parentStore:this.childStore};return _.cloneElement(r,i,n)}};sO.contextType=oa;let oVt=sO;/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const t2="",ed="0",us="_";function Tc(t,r){if(A2(t))return r[Number(t)];{const n=r[Number(K3(t))];return n.items?Tc(oVt(t),n.items):void 0}}function K3(t){return q3(t)?t:t.split(us)[0]}function oVt(t){if(q3(t))return t;{const r=t.indexOf(us);return t.substring(r+1)}}function QL(t){return rd("0",t)}function aVt(t,r){return r.indexOf(t)===0?r.length===t.length||r.charAt(t.length)===us:!1}function rd(t,r){return r?r+us+t:t}function A3(t){const r=t.lastIndexOf(us);return r<0?t2:t.substring(0,r)}function q3(t){return t===t2||t.indexOf(us)<0}function A2(t){return t!==t2&&t.indexOf(us)<0}function sVt(t){return cVt(t)===1}function lVt(t){return qm(t)===ed}function qm(t){const r=t.lastIndexOf(us);return r<0?t:t.substring(r+1)}function tE(t,r,n){return A2(r)?t?Number(r)0?(Number(r)-1).toString():(n-1).toString():r}function cVt(t){return t.split(us).length-1}/** + */const qn="",ed="0",hs="_";function Tc(t,r){if(z2(t))return r[Number(t)];{const n=r[Number(K3(t))];return n.items?Tc(aVt(t),n.items):void 0}}function K3(t){return q3(t)?t:t.split(hs)[0]}function aVt(t){if(q3(t))return t;{const r=t.indexOf(hs);return t.substring(r+1)}}function tE(t){return rd("0",t)}function sVt(t,r){return r.indexOf(t)===0?r.length===t.length||r.charAt(t.length)===hs:!1}function rd(t,r){return r?r+hs+t:t}function A3(t){const r=t.lastIndexOf(hs);return r<0?qn:t.substring(0,r)}function q3(t){return t===qn||t.indexOf(hs)<0}function z2(t){return t!==qn&&t.indexOf(hs)<0}function lVt(t){return hVt(t)===1}function cVt(t){return qm(t)===ed}function qm(t){const r=t.lastIndexOf(hs);return r<0?t:t.substring(r+1)}function eE(t,r,n){return z2(r)?t?Number(r)0?(Number(r)-1).toString():(n-1).toString():r}function hVt(t){return t.split(hs).length-1}/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const sO=class extends _.Component{render(){return null}};sO.propTypes={text:B.string,url:B.string,icon:B.string,disabled:B.bool,cssClass:B.string,cssStyle:B.object,render:B.any,linkRender:B.any,contentRender:B.any,data:B.any};let hVt=sO;/** + */const lO=class extends _.Component{render(){return null}};lO.propTypes={text:B.string,url:B.string,icon:B.string,disabled:B.bool,cssClass:B.string,cssStyle:B.object,render:B.any,linkRender:B.any,contentRender:B.any,data:B.any};let uVt=lO;/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */function uVt(t,r){if(t&&t.length>0)return{items:Jm(t),inputItems:t};if(Zm(r).length>0){const n=cO(Zm(r));return{items:Jm(n),inputItems:n}}else return{items:[],inputItems:[]}}function lO(t,r){let n={};const{text:i,url:o,icon:a,svgIcon:s,disabled:l,cssClass:h,cssStyle:p,render:f,linkRender:g,contentRender:b,data:z}=t||r.props;return i!==void 0&&(n.text=i),o!==void 0&&(n.url=o),a!==void 0&&(n.icon=a),s!==void 0&&(n.svgIcon=s),l!==void 0&&(n.disabled=l),h!==void 0&&(n.cssClass=h),p!==void 0&&(n.cssStyle=p),f!==void 0&&(n.render=f),g!==void 0&&(n.linkRender=g),b!==void 0&&(n.contentRender=b),z!==void 0&&(n.data=z),n}function Zm(t){return _.Children.toArray(t).filter(r=>r&&r.type===hVt)}function cO(t){const r=[];for(let n=0;n0&&(o.items=a),r.push(o)}return r}function Jm(t,r){const n=[];for(let i=0;i0)return{items:Jm(t),inputItems:t};if(Zm(r).length>0){const n=hO(Zm(r));return{items:Jm(n),inputItems:n}}else return{items:[],inputItems:[]}}function cO(t,r){let n={};const{text:i,url:o,icon:a,svgIcon:s,disabled:l,cssClass:h,cssStyle:p,render:f,linkRender:g,contentRender:b,data:z}=t||r.props;return i!==void 0&&(n.text=i),o!==void 0&&(n.url=o),a!==void 0&&(n.icon=a),s!==void 0&&(n.svgIcon=s),l!==void 0&&(n.disabled=l),h!==void 0&&(n.cssClass=h),p!==void 0&&(n.cssStyle=p),f!==void 0&&(n.render=f),g!==void 0&&(n.linkRender=g),b!==void 0&&(n.contentRender=b),z!==void 0&&(n.data=z),n}function Zm(t){return _.Children.toArray(t).filter(r=>r&&r.type===uVt)}function hO(t){const r=[];for(let n=0;n0&&(o.items=a),r.push(o)}return r}function Jm(t,r){const n=[];for(let i=0;i(kt.text||"").toLowerCase().startsWith(lt));return gt?gt.id:r}function F(){return A2(r)?et():sVt(r)?W(et(K3(r))):A3(r)}function H(){return A2(r)?$():A3(r)}function E(){return A2(r)?at():W(K()?r:at(K3(r)))}function R(){return W(A2(r)||K()?r:at(K3(r)))}function W(lt){return dt(!0,lt)}function $(lt){return dt(!1,lt)}function G(){return i.length===1&&dVt.test(i)}function Z(lt,yt){return lt===void 0&&(lt=r),yt===void 0&&(yt=t),Tc(lt,yt)}function K(lt){return Z(lt).items.length>0}function et(lt){return ht(!1,lt)}function at(lt){return ht(!0,lt)}function tt(lt){const yt=Z(lt).items;return yt[yt.length-1].id}function ft(){return A2(r)?t:Z(A3(r),t).items}function dt(lt,yt){yt===void 0&&(yt=r);const mt=Z(yt);return K(yt)&&!mt.disabled?lt?QL(yt):tt(yt):yt}function ht(lt,yt){if(yt===void 0&&(yt=r),A2(yt))return tE(lt,yt,t.length);{const mt=A3(yt),gt=qm(yt),kt=Z(mt).items.length;return rd(tE(lt,gt,kt),mt)}}}/** + */const fVt=/\S/;function vVt(t,r,n,i,o,a){const s=Z();switch(n){case te.left:return l();case te.right:return h();case te.up:return f();case te.down:return p();case te.enter:case te.space:return g();case te.home:return b();case te.end:return z();case te.esc:return M();default:return G()?I():r}function l(){return o?a?R():H():a?E():F()}function h(){return o?a?H():R():a?F():E()}function p(){return o?at():z2(r)?W():at()}function f(){return o?et():z2(r)?$():et()}function g(){return s.disabled?r:K()?tE(r):K3(r)}function b(){return ft()[0].id}function z(){const lt=ft();return lt[lt.length-1].id}function M(){return z2(r)?r:A3(r)}function I(){const lt=i.toLowerCase(),yt=ft(),mt=Number(qm(r)),gt=yt.slice(mt+1).concat(yt.slice(0,mt+1)).find(_t=>(_t.text||"").toLowerCase().startsWith(lt));return gt?gt.id:r}function F(){return z2(r)?et():lVt(r)?W(et(K3(r))):A3(r)}function H(){return z2(r)?$():A3(r)}function E(){return z2(r)?at():W(K()?r:at(K3(r)))}function R(){return W(z2(r)||K()?r:at(K3(r)))}function W(lt){return dt(!0,lt)}function $(lt){return dt(!1,lt)}function G(){return i.length===1&&fVt.test(i)}function Z(lt,yt){return lt===void 0&&(lt=r),yt===void 0&&(yt=t),Tc(lt,yt)}function K(lt){return Z(lt).items.length>0}function et(lt){return ht(!1,lt)}function at(lt){return ht(!0,lt)}function tt(lt){const yt=Z(lt).items;return yt[yt.length-1].id}function ft(){return z2(r)?t:Z(A3(r),t).items}function dt(lt,yt){yt===void 0&&(yt=r);const mt=Z(yt);return K(yt)&&!mt.disabled?lt?tE(yt):tt(yt):yt}function ht(lt,yt){if(yt===void 0&&(yt=r),z2(yt))return eE(lt,yt,t.length);{const mt=A3(yt),gt=qm(yt),_t=Z(mt).items.length;return rd(eE(lt,gt,_t),mt)}}}/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */function vVt(t){return t.hoverOpenDelay!==void 0?t.hoverOpenDelay:t.openOnClick?0:100}function gVt(t){return t.hoverCloseDelay!==void 0?t.hoverCloseDelay:100}/** + */function gVt(t){return t.hoverOpenDelay!==void 0?t.hoverOpenDelay:t.openOnClick?0:100}function mVt(t){return t.hoverCloseDelay!==void 0?t.hoverCloseDelay:100}/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const eE={vertical:"top",horizontal:"left"},rE={vertical:"top",horizontal:"right"},hO={vertical:"flip",horizontal:"fit"},uO={vertical:"fit",horizontal:"flip"},iE={downward:{anchorAlign:{vertical:"bottom",horizontal:"right"},popupAlign:rE,collision:hO},leftward:{anchorAlign:{vertical:"top",horizontal:"left"},popupAlign:rE,collision:uO}},nE={downward:{anchorAlign:{vertical:"bottom",horizontal:"left"},popupAlign:eE,collision:hO},rightward:{anchorAlign:{vertical:"top",horizontal:"right"},popupAlign:eE,collision:uO}};/** + */const rE={vertical:"top",horizontal:"left"},iE={vertical:"top",horizontal:"right"},uO={vertical:"flip",horizontal:"fit"},pO={vertical:"fit",horizontal:"flip"},nE={downward:{anchorAlign:{vertical:"bottom",horizontal:"right"},popupAlign:iE,collision:uO},leftward:{anchorAlign:{vertical:"top",horizontal:"left"},popupAlign:iE,collision:pO}},oE={downward:{anchorAlign:{vertical:"bottom",horizontal:"left"},popupAlign:rE,collision:uO},rightward:{anchorAlign:{vertical:"top",horizontal:"right"},popupAlign:rE,collision:pO}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */function mVt(t,r,n){const i=pO(t,r,n);return n?i==="downward"?iE.downward:iE.leftward:i==="downward"?nE.downward:nE.rightward}function pO(t,r,n){return A2(t)?r?n?"leftward":"rightward":"downward":n?"leftward":"rightward"}function oE(t){return t?"rtl":"ltr"}function Qm(t,r){return`${t}_${r}`}/** + */function yVt(t,r,n){const i=dO(t,r,n);return n?i==="downward"?nE.downward:nE.leftward:i==="downward"?oE.downward:oE.rightward}function dO(t,r,n){return z2(t)?r?n?"leftward":"rightward":"downward":n?"leftward":"rightward"}function aE(t){return t?"rtl":"ltr"}function Qm(t,r){return`${t}_${r}`}/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const dO=class extends _.Component{render(){return this.props.url?_.createElement("a",{className:this.getMenuItemClassName(),role:"presentation",href:this.props.url,tabIndex:-1},this.props.children):_.createElement("span",{id:this.props.id,className:Me(this.getMenuItemClassName(),this.props.className),style:this.props.style,role:"presentation"},this.props.children)}getMenuItemClassName(){return Me("k-link","k-menu-link",{"k-active":this.props.opened})}};dO.propTypes={opened:B.bool,url:B.string};let yVt=dO;const uC={name:"caret-alt-up",content:'',viewBox:"0 0 512 512"},Dl={name:"caret-alt-right",content:'',viewBox:"0 0 512 512"},Y0={name:"caret-alt-down",content:'',viewBox:"0 0 512 512"},Pl={name:"caret-alt-left",content:'',viewBox:"0 0 512 512"},aE={name:"caret-alt-to-right",content:'',viewBox:"0 0 512 512"},sE={name:"caret-alt-to-left",content:'',viewBox:"0 0 512 512"},xVt={name:"more-vertical",content:'',viewBox:"0 0 512 512"},bVt={name:"calendar",content:'',viewBox:"0 0 512 512"},wVt={name:"cancel",content:'',viewBox:"0 0 512 512"},pC={name:"x",content:'',viewBox:"0 0 512 512"},CVt={name:"x-circle",content:'',viewBox:"0 0 512 512"},fO={name:"plus",content:'',viewBox:"0 0 512 512"},SVt={name:"minus",content:'',viewBox:"0 0 512 512"},vO={name:"sort-asc-small",content:'',viewBox:"0 0 512 512"},gO={name:"sort-desc-small",content:'',viewBox:"0 0 512 512"},zVt={name:"filter",content:'',viewBox:"0 0 512 512"},MVt={name:"filter-clear",content:'',viewBox:"0 0 512 512"},kVt={name:"search",content:'',viewBox:"0 0 512 512"};/** + */const fO=class extends _.Component{render(){return this.props.url?_.createElement("a",{className:this.getMenuItemClassName(),role:"presentation",href:this.props.url,tabIndex:-1},this.props.children):_.createElement("span",{id:this.props.id,className:ke(this.getMenuItemClassName(),this.props.className),style:this.props.style,role:"presentation"},this.props.children)}getMenuItemClassName(){return ke("k-link","k-menu-link",{"k-active":this.props.opened})}};fO.propTypes={opened:B.bool,url:B.string};let xVt=fO;const pC={name:"caret-alt-up",content:'',viewBox:"0 0 512 512"},Dl={name:"caret-alt-right",content:'',viewBox:"0 0 512 512"},Y0={name:"caret-alt-down",content:'',viewBox:"0 0 512 512"},Pl={name:"caret-alt-left",content:'',viewBox:"0 0 512 512"},sE={name:"caret-alt-to-right",content:'',viewBox:"0 0 512 512"},lE={name:"caret-alt-to-left",content:'',viewBox:"0 0 512 512"},bVt={name:"more-vertical",content:'',viewBox:"0 0 512 512"},wVt={name:"calendar",content:'',viewBox:"0 0 512 512"},CVt={name:"cancel",content:'',viewBox:"0 0 512 512"},dC={name:"x",content:'',viewBox:"0 0 512 512"},SVt={name:"x-circle",content:'',viewBox:"0 0 512 512"},vO={name:"plus",content:'',viewBox:"0 0 512 512"},zVt={name:"minus",content:'',viewBox:"0 0 512 512"},gO={name:"sort-asc-small",content:'',viewBox:"0 0 512 512"},mO={name:"sort-desc-small",content:'',viewBox:"0 0 512 512"},MVt={name:"filter",content:'',viewBox:"0 0 512 512"},kVt={name:"filter-clear",content:'',viewBox:"0 0 512 512"},_Vt={name:"search",content:'',viewBox:"0 0 512 512"};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const _Vt="caret-alt-down",AVt="caret-alt-right",LVt="caret-alt-left",mO=class extends _.Component{render(){return _.createElement(en,{"aria-hidden":!0,...this.getIcon()})}getIcon(){switch(pO(this.props.itemId,this.props.verticalMenu===!0,this.props.dir==="rtl")){case"downward":return{name:_Vt,icon:Y0};case"rightward":return{name:AVt,icon:Dl};case"leftward":return{name:LVt,icon:Pl};default:return{}}}};mO.propTypes={itemId:B.string,dir:B.string,verticalMenu:B.bool};let EVt=mO;/** + */const AVt="caret-alt-down",LVt="caret-alt-right",EVt="caret-alt-left",yO=class extends _.Component{render(){return _.createElement(Qi,{"aria-hidden":!0,...this.getIcon()})}getIcon(){switch(dO(this.props.itemId,this.props.verticalMenu===!0,this.props.dir==="rtl")){case"downward":return{name:AVt,icon:Y0};case"rightward":return{name:LVt,icon:Dl};case"leftward":return{name:EVt,icon:Pl};default:return{}}}};yO.propTypes={itemId:B.string,dir:B.string,verticalMenu:B.bool};let IVt=yO;/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let yO=class extends _.Component{constructor(){super(...arguments),this.onMouseOver=r=>{this.props.onMouseOver(this.props.parentItemId),r.stopPropagation()},this.onMouseLeave=r=>{this.props.onMouseLeave(this.props.parentItemId),r.stopPropagation()}}render(){const r=this.props.parentItemId;return _.createElement("ul",{className:this.props.className,role:this.props.role?this.props.role:r!==void 0?"menu":"menubar",id:r!==void 0?Qm(this.props.menuGuid,r):void 0,onMouseOver:r!==void 0?this.onMouseOver:void 0,onMouseLeave:r!==void 0?this.onMouseLeave:void 0,"aria-orientation":this.props["aria-orientation"]},this.renderChildItems())}renderChildItems(){return this.props.items.length>0?this.props.items.map((r,n)=>_.createElement(IVt,{item:r,isMenuVertical:this.props.isMenuVertical,isDirectionRightToLeft:this.props.isDirectionRightToLeft,focusedItemId:this.props.focusedItemId,lastItemIdToBeOpened:this.props.lastItemIdToBeOpened,tabbableItemId:this.props.tabbableItemId,itemRender:this.props.itemRender,linkRender:this.props.linkRender,menuGuid:this.props.menuGuid,onMouseOver:this.props.onMouseOver,onMouseLeave:this.props.onMouseLeave,onMouseDown:this.props.onMouseDown,onBlur:this.props.onBlur,onFocus:this.props.onFocus,onClick:this.props.onClick,onOriginalItemNeeded:this.props.onOriginalItemNeeded,key:n})):null}},IVt=class extends _.Component{constructor(r){super(r),this.isFirstRender=!0,this.onMouseOver=n=>{this.props.onMouseOver(this.props.item.id),n.stopPropagation()},this.onMouseLeave=n=>{this.props.onMouseLeave(this.props.item.id),n.stopPropagation()},this.state={opened:!1}}componentDidMount(){const r=this.props.focusedItemId,n=this.props.item.id;r&&r===n&&this.itemElement.focus({preventScroll:!0}),this.isFirstRender=!1}componentDidUpdate(r){const n=this.props.focusedItemId,i=this.props.item.id;if(n){const o=Ki(document);r.focusedItemId!==n&&n===i&&!this.itemElement.contains(o)&&this.itemElement.focus({preventScroll:!0})}}render(){const r=this.props.item,n=r.id,i=Qm(this.props.menuGuid,n);return _.createElement(_.Fragment,null,_.createElement("li",{id:Qm(this.props.menuGuid,n),className:this.getMenuItemClassName(r),style:r.cssStyle,tabIndex:n===this.props.tabbableItemId?0:-1,onMouseOver:this.onMouseOver,onMouseLeave:this.onMouseLeave,onMouseDown:o=>this.props.onMouseDown(o),onBlur:o=>this.props.onBlur(n,o),onFocus:()=>this.props.onFocus(n),onClick:o=>this.props.onClick(o,n),role:"menuitem","aria-disabled":r.disabled?!0:void 0,"aria-haspopup":r.items.length>0?!0:void 0,"aria-expanded":r.items.length>0?this.Opened:void 0,"aria-label":r.text,"aria-owns":this.Opened?i:void 0,ref:o=>this.itemElement=o,key:"0"},this.contentRender?this.renderContent():this.renderMenuItemLink()),this.renderPopupIfOpened())}renderContent(){const r=this.props.item.contentParentItemId;return _.createElement("div",{className:"k-content",role:"presentation"},_.createElement(this.contentRender,{item:this.props.onOriginalItemNeeded(r),itemId:r}))}renderMenuItemLink(){const r=this.props.item;if(this.linkRender)return _.createElement(this.linkRender,{item:this.props.onOriginalItemNeeded(r.id),itemId:r.id,opened:this.Opened,dir:oE(this.props.isDirectionRightToLeft)});{const n=this.itemRender?_.createElement(this.itemRender,{item:this.props.onOriginalItemNeeded(r.id),itemId:r.id,key:"1"}):_.createElement("span",{className:"k-menu-link-text"},r.text);return _.createElement(yVt,{url:r.url,opened:this.Opened},this.renderMenuIconIfApplicable(),n,this.renderArrowIfApplicable())}}renderPopupIfOpened(){if(this.Opened){const r=this.props.item.id,{anchorAlign:n,popupAlign:i,collision:o}=mVt(r,this.props.isMenuVertical,this.props.isDirectionRightToLeft);return _.createElement(A4,{anchor:this.itemElement,show:!0,popupClass:this.getPopupClassName(),anchorAlign:n,popupAlign:i,collision:o,animate:!1,key:"1"},_.createElement(yO,{parentItemId:r,items:this.props.item.items,menuGuid:this.props.menuGuid,focusedItemId:this.props.focusedItemId,lastItemIdToBeOpened:this.props.lastItemIdToBeOpened,tabbableItemId:this.props.tabbableItemId,itemRender:this.props.itemRender,linkRender:this.props.linkRender,isMenuVertical:this.props.isMenuVertical,isDirectionRightToLeft:this.props.isDirectionRightToLeft,className:"k-group k-menu-group k-reset k-menu-group-md",onMouseOver:this.props.onMouseOver,onMouseLeave:this.props.onMouseLeave,onMouseDown:this.props.onMouseDown,onBlur:this.props.onBlur,onFocus:this.props.onFocus,onClick:this.props.onClick,onOriginalItemNeeded:this.props.onOriginalItemNeeded}))}else return null}renderMenuIconIfApplicable(){const{icon:r,svgIcon:n}=this.props.item;return r||n?_.createElement(en,{name:r,icon:n,key:"0"}):null}renderArrowIfApplicable(){return this.props.item.items.length>0?_.createElement("span",{className:"k-menu-expand-arrow","aria-hidden":!0},_.createElement(EVt,{itemId:this.props.item.id,verticalMenu:this.props.isMenuVertical,dir:oE(this.props.isDirectionRightToLeft),key:"2"})):null}get itemRender(){return this.props.item.render||this.props.itemRender}get linkRender(){return this.props.item.linkRender||this.props.linkRender}get contentRender(){return this.props.item.contentParentItemId?this.props.item.contentRender:null}get Opened(){const r=this.props;return r.item.items.length>0&&aVt(r.item.id,r.lastItemIdToBeOpened)&&!this.isFirstRender}getPopupClassName(){return Me("k-menu-popup",{"k-rtl":this.props.isDirectionRightToLeft})}getMenuItemClassName(r){return Me("k-item","k-menu-item",{"k-first":lVt(r.id),"k-last":r.isLastFromSiblings,"k-disabled":r.disabled},r.cssClass)}};/** + */let xO=class extends _.Component{constructor(){super(...arguments),this.onMouseOver=r=>{this.props.onMouseOver(this.props.parentItemId),r.stopPropagation()},this.onMouseLeave=r=>{this.props.onMouseLeave(this.props.parentItemId),r.stopPropagation()}}render(){const r=this.props.parentItemId;return _.createElement("ul",{className:this.props.className,role:this.props.role?this.props.role:r!==void 0?"menu":"menubar",id:r!==void 0?Qm(this.props.menuGuid,r):void 0,onMouseOver:r!==void 0?this.onMouseOver:void 0,onMouseLeave:r!==void 0?this.onMouseLeave:void 0,"aria-orientation":this.props["aria-orientation"]},this.renderChildItems())}renderChildItems(){return this.props.items.length>0?this.props.items.map((r,n)=>_.createElement(HVt,{item:r,isMenuVertical:this.props.isMenuVertical,isDirectionRightToLeft:this.props.isDirectionRightToLeft,focusedItemId:this.props.focusedItemId,lastItemIdToBeOpened:this.props.lastItemIdToBeOpened,tabbableItemId:this.props.tabbableItemId,itemRender:this.props.itemRender,linkRender:this.props.linkRender,menuGuid:this.props.menuGuid,onMouseOver:this.props.onMouseOver,onMouseLeave:this.props.onMouseLeave,onMouseDown:this.props.onMouseDown,onBlur:this.props.onBlur,onFocus:this.props.onFocus,onClick:this.props.onClick,onOriginalItemNeeded:this.props.onOriginalItemNeeded,key:n})):null}},HVt=class extends _.Component{constructor(r){super(r),this.isFirstRender=!0,this.onMouseOver=n=>{this.props.onMouseOver(this.props.item.id),n.stopPropagation()},this.onMouseLeave=n=>{this.props.onMouseLeave(this.props.item.id),n.stopPropagation()},this.state={opened:!1}}componentDidMount(){const r=this.props.focusedItemId,n=this.props.item.id;r&&r===n&&this.itemElement.focus({preventScroll:!0}),this.isFirstRender=!1}componentDidUpdate(r){const n=this.props.focusedItemId,i=this.props.item.id;if(n){const o=Yi(document);r.focusedItemId!==n&&n===i&&!this.itemElement.contains(o)&&this.itemElement.focus({preventScroll:!0})}}render(){const r=this.props.item,n=r.id,i=Qm(this.props.menuGuid,n);return _.createElement(_.Fragment,null,_.createElement("li",{id:Qm(this.props.menuGuid,n),className:this.getMenuItemClassName(r),style:r.cssStyle,tabIndex:n===this.props.tabbableItemId?0:-1,onMouseOver:this.onMouseOver,onMouseLeave:this.onMouseLeave,onMouseDown:o=>this.props.onMouseDown(o),onBlur:o=>this.props.onBlur(n,o),onFocus:()=>this.props.onFocus(n),onClick:o=>this.props.onClick(o,n),role:"menuitem","aria-disabled":r.disabled?!0:void 0,"aria-haspopup":r.items.length>0?!0:void 0,"aria-expanded":r.items.length>0?this.Opened:void 0,"aria-label":r.text,"aria-owns":this.Opened?i:void 0,ref:o=>this.itemElement=o,key:"0"},this.contentRender?this.renderContent():this.renderMenuItemLink()),this.renderPopupIfOpened())}renderContent(){const r=this.props.item.contentParentItemId;return _.createElement("div",{className:"k-content",role:"presentation"},_.createElement(this.contentRender,{item:this.props.onOriginalItemNeeded(r),itemId:r}))}renderMenuItemLink(){const r=this.props.item;if(this.linkRender)return _.createElement(this.linkRender,{item:this.props.onOriginalItemNeeded(r.id),itemId:r.id,opened:this.Opened,dir:aE(this.props.isDirectionRightToLeft)});{const n=this.itemRender?_.createElement(this.itemRender,{item:this.props.onOriginalItemNeeded(r.id),itemId:r.id,key:"1"}):_.createElement("span",{className:"k-menu-link-text"},r.text);return _.createElement(xVt,{url:r.url,opened:this.Opened},this.renderMenuIconIfApplicable(),n,this.renderArrowIfApplicable())}}renderPopupIfOpened(){if(this.Opened){const r=this.props.item.id,{anchorAlign:n,popupAlign:i,collision:o}=yVt(r,this.props.isMenuVertical,this.props.isDirectionRightToLeft);return _.createElement(A4,{anchor:this.itemElement,show:!0,popupClass:this.getPopupClassName(),anchorAlign:n,popupAlign:i,collision:o,animate:!1,key:"1"},_.createElement(xO,{parentItemId:r,items:this.props.item.items,menuGuid:this.props.menuGuid,focusedItemId:this.props.focusedItemId,lastItemIdToBeOpened:this.props.lastItemIdToBeOpened,tabbableItemId:this.props.tabbableItemId,itemRender:this.props.itemRender,linkRender:this.props.linkRender,isMenuVertical:this.props.isMenuVertical,isDirectionRightToLeft:this.props.isDirectionRightToLeft,className:"k-group k-menu-group k-reset k-menu-group-md",onMouseOver:this.props.onMouseOver,onMouseLeave:this.props.onMouseLeave,onMouseDown:this.props.onMouseDown,onBlur:this.props.onBlur,onFocus:this.props.onFocus,onClick:this.props.onClick,onOriginalItemNeeded:this.props.onOriginalItemNeeded}))}else return null}renderMenuIconIfApplicable(){const{icon:r,svgIcon:n}=this.props.item;return r||n?_.createElement(Qi,{name:r,icon:n,key:"0"}):null}renderArrowIfApplicable(){return this.props.item.items.length>0?_.createElement("span",{className:"k-menu-expand-arrow","aria-hidden":!0},_.createElement(IVt,{itemId:this.props.item.id,verticalMenu:this.props.isMenuVertical,dir:aE(this.props.isDirectionRightToLeft),key:"2"})):null}get itemRender(){return this.props.item.render||this.props.itemRender}get linkRender(){return this.props.item.linkRender||this.props.linkRender}get contentRender(){return this.props.item.contentParentItemId?this.props.item.contentRender:null}get Opened(){const r=this.props;return r.item.items.length>0&&sVt(r.item.id,r.lastItemIdToBeOpened)&&!this.isFirstRender}getPopupClassName(){return ke("k-menu-popup",{"k-rtl":this.props.isDirectionRightToLeft})}getMenuItemClassName(r){return ke("k-item","k-menu-item",{"k-first":cVt(r.id),"k-last":r.isLastFromSiblings,"k-disabled":r.disabled},r.cssClass)}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let HVt=class{constructor(){this.phase="Initialized"}getIsDirectionRightToLeft(){return this.isDirectionRightToLeft}setIsDirectionRightToLeft(r){this.phase=this.phase==="NotInitialized"?"Initialized":"NewValueReceived",this.previousIsDirectionRightToLeft=this.isDirectionRightToLeft,this.isDirectionRightToLeft=r}hasDirectionChanged(){return this.phase==="NewValueReceived"?this.previousIsDirectionRightToLeft!==this.isDirectionRightToLeft:!1}};/** + */let DVt=class{constructor(){this.phase="Initialized"}getIsDirectionRightToLeft(){return this.isDirectionRightToLeft}setIsDirectionRightToLeft(r){this.phase=this.phase==="NotInitialized"?"Initialized":"NewValueReceived",this.previousIsDirectionRightToLeft=this.isDirectionRightToLeft,this.isDirectionRightToLeft=r}hasDirectionChanged(){return this.phase==="NewValueReceived"?this.previousIsDirectionRightToLeft!==this.isDirectionRightToLeft:!1}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let DVt=class{constructor(r,n,i){this.openOnClick=r,this.resetMenu=n,this.openItem=i,this.mouseDown=!1,this.openOnClick=r,this.isMouseOverEnabled=!r}set OpenOnClick(r){!!r!=!!this.openOnClick&&(this.mouseDown=!1,this.isMouseOverEnabled=!r),this.openOnClick=r}handleItemSelectedViaKeyboard(){this.openOnClick&&(this.isMouseOverEnabled=!1,this.resetMenu())}get IsMouseOverEnabled(){return this.isMouseOverEnabled}handleItemMouseDown(){this.mouseDown=!0}handleItemFocus(){this.openOnClick&&!this.mouseDown&&(this.isMouseOverEnabled=!0),this.mouseDown=!1}handleItemClick(r,n){this.openOnClick&&(this.isMouseOverEnabled?n&&(this.isMouseOverEnabled=!1,this.resetMenu()):(this.isMouseOverEnabled=!0,this.openItem(r)))}};/** + */let PVt=class{constructor(r,n,i){this.openOnClick=r,this.resetMenu=n,this.openItem=i,this.mouseDown=!1,this.openOnClick=r,this.isMouseOverEnabled=!r}set OpenOnClick(r){!!r!=!!this.openOnClick&&(this.mouseDown=!1,this.isMouseOverEnabled=!r),this.openOnClick=r}handleItemSelectedViaKeyboard(){this.openOnClick&&(this.isMouseOverEnabled=!1,this.resetMenu())}get IsMouseOverEnabled(){return this.isMouseOverEnabled}handleItemMouseDown(){this.mouseDown=!0}handleItemFocus(){this.openOnClick&&!this.mouseDown&&(this.isMouseOverEnabled=!0),this.mouseDown=!1}handleItemClick(r,n){this.openOnClick&&(this.isMouseOverEnabled?n&&(this.isMouseOverEnabled=!1,this.resetMenu()):(this.isMouseOverEnabled=!0,this.openItem(r)))}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. @@ -841,196 +841,196 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const lE={focusedItemId:t2,hoveredItemId:t2,tabbableItemId:ed},ty=class extends _.Component{constructor(r){super(r),this.menuWrapperEl=null,this.directionHolder=new HVt,this.inputItems=[],this.items=[],this.reset=()=>{this.clearItemHoverAndLeaveRequestsIfApplicable(),this.setState(lE)},this.onKeyDown=n=>{if(this.state.focusedItemId!==t2){const i=Tc(this.state.focusedItemId,this.items),o=fVt(this.items,i.id,n.keyCode,n.key,this.props.vertical,this.directionHolder.getIsDirectionRightToLeft());i.id!==o&&(n.preventDefault(),this.setFocusedItemId(o)),(n.keyCode===Jt.enter||n.keyCode===Jt.space)&&!i.disabled&&(this.mouseOverHandler.handleItemSelectedViaKeyboard(),this.dispatchSelectEventIfWired(n,i.id),!n.isDefaultPrevented()&&i.items.length===0&&i.url&&window.location.assign(i.url))}n.keyCode===Jt.esc&&this.props.onClose&&this.props.onClose.call(void 0,n)},this.onItemMouseOver=n=>{this.mouseOverHandler.IsMouseOverEnabled&&(this.clearItemHoverAndLeaveRequestsIfApplicable(),this.itemHoverRequest=window.setTimeout(()=>{this.setHoveredItemId(n),this.itemHoverRequest=null},vVt(this.props)))},this.onItemMouseLeave=n=>{this.mouseOverHandler.IsMouseOverEnabled&&this.isItemWithDefaultClose(n)&&(this.clearItemHoverAndLeaveRequestsIfApplicable(),this.itemLeaveRequest=window.setTimeout(()=>{this.setHoveredItemId(t2),this.itemLeaveRequest=null},gVt(this.props)))},this.onItemMouseDown=()=>{this.mouseOverHandler.handleItemMouseDown()},this.onItemFocus=n=>{this.setFocusedItemId(n),this.mouseOverHandler.handleItemFocus()},this.onItemClick=(n,i)=>{const o=Tc(i,this.items);o.disabled||(this.setFocusedItemId(i),this.mouseOverHandler.handleItemClick(i,this.isItemWithDefaultClose(i)),this.dispatchSelectEventIfWired(n,i),!n.isDefaultPrevented()&&o.url&&window.location.assign(o.url))},this.onItemBlur=(n,i)=>{if(this.isItemWithDefaultClose(n)&&this.setFocusedItemId(t2),i.relatedTarget&&i.relatedTarget.nodeName==="LI"){const o=i.relatedTarget.getAttribute("id");if(o&&o.includes(this.menuItemId))return}this.props.onClose&&this.props.onClose.call(void 0,i)},this.getInputItem=n=>Tc(n,this.inputItems),gi(y9),this.mouseOverHandler=new DVt(this.props.openOnClick,this.reset,this.onItemMouseOver),this.state=Object.assign({},lE,{isFirstRender:!0})}get menuItemId(){return this.props.id}get element(){return this.menuWrapperEl}render(){this.prepareItems(),this.state.isFirstRender||this.directionHolder.setIsDirectionRightToLeft(this.checkIsDirectionRightToLeft());let r=this.state.hoveredItemId?this.state.hoveredItemId:this.state.focusedItemId?A3(this.state.focusedItemId):t2;return _.createElement("div",{id:this.props.id,onKeyDown:this.onKeyDown,style:this.props.style,className:this.directionHolder.getIsDirectionRightToLeft()?"k-rtl":void 0,ref:n=>this.menuWrapperEl=n},_.createElement(yO,{className:this.getMenuClassName(),"aria-orientation":this.props.vertical?"vertical":void 0,items:this.items,isMenuVertical:this.props.vertical,isDirectionRightToLeft:this.directionHolder.getIsDirectionRightToLeft(),focusedItemId:this.state.focusedItemId,lastItemIdToBeOpened:r,tabbableItemId:this.state.tabbableItemId,itemRender:this.props.itemRender,linkRender:this.props.linkRender,menuGuid:this.menuItemId,onMouseLeave:this.onItemMouseLeave,onMouseOver:this.onItemMouseOver,onMouseDown:this.onItemMouseDown,onFocus:this.onItemFocus,onClick:this.onItemClick,onBlur:this.onItemBlur,onOriginalItemNeeded:this.getInputItem,role:this.props.role}))}componentDidMount(){this.setState({isFirstRender:!1})}componentDidUpdate(r){(!!r.vertical!=!!this.props.vertical||this.directionHolder.hasDirectionChanged())&&this.reset(),this.mouseOverHandler.OpenOnClick=this.props.openOnClick}componentWillUnmount(){this.clearItemHoverAndLeaveRequestsIfApplicable()}setFocusedItemId(r){this.setState(n=>{const i=r===t2?n.tabbableItemId:K3(r);return{hoveredItemId:r===t2||q3(n.hoveredItemId)&&q3(r)?n.hoveredItemId:t2,focusedItemId:r,tabbableItemId:i}})}setHoveredItemId(r){this.setState(n=>q3(r)&&q3(n.focusedItemId)?{hoveredItemId:r,focusedItemId:n.focusedItemId,tabbableItemId:n.tabbableItemId}:{hoveredItemId:r,focusedItemId:t2,tabbableItemId:ed})}getMenuClassName(){return Me("k-reset","k-header","k-menu",{"k-menu-horizontal":!this.props.vertical},{"k-menu-vertical":this.props.vertical},this.props.className)}clearItemHoverAndLeaveRequestsIfApplicable(){this.itemHoverRequest&&(clearTimeout(this.itemHoverRequest),this.itemHoverRequest=null),this.itemLeaveRequest&&(clearTimeout(this.itemLeaveRequest),this.itemLeaveRequest=null)}isItemWithDefaultClose(r){return!this.props.customCloseItemIds||this.props.customCloseItemIds.indexOf(r)===-1}checkIsDirectionRightToLeft(){return!!(this.props.dir!==void 0?this.props.dir==="rtl":this.menuWrapperEl&&getComputedStyle(this.menuWrapperEl).direction==="rtl")}prepareItems(){const{items:r,inputItems:n}=uVt(this.props.items,this.props.children);this.items=r,this.inputItems=n}dispatchSelectEventIfWired(r,n){fn(this.props.onSelect,r,this,{item:this.getInputItem(n),itemId:n})}};ty.propTypes={vertical:B.bool,items:B.arrayOf(B.object),style:B.object,dir:B.string,hoverOpenDelay:B.number,hoverCloseDelay:B.number,openOnClick:B.bool,itemRender:B.any,linkRender:B.any,customCloseItemIds:B.arrayOf(B.string),onSelect:B.func,role:B.string},ty.defaultProps={vertical:!1};let PVt=ty;/** + */const cE={focusedItemId:qn,hoveredItemId:qn,tabbableItemId:ed},ty=class extends _.Component{constructor(r){super(r),this.menuWrapperEl=null,this.directionHolder=new DVt,this.inputItems=[],this.items=[],this.reset=()=>{this.clearItemHoverAndLeaveRequestsIfApplicable(),this.setState(cE)},this.onKeyDown=n=>{if(this.state.focusedItemId!==qn){const i=Tc(this.state.focusedItemId,this.items),o=vVt(this.items,i.id,n.keyCode,n.key,this.props.vertical,this.directionHolder.getIsDirectionRightToLeft());i.id!==o&&(n.preventDefault(),this.setFocusedItemId(o)),(n.keyCode===te.enter||n.keyCode===te.space)&&!i.disabled&&(this.mouseOverHandler.handleItemSelectedViaKeyboard(),this.dispatchSelectEventIfWired(n,i.id),!n.isDefaultPrevented()&&i.items.length===0&&i.url&&window.location.assign(i.url))}n.keyCode===te.esc&&this.props.onClose&&this.props.onClose.call(void 0,n)},this.onItemMouseOver=n=>{this.mouseOverHandler.IsMouseOverEnabled&&(this.clearItemHoverAndLeaveRequestsIfApplicable(),this.itemHoverRequest=window.setTimeout(()=>{this.setHoveredItemId(n),this.itemHoverRequest=null},gVt(this.props)))},this.onItemMouseLeave=n=>{this.mouseOverHandler.IsMouseOverEnabled&&this.isItemWithDefaultClose(n)&&(this.clearItemHoverAndLeaveRequestsIfApplicable(),this.itemLeaveRequest=window.setTimeout(()=>{this.setHoveredItemId(qn),this.itemLeaveRequest=null},mVt(this.props)))},this.onItemMouseDown=()=>{this.mouseOverHandler.handleItemMouseDown()},this.onItemFocus=n=>{this.setFocusedItemId(n),this.mouseOverHandler.handleItemFocus()},this.onItemClick=(n,i)=>{const o=Tc(i,this.items);o.disabled||(this.setFocusedItemId(i),this.mouseOverHandler.handleItemClick(i,this.isItemWithDefaultClose(i)),this.dispatchSelectEventIfWired(n,i),!n.isDefaultPrevented()&&o.url&&window.location.assign(o.url))},this.onItemBlur=(n,i)=>{if(this.isItemWithDefaultClose(n)&&this.setFocusedItemId(qn),i.relatedTarget&&i.relatedTarget.nodeName==="LI"){const o=i.relatedTarget.getAttribute("id");if(o&&o.includes(this.menuItemId))return}this.props.onClose&&this.props.onClose.call(void 0,i)},this.getInputItem=n=>Tc(n,this.inputItems),vi(y9),this.mouseOverHandler=new PVt(this.props.openOnClick,this.reset,this.onItemMouseOver),this.state=Object.assign({},cE,{isFirstRender:!0})}get menuItemId(){return this.props.id}get element(){return this.menuWrapperEl}render(){this.prepareItems(),this.state.isFirstRender||this.directionHolder.setIsDirectionRightToLeft(this.checkIsDirectionRightToLeft());let r=this.state.hoveredItemId?this.state.hoveredItemId:this.state.focusedItemId?A3(this.state.focusedItemId):qn;return _.createElement("div",{id:this.props.id,onKeyDown:this.onKeyDown,style:this.props.style,className:this.directionHolder.getIsDirectionRightToLeft()?"k-rtl":void 0,ref:n=>this.menuWrapperEl=n},_.createElement(xO,{className:this.getMenuClassName(),"aria-orientation":this.props.vertical?"vertical":void 0,items:this.items,isMenuVertical:this.props.vertical,isDirectionRightToLeft:this.directionHolder.getIsDirectionRightToLeft(),focusedItemId:this.state.focusedItemId,lastItemIdToBeOpened:r,tabbableItemId:this.state.tabbableItemId,itemRender:this.props.itemRender,linkRender:this.props.linkRender,menuGuid:this.menuItemId,onMouseLeave:this.onItemMouseLeave,onMouseOver:this.onItemMouseOver,onMouseDown:this.onItemMouseDown,onFocus:this.onItemFocus,onClick:this.onItemClick,onBlur:this.onItemBlur,onOriginalItemNeeded:this.getInputItem,role:this.props.role}))}componentDidMount(){this.setState({isFirstRender:!1})}componentDidUpdate(r){(!!r.vertical!=!!this.props.vertical||this.directionHolder.hasDirectionChanged())&&this.reset(),this.mouseOverHandler.OpenOnClick=this.props.openOnClick}componentWillUnmount(){this.clearItemHoverAndLeaveRequestsIfApplicable()}setFocusedItemId(r){this.setState(n=>{const i=r===qn?n.tabbableItemId:K3(r);return{hoveredItemId:r===qn||q3(n.hoveredItemId)&&q3(r)?n.hoveredItemId:qn,focusedItemId:r,tabbableItemId:i}})}setHoveredItemId(r){this.setState(n=>q3(r)&&q3(n.focusedItemId)?{hoveredItemId:r,focusedItemId:n.focusedItemId,tabbableItemId:n.tabbableItemId}:{hoveredItemId:r,focusedItemId:qn,tabbableItemId:ed})}getMenuClassName(){return ke("k-reset","k-header","k-menu",{"k-menu-horizontal":!this.props.vertical},{"k-menu-vertical":this.props.vertical},this.props.className)}clearItemHoverAndLeaveRequestsIfApplicable(){this.itemHoverRequest&&(clearTimeout(this.itemHoverRequest),this.itemHoverRequest=null),this.itemLeaveRequest&&(clearTimeout(this.itemLeaveRequest),this.itemLeaveRequest=null)}isItemWithDefaultClose(r){return!this.props.customCloseItemIds||this.props.customCloseItemIds.indexOf(r)===-1}checkIsDirectionRightToLeft(){return!!(this.props.dir!==void 0?this.props.dir==="rtl":this.menuWrapperEl&&getComputedStyle(this.menuWrapperEl).direction==="rtl")}prepareItems(){const{items:r,inputItems:n}=pVt(this.props.items,this.props.children);this.items=r,this.inputItems=n}dispatchSelectEventIfWired(r,n){pn(this.props.onSelect,r,this,{item:this.getInputItem(n),itemId:n})}};ty.propTypes={vertical:B.bool,items:B.arrayOf(B.object),style:B.object,dir:B.string,hoverOpenDelay:B.number,hoverCloseDelay:B.number,openOnClick:B.bool,itemRender:B.any,linkRender:B.any,customCloseItemIds:B.arrayOf(B.string),onSelect:B.func,role:B.string},ty.defaultProps={vertical:!1};let TVt=ty;/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const xO=class extends _.Component{constructor(){super(...arguments),this.itemRef=null,this.focus=()=>{this.itemRef&&this.itemRef.focus()},this.blur=()=>{this.itemRef&&this.itemRef.blur()},this.onClick=()=>{this.props.onSelect&&this.props.onSelect(this.props.index),this.itemRef&&(this.itemRef.tabIndex=0,this.itemRef.focus())}}render(){const{id:r,active:n,disabled:i,title:o="Untitled",index:a,renderAllContent:s,first:l,last:h}=this.props,p=s?`${this.props.contentPanelId}-${a.toString()}`:this.props.contentPanelId,f={id:`${r}-${a.toString()}`,"aria-selected":n,"aria-controls":n?p:void 0,"aria-disabled":i,role:"tab",onClick:i?void 0:this.onClick},g=Me("k-item","k-tabstrip-item",{"k-disabled":i,"k-active":n,"k-first":l,"k-last":h});return _.createElement("li",{...f,className:g,ref:b=>this.itemRef=b,onBlur:this.blur,"aria-controls":p},_.createElement("span",{className:"k-link"},o))}};xO.propTypes={active:B.bool,disabled:B.bool,index:B.number,onSelect:B.func,title:B.oneOfType([B.string,B.element]),first:B.bool,last:B.bool};let TVt=xO;/** + */const bO=class extends _.Component{constructor(){super(...arguments),this.itemRef=null,this.focus=()=>{this.itemRef&&this.itemRef.focus()},this.blur=()=>{this.itemRef&&this.itemRef.blur()},this.onClick=()=>{this.props.onSelect&&this.props.onSelect(this.props.index),this.itemRef&&(this.itemRef.tabIndex=0,this.itemRef.focus())}}render(){const{id:r,active:n,disabled:i,title:o="Untitled",index:a,renderAllContent:s,first:l,last:h}=this.props,p=s?`${this.props.contentPanelId}-${a.toString()}`:this.props.contentPanelId,f={id:`${r}-${a.toString()}`,"aria-selected":n,"aria-controls":n?p:void 0,"aria-disabled":i,role:"tab",onClick:i?void 0:this.onClick},g=ke("k-item","k-tabstrip-item",{"k-disabled":i,"k-active":n,"k-first":l,"k-last":h});return _.createElement("li",{...f,className:g,ref:b=>this.itemRef=b,onBlur:this.blur,"aria-controls":p},_.createElement("span",{className:"k-link"},o))}};bO.propTypes={active:B.bool,disabled:B.bool,index:B.number,onSelect:B.func,title:B.oneOfType([B.string,B.element]),first:B.bool,last:B.bool};let VVt=bO;/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const dC={name:"@progress/kendo-react-buttons",productName:"KendoReact",productCodes:["KENDOUIREACT","KENDOUICOMPLETE"],publishDate:1722843828,version:"",licensingDocsUrl:"https://www.telerik.com/kendo-react-ui/components/my-license/"};/** + */const fC={name:"@progress/kendo-react-buttons",productName:"KendoReact",productCodes:["KENDOUIREACT","KENDOUICOMPLETE"],publishDate:1722843828,version:"",licensingDocsUrl:"https://www.telerik.com/kendo-react-ui/components/my-license/"};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */function VVt({imageUrl:t,name:r,iconClass:n,svgIcon:i,imageAlt:o}){return t?_.createElement("img",{role:"presentation",className:"k-button-icon",alt:o,src:t}):r||i?_.createElement(en,{className:"k-button-icon",name:r,icon:i}):n?_.createElement("span",{role:"presentation",className:Me("k-button-icon",n)}):null}const ey=class pc extends _.Component{constructor(r){super(r),this._element=null,this.handleClick=n=>{this.toggleIfApplicable(),this.props.onClick&&this.props.onClick.call(void 0,n)},gi(dC),this.state={selected:this.props.togglable===!0&&this.props.selected===!0}}get element(){return this._element}get selected(){return this._selectedTemp!==void 0?this._selectedTemp:this.state.selected}static getDerivedStateFromProps(r,n){return r.togglable&&r.selected!==void 0&&r.selected!==n.selected?{selected:r.selected}:null}render(){const{children:r,togglable:n,icon:i,iconClass:o,svgIcon:a,imageUrl:s,imageAlt:l,className:h,startIcon:p,endIcon:f,onClick:g,size:b=pc.defaultProps.size,rounded:z=pc.defaultProps.rounded,fillMode:M=pc.defaultProps.fillMode,themeColor:I=pc.defaultProps.themeColor,...F}=this.props,H=a!==void 0||i!==void 0||o!==void 0||s!==void 0,E=r!==void 0,R=VVt({name:i,svgIcon:a,iconClass:o,imageUrl:s,imageAlt:l}),W=$=>_.cloneElement($,{className:"k-button-icon"});return _.createElement("button",{ref:$=>this._element=$,"aria-pressed":n?this.state.selected:void 0,...F,onClick:this.handleClick,className:Me("k-button",{[`k-button-${Gr.sizeMap[b]||b}`]:b,[`k-button-${M}`]:M,[`k-button-${M}-${I}`]:!!(M&&I),[`k-rounded-${Gr.roundedMap[z]||z}`]:z,"k-icon-button":!E&&H,"k-disabled":this.props.disabled,"k-selected":this.state.selected,"k-rtl":this.props.dir==="rtl"},this.props.className)},p&&W(p),R,r&&_.createElement("span",{className:"k-button-text"},r),f&&W(f))}toggleIfApplicable(){if(this.props.togglable&&this.props.selected===void 0){const r=!this.state.selected;this._selectedTemp=r,this.setState({selected:r},()=>this._selectedTemp=void 0)}}};ey.propTypes={children:B.node,selected:B.bool,togglable:B.bool,icon:B.string,svgIcon:dp,iconClass:B.string,imageUrl:B.string,imageAlt:B.string,size:B.oneOf([null,"small","medium","large"]),rounded:B.oneOf([null,"small","medium","large","full"]),fillMode:B.oneOf([null,"flat","link","outline","solid","clear"]),themeColor:B.oneOf([null,"base","primary","secondary","tertiary","info","success","warning","error","dark","light","inverse"])},ey.defaultProps={togglable:!1,size:"medium",rounded:"medium",fillMode:"solid",themeColor:"base"};let ei=ey;/** + */function FVt({imageUrl:t,name:r,iconClass:n,svgIcon:i,imageAlt:o}){return t?_.createElement("img",{role:"presentation",className:"k-button-icon",alt:o,src:t}):r||i?_.createElement(Qi,{className:"k-button-icon",name:r,icon:i}):n?_.createElement("span",{role:"presentation",className:ke("k-button-icon",n)}):null}const ey=class pc extends _.Component{constructor(r){super(r),this._element=null,this.handleClick=n=>{this.toggleIfApplicable(),this.props.onClick&&this.props.onClick.call(void 0,n)},vi(fC),this.state={selected:this.props.togglable===!0&&this.props.selected===!0}}get element(){return this._element}get selected(){return this._selectedTemp!==void 0?this._selectedTemp:this.state.selected}static getDerivedStateFromProps(r,n){return r.togglable&&r.selected!==void 0&&r.selected!==n.selected?{selected:r.selected}:null}render(){const{children:r,togglable:n,icon:i,iconClass:o,svgIcon:a,imageUrl:s,imageAlt:l,className:h,startIcon:p,endIcon:f,onClick:g,size:b=pc.defaultProps.size,rounded:z=pc.defaultProps.rounded,fillMode:M=pc.defaultProps.fillMode,themeColor:I=pc.defaultProps.themeColor,...F}=this.props,H=a!==void 0||i!==void 0||o!==void 0||s!==void 0,E=r!==void 0,R=FVt({name:i,svgIcon:a,iconClass:o,imageUrl:s,imageAlt:l}),W=$=>_.cloneElement($,{className:"k-button-icon"});return _.createElement("button",{ref:$=>this._element=$,"aria-pressed":n?this.state.selected:void 0,...F,onClick:this.handleClick,className:ke("k-button",{[`k-button-${Wr.sizeMap[b]||b}`]:b,[`k-button-${M}`]:M,[`k-button-${M}-${I}`]:!!(M&&I),[`k-rounded-${Wr.roundedMap[z]||z}`]:z,"k-icon-button":!E&&H,"k-disabled":this.props.disabled,"k-selected":this.state.selected,"k-rtl":this.props.dir==="rtl"},this.props.className)},p&&W(p),R,r&&_.createElement("span",{className:"k-button-text"},r),f&&W(f))}toggleIfApplicable(){if(this.props.togglable&&this.props.selected===void 0){const r=!this.state.selected;this._selectedTemp=r,this.setState({selected:r},()=>this._selectedTemp=void 0)}}};ey.propTypes={children:B.node,selected:B.bool,togglable:B.bool,icon:B.string,svgIcon:dp,iconClass:B.string,imageUrl:B.string,imageAlt:B.string,size:B.oneOf([null,"small","medium","large"]),rounded:B.oneOf([null,"small","medium","large","full"]),fillMode:B.oneOf([null,"flat","link","outline","solid","clear"]),themeColor:B.oneOf([null,"base","primary","secondary","tertiary","info","success","warning","error","dark","light","inverse"])},ey.defaultProps={togglable:!1,size:"medium",rounded:"medium",fillMode:"solid",themeColor:"base"};let Jr=ey;/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const fC=t=>{const r=_.useCallback(a=>{t.onClick(a,t.index)},[t]),n=t.dataItem.render||t.item||(t.item===void 0?t.render:null),i=t.dataItem.text!==void 0?t.dataItem.text:t.textField?t.dataItem[t.textField]:t.dataItem,o=_.createElement("li",{id:t.id,className:Me("k-item",t.className,{"k-focus":t.focused}),tabIndex:-1,onClick:r,onMouseDown:t.onDown,onPointerDown:t.onDown,role:"menuitem","aria-disabled":t.dataItem.disabled||void 0},_.createElement("span",{tabIndex:-1,className:Me("k-link k-menu-link",{"k-selected":t.dataItem.selected,"k-disabled":t.dataItem.disabled}),key:"icon"},n?_.createElement(n,{item:t.dataItem,itemIndex:t.index}):_.createElement(_.Fragment,null,(t.dataItem.icon||t.dataItem.iconClass||t.dataItem.svgIcon)&&_.createElement(en,{className:t.dataItem.iconClass,name:t.dataItem.icon,icon:t.dataItem.svgIcon}),t.dataItem.imageUrl&&_.createElement("img",{role:"presentation",alt:"",src:t.dataItem.imageUrl,className:"k-icon"}),i&&_.createElement("span",{className:"k-menu-link-text"},i))));return t.item!==void 0&&t.render!==void 0?t.render.call(void 0,o,t):o};fC.displayName="KendoReactButtonItem";/** + */const vC=t=>{const r=_.useCallback(a=>{t.onClick(a,t.index)},[t]),n=t.dataItem.render||t.item||(t.item===void 0?t.render:null),i=t.dataItem.text!==void 0?t.dataItem.text:t.textField?t.dataItem[t.textField]:t.dataItem,o=_.createElement("li",{id:t.id,className:ke("k-item",t.className,{"k-focus":t.focused}),tabIndex:-1,onClick:r,onMouseDown:t.onDown,onPointerDown:t.onDown,role:"menuitem","aria-disabled":t.dataItem.disabled||void 0},_.createElement("span",{tabIndex:-1,className:ke("k-link k-menu-link",{"k-selected":t.dataItem.selected,"k-disabled":t.dataItem.disabled}),key:"icon"},n?_.createElement(n,{item:t.dataItem,itemIndex:t.index}):_.createElement(_.Fragment,null,(t.dataItem.icon||t.dataItem.iconClass||t.dataItem.svgIcon)&&_.createElement(Qi,{className:t.dataItem.iconClass,name:t.dataItem.icon,icon:t.dataItem.svgIcon}),t.dataItem.imageUrl&&_.createElement("img",{role:"presentation",alt:"",src:t.dataItem.imageUrl,className:"k-icon"}),i&&_.createElement("span",{className:"k-menu-link-text"},i))));return t.item!==void 0&&t.render!==void 0?t.render.call(void 0,o,t):o};vC.displayName="KendoReactButtonItem";/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const bO=class extends _.Component{render(){return null}};bO.propTypes={text:B.string,icon:B.string,iconClass:B.string,imageUrl:B.string,disabled:B.bool,render:B.any};let FVt=bO;/** + */const wO=class extends _.Component{render(){return null}};wO.propTypes={text:B.string,icon:B.string,iconClass:B.string,imageUrl:B.string,disabled:B.bool,render:B.any};let RVt=wO;/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const wO=(t,r,n,i)=>{if(n)return t;const o=Math.min(i-1,Math.max(0,t));switch(r){case Jt.enter:case Jt.space:case Jt.esc:return-1;case Jt.up:case Jt.left:return o-1<0?i-1:o-1;case Jt.down:case Jt.right:return o+1>=i?0:o+1;case Jt.home:return 0;case Jt.end:return i-1;default:return t}};/** + */const CO=(t,r,n,i)=>{if(n)return t;const o=Math.min(i-1,Math.max(0,t));switch(r){case te.enter:case te.space:case te.esc:return-1;case te.up:case te.left:return o-1<0?i-1:o-1;case te.down:case te.right:return o+1>=i?0:o+1;case te.home:return 0;case te.end:return i-1;default:return t}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */function CO(t){let r={horizontal:"left",vertical:"bottom"};return t&&(r.horizontal="right"),r}function SO(t){let r={horizontal:"left",vertical:"top"};return t&&(r.horizontal="right"),r}/** + */function SO(t){let r={horizontal:"left",vertical:"bottom"};return t&&(r.horizontal="right"),r}function zO(t){let r={horizontal:"left",vertical:"top"};return t&&(r.horizontal="right"),r}/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const ry=class extends _.Component{constructor(r){super(r),this.state={focused:!1,focusedIndex:-1,opened:!1},this.wrapper=null,this.mainButton=null,this.list=null,this.skipFocus=!1,this.buttonsData=[],this.onKeyDown=n=>{const{focusedIndex:i}=this.state;if(n.altKey){!this.opened&&n.keyCode===Jt.down?(n.preventDefault(),this.setState({focusedIndex:0}),this.setOpen(!0,n)):this.opened&&n.keyCode===Jt.up&&(n.preventDefault(),this.setState({focusedIndex:-1}),this.setOpen(!1,n));return}let o;if(n.keyCode===Jt.enter||n.keyCode===Jt.space){if(n.preventDefault(),this.dispatchClickEvent(n,i),i>=0){o={focusedIndex:this.opened?-1:0};const a=!this.opened;this.setOpen(a,n)}}else if(this.opened&&n.keyCode===Jt.esc){this.setState({focusedIndex:-1}),this.setOpen(!1,n);return}if(this.opened){const a=wO(i,n.keyCode,n.altKey,this.buttonsData.length);a!==i&&(o=o||{},o.focusedIndex=a);const s=n.keyCode===Jt.up||n.keyCode===Jt.down||n.keyCode===Jt.left||n.keyCode===Jt.right;!n.altKey&&(s||n.keyCode===Jt.home||n.keyCode===Jt.end)&&n.preventDefault()}o&&this.setState(o)},this.switchFocus=n=>{this.skipFocus=!0,n(),window.setTimeout(()=>this.skipFocus=!1,0)},this.onFocus=n=>{this.skipFocus||(fn(this.props.onFocus,n,this,void 0),this.setState({focused:!0}))},this.setOpen=(n,i)=>{this.opened!==n&&(this.openedDuringOnChange=n,this.setState({opened:n}),i?this.dispatchPopupEvent(i,n):this.openedDuringOnChange=void 0)},this.onItemClick=(n,i)=>{this.opened&&this.setState({focusedIndex:0}),this.dispatchClickEvent(n,i),this.setOpen(!1,n)},this.onBlur=n=>{this.skipFocus||(this.setState({focused:!1,focusedIndex:-1}),fn(this.props.onBlur,n,this,void 0),setTimeout(()=>{this.setOpen(!1,n)},0))},this.onPopupClose=n=>{var i;const o=Ki(document);this.element&&this.element.removeAttribute("tabindex"),(o===this.list||(i=this.list)!=null&&i.contains(o))&&this.switchFocus(()=>{this.element&&this.element.focus({preventScroll:!0})}),this.props.popupSettings&&this.props.popupSettings.onClose&&this.props.popupSettings.onClose.call(void 0,n)},this.listRef=n=>{this.list=n,n&&this.state.focused&&this.switchFocus(()=>{n.focus({preventScroll:!0}),this.element&&(this.element.tabIndex=-1)})},this.onSplitPartClick=n=>{if(this.buttonsData.length){const i=!this.opened;this.setState({focusedIndex:i?0:-1,focused:!0}),this.setOpen(i,n)}},this.onDownSplitPart=n=>{n.preventDefault();const i=Ki(document);this.element&&i!==this.element&&i!==this.list&&this.element.focus()},this.onItemDown=n=>{Ki(document)===this.list&&n.preventDefault()},this.dispatchPopupEvent=(n,i)=>{fn(i?this.props.onOpen:this.props.onClose,n,this,void 0),this.openedDuringOnChange=void 0},gi(dC)}get guid(){return this.props.id?this.props.id+"-accessibility-id":this.props.id}get opened(){return this.openedDuringOnChange!==void 0?this.openedDuringOnChange:this.props.opened===void 0?this.state.opened:this.props.opened}render(){this.buttonsData=this.props.items||_.Children.toArray(this.props.children).filter(l=>l&&l.type===FVt).map(l=>l.props);const r=this.isRtl(),n=r?"rtl":void 0,{id:i,style:o,tabIndex:a,disabled:s}=this.props;return _.createElement("div",{id:i,style:o,className:Me("k-split-button","k-button-group",{"k-focus":this.state.focused},`k-rounded-${Gr.roundedMap[this.props.rounded||"medium"]}`,this.props.className),onKeyDown:this.onKeyDown,onFocus:this.onFocus,onBlur:this.onBlur,dir:n,ref:l=>this.wrapper=l},_.createElement(ei,{ref:l=>this.mainButton=l&&l.element,type:"button",size:this.props.size,rounded:this.props.rounded,fillMode:this.props.fillMode,themeColor:this.props.themeColor,onClick:l=>this.onItemClick(l,-1),disabled:s||void 0,tabIndex:a,accessKey:this.props.accessKey,className:this.props.buttonClass,icon:this.props.icon,svgIcon:this.props.svgIcon,iconClass:this.props.iconClass,imageUrl:this.props.imageUrl,dir:n,"aria-disabled":s,"aria-haspopup":!0,"aria-expanded":this.opened||void 0,"aria-label":this.props.ariaLabel,"aria-controls":this.opened?this.guid:void 0,id:"button-"+this.guid,title:this.props.title},this.props.text),_.createElement(ei,{type:"button",size:this.props.size,rounded:this.props.rounded,fillMode:this.props.fillMode,themeColor:this.props.themeColor,icon:"caret-alt-down",svgIcon:Y0,className:"k-split-button-arrow",disabled:s||void 0,tabIndex:-1,onClick:this.onSplitPartClick,onMouseDown:this.onDownSplitPart,onPointerDown:this.onDownSplitPart,dir:n,"aria-label":"menu toggling button"}),this.renderPopup(r))}componentDidMount(){(this.props.dir===void 0&&this.isRtl()||this.opened)&&this.forceUpdate()}get element(){return this.mainButton}dispatchClickEvent(r,n){this.isItemDisabled(n)||(n===-1?fn(this.props.onButtonClick,r,this,void 0):fn(this.props.onItemClick,r,this,{item:this.buttonsData[n],itemIndex:n}))}renderPopup(r){const{popupSettings:n={}}=this.props,{focusedIndex:i}=this.state;return _.createElement(A4,{anchor:this.wrapper,show:this.opened,animate:n.animate,popupClass:Me("k-menu-popup",n.popupClass),anchorAlign:n.anchorAlign||CO(r),popupAlign:n.popupAlign||SO(r),style:r?{direction:"rtl"}:void 0,onClose:this.onPopupClose},_.createElement("ul",{role:"menu",id:this.guid,"aria-labelledby":"button-"+this.guid,tabIndex:-1,ref:this.listRef,"aria-activedescendant":i>=0?`${this.guid}-${i}`:void 0,className:Me("k-menu-group",{[`k-menu-group-${Gr.sizeMap[this.props.size]||this.props.size}`]:this.props.size})},this.renderChildItems()))}renderChildItems(){const{item:r,itemRender:n,textField:i}=this.props;return this.buttonsData.length>0?this.buttonsData.map((o,a)=>_.createElement(fC,{className:"k-menu-item",dataItem:o,textField:i,focused:this.state.focusedIndex===a,onClick:this.onItemClick,onDown:this.onItemDown,render:n,item:r,key:a,index:a,id:`${this.guid}-${a}`})):null}isItemDisabled(r){return this.buttonsData[r]?this.buttonsData[r].disabled:this.props.disabled}isRtl(){return this.props.dir!==void 0?this.props.dir==="rtl":!!this.wrapper&&getComputedStyle(this.wrapper).direction==="rtl"}};ry.propTypes={accessKey:B.string,ariaLabel:B.string,title:B.string,onButtonClick:B.func,onFocus:B.func,onBlur:B.func,onItemClick:B.func,onOpen:B.func,onClose:B.func,text:B.string,items:B.arrayOf(B.any),textField:B.string,tabIndex:B.number,disabled:B.bool,icon:B.string,svgIcon:dp,iconClass:B.string,imageUrl:B.string,popupSettings:B.object,itemRender:B.any,item:B.func,className:B.string,buttonClass:B.string,dir:B.string},ry.defaultProps={size:"medium",rounded:"medium",fillMode:"solid",themeColor:"base"};let RVt=ry;/** + */const ry=class extends _.Component{constructor(r){super(r),this.state={focused:!1,focusedIndex:-1,opened:!1},this.wrapper=null,this.mainButton=null,this.list=null,this.skipFocus=!1,this.buttonsData=[],this.onKeyDown=n=>{const{focusedIndex:i}=this.state;if(n.altKey){!this.opened&&n.keyCode===te.down?(n.preventDefault(),this.setState({focusedIndex:0}),this.setOpen(!0,n)):this.opened&&n.keyCode===te.up&&(n.preventDefault(),this.setState({focusedIndex:-1}),this.setOpen(!1,n));return}let o;if(n.keyCode===te.enter||n.keyCode===te.space){if(n.preventDefault(),this.dispatchClickEvent(n,i),i>=0){o={focusedIndex:this.opened?-1:0};const a=!this.opened;this.setOpen(a,n)}}else if(this.opened&&n.keyCode===te.esc){this.setState({focusedIndex:-1}),this.setOpen(!1,n);return}if(this.opened){const a=CO(i,n.keyCode,n.altKey,this.buttonsData.length);a!==i&&(o=o||{},o.focusedIndex=a);const s=n.keyCode===te.up||n.keyCode===te.down||n.keyCode===te.left||n.keyCode===te.right;!n.altKey&&(s||n.keyCode===te.home||n.keyCode===te.end)&&n.preventDefault()}o&&this.setState(o)},this.switchFocus=n=>{this.skipFocus=!0,n(),window.setTimeout(()=>this.skipFocus=!1,0)},this.onFocus=n=>{this.skipFocus||(pn(this.props.onFocus,n,this,void 0),this.setState({focused:!0}))},this.setOpen=(n,i)=>{this.opened!==n&&(this.openedDuringOnChange=n,this.setState({opened:n}),i?this.dispatchPopupEvent(i,n):this.openedDuringOnChange=void 0)},this.onItemClick=(n,i)=>{this.opened&&this.setState({focusedIndex:0}),this.dispatchClickEvent(n,i),this.setOpen(!1,n)},this.onBlur=n=>{this.skipFocus||(this.setState({focused:!1,focusedIndex:-1}),pn(this.props.onBlur,n,this,void 0),setTimeout(()=>{this.setOpen(!1,n)},0))},this.onPopupClose=n=>{var i;const o=Yi(document);this.element&&this.element.removeAttribute("tabindex"),(o===this.list||(i=this.list)!=null&&i.contains(o))&&this.switchFocus(()=>{this.element&&this.element.focus({preventScroll:!0})}),this.props.popupSettings&&this.props.popupSettings.onClose&&this.props.popupSettings.onClose.call(void 0,n)},this.listRef=n=>{this.list=n,n&&this.state.focused&&this.switchFocus(()=>{n.focus({preventScroll:!0}),this.element&&(this.element.tabIndex=-1)})},this.onSplitPartClick=n=>{if(this.buttonsData.length){const i=!this.opened;this.setState({focusedIndex:i?0:-1,focused:!0}),this.setOpen(i,n)}},this.onDownSplitPart=n=>{n.preventDefault();const i=Yi(document);this.element&&i!==this.element&&i!==this.list&&this.element.focus()},this.onItemDown=n=>{Yi(document)===this.list&&n.preventDefault()},this.dispatchPopupEvent=(n,i)=>{pn(i?this.props.onOpen:this.props.onClose,n,this,void 0),this.openedDuringOnChange=void 0},vi(fC)}get guid(){return this.props.id?this.props.id+"-accessibility-id":this.props.id}get opened(){return this.openedDuringOnChange!==void 0?this.openedDuringOnChange:this.props.opened===void 0?this.state.opened:this.props.opened}render(){this.buttonsData=this.props.items||_.Children.toArray(this.props.children).filter(l=>l&&l.type===RVt).map(l=>l.props);const r=this.isRtl(),n=r?"rtl":void 0,{id:i,style:o,tabIndex:a,disabled:s}=this.props;return _.createElement("div",{id:i,style:o,className:ke("k-split-button","k-button-group",{"k-focus":this.state.focused},`k-rounded-${Wr.roundedMap[this.props.rounded||"medium"]}`,this.props.className),onKeyDown:this.onKeyDown,onFocus:this.onFocus,onBlur:this.onBlur,dir:n,ref:l=>this.wrapper=l},_.createElement(Jr,{ref:l=>this.mainButton=l&&l.element,type:"button",size:this.props.size,rounded:this.props.rounded,fillMode:this.props.fillMode,themeColor:this.props.themeColor,onClick:l=>this.onItemClick(l,-1),disabled:s||void 0,tabIndex:a,accessKey:this.props.accessKey,className:this.props.buttonClass,icon:this.props.icon,svgIcon:this.props.svgIcon,iconClass:this.props.iconClass,imageUrl:this.props.imageUrl,dir:n,"aria-disabled":s,"aria-haspopup":!0,"aria-expanded":this.opened||void 0,"aria-label":this.props.ariaLabel,"aria-controls":this.opened?this.guid:void 0,id:"button-"+this.guid,title:this.props.title},this.props.text),_.createElement(Jr,{type:"button",size:this.props.size,rounded:this.props.rounded,fillMode:this.props.fillMode,themeColor:this.props.themeColor,icon:"caret-alt-down",svgIcon:Y0,className:"k-split-button-arrow",disabled:s||void 0,tabIndex:-1,onClick:this.onSplitPartClick,onMouseDown:this.onDownSplitPart,onPointerDown:this.onDownSplitPart,dir:n,"aria-label":"menu toggling button"}),this.renderPopup(r))}componentDidMount(){(this.props.dir===void 0&&this.isRtl()||this.opened)&&this.forceUpdate()}get element(){return this.mainButton}dispatchClickEvent(r,n){this.isItemDisabled(n)||(n===-1?pn(this.props.onButtonClick,r,this,void 0):pn(this.props.onItemClick,r,this,{item:this.buttonsData[n],itemIndex:n}))}renderPopup(r){const{popupSettings:n={}}=this.props,{focusedIndex:i}=this.state;return _.createElement(A4,{anchor:this.wrapper,show:this.opened,animate:n.animate,popupClass:ke("k-menu-popup",n.popupClass),anchorAlign:n.anchorAlign||SO(r),popupAlign:n.popupAlign||zO(r),style:r?{direction:"rtl"}:void 0,onClose:this.onPopupClose},_.createElement("ul",{role:"menu",id:this.guid,"aria-labelledby":"button-"+this.guid,tabIndex:-1,ref:this.listRef,"aria-activedescendant":i>=0?`${this.guid}-${i}`:void 0,className:ke("k-menu-group",{[`k-menu-group-${Wr.sizeMap[this.props.size]||this.props.size}`]:this.props.size})},this.renderChildItems()))}renderChildItems(){const{item:r,itemRender:n,textField:i}=this.props;return this.buttonsData.length>0?this.buttonsData.map((o,a)=>_.createElement(vC,{className:"k-menu-item",dataItem:o,textField:i,focused:this.state.focusedIndex===a,onClick:this.onItemClick,onDown:this.onItemDown,render:n,item:r,key:a,index:a,id:`${this.guid}-${a}`})):null}isItemDisabled(r){return this.buttonsData[r]?this.buttonsData[r].disabled:this.props.disabled}isRtl(){return this.props.dir!==void 0?this.props.dir==="rtl":!!this.wrapper&&getComputedStyle(this.wrapper).direction==="rtl"}};ry.propTypes={accessKey:B.string,ariaLabel:B.string,title:B.string,onButtonClick:B.func,onFocus:B.func,onBlur:B.func,onItemClick:B.func,onOpen:B.func,onClose:B.func,text:B.string,items:B.arrayOf(B.any),textField:B.string,tabIndex:B.number,disabled:B.bool,icon:B.string,svgIcon:dp,iconClass:B.string,imageUrl:B.string,popupSettings:B.object,itemRender:B.any,item:B.func,className:B.string,buttonClass:B.string,dir:B.string},ry.defaultProps={size:"medium",rounded:"medium",fillMode:"solid",themeColor:"base"};let OVt=ry;/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const zO=class extends _.Component{render(){return null}};zO.propTypes={text:B.string,icon:B.string,iconClass:B.string,imageUrl:B.string,selected:B.bool,disabled:B.bool,render:B.any};let OVt=zO;/** + */const MO=class extends _.Component{render(){return null}};MO.propTypes={text:B.string,icon:B.string,iconClass:B.string,imageUrl:B.string,selected:B.bool,disabled:B.bool,render:B.any};let BVt=MO;/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const iy=class extends _.Component{constructor(r){super(r),this.state={opened:!1,focused:!1,focusedIndex:-1},this.mainButton=null,this.list=null,this.skipFocus=!1,this.buttonsData=[],this.onKeyDown=n=>{const{focusedIndex:i}=this.state;if(n.altKey){!this.opened&&n.keyCode===Jt.down?(n.preventDefault(),this.setOpen(!0,n),this.setState({focusedIndex:0})):this.opened&&n.keyCode===Jt.up&&(n.preventDefault(),this.setState({focusedIndex:-1}),this.setOpen(!1,n));return}const o={...this.state};if(n.keyCode===Jt.enter||n.keyCode===Jt.space){n.preventDefault(),i>=0&&this.dispatchClickEvent(n,i);const a=!this.opened;this.setState({focused:!0,focusedIndex:a?0:-1}),this.setOpen(a,n);return}if(this.opened&&n.keyCode===Jt.esc){this.setState({focusedIndex:-1}),this.setOpen(!1,n);return}if(this.opened){const a=wO(i,n.keyCode,n.altKey,this.buttonsData.length);o.focusedIndex=a;const s=n.keyCode===Jt.up||n.keyCode===Jt.down||n.keyCode===Jt.left||n.keyCode===Jt.right;!n.altKey&&(s||n.keyCode===Jt.home||n.keyCode===Jt.end)&&n.preventDefault()}this.setState(o)},this.switchFocus=n=>{this.skipFocus=!0,n(),window.setTimeout(()=>this.skipFocus=!1,0)},this.handleFocus=n=>{this.skipFocus||(this.setState({focused:!0,focusedIndex:this.opened?0:-1}),fn(this.props.onFocus,n,this,void 0))},this.handleButtonBlur=n=>{this.opened||(this.setState({focused:!1}),fn(this.props.onBlur,n,this,void 0))},this.handleMenuBlur=n=>{this.skipFocus||(this.setState({focused:!1,focusedIndex:-1}),fn(this.props.onBlur,n,this,void 0),setTimeout(()=>{this.setOpen(!1,n)},0))},this.setOpen=(n,i)=>{this.opened!==n&&(this.openedDuringOnChange=n,this.setState({opened:n}),i?this.dispatchPopupEvent(i,n):this.openedDuringOnChange=void 0)},this.onItemClick=(n,i)=>{this.setState({focusedIndex:-1}),this.dispatchClickEvent(n,i),this.setOpen(!1,n)},this.onItemDown=n=>{Ki(document)===this.list&&n.preventDefault()},this.mouseDown=n=>{n.preventDefault();const i=Ki(document);this.element&&i!==this.element&&i!==this.list&&this.element.focus()},this.onPopupClose=n=>{var i;const o=Ki(document);this.element&&this.element.removeAttribute("tabindex"),(o===this.list||(i=this.list)!=null&&i.contains(o))&&this.switchFocus(()=>{this.element&&this.element.focus({preventScroll:!0})}),this.props.popupSettings&&this.props.popupSettings.onClose&&this.props.popupSettings.onClose.call(void 0,n)},this.listRef=n=>{this.list=n,n&&this.state.focused&&this.switchFocus(()=>{n.focus({preventScroll:!0}),this.element&&(this.element.tabIndex=-1)})},this.onClickMainButton=n=>{if(!this.buttonsData.length)return;const i=!this.opened;this.setState({focused:!0,focusedIndex:i?0:-1}),this.setOpen(i,n)},this.dispatchPopupEvent=(n,i)=>{fn(i?this.props.onOpen:this.props.onClose,n,this,void 0),this.openedDuringOnChange=void 0},gi(dC)}get guid(){return this.props.id+"-accessibility-id"}get opened(){return this.openedDuringOnChange!==void 0?this.openedDuringOnChange:this.props.opened===void 0?this.state.opened:this.props.opened}render(){const r=this.isRtl(),n=r?"rtl":void 0,{id:i,style:o,tabIndex:a,disabled:s,size:l,rounded:h,fillMode:p,themeColor:f,ariaLabel:g,title:b,accessKey:z,icon:M,svgIcon:I,iconClass:F,buttonClass:H,className:E,imageUrl:R,startIcon:W,endIcon:$}=this.props;return this.buttonsData=this.props.items||_.Children.toArray(this.props.children).filter(G=>G&&G.type===OVt).map(G=>G.props),_.createElement(_.Fragment,null,_.createElement(ei,{id:i,size:l,style:o,rounded:h,fillMode:p,themeColor:f,onClick:this.onClickMainButton,onMouseDown:this.mouseDown,onKeyDown:this.onKeyDown,onFocus:this.handleFocus,onBlur:this.handleButtonBlur,"aria-disabled":s?"true":void 0,tabIndex:a,accessKey:z,icon:M,svgIcon:I,iconClass:F,className:Me(H,E,"k-menu-button",{"k-focus":this.state.focused},{"k-disabled":s}),imageUrl:R,dir:n,ref:G=>this.mainButton=G&&G.element,type:"button","aria-haspopup":"true","aria-expanded":this.opened?"true":"false","aria-label":g,"aria-controls":this.opened?this.guid:void 0,title:b,startIcon:W,endIcon:$},this.props.text),this.renderPopup(r))}componentDidMount(){(this.props.dir===void 0&&this.isRtl()||this.opened)&&this.forceUpdate()}get element(){return this.mainButton}dispatchClickEvent(r,n){this.isItemDisabled(n)||fn(this.props.onItemClick,r,this,{item:this.buttonsData[n],itemIndex:n})}renderPopup(r){const{popupSettings:n={},id:i}=this.props,{focusedIndex:o}=this.state;return _.createElement(A4,{anchor:this.mainButton,show:this.opened,animate:n.animate,popupClass:Me("k-menu-popup",n.popupClass),anchorAlign:n.anchorAlign||CO(r),popupAlign:n.popupAlign||SO(r),style:r?{direction:"rtl"}:void 0,onClose:this.onPopupClose},_.createElement("ul",{role:"list",id:this.guid,tabIndex:-1,"aria-activedescendant":o>=0?`${this.guid}-${o}`:void 0,ref:this.listRef,onKeyDown:this.onKeyDown,onBlur:this.handleMenuBlur,className:Me("k-menu-group",{[`k-menu-group-${Gr.sizeMap[this.props.size]||this.props.size}`]:this.props.size})},this.renderChildItems()))}renderChildItems(){const{item:r,itemRender:n,textField:i}=this.props;return this.buttonsData.length>0?this.buttonsData.map((o,a)=>_.createElement(fC,{className:"k-menu-item",dataItem:o,textField:i,focused:this.state.focusedIndex===a,onClick:this.onItemClick,onDown:this.onItemDown,render:n,item:r,index:a,key:a,id:`${this.guid}-${a}`})):null}isItemDisabled(r){return this.buttonsData[r]?this.buttonsData[r].disabled:this.props.disabled}isRtl(){return this.props.dir!==void 0?this.props.dir==="rtl":!!this.mainButton&&getComputedStyle(this.mainButton).direction==="rtl"}};iy.propTypes={accessKey:B.string,ariaLabel:B.string,title:B.string,onFocus:B.func,onBlur:B.func,onItemClick:B.func,onOpen:B.func,onClose:B.func,items:B.arrayOf(B.any),textField:B.string,tabIndex:B.number,disabled:B.bool,icon:B.string,svgIcon:dp,iconClass:B.string,imageUrl:B.string,popupSettings:B.object,itemRender:B.func,item:B.func,className:B.string,buttonClass:B.string,dir:B.string},iy.defaultProps={size:"medium",rounded:"medium",fillMode:"solid",themeColor:"base"};let BVt=iy;/** + */const iy=class extends _.Component{constructor(r){super(r),this.state={opened:!1,focused:!1,focusedIndex:-1},this.mainButton=null,this.list=null,this.skipFocus=!1,this.buttonsData=[],this.onKeyDown=n=>{const{focusedIndex:i}=this.state;if(n.altKey){!this.opened&&n.keyCode===te.down?(n.preventDefault(),this.setOpen(!0,n),this.setState({focusedIndex:0})):this.opened&&n.keyCode===te.up&&(n.preventDefault(),this.setState({focusedIndex:-1}),this.setOpen(!1,n));return}const o={...this.state};if(n.keyCode===te.enter||n.keyCode===te.space){n.preventDefault(),i>=0&&this.dispatchClickEvent(n,i);const a=!this.opened;this.setState({focused:!0,focusedIndex:a?0:-1}),this.setOpen(a,n);return}if(this.opened&&n.keyCode===te.esc){this.setState({focusedIndex:-1}),this.setOpen(!1,n);return}if(this.opened){const a=CO(i,n.keyCode,n.altKey,this.buttonsData.length);o.focusedIndex=a;const s=n.keyCode===te.up||n.keyCode===te.down||n.keyCode===te.left||n.keyCode===te.right;!n.altKey&&(s||n.keyCode===te.home||n.keyCode===te.end)&&n.preventDefault()}this.setState(o)},this.switchFocus=n=>{this.skipFocus=!0,n(),window.setTimeout(()=>this.skipFocus=!1,0)},this.handleFocus=n=>{this.skipFocus||(this.setState({focused:!0,focusedIndex:this.opened?0:-1}),pn(this.props.onFocus,n,this,void 0))},this.handleButtonBlur=n=>{this.opened||(this.setState({focused:!1}),pn(this.props.onBlur,n,this,void 0))},this.handleMenuBlur=n=>{this.skipFocus||(this.setState({focused:!1,focusedIndex:-1}),pn(this.props.onBlur,n,this,void 0),setTimeout(()=>{this.setOpen(!1,n)},0))},this.setOpen=(n,i)=>{this.opened!==n&&(this.openedDuringOnChange=n,this.setState({opened:n}),i?this.dispatchPopupEvent(i,n):this.openedDuringOnChange=void 0)},this.onItemClick=(n,i)=>{this.setState({focusedIndex:-1}),this.dispatchClickEvent(n,i),this.setOpen(!1,n)},this.onItemDown=n=>{Yi(document)===this.list&&n.preventDefault()},this.mouseDown=n=>{n.preventDefault();const i=Yi(document);this.element&&i!==this.element&&i!==this.list&&this.element.focus()},this.onPopupClose=n=>{var i;const o=Yi(document);this.element&&this.element.removeAttribute("tabindex"),(o===this.list||(i=this.list)!=null&&i.contains(o))&&this.switchFocus(()=>{this.element&&this.element.focus({preventScroll:!0})}),this.props.popupSettings&&this.props.popupSettings.onClose&&this.props.popupSettings.onClose.call(void 0,n)},this.listRef=n=>{this.list=n,n&&this.state.focused&&this.switchFocus(()=>{n.focus({preventScroll:!0}),this.element&&(this.element.tabIndex=-1)})},this.onClickMainButton=n=>{if(!this.buttonsData.length)return;const i=!this.opened;this.setState({focused:!0,focusedIndex:i?0:-1}),this.setOpen(i,n)},this.dispatchPopupEvent=(n,i)=>{pn(i?this.props.onOpen:this.props.onClose,n,this,void 0),this.openedDuringOnChange=void 0},vi(fC)}get guid(){return this.props.id+"-accessibility-id"}get opened(){return this.openedDuringOnChange!==void 0?this.openedDuringOnChange:this.props.opened===void 0?this.state.opened:this.props.opened}render(){const r=this.isRtl(),n=r?"rtl":void 0,{id:i,style:o,tabIndex:a,disabled:s,size:l,rounded:h,fillMode:p,themeColor:f,ariaLabel:g,title:b,accessKey:z,icon:M,svgIcon:I,iconClass:F,buttonClass:H,className:E,imageUrl:R,startIcon:W,endIcon:$}=this.props;return this.buttonsData=this.props.items||_.Children.toArray(this.props.children).filter(G=>G&&G.type===BVt).map(G=>G.props),_.createElement(_.Fragment,null,_.createElement(Jr,{id:i,size:l,style:o,rounded:h,fillMode:p,themeColor:f,onClick:this.onClickMainButton,onMouseDown:this.mouseDown,onKeyDown:this.onKeyDown,onFocus:this.handleFocus,onBlur:this.handleButtonBlur,"aria-disabled":s?"true":void 0,tabIndex:a,accessKey:z,icon:M,svgIcon:I,iconClass:F,className:ke(H,E,"k-menu-button",{"k-focus":this.state.focused},{"k-disabled":s}),imageUrl:R,dir:n,ref:G=>this.mainButton=G&&G.element,type:"button","aria-haspopup":"true","aria-expanded":this.opened?"true":"false","aria-label":g,"aria-controls":this.opened?this.guid:void 0,title:b,startIcon:W,endIcon:$},this.props.text),this.renderPopup(r))}componentDidMount(){(this.props.dir===void 0&&this.isRtl()||this.opened)&&this.forceUpdate()}get element(){return this.mainButton}dispatchClickEvent(r,n){this.isItemDisabled(n)||pn(this.props.onItemClick,r,this,{item:this.buttonsData[n],itemIndex:n})}renderPopup(r){const{popupSettings:n={},id:i}=this.props,{focusedIndex:o}=this.state;return _.createElement(A4,{anchor:this.mainButton,show:this.opened,animate:n.animate,popupClass:ke("k-menu-popup",n.popupClass),anchorAlign:n.anchorAlign||SO(r),popupAlign:n.popupAlign||zO(r),style:r?{direction:"rtl"}:void 0,onClose:this.onPopupClose},_.createElement("ul",{role:"list",id:this.guid,tabIndex:-1,"aria-activedescendant":o>=0?`${this.guid}-${o}`:void 0,ref:this.listRef,onKeyDown:this.onKeyDown,onBlur:this.handleMenuBlur,className:ke("k-menu-group",{[`k-menu-group-${Wr.sizeMap[this.props.size]||this.props.size}`]:this.props.size})},this.renderChildItems()))}renderChildItems(){const{item:r,itemRender:n,textField:i}=this.props;return this.buttonsData.length>0?this.buttonsData.map((o,a)=>_.createElement(vC,{className:"k-menu-item",dataItem:o,textField:i,focused:this.state.focusedIndex===a,onClick:this.onItemClick,onDown:this.onItemDown,render:n,item:r,index:a,key:a,id:`${this.guid}-${a}`})):null}isItemDisabled(r){return this.buttonsData[r]?this.buttonsData[r].disabled:this.props.disabled}isRtl(){return this.props.dir!==void 0?this.props.dir==="rtl":!!this.mainButton&&getComputedStyle(this.mainButton).direction==="rtl"}};iy.propTypes={accessKey:B.string,ariaLabel:B.string,title:B.string,onFocus:B.func,onBlur:B.func,onItemClick:B.func,onOpen:B.func,onClose:B.func,items:B.arrayOf(B.any),textField:B.string,tabIndex:B.number,disabled:B.bool,icon:B.string,svgIcon:dp,iconClass:B.string,imageUrl:B.string,popupSettings:B.object,itemRender:B.func,item:B.func,className:B.string,buttonClass:B.string,dir:B.string},iy.defaultProps={size:"medium",rounded:"medium",fillMode:"solid",themeColor:"base"};let NVt=iy;/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const NVt=na(BVt);NVt.displayName="KendoReactDropDownButton";const $Vt=na(RVt);$Vt.displayName="KendoReactSplitButton";/** + */const $Vt=ra(NVt);$Vt.displayName="KendoReactDropDownButton";const WVt=ra(OVt);WVt.displayName="KendoReactSplitButton";/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const ny="prevArrow.title",oy="nextArrow.title",cE={[ny]:"Previous tab arrow",[oy]:"Next tab arrow"};/** + */const ny="prevArrow.title",oy="nextArrow.title",hE={[ny]:"Previous tab arrow",[oy]:"Next tab arrow"};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const WVt=t=>Array.apply(null,Array(t)),jVt=t=>t.preventDefault(),U6="smooth",$4="prev",Y6="next",MO=class extends _.Component{constructor(r){super(r),this.itemsNavRef=_.createRef(),this.isRtl=()=>this.props.dir==="rtl",this.onWheel=n=>{n.stopPropagation();const i=n.deltaY<0?$4:Y6;this.setNewScrollPosition(i,n)},this.arrowClickPrev=n=>{this.handleArrowClick($4,n)},this.arrowClickNext=n=>{this.handleArrowClick(Y6,n)},this.handleArrowClick=(n,i)=>{this.setNewScrollPosition(n,i)},this.setNewScrollPosition=(n,i)=>{const o=this.itemsNavRef.current;if(!o)return;const a=this.horizontalScroll(),s=a?o.scrollWidth-o.offsetWidth:o.scrollHeight-o.offsetHeight,l=(i.type==="click"?this.props.buttonScrollSpeed:this.props.mouseScrollSpeed)||0;let h=a?o.scrollLeft:o.scrollTop,p=a?o.scrollWidth-o.scrollLeft:o.scrollHeight-o.scrollTop,f=o.scrollWidth-o.scrollLeft*-1;this.isRtl()&&this.horizontalScroll()?(n===$4&&h<0&&(h+=l,f+=l),n===Y6&&h0&&(h-=l,p+=l),n===Y6&&h{const o=this.horizontalScroll(),a=si(this),s={prev:{arrowTab:"k-tabstrip-prev",fontIcon:o?this.isRtl()?"caret-alt-right":"caret-alt-left":"caret-alt-up",svgIcon:o?this.isRtl()?Dl:Pl:uC,title:a.toLanguageString(ny,cE[ny])},next:{arrowTab:"k-tabstrip-next",fontIcon:o?this.isRtl()?"caret-alt-left":"caret-alt-right":"caret-alt-down",svgIcon:o?this.isRtl()?Pl:Dl:Y0,title:a.toLanguageString(oy,cE[oy])}},l=(n===$4?this.props.prevButton:this.props.nextButton)||ei,h=n===$4?this.arrowClickPrev:this.arrowClickNext;return _.createElement(l,{disabled:i,className:`${s[n].arrowTab}`,onClick:h,icon:s[n].fontIcon,svgIcon:s[n].svgIcon,onMouseDown:jVt,tabIndex:-1,fillMode:"flat",title:s[n].title})},this.state={disabledPrev:this.props.selected===0,disabledNext:this.props.selected===_.Children.count(this.props.children)-1}}componentDidMount(){this.props.scrollable&&this.scrollToSelected()}componentDidUpdate(r){const{scrollable:n,selected:i}=this.props;n&&r.selected!==i&&(this.scrollToSelected(),this.setState({disabledPrev:i===0,disabledNext:i===_.Children.count(this.props.children)-1}))}render(){const{selected:r,tabPosition:n,children:i,onSelect:o,onKeyDown:a,navItemId:s,contentPanelId:l,renderAllContent:h}=this.props,p=_.Children.count(i),f=_.Children.toArray(i);let g;i&&(g=WVt(p).map((M,I,F)=>{const H={active:r===I,disabled:f[I].props.disabled,index:I,title:f[I].props.title,first:I===0,last:I===F.length-1,contentPanelId:l,renderAllContent:h,id:s,onSelect:o};return _.createElement(TVt,{key:I,...H})}));const b=Me("k-tabstrip-items-wrapper",{"k-hstack":n==="top"||n==="bottom","k-vstack":n==="left"||n==="right"}),z=Me("k-tabstrip-items","k-reset");return _.createElement("div",{className:b},this.props.scrollable?_.createElement(_.Fragment,null,this.renderArrow($4,this.state.disabledPrev),_.createElement("ul",{ref:this.itemsNavRef,className:z,role:"tablist",tabIndex:this.props.tabIndex,onKeyDown:a,onWheel:this.onWheel,"aria-orientation":n==="left"||n==="right"?"vertical":void 0},g),this.renderArrow(Y6,this.state.disabledNext)):_.createElement("ul",{className:z,role:"tablist",tabIndex:this.props.tabIndex,onKeyDown:a},g))}scrollToSelected(){const r=this.itemsNavRef.current,n=r&&r.children[this.props.selected||0];if(n instanceof HTMLElement&&r instanceof HTMLElement){const i=this.horizontalScroll(),o=i?r.offsetWidth:r.offsetHeight,a=i?n.offsetWidth:n.offsetHeight,s=i?"left":"top";let l=i?r.scrollLeft:r.scrollTop,h=0;if(this.isRtl()){const p=n.offsetLeft;l=l*-1,p<0?(h=p-a+r.offsetLeft,r.scrollTo({[s]:h,behavior:U6})):p+a>o-l&&(h=l+p-a,r.scrollTo({[s]:h,behavior:U6}))}else{const p=i?n.offsetLeft-r.offsetLeft:n.offsetTop-r.offsetTop;l+op&&(h=p,r.scrollTo({[s]:h,behavior:U6}))}}}horizontalScroll(){return/top|bottom/.test(this.props.tabPosition||"top")}};MO.propTypes={children:B.oneOfType([B.element,B.arrayOf(B.element)]),onSelect:B.func,onKeyDown:B.func,selected:B.number,tabIndex:B.number};let hE=MO;/** + */const jVt=t=>Array.apply(null,Array(t)),GVt=t=>t.preventDefault(),U6="smooth",$4="prev",Y6="next",kO=class extends _.Component{constructor(r){super(r),this.itemsNavRef=_.createRef(),this.isRtl=()=>this.props.dir==="rtl",this.onWheel=n=>{n.stopPropagation();const i=n.deltaY<0?$4:Y6;this.setNewScrollPosition(i,n)},this.arrowClickPrev=n=>{this.handleArrowClick($4,n)},this.arrowClickNext=n=>{this.handleArrowClick(Y6,n)},this.handleArrowClick=(n,i)=>{this.setNewScrollPosition(n,i)},this.setNewScrollPosition=(n,i)=>{const o=this.itemsNavRef.current;if(!o)return;const a=this.horizontalScroll(),s=a?o.scrollWidth-o.offsetWidth:o.scrollHeight-o.offsetHeight,l=(i.type==="click"?this.props.buttonScrollSpeed:this.props.mouseScrollSpeed)||0;let h=a?o.scrollLeft:o.scrollTop,p=a?o.scrollWidth-o.scrollLeft:o.scrollHeight-o.scrollTop,f=o.scrollWidth-o.scrollLeft*-1;this.isRtl()&&this.horizontalScroll()?(n===$4&&h<0&&(h+=l,f+=l),n===Y6&&h0&&(h-=l,p+=l),n===Y6&&h{const o=this.horizontalScroll(),a=ai(this),s={prev:{arrowTab:"k-tabstrip-prev",fontIcon:o?this.isRtl()?"caret-alt-right":"caret-alt-left":"caret-alt-up",svgIcon:o?this.isRtl()?Dl:Pl:pC,title:a.toLanguageString(ny,hE[ny])},next:{arrowTab:"k-tabstrip-next",fontIcon:o?this.isRtl()?"caret-alt-left":"caret-alt-right":"caret-alt-down",svgIcon:o?this.isRtl()?Pl:Dl:Y0,title:a.toLanguageString(oy,hE[oy])}},l=(n===$4?this.props.prevButton:this.props.nextButton)||Jr,h=n===$4?this.arrowClickPrev:this.arrowClickNext;return _.createElement(l,{disabled:i,className:`${s[n].arrowTab}`,onClick:h,icon:s[n].fontIcon,svgIcon:s[n].svgIcon,onMouseDown:GVt,tabIndex:-1,fillMode:"flat",title:s[n].title})},this.state={disabledPrev:this.props.selected===0,disabledNext:this.props.selected===_.Children.count(this.props.children)-1}}componentDidMount(){this.props.scrollable&&this.scrollToSelected()}componentDidUpdate(r){const{scrollable:n,selected:i}=this.props;n&&r.selected!==i&&(this.scrollToSelected(),this.setState({disabledPrev:i===0,disabledNext:i===_.Children.count(this.props.children)-1}))}render(){const{selected:r,tabPosition:n,children:i,onSelect:o,onKeyDown:a,navItemId:s,contentPanelId:l,renderAllContent:h}=this.props,p=_.Children.count(i),f=_.Children.toArray(i);let g;i&&(g=jVt(p).map((M,I,F)=>{const H={active:r===I,disabled:f[I].props.disabled,index:I,title:f[I].props.title,first:I===0,last:I===F.length-1,contentPanelId:l,renderAllContent:h,id:s,onSelect:o};return _.createElement(VVt,{key:I,...H})}));const b=ke("k-tabstrip-items-wrapper",{"k-hstack":n==="top"||n==="bottom","k-vstack":n==="left"||n==="right"}),z=ke("k-tabstrip-items","k-reset");return _.createElement("div",{className:b},this.props.scrollable?_.createElement(_.Fragment,null,this.renderArrow($4,this.state.disabledPrev),_.createElement("ul",{ref:this.itemsNavRef,className:z,role:"tablist",tabIndex:this.props.tabIndex,onKeyDown:a,onWheel:this.onWheel,"aria-orientation":n==="left"||n==="right"?"vertical":void 0},g),this.renderArrow(Y6,this.state.disabledNext)):_.createElement("ul",{className:z,role:"tablist",tabIndex:this.props.tabIndex,onKeyDown:a},g))}scrollToSelected(){const r=this.itemsNavRef.current,n=r&&r.children[this.props.selected||0];if(n instanceof HTMLElement&&r instanceof HTMLElement){const i=this.horizontalScroll(),o=i?r.offsetWidth:r.offsetHeight,a=i?n.offsetWidth:n.offsetHeight,s=i?"left":"top";let l=i?r.scrollLeft:r.scrollTop,h=0;if(this.isRtl()){const p=n.offsetLeft;l=l*-1,p<0?(h=p-a+r.offsetLeft,r.scrollTo({[s]:h,behavior:U6})):p+a>o-l&&(h=l+p-a,r.scrollTo({[s]:h,behavior:U6}))}else{const p=i?n.offsetLeft-r.offsetLeft:n.offsetTop-r.offsetTop;l+op&&(h=p,r.scrollTo({[s]:h,behavior:U6}))}}}horizontalScroll(){return/top|bottom/.test(this.props.tabPosition||"top")}};kO.propTypes={children:B.oneOfType([B.element,B.arrayOf(B.element)]),onSelect:B.func,onKeyDown:B.func,selected:B.number,tabIndex:B.number};let uE=kO;/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const GVt=t=>{if(!t||!t.ownerDocument.defaultView)return 0;const r=t.ownerDocument.defaultView.getComputedStyle(t),n=parseFloat(r.marginTop),i=parseFloat(r.marginBottom);return t.offsetHeight+n+i},UVt=t=>{if(!t||!t.ownerDocument.defaultView)return 0;const r=t.ownerDocument.defaultView.getComputedStyle(t),n=parseFloat(r.marginLeft),i=parseFloat(r.marginRight);return t.offsetWidth+n+i},YVt={"animation-container":"k-animation-container","animation-container-shown":"k-animation-container-shown","animation-container-relative":"k-animation-container-relative","animation-container-fixed":"k-animation-container-fixed","push-right-enter":"k-push-right-enter","push-right-appear":"k-push-right-appear","push-right-enter-active":"k-push-right-enter-active","push-right-appear-active":"k-push-right-appear-active","push-right-exit":"k-push-right-exit","push-right-exit-active":"k-push-right-exit-active","push-left-enter":"k-push-left-enter","push-left-appear":"k-push-left-appear","push-left-enter-active":"k-push-left-enter-active","push-left-appear-active":"k-push-left-appear-active","push-left-exit":"k-push-left-exit","push-left-exit-active":"k-push-left-exit-active","push-down-enter":"k-push-down-enter","push-down-appear":"k-push-down-appear","push-down-enter-active":"k-push-down-enter-active","push-down-appear-active":"k-push-down-appear-active","push-down-exit":"k-push-down-exit","push-down-exit-active":"k-push-down-exit-active","push-up-enter":"k-push-up-enter","push-up-appear":"k-push-up-appear","push-up-enter-active":"k-push-up-enter-active","push-up-appear-active":"k-push-up-appear-active","push-up-exit":"k-push-up-exit","push-up-exit-active":"k-push-up-exit-active",expand:"k-expand","expand-vertical-enter":"k-expand-vertical-enter","expand-vertical-appear":"k-expand-vertical-appear","expand-vertical-enter-active":"k-expand-vertical-enter-active","expand-vertical-appear-active":"k-expand-vertical-appear-active","expand-vertical-exit":"k-expand-vertical-exit","expand-vertical-exit-active":"k-expand-vertical-exit-active","expand-horizontal-enter":"k-expand-horizontal-enter","expand-horizontal-appear":"k-expand-horizontal-appear","expand-horizontal-enter-active":"k-expand-horizontal-enter-active","expand-horizontal-appear-active":"k-expand-horizontal-appear-active","expand-horizontal-exit":"k-expand-horizontal-exit","expand-horizontal-exit-active":"k-expand-horizontal-exit-active","child-animation-container":"k-child-animation-container","fade-enter":"k-fade-enter","fade-appear":"k-fade-appear","fade-enter-active":"k-fade-enter-active","fade-appear-active":"k-fade-appear-active","fade-exit":"k-fade-exit","fade-exit-active":"k-fade-exit-active","zoom-in-enter":"k-zoom-in-enter","zoom-in-appear":"k-zoom-in-appear","zoom-in-enter-active":"k-zoom-in-enter-active","zoom-in-appear-active":"k-zoom-in-appear-active","zoom-in-exit":"k-zoom-in-exit","zoom-in-exit-active":"k-zoom-in-exit-active","zoom-out-enter":"k-zoom-out-enter","zoom-out-appear":"k-zoom-out-appear","zoom-out-enter-active":"k-zoom-out-enter-active","zoom-out-appear-active":"k-zoom-out-appear-active","zoom-out-exit":"k-zoom-out-exit","zoom-out-exit-active":"k-zoom-out-exit-active","slide-in-appear":"k-slide-in-appear",centered:"k-centered","slide-in-appear-active":"k-slide-in-appear-active","slide-down-enter":"k-slide-down-enter","slide-down-appear":"k-slide-down-appear","slide-down-enter-active":"k-slide-down-enter-active","slide-down-appear-active":"k-slide-down-appear-active","slide-down-exit":"k-slide-down-exit","slide-down-exit-active":"k-slide-down-exit-active","slide-up-enter":"k-slide-up-enter","slide-up-appear":"k-slide-up-appear","slide-up-enter-active":"k-slide-up-enter-active","slide-up-appear-active":"k-slide-up-appear-active","slide-up-exit":"k-slide-up-exit","slide-up-exit-active":"k-slide-up-exit-active","slide-right-enter":"k-slide-right-enter","slide-right-appear":"k-slide-right-appear","slide-right-enter-active":"k-slide-right-enter-active","slide-right-appear-active":"k-slide-right-appear-active","slide-right-exit":"k-slide-right-exit","slide-right-exit-active":"k-slide-right-exit-active","slide-left-enter":"k-slide-left-enter","slide-left-appear":"k-slide-left-appear","slide-left-enter-active":"k-slide-left-enter-active","slide-left-appear-active":"k-slide-left-appear-active","slide-left-exit":"k-slide-left-exit","slide-left-exit-active":"k-slide-left-exit-active","reveal-vertical-enter":"k-reveal-vertical-enter","reveal-vertical-appear":"k-reveal-vertical-appear","reveal-vertical-enter-active":"k-reveal-vertical-enter-active","reveal-vertical-appear-active":"k-reveal-vertical-appear-active","reveal-vertical-exit":"k-reveal-vertical-exit","reveal-vertical-exit-active":"k-reveal-vertical-exit-active","reveal-horizontal-enter":"k-reveal-horizontal-enter","reveal-horizontal-appear":"k-reveal-horizontal-appear","reveal-horizontal-enter-active":"k-reveal-horizontal-enter-active","reveal-horizontal-appear-active":"k-reveal-horizontal-appear-active","reveal-horizontal-exit":"k-reveal-horizontal-exit","reveal-horizontal-exit-active":"k-reveal-horizontal-exit-active"},kO={outerHeight:GVt,outerWidth:UVt,styles:YVt};/** + */const UVt=t=>{if(!t||!t.ownerDocument.defaultView)return 0;const r=t.ownerDocument.defaultView.getComputedStyle(t),n=parseFloat(r.marginTop),i=parseFloat(r.marginBottom);return t.offsetHeight+n+i},YVt=t=>{if(!t||!t.ownerDocument.defaultView)return 0;const r=t.ownerDocument.defaultView.getComputedStyle(t),n=parseFloat(r.marginLeft),i=parseFloat(r.marginRight);return t.offsetWidth+n+i},XVt={"animation-container":"k-animation-container","animation-container-shown":"k-animation-container-shown","animation-container-relative":"k-animation-container-relative","animation-container-fixed":"k-animation-container-fixed","push-right-enter":"k-push-right-enter","push-right-appear":"k-push-right-appear","push-right-enter-active":"k-push-right-enter-active","push-right-appear-active":"k-push-right-appear-active","push-right-exit":"k-push-right-exit","push-right-exit-active":"k-push-right-exit-active","push-left-enter":"k-push-left-enter","push-left-appear":"k-push-left-appear","push-left-enter-active":"k-push-left-enter-active","push-left-appear-active":"k-push-left-appear-active","push-left-exit":"k-push-left-exit","push-left-exit-active":"k-push-left-exit-active","push-down-enter":"k-push-down-enter","push-down-appear":"k-push-down-appear","push-down-enter-active":"k-push-down-enter-active","push-down-appear-active":"k-push-down-appear-active","push-down-exit":"k-push-down-exit","push-down-exit-active":"k-push-down-exit-active","push-up-enter":"k-push-up-enter","push-up-appear":"k-push-up-appear","push-up-enter-active":"k-push-up-enter-active","push-up-appear-active":"k-push-up-appear-active","push-up-exit":"k-push-up-exit","push-up-exit-active":"k-push-up-exit-active",expand:"k-expand","expand-vertical-enter":"k-expand-vertical-enter","expand-vertical-appear":"k-expand-vertical-appear","expand-vertical-enter-active":"k-expand-vertical-enter-active","expand-vertical-appear-active":"k-expand-vertical-appear-active","expand-vertical-exit":"k-expand-vertical-exit","expand-vertical-exit-active":"k-expand-vertical-exit-active","expand-horizontal-enter":"k-expand-horizontal-enter","expand-horizontal-appear":"k-expand-horizontal-appear","expand-horizontal-enter-active":"k-expand-horizontal-enter-active","expand-horizontal-appear-active":"k-expand-horizontal-appear-active","expand-horizontal-exit":"k-expand-horizontal-exit","expand-horizontal-exit-active":"k-expand-horizontal-exit-active","child-animation-container":"k-child-animation-container","fade-enter":"k-fade-enter","fade-appear":"k-fade-appear","fade-enter-active":"k-fade-enter-active","fade-appear-active":"k-fade-appear-active","fade-exit":"k-fade-exit","fade-exit-active":"k-fade-exit-active","zoom-in-enter":"k-zoom-in-enter","zoom-in-appear":"k-zoom-in-appear","zoom-in-enter-active":"k-zoom-in-enter-active","zoom-in-appear-active":"k-zoom-in-appear-active","zoom-in-exit":"k-zoom-in-exit","zoom-in-exit-active":"k-zoom-in-exit-active","zoom-out-enter":"k-zoom-out-enter","zoom-out-appear":"k-zoom-out-appear","zoom-out-enter-active":"k-zoom-out-enter-active","zoom-out-appear-active":"k-zoom-out-appear-active","zoom-out-exit":"k-zoom-out-exit","zoom-out-exit-active":"k-zoom-out-exit-active","slide-in-appear":"k-slide-in-appear",centered:"k-centered","slide-in-appear-active":"k-slide-in-appear-active","slide-down-enter":"k-slide-down-enter","slide-down-appear":"k-slide-down-appear","slide-down-enter-active":"k-slide-down-enter-active","slide-down-appear-active":"k-slide-down-appear-active","slide-down-exit":"k-slide-down-exit","slide-down-exit-active":"k-slide-down-exit-active","slide-up-enter":"k-slide-up-enter","slide-up-appear":"k-slide-up-appear","slide-up-enter-active":"k-slide-up-enter-active","slide-up-appear-active":"k-slide-up-appear-active","slide-up-exit":"k-slide-up-exit","slide-up-exit-active":"k-slide-up-exit-active","slide-right-enter":"k-slide-right-enter","slide-right-appear":"k-slide-right-appear","slide-right-enter-active":"k-slide-right-enter-active","slide-right-appear-active":"k-slide-right-appear-active","slide-right-exit":"k-slide-right-exit","slide-right-exit-active":"k-slide-right-exit-active","slide-left-enter":"k-slide-left-enter","slide-left-appear":"k-slide-left-appear","slide-left-enter-active":"k-slide-left-enter-active","slide-left-appear-active":"k-slide-left-appear-active","slide-left-exit":"k-slide-left-exit","slide-left-exit-active":"k-slide-left-exit-active","reveal-vertical-enter":"k-reveal-vertical-enter","reveal-vertical-appear":"k-reveal-vertical-appear","reveal-vertical-enter-active":"k-reveal-vertical-enter-active","reveal-vertical-appear-active":"k-reveal-vertical-appear-active","reveal-vertical-exit":"k-reveal-vertical-exit","reveal-vertical-exit-active":"k-reveal-vertical-exit-active","reveal-horizontal-enter":"k-reveal-horizontal-enter","reveal-horizontal-appear":"k-reveal-horizontal-appear","reveal-horizontal-enter-active":"k-reveal-horizontal-enter-active","reveal-horizontal-appear-active":"k-reveal-horizontal-appear-active","reveal-horizontal-exit":"k-reveal-horizontal-exit","reveal-horizontal-exit-active":"k-reveal-horizontal-exit-active"},_O={outerHeight:UVt,outerWidth:YVt,styles:XVt};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const W4=kO.styles,ay=class extends _.Component{constructor(){super(...arguments),this.elementRef=_.createRef()}get element(){return this.elementRef.current}render(){const{children:r,style:n,appear:i,enter:o,exit:a,transitionName:s,transitionEnterDuration:l,transitionExitDuration:h,className:p,onEnter:f,onEntering:g,onEntered:b,onExit:z,onExiting:M,onExited:I,onAfterExited:F,mountOnEnter:H,unmountOnExit:E,animationEnteringStyle:R,animationEnteredStyle:W,animationExitingStyle:$,animationExitedStyle:G,...Z}=this.props,K=Me(p,W4["child-animation-container"]),et={transitionDelay:"0ms",...n},at={entering:{transitionDuration:`${l}ms`,...R},entered:{...W},exiting:{transitionDuration:`${h}ms`,...$},exited:{...G}},tt={in:this.props.in,appear:i,enter:o,exit:a,mountOnEnter:H,unmountOnExit:E,timeout:{enter:l,exit:h},onEnter:()=>{f&&f.call(void 0,{animatedElement:this.element,target:this})},onEntering:()=>{g&&g.call(void 0,{animatedElement:this.element,target:this})},onEntered:()=>{b&&b.call(void 0,{animatedElement:this.element,target:this})},onExit:()=>{z&&z.call(void 0,{animatedElement:this.element,target:this})},onExiting:()=>{M&&M.call(void 0,{animatedElement:this.element,target:this})},onExited:()=>{F&&F.call(void 0,{animatedElement:this.element,target:this}),I&&I.call(void 0,{animatedElement:this.element,target:this})},classNames:{appear:W4[`${s}-appear`]||`${s}-appear`,appearActive:W4[`${s}-appear-active`]||`${s}-appear-active`,enter:W4[`${s}-enter`]||`${s}-enter`,enterActive:W4[`${s}-enter-active`]||`${s}-enter-active`,exit:W4[`${s}-exit`]||`${s}-exit`,exitActive:W4[`${s}-exit-active`]||`${s}-exit-active`}};return _.createElement(bbt,{...tt,...Z,nodeRef:this.elementRef},ft=>_.createElement("div",{style:{...et,...at[ft]},className:K,ref:this.elementRef},r))}};ay.propTypes={in:B.bool,children:B.oneOfType([B.arrayOf(B.node),B.node]),transitionName:B.string.isRequired,className:B.string,appear:B.bool,enter:B.bool,exit:B.bool,transitionEnterDuration:B.number.isRequired,transitionExitDuration:B.number.isRequired,mountOnEnter:B.bool,unmountOnExit:B.bool,animationEnteringStyle:B.object,animationEnteredStyle:B.object,animationExitingStyle:B.object,animationExitedStyle:B.object},ay.defaultProps={mountOnEnter:!0,unmountOnExit:!1,onEnter:Zr,onEntering:Zr,onEntered:Zr,onExit:Zr,onExiting:Zr,onExited:Zr,onAfterExited:Zr,animationEnteringStyle:{},animationEnteredStyle:{},animationExitingStyle:{},animationExitedStyle:{}};let XVt=ay;/** + */const W4=_O.styles,ay=class extends _.Component{constructor(){super(...arguments),this.elementRef=_.createRef()}get element(){return this.elementRef.current}render(){const{children:r,style:n,appear:i,enter:o,exit:a,transitionName:s,transitionEnterDuration:l,transitionExitDuration:h,className:p,onEnter:f,onEntering:g,onEntered:b,onExit:z,onExiting:M,onExited:I,onAfterExited:F,mountOnEnter:H,unmountOnExit:E,animationEnteringStyle:R,animationEnteredStyle:W,animationExitingStyle:$,animationExitedStyle:G,...Z}=this.props,K=ke(p,W4["child-animation-container"]),et={transitionDelay:"0ms",...n},at={entering:{transitionDuration:`${l}ms`,...R},entered:{...W},exiting:{transitionDuration:`${h}ms`,...$},exited:{...G}},tt={in:this.props.in,appear:i,enter:o,exit:a,mountOnEnter:H,unmountOnExit:E,timeout:{enter:l,exit:h},onEnter:()=>{f&&f.call(void 0,{animatedElement:this.element,target:this})},onEntering:()=>{g&&g.call(void 0,{animatedElement:this.element,target:this})},onEntered:()=>{b&&b.call(void 0,{animatedElement:this.element,target:this})},onExit:()=>{z&&z.call(void 0,{animatedElement:this.element,target:this})},onExiting:()=>{M&&M.call(void 0,{animatedElement:this.element,target:this})},onExited:()=>{F&&F.call(void 0,{animatedElement:this.element,target:this}),I&&I.call(void 0,{animatedElement:this.element,target:this})},classNames:{appear:W4[`${s}-appear`]||`${s}-appear`,appearActive:W4[`${s}-appear-active`]||`${s}-appear-active`,enter:W4[`${s}-enter`]||`${s}-enter`,enterActive:W4[`${s}-enter-active`]||`${s}-enter-active`,exit:W4[`${s}-exit`]||`${s}-exit`,exitActive:W4[`${s}-exit-active`]||`${s}-exit-active`}};return _.createElement(wbt,{...tt,...Z,nodeRef:this.elementRef},ft=>_.createElement("div",{style:{...et,...at[ft]},className:K,ref:this.elementRef},r))}};ay.propTypes={in:B.bool,children:B.oneOfType([B.arrayOf(B.node),B.node]),transitionName:B.string.isRequired,className:B.string,appear:B.bool,enter:B.bool,exit:B.bool,transitionEnterDuration:B.number.isRequired,transitionExitDuration:B.number.isRequired,mountOnEnter:B.bool,unmountOnExit:B.bool,animationEnteringStyle:B.object,animationEnteredStyle:B.object,animationExitingStyle:B.object,animationExitedStyle:B.object},ay.defaultProps={mountOnEnter:!0,unmountOnExit:!1,onEnter:Xr,onEntering:Xr,onEntered:Xr,onExit:Xr,onExiting:Xr,onExited:Xr,onAfterExited:Xr,animationEnteringStyle:{},animationEnteredStyle:{},animationExitingStyle:{},animationExitedStyle:{}};let KVt=ay;/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const KVt={name:"@progress/kendo-react-animation",productName:"KendoReact",productCodes:["KENDOUIREACT","KENDOUICOMPLETE"],publishDate:1722843829,version:"",licensingDocsUrl:"https://www.telerik.com/kendo-react-ui/components/my-license/"};/** + */const qVt={name:"@progress/kendo-react-animation",productName:"KendoReact",productCodes:["KENDOUIREACT","KENDOUICOMPLETE"],publishDate:1722843829,version:"",licensingDocsUrl:"https://www.telerik.com/kendo-react-ui/components/my-license/"};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const uE=kO.styles,sy=class extends _.Component{constructor(r){super(r),gi(KVt)}render(){const{id:r,style:n,children:i,component:o,className:a,childFactory:s,stackChildren:l,componentChildStyle:h,componentChildClassName:p,...f}=this.props,g={id:r,style:n,component:o,childFactory:s,className:Me(uE["animation-container"],uE["animation-container-relative"],a)},b=_.Children.map(i||null,z=>_.createElement(XVt,{...f,style:h,className:p},z));return _.createElement(kbt,{...g},b)}};sy.propTypes={children:B.oneOfType([B.arrayOf(B.node),B.node]),childFactory:B.any,className:B.string,component:B.string,id:B.string,style:B.any,transitionName:B.string.isRequired,appear:B.bool.isRequired,enter:B.bool.isRequired,exit:B.bool.isRequired,transitionEnterDuration:B.number.isRequired,transitionExitDuration:B.number.isRequired},sy.defaultProps={component:"div"};let _O=sy;/** + */const pE=_O.styles,sy=class extends _.Component{constructor(r){super(r),vi(qVt)}render(){const{id:r,style:n,children:i,component:o,className:a,childFactory:s,stackChildren:l,componentChildStyle:h,componentChildClassName:p,...f}=this.props,g={id:r,style:n,component:o,childFactory:s,className:ke(pE["animation-container"],pE["animation-container-relative"],a)},b=_.Children.map(i||null,z=>_.createElement(KVt,{...f,style:h,className:p},z));return _.createElement(_bt,{...g},b)}};sy.propTypes={children:B.oneOfType([B.arrayOf(B.node),B.node]),childFactory:B.any,className:B.string,component:B.string,id:B.string,style:B.any,transitionName:B.string.isRequired,appear:B.bool.isRequired,enter:B.bool.isRequired,exit:B.bool.isRequired,transitionEnterDuration:B.number.isRequired,transitionExitDuration:B.number.isRequired},sy.defaultProps={component:"div"};let AO=sy;/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const ly=class extends _.Component{render(){const{children:r,...n}=this.props,i={transitionName:"fade"};return _.createElement(_O,{...i,...n},r)}};ly.propTypes={children:B.oneOfType([B.arrayOf(B.node),B.node]),childFactory:B.any,className:B.string,component:B.string,id:B.string,style:B.any},ly.defaultProps={appear:!1,enter:!0,exit:!1,transitionEnterDuration:500,transitionExitDuration:500};let pE=ly;/** + */const ly=class extends _.Component{render(){const{children:r,...n}=this.props,i={transitionName:"fade"};return _.createElement(AO,{...i,...n},r)}};ly.propTypes={children:B.oneOfType([B.arrayOf(B.node),B.node]),childFactory:B.any,className:B.string,component:B.string,id:B.string,style:B.any},ly.defaultProps={appear:!1,enter:!0,exit:!1,transitionEnterDuration:500,transitionExitDuration:500};let dE=ly;/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const AO=class extends _.Component{constructor(){super(...arguments),this.contentId=this.props.contentPanelId,this.childFactory=r=>_.cloneElement(r,{...r.props,in:r.props.children.props.id===String(this.contentId+this.props.selected)})}render(){const{children:r,selected:n,contentPanelId:i,keepTabsMounted:o,navItemId:a,renderAllContent:s}=this.props,l=r&&typeof n=="number"&&_.Children.toArray(r)[n],h=Me("k-tabstrip-content","k-active",l&&l.props.contentClassName);return s?this.renderAllContent(r):_.createElement("div",{className:h,style:this.props.style,id:i,role:"tabpanel","aria-hidden":o,"aria-labelledby":`${a}-${(n==null?void 0:n.toString())||""}`,tabIndex:0},this.renderContent(r))}renderContent(r){return this.props.keepTabsMounted?_.Children.map(this.props.children,(n,i)=>this.renderChild(n,i)):this.renderChild(_.Children.toArray(r)[this.props.selected],this.props.selected)}renderAllContent(r){return _.Children.map(r,(n,i)=>{const o=n,a=i===this.props.selected,s=Me("k-tabstrip-content",{"k-active":a},o.props.contentClassName);return _.createElement("div",{className:s,style:this.props.style,id:`${this.props.contentPanelId}-${i}`,role:"tabpanel","aria-hidden":!a,hidden:!a,"aria-labelledby":`${this.props.navItemId}-${i}`},this.props.animation?_.createElement(pE,{key:`${i}-${a}`,appear:!0,enter:!0,exit:!1},o.props.children):o.props.children)})}renderChild(r,n){const i=n===this.props.selected,o={style:{display:i?void 0:"none"}},a={position:"initial",display:i?void 0:"none"};return r.props.disabled?null:this.props.animation?_.createElement(pE,{appear:!0,exit:this.props.keepTabsMounted,style:a,childFactory:this.props.keepTabsMounted?this.childFactory:void 0},_.createElement("div",{...o,id:String(this.contentId+n),key:n},r.props.children)):_.createElement("div",{...o,key:n},r.props.children)}};AO.propTypes={animation:B.bool,children:B.oneOfType([B.element,B.arrayOf(B.element)]),selected:B.number,style:B.object};let qVt=AO;/** + */const LO=class extends _.Component{constructor(){super(...arguments),this.contentId=this.props.contentPanelId,this.childFactory=r=>_.cloneElement(r,{...r.props,in:r.props.children.props.id===String(this.contentId+this.props.selected)})}render(){const{children:r,selected:n,contentPanelId:i,keepTabsMounted:o,navItemId:a,renderAllContent:s}=this.props,l=r&&typeof n=="number"&&_.Children.toArray(r)[n],h=ke("k-tabstrip-content","k-active",l&&l.props.contentClassName);return s?this.renderAllContent(r):_.createElement("div",{className:h,style:this.props.style,id:i,role:"tabpanel","aria-hidden":o,"aria-labelledby":`${a}-${(n==null?void 0:n.toString())||""}`,tabIndex:0},this.renderContent(r))}renderContent(r){return this.props.keepTabsMounted?_.Children.map(this.props.children,(n,i)=>this.renderChild(n,i)):this.renderChild(_.Children.toArray(r)[this.props.selected],this.props.selected)}renderAllContent(r){return _.Children.map(r,(n,i)=>{const o=n,a=i===this.props.selected,s=ke("k-tabstrip-content",{"k-active":a},o.props.contentClassName);return _.createElement("div",{className:s,style:this.props.style,id:`${this.props.contentPanelId}-${i}`,role:"tabpanel","aria-hidden":!a,hidden:!a,"aria-labelledby":`${this.props.navItemId}-${i}`},this.props.animation?_.createElement(dE,{key:`${i}-${a}`,appear:!0,enter:!0,exit:!1},o.props.children):o.props.children)})}renderChild(r,n){const i=n===this.props.selected,o={style:{display:i?void 0:"none"}},a={position:"initial",display:i?void 0:"none"};return r.props.disabled?null:this.props.animation?_.createElement(dE,{appear:!0,exit:this.props.keepTabsMounted,style:a,childFactory:this.props.keepTabsMounted?this.childFactory:void 0},_.createElement("div",{...o,id:String(this.contentId+n),key:n},r.props.children)):_.createElement("div",{...o,key:n},r.props.children)}};LO.propTypes={animation:B.bool,children:B.oneOfType([B.element,B.arrayOf(B.element)]),selected:B.number,style:B.object};let ZVt=LO;/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const cy=class extends _.Component{constructor(r){super(r),this.tabStripRef=_.createRef(),this.showLicenseWatermark=!1,this.onSelect=n=>{this.props.selected!==n&&this.props.onSelect&&this.props.onSelect({selected:n})},this.onKeyDown=n=>{this.navigation.triggerKeyboardEvent(n)},this.onKeyboardSelect=n=>{const i=this.children();i&&i[n].props.disabled||this.onSelect(n)},this.renderContent=n=>{const{selected:i,children:o,tabContentStyle:a}=n,s=_.Children.count(o);return i-1?_.createElement(qVt,{index:i,...n,style:a}):null},gi(y9),this.showLicenseWatermark=gb(y9)}get contentPanelId(){return this.props.id+"-content-panel-id"}get navItemId(){return this.props.id+"-nav-item-id"}componentDidMount(){var r;const n=this.tabStripRef.current,i=n&&getComputedStyle(n).direction==="rtl"||!1;n&&(this.navigation=new Sb({tabIndex:0,root:this.tabStripRef,rovingTabIndex:!0,focusClass:"k-focus",selectors:[".k-tabstrip .k-tabstrip-item"],keyboardEvents:{keydown:{ArrowLeft:(o,a,s)=>{s.preventDefault();const l=a.elements.indexOf(o),h=l!==0?l-1:a.elements.length-1,p=l!==a.elements.length-1?l+1:0;i?(a.focusNext(o),this.onKeyboardSelect(p)):(a.focusPrevious(o),this.onKeyboardSelect(h))},ArrowRight:(o,a,s)=>{s.preventDefault();const l=a.elements.indexOf(o),h=l!==0?l-1:a.elements.length-1,p=l!==a.elements.length-1?l+1:0;i?(a.focusPrevious(o),this.onKeyboardSelect(h)):(a.focusNext(o),this.onKeyboardSelect(p))},ArrowDown:(o,a,s)=>{s.preventDefault();const l=a.elements.indexOf(o),h=l!==a.elements.length-1?l+1:0;a.focusNext(o),this.onKeyboardSelect(h)},ArrowUp:(o,a,s)=>{s.preventDefault();const l=a.elements.indexOf(o),h=l!==0?l-1:a.elements.length-1;a.focusPrevious(o),this.onKeyboardSelect(h)},Home:(o,a,s)=>{s.preventDefault(),a.focusElement(a.first,o),this.onKeyboardSelect(0)},End:(o,a,s)=>{s.preventDefault(),a.focusElement(a.last,o),this.onKeyboardSelect(a.elements.length-1)}}}}),(r=this.navigation)==null||r.initializeRovingTab(this.props.selected))}componentWillUnmount(){var r;(r=this.navigation)==null||r.removeFocusListener()}render(){const r={...this.props,children:this.children(),contentPanelId:this.contentPanelId,renderAllContent:this.props.renderAllContent,navItemId:this.navItemId,onKeyDown:this.onKeyDown,onSelect:this.onSelect},{tabPosition:n,tabIndex:i}=r,o=n==="bottom",a=Me("k-tabstrip k-pos-relative",{"k-tabstrip-left":n==="left","k-tabstrip-right":n==="right","k-tabstrip-bottom":n==="bottom","k-tabstrip-top":n==="top","k-tabstrip-scrollable":this.props.scrollable},this.props.className);return _.createElement("div",{id:this.props.id,ref:this.tabStripRef,dir:this.props.dir,className:a,style:this.props.style},!o&&_.createElement(hE,{...r,tabIndex:i}),this.renderContent(r),o&&_.createElement(hE,{...r,tabIndex:i}),this.showLicenseWatermark&&_.createElement(mb,null))}children(){return _.Children.toArray(this.props.children).filter(r=>r)}};cy.propTypes={animation:B.bool,children:B.node,onSelect:B.func,selected:B.number,style:B.object,tabContentStyle:B.object,tabPosition:B.string,tabIndex:B.number,className:B.string,dir:B.string},cy.defaultProps={animation:!0,tabPosition:"top",keepTabsMounted:!1,buttonScrollSpeed:100,mouseScrollSpeed:10,renderAllContent:!1};let ZVt=cy;/** + */const cy=class extends _.Component{constructor(r){super(r),this.tabStripRef=_.createRef(),this.showLicenseWatermark=!1,this.onSelect=n=>{this.props.selected!==n&&this.props.onSelect&&this.props.onSelect({selected:n})},this.onKeyDown=n=>{this.navigation.triggerKeyboardEvent(n)},this.onKeyboardSelect=n=>{const i=this.children();i&&i[n].props.disabled||this.onSelect(n)},this.renderContent=n=>{const{selected:i,children:o,tabContentStyle:a}=n,s=_.Children.count(o);return i-1?_.createElement(ZVt,{index:i,...n,style:a}):null},vi(y9),this.showLicenseWatermark=mb(y9)}get contentPanelId(){return this.props.id+"-content-panel-id"}get navItemId(){return this.props.id+"-nav-item-id"}componentDidMount(){var r;const n=this.tabStripRef.current,i=n&&getComputedStyle(n).direction==="rtl"||!1;n&&(this.navigation=new zb({tabIndex:0,root:this.tabStripRef,rovingTabIndex:!0,focusClass:"k-focus",selectors:[".k-tabstrip .k-tabstrip-item"],keyboardEvents:{keydown:{ArrowLeft:(o,a,s)=>{s.preventDefault();const l=a.elements.indexOf(o),h=l!==0?l-1:a.elements.length-1,p=l!==a.elements.length-1?l+1:0;i?(a.focusNext(o),this.onKeyboardSelect(p)):(a.focusPrevious(o),this.onKeyboardSelect(h))},ArrowRight:(o,a,s)=>{s.preventDefault();const l=a.elements.indexOf(o),h=l!==0?l-1:a.elements.length-1,p=l!==a.elements.length-1?l+1:0;i?(a.focusPrevious(o),this.onKeyboardSelect(h)):(a.focusNext(o),this.onKeyboardSelect(p))},ArrowDown:(o,a,s)=>{s.preventDefault();const l=a.elements.indexOf(o),h=l!==a.elements.length-1?l+1:0;a.focusNext(o),this.onKeyboardSelect(h)},ArrowUp:(o,a,s)=>{s.preventDefault();const l=a.elements.indexOf(o),h=l!==0?l-1:a.elements.length-1;a.focusPrevious(o),this.onKeyboardSelect(h)},Home:(o,a,s)=>{s.preventDefault(),a.focusElement(a.first,o),this.onKeyboardSelect(0)},End:(o,a,s)=>{s.preventDefault(),a.focusElement(a.last,o),this.onKeyboardSelect(a.elements.length-1)}}}}),(r=this.navigation)==null||r.initializeRovingTab(this.props.selected))}componentWillUnmount(){var r;(r=this.navigation)==null||r.removeFocusListener()}render(){const r={...this.props,children:this.children(),contentPanelId:this.contentPanelId,renderAllContent:this.props.renderAllContent,navItemId:this.navItemId,onKeyDown:this.onKeyDown,onSelect:this.onSelect},{tabPosition:n,tabIndex:i}=r,o=n==="bottom",a=ke("k-tabstrip k-pos-relative",{"k-tabstrip-left":n==="left","k-tabstrip-right":n==="right","k-tabstrip-bottom":n==="bottom","k-tabstrip-top":n==="top","k-tabstrip-scrollable":this.props.scrollable},this.props.className);return _.createElement("div",{id:this.props.id,ref:this.tabStripRef,dir:this.props.dir,className:a,style:this.props.style},!o&&_.createElement(uE,{...r,tabIndex:i}),this.renderContent(r),o&&_.createElement(uE,{...r,tabIndex:i}),this.showLicenseWatermark&&_.createElement(yb,null))}children(){return _.Children.toArray(this.props.children).filter(r=>r)}};cy.propTypes={animation:B.bool,children:B.node,onSelect:B.func,selected:B.number,style:B.object,tabContentStyle:B.object,tabPosition:B.string,tabIndex:B.number,className:B.string,dir:B.string},cy.defaultProps={animation:!0,tabPosition:"top",keepTabsMounted:!1,buttonScrollSpeed:100,mouseScrollSpeed:10,renderAllContent:!1};let JVt=cy;/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const hy=t=>{const r=_.useRef(null),n=_.useCallback(i=>{t.onClick&&t.onClick.call(void 0,{syntheticEvent:i,item:t.item,title:t.title})},[t.item,t.title,t.onClick]);return _.useEffect(()=>{r.current&&t.focused&&r.current.focus()},[t.focused]),_.createElement("span",{style:t.style,tabIndex:t.tabIndex,className:Me("k-actionsheet-item","k-cursor-pointer",t.disabled&&"k-disabled",t.className),ref:r,role:"button","aria-disabled":t.disabled,onClick:n},_.createElement("span",{className:"k-actionsheet-action"},t.icon&&_.createElement("span",{className:"k-icon-wrap"},t.icon),(t.title||t.description)&&_.createElement("span",{className:"k-actionsheet-item-text"},t.title&&_.createElement("span",{className:"k-actionsheet-item-title"},t.title),t.description&&_.createElement("span",{className:"k-actionsheet-item-description"},t.description))))};hy.propTypes={className:B.string,style:B.object,description:B.string,disabled:B.bool,group:B.oneOf(["top","bottom"]),icon:B.element,title:B.string};/** + */const hy=t=>{const r=_.useRef(null),n=_.useCallback(i=>{t.onClick&&t.onClick.call(void 0,{syntheticEvent:i,item:t.item,title:t.title})},[t.item,t.title,t.onClick]);return _.useEffect(()=>{r.current&&t.focused&&r.current.focus()},[t.focused]),_.createElement("span",{style:t.style,tabIndex:t.tabIndex,className:ke("k-actionsheet-item","k-cursor-pointer",t.disabled&&"k-disabled",t.className),ref:r,role:"button","aria-disabled":t.disabled,onClick:n},_.createElement("span",{className:"k-actionsheet-action"},t.icon&&_.createElement("span",{className:"k-icon-wrap"},t.icon),(t.title||t.description)&&_.createElement("span",{className:"k-actionsheet-item-text"},t.title&&_.createElement("span",{className:"k-actionsheet-item-title"},t.title),t.description&&_.createElement("span",{className:"k-actionsheet-item-description"},t.description))))};hy.propTypes={className:B.string,style:B.object,description:B.string,disabled:B.bool,group:B.oneOf(["top","bottom"]),icon:B.element,title:B.string};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const uy="ActionSheetHeader",p5=t=>_.createElement("div",{className:Me("k-actionsheet-titlebar",t.className)},t.children);p5.propTypes={className:B.string};p5.displayName=uy;p5.propTypes={children:B.any};/** + */const uy="ActionSheetHeader",p5=t=>_.createElement("div",{className:ke("k-actionsheet-titlebar",t.className)},t.children);p5.propTypes={className:B.string};p5.displayName=uy;p5.propTypes={children:B.any};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const LO="ActionSheetFooter",id=t=>_.createElement("div",{className:Me("k-actionsheet-footer",t.className)},t.children);id.propTypes={className:B.string};id.displayName=LO;id.propTypes={children:B.any};/** + */const EO="ActionSheetFooter",id=t=>_.createElement("div",{className:ke("k-actionsheet-footer",t.className)},t.children);id.propTypes={className:B.string};id.displayName=EO;id.propTypes={children:B.any};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const EO="ActionSheetContent",d5=t=>_.createElement("div",{className:Me("k-actionsheet-content",t.className)},t.children);d5.propTypes={className:B.string};d5.displayName=EO;d5.propTypes={children:B.any};/** + */const IO="ActionSheetContent",d5=t=>_.createElement("div",{className:ke("k-actionsheet-content",t.className)},t.children);d5.propTypes={className:B.string};d5.displayName=IO;d5.propTypes={children:B.any};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const V7=class extends _.Component{constructor(r){super(r),this.actionSheetRef=_.createRef(),this.actionSheetTitleClass="k-actionsheet-title",this.ariaLabeledBy=this.actionSheetTitleClass,this.animationDuration=300,this.bottomPosition={bottom:"0",width:"100%"},this.handleKeyDown=n=>{this.props.navigatable&&this.navigation.triggerKeyboardEvent(n)},this.onTab=(n,i,o)=>{o.preventDefault(),o.shiftKey?i.focusPrevious(n):i.focusNext(n)},this.handleOverlayClick=n=>{this.props.onOverlayClick&&this.props.onOverlayClick.call(void 0,n),this.props.onClose&&this.props.onClose.call(void 0,n),this.props.animation||this.hideActionSheet()},this.handleItemClick=n=>{this.props.onItemClick&&this.props.onItemClick.call(void 0,n),this.props.onItemSelect&&this.props.onItemSelect.call(void 0,n),this.props.animation||this.hideActionSheet()},this.onEnter=(n,i,o)=>{if(n.ariaDisabled)return;const a=n.className&&n.className.indexOf?n.className.indexOf("k-actionsheet-item")!==-1:!1,s=i.elements.filter(l=>l.className.indexOf("k-actionsheet-item")!==-1);if(a&&this.props.onItemClick){o.preventDefault();const l=this.props.items[s.indexOf(n)];this.props.onItemClick.call(void 0,{syntheticEvent:o,item:l,title:l&&l.title})}if(a&&this.props.onItemSelect){o.preventDefault();const l=this.props.items[s.indexOf(n)];this.props.onItemSelect.call(void 0,{syntheticEvent:o,item:l,title:l&&l.title})}this.props.animation||this.hideActionSheet()},this.onEscape=(n,i,o)=>{this.props.onOverlayClick&&(o.preventDefault(),this.props.onOverlayClick.call(void 0,o)),this.props.onClose&&(o.preventDefault(),this.props.onClose.call(void 0,o)),this.props.animation||this.hideActionSheet()},this.hideActionSheet=()=>{this.setState({show:!1})},this.children=n=>{const i={};return _.Children.forEach(n,o=>{o&&(i[o.type.displayName]=o)}),i},this.state={show:!1,slide:!1},gi(y9)}componentDidMount(){this.props.expand&&!this.state.show&&this.setState({show:!0})}componentDidUpdate(r,n){const i=this.actionSheetRef.current;if(this.props.expand&&!this.state.show&&this.setState({show:!0}),this.props.expand&&this.state.show&&!this.state.slide&&this.setState({slide:!0}),!this.props.expand&&this.state.show&&this.state.slide&&this.setState({slide:!1}),n!==this.state&&this.state.slide&&i&&!this.props.className&&(i.style.setProperty("--kendo-actionsheet-height","auto"),i.style.setProperty("--kendo-actionsheet-max-height","none")),i&&this.props.navigatable){const o=[".k-actionsheet-item",...[".k-actionsheet-footer",".k-actionsheet-content",".k-actionsheet-titlebar"].map(a=>T0.concat(this.props.navigatableElements).map(s=>`${a} ${s}`)).flat()];this.navigation=new Sb({tabIndex:this.props.tabIndex||0,root:this.actionSheetRef,rovingTabIndex:!1,selectors:o,keyboardEvents:{keydown:{Tab:this.onTab,Enter:this.onEnter,Escape:this.onEscape}}}),this.navigation.focusElement(this.navigation.first,null)}}render(){const{title:r,subTitle:n,animationStyles:i,animation:o,expand:a,tabIndex:s,items:l}=this.props,h=l==null?void 0:l.filter(M=>!M.group||M.group==="top"),p=l==null?void 0:l.filter(M=>M.group==="bottom"),f=h&&h.length>0&&p&&p.length>0,g=this.children(this.props.children),b=this.props.animationDuration||this.animationDuration,z=this.state.slide&&_.createElement("div",{className:Me("k-actionsheet",this.props.className,{"k-actionsheet-bottom":!this.props.className}),role:"dialog","aria-modal":"true","aria-hidden":!1,"aria-labelledby":this.ariaLabeledBy,ref:this.actionSheetRef,onKeyDown:this.handleKeyDown},g[uy]&&!r&&!n&&g[uy],(r||n)&&_.createElement("div",{className:"k-actionsheet-titlebar k-text-center"},_.createElement("div",{className:"k-actionsheet-titlebar-group k-hbox"},_.createElement("div",{className:this.actionSheetTitleClass,id:this.ariaLabeledBy},r&&_.createElement("div",null,r),n&&_.createElement("div",{className:"k-actionsheet-subtitle"},n)))),g[EO]||_.createElement("div",{className:"k-actionsheet-content"},_.createElement("div",{className:"k-list-ul",role:"group"},h&&h.map((M,I)=>_.createElement(hy,{...M,id:I,key:I,item:M,tabIndex:s||0,onClick:this.handleItemClick}))),f&&_.createElement("hr",{className:"k-hr"}),_.createElement("div",{className:"k-list-ul",role:"group"},p&&p.map((M,I)=>_.createElement(hy,{...M,id:I+((h==null?void 0:h.length)||0),key:I,item:M,tabIndex:s||0,onClick:this.handleItemClick})))),g[LO]);return _.createElement(_.Fragment,null,a||this.state.show?_.createElement(_.Fragment,null,_.createElement("div",{className:"k-actionsheet-container"},_.createElement("div",{className:"k-overlay",onClick:this.handleOverlayClick}),o?_.createElement(_O,{transitionName:this.state.slide?"slide-up":"slide-down",onExited:this.hideActionSheet,transitionEnterDuration:b,transitionExitDuration:b,animationEnteringStyle:i||this.bottomPosition,animationEnteredStyle:i||this.bottomPosition,animationExitingStyle:i||this.bottomPosition,exit:!0,enter:!0,appear:!1},z):z)):null)}};V7.displayName="KendoReactActionSheet",V7.propTypes={items:B.array,subTitle:B.string,title:B.string,navigatable:B.bool,navigatableElements:B.array},V7.defaultProps={navigatable:!0,navigatableElements:[]};let IO=V7;/** + */const V7=class extends _.Component{constructor(r){super(r),this.actionSheetRef=_.createRef(),this.actionSheetTitleClass="k-actionsheet-title",this.ariaLabeledBy=this.actionSheetTitleClass,this.animationDuration=300,this.bottomPosition={bottom:"0",width:"100%"},this.handleKeyDown=n=>{this.props.navigatable&&this.navigation.triggerKeyboardEvent(n)},this.onTab=(n,i,o)=>{o.preventDefault(),o.shiftKey?i.focusPrevious(n):i.focusNext(n)},this.handleOverlayClick=n=>{this.props.onOverlayClick&&this.props.onOverlayClick.call(void 0,n),this.props.onClose&&this.props.onClose.call(void 0,n),this.props.animation||this.hideActionSheet()},this.handleItemClick=n=>{this.props.onItemClick&&this.props.onItemClick.call(void 0,n),this.props.onItemSelect&&this.props.onItemSelect.call(void 0,n),this.props.animation||this.hideActionSheet()},this.onEnter=(n,i,o)=>{if(n.ariaDisabled)return;const a=n.className&&n.className.indexOf?n.className.indexOf("k-actionsheet-item")!==-1:!1,s=i.elements.filter(l=>l.className.indexOf("k-actionsheet-item")!==-1);if(a&&this.props.onItemClick){o.preventDefault();const l=this.props.items[s.indexOf(n)];this.props.onItemClick.call(void 0,{syntheticEvent:o,item:l,title:l&&l.title})}if(a&&this.props.onItemSelect){o.preventDefault();const l=this.props.items[s.indexOf(n)];this.props.onItemSelect.call(void 0,{syntheticEvent:o,item:l,title:l&&l.title})}this.props.animation||this.hideActionSheet()},this.onEscape=(n,i,o)=>{this.props.onOverlayClick&&(o.preventDefault(),this.props.onOverlayClick.call(void 0,o)),this.props.onClose&&(o.preventDefault(),this.props.onClose.call(void 0,o)),this.props.animation||this.hideActionSheet()},this.hideActionSheet=()=>{this.setState({show:!1})},this.children=n=>{const i={};return _.Children.forEach(n,o=>{o&&(i[o.type.displayName]=o)}),i},this.state={show:!1,slide:!1},vi(y9)}componentDidMount(){this.props.expand&&!this.state.show&&this.setState({show:!0})}componentDidUpdate(r,n){const i=this.actionSheetRef.current;if(this.props.expand&&!this.state.show&&this.setState({show:!0}),this.props.expand&&this.state.show&&!this.state.slide&&this.setState({slide:!0}),!this.props.expand&&this.state.show&&this.state.slide&&this.setState({slide:!1}),n!==this.state&&this.state.slide&&i&&!this.props.className&&(i.style.setProperty("--kendo-actionsheet-height","auto"),i.style.setProperty("--kendo-actionsheet-max-height","none")),i&&this.props.navigatable){const o=[".k-actionsheet-item",...[".k-actionsheet-footer",".k-actionsheet-content",".k-actionsheet-titlebar"].map(a=>T0.concat(this.props.navigatableElements).map(s=>`${a} ${s}`)).flat()];this.navigation=new zb({tabIndex:this.props.tabIndex||0,root:this.actionSheetRef,rovingTabIndex:!1,selectors:o,keyboardEvents:{keydown:{Tab:this.onTab,Enter:this.onEnter,Escape:this.onEscape}}}),this.navigation.focusElement(this.navigation.first,null)}}render(){const{title:r,subTitle:n,animationStyles:i,animation:o,expand:a,tabIndex:s,items:l}=this.props,h=l==null?void 0:l.filter(M=>!M.group||M.group==="top"),p=l==null?void 0:l.filter(M=>M.group==="bottom"),f=h&&h.length>0&&p&&p.length>0,g=this.children(this.props.children),b=this.props.animationDuration||this.animationDuration,z=this.state.slide&&_.createElement("div",{className:ke("k-actionsheet",this.props.className,{"k-actionsheet-bottom":!this.props.className}),role:"dialog","aria-modal":"true","aria-hidden":!1,"aria-labelledby":this.ariaLabeledBy,ref:this.actionSheetRef,onKeyDown:this.handleKeyDown},g[uy]&&!r&&!n&&g[uy],(r||n)&&_.createElement("div",{className:"k-actionsheet-titlebar k-text-center"},_.createElement("div",{className:"k-actionsheet-titlebar-group k-hbox"},_.createElement("div",{className:this.actionSheetTitleClass,id:this.ariaLabeledBy},r&&_.createElement("div",null,r),n&&_.createElement("div",{className:"k-actionsheet-subtitle"},n)))),g[IO]||_.createElement("div",{className:"k-actionsheet-content"},_.createElement("div",{className:"k-list-ul",role:"group"},h&&h.map((M,I)=>_.createElement(hy,{...M,id:I,key:I,item:M,tabIndex:s||0,onClick:this.handleItemClick}))),f&&_.createElement("hr",{className:"k-hr"}),_.createElement("div",{className:"k-list-ul",role:"group"},p&&p.map((M,I)=>_.createElement(hy,{...M,id:I+((h==null?void 0:h.length)||0),key:I,item:M,tabIndex:s||0,onClick:this.handleItemClick})))),g[EO]);return _.createElement(_.Fragment,null,a||this.state.show?_.createElement(_.Fragment,null,_.createElement("div",{className:"k-actionsheet-container"},_.createElement("div",{className:"k-overlay",onClick:this.handleOverlayClick}),o?_.createElement(AO,{transitionName:this.state.slide?"slide-up":"slide-down",onExited:this.hideActionSheet,transitionEnterDuration:b,transitionExitDuration:b,animationEnteringStyle:i||this.bottomPosition,animationEnteredStyle:i||this.bottomPosition,animationExitingStyle:i||this.bottomPosition,exit:!0,enter:!0,appear:!1},z):z)):null)}};V7.displayName="KendoReactActionSheet",V7.propTypes={items:B.array,subTitle:B.string,title:B.string,navigatable:B.bool,navigatableElements:B.array},V7.defaultProps={navigatable:!0,navigatableElements:[]};let HO=V7;/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const HO=na(PVt);HO.displayName="KendoReactMenu";na(ZVt);HO.displayName="KendoReactMenu";/** + */const DO=ra(TVt);DO.displayName="KendoReactMenu";ra(JVt);DO.displayName="KendoReactMenu";/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const vC=t=>{let r=i=>_.createElement(_.Fragment,null);t.drilldownSeriesFactory&&(r=t.drilldownSeriesFactory);const n=i=>{var o,a;return i&&((a=(o=i.drilldownState)==null?void 0:o.steps)==null?void 0:a.find(({seriesName:s})=>s===t.name))};return _.createElement(sa.Consumer,null,i=>n(i)?_.createElement(r,{_chartCollectionIdxKey:t._chartCollectionIdxKey,drilldownValue:n(i).drilldownValue}):_.createElement(nVt,{...t}))};vC.displayName="ChartSeriesItem";/** + */const gC=t=>{let r=i=>_.createElement(_.Fragment,null);t.drilldownSeriesFactory&&(r=t.drilldownSeriesFactory);const n=i=>{var o,a;return i&&((a=(o=i.drilldownState)==null?void 0:o.steps)==null?void 0:a.find(({seriesName:s})=>s===t.name))};return _.createElement(oa.Consumer,null,i=>n(i)?_.createElement(r,{_chartCollectionIdxKey:t._chartCollectionIdxKey,drilldownValue:n(i).drilldownValue}):_.createElement(oVt,{...t}))};gC.displayName="ChartSeriesItem";/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const DO=t=>_.createElement(iVt,{...t,_chartKey:"series"});DO.propTypes={children:function(t,r,n){return sPt(t,r,n,vC)}};const JVt=({data:t,parentSize:r=JSON.parse(localStorage.getItem("formDimension")),posn:n=[0,0]})=>{const{Points:i,Size:o,FCol:a,Radius:s,Visible:l,FStyle:h,FillCol:p,Event:f,CSS:g}=t==null?void 0:t.Properties,{socket:b}=w1(),z=j1(g),M=i&&i[0].map((H,E)=>[i[1][E],H]),I=o&&o[0].map((H,E)=>[o[1][E],H]),F=t==null?void 0:t.Properties.hasOwnProperty("FCol");return vt.jsx("div",{id:t==null?void 0:t.ID,style:{position:"absolute",top:0,left:0,display:l==0?"none":"block",...z},onMouseDown:H=>{er(H,b,f,t==null?void 0:t.ID)},onMouseUp:H=>{rr(H,b,f,t==null?void 0:t.ID)},onMouseEnter:H=>{ir(H,b,f,t==null?void 0:t.ID)},onMouseMove:H=>{or(H,b,f,t==null?void 0:t.ID)},onMouseLeave:H=>{nr(H,b,f,t==null?void 0:t.ID)},onWheel:H=>{hr(H,b,f,t==null?void 0:t.ID)},onDoubleClick:H=>{mr(H,b,f,t==null?void 0:t.ID)},children:vt.jsx("svg",{height:r&&r[0],width:r&&r[1],children:M==null?void 0:M.map((H,E)=>vt.jsx("rect",{id:E,rx:s&&s[E*0],ry:s&&s[E*0],x:H[0],y:H[1],width:I&&I[E][0]+1,height:I&&I[E][1]+1,fill:h?h[E]=="-1"?"none":Hr(p&&p[E]):"none",stroke:F?a&&Hr(a[E]):"rgb(0,0,0)",strokeWidth:"1px"}))})})},QVt=({data:t})=>{const r=JSON.parse(localStorage.getItem("formDimension")),{FillCol:n,Start:i,FCol:o,Size:a,End:s,Points:l,Event:h,CSS:p}=t==null?void 0:t.Properties,f=j1(p),{socket:g}=w1(),M=s?((I,F,H)=>{const E=(a&&a[1]/2)+10,R=(a&&a[0]/2)+250,W=a&&a[1]/2,$=a&&a[0]/2;console.log({Start:i}),console.log({End:s});const G=[];for(let Z=0;Z_.createElement(nVt,{...t,_chartKey:"series"});PO.propTypes={children:function(t,r,n){return lPt(t,r,n,gC)}};const QVt=({data:t,parentSize:r=JSON.parse(localStorage.getItem("formDimension")),posn:n=[0,0]})=>{const{Points:i,Size:o,FCol:a,Radius:s,Visible:l,FStyle:h,FillCol:p,Event:f,CSS:g}=t==null?void 0:t.Properties,{socket:b}=x1(),z=$1(g),M=i&&i[0].map((H,E)=>[i[1][E],H]),I=o&&o[0].map((H,E)=>[o[1][E],H]),F=t==null?void 0:t.Properties.hasOwnProperty("FCol");return vt.jsx("div",{id:t==null?void 0:t.ID,style:{position:"absolute",top:0,left:0,display:l==0?"none":"block",...z},onMouseDown:H=>{Q1(H,b,f,t==null?void 0:t.ID)},onMouseUp:H=>{tr(H,b,f,t==null?void 0:t.ID)},onMouseEnter:H=>{er(H,b,f,t==null?void 0:t.ID)},onMouseMove:H=>{ir(H,b,f,t==null?void 0:t.ID)},onMouseLeave:H=>{rr(H,b,f,t==null?void 0:t.ID)},onWheel:H=>{lr(H,b,f,t==null?void 0:t.ID)},onDoubleClick:H=>{gr(H,b,f,t==null?void 0:t.ID)},children:vt.jsx("svg",{height:r&&r[0],width:r&&r[1],children:M==null?void 0:M.map((H,E)=>vt.jsx("rect",{id:E,rx:s&&s[E*0],ry:s&&s[E*0],x:H[0],y:H[1],width:I&&I[E][0]+1,height:I&&I[E][1]+1,fill:h?h[E]=="-1"?"none":Er(p&&p[E]):"none",stroke:F?a&&Er(a[E]):"rgb(0,0,0)",strokeWidth:"1px"}))})})},tFt=({data:t})=>{const r=JSON.parse(localStorage.getItem("formDimension")),{FillCol:n,Start:i,FCol:o,Size:a,End:s,Points:l,Event:h,CSS:p}=t==null?void 0:t.Properties,f=$1(p),{socket:g}=x1(),M=s?((I,F,H)=>{const E=(a&&a[1]/2)+10,R=(a&&a[0]/2)+250,W=a&&a[1]/2,$=a&&a[0]/2;console.log({Start:i}),console.log({End:s});const G=[];for(let Z=0;Z{const H=a&&a[1]/2+10,E=a&&a[0]/2+10,R=a&&a[1]/2,W=a&&a[0]/2,$=[];for(let G=0;G<(I==null?void 0:I.length);G++){const Z=-I[G],K=G===(I==null?void 0:I.length)-1?2*Math.PI:-I[G+1],et=H+R*Math.cos(Z),at=E+W*Math.sin(Z),tt=H+R*Math.cos(K),ft=E+W*Math.sin(K),dt=` + `;G.push({d:lt,fill:Er(n&&n[Z]),stroke:"black",strokeWidth:"1"})}return G})(i,s):((I,F)=>{const H=a&&a[1]/2+10,E=a&&a[0]/2+10,R=a&&a[1]/2,W=a&&a[0]/2,$=[];for(let G=0;G<(I==null?void 0:I.length);G++){const Z=-I[G],K=G===(I==null?void 0:I.length)-1?2*Math.PI:-I[G+1],et=H+R*Math.cos(Z),at=E+W*Math.sin(Z),tt=H+R*Math.cos(K),ft=E+W*Math.sin(K),dt=` M ${H},${E} L ${et},${at} A ${R},${W} 0 0,0 ${tt},${ft} Z - `;$.push({d:dt,fill:Hr(n&&n[G]),stroke:"black",strokeWidth:"1"})}return $})(i);return vt.jsx("div",{style:{position:"absolute",top:0,left:0,...f},onMouseDown:I=>{er(I,g,h,t==null?void 0:t.ID)},onMouseUp:I=>{rr(I,g,h,t==null?void 0:t.ID)},onMouseEnter:I=>{ir(I,g,h,t==null?void 0:t.ID)},onMouseMove:I=>{or(I,g,h,t==null?void 0:t.ID)},onMouseLeave:I=>{nr(I,g,h,t==null?void 0:t.ID)},onWheel:I=>{hr(I,g,h,t==null?void 0:t.ID)},onDoubleClick:I=>{mr(I,g,h,t==null?void 0:t.ID)},children:vt.jsx("svg",{height:r&&r[0],width:r&&r[1],children:M.map((I,F)=>vt.jsx("path",{d:I.d,fill:I.fill,stroke:I.stroke,strokeWidth:I.strokeWidth},F))})})},tFt=({data:t})=>{const r=JSON.parse(localStorage.getItem("formDimension")),{FillCol:n,Start:i,FCol:o,Points:a,Radius:s,Event:l,CSS:h}=t==null?void 0:t.Properties,p=j1(h),{socket:f}=w1(),b=(z=>{const M=a&&a[1][0],I=a&&a[0][0],F=s&&s[0],H=s&&s[0],E=[];for(let R=0;R<(z==null?void 0:z.length);R++){const W=-z[R],$=R===(z==null?void 0:z.length)-1?2*Math.PI:-z[R+1],G=M+F*Math.cos(W),Z=I+H*Math.sin(W),K=M+F*Math.cos($),et=I+H*Math.sin($),at=` + `;$.push({d:dt,fill:Er(n&&n[G]),stroke:"black",strokeWidth:"1"})}return $})(i);return vt.jsx("div",{style:{position:"absolute",top:0,left:0,...f},onMouseDown:I=>{Q1(I,g,h,t==null?void 0:t.ID)},onMouseUp:I=>{tr(I,g,h,t==null?void 0:t.ID)},onMouseEnter:I=>{er(I,g,h,t==null?void 0:t.ID)},onMouseMove:I=>{ir(I,g,h,t==null?void 0:t.ID)},onMouseLeave:I=>{rr(I,g,h,t==null?void 0:t.ID)},onWheel:I=>{lr(I,g,h,t==null?void 0:t.ID)},onDoubleClick:I=>{gr(I,g,h,t==null?void 0:t.ID)},children:vt.jsx("svg",{height:r&&r[0],width:r&&r[1],children:M.map((I,F)=>vt.jsx("path",{d:I.d,fill:I.fill,stroke:I.stroke,strokeWidth:I.strokeWidth},F))})})},eFt=({data:t})=>{const r=JSON.parse(localStorage.getItem("formDimension")),{FillCol:n,Start:i,FCol:o,Points:a,Radius:s,Event:l,CSS:h}=t==null?void 0:t.Properties,p=$1(h),{socket:f}=x1(),b=(z=>{const M=a&&a[1][0],I=a&&a[0][0],F=s&&s[0],H=s&&s[0],E=[];for(let R=0;R<(z==null?void 0:z.length);R++){const W=-z[R],$=R===(z==null?void 0:z.length)-1?2*Math.PI:-z[R+1],G=M+F*Math.cos(W),Z=I+H*Math.sin(W),K=M+F*Math.cos($),et=I+H*Math.sin($),at=` M ${M},${I} L ${G},${Z} A ${F},${H} 0 0,0 ${K},${et} Z - `;E.push({d:at,fill:"none",stroke:o&&Hr(o[R]),strokeWidth:"1"})}return E})(i);return vt.jsx("div",{style:{position:"absolute",top:0,left:0,...p},onMouseDown:z=>{er(z,f,l,t==null?void 0:t.ID)},onMouseUp:z=>{rr(z,f,l,t==null?void 0:t.ID)},onMouseEnter:z=>{ir(z,f,l,t==null?void 0:t.ID)},onMouseMove:z=>{or(z,f,l,t==null?void 0:t.ID)},onMouseLeave:z=>{nr(z,f,l,t==null?void 0:t.ID)},onWheel:z=>{hr(z,f,l,t==null?void 0:t.ID)},onDoubleClick:z=>{mr(z,f,l,t==null?void 0:t.ID)},children:vt.jsx("svg",{height:r&&r[0],width:r&&r[1],children:b.map((z,M)=>vt.jsx("path",{d:z.d,fill:z.fill,stroke:z.stroke,strokeWidth:z.strokeWidth},M))})})};function eFt(){const[t,r]=_.useState(!0);return{reRender:()=>{r(i=>!i)}}}const PO=t=>Array.isArray(t)?1+Math.max(0,...t.map(PO)):0,rFt=t=>t.reduce((r,n)=>r.concat(n),[]),iFt=t=>PO(t)===3?rFt(t):t,TO=(t,r=12)=>{const n=localStorage.getItem("fontscale"),i=document.createElement("div");i.style.visibility="hidden",i.style.display="inline-block",i.style.position="fixed",i.style.fontSize=r,i.style.lineHeight=r+"px",i.style.top="0",i.style.left="0",i.style.fontSize=r*n+"px",t.forEach(s=>{const l=document.createElement("div");l.style.margin="0",l.style.padding="0",l.textContent=s,l.style.display="block",i.appendChild(l)}),document.body.appendChild(i);const o=i.offsetWidth,a=i.offsetHeight;return document.body.removeChild(i),[a,o]},gC=({data:t,fontProperties:r})=>{const{Visible:n,Points:i,Text:o,FCol:a,BCol:s,Event:l,CSS:h}=t==null?void 0:t.Properties;console.log("254",{data:t,fontProperties:r});const{socket:p,fontScale:f}=w1(),g=j1(h);eFt();const b=JSON.parse(localStorage.getItem("formDimension")),z=iFt(i),M=z&&z[0].map((I,F)=>[z[1][F],I]);return vt.jsx(vt.Fragment,{children:vt.jsx("div",{style:{position:"absolute",display:n==0?"none":"block",top:0,left:0},onMouseDown:I=>{er(I,p,l,t==null?void 0:t.ID)},onMouseUp:I=>{rr(I,p,l,t==null?void 0:t.ID)},onMouseEnter:I=>{ir(I,p,l,t==null?void 0:t.ID)},onMouseMove:I=>{or(I,p,l,t==null?void 0:t.ID)},onMouseLeave:I=>{nr(I,p,l,t==null?void 0:t.ID)},onWheel:I=>{hr(I,p,l,t==null?void 0:t.ID)},onDoubleClick:I=>{mr(I,p,l,t==null?void 0:t.ID)},children:vt.jsx("svg",{height:b&&b[0],width:b&&b[1],children:o==null?void 0:o.map((I,F)=>{var $,G;const H=TO([I],r!=null&&r.Size?r.Size*f:12*f),E=H==null?void 0:H.width,R=H==null?void 0:H.height,W=M[F]||[($=M==null?void 0:M[F-1])==null?void 0:$[0],((G=M==null?void 0:M[F-1])==null?void 0:G[1])+10];return vt.jsxs("g",{children:[vt.jsx("rect",{x:W&&W[0],y:W&&W[1],width:E,height:R,transform:`translate(${W&&W[0]}, ${W&&W[1]}) rotate(${(r==null?void 0:r.Rotate)*(180/Math.PI)}) translate(${W&&-W[0]}, ${W&&-W[1]})`,fill:s?Hr(s):"transparent"}),vt.jsx("text",{id:`${t==null?void 0:t.ID}-t${F+1}`,dominantBaseline:"hanging",dy:"0em",x:W&&W[0],y:W&&W[1],fontFamily:r==null?void 0:r.PName,fontSize:r!=null&&r.Size?`${r.Size*f}px`:`${12*f}px`,fill:a?Hr(a[F]):"black",fontStyle:r!=null&&r.Italic&&(r==null?void 0:r.Italic)==1?"italic":"none",fontWeight:r!=null&&r.Weight?r==null?void 0:r.Weight:0,textDecoration:r!=null&&r.Underline&&(r==null?void 0:r.Underline)==1?"underline":"none",transform:`translate(${W&&W[0]}, ${W&&W[1]}) rotate(${(r==null?void 0:r.Rotate)*(180/Math.PI)}) translate(${W&&-W[0]}, ${W&&-W[1]})`,style:{...g},children:I})]},F)})})})})};gC.calculateTextDimensions=TO;const nFt=({data:t})=>{const{socket:r}=w1(),{Interval:n,FireOnce:i,Active:o,Event:a}=t==null?void 0:t.Properties;let s=i||0,h=(t==null?void 0:t.Properties.hasOwnProperty("Active"))?o:1;return _.useEffect(()=>{let p,f;const g=JSON.stringify({Event:{EventName:"Timer",ID:t==null?void 0:t.ID,Info:[]}});if(h==1)return s==1?(p&&clearInterval(p),f=setTimeout(()=>{r.send(g)},n&&n),localStorage.setItem(t.ID,JSON.stringify({Event:{EventName:"Timer",ID:t==null?void 0:t.ID,FireOnce:2}}))):s==2?(p&&clearInterval(p),f&&clearTimeout(f),clearInterval(p),clearTimeout(f)):s==0&&(localStorage.setItem(t.ID,JSON.stringify({Event:{EventName:"Timer",ID:t==null?void 0:t.ID,FireOnce:0}})),p=setInterval(()=>{r.send(g)},n&&n)),()=>{clearInterval(p),clearTimeout(f)}},[t]),vt.jsx(vt.Fragment,{})},oFt=({data:t})=>{var H,E,R,W,$,G,Z;const{findDesiredData:r,socket:n}=w1(),{View:i,Border:o,ColTitles:a,ImageIndex:s,ImageListObj:l,Items:h,ReportInfo:p,Event:f,CSS:g}=t&&(t==null?void 0:t.Properties),b=j1(g),z=Yr(t==null?void 0:t.Properties);_.useEffect(()=>{localStorage.setItem(t.ID,JSON.stringify({Event:{SelItems:new Array(h==null?void 0:h.length).fill(0)}}))},[t==null?void 0:t.Properties]);const M=(K,et,at)=>{const tt=JSON.stringify({Event:{EventName:at,ID:t==null?void 0:t.ID,Info:[K+1,1,et,4]}}),ft=new Array(h==null?void 0:h.length).fill(0);ft[K]=1;const dt=JSON.stringify({Event:{SelItems:ft}});localStorage.setItem(t==null?void 0:t.ID,dt),f&&f.some(lt=>lt[0]===at)&&(console.log(tt),n.send(tt))},I=(K,et,at)=>{at==="ItemDblClick"&&mr(e,n,f,t==null?void 0:t.ID);const tt=K!=null&&K.altKey?4:0,ft=K!=null&&K.ctrlKey?2:0,dt=K!=null&&K.shiftKey?1:0;K==null||K.button;let ht=tt+ft+dt;M(et,ht,at)},F=({orientation:K="row",Images:et=[],parentOrientation:at="row",height:tt,width:ft,imageHeight:dt,imageWidth:ht,style:lt=""})=>{const yt=h||[];return vt.jsx("div",{className:`d-flex flex-wrap flex-${at}`,style:{...z,border:o?"1px solid black":null,...lt,...b},onMouseDown:mt=>{er(mt,n,f,t==null?void 0:t.ID)},onMouseUp:mt=>{rr(mt,n,f,t==null?void 0:t.ID)},onMouseEnter:mt=>{ir(mt,n,f,t==null?void 0:t.ID)},onMouseMove:mt=>{or(mt,n,f,t==null?void 0:t.ID)},onMouseLeave:mt=>{nr(mt,n,f,t==null?void 0:t.ID)},onWheel:mt=>{hr(mt,n,f,t==null?void 0:t.ID)},onDoubleClick:mt=>{mr(mt,n,f,t==null?void 0:t.ID)},onKeyDown:()=>{In(e,n,f,t==null?void 0:t.ID)},children:yt==null?void 0:yt.map((mt,gt)=>vt.jsxs("div",{onDoubleClick:kt=>I(kt.nativeEvent,gt,"ItemDblClick"),onClick:kt=>I(kt.nativeEvent,gt,"ItemDown"),style:{width:"60px"},className:`d-flex flex-${K}`,children:[et.length>0?vt.jsx("img",{style:{width:ht,height:dt},src:`${Qi()}${et[s[gt]-1]}`}):null,vt.jsx("span",{style:{fontSize:"12px"},children:mt})]}))})};if(i&&i=="Icon"){const K=r(l&&l[0]),et=(H=K==null?void 0:K.Properties)==null?void 0:H.Files,at=K&&((E=K==null?void 0:K.Properties)==null?void 0:E.Size);return vt.jsx(F,{style:{overflowY:"scroll"},orientation:"column",height:`${at&&at[0]+15}px`,width:`${at&&at[1]+30}px`,Images:et,imageHeight:`${at&&at[0]}px`,imageWidth:`${at&&at[1]}px`})}if(i&&i=="SmallIcon"){const K=r(l&&l[1]),et=(R=K==null?void 0:K.Properties)==null?void 0:R.Files,at=(W=K==null?void 0:K.Properties)==null?void 0:W.Size;return vt.jsx(F,{imageHeight:`${at&&at[0]}px`,imageWidth:`${at&&at[1]}px`,orientation:"row",height:`${at&&at[0]+15}px`,width:`${at&&at[1]+30}px`,Images:et})}if(i&&i=="List"){const K=r(l&&l[1]),et=($=K==null?void 0:K.Properties)==null?void 0:$.Files,at=(G=K==null?void 0:K.Properties)==null?void 0:G.Size;return vt.jsx(F,{imageHeight:`${at&&at[0]}px`,imageWidth:`${at&&at[1]}px`,parentOrientation:"column",orientation:"row",height:`${at&&at[0]}px`,width:`${at&&at[1]+30}px`,Images:et})}if(i&&i=="Report"){const K=r(l&&l[1]),et=(Z=K==null?void 0:K.Properties)==null?void 0:Z.Files,at=Dq(et||[],h||[],p||[],s||[]);return vt.jsxs("div",{style:{...z,border:o?"1px solid black":null,overflowY:"scroll",...b},children:[vt.jsx("div",{className:"d-flex align-items-center",children:a==null?void 0:a.map((tt,ft,dt)=>vt.jsx("div",{style:{borderRight:ft!==dt.length-1?"1px solid #F0F0F0":"none",flex:1,fontSize:"12px",paddingLeft:"5px"},onMouseDown:ht=>{er(ht,n,f,t==null?void 0:t.ID)},onMouseUp:ht=>{rr(ht,n,f,t==null?void 0:t.ID)},onMouseEnter:ht=>{ir(ht,n,f,t==null?void 0:t.ID)},onMouseMove:ht=>{or(ht,n,f,t==null?void 0:t.ID)},onMouseLeave:ht=>{nr(ht,n,f,t==null?void 0:t.ID)},onWheel:ht=>{hr(ht,n,f,t==null?void 0:t.ID)},onDoubleClick:ht=>{mr(ht,n,f,t==null?void 0:t.ID)},onKeyDown:()=>{In(e,n,f,t==null?void 0:t.ID)},children:tt}))}),vt.jsx("div",{className:"mt-1",children:at==null?void 0:at.map((tt,ft)=>vt.jsxs("div",{className:"d-flex align-items-center",children:[vt.jsx("div",{style:{flex:1,paddingLeft:"5px",cursor:"pointer"},onKeyDown:()=>{In(e,n,f,t==null?void 0:t.ID)},onDoubleClick:dt=>I(dt.nativeEvent,ft,"ItemDblClick"),onMouseDown:dt=>{er(dt,n,f,t==null?void 0:t.ID)},onMouseUp:dt=>{rr(dt,n,f,t==null?void 0:t.ID)},onMouseEnter:dt=>{ir(dt,n,f,t==null?void 0:t.ID)},onMouseMove:dt=>{or(dt,n,f,t==null?void 0:t.ID)},onMouseLeave:dt=>{nr(dt,n,f,t==null?void 0:t.ID)},onWheel:dt=>{hr(dt,n,f,t==null?void 0:t.ID)},onClick:dt=>I(dt.nativeEvent,ft,"ItemDown"),children:vt.jsxs("div",{className:"d-flex align-items-center",children:[tt!=null&&tt.image?vt.jsx("img",{src:`${Qi()}${tt.image}`}):null,vt.jsx("span",{style:{fontSize:"12px"},children:tt==null?void 0:tt.title})]})}),vt.jsx("div",{style:{flex:1,fontSize:"12px",paddingLeft:"5px",cursor:"pointer"},onDoubleClick:dt=>I(dt.nativeEvent,ft,"ItemDblClick"),onMouseDown:dt=>{er(dt,n,f,t==null?void 0:t.ID)},onMouseUp:dt=>{rr(dt,n,f,t==null?void 0:t.ID)},onMouseEnter:dt=>{ir(dt,n,f,t==null?void 0:t.ID)},onMouseMove:dt=>{or(dt,n,f,t==null?void 0:t.ID)},onMouseLeave:dt=>{nr(dt,n,f,t==null?void 0:t.ID)},onWheel:dt=>{hr(dt,n,f,t==null?void 0:t.ID)},onClick:dt=>I(dt.nativeEvent,ft,"ItemDown"),onKeyDown:()=>{In(e,n,f,t==null?void 0:t.ID)},children:tt==null?void 0:tt.description}),vt.jsx("div",{style:{flex:1,fontSize:"12px",paddingLeft:"5px",cursor:"pointer"},onKeyDown:()=>{In(e,n,f,t==null?void 0:t.ID)},onDoubleClick:dt=>I(dt.nativeEvent,ft,"ItemDblClick"),onMouseDown:dt=>{er(dt,n,f,t==null?void 0:t.ID)},onMouseUp:dt=>{rr(dt,n,f,t==null?void 0:t.ID)},onMouseEnter:dt=>{ir(dt,n,f,t==null?void 0:t.ID)},onMouseMove:dt=>{or(dt,n,f,t==null?void 0:t.ID)},onMouseLeave:dt=>{nr(dt,n,f,t==null?void 0:t.ID)},onWheel:dt=>{hr(dt,n,f,t==null?void 0:t.ID)},onClick:dt=>I(dt.nativeEvent,ft,"ItemDown"),children:tt==null?void 0:tt.index})]}))})]})}},aFt=({data:t})=>{const{findDesiredData:r,socket:n}=w1(),{Points:i,Picture:o,Visible:a,Event:s,CSS:l}=t==null?void 0:t.Properties,h=j1(l),p=i&&i[0].map((b,z)=>[i[1][z],b]),f=JSON.parse(localStorage.getItem("formDimension")),g=Yr(t.Properties);return vt.jsx("div",{id:t==null?void 0:t.ID,style:{position:"absolute",top:0,left:0,display:a==0?"none":"block",...g,...h},onMouseDown:b=>{er(b,n,s,t.ID)},onMouseUp:b=>{rr(b,n,s,t==null?void 0:t.ID)},onMouseEnter:b=>{ir(b,n,s,t==null?void 0:t.ID)},onMouseMove:b=>{or(b,n,s,t==null?void 0:t.ID)},onMouseLeave:b=>{nr(b,n,s,t==null?void 0:t.ID)},onWheel:b=>{hr(b,n,s,t==null?void 0:t.ID)},onDoubleClick:b=>{mr(b,n,s,t==null?void 0:t.ID)},children:vt.jsx("svg",{height:f&&f[0],width:f&&f[1],children:p.map((b,z)=>{const M=r(o&&o[z]),I=bq(M);return vt.jsx("image",{href:I,x:b[0],y:b[1]})})})})};var VO={},py={exports:{}};/*! + `;E.push({d:at,fill:"none",stroke:o&&Er(o[R]),strokeWidth:"1"})}return E})(i);return vt.jsx("div",{style:{position:"absolute",top:0,left:0,...p},onMouseDown:z=>{Q1(z,f,l,t==null?void 0:t.ID)},onMouseUp:z=>{tr(z,f,l,t==null?void 0:t.ID)},onMouseEnter:z=>{er(z,f,l,t==null?void 0:t.ID)},onMouseMove:z=>{ir(z,f,l,t==null?void 0:t.ID)},onMouseLeave:z=>{rr(z,f,l,t==null?void 0:t.ID)},onWheel:z=>{lr(z,f,l,t==null?void 0:t.ID)},onDoubleClick:z=>{gr(z,f,l,t==null?void 0:t.ID)},children:vt.jsx("svg",{height:r&&r[0],width:r&&r[1],children:b.map((z,M)=>vt.jsx("path",{d:z.d,fill:z.fill,stroke:z.stroke,strokeWidth:z.strokeWidth},M))})})};function rFt(){const[t,r]=_.useState(!0);return{reRender:()=>{r(i=>!i)}}}const TO=t=>Array.isArray(t)?1+Math.max(0,...t.map(TO)):0,iFt=t=>t.reduce((r,n)=>r.concat(n),[]),nFt=t=>TO(t)===3?iFt(t):t,VO=(t,r=12)=>{const n=localStorage.getItem("fontscale"),i=document.createElement("div");i.style.visibility="hidden",i.style.display="inline-block",i.style.position="fixed",i.style.fontSize=r,i.style.lineHeight=r+"px",i.style.top="0",i.style.left="0",i.style.fontSize=r*n+"px",t.forEach(s=>{const l=document.createElement("div");l.style.margin="0",l.style.padding="0",l.textContent=s,l.style.display="block",i.appendChild(l)}),document.body.appendChild(i);const o=i.offsetWidth,a=i.offsetHeight;return document.body.removeChild(i),[a,o]},mC=({data:t,fontProperties:r})=>{const{Visible:n,Points:i,Text:o,FCol:a,BCol:s,Event:l,CSS:h}=t==null?void 0:t.Properties;console.log("254",{data:t,fontProperties:r});const{socket:p,fontScale:f}=x1(),g=$1(h);rFt();const b=JSON.parse(localStorage.getItem("formDimension")),z=nFt(i),M=z&&z[0].map((I,F)=>[z[1][F],I]);return vt.jsx(vt.Fragment,{children:vt.jsx("div",{style:{position:"absolute",display:n==0?"none":"block",top:0,left:0},onMouseDown:I=>{Q1(I,p,l,t==null?void 0:t.ID)},onMouseUp:I=>{tr(I,p,l,t==null?void 0:t.ID)},onMouseEnter:I=>{er(I,p,l,t==null?void 0:t.ID)},onMouseMove:I=>{ir(I,p,l,t==null?void 0:t.ID)},onMouseLeave:I=>{rr(I,p,l,t==null?void 0:t.ID)},onWheel:I=>{lr(I,p,l,t==null?void 0:t.ID)},onDoubleClick:I=>{gr(I,p,l,t==null?void 0:t.ID)},children:vt.jsx("svg",{height:b&&b[0],width:b&&b[1],children:o==null?void 0:o.map((I,F)=>{var $,G;const H=VO([I],r!=null&&r.Size?r.Size*f:12*f),E=H==null?void 0:H.width,R=H==null?void 0:H.height,W=M[F]||[($=M==null?void 0:M[F-1])==null?void 0:$[0],((G=M==null?void 0:M[F-1])==null?void 0:G[1])+10];return vt.jsxs("g",{children:[vt.jsx("rect",{x:W&&W[0],y:W&&W[1],width:E,height:R,transform:`translate(${W&&W[0]}, ${W&&W[1]}) rotate(${(r==null?void 0:r.Rotate)*(180/Math.PI)}) translate(${W&&-W[0]}, ${W&&-W[1]})`,fill:s?Er(s):"transparent"}),vt.jsx("text",{id:`${t==null?void 0:t.ID}-t${F+1}`,dominantBaseline:"hanging",dy:"0em",x:W&&W[0],y:W&&W[1],fontFamily:r==null?void 0:r.PName,fontSize:r!=null&&r.Size?`${r.Size*f}px`:`${12*f}px`,fill:a?Er(a[F]):"black",fontStyle:r!=null&&r.Italic&&(r==null?void 0:r.Italic)==1?"italic":"none",fontWeight:r!=null&&r.Weight?r==null?void 0:r.Weight:0,textDecoration:r!=null&&r.Underline&&(r==null?void 0:r.Underline)==1?"underline":"none",transform:`translate(${W&&W[0]}, ${W&&W[1]}) rotate(${(r==null?void 0:r.Rotate)*(180/Math.PI)}) translate(${W&&-W[0]}, ${W&&-W[1]})`,style:{...g},children:I})]},F)})})})})};mC.calculateTextDimensions=VO;const oFt=({data:t})=>{const{socket:r}=x1(),{Interval:n,FireOnce:i,Active:o,Event:a}=t==null?void 0:t.Properties;let s=i||0,h=(t==null?void 0:t.Properties.hasOwnProperty("Active"))?o:1;return _.useEffect(()=>{let p,f;const g=JSON.stringify({Event:{EventName:"Timer",ID:t==null?void 0:t.ID,Info:[]}});if(h==1)return s==1?(p&&clearInterval(p),f=setTimeout(()=>{r.send(g)},n&&n),localStorage.setItem(t.ID,JSON.stringify({Event:{EventName:"Timer",ID:t==null?void 0:t.ID,FireOnce:2}}))):s==2?(p&&clearInterval(p),f&&clearTimeout(f),clearInterval(p),clearTimeout(f)):s==0&&(localStorage.setItem(t.ID,JSON.stringify({Event:{EventName:"Timer",ID:t==null?void 0:t.ID,FireOnce:0}})),p=setInterval(()=>{r.send(g)},n&&n)),()=>{clearInterval(p),clearTimeout(f)}},[t]),vt.jsx(vt.Fragment,{})},aFt=({data:t})=>{var H,E,R,W,$,G,Z;const{findDesiredData:r,socket:n}=x1(),{View:i,Border:o,ColTitles:a,ImageIndex:s,ImageListObj:l,Items:h,ReportInfo:p,Event:f,CSS:g}=t&&(t==null?void 0:t.Properties),b=$1(g),z=Gr(t==null?void 0:t.Properties);_.useEffect(()=>{localStorage.setItem(t.ID,JSON.stringify({Event:{SelItems:new Array(h==null?void 0:h.length).fill(0)}}))},[t==null?void 0:t.Properties]);const M=(K,et,at)=>{const tt=JSON.stringify({Event:{EventName:at,ID:t==null?void 0:t.ID,Info:[K+1,1,et,4]}}),ft=new Array(h==null?void 0:h.length).fill(0);ft[K]=1;const dt=JSON.stringify({Event:{SelItems:ft}});localStorage.setItem(t==null?void 0:t.ID,dt),f&&f.some(lt=>lt[0]===at)&&(console.log(tt),n.send(tt))},I=(K,et,at)=>{at==="ItemDblClick"&&gr(e,n,f,t==null?void 0:t.ID);const tt=K!=null&&K.altKey?4:0,ft=K!=null&&K.ctrlKey?2:0,dt=K!=null&&K.shiftKey?1:0;K==null||K.button;let ht=tt+ft+dt;M(et,ht,at)},F=({orientation:K="row",Images:et=[],parentOrientation:at="row",height:tt,width:ft,imageHeight:dt,imageWidth:ht,style:lt=""})=>{const yt=h||[];return vt.jsx("div",{className:`d-flex flex-wrap flex-${at}`,style:{...z,border:o?"1px solid black":null,...lt,...b},onMouseDown:mt=>{Q1(mt,n,f,t==null?void 0:t.ID)},onMouseUp:mt=>{tr(mt,n,f,t==null?void 0:t.ID)},onMouseEnter:mt=>{er(mt,n,f,t==null?void 0:t.ID)},onMouseMove:mt=>{ir(mt,n,f,t==null?void 0:t.ID)},onMouseLeave:mt=>{rr(mt,n,f,t==null?void 0:t.ID)},onWheel:mt=>{lr(mt,n,f,t==null?void 0:t.ID)},onDoubleClick:mt=>{gr(mt,n,f,t==null?void 0:t.ID)},onKeyDown:()=>{Ln(e,n,f,t==null?void 0:t.ID)},children:yt==null?void 0:yt.map((mt,gt)=>vt.jsxs("div",{onDoubleClick:_t=>I(_t.nativeEvent,gt,"ItemDblClick"),onClick:_t=>I(_t.nativeEvent,gt,"ItemDown"),style:{width:"60px"},className:`d-flex flex-${K}`,children:[et.length>0?vt.jsx("img",{style:{width:ht,height:dt},src:`${Zi()}${et[s[gt]-1]}`}):null,vt.jsx("span",{style:{fontSize:"12px"},children:mt})]}))})};if(i&&i=="Icon"){const K=r(l&&l[0]),et=(H=K==null?void 0:K.Properties)==null?void 0:H.Files,at=K&&((E=K==null?void 0:K.Properties)==null?void 0:E.Size);return vt.jsx(F,{style:{overflowY:"scroll"},orientation:"column",height:`${at&&at[0]+15}px`,width:`${at&&at[1]+30}px`,Images:et,imageHeight:`${at&&at[0]}px`,imageWidth:`${at&&at[1]}px`})}if(i&&i=="SmallIcon"){const K=r(l&&l[1]),et=(R=K==null?void 0:K.Properties)==null?void 0:R.Files,at=(W=K==null?void 0:K.Properties)==null?void 0:W.Size;return vt.jsx(F,{imageHeight:`${at&&at[0]}px`,imageWidth:`${at&&at[1]}px`,orientation:"row",height:`${at&&at[0]+15}px`,width:`${at&&at[1]+30}px`,Images:et})}if(i&&i=="List"){const K=r(l&&l[1]),et=($=K==null?void 0:K.Properties)==null?void 0:$.Files,at=(G=K==null?void 0:K.Properties)==null?void 0:G.Size;return vt.jsx(F,{imageHeight:`${at&&at[0]}px`,imageWidth:`${at&&at[1]}px`,parentOrientation:"column",orientation:"row",height:`${at&&at[0]}px`,width:`${at&&at[1]+30}px`,Images:et})}if(i&&i=="Report"){const K=r(l&&l[1]),et=(Z=K==null?void 0:K.Properties)==null?void 0:Z.Files,at=Pq(et||[],h||[],p||[],s||[]);return vt.jsxs("div",{style:{...z,border:o?"1px solid black":null,overflowY:"scroll",...b},children:[vt.jsx("div",{className:"d-flex align-items-center",children:a==null?void 0:a.map((tt,ft,dt)=>vt.jsx("div",{style:{borderRight:ft!==dt.length-1?"1px solid #F0F0F0":"none",flex:1,fontSize:"12px",paddingLeft:"5px"},onMouseDown:ht=>{Q1(ht,n,f,t==null?void 0:t.ID)},onMouseUp:ht=>{tr(ht,n,f,t==null?void 0:t.ID)},onMouseEnter:ht=>{er(ht,n,f,t==null?void 0:t.ID)},onMouseMove:ht=>{ir(ht,n,f,t==null?void 0:t.ID)},onMouseLeave:ht=>{rr(ht,n,f,t==null?void 0:t.ID)},onWheel:ht=>{lr(ht,n,f,t==null?void 0:t.ID)},onDoubleClick:ht=>{gr(ht,n,f,t==null?void 0:t.ID)},onKeyDown:()=>{Ln(e,n,f,t==null?void 0:t.ID)},children:tt}))}),vt.jsx("div",{className:"mt-1",children:at==null?void 0:at.map((tt,ft)=>vt.jsxs("div",{className:"d-flex align-items-center",children:[vt.jsx("div",{style:{flex:1,paddingLeft:"5px",cursor:"pointer"},onKeyDown:()=>{Ln(e,n,f,t==null?void 0:t.ID)},onDoubleClick:dt=>I(dt.nativeEvent,ft,"ItemDblClick"),onMouseDown:dt=>{Q1(dt,n,f,t==null?void 0:t.ID)},onMouseUp:dt=>{tr(dt,n,f,t==null?void 0:t.ID)},onMouseEnter:dt=>{er(dt,n,f,t==null?void 0:t.ID)},onMouseMove:dt=>{ir(dt,n,f,t==null?void 0:t.ID)},onMouseLeave:dt=>{rr(dt,n,f,t==null?void 0:t.ID)},onWheel:dt=>{lr(dt,n,f,t==null?void 0:t.ID)},onClick:dt=>I(dt.nativeEvent,ft,"ItemDown"),children:vt.jsxs("div",{className:"d-flex align-items-center",children:[tt!=null&&tt.image?vt.jsx("img",{src:`${Zi()}${tt.image}`}):null,vt.jsx("span",{style:{fontSize:"12px"},children:tt==null?void 0:tt.title})]})}),vt.jsx("div",{style:{flex:1,fontSize:"12px",paddingLeft:"5px",cursor:"pointer"},onDoubleClick:dt=>I(dt.nativeEvent,ft,"ItemDblClick"),onMouseDown:dt=>{Q1(dt,n,f,t==null?void 0:t.ID)},onMouseUp:dt=>{tr(dt,n,f,t==null?void 0:t.ID)},onMouseEnter:dt=>{er(dt,n,f,t==null?void 0:t.ID)},onMouseMove:dt=>{ir(dt,n,f,t==null?void 0:t.ID)},onMouseLeave:dt=>{rr(dt,n,f,t==null?void 0:t.ID)},onWheel:dt=>{lr(dt,n,f,t==null?void 0:t.ID)},onClick:dt=>I(dt.nativeEvent,ft,"ItemDown"),onKeyDown:()=>{Ln(e,n,f,t==null?void 0:t.ID)},children:tt==null?void 0:tt.description}),vt.jsx("div",{style:{flex:1,fontSize:"12px",paddingLeft:"5px",cursor:"pointer"},onKeyDown:()=>{Ln(e,n,f,t==null?void 0:t.ID)},onDoubleClick:dt=>I(dt.nativeEvent,ft,"ItemDblClick"),onMouseDown:dt=>{Q1(dt,n,f,t==null?void 0:t.ID)},onMouseUp:dt=>{tr(dt,n,f,t==null?void 0:t.ID)},onMouseEnter:dt=>{er(dt,n,f,t==null?void 0:t.ID)},onMouseMove:dt=>{ir(dt,n,f,t==null?void 0:t.ID)},onMouseLeave:dt=>{rr(dt,n,f,t==null?void 0:t.ID)},onWheel:dt=>{lr(dt,n,f,t==null?void 0:t.ID)},onClick:dt=>I(dt.nativeEvent,ft,"ItemDown"),children:tt==null?void 0:tt.index})]}))})]})}},sFt=({data:t})=>{const{findDesiredData:r,socket:n}=x1(),{Points:i,Picture:o,Visible:a,Event:s,CSS:l}=t==null?void 0:t.Properties,h=$1(l),p=i&&i[0].map((b,z)=>[i[1][z],b]),f=JSON.parse(localStorage.getItem("formDimension")),g=Gr(t.Properties);return vt.jsx("div",{id:t==null?void 0:t.ID,style:{position:"absolute",top:0,left:0,display:a==0?"none":"block",...g,...h},onMouseDown:b=>{Q1(b,n,s,t.ID)},onMouseUp:b=>{tr(b,n,s,t==null?void 0:t.ID)},onMouseEnter:b=>{er(b,n,s,t==null?void 0:t.ID)},onMouseMove:b=>{ir(b,n,s,t==null?void 0:t.ID)},onMouseLeave:b=>{rr(b,n,s,t==null?void 0:t.ID)},onWheel:b=>{lr(b,n,s,t==null?void 0:t.ID)},onDoubleClick:b=>{gr(b,n,s,t==null?void 0:t.ID)},children:vt.jsx("svg",{height:f&&f[0],width:f&&f[1],children:p.map((b,z)=>{const M=r(o&&o[z]),I=wq(M);return vt.jsx("image",{href:I,x:b[0],y:b[1]})})})})};var FO={},py={exports:{}};/*! * ApexCharts v3.52.0 * (c) 2018-2024 ApexCharts * Released under the MIT License. */(function(t,r){function n(Q,c){var u=Object.keys(Q);if(Object.getOwnPropertySymbols){var d=Object.getOwnPropertySymbols(Q);c&&(d=d.filter(function(v){return Object.getOwnPropertyDescriptor(Q,v).enumerable})),u.push.apply(u,d)}return u}function i(Q){for(var c=1;c"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}();return function(){var u,d=f(Q);if(c){var v=f(this).constructor;u=Reflect.construct(d,arguments,v)}else u=d.apply(this,arguments);return function(m,x){if(x&&(typeof x=="object"||typeof x=="function"))return x;if(x!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return b(m)}(this,u)}}function M(Q,c){return function(u){if(Array.isArray(u))return u}(Q)||function(u,d){var v=u==null?null:typeof Symbol<"u"&&u[Symbol.iterator]||u["@@iterator"];if(v!=null){var m,x,w=[],k=!0,L=!1;try{for(v=v.call(u);!(k=(m=v.next()).done)&&(w.push(m.value),!d||w.length!==d);k=!0);}catch(D){L=!0,x=D}finally{try{k||v.return==null||v.return()}finally{if(L)throw x}}return w}}(Q,c)||F(Q,c)||function(){throw new TypeError(`Invalid attempt to destructure non-iterable instance. In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}()}function I(Q){return function(c){if(Array.isArray(c))return H(c)}(Q)||function(c){if(typeof Symbol<"u"&&c[Symbol.iterator]!=null||c["@@iterator"]!=null)return Array.from(c)}(Q)||F(Q)||function(){throw new TypeError(`Invalid attempt to spread non-iterable instance. -In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}()}function F(Q,c){if(Q){if(typeof Q=="string")return H(Q,c);var u=Object.prototype.toString.call(Q).slice(8,-1);return u==="Object"&&Q.constructor&&(u=Q.constructor.name),u==="Map"||u==="Set"?Array.from(Q):u==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(u)?H(Q,c):void 0}}function H(Q,c){(c==null||c>Q.length)&&(c=Q.length);for(var u=0,d=new Array(c);u>16,w=d>>8&255,k=255&d;return"#"+(16777216+65536*(Math.round((v-x)*m)+x)+256*(Math.round((v-w)*m)+w)+(Math.round((v-k)*m)+k)).toString(16).slice(1)}},{key:"shadeColor",value:function(c,u){return Q.isColorHex(u)?this.shadeHexColor(c,u):this.shadeRGBColor(c,u)}}],[{key:"bind",value:function(c,u){return function(){return c.apply(u,arguments)}}},{key:"isObject",value:function(c){return c&&o(c)==="object"&&!Array.isArray(c)&&c!=null}},{key:"is",value:function(c,u){return Object.prototype.toString.call(u)==="[object "+c+"]"}},{key:"listToArray",value:function(c){var u,d=[];for(u=0;u1&&arguments[1]!==void 0?arguments[1]:2;return Number.isInteger(c)?c:parseFloat(c.toPrecision(u))}},{key:"randomId",value:function(){return(Math.random()+1).toString(36).substring(4)}},{key:"noExponents",value:function(c){var u=String(c).split(/[eE]/);if(u.length===1)return u[0];var d="",v=c<0?"-":"",m=u[0].replace(".",""),x=Number(u[1])+1;if(x<0){for(d=v+"0.";x++;)d+="0";return d+m.replace(/^-/,"")}for(x-=m.length;x--;)d+="0";return m+d}},{key:"getDimensions",value:function(c){var u=getComputedStyle(c,null),d=c.clientHeight,v=c.clientWidth;return d-=parseFloat(u.paddingTop)+parseFloat(u.paddingBottom),[v-=parseFloat(u.paddingLeft)+parseFloat(u.paddingRight),d]}},{key:"getBoundingClientRect",value:function(c){var u=c.getBoundingClientRect();return{top:u.top,right:u.right,bottom:u.bottom,left:u.left,width:c.clientWidth,height:c.clientHeight,x:u.left,y:u.top}}},{key:"getLargestStringFromArr",value:function(c){return c.reduce(function(u,d){return Array.isArray(d)&&(d=d.reduce(function(v,m){return v.length>m.length?v:m})),u.length>d.length?u:d},0)}},{key:"hexToRgba",value:function(){var c=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"#999999",u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:.6;c.substring(0,1)!=="#"&&(c="#999999");var d=c.replace("#","");d=d.match(new RegExp("(.{"+d.length/3+"})","g"));for(var v=0;v1&&arguments[1]!==void 0?arguments[1]:"x",d=c.toString().slice();return d=d.replace(/[` ~!@#$%^&*()|+\=?;:'",.<>{}[\]\\/]/gi,u)}},{key:"negToZero",value:function(c){return c<0?0:c}},{key:"moveIndexInArray",value:function(c,u,d){if(d>=c.length)for(var v=d-c.length+1;v--;)c.push(void 0);return c.splice(d,0,c.splice(u,1)[0]),c}},{key:"extractNumber",value:function(c){return parseFloat(c.replace(/[^\d.]*/g,""))}},{key:"findAncestor",value:function(c,u){for(;(c=c.parentElement)&&!c.classList.contains(u););return c}},{key:"setELstyles",value:function(c,u){for(var d in u)u.hasOwnProperty(d)&&(c.style.key=u[d])}},{key:"preciseAddition",value:function(c,u){var d=(String(c).split(".")[1]||"").length,v=(String(u).split(".")[1]||"").length,m=Math.pow(10,Math.max(d,v));return(Math.round(c*m)+Math.round(u*m))/m}},{key:"isNumber",value:function(c){return!isNaN(c)&&parseFloat(Number(c))===c&&!isNaN(parseInt(c,10))}},{key:"isFloat",value:function(c){return Number(c)===c&&c%1!=0}},{key:"isSafari",value:function(){return/^((?!chrome|android).)*safari/i.test(navigator.userAgent)}},{key:"isFirefox",value:function(){return navigator.userAgent.toLowerCase().indexOf("firefox")>-1}},{key:"isIE11",value:function(){if(window.navigator.userAgent.indexOf("MSIE")!==-1||window.navigator.appVersion.indexOf("Trident/")>-1)return!0}},{key:"isIE",value:function(){var c=window.navigator.userAgent,u=c.indexOf("MSIE ");if(u>0)return parseInt(c.substring(u+5,c.indexOf(".",u)),10);if(c.indexOf("Trident/")>0){var d=c.indexOf("rv:");return parseInt(c.substring(d+3,c.indexOf(".",d)),10)}var v=c.indexOf("Edge/");return v>0&&parseInt(c.substring(v+5,c.indexOf(".",v)),10)}},{key:"getGCD",value:function(c,u){var d=arguments.length>2&&arguments[2]!==void 0?arguments[2]:7,v=Math.pow(10,d-Math.floor(Math.log10(Math.max(c,u))));for(c=Math.round(Math.abs(c)*v),u=Math.round(Math.abs(u)*v);u;){var m=u;u=c%u,c=m}return c/v}},{key:"getPrimeFactors",value:function(c){for(var u=[],d=2;c>=2;)c%d==0?(u.push(d),c/=d):d++;return u}},{key:"mod",value:function(c,u){var d=arguments.length>2&&arguments[2]!==void 0?arguments[2]:7,v=Math.pow(10,d-Math.floor(Math.log10(Math.max(c,u))));return(c=Math.round(Math.abs(c)*v))%(u=Math.round(Math.abs(u)*v))/v}}]),Q}(),R=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w,this.setEasingFunctions()}return l(Q,[{key:"setEasingFunctions",value:function(){var c;if(!this.w.globals.easing){switch(this.w.config.chart.animations.easing){case"linear":c="-";break;case"easein":c="<";break;case"easeout":c=">";break;case"easeinout":default:c="<>";break;case"swing":c=function(u){var d=1.70158;return(u-=1)*u*((d+1)*u+d)+1};break;case"bounce":c=function(u){return u<1/2.75?7.5625*u*u:u<2/2.75?7.5625*(u-=1.5/2.75)*u+.75:u<2.5/2.75?7.5625*(u-=2.25/2.75)*u+.9375:7.5625*(u-=2.625/2.75)*u+.984375};break;case"elastic":c=function(u){return u===!!u?u:Math.pow(2,-10*u)*Math.sin((u-.075)*(2*Math.PI)/.3)+1}}this.w.globals.easing=c}}},{key:"animateLine",value:function(c,u,d,v){c.attr(u).animate(v).attr(d)}},{key:"animateMarker",value:function(c,u,d,v){c.attr({opacity:0}).animate(u,d).attr({opacity:1}).afterAll(function(){v()})}},{key:"animateRect",value:function(c,u,d,v,m){c.attr(u).animate(v).attr(d).afterAll(function(){return m()})}},{key:"animatePathsGradually",value:function(c){var u=c.el,d=c.realIndex,v=c.j,m=c.fill,x=c.pathFrom,w=c.pathTo,k=c.speed,L=c.delay,D=this.w,P=0;D.config.chart.animations.animateGradually.enabled&&(P=D.config.chart.animations.animateGradually.delay),D.config.chart.animations.dynamicAnimation.enabled&&D.globals.dataChanged&&D.config.chart.type!=="bar"&&(P=0),this.morphSVG(u,d,v,D.config.chart.type!=="line"||D.globals.comboCharts?m:"stroke",x,w,k,L*P)}},{key:"showDelayedElements",value:function(){this.w.globals.delayedElements.forEach(function(c){var u=c.el;u.classList.remove("apexcharts-element-hidden"),u.classList.add("apexcharts-hidden-element-shown")})}},{key:"animationCompleted",value:function(c){var u=this.w;u.globals.animationEnded||(u.globals.animationEnded=!0,this.showDelayedElements(),typeof u.config.chart.events.animationEnd=="function"&&u.config.chart.events.animationEnd(this.ctx,{el:c,w:u}))}},{key:"morphSVG",value:function(c,u,d,v,m,x,w,k){var L=this,D=this.w;m||(m=c.attr("pathFrom")),x||(x=c.attr("pathTo"));var P=function(V){return D.config.chart.type==="radar"&&(w=1),"M 0 ".concat(D.globals.gridHeight)};(!m||m.indexOf("undefined")>-1||m.indexOf("NaN")>-1)&&(m=P()),(!x||x.indexOf("undefined")>-1||x.indexOf("NaN")>-1)&&(x=P()),D.globals.shouldAnimate||(w=1),c.plot(m).animate(1,D.globals.easing,k).plot(m).animate(w,D.globals.easing,k).plot(x).afterAll(function(){E.isNumber(d)?d===D.globals.series[D.globals.maxValsInArrayIndex].length-2&&D.globals.shouldAnimate&&L.animationCompleted(c):v!=="none"&&D.globals.shouldAnimate&&(!D.globals.comboCharts&&u===D.globals.series.length-1||D.globals.comboCharts)&&L.animationCompleted(c),L.showDelayedElements()})}}]),Q}(),W=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w}return l(Q,[{key:"getDefaultFilter",value:function(c,u){var d=this.w;c.unfilter(!0),new window.SVG.Filter().size("120%","180%","-5%","-40%"),d.config.states.normal.filter!=="none"?this.applyFilter(c,u,d.config.states.normal.filter.type,d.config.states.normal.filter.value):d.config.chart.dropShadow.enabled&&this.dropShadow(c,d.config.chart.dropShadow,u)}},{key:"addNormalFilter",value:function(c,u){var d=this.w;d.config.chart.dropShadow.enabled&&!c.node.classList.contains("apexcharts-marker")&&this.dropShadow(c,d.config.chart.dropShadow,u)}},{key:"addLightenFilter",value:function(c,u,d){var v=this,m=this.w,x=d.intensity;c.unfilter(!0),new window.SVG.Filter,c.filter(function(w){var k=m.config.chart.dropShadow;(k.enabled?v.addShadow(w,u,k):w).componentTransfer({rgb:{type:"linear",slope:1.5,intercept:x}})}),c.filterer.node.setAttribute("filterUnits","userSpaceOnUse"),this._scaleFilterSize(c.filterer.node)}},{key:"addDarkenFilter",value:function(c,u,d){var v=this,m=this.w,x=d.intensity;c.unfilter(!0),new window.SVG.Filter,c.filter(function(w){var k=m.config.chart.dropShadow;(k.enabled?v.addShadow(w,u,k):w).componentTransfer({rgb:{type:"linear",slope:x}})}),c.filterer.node.setAttribute("filterUnits","userSpaceOnUse"),this._scaleFilterSize(c.filterer.node)}},{key:"applyFilter",value:function(c,u,d){var v=arguments.length>3&&arguments[3]!==void 0?arguments[3]:.5;switch(d){case"none":this.addNormalFilter(c,u);break;case"lighten":this.addLightenFilter(c,u,{intensity:v});break;case"darken":this.addDarkenFilter(c,u,{intensity:v})}}},{key:"addShadow",value:function(c,u,d){var v,m=this.w,x=d.blur,w=d.top,k=d.left,L=d.color,D=d.opacity;if(((v=m.config.chart.dropShadow.enabledOnSeries)===null||v===void 0?void 0:v.length)>0&&m.config.chart.dropShadow.enabledOnSeries.indexOf(u)===-1)return c;var P=c.flood(Array.isArray(L)?L[u]:L,D).composite(c.sourceAlpha,"in").offset(k,w).gaussianBlur(x).merge(c.source);return c.blend(c.source,P)}},{key:"dropShadow",value:function(c,u){var d,v,m=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0,x=u.top,w=u.left,k=u.blur,L=u.color,D=u.opacity,P=u.noUserSpaceOnUse,V=this.w;return c.unfilter(!0),E.isIE()&&V.config.chart.type==="radialBar"||((d=V.config.chart.dropShadow.enabledOnSeries)===null||d===void 0?void 0:d.length)>0&&((v=V.config.chart.dropShadow.enabledOnSeries)===null||v===void 0?void 0:v.indexOf(m))===-1||(L=Array.isArray(L)?L[m]:L,c.filter(function(N){var j=null;j=E.isSafari()||E.isFirefox()||E.isIE()?N.flood(L,D).composite(N.sourceAlpha,"in").offset(w,x).gaussianBlur(k):N.flood(L,D).composite(N.sourceAlpha,"in").offset(w,x).gaussianBlur(k).merge(N.source),N.blend(N.source,j)}),P||c.filterer.node.setAttribute("filterUnits","userSpaceOnUse"),this._scaleFilterSize(c.filterer.node)),c}},{key:"setSelectionFilter",value:function(c,u,d){var v=this.w;if(v.globals.selectedDataPoints[u]!==void 0&&v.globals.selectedDataPoints[u].indexOf(d)>-1){c.node.setAttribute("selected",!0);var m=v.config.states.active.filter;m!=="none"&&this.applyFilter(c,u,m.type,m.value)}}},{key:"_scaleFilterSize",value:function(c){(function(u){for(var d in u)u.hasOwnProperty(d)&&c.setAttribute(d,u[d])})({width:"200%",height:"200%",x:"-50%",y:"-50%"})}}]),Q}(),$=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w}return l(Q,[{key:"roundPathCorners",value:function(c,u){function d(ct,wt,xt){var jt=wt.x-ct.x,ee=wt.y-ct.y,Nt=Math.sqrt(jt*jt+ee*ee);return v(ct,wt,Math.min(1,xt/Nt))}function v(ct,wt,xt){return{x:ct.x+(wt.x-ct.x)*xt,y:ct.y+(wt.y-ct.y)*xt}}function m(ct,wt){ct.length>2&&(ct[ct.length-2]=wt.x,ct[ct.length-1]=wt.y)}function x(ct){return{x:parseFloat(ct[ct.length-2]),y:parseFloat(ct[ct.length-1])}}c.indexOf("NaN")>-1&&(c="");var w=c.split(/[,\s]/).reduce(function(ct,wt){var xt=wt.match("([a-zA-Z])(.+)");return xt?(ct.push(xt[1]),ct.push(xt[2])):ct.push(wt),ct},[]).reduce(function(ct,wt){return parseFloat(wt)==wt&&ct.length?ct[ct.length-1].push(wt):ct.push([wt]),ct},[]),k=[];if(w.length>1){var L=x(w[0]),D=null;w[w.length-1][0]=="Z"&&w[0].length>2&&(D=["L",L.x,L.y],w[w.length-1]=D),k.push(w[0]);for(var P=1;P2&&N[0]=="L"&&j.length>2&&j[0]=="L"){var U,q,J=x(V),rt=x(N),A=x(j);U=d(rt,J,u),q=d(rt,A,u),m(N,U),N.origPoint=rt,k.push(N);var O=v(U,rt,.5),X=v(rt,q,.5),ot=["C",O.x,O.y,X.x,X.y,q.x,q.y];ot.origPoint=rt,k.push(ot)}else k.push(N)}if(D){var nt=x(k[k.length-1]);k.push(["Z"]),m(k[0],nt)}}else k=w;return k.reduce(function(ct,wt){return ct+wt.join(" ")+" "},"")}},{key:"drawLine",value:function(c,u,d,v){var m=arguments.length>4&&arguments[4]!==void 0?arguments[4]:"#a8a8a8",x=arguments.length>5&&arguments[5]!==void 0?arguments[5]:0,w=arguments.length>6&&arguments[6]!==void 0?arguments[6]:null,k=arguments.length>7&&arguments[7]!==void 0?arguments[7]:"butt";return this.w.globals.dom.Paper.line().attr({x1:c,y1:u,x2:d,y2:v,stroke:m,"stroke-dasharray":x,"stroke-width":w,"stroke-linecap":k})}},{key:"drawRect",value:function(){var c=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,d=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0,v=arguments.length>3&&arguments[3]!==void 0?arguments[3]:0,m=arguments.length>4&&arguments[4]!==void 0?arguments[4]:0,x=arguments.length>5&&arguments[5]!==void 0?arguments[5]:"#fefefe",w=arguments.length>6&&arguments[6]!==void 0?arguments[6]:1,k=arguments.length>7&&arguments[7]!==void 0?arguments[7]:null,L=arguments.length>8&&arguments[8]!==void 0?arguments[8]:null,D=arguments.length>9&&arguments[9]!==void 0?arguments[9]:0,P=this.w.globals.dom.Paper.rect();return P.attr({x:c,y:u,width:d>0?d:0,height:v>0?v:0,rx:m,ry:m,opacity:w,"stroke-width":k!==null?k:0,stroke:L!==null?L:"none","stroke-dasharray":D}),P.node.setAttribute("fill",x),P}},{key:"drawPolygon",value:function(c){var u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"#e1e1e1",d=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1,v=arguments.length>3&&arguments[3]!==void 0?arguments[3]:"none";return this.w.globals.dom.Paper.polygon(c).attr({fill:v,stroke:u,"stroke-width":d})}},{key:"drawCircle",value:function(c){var u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:null;c<0&&(c=0);var d=this.w.globals.dom.Paper.circle(2*c);return u!==null&&d.attr(u),d}},{key:"drawPath",value:function(c){var u=c.d,d=u===void 0?"":u,v=c.stroke,m=v===void 0?"#a8a8a8":v,x=c.strokeWidth,w=x===void 0?1:x,k=c.fill,L=c.fillOpacity,D=L===void 0?1:L,P=c.strokeOpacity,V=P===void 0?1:P,N=c.classes,j=c.strokeLinecap,U=j===void 0?null:j,q=c.strokeDashArray,J=q===void 0?0:q,rt=this.w;return U===null&&(U=rt.config.stroke.lineCap),(d.indexOf("undefined")>-1||d.indexOf("NaN")>-1)&&(d="M 0 ".concat(rt.globals.gridHeight)),rt.globals.dom.Paper.path(d).attr({fill:k,"fill-opacity":D,stroke:m,"stroke-opacity":V,"stroke-linecap":U,"stroke-width":w,"stroke-dasharray":J,class:N})}},{key:"group",value:function(){var c=arguments.length>0&&arguments[0]!==void 0?arguments[0]:null,u=this.w.globals.dom.Paper.group();return c!==null&&u.attr(c),u}},{key:"move",value:function(c,u){var d=["M",c,u].join(" ");return d}},{key:"line",value:function(c,u){var d=arguments.length>2&&arguments[2]!==void 0?arguments[2]:null,v=null;return d===null?v=[" L",c,u].join(" "):d==="H"?v=[" H",c].join(" "):d==="V"&&(v=[" V",u].join(" ")),v}},{key:"curve",value:function(c,u,d,v,m,x){var w=["C",c,u,d,v,m,x].join(" ");return w}},{key:"quadraticCurve",value:function(c,u,d,v){return["Q",c,u,d,v].join(" ")}},{key:"arc",value:function(c,u,d,v,m,x,w){var k="A";arguments.length>7&&arguments[7]!==void 0&&arguments[7]&&(k="a");var L=[k,c,u,d,v,m,x,w].join(" ");return L}},{key:"renderPaths",value:function(c){var u,d=c.j,v=c.realIndex,m=c.pathFrom,x=c.pathTo,w=c.stroke,k=c.strokeWidth,L=c.strokeLinecap,D=c.fill,P=c.animationDelay,V=c.initialSpeed,N=c.dataChangeSpeed,j=c.className,U=c.shouldClipToGrid,q=U===void 0||U,J=c.bindEventsOnPaths,rt=J===void 0||J,A=c.drawShadow,O=A===void 0||A,X=this.w,ot=new W(this.ctx),nt=new R(this.ctx),ct=this.w.config.chart.animations.enabled,wt=ct&&this.w.config.chart.animations.dynamicAnimation.enabled,xt=!!(ct&&!X.globals.resized||wt&&X.globals.dataChanged&&X.globals.shouldAnimate);xt?u=m:(u=x,X.globals.animationEnded=!0);var jt=X.config.stroke.dashArray,ee=0;ee=Array.isArray(jt)?jt[v]:X.config.stroke.dashArray;var Nt=this.drawPath({d:u,stroke:w,strokeWidth:k,fill:D,fillOpacity:1,classes:j,strokeLinecap:L,strokeDashArray:ee});if(Nt.attr("index",v),q&&Nt.attr({"clip-path":"url(#gridRectMask".concat(X.globals.cuid,")")}),X.config.states.normal.filter.type!=="none")ot.getDefaultFilter(Nt,v);else if(X.config.chart.dropShadow.enabled&&O){var Zt=X.config.chart.dropShadow;ot.dropShadow(Nt,Zt,v)}rt&&(Nt.node.addEventListener("mouseenter",this.pathMouseEnter.bind(this,Nt)),Nt.node.addEventListener("mouseleave",this.pathMouseLeave.bind(this,Nt)),Nt.node.addEventListener("mousedown",this.pathMouseDown.bind(this,Nt))),Nt.attr({pathTo:x,pathFrom:m});var ze={el:Nt,j:d,realIndex:v,pathFrom:m,pathTo:x,fill:D,strokeWidth:k,delay:P};return!ct||X.globals.resized||X.globals.dataChanged?!X.globals.resized&&X.globals.dataChanged||nt.showDelayedElements():nt.animatePathsGradually(i(i({},ze),{},{speed:V})),X.globals.dataChanged&&wt&&xt&&nt.animatePathsGradually(i(i({},ze),{},{speed:N})),Nt}},{key:"drawPattern",value:function(c,u,d){var v=arguments.length>3&&arguments[3]!==void 0?arguments[3]:"#a8a8a8",m=arguments.length>4&&arguments[4]!==void 0?arguments[4]:0;return this.w.globals.dom.Paper.pattern(u,d,function(x){c==="horizontalLines"?x.line(0,0,d,0).stroke({color:v,width:m+1}):c==="verticalLines"?x.line(0,0,0,u).stroke({color:v,width:m+1}):c==="slantedLines"?x.line(0,0,u,d).stroke({color:v,width:m}):c==="squares"?x.rect(u,d).fill("none").stroke({color:v,width:m}):c==="circles"&&x.circle(u).fill("none").stroke({color:v,width:m})})}},{key:"drawGradient",value:function(c,u,d,v,m){var x,w=arguments.length>5&&arguments[5]!==void 0?arguments[5]:null,k=arguments.length>6&&arguments[6]!==void 0?arguments[6]:null,L=arguments.length>7&&arguments[7]!==void 0?arguments[7]:null,D=arguments.length>8&&arguments[8]!==void 0?arguments[8]:0,P=this.w;u.length<9&&u.indexOf("#")===0&&(u=E.hexToRgba(u,v)),d.length<9&&d.indexOf("#")===0&&(d=E.hexToRgba(d,m));var V=0,N=1,j=1,U=null;k!==null&&(V=k[0]!==void 0?k[0]/100:0,N=k[1]!==void 0?k[1]/100:1,j=k[2]!==void 0?k[2]/100:1,U=k[3]!==void 0?k[3]/100:null);var q=!(P.config.chart.type!=="donut"&&P.config.chart.type!=="pie"&&P.config.chart.type!=="polarArea"&&P.config.chart.type!=="bubble");if(x=L===null||L.length===0?P.globals.dom.Paper.gradient(q?"radial":"linear",function(A){A.at(V,u,v),A.at(N,d,m),A.at(j,d,m),U!==null&&A.at(U,u,v)}):P.globals.dom.Paper.gradient(q?"radial":"linear",function(A){(Array.isArray(L[D])?L[D]:L).forEach(function(O){A.at(O.offset/100,O.color,O.opacity)})}),q){var J=P.globals.gridWidth/2,rt=P.globals.gridHeight/2;P.config.chart.type!=="bubble"?x.attr({gradientUnits:"userSpaceOnUse",cx:J,cy:rt,r:w}):x.attr({cx:.5,cy:.5,r:.8,fx:.2,fy:.2})}else c==="vertical"?x.from(0,0).to(0,1):c==="diagonal"?x.from(0,0).to(1,1):c==="horizontal"?x.from(0,1).to(1,1):c==="diagonal2"&&x.from(1,0).to(0,1);return x}},{key:"getTextBasedOnMaxWidth",value:function(c){var u=c.text,d=c.maxWidth,v=c.fontSize,m=c.fontFamily,x=this.getTextRects(u,v,m),w=x.width/u.length,k=Math.floor(d/w);return dQ.length)&&(c=Q.length);for(var u=0,d=new Array(c);u>16,w=d>>8&255,k=255&d;return"#"+(16777216+65536*(Math.round((v-x)*m)+x)+256*(Math.round((v-w)*m)+w)+(Math.round((v-k)*m)+k)).toString(16).slice(1)}},{key:"shadeColor",value:function(c,u){return Q.isColorHex(u)?this.shadeHexColor(c,u):this.shadeRGBColor(c,u)}}],[{key:"bind",value:function(c,u){return function(){return c.apply(u,arguments)}}},{key:"isObject",value:function(c){return c&&o(c)==="object"&&!Array.isArray(c)&&c!=null}},{key:"is",value:function(c,u){return Object.prototype.toString.call(u)==="[object "+c+"]"}},{key:"listToArray",value:function(c){var u,d=[];for(u=0;u1&&arguments[1]!==void 0?arguments[1]:2;return Number.isInteger(c)?c:parseFloat(c.toPrecision(u))}},{key:"randomId",value:function(){return(Math.random()+1).toString(36).substring(4)}},{key:"noExponents",value:function(c){var u=String(c).split(/[eE]/);if(u.length===1)return u[0];var d="",v=c<0?"-":"",m=u[0].replace(".",""),x=Number(u[1])+1;if(x<0){for(d=v+"0.";x++;)d+="0";return d+m.replace(/^-/,"")}for(x-=m.length;x--;)d+="0";return m+d}},{key:"getDimensions",value:function(c){var u=getComputedStyle(c,null),d=c.clientHeight,v=c.clientWidth;return d-=parseFloat(u.paddingTop)+parseFloat(u.paddingBottom),[v-=parseFloat(u.paddingLeft)+parseFloat(u.paddingRight),d]}},{key:"getBoundingClientRect",value:function(c){var u=c.getBoundingClientRect();return{top:u.top,right:u.right,bottom:u.bottom,left:u.left,width:c.clientWidth,height:c.clientHeight,x:u.left,y:u.top}}},{key:"getLargestStringFromArr",value:function(c){return c.reduce(function(u,d){return Array.isArray(d)&&(d=d.reduce(function(v,m){return v.length>m.length?v:m})),u.length>d.length?u:d},0)}},{key:"hexToRgba",value:function(){var c=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"#999999",u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:.6;c.substring(0,1)!=="#"&&(c="#999999");var d=c.replace("#","");d=d.match(new RegExp("(.{"+d.length/3+"})","g"));for(var v=0;v1&&arguments[1]!==void 0?arguments[1]:"x",d=c.toString().slice();return d=d.replace(/[` ~!@#$%^&*()|+\=?;:'",.<>{}[\]\\/]/gi,u)}},{key:"negToZero",value:function(c){return c<0?0:c}},{key:"moveIndexInArray",value:function(c,u,d){if(d>=c.length)for(var v=d-c.length+1;v--;)c.push(void 0);return c.splice(d,0,c.splice(u,1)[0]),c}},{key:"extractNumber",value:function(c){return parseFloat(c.replace(/[^\d.]*/g,""))}},{key:"findAncestor",value:function(c,u){for(;(c=c.parentElement)&&!c.classList.contains(u););return c}},{key:"setELstyles",value:function(c,u){for(var d in u)u.hasOwnProperty(d)&&(c.style.key=u[d])}},{key:"preciseAddition",value:function(c,u){var d=(String(c).split(".")[1]||"").length,v=(String(u).split(".")[1]||"").length,m=Math.pow(10,Math.max(d,v));return(Math.round(c*m)+Math.round(u*m))/m}},{key:"isNumber",value:function(c){return!isNaN(c)&&parseFloat(Number(c))===c&&!isNaN(parseInt(c,10))}},{key:"isFloat",value:function(c){return Number(c)===c&&c%1!=0}},{key:"isSafari",value:function(){return/^((?!chrome|android).)*safari/i.test(navigator.userAgent)}},{key:"isFirefox",value:function(){return navigator.userAgent.toLowerCase().indexOf("firefox")>-1}},{key:"isIE11",value:function(){if(window.navigator.userAgent.indexOf("MSIE")!==-1||window.navigator.appVersion.indexOf("Trident/")>-1)return!0}},{key:"isIE",value:function(){var c=window.navigator.userAgent,u=c.indexOf("MSIE ");if(u>0)return parseInt(c.substring(u+5,c.indexOf(".",u)),10);if(c.indexOf("Trident/")>0){var d=c.indexOf("rv:");return parseInt(c.substring(d+3,c.indexOf(".",d)),10)}var v=c.indexOf("Edge/");return v>0&&parseInt(c.substring(v+5,c.indexOf(".",v)),10)}},{key:"getGCD",value:function(c,u){var d=arguments.length>2&&arguments[2]!==void 0?arguments[2]:7,v=Math.pow(10,d-Math.floor(Math.log10(Math.max(c,u))));for(c=Math.round(Math.abs(c)*v),u=Math.round(Math.abs(u)*v);u;){var m=u;u=c%u,c=m}return c/v}},{key:"getPrimeFactors",value:function(c){for(var u=[],d=2;c>=2;)c%d==0?(u.push(d),c/=d):d++;return u}},{key:"mod",value:function(c,u){var d=arguments.length>2&&arguments[2]!==void 0?arguments[2]:7,v=Math.pow(10,d-Math.floor(Math.log10(Math.max(c,u))));return(c=Math.round(Math.abs(c)*v))%(u=Math.round(Math.abs(u)*v))/v}}]),Q}(),R=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w,this.setEasingFunctions()}return l(Q,[{key:"setEasingFunctions",value:function(){var c;if(!this.w.globals.easing){switch(this.w.config.chart.animations.easing){case"linear":c="-";break;case"easein":c="<";break;case"easeout":c=">";break;case"easeinout":default:c="<>";break;case"swing":c=function(u){var d=1.70158;return(u-=1)*u*((d+1)*u+d)+1};break;case"bounce":c=function(u){return u<1/2.75?7.5625*u*u:u<2/2.75?7.5625*(u-=1.5/2.75)*u+.75:u<2.5/2.75?7.5625*(u-=2.25/2.75)*u+.9375:7.5625*(u-=2.625/2.75)*u+.984375};break;case"elastic":c=function(u){return u===!!u?u:Math.pow(2,-10*u)*Math.sin((u-.075)*(2*Math.PI)/.3)+1}}this.w.globals.easing=c}}},{key:"animateLine",value:function(c,u,d,v){c.attr(u).animate(v).attr(d)}},{key:"animateMarker",value:function(c,u,d,v){c.attr({opacity:0}).animate(u,d).attr({opacity:1}).afterAll(function(){v()})}},{key:"animateRect",value:function(c,u,d,v,m){c.attr(u).animate(v).attr(d).afterAll(function(){return m()})}},{key:"animatePathsGradually",value:function(c){var u=c.el,d=c.realIndex,v=c.j,m=c.fill,x=c.pathFrom,w=c.pathTo,k=c.speed,L=c.delay,D=this.w,P=0;D.config.chart.animations.animateGradually.enabled&&(P=D.config.chart.animations.animateGradually.delay),D.config.chart.animations.dynamicAnimation.enabled&&D.globals.dataChanged&&D.config.chart.type!=="bar"&&(P=0),this.morphSVG(u,d,v,D.config.chart.type!=="line"||D.globals.comboCharts?m:"stroke",x,w,k,L*P)}},{key:"showDelayedElements",value:function(){this.w.globals.delayedElements.forEach(function(c){var u=c.el;u.classList.remove("apexcharts-element-hidden"),u.classList.add("apexcharts-hidden-element-shown")})}},{key:"animationCompleted",value:function(c){var u=this.w;u.globals.animationEnded||(u.globals.animationEnded=!0,this.showDelayedElements(),typeof u.config.chart.events.animationEnd=="function"&&u.config.chart.events.animationEnd(this.ctx,{el:c,w:u}))}},{key:"morphSVG",value:function(c,u,d,v,m,x,w,k){var L=this,D=this.w;m||(m=c.attr("pathFrom")),x||(x=c.attr("pathTo"));var P=function(V){return D.config.chart.type==="radar"&&(w=1),"M 0 ".concat(D.globals.gridHeight)};(!m||m.indexOf("undefined")>-1||m.indexOf("NaN")>-1)&&(m=P()),(!x||x.indexOf("undefined")>-1||x.indexOf("NaN")>-1)&&(x=P()),D.globals.shouldAnimate||(w=1),c.plot(m).animate(1,D.globals.easing,k).plot(m).animate(w,D.globals.easing,k).plot(x).afterAll(function(){E.isNumber(d)?d===D.globals.series[D.globals.maxValsInArrayIndex].length-2&&D.globals.shouldAnimate&&L.animationCompleted(c):v!=="none"&&D.globals.shouldAnimate&&(!D.globals.comboCharts&&u===D.globals.series.length-1||D.globals.comboCharts)&&L.animationCompleted(c),L.showDelayedElements()})}}]),Q}(),W=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w}return l(Q,[{key:"getDefaultFilter",value:function(c,u){var d=this.w;c.unfilter(!0),new window.SVG.Filter().size("120%","180%","-5%","-40%"),d.config.states.normal.filter!=="none"?this.applyFilter(c,u,d.config.states.normal.filter.type,d.config.states.normal.filter.value):d.config.chart.dropShadow.enabled&&this.dropShadow(c,d.config.chart.dropShadow,u)}},{key:"addNormalFilter",value:function(c,u){var d=this.w;d.config.chart.dropShadow.enabled&&!c.node.classList.contains("apexcharts-marker")&&this.dropShadow(c,d.config.chart.dropShadow,u)}},{key:"addLightenFilter",value:function(c,u,d){var v=this,m=this.w,x=d.intensity;c.unfilter(!0),new window.SVG.Filter,c.filter(function(w){var k=m.config.chart.dropShadow;(k.enabled?v.addShadow(w,u,k):w).componentTransfer({rgb:{type:"linear",slope:1.5,intercept:x}})}),c.filterer.node.setAttribute("filterUnits","userSpaceOnUse"),this._scaleFilterSize(c.filterer.node)}},{key:"addDarkenFilter",value:function(c,u,d){var v=this,m=this.w,x=d.intensity;c.unfilter(!0),new window.SVG.Filter,c.filter(function(w){var k=m.config.chart.dropShadow;(k.enabled?v.addShadow(w,u,k):w).componentTransfer({rgb:{type:"linear",slope:x}})}),c.filterer.node.setAttribute("filterUnits","userSpaceOnUse"),this._scaleFilterSize(c.filterer.node)}},{key:"applyFilter",value:function(c,u,d){var v=arguments.length>3&&arguments[3]!==void 0?arguments[3]:.5;switch(d){case"none":this.addNormalFilter(c,u);break;case"lighten":this.addLightenFilter(c,u,{intensity:v});break;case"darken":this.addDarkenFilter(c,u,{intensity:v})}}},{key:"addShadow",value:function(c,u,d){var v,m=this.w,x=d.blur,w=d.top,k=d.left,L=d.color,D=d.opacity;if(((v=m.config.chart.dropShadow.enabledOnSeries)===null||v===void 0?void 0:v.length)>0&&m.config.chart.dropShadow.enabledOnSeries.indexOf(u)===-1)return c;var P=c.flood(Array.isArray(L)?L[u]:L,D).composite(c.sourceAlpha,"in").offset(k,w).gaussianBlur(x).merge(c.source);return c.blend(c.source,P)}},{key:"dropShadow",value:function(c,u){var d,v,m=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0,x=u.top,w=u.left,k=u.blur,L=u.color,D=u.opacity,P=u.noUserSpaceOnUse,V=this.w;return c.unfilter(!0),E.isIE()&&V.config.chart.type==="radialBar"||((d=V.config.chart.dropShadow.enabledOnSeries)===null||d===void 0?void 0:d.length)>0&&((v=V.config.chart.dropShadow.enabledOnSeries)===null||v===void 0?void 0:v.indexOf(m))===-1||(L=Array.isArray(L)?L[m]:L,c.filter(function(N){var j=null;j=E.isSafari()||E.isFirefox()||E.isIE()?N.flood(L,D).composite(N.sourceAlpha,"in").offset(w,x).gaussianBlur(k):N.flood(L,D).composite(N.sourceAlpha,"in").offset(w,x).gaussianBlur(k).merge(N.source),N.blend(N.source,j)}),P||c.filterer.node.setAttribute("filterUnits","userSpaceOnUse"),this._scaleFilterSize(c.filterer.node)),c}},{key:"setSelectionFilter",value:function(c,u,d){var v=this.w;if(v.globals.selectedDataPoints[u]!==void 0&&v.globals.selectedDataPoints[u].indexOf(d)>-1){c.node.setAttribute("selected",!0);var m=v.config.states.active.filter;m!=="none"&&this.applyFilter(c,u,m.type,m.value)}}},{key:"_scaleFilterSize",value:function(c){(function(u){for(var d in u)u.hasOwnProperty(d)&&c.setAttribute(d,u[d])})({width:"200%",height:"200%",x:"-50%",y:"-50%"})}}]),Q}(),$=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w}return l(Q,[{key:"roundPathCorners",value:function(c,u){function d(ct,Ct,xt){var $t=Ct.x-ct.x,re=Ct.y-ct.y,Ot=Math.sqrt($t*$t+re*re);return v(ct,Ct,Math.min(1,xt/Ot))}function v(ct,Ct,xt){return{x:ct.x+(Ct.x-ct.x)*xt,y:ct.y+(Ct.y-ct.y)*xt}}function m(ct,Ct){ct.length>2&&(ct[ct.length-2]=Ct.x,ct[ct.length-1]=Ct.y)}function x(ct){return{x:parseFloat(ct[ct.length-2]),y:parseFloat(ct[ct.length-1])}}c.indexOf("NaN")>-1&&(c="");var w=c.split(/[,\s]/).reduce(function(ct,Ct){var xt=Ct.match("([a-zA-Z])(.+)");return xt?(ct.push(xt[1]),ct.push(xt[2])):ct.push(Ct),ct},[]).reduce(function(ct,Ct){return parseFloat(Ct)==Ct&&ct.length?ct[ct.length-1].push(Ct):ct.push([Ct]),ct},[]),k=[];if(w.length>1){var L=x(w[0]),D=null;w[w.length-1][0]=="Z"&&w[0].length>2&&(D=["L",L.x,L.y],w[w.length-1]=D),k.push(w[0]);for(var P=1;P2&&N[0]=="L"&&j.length>2&&j[0]=="L"){var U,q,J=x(V),rt=x(N),A=x(j);U=d(rt,J,u),q=d(rt,A,u),m(N,U),N.origPoint=rt,k.push(N);var O=v(U,rt,.5),X=v(rt,q,.5),ot=["C",O.x,O.y,X.x,X.y,q.x,q.y];ot.origPoint=rt,k.push(ot)}else k.push(N)}if(D){var nt=x(k[k.length-1]);k.push(["Z"]),m(k[0],nt)}}else k=w;return k.reduce(function(ct,Ct){return ct+Ct.join(" ")+" "},"")}},{key:"drawLine",value:function(c,u,d,v){var m=arguments.length>4&&arguments[4]!==void 0?arguments[4]:"#a8a8a8",x=arguments.length>5&&arguments[5]!==void 0?arguments[5]:0,w=arguments.length>6&&arguments[6]!==void 0?arguments[6]:null,k=arguments.length>7&&arguments[7]!==void 0?arguments[7]:"butt";return this.w.globals.dom.Paper.line().attr({x1:c,y1:u,x2:d,y2:v,stroke:m,"stroke-dasharray":x,"stroke-width":w,"stroke-linecap":k})}},{key:"drawRect",value:function(){var c=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,d=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0,v=arguments.length>3&&arguments[3]!==void 0?arguments[3]:0,m=arguments.length>4&&arguments[4]!==void 0?arguments[4]:0,x=arguments.length>5&&arguments[5]!==void 0?arguments[5]:"#fefefe",w=arguments.length>6&&arguments[6]!==void 0?arguments[6]:1,k=arguments.length>7&&arguments[7]!==void 0?arguments[7]:null,L=arguments.length>8&&arguments[8]!==void 0?arguments[8]:null,D=arguments.length>9&&arguments[9]!==void 0?arguments[9]:0,P=this.w.globals.dom.Paper.rect();return P.attr({x:c,y:u,width:d>0?d:0,height:v>0?v:0,rx:m,ry:m,opacity:w,"stroke-width":k!==null?k:0,stroke:L!==null?L:"none","stroke-dasharray":D}),P.node.setAttribute("fill",x),P}},{key:"drawPolygon",value:function(c){var u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"#e1e1e1",d=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1,v=arguments.length>3&&arguments[3]!==void 0?arguments[3]:"none";return this.w.globals.dom.Paper.polygon(c).attr({fill:v,stroke:u,"stroke-width":d})}},{key:"drawCircle",value:function(c){var u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:null;c<0&&(c=0);var d=this.w.globals.dom.Paper.circle(2*c);return u!==null&&d.attr(u),d}},{key:"drawPath",value:function(c){var u=c.d,d=u===void 0?"":u,v=c.stroke,m=v===void 0?"#a8a8a8":v,x=c.strokeWidth,w=x===void 0?1:x,k=c.fill,L=c.fillOpacity,D=L===void 0?1:L,P=c.strokeOpacity,V=P===void 0?1:P,N=c.classes,j=c.strokeLinecap,U=j===void 0?null:j,q=c.strokeDashArray,J=q===void 0?0:q,rt=this.w;return U===null&&(U=rt.config.stroke.lineCap),(d.indexOf("undefined")>-1||d.indexOf("NaN")>-1)&&(d="M 0 ".concat(rt.globals.gridHeight)),rt.globals.dom.Paper.path(d).attr({fill:k,"fill-opacity":D,stroke:m,"stroke-opacity":V,"stroke-linecap":U,"stroke-width":w,"stroke-dasharray":J,class:N})}},{key:"group",value:function(){var c=arguments.length>0&&arguments[0]!==void 0?arguments[0]:null,u=this.w.globals.dom.Paper.group();return c!==null&&u.attr(c),u}},{key:"move",value:function(c,u){var d=["M",c,u].join(" ");return d}},{key:"line",value:function(c,u){var d=arguments.length>2&&arguments[2]!==void 0?arguments[2]:null,v=null;return d===null?v=[" L",c,u].join(" "):d==="H"?v=[" H",c].join(" "):d==="V"&&(v=[" V",u].join(" ")),v}},{key:"curve",value:function(c,u,d,v,m,x){var w=["C",c,u,d,v,m,x].join(" ");return w}},{key:"quadraticCurve",value:function(c,u,d,v){return["Q",c,u,d,v].join(" ")}},{key:"arc",value:function(c,u,d,v,m,x,w){var k="A";arguments.length>7&&arguments[7]!==void 0&&arguments[7]&&(k="a");var L=[k,c,u,d,v,m,x,w].join(" ");return L}},{key:"renderPaths",value:function(c){var u,d=c.j,v=c.realIndex,m=c.pathFrom,x=c.pathTo,w=c.stroke,k=c.strokeWidth,L=c.strokeLinecap,D=c.fill,P=c.animationDelay,V=c.initialSpeed,N=c.dataChangeSpeed,j=c.className,U=c.shouldClipToGrid,q=U===void 0||U,J=c.bindEventsOnPaths,rt=J===void 0||J,A=c.drawShadow,O=A===void 0||A,X=this.w,ot=new W(this.ctx),nt=new R(this.ctx),ct=this.w.config.chart.animations.enabled,Ct=ct&&this.w.config.chart.animations.dynamicAnimation.enabled,xt=!!(ct&&!X.globals.resized||Ct&&X.globals.dataChanged&&X.globals.shouldAnimate);xt?u=m:(u=x,X.globals.animationEnded=!0);var $t=X.config.stroke.dashArray,re=0;re=Array.isArray($t)?$t[v]:X.config.stroke.dashArray;var Ot=this.drawPath({d:u,stroke:w,strokeWidth:k,fill:D,fillOpacity:1,classes:j,strokeLinecap:L,strokeDashArray:re});if(Ot.attr("index",v),q&&Ot.attr({"clip-path":"url(#gridRectMask".concat(X.globals.cuid,")")}),X.config.states.normal.filter.type!=="none")ot.getDefaultFilter(Ot,v);else if(X.config.chart.dropShadow.enabled&&O){var Qt=X.config.chart.dropShadow;ot.dropShadow(Ot,Qt,v)}rt&&(Ot.node.addEventListener("mouseenter",this.pathMouseEnter.bind(this,Ot)),Ot.node.addEventListener("mouseleave",this.pathMouseLeave.bind(this,Ot)),Ot.node.addEventListener("mousedown",this.pathMouseDown.bind(this,Ot))),Ot.attr({pathTo:x,pathFrom:m});var Me={el:Ot,j:d,realIndex:v,pathFrom:m,pathTo:x,fill:D,strokeWidth:k,delay:P};return!ct||X.globals.resized||X.globals.dataChanged?!X.globals.resized&&X.globals.dataChanged||nt.showDelayedElements():nt.animatePathsGradually(i(i({},Me),{},{speed:V})),X.globals.dataChanged&&Ct&&xt&&nt.animatePathsGradually(i(i({},Me),{},{speed:N})),Ot}},{key:"drawPattern",value:function(c,u,d){var v=arguments.length>3&&arguments[3]!==void 0?arguments[3]:"#a8a8a8",m=arguments.length>4&&arguments[4]!==void 0?arguments[4]:0;return this.w.globals.dom.Paper.pattern(u,d,function(x){c==="horizontalLines"?x.line(0,0,d,0).stroke({color:v,width:m+1}):c==="verticalLines"?x.line(0,0,0,u).stroke({color:v,width:m+1}):c==="slantedLines"?x.line(0,0,u,d).stroke({color:v,width:m}):c==="squares"?x.rect(u,d).fill("none").stroke({color:v,width:m}):c==="circles"&&x.circle(u).fill("none").stroke({color:v,width:m})})}},{key:"drawGradient",value:function(c,u,d,v,m){var x,w=arguments.length>5&&arguments[5]!==void 0?arguments[5]:null,k=arguments.length>6&&arguments[6]!==void 0?arguments[6]:null,L=arguments.length>7&&arguments[7]!==void 0?arguments[7]:null,D=arguments.length>8&&arguments[8]!==void 0?arguments[8]:0,P=this.w;u.length<9&&u.indexOf("#")===0&&(u=E.hexToRgba(u,v)),d.length<9&&d.indexOf("#")===0&&(d=E.hexToRgba(d,m));var V=0,N=1,j=1,U=null;k!==null&&(V=k[0]!==void 0?k[0]/100:0,N=k[1]!==void 0?k[1]/100:1,j=k[2]!==void 0?k[2]/100:1,U=k[3]!==void 0?k[3]/100:null);var q=!(P.config.chart.type!=="donut"&&P.config.chart.type!=="pie"&&P.config.chart.type!=="polarArea"&&P.config.chart.type!=="bubble");if(x=L===null||L.length===0?P.globals.dom.Paper.gradient(q?"radial":"linear",function(A){A.at(V,u,v),A.at(N,d,m),A.at(j,d,m),U!==null&&A.at(U,u,v)}):P.globals.dom.Paper.gradient(q?"radial":"linear",function(A){(Array.isArray(L[D])?L[D]:L).forEach(function(O){A.at(O.offset/100,O.color,O.opacity)})}),q){var J=P.globals.gridWidth/2,rt=P.globals.gridHeight/2;P.config.chart.type!=="bubble"?x.attr({gradientUnits:"userSpaceOnUse",cx:J,cy:rt,r:w}):x.attr({cx:.5,cy:.5,r:.8,fx:.2,fy:.2})}else c==="vertical"?x.from(0,0).to(0,1):c==="diagonal"?x.from(0,0).to(1,1):c==="horizontal"?x.from(0,1).to(1,1):c==="diagonal2"&&x.from(1,0).to(0,1);return x}},{key:"getTextBasedOnMaxWidth",value:function(c){var u=c.text,d=c.maxWidth,v=c.fontSize,m=c.fontFamily,x=this.getTextRects(u,v,m),w=x.width/u.length,k=Math.floor(d/w);return d-1){var k=d.globals.selectedDataPoints[m].indexOf(x);d.globals.selectedDataPoints[m].splice(k,1)}}else{if(!d.config.states.active.allowMultipleDataPointsSelection&&d.globals.selectedDataPoints.length>0){d.globals.selectedDataPoints=[];var L=d.globals.dom.Paper.select(".apexcharts-series path").members,D=d.globals.dom.Paper.select(".apexcharts-series circle, .apexcharts-series rect").members,P=function(j){Array.prototype.forEach.call(j,function(U){U.node.setAttribute("selected","false"),v.getDefaultFilter(U,m)})};P(L),P(D)}c.node.setAttribute("selected","true"),w="true",d.globals.selectedDataPoints[m]===void 0&&(d.globals.selectedDataPoints[m]=[]),d.globals.selectedDataPoints[m].push(x)}if(w==="true"){var V=d.config.states.active.filter;if(V!=="none")v.applyFilter(c,m,V.type,V.value);else if(d.config.states.hover.filter!=="none"&&!d.globals.isTouchDevice){var N=d.config.states.hover.filter;v.applyFilter(c,m,N.type,N.value)}}else d.config.states.active.filter.type!=="none"&&(d.config.states.hover.filter.type==="none"||d.globals.isTouchDevice?v.getDefaultFilter(c,m):(N=d.config.states.hover.filter,v.applyFilter(c,m,N.type,N.value)));typeof d.config.chart.events.dataPointSelection=="function"&&d.config.chart.events.dataPointSelection(u,this.ctx,{selectedDataPoints:d.globals.selectedDataPoints,seriesIndex:m,dataPointIndex:x,w:d}),u&&this.ctx.events.fireEvent("dataPointSelection",[u,this.ctx,{selectedDataPoints:d.globals.selectedDataPoints,seriesIndex:m,dataPointIndex:x,w:d}])}},{key:"rotateAroundCenter",value:function(c){var u={};return c&&typeof c.getBBox=="function"&&(u=c.getBBox()),{x:u.x+u.width/2,y:u.y+u.height/2}}},{key:"getTextRects",value:function(c,u,d,v){var m=!(arguments.length>4&&arguments[4]!==void 0)||arguments[4],x=this.w,w=this.drawText({x:-200,y:-200,text:c,textAnchor:"start",fontSize:u,fontFamily:d,foreColor:"#fff",opacity:0});v&&w.attr("transform",v),x.globals.dom.Paper.add(w);var k=w.bbox();return m||(k=w.node.getBoundingClientRect()),w.remove(),{width:k.width,height:k.height}}},{key:"placeTextWithEllipsis",value:function(c,u,d){if(typeof c.getComputedTextLength=="function"&&(c.textContent=u,u.length>0&&c.getComputedTextLength()>=d/1.1)){for(var v=u.length-3;v>0;v-=3)if(c.getSubStringLength(0,v)<=d/1.1)return void(c.textContent=u.substring(0,v)+"...");c.textContent="."}}}],[{key:"setAttrs",value:function(c,u){for(var d in u)u.hasOwnProperty(d)&&c.setAttribute(d,u[d])}}]),Q}(),G=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w}return l(Q,[{key:"getStackedSeriesTotals",value:function(){var c=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],u=this.w,d=[];if(u.globals.series.length===0)return d;for(var v=0;v0&&arguments[0]!==void 0?arguments[0]:null;return c===null?this.w.config.series.reduce(function(u,d){return u+d},0):this.w.globals.series[c].reduce(function(u,d){return u+d},0)}},{key:"getStackedSeriesTotalsByGroups",value:function(){var c=this,u=this.w,d=[];return u.globals.seriesGroups.forEach(function(v){var m=[];u.config.series.forEach(function(w,k){v.indexOf(u.globals.seriesNames[k])>-1&&m.push(k)});var x=u.globals.series.map(function(w,k){return m.indexOf(k)===-1?k:-1}).filter(function(w){return w!==-1});d.push(c.getStackedSeriesTotals(x))}),d}},{key:"setSeriesYAxisMappings",value:function(){var c=this.w.globals,u=this.w.config,d=[],v=[],m=[],x=c.series.length>u.yaxis.length||u.yaxis.some(function(P){return Array.isArray(P.seriesName)});u.series.forEach(function(P,V){m.push(V),v.push(null)}),u.yaxis.forEach(function(P,V){d[V]=[]});var w=[];u.yaxis.forEach(function(P,V){var N=!1;if(P.seriesName){var j=[];Array.isArray(P.seriesName)?j=P.seriesName:j.push(P.seriesName),j.forEach(function(U){u.series.forEach(function(q,J){if(q.name===U){var rt=J;V===J||x?!x||m.indexOf(J)>-1?d[V].push([V,J]):console.warn("Series '"+q.name+"' referenced more than once in what looks like the new style. That is, when using either seriesName: [], or when there are more series than yaxes."):(d[J].push([J,V]),rt=V),N=!0,(rt=m.indexOf(rt))!==-1&&m.splice(rt,1)}})})}N||w.push(V)}),d=d.map(function(P,V){var N=[];return P.forEach(function(j){v[j[1]]=j[0],N.push(j[1])}),N});for(var k=u.yaxis.length-1,L=0;L0&&arguments[0]!==void 0?arguments[0]:null;return(c===null?this.w.config.series.filter(function(u){return u!==null}):this.w.config.series[c].data.filter(function(u){return u!==null})).length===0}},{key:"seriesHaveSameValues",value:function(c){return this.w.globals.series[c].every(function(u,d,v){return u===v[0]})}},{key:"getCategoryLabels",value:function(c){var u=this.w,d=c.slice();return u.config.xaxis.convertedCatToNumeric&&(d=c.map(function(v,m){return u.config.xaxis.labels.formatter(v-u.globals.minX+1)})),d}},{key:"getLargestSeries",value:function(){var c=this.w;c.globals.maxValsInArrayIndex=c.globals.series.map(function(u){return u.length}).indexOf(Math.max.apply(Math,c.globals.series.map(function(u){return u.length})))}},{key:"getLargestMarkerSize",value:function(){var c=this.w,u=0;return c.globals.markers.size.forEach(function(d){u=Math.max(u,d)}),c.config.markers.discrete&&c.config.markers.discrete.length&&c.config.markers.discrete.forEach(function(d){u=Math.max(u,d.size)}),u>0&&(u+=c.config.markers.hover.sizeOffset+1),c.globals.markers.largestSize=u,u}},{key:"getSeriesTotals",value:function(){var c=this.w;c.globals.seriesTotals=c.globals.series.map(function(u,d){var v=0;if(Array.isArray(u))for(var m=0;mc&&d.globals.seriesX[m][w]0){var j=function(q,J){var rt=m.config.yaxis[m.globals.seriesYAxisReverseMap[J]],A=q<0?-1:1;return q=Math.abs(q),rt.logarithmic&&(q=v.getBaseLog(rt.logBase,q)),-A*q/w[J]};if(x.isMultipleYAxis){L=[];for(var U=0;U0&&u.forEach(function(w){var k=[],L=[];c.i.forEach(function(D,P){m.config.series[D].group===w&&(k.push(c.series[P]),L.push(D))}),k.length>0&&x.push(v.draw(k,d,L))}),x}}],[{key:"checkComboSeries",value:function(c,u){var d=!1,v=0,m=0;return u===void 0&&(u="line"),c.length&&c[0].type!==void 0&&c.forEach(function(x){x.type!=="bar"&&x.type!=="column"&&x.type!=="candlestick"&&x.type!=="boxPlot"||v++,x.type!==void 0&&x.type!==u&&m++}),m>0&&(d=!0),{comboBarCount:v,comboCharts:d}}},{key:"extendArrayProps",value:function(c,u,d){var v,m,x,w,k,L;return(v=u)!==null&&v!==void 0&&v.yaxis&&(u=c.extendYAxis(u,d)),(m=u)!==null&&m!==void 0&&m.annotations&&(u.annotations.yaxis&&(u=c.extendYAxisAnnotations(u)),(x=u)!==null&&x!==void 0&&(w=x.annotations)!==null&&w!==void 0&&w.xaxis&&(u=c.extendXAxisAnnotations(u)),(k=u)!==null&&k!==void 0&&(L=k.annotations)!==null&&L!==void 0&&L.points&&(u=c.extendPointAnnotations(u))),u}}]),Q}(),Z=function(){function Q(c){a(this,Q),this.w=c.w,this.annoCtx=c}return l(Q,[{key:"setOrientations",value:function(c){var u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:null,d=this.w;if(c.label.orientation==="vertical"){var v=u!==null?u:0,m=d.globals.dom.baseEl.querySelector(".apexcharts-xaxis-annotations .apexcharts-xaxis-annotation-label[rel='".concat(v,"']"));if(m!==null){var x=m.getBoundingClientRect();m.setAttribute("x",parseFloat(m.getAttribute("x"))-x.height+4),c.label.position==="top"?m.setAttribute("y",parseFloat(m.getAttribute("y"))+x.width):m.setAttribute("y",parseFloat(m.getAttribute("y"))-x.width);var w=this.annoCtx.graphics.rotateAroundCenter(m),k=w.x,L=w.y;m.setAttribute("transform","rotate(-90 ".concat(k," ").concat(L,")"))}}}},{key:"addBackgroundToAnno",value:function(c,u){var d=this.w;if(!c||u.label.text===void 0||u.label.text!==void 0&&!String(u.label.text).trim())return null;var v=d.globals.dom.baseEl.querySelector(".apexcharts-grid").getBoundingClientRect(),m=c.getBoundingClientRect(),x=u.label.style.padding.left,w=u.label.style.padding.right,k=u.label.style.padding.top,L=u.label.style.padding.bottom;u.label.orientation==="vertical"&&(k=u.label.style.padding.left,L=u.label.style.padding.right,x=u.label.style.padding.top,w=u.label.style.padding.bottom);var D=m.left-v.left-x,P=m.top-v.top-k,V=this.annoCtx.graphics.drawRect(D-d.globals.barPadForNumericAxis,P,m.width+x+w,m.height+k+L,u.label.borderRadius,u.label.style.background,1,u.label.borderWidth,u.label.borderColor,0);return u.id&&V.node.classList.add(u.id),V}},{key:"annotationsBackground",value:function(){var c=this,u=this.w,d=function(v,m,x){var w=u.globals.dom.baseEl.querySelector(".apexcharts-".concat(x,"-annotations .apexcharts-").concat(x,"-annotation-label[rel='").concat(m,"']"));if(w){var k=w.parentNode,L=c.addBackgroundToAnno(w,v);L&&(k.insertBefore(L.node,w),v.label.mouseEnter&&L.node.addEventListener("mouseenter",v.label.mouseEnter.bind(c,v)),v.label.mouseLeave&&L.node.addEventListener("mouseleave",v.label.mouseLeave.bind(c,v)),v.label.click&&L.node.addEventListener("click",v.label.click.bind(c,v)))}};u.config.annotations.xaxis.map(function(v,m){d(v,m,"xaxis")}),u.config.annotations.yaxis.map(function(v,m){d(v,m,"yaxis")}),u.config.annotations.points.map(function(v,m){d(v,m,"point")})}},{key:"getY1Y2",value:function(c,u){var d,v=c==="y1"?u.y:u.y2,m=!1,x=this.w;if(this.annoCtx.invertAxis){var w=x.globals.labels;x.config.xaxis.convertedCatToNumeric&&(w=x.globals.categoryLabels);var k=w.indexOf(v),L=x.globals.dom.baseEl.querySelector(".apexcharts-yaxis-texts-g text:nth-child("+(k+1)+")");d=L?parseFloat(L.getAttribute("y")):(x.globals.gridHeight/w.length-1)*(k+1)-x.globals.barHeight,u.seriesIndex!==void 0&&x.globals.barHeight&&(d=d-x.globals.barHeight/2*(x.globals.series.length-1)+x.globals.barHeight*u.seriesIndex)}else{var D,P=x.globals.seriesYAxisMap[u.yAxisIndex][0];x.config.yaxis[u.yAxisIndex].logarithmic?D=(v=new G(this.annoCtx.ctx).getLogVal(x.config.yaxis[u.yAxisIndex].logBase,v,P))/x.globals.yLogRatio[P]:D=(v-x.globals.minYArr[P])/(x.globals.yRange[P]/x.globals.gridHeight),D>x.globals.gridHeight?(D=x.globals.gridHeight,m=!0):D<0&&(D=0,m=!0),d=x.globals.gridHeight-D,!u.marker||u.y!==void 0&&u.y!==null||(d=0),x.config.yaxis[u.yAxisIndex]&&x.config.yaxis[u.yAxisIndex].reversed&&(d=D)}return typeof v=="string"&&v.indexOf("px")>-1&&(d=parseFloat(v)),{yP:d,clipped:m}}},{key:"getX1X2",value:function(c,u){var d,v=c==="x1"?u.x:u.x2,m=this.w,x=this.annoCtx.invertAxis?m.globals.minY:m.globals.minX,w=this.annoCtx.invertAxis?m.globals.maxY:m.globals.maxX,k=this.annoCtx.invertAxis?m.globals.yRange[0]:m.globals.xRange,L=!1;return d=this.annoCtx.inversedReversedAxis?(w-v)/(k/m.globals.gridWidth):(v-x)/(k/m.globals.gridWidth),m.config.xaxis.type!=="category"&&!m.config.xaxis.convertedCatToNumeric||this.annoCtx.invertAxis||m.globals.dataFormatXNumeric||m.config.chart.sparkline.enabled||(d=this.getStringX(v)),typeof v=="string"&&v.indexOf("px")>-1&&(d=parseFloat(v)),v==null&&u.marker&&(d=m.globals.gridWidth),u.seriesIndex!==void 0&&m.globals.barWidth&&!this.annoCtx.invertAxis&&(d=d-m.globals.barWidth/2*(m.globals.series.length-1)+m.globals.barWidth*u.seriesIndex),d>m.globals.gridWidth?(d=m.globals.gridWidth,L=!0):d<0&&(d=0,L=!0),{x:d,clipped:L}}},{key:"getStringX",value:function(c){var u=this.w,d=c;u.config.xaxis.convertedCatToNumeric&&u.globals.categoryLabels.length&&(c=u.globals.categoryLabels.indexOf(c)+1);var v=u.globals.labels.indexOf(c),m=u.globals.dom.baseEl.querySelector(".apexcharts-xaxis-texts-g text:nth-child("+(v+1)+")");return m&&(d=parseFloat(m.getAttribute("x"))),d}}]),Q}(),K=function(){function Q(c){a(this,Q),this.w=c.w,this.annoCtx=c,this.invertAxis=this.annoCtx.invertAxis,this.helpers=new Z(this.annoCtx)}return l(Q,[{key:"addXaxisAnnotation",value:function(c,u,d){var v,m=this.w,x=this.helpers.getX1X2("x1",c),w=x.x,k=x.clipped,L=!0,D=c.label.text,P=c.strokeDashArray;if(E.isNumber(w)){if(c.x2===null||c.x2===void 0){if(!k){var V=this.annoCtx.graphics.drawLine(w+c.offsetX,0+c.offsetY,w+c.offsetX,m.globals.gridHeight+c.offsetY,c.borderColor,P,c.borderWidth);u.appendChild(V.node),c.id&&V.node.classList.add(c.id)}}else{var N=this.helpers.getX1X2("x2",c);if(v=N.x,L=N.clipped,!k||!L){if(v12?N-12:N===0?12:N;u=(u=(u=(u=u.replace(/(^|[^\\])HH+/g,"$1"+L(N))).replace(/(^|[^\\])H/g,"$1"+N)).replace(/(^|[^\\])hh+/g,"$1"+L(j))).replace(/(^|[^\\])h/g,"$1"+j);var U=v?c.getUTCMinutes():c.getMinutes();u=(u=u.replace(/(^|[^\\])mm+/g,"$1"+L(U))).replace(/(^|[^\\])m/g,"$1"+U);var q=v?c.getUTCSeconds():c.getSeconds();u=(u=u.replace(/(^|[^\\])ss+/g,"$1"+L(q))).replace(/(^|[^\\])s/g,"$1"+q);var J=v?c.getUTCMilliseconds():c.getMilliseconds();u=u.replace(/(^|[^\\])fff+/g,"$1"+L(J,3)),J=Math.round(J/10),u=u.replace(/(^|[^\\])ff/g,"$1"+L(J)),J=Math.round(J/10);var rt=N<12?"AM":"PM";u=(u=(u=u.replace(/(^|[^\\])f/g,"$1"+J)).replace(/(^|[^\\])TT+/g,"$1"+rt)).replace(/(^|[^\\])T/g,"$1"+rt.charAt(0));var A=rt.toLowerCase();u=(u=u.replace(/(^|[^\\])tt+/g,"$1"+A)).replace(/(^|[^\\])t/g,"$1"+A.charAt(0));var O=-c.getTimezoneOffset(),X=v||!O?"Z":O>0?"+":"-";if(!v){var ot=(O=Math.abs(O))%60;X+=L(Math.floor(O/60))+":"+L(ot)}u=u.replace(/(^|[^\\])K/g,"$1"+X);var nt=(v?c.getUTCDay():c.getDay())+1;return u=(u=(u=(u=(u=u.replace(new RegExp(w[0],"g"),w[nt])).replace(new RegExp(k[0],"g"),k[nt])).replace(new RegExp(m[0],"g"),m[P])).replace(new RegExp(x[0],"g"),x[P])).replace(/\\(.)/g,"$1")}},{key:"getTimeUnitsfromTimestamp",value:function(c,u,d){var v=this.w;v.config.xaxis.min!==void 0&&(c=v.config.xaxis.min),v.config.xaxis.max!==void 0&&(u=v.config.xaxis.max);var m=this.getDate(c),x=this.getDate(u),w=this.formatDate(m,"yyyy MM dd HH mm ss fff").split(" "),k=this.formatDate(x,"yyyy MM dd HH mm ss fff").split(" ");return{minMillisecond:parseInt(w[6],10),maxMillisecond:parseInt(k[6],10),minSecond:parseInt(w[5],10),maxSecond:parseInt(k[5],10),minMinute:parseInt(w[4],10),maxMinute:parseInt(k[4],10),minHour:parseInt(w[3],10),maxHour:parseInt(k[3],10),minDate:parseInt(w[2],10),maxDate:parseInt(k[2],10),minMonth:parseInt(w[1],10)-1,maxMonth:parseInt(k[1],10)-1,minYear:parseInt(w[0],10),maxYear:parseInt(k[0],10)}}},{key:"isLeapYear",value:function(c){return c%4==0&&c%100!=0||c%400==0}},{key:"calculcateLastDaysOfMonth",value:function(c,u,d){return this.determineDaysOfMonths(c,u)-d}},{key:"determineDaysOfYear",value:function(c){var u=365;return this.isLeapYear(c)&&(u=366),u}},{key:"determineRemainingDaysOfYear",value:function(c,u,d){var v=this.daysCntOfYear[u]+d;return u>1&&this.isLeapYear()&&v++,v}},{key:"determineDaysOfMonths",value:function(c,u){var d=30;switch(c=E.monthMod(c),!0){case this.months30.indexOf(c)>-1:c===2&&(d=this.isLeapYear(u)?29:28);break;case this.months31.indexOf(c)>-1:default:d=31}return d}}]),Q}(),at=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w,this.tooltipKeyFormat="dd MMM"}return l(Q,[{key:"xLabelFormat",value:function(c,u,d,v){var m=this.w;if(m.config.xaxis.type==="datetime"&&m.config.xaxis.labels.formatter===void 0&&m.config.tooltip.x.formatter===void 0){var x=new et(this.ctx);return x.formatDate(x.getDate(u),m.config.tooltip.x.format)}return c(u,d,v)}},{key:"defaultGeneralFormatter",value:function(c){return Array.isArray(c)?c.map(function(u){return u}):c}},{key:"defaultYFormatter",value:function(c,u,d){var v=this.w;if(E.isNumber(c))if(v.globals.yValueDecimal!==0)c=c.toFixed(u.decimalsInFloat!==void 0?u.decimalsInFloat:v.globals.yValueDecimal);else{var m=c.toFixed(0);c=c==m?m:c.toFixed(1)}return c}},{key:"setLabelFormatters",value:function(){var c=this,u=this.w;return u.globals.xaxisTooltipFormatter=function(d){return c.defaultGeneralFormatter(d)},u.globals.ttKeyFormatter=function(d){return c.defaultGeneralFormatter(d)},u.globals.ttZFormatter=function(d){return d},u.globals.legendFormatter=function(d){return c.defaultGeneralFormatter(d)},u.config.xaxis.labels.formatter!==void 0?u.globals.xLabelFormatter=u.config.xaxis.labels.formatter:u.globals.xLabelFormatter=function(d){if(E.isNumber(d)){if(!u.config.xaxis.convertedCatToNumeric&&u.config.xaxis.type==="numeric"){if(E.isNumber(u.config.xaxis.decimalsInFloat))return d.toFixed(u.config.xaxis.decimalsInFloat);var v=u.globals.maxX-u.globals.minX;return v>0&&v<100?d.toFixed(1):d.toFixed(0)}return u.globals.isBarHorizontal&&u.globals.maxY-u.globals.minYArr<4?d.toFixed(1):d.toFixed(0)}return d},typeof u.config.tooltip.x.formatter=="function"?u.globals.ttKeyFormatter=u.config.tooltip.x.formatter:u.globals.ttKeyFormatter=u.globals.xLabelFormatter,typeof u.config.xaxis.tooltip.formatter=="function"&&(u.globals.xaxisTooltipFormatter=u.config.xaxis.tooltip.formatter),(Array.isArray(u.config.tooltip.y)||u.config.tooltip.y.formatter!==void 0)&&(u.globals.ttVal=u.config.tooltip.y),u.config.tooltip.z.formatter!==void 0&&(u.globals.ttZFormatter=u.config.tooltip.z.formatter),u.config.legend.formatter!==void 0&&(u.globals.legendFormatter=u.config.legend.formatter),u.config.yaxis.forEach(function(d,v){d.labels.formatter!==void 0?u.globals.yLabelFormatters[v]=d.labels.formatter:u.globals.yLabelFormatters[v]=function(m){return u.globals.xyCharts?Array.isArray(m)?m.map(function(x){return c.defaultYFormatter(x,d,v)}):c.defaultYFormatter(m,d,v):m}}),u.globals}},{key:"heatmapLabelFormatters",value:function(){var c=this.w;if(c.config.chart.type==="heatmap"){c.globals.yAxisScale[0].result=c.globals.seriesNames.slice();var u=c.globals.seriesNames.reduce(function(d,v){return d.length>v.length?d:v},0);c.globals.yAxisScale[0].niceMax=u,c.globals.yAxisScale[0].niceMin=u}}}]),Q}(),tt=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w}return l(Q,[{key:"getLabel",value:function(c,u,d,v){var m=arguments.length>4&&arguments[4]!==void 0?arguments[4]:[],x=arguments.length>5&&arguments[5]!==void 0?arguments[5]:"12px",w=!(arguments.length>6&&arguments[6]!==void 0)||arguments[6],k=this.w,L=c[v]===void 0?"":c[v],D=L,P=k.globals.xLabelFormatter,V=k.config.xaxis.labels.formatter,N=!1,j=new at(this.ctx),U=L;w&&(D=j.xLabelFormat(P,L,U,{i:v,dateFormatter:new et(this.ctx).formatDate,w:k}),V!==void 0&&(D=V(L,c[v],{i:v,dateFormatter:new et(this.ctx).formatDate,w:k})));var q,J;u.length>0?(q=u[v].unit,J=null,u.forEach(function(X){X.unit==="month"?J="year":X.unit==="day"?J="month":X.unit==="hour"?J="day":X.unit==="minute"&&(J="hour")}),N=J===q,d=u[v].position,D=u[v].value):k.config.xaxis.type==="datetime"&&V===void 0&&(D=""),D===void 0&&(D=""),D=Array.isArray(D)?D:D.toString();var rt=new $(this.ctx),A={};A=k.globals.rotateXLabels&&w?rt.getTextRects(D,parseInt(x,10),null,"rotate(".concat(k.config.xaxis.labels.rotate," 0 0)"),!1):rt.getTextRects(D,parseInt(x,10));var O=!k.config.xaxis.labels.showDuplicates&&this.ctx.timeScale;return!Array.isArray(D)&&(String(D)==="NaN"||m.indexOf(D)>=0&&O)&&(D=""),{x:d,text:D,textRect:A,isBold:N}}},{key:"checkLabelBasedOnTickamount",value:function(c,u,d){var v=this.w,m=v.config.xaxis.tickAmount;return m==="dataPoints"&&(m=Math.round(v.globals.gridWidth/120)),m>d||c%Math.round(d/(m+1))==0||(u.text=""),u}},{key:"checkForOverflowingLabels",value:function(c,u,d,v,m){var x=this.w;if(c===0&&x.globals.skipFirstTimelinelabel&&(u.text=""),c===d-1&&x.globals.skipLastTimelinelabel&&(u.text=""),x.config.xaxis.labels.hideOverlappingLabels&&v.length>0){var w=m[m.length-1];u.xv.length||v.some(function(m){return Array.isArray(m.seriesName)})?c:d.seriesYAxisReverseMap[c]}},{key:"isYAxisHidden",value:function(c){var u=this.w,d=u.config.yaxis[c];if(!d.show||this.yAxisAllSeriesCollapsed(c))return!0;if(!d.showForNullSeries){var v=u.globals.seriesYAxisMap[c],m=new G(this.ctx);return v.every(function(x){return m.isSeriesNull(x)})}return!1}},{key:"getYAxisForeColor",value:function(c,u){var d=this.w;return Array.isArray(c)&&d.globals.yAxisScale[u]&&this.ctx.theme.pushExtraColors(c,d.globals.yAxisScale[u].result.length,!1),c}},{key:"drawYAxisTicks",value:function(c,u,d,v,m,x,w){var k=this.w,L=new $(this.ctx),D=k.globals.translateY+k.config.yaxis[m].labels.offsetY;if(k.globals.isBarHorizontal?D=0:k.config.chart.type==="heatmap"&&(D+=x/2),v.show&&u>0){k.config.yaxis[m].opposite===!0&&(c+=v.width);for(var P=u;P>=0;P--){var V=L.drawLine(c+d.offsetX-v.width+v.offsetX,D+v.offsetY,c+d.offsetX+v.offsetX,D+v.offsetY,v.color);w.add(V),D+=x}}}}]),Q}(),ft=function(){function Q(c){a(this,Q),this.w=c.w,this.annoCtx=c,this.helpers=new Z(this.annoCtx),this.axesUtils=new tt(this.annoCtx)}return l(Q,[{key:"addYaxisAnnotation",value:function(c,u,d){var v,m=this.w,x=c.strokeDashArray,w=this.helpers.getY1Y2("y1",c),k=w.yP,L=w.clipped,D=!0,P=!1,V=c.label.text;if(c.y2===null||c.y2===void 0){if(!L){P=!0;var N=this.annoCtx.graphics.drawLine(0+c.offsetX,k+c.offsetY,this._getYAxisAnnotationWidth(c),k+c.offsetY,c.borderColor,x,c.borderWidth);u.appendChild(N.node),c.id&&N.node.classList.add(c.id)}}else{if(v=(w=this.helpers.getY1Y2("y2",c)).yP,D=w.clipped,v>k){var j=k;k=v,v=j}if(!L||!D){P=!0;var U=this.annoCtx.graphics.drawRect(0+c.offsetX,v+c.offsetY,this._getYAxisAnnotationWidth(c),k-v,0,c.fillColor,c.opacity,1,c.borderColor,x);U.node.classList.add("apexcharts-annotation-rect"),U.attr("clip-path","url(#gridRectMask".concat(m.globals.cuid,")")),u.appendChild(U.node),c.id&&U.node.classList.add(c.id)}}if(P){var q=c.label.position==="right"?m.globals.gridWidth:c.label.position==="center"?m.globals.gridWidth/2:0,J=this.annoCtx.graphics.drawText({x:q+c.label.offsetX,y:(v??k)+c.label.offsetY-3,text:V,textAnchor:c.label.textAnchor,fontSize:c.label.style.fontSize,fontFamily:c.label.style.fontFamily,fontWeight:c.label.style.fontWeight,foreColor:c.label.style.color,cssClass:"apexcharts-yaxis-annotation-label ".concat(c.label.style.cssClass," ").concat(c.id?c.id:"")});J.attr({rel:d}),u.appendChild(J.node)}}},{key:"_getYAxisAnnotationWidth",value:function(c){var u=this.w;return u.globals.gridWidth,(c.width.indexOf("%")>-1?u.globals.gridWidth*parseInt(c.width,10)/100:parseInt(c.width,10))+c.offsetX}},{key:"drawYAxisAnnotations",value:function(){var c=this,u=this.w,d=this.annoCtx.graphics.group({class:"apexcharts-yaxis-annotations"});return u.config.annotations.yaxis.forEach(function(v,m){v.yAxisIndex=c.axesUtils.translateYAxisIndex(v.yAxisIndex),c.axesUtils.isYAxisHidden(v.yAxisIndex)&&c.axesUtils.yAxisAllSeriesCollapsed(v.yAxisIndex)||c.addYaxisAnnotation(v,d.node,m)}),d}}]),Q}(),dt=function(){function Q(c){a(this,Q),this.w=c.w,this.annoCtx=c,this.helpers=new Z(this.annoCtx)}return l(Q,[{key:"addPointAnnotation",value:function(c,u,d){if(!(this.w.globals.collapsedSeriesIndices.indexOf(c.seriesIndex)>-1)){var v=this.helpers.getX1X2("x1",c),m=v.x,x=v.clipped,w=(v=this.helpers.getY1Y2("y1",c)).yP,k=v.clipped;if(E.isNumber(m)&&!k&&!x){var L={pSize:c.marker.size,pointStrokeWidth:c.marker.strokeWidth,pointFillColor:c.marker.fillColor,pointStrokeColor:c.marker.strokeColor,shape:c.marker.shape,pRadius:c.marker.radius,class:"apexcharts-point-annotation-marker ".concat(c.marker.cssClass," ").concat(c.id?c.id:"")},D=this.annoCtx.graphics.drawMarker(m+c.marker.offsetX,w+c.marker.offsetY,L);u.appendChild(D.node);var P=c.label.text?c.label.text:"",V=this.annoCtx.graphics.drawText({x:m+c.label.offsetX,y:w+c.label.offsetY-c.marker.size-parseFloat(c.label.style.fontSize)/1.6,text:P,textAnchor:c.label.textAnchor,fontSize:c.label.style.fontSize,fontFamily:c.label.style.fontFamily,fontWeight:c.label.style.fontWeight,foreColor:c.label.style.color,cssClass:"apexcharts-point-annotation-label ".concat(c.label.style.cssClass," ").concat(c.id?c.id:"")});if(V.attr({rel:d}),u.appendChild(V.node),c.customSVG.SVG){var N=this.annoCtx.graphics.group({class:"apexcharts-point-annotations-custom-svg "+c.customSVG.cssClass});N.attr({transform:"translate(".concat(m+c.customSVG.offsetX,", ").concat(w+c.customSVG.offsetY,")")}),N.node.innerHTML=c.customSVG.SVG,u.appendChild(N.node)}if(c.image.path){var j=c.image.width?c.image.width:20,U=c.image.height?c.image.height:20;D=this.annoCtx.addImage({x:m+c.image.offsetX-j/2,y:w+c.image.offsetY-U/2,width:j,height:U,path:c.image.path,appendTo:".apexcharts-point-annotations"})}c.mouseEnter&&D.node.addEventListener("mouseenter",c.mouseEnter.bind(this,c)),c.mouseLeave&&D.node.addEventListener("mouseleave",c.mouseLeave.bind(this,c)),c.click&&D.node.addEventListener("click",c.click.bind(this,c))}}}},{key:"drawPointAnnotations",value:function(){var c=this,u=this.w,d=this.annoCtx.graphics.group({class:"apexcharts-point-annotations"});return u.config.annotations.points.map(function(v,m){c.addPointAnnotation(v,d.node,m)}),d}}]),Q}(),ht={name:"en",options:{months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],toolbar:{exportToSVG:"Download SVG",exportToPNG:"Download PNG",exportToCSV:"Download CSV",menu:"Menu",selection:"Selection",selectionZoom:"Selection Zoom",zoomIn:"Zoom In",zoomOut:"Zoom Out",pan:"Panning",reset:"Reset Zoom"}}},lt=function(){function Q(){a(this,Q),this.yAxis={show:!0,showAlways:!1,showForNullSeries:!0,seriesName:void 0,opposite:!1,reversed:!1,logarithmic:!1,logBase:10,tickAmount:void 0,stepSize:void 0,forceNiceScale:!1,max:void 0,min:void 0,floating:!1,decimalsInFloat:void 0,labels:{show:!0,minWidth:0,maxWidth:160,offsetX:0,offsetY:0,align:void 0,rotate:0,padding:20,style:{colors:[],fontSize:"11px",fontWeight:400,fontFamily:void 0,cssClass:""},formatter:void 0},axisBorder:{show:!1,color:"#e0e0e0",width:1,offsetX:0,offsetY:0},axisTicks:{show:!1,color:"#e0e0e0",width:6,offsetX:0,offsetY:0},title:{text:void 0,rotate:-90,offsetY:0,offsetX:0,style:{color:void 0,fontSize:"11px",fontWeight:900,fontFamily:void 0,cssClass:""}},tooltip:{enabled:!1,offsetX:0},crosshairs:{show:!0,position:"front",stroke:{color:"#b6b6b6",width:1,dashArray:0}}},this.pointAnnotation={id:void 0,x:0,y:null,yAxisIndex:0,seriesIndex:void 0,mouseEnter:void 0,mouseLeave:void 0,click:void 0,marker:{size:4,fillColor:"#fff",strokeWidth:2,strokeColor:"#333",shape:"circle",offsetX:0,offsetY:0,cssClass:""},label:{borderColor:"#c2c2c2",borderWidth:1,borderRadius:2,text:void 0,textAnchor:"middle",offsetX:0,offsetY:0,mouseEnter:void 0,mouseLeave:void 0,click:void 0,style:{background:"#fff",color:void 0,fontSize:"11px",fontFamily:void 0,fontWeight:400,cssClass:"",padding:{left:5,right:5,top:2,bottom:2}}},customSVG:{SVG:void 0,cssClass:void 0,offsetX:0,offsetY:0},image:{path:void 0,width:20,height:20,offsetX:0,offsetY:0}},this.yAxisAnnotation={id:void 0,y:0,y2:null,strokeDashArray:1,fillColor:"#c2c2c2",borderColor:"#c2c2c2",borderWidth:1,opacity:.3,offsetX:0,offsetY:0,width:"100%",yAxisIndex:0,label:{borderColor:"#c2c2c2",borderWidth:1,borderRadius:2,text:void 0,textAnchor:"end",position:"right",offsetX:0,offsetY:-3,mouseEnter:void 0,mouseLeave:void 0,click:void 0,style:{background:"#fff",color:void 0,fontSize:"11px",fontFamily:void 0,fontWeight:400,cssClass:"",padding:{left:5,right:5,top:2,bottom:2}}}},this.xAxisAnnotation={id:void 0,x:0,x2:null,strokeDashArray:1,fillColor:"#c2c2c2",borderColor:"#c2c2c2",borderWidth:1,opacity:.3,offsetX:0,offsetY:0,label:{borderColor:"#c2c2c2",borderWidth:1,borderRadius:2,text:void 0,textAnchor:"middle",orientation:"vertical",position:"top",offsetX:0,offsetY:0,mouseEnter:void 0,mouseLeave:void 0,click:void 0,style:{background:"#fff",color:void 0,fontSize:"11px",fontFamily:void 0,fontWeight:400,cssClass:"",padding:{left:5,right:5,top:2,bottom:2}}}},this.text={x:0,y:0,text:"",textAnchor:"start",foreColor:void 0,fontSize:"13px",fontFamily:void 0,fontWeight:400,appendTo:".apexcharts-annotations",backgroundColor:"transparent",borderColor:"#c2c2c2",borderRadius:0,borderWidth:0,paddingLeft:4,paddingRight:4,paddingTop:2,paddingBottom:2}}return l(Q,[{key:"init",value:function(){return{annotations:{yaxis:[this.yAxisAnnotation],xaxis:[this.xAxisAnnotation],points:[this.pointAnnotation],texts:[],images:[],shapes:[]},chart:{animations:{enabled:!0,easing:"easeinout",speed:800,animateGradually:{delay:150,enabled:!0},dynamicAnimation:{enabled:!0,speed:350}},background:"",locales:[ht],defaultLocale:"en",dropShadow:{enabled:!1,enabledOnSeries:void 0,top:2,left:2,blur:4,color:"#000",opacity:.35},events:{animationEnd:void 0,beforeMount:void 0,mounted:void 0,updated:void 0,click:void 0,mouseMove:void 0,mouseLeave:void 0,xAxisLabelClick:void 0,legendClick:void 0,markerClick:void 0,selection:void 0,dataPointSelection:void 0,dataPointMouseEnter:void 0,dataPointMouseLeave:void 0,beforeZoom:void 0,beforeResetZoom:void 0,zoomed:void 0,scrolled:void 0,brushScrolled:void 0},foreColor:"#373d3f",fontFamily:"Helvetica, Arial, sans-serif",height:"auto",parentHeightOffset:15,redrawOnParentResize:!0,redrawOnWindowResize:!0,id:void 0,group:void 0,nonce:void 0,offsetX:0,offsetY:0,selection:{enabled:!1,type:"x",fill:{color:"#24292e",opacity:.1},stroke:{width:1,color:"#24292e",opacity:.4,dashArray:3},xaxis:{min:void 0,max:void 0},yaxis:{min:void 0,max:void 0}},sparkline:{enabled:!1},brush:{enabled:!1,autoScaleYaxis:!0,target:void 0,targets:void 0},stacked:!1,stackOnlyBar:!0,stackType:"normal",toolbar:{show:!0,offsetX:0,offsetY:0,tools:{download:!0,selection:!0,zoom:!0,zoomin:!0,zoomout:!0,pan:!0,reset:!0,customIcons:[]},export:{csv:{filename:void 0,columnDelimiter:",",headerCategory:"category",headerValue:"value",categoryFormatter:void 0,valueFormatter:void 0},png:{filename:void 0},svg:{filename:void 0}},autoSelected:"zoom"},type:"line",width:"100%",zoom:{enabled:!0,type:"x",autoScaleYaxis:!1,zoomedArea:{fill:{color:"#90CAF9",opacity:.4},stroke:{color:"#0D47A1",opacity:.4,width:1}}}},plotOptions:{line:{isSlopeChart:!1},area:{fillTo:"origin"},bar:{horizontal:!1,columnWidth:"70%",barHeight:"70%",distributed:!1,borderRadius:0,borderRadiusApplication:"around",borderRadiusWhenStacked:"last",rangeBarOverlap:!0,rangeBarGroupRows:!1,hideZeroBarsWhenGrouped:!1,isDumbbell:!1,dumbbellColors:void 0,isFunnel:!1,isFunnel3d:!0,colors:{ranges:[],backgroundBarColors:[],backgroundBarOpacity:1,backgroundBarRadius:0},dataLabels:{position:"top",maxItems:100,hideOverflowingLabels:!0,orientation:"horizontal",total:{enabled:!1,formatter:void 0,offsetX:0,offsetY:0,style:{color:"#373d3f",fontSize:"12px",fontFamily:void 0,fontWeight:600}}}},bubble:{zScaling:!0,minBubbleRadius:void 0,maxBubbleRadius:void 0},candlestick:{colors:{upward:"#00B746",downward:"#EF403C"},wick:{useFillColor:!0}},boxPlot:{colors:{upper:"#00E396",lower:"#008FFB"}},heatmap:{radius:2,enableShades:!0,shadeIntensity:.5,reverseNegativeShade:!1,distributed:!1,useFillColorAsStroke:!1,colorScale:{inverse:!1,ranges:[],min:void 0,max:void 0}},treemap:{enableShades:!0,shadeIntensity:.5,distributed:!1,reverseNegativeShade:!1,useFillColorAsStroke:!1,borderRadius:4,dataLabels:{format:"scale"},colorScale:{inverse:!1,ranges:[],min:void 0,max:void 0}},radialBar:{inverseOrder:!1,startAngle:0,endAngle:360,offsetX:0,offsetY:0,hollow:{margin:5,size:"50%",background:"transparent",image:void 0,imageWidth:150,imageHeight:150,imageOffsetX:0,imageOffsetY:0,imageClipped:!0,position:"front",dropShadow:{enabled:!1,top:0,left:0,blur:3,color:"#000",opacity:.5}},track:{show:!0,startAngle:void 0,endAngle:void 0,background:"#f2f2f2",strokeWidth:"97%",opacity:1,margin:5,dropShadow:{enabled:!1,top:0,left:0,blur:3,color:"#000",opacity:.5}},dataLabels:{show:!0,name:{show:!0,fontSize:"16px",fontFamily:void 0,fontWeight:600,color:void 0,offsetY:0,formatter:function(c){return c}},value:{show:!0,fontSize:"14px",fontFamily:void 0,fontWeight:400,color:void 0,offsetY:16,formatter:function(c){return c+"%"}},total:{show:!1,label:"Total",fontSize:"16px",fontWeight:600,fontFamily:void 0,color:void 0,formatter:function(c){return c.globals.seriesTotals.reduce(function(u,d){return u+d},0)/c.globals.series.length+"%"}}},barLabels:{enabled:!1,offsetX:0,offsetY:0,useSeriesColors:!0,fontFamily:void 0,fontWeight:600,fontSize:"16px",formatter:function(c){return c},onClick:void 0}},pie:{customScale:1,offsetX:0,offsetY:0,startAngle:0,endAngle:360,expandOnClick:!0,dataLabels:{offset:0,minAngleToShowLabel:10},donut:{size:"65%",background:"transparent",labels:{show:!1,name:{show:!0,fontSize:"16px",fontFamily:void 0,fontWeight:600,color:void 0,offsetY:-10,formatter:function(c){return c}},value:{show:!0,fontSize:"20px",fontFamily:void 0,fontWeight:400,color:void 0,offsetY:10,formatter:function(c){return c}},total:{show:!1,showAlways:!1,label:"Total",fontSize:"16px",fontWeight:400,fontFamily:void 0,color:void 0,formatter:function(c){return c.globals.seriesTotals.reduce(function(u,d){return u+d},0)}}}}},polarArea:{rings:{strokeWidth:1,strokeColor:"#e8e8e8"},spokes:{strokeWidth:1,connectorColors:"#e8e8e8"}},radar:{size:void 0,offsetX:0,offsetY:0,polygons:{strokeWidth:1,strokeColors:"#e8e8e8",connectorColors:"#e8e8e8",fill:{colors:void 0}}}},colors:void 0,dataLabels:{enabled:!0,enabledOnSeries:void 0,formatter:function(c){return c!==null?c:""},textAnchor:"middle",distributed:!1,offsetX:0,offsetY:0,style:{fontSize:"12px",fontFamily:void 0,fontWeight:600,colors:void 0},background:{enabled:!0,foreColor:"#fff",borderRadius:2,padding:4,opacity:.9,borderWidth:1,borderColor:"#fff",dropShadow:{enabled:!1,top:1,left:1,blur:1,color:"#000",opacity:.45}},dropShadow:{enabled:!1,top:1,left:1,blur:1,color:"#000",opacity:.45}},fill:{type:"solid",colors:void 0,opacity:.85,gradient:{shade:"dark",type:"horizontal",shadeIntensity:.5,gradientToColors:void 0,inverseColors:!0,opacityFrom:1,opacityTo:1,stops:[0,50,100],colorStops:[]},image:{src:[],width:void 0,height:void 0},pattern:{style:"squares",width:6,height:6,strokeWidth:2}},forecastDataPoints:{count:0,fillOpacity:.5,strokeWidth:void 0,dashArray:4},grid:{show:!0,borderColor:"#e0e0e0",strokeDashArray:0,position:"back",xaxis:{lines:{show:!1}},yaxis:{lines:{show:!0}},row:{colors:void 0,opacity:.5},column:{colors:void 0,opacity:.5},padding:{top:0,right:10,bottom:0,left:12}},labels:[],legend:{show:!0,showForSingleSeries:!1,showForNullSeries:!0,showForZeroSeries:!0,floating:!1,position:"bottom",horizontalAlign:"center",inverseOrder:!1,fontSize:"12px",fontFamily:void 0,fontWeight:400,width:void 0,height:void 0,formatter:void 0,tooltipHoverFormatter:void 0,offsetX:-20,offsetY:4,customLegendItems:[],labels:{colors:void 0,useSeriesColors:!1},markers:{size:7,fillColors:void 0,strokeWidth:1,shape:void 0,offsetX:0,offsetY:0,customHTML:void 0,onClick:void 0},itemMargin:{horizontal:5,vertical:4},onItemClick:{toggleDataSeries:!0},onItemHover:{highlightDataSeries:!0}},markers:{discrete:[],size:0,colors:void 0,strokeColors:"#fff",strokeWidth:2,strokeOpacity:.9,strokeDashArray:0,fillOpacity:1,shape:"circle",offsetX:0,offsetY:0,showNullDataPoints:!0,onClick:void 0,onDblClick:void 0,hover:{size:void 0,sizeOffset:3}},noData:{text:void 0,align:"center",verticalAlign:"middle",offsetX:0,offsetY:0,style:{color:void 0,fontSize:"14px",fontFamily:void 0}},responsive:[],series:void 0,states:{normal:{filter:{type:"none",value:0}},hover:{filter:{type:"lighten",value:.1}},active:{allowMultipleDataPointsSelection:!1,filter:{type:"darken",value:.5}}},title:{text:void 0,align:"left",margin:5,offsetX:0,offsetY:0,floating:!1,style:{fontSize:"14px",fontWeight:900,fontFamily:void 0,color:void 0}},subtitle:{text:void 0,align:"left",margin:5,offsetX:0,offsetY:30,floating:!1,style:{fontSize:"12px",fontWeight:400,fontFamily:void 0,color:void 0}},stroke:{show:!0,curve:"smooth",lineCap:"butt",width:2,colors:void 0,dashArray:0,fill:{type:"solid",colors:void 0,opacity:.85,gradient:{shade:"dark",type:"horizontal",shadeIntensity:.5,gradientToColors:void 0,inverseColors:!0,opacityFrom:1,opacityTo:1,stops:[0,50,100],colorStops:[]}}},tooltip:{enabled:!0,enabledOnSeries:void 0,shared:!0,hideEmptySeries:!1,followCursor:!1,intersect:!1,inverseOrder:!1,custom:void 0,fillSeriesColor:!1,theme:"light",cssClass:"",style:{fontSize:"12px",fontFamily:void 0},onDatasetHover:{highlightDataSeries:!1},x:{show:!0,format:"dd MMM",formatter:void 0},y:{formatter:void 0,title:{formatter:function(c){return c?c+": ":""}}},z:{formatter:void 0,title:"Size: "},marker:{show:!0,fillColors:void 0},items:{display:"flex"},fixed:{enabled:!1,position:"topRight",offsetX:0,offsetY:0}},xaxis:{type:"category",categories:[],convertedCatToNumeric:!1,offsetX:0,offsetY:0,overwriteCategories:void 0,labels:{show:!0,rotate:-45,rotateAlways:!1,hideOverlappingLabels:!0,trim:!1,minHeight:void 0,maxHeight:120,showDuplicates:!0,style:{colors:[],fontSize:"12px",fontWeight:400,fontFamily:void 0,cssClass:""},offsetX:0,offsetY:0,format:void 0,formatter:void 0,datetimeUTC:!0,datetimeFormatter:{year:"yyyy",month:"MMM 'yy",day:"dd MMM",hour:"HH:mm",minute:"HH:mm:ss",second:"HH:mm:ss"}},group:{groups:[],style:{colors:[],fontSize:"12px",fontWeight:400,fontFamily:void 0,cssClass:""}},axisBorder:{show:!0,color:"#e0e0e0",width:"100%",height:1,offsetX:0,offsetY:0},axisTicks:{show:!0,color:"#e0e0e0",height:6,offsetX:0,offsetY:0},stepSize:void 0,tickAmount:void 0,tickPlacement:"on",min:void 0,max:void 0,range:void 0,floating:!1,decimalsInFloat:void 0,position:"bottom",title:{text:void 0,offsetX:0,offsetY:0,style:{color:void 0,fontSize:"12px",fontWeight:900,fontFamily:void 0,cssClass:""}},crosshairs:{show:!0,width:1,position:"back",opacity:.9,stroke:{color:"#b6b6b6",width:1,dashArray:3},fill:{type:"solid",color:"#B1B9C4",gradient:{colorFrom:"#D8E3F0",colorTo:"#BED1E6",stops:[0,100],opacityFrom:.4,opacityTo:.5}},dropShadow:{enabled:!1,left:0,top:0,blur:1,opacity:.4}},tooltip:{enabled:!0,offsetY:0,formatter:void 0,style:{fontSize:"12px",fontFamily:void 0}}},yaxis:this.yAxis,theme:{mode:"",palette:"palette1",monochrome:{enabled:!1,color:"#008FFB",shadeTo:"light",shadeIntensity:.65}}}}}]),Q}(),yt=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w,this.graphics=new $(this.ctx),this.w.globals.isBarHorizontal&&(this.invertAxis=!0),this.helpers=new Z(this),this.xAxisAnnotations=new K(this),this.yAxisAnnotations=new ft(this),this.pointsAnnotations=new dt(this),this.w.globals.isBarHorizontal&&this.w.config.yaxis[0].reversed&&(this.inversedReversedAxis=!0),this.xDivision=this.w.globals.gridWidth/this.w.globals.dataPoints}return l(Q,[{key:"drawAxesAnnotations",value:function(){var c=this.w;if(c.globals.axisCharts){for(var u=this.yAxisAnnotations.drawYAxisAnnotations(),d=this.xAxisAnnotations.drawXAxisAnnotations(),v=this.pointsAnnotations.drawPointAnnotations(),m=c.config.chart.animations.enabled,x=[u,d,v],w=[d.node,u.node,v.node],k=0;k<3;k++)c.globals.dom.elGraphical.add(x[k]),!m||c.globals.resized||c.globals.dataChanged||c.config.chart.type!=="scatter"&&c.config.chart.type!=="bubble"&&c.globals.dataPoints>1&&w[k].classList.add("apexcharts-element-hidden"),c.globals.delayedElements.push({el:w[k],index:0});this.helpers.annotationsBackground()}}},{key:"drawImageAnnos",value:function(){var c=this;this.w.config.annotations.images.map(function(u,d){c.addImage(u,d)})}},{key:"drawTextAnnos",value:function(){var c=this;this.w.config.annotations.texts.map(function(u,d){c.addText(u,d)})}},{key:"addXaxisAnnotation",value:function(c,u,d){this.xAxisAnnotations.addXaxisAnnotation(c,u,d)}},{key:"addYaxisAnnotation",value:function(c,u,d){this.yAxisAnnotations.addYaxisAnnotation(c,u,d)}},{key:"addPointAnnotation",value:function(c,u,d){this.pointsAnnotations.addPointAnnotation(c,u,d)}},{key:"addText",value:function(c,u){var d=c.x,v=c.y,m=c.text,x=c.textAnchor,w=c.foreColor,k=c.fontSize,L=c.fontFamily,D=c.fontWeight,P=c.cssClass,V=c.backgroundColor,N=c.borderWidth,j=c.strokeDashArray,U=c.borderRadius,q=c.borderColor,J=c.appendTo,rt=J===void 0?".apexcharts-svg":J,A=c.paddingLeft,O=A===void 0?4:A,X=c.paddingRight,ot=X===void 0?4:X,nt=c.paddingBottom,ct=nt===void 0?2:nt,wt=c.paddingTop,xt=wt===void 0?2:wt,jt=this.w,ee=this.graphics.drawText({x:d,y:v,text:m,textAnchor:x||"start",fontSize:k||"12px",fontWeight:D||"regular",fontFamily:L||jt.config.chart.fontFamily,foreColor:w||jt.config.chart.foreColor,cssClass:P}),Nt=jt.globals.dom.baseEl.querySelector(rt);Nt&&Nt.appendChild(ee.node);var Zt=ee.bbox();if(m){var ze=this.graphics.drawRect(Zt.x-O,Zt.y-xt,Zt.width+O+ot,Zt.height+ct+xt,U,V||"transparent",1,N,q,j);Nt.insertBefore(ze.node,ee.node)}}},{key:"addImage",value:function(c,u){var d=this.w,v=c.path,m=c.x,x=m===void 0?0:m,w=c.y,k=w===void 0?0:w,L=c.width,D=L===void 0?20:L,P=c.height,V=P===void 0?20:P,N=c.appendTo,j=N===void 0?".apexcharts-svg":N,U=d.globals.dom.Paper.image(v);U.size(D,V).move(x,k);var q=d.globals.dom.baseEl.querySelector(j);return q&&q.appendChild(U.node),U}},{key:"addXaxisAnnotationExternal",value:function(c,u,d){return this.addAnnotationExternal({params:c,pushToMemory:u,context:d,type:"xaxis",contextMethod:d.addXaxisAnnotation}),d}},{key:"addYaxisAnnotationExternal",value:function(c,u,d){return this.addAnnotationExternal({params:c,pushToMemory:u,context:d,type:"yaxis",contextMethod:d.addYaxisAnnotation}),d}},{key:"addPointAnnotationExternal",value:function(c,u,d){return this.invertAxis===void 0&&(this.invertAxis=d.w.globals.isBarHorizontal),this.addAnnotationExternal({params:c,pushToMemory:u,context:d,type:"point",contextMethod:d.addPointAnnotation}),d}},{key:"addAnnotationExternal",value:function(c){var u=c.params,d=c.pushToMemory,v=c.context,m=c.type,x=c.contextMethod,w=v,k=w.w,L=k.globals.dom.baseEl.querySelector(".apexcharts-".concat(m,"-annotations")),D=L.childNodes.length+1,P=new lt,V=Object.assign({},m==="xaxis"?P.xAxisAnnotation:m==="yaxis"?P.yAxisAnnotation:P.pointAnnotation),N=E.extend(V,u);switch(m){case"xaxis":this.addXaxisAnnotation(N,L,D);break;case"yaxis":this.addYaxisAnnotation(N,L,D);break;case"point":this.addPointAnnotation(N,L,D)}var j=k.globals.dom.baseEl.querySelector(".apexcharts-".concat(m,"-annotations .apexcharts-").concat(m,"-annotation-label[rel='").concat(D,"']")),U=this.helpers.addBackgroundToAnno(j,N);return U&&L.insertBefore(U.node,j),d&&k.globals.memory.methodsToExec.push({context:w,id:N.id?N.id:E.randomId(),method:x,label:"addAnnotation",params:u}),v}},{key:"clearAnnotations",value:function(c){var u=c.w,d=u.globals.dom.baseEl.querySelectorAll(".apexcharts-yaxis-annotations, .apexcharts-xaxis-annotations, .apexcharts-point-annotations");u.globals.memory.methodsToExec.map(function(v,m){v.label!=="addText"&&v.label!=="addAnnotation"||u.globals.memory.methodsToExec.splice(m,1)}),d=E.listToArray(d),Array.prototype.forEach.call(d,function(v){for(;v.firstChild;)v.removeChild(v.firstChild)})}},{key:"removeAnnotation",value:function(c,u){var d=c.w,v=d.globals.dom.baseEl.querySelectorAll(".".concat(u));v&&(d.globals.memory.methodsToExec.map(function(m,x){m.id===u&&d.globals.memory.methodsToExec.splice(x,1)}),Array.prototype.forEach.call(v,function(m){m.parentElement.removeChild(m)}))}}]),Q}(),mt=function(Q){var c,u=Q.isTimeline,d=Q.ctx,v=Q.seriesIndex,m=Q.dataPointIndex,x=Q.y1,w=Q.y2,k=Q.w,L=k.globals.seriesRangeStart[v][m],D=k.globals.seriesRangeEnd[v][m],P=k.globals.labels[m],V=k.config.series[v].name?k.config.series[v].name:"",N=k.globals.ttKeyFormatter,j=k.config.tooltip.y.title.formatter,U={w:k,seriesIndex:v,dataPointIndex:m,start:L,end:D};typeof j=="function"&&(V=j(V,U)),(c=k.config.series[v].data[m])!==null&&c!==void 0&&c.x&&(P=k.config.series[v].data[m].x),u||k.config.xaxis.type==="datetime"&&(P=new at(d).xLabelFormat(k.globals.ttKeyFormatter,P,P,{i:void 0,dateFormatter:new et(d).formatDate,w:k})),typeof N=="function"&&(P=N(P,U)),Number.isFinite(x)&&Number.isFinite(w)&&(L=x,D=w);var q="",J="",rt=k.globals.colors[v];if(k.config.tooltip.x.formatter===void 0)if(k.config.xaxis.type==="datetime"){var A=new et(d);q=A.formatDate(A.getDate(L),k.config.tooltip.x.format),J=A.formatDate(A.getDate(D),k.config.tooltip.x.format)}else q=L,J=D;else q=k.config.tooltip.x.formatter(L),J=k.config.tooltip.x.formatter(D);return{start:L,end:D,startVal:q,endVal:J,ylabel:P,color:rt,seriesName:V}},gt=function(Q){var c=Q.color,u=Q.seriesName,d=Q.ylabel,v=Q.start,m=Q.end,x=Q.seriesIndex,w=Q.dataPointIndex,k=Q.ctx.tooltip.tooltipLabels.getFormatters(x);v=k.yLbFormatter(v),m=k.yLbFormatter(m);var L=k.yLbFormatter(Q.w.globals.series[x][w]),D=` + a `).concat(v/2,",").concat(v/2," 0 1,0 -").concat(v,",0")}return m}},{key:"drawMarkerShape",value:function(c,u,d,v,m){var x=this.drawPath({d:this.getMarkerPath(c,u,d,v,m),stroke:m.pointStrokeColor,strokeDashArray:m.pointStrokeDashArray,strokeWidth:m.pointStrokeWidth,fill:m.pointFillColor,fillOpacity:m.pointFillOpacity,strokeOpacity:m.pointStrokeOpacity});return x.attr({cx:c,cy:u,shape:m.shape,class:m.class?m.class:""}),x}},{key:"drawMarker",value:function(c,u,d){c=c||0;var v=d.pSize||0;return E.isNumber(u)||(v=0,u=0),this.drawMarkerShape(c,u,d==null?void 0:d.shape,v,i(i({},d),d.shape==="line"||d.shape==="plus"||d.shape==="cross"?{pointStrokeColor:d.pointFillColor,pointStrokeOpacity:d.pointFillOpacity}:{}))}},{key:"pathMouseEnter",value:function(c,u){var d=this.w,v=new W(this.ctx),m=parseInt(c.node.getAttribute("index"),10),x=parseInt(c.node.getAttribute("j"),10);if(typeof d.config.chart.events.dataPointMouseEnter=="function"&&d.config.chart.events.dataPointMouseEnter(u,this.ctx,{seriesIndex:m,dataPointIndex:x,w:d}),this.ctx.events.fireEvent("dataPointMouseEnter",[u,this.ctx,{seriesIndex:m,dataPointIndex:x,w:d}]),(d.config.states.active.filter.type==="none"||c.node.getAttribute("selected")!=="true")&&d.config.states.hover.filter.type!=="none"&&!d.globals.isTouchDevice){var w=d.config.states.hover.filter;v.applyFilter(c,m,w.type,w.value)}}},{key:"pathMouseLeave",value:function(c,u){var d=this.w,v=new W(this.ctx),m=parseInt(c.node.getAttribute("index"),10),x=parseInt(c.node.getAttribute("j"),10);typeof d.config.chart.events.dataPointMouseLeave=="function"&&d.config.chart.events.dataPointMouseLeave(u,this.ctx,{seriesIndex:m,dataPointIndex:x,w:d}),this.ctx.events.fireEvent("dataPointMouseLeave",[u,this.ctx,{seriesIndex:m,dataPointIndex:x,w:d}]),d.config.states.active.filter.type!=="none"&&c.node.getAttribute("selected")==="true"||d.config.states.hover.filter.type!=="none"&&v.getDefaultFilter(c,m)}},{key:"pathMouseDown",value:function(c,u){var d=this.w,v=new W(this.ctx),m=parseInt(c.node.getAttribute("index"),10),x=parseInt(c.node.getAttribute("j"),10),w="false";if(c.node.getAttribute("selected")==="true"){if(c.node.setAttribute("selected","false"),d.globals.selectedDataPoints[m].indexOf(x)>-1){var k=d.globals.selectedDataPoints[m].indexOf(x);d.globals.selectedDataPoints[m].splice(k,1)}}else{if(!d.config.states.active.allowMultipleDataPointsSelection&&d.globals.selectedDataPoints.length>0){d.globals.selectedDataPoints=[];var L=d.globals.dom.Paper.select(".apexcharts-series path").members,D=d.globals.dom.Paper.select(".apexcharts-series circle, .apexcharts-series rect").members,P=function(j){Array.prototype.forEach.call(j,function(U){U.node.setAttribute("selected","false"),v.getDefaultFilter(U,m)})};P(L),P(D)}c.node.setAttribute("selected","true"),w="true",d.globals.selectedDataPoints[m]===void 0&&(d.globals.selectedDataPoints[m]=[]),d.globals.selectedDataPoints[m].push(x)}if(w==="true"){var V=d.config.states.active.filter;if(V!=="none")v.applyFilter(c,m,V.type,V.value);else if(d.config.states.hover.filter!=="none"&&!d.globals.isTouchDevice){var N=d.config.states.hover.filter;v.applyFilter(c,m,N.type,N.value)}}else d.config.states.active.filter.type!=="none"&&(d.config.states.hover.filter.type==="none"||d.globals.isTouchDevice?v.getDefaultFilter(c,m):(N=d.config.states.hover.filter,v.applyFilter(c,m,N.type,N.value)));typeof d.config.chart.events.dataPointSelection=="function"&&d.config.chart.events.dataPointSelection(u,this.ctx,{selectedDataPoints:d.globals.selectedDataPoints,seriesIndex:m,dataPointIndex:x,w:d}),u&&this.ctx.events.fireEvent("dataPointSelection",[u,this.ctx,{selectedDataPoints:d.globals.selectedDataPoints,seriesIndex:m,dataPointIndex:x,w:d}])}},{key:"rotateAroundCenter",value:function(c){var u={};return c&&typeof c.getBBox=="function"&&(u=c.getBBox()),{x:u.x+u.width/2,y:u.y+u.height/2}}},{key:"getTextRects",value:function(c,u,d,v){var m=!(arguments.length>4&&arguments[4]!==void 0)||arguments[4],x=this.w,w=this.drawText({x:-200,y:-200,text:c,textAnchor:"start",fontSize:u,fontFamily:d,foreColor:"#fff",opacity:0});v&&w.attr("transform",v),x.globals.dom.Paper.add(w);var k=w.bbox();return m||(k=w.node.getBoundingClientRect()),w.remove(),{width:k.width,height:k.height}}},{key:"placeTextWithEllipsis",value:function(c,u,d){if(typeof c.getComputedTextLength=="function"&&(c.textContent=u,u.length>0&&c.getComputedTextLength()>=d/1.1)){for(var v=u.length-3;v>0;v-=3)if(c.getSubStringLength(0,v)<=d/1.1)return void(c.textContent=u.substring(0,v)+"...");c.textContent="."}}}],[{key:"setAttrs",value:function(c,u){for(var d in u)u.hasOwnProperty(d)&&c.setAttribute(d,u[d])}}]),Q}(),G=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w}return l(Q,[{key:"getStackedSeriesTotals",value:function(){var c=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],u=this.w,d=[];if(u.globals.series.length===0)return d;for(var v=0;v0&&arguments[0]!==void 0?arguments[0]:null;return c===null?this.w.config.series.reduce(function(u,d){return u+d},0):this.w.globals.series[c].reduce(function(u,d){return u+d},0)}},{key:"getStackedSeriesTotalsByGroups",value:function(){var c=this,u=this.w,d=[];return u.globals.seriesGroups.forEach(function(v){var m=[];u.config.series.forEach(function(w,k){v.indexOf(u.globals.seriesNames[k])>-1&&m.push(k)});var x=u.globals.series.map(function(w,k){return m.indexOf(k)===-1?k:-1}).filter(function(w){return w!==-1});d.push(c.getStackedSeriesTotals(x))}),d}},{key:"setSeriesYAxisMappings",value:function(){var c=this.w.globals,u=this.w.config,d=[],v=[],m=[],x=c.series.length>u.yaxis.length||u.yaxis.some(function(P){return Array.isArray(P.seriesName)});u.series.forEach(function(P,V){m.push(V),v.push(null)}),u.yaxis.forEach(function(P,V){d[V]=[]});var w=[];u.yaxis.forEach(function(P,V){var N=!1;if(P.seriesName){var j=[];Array.isArray(P.seriesName)?j=P.seriesName:j.push(P.seriesName),j.forEach(function(U){u.series.forEach(function(q,J){if(q.name===U){var rt=J;V===J||x?!x||m.indexOf(J)>-1?d[V].push([V,J]):console.warn("Series '"+q.name+"' referenced more than once in what looks like the new style. That is, when using either seriesName: [], or when there are more series than yaxes."):(d[J].push([J,V]),rt=V),N=!0,(rt=m.indexOf(rt))!==-1&&m.splice(rt,1)}})})}N||w.push(V)}),d=d.map(function(P,V){var N=[];return P.forEach(function(j){v[j[1]]=j[0],N.push(j[1])}),N});for(var k=u.yaxis.length-1,L=0;L0&&arguments[0]!==void 0?arguments[0]:null;return(c===null?this.w.config.series.filter(function(u){return u!==null}):this.w.config.series[c].data.filter(function(u){return u!==null})).length===0}},{key:"seriesHaveSameValues",value:function(c){return this.w.globals.series[c].every(function(u,d,v){return u===v[0]})}},{key:"getCategoryLabels",value:function(c){var u=this.w,d=c.slice();return u.config.xaxis.convertedCatToNumeric&&(d=c.map(function(v,m){return u.config.xaxis.labels.formatter(v-u.globals.minX+1)})),d}},{key:"getLargestSeries",value:function(){var c=this.w;c.globals.maxValsInArrayIndex=c.globals.series.map(function(u){return u.length}).indexOf(Math.max.apply(Math,c.globals.series.map(function(u){return u.length})))}},{key:"getLargestMarkerSize",value:function(){var c=this.w,u=0;return c.globals.markers.size.forEach(function(d){u=Math.max(u,d)}),c.config.markers.discrete&&c.config.markers.discrete.length&&c.config.markers.discrete.forEach(function(d){u=Math.max(u,d.size)}),u>0&&(u+=c.config.markers.hover.sizeOffset+1),c.globals.markers.largestSize=u,u}},{key:"getSeriesTotals",value:function(){var c=this.w;c.globals.seriesTotals=c.globals.series.map(function(u,d){var v=0;if(Array.isArray(u))for(var m=0;mc&&d.globals.seriesX[m][w]0){var j=function(q,J){var rt=m.config.yaxis[m.globals.seriesYAxisReverseMap[J]],A=q<0?-1:1;return q=Math.abs(q),rt.logarithmic&&(q=v.getBaseLog(rt.logBase,q)),-A*q/w[J]};if(x.isMultipleYAxis){L=[];for(var U=0;U0&&u.forEach(function(w){var k=[],L=[];c.i.forEach(function(D,P){m.config.series[D].group===w&&(k.push(c.series[P]),L.push(D))}),k.length>0&&x.push(v.draw(k,d,L))}),x}}],[{key:"checkComboSeries",value:function(c,u){var d=!1,v=0,m=0;return u===void 0&&(u="line"),c.length&&c[0].type!==void 0&&c.forEach(function(x){x.type!=="bar"&&x.type!=="column"&&x.type!=="candlestick"&&x.type!=="boxPlot"||v++,x.type!==void 0&&x.type!==u&&m++}),m>0&&(d=!0),{comboBarCount:v,comboCharts:d}}},{key:"extendArrayProps",value:function(c,u,d){var v,m,x,w,k,L;return(v=u)!==null&&v!==void 0&&v.yaxis&&(u=c.extendYAxis(u,d)),(m=u)!==null&&m!==void 0&&m.annotations&&(u.annotations.yaxis&&(u=c.extendYAxisAnnotations(u)),(x=u)!==null&&x!==void 0&&(w=x.annotations)!==null&&w!==void 0&&w.xaxis&&(u=c.extendXAxisAnnotations(u)),(k=u)!==null&&k!==void 0&&(L=k.annotations)!==null&&L!==void 0&&L.points&&(u=c.extendPointAnnotations(u))),u}}]),Q}(),Z=function(){function Q(c){a(this,Q),this.w=c.w,this.annoCtx=c}return l(Q,[{key:"setOrientations",value:function(c){var u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:null,d=this.w;if(c.label.orientation==="vertical"){var v=u!==null?u:0,m=d.globals.dom.baseEl.querySelector(".apexcharts-xaxis-annotations .apexcharts-xaxis-annotation-label[rel='".concat(v,"']"));if(m!==null){var x=m.getBoundingClientRect();m.setAttribute("x",parseFloat(m.getAttribute("x"))-x.height+4),c.label.position==="top"?m.setAttribute("y",parseFloat(m.getAttribute("y"))+x.width):m.setAttribute("y",parseFloat(m.getAttribute("y"))-x.width);var w=this.annoCtx.graphics.rotateAroundCenter(m),k=w.x,L=w.y;m.setAttribute("transform","rotate(-90 ".concat(k," ").concat(L,")"))}}}},{key:"addBackgroundToAnno",value:function(c,u){var d=this.w;if(!c||u.label.text===void 0||u.label.text!==void 0&&!String(u.label.text).trim())return null;var v=d.globals.dom.baseEl.querySelector(".apexcharts-grid").getBoundingClientRect(),m=c.getBoundingClientRect(),x=u.label.style.padding.left,w=u.label.style.padding.right,k=u.label.style.padding.top,L=u.label.style.padding.bottom;u.label.orientation==="vertical"&&(k=u.label.style.padding.left,L=u.label.style.padding.right,x=u.label.style.padding.top,w=u.label.style.padding.bottom);var D=m.left-v.left-x,P=m.top-v.top-k,V=this.annoCtx.graphics.drawRect(D-d.globals.barPadForNumericAxis,P,m.width+x+w,m.height+k+L,u.label.borderRadius,u.label.style.background,1,u.label.borderWidth,u.label.borderColor,0);return u.id&&V.node.classList.add(u.id),V}},{key:"annotationsBackground",value:function(){var c=this,u=this.w,d=function(v,m,x){var w=u.globals.dom.baseEl.querySelector(".apexcharts-".concat(x,"-annotations .apexcharts-").concat(x,"-annotation-label[rel='").concat(m,"']"));if(w){var k=w.parentNode,L=c.addBackgroundToAnno(w,v);L&&(k.insertBefore(L.node,w),v.label.mouseEnter&&L.node.addEventListener("mouseenter",v.label.mouseEnter.bind(c,v)),v.label.mouseLeave&&L.node.addEventListener("mouseleave",v.label.mouseLeave.bind(c,v)),v.label.click&&L.node.addEventListener("click",v.label.click.bind(c,v)))}};u.config.annotations.xaxis.map(function(v,m){d(v,m,"xaxis")}),u.config.annotations.yaxis.map(function(v,m){d(v,m,"yaxis")}),u.config.annotations.points.map(function(v,m){d(v,m,"point")})}},{key:"getY1Y2",value:function(c,u){var d,v=c==="y1"?u.y:u.y2,m=!1,x=this.w;if(this.annoCtx.invertAxis){var w=x.globals.labels;x.config.xaxis.convertedCatToNumeric&&(w=x.globals.categoryLabels);var k=w.indexOf(v),L=x.globals.dom.baseEl.querySelector(".apexcharts-yaxis-texts-g text:nth-child("+(k+1)+")");d=L?parseFloat(L.getAttribute("y")):(x.globals.gridHeight/w.length-1)*(k+1)-x.globals.barHeight,u.seriesIndex!==void 0&&x.globals.barHeight&&(d=d-x.globals.barHeight/2*(x.globals.series.length-1)+x.globals.barHeight*u.seriesIndex)}else{var D,P=x.globals.seriesYAxisMap[u.yAxisIndex][0];x.config.yaxis[u.yAxisIndex].logarithmic?D=(v=new G(this.annoCtx.ctx).getLogVal(x.config.yaxis[u.yAxisIndex].logBase,v,P))/x.globals.yLogRatio[P]:D=(v-x.globals.minYArr[P])/(x.globals.yRange[P]/x.globals.gridHeight),D>x.globals.gridHeight?(D=x.globals.gridHeight,m=!0):D<0&&(D=0,m=!0),d=x.globals.gridHeight-D,!u.marker||u.y!==void 0&&u.y!==null||(d=0),x.config.yaxis[u.yAxisIndex]&&x.config.yaxis[u.yAxisIndex].reversed&&(d=D)}return typeof v=="string"&&v.indexOf("px")>-1&&(d=parseFloat(v)),{yP:d,clipped:m}}},{key:"getX1X2",value:function(c,u){var d,v=c==="x1"?u.x:u.x2,m=this.w,x=this.annoCtx.invertAxis?m.globals.minY:m.globals.minX,w=this.annoCtx.invertAxis?m.globals.maxY:m.globals.maxX,k=this.annoCtx.invertAxis?m.globals.yRange[0]:m.globals.xRange,L=!1;return d=this.annoCtx.inversedReversedAxis?(w-v)/(k/m.globals.gridWidth):(v-x)/(k/m.globals.gridWidth),m.config.xaxis.type!=="category"&&!m.config.xaxis.convertedCatToNumeric||this.annoCtx.invertAxis||m.globals.dataFormatXNumeric||m.config.chart.sparkline.enabled||(d=this.getStringX(v)),typeof v=="string"&&v.indexOf("px")>-1&&(d=parseFloat(v)),v==null&&u.marker&&(d=m.globals.gridWidth),u.seriesIndex!==void 0&&m.globals.barWidth&&!this.annoCtx.invertAxis&&(d=d-m.globals.barWidth/2*(m.globals.series.length-1)+m.globals.barWidth*u.seriesIndex),d>m.globals.gridWidth?(d=m.globals.gridWidth,L=!0):d<0&&(d=0,L=!0),{x:d,clipped:L}}},{key:"getStringX",value:function(c){var u=this.w,d=c;u.config.xaxis.convertedCatToNumeric&&u.globals.categoryLabels.length&&(c=u.globals.categoryLabels.indexOf(c)+1);var v=u.globals.labels.indexOf(c),m=u.globals.dom.baseEl.querySelector(".apexcharts-xaxis-texts-g text:nth-child("+(v+1)+")");return m&&(d=parseFloat(m.getAttribute("x"))),d}}]),Q}(),K=function(){function Q(c){a(this,Q),this.w=c.w,this.annoCtx=c,this.invertAxis=this.annoCtx.invertAxis,this.helpers=new Z(this.annoCtx)}return l(Q,[{key:"addXaxisAnnotation",value:function(c,u,d){var v,m=this.w,x=this.helpers.getX1X2("x1",c),w=x.x,k=x.clipped,L=!0,D=c.label.text,P=c.strokeDashArray;if(E.isNumber(w)){if(c.x2===null||c.x2===void 0){if(!k){var V=this.annoCtx.graphics.drawLine(w+c.offsetX,0+c.offsetY,w+c.offsetX,m.globals.gridHeight+c.offsetY,c.borderColor,P,c.borderWidth);u.appendChild(V.node),c.id&&V.node.classList.add(c.id)}}else{var N=this.helpers.getX1X2("x2",c);if(v=N.x,L=N.clipped,!k||!L){if(v12?N-12:N===0?12:N;u=(u=(u=(u=u.replace(/(^|[^\\])HH+/g,"$1"+L(N))).replace(/(^|[^\\])H/g,"$1"+N)).replace(/(^|[^\\])hh+/g,"$1"+L(j))).replace(/(^|[^\\])h/g,"$1"+j);var U=v?c.getUTCMinutes():c.getMinutes();u=(u=u.replace(/(^|[^\\])mm+/g,"$1"+L(U))).replace(/(^|[^\\])m/g,"$1"+U);var q=v?c.getUTCSeconds():c.getSeconds();u=(u=u.replace(/(^|[^\\])ss+/g,"$1"+L(q))).replace(/(^|[^\\])s/g,"$1"+q);var J=v?c.getUTCMilliseconds():c.getMilliseconds();u=u.replace(/(^|[^\\])fff+/g,"$1"+L(J,3)),J=Math.round(J/10),u=u.replace(/(^|[^\\])ff/g,"$1"+L(J)),J=Math.round(J/10);var rt=N<12?"AM":"PM";u=(u=(u=u.replace(/(^|[^\\])f/g,"$1"+J)).replace(/(^|[^\\])TT+/g,"$1"+rt)).replace(/(^|[^\\])T/g,"$1"+rt.charAt(0));var A=rt.toLowerCase();u=(u=u.replace(/(^|[^\\])tt+/g,"$1"+A)).replace(/(^|[^\\])t/g,"$1"+A.charAt(0));var O=-c.getTimezoneOffset(),X=v||!O?"Z":O>0?"+":"-";if(!v){var ot=(O=Math.abs(O))%60;X+=L(Math.floor(O/60))+":"+L(ot)}u=u.replace(/(^|[^\\])K/g,"$1"+X);var nt=(v?c.getUTCDay():c.getDay())+1;return u=(u=(u=(u=(u=u.replace(new RegExp(w[0],"g"),w[nt])).replace(new RegExp(k[0],"g"),k[nt])).replace(new RegExp(m[0],"g"),m[P])).replace(new RegExp(x[0],"g"),x[P])).replace(/\\(.)/g,"$1")}},{key:"getTimeUnitsfromTimestamp",value:function(c,u,d){var v=this.w;v.config.xaxis.min!==void 0&&(c=v.config.xaxis.min),v.config.xaxis.max!==void 0&&(u=v.config.xaxis.max);var m=this.getDate(c),x=this.getDate(u),w=this.formatDate(m,"yyyy MM dd HH mm ss fff").split(" "),k=this.formatDate(x,"yyyy MM dd HH mm ss fff").split(" ");return{minMillisecond:parseInt(w[6],10),maxMillisecond:parseInt(k[6],10),minSecond:parseInt(w[5],10),maxSecond:parseInt(k[5],10),minMinute:parseInt(w[4],10),maxMinute:parseInt(k[4],10),minHour:parseInt(w[3],10),maxHour:parseInt(k[3],10),minDate:parseInt(w[2],10),maxDate:parseInt(k[2],10),minMonth:parseInt(w[1],10)-1,maxMonth:parseInt(k[1],10)-1,minYear:parseInt(w[0],10),maxYear:parseInt(k[0],10)}}},{key:"isLeapYear",value:function(c){return c%4==0&&c%100!=0||c%400==0}},{key:"calculcateLastDaysOfMonth",value:function(c,u,d){return this.determineDaysOfMonths(c,u)-d}},{key:"determineDaysOfYear",value:function(c){var u=365;return this.isLeapYear(c)&&(u=366),u}},{key:"determineRemainingDaysOfYear",value:function(c,u,d){var v=this.daysCntOfYear[u]+d;return u>1&&this.isLeapYear()&&v++,v}},{key:"determineDaysOfMonths",value:function(c,u){var d=30;switch(c=E.monthMod(c),!0){case this.months30.indexOf(c)>-1:c===2&&(d=this.isLeapYear(u)?29:28);break;case this.months31.indexOf(c)>-1:default:d=31}return d}}]),Q}(),at=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w,this.tooltipKeyFormat="dd MMM"}return l(Q,[{key:"xLabelFormat",value:function(c,u,d,v){var m=this.w;if(m.config.xaxis.type==="datetime"&&m.config.xaxis.labels.formatter===void 0&&m.config.tooltip.x.formatter===void 0){var x=new et(this.ctx);return x.formatDate(x.getDate(u),m.config.tooltip.x.format)}return c(u,d,v)}},{key:"defaultGeneralFormatter",value:function(c){return Array.isArray(c)?c.map(function(u){return u}):c}},{key:"defaultYFormatter",value:function(c,u,d){var v=this.w;if(E.isNumber(c))if(v.globals.yValueDecimal!==0)c=c.toFixed(u.decimalsInFloat!==void 0?u.decimalsInFloat:v.globals.yValueDecimal);else{var m=c.toFixed(0);c=c==m?m:c.toFixed(1)}return c}},{key:"setLabelFormatters",value:function(){var c=this,u=this.w;return u.globals.xaxisTooltipFormatter=function(d){return c.defaultGeneralFormatter(d)},u.globals.ttKeyFormatter=function(d){return c.defaultGeneralFormatter(d)},u.globals.ttZFormatter=function(d){return d},u.globals.legendFormatter=function(d){return c.defaultGeneralFormatter(d)},u.config.xaxis.labels.formatter!==void 0?u.globals.xLabelFormatter=u.config.xaxis.labels.formatter:u.globals.xLabelFormatter=function(d){if(E.isNumber(d)){if(!u.config.xaxis.convertedCatToNumeric&&u.config.xaxis.type==="numeric"){if(E.isNumber(u.config.xaxis.decimalsInFloat))return d.toFixed(u.config.xaxis.decimalsInFloat);var v=u.globals.maxX-u.globals.minX;return v>0&&v<100?d.toFixed(1):d.toFixed(0)}return u.globals.isBarHorizontal&&u.globals.maxY-u.globals.minYArr<4?d.toFixed(1):d.toFixed(0)}return d},typeof u.config.tooltip.x.formatter=="function"?u.globals.ttKeyFormatter=u.config.tooltip.x.formatter:u.globals.ttKeyFormatter=u.globals.xLabelFormatter,typeof u.config.xaxis.tooltip.formatter=="function"&&(u.globals.xaxisTooltipFormatter=u.config.xaxis.tooltip.formatter),(Array.isArray(u.config.tooltip.y)||u.config.tooltip.y.formatter!==void 0)&&(u.globals.ttVal=u.config.tooltip.y),u.config.tooltip.z.formatter!==void 0&&(u.globals.ttZFormatter=u.config.tooltip.z.formatter),u.config.legend.formatter!==void 0&&(u.globals.legendFormatter=u.config.legend.formatter),u.config.yaxis.forEach(function(d,v){d.labels.formatter!==void 0?u.globals.yLabelFormatters[v]=d.labels.formatter:u.globals.yLabelFormatters[v]=function(m){return u.globals.xyCharts?Array.isArray(m)?m.map(function(x){return c.defaultYFormatter(x,d,v)}):c.defaultYFormatter(m,d,v):m}}),u.globals}},{key:"heatmapLabelFormatters",value:function(){var c=this.w;if(c.config.chart.type==="heatmap"){c.globals.yAxisScale[0].result=c.globals.seriesNames.slice();var u=c.globals.seriesNames.reduce(function(d,v){return d.length>v.length?d:v},0);c.globals.yAxisScale[0].niceMax=u,c.globals.yAxisScale[0].niceMin=u}}}]),Q}(),tt=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w}return l(Q,[{key:"getLabel",value:function(c,u,d,v){var m=arguments.length>4&&arguments[4]!==void 0?arguments[4]:[],x=arguments.length>5&&arguments[5]!==void 0?arguments[5]:"12px",w=!(arguments.length>6&&arguments[6]!==void 0)||arguments[6],k=this.w,L=c[v]===void 0?"":c[v],D=L,P=k.globals.xLabelFormatter,V=k.config.xaxis.labels.formatter,N=!1,j=new at(this.ctx),U=L;w&&(D=j.xLabelFormat(P,L,U,{i:v,dateFormatter:new et(this.ctx).formatDate,w:k}),V!==void 0&&(D=V(L,c[v],{i:v,dateFormatter:new et(this.ctx).formatDate,w:k})));var q,J;u.length>0?(q=u[v].unit,J=null,u.forEach(function(X){X.unit==="month"?J="year":X.unit==="day"?J="month":X.unit==="hour"?J="day":X.unit==="minute"&&(J="hour")}),N=J===q,d=u[v].position,D=u[v].value):k.config.xaxis.type==="datetime"&&V===void 0&&(D=""),D===void 0&&(D=""),D=Array.isArray(D)?D:D.toString();var rt=new $(this.ctx),A={};A=k.globals.rotateXLabels&&w?rt.getTextRects(D,parseInt(x,10),null,"rotate(".concat(k.config.xaxis.labels.rotate," 0 0)"),!1):rt.getTextRects(D,parseInt(x,10));var O=!k.config.xaxis.labels.showDuplicates&&this.ctx.timeScale;return!Array.isArray(D)&&(String(D)==="NaN"||m.indexOf(D)>=0&&O)&&(D=""),{x:d,text:D,textRect:A,isBold:N}}},{key:"checkLabelBasedOnTickamount",value:function(c,u,d){var v=this.w,m=v.config.xaxis.tickAmount;return m==="dataPoints"&&(m=Math.round(v.globals.gridWidth/120)),m>d||c%Math.round(d/(m+1))==0||(u.text=""),u}},{key:"checkForOverflowingLabels",value:function(c,u,d,v,m){var x=this.w;if(c===0&&x.globals.skipFirstTimelinelabel&&(u.text=""),c===d-1&&x.globals.skipLastTimelinelabel&&(u.text=""),x.config.xaxis.labels.hideOverlappingLabels&&v.length>0){var w=m[m.length-1];u.xv.length||v.some(function(m){return Array.isArray(m.seriesName)})?c:d.seriesYAxisReverseMap[c]}},{key:"isYAxisHidden",value:function(c){var u=this.w,d=u.config.yaxis[c];if(!d.show||this.yAxisAllSeriesCollapsed(c))return!0;if(!d.showForNullSeries){var v=u.globals.seriesYAxisMap[c],m=new G(this.ctx);return v.every(function(x){return m.isSeriesNull(x)})}return!1}},{key:"getYAxisForeColor",value:function(c,u){var d=this.w;return Array.isArray(c)&&d.globals.yAxisScale[u]&&this.ctx.theme.pushExtraColors(c,d.globals.yAxisScale[u].result.length,!1),c}},{key:"drawYAxisTicks",value:function(c,u,d,v,m,x,w){var k=this.w,L=new $(this.ctx),D=k.globals.translateY+k.config.yaxis[m].labels.offsetY;if(k.globals.isBarHorizontal?D=0:k.config.chart.type==="heatmap"&&(D+=x/2),v.show&&u>0){k.config.yaxis[m].opposite===!0&&(c+=v.width);for(var P=u;P>=0;P--){var V=L.drawLine(c+d.offsetX-v.width+v.offsetX,D+v.offsetY,c+d.offsetX+v.offsetX,D+v.offsetY,v.color);w.add(V),D+=x}}}}]),Q}(),ft=function(){function Q(c){a(this,Q),this.w=c.w,this.annoCtx=c,this.helpers=new Z(this.annoCtx),this.axesUtils=new tt(this.annoCtx)}return l(Q,[{key:"addYaxisAnnotation",value:function(c,u,d){var v,m=this.w,x=c.strokeDashArray,w=this.helpers.getY1Y2("y1",c),k=w.yP,L=w.clipped,D=!0,P=!1,V=c.label.text;if(c.y2===null||c.y2===void 0){if(!L){P=!0;var N=this.annoCtx.graphics.drawLine(0+c.offsetX,k+c.offsetY,this._getYAxisAnnotationWidth(c),k+c.offsetY,c.borderColor,x,c.borderWidth);u.appendChild(N.node),c.id&&N.node.classList.add(c.id)}}else{if(v=(w=this.helpers.getY1Y2("y2",c)).yP,D=w.clipped,v>k){var j=k;k=v,v=j}if(!L||!D){P=!0;var U=this.annoCtx.graphics.drawRect(0+c.offsetX,v+c.offsetY,this._getYAxisAnnotationWidth(c),k-v,0,c.fillColor,c.opacity,1,c.borderColor,x);U.node.classList.add("apexcharts-annotation-rect"),U.attr("clip-path","url(#gridRectMask".concat(m.globals.cuid,")")),u.appendChild(U.node),c.id&&U.node.classList.add(c.id)}}if(P){var q=c.label.position==="right"?m.globals.gridWidth:c.label.position==="center"?m.globals.gridWidth/2:0,J=this.annoCtx.graphics.drawText({x:q+c.label.offsetX,y:(v??k)+c.label.offsetY-3,text:V,textAnchor:c.label.textAnchor,fontSize:c.label.style.fontSize,fontFamily:c.label.style.fontFamily,fontWeight:c.label.style.fontWeight,foreColor:c.label.style.color,cssClass:"apexcharts-yaxis-annotation-label ".concat(c.label.style.cssClass," ").concat(c.id?c.id:"")});J.attr({rel:d}),u.appendChild(J.node)}}},{key:"_getYAxisAnnotationWidth",value:function(c){var u=this.w;return u.globals.gridWidth,(c.width.indexOf("%")>-1?u.globals.gridWidth*parseInt(c.width,10)/100:parseInt(c.width,10))+c.offsetX}},{key:"drawYAxisAnnotations",value:function(){var c=this,u=this.w,d=this.annoCtx.graphics.group({class:"apexcharts-yaxis-annotations"});return u.config.annotations.yaxis.forEach(function(v,m){v.yAxisIndex=c.axesUtils.translateYAxisIndex(v.yAxisIndex),c.axesUtils.isYAxisHidden(v.yAxisIndex)&&c.axesUtils.yAxisAllSeriesCollapsed(v.yAxisIndex)||c.addYaxisAnnotation(v,d.node,m)}),d}}]),Q}(),dt=function(){function Q(c){a(this,Q),this.w=c.w,this.annoCtx=c,this.helpers=new Z(this.annoCtx)}return l(Q,[{key:"addPointAnnotation",value:function(c,u,d){if(!(this.w.globals.collapsedSeriesIndices.indexOf(c.seriesIndex)>-1)){var v=this.helpers.getX1X2("x1",c),m=v.x,x=v.clipped,w=(v=this.helpers.getY1Y2("y1",c)).yP,k=v.clipped;if(E.isNumber(m)&&!k&&!x){var L={pSize:c.marker.size,pointStrokeWidth:c.marker.strokeWidth,pointFillColor:c.marker.fillColor,pointStrokeColor:c.marker.strokeColor,shape:c.marker.shape,pRadius:c.marker.radius,class:"apexcharts-point-annotation-marker ".concat(c.marker.cssClass," ").concat(c.id?c.id:"")},D=this.annoCtx.graphics.drawMarker(m+c.marker.offsetX,w+c.marker.offsetY,L);u.appendChild(D.node);var P=c.label.text?c.label.text:"",V=this.annoCtx.graphics.drawText({x:m+c.label.offsetX,y:w+c.label.offsetY-c.marker.size-parseFloat(c.label.style.fontSize)/1.6,text:P,textAnchor:c.label.textAnchor,fontSize:c.label.style.fontSize,fontFamily:c.label.style.fontFamily,fontWeight:c.label.style.fontWeight,foreColor:c.label.style.color,cssClass:"apexcharts-point-annotation-label ".concat(c.label.style.cssClass," ").concat(c.id?c.id:"")});if(V.attr({rel:d}),u.appendChild(V.node),c.customSVG.SVG){var N=this.annoCtx.graphics.group({class:"apexcharts-point-annotations-custom-svg "+c.customSVG.cssClass});N.attr({transform:"translate(".concat(m+c.customSVG.offsetX,", ").concat(w+c.customSVG.offsetY,")")}),N.node.innerHTML=c.customSVG.SVG,u.appendChild(N.node)}if(c.image.path){var j=c.image.width?c.image.width:20,U=c.image.height?c.image.height:20;D=this.annoCtx.addImage({x:m+c.image.offsetX-j/2,y:w+c.image.offsetY-U/2,width:j,height:U,path:c.image.path,appendTo:".apexcharts-point-annotations"})}c.mouseEnter&&D.node.addEventListener("mouseenter",c.mouseEnter.bind(this,c)),c.mouseLeave&&D.node.addEventListener("mouseleave",c.mouseLeave.bind(this,c)),c.click&&D.node.addEventListener("click",c.click.bind(this,c))}}}},{key:"drawPointAnnotations",value:function(){var c=this,u=this.w,d=this.annoCtx.graphics.group({class:"apexcharts-point-annotations"});return u.config.annotations.points.map(function(v,m){c.addPointAnnotation(v,d.node,m)}),d}}]),Q}(),ht={name:"en",options:{months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],toolbar:{exportToSVG:"Download SVG",exportToPNG:"Download PNG",exportToCSV:"Download CSV",menu:"Menu",selection:"Selection",selectionZoom:"Selection Zoom",zoomIn:"Zoom In",zoomOut:"Zoom Out",pan:"Panning",reset:"Reset Zoom"}}},lt=function(){function Q(){a(this,Q),this.yAxis={show:!0,showAlways:!1,showForNullSeries:!0,seriesName:void 0,opposite:!1,reversed:!1,logarithmic:!1,logBase:10,tickAmount:void 0,stepSize:void 0,forceNiceScale:!1,max:void 0,min:void 0,floating:!1,decimalsInFloat:void 0,labels:{show:!0,minWidth:0,maxWidth:160,offsetX:0,offsetY:0,align:void 0,rotate:0,padding:20,style:{colors:[],fontSize:"11px",fontWeight:400,fontFamily:void 0,cssClass:""},formatter:void 0},axisBorder:{show:!1,color:"#e0e0e0",width:1,offsetX:0,offsetY:0},axisTicks:{show:!1,color:"#e0e0e0",width:6,offsetX:0,offsetY:0},title:{text:void 0,rotate:-90,offsetY:0,offsetX:0,style:{color:void 0,fontSize:"11px",fontWeight:900,fontFamily:void 0,cssClass:""}},tooltip:{enabled:!1,offsetX:0},crosshairs:{show:!0,position:"front",stroke:{color:"#b6b6b6",width:1,dashArray:0}}},this.pointAnnotation={id:void 0,x:0,y:null,yAxisIndex:0,seriesIndex:void 0,mouseEnter:void 0,mouseLeave:void 0,click:void 0,marker:{size:4,fillColor:"#fff",strokeWidth:2,strokeColor:"#333",shape:"circle",offsetX:0,offsetY:0,cssClass:""},label:{borderColor:"#c2c2c2",borderWidth:1,borderRadius:2,text:void 0,textAnchor:"middle",offsetX:0,offsetY:0,mouseEnter:void 0,mouseLeave:void 0,click:void 0,style:{background:"#fff",color:void 0,fontSize:"11px",fontFamily:void 0,fontWeight:400,cssClass:"",padding:{left:5,right:5,top:2,bottom:2}}},customSVG:{SVG:void 0,cssClass:void 0,offsetX:0,offsetY:0},image:{path:void 0,width:20,height:20,offsetX:0,offsetY:0}},this.yAxisAnnotation={id:void 0,y:0,y2:null,strokeDashArray:1,fillColor:"#c2c2c2",borderColor:"#c2c2c2",borderWidth:1,opacity:.3,offsetX:0,offsetY:0,width:"100%",yAxisIndex:0,label:{borderColor:"#c2c2c2",borderWidth:1,borderRadius:2,text:void 0,textAnchor:"end",position:"right",offsetX:0,offsetY:-3,mouseEnter:void 0,mouseLeave:void 0,click:void 0,style:{background:"#fff",color:void 0,fontSize:"11px",fontFamily:void 0,fontWeight:400,cssClass:"",padding:{left:5,right:5,top:2,bottom:2}}}},this.xAxisAnnotation={id:void 0,x:0,x2:null,strokeDashArray:1,fillColor:"#c2c2c2",borderColor:"#c2c2c2",borderWidth:1,opacity:.3,offsetX:0,offsetY:0,label:{borderColor:"#c2c2c2",borderWidth:1,borderRadius:2,text:void 0,textAnchor:"middle",orientation:"vertical",position:"top",offsetX:0,offsetY:0,mouseEnter:void 0,mouseLeave:void 0,click:void 0,style:{background:"#fff",color:void 0,fontSize:"11px",fontFamily:void 0,fontWeight:400,cssClass:"",padding:{left:5,right:5,top:2,bottom:2}}}},this.text={x:0,y:0,text:"",textAnchor:"start",foreColor:void 0,fontSize:"13px",fontFamily:void 0,fontWeight:400,appendTo:".apexcharts-annotations",backgroundColor:"transparent",borderColor:"#c2c2c2",borderRadius:0,borderWidth:0,paddingLeft:4,paddingRight:4,paddingTop:2,paddingBottom:2}}return l(Q,[{key:"init",value:function(){return{annotations:{yaxis:[this.yAxisAnnotation],xaxis:[this.xAxisAnnotation],points:[this.pointAnnotation],texts:[],images:[],shapes:[]},chart:{animations:{enabled:!0,easing:"easeinout",speed:800,animateGradually:{delay:150,enabled:!0},dynamicAnimation:{enabled:!0,speed:350}},background:"",locales:[ht],defaultLocale:"en",dropShadow:{enabled:!1,enabledOnSeries:void 0,top:2,left:2,blur:4,color:"#000",opacity:.35},events:{animationEnd:void 0,beforeMount:void 0,mounted:void 0,updated:void 0,click:void 0,mouseMove:void 0,mouseLeave:void 0,xAxisLabelClick:void 0,legendClick:void 0,markerClick:void 0,selection:void 0,dataPointSelection:void 0,dataPointMouseEnter:void 0,dataPointMouseLeave:void 0,beforeZoom:void 0,beforeResetZoom:void 0,zoomed:void 0,scrolled:void 0,brushScrolled:void 0},foreColor:"#373d3f",fontFamily:"Helvetica, Arial, sans-serif",height:"auto",parentHeightOffset:15,redrawOnParentResize:!0,redrawOnWindowResize:!0,id:void 0,group:void 0,nonce:void 0,offsetX:0,offsetY:0,selection:{enabled:!1,type:"x",fill:{color:"#24292e",opacity:.1},stroke:{width:1,color:"#24292e",opacity:.4,dashArray:3},xaxis:{min:void 0,max:void 0},yaxis:{min:void 0,max:void 0}},sparkline:{enabled:!1},brush:{enabled:!1,autoScaleYaxis:!0,target:void 0,targets:void 0},stacked:!1,stackOnlyBar:!0,stackType:"normal",toolbar:{show:!0,offsetX:0,offsetY:0,tools:{download:!0,selection:!0,zoom:!0,zoomin:!0,zoomout:!0,pan:!0,reset:!0,customIcons:[]},export:{csv:{filename:void 0,columnDelimiter:",",headerCategory:"category",headerValue:"value",categoryFormatter:void 0,valueFormatter:void 0},png:{filename:void 0},svg:{filename:void 0}},autoSelected:"zoom"},type:"line",width:"100%",zoom:{enabled:!0,type:"x",autoScaleYaxis:!1,zoomedArea:{fill:{color:"#90CAF9",opacity:.4},stroke:{color:"#0D47A1",opacity:.4,width:1}}}},plotOptions:{line:{isSlopeChart:!1},area:{fillTo:"origin"},bar:{horizontal:!1,columnWidth:"70%",barHeight:"70%",distributed:!1,borderRadius:0,borderRadiusApplication:"around",borderRadiusWhenStacked:"last",rangeBarOverlap:!0,rangeBarGroupRows:!1,hideZeroBarsWhenGrouped:!1,isDumbbell:!1,dumbbellColors:void 0,isFunnel:!1,isFunnel3d:!0,colors:{ranges:[],backgroundBarColors:[],backgroundBarOpacity:1,backgroundBarRadius:0},dataLabels:{position:"top",maxItems:100,hideOverflowingLabels:!0,orientation:"horizontal",total:{enabled:!1,formatter:void 0,offsetX:0,offsetY:0,style:{color:"#373d3f",fontSize:"12px",fontFamily:void 0,fontWeight:600}}}},bubble:{zScaling:!0,minBubbleRadius:void 0,maxBubbleRadius:void 0},candlestick:{colors:{upward:"#00B746",downward:"#EF403C"},wick:{useFillColor:!0}},boxPlot:{colors:{upper:"#00E396",lower:"#008FFB"}},heatmap:{radius:2,enableShades:!0,shadeIntensity:.5,reverseNegativeShade:!1,distributed:!1,useFillColorAsStroke:!1,colorScale:{inverse:!1,ranges:[],min:void 0,max:void 0}},treemap:{enableShades:!0,shadeIntensity:.5,distributed:!1,reverseNegativeShade:!1,useFillColorAsStroke:!1,borderRadius:4,dataLabels:{format:"scale"},colorScale:{inverse:!1,ranges:[],min:void 0,max:void 0}},radialBar:{inverseOrder:!1,startAngle:0,endAngle:360,offsetX:0,offsetY:0,hollow:{margin:5,size:"50%",background:"transparent",image:void 0,imageWidth:150,imageHeight:150,imageOffsetX:0,imageOffsetY:0,imageClipped:!0,position:"front",dropShadow:{enabled:!1,top:0,left:0,blur:3,color:"#000",opacity:.5}},track:{show:!0,startAngle:void 0,endAngle:void 0,background:"#f2f2f2",strokeWidth:"97%",opacity:1,margin:5,dropShadow:{enabled:!1,top:0,left:0,blur:3,color:"#000",opacity:.5}},dataLabels:{show:!0,name:{show:!0,fontSize:"16px",fontFamily:void 0,fontWeight:600,color:void 0,offsetY:0,formatter:function(c){return c}},value:{show:!0,fontSize:"14px",fontFamily:void 0,fontWeight:400,color:void 0,offsetY:16,formatter:function(c){return c+"%"}},total:{show:!1,label:"Total",fontSize:"16px",fontWeight:600,fontFamily:void 0,color:void 0,formatter:function(c){return c.globals.seriesTotals.reduce(function(u,d){return u+d},0)/c.globals.series.length+"%"}}},barLabels:{enabled:!1,offsetX:0,offsetY:0,useSeriesColors:!0,fontFamily:void 0,fontWeight:600,fontSize:"16px",formatter:function(c){return c},onClick:void 0}},pie:{customScale:1,offsetX:0,offsetY:0,startAngle:0,endAngle:360,expandOnClick:!0,dataLabels:{offset:0,minAngleToShowLabel:10},donut:{size:"65%",background:"transparent",labels:{show:!1,name:{show:!0,fontSize:"16px",fontFamily:void 0,fontWeight:600,color:void 0,offsetY:-10,formatter:function(c){return c}},value:{show:!0,fontSize:"20px",fontFamily:void 0,fontWeight:400,color:void 0,offsetY:10,formatter:function(c){return c}},total:{show:!1,showAlways:!1,label:"Total",fontSize:"16px",fontWeight:400,fontFamily:void 0,color:void 0,formatter:function(c){return c.globals.seriesTotals.reduce(function(u,d){return u+d},0)}}}}},polarArea:{rings:{strokeWidth:1,strokeColor:"#e8e8e8"},spokes:{strokeWidth:1,connectorColors:"#e8e8e8"}},radar:{size:void 0,offsetX:0,offsetY:0,polygons:{strokeWidth:1,strokeColors:"#e8e8e8",connectorColors:"#e8e8e8",fill:{colors:void 0}}}},colors:void 0,dataLabels:{enabled:!0,enabledOnSeries:void 0,formatter:function(c){return c!==null?c:""},textAnchor:"middle",distributed:!1,offsetX:0,offsetY:0,style:{fontSize:"12px",fontFamily:void 0,fontWeight:600,colors:void 0},background:{enabled:!0,foreColor:"#fff",borderRadius:2,padding:4,opacity:.9,borderWidth:1,borderColor:"#fff",dropShadow:{enabled:!1,top:1,left:1,blur:1,color:"#000",opacity:.45}},dropShadow:{enabled:!1,top:1,left:1,blur:1,color:"#000",opacity:.45}},fill:{type:"solid",colors:void 0,opacity:.85,gradient:{shade:"dark",type:"horizontal",shadeIntensity:.5,gradientToColors:void 0,inverseColors:!0,opacityFrom:1,opacityTo:1,stops:[0,50,100],colorStops:[]},image:{src:[],width:void 0,height:void 0},pattern:{style:"squares",width:6,height:6,strokeWidth:2}},forecastDataPoints:{count:0,fillOpacity:.5,strokeWidth:void 0,dashArray:4},grid:{show:!0,borderColor:"#e0e0e0",strokeDashArray:0,position:"back",xaxis:{lines:{show:!1}},yaxis:{lines:{show:!0}},row:{colors:void 0,opacity:.5},column:{colors:void 0,opacity:.5},padding:{top:0,right:10,bottom:0,left:12}},labels:[],legend:{show:!0,showForSingleSeries:!1,showForNullSeries:!0,showForZeroSeries:!0,floating:!1,position:"bottom",horizontalAlign:"center",inverseOrder:!1,fontSize:"12px",fontFamily:void 0,fontWeight:400,width:void 0,height:void 0,formatter:void 0,tooltipHoverFormatter:void 0,offsetX:-20,offsetY:4,customLegendItems:[],labels:{colors:void 0,useSeriesColors:!1},markers:{size:7,fillColors:void 0,strokeWidth:1,shape:void 0,offsetX:0,offsetY:0,customHTML:void 0,onClick:void 0},itemMargin:{horizontal:5,vertical:4},onItemClick:{toggleDataSeries:!0},onItemHover:{highlightDataSeries:!0}},markers:{discrete:[],size:0,colors:void 0,strokeColors:"#fff",strokeWidth:2,strokeOpacity:.9,strokeDashArray:0,fillOpacity:1,shape:"circle",offsetX:0,offsetY:0,showNullDataPoints:!0,onClick:void 0,onDblClick:void 0,hover:{size:void 0,sizeOffset:3}},noData:{text:void 0,align:"center",verticalAlign:"middle",offsetX:0,offsetY:0,style:{color:void 0,fontSize:"14px",fontFamily:void 0}},responsive:[],series:void 0,states:{normal:{filter:{type:"none",value:0}},hover:{filter:{type:"lighten",value:.1}},active:{allowMultipleDataPointsSelection:!1,filter:{type:"darken",value:.5}}},title:{text:void 0,align:"left",margin:5,offsetX:0,offsetY:0,floating:!1,style:{fontSize:"14px",fontWeight:900,fontFamily:void 0,color:void 0}},subtitle:{text:void 0,align:"left",margin:5,offsetX:0,offsetY:30,floating:!1,style:{fontSize:"12px",fontWeight:400,fontFamily:void 0,color:void 0}},stroke:{show:!0,curve:"smooth",lineCap:"butt",width:2,colors:void 0,dashArray:0,fill:{type:"solid",colors:void 0,opacity:.85,gradient:{shade:"dark",type:"horizontal",shadeIntensity:.5,gradientToColors:void 0,inverseColors:!0,opacityFrom:1,opacityTo:1,stops:[0,50,100],colorStops:[]}}},tooltip:{enabled:!0,enabledOnSeries:void 0,shared:!0,hideEmptySeries:!1,followCursor:!1,intersect:!1,inverseOrder:!1,custom:void 0,fillSeriesColor:!1,theme:"light",cssClass:"",style:{fontSize:"12px",fontFamily:void 0},onDatasetHover:{highlightDataSeries:!1},x:{show:!0,format:"dd MMM",formatter:void 0},y:{formatter:void 0,title:{formatter:function(c){return c?c+": ":""}}},z:{formatter:void 0,title:"Size: "},marker:{show:!0,fillColors:void 0},items:{display:"flex"},fixed:{enabled:!1,position:"topRight",offsetX:0,offsetY:0}},xaxis:{type:"category",categories:[],convertedCatToNumeric:!1,offsetX:0,offsetY:0,overwriteCategories:void 0,labels:{show:!0,rotate:-45,rotateAlways:!1,hideOverlappingLabels:!0,trim:!1,minHeight:void 0,maxHeight:120,showDuplicates:!0,style:{colors:[],fontSize:"12px",fontWeight:400,fontFamily:void 0,cssClass:""},offsetX:0,offsetY:0,format:void 0,formatter:void 0,datetimeUTC:!0,datetimeFormatter:{year:"yyyy",month:"MMM 'yy",day:"dd MMM",hour:"HH:mm",minute:"HH:mm:ss",second:"HH:mm:ss"}},group:{groups:[],style:{colors:[],fontSize:"12px",fontWeight:400,fontFamily:void 0,cssClass:""}},axisBorder:{show:!0,color:"#e0e0e0",width:"100%",height:1,offsetX:0,offsetY:0},axisTicks:{show:!0,color:"#e0e0e0",height:6,offsetX:0,offsetY:0},stepSize:void 0,tickAmount:void 0,tickPlacement:"on",min:void 0,max:void 0,range:void 0,floating:!1,decimalsInFloat:void 0,position:"bottom",title:{text:void 0,offsetX:0,offsetY:0,style:{color:void 0,fontSize:"12px",fontWeight:900,fontFamily:void 0,cssClass:""}},crosshairs:{show:!0,width:1,position:"back",opacity:.9,stroke:{color:"#b6b6b6",width:1,dashArray:3},fill:{type:"solid",color:"#B1B9C4",gradient:{colorFrom:"#D8E3F0",colorTo:"#BED1E6",stops:[0,100],opacityFrom:.4,opacityTo:.5}},dropShadow:{enabled:!1,left:0,top:0,blur:1,opacity:.4}},tooltip:{enabled:!0,offsetY:0,formatter:void 0,style:{fontSize:"12px",fontFamily:void 0}}},yaxis:this.yAxis,theme:{mode:"",palette:"palette1",monochrome:{enabled:!1,color:"#008FFB",shadeTo:"light",shadeIntensity:.65}}}}}]),Q}(),yt=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w,this.graphics=new $(this.ctx),this.w.globals.isBarHorizontal&&(this.invertAxis=!0),this.helpers=new Z(this),this.xAxisAnnotations=new K(this),this.yAxisAnnotations=new ft(this),this.pointsAnnotations=new dt(this),this.w.globals.isBarHorizontal&&this.w.config.yaxis[0].reversed&&(this.inversedReversedAxis=!0),this.xDivision=this.w.globals.gridWidth/this.w.globals.dataPoints}return l(Q,[{key:"drawAxesAnnotations",value:function(){var c=this.w;if(c.globals.axisCharts){for(var u=this.yAxisAnnotations.drawYAxisAnnotations(),d=this.xAxisAnnotations.drawXAxisAnnotations(),v=this.pointsAnnotations.drawPointAnnotations(),m=c.config.chart.animations.enabled,x=[u,d,v],w=[d.node,u.node,v.node],k=0;k<3;k++)c.globals.dom.elGraphical.add(x[k]),!m||c.globals.resized||c.globals.dataChanged||c.config.chart.type!=="scatter"&&c.config.chart.type!=="bubble"&&c.globals.dataPoints>1&&w[k].classList.add("apexcharts-element-hidden"),c.globals.delayedElements.push({el:w[k],index:0});this.helpers.annotationsBackground()}}},{key:"drawImageAnnos",value:function(){var c=this;this.w.config.annotations.images.map(function(u,d){c.addImage(u,d)})}},{key:"drawTextAnnos",value:function(){var c=this;this.w.config.annotations.texts.map(function(u,d){c.addText(u,d)})}},{key:"addXaxisAnnotation",value:function(c,u,d){this.xAxisAnnotations.addXaxisAnnotation(c,u,d)}},{key:"addYaxisAnnotation",value:function(c,u,d){this.yAxisAnnotations.addYaxisAnnotation(c,u,d)}},{key:"addPointAnnotation",value:function(c,u,d){this.pointsAnnotations.addPointAnnotation(c,u,d)}},{key:"addText",value:function(c,u){var d=c.x,v=c.y,m=c.text,x=c.textAnchor,w=c.foreColor,k=c.fontSize,L=c.fontFamily,D=c.fontWeight,P=c.cssClass,V=c.backgroundColor,N=c.borderWidth,j=c.strokeDashArray,U=c.borderRadius,q=c.borderColor,J=c.appendTo,rt=J===void 0?".apexcharts-svg":J,A=c.paddingLeft,O=A===void 0?4:A,X=c.paddingRight,ot=X===void 0?4:X,nt=c.paddingBottom,ct=nt===void 0?2:nt,Ct=c.paddingTop,xt=Ct===void 0?2:Ct,$t=this.w,re=this.graphics.drawText({x:d,y:v,text:m,textAnchor:x||"start",fontSize:k||"12px",fontWeight:D||"regular",fontFamily:L||$t.config.chart.fontFamily,foreColor:w||$t.config.chart.foreColor,cssClass:P}),Ot=$t.globals.dom.baseEl.querySelector(rt);Ot&&Ot.appendChild(re.node);var Qt=re.bbox();if(m){var Me=this.graphics.drawRect(Qt.x-O,Qt.y-xt,Qt.width+O+ot,Qt.height+ct+xt,U,V||"transparent",1,N,q,j);Ot.insertBefore(Me.node,re.node)}}},{key:"addImage",value:function(c,u){var d=this.w,v=c.path,m=c.x,x=m===void 0?0:m,w=c.y,k=w===void 0?0:w,L=c.width,D=L===void 0?20:L,P=c.height,V=P===void 0?20:P,N=c.appendTo,j=N===void 0?".apexcharts-svg":N,U=d.globals.dom.Paper.image(v);U.size(D,V).move(x,k);var q=d.globals.dom.baseEl.querySelector(j);return q&&q.appendChild(U.node),U}},{key:"addXaxisAnnotationExternal",value:function(c,u,d){return this.addAnnotationExternal({params:c,pushToMemory:u,context:d,type:"xaxis",contextMethod:d.addXaxisAnnotation}),d}},{key:"addYaxisAnnotationExternal",value:function(c,u,d){return this.addAnnotationExternal({params:c,pushToMemory:u,context:d,type:"yaxis",contextMethod:d.addYaxisAnnotation}),d}},{key:"addPointAnnotationExternal",value:function(c,u,d){return this.invertAxis===void 0&&(this.invertAxis=d.w.globals.isBarHorizontal),this.addAnnotationExternal({params:c,pushToMemory:u,context:d,type:"point",contextMethod:d.addPointAnnotation}),d}},{key:"addAnnotationExternal",value:function(c){var u=c.params,d=c.pushToMemory,v=c.context,m=c.type,x=c.contextMethod,w=v,k=w.w,L=k.globals.dom.baseEl.querySelector(".apexcharts-".concat(m,"-annotations")),D=L.childNodes.length+1,P=new lt,V=Object.assign({},m==="xaxis"?P.xAxisAnnotation:m==="yaxis"?P.yAxisAnnotation:P.pointAnnotation),N=E.extend(V,u);switch(m){case"xaxis":this.addXaxisAnnotation(N,L,D);break;case"yaxis":this.addYaxisAnnotation(N,L,D);break;case"point":this.addPointAnnotation(N,L,D)}var j=k.globals.dom.baseEl.querySelector(".apexcharts-".concat(m,"-annotations .apexcharts-").concat(m,"-annotation-label[rel='").concat(D,"']")),U=this.helpers.addBackgroundToAnno(j,N);return U&&L.insertBefore(U.node,j),d&&k.globals.memory.methodsToExec.push({context:w,id:N.id?N.id:E.randomId(),method:x,label:"addAnnotation",params:u}),v}},{key:"clearAnnotations",value:function(c){var u=c.w,d=u.globals.dom.baseEl.querySelectorAll(".apexcharts-yaxis-annotations, .apexcharts-xaxis-annotations, .apexcharts-point-annotations");u.globals.memory.methodsToExec.map(function(v,m){v.label!=="addText"&&v.label!=="addAnnotation"||u.globals.memory.methodsToExec.splice(m,1)}),d=E.listToArray(d),Array.prototype.forEach.call(d,function(v){for(;v.firstChild;)v.removeChild(v.firstChild)})}},{key:"removeAnnotation",value:function(c,u){var d=c.w,v=d.globals.dom.baseEl.querySelectorAll(".".concat(u));v&&(d.globals.memory.methodsToExec.map(function(m,x){m.id===u&&d.globals.memory.methodsToExec.splice(x,1)}),Array.prototype.forEach.call(v,function(m){m.parentElement.removeChild(m)}))}}]),Q}(),mt=function(Q){var c,u=Q.isTimeline,d=Q.ctx,v=Q.seriesIndex,m=Q.dataPointIndex,x=Q.y1,w=Q.y2,k=Q.w,L=k.globals.seriesRangeStart[v][m],D=k.globals.seriesRangeEnd[v][m],P=k.globals.labels[m],V=k.config.series[v].name?k.config.series[v].name:"",N=k.globals.ttKeyFormatter,j=k.config.tooltip.y.title.formatter,U={w:k,seriesIndex:v,dataPointIndex:m,start:L,end:D};typeof j=="function"&&(V=j(V,U)),(c=k.config.series[v].data[m])!==null&&c!==void 0&&c.x&&(P=k.config.series[v].data[m].x),u||k.config.xaxis.type==="datetime"&&(P=new at(d).xLabelFormat(k.globals.ttKeyFormatter,P,P,{i:void 0,dateFormatter:new et(d).formatDate,w:k})),typeof N=="function"&&(P=N(P,U)),Number.isFinite(x)&&Number.isFinite(w)&&(L=x,D=w);var q="",J="",rt=k.globals.colors[v];if(k.config.tooltip.x.formatter===void 0)if(k.config.xaxis.type==="datetime"){var A=new et(d);q=A.formatDate(A.getDate(L),k.config.tooltip.x.format),J=A.formatDate(A.getDate(D),k.config.tooltip.x.format)}else q=L,J=D;else q=k.config.tooltip.x.formatter(L),J=k.config.tooltip.x.formatter(D);return{start:L,end:D,startVal:q,endVal:J,ylabel:P,color:rt,seriesName:V}},gt=function(Q){var c=Q.color,u=Q.seriesName,d=Q.ylabel,v=Q.start,m=Q.end,x=Q.seriesIndex,w=Q.dataPointIndex,k=Q.ctx.tooltip.tooltipLabels.getFormatters(x);v=k.yLbFormatter(v),m=k.yLbFormatter(m);var L=k.yLbFormatter(Q.w.globals.series[x][w]),D=` `.concat(v,` - `).concat(m,` - `);return'
'+(u||"")+'
'+d+": "+(Q.w.globals.comboCharts?Q.w.config.series[x].type==="rangeArea"||Q.w.config.series[x].type==="rangeBar"?D:"".concat(L,""):D)+"
"},kt=function(){function Q(c){a(this,Q),this.opts=c}return l(Q,[{key:"hideYAxis",value:function(){this.opts.yaxis[0].show=!1,this.opts.yaxis[0].title.text="",this.opts.yaxis[0].axisBorder.show=!1,this.opts.yaxis[0].axisTicks.show=!1,this.opts.yaxis[0].floating=!0}},{key:"line",value:function(){return{chart:{animations:{easing:"swing"}},dataLabels:{enabled:!1},stroke:{width:5,curve:"straight"},markers:{size:0,hover:{sizeOffset:6}},xaxis:{crosshairs:{width:1}}}}},{key:"sparkline",value:function(c){return this.hideYAxis(),E.extend(c,{grid:{show:!1,padding:{left:0,right:0,top:0,bottom:0}},legend:{show:!1},xaxis:{labels:{show:!1},tooltip:{enabled:!1},axisBorder:{show:!1},axisTicks:{show:!1}},chart:{toolbar:{show:!1},zoom:{enabled:!1}},dataLabels:{enabled:!1}})}},{key:"slope",value:function(){return this.hideYAxis(),{chart:{toolbar:{show:!1},zoom:{enabled:!1}},dataLabels:{enabled:!0,formatter:function(c,u){var d=u.w.config.series[u.seriesIndex].name;return c!==null?d+": "+c:""},background:{enabled:!1},offsetX:-5},grid:{xaxis:{lines:{show:!0}},yaxis:{lines:{show:!1}}},xaxis:{position:"top",labels:{style:{fontSize:14,fontWeight:900}},tooltip:{enabled:!1},crosshairs:{show:!1}},markers:{size:8,hover:{sizeOffset:1}},legend:{show:!1},tooltip:{shared:!1,intersect:!0,followCursor:!0},stroke:{width:5,curve:"straight"}}}},{key:"bar",value:function(){return{chart:{stacked:!1,animations:{easing:"swing"}},plotOptions:{bar:{dataLabels:{position:"center"}}},dataLabels:{style:{colors:["#fff"]},background:{enabled:!1}},stroke:{width:0,lineCap:"round"},fill:{opacity:.85},legend:{markers:{shape:"square"}},tooltip:{shared:!1,intersect:!0},xaxis:{tooltip:{enabled:!1},tickPlacement:"between",crosshairs:{width:"barWidth",position:"back",fill:{type:"gradient"},dropShadow:{enabled:!1},stroke:{width:0}}}}}},{key:"funnel",value:function(){return this.hideYAxis(),i(i({},this.bar()),{},{chart:{animations:{easing:"linear",speed:800,animateGradually:{enabled:!1}}},plotOptions:{bar:{horizontal:!0,borderRadiusApplication:"around",borderRadius:0,dataLabels:{position:"center"}}},grid:{show:!1,padding:{left:0,right:0}},xaxis:{labels:{show:!1},tooltip:{enabled:!1},axisBorder:{show:!1},axisTicks:{show:!1}}})}},{key:"candlestick",value:function(){var c=this;return{stroke:{width:1,colors:["#333"]},fill:{opacity:1},dataLabels:{enabled:!1},tooltip:{shared:!0,custom:function(u){var d=u.seriesIndex,v=u.dataPointIndex,m=u.w;return c._getBoxTooltip(m,d,v,["Open","High","","Low","Close"],"candlestick")}},states:{active:{filter:{type:"none"}}},xaxis:{crosshairs:{width:1}}}}},{key:"boxPlot",value:function(){var c=this;return{chart:{animations:{dynamicAnimation:{enabled:!1}}},stroke:{width:1,colors:["#24292e"]},dataLabels:{enabled:!1},tooltip:{shared:!0,custom:function(u){var d=u.seriesIndex,v=u.dataPointIndex,m=u.w;return c._getBoxTooltip(m,d,v,["Minimum","Q1","Median","Q3","Maximum"],"boxPlot")}},markers:{size:7,strokeWidth:1,strokeColors:"#111"},xaxis:{crosshairs:{width:1}}}}},{key:"rangeBar",value:function(){return{chart:{animations:{animateGradually:!1}},stroke:{width:0,lineCap:"square"},plotOptions:{bar:{borderRadius:0,dataLabels:{position:"center"}}},dataLabels:{enabled:!1,formatter:function(c,u){u.ctx;var d=u.seriesIndex,v=u.dataPointIndex,m=u.w,x=function(){var w=m.globals.seriesRangeStart[d][v];return m.globals.seriesRangeEnd[d][v]-w};return m.globals.comboCharts?m.config.series[d].type==="rangeBar"||m.config.series[d].type==="rangeArea"?x():c:x()},background:{enabled:!1},style:{colors:["#fff"]}},markers:{size:10},tooltip:{shared:!1,followCursor:!0,custom:function(c){return c.w.config.plotOptions&&c.w.config.plotOptions.bar&&c.w.config.plotOptions.bar.horizontal?function(u){var d=mt(i(i({},u),{},{isTimeline:!0})),v=d.color,m=d.seriesName,x=d.ylabel,w=d.startVal,k=d.endVal;return gt(i(i({},u),{},{color:v,seriesName:m,ylabel:x,start:w,end:k}))}(c):function(u){var d=mt(u),v=d.color,m=d.seriesName,x=d.ylabel,w=d.start,k=d.end;return gt(i(i({},u),{},{color:v,seriesName:m,ylabel:x,start:w,end:k}))}(c)}},xaxis:{tickPlacement:"between",tooltip:{enabled:!1},crosshairs:{stroke:{width:0}}}}}},{key:"dumbbell",value:function(c){var u,d;return(u=c.plotOptions.bar)!==null&&u!==void 0&&u.barHeight||(c.plotOptions.bar.barHeight=2),(d=c.plotOptions.bar)!==null&&d!==void 0&&d.columnWidth||(c.plotOptions.bar.columnWidth=2),c}},{key:"area",value:function(){return{stroke:{width:4,fill:{type:"solid",gradient:{inverseColors:!1,shade:"light",type:"vertical",opacityFrom:.65,opacityTo:.5,stops:[0,100,100]}}},fill:{type:"gradient",gradient:{inverseColors:!1,shade:"light",type:"vertical",opacityFrom:.65,opacityTo:.5,stops:[0,100,100]}},markers:{size:0,hover:{sizeOffset:6}},tooltip:{followCursor:!1}}}},{key:"rangeArea",value:function(){return{stroke:{curve:"straight",width:0},fill:{type:"solid",opacity:.6},markers:{size:0},states:{hover:{filter:{type:"none"}},active:{filter:{type:"none"}}},tooltip:{intersect:!1,shared:!0,followCursor:!0,custom:function(c){return function(u){var d=mt(u),v=d.color,m=d.seriesName,x=d.ylabel,w=d.start,k=d.end;return gt(i(i({},u),{},{color:v,seriesName:m,ylabel:x,start:w,end:k}))}(c)}}}}},{key:"brush",value:function(c){return E.extend(c,{chart:{toolbar:{autoSelected:"selection",show:!1},zoom:{enabled:!1}},dataLabels:{enabled:!1},stroke:{width:1},tooltip:{enabled:!1},xaxis:{tooltip:{enabled:!1}}})}},{key:"stacked100",value:function(c){c.dataLabels=c.dataLabels||{},c.dataLabels.formatter=c.dataLabels.formatter||void 0;var u=c.dataLabels.formatter;return c.yaxis.forEach(function(d,v){c.yaxis[v].min=0,c.yaxis[v].max=100}),c.chart.type==="bar"&&(c.dataLabels.formatter=u||function(d){return typeof d=="number"&&d?d.toFixed(0)+"%":d}),c}},{key:"stackedBars",value:function(){var c=this.bar();return i(i({},c),{},{plotOptions:i(i({},c.plotOptions),{},{bar:i(i({},c.plotOptions.bar),{},{borderRadiusApplication:"end",borderRadiusWhenStacked:"last"})})})}},{key:"convertCatToNumeric",value:function(c){return c.xaxis.convertedCatToNumeric=!0,c}},{key:"convertCatToNumericXaxis",value:function(c,u,d){c.xaxis.type="numeric",c.xaxis.labels=c.xaxis.labels||{},c.xaxis.labels.formatter=c.xaxis.labels.formatter||function(x){return E.isNumber(x)?Math.floor(x):x};var v=c.xaxis.labels.formatter,m=c.xaxis.categories&&c.xaxis.categories.length?c.xaxis.categories:c.labels;return d&&d.length&&(m=d.map(function(x){return Array.isArray(x)?x:String(x)})),m&&m.length&&(c.xaxis.labels.formatter=function(x){return E.isNumber(x)?v(m[Math.floor(x)-1]):v(x)}),c.xaxis.categories=[],c.labels=[],c.xaxis.tickAmount=c.xaxis.tickAmount||"dataPoints",c}},{key:"bubble",value:function(){return{dataLabels:{style:{colors:["#fff"]}},tooltip:{shared:!1,intersect:!0},xaxis:{crosshairs:{width:0}},fill:{type:"solid",gradient:{shade:"light",inverse:!0,shadeIntensity:.55,opacityFrom:.4,opacityTo:.8}}}}},{key:"scatter",value:function(){return{dataLabels:{enabled:!1},tooltip:{shared:!1,intersect:!0},markers:{size:6,strokeWidth:1,hover:{sizeOffset:2}}}}},{key:"heatmap",value:function(){return{chart:{stacked:!1},fill:{opacity:1},dataLabels:{style:{colors:["#fff"]}},stroke:{colors:["#fff"]},tooltip:{followCursor:!0,marker:{show:!1},x:{show:!1}},legend:{position:"top",markers:{shape:"square"}},grid:{padding:{right:20}}}}},{key:"treemap",value:function(){return{chart:{zoom:{enabled:!1}},dataLabels:{style:{fontSize:14,fontWeight:600,colors:["#fff"]}},stroke:{show:!0,width:2,colors:["#fff"]},legend:{show:!1},fill:{opacity:1,gradient:{stops:[0,100]}},tooltip:{followCursor:!0,x:{show:!1}},grid:{padding:{left:0,right:0}},xaxis:{crosshairs:{show:!1},tooltip:{enabled:!1}}}}},{key:"pie",value:function(){return{chart:{toolbar:{show:!1}},plotOptions:{pie:{donut:{labels:{show:!1}}}},dataLabels:{formatter:function(c){return c.toFixed(1)+"%"},style:{colors:["#fff"]},background:{enabled:!1},dropShadow:{enabled:!0}},stroke:{colors:["#fff"]},fill:{opacity:1,gradient:{shade:"light",stops:[0,100]}},tooltip:{theme:"dark",fillSeriesColor:!0},legend:{position:"right"}}}},{key:"donut",value:function(){return{chart:{toolbar:{show:!1}},dataLabels:{formatter:function(c){return c.toFixed(1)+"%"},style:{colors:["#fff"]},background:{enabled:!1},dropShadow:{enabled:!0}},stroke:{colors:["#fff"]},fill:{opacity:1,gradient:{shade:"light",shadeIntensity:.35,stops:[80,100],opacityFrom:1,opacityTo:1}},tooltip:{theme:"dark",fillSeriesColor:!0},legend:{position:"right"}}}},{key:"polarArea",value:function(){return{chart:{toolbar:{show:!1}},dataLabels:{formatter:function(c){return c.toFixed(1)+"%"},enabled:!1},stroke:{show:!0,width:2},fill:{opacity:.7},tooltip:{theme:"dark",fillSeriesColor:!0},legend:{position:"right"}}}},{key:"radar",value:function(){return this.opts.yaxis[0].labels.offsetY=this.opts.yaxis[0].labels.offsetY?this.opts.yaxis[0].labels.offsetY:6,{dataLabels:{enabled:!1,style:{fontSize:"11px"}},stroke:{width:2},markers:{size:5,strokeWidth:1,strokeOpacity:1},fill:{opacity:.2},tooltip:{shared:!1,intersect:!0,followCursor:!0},grid:{show:!1},xaxis:{labels:{formatter:function(c){return c},style:{colors:["#a8a8a8"],fontSize:"11px"}},tooltip:{enabled:!1},crosshairs:{show:!1}}}}},{key:"radialBar",value:function(){return{chart:{animations:{dynamicAnimation:{enabled:!0,speed:800}},toolbar:{show:!1}},fill:{gradient:{shade:"dark",shadeIntensity:.4,inverseColors:!1,type:"diagonal2",opacityFrom:1,opacityTo:1,stops:[70,98,100]}},legend:{show:!1,position:"right"},tooltip:{enabled:!1,fillSeriesColor:!0}}}},{key:"_getBoxTooltip",value:function(c,u,d,v,m){var x=c.globals.seriesCandleO[u][d],w=c.globals.seriesCandleH[u][d],k=c.globals.seriesCandleM[u][d],L=c.globals.seriesCandleL[u][d],D=c.globals.seriesCandleC[u][d];return c.config.series[u].type&&c.config.series[u].type!==m?`
+ `);return'
'+(u||"")+'
'+d+": "+(Q.w.globals.comboCharts?Q.w.config.series[x].type==="rangeArea"||Q.w.config.series[x].type==="rangeBar"?D:"".concat(L,""):D)+"
"},_t=function(){function Q(c){a(this,Q),this.opts=c}return l(Q,[{key:"hideYAxis",value:function(){this.opts.yaxis[0].show=!1,this.opts.yaxis[0].title.text="",this.opts.yaxis[0].axisBorder.show=!1,this.opts.yaxis[0].axisTicks.show=!1,this.opts.yaxis[0].floating=!0}},{key:"line",value:function(){return{chart:{animations:{easing:"swing"}},dataLabels:{enabled:!1},stroke:{width:5,curve:"straight"},markers:{size:0,hover:{sizeOffset:6}},xaxis:{crosshairs:{width:1}}}}},{key:"sparkline",value:function(c){return this.hideYAxis(),E.extend(c,{grid:{show:!1,padding:{left:0,right:0,top:0,bottom:0}},legend:{show:!1},xaxis:{labels:{show:!1},tooltip:{enabled:!1},axisBorder:{show:!1},axisTicks:{show:!1}},chart:{toolbar:{show:!1},zoom:{enabled:!1}},dataLabels:{enabled:!1}})}},{key:"slope",value:function(){return this.hideYAxis(),{chart:{toolbar:{show:!1},zoom:{enabled:!1}},dataLabels:{enabled:!0,formatter:function(c,u){var d=u.w.config.series[u.seriesIndex].name;return c!==null?d+": "+c:""},background:{enabled:!1},offsetX:-5},grid:{xaxis:{lines:{show:!0}},yaxis:{lines:{show:!1}}},xaxis:{position:"top",labels:{style:{fontSize:14,fontWeight:900}},tooltip:{enabled:!1},crosshairs:{show:!1}},markers:{size:8,hover:{sizeOffset:1}},legend:{show:!1},tooltip:{shared:!1,intersect:!0,followCursor:!0},stroke:{width:5,curve:"straight"}}}},{key:"bar",value:function(){return{chart:{stacked:!1,animations:{easing:"swing"}},plotOptions:{bar:{dataLabels:{position:"center"}}},dataLabels:{style:{colors:["#fff"]},background:{enabled:!1}},stroke:{width:0,lineCap:"round"},fill:{opacity:.85},legend:{markers:{shape:"square"}},tooltip:{shared:!1,intersect:!0},xaxis:{tooltip:{enabled:!1},tickPlacement:"between",crosshairs:{width:"barWidth",position:"back",fill:{type:"gradient"},dropShadow:{enabled:!1},stroke:{width:0}}}}}},{key:"funnel",value:function(){return this.hideYAxis(),i(i({},this.bar()),{},{chart:{animations:{easing:"linear",speed:800,animateGradually:{enabled:!1}}},plotOptions:{bar:{horizontal:!0,borderRadiusApplication:"around",borderRadius:0,dataLabels:{position:"center"}}},grid:{show:!1,padding:{left:0,right:0}},xaxis:{labels:{show:!1},tooltip:{enabled:!1},axisBorder:{show:!1},axisTicks:{show:!1}}})}},{key:"candlestick",value:function(){var c=this;return{stroke:{width:1,colors:["#333"]},fill:{opacity:1},dataLabels:{enabled:!1},tooltip:{shared:!0,custom:function(u){var d=u.seriesIndex,v=u.dataPointIndex,m=u.w;return c._getBoxTooltip(m,d,v,["Open","High","","Low","Close"],"candlestick")}},states:{active:{filter:{type:"none"}}},xaxis:{crosshairs:{width:1}}}}},{key:"boxPlot",value:function(){var c=this;return{chart:{animations:{dynamicAnimation:{enabled:!1}}},stroke:{width:1,colors:["#24292e"]},dataLabels:{enabled:!1},tooltip:{shared:!0,custom:function(u){var d=u.seriesIndex,v=u.dataPointIndex,m=u.w;return c._getBoxTooltip(m,d,v,["Minimum","Q1","Median","Q3","Maximum"],"boxPlot")}},markers:{size:7,strokeWidth:1,strokeColors:"#111"},xaxis:{crosshairs:{width:1}}}}},{key:"rangeBar",value:function(){return{chart:{animations:{animateGradually:!1}},stroke:{width:0,lineCap:"square"},plotOptions:{bar:{borderRadius:0,dataLabels:{position:"center"}}},dataLabels:{enabled:!1,formatter:function(c,u){u.ctx;var d=u.seriesIndex,v=u.dataPointIndex,m=u.w,x=function(){var w=m.globals.seriesRangeStart[d][v];return m.globals.seriesRangeEnd[d][v]-w};return m.globals.comboCharts?m.config.series[d].type==="rangeBar"||m.config.series[d].type==="rangeArea"?x():c:x()},background:{enabled:!1},style:{colors:["#fff"]}},markers:{size:10},tooltip:{shared:!1,followCursor:!0,custom:function(c){return c.w.config.plotOptions&&c.w.config.plotOptions.bar&&c.w.config.plotOptions.bar.horizontal?function(u){var d=mt(i(i({},u),{},{isTimeline:!0})),v=d.color,m=d.seriesName,x=d.ylabel,w=d.startVal,k=d.endVal;return gt(i(i({},u),{},{color:v,seriesName:m,ylabel:x,start:w,end:k}))}(c):function(u){var d=mt(u),v=d.color,m=d.seriesName,x=d.ylabel,w=d.start,k=d.end;return gt(i(i({},u),{},{color:v,seriesName:m,ylabel:x,start:w,end:k}))}(c)}},xaxis:{tickPlacement:"between",tooltip:{enabled:!1},crosshairs:{stroke:{width:0}}}}}},{key:"dumbbell",value:function(c){var u,d;return(u=c.plotOptions.bar)!==null&&u!==void 0&&u.barHeight||(c.plotOptions.bar.barHeight=2),(d=c.plotOptions.bar)!==null&&d!==void 0&&d.columnWidth||(c.plotOptions.bar.columnWidth=2),c}},{key:"area",value:function(){return{stroke:{width:4,fill:{type:"solid",gradient:{inverseColors:!1,shade:"light",type:"vertical",opacityFrom:.65,opacityTo:.5,stops:[0,100,100]}}},fill:{type:"gradient",gradient:{inverseColors:!1,shade:"light",type:"vertical",opacityFrom:.65,opacityTo:.5,stops:[0,100,100]}},markers:{size:0,hover:{sizeOffset:6}},tooltip:{followCursor:!1}}}},{key:"rangeArea",value:function(){return{stroke:{curve:"straight",width:0},fill:{type:"solid",opacity:.6},markers:{size:0},states:{hover:{filter:{type:"none"}},active:{filter:{type:"none"}}},tooltip:{intersect:!1,shared:!0,followCursor:!0,custom:function(c){return function(u){var d=mt(u),v=d.color,m=d.seriesName,x=d.ylabel,w=d.start,k=d.end;return gt(i(i({},u),{},{color:v,seriesName:m,ylabel:x,start:w,end:k}))}(c)}}}}},{key:"brush",value:function(c){return E.extend(c,{chart:{toolbar:{autoSelected:"selection",show:!1},zoom:{enabled:!1}},dataLabels:{enabled:!1},stroke:{width:1},tooltip:{enabled:!1},xaxis:{tooltip:{enabled:!1}}})}},{key:"stacked100",value:function(c){c.dataLabels=c.dataLabels||{},c.dataLabels.formatter=c.dataLabels.formatter||void 0;var u=c.dataLabels.formatter;return c.yaxis.forEach(function(d,v){c.yaxis[v].min=0,c.yaxis[v].max=100}),c.chart.type==="bar"&&(c.dataLabels.formatter=u||function(d){return typeof d=="number"&&d?d.toFixed(0)+"%":d}),c}},{key:"stackedBars",value:function(){var c=this.bar();return i(i({},c),{},{plotOptions:i(i({},c.plotOptions),{},{bar:i(i({},c.plotOptions.bar),{},{borderRadiusApplication:"end",borderRadiusWhenStacked:"last"})})})}},{key:"convertCatToNumeric",value:function(c){return c.xaxis.convertedCatToNumeric=!0,c}},{key:"convertCatToNumericXaxis",value:function(c,u,d){c.xaxis.type="numeric",c.xaxis.labels=c.xaxis.labels||{},c.xaxis.labels.formatter=c.xaxis.labels.formatter||function(x){return E.isNumber(x)?Math.floor(x):x};var v=c.xaxis.labels.formatter,m=c.xaxis.categories&&c.xaxis.categories.length?c.xaxis.categories:c.labels;return d&&d.length&&(m=d.map(function(x){return Array.isArray(x)?x:String(x)})),m&&m.length&&(c.xaxis.labels.formatter=function(x){return E.isNumber(x)?v(m[Math.floor(x)-1]):v(x)}),c.xaxis.categories=[],c.labels=[],c.xaxis.tickAmount=c.xaxis.tickAmount||"dataPoints",c}},{key:"bubble",value:function(){return{dataLabels:{style:{colors:["#fff"]}},tooltip:{shared:!1,intersect:!0},xaxis:{crosshairs:{width:0}},fill:{type:"solid",gradient:{shade:"light",inverse:!0,shadeIntensity:.55,opacityFrom:.4,opacityTo:.8}}}}},{key:"scatter",value:function(){return{dataLabels:{enabled:!1},tooltip:{shared:!1,intersect:!0},markers:{size:6,strokeWidth:1,hover:{sizeOffset:2}}}}},{key:"heatmap",value:function(){return{chart:{stacked:!1},fill:{opacity:1},dataLabels:{style:{colors:["#fff"]}},stroke:{colors:["#fff"]},tooltip:{followCursor:!0,marker:{show:!1},x:{show:!1}},legend:{position:"top",markers:{shape:"square"}},grid:{padding:{right:20}}}}},{key:"treemap",value:function(){return{chart:{zoom:{enabled:!1}},dataLabels:{style:{fontSize:14,fontWeight:600,colors:["#fff"]}},stroke:{show:!0,width:2,colors:["#fff"]},legend:{show:!1},fill:{opacity:1,gradient:{stops:[0,100]}},tooltip:{followCursor:!0,x:{show:!1}},grid:{padding:{left:0,right:0}},xaxis:{crosshairs:{show:!1},tooltip:{enabled:!1}}}}},{key:"pie",value:function(){return{chart:{toolbar:{show:!1}},plotOptions:{pie:{donut:{labels:{show:!1}}}},dataLabels:{formatter:function(c){return c.toFixed(1)+"%"},style:{colors:["#fff"]},background:{enabled:!1},dropShadow:{enabled:!0}},stroke:{colors:["#fff"]},fill:{opacity:1,gradient:{shade:"light",stops:[0,100]}},tooltip:{theme:"dark",fillSeriesColor:!0},legend:{position:"right"}}}},{key:"donut",value:function(){return{chart:{toolbar:{show:!1}},dataLabels:{formatter:function(c){return c.toFixed(1)+"%"},style:{colors:["#fff"]},background:{enabled:!1},dropShadow:{enabled:!0}},stroke:{colors:["#fff"]},fill:{opacity:1,gradient:{shade:"light",shadeIntensity:.35,stops:[80,100],opacityFrom:1,opacityTo:1}},tooltip:{theme:"dark",fillSeriesColor:!0},legend:{position:"right"}}}},{key:"polarArea",value:function(){return{chart:{toolbar:{show:!1}},dataLabels:{formatter:function(c){return c.toFixed(1)+"%"},enabled:!1},stroke:{show:!0,width:2},fill:{opacity:.7},tooltip:{theme:"dark",fillSeriesColor:!0},legend:{position:"right"}}}},{key:"radar",value:function(){return this.opts.yaxis[0].labels.offsetY=this.opts.yaxis[0].labels.offsetY?this.opts.yaxis[0].labels.offsetY:6,{dataLabels:{enabled:!1,style:{fontSize:"11px"}},stroke:{width:2},markers:{size:5,strokeWidth:1,strokeOpacity:1},fill:{opacity:.2},tooltip:{shared:!1,intersect:!0,followCursor:!0},grid:{show:!1},xaxis:{labels:{formatter:function(c){return c},style:{colors:["#a8a8a8"],fontSize:"11px"}},tooltip:{enabled:!1},crosshairs:{show:!1}}}}},{key:"radialBar",value:function(){return{chart:{animations:{dynamicAnimation:{enabled:!0,speed:800}},toolbar:{show:!1}},fill:{gradient:{shade:"dark",shadeIntensity:.4,inverseColors:!1,type:"diagonal2",opacityFrom:1,opacityTo:1,stops:[70,98,100]}},legend:{show:!1,position:"right"},tooltip:{enabled:!1,fillSeriesColor:!0}}}},{key:"_getBoxTooltip",value:function(c,u,d,v,m){var x=c.globals.seriesCandleO[u][d],w=c.globals.seriesCandleH[u][d],k=c.globals.seriesCandleM[u][d],L=c.globals.seriesCandleL[u][d],D=c.globals.seriesCandleC[u][d];return c.config.series[u].type&&c.config.series[u].type!==m?`
`.concat(c.config.series[u].name?c.config.series[u].name:"series-"+(u+1),": ").concat(c.globals.series[u][d],` -
`):'
')+"
".concat(v[0],': ')+x+"
"+"
".concat(v[1],': ')+w+"
"+(k?"
".concat(v[2],': ')+k+"
":"")+"
".concat(v[3],': ')+L+"
"+"
".concat(v[4],': ')+D+"
"}}]),Q}(),_t=function(){function Q(c){a(this,Q),this.opts=c}return l(Q,[{key:"init",value:function(c){var u=c.responsiveOverride,d=this.opts,v=new lt,m=new kt(d);this.chartType=d.chart.type,d=this.extendYAxis(d),d=this.extendAnnotations(d);var x=v.init(),w={};if(d&&o(d)==="object"){var k,L,D,P,V,N,j,U,q,J,rt={};rt=["line","area","bar","candlestick","boxPlot","rangeBar","rangeArea","bubble","scatter","heatmap","treemap","pie","polarArea","donut","radar","radialBar"].indexOf(d.chart.type)!==-1?m[d.chart.type]():m.line(),(k=d.plotOptions)!==null&&k!==void 0&&(L=k.bar)!==null&&L!==void 0&&L.isFunnel&&(rt=m.funnel()),d.chart.stacked&&d.chart.type==="bar"&&(rt=m.stackedBars()),(D=d.chart.brush)!==null&&D!==void 0&&D.enabled&&(rt=m.brush(rt)),(P=d.plotOptions)!==null&&P!==void 0&&(V=P.line)!==null&&V!==void 0&&V.isSlopeChart&&(rt=m.slope()),d.chart.stacked&&d.chart.stackType==="100%"&&(d=m.stacked100(d)),(N=d.plotOptions)!==null&&N!==void 0&&(j=N.bar)!==null&&j!==void 0&&j.isDumbbell&&(d=m.dumbbell(d)),this.checkForDarkTheme(window.Apex),this.checkForDarkTheme(d),d.xaxis=d.xaxis||window.Apex.xaxis||{},u||(d.xaxis.convertedCatToNumeric=!1),((U=(d=this.checkForCatToNumericXAxis(this.chartType,rt,d)).chart.sparkline)!==null&&U!==void 0&&U.enabled||(q=window.Apex.chart)!==null&&q!==void 0&&(J=q.sparkline)!==null&&J!==void 0&&J.enabled)&&(rt=m.sparkline(rt)),w=E.extend(x,rt)}var A=E.extend(w,window.Apex);return x=E.extend(A,d),x=this.handleUserInputErrors(x)}},{key:"checkForCatToNumericXAxis",value:function(c,u,d){var v,m,x=new kt(d),w=(c==="bar"||c==="boxPlot")&&((v=d.plotOptions)===null||v===void 0||(m=v.bar)===null||m===void 0?void 0:m.horizontal),k=c==="pie"||c==="polarArea"||c==="donut"||c==="radar"||c==="radialBar"||c==="heatmap",L=d.xaxis.type!=="datetime"&&d.xaxis.type!=="numeric",D=d.xaxis.tickPlacement?d.xaxis.tickPlacement:u.xaxis&&u.xaxis.tickPlacement;return w||k||!L||D==="between"||(d=x.convertCatToNumeric(d)),d}},{key:"extendYAxis",value:function(c,u){var d=new lt;(c.yaxis===void 0||!c.yaxis||Array.isArray(c.yaxis)&&c.yaxis.length===0)&&(c.yaxis={}),c.yaxis.constructor!==Array&&window.Apex.yaxis&&window.Apex.yaxis.constructor!==Array&&(c.yaxis=E.extend(c.yaxis,window.Apex.yaxis)),c.yaxis.constructor!==Array?c.yaxis=[E.extend(d.yAxis,c.yaxis)]:c.yaxis=E.extendArray(c.yaxis,d.yAxis);var v=!1;c.yaxis.forEach(function(x){x.logarithmic&&(v=!0)});var m=c.series;return u&&!m&&(m=u.config.series),v&&m.length!==c.yaxis.length&&m.length&&(c.yaxis=m.map(function(x,w){if(x.name||(m[w].name="series-".concat(w+1)),c.yaxis[w])return c.yaxis[w].seriesName=m[w].name,c.yaxis[w];var k=E.extend(d.yAxis,c.yaxis[0]);return k.show=!1,k})),v&&m.length>1&&m.length!==c.yaxis.length&&console.warn("A multi-series logarithmic chart should have equal number of series and y-axes"),c}},{key:"extendAnnotations",value:function(c){return c.annotations===void 0&&(c.annotations={},c.annotations.yaxis=[],c.annotations.xaxis=[],c.annotations.points=[]),c=this.extendYAxisAnnotations(c),c=this.extendXAxisAnnotations(c),c=this.extendPointAnnotations(c)}},{key:"extendYAxisAnnotations",value:function(c){var u=new lt;return c.annotations.yaxis=E.extendArray(c.annotations.yaxis!==void 0?c.annotations.yaxis:[],u.yAxisAnnotation),c}},{key:"extendXAxisAnnotations",value:function(c){var u=new lt;return c.annotations.xaxis=E.extendArray(c.annotations.xaxis!==void 0?c.annotations.xaxis:[],u.xAxisAnnotation),c}},{key:"extendPointAnnotations",value:function(c){var u=new lt;return c.annotations.points=E.extendArray(c.annotations.points!==void 0?c.annotations.points:[],u.pointAnnotation),c}},{key:"checkForDarkTheme",value:function(c){c.theme&&c.theme.mode==="dark"&&(c.tooltip||(c.tooltip={}),c.tooltip.theme!=="light"&&(c.tooltip.theme="dark"),c.chart.foreColor||(c.chart.foreColor="#f6f7f8"),c.theme.palette||(c.theme.palette="palette4"))}},{key:"handleUserInputErrors",value:function(c){var u=c;if(u.tooltip.shared&&u.tooltip.intersect)throw new Error("tooltip.shared cannot be enabled when tooltip.intersect is true. Turn off any other option by setting it to false.");if(u.chart.type==="bar"&&u.plotOptions.bar.horizontal){if(u.yaxis.length>1)throw new Error("Multiple Y Axis for bars are not supported. Switch to column chart by setting plotOptions.bar.horizontal=false");u.yaxis[0].reversed&&(u.yaxis[0].opposite=!0),u.xaxis.tooltip.enabled=!1,u.yaxis[0].tooltip.enabled=!1,u.chart.zoom.enabled=!1}return u.chart.type!=="bar"&&u.chart.type!=="rangeBar"||u.tooltip.shared&&u.xaxis.crosshairs.width==="barWidth"&&u.series.length>1&&(u.xaxis.crosshairs.width="tickWidth"),u.chart.type!=="candlestick"&&u.chart.type!=="boxPlot"||u.yaxis[0].reversed&&(console.warn("Reversed y-axis in ".concat(u.chart.type," chart is not supported.")),u.yaxis[0].reversed=!1),u}}]),Q}(),bt=function(){function Q(){a(this,Q)}return l(Q,[{key:"initGlobalVars",value:function(c){c.series=[],c.seriesCandleO=[],c.seriesCandleH=[],c.seriesCandleM=[],c.seriesCandleL=[],c.seriesCandleC=[],c.seriesRangeStart=[],c.seriesRangeEnd=[],c.seriesRange=[],c.seriesPercent=[],c.seriesGoals=[],c.seriesX=[],c.seriesZ=[],c.seriesNames=[],c.seriesTotals=[],c.seriesLog=[],c.seriesColors=[],c.stackedSeriesTotals=[],c.seriesXvalues=[],c.seriesYvalues=[],c.labels=[],c.hasXaxisGroups=!1,c.groups=[],c.barGroups=[],c.lineGroups=[],c.areaGroups=[],c.hasSeriesGroups=!1,c.seriesGroups=[],c.categoryLabels=[],c.timescaleLabels=[],c.noLabelsProvided=!1,c.resizeTimer=null,c.selectionResizeTimer=null,c.delayedElements=[],c.pointsArray=[],c.dataLabelsRects=[],c.isXNumeric=!1,c.skipLastTimelinelabel=!1,c.skipFirstTimelinelabel=!1,c.isDataXYZ=!1,c.isMultiLineX=!1,c.isMultipleYAxis=!1,c.maxY=-Number.MAX_VALUE,c.minY=Number.MIN_VALUE,c.minYArr=[],c.maxYArr=[],c.maxX=-Number.MAX_VALUE,c.minX=Number.MAX_VALUE,c.initialMaxX=-Number.MAX_VALUE,c.initialMinX=Number.MAX_VALUE,c.maxDate=0,c.minDate=Number.MAX_VALUE,c.minZ=Number.MAX_VALUE,c.maxZ=-Number.MAX_VALUE,c.minXDiff=Number.MAX_VALUE,c.yAxisScale=[],c.xAxisScale=null,c.xAxisTicksPositions=[],c.yLabelsCoords=[],c.yTitleCoords=[],c.barPadForNumericAxis=0,c.padHorizontal=0,c.xRange=0,c.yRange=[],c.zRange=0,c.dataPoints=0,c.xTickAmount=0,c.multiAxisTickAmount=0}},{key:"globalVars",value:function(c){return{chartID:null,cuid:null,events:{beforeMount:[],mounted:[],updated:[],clicked:[],selection:[],dataPointSelection:[],zoomed:[],scrolled:[]},colors:[],clientX:null,clientY:null,fill:{colors:[]},stroke:{colors:[]},dataLabels:{style:{colors:[]}},radarPolygons:{fill:{colors:[]}},markers:{colors:[],size:c.markers.size,largestSize:0},animationEnded:!1,isTouchDevice:"ontouchstart"in window||navigator.msMaxTouchPoints,isDirty:!1,isExecCalled:!1,initialConfig:null,initialSeries:[],lastXAxis:[],lastYAxis:[],columnSeries:null,labels:[],timescaleLabels:[],noLabelsProvided:!1,allSeriesCollapsed:!1,collapsedSeries:[],collapsedSeriesIndices:[],ancillaryCollapsedSeries:[],ancillaryCollapsedSeriesIndices:[],risingSeries:[],dataFormatXNumeric:!1,capturedSeriesIndex:-1,capturedDataPointIndex:-1,selectedDataPoints:[],goldenPadding:35,invalidLogScale:!1,ignoreYAxisIndexes:[],maxValsInArrayIndex:0,radialSize:0,selection:void 0,zoomEnabled:c.chart.toolbar.autoSelected==="zoom"&&c.chart.toolbar.tools.zoom&&c.chart.zoom.enabled,panEnabled:c.chart.toolbar.autoSelected==="pan"&&c.chart.toolbar.tools.pan,selectionEnabled:c.chart.toolbar.autoSelected==="selection"&&c.chart.toolbar.tools.selection,yaxis:null,mousedown:!1,lastClientPosition:{},visibleXRange:void 0,yValueDecimal:0,total:0,SVGNS:"http://www.w3.org/2000/svg",svgWidth:0,svgHeight:0,noData:!1,locale:{},dom:{},memory:{methodsToExec:[]},shouldAnimate:!0,skipLastTimelinelabel:!1,skipFirstTimelinelabel:!1,delayedElements:[],axisCharts:!0,isDataXYZ:!1,isSlopeChart:c.plotOptions.line.isSlopeChart,resized:!1,resizeTimer:null,comboCharts:!1,dataChanged:!1,previousPaths:[],allSeriesHasEqualX:!0,pointsArray:[],dataLabelsRects:[],lastDrawnDataLabelsIndexes:[],hasNullValues:!1,easing:null,zoomed:!1,gridWidth:0,gridHeight:0,rotateXLabels:!1,defaultLabels:!1,xLabelFormatter:void 0,yLabelFormatters:[],xaxisTooltipFormatter:void 0,ttKeyFormatter:void 0,ttVal:void 0,ttZFormatter:void 0,LINE_HEIGHT_RATIO:1.618,xAxisLabelsHeight:0,xAxisGroupLabelsHeight:0,xAxisLabelsWidth:0,yAxisLabelsWidth:0,scaleX:1,scaleY:1,translateX:0,translateY:0,translateYAxisX:[],yAxisWidths:[],translateXAxisY:0,translateXAxisX:0,tooltip:null,niceScaleAllowedMagMsd:[[1,1,2,5,5,5,10,10,10,10,10],[1,1,2,5,5,5,10,10,10,10,10]],niceScaleDefaultTicks:[1,2,4,4,6,6,6,6,6,6,6,6,6,6,6,6,6,6,12,12,12,12,12,12,12,12,12,24],seriesYAxisMap:[],seriesYAxisReverseMap:[]}}},{key:"init",value:function(c){var u=this.globalVars(c);return this.initGlobalVars(u),u.initialConfig=E.extend({},c),u.initialSeries=E.clone(c.series),u.lastXAxis=E.clone(u.initialConfig.xaxis),u.lastYAxis=E.clone(u.initialConfig.yaxis),u}}]),Q}(),Mt=function(){function Q(c){a(this,Q),this.opts=c}return l(Q,[{key:"init",value:function(){var c=new _t(this.opts).init({responsiveOverride:!1});return{config:c,globals:new bt().init(c)}}}]),Q}(),At=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w,this.opts=null,this.seriesIndex=0}return l(Q,[{key:"clippedImgArea",value:function(c){var u=this.w,d=u.config,v=parseInt(u.globals.gridWidth,10),m=parseInt(u.globals.gridHeight,10),x=v>m?v:m,w=c.image,k=0,L=0;c.width===void 0&&c.height===void 0?d.fill.image.width!==void 0&&d.fill.image.height!==void 0?(k=d.fill.image.width+1,L=d.fill.image.height):(k=x+1,L=x):(k=c.width,L=c.height);var D=document.createElementNS(u.globals.SVGNS,"pattern");$.setAttrs(D,{id:c.patternID,patternUnits:c.patternUnits?c.patternUnits:"userSpaceOnUse",width:k+"px",height:L+"px"});var P=document.createElementNS(u.globals.SVGNS,"image");D.appendChild(P),P.setAttributeNS(window.SVG.xlink,"href",w),$.setAttrs(P,{x:0,y:0,preserveAspectRatio:"none",width:k+"px",height:L+"px"}),P.style.opacity=c.opacity,u.globals.dom.elDefs.node.appendChild(D)}},{key:"getSeriesIndex",value:function(c){var u=this.w,d=u.config.chart.type;return(d==="bar"||d==="rangeBar")&&u.config.plotOptions.bar.distributed||d==="heatmap"||d==="treemap"?this.seriesIndex=c.seriesNumber:this.seriesIndex=c.seriesNumber%u.globals.series.length,this.seriesIndex}},{key:"fillPath",value:function(c){var u=this.w;this.opts=c;var d,v,m,x=this.w.config;this.seriesIndex=this.getSeriesIndex(c);var w=this.getFillColors()[this.seriesIndex];u.globals.seriesColors[this.seriesIndex]!==void 0&&(w=u.globals.seriesColors[this.seriesIndex]),typeof w=="function"&&(w=w({seriesIndex:this.seriesIndex,dataPointIndex:c.dataPointIndex,value:c.value,w:u}));var k=c.fillType?c.fillType:this.getFillType(this.seriesIndex),L=Array.isArray(x.fill.opacity)?x.fill.opacity[this.seriesIndex]:x.fill.opacity;c.color&&(w=c.color),w||(w="#fff",console.warn("undefined color - ApexCharts"));var D=w;if(w.indexOf("rgb")===-1?w.length<9&&(D=E.hexToRgba(w,L)):w.indexOf("rgba")>-1&&(L=E.getOpacityFromRGBA(w)),c.opacity&&(L=c.opacity),k==="pattern"&&(v=this.handlePatternFill({fillConfig:c.fillConfig,patternFill:v,fillColor:w,fillOpacity:L,defaultColor:D})),k==="gradient"&&(m=this.handleGradientFill({fillConfig:c.fillConfig,fillColor:w,fillOpacity:L,i:this.seriesIndex})),k==="image"){var P=x.fill.image.src,V=c.patternID?c.patternID:"";this.clippedImgArea({opacity:L,image:Array.isArray(P)?c.seriesNumber-1&&(N=E.getOpacityFromRGBA(V));var j=x.gradient.opacityTo===void 0?d:Array.isArray(x.gradient.opacityTo)?x.gradient.opacityTo[m]:x.gradient.opacityTo;if(x.gradient.gradientToColors===void 0||x.gradient.gradientToColors.length===0)w=x.gradient.shade==="dark"?D.shadeColor(-1*parseFloat(x.gradient.shadeIntensity),u.indexOf("rgb")>-1?E.rgb2hex(u):u):D.shadeColor(parseFloat(x.gradient.shadeIntensity),u.indexOf("rgb")>-1?E.rgb2hex(u):u);else if(x.gradient.gradientToColors[k.seriesNumber]){var U=x.gradient.gradientToColors[k.seriesNumber];w=U,U.indexOf("rgba")>-1&&(j=E.getOpacityFromRGBA(U))}else w=u;if(x.gradient.gradientFrom&&(V=x.gradient.gradientFrom),x.gradient.gradientTo&&(w=x.gradient.gradientTo),x.gradient.inverseColors){var q=V;V=w,w=q}return V.indexOf("rgb")>-1&&(V=E.rgb2hex(V)),w.indexOf("rgb")>-1&&(w=E.rgb2hex(w)),L.drawGradient(P,V,w,N,j,k.size,x.gradient.stops,x.gradient.colorStops,m)}}]),Q}(),Ft=function(){function Q(c,u){a(this,Q),this.ctx=c,this.w=c.w}return l(Q,[{key:"setGlobalMarkerSize",value:function(){var c=this.w;if(c.globals.markers.size=Array.isArray(c.config.markers.size)?c.config.markers.size:[c.config.markers.size],c.globals.markers.size.length>0){if(c.globals.markers.size.length4&&arguments[4]!==void 0&&arguments[4],w=this.w,k=u,L=c,D=null,P=new $(this.ctx),V=w.config.markers.discrete&&w.config.markers.discrete.length;if((w.globals.markers.size[u]>0||x||V)&&(D=P.group({class:x||V?"":"apexcharts-series-markers"})).attr("clip-path","url(#gridRectMarkerMask".concat(w.globals.cuid,")")),Array.isArray(L.x))for(var N=0;N0:w.config.markers.size>0)||x||V){E.isNumber(L.y[N])?U+=" w".concat(E.randomId()):U="apexcharts-nullpoint";var q=this.getMarkerConfig({cssClass:U,seriesIndex:u,dataPointIndex:j});w.config.series[k].data[j]&&(w.config.series[k].data[j].fillColor&&(q.pointFillColor=w.config.series[k].data[j].fillColor),w.config.series[k].data[j].strokeColor&&(q.pointStrokeColor=w.config.series[k].data[j].strokeColor)),v!==void 0&&(q.pSize=v),(L.x[N]<-w.globals.markers.largestSize||L.x[N]>w.globals.gridWidth+w.globals.markers.largestSize||L.y[N]<-w.globals.markers.largestSize||L.y[N]>w.globals.gridHeight+w.globals.markers.largestSize)&&(q.pSize=0),(m=P.drawMarker(L.x[N],L.y[N],q)).attr("rel",j),m.attr("j",j),m.attr("index",u),m.node.setAttribute("default-marker-size",q.pSize),new W(this.ctx).setSelectionFilter(m,u,j),this.addEvents(m),D&&D.add(m)}else w.globals.pointsArray[u]===void 0&&(w.globals.pointsArray[u]=[]),w.globals.pointsArray[u].push([L.x[N],L.y[N]])}return D}},{key:"getMarkerConfig",value:function(c){var u=c.cssClass,d=c.seriesIndex,v=c.dataPointIndex,m=v===void 0?null:v,x=c.radius,w=x===void 0?null:x,k=c.size,L=k===void 0?null:k,D=c.strokeWidth,P=D===void 0?null:D,V=this.w,N=this.getMarkerStyle(d),j=L===null?V.globals.markers.size[d]:L,U=V.config.markers;return m!==null&&U.discrete.length&&U.discrete.map(function(q){q.seriesIndex===d&&q.dataPointIndex===m&&(N.pointStrokeColor=q.strokeColor,N.pointFillColor=q.fillColor,j=q.size,N.pointShape=q.shape)}),{pSize:w===null?j:w,pRadius:w!==null?w:U.radius,pointStrokeWidth:P!==null?P:Array.isArray(U.strokeWidth)?U.strokeWidth[d]:U.strokeWidth,pointStrokeColor:N.pointStrokeColor,pointFillColor:N.pointFillColor,shape:N.pointShape||(Array.isArray(U.shape)?U.shape[d]:U.shape),class:u,pointStrokeOpacity:Array.isArray(U.strokeOpacity)?U.strokeOpacity[d]:U.strokeOpacity,pointStrokeDashArray:Array.isArray(U.strokeDashArray)?U.strokeDashArray[d]:U.strokeDashArray,pointFillOpacity:Array.isArray(U.fillOpacity)?U.fillOpacity[d]:U.fillOpacity,seriesIndex:d}}},{key:"addEvents",value:function(c){var u=this.w,d=new $(this.ctx);c.node.addEventListener("mouseenter",d.pathMouseEnter.bind(this.ctx,c)),c.node.addEventListener("mouseleave",d.pathMouseLeave.bind(this.ctx,c)),c.node.addEventListener("mousedown",d.pathMouseDown.bind(this.ctx,c)),c.node.addEventListener("click",u.config.markers.onClick),c.node.addEventListener("dblclick",u.config.markers.onDblClick),c.node.addEventListener("touchstart",d.pathMouseDown.bind(this.ctx,c),{passive:!0})}},{key:"getMarkerStyle",value:function(c){var u=this.w,d=u.globals.markers.colors,v=u.config.markers.strokeColor||u.config.markers.strokeColors;return{pointStrokeColor:Array.isArray(v)?v[c]:v,pointFillColor:Array.isArray(d)?d[c]:d}}}]),Q}(),Bt=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w,this.initialAnim=this.w.config.chart.animations.enabled}return l(Q,[{key:"draw",value:function(c,u,d){var v=this.w,m=new $(this.ctx),x=d.realIndex,w=d.pointsPos,k=d.zRatio,L=d.elParent,D=m.group({class:"apexcharts-series-markers apexcharts-series-".concat(v.config.chart.type)});if(D.attr("clip-path","url(#gridRectMarkerMask".concat(v.globals.cuid,")")),Array.isArray(w.x))for(var P=0;PU.maxBubbleRadius&&(j=U.maxBubbleRadius)}var q=w.x[P],J=w.y[P];if(j=j||0,J!==null&&v.globals.series[x][V]!==void 0||(N=!1),N){var rt=this.drawPoint(q,J,j,x,V,u);D.add(rt)}L.add(D)}}},{key:"drawPoint",value:function(c,u,d,v,m,x){var w=this.w,k=v,L=new R(this.ctx),D=new W(this.ctx),P=new At(this.ctx),V=new Ft(this.ctx),N=new $(this.ctx),j=V.getMarkerConfig({cssClass:"apexcharts-marker",seriesIndex:k,dataPointIndex:m,radius:w.config.chart.type==="bubble"||w.globals.comboCharts&&w.config.series[v]&&w.config.series[v].type==="bubble"?d:null}),U=P.fillPath({seriesNumber:v,dataPointIndex:m,color:j.pointFillColor,patternUnits:"objectBoundingBox",value:w.globals.series[v][x]}),q=N.drawMarker(c,u,j);if(w.config.series[k].data[m]&&w.config.series[k].data[m].fillColor&&(U=w.config.series[k].data[m].fillColor),q.attr({fill:U}),w.config.chart.dropShadow.enabled){var J=w.config.chart.dropShadow;D.dropShadow(q,J,v)}if(!this.initialAnim||w.globals.dataChanged||w.globals.resized)w.globals.animationEnded=!0;else{var rt=w.config.chart.animations.speed;L.animateMarker(q,rt,w.globals.easing,function(){window.setTimeout(function(){L.animationCompleted(q)},100)})}return q.attr({rel:m,j:m,index:v,"default-marker-size":j.pSize}),D.setSelectionFilter(q,v,m),V.addEvents(q),q.node.classList.add("apexcharts-marker"),q}},{key:"centerTextInBubble",value:function(c){var u=this.w;return{y:c+=parseInt(u.config.dataLabels.style.fontSize,10)/4}}}]),Q}(),Ut=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w}return l(Q,[{key:"dataLabelsCorrection",value:function(c,u,d,v,m,x,w){var k=this.w,L=!1,D=new $(this.ctx).getTextRects(d,w),P=D.width,V=D.height;u<0&&(u=0),u>k.globals.gridHeight+V&&(u=k.globals.gridHeight+V/2),k.globals.dataLabelsRects[v]===void 0&&(k.globals.dataLabelsRects[v]=[]),k.globals.dataLabelsRects[v].push({x:c,y:u,width:P,height:V});var N=k.globals.dataLabelsRects[v].length-2,j=k.globals.lastDrawnDataLabelsIndexes[v]!==void 0?k.globals.lastDrawnDataLabelsIndexes[v][k.globals.lastDrawnDataLabelsIndexes[v].length-1]:0;if(k.globals.dataLabelsRects[v][N]!==void 0){var U=k.globals.dataLabelsRects[v][j];(c>U.x+U.width||u>U.y+U.height||u+Vu.globals.gridWidth+rt.textRects.width+30)&&(k="");var A=u.globals.dataLabels.style.colors[x];((u.config.chart.type==="bar"||u.config.chart.type==="rangeBar")&&u.config.plotOptions.bar.distributed||u.config.dataLabels.distributed)&&(A=u.globals.dataLabels.style.colors[w]),typeof A=="function"&&(A=A({series:u.globals.series,seriesIndex:x,dataPointIndex:w,w:u})),N&&(A=N);var O=V.offsetX,X=V.offsetY;if(u.config.chart.type!=="bar"&&u.config.chart.type!=="rangeBar"||(O=0,X=0),u.globals.isSlopeChart&&(w!==0&&(O=-2*V.offsetX+5),w!==0&&w!==u.config.series[x].data.length-1&&(O=0)),rt.drawnextLabel){if((J=d.drawText({width:100,height:parseInt(V.style.fontSize,10),x:v+O,y:m+X,foreColor:A,textAnchor:L||V.textAnchor,text:k,fontSize:D||V.style.fontSize,fontFamily:V.style.fontFamily,fontWeight:V.style.fontWeight||"normal"})).attr({class:q||"apexcharts-datalabel",cx:v,cy:m}),V.dropShadow.enabled){var ot=V.dropShadow;new W(this.ctx).dropShadow(J,ot)}P.add(J),u.globals.lastDrawnDataLabelsIndexes[x]===void 0&&(u.globals.lastDrawnDataLabelsIndexes[x]=[]),u.globals.lastDrawnDataLabelsIndexes[x].push(w)}return J}},{key:"addBackgroundToDataLabel",value:function(c,u){var d=this.w,v=d.config.dataLabels.background,m=v.padding,x=v.padding/2,w=u.width,k=u.height,L=new $(this.ctx).drawRect(u.x-m,u.y-x/2,w+2*m,k+x,v.borderRadius,d.config.chart.background!=="transparent"&&d.config.chart.background?d.config.chart.background:"#fff",v.opacity,v.borderWidth,v.borderColor);return v.dropShadow.enabled&&new W(this.ctx).dropShadow(L,v.dropShadow),L}},{key:"dataLabelsBackground",value:function(){var c=this.w;if(c.config.chart.type!=="bubble")for(var u=c.globals.dom.baseEl.querySelectorAll(".apexcharts-datalabels text"),d=0;d0&&arguments[0]!==void 0)||arguments[0],u=!(arguments.length>1&&arguments[1]!==void 0)||arguments[1],d=!(arguments.length>2&&arguments[2]!==void 0)||arguments[2],v=this.w,m=E.clone(v.globals.initialSeries);v.globals.previousPaths=[],d?(v.globals.collapsedSeries=[],v.globals.ancillaryCollapsedSeries=[],v.globals.collapsedSeriesIndices=[],v.globals.ancillaryCollapsedSeriesIndices=[]):m=this.emptyCollapsedSeries(m),v.config.series=m,c&&(u&&(v.globals.zoomed=!1,this.ctx.updateHelpers.revertDefaultAxisMinMax()),this.ctx.updateHelpers._updateSeries(m,v.config.chart.animations.dynamicAnimation.enabled))}},{key:"emptyCollapsedSeries",value:function(c){for(var u=this.w,d=0;d-1&&(c[d].data=[]);return c}},{key:"toggleSeriesOnHover",value:function(c,u){var d=this.w;u||(u=c.target);var v=d.globals.dom.baseEl.querySelectorAll(".apexcharts-series, .apexcharts-datalabels, .apexcharts-yaxis");if(c.type==="mousemove"){var m=parseInt(u.getAttribute("rel"),10)-1,x=null,w=null,k=null;if(d.globals.axisCharts||d.config.chart.type==="radialBar")if(d.globals.axisCharts){x=d.globals.dom.baseEl.querySelector(".apexcharts-series[data\\:realIndex='".concat(m,"']")),w=d.globals.dom.baseEl.querySelector(".apexcharts-datalabels[data\\:realIndex='".concat(m,"']"));var L=d.globals.seriesYAxisReverseMap[m];k=d.globals.dom.baseEl.querySelector(".apexcharts-yaxis[rel='".concat(L,"']"))}else x=d.globals.dom.baseEl.querySelector(".apexcharts-series[rel='".concat(m+1,"']"));else x=d.globals.dom.baseEl.querySelector(".apexcharts-series[rel='".concat(m+1,"'] path"));for(var D=0;D=k.from&&D<=k.to&&m[L].classList.remove(d.legendInactiveClass)}}(v.config.plotOptions.heatmap.colorScale.ranges[w])}else c.type==="mouseout"&&x("remove")}},{key:"getActiveConfigSeriesIndex",value:function(){var c=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"asc",u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],d=this.w,v=0;if(d.config.series.length>1){for(var m=d.config.series.map(function(w,k){return w.data&&w.data.length>0&&d.globals.collapsedSeriesIndices.indexOf(k)===-1&&(!d.globals.comboCharts||u.length===0||u.length&&u.indexOf(d.config.series[k].type)>-1)?k:-1}),x=c==="asc"?0:m.length-1;c==="asc"?x=0;c==="asc"?x++:x--)if(m[x]!==-1){v=m[x];break}}return v}},{key:"getBarSeriesIndices",value:function(){return this.w.globals.comboCharts?this.w.config.series.map(function(c,u){return c.type==="bar"||c.type==="column"?u:-1}).filter(function(c){return c!==-1}):this.w.config.series.map(function(c,u){return u})}},{key:"getPreviousPaths",value:function(){var c=this.w;function u(x,w,k){for(var L=x[w].childNodes,D={type:k,paths:[],realIndex:x[w].getAttribute("data:realIndex")},P=0;P0)for(var v=function(x){for(var w=c.globals.dom.baseEl.querySelectorAll(".apexcharts-".concat(c.config.chart.type," .apexcharts-series[data\\:realIndex='").concat(x,"'] rect")),k=[],L=function(P){var V=function(j){return w[P].getAttribute(j)},N={x:parseFloat(V("x")),y:parseFloat(V("y")),width:parseFloat(V("width")),height:parseFloat(V("height"))};k.push({rect:N,color:w[P].getAttribute("color")})},D=0;D0)for(var v=0;v0?u:[]});return c}}]),Q}(),It=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w,this.twoDSeries=[],this.threeDSeries=[],this.twoDSeriesX=[],this.seriesGoals=[],this.coreUtils=new G(this.ctx)}return l(Q,[{key:"isMultiFormat",value:function(){return this.isFormatXY()||this.isFormat2DArray()}},{key:"isFormatXY",value:function(){var c=this.w.config.series.slice(),u=new Xt(this.ctx);if(this.activeSeriesIndex=u.getActiveConfigSeriesIndex(),c[this.activeSeriesIndex].data!==void 0&&c[this.activeSeriesIndex].data.length>0&&c[this.activeSeriesIndex].data[0]!==null&&c[this.activeSeriesIndex].data[0].x!==void 0&&c[this.activeSeriesIndex].data[0]!==null)return!0}},{key:"isFormat2DArray",value:function(){var c=this.w.config.series.slice(),u=new Xt(this.ctx);if(this.activeSeriesIndex=u.getActiveConfigSeriesIndex(),c[this.activeSeriesIndex].data!==void 0&&c[this.activeSeriesIndex].data.length>0&&c[this.activeSeriesIndex].data[0]!==void 0&&c[this.activeSeriesIndex].data[0]!==null&&c[this.activeSeriesIndex].data[0].constructor===Array)return!0}},{key:"handleFormat2DArray",value:function(c,u){for(var d=this.w.config,v=this.w.globals,m=d.chart.type==="boxPlot"||d.series[u].type==="boxPlot",x=0;x=5?this.twoDSeries.push(E.parseNumber(c[u].data[x][4])):this.twoDSeries.push(E.parseNumber(c[u].data[x][1])),v.dataFormatXNumeric=!0),d.xaxis.type==="datetime"){var w=new Date(c[u].data[x][0]);w=new Date(w).getTime(),this.twoDSeriesX.push(w)}else this.twoDSeriesX.push(c[u].data[x][0]);for(var k=0;k-1&&(x=this.activeSeriesIndex);for(var w=0;w1&&arguments[1]!==void 0?arguments[1]:this.ctx,v=this.w.config,m=this.w.globals,x=new et(d),w=v.labels.length>0?v.labels.slice():v.xaxis.categories.slice();m.isRangeBar=v.chart.type==="rangeBar"&&m.isBarHorizontal,m.hasXaxisGroups=v.xaxis.type==="category"&&v.xaxis.group.groups.length>0,m.hasXaxisGroups&&(m.groups=v.xaxis.group.groups),c.forEach(function(N,j){N.name!==void 0?m.seriesNames.push(N.name):m.seriesNames.push("series-"+parseInt(j+1,10))}),this.coreUtils.setSeriesYAxisMappings();var k=[],L=I(new Set(v.series.map(function(N){return N.group})));v.series.forEach(function(N,j){var U=L.indexOf(N.group);k[U]||(k[U]=[]),k[U].push(m.seriesNames[j])}),m.seriesGroups=k;for(var D=function(){for(var N=0;N0&&(this.twoDSeriesX=w,m.seriesX.push(this.twoDSeriesX))),m.labels.push(this.twoDSeriesX);var V=c[P].data.map(function(N){return E.parseNumber(N)});m.series.push(V)}m.seriesZ.push(this.threeDSeries),c[P].color!==void 0?m.seriesColors.push(c[P].color):m.seriesColors.push(void 0)}return this.w}},{key:"parseDataNonAxisCharts",value:function(c){var u=this.w.globals,d=this.w.config;u.series=c.slice(),u.seriesNames=d.labels.slice();for(var v=0;v0?d.labels=u.xaxis.categories:u.labels.length>0?d.labels=u.labels.slice():this.fallbackToCategory?(d.labels=d.labels[0],d.seriesRange.length&&(d.seriesRange.map(function(v){v.forEach(function(m){d.labels.indexOf(m.x)<0&&m.x&&d.labels.push(m.x)})}),d.labels=Array.from(new Set(d.labels.map(JSON.stringify)),JSON.parse)),u.xaxis.convertedCatToNumeric&&(new kt(u).convertCatToNumericXaxis(u,this.ctx,d.seriesX[0]),this._generateExternalLabels(c))):this._generateExternalLabels(c)}},{key:"_generateExternalLabels",value:function(c){var u=this.w.globals,d=this.w.config,v=[];if(u.axisCharts){if(u.series.length>0)if(this.isFormatXY())for(var m=d.series.map(function(P,V){return P.data.filter(function(N,j,U){return U.findIndex(function(q){return q.x===N.x})===j})}),x=m.reduce(function(P,V,N,j){return j[P].length>V.length?P:N},0),w=0;w0&&m==d.length&&u.push(v)}),c.globals.ignoreYAxisIndexes=u.map(function(d){return d})}}]),Q}(),ae=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w}return l(Q,[{key:"scaleSvgNode",value:function(c,u){var d=parseFloat(c.getAttributeNS(null,"width")),v=parseFloat(c.getAttributeNS(null,"height"));c.setAttributeNS(null,"width",d*u),c.setAttributeNS(null,"height",v*u),c.setAttributeNS(null,"viewBox","0 0 "+d+" "+v)}},{key:"fixSvgStringForIe11",value:function(c){if(!E.isIE11())return c.replace(/ /g," ");var u=0,d=c.replace(/xmlns="http:\/\/www.w3.org\/2000\/svg"/g,function(v){return++u===2?'xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:svgjs="http://svgjs.dev"':v});return d=(d=d.replace(/xmlns:NS\d+=""/g,"")).replace(/NS\d+:(\w+:\w+=")/g,"$1")}},{key:"getSvgString",value:function(c){c==null&&(c=1);var u=this.w.globals.dom.Paper.svg();if(c!==1){var d=this.w.globals.dom.Paper.node.cloneNode(!0);this.scaleSvgNode(d,c),u=new XMLSerializer().serializeToString(d)}return this.fixSvgStringForIe11(u)}},{key:"cleanup",value:function(){var c=this.w,u=c.globals.dom.baseEl.getElementsByClassName("apexcharts-xcrosshairs"),d=c.globals.dom.baseEl.getElementsByClassName("apexcharts-ycrosshairs"),v=c.globals.dom.baseEl.querySelectorAll(".apexcharts-zoom-rect, .apexcharts-selection-rect");Array.prototype.forEach.call(v,function(m){m.setAttribute("width",0)}),u&&u[0]&&(u[0].setAttribute("x",-500),u[0].setAttribute("x1",-500),u[0].setAttribute("x2",-500)),d&&d[0]&&(d[0].setAttribute("y",-100),d[0].setAttribute("y1",-100),d[0].setAttribute("y2",-100))}},{key:"svgUrl",value:function(){this.cleanup();var c=this.getSvgString(),u=new Blob([c],{type:"image/svg+xml;charset=utf-8"});return URL.createObjectURL(u)}},{key:"dataURI",value:function(c){var u=this;return new Promise(function(d){var v=u.w,m=c?c.scale||c.width/v.globals.svgWidth:1;u.cleanup();var x=document.createElement("canvas");x.width=v.globals.svgWidth*m,x.height=parseInt(v.globals.dom.elWrap.style.height,10)*m;var w=v.config.chart.background!=="transparent"&&v.config.chart.background?v.config.chart.background:"#fff",k=x.getContext("2d");k.fillStyle=w,k.fillRect(0,0,x.width*m,x.height*m);var L=u.getSvgString(m);if(window.canvg&&E.isIE11()){var D=window.canvg.Canvg.fromString(k,L,{ignoreClear:!0,ignoreDimensions:!0});D.start();var P=x.msToBlob();D.stop(),d({blob:P})}else{var V="data:image/svg+xml,"+encodeURIComponent(L),N=new Image;N.crossOrigin="anonymous",N.onload=function(){if(k.drawImage(N,0,0),x.msToBlob){var j=x.msToBlob();d({blob:j})}else{var U=x.toDataURL("image/png");d({imgURI:U})}},N.src=V}})}},{key:"exportToSVG",value:function(){this.triggerDownload(this.svgUrl(),this.w.config.chart.toolbar.export.svg.filename,".svg")}},{key:"exportToPng",value:function(){var c=this;this.dataURI().then(function(u){var d=u.imgURI,v=u.blob;v?navigator.msSaveOrOpenBlob(v,c.w.globals.chartID+".png"):c.triggerDownload(d,c.w.config.chart.toolbar.export.png.filename,".png")})}},{key:"exportToCSV",value:function(c){var u=this,d=c.series,v=c.fileName,m=c.columnDelimiter,x=m===void 0?",":m,w=c.lineDelimiter,k=w===void 0?` -`:w,L=this.w;d||(d=L.config.series);var D,P,V=[],N=[],j="",U=L.globals.series.map(function(nt,ct){return L.globals.collapsedSeriesIndices.indexOf(ct)===-1?nt:[]}),q=function(nt){return typeof L.config.chart.toolbar.export.csv.categoryFormatter=="function"?L.config.chart.toolbar.export.csv.categoryFormatter(nt):L.config.xaxis.type==="datetime"&&String(nt).length>=10?new Date(nt).toDateString():E.isNumber(nt)?nt:nt.split(x).join("")},J=function(nt){return typeof L.config.chart.toolbar.export.csv.valueFormatter=="function"?L.config.chart.toolbar.export.csv.valueFormatter(nt):nt},rt=Math.max.apply(Math,I(d.map(function(nt){return nt.data?nt.data.length:0}))),A=new It(this.ctx),O=new tt(this.ctx),X=function(nt){var ct="";if(L.globals.axisCharts){if(L.config.xaxis.type==="category"||L.config.xaxis.convertedCatToNumeric)if(L.globals.isBarHorizontal){var wt=L.globals.yLabelFormatters[0],xt=new Xt(u.ctx).getActiveConfigSeriesIndex();ct=wt(L.globals.labels[nt],{seriesIndex:xt,dataPointIndex:nt,w:L})}else ct=O.getLabel(L.globals.labels,L.globals.timescaleLabels,0,nt).text;L.config.xaxis.type==="datetime"&&(L.config.xaxis.categories.length?ct=L.config.xaxis.categories[nt]:L.config.labels.length&&(ct=L.config.labels[nt]))}else ct=L.config.labels[nt];return ct===null?"nullvalue":(Array.isArray(ct)&&(ct=ct.join(" ")),E.isNumber(ct)?ct:ct.split(x).join(""))},ot=function(nt,ct){if(V.length&&ct===0&&N.push(V.join(x)),nt.data){nt.data=nt.data.length&&nt.data||I(Array(rt)).map(function(){return""});for(var wt=0;wt0&&!d.globals.isBarHorizontal&&(this.xaxisLabels=d.globals.timescaleLabels.slice()),d.config.xaxis.overwriteCategories&&(this.xaxisLabels=d.config.xaxis.overwriteCategories),this.drawnLabels=[],this.drawnLabelsRects=[],d.config.xaxis.position==="top"?this.offY=0:this.offY=d.globals.gridHeight,this.offY=this.offY+d.config.xaxis.axisBorder.offsetY,this.isCategoryBarHorizontal=d.config.chart.type==="bar"&&d.config.plotOptions.bar.horizontal,this.xaxisFontSize=d.config.xaxis.labels.style.fontSize,this.xaxisFontFamily=d.config.xaxis.labels.style.fontFamily,this.xaxisForeColors=d.config.xaxis.labels.style.colors,this.xaxisBorderWidth=d.config.xaxis.axisBorder.width,this.isCategoryBarHorizontal&&(this.xaxisBorderWidth=d.config.yaxis[0].axisBorder.width.toString()),this.xaxisBorderWidth.indexOf("%")>-1?this.xaxisBorderWidth=d.globals.gridWidth*parseInt(this.xaxisBorderWidth,10)/100:this.xaxisBorderWidth=parseInt(this.xaxisBorderWidth,10),this.xaxisBorderHeight=d.config.xaxis.axisBorder.height,this.yaxis=d.config.yaxis[0]}return l(Q,[{key:"drawXaxis",value:function(){var c=this.w,u=new $(this.ctx),d=u.group({class:"apexcharts-xaxis",transform:"translate(".concat(c.config.xaxis.offsetX,", ").concat(c.config.xaxis.offsetY,")")}),v=u.group({class:"apexcharts-xaxis-texts-g",transform:"translate(".concat(c.globals.translateXAxisX,", ").concat(c.globals.translateXAxisY,")")});d.add(v);for(var m=[],x=0;x6&&arguments[6]!==void 0?arguments[6]:{},D=[],P=[],V=this.w,N=L.xaxisFontSize||this.xaxisFontSize,j=L.xaxisFontFamily||this.xaxisFontFamily,U=L.xaxisForeColors||this.xaxisForeColors,q=L.fontWeight||V.config.xaxis.labels.style.fontWeight,J=L.cssClass||V.config.xaxis.labels.style.cssClass,rt=V.globals.padHorizontal,A=v.length,O=V.config.xaxis.type==="category"?V.globals.dataPoints:A;if(O===0&&A>O&&(O=A),m){var X=O>1?O-1:O;w=V.globals.gridWidth/Math.min(X,A-1),rt=rt+x(0,w)/2+V.config.xaxis.labels.offsetX}else w=V.globals.gridWidth/O,rt=rt+x(0,w)+V.config.xaxis.labels.offsetX;for(var ot=function(ct){var wt=rt-x(ct,w)/2+V.config.xaxis.labels.offsetX;ct===0&&A===1&&w/2===rt&&O===1&&(wt=V.globals.gridWidth/2);var xt=k.axesUtils.getLabel(v,V.globals.timescaleLabels,wt,ct,D,N,c),jt=28;if(V.globals.rotateXLabels&&c&&(jt=22),V.config.xaxis.title.text&&V.config.xaxis.position==="top"&&(jt+=parseFloat(V.config.xaxis.title.style.fontSize)+2),c||(jt=jt+parseFloat(N)+(V.globals.xAxisLabelsHeight-V.globals.xAxisGroupLabelsHeight)+(V.globals.rotateXLabels?10:0)),xt=V.config.xaxis.tickAmount!==void 0&&V.config.xaxis.tickAmount!=="dataPoints"&&V.config.xaxis.type!=="datetime"?k.axesUtils.checkLabelBasedOnTickamount(ct,xt,A):k.axesUtils.checkForOverflowingLabels(ct,xt,A,D,P),V.config.xaxis.labels.show){var ee=u.drawText({x:xt.x,y:k.offY+V.config.xaxis.labels.offsetY+jt-(V.config.xaxis.position==="top"?V.globals.xAxisHeight+V.config.xaxis.axisTicks.height-2:0),text:xt.text,textAnchor:"middle",fontWeight:xt.isBold?600:q,fontSize:N,fontFamily:j,foreColor:Array.isArray(U)?c&&V.config.xaxis.convertedCatToNumeric?U[V.globals.minX+ct-1]:U[ct]:U,isPlainText:!1,cssClass:(c?"apexcharts-xaxis-label ":"apexcharts-xaxis-group-label ")+J});if(d.add(ee),ee.on("click",function(Zt){if(typeof V.config.chart.events.xAxisLabelClick=="function"){var ze=Object.assign({},V,{labelIndex:ct});V.config.chart.events.xAxisLabelClick(Zt,k.ctx,ze)}}),c){var Nt=document.createElementNS(V.globals.SVGNS,"title");Nt.textContent=Array.isArray(xt.text)?xt.text.join(" "):xt.text,ee.node.appendChild(Nt),xt.text!==""&&(D.push(xt.text),P.push(xt))}}ctv.globals.gridWidth)){var x=this.offY+v.config.xaxis.axisTicks.offsetY;if(u=u+x+v.config.xaxis.axisTicks.height,v.config.xaxis.position==="top"&&(u=x-v.config.xaxis.axisTicks.height),v.config.xaxis.axisTicks.show){var w=new $(this.ctx).drawLine(c+v.config.xaxis.axisTicks.offsetX,x+v.config.xaxis.offsetY,m+v.config.xaxis.axisTicks.offsetX,u+v.config.xaxis.offsetY,v.config.xaxis.axisTicks.color);d.add(w),w.node.classList.add("apexcharts-xaxis-tick")}}}},{key:"getXAxisTicksPositions",value:function(){var c=this.w,u=[],d=this.xaxisLabels.length,v=c.globals.padHorizontal;if(c.globals.timescaleLabels.length>0)for(var m=0;m0){var D=m[m.length-1].getBBox(),P=m[0].getBBox();D.x<-20&&m[m.length-1].parentNode.removeChild(m[m.length-1]),P.x+P.width>c.globals.gridWidth&&!c.globals.isBarHorizontal&&m[0].parentNode.removeChild(m[0]);for(var V=0;V0&&(this.xaxisLabels=u.globals.timescaleLabels.slice())}return l(Q,[{key:"drawGridArea",value:function(){var c=arguments.length>0&&arguments[0]!==void 0?arguments[0]:null,u=this.w,d=new $(this.ctx);c===null&&(c=d.group({class:"apexcharts-grid"}));var v=d.drawLine(u.globals.padHorizontal,1,u.globals.padHorizontal,u.globals.gridHeight,"transparent"),m=d.drawLine(u.globals.padHorizontal,u.globals.gridHeight,u.globals.gridWidth,u.globals.gridHeight,"transparent");return c.add(m),c.add(v),c}},{key:"drawGrid",value:function(){var c=null;return this.w.globals.axisCharts&&(c=this.renderGrid(),this.drawGridArea(c.el)),c}},{key:"createGridMask",value:function(){var c=this.w,u=c.globals,d=new $(this.ctx),v=Array.isArray(c.config.stroke.width)?0:c.config.stroke.width;if(Array.isArray(c.config.stroke.width)){var m=0;c.config.stroke.width.forEach(function(P){m=Math.max(m,P)}),v=m}u.dom.elGridRectMask=document.createElementNS(u.SVGNS,"clipPath"),u.dom.elGridRectMask.setAttribute("id","gridRectMask".concat(u.cuid)),u.dom.elGridRectMarkerMask=document.createElementNS(u.SVGNS,"clipPath"),u.dom.elGridRectMarkerMask.setAttribute("id","gridRectMarkerMask".concat(u.cuid)),u.dom.elForecastMask=document.createElementNS(u.SVGNS,"clipPath"),u.dom.elForecastMask.setAttribute("id","forecastMask".concat(u.cuid)),u.dom.elNonForecastMask=document.createElementNS(u.SVGNS,"clipPath"),u.dom.elNonForecastMask.setAttribute("id","nonForecastMask".concat(u.cuid));var x=c.config.chart.type,w=0,k=0;(x==="bar"||x==="rangeBar"||x==="candlestick"||x==="boxPlot"||c.globals.comboBarCount>0)&&c.globals.isXNumeric&&!c.globals.isBarHorizontal&&(w=c.config.grid.padding.left,k=c.config.grid.padding.right,u.barPadForNumericAxis>w&&(w=u.barPadForNumericAxis,k=u.barPadForNumericAxis)),u.dom.elGridRect=d.drawRect(-v/2-w-2,-v/2-2,u.gridWidth+v+k+w+4,u.gridHeight+v+4,0,"#fff");var L=c.globals.markers.largestSize+1;u.dom.elGridRectMarker=d.drawRect(2*-L,2*-L,u.gridWidth+4*L,u.gridHeight+4*L,0,"#fff"),u.dom.elGridRectMask.appendChild(u.dom.elGridRect.node),u.dom.elGridRectMarkerMask.appendChild(u.dom.elGridRectMarker.node);var D=u.dom.baseEl.querySelector("defs");D.appendChild(u.dom.elGridRectMask),D.appendChild(u.dom.elForecastMask),D.appendChild(u.dom.elNonForecastMask),D.appendChild(u.dom.elGridRectMarkerMask)}},{key:"_drawGridLines",value:function(c){var u=c.i,d=c.x1,v=c.y1,m=c.x2,x=c.y2,w=c.xCount,k=c.parent,L=this.w;if(!(u===0&&L.globals.skipFirstTimelinelabel||u===w-1&&L.globals.skipLastTimelinelabel&&!L.config.xaxis.labels.formatter||L.config.chart.type==="radar")){L.config.grid.xaxis.lines.show&&this._drawGridLine({i:u,x1:d,y1:v,x2:m,y2:x,xCount:w,parent:k});var D=0;if(L.globals.hasXaxisGroups&&L.config.xaxis.tickPlacement==="between"){var P=L.globals.groups;if(P){for(var V=0,N=0;V0&&c.config.xaxis.type!=="datetime"&&(m=u.yAxisScale[v].result.length-1)),this._drawXYLines({xCount:m,tickAmount:x})}else m=x,x=u.xTickAmount,this._drawInvertedXYLines({xCount:m,tickAmount:x});return this.drawGridBands(m,x),{el:this.elg,elGridBorders:this.elGridBorders,xAxisTickWidth:u.gridWidth/m}}},{key:"drawGridBands",value:function(c,u){var d=this.w;if(d.config.grid.row.colors!==void 0&&d.config.grid.row.colors.length>0)for(var v=0,m=d.globals.gridHeight/u,x=d.globals.gridWidth,w=0,k=0;w=d.config.grid.row.colors.length&&(k=0),this._drawGridBandRect({c:k,x1:0,y1:v,x2:x,y2:m,type:"row"}),v+=d.globals.gridHeight/u;if(d.config.grid.column.colors!==void 0&&d.config.grid.column.colors.length>0)for(var L=d.globals.isBarHorizontal||d.config.xaxis.tickPlacement!=="on"||d.config.xaxis.type!=="category"&&!d.config.xaxis.convertedCatToNumeric?c:c-1,D=d.globals.padHorizontal,P=d.globals.padHorizontal+d.globals.gridWidth/L,V=d.globals.gridHeight,N=0,j=0;N=d.config.grid.column.colors.length&&(j=0),this._drawGridBandRect({c:j,x1:D,y1:0,x2:P,y2:V,type:"column"}),D+=d.globals.gridWidth/L}}]),Q}(),Ot=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w}return l(Q,[{key:"niceScale",value:function(c,u){var d,v,m,x,w=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0,k=1e-11,L=this.w,D=L.globals;D.isBarHorizontal?(d=L.config.xaxis,v=Math.max((D.svgWidth-100)/25,2)):(d=L.config.yaxis[w],v=Math.max((D.svgHeight-100)/15,2)),m=d.min!==void 0&&d.min!==null,x=d.max!==void 0&&d.min!==null;var P=d.stepSize!==void 0&&d.stepSize!==null,V=d.tickAmount!==void 0&&d.tickAmount!==null,N=V?d.tickAmount:d.forceNiceScale?D.niceScaleDefaultTicks[Math.min(Math.round(v/2),D.niceScaleDefaultTicks.length-1)]:10;if(D.isMultipleYAxis&&!V&&D.multiAxisTickAmount>0&&(N=D.multiAxisTickAmount,V=!0),N=N==="dataPoints"?D.dataPoints-1:Math.abs(Math.round(N)),(c===Number.MIN_VALUE&&u===0||!E.isNumber(c)&&!E.isNumber(u)||c===Number.MIN_VALUE&&u===-Number.MAX_VALUE)&&(c=E.isNumber(d.min)?d.min:0,u=E.isNumber(d.max)?d.max:c+N,D.allSeriesCollapsed=!1),c>u){console.warn("axis.min cannot be greater than axis.max: swapping min and max");var j=u;u=c,c=j}else c===u&&(c=c===0?0:c-1,u=u===0?2:u+1);var U=[];N<1&&(N=1);var q=N,J=Math.abs(u-c);d.forceNiceScale&&(!m&&c>0&&c/J<.15&&(c=0,m=!0),!x&&u<0&&-u/J<.15&&(u=0,x=!0),J=Math.abs(u-c));var rt=J/q,A=rt,O=Math.floor(Math.log10(A)),X=Math.pow(10,O),ot=Math.ceil(A/X);if(rt=A=(ot=D.niceScaleAllowedMagMsd[D.yValueDecimal===0?0:1][ot])*X,D.isBarHorizontal&&d.stepSize&&d.type!=="datetime"?(rt=d.stepSize,P=!0):P&&(rt=d.stepSize),P&&d.forceNiceScale){var nt=Math.floor(Math.log10(rt));rt*=Math.pow(10,O-nt)}if(m&&x){var ct=J/q;if(V)if(P)if(E.mod(J,rt)!=0){var wt=E.getGCD(rt,ct);rt=ct/wt<10?wt:ct}else E.mod(rt,ct)==0?rt=ct:(ct=rt,V=!1);else rt=ct;else if(P)E.mod(J,rt)==0?ct=rt:rt=ct;else if(E.mod(J,rt)==0)ct=rt;else{ct=J/(q=Math.ceil(J/rt));var xt=E.getGCD(J,rt);J/xtv&&(c=u-rt*N,c+=rt*Math.floor((jt-c)/rt))}else if(m)if(V)u=c+rt*q;else{var ee=u;u=rt*Math.ceil(u/rt),Math.abs(u-c)/E.getGCD(J,rt)>v&&(u=c+rt*N,u+=rt*Math.ceil((ee-u)/rt))}}else if(V){var Nt=rt/(u-c>u?1:2),Zt=Nt*Math.floor(c/Nt);Math.abs(Zt-c)<=Nt/2?u=(c=Zt)+rt*q:c=(u=Nt*Math.ceil(u/Nt))-rt*q}else c=rt*Math.floor(c/rt),u=rt*Math.ceil(u/rt);J=Math.abs(u-c),rt=E.getGCD(J,rt),q=Math.round(J/rt)}if(V||m||x||(q=Math.ceil((J-k)/(rt+k)))>16&&E.getPrimeFactors(q).length<2&&q++,!V&&d.forceNiceScale&&D.yValueDecimal===0&&q>J&&(q=J,rt=Math.round(J/q)),q>v&&(!V&&!P||d.forceNiceScale)){var ze=E.getPrimeFactors(q),Te=ze.length-1,Ge=q;t:for(var Ye=0;YeBi);return{result:U,niceMin:U[0],niceMax:U[U.length-1]}}},{key:"linearScale",value:function(c,u){var d=arguments.length>2&&arguments[2]!==void 0?arguments[2]:10,v=arguments.length>3&&arguments[3]!==void 0?arguments[3]:0,m=arguments.length>4&&arguments[4]!==void 0?arguments[4]:void 0,x=Math.abs(u-c),w=[];if(c===u)return{result:w=[c],niceMin:w[0],niceMax:w[w.length-1]};(d=this._adjustTicksForSmallRange(d,v,x))==="dataPoints"&&(d=this.w.globals.dataPoints-1),m||(m=x/d),m=Math.round(10*(m+Number.EPSILON))/10,d===Number.MAX_VALUE&&(d=5,m=1);for(var k=c;d>=0;)w.push(k),k=E.preciseAddition(k,m),d-=1;return{result:w,niceMin:w[0],niceMax:w[w.length-1]}}},{key:"logarithmicScaleNice",value:function(c,u,d){u<=0&&(u=Math.max(c,d)),c<=0&&(c=Math.min(u,d));for(var v=[],m=Math.ceil(Math.log(u)/Math.log(d)+1),x=Math.floor(Math.log(c)/Math.log(d));x5?(v.allSeriesCollapsed=!1,v.yAxisScale[c]=x.forceNiceScale?this.logarithmicScaleNice(u,d,x.logBase):this.logarithmicScale(u,d,x.logBase)):d!==-Number.MAX_VALUE&&E.isNumber(d)&&u!==Number.MAX_VALUE&&E.isNumber(u)?(v.allSeriesCollapsed=!1,v.yAxisScale[c]=this.niceScale(u,d,c)):v.yAxisScale[c]=this.niceScale(Number.MIN_VALUE,0,c)}},{key:"setXScale",value:function(c,u){var d=this.w,v=d.globals,m=Math.abs(u-c);if(u!==-Number.MAX_VALUE&&E.isNumber(u)){var x=v.xTickAmount+1;m<10&&m>1&&(x=m),v.xAxisScale=this.linearScale(c,u,x,0,d.config.xaxis.stepSize)}else v.xAxisScale=this.linearScale(0,10,10);return v.xAxisScale}},{key:"setSeriesYAxisMappings",value:function(){var c=this.w.globals,u=this.w.config,d=[],v=[],m=[],x=c.series.length>u.yaxis.length||u.yaxis.some(function(P){return Array.isArray(P.seriesName)});u.series.forEach(function(P,V){m.push(V),v.push(null)}),u.yaxis.forEach(function(P,V){d[V]=[]});var w=[];u.yaxis.forEach(function(P,V){var N=!1;if(P.seriesName){var j=[];Array.isArray(P.seriesName)?j=P.seriesName:j.push(P.seriesName),j.forEach(function(U){u.series.forEach(function(q,J){if(q.name===U){var rt=J;V===J||x?!x||m.indexOf(J)>-1?d[V].push([V,J]):console.warn("Series '"+q.name+"' referenced more than once in what looks like the new style. That is, when using either seriesName: [], or when there are more series than yaxes."):(d[J].push([J,V]),rt=V),N=!0,(rt=m.indexOf(rt))!==-1&&m.splice(rt,1)}})})}N||w.push(V)}),d=d.map(function(P,V){var N=[];return P.forEach(function(j){v[j[1]]=j[0],N.push(j[1])}),N});for(var k=u.yaxis.length-1,L=0;L0?function(){var D,P,V=Number.MAX_VALUE,N=-Number.MAX_VALUE,j=V,U=N;if(u.chart.stacked)(function(){var rt=d.seriesX[w[0]],A=[],O=[],X=[];L.forEach(function(){A.push(rt.map(function(){return Number.MIN_VALUE})),O.push(rt.map(function(){return Number.MIN_VALUE})),X.push(rt.map(function(){return Number.MIN_VALUE}))});for(var ot=function(ct){!D&&u.series[w[ct]].type&&(D=u.series[w[ct]].type);var wt=w[ct];P=u.series[wt].group?u.series[wt].group:"axis-".concat(k),!(d.collapsedSeriesIndices.indexOf(wt)<0&&d.ancillaryCollapsedSeriesIndices.indexOf(wt)<0)||(d.allSeriesCollapsed=!1,L.forEach(function(xt,jt){if(u.series[wt].group===xt)for(var ee=0;ee=0?O[jt][ee]+=Nt:X[jt][ee]+=Nt,A[jt][ee]+=Nt,j=Math.min(j,Nt),U=Math.max(U,Nt)}})),D!=="bar"&&D!=="column"||d.barGroups.push(P)},nt=0;nt1&&arguments[1]!==void 0?arguments[1]:Number.MAX_VALUE,d=arguments.length>2&&arguments[2]!==void 0?arguments[2]:-Number.MAX_VALUE,v=arguments.length>3&&arguments[3]!==void 0?arguments[3]:null,m=this.w.config,x=this.w.globals,w=-Number.MAX_VALUE,k=Number.MIN_VALUE;v===null&&(v=c+1);var L=x.series,D=L,P=L;m.chart.type==="candlestick"?(D=x.seriesCandleL,P=x.seriesCandleH):m.chart.type==="boxPlot"?(D=x.seriesCandleO,P=x.seriesCandleC):x.isRangeData&&(D=x.seriesRangeStart,P=x.seriesRangeEnd);var V=!1;if(x.seriesX.length>=v){var N,j=(N=x.brushSource)===null||N===void 0?void 0:N.w.config.chart.brush;(m.chart.zoom.enabled&&m.chart.zoom.autoScaleYaxis||j!=null&&j.enabled&&j!=null&&j.autoScaleYaxis)&&(V=!0)}for(var U=c;UJ&&x.seriesX[U][rt]>m.xaxis.max;rt--);}for(var A=J;A<=rt&&AD[U][A]&&D[U][A]<0&&(k=D[U][A])}else x.hasNullValues=!0}q!=="bar"&&q!=="column"||(k<0&&w<0&&(w=0,d=Math.max(d,0)),k===Number.MIN_VALUE&&(k=0,u=Math.min(u,0)))}return m.chart.type==="rangeBar"&&x.seriesRangeStart.length&&x.isBarHorizontal&&(k=u),m.chart.type==="bar"&&(k<0&&w<0&&(w=0),k===Number.MIN_VALUE&&(k=0)),{minY:k,maxY:w,lowestY:u,highestY:d}}},{key:"setYRange",value:function(){var c=this.w.globals,u=this.w.config;c.maxY=-Number.MAX_VALUE,c.minY=Number.MIN_VALUE;var d,v=Number.MAX_VALUE;if(c.isMultipleYAxis){v=Number.MAX_VALUE;for(var m=0;mc.dataPoints&&c.dataPoints!==0&&(v=c.dataPoints-1)):u.xaxis.tickAmount==="dataPoints"?(c.series.length>1&&(v=c.series[c.maxValsInArrayIndex].length-1),c.isXNumeric&&(v=c.maxX-c.minX-1)):v=u.xaxis.tickAmount,c.xTickAmount=v,u.xaxis.max!==void 0&&typeof u.xaxis.max=="number"&&(c.maxX=u.xaxis.max),u.xaxis.min!==void 0&&typeof u.xaxis.min=="number"&&(c.minX=u.xaxis.min),u.xaxis.range!==void 0&&(c.minX=c.maxX-u.xaxis.range),c.minX!==Number.MAX_VALUE&&c.maxX!==-Number.MAX_VALUE)if(u.xaxis.convertedCatToNumeric&&!c.dataFormatXNumeric){for(var m=[],x=c.minX-1;x0&&(c.xAxisScale=this.scales.linearScale(1,c.labels.length,v-1,0,u.xaxis.stepSize),c.seriesX=c.labels.slice());d&&(c.labels=c.xAxisScale.result.slice())}return c.isBarHorizontal&&c.labels.length&&(c.xTickAmount=c.labels.length),this._handleSingleDataPoint(),this._getMinXDiff(),{minX:c.minX,maxX:c.maxX}}},{key:"setZRange",value:function(){var c=this.w.globals;if(c.isDataXYZ){for(var u=0;u0){var w=m-v[x-1];w>0&&(c.minXDiff=Math.min(w,c.minXDiff))}}),c.dataPoints!==1&&c.minXDiff!==Number.MAX_VALUE||(c.minXDiff=.5)})}},{key:"_setStackedMinMax",value:function(){var c=this,u=this.w.globals;if(u.series.length){var d=u.seriesGroups;d.length||(d=[this.w.globals.seriesNames.map(function(x){return x})]);var v={},m={};d.forEach(function(x){v[x]=[],m[x]=[],c.w.config.series.map(function(w,k){return x.indexOf(u.seriesNames[k])>-1?k:null}).filter(function(w){return w!==null}).forEach(function(w){for(var k=0;k0?v[x][k]+=parseFloat(u.series[w][k])+1e-4:m[x][k]+=parseFloat(u.series[w][k]))}})}),Object.entries(v).forEach(function(x){var w=M(x,1)[0];v[w].forEach(function(k,L){u.maxY=Math.max(u.maxY,v[w][L]),u.minY=Math.min(u.minY,m[w][L])})})}}}]),Q}(),Ht=function(){function Q(c,u){a(this,Q),this.ctx=c,this.elgrid=u,this.w=c.w;var d=this.w;this.xaxisFontSize=d.config.xaxis.labels.style.fontSize,this.axisFontFamily=d.config.xaxis.labels.style.fontFamily,this.xaxisForeColors=d.config.xaxis.labels.style.colors,this.isCategoryBarHorizontal=d.config.chart.type==="bar"&&d.config.plotOptions.bar.horizontal,this.xAxisoffX=0,d.config.xaxis.position==="bottom"&&(this.xAxisoffX=d.globals.gridHeight),this.drawnLabels=[],this.axesUtils=new tt(c)}return l(Q,[{key:"drawYaxis",value:function(c){var u=this,d=this.w,v=new $(this.ctx),m=d.config.yaxis[c].labels.style,x=m.fontSize,w=m.fontFamily,k=m.fontWeight,L=v.group({class:"apexcharts-yaxis",rel:c,transform:"translate("+d.globals.translateYAxisX[c]+", 0)"});if(this.axesUtils.isYAxisHidden(c))return L;var D=v.group({class:"apexcharts-yaxis-texts-g"});L.add(D);var P=d.globals.yAxisScale[c].result.length-1,V=d.globals.gridHeight/P,N=d.globals.yLabelFormatters[c],j=d.globals.yAxisScale[c].result.slice();j=this.axesUtils.checkForReversedLabels(c,j);var U="";if(d.config.yaxis[c].labels.show){var q=d.globals.translateY+d.config.yaxis[c].labels.offsetY;d.globals.isBarHorizontal?q=0:d.config.chart.type==="heatmap"&&(q-=V/2),q+=parseInt(d.config.yaxis[c].labels.style.fontSize,10)/3;for(var J=function(wt){var xt=j[wt];xt=N(xt,wt,d);var jt=d.config.yaxis[c].labels.padding;d.config.yaxis[c].opposite&&d.config.yaxis.length!==0&&(jt*=-1);var ee="end";d.config.yaxis[c].opposite&&(ee="start"),d.config.yaxis[c].labels.align==="left"?ee="start":d.config.yaxis[c].labels.align==="center"?ee="middle":d.config.yaxis[c].labels.align==="right"&&(ee="end");var Nt=u.axesUtils.getYAxisForeColor(m.colors,c),Zt=E.listToArray(d.globals.dom.baseEl.querySelectorAll(".apexcharts-yaxis[rel='".concat(c,"'] .apexcharts-yaxis-label tspan"))).map(function(l1){return l1.textContent}),ze=v.drawText({x:jt,y:q,text:Zt.indexOf(xt)>=0?"":xt,textAnchor:ee,fontSize:x,fontFamily:w,fontWeight:k,maxWidth:d.config.yaxis[c].labels.maxWidth,foreColor:Array.isArray(Nt)?Nt[wt]:Nt,isPlainText:!1,cssClass:"apexcharts-yaxis-label "+m.cssClass});wt===P&&(U=ze),D.add(ze);var Te=document.createElementNS(d.globals.SVGNS,"title");if(Te.textContent=Array.isArray(xt)?xt.join(" "):xt,ze.node.appendChild(Te),d.config.yaxis[c].labels.rotate!==0){var Ge=v.rotateAroundCenter(U.node),Ye=v.rotateAroundCenter(ze.node);ze.node.setAttribute("transform","rotate(".concat(d.config.yaxis[c].labels.rotate," ").concat(Ge.x," ").concat(Ye.y,")"))}q+=V},rt=P;rt>=0;rt--)J(rt)}if(d.config.yaxis[c].title.text!==void 0){var A=v.group({class:"apexcharts-yaxis-title"}),O=0;d.config.yaxis[c].opposite&&(O=d.globals.translateYAxisX[c]);var X=v.drawText({x:O,y:d.globals.gridHeight/2+d.globals.translateY+d.config.yaxis[c].title.offsetY,text:d.config.yaxis[c].title.text,textAnchor:"end",foreColor:d.config.yaxis[c].title.style.color,fontSize:d.config.yaxis[c].title.style.fontSize,fontWeight:d.config.yaxis[c].title.style.fontWeight,fontFamily:d.config.yaxis[c].title.style.fontFamily,cssClass:"apexcharts-yaxis-title-text "+d.config.yaxis[c].title.style.cssClass});A.add(X),L.add(A)}var ot=d.config.yaxis[c].axisBorder,nt=31+ot.offsetX;if(d.config.yaxis[c].opposite&&(nt=-31-ot.offsetX),ot.show){var ct=v.drawLine(nt,d.globals.translateY+ot.offsetY-2,nt,d.globals.gridHeight+d.globals.translateY+ot.offsetY+2,ot.color,0,ot.width);L.add(ct)}return d.config.yaxis[c].axisTicks.show&&this.axesUtils.drawYAxisTicks(nt,P,ot,d.config.yaxis[c].axisTicks,c,V,L),L}},{key:"drawYaxisInversed",value:function(c){var u=this.w,d=new $(this.ctx),v=d.group({class:"apexcharts-xaxis apexcharts-yaxis-inversed"}),m=d.group({class:"apexcharts-xaxis-texts-g",transform:"translate(".concat(u.globals.translateXAxisX,", ").concat(u.globals.translateXAxisY,")")});v.add(m);var x=u.globals.yAxisScale[c].result.length-1,w=u.globals.gridWidth/x+.1,k=w+u.config.xaxis.labels.offsetX,L=u.globals.xLabelFormatter,D=u.globals.yAxisScale[c].result.slice(),P=u.globals.timescaleLabels;P.length>0&&(this.xaxisLabels=P.slice(),x=(D=P.slice()).length),D=this.axesUtils.checkForReversedLabels(c,D);var V=P.length;if(u.config.xaxis.labels.show)for(var N=V?0:x;V?N=0;V?N++:N--){var j=D[N];j=L(j,N,u);var U=u.globals.gridWidth+u.globals.padHorizontal-(k-w+u.config.xaxis.labels.offsetX);if(P.length){var q=this.axesUtils.getLabel(D,P,U,N,this.drawnLabels,this.xaxisFontSize);U=q.x,j=q.text,this.drawnLabels.push(q.text),N===0&&u.globals.skipFirstTimelinelabel&&(j=""),N===D.length-1&&u.globals.skipLastTimelinelabel&&(j="")}var J=d.drawText({x:U,y:this.xAxisoffX+u.config.xaxis.labels.offsetY+30-(u.config.xaxis.position==="top"?u.globals.xAxisHeight+u.config.xaxis.axisTicks.height-2:0),text:j,textAnchor:"middle",foreColor:Array.isArray(this.xaxisForeColors)?this.xaxisForeColors[c]:this.xaxisForeColors,fontSize:this.xaxisFontSize,fontFamily:this.xaxisFontFamily,fontWeight:u.config.xaxis.labels.style.fontWeight,isPlainText:!1,cssClass:"apexcharts-xaxis-label "+u.config.xaxis.labels.style.cssClass});m.add(J),J.tspan(j);var rt=document.createElementNS(u.globals.SVGNS,"title");rt.textContent=j,J.node.appendChild(rt),k+=w}return this.inversedYAxisTitleText(v),this.inversedYAxisBorder(v),v}},{key:"inversedYAxisBorder",value:function(c){var u=this.w,d=new $(this.ctx),v=u.config.xaxis.axisBorder;if(v.show){var m=0;u.config.chart.type==="bar"&&u.globals.isXNumeric&&(m-=15);var x=d.drawLine(u.globals.padHorizontal+m+v.offsetX,this.xAxisoffX,u.globals.gridWidth,this.xAxisoffX,v.color,0,v.height);this.elgrid&&this.elgrid.elGridBorders&&u.config.grid.show?this.elgrid.elGridBorders.add(x):c.add(x)}}},{key:"inversedYAxisTitleText",value:function(c){var u=this.w,d=new $(this.ctx);if(u.config.xaxis.title.text!==void 0){var v=d.group({class:"apexcharts-xaxis-title apexcharts-yaxis-title-inversed"}),m=d.drawText({x:u.globals.gridWidth/2+u.config.xaxis.title.offsetX,y:this.xAxisoffX+parseFloat(this.xaxisFontSize)+parseFloat(u.config.xaxis.title.style.fontSize)+u.config.xaxis.title.offsetY+20,text:u.config.xaxis.title.text,textAnchor:"middle",fontSize:u.config.xaxis.title.style.fontSize,fontFamily:u.config.xaxis.title.style.fontFamily,fontWeight:u.config.xaxis.title.style.fontWeight,foreColor:u.config.xaxis.title.style.color,cssClass:"apexcharts-xaxis-title-text "+u.config.xaxis.title.style.cssClass});v.add(m),c.add(v)}}},{key:"yAxisTitleRotate",value:function(c,u){var d=this.w,v=new $(this.ctx),m={width:0,height:0},x={width:0,height:0},w=d.globals.dom.baseEl.querySelector(" .apexcharts-yaxis[rel='".concat(c,"'] .apexcharts-yaxis-texts-g"));w!==null&&(m=w.getBoundingClientRect());var k=d.globals.dom.baseEl.querySelector(".apexcharts-yaxis[rel='".concat(c,"'] .apexcharts-yaxis-title text"));if(k!==null&&(x=k.getBoundingClientRect()),k!==null){var L=this.xPaddingForYAxisTitle(c,m,x,u);k.setAttribute("x",L.xPos-(u?10:0))}if(k!==null){var D=v.rotateAroundCenter(k);k.setAttribute("transform","rotate(".concat(u?-1*d.config.yaxis[c].title.rotate:d.config.yaxis[c].title.rotate," ").concat(D.x," ").concat(D.y,")"))}}},{key:"xPaddingForYAxisTitle",value:function(c,u,d,v){var m=this.w,x=0,w=0,k=10;return m.config.yaxis[c].title.text===void 0||c<0?{xPos:w,padd:0}:(v?(w=u.width+m.config.yaxis[c].title.offsetX+d.width/2+k/2,(x+=1)===0&&(w-=k/2)):(w=-1*u.width+m.config.yaxis[c].title.offsetX+k/2+d.width/2,m.globals.isBarHorizontal&&(k=25,w=-1*u.width-m.config.yaxis[c].title.offsetX-k)),{xPos:w,padd:k})}},{key:"setYAxisXPosition",value:function(c,u){var d=this.w,v=0,m=0,x=18,w=1;d.config.yaxis.length>1&&(this.multipleYs=!0),d.config.yaxis.map(function(k,L){var D=d.globals.ignoreYAxisIndexes.indexOf(L)>-1||!k.show||k.floating||c[L].width===0,P=c[L].width+u[L].width;k.opposite?d.globals.isBarHorizontal?(m=d.globals.gridWidth+d.globals.translateX-1,d.globals.translateYAxisX[L]=m-k.labels.offsetX):(m=d.globals.gridWidth+d.globals.translateX+w,D||(w=w+P+20),d.globals.translateYAxisX[L]=m-k.labels.offsetX+20):(v=d.globals.translateX-x,D||(x=x+P+20),d.globals.translateYAxisX[L]=v+k.labels.offsetX)})}},{key:"setYAxisTextAlignments",value:function(){var c=this.w,u=c.globals.dom.baseEl.getElementsByClassName("apexcharts-yaxis");(u=E.listToArray(u)).forEach(function(d,v){var m=c.config.yaxis[v];if(m&&!m.floating&&m.labels.align!==void 0){var x=c.globals.dom.baseEl.querySelector(".apexcharts-yaxis[rel='".concat(v,"'] .apexcharts-yaxis-texts-g")),w=c.globals.dom.baseEl.querySelectorAll(".apexcharts-yaxis[rel='".concat(v,"'] .apexcharts-yaxis-label"));w=E.listToArray(w);var k=x.getBoundingClientRect();m.labels.align==="left"?(w.forEach(function(L,D){L.setAttribute("text-anchor","start")}),m.opposite||x.setAttribute("transform","translate(-".concat(k.width,", 0)"))):m.labels.align==="center"?(w.forEach(function(L,D){L.setAttribute("text-anchor","middle")}),x.setAttribute("transform","translate(".concat(k.width/2*(m.opposite?1:-1),", 0)"))):m.labels.align==="right"&&(w.forEach(function(L,D){L.setAttribute("text-anchor","end")}),m.opposite&&x.setAttribute("transform","translate(".concat(k.width,", 0)")))}})}}]),Q}(),se=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w,this.documentEvent=E.bind(this.documentEvent,this)}return l(Q,[{key:"addEventListener",value:function(c,u){var d=this.w;d.globals.events.hasOwnProperty(c)?d.globals.events[c].push(u):d.globals.events[c]=[u]}},{key:"removeEventListener",value:function(c,u){var d=this.w;if(d.globals.events.hasOwnProperty(c)){var v=d.globals.events[c].indexOf(u);v!==-1&&d.globals.events[c].splice(v,1)}}},{key:"fireEvent",value:function(c,u){var d=this.w;if(d.globals.events.hasOwnProperty(c)){u&&u.length||(u=[]);for(var v=d.globals.events[c],m=v.length,x=0;x0&&(u=this.w.config.chart.locales.concat(window.Apex.chart.locales));var d=u.filter(function(m){return m.name===c})[0];if(!d)throw new Error("Wrong locale name provided. Please make sure you set the correct locale name in options");var v=E.extend(ht,d);this.w.globals.locale=v.options}}]),Q}(),Kt=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w}return l(Q,[{key:"drawAxis",value:function(c,u){var d,v,m=this,x=this.w.globals,w=this.w.config,k=new $t(this.ctx,u),L=new Ht(this.ctx,u);x.axisCharts&&c!=="radar"&&(x.isBarHorizontal?(v=L.drawYaxisInversed(0),d=k.drawXaxisInversed(0),x.dom.elGraphical.add(d),x.dom.elGraphical.add(v)):(d=k.drawXaxis(),x.dom.elGraphical.add(d),w.yaxis.map(function(D,P){if(x.ignoreYAxisIndexes.indexOf(P)===-1&&(v=L.drawYaxis(P),x.dom.Paper.add(v),m.w.config.grid.position==="back")){var V=x.dom.Paper.children()[1];V.remove(),x.dom.Paper.add(V)}})))}}]),Q}(),fe=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w}return l(Q,[{key:"drawXCrosshairs",value:function(){var c=this.w,u=new $(this.ctx),d=new W(this.ctx),v=c.config.xaxis.crosshairs.fill.gradient,m=c.config.xaxis.crosshairs.dropShadow,x=c.config.xaxis.crosshairs.fill.type,w=v.colorFrom,k=v.colorTo,L=v.opacityFrom,D=v.opacityTo,P=v.stops,V=m.enabled,N=m.left,j=m.top,U=m.blur,q=m.color,J=m.opacity,rt=c.config.xaxis.crosshairs.fill.color;if(c.config.xaxis.crosshairs.show){x==="gradient"&&(rt=u.drawGradient("vertical",w,k,L,D,null,P,null));var A=u.drawRect();c.config.xaxis.crosshairs.width===1&&(A=u.drawLine());var O=c.globals.gridHeight;(!E.isNumber(O)||O<0)&&(O=0);var X=c.config.xaxis.crosshairs.width;(!E.isNumber(X)||X<0)&&(X=0),A.attr({class:"apexcharts-xcrosshairs",x:0,y:0,y2:O,width:X,height:O,fill:rt,filter:"none","fill-opacity":c.config.xaxis.crosshairs.opacity,stroke:c.config.xaxis.crosshairs.stroke.color,"stroke-width":c.config.xaxis.crosshairs.stroke.width,"stroke-dasharray":c.config.xaxis.crosshairs.stroke.dashArray}),V&&(A=d.dropShadow(A,{left:N,top:j,blur:U,color:q,opacity:J})),c.globals.dom.elGraphical.add(A)}}},{key:"drawYCrosshairs",value:function(){var c=this.w,u=new $(this.ctx),d=c.config.yaxis[0].crosshairs,v=c.globals.barPadForNumericAxis;if(c.config.yaxis[0].crosshairs.show){var m=u.drawLine(-v,0,c.globals.gridWidth+v,0,d.stroke.color,d.stroke.dashArray,d.stroke.width);m.attr({class:"apexcharts-ycrosshairs"}),c.globals.dom.elGraphical.add(m)}var x=u.drawLine(-v,0,c.globals.gridWidth+v,0,d.stroke.color,0,0);x.attr({class:"apexcharts-ycrosshairs-hidden"}),c.globals.dom.elGraphical.add(x)}}]),Q}(),ne=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w}return l(Q,[{key:"checkResponsiveConfig",value:function(c){var u=this,d=this.w,v=d.config;if(v.responsive.length!==0){var m=v.responsive.slice();m.sort(function(L,D){return L.breakpoint>D.breakpoint?1:D.breakpoint>L.breakpoint?-1:0}).reverse();var x=new _t({}),w=function(){var L=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},D=m[0].breakpoint,P=window.innerWidth>0?window.innerWidth:screen.width;if(P>D){var V=E.clone(d.globals.initialConfig);V.series=E.clone(d.config.series);var N=G.extendArrayProps(x,V,d);L=E.extend(N,L),L=E.extend(d.config,L),u.overrideResponsiveOptions(L)}else for(var j=0;j0&&typeof d.config.colors[0]=="function"&&(d.globals.colors=d.config.series.map(function(j,U){var q=d.config.colors[U];return q||(q=d.config.colors[0]),typeof q=="function"?(u.isColorFn=!0,q({value:d.globals.axisCharts?d.globals.series[U][0]?d.globals.series[U][0]:0:d.globals.series[U],seriesIndex:U,dataPointIndex:U,w:d})):q}))),d.globals.seriesColors.map(function(j,U){j&&(d.globals.colors[U]=j)}),d.config.theme.monochrome.enabled){var m=[],x=d.globals.series.length;(this.isBarDistributed||this.isHeatmapDistributed)&&(x=d.globals.series[0].length*d.globals.series.length);for(var w=d.config.theme.monochrome.color,k=1/(x/d.config.theme.monochrome.shadeIntensity),L=d.config.theme.monochrome.shadeTo,D=0,P=0;P2&&arguments[2]!==void 0?arguments[2]:null,v=this.w,m=u||v.globals.series.length;if(d===null&&(d=this.isBarDistributed||this.isHeatmapDistributed||v.config.chart.type==="heatmap"&&v.config.plotOptions.heatmap.colorScale.inverse),d&&v.globals.series.length&&(m=v.globals.series[v.globals.maxValsInArrayIndex].length*v.globals.series.length),c.lengthc.globals.svgWidth&&(this.dCtx.lgRect.width=c.globals.svgWidth/1.5),this.dCtx.lgRect}},{key:"getDatalabelsRect",value:function(){var c=this,u=this.w,d=[];u.config.series.forEach(function(k,L){k.data.forEach(function(D,P){var V;V=u.globals.series[L][P],v=u.config.dataLabels.formatter(V,{ctx:c.dCtx.ctx,seriesIndex:L,dataPointIndex:P,w:u}),d.push(v)})});var v=E.getLargestStringFromArr(d),m=new $(this.dCtx.ctx),x=u.config.dataLabels.style,w=m.getTextRects(v,parseInt(x.fontSize),x.fontFamily);return{width:1.05*w.width,height:w.height}}},{key:"getLargestStringFromMultiArr",value:function(c,u){var d=c;if(this.w.globals.isMultiLineX){var v=u.map(function(x,w){return Array.isArray(x)?x.length:1}),m=Math.max.apply(Math,I(v));d=u[v.indexOf(m)]}return d}}]),Q}(),qt=function(){function Q(c){a(this,Q),this.w=c.w,this.dCtx=c}return l(Q,[{key:"getxAxisLabelsCoords",value:function(){var c,u=this.w,d=u.globals.labels.slice();if(u.config.xaxis.convertedCatToNumeric&&d.length===0&&(d=u.globals.categoryLabels),u.globals.timescaleLabels.length>0){var v=this.getxAxisTimeScaleLabelsCoords();c={width:v.width,height:v.height},u.globals.rotateXLabels=!1}else{this.dCtx.lgWidthForSideLegends=u.config.legend.position!=="left"&&u.config.legend.position!=="right"||u.config.legend.floating?0:this.dCtx.lgRect.width;var m=u.globals.xLabelFormatter,x=E.getLargestStringFromArr(d),w=this.dCtx.dimHelpers.getLargestStringFromMultiArr(x,d);u.globals.isBarHorizontal&&(w=x=u.globals.yAxisScale[0].result.reduce(function(j,U){return j.length>U.length?j:U},0));var k=new at(this.dCtx.ctx),L=x;x=k.xLabelFormat(m,x,L,{i:void 0,dateFormatter:new et(this.dCtx.ctx).formatDate,w:u}),w=k.xLabelFormat(m,w,L,{i:void 0,dateFormatter:new et(this.dCtx.ctx).formatDate,w:u}),(u.config.xaxis.convertedCatToNumeric&&x===void 0||String(x).trim()==="")&&(w=x="1");var D=new $(this.dCtx.ctx),P=D.getTextRects(x,u.config.xaxis.labels.style.fontSize),V=P;if(x!==w&&(V=D.getTextRects(w,u.config.xaxis.labels.style.fontSize)),(c={width:P.width>=V.width?P.width:V.width,height:P.height>=V.height?P.height:V.height}).width*d.length>u.globals.svgWidth-this.dCtx.lgWidthForSideLegends-this.dCtx.yAxisWidth-this.dCtx.gridPad.left-this.dCtx.gridPad.right&&u.config.xaxis.labels.rotate!==0||u.config.xaxis.labels.rotateAlways){if(!u.globals.isBarHorizontal){u.globals.rotateXLabels=!0;var N=function(j){return D.getTextRects(j,u.config.xaxis.labels.style.fontSize,u.config.xaxis.labels.style.fontFamily,"rotate(".concat(u.config.xaxis.labels.rotate," 0 0)"),!1)};P=N(x),x!==w&&(V=N(w)),c.height=(P.height>V.height?P.height:V.height)/1.5,c.width=P.width>V.width?P.width:V.width}}else u.globals.rotateXLabels=!1}return u.config.xaxis.labels.show||(c={width:0,height:0}),{width:c.width,height:c.height}}},{key:"getxAxisGroupLabelsCoords",value:function(){var c,u=this.w;if(!u.globals.hasXaxisGroups)return{width:0,height:0};var d,v=((c=u.config.xaxis.group.style)===null||c===void 0?void 0:c.fontSize)||u.config.xaxis.labels.style.fontSize,m=u.globals.groups.map(function(P){return P.title}),x=E.getLargestStringFromArr(m),w=this.dCtx.dimHelpers.getLargestStringFromMultiArr(x,m),k=new $(this.dCtx.ctx),L=k.getTextRects(x,v),D=L;return x!==w&&(D=k.getTextRects(w,v)),d={width:L.width>=D.width?L.width:D.width,height:L.height>=D.height?L.height:D.height},u.config.xaxis.labels.show||(d={width:0,height:0}),{width:d.width,height:d.height}}},{key:"getxAxisTitleCoords",value:function(){var c=this.w,u=0,d=0;if(c.config.xaxis.title.text!==void 0){var v=new $(this.dCtx.ctx).getTextRects(c.config.xaxis.title.text,c.config.xaxis.title.style.fontSize);u=v.width,d=v.height}return{width:u,height:d}}},{key:"getxAxisTimeScaleLabelsCoords",value:function(){var c,u=this.w;this.dCtx.timescaleLabels=u.globals.timescaleLabels.slice();var d=this.dCtx.timescaleLabels.map(function(m){return m.value}),v=d.reduce(function(m,x){return m===void 0?(console.error("You have possibly supplied invalid Date format. Please supply a valid JavaScript Date"),0):m.length>x.length?m:x},0);return 1.05*(c=new $(this.dCtx.ctx).getTextRects(v,u.config.xaxis.labels.style.fontSize)).width*d.length>u.globals.gridWidth&&u.config.xaxis.labels.rotate!==0&&(u.globals.overlappingXLabels=!0),c}},{key:"additionalPaddingXLabels",value:function(c){var u=this,d=this.w,v=d.globals,m=d.config,x=m.xaxis.type,w=c.width;v.skipLastTimelinelabel=!1,v.skipFirstTimelinelabel=!1;var k=d.config.yaxis[0].opposite&&d.globals.isBarHorizontal,L=function(D,P){m.yaxis.length>1&&function(V){return v.collapsedSeriesIndices.indexOf(V)!==-1}(P)||function(V){if(u.dCtx.timescaleLabels&&u.dCtx.timescaleLabels.length){var N=u.dCtx.timescaleLabels[0],j=u.dCtx.timescaleLabels[u.dCtx.timescaleLabels.length-1].position+w/1.75-u.dCtx.yAxisWidthRight,U=N.position-w/1.75+u.dCtx.yAxisWidthLeft,q=d.config.legend.position==="right"&&u.dCtx.lgRect.width>0?u.dCtx.lgRect.width:0;j>v.svgWidth-v.translateX-q&&(v.skipLastTimelinelabel=!0),U<-(V.show&&!V.floating||m.chart.type!=="bar"&&m.chart.type!=="candlestick"&&m.chart.type!=="rangeBar"&&m.chart.type!=="boxPlot"?10:w/1.75)&&(v.skipFirstTimelinelabel=!0)}else x==="datetime"?u.dCtx.gridPad.right((nt=String(P(X,k)))===null||nt===void 0?void 0:nt.length)?O:X},V),j=N=P(N,k);if(N!==void 0&&N.length!==0||(N=L.niceMax),u.globals.isBarHorizontal){v=0;var U=u.globals.labels.slice();N=E.getLargestStringFromArr(U),N=P(N,{seriesIndex:w,dataPointIndex:-1,w:u}),j=c.dCtx.dimHelpers.getLargestStringFromMultiArr(N,U)}var q=new $(c.dCtx.ctx),J="rotate(".concat(x.labels.rotate," 0 0)"),rt=q.getTextRects(N,x.labels.style.fontSize,x.labels.style.fontFamily,J,!1),A=rt;N!==j&&(A=q.getTextRects(j,x.labels.style.fontSize,x.labels.style.fontFamily,J,!1)),d.push({width:(D>A.width||D>rt.width?D:A.width>rt.width?A.width:rt.width)+v,height:A.height>rt.height?A.height:rt.height})}else d.push({width:0,height:0})}),d}},{key:"getyAxisTitleCoords",value:function(){var c=this,u=this.w,d=[];return u.config.yaxis.map(function(v,m){if(v.show&&v.title.text!==void 0){var x=new $(c.dCtx.ctx),w="rotate(".concat(v.title.rotate," 0 0)"),k=x.getTextRects(v.title.text,v.title.style.fontSize,v.title.style.fontFamily,w,!1);d.push({width:k.width,height:k.height})}else d.push({width:0,height:0})}),d}},{key:"getTotalYAxisWidth",value:function(){var c=this.w,u=0,d=0,v=0,m=c.globals.yAxisScale.length>1?10:0,x=new tt(this.dCtx.ctx),w=function(k,L){var D=c.config.yaxis[L].floating,P=0;k.width>0&&!D?(P=k.width+m,function(V){return c.globals.ignoreYAxisIndexes.indexOf(V)>-1}(L)&&(P=P-k.width-m)):P=D||x.isYAxisHidden(L)?0:5,c.config.yaxis[L].opposite?v+=P:d+=P,u+=P};return c.globals.yLabelsCoords.map(function(k,L){w(k,L)}),c.globals.yTitleCoords.map(function(k,L){w(k,L)}),c.globals.isBarHorizontal&&!c.config.yaxis[0].floating&&(u=c.globals.yLabelsCoords[0].width+c.globals.yTitleCoords[0].width+15),this.dCtx.yAxisWidthLeft=d,this.dCtx.yAxisWidthRight=v,u}}]),Q}(),Ie=function(){function Q(c){a(this,Q),this.w=c.w,this.dCtx=c}return l(Q,[{key:"gridPadForColumnsInNumericAxis",value:function(c){var u=this.w,d=u.config,v=u.globals;if(v.noData||v.collapsedSeries.length+v.ancillaryCollapsedSeries.length===d.series.length)return 0;var m=function(N){return N==="bar"||N==="rangeBar"||N==="candlestick"||N==="boxPlot"},x=d.chart.type,w=0,k=m(x)?d.series.length:1;v.comboBarCount>0&&(k=v.comboBarCount),v.collapsedSeries.forEach(function(N){m(N.type)&&(k-=1)}),d.chart.stacked&&(k=1);var L=m(x)||v.comboBarCount>0,D=Math.abs(v.initialMaxX-v.initialMinX);if(L&&v.isXNumeric&&!v.isBarHorizontal&&k>0&&D!==0){var P,V;D<=3&&(D=v.dataPoints),P=D/c,v.minXDiff&&v.minXDiff/P>0&&(V=v.minXDiff/P),V>c/2&&(V/=2),(w=V*parseInt(d.plotOptions.bar.columnWidth,10)/100)<1&&(w=1),v.barPadForNumericAxis=w}return w}},{key:"gridPadFortitleSubtitle",value:function(){var c=this,u=this.w,d=u.globals,v=this.dCtx.isSparkline||!u.globals.axisCharts?0:10;["title","subtitle"].forEach(function(w){u.config[w].text!==void 0?v+=u.config[w].margin:v+=c.dCtx.isSparkline||!u.globals.axisCharts?0:5}),!u.config.legend.show||u.config.legend.position!=="bottom"||u.config.legend.floating||u.globals.axisCharts||(v+=10);var m=this.dCtx.dimHelpers.getTitleSubtitleCoords("title"),x=this.dCtx.dimHelpers.getTitleSubtitleCoords("subtitle");d.gridHeight=d.gridHeight-m.height-x.height-v,d.translateY=d.translateY+m.height+x.height+v}},{key:"setGridXPosForDualYAxis",value:function(c,u){var d=this.w,v=new tt(this.dCtx.ctx);d.config.yaxis.map(function(m,x){d.globals.ignoreYAxisIndexes.indexOf(x)!==-1||m.floating||v.isYAxisHidden(x)||(m.opposite&&(d.globals.translateX=d.globals.translateX-(u[x].width+c[x].width)-parseInt(d.config.yaxis[x].labels.style.fontSize,10)/1.2-12),d.globals.translateX<2&&(d.globals.translateX=2))})}}]),Q}(),Pe=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w,this.lgRect={},this.yAxisWidth=0,this.yAxisWidthLeft=0,this.yAxisWidthRight=0,this.xAxisHeight=0,this.isSparkline=this.w.config.chart.sparkline.enabled,this.dimHelpers=new Wt(this),this.dimYAxis=new Ee(this),this.dimXAxis=new qt(this),this.dimGrid=new Ie(this),this.lgWidthForSideLegends=0,this.gridPad=this.w.config.grid.padding,this.xPadRight=0,this.xPadLeft=0}return l(Q,[{key:"plotCoords",value:function(){var c=this,u=this.w,d=u.globals;this.lgRect=this.dimHelpers.getLegendsRect(),this.datalabelsCoords={width:0,height:0};var v=Array.isArray(u.config.stroke.width)?Math.max.apply(Math,I(u.config.stroke.width)):u.config.stroke.width;this.isSparkline&&((u.config.markers.discrete.length>0||u.config.markers.size>0)&&Object.entries(this.gridPad).forEach(function(x){var w=M(x,2),k=w[0],L=w[1];c.gridPad[k]=Math.max(L,c.w.globals.markers.largestSize/1.5)}),this.gridPad.top=Math.max(v/2,this.gridPad.top),this.gridPad.bottom=Math.max(v/2,this.gridPad.bottom)),d.axisCharts?this.setDimensionsForAxisCharts():this.setDimensionsForNonAxisCharts(),this.dimGrid.gridPadFortitleSubtitle(),d.gridHeight=d.gridHeight-this.gridPad.top-this.gridPad.bottom,d.gridWidth=d.gridWidth-this.gridPad.left-this.gridPad.right-this.xPadRight-this.xPadLeft;var m=this.dimGrid.gridPadForColumnsInNumericAxis(d.gridWidth);d.gridWidth=d.gridWidth-2*m,d.translateX=d.translateX+this.gridPad.left+this.xPadLeft+(m>0?m:0),d.translateY=d.translateY+this.gridPad.top}},{key:"setDimensionsForAxisCharts",value:function(){var c=this,u=this.w,d=u.globals,v=this.dimYAxis.getyAxisLabelsCoords(),m=this.dimYAxis.getyAxisTitleCoords();d.isSlopeChart&&(this.datalabelsCoords=this.dimHelpers.getDatalabelsRect()),u.globals.yLabelsCoords=[],u.globals.yTitleCoords=[],u.config.yaxis.map(function(N,j){u.globals.yLabelsCoords.push({width:v[j].width,index:j}),u.globals.yTitleCoords.push({width:m[j].width,index:j})}),this.yAxisWidth=this.dimYAxis.getTotalYAxisWidth();var x=this.dimXAxis.getxAxisLabelsCoords(),w=this.dimXAxis.getxAxisGroupLabelsCoords(),k=this.dimXAxis.getxAxisTitleCoords();this.conditionalChecksForAxisCoords(x,k,w),d.translateXAxisY=u.globals.rotateXLabels?this.xAxisHeight/8:-4,d.translateXAxisX=u.globals.rotateXLabels&&u.globals.isXNumeric&&u.config.xaxis.labels.rotate<=-45?-this.xAxisWidth/4:0,u.globals.isBarHorizontal&&(d.rotateXLabels=!1,d.translateXAxisY=parseInt(u.config.xaxis.labels.style.fontSize,10)/1.5*-1),d.translateXAxisY=d.translateXAxisY+u.config.xaxis.labels.offsetY,d.translateXAxisX=d.translateXAxisX+u.config.xaxis.labels.offsetX;var L=this.yAxisWidth,D=this.xAxisHeight;d.xAxisLabelsHeight=this.xAxisHeight-k.height,d.xAxisGroupLabelsHeight=d.xAxisLabelsHeight-x.height,d.xAxisLabelsWidth=this.xAxisWidth,d.xAxisHeight=this.xAxisHeight;var P=10;(u.config.chart.type==="radar"||this.isSparkline)&&(L=0,D=d.goldenPadding),this.isSparkline&&(this.lgRect={height:0,width:0}),(this.isSparkline||u.config.chart.type==="treemap")&&(L=0,D=0,P=0),this.isSparkline||this.dimXAxis.additionalPaddingXLabels(x);var V=function(){d.translateX=L+c.datalabelsCoords.width,d.gridHeight=d.svgHeight-c.lgRect.height-D-(c.isSparkline||u.config.chart.type==="treemap"?0:u.globals.rotateXLabels?10:15),d.gridWidth=d.svgWidth-L-2*c.datalabelsCoords.width};switch(u.config.xaxis.position==="top"&&(P=d.xAxisHeight-u.config.xaxis.axisTicks.height-5),u.config.legend.position){case"bottom":d.translateY=P,V();break;case"top":d.translateY=this.lgRect.height+P,V();break;case"left":d.translateY=P,d.translateX=this.lgRect.width+L+this.datalabelsCoords.width,d.gridHeight=d.svgHeight-D-12,d.gridWidth=d.svgWidth-this.lgRect.width-L-2*this.datalabelsCoords.width;break;case"right":d.translateY=P,d.translateX=L+this.datalabelsCoords.width,d.gridHeight=d.svgHeight-D-12,d.gridWidth=d.svgWidth-this.lgRect.width-L-2*this.datalabelsCoords.width-5;break;default:throw new Error("Legend position not supported")}this.dimGrid.setGridXPosForDualYAxis(m,v),new Ht(this.ctx).setYAxisXPosition(v,m)}},{key:"setDimensionsForNonAxisCharts",value:function(){var c=this.w,u=c.globals,d=c.config,v=0;c.config.legend.show&&!c.config.legend.floating&&(v=20);var m=d.chart.type==="pie"||d.chart.type==="polarArea"||d.chart.type==="donut"?"pie":"radialBar",x=d.plotOptions[m].offsetY,w=d.plotOptions[m].offsetX;if(!d.legend.show||d.legend.floating){u.gridHeight=u.svgHeight-d.grid.padding.top-d.grid.padding.bottom;var k=u.dom.elWrap.getBoundingClientRect().width;return u.gridWidth=Math.min(k,u.gridHeight)-d.grid.padding.left-d.grid.padding.right,u.translateY=x,void(u.translateX=w+(u.svgWidth-u.gridWidth)/2)}switch(d.legend.position){case"bottom":u.gridHeight=u.svgHeight-this.lgRect.height-u.goldenPadding,u.gridWidth=u.svgWidth,u.translateY=x-10,u.translateX=w+(u.svgWidth-u.gridWidth)/2;break;case"top":u.gridHeight=u.svgHeight-this.lgRect.height-u.goldenPadding,u.gridWidth=u.svgWidth,u.translateY=this.lgRect.height+x+10,u.translateX=w+(u.svgWidth-u.gridWidth)/2;break;case"left":u.gridWidth=u.svgWidth-this.lgRect.width-v,u.gridHeight=d.chart.height!=="auto"?u.svgHeight:u.gridWidth,u.translateY=x,u.translateX=w+this.lgRect.width+v;break;case"right":u.gridWidth=u.svgWidth-this.lgRect.width-v-5,u.gridHeight=d.chart.height!=="auto"?u.svgHeight:u.gridWidth,u.translateY=x,u.translateX=w+10;break;default:throw new Error("Legend position not supported")}}},{key:"conditionalChecksForAxisCoords",value:function(c,u,d){var v=this.w,m=v.globals.hasXaxisGroups?2:1,x=d.height+c.height+u.height,w=v.globals.isMultiLineX?1.2:v.globals.LINE_HEIGHT_RATIO,k=v.globals.rotateXLabels?22:10,L=v.globals.rotateXLabels&&v.config.legend.position==="bottom"?10:0;this.xAxisHeight=x*w+m*k+L,this.xAxisWidth=c.width,this.xAxisHeight-u.height>v.config.xaxis.labels.maxHeight&&(this.xAxisHeight=v.config.xaxis.labels.maxHeight),v.config.xaxis.labels.minHeight&&this.xAxisHeightP&&(this.yAxisWidth=P)}}]),Q}(),Yt=function(){function Q(c){a(this,Q),this.w=c.w,this.lgCtx=c}return l(Q,[{key:"getLegendStyles",value:function(){var c,u,d,v=document.createElement("style");v.setAttribute("type","text/css");var m=((c=this.lgCtx.ctx)===null||c===void 0||(u=c.opts)===null||u===void 0||(d=u.chart)===null||d===void 0?void 0:d.nonce)||this.w.config.chart.nonce;m&&v.setAttribute("nonce",m);var x=document.createTextNode(` +
`):'
')+"
".concat(v[0],': ')+x+"
"+"
".concat(v[1],': ')+w+"
"+(k?"
".concat(v[2],': ')+k+"
":"")+"
".concat(v[3],': ')+L+"
"+"
".concat(v[4],': ')+D+"
"}}]),Q}(),At=function(){function Q(c){a(this,Q),this.opts=c}return l(Q,[{key:"init",value:function(c){var u=c.responsiveOverride,d=this.opts,v=new lt,m=new _t(d);this.chartType=d.chart.type,d=this.extendYAxis(d),d=this.extendAnnotations(d);var x=v.init(),w={};if(d&&o(d)==="object"){var k,L,D,P,V,N,j,U,q,J,rt={};rt=["line","area","bar","candlestick","boxPlot","rangeBar","rangeArea","bubble","scatter","heatmap","treemap","pie","polarArea","donut","radar","radialBar"].indexOf(d.chart.type)!==-1?m[d.chart.type]():m.line(),(k=d.plotOptions)!==null&&k!==void 0&&(L=k.bar)!==null&&L!==void 0&&L.isFunnel&&(rt=m.funnel()),d.chart.stacked&&d.chart.type==="bar"&&(rt=m.stackedBars()),(D=d.chart.brush)!==null&&D!==void 0&&D.enabled&&(rt=m.brush(rt)),(P=d.plotOptions)!==null&&P!==void 0&&(V=P.line)!==null&&V!==void 0&&V.isSlopeChart&&(rt=m.slope()),d.chart.stacked&&d.chart.stackType==="100%"&&(d=m.stacked100(d)),(N=d.plotOptions)!==null&&N!==void 0&&(j=N.bar)!==null&&j!==void 0&&j.isDumbbell&&(d=m.dumbbell(d)),this.checkForDarkTheme(window.Apex),this.checkForDarkTheme(d),d.xaxis=d.xaxis||window.Apex.xaxis||{},u||(d.xaxis.convertedCatToNumeric=!1),((U=(d=this.checkForCatToNumericXAxis(this.chartType,rt,d)).chart.sparkline)!==null&&U!==void 0&&U.enabled||(q=window.Apex.chart)!==null&&q!==void 0&&(J=q.sparkline)!==null&&J!==void 0&&J.enabled)&&(rt=m.sparkline(rt)),w=E.extend(x,rt)}var A=E.extend(w,window.Apex);return x=E.extend(A,d),x=this.handleUserInputErrors(x)}},{key:"checkForCatToNumericXAxis",value:function(c,u,d){var v,m,x=new _t(d),w=(c==="bar"||c==="boxPlot")&&((v=d.plotOptions)===null||v===void 0||(m=v.bar)===null||m===void 0?void 0:m.horizontal),k=c==="pie"||c==="polarArea"||c==="donut"||c==="radar"||c==="radialBar"||c==="heatmap",L=d.xaxis.type!=="datetime"&&d.xaxis.type!=="numeric",D=d.xaxis.tickPlacement?d.xaxis.tickPlacement:u.xaxis&&u.xaxis.tickPlacement;return w||k||!L||D==="between"||(d=x.convertCatToNumeric(d)),d}},{key:"extendYAxis",value:function(c,u){var d=new lt;(c.yaxis===void 0||!c.yaxis||Array.isArray(c.yaxis)&&c.yaxis.length===0)&&(c.yaxis={}),c.yaxis.constructor!==Array&&window.Apex.yaxis&&window.Apex.yaxis.constructor!==Array&&(c.yaxis=E.extend(c.yaxis,window.Apex.yaxis)),c.yaxis.constructor!==Array?c.yaxis=[E.extend(d.yAxis,c.yaxis)]:c.yaxis=E.extendArray(c.yaxis,d.yAxis);var v=!1;c.yaxis.forEach(function(x){x.logarithmic&&(v=!0)});var m=c.series;return u&&!m&&(m=u.config.series),v&&m.length!==c.yaxis.length&&m.length&&(c.yaxis=m.map(function(x,w){if(x.name||(m[w].name="series-".concat(w+1)),c.yaxis[w])return c.yaxis[w].seriesName=m[w].name,c.yaxis[w];var k=E.extend(d.yAxis,c.yaxis[0]);return k.show=!1,k})),v&&m.length>1&&m.length!==c.yaxis.length&&console.warn("A multi-series logarithmic chart should have equal number of series and y-axes"),c}},{key:"extendAnnotations",value:function(c){return c.annotations===void 0&&(c.annotations={},c.annotations.yaxis=[],c.annotations.xaxis=[],c.annotations.points=[]),c=this.extendYAxisAnnotations(c),c=this.extendXAxisAnnotations(c),c=this.extendPointAnnotations(c)}},{key:"extendYAxisAnnotations",value:function(c){var u=new lt;return c.annotations.yaxis=E.extendArray(c.annotations.yaxis!==void 0?c.annotations.yaxis:[],u.yAxisAnnotation),c}},{key:"extendXAxisAnnotations",value:function(c){var u=new lt;return c.annotations.xaxis=E.extendArray(c.annotations.xaxis!==void 0?c.annotations.xaxis:[],u.xAxisAnnotation),c}},{key:"extendPointAnnotations",value:function(c){var u=new lt;return c.annotations.points=E.extendArray(c.annotations.points!==void 0?c.annotations.points:[],u.pointAnnotation),c}},{key:"checkForDarkTheme",value:function(c){c.theme&&c.theme.mode==="dark"&&(c.tooltip||(c.tooltip={}),c.tooltip.theme!=="light"&&(c.tooltip.theme="dark"),c.chart.foreColor||(c.chart.foreColor="#f6f7f8"),c.theme.palette||(c.theme.palette="palette4"))}},{key:"handleUserInputErrors",value:function(c){var u=c;if(u.tooltip.shared&&u.tooltip.intersect)throw new Error("tooltip.shared cannot be enabled when tooltip.intersect is true. Turn off any other option by setting it to false.");if(u.chart.type==="bar"&&u.plotOptions.bar.horizontal){if(u.yaxis.length>1)throw new Error("Multiple Y Axis for bars are not supported. Switch to column chart by setting plotOptions.bar.horizontal=false");u.yaxis[0].reversed&&(u.yaxis[0].opposite=!0),u.xaxis.tooltip.enabled=!1,u.yaxis[0].tooltip.enabled=!1,u.chart.zoom.enabled=!1}return u.chart.type!=="bar"&&u.chart.type!=="rangeBar"||u.tooltip.shared&&u.xaxis.crosshairs.width==="barWidth"&&u.series.length>1&&(u.xaxis.crosshairs.width="tickWidth"),u.chart.type!=="candlestick"&&u.chart.type!=="boxPlot"||u.yaxis[0].reversed&&(console.warn("Reversed y-axis in ".concat(u.chart.type," chart is not supported.")),u.yaxis[0].reversed=!1),u}}]),Q}(),bt=function(){function Q(){a(this,Q)}return l(Q,[{key:"initGlobalVars",value:function(c){c.series=[],c.seriesCandleO=[],c.seriesCandleH=[],c.seriesCandleM=[],c.seriesCandleL=[],c.seriesCandleC=[],c.seriesRangeStart=[],c.seriesRangeEnd=[],c.seriesRange=[],c.seriesPercent=[],c.seriesGoals=[],c.seriesX=[],c.seriesZ=[],c.seriesNames=[],c.seriesTotals=[],c.seriesLog=[],c.seriesColors=[],c.stackedSeriesTotals=[],c.seriesXvalues=[],c.seriesYvalues=[],c.labels=[],c.hasXaxisGroups=!1,c.groups=[],c.barGroups=[],c.lineGroups=[],c.areaGroups=[],c.hasSeriesGroups=!1,c.seriesGroups=[],c.categoryLabels=[],c.timescaleLabels=[],c.noLabelsProvided=!1,c.resizeTimer=null,c.selectionResizeTimer=null,c.delayedElements=[],c.pointsArray=[],c.dataLabelsRects=[],c.isXNumeric=!1,c.skipLastTimelinelabel=!1,c.skipFirstTimelinelabel=!1,c.isDataXYZ=!1,c.isMultiLineX=!1,c.isMultipleYAxis=!1,c.maxY=-Number.MAX_VALUE,c.minY=Number.MIN_VALUE,c.minYArr=[],c.maxYArr=[],c.maxX=-Number.MAX_VALUE,c.minX=Number.MAX_VALUE,c.initialMaxX=-Number.MAX_VALUE,c.initialMinX=Number.MAX_VALUE,c.maxDate=0,c.minDate=Number.MAX_VALUE,c.minZ=Number.MAX_VALUE,c.maxZ=-Number.MAX_VALUE,c.minXDiff=Number.MAX_VALUE,c.yAxisScale=[],c.xAxisScale=null,c.xAxisTicksPositions=[],c.yLabelsCoords=[],c.yTitleCoords=[],c.barPadForNumericAxis=0,c.padHorizontal=0,c.xRange=0,c.yRange=[],c.zRange=0,c.dataPoints=0,c.xTickAmount=0,c.multiAxisTickAmount=0}},{key:"globalVars",value:function(c){return{chartID:null,cuid:null,events:{beforeMount:[],mounted:[],updated:[],clicked:[],selection:[],dataPointSelection:[],zoomed:[],scrolled:[]},colors:[],clientX:null,clientY:null,fill:{colors:[]},stroke:{colors:[]},dataLabels:{style:{colors:[]}},radarPolygons:{fill:{colors:[]}},markers:{colors:[],size:c.markers.size,largestSize:0},animationEnded:!1,isTouchDevice:"ontouchstart"in window||navigator.msMaxTouchPoints,isDirty:!1,isExecCalled:!1,initialConfig:null,initialSeries:[],lastXAxis:[],lastYAxis:[],columnSeries:null,labels:[],timescaleLabels:[],noLabelsProvided:!1,allSeriesCollapsed:!1,collapsedSeries:[],collapsedSeriesIndices:[],ancillaryCollapsedSeries:[],ancillaryCollapsedSeriesIndices:[],risingSeries:[],dataFormatXNumeric:!1,capturedSeriesIndex:-1,capturedDataPointIndex:-1,selectedDataPoints:[],goldenPadding:35,invalidLogScale:!1,ignoreYAxisIndexes:[],maxValsInArrayIndex:0,radialSize:0,selection:void 0,zoomEnabled:c.chart.toolbar.autoSelected==="zoom"&&c.chart.toolbar.tools.zoom&&c.chart.zoom.enabled,panEnabled:c.chart.toolbar.autoSelected==="pan"&&c.chart.toolbar.tools.pan,selectionEnabled:c.chart.toolbar.autoSelected==="selection"&&c.chart.toolbar.tools.selection,yaxis:null,mousedown:!1,lastClientPosition:{},visibleXRange:void 0,yValueDecimal:0,total:0,SVGNS:"http://www.w3.org/2000/svg",svgWidth:0,svgHeight:0,noData:!1,locale:{},dom:{},memory:{methodsToExec:[]},shouldAnimate:!0,skipLastTimelinelabel:!1,skipFirstTimelinelabel:!1,delayedElements:[],axisCharts:!0,isDataXYZ:!1,isSlopeChart:c.plotOptions.line.isSlopeChart,resized:!1,resizeTimer:null,comboCharts:!1,dataChanged:!1,previousPaths:[],allSeriesHasEqualX:!0,pointsArray:[],dataLabelsRects:[],lastDrawnDataLabelsIndexes:[],hasNullValues:!1,easing:null,zoomed:!1,gridWidth:0,gridHeight:0,rotateXLabels:!1,defaultLabels:!1,xLabelFormatter:void 0,yLabelFormatters:[],xaxisTooltipFormatter:void 0,ttKeyFormatter:void 0,ttVal:void 0,ttZFormatter:void 0,LINE_HEIGHT_RATIO:1.618,xAxisLabelsHeight:0,xAxisGroupLabelsHeight:0,xAxisLabelsWidth:0,yAxisLabelsWidth:0,scaleX:1,scaleY:1,translateX:0,translateY:0,translateYAxisX:[],yAxisWidths:[],translateXAxisY:0,translateXAxisX:0,tooltip:null,niceScaleAllowedMagMsd:[[1,1,2,5,5,5,10,10,10,10,10],[1,1,2,5,5,5,10,10,10,10,10]],niceScaleDefaultTicks:[1,2,4,4,6,6,6,6,6,6,6,6,6,6,6,6,6,6,12,12,12,12,12,12,12,12,12,24],seriesYAxisMap:[],seriesYAxisReverseMap:[]}}},{key:"init",value:function(c){var u=this.globalVars(c);return this.initGlobalVars(u),u.initialConfig=E.extend({},c),u.initialSeries=E.clone(c.series),u.lastXAxis=E.clone(u.initialConfig.xaxis),u.lastYAxis=E.clone(u.initialConfig.yaxis),u}}]),Q}(),kt=function(){function Q(c){a(this,Q),this.opts=c}return l(Q,[{key:"init",value:function(){var c=new At(this.opts).init({responsiveOverride:!1});return{config:c,globals:new bt().init(c)}}}]),Q}(),Lt=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w,this.opts=null,this.seriesIndex=0}return l(Q,[{key:"clippedImgArea",value:function(c){var u=this.w,d=u.config,v=parseInt(u.globals.gridWidth,10),m=parseInt(u.globals.gridHeight,10),x=v>m?v:m,w=c.image,k=0,L=0;c.width===void 0&&c.height===void 0?d.fill.image.width!==void 0&&d.fill.image.height!==void 0?(k=d.fill.image.width+1,L=d.fill.image.height):(k=x+1,L=x):(k=c.width,L=c.height);var D=document.createElementNS(u.globals.SVGNS,"pattern");$.setAttrs(D,{id:c.patternID,patternUnits:c.patternUnits?c.patternUnits:"userSpaceOnUse",width:k+"px",height:L+"px"});var P=document.createElementNS(u.globals.SVGNS,"image");D.appendChild(P),P.setAttributeNS(window.SVG.xlink,"href",w),$.setAttrs(P,{x:0,y:0,preserveAspectRatio:"none",width:k+"px",height:L+"px"}),P.style.opacity=c.opacity,u.globals.dom.elDefs.node.appendChild(D)}},{key:"getSeriesIndex",value:function(c){var u=this.w,d=u.config.chart.type;return(d==="bar"||d==="rangeBar")&&u.config.plotOptions.bar.distributed||d==="heatmap"||d==="treemap"?this.seriesIndex=c.seriesNumber:this.seriesIndex=c.seriesNumber%u.globals.series.length,this.seriesIndex}},{key:"fillPath",value:function(c){var u=this.w;this.opts=c;var d,v,m,x=this.w.config;this.seriesIndex=this.getSeriesIndex(c);var w=this.getFillColors()[this.seriesIndex];u.globals.seriesColors[this.seriesIndex]!==void 0&&(w=u.globals.seriesColors[this.seriesIndex]),typeof w=="function"&&(w=w({seriesIndex:this.seriesIndex,dataPointIndex:c.dataPointIndex,value:c.value,w:u}));var k=c.fillType?c.fillType:this.getFillType(this.seriesIndex),L=Array.isArray(x.fill.opacity)?x.fill.opacity[this.seriesIndex]:x.fill.opacity;c.color&&(w=c.color),w||(w="#fff",console.warn("undefined color - ApexCharts"));var D=w;if(w.indexOf("rgb")===-1?w.length<9&&(D=E.hexToRgba(w,L)):w.indexOf("rgba")>-1&&(L=E.getOpacityFromRGBA(w)),c.opacity&&(L=c.opacity),k==="pattern"&&(v=this.handlePatternFill({fillConfig:c.fillConfig,patternFill:v,fillColor:w,fillOpacity:L,defaultColor:D})),k==="gradient"&&(m=this.handleGradientFill({fillConfig:c.fillConfig,fillColor:w,fillOpacity:L,i:this.seriesIndex})),k==="image"){var P=x.fill.image.src,V=c.patternID?c.patternID:"";this.clippedImgArea({opacity:L,image:Array.isArray(P)?c.seriesNumber-1&&(N=E.getOpacityFromRGBA(V));var j=x.gradient.opacityTo===void 0?d:Array.isArray(x.gradient.opacityTo)?x.gradient.opacityTo[m]:x.gradient.opacityTo;if(x.gradient.gradientToColors===void 0||x.gradient.gradientToColors.length===0)w=x.gradient.shade==="dark"?D.shadeColor(-1*parseFloat(x.gradient.shadeIntensity),u.indexOf("rgb")>-1?E.rgb2hex(u):u):D.shadeColor(parseFloat(x.gradient.shadeIntensity),u.indexOf("rgb")>-1?E.rgb2hex(u):u);else if(x.gradient.gradientToColors[k.seriesNumber]){var U=x.gradient.gradientToColors[k.seriesNumber];w=U,U.indexOf("rgba")>-1&&(j=E.getOpacityFromRGBA(U))}else w=u;if(x.gradient.gradientFrom&&(V=x.gradient.gradientFrom),x.gradient.gradientTo&&(w=x.gradient.gradientTo),x.gradient.inverseColors){var q=V;V=w,w=q}return V.indexOf("rgb")>-1&&(V=E.rgb2hex(V)),w.indexOf("rgb")>-1&&(w=E.rgb2hex(w)),L.drawGradient(P,V,w,N,j,k.size,x.gradient.stops,x.gradient.colorStops,m)}}]),Q}(),Vt=function(){function Q(c,u){a(this,Q),this.ctx=c,this.w=c.w}return l(Q,[{key:"setGlobalMarkerSize",value:function(){var c=this.w;if(c.globals.markers.size=Array.isArray(c.config.markers.size)?c.config.markers.size:[c.config.markers.size],c.globals.markers.size.length>0){if(c.globals.markers.size.length4&&arguments[4]!==void 0&&arguments[4],w=this.w,k=u,L=c,D=null,P=new $(this.ctx),V=w.config.markers.discrete&&w.config.markers.discrete.length;if((w.globals.markers.size[u]>0||x||V)&&(D=P.group({class:x||V?"":"apexcharts-series-markers"})).attr("clip-path","url(#gridRectMarkerMask".concat(w.globals.cuid,")")),Array.isArray(L.x))for(var N=0;N0:w.config.markers.size>0)||x||V){E.isNumber(L.y[N])?U+=" w".concat(E.randomId()):U="apexcharts-nullpoint";var q=this.getMarkerConfig({cssClass:U,seriesIndex:u,dataPointIndex:j});w.config.series[k].data[j]&&(w.config.series[k].data[j].fillColor&&(q.pointFillColor=w.config.series[k].data[j].fillColor),w.config.series[k].data[j].strokeColor&&(q.pointStrokeColor=w.config.series[k].data[j].strokeColor)),v!==void 0&&(q.pSize=v),(L.x[N]<-w.globals.markers.largestSize||L.x[N]>w.globals.gridWidth+w.globals.markers.largestSize||L.y[N]<-w.globals.markers.largestSize||L.y[N]>w.globals.gridHeight+w.globals.markers.largestSize)&&(q.pSize=0),(m=P.drawMarker(L.x[N],L.y[N],q)).attr("rel",j),m.attr("j",j),m.attr("index",u),m.node.setAttribute("default-marker-size",q.pSize),new W(this.ctx).setSelectionFilter(m,u,j),this.addEvents(m),D&&D.add(m)}else w.globals.pointsArray[u]===void 0&&(w.globals.pointsArray[u]=[]),w.globals.pointsArray[u].push([L.x[N],L.y[N]])}return D}},{key:"getMarkerConfig",value:function(c){var u=c.cssClass,d=c.seriesIndex,v=c.dataPointIndex,m=v===void 0?null:v,x=c.radius,w=x===void 0?null:x,k=c.size,L=k===void 0?null:k,D=c.strokeWidth,P=D===void 0?null:D,V=this.w,N=this.getMarkerStyle(d),j=L===null?V.globals.markers.size[d]:L,U=V.config.markers;return m!==null&&U.discrete.length&&U.discrete.map(function(q){q.seriesIndex===d&&q.dataPointIndex===m&&(N.pointStrokeColor=q.strokeColor,N.pointFillColor=q.fillColor,j=q.size,N.pointShape=q.shape)}),{pSize:w===null?j:w,pRadius:w!==null?w:U.radius,pointStrokeWidth:P!==null?P:Array.isArray(U.strokeWidth)?U.strokeWidth[d]:U.strokeWidth,pointStrokeColor:N.pointStrokeColor,pointFillColor:N.pointFillColor,shape:N.pointShape||(Array.isArray(U.shape)?U.shape[d]:U.shape),class:u,pointStrokeOpacity:Array.isArray(U.strokeOpacity)?U.strokeOpacity[d]:U.strokeOpacity,pointStrokeDashArray:Array.isArray(U.strokeDashArray)?U.strokeDashArray[d]:U.strokeDashArray,pointFillOpacity:Array.isArray(U.fillOpacity)?U.fillOpacity[d]:U.fillOpacity,seriesIndex:d}}},{key:"addEvents",value:function(c){var u=this.w,d=new $(this.ctx);c.node.addEventListener("mouseenter",d.pathMouseEnter.bind(this.ctx,c)),c.node.addEventListener("mouseleave",d.pathMouseLeave.bind(this.ctx,c)),c.node.addEventListener("mousedown",d.pathMouseDown.bind(this.ctx,c)),c.node.addEventListener("click",u.config.markers.onClick),c.node.addEventListener("dblclick",u.config.markers.onDblClick),c.node.addEventListener("touchstart",d.pathMouseDown.bind(this.ctx,c),{passive:!0})}},{key:"getMarkerStyle",value:function(c){var u=this.w,d=u.globals.markers.colors,v=u.config.markers.strokeColor||u.config.markers.strokeColors;return{pointStrokeColor:Array.isArray(v)?v[c]:v,pointFillColor:Array.isArray(d)?d[c]:d}}}]),Q}(),Rt=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w,this.initialAnim=this.w.config.chart.animations.enabled}return l(Q,[{key:"draw",value:function(c,u,d){var v=this.w,m=new $(this.ctx),x=d.realIndex,w=d.pointsPos,k=d.zRatio,L=d.elParent,D=m.group({class:"apexcharts-series-markers apexcharts-series-".concat(v.config.chart.type)});if(D.attr("clip-path","url(#gridRectMarkerMask".concat(v.globals.cuid,")")),Array.isArray(w.x))for(var P=0;PU.maxBubbleRadius&&(j=U.maxBubbleRadius)}var q=w.x[P],J=w.y[P];if(j=j||0,J!==null&&v.globals.series[x][V]!==void 0||(N=!1),N){var rt=this.drawPoint(q,J,j,x,V,u);D.add(rt)}L.add(D)}}},{key:"drawPoint",value:function(c,u,d,v,m,x){var w=this.w,k=v,L=new R(this.ctx),D=new W(this.ctx),P=new Lt(this.ctx),V=new Vt(this.ctx),N=new $(this.ctx),j=V.getMarkerConfig({cssClass:"apexcharts-marker",seriesIndex:k,dataPointIndex:m,radius:w.config.chart.type==="bubble"||w.globals.comboCharts&&w.config.series[v]&&w.config.series[v].type==="bubble"?d:null}),U=P.fillPath({seriesNumber:v,dataPointIndex:m,color:j.pointFillColor,patternUnits:"objectBoundingBox",value:w.globals.series[v][x]}),q=N.drawMarker(c,u,j);if(w.config.series[k].data[m]&&w.config.series[k].data[m].fillColor&&(U=w.config.series[k].data[m].fillColor),q.attr({fill:U}),w.config.chart.dropShadow.enabled){var J=w.config.chart.dropShadow;D.dropShadow(q,J,v)}if(!this.initialAnim||w.globals.dataChanged||w.globals.resized)w.globals.animationEnded=!0;else{var rt=w.config.chart.animations.speed;L.animateMarker(q,rt,w.globals.easing,function(){window.setTimeout(function(){L.animationCompleted(q)},100)})}return q.attr({rel:m,j:m,index:v,"default-marker-size":j.pSize}),D.setSelectionFilter(q,v,m),V.addEvents(q),q.node.classList.add("apexcharts-marker"),q}},{key:"centerTextInBubble",value:function(c){var u=this.w;return{y:c+=parseInt(u.config.dataLabels.style.fontSize,10)/4}}}]),Q}(),Ut=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w}return l(Q,[{key:"dataLabelsCorrection",value:function(c,u,d,v,m,x,w){var k=this.w,L=!1,D=new $(this.ctx).getTextRects(d,w),P=D.width,V=D.height;u<0&&(u=0),u>k.globals.gridHeight+V&&(u=k.globals.gridHeight+V/2),k.globals.dataLabelsRects[v]===void 0&&(k.globals.dataLabelsRects[v]=[]),k.globals.dataLabelsRects[v].push({x:c,y:u,width:P,height:V});var N=k.globals.dataLabelsRects[v].length-2,j=k.globals.lastDrawnDataLabelsIndexes[v]!==void 0?k.globals.lastDrawnDataLabelsIndexes[v][k.globals.lastDrawnDataLabelsIndexes[v].length-1]:0;if(k.globals.dataLabelsRects[v][N]!==void 0){var U=k.globals.dataLabelsRects[v][j];(c>U.x+U.width||u>U.y+U.height||u+Vu.globals.gridWidth+rt.textRects.width+30)&&(k="");var A=u.globals.dataLabels.style.colors[x];((u.config.chart.type==="bar"||u.config.chart.type==="rangeBar")&&u.config.plotOptions.bar.distributed||u.config.dataLabels.distributed)&&(A=u.globals.dataLabels.style.colors[w]),typeof A=="function"&&(A=A({series:u.globals.series,seriesIndex:x,dataPointIndex:w,w:u})),N&&(A=N);var O=V.offsetX,X=V.offsetY;if(u.config.chart.type!=="bar"&&u.config.chart.type!=="rangeBar"||(O=0,X=0),u.globals.isSlopeChart&&(w!==0&&(O=-2*V.offsetX+5),w!==0&&w!==u.config.series[x].data.length-1&&(O=0)),rt.drawnextLabel){if((J=d.drawText({width:100,height:parseInt(V.style.fontSize,10),x:v+O,y:m+X,foreColor:A,textAnchor:L||V.textAnchor,text:k,fontSize:D||V.style.fontSize,fontFamily:V.style.fontFamily,fontWeight:V.style.fontWeight||"normal"})).attr({class:q||"apexcharts-datalabel",cx:v,cy:m}),V.dropShadow.enabled){var ot=V.dropShadow;new W(this.ctx).dropShadow(J,ot)}P.add(J),u.globals.lastDrawnDataLabelsIndexes[x]===void 0&&(u.globals.lastDrawnDataLabelsIndexes[x]=[]),u.globals.lastDrawnDataLabelsIndexes[x].push(w)}return J}},{key:"addBackgroundToDataLabel",value:function(c,u){var d=this.w,v=d.config.dataLabels.background,m=v.padding,x=v.padding/2,w=u.width,k=u.height,L=new $(this.ctx).drawRect(u.x-m,u.y-x/2,w+2*m,k+x,v.borderRadius,d.config.chart.background!=="transparent"&&d.config.chart.background?d.config.chart.background:"#fff",v.opacity,v.borderWidth,v.borderColor);return v.dropShadow.enabled&&new W(this.ctx).dropShadow(L,v.dropShadow),L}},{key:"dataLabelsBackground",value:function(){var c=this.w;if(c.config.chart.type!=="bubble")for(var u=c.globals.dom.baseEl.querySelectorAll(".apexcharts-datalabels text"),d=0;d0&&arguments[0]!==void 0)||arguments[0],u=!(arguments.length>1&&arguments[1]!==void 0)||arguments[1],d=!(arguments.length>2&&arguments[2]!==void 0)||arguments[2],v=this.w,m=E.clone(v.globals.initialSeries);v.globals.previousPaths=[],d?(v.globals.collapsedSeries=[],v.globals.ancillaryCollapsedSeries=[],v.globals.collapsedSeriesIndices=[],v.globals.ancillaryCollapsedSeriesIndices=[]):m=this.emptyCollapsedSeries(m),v.config.series=m,c&&(u&&(v.globals.zoomed=!1,this.ctx.updateHelpers.revertDefaultAxisMinMax()),this.ctx.updateHelpers._updateSeries(m,v.config.chart.animations.dynamicAnimation.enabled))}},{key:"emptyCollapsedSeries",value:function(c){for(var u=this.w,d=0;d-1&&(c[d].data=[]);return c}},{key:"toggleSeriesOnHover",value:function(c,u){var d=this.w;u||(u=c.target);var v=d.globals.dom.baseEl.querySelectorAll(".apexcharts-series, .apexcharts-datalabels, .apexcharts-yaxis");if(c.type==="mousemove"){var m=parseInt(u.getAttribute("rel"),10)-1,x=null,w=null,k=null;if(d.globals.axisCharts||d.config.chart.type==="radialBar")if(d.globals.axisCharts){x=d.globals.dom.baseEl.querySelector(".apexcharts-series[data\\:realIndex='".concat(m,"']")),w=d.globals.dom.baseEl.querySelector(".apexcharts-datalabels[data\\:realIndex='".concat(m,"']"));var L=d.globals.seriesYAxisReverseMap[m];k=d.globals.dom.baseEl.querySelector(".apexcharts-yaxis[rel='".concat(L,"']"))}else x=d.globals.dom.baseEl.querySelector(".apexcharts-series[rel='".concat(m+1,"']"));else x=d.globals.dom.baseEl.querySelector(".apexcharts-series[rel='".concat(m+1,"'] path"));for(var D=0;D=k.from&&D<=k.to&&m[L].classList.remove(d.legendInactiveClass)}}(v.config.plotOptions.heatmap.colorScale.ranges[w])}else c.type==="mouseout"&&x("remove")}},{key:"getActiveConfigSeriesIndex",value:function(){var c=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"asc",u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],d=this.w,v=0;if(d.config.series.length>1){for(var m=d.config.series.map(function(w,k){return w.data&&w.data.length>0&&d.globals.collapsedSeriesIndices.indexOf(k)===-1&&(!d.globals.comboCharts||u.length===0||u.length&&u.indexOf(d.config.series[k].type)>-1)?k:-1}),x=c==="asc"?0:m.length-1;c==="asc"?x=0;c==="asc"?x++:x--)if(m[x]!==-1){v=m[x];break}}return v}},{key:"getBarSeriesIndices",value:function(){return this.w.globals.comboCharts?this.w.config.series.map(function(c,u){return c.type==="bar"||c.type==="column"?u:-1}).filter(function(c){return c!==-1}):this.w.config.series.map(function(c,u){return u})}},{key:"getPreviousPaths",value:function(){var c=this.w;function u(x,w,k){for(var L=x[w].childNodes,D={type:k,paths:[],realIndex:x[w].getAttribute("data:realIndex")},P=0;P0)for(var v=function(x){for(var w=c.globals.dom.baseEl.querySelectorAll(".apexcharts-".concat(c.config.chart.type," .apexcharts-series[data\\:realIndex='").concat(x,"'] rect")),k=[],L=function(P){var V=function(j){return w[P].getAttribute(j)},N={x:parseFloat(V("x")),y:parseFloat(V("y")),width:parseFloat(V("width")),height:parseFloat(V("height"))};k.push({rect:N,color:w[P].getAttribute("color")})},D=0;D0)for(var v=0;v0?u:[]});return c}}]),Q}(),It=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w,this.twoDSeries=[],this.threeDSeries=[],this.twoDSeriesX=[],this.seriesGoals=[],this.coreUtils=new G(this.ctx)}return l(Q,[{key:"isMultiFormat",value:function(){return this.isFormatXY()||this.isFormat2DArray()}},{key:"isFormatXY",value:function(){var c=this.w.config.series.slice(),u=new Kt(this.ctx);if(this.activeSeriesIndex=u.getActiveConfigSeriesIndex(),c[this.activeSeriesIndex].data!==void 0&&c[this.activeSeriesIndex].data.length>0&&c[this.activeSeriesIndex].data[0]!==null&&c[this.activeSeriesIndex].data[0].x!==void 0&&c[this.activeSeriesIndex].data[0]!==null)return!0}},{key:"isFormat2DArray",value:function(){var c=this.w.config.series.slice(),u=new Kt(this.ctx);if(this.activeSeriesIndex=u.getActiveConfigSeriesIndex(),c[this.activeSeriesIndex].data!==void 0&&c[this.activeSeriesIndex].data.length>0&&c[this.activeSeriesIndex].data[0]!==void 0&&c[this.activeSeriesIndex].data[0]!==null&&c[this.activeSeriesIndex].data[0].constructor===Array)return!0}},{key:"handleFormat2DArray",value:function(c,u){for(var d=this.w.config,v=this.w.globals,m=d.chart.type==="boxPlot"||d.series[u].type==="boxPlot",x=0;x=5?this.twoDSeries.push(E.parseNumber(c[u].data[x][4])):this.twoDSeries.push(E.parseNumber(c[u].data[x][1])),v.dataFormatXNumeric=!0),d.xaxis.type==="datetime"){var w=new Date(c[u].data[x][0]);w=new Date(w).getTime(),this.twoDSeriesX.push(w)}else this.twoDSeriesX.push(c[u].data[x][0]);for(var k=0;k-1&&(x=this.activeSeriesIndex);for(var w=0;w1&&arguments[1]!==void 0?arguments[1]:this.ctx,v=this.w.config,m=this.w.globals,x=new et(d),w=v.labels.length>0?v.labels.slice():v.xaxis.categories.slice();m.isRangeBar=v.chart.type==="rangeBar"&&m.isBarHorizontal,m.hasXaxisGroups=v.xaxis.type==="category"&&v.xaxis.group.groups.length>0,m.hasXaxisGroups&&(m.groups=v.xaxis.group.groups),c.forEach(function(N,j){N.name!==void 0?m.seriesNames.push(N.name):m.seriesNames.push("series-"+parseInt(j+1,10))}),this.coreUtils.setSeriesYAxisMappings();var k=[],L=I(new Set(v.series.map(function(N){return N.group})));v.series.forEach(function(N,j){var U=L.indexOf(N.group);k[U]||(k[U]=[]),k[U].push(m.seriesNames[j])}),m.seriesGroups=k;for(var D=function(){for(var N=0;N0&&(this.twoDSeriesX=w,m.seriesX.push(this.twoDSeriesX))),m.labels.push(this.twoDSeriesX);var V=c[P].data.map(function(N){return E.parseNumber(N)});m.series.push(V)}m.seriesZ.push(this.threeDSeries),c[P].color!==void 0?m.seriesColors.push(c[P].color):m.seriesColors.push(void 0)}return this.w}},{key:"parseDataNonAxisCharts",value:function(c){var u=this.w.globals,d=this.w.config;u.series=c.slice(),u.seriesNames=d.labels.slice();for(var v=0;v0?d.labels=u.xaxis.categories:u.labels.length>0?d.labels=u.labels.slice():this.fallbackToCategory?(d.labels=d.labels[0],d.seriesRange.length&&(d.seriesRange.map(function(v){v.forEach(function(m){d.labels.indexOf(m.x)<0&&m.x&&d.labels.push(m.x)})}),d.labels=Array.from(new Set(d.labels.map(JSON.stringify)),JSON.parse)),u.xaxis.convertedCatToNumeric&&(new _t(u).convertCatToNumericXaxis(u,this.ctx,d.seriesX[0]),this._generateExternalLabels(c))):this._generateExternalLabels(c)}},{key:"_generateExternalLabels",value:function(c){var u=this.w.globals,d=this.w.config,v=[];if(u.axisCharts){if(u.series.length>0)if(this.isFormatXY())for(var m=d.series.map(function(P,V){return P.data.filter(function(N,j,U){return U.findIndex(function(q){return q.x===N.x})===j})}),x=m.reduce(function(P,V,N,j){return j[P].length>V.length?P:N},0),w=0;w0&&m==d.length&&u.push(v)}),c.globals.ignoreYAxisIndexes=u.map(function(d){return d})}}]),Q}(),le=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w}return l(Q,[{key:"scaleSvgNode",value:function(c,u){var d=parseFloat(c.getAttributeNS(null,"width")),v=parseFloat(c.getAttributeNS(null,"height"));c.setAttributeNS(null,"width",d*u),c.setAttributeNS(null,"height",v*u),c.setAttributeNS(null,"viewBox","0 0 "+d+" "+v)}},{key:"fixSvgStringForIe11",value:function(c){if(!E.isIE11())return c.replace(/ /g," ");var u=0,d=c.replace(/xmlns="http:\/\/www.w3.org\/2000\/svg"/g,function(v){return++u===2?'xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:svgjs="http://svgjs.dev"':v});return d=(d=d.replace(/xmlns:NS\d+=""/g,"")).replace(/NS\d+:(\w+:\w+=")/g,"$1")}},{key:"getSvgString",value:function(c){c==null&&(c=1);var u=this.w.globals.dom.Paper.svg();if(c!==1){var d=this.w.globals.dom.Paper.node.cloneNode(!0);this.scaleSvgNode(d,c),u=new XMLSerializer().serializeToString(d)}return this.fixSvgStringForIe11(u)}},{key:"cleanup",value:function(){var c=this.w,u=c.globals.dom.baseEl.getElementsByClassName("apexcharts-xcrosshairs"),d=c.globals.dom.baseEl.getElementsByClassName("apexcharts-ycrosshairs"),v=c.globals.dom.baseEl.querySelectorAll(".apexcharts-zoom-rect, .apexcharts-selection-rect");Array.prototype.forEach.call(v,function(m){m.setAttribute("width",0)}),u&&u[0]&&(u[0].setAttribute("x",-500),u[0].setAttribute("x1",-500),u[0].setAttribute("x2",-500)),d&&d[0]&&(d[0].setAttribute("y",-100),d[0].setAttribute("y1",-100),d[0].setAttribute("y2",-100))}},{key:"svgUrl",value:function(){this.cleanup();var c=this.getSvgString(),u=new Blob([c],{type:"image/svg+xml;charset=utf-8"});return URL.createObjectURL(u)}},{key:"dataURI",value:function(c){var u=this;return new Promise(function(d){var v=u.w,m=c?c.scale||c.width/v.globals.svgWidth:1;u.cleanup();var x=document.createElement("canvas");x.width=v.globals.svgWidth*m,x.height=parseInt(v.globals.dom.elWrap.style.height,10)*m;var w=v.config.chart.background!=="transparent"&&v.config.chart.background?v.config.chart.background:"#fff",k=x.getContext("2d");k.fillStyle=w,k.fillRect(0,0,x.width*m,x.height*m);var L=u.getSvgString(m);if(window.canvg&&E.isIE11()){var D=window.canvg.Canvg.fromString(k,L,{ignoreClear:!0,ignoreDimensions:!0});D.start();var P=x.msToBlob();D.stop(),d({blob:P})}else{var V="data:image/svg+xml,"+encodeURIComponent(L),N=new Image;N.crossOrigin="anonymous",N.onload=function(){if(k.drawImage(N,0,0),x.msToBlob){var j=x.msToBlob();d({blob:j})}else{var U=x.toDataURL("image/png");d({imgURI:U})}},N.src=V}})}},{key:"exportToSVG",value:function(){this.triggerDownload(this.svgUrl(),this.w.config.chart.toolbar.export.svg.filename,".svg")}},{key:"exportToPng",value:function(){var c=this;this.dataURI().then(function(u){var d=u.imgURI,v=u.blob;v?navigator.msSaveOrOpenBlob(v,c.w.globals.chartID+".png"):c.triggerDownload(d,c.w.config.chart.toolbar.export.png.filename,".png")})}},{key:"exportToCSV",value:function(c){var u=this,d=c.series,v=c.fileName,m=c.columnDelimiter,x=m===void 0?",":m,w=c.lineDelimiter,k=w===void 0?` +`:w,L=this.w;d||(d=L.config.series);var D,P,V=[],N=[],j="",U=L.globals.series.map(function(nt,ct){return L.globals.collapsedSeriesIndices.indexOf(ct)===-1?nt:[]}),q=function(nt){return typeof L.config.chart.toolbar.export.csv.categoryFormatter=="function"?L.config.chart.toolbar.export.csv.categoryFormatter(nt):L.config.xaxis.type==="datetime"&&String(nt).length>=10?new Date(nt).toDateString():E.isNumber(nt)?nt:nt.split(x).join("")},J=function(nt){return typeof L.config.chart.toolbar.export.csv.valueFormatter=="function"?L.config.chart.toolbar.export.csv.valueFormatter(nt):nt},rt=Math.max.apply(Math,I(d.map(function(nt){return nt.data?nt.data.length:0}))),A=new It(this.ctx),O=new tt(this.ctx),X=function(nt){var ct="";if(L.globals.axisCharts){if(L.config.xaxis.type==="category"||L.config.xaxis.convertedCatToNumeric)if(L.globals.isBarHorizontal){var Ct=L.globals.yLabelFormatters[0],xt=new Kt(u.ctx).getActiveConfigSeriesIndex();ct=Ct(L.globals.labels[nt],{seriesIndex:xt,dataPointIndex:nt,w:L})}else ct=O.getLabel(L.globals.labels,L.globals.timescaleLabels,0,nt).text;L.config.xaxis.type==="datetime"&&(L.config.xaxis.categories.length?ct=L.config.xaxis.categories[nt]:L.config.labels.length&&(ct=L.config.labels[nt]))}else ct=L.config.labels[nt];return ct===null?"nullvalue":(Array.isArray(ct)&&(ct=ct.join(" ")),E.isNumber(ct)?ct:ct.split(x).join(""))},ot=function(nt,ct){if(V.length&&ct===0&&N.push(V.join(x)),nt.data){nt.data=nt.data.length&&nt.data||I(Array(rt)).map(function(){return""});for(var Ct=0;Ct0&&!d.globals.isBarHorizontal&&(this.xaxisLabels=d.globals.timescaleLabels.slice()),d.config.xaxis.overwriteCategories&&(this.xaxisLabels=d.config.xaxis.overwriteCategories),this.drawnLabels=[],this.drawnLabelsRects=[],d.config.xaxis.position==="top"?this.offY=0:this.offY=d.globals.gridHeight,this.offY=this.offY+d.config.xaxis.axisBorder.offsetY,this.isCategoryBarHorizontal=d.config.chart.type==="bar"&&d.config.plotOptions.bar.horizontal,this.xaxisFontSize=d.config.xaxis.labels.style.fontSize,this.xaxisFontFamily=d.config.xaxis.labels.style.fontFamily,this.xaxisForeColors=d.config.xaxis.labels.style.colors,this.xaxisBorderWidth=d.config.xaxis.axisBorder.width,this.isCategoryBarHorizontal&&(this.xaxisBorderWidth=d.config.yaxis[0].axisBorder.width.toString()),this.xaxisBorderWidth.indexOf("%")>-1?this.xaxisBorderWidth=d.globals.gridWidth*parseInt(this.xaxisBorderWidth,10)/100:this.xaxisBorderWidth=parseInt(this.xaxisBorderWidth,10),this.xaxisBorderHeight=d.config.xaxis.axisBorder.height,this.yaxis=d.config.yaxis[0]}return l(Q,[{key:"drawXaxis",value:function(){var c=this.w,u=new $(this.ctx),d=u.group({class:"apexcharts-xaxis",transform:"translate(".concat(c.config.xaxis.offsetX,", ").concat(c.config.xaxis.offsetY,")")}),v=u.group({class:"apexcharts-xaxis-texts-g",transform:"translate(".concat(c.globals.translateXAxisX,", ").concat(c.globals.translateXAxisY,")")});d.add(v);for(var m=[],x=0;x6&&arguments[6]!==void 0?arguments[6]:{},D=[],P=[],V=this.w,N=L.xaxisFontSize||this.xaxisFontSize,j=L.xaxisFontFamily||this.xaxisFontFamily,U=L.xaxisForeColors||this.xaxisForeColors,q=L.fontWeight||V.config.xaxis.labels.style.fontWeight,J=L.cssClass||V.config.xaxis.labels.style.cssClass,rt=V.globals.padHorizontal,A=v.length,O=V.config.xaxis.type==="category"?V.globals.dataPoints:A;if(O===0&&A>O&&(O=A),m){var X=O>1?O-1:O;w=V.globals.gridWidth/Math.min(X,A-1),rt=rt+x(0,w)/2+V.config.xaxis.labels.offsetX}else w=V.globals.gridWidth/O,rt=rt+x(0,w)+V.config.xaxis.labels.offsetX;for(var ot=function(ct){var Ct=rt-x(ct,w)/2+V.config.xaxis.labels.offsetX;ct===0&&A===1&&w/2===rt&&O===1&&(Ct=V.globals.gridWidth/2);var xt=k.axesUtils.getLabel(v,V.globals.timescaleLabels,Ct,ct,D,N,c),$t=28;if(V.globals.rotateXLabels&&c&&($t=22),V.config.xaxis.title.text&&V.config.xaxis.position==="top"&&($t+=parseFloat(V.config.xaxis.title.style.fontSize)+2),c||($t=$t+parseFloat(N)+(V.globals.xAxisLabelsHeight-V.globals.xAxisGroupLabelsHeight)+(V.globals.rotateXLabels?10:0)),xt=V.config.xaxis.tickAmount!==void 0&&V.config.xaxis.tickAmount!=="dataPoints"&&V.config.xaxis.type!=="datetime"?k.axesUtils.checkLabelBasedOnTickamount(ct,xt,A):k.axesUtils.checkForOverflowingLabels(ct,xt,A,D,P),V.config.xaxis.labels.show){var re=u.drawText({x:xt.x,y:k.offY+V.config.xaxis.labels.offsetY+$t-(V.config.xaxis.position==="top"?V.globals.xAxisHeight+V.config.xaxis.axisTicks.height-2:0),text:xt.text,textAnchor:"middle",fontWeight:xt.isBold?600:q,fontSize:N,fontFamily:j,foreColor:Array.isArray(U)?c&&V.config.xaxis.convertedCatToNumeric?U[V.globals.minX+ct-1]:U[ct]:U,isPlainText:!1,cssClass:(c?"apexcharts-xaxis-label ":"apexcharts-xaxis-group-label ")+J});if(d.add(re),re.on("click",function(Qt){if(typeof V.config.chart.events.xAxisLabelClick=="function"){var Me=Object.assign({},V,{labelIndex:ct});V.config.chart.events.xAxisLabelClick(Qt,k.ctx,Me)}}),c){var Ot=document.createElementNS(V.globals.SVGNS,"title");Ot.textContent=Array.isArray(xt.text)?xt.text.join(" "):xt.text,re.node.appendChild(Ot),xt.text!==""&&(D.push(xt.text),P.push(xt))}}ctv.globals.gridWidth)){var x=this.offY+v.config.xaxis.axisTicks.offsetY;if(u=u+x+v.config.xaxis.axisTicks.height,v.config.xaxis.position==="top"&&(u=x-v.config.xaxis.axisTicks.height),v.config.xaxis.axisTicks.show){var w=new $(this.ctx).drawLine(c+v.config.xaxis.axisTicks.offsetX,x+v.config.xaxis.offsetY,m+v.config.xaxis.axisTicks.offsetX,u+v.config.xaxis.offsetY,v.config.xaxis.axisTicks.color);d.add(w),w.node.classList.add("apexcharts-xaxis-tick")}}}},{key:"getXAxisTicksPositions",value:function(){var c=this.w,u=[],d=this.xaxisLabels.length,v=c.globals.padHorizontal;if(c.globals.timescaleLabels.length>0)for(var m=0;m0){var D=m[m.length-1].getBBox(),P=m[0].getBBox();D.x<-20&&m[m.length-1].parentNode.removeChild(m[m.length-1]),P.x+P.width>c.globals.gridWidth&&!c.globals.isBarHorizontal&&m[0].parentNode.removeChild(m[0]);for(var V=0;V0&&(this.xaxisLabels=u.globals.timescaleLabels.slice())}return l(Q,[{key:"drawGridArea",value:function(){var c=arguments.length>0&&arguments[0]!==void 0?arguments[0]:null,u=this.w,d=new $(this.ctx);c===null&&(c=d.group({class:"apexcharts-grid"}));var v=d.drawLine(u.globals.padHorizontal,1,u.globals.padHorizontal,u.globals.gridHeight,"transparent"),m=d.drawLine(u.globals.padHorizontal,u.globals.gridHeight,u.globals.gridWidth,u.globals.gridHeight,"transparent");return c.add(m),c.add(v),c}},{key:"drawGrid",value:function(){var c=null;return this.w.globals.axisCharts&&(c=this.renderGrid(),this.drawGridArea(c.el)),c}},{key:"createGridMask",value:function(){var c=this.w,u=c.globals,d=new $(this.ctx),v=Array.isArray(c.config.stroke.width)?0:c.config.stroke.width;if(Array.isArray(c.config.stroke.width)){var m=0;c.config.stroke.width.forEach(function(P){m=Math.max(m,P)}),v=m}u.dom.elGridRectMask=document.createElementNS(u.SVGNS,"clipPath"),u.dom.elGridRectMask.setAttribute("id","gridRectMask".concat(u.cuid)),u.dom.elGridRectMarkerMask=document.createElementNS(u.SVGNS,"clipPath"),u.dom.elGridRectMarkerMask.setAttribute("id","gridRectMarkerMask".concat(u.cuid)),u.dom.elForecastMask=document.createElementNS(u.SVGNS,"clipPath"),u.dom.elForecastMask.setAttribute("id","forecastMask".concat(u.cuid)),u.dom.elNonForecastMask=document.createElementNS(u.SVGNS,"clipPath"),u.dom.elNonForecastMask.setAttribute("id","nonForecastMask".concat(u.cuid));var x=c.config.chart.type,w=0,k=0;(x==="bar"||x==="rangeBar"||x==="candlestick"||x==="boxPlot"||c.globals.comboBarCount>0)&&c.globals.isXNumeric&&!c.globals.isBarHorizontal&&(w=c.config.grid.padding.left,k=c.config.grid.padding.right,u.barPadForNumericAxis>w&&(w=u.barPadForNumericAxis,k=u.barPadForNumericAxis)),u.dom.elGridRect=d.drawRect(-v/2-w-2,-v/2-2,u.gridWidth+v+k+w+4,u.gridHeight+v+4,0,"#fff");var L=c.globals.markers.largestSize+1;u.dom.elGridRectMarker=d.drawRect(2*-L,2*-L,u.gridWidth+4*L,u.gridHeight+4*L,0,"#fff"),u.dom.elGridRectMask.appendChild(u.dom.elGridRect.node),u.dom.elGridRectMarkerMask.appendChild(u.dom.elGridRectMarker.node);var D=u.dom.baseEl.querySelector("defs");D.appendChild(u.dom.elGridRectMask),D.appendChild(u.dom.elForecastMask),D.appendChild(u.dom.elNonForecastMask),D.appendChild(u.dom.elGridRectMarkerMask)}},{key:"_drawGridLines",value:function(c){var u=c.i,d=c.x1,v=c.y1,m=c.x2,x=c.y2,w=c.xCount,k=c.parent,L=this.w;if(!(u===0&&L.globals.skipFirstTimelinelabel||u===w-1&&L.globals.skipLastTimelinelabel&&!L.config.xaxis.labels.formatter||L.config.chart.type==="radar")){L.config.grid.xaxis.lines.show&&this._drawGridLine({i:u,x1:d,y1:v,x2:m,y2:x,xCount:w,parent:k});var D=0;if(L.globals.hasXaxisGroups&&L.config.xaxis.tickPlacement==="between"){var P=L.globals.groups;if(P){for(var V=0,N=0;V0&&c.config.xaxis.type!=="datetime"&&(m=u.yAxisScale[v].result.length-1)),this._drawXYLines({xCount:m,tickAmount:x})}else m=x,x=u.xTickAmount,this._drawInvertedXYLines({xCount:m,tickAmount:x});return this.drawGridBands(m,x),{el:this.elg,elGridBorders:this.elGridBorders,xAxisTickWidth:u.gridWidth/m}}},{key:"drawGridBands",value:function(c,u){var d=this.w;if(d.config.grid.row.colors!==void 0&&d.config.grid.row.colors.length>0)for(var v=0,m=d.globals.gridHeight/u,x=d.globals.gridWidth,w=0,k=0;w=d.config.grid.row.colors.length&&(k=0),this._drawGridBandRect({c:k,x1:0,y1:v,x2:x,y2:m,type:"row"}),v+=d.globals.gridHeight/u;if(d.config.grid.column.colors!==void 0&&d.config.grid.column.colors.length>0)for(var L=d.globals.isBarHorizontal||d.config.xaxis.tickPlacement!=="on"||d.config.xaxis.type!=="category"&&!d.config.xaxis.convertedCatToNumeric?c:c-1,D=d.globals.padHorizontal,P=d.globals.padHorizontal+d.globals.gridWidth/L,V=d.globals.gridHeight,N=0,j=0;N=d.config.grid.column.colors.length&&(j=0),this._drawGridBandRect({c:j,x1:D,y1:0,x2:P,y2:V,type:"column"}),D+=d.globals.gridWidth/L}}]),Q}(),Ft=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w}return l(Q,[{key:"niceScale",value:function(c,u){var d,v,m,x,w=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0,k=1e-11,L=this.w,D=L.globals;D.isBarHorizontal?(d=L.config.xaxis,v=Math.max((D.svgWidth-100)/25,2)):(d=L.config.yaxis[w],v=Math.max((D.svgHeight-100)/15,2)),m=d.min!==void 0&&d.min!==null,x=d.max!==void 0&&d.min!==null;var P=d.stepSize!==void 0&&d.stepSize!==null,V=d.tickAmount!==void 0&&d.tickAmount!==null,N=V?d.tickAmount:d.forceNiceScale?D.niceScaleDefaultTicks[Math.min(Math.round(v/2),D.niceScaleDefaultTicks.length-1)]:10;if(D.isMultipleYAxis&&!V&&D.multiAxisTickAmount>0&&(N=D.multiAxisTickAmount,V=!0),N=N==="dataPoints"?D.dataPoints-1:Math.abs(Math.round(N)),(c===Number.MIN_VALUE&&u===0||!E.isNumber(c)&&!E.isNumber(u)||c===Number.MIN_VALUE&&u===-Number.MAX_VALUE)&&(c=E.isNumber(d.min)?d.min:0,u=E.isNumber(d.max)?d.max:c+N,D.allSeriesCollapsed=!1),c>u){console.warn("axis.min cannot be greater than axis.max: swapping min and max");var j=u;u=c,c=j}else c===u&&(c=c===0?0:c-1,u=u===0?2:u+1);var U=[];N<1&&(N=1);var q=N,J=Math.abs(u-c);d.forceNiceScale&&(!m&&c>0&&c/J<.15&&(c=0,m=!0),!x&&u<0&&-u/J<.15&&(u=0,x=!0),J=Math.abs(u-c));var rt=J/q,A=rt,O=Math.floor(Math.log10(A)),X=Math.pow(10,O),ot=Math.ceil(A/X);if(rt=A=(ot=D.niceScaleAllowedMagMsd[D.yValueDecimal===0?0:1][ot])*X,D.isBarHorizontal&&d.stepSize&&d.type!=="datetime"?(rt=d.stepSize,P=!0):P&&(rt=d.stepSize),P&&d.forceNiceScale){var nt=Math.floor(Math.log10(rt));rt*=Math.pow(10,O-nt)}if(m&&x){var ct=J/q;if(V)if(P)if(E.mod(J,rt)!=0){var Ct=E.getGCD(rt,ct);rt=ct/Ct<10?Ct:ct}else E.mod(rt,ct)==0?rt=ct:(ct=rt,V=!1);else rt=ct;else if(P)E.mod(J,rt)==0?ct=rt:rt=ct;else if(E.mod(J,rt)==0)ct=rt;else{ct=J/(q=Math.ceil(J/rt));var xt=E.getGCD(J,rt);J/xtv&&(c=u-rt*N,c+=rt*Math.floor(($t-c)/rt))}else if(m)if(V)u=c+rt*q;else{var re=u;u=rt*Math.ceil(u/rt),Math.abs(u-c)/E.getGCD(J,rt)>v&&(u=c+rt*N,u+=rt*Math.ceil((re-u)/rt))}}else if(V){var Ot=rt/(u-c>u?1:2),Qt=Ot*Math.floor(c/Ot);Math.abs(Qt-c)<=Ot/2?u=(c=Qt)+rt*q:c=(u=Ot*Math.ceil(u/Ot))-rt*q}else c=rt*Math.floor(c/rt),u=rt*Math.ceil(u/rt);J=Math.abs(u-c),rt=E.getGCD(J,rt),q=Math.round(J/rt)}if(V||m||x||(q=Math.ceil((J-k)/(rt+k)))>16&&E.getPrimeFactors(q).length<2&&q++,!V&&d.forceNiceScale&&D.yValueDecimal===0&&q>J&&(q=J,rt=Math.round(J/q)),q>v&&(!V&&!P||d.forceNiceScale)){var Me=E.getPrimeFactors(q),Te=Me.length-1,Ge=q;t:for(var Ye=0;YeRi);return{result:U,niceMin:U[0],niceMax:U[U.length-1]}}},{key:"linearScale",value:function(c,u){var d=arguments.length>2&&arguments[2]!==void 0?arguments[2]:10,v=arguments.length>3&&arguments[3]!==void 0?arguments[3]:0,m=arguments.length>4&&arguments[4]!==void 0?arguments[4]:void 0,x=Math.abs(u-c),w=[];if(c===u)return{result:w=[c],niceMin:w[0],niceMax:w[w.length-1]};(d=this._adjustTicksForSmallRange(d,v,x))==="dataPoints"&&(d=this.w.globals.dataPoints-1),m||(m=x/d),m=Math.round(10*(m+Number.EPSILON))/10,d===Number.MAX_VALUE&&(d=5,m=1);for(var k=c;d>=0;)w.push(k),k=E.preciseAddition(k,m),d-=1;return{result:w,niceMin:w[0],niceMax:w[w.length-1]}}},{key:"logarithmicScaleNice",value:function(c,u,d){u<=0&&(u=Math.max(c,d)),c<=0&&(c=Math.min(u,d));for(var v=[],m=Math.ceil(Math.log(u)/Math.log(d)+1),x=Math.floor(Math.log(c)/Math.log(d));x5?(v.allSeriesCollapsed=!1,v.yAxisScale[c]=x.forceNiceScale?this.logarithmicScaleNice(u,d,x.logBase):this.logarithmicScale(u,d,x.logBase)):d!==-Number.MAX_VALUE&&E.isNumber(d)&&u!==Number.MAX_VALUE&&E.isNumber(u)?(v.allSeriesCollapsed=!1,v.yAxisScale[c]=this.niceScale(u,d,c)):v.yAxisScale[c]=this.niceScale(Number.MIN_VALUE,0,c)}},{key:"setXScale",value:function(c,u){var d=this.w,v=d.globals,m=Math.abs(u-c);if(u!==-Number.MAX_VALUE&&E.isNumber(u)){var x=v.xTickAmount+1;m<10&&m>1&&(x=m),v.xAxisScale=this.linearScale(c,u,x,0,d.config.xaxis.stepSize)}else v.xAxisScale=this.linearScale(0,10,10);return v.xAxisScale}},{key:"setSeriesYAxisMappings",value:function(){var c=this.w.globals,u=this.w.config,d=[],v=[],m=[],x=c.series.length>u.yaxis.length||u.yaxis.some(function(P){return Array.isArray(P.seriesName)});u.series.forEach(function(P,V){m.push(V),v.push(null)}),u.yaxis.forEach(function(P,V){d[V]=[]});var w=[];u.yaxis.forEach(function(P,V){var N=!1;if(P.seriesName){var j=[];Array.isArray(P.seriesName)?j=P.seriesName:j.push(P.seriesName),j.forEach(function(U){u.series.forEach(function(q,J){if(q.name===U){var rt=J;V===J||x?!x||m.indexOf(J)>-1?d[V].push([V,J]):console.warn("Series '"+q.name+"' referenced more than once in what looks like the new style. That is, when using either seriesName: [], or when there are more series than yaxes."):(d[J].push([J,V]),rt=V),N=!0,(rt=m.indexOf(rt))!==-1&&m.splice(rt,1)}})})}N||w.push(V)}),d=d.map(function(P,V){var N=[];return P.forEach(function(j){v[j[1]]=j[0],N.push(j[1])}),N});for(var k=u.yaxis.length-1,L=0;L0?function(){var D,P,V=Number.MAX_VALUE,N=-Number.MAX_VALUE,j=V,U=N;if(u.chart.stacked)(function(){var rt=d.seriesX[w[0]],A=[],O=[],X=[];L.forEach(function(){A.push(rt.map(function(){return Number.MIN_VALUE})),O.push(rt.map(function(){return Number.MIN_VALUE})),X.push(rt.map(function(){return Number.MIN_VALUE}))});for(var ot=function(ct){!D&&u.series[w[ct]].type&&(D=u.series[w[ct]].type);var Ct=w[ct];P=u.series[Ct].group?u.series[Ct].group:"axis-".concat(k),!(d.collapsedSeriesIndices.indexOf(Ct)<0&&d.ancillaryCollapsedSeriesIndices.indexOf(Ct)<0)||(d.allSeriesCollapsed=!1,L.forEach(function(xt,$t){if(u.series[Ct].group===xt)for(var re=0;re=0?O[$t][re]+=Ot:X[$t][re]+=Ot,A[$t][re]+=Ot,j=Math.min(j,Ot),U=Math.max(U,Ot)}})),D!=="bar"&&D!=="column"||d.barGroups.push(P)},nt=0;nt1&&arguments[1]!==void 0?arguments[1]:Number.MAX_VALUE,d=arguments.length>2&&arguments[2]!==void 0?arguments[2]:-Number.MAX_VALUE,v=arguments.length>3&&arguments[3]!==void 0?arguments[3]:null,m=this.w.config,x=this.w.globals,w=-Number.MAX_VALUE,k=Number.MIN_VALUE;v===null&&(v=c+1);var L=x.series,D=L,P=L;m.chart.type==="candlestick"?(D=x.seriesCandleL,P=x.seriesCandleH):m.chart.type==="boxPlot"?(D=x.seriesCandleO,P=x.seriesCandleC):x.isRangeData&&(D=x.seriesRangeStart,P=x.seriesRangeEnd);var V=!1;if(x.seriesX.length>=v){var N,j=(N=x.brushSource)===null||N===void 0?void 0:N.w.config.chart.brush;(m.chart.zoom.enabled&&m.chart.zoom.autoScaleYaxis||j!=null&&j.enabled&&j!=null&&j.autoScaleYaxis)&&(V=!0)}for(var U=c;UJ&&x.seriesX[U][rt]>m.xaxis.max;rt--);}for(var A=J;A<=rt&&AD[U][A]&&D[U][A]<0&&(k=D[U][A])}else x.hasNullValues=!0}q!=="bar"&&q!=="column"||(k<0&&w<0&&(w=0,d=Math.max(d,0)),k===Number.MIN_VALUE&&(k=0,u=Math.min(u,0)))}return m.chart.type==="rangeBar"&&x.seriesRangeStart.length&&x.isBarHorizontal&&(k=u),m.chart.type==="bar"&&(k<0&&w<0&&(w=0),k===Number.MIN_VALUE&&(k=0)),{minY:k,maxY:w,lowestY:u,highestY:d}}},{key:"setYRange",value:function(){var c=this.w.globals,u=this.w.config;c.maxY=-Number.MAX_VALUE,c.minY=Number.MIN_VALUE;var d,v=Number.MAX_VALUE;if(c.isMultipleYAxis){v=Number.MAX_VALUE;for(var m=0;mc.dataPoints&&c.dataPoints!==0&&(v=c.dataPoints-1)):u.xaxis.tickAmount==="dataPoints"?(c.series.length>1&&(v=c.series[c.maxValsInArrayIndex].length-1),c.isXNumeric&&(v=c.maxX-c.minX-1)):v=u.xaxis.tickAmount,c.xTickAmount=v,u.xaxis.max!==void 0&&typeof u.xaxis.max=="number"&&(c.maxX=u.xaxis.max),u.xaxis.min!==void 0&&typeof u.xaxis.min=="number"&&(c.minX=u.xaxis.min),u.xaxis.range!==void 0&&(c.minX=c.maxX-u.xaxis.range),c.minX!==Number.MAX_VALUE&&c.maxX!==-Number.MAX_VALUE)if(u.xaxis.convertedCatToNumeric&&!c.dataFormatXNumeric){for(var m=[],x=c.minX-1;x0&&(c.xAxisScale=this.scales.linearScale(1,c.labels.length,v-1,0,u.xaxis.stepSize),c.seriesX=c.labels.slice());d&&(c.labels=c.xAxisScale.result.slice())}return c.isBarHorizontal&&c.labels.length&&(c.xTickAmount=c.labels.length),this._handleSingleDataPoint(),this._getMinXDiff(),{minX:c.minX,maxX:c.maxX}}},{key:"setZRange",value:function(){var c=this.w.globals;if(c.isDataXYZ){for(var u=0;u0){var w=m-v[x-1];w>0&&(c.minXDiff=Math.min(w,c.minXDiff))}}),c.dataPoints!==1&&c.minXDiff!==Number.MAX_VALUE||(c.minXDiff=.5)})}},{key:"_setStackedMinMax",value:function(){var c=this,u=this.w.globals;if(u.series.length){var d=u.seriesGroups;d.length||(d=[this.w.globals.seriesNames.map(function(x){return x})]);var v={},m={};d.forEach(function(x){v[x]=[],m[x]=[],c.w.config.series.map(function(w,k){return x.indexOf(u.seriesNames[k])>-1?k:null}).filter(function(w){return w!==null}).forEach(function(w){for(var k=0;k0?v[x][k]+=parseFloat(u.series[w][k])+1e-4:m[x][k]+=parseFloat(u.series[w][k]))}})}),Object.entries(v).forEach(function(x){var w=M(x,1)[0];v[w].forEach(function(k,L){u.maxY=Math.max(u.maxY,v[w][L]),u.minY=Math.min(u.minY,m[w][L])})})}}}]),Q}(),Ht=function(){function Q(c,u){a(this,Q),this.ctx=c,this.elgrid=u,this.w=c.w;var d=this.w;this.xaxisFontSize=d.config.xaxis.labels.style.fontSize,this.axisFontFamily=d.config.xaxis.labels.style.fontFamily,this.xaxisForeColors=d.config.xaxis.labels.style.colors,this.isCategoryBarHorizontal=d.config.chart.type==="bar"&&d.config.plotOptions.bar.horizontal,this.xAxisoffX=0,d.config.xaxis.position==="bottom"&&(this.xAxisoffX=d.globals.gridHeight),this.drawnLabels=[],this.axesUtils=new tt(c)}return l(Q,[{key:"drawYaxis",value:function(c){var u=this,d=this.w,v=new $(this.ctx),m=d.config.yaxis[c].labels.style,x=m.fontSize,w=m.fontFamily,k=m.fontWeight,L=v.group({class:"apexcharts-yaxis",rel:c,transform:"translate("+d.globals.translateYAxisX[c]+", 0)"});if(this.axesUtils.isYAxisHidden(c))return L;var D=v.group({class:"apexcharts-yaxis-texts-g"});L.add(D);var P=d.globals.yAxisScale[c].result.length-1,V=d.globals.gridHeight/P,N=d.globals.yLabelFormatters[c],j=d.globals.yAxisScale[c].result.slice();j=this.axesUtils.checkForReversedLabels(c,j);var U="";if(d.config.yaxis[c].labels.show){var q=d.globals.translateY+d.config.yaxis[c].labels.offsetY;d.globals.isBarHorizontal?q=0:d.config.chart.type==="heatmap"&&(q-=V/2),q+=parseInt(d.config.yaxis[c].labels.style.fontSize,10)/3;for(var J=function(Ct){var xt=j[Ct];xt=N(xt,Ct,d);var $t=d.config.yaxis[c].labels.padding;d.config.yaxis[c].opposite&&d.config.yaxis.length!==0&&($t*=-1);var re="end";d.config.yaxis[c].opposite&&(re="start"),d.config.yaxis[c].labels.align==="left"?re="start":d.config.yaxis[c].labels.align==="center"?re="middle":d.config.yaxis[c].labels.align==="right"&&(re="end");var Ot=u.axesUtils.getYAxisForeColor(m.colors,c),Qt=E.listToArray(d.globals.dom.baseEl.querySelectorAll(".apexcharts-yaxis[rel='".concat(c,"'] .apexcharts-yaxis-label tspan"))).map(function(l1){return l1.textContent}),Me=v.drawText({x:$t,y:q,text:Qt.indexOf(xt)>=0?"":xt,textAnchor:re,fontSize:x,fontFamily:w,fontWeight:k,maxWidth:d.config.yaxis[c].labels.maxWidth,foreColor:Array.isArray(Ot)?Ot[Ct]:Ot,isPlainText:!1,cssClass:"apexcharts-yaxis-label "+m.cssClass});Ct===P&&(U=Me),D.add(Me);var Te=document.createElementNS(d.globals.SVGNS,"title");if(Te.textContent=Array.isArray(xt)?xt.join(" "):xt,Me.node.appendChild(Te),d.config.yaxis[c].labels.rotate!==0){var Ge=v.rotateAroundCenter(U.node),Ye=v.rotateAroundCenter(Me.node);Me.node.setAttribute("transform","rotate(".concat(d.config.yaxis[c].labels.rotate," ").concat(Ge.x," ").concat(Ye.y,")"))}q+=V},rt=P;rt>=0;rt--)J(rt)}if(d.config.yaxis[c].title.text!==void 0){var A=v.group({class:"apexcharts-yaxis-title"}),O=0;d.config.yaxis[c].opposite&&(O=d.globals.translateYAxisX[c]);var X=v.drawText({x:O,y:d.globals.gridHeight/2+d.globals.translateY+d.config.yaxis[c].title.offsetY,text:d.config.yaxis[c].title.text,textAnchor:"end",foreColor:d.config.yaxis[c].title.style.color,fontSize:d.config.yaxis[c].title.style.fontSize,fontWeight:d.config.yaxis[c].title.style.fontWeight,fontFamily:d.config.yaxis[c].title.style.fontFamily,cssClass:"apexcharts-yaxis-title-text "+d.config.yaxis[c].title.style.cssClass});A.add(X),L.add(A)}var ot=d.config.yaxis[c].axisBorder,nt=31+ot.offsetX;if(d.config.yaxis[c].opposite&&(nt=-31-ot.offsetX),ot.show){var ct=v.drawLine(nt,d.globals.translateY+ot.offsetY-2,nt,d.globals.gridHeight+d.globals.translateY+ot.offsetY+2,ot.color,0,ot.width);L.add(ct)}return d.config.yaxis[c].axisTicks.show&&this.axesUtils.drawYAxisTicks(nt,P,ot,d.config.yaxis[c].axisTicks,c,V,L),L}},{key:"drawYaxisInversed",value:function(c){var u=this.w,d=new $(this.ctx),v=d.group({class:"apexcharts-xaxis apexcharts-yaxis-inversed"}),m=d.group({class:"apexcharts-xaxis-texts-g",transform:"translate(".concat(u.globals.translateXAxisX,", ").concat(u.globals.translateXAxisY,")")});v.add(m);var x=u.globals.yAxisScale[c].result.length-1,w=u.globals.gridWidth/x+.1,k=w+u.config.xaxis.labels.offsetX,L=u.globals.xLabelFormatter,D=u.globals.yAxisScale[c].result.slice(),P=u.globals.timescaleLabels;P.length>0&&(this.xaxisLabels=P.slice(),x=(D=P.slice()).length),D=this.axesUtils.checkForReversedLabels(c,D);var V=P.length;if(u.config.xaxis.labels.show)for(var N=V?0:x;V?N=0;V?N++:N--){var j=D[N];j=L(j,N,u);var U=u.globals.gridWidth+u.globals.padHorizontal-(k-w+u.config.xaxis.labels.offsetX);if(P.length){var q=this.axesUtils.getLabel(D,P,U,N,this.drawnLabels,this.xaxisFontSize);U=q.x,j=q.text,this.drawnLabels.push(q.text),N===0&&u.globals.skipFirstTimelinelabel&&(j=""),N===D.length-1&&u.globals.skipLastTimelinelabel&&(j="")}var J=d.drawText({x:U,y:this.xAxisoffX+u.config.xaxis.labels.offsetY+30-(u.config.xaxis.position==="top"?u.globals.xAxisHeight+u.config.xaxis.axisTicks.height-2:0),text:j,textAnchor:"middle",foreColor:Array.isArray(this.xaxisForeColors)?this.xaxisForeColors[c]:this.xaxisForeColors,fontSize:this.xaxisFontSize,fontFamily:this.xaxisFontFamily,fontWeight:u.config.xaxis.labels.style.fontWeight,isPlainText:!1,cssClass:"apexcharts-xaxis-label "+u.config.xaxis.labels.style.cssClass});m.add(J),J.tspan(j);var rt=document.createElementNS(u.globals.SVGNS,"title");rt.textContent=j,J.node.appendChild(rt),k+=w}return this.inversedYAxisTitleText(v),this.inversedYAxisBorder(v),v}},{key:"inversedYAxisBorder",value:function(c){var u=this.w,d=new $(this.ctx),v=u.config.xaxis.axisBorder;if(v.show){var m=0;u.config.chart.type==="bar"&&u.globals.isXNumeric&&(m-=15);var x=d.drawLine(u.globals.padHorizontal+m+v.offsetX,this.xAxisoffX,u.globals.gridWidth,this.xAxisoffX,v.color,0,v.height);this.elgrid&&this.elgrid.elGridBorders&&u.config.grid.show?this.elgrid.elGridBorders.add(x):c.add(x)}}},{key:"inversedYAxisTitleText",value:function(c){var u=this.w,d=new $(this.ctx);if(u.config.xaxis.title.text!==void 0){var v=d.group({class:"apexcharts-xaxis-title apexcharts-yaxis-title-inversed"}),m=d.drawText({x:u.globals.gridWidth/2+u.config.xaxis.title.offsetX,y:this.xAxisoffX+parseFloat(this.xaxisFontSize)+parseFloat(u.config.xaxis.title.style.fontSize)+u.config.xaxis.title.offsetY+20,text:u.config.xaxis.title.text,textAnchor:"middle",fontSize:u.config.xaxis.title.style.fontSize,fontFamily:u.config.xaxis.title.style.fontFamily,fontWeight:u.config.xaxis.title.style.fontWeight,foreColor:u.config.xaxis.title.style.color,cssClass:"apexcharts-xaxis-title-text "+u.config.xaxis.title.style.cssClass});v.add(m),c.add(v)}}},{key:"yAxisTitleRotate",value:function(c,u){var d=this.w,v=new $(this.ctx),m={width:0,height:0},x={width:0,height:0},w=d.globals.dom.baseEl.querySelector(" .apexcharts-yaxis[rel='".concat(c,"'] .apexcharts-yaxis-texts-g"));w!==null&&(m=w.getBoundingClientRect());var k=d.globals.dom.baseEl.querySelector(".apexcharts-yaxis[rel='".concat(c,"'] .apexcharts-yaxis-title text"));if(k!==null&&(x=k.getBoundingClientRect()),k!==null){var L=this.xPaddingForYAxisTitle(c,m,x,u);k.setAttribute("x",L.xPos-(u?10:0))}if(k!==null){var D=v.rotateAroundCenter(k);k.setAttribute("transform","rotate(".concat(u?-1*d.config.yaxis[c].title.rotate:d.config.yaxis[c].title.rotate," ").concat(D.x," ").concat(D.y,")"))}}},{key:"xPaddingForYAxisTitle",value:function(c,u,d,v){var m=this.w,x=0,w=0,k=10;return m.config.yaxis[c].title.text===void 0||c<0?{xPos:w,padd:0}:(v?(w=u.width+m.config.yaxis[c].title.offsetX+d.width/2+k/2,(x+=1)===0&&(w-=k/2)):(w=-1*u.width+m.config.yaxis[c].title.offsetX+k/2+d.width/2,m.globals.isBarHorizontal&&(k=25,w=-1*u.width-m.config.yaxis[c].title.offsetX-k)),{xPos:w,padd:k})}},{key:"setYAxisXPosition",value:function(c,u){var d=this.w,v=0,m=0,x=18,w=1;d.config.yaxis.length>1&&(this.multipleYs=!0),d.config.yaxis.map(function(k,L){var D=d.globals.ignoreYAxisIndexes.indexOf(L)>-1||!k.show||k.floating||c[L].width===0,P=c[L].width+u[L].width;k.opposite?d.globals.isBarHorizontal?(m=d.globals.gridWidth+d.globals.translateX-1,d.globals.translateYAxisX[L]=m-k.labels.offsetX):(m=d.globals.gridWidth+d.globals.translateX+w,D||(w=w+P+20),d.globals.translateYAxisX[L]=m-k.labels.offsetX+20):(v=d.globals.translateX-x,D||(x=x+P+20),d.globals.translateYAxisX[L]=v+k.labels.offsetX)})}},{key:"setYAxisTextAlignments",value:function(){var c=this.w,u=c.globals.dom.baseEl.getElementsByClassName("apexcharts-yaxis");(u=E.listToArray(u)).forEach(function(d,v){var m=c.config.yaxis[v];if(m&&!m.floating&&m.labels.align!==void 0){var x=c.globals.dom.baseEl.querySelector(".apexcharts-yaxis[rel='".concat(v,"'] .apexcharts-yaxis-texts-g")),w=c.globals.dom.baseEl.querySelectorAll(".apexcharts-yaxis[rel='".concat(v,"'] .apexcharts-yaxis-label"));w=E.listToArray(w);var k=x.getBoundingClientRect();m.labels.align==="left"?(w.forEach(function(L,D){L.setAttribute("text-anchor","start")}),m.opposite||x.setAttribute("transform","translate(-".concat(k.width,", 0)"))):m.labels.align==="center"?(w.forEach(function(L,D){L.setAttribute("text-anchor","middle")}),x.setAttribute("transform","translate(".concat(k.width/2*(m.opposite?1:-1),", 0)"))):m.labels.align==="right"&&(w.forEach(function(L,D){L.setAttribute("text-anchor","end")}),m.opposite&&x.setAttribute("transform","translate(".concat(k.width,", 0)")))}})}}]),Q}(),ce=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w,this.documentEvent=E.bind(this.documentEvent,this)}return l(Q,[{key:"addEventListener",value:function(c,u){var d=this.w;d.globals.events.hasOwnProperty(c)?d.globals.events[c].push(u):d.globals.events[c]=[u]}},{key:"removeEventListener",value:function(c,u){var d=this.w;if(d.globals.events.hasOwnProperty(c)){var v=d.globals.events[c].indexOf(u);v!==-1&&d.globals.events[c].splice(v,1)}}},{key:"fireEvent",value:function(c,u){var d=this.w;if(d.globals.events.hasOwnProperty(c)){u&&u.length||(u=[]);for(var v=d.globals.events[c],m=v.length,x=0;x0&&(u=this.w.config.chart.locales.concat(window.Apex.chart.locales));var d=u.filter(function(m){return m.name===c})[0];if(!d)throw new Error("Wrong locale name provided. Please make sure you set the correct locale name in options");var v=E.extend(ht,d);this.w.globals.locale=v.options}}]),Q}(),qt=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w}return l(Q,[{key:"drawAxis",value:function(c,u){var d,v,m=this,x=this.w.globals,w=this.w.config,k=new Bt(this.ctx,u),L=new Ht(this.ctx,u);x.axisCharts&&c!=="radar"&&(x.isBarHorizontal?(v=L.drawYaxisInversed(0),d=k.drawXaxisInversed(0),x.dom.elGraphical.add(d),x.dom.elGraphical.add(v)):(d=k.drawXaxis(),x.dom.elGraphical.add(d),w.yaxis.map(function(D,P){if(x.ignoreYAxisIndexes.indexOf(P)===-1&&(v=L.drawYaxis(P),x.dom.Paper.add(v),m.w.config.grid.position==="back")){var V=x.dom.Paper.children()[1];V.remove(),x.dom.Paper.add(V)}})))}}]),Q}(),ge=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w}return l(Q,[{key:"drawXCrosshairs",value:function(){var c=this.w,u=new $(this.ctx),d=new W(this.ctx),v=c.config.xaxis.crosshairs.fill.gradient,m=c.config.xaxis.crosshairs.dropShadow,x=c.config.xaxis.crosshairs.fill.type,w=v.colorFrom,k=v.colorTo,L=v.opacityFrom,D=v.opacityTo,P=v.stops,V=m.enabled,N=m.left,j=m.top,U=m.blur,q=m.color,J=m.opacity,rt=c.config.xaxis.crosshairs.fill.color;if(c.config.xaxis.crosshairs.show){x==="gradient"&&(rt=u.drawGradient("vertical",w,k,L,D,null,P,null));var A=u.drawRect();c.config.xaxis.crosshairs.width===1&&(A=u.drawLine());var O=c.globals.gridHeight;(!E.isNumber(O)||O<0)&&(O=0);var X=c.config.xaxis.crosshairs.width;(!E.isNumber(X)||X<0)&&(X=0),A.attr({class:"apexcharts-xcrosshairs",x:0,y:0,y2:O,width:X,height:O,fill:rt,filter:"none","fill-opacity":c.config.xaxis.crosshairs.opacity,stroke:c.config.xaxis.crosshairs.stroke.color,"stroke-width":c.config.xaxis.crosshairs.stroke.width,"stroke-dasharray":c.config.xaxis.crosshairs.stroke.dashArray}),V&&(A=d.dropShadow(A,{left:N,top:j,blur:U,color:q,opacity:J})),c.globals.dom.elGraphical.add(A)}}},{key:"drawYCrosshairs",value:function(){var c=this.w,u=new $(this.ctx),d=c.config.yaxis[0].crosshairs,v=c.globals.barPadForNumericAxis;if(c.config.yaxis[0].crosshairs.show){var m=u.drawLine(-v,0,c.globals.gridWidth+v,0,d.stroke.color,d.stroke.dashArray,d.stroke.width);m.attr({class:"apexcharts-ycrosshairs"}),c.globals.dom.elGraphical.add(m)}var x=u.drawLine(-v,0,c.globals.gridWidth+v,0,d.stroke.color,0,0);x.attr({class:"apexcharts-ycrosshairs-hidden"}),c.globals.dom.elGraphical.add(x)}}]),Q}(),oe=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w}return l(Q,[{key:"checkResponsiveConfig",value:function(c){var u=this,d=this.w,v=d.config;if(v.responsive.length!==0){var m=v.responsive.slice();m.sort(function(L,D){return L.breakpoint>D.breakpoint?1:D.breakpoint>L.breakpoint?-1:0}).reverse();var x=new At({}),w=function(){var L=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},D=m[0].breakpoint,P=window.innerWidth>0?window.innerWidth:screen.width;if(P>D){var V=E.clone(d.globals.initialConfig);V.series=E.clone(d.config.series);var N=G.extendArrayProps(x,V,d);L=E.extend(N,L),L=E.extend(d.config,L),u.overrideResponsiveOptions(L)}else for(var j=0;j0&&typeof d.config.colors[0]=="function"&&(d.globals.colors=d.config.series.map(function(j,U){var q=d.config.colors[U];return q||(q=d.config.colors[0]),typeof q=="function"?(u.isColorFn=!0,q({value:d.globals.axisCharts?d.globals.series[U][0]?d.globals.series[U][0]:0:d.globals.series[U],seriesIndex:U,dataPointIndex:U,w:d})):q}))),d.globals.seriesColors.map(function(j,U){j&&(d.globals.colors[U]=j)}),d.config.theme.monochrome.enabled){var m=[],x=d.globals.series.length;(this.isBarDistributed||this.isHeatmapDistributed)&&(x=d.globals.series[0].length*d.globals.series.length);for(var w=d.config.theme.monochrome.color,k=1/(x/d.config.theme.monochrome.shadeIntensity),L=d.config.theme.monochrome.shadeTo,D=0,P=0;P2&&arguments[2]!==void 0?arguments[2]:null,v=this.w,m=u||v.globals.series.length;if(d===null&&(d=this.isBarDistributed||this.isHeatmapDistributed||v.config.chart.type==="heatmap"&&v.config.plotOptions.heatmap.colorScale.inverse),d&&v.globals.series.length&&(m=v.globals.series[v.globals.maxValsInArrayIndex].length*v.globals.series.length),c.lengthc.globals.svgWidth&&(this.dCtx.lgRect.width=c.globals.svgWidth/1.5),this.dCtx.lgRect}},{key:"getDatalabelsRect",value:function(){var c=this,u=this.w,d=[];u.config.series.forEach(function(k,L){k.data.forEach(function(D,P){var V;V=u.globals.series[L][P],v=u.config.dataLabels.formatter(V,{ctx:c.dCtx.ctx,seriesIndex:L,dataPointIndex:P,w:u}),d.push(v)})});var v=E.getLargestStringFromArr(d),m=new $(this.dCtx.ctx),x=u.config.dataLabels.style,w=m.getTextRects(v,parseInt(x.fontSize),x.fontFamily);return{width:1.05*w.width,height:w.height}}},{key:"getLargestStringFromMultiArr",value:function(c,u){var d=c;if(this.w.globals.isMultiLineX){var v=u.map(function(x,w){return Array.isArray(x)?x.length:1}),m=Math.max.apply(Math,I(v));d=u[v.indexOf(m)]}return d}}]),Q}(),Jt=function(){function Q(c){a(this,Q),this.w=c.w,this.dCtx=c}return l(Q,[{key:"getxAxisLabelsCoords",value:function(){var c,u=this.w,d=u.globals.labels.slice();if(u.config.xaxis.convertedCatToNumeric&&d.length===0&&(d=u.globals.categoryLabels),u.globals.timescaleLabels.length>0){var v=this.getxAxisTimeScaleLabelsCoords();c={width:v.width,height:v.height},u.globals.rotateXLabels=!1}else{this.dCtx.lgWidthForSideLegends=u.config.legend.position!=="left"&&u.config.legend.position!=="right"||u.config.legend.floating?0:this.dCtx.lgRect.width;var m=u.globals.xLabelFormatter,x=E.getLargestStringFromArr(d),w=this.dCtx.dimHelpers.getLargestStringFromMultiArr(x,d);u.globals.isBarHorizontal&&(w=x=u.globals.yAxisScale[0].result.reduce(function(j,U){return j.length>U.length?j:U},0));var k=new at(this.dCtx.ctx),L=x;x=k.xLabelFormat(m,x,L,{i:void 0,dateFormatter:new et(this.dCtx.ctx).formatDate,w:u}),w=k.xLabelFormat(m,w,L,{i:void 0,dateFormatter:new et(this.dCtx.ctx).formatDate,w:u}),(u.config.xaxis.convertedCatToNumeric&&x===void 0||String(x).trim()==="")&&(w=x="1");var D=new $(this.dCtx.ctx),P=D.getTextRects(x,u.config.xaxis.labels.style.fontSize),V=P;if(x!==w&&(V=D.getTextRects(w,u.config.xaxis.labels.style.fontSize)),(c={width:P.width>=V.width?P.width:V.width,height:P.height>=V.height?P.height:V.height}).width*d.length>u.globals.svgWidth-this.dCtx.lgWidthForSideLegends-this.dCtx.yAxisWidth-this.dCtx.gridPad.left-this.dCtx.gridPad.right&&u.config.xaxis.labels.rotate!==0||u.config.xaxis.labels.rotateAlways){if(!u.globals.isBarHorizontal){u.globals.rotateXLabels=!0;var N=function(j){return D.getTextRects(j,u.config.xaxis.labels.style.fontSize,u.config.xaxis.labels.style.fontFamily,"rotate(".concat(u.config.xaxis.labels.rotate," 0 0)"),!1)};P=N(x),x!==w&&(V=N(w)),c.height=(P.height>V.height?P.height:V.height)/1.5,c.width=P.width>V.width?P.width:V.width}}else u.globals.rotateXLabels=!1}return u.config.xaxis.labels.show||(c={width:0,height:0}),{width:c.width,height:c.height}}},{key:"getxAxisGroupLabelsCoords",value:function(){var c,u=this.w;if(!u.globals.hasXaxisGroups)return{width:0,height:0};var d,v=((c=u.config.xaxis.group.style)===null||c===void 0?void 0:c.fontSize)||u.config.xaxis.labels.style.fontSize,m=u.globals.groups.map(function(P){return P.title}),x=E.getLargestStringFromArr(m),w=this.dCtx.dimHelpers.getLargestStringFromMultiArr(x,m),k=new $(this.dCtx.ctx),L=k.getTextRects(x,v),D=L;return x!==w&&(D=k.getTextRects(w,v)),d={width:L.width>=D.width?L.width:D.width,height:L.height>=D.height?L.height:D.height},u.config.xaxis.labels.show||(d={width:0,height:0}),{width:d.width,height:d.height}}},{key:"getxAxisTitleCoords",value:function(){var c=this.w,u=0,d=0;if(c.config.xaxis.title.text!==void 0){var v=new $(this.dCtx.ctx).getTextRects(c.config.xaxis.title.text,c.config.xaxis.title.style.fontSize);u=v.width,d=v.height}return{width:u,height:d}}},{key:"getxAxisTimeScaleLabelsCoords",value:function(){var c,u=this.w;this.dCtx.timescaleLabels=u.globals.timescaleLabels.slice();var d=this.dCtx.timescaleLabels.map(function(m){return m.value}),v=d.reduce(function(m,x){return m===void 0?(console.error("You have possibly supplied invalid Date format. Please supply a valid JavaScript Date"),0):m.length>x.length?m:x},0);return 1.05*(c=new $(this.dCtx.ctx).getTextRects(v,u.config.xaxis.labels.style.fontSize)).width*d.length>u.globals.gridWidth&&u.config.xaxis.labels.rotate!==0&&(u.globals.overlappingXLabels=!0),c}},{key:"additionalPaddingXLabels",value:function(c){var u=this,d=this.w,v=d.globals,m=d.config,x=m.xaxis.type,w=c.width;v.skipLastTimelinelabel=!1,v.skipFirstTimelinelabel=!1;var k=d.config.yaxis[0].opposite&&d.globals.isBarHorizontal,L=function(D,P){m.yaxis.length>1&&function(V){return v.collapsedSeriesIndices.indexOf(V)!==-1}(P)||function(V){if(u.dCtx.timescaleLabels&&u.dCtx.timescaleLabels.length){var N=u.dCtx.timescaleLabels[0],j=u.dCtx.timescaleLabels[u.dCtx.timescaleLabels.length-1].position+w/1.75-u.dCtx.yAxisWidthRight,U=N.position-w/1.75+u.dCtx.yAxisWidthLeft,q=d.config.legend.position==="right"&&u.dCtx.lgRect.width>0?u.dCtx.lgRect.width:0;j>v.svgWidth-v.translateX-q&&(v.skipLastTimelinelabel=!0),U<-(V.show&&!V.floating||m.chart.type!=="bar"&&m.chart.type!=="candlestick"&&m.chart.type!=="rangeBar"&&m.chart.type!=="boxPlot"?10:w/1.75)&&(v.skipFirstTimelinelabel=!0)}else x==="datetime"?u.dCtx.gridPad.right((nt=String(P(X,k)))===null||nt===void 0?void 0:nt.length)?O:X},V),j=N=P(N,k);if(N!==void 0&&N.length!==0||(N=L.niceMax),u.globals.isBarHorizontal){v=0;var U=u.globals.labels.slice();N=E.getLargestStringFromArr(U),N=P(N,{seriesIndex:w,dataPointIndex:-1,w:u}),j=c.dCtx.dimHelpers.getLargestStringFromMultiArr(N,U)}var q=new $(c.dCtx.ctx),J="rotate(".concat(x.labels.rotate," 0 0)"),rt=q.getTextRects(N,x.labels.style.fontSize,x.labels.style.fontFamily,J,!1),A=rt;N!==j&&(A=q.getTextRects(j,x.labels.style.fontSize,x.labels.style.fontFamily,J,!1)),d.push({width:(D>A.width||D>rt.width?D:A.width>rt.width?A.width:rt.width)+v,height:A.height>rt.height?A.height:rt.height})}else d.push({width:0,height:0})}),d}},{key:"getyAxisTitleCoords",value:function(){var c=this,u=this.w,d=[];return u.config.yaxis.map(function(v,m){if(v.show&&v.title.text!==void 0){var x=new $(c.dCtx.ctx),w="rotate(".concat(v.title.rotate," 0 0)"),k=x.getTextRects(v.title.text,v.title.style.fontSize,v.title.style.fontFamily,w,!1);d.push({width:k.width,height:k.height})}else d.push({width:0,height:0})}),d}},{key:"getTotalYAxisWidth",value:function(){var c=this.w,u=0,d=0,v=0,m=c.globals.yAxisScale.length>1?10:0,x=new tt(this.dCtx.ctx),w=function(k,L){var D=c.config.yaxis[L].floating,P=0;k.width>0&&!D?(P=k.width+m,function(V){return c.globals.ignoreYAxisIndexes.indexOf(V)>-1}(L)&&(P=P-k.width-m)):P=D||x.isYAxisHidden(L)?0:5,c.config.yaxis[L].opposite?v+=P:d+=P,u+=P};return c.globals.yLabelsCoords.map(function(k,L){w(k,L)}),c.globals.yTitleCoords.map(function(k,L){w(k,L)}),c.globals.isBarHorizontal&&!c.config.yaxis[0].floating&&(u=c.globals.yLabelsCoords[0].width+c.globals.yTitleCoords[0].width+15),this.dCtx.yAxisWidthLeft=d,this.dCtx.yAxisWidthRight=v,u}}]),Q}(),He=function(){function Q(c){a(this,Q),this.w=c.w,this.dCtx=c}return l(Q,[{key:"gridPadForColumnsInNumericAxis",value:function(c){var u=this.w,d=u.config,v=u.globals;if(v.noData||v.collapsedSeries.length+v.ancillaryCollapsedSeries.length===d.series.length)return 0;var m=function(N){return N==="bar"||N==="rangeBar"||N==="candlestick"||N==="boxPlot"},x=d.chart.type,w=0,k=m(x)?d.series.length:1;v.comboBarCount>0&&(k=v.comboBarCount),v.collapsedSeries.forEach(function(N){m(N.type)&&(k-=1)}),d.chart.stacked&&(k=1);var L=m(x)||v.comboBarCount>0,D=Math.abs(v.initialMaxX-v.initialMinX);if(L&&v.isXNumeric&&!v.isBarHorizontal&&k>0&&D!==0){var P,V;D<=3&&(D=v.dataPoints),P=D/c,v.minXDiff&&v.minXDiff/P>0&&(V=v.minXDiff/P),V>c/2&&(V/=2),(w=V*parseInt(d.plotOptions.bar.columnWidth,10)/100)<1&&(w=1),v.barPadForNumericAxis=w}return w}},{key:"gridPadFortitleSubtitle",value:function(){var c=this,u=this.w,d=u.globals,v=this.dCtx.isSparkline||!u.globals.axisCharts?0:10;["title","subtitle"].forEach(function(w){u.config[w].text!==void 0?v+=u.config[w].margin:v+=c.dCtx.isSparkline||!u.globals.axisCharts?0:5}),!u.config.legend.show||u.config.legend.position!=="bottom"||u.config.legend.floating||u.globals.axisCharts||(v+=10);var m=this.dCtx.dimHelpers.getTitleSubtitleCoords("title"),x=this.dCtx.dimHelpers.getTitleSubtitleCoords("subtitle");d.gridHeight=d.gridHeight-m.height-x.height-v,d.translateY=d.translateY+m.height+x.height+v}},{key:"setGridXPosForDualYAxis",value:function(c,u){var d=this.w,v=new tt(this.dCtx.ctx);d.config.yaxis.map(function(m,x){d.globals.ignoreYAxisIndexes.indexOf(x)!==-1||m.floating||v.isYAxisHidden(x)||(m.opposite&&(d.globals.translateX=d.globals.translateX-(u[x].width+c[x].width)-parseInt(d.config.yaxis[x].labels.style.fontSize,10)/1.2-12),d.globals.translateX<2&&(d.globals.translateX=2))})}}]),Q}(),Pe=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w,this.lgRect={},this.yAxisWidth=0,this.yAxisWidthLeft=0,this.yAxisWidthRight=0,this.xAxisHeight=0,this.isSparkline=this.w.config.chart.sparkline.enabled,this.dimHelpers=new Nt(this),this.dimYAxis=new Ie(this),this.dimXAxis=new Jt(this),this.dimGrid=new He(this),this.lgWidthForSideLegends=0,this.gridPad=this.w.config.grid.padding,this.xPadRight=0,this.xPadLeft=0}return l(Q,[{key:"plotCoords",value:function(){var c=this,u=this.w,d=u.globals;this.lgRect=this.dimHelpers.getLegendsRect(),this.datalabelsCoords={width:0,height:0};var v=Array.isArray(u.config.stroke.width)?Math.max.apply(Math,I(u.config.stroke.width)):u.config.stroke.width;this.isSparkline&&((u.config.markers.discrete.length>0||u.config.markers.size>0)&&Object.entries(this.gridPad).forEach(function(x){var w=M(x,2),k=w[0],L=w[1];c.gridPad[k]=Math.max(L,c.w.globals.markers.largestSize/1.5)}),this.gridPad.top=Math.max(v/2,this.gridPad.top),this.gridPad.bottom=Math.max(v/2,this.gridPad.bottom)),d.axisCharts?this.setDimensionsForAxisCharts():this.setDimensionsForNonAxisCharts(),this.dimGrid.gridPadFortitleSubtitle(),d.gridHeight=d.gridHeight-this.gridPad.top-this.gridPad.bottom,d.gridWidth=d.gridWidth-this.gridPad.left-this.gridPad.right-this.xPadRight-this.xPadLeft;var m=this.dimGrid.gridPadForColumnsInNumericAxis(d.gridWidth);d.gridWidth=d.gridWidth-2*m,d.translateX=d.translateX+this.gridPad.left+this.xPadLeft+(m>0?m:0),d.translateY=d.translateY+this.gridPad.top}},{key:"setDimensionsForAxisCharts",value:function(){var c=this,u=this.w,d=u.globals,v=this.dimYAxis.getyAxisLabelsCoords(),m=this.dimYAxis.getyAxisTitleCoords();d.isSlopeChart&&(this.datalabelsCoords=this.dimHelpers.getDatalabelsRect()),u.globals.yLabelsCoords=[],u.globals.yTitleCoords=[],u.config.yaxis.map(function(N,j){u.globals.yLabelsCoords.push({width:v[j].width,index:j}),u.globals.yTitleCoords.push({width:m[j].width,index:j})}),this.yAxisWidth=this.dimYAxis.getTotalYAxisWidth();var x=this.dimXAxis.getxAxisLabelsCoords(),w=this.dimXAxis.getxAxisGroupLabelsCoords(),k=this.dimXAxis.getxAxisTitleCoords();this.conditionalChecksForAxisCoords(x,k,w),d.translateXAxisY=u.globals.rotateXLabels?this.xAxisHeight/8:-4,d.translateXAxisX=u.globals.rotateXLabels&&u.globals.isXNumeric&&u.config.xaxis.labels.rotate<=-45?-this.xAxisWidth/4:0,u.globals.isBarHorizontal&&(d.rotateXLabels=!1,d.translateXAxisY=parseInt(u.config.xaxis.labels.style.fontSize,10)/1.5*-1),d.translateXAxisY=d.translateXAxisY+u.config.xaxis.labels.offsetY,d.translateXAxisX=d.translateXAxisX+u.config.xaxis.labels.offsetX;var L=this.yAxisWidth,D=this.xAxisHeight;d.xAxisLabelsHeight=this.xAxisHeight-k.height,d.xAxisGroupLabelsHeight=d.xAxisLabelsHeight-x.height,d.xAxisLabelsWidth=this.xAxisWidth,d.xAxisHeight=this.xAxisHeight;var P=10;(u.config.chart.type==="radar"||this.isSparkline)&&(L=0,D=d.goldenPadding),this.isSparkline&&(this.lgRect={height:0,width:0}),(this.isSparkline||u.config.chart.type==="treemap")&&(L=0,D=0,P=0),this.isSparkline||this.dimXAxis.additionalPaddingXLabels(x);var V=function(){d.translateX=L+c.datalabelsCoords.width,d.gridHeight=d.svgHeight-c.lgRect.height-D-(c.isSparkline||u.config.chart.type==="treemap"?0:u.globals.rotateXLabels?10:15),d.gridWidth=d.svgWidth-L-2*c.datalabelsCoords.width};switch(u.config.xaxis.position==="top"&&(P=d.xAxisHeight-u.config.xaxis.axisTicks.height-5),u.config.legend.position){case"bottom":d.translateY=P,V();break;case"top":d.translateY=this.lgRect.height+P,V();break;case"left":d.translateY=P,d.translateX=this.lgRect.width+L+this.datalabelsCoords.width,d.gridHeight=d.svgHeight-D-12,d.gridWidth=d.svgWidth-this.lgRect.width-L-2*this.datalabelsCoords.width;break;case"right":d.translateY=P,d.translateX=L+this.datalabelsCoords.width,d.gridHeight=d.svgHeight-D-12,d.gridWidth=d.svgWidth-this.lgRect.width-L-2*this.datalabelsCoords.width-5;break;default:throw new Error("Legend position not supported")}this.dimGrid.setGridXPosForDualYAxis(m,v),new Ht(this.ctx).setYAxisXPosition(v,m)}},{key:"setDimensionsForNonAxisCharts",value:function(){var c=this.w,u=c.globals,d=c.config,v=0;c.config.legend.show&&!c.config.legend.floating&&(v=20);var m=d.chart.type==="pie"||d.chart.type==="polarArea"||d.chart.type==="donut"?"pie":"radialBar",x=d.plotOptions[m].offsetY,w=d.plotOptions[m].offsetX;if(!d.legend.show||d.legend.floating){u.gridHeight=u.svgHeight-d.grid.padding.top-d.grid.padding.bottom;var k=u.dom.elWrap.getBoundingClientRect().width;return u.gridWidth=Math.min(k,u.gridHeight)-d.grid.padding.left-d.grid.padding.right,u.translateY=x,void(u.translateX=w+(u.svgWidth-u.gridWidth)/2)}switch(d.legend.position){case"bottom":u.gridHeight=u.svgHeight-this.lgRect.height-u.goldenPadding,u.gridWidth=u.svgWidth,u.translateY=x-10,u.translateX=w+(u.svgWidth-u.gridWidth)/2;break;case"top":u.gridHeight=u.svgHeight-this.lgRect.height-u.goldenPadding,u.gridWidth=u.svgWidth,u.translateY=this.lgRect.height+x+10,u.translateX=w+(u.svgWidth-u.gridWidth)/2;break;case"left":u.gridWidth=u.svgWidth-this.lgRect.width-v,u.gridHeight=d.chart.height!=="auto"?u.svgHeight:u.gridWidth,u.translateY=x,u.translateX=w+this.lgRect.width+v;break;case"right":u.gridWidth=u.svgWidth-this.lgRect.width-v-5,u.gridHeight=d.chart.height!=="auto"?u.svgHeight:u.gridWidth,u.translateY=x,u.translateX=w+10;break;default:throw new Error("Legend position not supported")}}},{key:"conditionalChecksForAxisCoords",value:function(c,u,d){var v=this.w,m=v.globals.hasXaxisGroups?2:1,x=d.height+c.height+u.height,w=v.globals.isMultiLineX?1.2:v.globals.LINE_HEIGHT_RATIO,k=v.globals.rotateXLabels?22:10,L=v.globals.rotateXLabels&&v.config.legend.position==="bottom"?10:0;this.xAxisHeight=x*w+m*k+L,this.xAxisWidth=c.width,this.xAxisHeight-u.height>v.config.xaxis.labels.maxHeight&&(this.xAxisHeight=v.config.xaxis.labels.maxHeight),v.config.xaxis.labels.minHeight&&this.xAxisHeightP&&(this.yAxisWidth=P)}}]),Q}(),Xt=function(){function Q(c){a(this,Q),this.w=c.w,this.lgCtx=c}return l(Q,[{key:"getLegendStyles",value:function(){var c,u,d,v=document.createElement("style");v.setAttribute("type","text/css");var m=((c=this.lgCtx.ctx)===null||c===void 0||(u=c.opts)===null||u===void 0||(d=u.chart)===null||d===void 0?void 0:d.nonce)||this.w.config.chart.nonce;m&&v.setAttribute("nonce",m);var x=document.createTextNode(` .apexcharts-legend { display: flex; overflow: auto; @@ -1104,7 +1104,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho } .apexcharts-inactive-legend { opacity: 0.45; - }`);return v.appendChild(x),v}},{key:"getLegendDimensions",value:function(){var c=this.w.globals.dom.baseEl.querySelector(".apexcharts-legend"),u=c.offsetWidth;return{clwh:c.offsetHeight,clww:u}}},{key:"appendToForeignObject",value:function(){this.w.globals.dom.elLegendForeign.appendChild(this.getLegendStyles())}},{key:"toggleDataSeries",value:function(c,u){var d=this,v=this.w;if(v.globals.axisCharts||v.config.chart.type==="radialBar"){v.globals.resized=!0;var m=null,x=null;v.globals.risingSeries=[],v.globals.axisCharts?(m=v.globals.dom.baseEl.querySelector(".apexcharts-series[data\\:realIndex='".concat(c,"']")),x=parseInt(m.getAttribute("data:realIndex"),10)):(m=v.globals.dom.baseEl.querySelector(".apexcharts-series[rel='".concat(c+1,"']")),x=parseInt(m.getAttribute("rel"),10)-1),u?[{cs:v.globals.collapsedSeries,csi:v.globals.collapsedSeriesIndices},{cs:v.globals.ancillaryCollapsedSeries,csi:v.globals.ancillaryCollapsedSeriesIndices}].forEach(function(D){d.riseCollapsedSeries(D.cs,D.csi,x)}):this.hideSeries({seriesEl:m,realIndex:x})}else{var w=v.globals.dom.Paper.select(" .apexcharts-series[rel='".concat(c+1,"'] path")),k=v.config.chart.type;if(k==="pie"||k==="polarArea"||k==="donut"){var L=v.config.plotOptions.pie.donut.labels;new $(this.lgCtx.ctx).pathMouseDown(w.members[0],null),this.lgCtx.ctx.pie.printDataLabelsInner(w.members[0].node,L)}w.fire("click")}}},{key:"hideSeries",value:function(c){var u=c.seriesEl,d=c.realIndex,v=this.w,m=v.globals,x=E.clone(v.config.series);if(m.axisCharts){var w=v.config.yaxis[m.seriesYAxisReverseMap[d]];if(w&&w.show&&w.showAlways)m.ancillaryCollapsedSeriesIndices.indexOf(d)<0&&(m.ancillaryCollapsedSeries.push({index:d,data:x[d].data.slice(),type:u.parentNode.className.baseVal.split("-")[1]}),m.ancillaryCollapsedSeriesIndices.push(d));else if(m.collapsedSeriesIndices.indexOf(d)<0){m.collapsedSeries.push({index:d,data:x[d].data.slice(),type:u.parentNode.className.baseVal.split("-")[1]}),m.collapsedSeriesIndices.push(d);var k=m.risingSeries.indexOf(d);m.risingSeries.splice(k,1)}}else m.collapsedSeries.push({index:d,data:x[d]}),m.collapsedSeriesIndices.push(d);for(var L=u.childNodes,D=0;D0){for(var x=0;x1||!u.axisCharts)&&d.legend.show){for(;u.dom.elLegendWrap.firstChild;)u.dom.elLegendWrap.removeChild(u.dom.elLegendWrap.firstChild);this.drawLegends(),E.isIE11()?document.getElementsByTagName("head")[0].appendChild(this.legendHelpers.getLegendStyles()):this.legendHelpers.appendToForeignObject(),d.legend.position==="bottom"||d.legend.position==="top"?this.legendAlignHorizontal():d.legend.position!=="right"&&d.legend.position!=="left"||this.legendAlignVertical()}}},{key:"createLegendMarker",value:function(c){var u=c.i,d=c.fillcolor,v=this.w,m=document.createElement("span");m.classList.add("apexcharts-legend-marker");var x=v.config.legend.markers.shape||v.config.markers.shape,w=x;Array.isArray(x)&&(w=x[u]);var k=Array.isArray(v.config.legend.markers.size)?parseFloat(v.config.legend.markers.size[u]):parseFloat(v.config.legend.markers.size),L=Array.isArray(v.config.legend.markers.offsetX)?parseFloat(v.config.legend.markers.offsetX[u]):parseFloat(v.config.legend.markers.offsetX),D=Array.isArray(v.config.legend.markers.offsetY)?parseFloat(v.config.legend.markers.offsetY[u]):parseFloat(v.config.legend.markers.offsetY),P=Array.isArray(v.config.legend.markers.strokeWidth)?parseFloat(v.config.legend.markers.strokeWidth[u]):parseFloat(v.config.legend.markers.strokeWidth),V=m.style;if(V.height=2*(k+P)+"px",V.width=2*(k+P)+"px",V.left=L+"px",V.top=D+"px",v.config.legend.markers.customHTML)V.background="transparent",V.color=d[u],Array.isArray(v.config.legend.markers.customHTML)?v.config.legend.markers.customHTML[u]&&(m.innerHTML=v.config.legend.markers.customHTML[u]()):m.innerHTML=v.config.legend.markers.customHTML();else{var N=new Ft(this.ctx).getMarkerConfig({cssClass:"apexcharts-legend-marker apexcharts-marker apexcharts-marker-".concat(w),seriesIndex:u,strokeWidth:P,size:k}),j=SVG(m).size("100%","100%"),U=new $(this.ctx).drawMarker(0,0,i(i({},N),{},{pointFillColor:Array.isArray(d)?d[u]:N.pointFillColor,shape:w}));SVG.select(".apexcharts-legend-marker.apexcharts-marker").members.forEach(function(q){q.node.classList.contains("apexcharts-marker-triangle")?q.node.style.transform="translate(50%, 45%)":q.node.style.transform="translate(50%, 50%)"}),j.add(U)}return m}},{key:"drawLegends",value:function(){var c=this,u=this.w,d=u.config.legend.fontFamily,v=u.globals.seriesNames,m=u.config.legend.markers.fillColors?u.config.legend.markers.fillColors.slice():u.globals.colors.slice();if(u.config.chart.type==="heatmap"){var x=u.config.plotOptions.heatmap.colorScale.ranges;v=x.map(function(X){return X.name?X.name:X.from+" - "+X.to}),m=x.map(function(X){return X.color})}else this.isBarsDistributed&&(v=u.globals.labels.slice());u.config.legend.customLegendItems.length&&(v=u.config.legend.customLegendItems);for(var w=u.globals.legendFormatter,k=u.config.legend.inverseOrder,L=k?v.length-1:0;k?L>=0:L<=v.length-1;k?L--:L++){var D,P=w(v[L],{seriesIndex:L,w:u}),V=!1,N=!1;if(u.globals.collapsedSeries.length>0)for(var j=0;j0)for(var U=0;U0?L-10:0)+(D>0?D-10:0)}v.style.position="absolute",x=x+c+d.config.legend.offsetX,w=w+u+d.config.legend.offsetY,v.style.left=x+"px",v.style.top=w+"px",d.config.legend.position==="bottom"?(v.style.top="auto",v.style.bottom=5-d.config.legend.offsetY+"px"):d.config.legend.position==="right"&&(v.style.left="auto",v.style.right=25+d.config.legend.offsetX+"px"),["width","height"].forEach(function(P){v.style[P]&&(v.style[P]=parseInt(d.config.legend[P],10)+"px")})}},{key:"legendAlignHorizontal",value:function(){var c=this.w;c.globals.dom.elLegendWrap.style.right=0;var u=this.legendHelpers.getLegendDimensions(),d=new Pe(this.ctx),v=d.dimHelpers.getTitleSubtitleCoords("title"),m=d.dimHelpers.getTitleSubtitleCoords("subtitle"),x=0;c.config.legend.position==="bottom"?x=-u.clwh/1.8:c.config.legend.position==="top"&&(x=v.height+m.height+c.config.title.margin+c.config.subtitle.margin-10),this.setLegendWrapXY(20,x)}},{key:"legendAlignVertical",value:function(){var c=this.w,u=this.legendHelpers.getLegendDimensions(),d=0;c.config.legend.position==="left"&&(d=20),c.config.legend.position==="right"&&(d=c.globals.svgWidth-u.clww-10),this.setLegendWrapXY(d,20)}},{key:"onLegendHovered",value:function(c){var u=this.w,d=c.target.classList.contains("apexcharts-legend-series")||c.target.classList.contains("apexcharts-legend-text")||c.target.classList.contains("apexcharts-legend-marker");if(u.config.chart.type==="heatmap"||this.isBarsDistributed){if(d){var v=parseInt(c.target.getAttribute("rel"),10)-1;this.ctx.events.fireEvent("legendHover",[this.ctx,v,this.w]),new Xt(this.ctx).highlightRangeInSeries(c,c.target)}}else!c.target.classList.contains("apexcharts-inactive-legend")&&d&&new Xt(this.ctx).toggleSeriesOnHover(c,c.target)}},{key:"onLegendClick",value:function(c){var u=this.w;if(!u.config.legend.customLegendItems.length&&(c.target.classList.contains("apexcharts-legend-series")||c.target.classList.contains("apexcharts-legend-text")||c.target.classList.contains("apexcharts-legend-marker"))){var d=parseInt(c.target.getAttribute("rel"),10)-1,v=c.target.getAttribute("data:collapsed")==="true",m=this.w.config.chart.events.legendClick;typeof m=="function"&&m(this.ctx,d,this.w),this.ctx.events.fireEvent("legendClick",[this.ctx,d,this.w]);var x=this.w.config.legend.markers.onClick;typeof x=="function"&&c.target.classList.contains("apexcharts-legend-marker")&&(x(this.ctx,d,this.w),this.ctx.events.fireEvent("legendMarkerClick",[this.ctx,d,this.w])),u.config.chart.type!=="treemap"&&u.config.chart.type!=="heatmap"&&!this.isBarsDistributed&&u.config.legend.onItemClick.toggleDataSeries&&this.legendHelpers.toggleDataSeries(d,v)}}}]),Q}(),Et=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w;var u=this.w;this.ev=this.w.config.chart.events,this.selectedClass="apexcharts-selected",this.localeValues=this.w.globals.locale.toolbar,this.minX=u.globals.minX,this.maxX=u.globals.maxX}return l(Q,[{key:"createToolbar",value:function(){var c=this,u=this.w,d=function(){return document.createElement("div")},v=d();if(v.setAttribute("class","apexcharts-toolbar"),v.style.top=u.config.chart.toolbar.offsetY+"px",v.style.right=3-u.config.chart.toolbar.offsetX+"px",u.globals.dom.elWrap.appendChild(v),this.elZoom=d(),this.elZoomIn=d(),this.elZoomOut=d(),this.elPan=d(),this.elSelection=d(),this.elZoomReset=d(),this.elMenuIcon=d(),this.elMenu=d(),this.elCustomIcons=[],this.t=u.config.chart.toolbar.tools,Array.isArray(this.t.customIcons))for(var m=0;m + }`);return v.appendChild(x),v}},{key:"getLegendDimensions",value:function(){var c=this.w.globals.dom.baseEl.querySelector(".apexcharts-legend"),u=c.offsetWidth;return{clwh:c.offsetHeight,clww:u}}},{key:"appendToForeignObject",value:function(){this.w.globals.dom.elLegendForeign.appendChild(this.getLegendStyles())}},{key:"toggleDataSeries",value:function(c,u){var d=this,v=this.w;if(v.globals.axisCharts||v.config.chart.type==="radialBar"){v.globals.resized=!0;var m=null,x=null;v.globals.risingSeries=[],v.globals.axisCharts?(m=v.globals.dom.baseEl.querySelector(".apexcharts-series[data\\:realIndex='".concat(c,"']")),x=parseInt(m.getAttribute("data:realIndex"),10)):(m=v.globals.dom.baseEl.querySelector(".apexcharts-series[rel='".concat(c+1,"']")),x=parseInt(m.getAttribute("rel"),10)-1),u?[{cs:v.globals.collapsedSeries,csi:v.globals.collapsedSeriesIndices},{cs:v.globals.ancillaryCollapsedSeries,csi:v.globals.ancillaryCollapsedSeriesIndices}].forEach(function(D){d.riseCollapsedSeries(D.cs,D.csi,x)}):this.hideSeries({seriesEl:m,realIndex:x})}else{var w=v.globals.dom.Paper.select(" .apexcharts-series[rel='".concat(c+1,"'] path")),k=v.config.chart.type;if(k==="pie"||k==="polarArea"||k==="donut"){var L=v.config.plotOptions.pie.donut.labels;new $(this.lgCtx.ctx).pathMouseDown(w.members[0],null),this.lgCtx.ctx.pie.printDataLabelsInner(w.members[0].node,L)}w.fire("click")}}},{key:"hideSeries",value:function(c){var u=c.seriesEl,d=c.realIndex,v=this.w,m=v.globals,x=E.clone(v.config.series);if(m.axisCharts){var w=v.config.yaxis[m.seriesYAxisReverseMap[d]];if(w&&w.show&&w.showAlways)m.ancillaryCollapsedSeriesIndices.indexOf(d)<0&&(m.ancillaryCollapsedSeries.push({index:d,data:x[d].data.slice(),type:u.parentNode.className.baseVal.split("-")[1]}),m.ancillaryCollapsedSeriesIndices.push(d));else if(m.collapsedSeriesIndices.indexOf(d)<0){m.collapsedSeries.push({index:d,data:x[d].data.slice(),type:u.parentNode.className.baseVal.split("-")[1]}),m.collapsedSeriesIndices.push(d);var k=m.risingSeries.indexOf(d);m.risingSeries.splice(k,1)}}else m.collapsedSeries.push({index:d,data:x[d]}),m.collapsedSeriesIndices.push(d);for(var L=u.childNodes,D=0;D0){for(var x=0;x1||!u.axisCharts)&&d.legend.show){for(;u.dom.elLegendWrap.firstChild;)u.dom.elLegendWrap.removeChild(u.dom.elLegendWrap.firstChild);this.drawLegends(),E.isIE11()?document.getElementsByTagName("head")[0].appendChild(this.legendHelpers.getLegendStyles()):this.legendHelpers.appendToForeignObject(),d.legend.position==="bottom"||d.legend.position==="top"?this.legendAlignHorizontal():d.legend.position!=="right"&&d.legend.position!=="left"||this.legendAlignVertical()}}},{key:"createLegendMarker",value:function(c){var u=c.i,d=c.fillcolor,v=this.w,m=document.createElement("span");m.classList.add("apexcharts-legend-marker");var x=v.config.legend.markers.shape||v.config.markers.shape,w=x;Array.isArray(x)&&(w=x[u]);var k=Array.isArray(v.config.legend.markers.size)?parseFloat(v.config.legend.markers.size[u]):parseFloat(v.config.legend.markers.size),L=Array.isArray(v.config.legend.markers.offsetX)?parseFloat(v.config.legend.markers.offsetX[u]):parseFloat(v.config.legend.markers.offsetX),D=Array.isArray(v.config.legend.markers.offsetY)?parseFloat(v.config.legend.markers.offsetY[u]):parseFloat(v.config.legend.markers.offsetY),P=Array.isArray(v.config.legend.markers.strokeWidth)?parseFloat(v.config.legend.markers.strokeWidth[u]):parseFloat(v.config.legend.markers.strokeWidth),V=m.style;if(V.height=2*(k+P)+"px",V.width=2*(k+P)+"px",V.left=L+"px",V.top=D+"px",v.config.legend.markers.customHTML)V.background="transparent",V.color=d[u],Array.isArray(v.config.legend.markers.customHTML)?v.config.legend.markers.customHTML[u]&&(m.innerHTML=v.config.legend.markers.customHTML[u]()):m.innerHTML=v.config.legend.markers.customHTML();else{var N=new Vt(this.ctx).getMarkerConfig({cssClass:"apexcharts-legend-marker apexcharts-marker apexcharts-marker-".concat(w),seriesIndex:u,strokeWidth:P,size:k}),j=SVG(m).size("100%","100%"),U=new $(this.ctx).drawMarker(0,0,i(i({},N),{},{pointFillColor:Array.isArray(d)?d[u]:N.pointFillColor,shape:w}));SVG.select(".apexcharts-legend-marker.apexcharts-marker").members.forEach(function(q){q.node.classList.contains("apexcharts-marker-triangle")?q.node.style.transform="translate(50%, 45%)":q.node.style.transform="translate(50%, 50%)"}),j.add(U)}return m}},{key:"drawLegends",value:function(){var c=this,u=this.w,d=u.config.legend.fontFamily,v=u.globals.seriesNames,m=u.config.legend.markers.fillColors?u.config.legend.markers.fillColors.slice():u.globals.colors.slice();if(u.config.chart.type==="heatmap"){var x=u.config.plotOptions.heatmap.colorScale.ranges;v=x.map(function(X){return X.name?X.name:X.from+" - "+X.to}),m=x.map(function(X){return X.color})}else this.isBarsDistributed&&(v=u.globals.labels.slice());u.config.legend.customLegendItems.length&&(v=u.config.legend.customLegendItems);for(var w=u.globals.legendFormatter,k=u.config.legend.inverseOrder,L=k?v.length-1:0;k?L>=0:L<=v.length-1;k?L--:L++){var D,P=w(v[L],{seriesIndex:L,w:u}),V=!1,N=!1;if(u.globals.collapsedSeries.length>0)for(var j=0;j0)for(var U=0;U0?L-10:0)+(D>0?D-10:0)}v.style.position="absolute",x=x+c+d.config.legend.offsetX,w=w+u+d.config.legend.offsetY,v.style.left=x+"px",v.style.top=w+"px",d.config.legend.position==="bottom"?(v.style.top="auto",v.style.bottom=5-d.config.legend.offsetY+"px"):d.config.legend.position==="right"&&(v.style.left="auto",v.style.right=25+d.config.legend.offsetX+"px"),["width","height"].forEach(function(P){v.style[P]&&(v.style[P]=parseInt(d.config.legend[P],10)+"px")})}},{key:"legendAlignHorizontal",value:function(){var c=this.w;c.globals.dom.elLegendWrap.style.right=0;var u=this.legendHelpers.getLegendDimensions(),d=new Pe(this.ctx),v=d.dimHelpers.getTitleSubtitleCoords("title"),m=d.dimHelpers.getTitleSubtitleCoords("subtitle"),x=0;c.config.legend.position==="bottom"?x=-u.clwh/1.8:c.config.legend.position==="top"&&(x=v.height+m.height+c.config.title.margin+c.config.subtitle.margin-10),this.setLegendWrapXY(20,x)}},{key:"legendAlignVertical",value:function(){var c=this.w,u=this.legendHelpers.getLegendDimensions(),d=0;c.config.legend.position==="left"&&(d=20),c.config.legend.position==="right"&&(d=c.globals.svgWidth-u.clww-10),this.setLegendWrapXY(d,20)}},{key:"onLegendHovered",value:function(c){var u=this.w,d=c.target.classList.contains("apexcharts-legend-series")||c.target.classList.contains("apexcharts-legend-text")||c.target.classList.contains("apexcharts-legend-marker");if(u.config.chart.type==="heatmap"||this.isBarsDistributed){if(d){var v=parseInt(c.target.getAttribute("rel"),10)-1;this.ctx.events.fireEvent("legendHover",[this.ctx,v,this.w]),new Kt(this.ctx).highlightRangeInSeries(c,c.target)}}else!c.target.classList.contains("apexcharts-inactive-legend")&&d&&new Kt(this.ctx).toggleSeriesOnHover(c,c.target)}},{key:"onLegendClick",value:function(c){var u=this.w;if(!u.config.legend.customLegendItems.length&&(c.target.classList.contains("apexcharts-legend-series")||c.target.classList.contains("apexcharts-legend-text")||c.target.classList.contains("apexcharts-legend-marker"))){var d=parseInt(c.target.getAttribute("rel"),10)-1,v=c.target.getAttribute("data:collapsed")==="true",m=this.w.config.chart.events.legendClick;typeof m=="function"&&m(this.ctx,d,this.w),this.ctx.events.fireEvent("legendClick",[this.ctx,d,this.w]);var x=this.w.config.legend.markers.onClick;typeof x=="function"&&c.target.classList.contains("apexcharts-legend-marker")&&(x(this.ctx,d,this.w),this.ctx.events.fireEvent("legendMarkerClick",[this.ctx,d,this.w])),u.config.chart.type!=="treemap"&&u.config.chart.type!=="heatmap"&&!this.isBarsDistributed&&u.config.legend.onItemClick.toggleDataSeries&&this.legendHelpers.toggleDataSeries(d,v)}}}]),Q}(),Mt=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w;var u=this.w;this.ev=this.w.config.chart.events,this.selectedClass="apexcharts-selected",this.localeValues=this.w.globals.locale.toolbar,this.minX=u.globals.minX,this.maxX=u.globals.maxX}return l(Q,[{key:"createToolbar",value:function(){var c=this,u=this.w,d=function(){return document.createElement("div")},v=d();if(v.setAttribute("class","apexcharts-toolbar"),v.style.top=u.config.chart.toolbar.offsetY+"px",v.style.right=3-u.config.chart.toolbar.offsetX+"px",u.globals.dom.elWrap.appendChild(v),this.elZoom=d(),this.elZoomIn=d(),this.elZoomOut=d(),this.elPan=d(),this.elSelection=d(),this.elZoomReset=d(),this.elMenuIcon=d(),this.elMenu=d(),this.elCustomIcons=[],this.t=u.config.chart.toolbar.tools,Array.isArray(this.t.customIcons))for(var m=0;m @@ -1130,14 +1130,14 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho `,title:this.localeValues.pan,class:u.globals.isTouchDevice?"apexcharts-element-hidden":"apexcharts-pan-icon"}),w("reset",this.elZoomReset,` -`),this.t.download&&x.push({el:this.elMenuIcon,icon:typeof this.t.download=="string"?this.t.download:'',title:this.localeValues.menu,class:"apexcharts-menu-icon"});for(var L=0;L0&&v.height>0&&this.slDraggableRect.selectize({points:"l, r",pointSize:8,pointType:"rect"}).resize({constraint:{minX:0,minY:0,maxX:d.globals.gridWidth,maxY:d.globals.gridHeight}}).on("resizing",this.selectionDragging.bind(this,"resizing"))}}},{key:"preselectedSelection",value:function(){var d=this.w,v=this.xyRatios;if(!d.globals.zoomEnabled){if(d.globals.selection!==void 0&&d.globals.selection!==null)this.drawSelectionRect(d.globals.selection);else if(d.config.chart.selection.xaxis.min!==void 0&&d.config.chart.selection.xaxis.max!==void 0){var m=(d.config.chart.selection.xaxis.min-d.globals.minX)/v.xRatio,x=d.globals.gridWidth-(d.globals.maxX-d.config.chart.selection.xaxis.max)/v.xRatio-m;d.globals.isRangeBar&&(m=(d.config.chart.selection.xaxis.min-d.globals.yAxisScale[0].niceMin)/v.invertedYRatio,x=(d.config.chart.selection.xaxis.max-d.config.chart.selection.xaxis.min)/v.invertedYRatio);var w={x:m,y:0,width:x,height:d.globals.gridHeight,translateX:0,translateY:0,selectionEnabled:!0};this.drawSelectionRect(w),this.makeSelectionRectDraggable(),typeof d.config.chart.events.selection=="function"&&d.config.chart.events.selection(this.ctx,{xaxis:{min:d.config.chart.selection.xaxis.min,max:d.config.chart.selection.xaxis.max},yaxis:{}})}}}},{key:"drawSelectionRect",value:function(d){var v=d.x,m=d.y,x=d.width,w=d.height,k=d.translateX,L=k===void 0?0:k,D=d.translateY,P=D===void 0?0:D,V=this.w,N=this.zoomRect,j=this.selectionRect;if(this.dragged||V.globals.selection!==null){var U={transform:"translate("+L+", "+P+")"};V.globals.zoomEnabled&&this.dragged&&(x<0&&(x=1),N.attr({x:v,y:m,width:x,height:w,fill:V.config.chart.zoom.zoomedArea.fill.color,"fill-opacity":V.config.chart.zoom.zoomedArea.fill.opacity,stroke:V.config.chart.zoom.zoomedArea.stroke.color,"stroke-width":V.config.chart.zoom.zoomedArea.stroke.width,"stroke-opacity":V.config.chart.zoom.zoomedArea.stroke.opacity}),$.setAttrs(N.node,U)),V.globals.selectionEnabled&&(j.attr({x:v,y:m,width:x>0?x:0,height:w>0?w:0,fill:V.config.chart.selection.fill.color,"fill-opacity":V.config.chart.selection.fill.opacity,stroke:V.config.chart.selection.stroke.color,"stroke-width":V.config.chart.selection.stroke.width,"stroke-dasharray":V.config.chart.selection.stroke.dashArray,"stroke-opacity":V.config.chart.selection.stroke.opacity}),$.setAttrs(j.node,U))}}},{key:"hideSelectionRect",value:function(d){d&&d.attr({x:0,y:0,width:0,height:0})}},{key:"selectionDrawing",value:function(d){var v=d.context,m=d.zoomtype,x=this.w,w=v,k=this.gridRect.getBoundingClientRect(),L=w.startX-1,D=w.startY,P=!1,V=!1,N=w.clientX-k.left-L,j=w.clientY-k.top-D,U={};return Math.abs(N+L)>x.globals.gridWidth?N=x.globals.gridWidth-L:w.clientX-k.left<0&&(N=L),L>w.clientX-k.left&&(P=!0,N=Math.abs(N)),D>w.clientY-k.top&&(V=!0,j=Math.abs(j)),U=m==="x"?{x:P?L-N:L,y:0,width:N,height:x.globals.gridHeight}:m==="y"?{x:0,y:V?D-j:D,width:x.globals.gridWidth,height:j}:{x:P?L-N:L,y:V?D-j:D,width:N,height:j},w.drawSelectionRect(U),w.selectionDragging("resizing"),U}},{key:"selectionDragging",value:function(d,v){var m=this,x=this.w,w=this.xyRatios,k=this.selectionRect,L=0;d==="resizing"&&(L=30);var D=function(V){return parseFloat(k.node.getAttribute(V))},P={x:D("x"),y:D("y"),width:D("width"),height:D("height")};x.globals.selection=P,typeof x.config.chart.events.selection=="function"&&x.globals.selectionEnabled&&(clearTimeout(this.w.globals.selectionResizeTimer),this.w.globals.selectionResizeTimer=window.setTimeout(function(){var V,N,j,U,q=m.gridRect.getBoundingClientRect(),J=k.node.getBoundingClientRect();x.globals.isRangeBar?(V=x.globals.yAxisScale[0].niceMin+(J.left-q.left)*w.invertedYRatio,N=x.globals.yAxisScale[0].niceMin+(J.right-q.left)*w.invertedYRatio,j=0,U=1):(V=x.globals.xAxisScale.niceMin+(J.left-q.left)*w.xRatio,N=x.globals.xAxisScale.niceMin+(J.right-q.left)*w.xRatio,j=x.globals.yAxisScale[0].niceMin+(q.bottom-J.bottom)*w.yRatio[0],U=x.globals.yAxisScale[0].niceMax-(J.top-q.top)*w.yRatio[0]);var rt={xaxis:{min:V,max:N},yaxis:{min:j,max:U}};x.config.chart.events.selection(m.ctx,rt),x.config.chart.brush.enabled&&x.config.chart.events.brushScrolled!==void 0&&x.config.chart.events.brushScrolled(m.ctx,rt)},L))}},{key:"selectionDrawn",value:function(d){var v=d.context,m=d.zoomtype,x=this.w,w=v,k=this.xyRatios,L=this.ctx.toolbar;if(w.startX>w.endX){var D=w.startX;w.startX=w.endX,w.endX=D}if(w.startY>w.endY){var P=w.startY;w.startY=w.endY,w.endY=P}var V=void 0,N=void 0;x.globals.isRangeBar?(V=x.globals.yAxisScale[0].niceMin+w.startX*k.invertedYRatio,N=x.globals.yAxisScale[0].niceMin+w.endX*k.invertedYRatio):(V=x.globals.xAxisScale.niceMin+w.startX*k.xRatio,N=x.globals.xAxisScale.niceMin+w.endX*k.xRatio);var j=[],U=[];if(x.config.yaxis.forEach(function(ot,nt){var ct=x.globals.seriesYAxisMap[nt][0];j.push(x.globals.yAxisScale[nt].niceMax-k.yRatio[ct]*w.startY),U.push(x.globals.yAxisScale[nt].niceMax-k.yRatio[ct]*w.endY)}),w.dragged&&(w.dragX>10||w.dragY>10)&&V!==N){if(x.globals.zoomEnabled){var q=E.clone(x.globals.initialConfig.yaxis),J=E.clone(x.globals.initialConfig.xaxis);if(x.globals.zoomed=!0,x.config.xaxis.convertedCatToNumeric&&(V=Math.floor(V),N=Math.floor(N),V<1&&(V=1,N=x.globals.dataPoints),N-V<2&&(N=V+1)),m!=="xy"&&m!=="x"||(J={min:V,max:N}),m!=="xy"&&m!=="y"||q.forEach(function(ot,nt){q[nt].min=U[nt],q[nt].max=j[nt]}),L){var rt=L.getBeforeZoomRange(J,q);rt&&(J=rt.xaxis?rt.xaxis:J,q=rt.yaxis?rt.yaxis:q)}var A={xaxis:J};x.config.chart.group||(A.yaxis=q),w.ctx.updateHelpers._updateOptions(A,!1,w.w.config.chart.animations.dynamicAnimation.enabled),typeof x.config.chart.events.zoomed=="function"&&L.zoomCallback(J,q)}else if(x.globals.selectionEnabled){var O,X=null;O={min:V,max:N},m!=="xy"&&m!=="y"||(X=E.clone(x.config.yaxis)).forEach(function(ot,nt){X[nt].min=U[nt],X[nt].max=j[nt]}),x.globals.selection=w.selection,typeof x.config.chart.events.selection=="function"&&x.config.chart.events.selection(w.ctx,{xaxis:O,yaxis:X})}}}},{key:"panDragging",value:function(d){var v=d.context,m=this.w,x=v;if(m.globals.lastClientPosition.x!==void 0){var w=m.globals.lastClientPosition.x-x.clientX,k=m.globals.lastClientPosition.y-x.clientY;Math.abs(w)>Math.abs(k)&&w>0?this.moveDirection="left":Math.abs(w)>Math.abs(k)&&w<0?this.moveDirection="right":Math.abs(k)>Math.abs(w)&&k>0?this.moveDirection="up":Math.abs(k)>Math.abs(w)&&k<0&&(this.moveDirection="down")}m.globals.lastClientPosition={x:x.clientX,y:x.clientY};var L=m.globals.isRangeBar?m.globals.minY:m.globals.minX,D=m.globals.isRangeBar?m.globals.maxY:m.globals.maxX;m.config.xaxis.convertedCatToNumeric||x.panScrolled(L,D)}},{key:"delayedPanScrolled",value:function(){var d=this.w,v=d.globals.minX,m=d.globals.maxX,x=(d.globals.maxX-d.globals.minX)/2;this.moveDirection==="left"?(v=d.globals.minX+x,m=d.globals.maxX+x):this.moveDirection==="right"&&(v=d.globals.minX-x,m=d.globals.maxX-x),v=Math.floor(v),m=Math.floor(m),this.updateScrolledChart({xaxis:{min:v,max:m}},v,m)}},{key:"panScrolled",value:function(d,v){var m=this.w,x=this.xyRatios,w=E.clone(m.globals.initialConfig.yaxis),k=x.xRatio,L=m.globals.minX,D=m.globals.maxX;m.globals.isRangeBar&&(k=x.invertedYRatio,L=m.globals.minY,D=m.globals.maxY),this.moveDirection==="left"?(d=L+m.globals.gridWidth/15*k,v=D+m.globals.gridWidth/15*k):this.moveDirection==="right"&&(d=L-m.globals.gridWidth/15*k,v=D-m.globals.gridWidth/15*k),m.globals.isRangeBar||(dm.globals.initialMaxX)&&(d=L,v=D);var P={xaxis:{min:d,max:v}};m.config.chart.group||(P.yaxis=w),this.updateScrolledChart(P,d,v)}},{key:"updateScrolledChart",value:function(d,v,m){var x=this.w;this.ctx.updateHelpers._updateOptions(d,!1,!1),typeof x.config.chart.events.scrolled=="function"&&x.config.chart.events.scrolled(this.ctx,{xaxis:{min:v,max:m}})}}]),u}(),Rt=function(){function Q(c){a(this,Q),this.w=c.w,this.ttCtx=c,this.ctx=c.ctx}return l(Q,[{key:"getNearestValues",value:function(c){var u=c.hoverArea,d=c.elGrid,v=c.clientX,m=c.clientY,x=this.w,w=d.getBoundingClientRect(),k=w.width,L=w.height,D=k/(x.globals.dataPoints-1),P=L/x.globals.dataPoints,V=this.hasBars();!x.globals.comboCharts&&!V||x.config.xaxis.convertedCatToNumeric||(D=k/x.globals.dataPoints);var N=v-w.left-x.globals.barPadForNumericAxis,j=m-w.top;N<0||j<0||N>k||j>L?(u.classList.remove("hovering-zoom"),u.classList.remove("hovering-pan")):x.globals.zoomEnabled?(u.classList.remove("hovering-pan"),u.classList.add("hovering-zoom")):x.globals.panEnabled&&(u.classList.remove("hovering-zoom"),u.classList.add("hovering-pan"));var U=Math.round(N/D),q=Math.floor(j/P);V&&!x.config.xaxis.convertedCatToNumeric&&(U=Math.ceil(N/D),U-=1);var J=null,rt=null,A=x.globals.seriesXvalues.map(function(ct){return ct.filter(function(wt){return E.isNumber(wt)})}),O=x.globals.seriesYvalues.map(function(ct){return ct.filter(function(wt){return E.isNumber(wt)})});if(x.globals.isXNumeric){var X=this.ttCtx.getElGrid().getBoundingClientRect(),ot=N*(X.width/k),nt=j*(X.height/L);J=(rt=this.closestInMultiArray(ot,nt,A,O)).index,U=rt.j,J!==null&&(A=x.globals.seriesXvalues[J],U=(rt=this.closestInArray(ot,A)).index)}return x.globals.capturedSeriesIndex=J===null?-1:J,(!U||U<1)&&(U=0),x.globals.isBarHorizontal?x.globals.capturedDataPointIndex=q:x.globals.capturedDataPointIndex=U,{capturedSeries:J,j:x.globals.isBarHorizontal?q:U,hoverX:N,hoverY:j}}},{key:"closestInMultiArray",value:function(c,u,d,v){var m=this.w,x=0,w=null,k=-1;m.globals.series.length>1?x=this.getFirstActiveXArray(d):w=0;var L=d[x][0],D=Math.abs(c-L);if(d.forEach(function(N){N.forEach(function(j,U){var q=Math.abs(c-j);q<=D&&(D=q,k=U)})}),k!==-1){var P=v[x][k],V=Math.abs(u-P);w=x,v.forEach(function(N,j){var U=Math.abs(u-N[k]);U<=V&&(V=U,w=j)})}return{index:w,j:k}}},{key:"getFirstActiveXArray",value:function(c){for(var u=this.w,d=0,v=c.map(function(x,w){return x.length>0?w:-1}),m=0;m0)for(var v=0;v *")):this.w.globals.dom.baseEl.querySelectorAll(".apexcharts-series-markers-wrap > *")}},{key:"getAllMarkers",value:function(){var c=this.w.globals.dom.baseEl.querySelectorAll(".apexcharts-series-markers-wrap");(c=I(c)).sort(function(d,v){var m=Number(d.getAttribute("data:realIndex")),x=Number(v.getAttribute("data:realIndex"));return xm?-1:0});var u=[];return c.forEach(function(d){u.push(d.querySelector(".apexcharts-marker"))}),u}},{key:"hasMarkers",value:function(c){return this.getElMarkers(c).length>0}},{key:"getPathFromPoint",value:function(c,u){var d=Number(c.getAttribute("cx")),v=Number(c.getAttribute("cy")),m=c.getAttribute("shape");return new $(this.ctx).getMarkerPath(d,v,m,u)}},{key:"getElBars",value:function(){return this.w.globals.dom.baseEl.querySelectorAll(".apexcharts-bar-series, .apexcharts-candlestick-series, .apexcharts-boxPlot-series, .apexcharts-rangebar-series")}},{key:"hasBars",value:function(){return this.getElBars().length>0}},{key:"getHoverMarkerSize",value:function(c){var u=this.w,d=u.config.markers.hover.size;return d===void 0&&(d=u.globals.markers.size[c]+u.config.markers.hover.sizeOffset),d}},{key:"toggleAllTooltipSeriesGroups",value:function(c){var u=this.w,d=this.ttCtx;d.allTooltipSeriesGroups.length===0&&(d.allTooltipSeriesGroups=u.globals.dom.baseEl.querySelectorAll(".apexcharts-tooltip-series-group"));for(var v=d.allTooltipSeriesGroups,m=0;m
').concat(xt.attrs.name,"
"),wt+="
".concat(xt.val,"
")}),A.innerHTML=ct+"
",O.innerHTML=wt+"
"};w?L.globals.seriesGoals[u][d]&&Array.isArray(L.globals.seriesGoals[u][d])?X():(A.innerHTML="",O.innerHTML=""):X()}else A.innerHTML="",O.innerHTML="";if(U!==null&&(v[u].querySelector(".apexcharts-tooltip-text-z-label").innerHTML=L.config.tooltip.z.title,v[u].querySelector(".apexcharts-tooltip-text-z-value").innerHTML=U!==void 0?U:""),w&&q[0]){if(L.config.tooltip.hideEmptySeries){var ot=v[u].querySelector(".apexcharts-tooltip-marker"),nt=v[u].querySelector(".apexcharts-tooltip-text");parseFloat(P)==0?(ot.style.display="none",nt.style.display="none"):(ot.style.display="block",nt.style.display="block")}P==null||L.globals.ancillaryCollapsedSeriesIndices.indexOf(u)>-1||L.globals.collapsedSeriesIndices.indexOf(u)>-1||Array.isArray(D.tConfig.enabledOnSeries)&&D.tConfig.enabledOnSeries.indexOf(u)===-1?q[0].parentNode.style.display="none":q[0].parentNode.style.display=L.config.tooltip.items.display}else Array.isArray(D.tConfig.enabledOnSeries)&&D.tConfig.enabledOnSeries.indexOf(u)===-1&&(q[0].parentNode.style.display="none")}},{key:"toggleActiveInactiveSeries",value:function(c,u){var d=this.w;if(c)this.tooltipUtil.toggleAllTooltipSeriesGroups("enable");else{this.tooltipUtil.toggleAllTooltipSeriesGroups("disable");var v=d.globals.dom.baseEl.querySelector(".apexcharts-tooltip-series-group-".concat(u));v&&(v.classList.add("apexcharts-active"),v.style.display=d.config.tooltip.items.display)}}},{key:"getValuesToPrint",value:function(c){var u=c.i,d=c.j,v=this.w,m=this.ctx.series.filteredSeriesX(),x="",w="",k=null,L=null,D={series:v.globals.series,seriesIndex:u,dataPointIndex:d,w:v},P=v.globals.ttZFormatter;d===null?L=v.globals.series[u]:v.globals.isXNumeric&&v.config.chart.type!=="treemap"?(x=m[u][d],m[u].length===0&&(x=m[this.tooltipUtil.getFirstActiveXArray(m)][d])):x=v.globals.labels[d]!==void 0?v.globals.labels[d]:"";var V=x;return v.globals.isXNumeric&&v.config.xaxis.type==="datetime"?x=new at(this.ctx).xLabelFormat(v.globals.ttKeyFormatter,V,V,{i:void 0,dateFormatter:new et(this.ctx).formatDate,w:this.w}):x=v.globals.isBarHorizontal?v.globals.yLabelFormatters[0](V,D):v.globals.xLabelFormatter(V,D),v.config.tooltip.x.formatter!==void 0&&(x=v.globals.ttKeyFormatter(V,D)),v.globals.seriesZ.length>0&&v.globals.seriesZ[u].length>0&&(k=P(v.globals.seriesZ[u][d],v)),w=typeof v.config.xaxis.tooltip.formatter=="function"?v.globals.xaxisTooltipFormatter(V,D):x,{val:Array.isArray(L)?L.join(" "):L,xVal:Array.isArray(x)?x.join(" "):x,xAxisTTVal:Array.isArray(w)?w.join(" "):w,zVal:k}}},{key:"handleCustomTooltip",value:function(c){var u=c.i,d=c.j,v=c.y1,m=c.y2,x=c.w,w=this.ttCtx.getElTooltip(),k=x.config.tooltip.custom;Array.isArray(k)&&k[u]&&(k=k[u]),w.innerHTML=k({ctx:this.ctx,series:x.globals.series,seriesIndex:u,dataPointIndex:d,y1:v,y2:m,w:x})}}]),Q}(),Qt=function(){function Q(c){a(this,Q),this.ttCtx=c,this.ctx=c.ctx,this.w=c.w}return l(Q,[{key:"moveXCrosshairs",value:function(c){var u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:null,d=this.ttCtx,v=this.w,m=d.getElXCrosshairs(),x=c-d.xcrosshairsWidth/2,w=v.globals.labels.slice().length;if(u!==null&&(x=v.globals.gridWidth/w*u),m===null||v.globals.isBarHorizontal||(m.setAttribute("x",x),m.setAttribute("x1",x),m.setAttribute("x2",x),m.setAttribute("y2",v.globals.gridHeight),m.classList.add("apexcharts-active")),x<0&&(x=0),x>v.globals.gridWidth&&(x=v.globals.gridWidth),d.isXAxisTooltipEnabled){var k=x;v.config.xaxis.crosshairs.width!=="tickWidth"&&v.config.xaxis.crosshairs.width!=="barWidth"||(k=x+d.xcrosshairsWidth/2),this.moveXAxisTooltip(k)}}},{key:"moveYCrosshairs",value:function(c){var u=this.ttCtx;u.ycrosshairs!==null&&$.setAttrs(u.ycrosshairs,{y1:c,y2:c}),u.ycrosshairsHidden!==null&&$.setAttrs(u.ycrosshairsHidden,{y1:c,y2:c})}},{key:"moveXAxisTooltip",value:function(c){var u=this.w,d=this.ttCtx;if(d.xaxisTooltip!==null&&d.xcrosshairsWidth!==0){d.xaxisTooltip.classList.add("apexcharts-active");var v=d.xaxisOffY+u.config.xaxis.tooltip.offsetY+u.globals.translateY+1+u.config.xaxis.offsetY;if(c-=d.xaxisTooltip.getBoundingClientRect().width/2,!isNaN(c)){c+=u.globals.translateX;var m;m=new $(this.ctx).getTextRects(d.xaxisTooltipText.innerHTML),d.xaxisTooltipText.style.minWidth=m.width+"px",d.xaxisTooltip.style.left=c+"px",d.xaxisTooltip.style.top=v+"px"}}}},{key:"moveYAxisTooltip",value:function(c){var u=this.w,d=this.ttCtx;d.yaxisTTEls===null&&(d.yaxisTTEls=u.globals.dom.baseEl.querySelectorAll(".apexcharts-yaxistooltip"));var v=parseInt(d.ycrosshairsHidden.getAttribute("y1"),10),m=u.globals.translateY+v,x=d.yaxisTTEls[c].getBoundingClientRect().height,w=u.globals.translateYAxisX[c]-2;u.config.yaxis[c].opposite&&(w-=26),m-=x/2,u.globals.ignoreYAxisIndexes.indexOf(c)===-1?(d.yaxisTTEls[c].classList.add("apexcharts-active"),d.yaxisTTEls[c].style.top=m+"px",d.yaxisTTEls[c].style.left=w+u.config.yaxis[c].tooltip.offsetX+"px"):d.yaxisTTEls[c].classList.remove("apexcharts-active")}},{key:"moveTooltip",value:function(c,u){var d=arguments.length>2&&arguments[2]!==void 0?arguments[2]:null,v=this.w,m=this.ttCtx,x=m.getElTooltip(),w=m.tooltipRect,k=d!==null?parseFloat(d):1,L=parseFloat(c)+k+5,D=parseFloat(u)+k/2;if(L>v.globals.gridWidth/2&&(L=L-w.ttWidth-k-10),L>v.globals.gridWidth-w.ttWidth-10&&(L=v.globals.gridWidth-w.ttWidth),L<-20&&(L=-20),v.config.tooltip.followCursor){var P=m.getElGrid().getBoundingClientRect();(L=m.e.clientX-P.left)>v.globals.gridWidth/2&&(L-=m.tooltipRect.ttWidth),(D=m.e.clientY+v.globals.translateY-P.top)>v.globals.gridHeight/2&&(D-=m.tooltipRect.ttHeight)}else v.globals.isBarHorizontal||w.ttHeight/2+D>v.globals.gridHeight&&(D=v.globals.gridHeight-w.ttHeight+v.globals.translateY);isNaN(L)||(L+=v.globals.translateX,x.style.left=L+"px",x.style.top=D+"px")}},{key:"moveMarkers",value:function(c,u){var d=this.w,v=this.ttCtx;if(d.globals.markers.size[c]>0)for(var m=d.globals.dom.baseEl.querySelectorAll(" .apexcharts-series[data\\:realIndex='".concat(c,"'] .apexcharts-marker")),x=0;x0){var j=N.getAttribute("shape"),U=L.getMarkerPath(m,x,j,1.5*P);N.setAttribute("d",U)}this.moveXCrosshairs(m),k.fixedTooltip||this.moveTooltip(m,x,P)}}},{key:"moveDynamicPointsOnHover",value:function(c){var u,d=this.ttCtx,v=d.w,m=0,x=0,w=v.globals.pointsArray,k=new Xt(this.ctx),L=new $(this.ctx);u=k.getActiveConfigSeriesIndex("asc",["line","area","scatter","bubble"]);var D=d.tooltipUtil.getHoverMarkerSize(u);w[u]&&(m=w[u][c][0],x=w[u][c][1]);var P=d.tooltipUtil.getAllMarkers();if(P!==null)for(var V=0;V0){var rt=L.getMarkerPath(m,j,q,D);P[V].setAttribute("d",rt)}else P[V].setAttribute("d","")}}this.moveXCrosshairs(m),d.fixedTooltip||this.moveTooltip(m,x||v.globals.gridHeight,D)}},{key:"moveStickyTooltipOverBars",value:function(c,u){var d=this.w,v=this.ttCtx,m=d.globals.columnSeries?d.globals.columnSeries.length:d.globals.series.length,x=m>=2&&m%2==0?Math.floor(m/2):Math.floor(m/2)+1;d.globals.isBarHorizontal&&(x=new Xt(this.ctx).getActiveConfigSeriesIndex("desc")+1);var w=d.globals.dom.baseEl.querySelector(".apexcharts-bar-series .apexcharts-series[rel='".concat(x,"'] path[j='").concat(c,"'], .apexcharts-candlestick-series .apexcharts-series[rel='").concat(x,"'] path[j='").concat(c,"'], .apexcharts-boxPlot-series .apexcharts-series[rel='").concat(x,"'] path[j='").concat(c,"'], .apexcharts-rangebar-series .apexcharts-series[rel='").concat(x,"'] path[j='").concat(c,"']"));w||typeof u!="number"||(w=d.globals.dom.baseEl.querySelector(".apexcharts-bar-series .apexcharts-series[data\\:realIndex='".concat(u,"'] path[j='").concat(c,`'], +`),this.t.download&&x.push({el:this.elMenuIcon,icon:typeof this.t.download=="string"?this.t.download:'',title:this.localeValues.menu,class:"apexcharts-menu-icon"});for(var L=0;L0&&v.height>0&&this.slDraggableRect.selectize({points:"l, r",pointSize:8,pointType:"rect"}).resize({constraint:{minX:0,minY:0,maxX:d.globals.gridWidth,maxY:d.globals.gridHeight}}).on("resizing",this.selectionDragging.bind(this,"resizing"))}}},{key:"preselectedSelection",value:function(){var d=this.w,v=this.xyRatios;if(!d.globals.zoomEnabled){if(d.globals.selection!==void 0&&d.globals.selection!==null)this.drawSelectionRect(d.globals.selection);else if(d.config.chart.selection.xaxis.min!==void 0&&d.config.chart.selection.xaxis.max!==void 0){var m=(d.config.chart.selection.xaxis.min-d.globals.minX)/v.xRatio,x=d.globals.gridWidth-(d.globals.maxX-d.config.chart.selection.xaxis.max)/v.xRatio-m;d.globals.isRangeBar&&(m=(d.config.chart.selection.xaxis.min-d.globals.yAxisScale[0].niceMin)/v.invertedYRatio,x=(d.config.chart.selection.xaxis.max-d.config.chart.selection.xaxis.min)/v.invertedYRatio);var w={x:m,y:0,width:x,height:d.globals.gridHeight,translateX:0,translateY:0,selectionEnabled:!0};this.drawSelectionRect(w),this.makeSelectionRectDraggable(),typeof d.config.chart.events.selection=="function"&&d.config.chart.events.selection(this.ctx,{xaxis:{min:d.config.chart.selection.xaxis.min,max:d.config.chart.selection.xaxis.max},yaxis:{}})}}}},{key:"drawSelectionRect",value:function(d){var v=d.x,m=d.y,x=d.width,w=d.height,k=d.translateX,L=k===void 0?0:k,D=d.translateY,P=D===void 0?0:D,V=this.w,N=this.zoomRect,j=this.selectionRect;if(this.dragged||V.globals.selection!==null){var U={transform:"translate("+L+", "+P+")"};V.globals.zoomEnabled&&this.dragged&&(x<0&&(x=1),N.attr({x:v,y:m,width:x,height:w,fill:V.config.chart.zoom.zoomedArea.fill.color,"fill-opacity":V.config.chart.zoom.zoomedArea.fill.opacity,stroke:V.config.chart.zoom.zoomedArea.stroke.color,"stroke-width":V.config.chart.zoom.zoomedArea.stroke.width,"stroke-opacity":V.config.chart.zoom.zoomedArea.stroke.opacity}),$.setAttrs(N.node,U)),V.globals.selectionEnabled&&(j.attr({x:v,y:m,width:x>0?x:0,height:w>0?w:0,fill:V.config.chart.selection.fill.color,"fill-opacity":V.config.chart.selection.fill.opacity,stroke:V.config.chart.selection.stroke.color,"stroke-width":V.config.chart.selection.stroke.width,"stroke-dasharray":V.config.chart.selection.stroke.dashArray,"stroke-opacity":V.config.chart.selection.stroke.opacity}),$.setAttrs(j.node,U))}}},{key:"hideSelectionRect",value:function(d){d&&d.attr({x:0,y:0,width:0,height:0})}},{key:"selectionDrawing",value:function(d){var v=d.context,m=d.zoomtype,x=this.w,w=v,k=this.gridRect.getBoundingClientRect(),L=w.startX-1,D=w.startY,P=!1,V=!1,N=w.clientX-k.left-L,j=w.clientY-k.top-D,U={};return Math.abs(N+L)>x.globals.gridWidth?N=x.globals.gridWidth-L:w.clientX-k.left<0&&(N=L),L>w.clientX-k.left&&(P=!0,N=Math.abs(N)),D>w.clientY-k.top&&(V=!0,j=Math.abs(j)),U=m==="x"?{x:P?L-N:L,y:0,width:N,height:x.globals.gridHeight}:m==="y"?{x:0,y:V?D-j:D,width:x.globals.gridWidth,height:j}:{x:P?L-N:L,y:V?D-j:D,width:N,height:j},w.drawSelectionRect(U),w.selectionDragging("resizing"),U}},{key:"selectionDragging",value:function(d,v){var m=this,x=this.w,w=this.xyRatios,k=this.selectionRect,L=0;d==="resizing"&&(L=30);var D=function(V){return parseFloat(k.node.getAttribute(V))},P={x:D("x"),y:D("y"),width:D("width"),height:D("height")};x.globals.selection=P,typeof x.config.chart.events.selection=="function"&&x.globals.selectionEnabled&&(clearTimeout(this.w.globals.selectionResizeTimer),this.w.globals.selectionResizeTimer=window.setTimeout(function(){var V,N,j,U,q=m.gridRect.getBoundingClientRect(),J=k.node.getBoundingClientRect();x.globals.isRangeBar?(V=x.globals.yAxisScale[0].niceMin+(J.left-q.left)*w.invertedYRatio,N=x.globals.yAxisScale[0].niceMin+(J.right-q.left)*w.invertedYRatio,j=0,U=1):(V=x.globals.xAxisScale.niceMin+(J.left-q.left)*w.xRatio,N=x.globals.xAxisScale.niceMin+(J.right-q.left)*w.xRatio,j=x.globals.yAxisScale[0].niceMin+(q.bottom-J.bottom)*w.yRatio[0],U=x.globals.yAxisScale[0].niceMax-(J.top-q.top)*w.yRatio[0]);var rt={xaxis:{min:V,max:N},yaxis:{min:j,max:U}};x.config.chart.events.selection(m.ctx,rt),x.config.chart.brush.enabled&&x.config.chart.events.brushScrolled!==void 0&&x.config.chart.events.brushScrolled(m.ctx,rt)},L))}},{key:"selectionDrawn",value:function(d){var v=d.context,m=d.zoomtype,x=this.w,w=v,k=this.xyRatios,L=this.ctx.toolbar;if(w.startX>w.endX){var D=w.startX;w.startX=w.endX,w.endX=D}if(w.startY>w.endY){var P=w.startY;w.startY=w.endY,w.endY=P}var V=void 0,N=void 0;x.globals.isRangeBar?(V=x.globals.yAxisScale[0].niceMin+w.startX*k.invertedYRatio,N=x.globals.yAxisScale[0].niceMin+w.endX*k.invertedYRatio):(V=x.globals.xAxisScale.niceMin+w.startX*k.xRatio,N=x.globals.xAxisScale.niceMin+w.endX*k.xRatio);var j=[],U=[];if(x.config.yaxis.forEach(function(ot,nt){var ct=x.globals.seriesYAxisMap[nt][0];j.push(x.globals.yAxisScale[nt].niceMax-k.yRatio[ct]*w.startY),U.push(x.globals.yAxisScale[nt].niceMax-k.yRatio[ct]*w.endY)}),w.dragged&&(w.dragX>10||w.dragY>10)&&V!==N){if(x.globals.zoomEnabled){var q=E.clone(x.globals.initialConfig.yaxis),J=E.clone(x.globals.initialConfig.xaxis);if(x.globals.zoomed=!0,x.config.xaxis.convertedCatToNumeric&&(V=Math.floor(V),N=Math.floor(N),V<1&&(V=1,N=x.globals.dataPoints),N-V<2&&(N=V+1)),m!=="xy"&&m!=="x"||(J={min:V,max:N}),m!=="xy"&&m!=="y"||q.forEach(function(ot,nt){q[nt].min=U[nt],q[nt].max=j[nt]}),L){var rt=L.getBeforeZoomRange(J,q);rt&&(J=rt.xaxis?rt.xaxis:J,q=rt.yaxis?rt.yaxis:q)}var A={xaxis:J};x.config.chart.group||(A.yaxis=q),w.ctx.updateHelpers._updateOptions(A,!1,w.w.config.chart.animations.dynamicAnimation.enabled),typeof x.config.chart.events.zoomed=="function"&&L.zoomCallback(J,q)}else if(x.globals.selectionEnabled){var O,X=null;O={min:V,max:N},m!=="xy"&&m!=="y"||(X=E.clone(x.config.yaxis)).forEach(function(ot,nt){X[nt].min=U[nt],X[nt].max=j[nt]}),x.globals.selection=w.selection,typeof x.config.chart.events.selection=="function"&&x.config.chart.events.selection(w.ctx,{xaxis:O,yaxis:X})}}}},{key:"panDragging",value:function(d){var v=d.context,m=this.w,x=v;if(m.globals.lastClientPosition.x!==void 0){var w=m.globals.lastClientPosition.x-x.clientX,k=m.globals.lastClientPosition.y-x.clientY;Math.abs(w)>Math.abs(k)&&w>0?this.moveDirection="left":Math.abs(w)>Math.abs(k)&&w<0?this.moveDirection="right":Math.abs(k)>Math.abs(w)&&k>0?this.moveDirection="up":Math.abs(k)>Math.abs(w)&&k<0&&(this.moveDirection="down")}m.globals.lastClientPosition={x:x.clientX,y:x.clientY};var L=m.globals.isRangeBar?m.globals.minY:m.globals.minX,D=m.globals.isRangeBar?m.globals.maxY:m.globals.maxX;m.config.xaxis.convertedCatToNumeric||x.panScrolled(L,D)}},{key:"delayedPanScrolled",value:function(){var d=this.w,v=d.globals.minX,m=d.globals.maxX,x=(d.globals.maxX-d.globals.minX)/2;this.moveDirection==="left"?(v=d.globals.minX+x,m=d.globals.maxX+x):this.moveDirection==="right"&&(v=d.globals.minX-x,m=d.globals.maxX-x),v=Math.floor(v),m=Math.floor(m),this.updateScrolledChart({xaxis:{min:v,max:m}},v,m)}},{key:"panScrolled",value:function(d,v){var m=this.w,x=this.xyRatios,w=E.clone(m.globals.initialConfig.yaxis),k=x.xRatio,L=m.globals.minX,D=m.globals.maxX;m.globals.isRangeBar&&(k=x.invertedYRatio,L=m.globals.minY,D=m.globals.maxY),this.moveDirection==="left"?(d=L+m.globals.gridWidth/15*k,v=D+m.globals.gridWidth/15*k):this.moveDirection==="right"&&(d=L-m.globals.gridWidth/15*k,v=D-m.globals.gridWidth/15*k),m.globals.isRangeBar||(dm.globals.initialMaxX)&&(d=L,v=D);var P={xaxis:{min:d,max:v}};m.config.chart.group||(P.yaxis=w),this.updateScrolledChart(P,d,v)}},{key:"updateScrolledChart",value:function(d,v,m){var x=this.w;this.ctx.updateHelpers._updateOptions(d,!1,!1),typeof x.config.chart.events.scrolled=="function"&&x.config.chart.events.scrolled(this.ctx,{xaxis:{min:v,max:m}})}}]),u}(),Pt=function(){function Q(c){a(this,Q),this.w=c.w,this.ttCtx=c,this.ctx=c.ctx}return l(Q,[{key:"getNearestValues",value:function(c){var u=c.hoverArea,d=c.elGrid,v=c.clientX,m=c.clientY,x=this.w,w=d.getBoundingClientRect(),k=w.width,L=w.height,D=k/(x.globals.dataPoints-1),P=L/x.globals.dataPoints,V=this.hasBars();!x.globals.comboCharts&&!V||x.config.xaxis.convertedCatToNumeric||(D=k/x.globals.dataPoints);var N=v-w.left-x.globals.barPadForNumericAxis,j=m-w.top;N<0||j<0||N>k||j>L?(u.classList.remove("hovering-zoom"),u.classList.remove("hovering-pan")):x.globals.zoomEnabled?(u.classList.remove("hovering-pan"),u.classList.add("hovering-zoom")):x.globals.panEnabled&&(u.classList.remove("hovering-zoom"),u.classList.add("hovering-pan"));var U=Math.round(N/D),q=Math.floor(j/P);V&&!x.config.xaxis.convertedCatToNumeric&&(U=Math.ceil(N/D),U-=1);var J=null,rt=null,A=x.globals.seriesXvalues.map(function(ct){return ct.filter(function(Ct){return E.isNumber(Ct)})}),O=x.globals.seriesYvalues.map(function(ct){return ct.filter(function(Ct){return E.isNumber(Ct)})});if(x.globals.isXNumeric){var X=this.ttCtx.getElGrid().getBoundingClientRect(),ot=N*(X.width/k),nt=j*(X.height/L);J=(rt=this.closestInMultiArray(ot,nt,A,O)).index,U=rt.j,J!==null&&(A=x.globals.seriesXvalues[J],U=(rt=this.closestInArray(ot,A)).index)}return x.globals.capturedSeriesIndex=J===null?-1:J,(!U||U<1)&&(U=0),x.globals.isBarHorizontal?x.globals.capturedDataPointIndex=q:x.globals.capturedDataPointIndex=U,{capturedSeries:J,j:x.globals.isBarHorizontal?q:U,hoverX:N,hoverY:j}}},{key:"closestInMultiArray",value:function(c,u,d,v){var m=this.w,x=0,w=null,k=-1;m.globals.series.length>1?x=this.getFirstActiveXArray(d):w=0;var L=d[x][0],D=Math.abs(c-L);if(d.forEach(function(N){N.forEach(function(j,U){var q=Math.abs(c-j);q<=D&&(D=q,k=U)})}),k!==-1){var P=v[x][k],V=Math.abs(u-P);w=x,v.forEach(function(N,j){var U=Math.abs(u-N[k]);U<=V&&(V=U,w=j)})}return{index:w,j:k}}},{key:"getFirstActiveXArray",value:function(c){for(var u=this.w,d=0,v=c.map(function(x,w){return x.length>0?w:-1}),m=0;m0)for(var v=0;v *")):this.w.globals.dom.baseEl.querySelectorAll(".apexcharts-series-markers-wrap > *")}},{key:"getAllMarkers",value:function(){var c=this.w.globals.dom.baseEl.querySelectorAll(".apexcharts-series-markers-wrap");(c=I(c)).sort(function(d,v){var m=Number(d.getAttribute("data:realIndex")),x=Number(v.getAttribute("data:realIndex"));return xm?-1:0});var u=[];return c.forEach(function(d){u.push(d.querySelector(".apexcharts-marker"))}),u}},{key:"hasMarkers",value:function(c){return this.getElMarkers(c).length>0}},{key:"getPathFromPoint",value:function(c,u){var d=Number(c.getAttribute("cx")),v=Number(c.getAttribute("cy")),m=c.getAttribute("shape");return new $(this.ctx).getMarkerPath(d,v,m,u)}},{key:"getElBars",value:function(){return this.w.globals.dom.baseEl.querySelectorAll(".apexcharts-bar-series, .apexcharts-candlestick-series, .apexcharts-boxPlot-series, .apexcharts-rangebar-series")}},{key:"hasBars",value:function(){return this.getElBars().length>0}},{key:"getHoverMarkerSize",value:function(c){var u=this.w,d=u.config.markers.hover.size;return d===void 0&&(d=u.globals.markers.size[c]+u.config.markers.hover.sizeOffset),d}},{key:"toggleAllTooltipSeriesGroups",value:function(c){var u=this.w,d=this.ttCtx;d.allTooltipSeriesGroups.length===0&&(d.allTooltipSeriesGroups=u.globals.dom.baseEl.querySelectorAll(".apexcharts-tooltip-series-group"));for(var v=d.allTooltipSeriesGroups,m=0;m ').concat(xt.attrs.name,""),Ct+="
".concat(xt.val,"
")}),A.innerHTML=ct+"",O.innerHTML=Ct+""};w?L.globals.seriesGoals[u][d]&&Array.isArray(L.globals.seriesGoals[u][d])?X():(A.innerHTML="",O.innerHTML=""):X()}else A.innerHTML="",O.innerHTML="";if(U!==null&&(v[u].querySelector(".apexcharts-tooltip-text-z-label").innerHTML=L.config.tooltip.z.title,v[u].querySelector(".apexcharts-tooltip-text-z-value").innerHTML=U!==void 0?U:""),w&&q[0]){if(L.config.tooltip.hideEmptySeries){var ot=v[u].querySelector(".apexcharts-tooltip-marker"),nt=v[u].querySelector(".apexcharts-tooltip-text");parseFloat(P)==0?(ot.style.display="none",nt.style.display="none"):(ot.style.display="block",nt.style.display="block")}P==null||L.globals.ancillaryCollapsedSeriesIndices.indexOf(u)>-1||L.globals.collapsedSeriesIndices.indexOf(u)>-1||Array.isArray(D.tConfig.enabledOnSeries)&&D.tConfig.enabledOnSeries.indexOf(u)===-1?q[0].parentNode.style.display="none":q[0].parentNode.style.display=L.config.tooltip.items.display}else Array.isArray(D.tConfig.enabledOnSeries)&&D.tConfig.enabledOnSeries.indexOf(u)===-1&&(q[0].parentNode.style.display="none")}},{key:"toggleActiveInactiveSeries",value:function(c,u){var d=this.w;if(c)this.tooltipUtil.toggleAllTooltipSeriesGroups("enable");else{this.tooltipUtil.toggleAllTooltipSeriesGroups("disable");var v=d.globals.dom.baseEl.querySelector(".apexcharts-tooltip-series-group-".concat(u));v&&(v.classList.add("apexcharts-active"),v.style.display=d.config.tooltip.items.display)}}},{key:"getValuesToPrint",value:function(c){var u=c.i,d=c.j,v=this.w,m=this.ctx.series.filteredSeriesX(),x="",w="",k=null,L=null,D={series:v.globals.series,seriesIndex:u,dataPointIndex:d,w:v},P=v.globals.ttZFormatter;d===null?L=v.globals.series[u]:v.globals.isXNumeric&&v.config.chart.type!=="treemap"?(x=m[u][d],m[u].length===0&&(x=m[this.tooltipUtil.getFirstActiveXArray(m)][d])):x=v.globals.labels[d]!==void 0?v.globals.labels[d]:"";var V=x;return v.globals.isXNumeric&&v.config.xaxis.type==="datetime"?x=new at(this.ctx).xLabelFormat(v.globals.ttKeyFormatter,V,V,{i:void 0,dateFormatter:new et(this.ctx).formatDate,w:this.w}):x=v.globals.isBarHorizontal?v.globals.yLabelFormatters[0](V,D):v.globals.xLabelFormatter(V,D),v.config.tooltip.x.formatter!==void 0&&(x=v.globals.ttKeyFormatter(V,D)),v.globals.seriesZ.length>0&&v.globals.seriesZ[u].length>0&&(k=P(v.globals.seriesZ[u][d],v)),w=typeof v.config.xaxis.tooltip.formatter=="function"?v.globals.xaxisTooltipFormatter(V,D):x,{val:Array.isArray(L)?L.join(" "):L,xVal:Array.isArray(x)?x.join(" "):x,xAxisTTVal:Array.isArray(w)?w.join(" "):w,zVal:k}}},{key:"handleCustomTooltip",value:function(c){var u=c.i,d=c.j,v=c.y1,m=c.y2,x=c.w,w=this.ttCtx.getElTooltip(),k=x.config.tooltip.custom;Array.isArray(k)&&k[u]&&(k=k[u]),w.innerHTML=k({ctx:this.ctx,series:x.globals.series,seriesIndex:u,dataPointIndex:d,y1:v,y2:m,w:x})}}]),Q}(),Zt=function(){function Q(c){a(this,Q),this.ttCtx=c,this.ctx=c.ctx,this.w=c.w}return l(Q,[{key:"moveXCrosshairs",value:function(c){var u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:null,d=this.ttCtx,v=this.w,m=d.getElXCrosshairs(),x=c-d.xcrosshairsWidth/2,w=v.globals.labels.slice().length;if(u!==null&&(x=v.globals.gridWidth/w*u),m===null||v.globals.isBarHorizontal||(m.setAttribute("x",x),m.setAttribute("x1",x),m.setAttribute("x2",x),m.setAttribute("y2",v.globals.gridHeight),m.classList.add("apexcharts-active")),x<0&&(x=0),x>v.globals.gridWidth&&(x=v.globals.gridWidth),d.isXAxisTooltipEnabled){var k=x;v.config.xaxis.crosshairs.width!=="tickWidth"&&v.config.xaxis.crosshairs.width!=="barWidth"||(k=x+d.xcrosshairsWidth/2),this.moveXAxisTooltip(k)}}},{key:"moveYCrosshairs",value:function(c){var u=this.ttCtx;u.ycrosshairs!==null&&$.setAttrs(u.ycrosshairs,{y1:c,y2:c}),u.ycrosshairsHidden!==null&&$.setAttrs(u.ycrosshairsHidden,{y1:c,y2:c})}},{key:"moveXAxisTooltip",value:function(c){var u=this.w,d=this.ttCtx;if(d.xaxisTooltip!==null&&d.xcrosshairsWidth!==0){d.xaxisTooltip.classList.add("apexcharts-active");var v=d.xaxisOffY+u.config.xaxis.tooltip.offsetY+u.globals.translateY+1+u.config.xaxis.offsetY;if(c-=d.xaxisTooltip.getBoundingClientRect().width/2,!isNaN(c)){c+=u.globals.translateX;var m;m=new $(this.ctx).getTextRects(d.xaxisTooltipText.innerHTML),d.xaxisTooltipText.style.minWidth=m.width+"px",d.xaxisTooltip.style.left=c+"px",d.xaxisTooltip.style.top=v+"px"}}}},{key:"moveYAxisTooltip",value:function(c){var u=this.w,d=this.ttCtx;d.yaxisTTEls===null&&(d.yaxisTTEls=u.globals.dom.baseEl.querySelectorAll(".apexcharts-yaxistooltip"));var v=parseInt(d.ycrosshairsHidden.getAttribute("y1"),10),m=u.globals.translateY+v,x=d.yaxisTTEls[c].getBoundingClientRect().height,w=u.globals.translateYAxisX[c]-2;u.config.yaxis[c].opposite&&(w-=26),m-=x/2,u.globals.ignoreYAxisIndexes.indexOf(c)===-1?(d.yaxisTTEls[c].classList.add("apexcharts-active"),d.yaxisTTEls[c].style.top=m+"px",d.yaxisTTEls[c].style.left=w+u.config.yaxis[c].tooltip.offsetX+"px"):d.yaxisTTEls[c].classList.remove("apexcharts-active")}},{key:"moveTooltip",value:function(c,u){var d=arguments.length>2&&arguments[2]!==void 0?arguments[2]:null,v=this.w,m=this.ttCtx,x=m.getElTooltip(),w=m.tooltipRect,k=d!==null?parseFloat(d):1,L=parseFloat(c)+k+5,D=parseFloat(u)+k/2;if(L>v.globals.gridWidth/2&&(L=L-w.ttWidth-k-10),L>v.globals.gridWidth-w.ttWidth-10&&(L=v.globals.gridWidth-w.ttWidth),L<-20&&(L=-20),v.config.tooltip.followCursor){var P=m.getElGrid().getBoundingClientRect();(L=m.e.clientX-P.left)>v.globals.gridWidth/2&&(L-=m.tooltipRect.ttWidth),(D=m.e.clientY+v.globals.translateY-P.top)>v.globals.gridHeight/2&&(D-=m.tooltipRect.ttHeight)}else v.globals.isBarHorizontal||w.ttHeight/2+D>v.globals.gridHeight&&(D=v.globals.gridHeight-w.ttHeight+v.globals.translateY);isNaN(L)||(L+=v.globals.translateX,x.style.left=L+"px",x.style.top=D+"px")}},{key:"moveMarkers",value:function(c,u){var d=this.w,v=this.ttCtx;if(d.globals.markers.size[c]>0)for(var m=d.globals.dom.baseEl.querySelectorAll(" .apexcharts-series[data\\:realIndex='".concat(c,"'] .apexcharts-marker")),x=0;x0){var j=N.getAttribute("shape"),U=L.getMarkerPath(m,x,j,1.5*P);N.setAttribute("d",U)}this.moveXCrosshairs(m),k.fixedTooltip||this.moveTooltip(m,x,P)}}},{key:"moveDynamicPointsOnHover",value:function(c){var u,d=this.ttCtx,v=d.w,m=0,x=0,w=v.globals.pointsArray,k=new Kt(this.ctx),L=new $(this.ctx);u=k.getActiveConfigSeriesIndex("asc",["line","area","scatter","bubble"]);var D=d.tooltipUtil.getHoverMarkerSize(u);w[u]&&(m=w[u][c][0],x=w[u][c][1]);var P=d.tooltipUtil.getAllMarkers();if(P!==null)for(var V=0;V0){var rt=L.getMarkerPath(m,j,q,D);P[V].setAttribute("d",rt)}else P[V].setAttribute("d","")}}this.moveXCrosshairs(m),d.fixedTooltip||this.moveTooltip(m,x||v.globals.gridHeight,D)}},{key:"moveStickyTooltipOverBars",value:function(c,u){var d=this.w,v=this.ttCtx,m=d.globals.columnSeries?d.globals.columnSeries.length:d.globals.series.length,x=m>=2&&m%2==0?Math.floor(m/2):Math.floor(m/2)+1;d.globals.isBarHorizontal&&(x=new Kt(this.ctx).getActiveConfigSeriesIndex("desc")+1);var w=d.globals.dom.baseEl.querySelector(".apexcharts-bar-series .apexcharts-series[rel='".concat(x,"'] path[j='").concat(c,"'], .apexcharts-candlestick-series .apexcharts-series[rel='").concat(x,"'] path[j='").concat(c,"'], .apexcharts-boxPlot-series .apexcharts-series[rel='").concat(x,"'] path[j='").concat(c,"'], .apexcharts-rangebar-series .apexcharts-series[rel='").concat(x,"'] path[j='").concat(c,"']"));w||typeof u!="number"||(w=d.globals.dom.baseEl.querySelector(".apexcharts-bar-series .apexcharts-series[data\\:realIndex='".concat(u,"'] path[j='").concat(c,`'], .apexcharts-candlestick-series .apexcharts-series[data\\:realIndex='`).concat(u,"'] path[j='").concat(c,`'], .apexcharts-boxPlot-series .apexcharts-series[data\\:realIndex='`).concat(u,"'] path[j='").concat(c,`'], - .apexcharts-rangebar-series .apexcharts-series[data\\:realIndex='`).concat(u,"'] path[j='").concat(c,"']")));var k=w?parseFloat(w.getAttribute("cx")):0,L=w?parseFloat(w.getAttribute("cy")):0,D=w?parseFloat(w.getAttribute("barWidth")):0,P=v.getElGrid().getBoundingClientRect(),V=w&&(w.classList.contains("apexcharts-candlestick-area")||w.classList.contains("apexcharts-boxPlot-area"));d.globals.isXNumeric?(w&&!V&&(k-=m%2!=0?D/2:0),w&&V&&d.globals.comboCharts&&(k-=D/2)):d.globals.isBarHorizontal||(k=v.xAxisTicksPositions[c-1]+v.dataPointsDividedWidth/2,isNaN(k)&&(k=v.xAxisTicksPositions[c]-v.dataPointsDividedWidth/2)),d.globals.isBarHorizontal?L-=v.tooltipRect.ttHeight:d.config.tooltip.followCursor?L=v.e.clientY-P.top-v.tooltipRect.ttHeight/2:L+v.tooltipRect.ttHeight+15>d.globals.gridHeight&&(L=d.globals.gridHeight),d.globals.isBarHorizontal||this.moveXCrosshairs(k),v.fixedTooltip||this.moveTooltip(k,L||d.globals.gridHeight)}}]),Q}(),ve=function(){function Q(c){a(this,Q),this.w=c.w,this.ttCtx=c,this.ctx=c.ctx,this.tooltipPosition=new Qt(c)}return l(Q,[{key:"drawDynamicPoints",value:function(){var c=this.w,u=new $(this.ctx),d=new Ft(this.ctx),v=c.globals.dom.baseEl.querySelectorAll(".apexcharts-series");v=I(v),c.config.chart.stacked&&v.sort(function(P,V){return parseFloat(P.getAttribute("data:realIndex"))-parseFloat(V.getAttribute("data:realIndex"))});for(var m=0;m2&&arguments[2]!==void 0?arguments[2]:null,v=arguments.length>3&&arguments[3]!==void 0?arguments[3]:null,m=this.w;m.config.chart.type!=="bubble"&&this.newPointSize(c,u);var x=u.getAttribute("cx"),w=u.getAttribute("cy");if(d!==null&&v!==null&&(x=d,w=v),this.tooltipPosition.moveXCrosshairs(x),!this.fixedTooltip){if(m.config.chart.type==="radar"){var k=this.ttCtx.getElGrid().getBoundingClientRect();x=this.ttCtx.e.clientX-k.left}this.tooltipPosition.moveTooltip(x,w,m.config.markers.hover.size)}}},{key:"enlargePoints",value:function(c){for(var u=this.w,d=this,v=this.ttCtx,m=c,x=u.globals.dom.baseEl.querySelectorAll(".apexcharts-series:not(.apexcharts-series-collapsed) .apexcharts-marker"),w=u.config.markers.hover.size,k=0;k=0){var v=this.ttCtx.tooltipUtil.getPathFromPoint(c[u],d);c[u].setAttribute("d",v)}else c[u].setAttribute("d","M0,0")}}}]),Q}(),je=function(){function Q(c){a(this,Q),this.w=c.w;var u=this.w;this.ttCtx=c,this.isVerticalGroupedRangeBar=!u.globals.isBarHorizontal&&u.config.chart.type==="rangeBar"&&u.config.plotOptions.bar.rangeBarGroupRows}return l(Q,[{key:"getAttr",value:function(c,u){return parseFloat(c.target.getAttribute(u))}},{key:"handleHeatTreeTooltip",value:function(c){var u=c.e,d=c.opt,v=c.x,m=c.y,x=c.type,w=this.ttCtx,k=this.w;if(u.target.classList.contains("apexcharts-".concat(x,"-rect"))){var L=this.getAttr(u,"i"),D=this.getAttr(u,"j"),P=this.getAttr(u,"cx"),V=this.getAttr(u,"cy"),N=this.getAttr(u,"width"),j=this.getAttr(u,"height");if(w.tooltipLabels.drawSeriesTexts({ttItems:d.ttItems,i:L,j:D,shared:!1,e:u}),k.globals.capturedSeriesIndex=L,k.globals.capturedDataPointIndex=D,v=P+w.tooltipRect.ttWidth/2+N,m=V+w.tooltipRect.ttHeight/2-j/2,w.tooltipPosition.moveXCrosshairs(P+N/2),v>k.globals.gridWidth/2&&(v=P-w.tooltipRect.ttWidth/2+N),w.w.config.tooltip.followCursor){var U=k.globals.dom.elWrap.getBoundingClientRect();v=k.globals.clientX-U.left-(v>k.globals.gridWidth/2?w.tooltipRect.ttWidth:0),m=k.globals.clientY-U.top-(m>k.globals.gridHeight/2?w.tooltipRect.ttHeight:0)}}return{x:v,y:m}}},{key:"handleMarkerTooltip",value:function(c){var u,d,v=c.e,m=c.opt,x=c.x,w=c.y,k=this.w,L=this.ttCtx;if(v.target.classList.contains("apexcharts-marker")){var D=parseInt(m.paths.getAttribute("cx"),10),P=parseInt(m.paths.getAttribute("cy"),10),V=parseFloat(m.paths.getAttribute("val"));if(d=parseInt(m.paths.getAttribute("rel"),10),u=parseInt(m.paths.parentNode.parentNode.parentNode.getAttribute("rel"),10)-1,L.intersect){var N=E.findAncestor(m.paths,"apexcharts-series");N&&(u=parseInt(N.getAttribute("data:realIndex"),10))}if(L.tooltipLabels.drawSeriesTexts({ttItems:m.ttItems,i:u,j:d,shared:!L.showOnIntersect&&k.config.tooltip.shared,e:v}),v.type==="mouseup"&&L.markerClick(v,u,d),k.globals.capturedSeriesIndex=u,k.globals.capturedDataPointIndex=d,x=D,w=P+k.globals.translateY-1.4*L.tooltipRect.ttHeight,L.w.config.tooltip.followCursor){var j=L.getElGrid().getBoundingClientRect();w=L.e.clientY+k.globals.translateY-j.top}V<0&&(w=P),L.marker.enlargeCurrentPoint(d,m.paths,x,w)}return{x,y:w}}},{key:"handleBarTooltip",value:function(c){var u,d,v=c.e,m=c.opt,x=this.w,w=this.ttCtx,k=w.getElTooltip(),L=0,D=0,P=0,V=this.getBarTooltipXY({e:v,opt:m});u=V.i,V.barHeight;var N=V.j;x.globals.capturedSeriesIndex=u,x.globals.capturedDataPointIndex=N,x.globals.isBarHorizontal&&w.tooltipUtil.hasBars()||!x.config.tooltip.shared?(D=V.x,P=V.y,d=Array.isArray(x.config.stroke.width)?x.config.stroke.width[u]:x.config.stroke.width,L=D):x.globals.comboCharts||x.config.tooltip.shared||(L/=2),isNaN(P)&&(P=x.globals.svgHeight-w.tooltipRect.ttHeight);var j=parseInt(m.paths.parentNode.getAttribute("data:realIndex"),10);if(x.globals.isMultipleYAxis?x.config.yaxis[j]&&x.config.yaxis[j].reversed:x.config.yaxis[0].reversed,D+w.tooltipRect.ttWidth>x.globals.gridWidth?D-=w.tooltipRect.ttWidth:D<0&&(D=0),w.w.config.tooltip.followCursor){var U=w.getElGrid().getBoundingClientRect();P=w.e.clientY-U.top}w.tooltip===null&&(w.tooltip=x.globals.dom.baseEl.querySelector(".apexcharts-tooltip")),x.config.tooltip.shared||(x.globals.comboBarCount>0?w.tooltipPosition.moveXCrosshairs(L+d/2):w.tooltipPosition.moveXCrosshairs(L)),!w.fixedTooltip&&(!x.config.tooltip.shared||x.globals.isBarHorizontal&&w.tooltipUtil.hasBars())&&(P=P+x.globals.translateY-w.tooltipRect.ttHeight/2,k.style.left=D+x.globals.translateX+"px",k.style.top=P+"px")}},{key:"getBarTooltipXY",value:function(c){var u=this,d=c.e,v=c.opt,m=this.w,x=null,w=this.ttCtx,k=0,L=0,D=0,P=0,V=0,N=d.target.classList;if(N.contains("apexcharts-bar-area")||N.contains("apexcharts-candlestick-area")||N.contains("apexcharts-boxPlot-area")||N.contains("apexcharts-rangebar-area")){var j=d.target,U=j.getBoundingClientRect(),q=v.elGrid.getBoundingClientRect(),J=U.height;V=U.height;var rt=U.width,A=parseInt(j.getAttribute("cx"),10),O=parseInt(j.getAttribute("cy"),10);P=parseFloat(j.getAttribute("barWidth"));var X=d.type==="touchmove"?d.touches[0].clientX:d.clientX;x=parseInt(j.getAttribute("j"),10),k=parseInt(j.parentNode.getAttribute("rel"),10)-1;var ot=j.getAttribute("data-range-y1"),nt=j.getAttribute("data-range-y2");m.globals.comboCharts&&(k=parseInt(j.parentNode.getAttribute("data:realIndex"),10));var ct=function(xt){return m.globals.isXNumeric?A-rt/2:u.isVerticalGroupedRangeBar?A+rt/2:A-w.dataPointsDividedWidth+rt/2},wt=function(){return O-w.dataPointsDividedHeight+J/2-w.tooltipRect.ttHeight/2};w.tooltipLabels.drawSeriesTexts({ttItems:v.ttItems,i:k,j:x,y1:ot?parseInt(ot,10):null,y2:nt?parseInt(nt,10):null,shared:!w.showOnIntersect&&m.config.tooltip.shared,e:d}),m.config.tooltip.followCursor?m.globals.isBarHorizontal?(L=X-q.left+15,D=wt()):(L=ct(),D=d.clientY-q.top-w.tooltipRect.ttHeight/2-15):m.globals.isBarHorizontal?((L=A)0&&d.setAttribute("width",u.xcrosshairsWidth)}},{key:"handleYCrosshair",value:function(){var c=this.w,u=this.ttCtx;u.ycrosshairs=c.globals.dom.baseEl.querySelector(".apexcharts-ycrosshairs"),u.ycrosshairsHidden=c.globals.dom.baseEl.querySelector(".apexcharts-ycrosshairs-hidden")}},{key:"drawYaxisTooltipText",value:function(c,u,d){var v=this.ttCtx,m=this.w,x=m.globals,w=x.seriesYAxisMap[c];if(v.yaxisTooltips[c]&&w.length>0){var k=x.yLabelFormatters[c],L=v.getElGrid().getBoundingClientRect(),D=w[0],P=0;d.yRatio.length>1&&(P=D);var V=(u-L.top)*d.yRatio[P],N=x.maxYArr[D]-x.minYArr[D],j=x.minYArr[D]+(N-V);m.config.yaxis[c].reversed&&(j=x.maxYArr[D]-(N-V)),v.tooltipPosition.moveYCrosshairs(u-L.top),v.yaxisTooltipText[c].innerHTML=k(j),v.tooltipPosition.moveYAxisTooltip(c)}}}]),Q}(),c1=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w;var u=this.w;this.tConfig=u.config.tooltip,this.tooltipUtil=new Rt(this),this.tooltipLabels=new Vt(this),this.tooltipPosition=new Qt(this),this.marker=new ve(this),this.intersect=new je(this),this.axesTooltip=new ke(this),this.showOnIntersect=this.tConfig.intersect,this.showTooltipTitle=this.tConfig.x.show,this.fixedTooltip=this.tConfig.fixed.enabled,this.xaxisTooltip=null,this.yaxisTTEls=null,this.isBarShared=!u.globals.isBarHorizontal&&this.tConfig.shared,this.lastHoverTime=Date.now()}return l(Q,[{key:"getElTooltip",value:function(c){return c||(c=this),c.w.globals.dom.baseEl?c.w.globals.dom.baseEl.querySelector(".apexcharts-tooltip"):null}},{key:"getElXCrosshairs",value:function(){return this.w.globals.dom.baseEl.querySelector(".apexcharts-xcrosshairs")}},{key:"getElGrid",value:function(){return this.w.globals.dom.baseEl.querySelector(".apexcharts-grid")}},{key:"drawTooltip",value:function(c){var u=this.w;this.xyRatios=c,this.isXAxisTooltipEnabled=u.config.xaxis.tooltip.enabled&&u.globals.axisCharts,this.yaxisTooltips=u.config.yaxis.map(function(x,w){return!!(x.show&&x.tooltip.enabled&&u.globals.axisCharts)}),this.allTooltipSeriesGroups=[],u.globals.axisCharts||(this.showTooltipTitle=!1);var d=document.createElement("div");if(d.classList.add("apexcharts-tooltip"),u.config.tooltip.cssClass&&d.classList.add(u.config.tooltip.cssClass),d.classList.add("apexcharts-theme-".concat(this.tConfig.theme)),u.globals.dom.elWrap.appendChild(d),u.globals.axisCharts){this.axesTooltip.drawXaxisTooltip(),this.axesTooltip.drawYaxisTooltip(),this.axesTooltip.setXCrosshairWidth(),this.axesTooltip.handleYCrosshair();var v=new $t(this.ctx);this.xAxisTicksPositions=v.getXAxisTicksPositions()}if(!u.globals.comboCharts&&!this.tConfig.intersect&&u.config.chart.type!=="rangeBar"||this.tConfig.shared||(this.showOnIntersect=!0),u.config.markers.size!==0&&u.globals.markers.largestSize!==0||this.marker.drawDynamicPoints(this),u.globals.collapsedSeries.length!==u.globals.series.length){this.dataPointsDividedHeight=u.globals.gridHeight/u.globals.dataPoints,this.dataPointsDividedWidth=u.globals.gridWidth/u.globals.dataPoints,this.showTooltipTitle&&(this.tooltipTitle=document.createElement("div"),this.tooltipTitle.classList.add("apexcharts-tooltip-title"),this.tooltipTitle.style.fontFamily=this.tConfig.style.fontFamily||u.config.chart.fontFamily,this.tooltipTitle.style.fontSize=this.tConfig.style.fontSize,d.appendChild(this.tooltipTitle));var m=u.globals.series.length;(u.globals.xyCharts||u.globals.comboCharts)&&this.tConfig.shared&&(m=this.showOnIntersect?1:u.globals.series.length),this.legendLabels=u.globals.dom.baseEl.querySelectorAll(".apexcharts-legend-text"),this.ttItems=this.createTTElements(m),this.addSVGEvents()}}},{key:"createTTElements",value:function(c){for(var u=this,d=this.w,v=[],m=this.getElTooltip(),x=function(k){var L=document.createElement("div");L.classList.add("apexcharts-tooltip-series-group","apexcharts-tooltip-series-group-".concat(k)),L.style.order=d.config.tooltip.inverseOrder?c-k:k+1;var D=document.createElement("span");D.classList.add("apexcharts-tooltip-marker"),D.style.backgroundColor=d.globals.colors[k],L.appendChild(D);var P=document.createElement("div");P.classList.add("apexcharts-tooltip-text"),P.style.fontFamily=u.tConfig.style.fontFamily||d.config.chart.fontFamily,P.style.fontSize=u.tConfig.style.fontSize,["y","goals","z"].forEach(function(V){var N=document.createElement("div");N.classList.add("apexcharts-tooltip-".concat(V,"-group"));var j=document.createElement("span");j.classList.add("apexcharts-tooltip-text-".concat(V,"-label")),N.appendChild(j);var U=document.createElement("span");U.classList.add("apexcharts-tooltip-text-".concat(V,"-value")),N.appendChild(U),P.appendChild(N)}),L.appendChild(P),m.appendChild(L),v.push(L)},w=0;w0&&this.addPathsEventListeners(j,P),this.tooltipUtil.hasBars()&&!this.tConfig.shared&&this.addDatapointEventsListeners(P)}}},{key:"drawFixedTooltipRect",value:function(){var c=this.w,u=this.getElTooltip(),d=u.getBoundingClientRect(),v=d.width+10,m=d.height+10,x=this.tConfig.fixed.offsetX,w=this.tConfig.fixed.offsetY,k=this.tConfig.fixed.position.toLowerCase();return k.indexOf("right")>-1&&(x=x+c.globals.svgWidth-v+10),k.indexOf("bottom")>-1&&(w=w+c.globals.svgHeight-m-10),u.style.left=x+"px",u.style.top=w+"px",{x,y:w,ttWidth:v,ttHeight:m}}},{key:"addDatapointEventsListeners",value:function(c){var u=this.w.globals.dom.baseEl.querySelectorAll(".apexcharts-series-markers .apexcharts-marker, .apexcharts-bar-area, .apexcharts-candlestick-area, .apexcharts-boxPlot-area, .apexcharts-rangebar-area");this.addPathsEventListeners(u,c)}},{key:"addPathsEventListeners",value:function(c,u){for(var d=this,v=function(x){var w={paths:c[x],tooltipEl:u.tooltipEl,tooltipY:u.tooltipY,tooltipX:u.tooltipX,elGrid:u.elGrid,hoverArea:u.hoverArea,ttItems:u.ttItems};["mousemove","mouseup","touchmove","mouseout","touchend"].map(function(k){return c[x].addEventListener(k,d.onSeriesHover.bind(d,w),{capture:!1,passive:!0})})},m=0;m=100?this.seriesHover(c,u):(clearTimeout(this.seriesHoverTimeout),this.seriesHoverTimeout=setTimeout(function(){d.seriesHover(c,u)},100-v))}},{key:"seriesHover",value:function(c,u){var d=this;this.lastHoverTime=Date.now();var v=[],m=this.w;m.config.chart.group&&(v=this.ctx.getGroupedCharts()),m.globals.axisCharts&&(m.globals.minX===-1/0&&m.globals.maxX===1/0||m.globals.dataPoints===0)||(v.length?v.forEach(function(x){var w=d.getElTooltip(x),k={paths:c.paths,tooltipEl:w,tooltipY:c.tooltipY,tooltipX:c.tooltipX,elGrid:c.elGrid,hoverArea:c.hoverArea,ttItems:x.w.globals.tooltip.ttItems};x.w.globals.minX===d.w.globals.minX&&x.w.globals.maxX===d.w.globals.maxX&&x.w.globals.tooltip.seriesHoverByContext({chartCtx:x,ttCtx:x.w.globals.tooltip,opt:k,e:u})}):this.seriesHoverByContext({chartCtx:this.ctx,ttCtx:this.w.globals.tooltip,opt:c,e:u}))}},{key:"seriesHoverByContext",value:function(c){var u=c.chartCtx,d=c.ttCtx,v=c.opt,m=c.e,x=u.w,w=this.getElTooltip();w&&(d.tooltipRect={x:0,y:0,ttWidth:w.getBoundingClientRect().width,ttHeight:w.getBoundingClientRect().height},d.e=m,d.tooltipUtil.hasBars()&&!x.globals.comboCharts&&!d.isBarShared&&this.tConfig.onDatasetHover.highlightDataSeries&&new Xt(u).toggleSeriesOnHover(m,m.target.parentNode),d.fixedTooltip&&d.drawFixedTooltipRect(),x.globals.axisCharts?d.axisChartsTooltips({e:m,opt:v,tooltipRect:d.tooltipRect}):d.nonAxisChartsTooltips({e:m,opt:v,tooltipRect:d.tooltipRect}))}},{key:"axisChartsTooltips",value:function(c){var u,d,v=c.e,m=c.opt,x=this.w,w=m.elGrid.getBoundingClientRect(),k=v.type==="touchmove"?v.touches[0].clientX:v.clientX,L=v.type==="touchmove"?v.touches[0].clientY:v.clientY;if(this.clientY=L,this.clientX=k,x.globals.capturedSeriesIndex=-1,x.globals.capturedDataPointIndex=-1,Lw.top+w.height)this.handleMouseOut(m);else{if(Array.isArray(this.tConfig.enabledOnSeries)&&!x.config.tooltip.shared){var D=parseInt(m.paths.getAttribute("index"),10);if(this.tConfig.enabledOnSeries.indexOf(D)<0)return void this.handleMouseOut(m)}var P=this.getElTooltip(),V=this.getElXCrosshairs(),N=x.globals.xyCharts||x.config.chart.type==="bar"&&!x.globals.isBarHorizontal&&this.tooltipUtil.hasBars()&&this.tConfig.shared||x.globals.comboCharts&&this.tooltipUtil.hasBars();if(v.type==="mousemove"||v.type==="touchmove"||v.type==="mouseup"){if(x.globals.collapsedSeries.length+x.globals.ancillaryCollapsedSeries.length===x.globals.series.length)return;V!==null&&V.classList.add("apexcharts-active");var j=this.yaxisTooltips.filter(function(J){return J===!0});if(this.ycrosshairs!==null&&j.length&&this.ycrosshairs.classList.add("apexcharts-active"),N&&!this.showOnIntersect)this.handleStickyTooltip(v,k,L,m);else if(x.config.chart.type==="heatmap"||x.config.chart.type==="treemap"){var U=this.intersect.handleHeatTreeTooltip({e:v,opt:m,x:u,y:d,type:x.config.chart.type});u=U.x,d=U.y,P.style.left=u+"px",P.style.top=d+"px"}else this.tooltipUtil.hasBars()&&this.intersect.handleBarTooltip({e:v,opt:m}),this.tooltipUtil.hasMarkers()&&this.intersect.handleMarkerTooltip({e:v,opt:m,x:u,y:d});if(this.yaxisTooltips.length)for(var q=0;qL.width)this.handleMouseOut(v);else if(k!==null)this.handleStickyCapturedSeries(c,k,v,w);else if(this.tooltipUtil.isXoverlap(w)||m.globals.isBarHorizontal){var D=m.globals.series.findIndex(function(P,V){return!m.globals.collapsedSeriesIndices.includes(V)});this.create(c,this,D,w,v.ttItems)}}},{key:"handleStickyCapturedSeries",value:function(c,u,d,v){var m=this.w;if(!this.tConfig.shared&&m.globals.series[u][v]===null)return void this.handleMouseOut(d);if(m.globals.series[u][v]!==void 0)this.tConfig.shared&&this.tooltipUtil.isXoverlap(v)&&this.tooltipUtil.isInitialSeriesSameLen()?this.create(c,this,u,v,d.ttItems):this.create(c,this,u,v,d.ttItems,!1);else if(this.tooltipUtil.isXoverlap(v)){var x=m.globals.series.findIndex(function(w,k){return!m.globals.collapsedSeriesIndices.includes(k)});this.create(c,this,x,v,d.ttItems)}}},{key:"deactivateHoverFilter",value:function(){for(var c=this.w,u=new $(this.ctx),d=c.globals.dom.Paper.select(".apexcharts-bar-area"),v=0;v5&&arguments[5]!==void 0?arguments[5]:null,nt=this.w,ct=u;c.type==="mouseup"&&this.markerClick(c,d,v),ot===null&&(ot=this.tConfig.shared);var wt=this.tooltipUtil.hasMarkers(d),xt=this.tooltipUtil.getElBars();if(nt.config.legend.tooltipHoverFormatter){var jt=nt.config.legend.tooltipHoverFormatter,ee=Array.from(this.legendLabels);ee.forEach(function(xr){var Lr=xr.getAttribute("data:default-text");xr.innerHTML=decodeURIComponent(Lr)});for(var Nt=0;Nt0?ct.marker.enlargePoints(v):ct.tooltipPosition.moveDynamicPointsOnHover(v);else if(this.tooltipUtil.hasBars()&&(this.barSeriesHeight=this.tooltipUtil.getBarsHeight(xt),this.barSeriesHeight>0)){var l1=new $(this.ctx),i1=nt.globals.dom.Paper.select(".apexcharts-bar-area[j='".concat(v,"']"));this.deactivateHoverFilter(),this.tooltipPosition.moveStickyTooltipOverBars(v,d);for(var y1=0;y10&&u.config.plotOptions.bar.hideZeroBarsWhenGrouped&&(N-=D*nt)),ot&&(N=N+V.height/2-rt/2-2);var wt=u.globals.series[d][v]<0,xt=k;switch(this.barCtx.isReversed&&(xt=k+(wt?P:-P)),q.position){case"center":j=ot?wt?xt-P/2+O:xt+P/2-O:wt?xt-P/2+V.height/2+O:xt+P/2+V.height/2-O;break;case"bottom":j=ot?wt?xt-P+O:xt+P-O:wt?xt-P+V.height+rt+O:xt+P-V.height/2+rt-O;break;case"top":j=ot?wt?xt+O:xt-O:wt?xt-V.height/2-O:xt+V.height+O}if(this.barCtx.lastActiveBarSerieIndex===m&&J.enabled){var jt=new $(this.barCtx.ctx).getTextRects(this.getStackedTotalDataLabel({realIndex:m,j:v}),U.fontSize);x=wt?xt-jt.height/2-O-J.offsetY+18:xt+jt.height+O+J.offsetY-18;var ee=ct;w=X+(u.globals.isXNumeric?-D*u.globals.barGroups.length/2:u.globals.barGroups.length*D/2-(u.globals.barGroups.length-1)*D-ee)+J.offsetX}return u.config.chart.stacked||(j<0?j=0+rt:j+V.height/3>u.globals.gridHeight&&(j=u.globals.gridHeight-rt)),{bcx:L,bcy:k,dataLabelsX:N,dataLabelsY:j,totalDataLabelsX:w,totalDataLabelsY:x,totalDataLabelsAnchor:"middle"}}},{key:"calculateBarsDataLabelsPosition",value:function(c){var u=this.w,d=c.x,v=c.i,m=c.j,x=c.realIndex;c.columnGroupIndex;var w=c.bcy,k=c.barHeight,L=c.barWidth,D=c.textRects,P=c.dataLabelsX,V=c.strokeWidth,N=c.dataLabelsConfig,j=c.barDataLabelsConfig,U=c.barTotalDataLabelsConfig,q=c.offX,J=c.offY,rt=u.globals.gridHeight/u.globals.dataPoints;L=Math.abs(L);var A,O,X=w-(this.barCtx.isRangeBar?0:rt)+k/2+D.height/2+J-3,ot="start",nt=u.globals.series[v][m]<0,ct=d;switch(this.barCtx.isReversed&&(ct=d+(nt?-L:L),ot=nt?"start":"end"),j.position){case"center":P=nt?ct+L/2-q:Math.max(D.width/2,ct-L/2)+q;break;case"bottom":P=nt?ct+L-V-Math.round(D.width/2)-q:ct-L+V+Math.round(D.width/2)+q;break;case"top":P=nt?ct-V+Math.round(D.width/2)-q:ct-V-Math.round(D.width/2)+q}if(this.barCtx.lastActiveBarSerieIndex===x&&U.enabled){var wt=new $(this.barCtx.ctx).getTextRects(this.getStackedTotalDataLabel({realIndex:x,j:m}),N.fontSize);nt?(A=ct-V-q-U.offsetX,ot="end"):A=ct+q+U.offsetX+(this.barCtx.isReversed?-(L+V):V),O=X-D.height/2+wt.height/2+U.offsetY+V}return u.config.chart.stacked||(P<0?P=P+D.width+V:P+D.width/2>u.globals.gridWidth&&(P=u.globals.gridWidth-D.width-V)),{bcx:d,bcy:w,dataLabelsX:P,dataLabelsY:X,totalDataLabelsX:A,totalDataLabelsY:O,totalDataLabelsAnchor:ot}}},{key:"drawCalculatedDataLabels",value:function(c){var u=c.x,d=c.y,v=c.val,m=c.i,x=c.j,w=c.textRects,k=c.barHeight,L=c.barWidth,D=c.dataLabelsConfig,P=this.w,V="rotate(0)";P.config.plotOptions.bar.dataLabels.orientation==="vertical"&&(V="rotate(-90, ".concat(u,", ").concat(d,")"));var N=new Ut(this.barCtx.ctx),j=new $(this.barCtx.ctx),U=D.formatter,q=null,J=P.globals.collapsedSeriesIndices.indexOf(m)>-1;if(D.enabled&&!J){q=j.group({class:"apexcharts-data-labels",transform:V});var rt="";v!==void 0&&(rt=U(v,i(i({},P),{},{seriesIndex:m,dataPointIndex:x,w:P}))),!v&&P.config.plotOptions.bar.hideZeroBarsWhenGrouped&&(rt="");var A=P.globals.series[m][x]<0,O=P.config.plotOptions.bar.dataLabels.position;P.config.plotOptions.bar.dataLabels.orientation==="vertical"&&(O==="top"&&(D.textAnchor=A?"end":"start"),O==="center"&&(D.textAnchor="middle"),O==="bottom"&&(D.textAnchor=A?"end":"start")),this.barCtx.isRangeBar&&this.barCtx.barOptions.dataLabels.hideOverflowingLabels&&LMath.abs(L)&&(rt=""):w.height/1.6>Math.abs(k)&&(rt=""));var X=i({},D);this.barCtx.isHorizontal&&v<0&&(D.textAnchor==="start"?X.textAnchor="end":D.textAnchor==="end"&&(X.textAnchor="start")),N.plotDataLabelsText({x:u,y:d,text:rt,i:m,j:x,parent:q,dataLabelsConfig:X,alwaysDrawDataLabel:!0,offsetCorrection:!0})}return q}},{key:"drawTotalDataLabels",value:function(c){var u=c.x,d=c.y,v=c.val;c.barWidth,c.barHeight;var m=c.realIndex,x=c.textAnchor,w=c.barTotalDataLabelsConfig;this.w;var k,L=new $(this.barCtx.ctx);return w.enabled&&u!==void 0&&d!==void 0&&this.barCtx.lastActiveBarSerieIndex===m&&(k=L.drawText({x:u,y:d,foreColor:w.style.color,text:v,textAnchor:x,fontFamily:w.style.fontFamily,fontSize:w.style.fontSize,fontWeight:w.style.fontWeight})),k}}]),Q}(),Tt=function(){function Q(c){a(this,Q),this.w=c.w,this.barCtx=c}return l(Q,[{key:"initVariables",value:function(c){var u=this.w;this.barCtx.series=c,this.barCtx.totalItems=0,this.barCtx.seriesLen=0,this.barCtx.visibleI=-1,this.barCtx.visibleItems=1;for(var d=0;d0&&(this.barCtx.seriesLen=this.barCtx.seriesLen+1,this.barCtx.totalItems+=c[d].length),u.globals.isXNumeric)for(var v=0;vu.globals.minX&&u.globals.seriesX[d][v]0&&(v=L.globals.minXDiff/V),(x=v/P*parseInt(this.barCtx.barOptions.columnWidth,10)/100)<1&&(x=1)}String(this.barCtx.barOptions.columnWidth).indexOf("%")===-1&&(x=parseInt(this.barCtx.barOptions.columnWidth,10)),w=L.globals.gridHeight-this.barCtx.baseLineY[this.barCtx.translationsIndex]-(this.barCtx.isReversed?L.globals.gridHeight:0)+(this.barCtx.isReversed?2*this.barCtx.baseLineY[this.barCtx.translationsIndex]:0),c=L.globals.padHorizontal+(v-x*this.barCtx.seriesLen)/2}return L.globals.barHeight=m,L.globals.barWidth=x,{x:c,y:u,yDivision:d,xDivision:v,barHeight:m,barWidth:x,zeroH:w,zeroW:k}}},{key:"initializeStackedPrevVars",value:function(c){c.w.globals.seriesGroups.forEach(function(u){c[u]||(c[u]={}),c[u].prevY=[],c[u].prevX=[],c[u].prevYF=[],c[u].prevXF=[],c[u].prevYVal=[],c[u].prevXVal=[]})}},{key:"initializeStackedXYVars",value:function(c){c.w.globals.seriesGroups.forEach(function(u){c[u]||(c[u]={}),c[u].xArrj=[],c[u].xArrjF=[],c[u].xArrjVal=[],c[u].yArrj=[],c[u].yArrjF=[],c[u].yArrjVal=[]})}},{key:"getPathFillColor",value:function(c,u,d,v){var m,x,w,k,L,D=this.w,P=new At(this.barCtx.ctx),V=null,N=this.barCtx.barOptions.distributed?d:u;return this.barCtx.barOptions.colors.ranges.length>0&&this.barCtx.barOptions.colors.ranges.map(function(j){c[u][d]>=j.from&&c[u][d]<=j.to&&(V=j.color)}),(m=D.config.series[u].data[d])!==null&&m!==void 0&&m.fillColor&&(V=D.config.series[u].data[d].fillColor),P.fillPath({seriesNumber:this.barCtx.barOptions.distributed?N:v,dataPointIndex:d,color:V,value:c[u][d],fillConfig:(x=D.config.series[u].data[d])===null||x===void 0?void 0:x.fill,fillType:(w=D.config.series[u].data[d])!==null&&w!==void 0&&(k=w.fill)!==null&&k!==void 0&&k.type?(L=D.config.series[u].data[d])===null||L===void 0?void 0:L.fill.type:Array.isArray(D.config.fill.type)?D.config.fill.type[v]:D.config.fill.type})}},{key:"getStrokeWidth",value:function(c,u,d){var v=0,m=this.w;return this.barCtx.series[c][u]===void 0||this.barCtx.series[c][u]===null?this.barCtx.isNullValue=!0:this.barCtx.isNullValue=!1,m.config.stroke.show&&(this.barCtx.isNullValue||(v=Array.isArray(this.barCtx.strokeWidth)?this.barCtx.strokeWidth[d]:this.barCtx.strokeWidth)),v}},{key:"shouldApplyRadius",value:function(c){var u=this.w,d=!1;return u.config.plotOptions.bar.borderRadius>0&&(u.config.chart.stacked&&u.config.plotOptions.bar.borderRadiusWhenStacked==="last"?this.barCtx.lastActiveBarSerieIndex===c&&(d=!0):d=!0),d}},{key:"barBackground",value:function(c){var u=c.j,d=c.i,v=c.x1,m=c.x2,x=c.y1,w=c.y2,k=c.elSeries,L=this.w,D=new $(this.barCtx.ctx),P=new Xt(this.barCtx.ctx).getActiveConfigSeriesIndex();if(this.barCtx.barOptions.colors.backgroundBarColors.length>0&&P===d){u>=this.barCtx.barOptions.colors.backgroundBarColors.length&&(u%=this.barCtx.barOptions.colors.backgroundBarColors.length);var V=this.barCtx.barOptions.colors.backgroundBarColors[u],N=D.drawRect(v!==void 0?v:0,x!==void 0?x:0,m!==void 0?m:L.globals.gridWidth,w!==void 0?w:L.globals.gridHeight,this.barCtx.barOptions.colors.backgroundBarRadius,V,this.barCtx.barOptions.colors.backgroundBarOpacity);k.add(N),N.node.classList.add("apexcharts-backgroundBar")}}},{key:"getColumnPaths",value:function(c){var u,d=c.barWidth,v=c.barXPosition,m=c.y1,x=c.y2,w=c.strokeWidth,k=c.seriesGroup,L=c.realIndex,D=c.i,P=c.j,V=c.w,N=new $(this.barCtx.ctx);(w=Array.isArray(w)?w[L]:w)||(w=0);var j=d,U=v;(u=V.config.series[L].data[P])!==null&&u!==void 0&&u.columnWidthOffset&&(U=v-V.config.series[L].data[P].columnWidthOffset/2,j=d+V.config.series[L].data[P].columnWidthOffset);var q=w/2,J=U+q,rt=U+j-q;m+=.001-q,x+=.001+q;var A=N.move(J,m),O=N.move(J,m),X=N.line(rt,m);if(V.globals.previousPaths.length>0&&(O=this.barCtx.getPreviousPath(L,P,!1)),A=A+N.line(J,x)+N.line(rt,x)+N.line(rt,m)+(V.config.plotOptions.bar.borderRadiusApplication==="around"?" Z":" z"),O=O+N.line(J,m)+X+X+X+X+X+N.line(J,m)+(V.config.plotOptions.bar.borderRadiusApplication==="around"?" Z":" z"),this.shouldApplyRadius(L)&&(A=N.roundPathCorners(A,V.config.plotOptions.bar.borderRadius)),V.config.chart.stacked){var ot=this.barCtx;(ot=this.barCtx[k]).yArrj.push(x-q),ot.yArrjF.push(Math.abs(m-x+w)),ot.yArrjVal.push(this.barCtx.series[D][P])}return{pathTo:A,pathFrom:O}}},{key:"getBarpaths",value:function(c){var u,d=c.barYPosition,v=c.barHeight,m=c.x1,x=c.x2,w=c.strokeWidth,k=c.seriesGroup,L=c.realIndex,D=c.i,P=c.j,V=c.w,N=new $(this.barCtx.ctx);(w=Array.isArray(w)?w[L]:w)||(w=0);var j=d,U=v;(u=V.config.series[L].data[P])!==null&&u!==void 0&&u.barHeightOffset&&(j=d-V.config.series[L].data[P].barHeightOffset/2,U=v+V.config.series[L].data[P].barHeightOffset);var q=w/2,J=j+q,rt=j+U-q;m+=.001-q,x+=.001+q;var A=N.move(m,J),O=N.move(m,J);V.globals.previousPaths.length>0&&(O=this.barCtx.getPreviousPath(L,P,!1));var X=N.line(m,rt);if(A=A+N.line(x,J)+N.line(x,rt)+X+(V.config.plotOptions.bar.borderRadiusApplication==="around"?" Z":" z"),O=O+N.line(m,J)+X+X+X+X+X+N.line(m,J)+(V.config.plotOptions.bar.borderRadiusApplication==="around"?" Z":" z"),this.shouldApplyRadius(L)&&(A=N.roundPathCorners(A,V.config.plotOptions.bar.borderRadius)),V.config.chart.stacked){var ot=this.barCtx;(ot=this.barCtx[k]).xArrj.push(x+q),ot.xArrjF.push(Math.abs(m-x)),ot.xArrjVal.push(this.barCtx.series[D][P])}return{pathTo:A,pathFrom:O}}},{key:"checkZeroSeries",value:function(c){for(var u=c.series,d=this.w,v=0;v2&&arguments[2]!==void 0)||arguments[2]?u:null;return c!=null&&(d=u+c/this.barCtx.invertedYRatio-2*(this.barCtx.isReversed?c/this.barCtx.invertedYRatio:0)),d}},{key:"getYForValue",value:function(c,u,d){var v=!(arguments.length>3&&arguments[3]!==void 0)||arguments[3]?u:null;return c!=null&&(v=u-c/this.barCtx.yRatio[d]+2*(this.barCtx.isReversed?c/this.barCtx.yRatio[d]:0)),v}},{key:"getGoalValues",value:function(c,u,d,v,m,x){var w=this,k=this.w,L=[],D=function(N,j){var U;L.push((h(U={},c,c==="x"?w.getXForValue(N,u,!1):w.getYForValue(N,d,x,!1)),h(U,"attrs",j),U))};if(k.globals.seriesGoals[v]&&k.globals.seriesGoals[v][m]&&Array.isArray(k.globals.seriesGoals[v][m])&&k.globals.seriesGoals[v][m].forEach(function(N){D(N.value,N)}),this.barCtx.barOptions.isDumbbell&&k.globals.seriesRange.length){var P=this.barCtx.barOptions.dumbbellColors?this.barCtx.barOptions.dumbbellColors:k.globals.colors,V={strokeHeight:c==="x"?0:k.globals.markers.size[v],strokeWidth:c==="x"?k.globals.markers.size[v]:0,strokeDashArray:0,strokeLineCap:"round",strokeColor:Array.isArray(P[v])?P[v][0]:P[v]};D(k.globals.seriesRangeStart[v][m],V),D(k.globals.seriesRangeEnd[v][m],i(i({},V),{},{strokeColor:Array.isArray(P[v])?P[v][1]:P[v]}))}return L}},{key:"drawGoalLine",value:function(c){var u=c.barXPosition,d=c.barYPosition,v=c.goalX,m=c.goalY,x=c.barWidth,w=c.barHeight,k=new $(this.barCtx.ctx),L=k.group({className:"apexcharts-bar-goals-groups"});L.node.classList.add("apexcharts-element-hidden"),this.barCtx.w.globals.delayedElements.push({el:L.node}),L.attr("clip-path","url(#gridRectMarkerMask".concat(this.barCtx.w.globals.cuid,")"));var D=null;return this.barCtx.isHorizontal?Array.isArray(v)&&v.forEach(function(P){if(P.x>=-1&&P.x<=k.w.globals.gridWidth+1){var V=P.attrs.strokeHeight!==void 0?P.attrs.strokeHeight:w/2,N=d+V+w/2;D=k.drawLine(P.x,N-2*V,P.x,N,P.attrs.strokeColor?P.attrs.strokeColor:void 0,P.attrs.strokeDashArray,P.attrs.strokeWidth?P.attrs.strokeWidth:2,P.attrs.strokeLineCap),L.add(D)}}):Array.isArray(m)&&m.forEach(function(P){if(P.y>=-1&&P.y<=k.w.globals.gridHeight+1){var V=P.attrs.strokeWidth!==void 0?P.attrs.strokeWidth:x/2,N=u+V+x/2;D=k.drawLine(N-2*V,P.y,N,P.y,P.attrs.strokeColor?P.attrs.strokeColor:void 0,P.attrs.strokeDashArray,P.attrs.strokeHeight?P.attrs.strokeHeight:2,P.attrs.strokeLineCap),L.add(D)}}),L}},{key:"drawBarShadow",value:function(c){var u=c.prevPaths,d=c.currPaths,v=c.color,m=this.w,x=u.x,w=u.x1,k=u.barYPosition,L=d.x,D=d.x1,P=d.barYPosition,V=k+d.barHeight,N=new $(this.barCtx.ctx),j=new E,U=N.move(w,V)+N.line(x,V)+N.line(L,P)+N.line(D,P)+N.line(w,V)+(m.config.plotOptions.bar.borderRadiusApplication==="around"?" Z":" z");return N.drawPath({d:U,fill:j.shadeColor(.5,E.rgb2hex(v)),stroke:"none",strokeWidth:0,fillOpacity:1,classes:"apexcharts-bar-shadows"})}},{key:"getZeroValueEncounters",value:function(c){var u,d=c.i,v=c.j,m=this.w,x=0,w=0;return(m.config.plotOptions.bar.horizontal?m.globals.series.map(function(k,L){return L}):((u=m.globals.columnSeries)===null||u===void 0?void 0:u.i.map(function(k){return k}))||[]).forEach(function(k){var L=m.globals.seriesPercent[k][v];L&&x++,k-1}),v=this.barCtx.columnGroupIndices,m=v.indexOf(d);return m<0&&(v.push(d),m=v.length-1),{groupIndex:d,columnGroupIndex:m}}}]),Q}(),te=function(){function Q(c,u){a(this,Q),this.ctx=c,this.w=c.w;var d=this.w;this.barOptions=d.config.plotOptions.bar,this.isHorizontal=this.barOptions.horizontal,this.strokeWidth=d.config.stroke.width,this.isNullValue=!1,this.isRangeBar=d.globals.seriesRange.length&&this.isHorizontal,this.isVerticalGroupedRangeBar=!d.globals.isBarHorizontal&&d.globals.seriesRange.length&&d.config.plotOptions.bar.rangeBarGroupRows,this.isFunnel=this.barOptions.isFunnel,this.xyRatios=u,this.xyRatios!==null&&(this.xRatio=u.xRatio,this.yRatio=u.yRatio,this.invertedXRatio=u.invertedXRatio,this.invertedYRatio=u.invertedYRatio,this.baseLineY=u.baseLineY,this.baseLineInvertedY=u.baseLineInvertedY),this.yaxisIndex=0,this.translationsIndex=0,this.seriesLen=0,this.pathArr=[];var v=new Xt(this.ctx);this.lastActiveBarSerieIndex=v.getActiveConfigSeriesIndex("desc",["bar","column"]),this.columnGroupIndices=[];var m=v.getBarSeriesIndices(),x=new G(this.ctx);this.stackedSeriesTotals=x.getStackedSeriesTotals(this.w.config.series.map(function(w,k){return m.indexOf(k)===-1?k:-1}).filter(function(w){return w!==-1})),this.barHelpers=new Tt(this)}return l(Q,[{key:"draw",value:function(c,u){var d=this.w,v=new $(this.ctx),m=new G(this.ctx,d);c=m.getLogSeries(c),this.series=c,this.yRatio=m.getLogYRatios(this.yRatio),this.barHelpers.initVariables(c);var x=v.group({class:"apexcharts-bar-series apexcharts-plot-series"});d.config.dataLabels.enabled&&this.totalItems>this.barOptions.dataLabels.maxItems&&console.warn("WARNING: DataLabels are enabled but there are too many to display. This may cause performance issue when rendering - ApexCharts");for(var w=0,k=0;w0&&(this.visibleI=this.visibleI+1);var O=0,X=0;this.yRatio.length>1&&(this.yaxisIndex=d.globals.seriesYAxisReverseMap[J],this.translationsIndex=J);var ot=this.translationsIndex;this.isReversed=d.config.yaxis[this.yaxisIndex]&&d.config.yaxis[this.yaxisIndex].reversed;var nt=this.barHelpers.initialPositions();j=nt.y,O=nt.barHeight,D=nt.yDivision,V=nt.zeroW,N=nt.x,X=nt.barWidth,L=nt.xDivision,P=nt.zeroH,this.horizontal||q.push(N+X/2);var ct=v.group({class:"apexcharts-datalabels","data:realIndex":J});d.globals.delayedElements.push({el:ct.node}),ct.node.classList.add("apexcharts-element-hidden");var wt=v.group({class:"apexcharts-bar-goals-markers"}),xt=v.group({class:"apexcharts-bar-shadows"});d.globals.delayedElements.push({el:xt.node}),xt.node.classList.add("apexcharts-element-hidden");for(var jt=0;jt0){var Te=this.barHelpers.drawBarShadow({color:typeof ze=="string"&&(ze==null?void 0:ze.indexOf("url"))===-1?ze:E.hexToRgba(d.globals.colors[w]),prevPaths:this.pathArr[this.pathArr.length-1],currPaths:Nt});Te&&xt.add(Te)}this.pathArr.push(Nt);var Ge=this.barHelpers.drawGoalLine({barXPosition:Nt.barXPosition,barYPosition:Nt.barYPosition,goalX:Nt.goalX,goalY:Nt.goalY,barHeight:O,barWidth:X});Ge&&wt.add(Ge),j=Nt.y,N=Nt.x,jt>0&&q.push(N+X/2),U.push(j),this.renderSeries({realIndex:J,pathFill:ze,j:jt,i:w,columnGroupIndex:rt,pathFrom:Nt.pathFrom,pathTo:Nt.pathTo,strokeWidth:ee,elSeries:A,x:N,y:j,series:c,barHeight:Math.abs(Nt.barHeight?Nt.barHeight:O),barWidth:Math.abs(Nt.barWidth?Nt.barWidth:X),elDataLabelsWrap:ct,elGoalsMarkers:wt,elBarShadows:xt,visibleSeries:this.visibleI,type:"bar"})}d.globals.seriesXvalues[J]=q,d.globals.seriesYvalues[J]=U,x.add(A)}return x}},{key:"renderSeries",value:function(c){var u=c.realIndex,d=c.pathFill,v=c.lineFill,m=c.j,x=c.i,w=c.columnGroupIndex,k=c.pathFrom,L=c.pathTo,D=c.strokeWidth,P=c.elSeries,V=c.x,N=c.y,j=c.y1,U=c.y2,q=c.series,J=c.barHeight,rt=c.barWidth,A=c.barXPosition,O=c.barYPosition,X=c.elDataLabelsWrap,ot=c.elGoalsMarkers,nt=c.elBarShadows,ct=c.visibleSeries,wt=c.type,xt=this.w,jt=new $(this.ctx);if(!v){var ee=typeof xt.globals.stroke.colors[u]=="function"?function(Ge){var Ye,l1=xt.config.stroke.colors;return Array.isArray(l1)&&l1.length>0&&((Ye=l1[Ge])||(Ye=""),typeof Ye=="function")?Ye({value:xt.globals.series[Ge][m],dataPointIndex:m,w:xt}):Ye}(u):xt.globals.stroke.colors[u];v=this.barOptions.distributed?xt.globals.stroke.colors[m]:ee}xt.config.series[x].data[m]&&xt.config.series[x].data[m].strokeColor&&(v=xt.config.series[x].data[m].strokeColor),this.isNullValue&&(d="none");var Nt=m/xt.config.chart.animations.animateGradually.delay*(xt.config.chart.animations.speed/xt.globals.dataPoints)/2.4,Zt=jt.renderPaths({i:x,j:m,realIndex:u,pathFrom:k,pathTo:L,stroke:v,strokeWidth:D,strokeLineCap:xt.config.stroke.lineCap,fill:d,animationDelay:Nt,initialSpeed:xt.config.chart.animations.speed,dataChangeSpeed:xt.config.chart.animations.dynamicAnimation.speed,className:"apexcharts-".concat(wt,"-area")});Zt.attr("clip-path","url(#gridRectMask".concat(xt.globals.cuid,")"));var ze=xt.config.forecastDataPoints;ze.count>0&&m>=xt.globals.dataPoints-ze.count&&(Zt.node.setAttribute("stroke-dasharray",ze.dashArray),Zt.node.setAttribute("stroke-width",ze.strokeWidth),Zt.node.setAttribute("fill-opacity",ze.fillOpacity)),j!==void 0&&U!==void 0&&(Zt.attr("data-range-y1",j),Zt.attr("data-range-y2",U)),new W(this.ctx).setSelectionFilter(Zt,u,m),P.add(Zt);var Te=new Oe(this).handleBarDataLabels({x:V,y:N,y1:j,y2:U,i:x,j:m,series:q,realIndex:u,columnGroupIndex:w,barHeight:J,barWidth:rt,barXPosition:A,barYPosition:O,renderedPath:Zt,visibleSeries:ct});return Te.dataLabels!==null&&X.add(Te.dataLabels),Te.totalDataLabels&&X.add(Te.totalDataLabels),P.add(X),ot&&P.add(ot),nt&&P.add(nt),P}},{key:"drawBarPaths",value:function(c){var u,d=c.indexes,v=c.barHeight,m=c.strokeWidth,x=c.zeroW,w=c.x,k=c.y,L=c.yDivision,D=c.elSeries,P=this.w,V=d.i,N=d.j;if(P.globals.isXNumeric)u=(k=(P.globals.seriesX[V][N]-P.globals.minX)/this.invertedXRatio-v)+v*this.visibleI;else if(P.config.plotOptions.bar.hideZeroBarsWhenGrouped){var j=0,U=0;P.globals.seriesPercent.forEach(function(J,rt){J[N]&&j++,rt0&&(v=this.seriesLen*v/j),u=k+v*this.visibleI,u-=v*U}else u=k+v*this.visibleI;this.isFunnel&&(x-=(this.barHelpers.getXForValue(this.series[V][N],x)-x)/2),w=this.barHelpers.getXForValue(this.series[V][N],x);var q=this.barHelpers.getBarpaths({barYPosition:u,barHeight:v,x1:x,x2:w,strokeWidth:m,series:this.series,realIndex:d.realIndex,i:V,j:N,w:P});return P.globals.isXNumeric||(k+=L),this.barHelpers.barBackground({j:N,i:V,y1:u-v*this.visibleI,y2:v*this.seriesLen,elSeries:D}),{pathTo:q.pathTo,pathFrom:q.pathFrom,x1:x,x:w,y:k,goalX:this.barHelpers.getGoalValues("x",x,null,V,N),barYPosition:u,barHeight:v}}},{key:"drawColumnPaths",value:function(c){var u,d=c.indexes,v=c.x,m=c.y,x=c.xDivision,w=c.barWidth,k=c.zeroH,L=c.strokeWidth,D=c.elSeries,P=this.w,V=d.realIndex,N=d.translationsIndex,j=d.i,U=d.j,q=d.bc;if(P.globals.isXNumeric){var J=this.getBarXForNumericXAxis({x:v,j:U,realIndex:V,barWidth:w});v=J.x,u=J.barXPosition}else if(P.config.plotOptions.bar.hideZeroBarsWhenGrouped){var rt=this.barHelpers.getZeroValueEncounters({i:j,j:U}),A=rt.nonZeroColumns,O=rt.zeroEncounters;A>0&&(w=this.seriesLen*w/A),u=v+w*this.visibleI,u-=w*O}else u=v+w*this.visibleI;m=this.barHelpers.getYForValue(this.series[j][U],k,N);var X=this.barHelpers.getColumnPaths({barXPosition:u,barWidth:w,y1:k,y2:m,strokeWidth:L,series:this.series,realIndex:V,i:j,j:U,w:P});return P.globals.isXNumeric||(v+=x),this.barHelpers.barBackground({bc:q,j:U,i:j,x1:u-L/2-w*this.visibleI,x2:w*this.seriesLen+L/2,elSeries:D}),{pathTo:X.pathTo,pathFrom:X.pathFrom,x:v,y:m,goalY:this.barHelpers.getGoalValues("y",null,k,j,U,N),barXPosition:u,barWidth:w}}},{key:"getBarXForNumericXAxis",value:function(c){var u=c.x,d=c.barWidth,v=c.realIndex,m=c.j,x=this.w,w=v;return x.globals.seriesX[v].length||(w=x.globals.maxValsInArrayIndex),x.globals.seriesX[w][m]&&(u=(x.globals.seriesX[w][m]-x.globals.minX)/this.xRatio-d*this.seriesLen/2),{barXPosition:u+d*this.visibleI,x:u}}},{key:"getPreviousPath",value:function(c,u){for(var d,v=this.w,m=0;m0&&parseInt(x.realIndex,10)===parseInt(c,10)&&v.globals.previousPaths[m].paths[u]!==void 0&&(d=v.globals.previousPaths[m].paths[u].d)}return d}}]),Q}(),Ve=function(Q){p(u,te);var c=z(u);function u(){return a(this,u),c.apply(this,arguments)}return l(u,[{key:"draw",value:function(d,v){var m=this,x=this.w;this.graphics=new $(this.ctx),this.bar=new te(this.ctx,this.xyRatios);var w=new G(this.ctx,x);d=w.getLogSeries(d),this.yRatio=w.getLogYRatios(this.yRatio),this.barHelpers.initVariables(d),x.config.chart.stackType==="100%"&&(d=x.globals.comboCharts?v.map(function(j){return x.globals.seriesPercent[j]}):x.globals.seriesPercent.slice()),this.series=d,this.barHelpers.initializeStackedPrevVars(this);for(var k=this.graphics.group({class:"apexcharts-bar-series apexcharts-plot-series"}),L=0,D=0,P=function(j,U){var q=void 0,J=void 0,rt=void 0,A=void 0,O=x.globals.comboCharts?v[j]:j,X=m.barHelpers.getGroupIndex(O),ot=X.groupIndex,nt=X.columnGroupIndex;m.groupCtx=m[x.globals.seriesGroups[ot]];var ct=[],wt=[],xt=0;m.yRatio.length>1&&(m.yaxisIndex=x.globals.seriesYAxisReverseMap[O][0],xt=O),m.isReversed=x.config.yaxis[m.yaxisIndex]&&x.config.yaxis[m.yaxisIndex].reversed;var jt=m.graphics.group({class:"apexcharts-series",seriesName:E.escapeString(x.globals.seriesNames[O]),rel:j+1,"data:realIndex":O});m.ctx.series.addCollapsedClassToSeries(jt,O);var ee=m.graphics.group({class:"apexcharts-datalabels","data:realIndex":O}),Nt=m.graphics.group({class:"apexcharts-bar-goals-markers"}),Zt=0,ze=0,Te=m.initialPositions(L,D,q,J,rt,A,xt);D=Te.y,Zt=Te.barHeight,J=Te.yDivision,A=Te.zeroW,L=Te.x,ze=Te.barWidth,q=Te.xDivision,rt=Te.zeroH,x.globals.barHeight=Zt,x.globals.barWidth=ze,m.barHelpers.initializeStackedXYVars(m),m.groupCtx.prevY.length===1&&m.groupCtx.prevY[0].every(function(Lr){return isNaN(Lr)})&&(m.groupCtx.prevY[0]=m.groupCtx.prevY[0].map(function(){return rt}),m.groupCtx.prevYF[0]=m.groupCtx.prevYF[0].map(function(){return 0}));for(var Ge=0;Ge1?P=(m=V.globals.minXDiff/this.xRatio)*parseInt(this.barOptions.columnWidth,10)/100:String(j).indexOf("%")===-1?P=parseInt(j,10):P*=parseInt(j,10)/100,w=V.globals.gridHeight-this.baseLineY[L]-(this.isReversed?V.globals.gridHeight:0),d=V.globals.padHorizontal+(m-P)/2}var U=V.globals.barGroups.length||1;return{x:d,y:v,yDivision:x,xDivision:m,barHeight:D/U,barWidth:P/U,zeroH:w,zeroW:k}}},{key:"drawStackedBarPaths",value:function(d){for(var v,m=d.indexes,x=d.barHeight,w=d.strokeWidth,k=d.zeroW,L=d.x,D=d.y,P=d.columnGroupIndex,V=d.seriesGroup,N=d.yDivision,j=d.elSeries,U=this.w,q=D+P*x,J=m.i,rt=m.j,A=m.realIndex,O=m.translationsIndex,X=0,ot=0;ot0){var ct=k;this.groupCtx.prevXVal[nt-1][rt]<0?ct=this.series[J][rt]>=0?this.groupCtx.prevX[nt-1][rt]+X-2*(this.isReversed?X:0):this.groupCtx.prevX[nt-1][rt]:this.groupCtx.prevXVal[nt-1][rt]>=0&&(ct=this.series[J][rt]>=0?this.groupCtx.prevX[nt-1][rt]:this.groupCtx.prevX[nt-1][rt]-X+2*(this.isReversed?X:0)),v=ct}else v=k;L=this.series[J][rt]===null?v:v+this.series[J][rt]/this.invertedYRatio-2*(this.isReversed?this.series[J][rt]/this.invertedYRatio:0);var wt=this.barHelpers.getBarpaths({barYPosition:q,barHeight:x,x1:v,x2:L,strokeWidth:w,series:this.series,realIndex:m.realIndex,seriesGroup:V,i:J,j:rt,w:U});return this.barHelpers.barBackground({j:rt,i:J,y1:q,y2:x,elSeries:j}),D+=N,{pathTo:wt.pathTo,pathFrom:wt.pathFrom,goalX:this.barHelpers.getGoalValues("x",k,null,J,rt,O),barXPosition:v,barYPosition:q,x:L,y:D}}},{key:"drawStackedColumnPaths",value:function(d){var v=d.indexes,m=d.x,x=d.y,w=d.xDivision,k=d.barWidth,L=d.zeroH,D=d.columnGroupIndex,P=d.seriesGroup,V=d.elSeries,N=this.w,j=v.i,U=v.j,q=v.bc,J=v.realIndex,rt=v.translationsIndex;if(N.globals.isXNumeric){var A=N.globals.seriesX[J][U];A||(A=0),m=(A-N.globals.minX)/this.xRatio-k/2*N.globals.barGroups.length}for(var O,X=m+D*k,ot=0,nt=0;nt0&&!N.globals.isXNumeric||ct>0&&N.globals.isXNumeric&&N.globals.seriesX[J-1][U]===N.globals.seriesX[J][U]){var wt,xt,jt,ee=Math.min(this.yRatio.length+1,J+1);if(this.groupCtx.prevY[ct-1]!==void 0&&this.groupCtx.prevY[ct-1].length)for(var Nt=1;Nt=0?jt-ot+2*(this.isReversed?ot:0):jt;break}if(((Ge=this.groupCtx.prevYVal[ct-ze])===null||Ge===void 0?void 0:Ge[U])>=0){xt=this.series[j][U]>=0?jt:jt+ot-2*(this.isReversed?ot:0);break}}xt===void 0&&(xt=N.globals.gridHeight),O=(wt=this.groupCtx.prevYF[0])!==null&&wt!==void 0&&wt.every(function(l1){return l1===0})&&this.groupCtx.prevYF.slice(1,ct).every(function(l1){return l1.every(function(i1){return isNaN(i1)})})?L:xt}else O=L;x=this.series[j][U]?O-this.series[j][U]/this.yRatio[rt]+2*(this.isReversed?this.series[j][U]/this.yRatio[rt]:0):O;var Ye=this.barHelpers.getColumnPaths({barXPosition:X,barWidth:k,y1:O,y2:x,yRatio:this.yRatio[rt],strokeWidth:this.strokeWidth,series:this.series,seriesGroup:P,realIndex:v.realIndex,i:j,j:U,w:N});return this.barHelpers.barBackground({bc:q,j:U,i:j,x1:X,x2:k,elSeries:V}),{pathTo:Ye.pathTo,pathFrom:Ye.pathFrom,goalY:this.barHelpers.getGoalValues("y",null,L,j,U),barXPosition:X,x:N.globals.isXNumeric?m:m+w,y:x}}}]),u}(),He=function(Q){p(u,te);var c=z(u);function u(){return a(this,u),c.apply(this,arguments)}return l(u,[{key:"draw",value:function(d,v,m){var x=this,w=this.w,k=new $(this.ctx),L=w.globals.comboCharts?v:w.config.chart.type,D=new At(this.ctx);this.candlestickOptions=this.w.config.plotOptions.candlestick,this.boxOptions=this.w.config.plotOptions.boxPlot,this.isHorizontal=w.config.plotOptions.bar.horizontal;var P=new G(this.ctx,w);d=P.getLogSeries(d),this.series=d,this.yRatio=P.getLogYRatios(this.yRatio),this.barHelpers.initVariables(d);for(var V=k.group({class:"apexcharts-".concat(L,"-series apexcharts-plot-series")}),N=function(U){x.isBoxPlot=w.config.chart.type==="boxPlot"||w.config.series[U].type==="boxPlot";var q,J,rt,A,O=void 0,X=void 0,ot=[],nt=[],ct=w.globals.comboCharts?m[U]:U,wt=x.barHelpers.getGroupIndex(ct).columnGroupIndex,xt=k.group({class:"apexcharts-series",seriesName:E.escapeString(w.globals.seriesNames[ct]),rel:U+1,"data:realIndex":ct});x.ctx.series.addCollapsedClassToSeries(xt,ct),d[U].length>0&&(x.visibleI=x.visibleI+1);var jt,ee,Nt=0;x.yRatio.length>1&&(x.yaxisIndex=w.globals.seriesYAxisReverseMap[ct][0],Nt=ct);var Zt=x.barHelpers.initialPositions();X=Zt.y,jt=Zt.barHeight,J=Zt.yDivision,A=Zt.zeroW,O=Zt.x,ee=Zt.barWidth,q=Zt.xDivision,rt=Zt.zeroH,nt.push(O+ee/2);for(var ze=k.group({class:"apexcharts-datalabels","data:realIndex":ct}),Te=function(Ye){var l1=x.barHelpers.getStrokeWidth(U,Ye,ct),i1=null,y1={indexes:{i:U,j:Ye,realIndex:ct,translationsIndex:Nt},x:O,y:X,strokeWidth:l1,elSeries:xt};i1=x.isHorizontal?x.drawHorizontalBoxPaths(i(i({},y1),{},{yDivision:J,barHeight:jt,zeroW:A})):x.drawVerticalBoxPaths(i(i({},y1),{},{xDivision:q,barWidth:ee,zeroH:rt})),X=i1.y,O=i1.x,Ye>0&&nt.push(O+ee/2),ot.push(X),i1.pathTo.forEach(function(xr,Lr){var dr=!x.isBoxPlot&&x.candlestickOptions.wick.useFillColor?i1.color[Lr]:w.globals.stroke.colors[U],Bi=D.fillPath({seriesNumber:ct,dataPointIndex:Ye,color:i1.color[Lr],value:d[U][Ye]});x.renderSeries({realIndex:ct,pathFill:Bi,lineFill:dr,j:Ye,i:U,pathFrom:i1.pathFrom,pathTo:xr,strokeWidth:l1,elSeries:xt,x:O,y:X,series:d,columnGroupIndex:wt,barHeight:jt,barWidth:ee,elDataLabelsWrap:ze,visibleSeries:x.visibleI,type:w.config.chart.type})})},Ge=0;GeO.c&&(j=!1);var nt=Math.min(O.o,O.c),ct=Math.max(O.o,O.c),wt=O.m;D.globals.isXNumeric&&(m=(D.globals.seriesX[A][N]-D.globals.minX)/this.xRatio-w/2);var xt=m+w*this.visibleI;this.series[V][N]===void 0||this.series[V][N]===null?(nt=k,ct=k):(nt=k-nt/rt,ct=k-ct/rt,X=k-O.h/rt,ot=k-O.l/rt,wt=k-O.m/rt);var jt=P.move(xt,k),ee=P.move(xt+w/2,nt);return D.globals.previousPaths.length>0&&(ee=this.getPreviousPath(A,N,!0)),jt=this.isBoxPlot?[P.move(xt,nt)+P.line(xt+w/2,nt)+P.line(xt+w/2,X)+P.line(xt+w/4,X)+P.line(xt+w-w/4,X)+P.line(xt+w/2,X)+P.line(xt+w/2,nt)+P.line(xt+w,nt)+P.line(xt+w,wt)+P.line(xt,wt)+P.line(xt,nt+L/2),P.move(xt,wt)+P.line(xt+w,wt)+P.line(xt+w,ct)+P.line(xt+w/2,ct)+P.line(xt+w/2,ot)+P.line(xt+w-w/4,ot)+P.line(xt+w/4,ot)+P.line(xt+w/2,ot)+P.line(xt+w/2,ct)+P.line(xt,ct)+P.line(xt,wt)+"z"]:[P.move(xt,ct)+P.line(xt+w/2,ct)+P.line(xt+w/2,X)+P.line(xt+w/2,ct)+P.line(xt+w,ct)+P.line(xt+w,nt)+P.line(xt+w/2,nt)+P.line(xt+w/2,ot)+P.line(xt+w/2,nt)+P.line(xt,nt)+P.line(xt,ct-L/2)],ee+=P.move(xt,nt),D.globals.isXNumeric||(m+=x),{pathTo:jt,pathFrom:ee,x:m,y:ct,barXPosition:xt,color:this.isBoxPlot?J:j?[U]:[q]}}},{key:"drawHorizontalBoxPaths",value:function(d){var v=d.indexes;d.x;var m=d.y,x=d.yDivision,w=d.barHeight,k=d.zeroW,L=d.strokeWidth,D=this.w,P=new $(this.ctx),V=v.i,N=v.j,j=this.boxOptions.colors.lower;this.isBoxPlot&&(j=[this.boxOptions.colors.lower,this.boxOptions.colors.upper]);var U=this.invertedYRatio,q=v.realIndex,J=this.getOHLCValue(q,N),rt=k,A=k,O=Math.min(J.o,J.c),X=Math.max(J.o,J.c),ot=J.m;D.globals.isXNumeric&&(m=(D.globals.seriesX[q][N]-D.globals.minX)/this.invertedXRatio-w/2);var nt=m+w*this.visibleI;this.series[V][N]===void 0||this.series[V][N]===null?(O=k,X=k):(O=k+O/U,X=k+X/U,rt=k+J.h/U,A=k+J.l/U,ot=k+J.m/U);var ct=P.move(k,nt),wt=P.move(O,nt+w/2);return D.globals.previousPaths.length>0&&(wt=this.getPreviousPath(q,N,!0)),ct=[P.move(O,nt)+P.line(O,nt+w/2)+P.line(rt,nt+w/2)+P.line(rt,nt+w/2-w/4)+P.line(rt,nt+w/2+w/4)+P.line(rt,nt+w/2)+P.line(O,nt+w/2)+P.line(O,nt+w)+P.line(ot,nt+w)+P.line(ot,nt)+P.line(O+L/2,nt),P.move(ot,nt)+P.line(ot,nt+w)+P.line(X,nt+w)+P.line(X,nt+w/2)+P.line(A,nt+w/2)+P.line(A,nt+w-w/4)+P.line(A,nt+w/4)+P.line(A,nt+w/2)+P.line(X,nt+w/2)+P.line(X,nt)+P.line(ot,nt)+"z"],wt+=P.move(O,nt),D.globals.isXNumeric||(m+=x),{pathTo:ct,pathFrom:wt,x:X,y:m,barYPosition:nt,color:j}}},{key:"getOHLCValue",value:function(d,v){var m=this.w;return{o:this.isBoxPlot?m.globals.seriesCandleH[d][v]:m.globals.seriesCandleO[d][v],h:this.isBoxPlot?m.globals.seriesCandleO[d][v]:m.globals.seriesCandleH[d][v],m:m.globals.seriesCandleM[d][v],l:this.isBoxPlot?m.globals.seriesCandleC[d][v]:m.globals.seriesCandleL[d][v],c:this.isBoxPlot?m.globals.seriesCandleL[d][v]:m.globals.seriesCandleC[d][v]}}}]),u}(),d1=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w}return l(Q,[{key:"checkColorRange",value:function(){var c=this.w,u=!1,d=c.config.plotOptions[c.config.chart.type];return d.colorScale.ranges.length>0&&d.colorScale.ranges.map(function(v,m){v.from<=0&&(u=!0)}),u}},{key:"getShadeColor",value:function(c,u,d,v){var m=this.w,x=1,w=m.config.plotOptions[c].shadeIntensity,k=this.determineColor(c,u,d);m.globals.hasNegs||v?x=m.config.plotOptions[c].reverseNegativeShade?k.percent<0?k.percent/100*(1.25*w):(1-k.percent/100)*(1.25*w):k.percent<=0?1-(1+k.percent/100)*w:(1-k.percent/100)*w:(x=1-k.percent/100,c==="treemap"&&(x=(1-k.percent/100)*(1.25*w)));var L=k.color,D=new E;return m.config.plotOptions[c].enableShades&&(L=this.w.config.theme.mode==="dark"?E.hexToRgba(D.shadeColor(-1*x,k.color),m.config.fill.opacity):E.hexToRgba(D.shadeColor(x,k.color),m.config.fill.opacity)),{color:L,colorProps:k}}},{key:"determineColor",value:function(c,u,d){var v=this.w,m=v.globals.series[u][d],x=v.config.plotOptions[c],w=x.colorScale.inverse?d:u;x.distributed&&v.config.chart.type==="treemap"&&(w=d);var k=v.globals.colors[w],L=null,D=Math.min.apply(Math,I(v.globals.series[u])),P=Math.max.apply(Math,I(v.globals.series[u]));x.distributed||c!=="heatmap"||(D=v.globals.minY,P=v.globals.maxY),x.colorScale.min!==void 0&&(D=x.colorScale.minv.globals.maxY?x.colorScale.max:v.globals.maxY);var V=Math.abs(P)+Math.abs(D),N=100*m/(V===0?V-1e-6:V);return x.colorScale.ranges.length>0&&x.colorScale.ranges.map(function(j,U){if(m>=j.from&&m<=j.to){k=j.color,L=j.foreColor?j.foreColor:null,D=j.from,P=j.to;var q=Math.abs(P)+Math.abs(D);N=100*m/(q===0?q-1e-6:q)}}),{color:k,foreColor:L,percent:N}}},{key:"calculateDataLabels",value:function(c){var u=c.text,d=c.x,v=c.y,m=c.i,x=c.j,w=c.colorProps,k=c.fontSize,L=this.w.config.dataLabels,D=new $(this.ctx),P=new Ut(this.ctx),V=null;if(L.enabled){V=D.group({class:"apexcharts-data-labels"});var N=L.offsetX,j=L.offsetY,U=d+N,q=v+parseFloat(L.style.fontSize)/3+j;P.plotDataLabelsText({x:U,y:q,text:u,i:m,j:x,color:w.foreColor,parent:V,fontSize:k,dataLabelsConfig:L})}return V}},{key:"addListeners",value:function(c){var u=new $(this.ctx);c.node.addEventListener("mouseenter",u.pathMouseEnter.bind(this,c)),c.node.addEventListener("mouseleave",u.pathMouseLeave.bind(this,c)),c.node.addEventListener("mousedown",u.pathMouseDown.bind(this,c))}}]),Q}(),Le=function(){function Q(c,u){a(this,Q),this.ctx=c,this.w=c.w,this.xRatio=u.xRatio,this.yRatio=u.yRatio,this.dynamicAnim=this.w.config.chart.animations.dynamicAnimation,this.helpers=new d1(c),this.rectRadius=this.w.config.plotOptions.heatmap.radius,this.strokeWidth=this.w.config.stroke.show?this.w.config.stroke.width:0}return l(Q,[{key:"draw",value:function(c){var u=this.w,d=new $(this.ctx),v=d.group({class:"apexcharts-heatmap"});v.attr("clip-path","url(#gridRectMask".concat(u.globals.cuid,")"));var m=u.globals.gridWidth/u.globals.dataPoints,x=u.globals.gridHeight/u.globals.series.length,w=0,k=!1;this.negRange=this.helpers.checkColorRange();var L=c.slice();u.config.yaxis[0].reversed&&(k=!0,L.reverse());for(var D=k?0:L.length-1;k?D=0;k?D++:D--){var P=d.group({class:"apexcharts-series apexcharts-heatmap-series",seriesName:E.escapeString(u.globals.seriesNames[D]),rel:D+1,"data:realIndex":D});if(this.ctx.series.addCollapsedClassToSeries(P,D),u.config.chart.dropShadow.enabled){var V=u.config.chart.dropShadow;new W(this.ctx).dropShadow(P,V,D)}for(var N=0,j=u.config.plotOptions.heatmap.shadeIntensity,U=0;U-1&&this.pieClicked(V),d.config.dataLabels.enabled){var X=A.x,ot=A.y,nt=100*j/this.fullAngle+"%";if(j!==0&&d.config.plotOptions.pie.dataLabels.minAngleToShowLabelthis.fullAngle?u.endAngle=u.endAngle-(v+w):v+w=this.fullAngle+this.w.config.plotOptions.pie.startAngle%this.fullAngle&&(D=this.fullAngle+this.w.config.plotOptions.pie.startAngle%this.fullAngle-.01),Math.ceil(D)>this.fullAngle&&(D-=this.fullAngle);var P=Math.PI*(D-90)/180,V=d.centerX+x*Math.cos(L),N=d.centerY+x*Math.sin(L),j=d.centerX+x*Math.cos(P),U=d.centerY+x*Math.sin(P),q=E.polarToCartesian(d.centerX,d.centerY,d.donutSize,D),J=E.polarToCartesian(d.centerX,d.centerY,d.donutSize,k),rt=m>180?1:0,A=["M",V,N,"A",x,x,0,rt,1,j,U];return u=d.chartType==="donut"?[].concat(A,["L",q.x,q.y,"A",d.donutSize,d.donutSize,0,rt,0,J.x,J.y,"L",V,N,"z"]).join(" "):d.chartType==="pie"||d.chartType==="polarArea"?[].concat(A,["L",d.centerX,d.centerY,"L",V,N]).join(" "):[].concat(A).join(" "),w.roundPathCorners(u,2*this.strokeWidth)}},{key:"drawPolarElements",value:function(c){var u=this.w,d=new Ot(this.ctx),v=new $(this.ctx),m=new ge(this.ctx),x=v.group(),w=v.group(),k=d.niceScale(0,Math.ceil(this.maxY),0),L=k.result.reverse(),D=k.result.length;this.maxY=k.niceMax;for(var P=u.globals.radialSize,V=P/(D-1),N=0;N1&&c.total.show&&(m=c.total.color);var w=x.globals.dom.baseEl.querySelector(".apexcharts-datalabel-label"),k=x.globals.dom.baseEl.querySelector(".apexcharts-datalabel-value");d=(0,c.value.formatter)(d,x),v||typeof c.total.formatter!="function"||(d=c.total.formatter(x));var L=u===c.total.label;u=c.name.formatter(u,L,x),w!==null&&(w.textContent=u),k!==null&&(k.textContent=d),w!==null&&(w.style.fill=m)}},{key:"printDataLabelsInner",value:function(c,u){var d=this.w,v=c.getAttribute("data:value"),m=d.globals.seriesNames[parseInt(c.parentNode.getAttribute("rel"),10)-1];d.globals.series.length>1&&this.printInnerLabels(u,m,v,c);var x=d.globals.dom.baseEl.querySelector(".apexcharts-datalabels-group");x!==null&&(x.style.opacity=1)}},{key:"drawSpokes",value:function(c){var u=this,d=this.w,v=new $(this.ctx),m=d.config.plotOptions.polarArea.spokes;if(m.strokeWidth!==0){for(var x=[],w=360/d.globals.series.length,k=0;k0&&(ot=u.getPreviousPath(J));for(var nt=0;nt=10?c.x>0?(d="start",v+=10):c.x<0&&(d="end",v-=10):d="middle",Math.abs(c.y)>=u-10&&(c.y<0?m-=10:c.y>0&&(m+=10)),{textAnchor:d,newX:v,newY:m}}},{key:"getPreviousPath",value:function(c){for(var u=this.w,d=null,v=0;v0&&parseInt(m.realIndex,10)===parseInt(c,10)&&u.globals.previousPaths[v].paths[0]!==void 0&&(d=u.globals.previousPaths[v].paths[0].d)}return d}},{key:"getDataPointsPos",value:function(c,u){var d=arguments.length>2&&arguments[2]!==void 0?arguments[2]:this.dataPointsLen;c=c||[],u=u||[];for(var v=[],m=0;m=360&&(U=360-Math.abs(this.startAngle)-.1);var q=m.drawPath({d:"",stroke:N,strokeWidth:L*parseInt(V.strokeWidth,10)/100,fill:"none",strokeOpacity:V.opacity,classes:"apexcharts-radialbar-area"});if(V.dropShadow.enabled){var J=V.dropShadow;w.dropShadow(q,J)}P.add(q),q.attr("id","apexcharts-radialbarTrack-"+D),this.animatePaths(q,{centerX:d.centerX,centerY:d.centerY,endAngle:U,startAngle:j,size:d.size,i:D,totalItems:2,animBeginArr:0,dur:0,isTrack:!0,easing:v.globals.easing})}return x}},{key:"drawArcs",value:function(d){var v=this.w,m=new $(this.ctx),x=new At(this.ctx),w=new W(this.ctx),k=m.group(),L=this.getStrokeWidth(d);d.size=d.size-L/2;var D=v.config.plotOptions.radialBar.hollow.background,P=d.size-L*d.series.length-this.margin*d.series.length-L*parseInt(v.config.plotOptions.radialBar.track.strokeWidth,10)/100/2,V=P-v.config.plotOptions.radialBar.hollow.margin;v.config.plotOptions.radialBar.hollow.image!==void 0&&(D=this.drawHollowImage(d,k,P,D));var N=this.drawHollow({size:V,centerX:d.centerX,centerY:d.centerY,fill:D||"transparent"});if(v.config.plotOptions.radialBar.hollow.dropShadow.enabled){var j=v.config.plotOptions.radialBar.hollow.dropShadow;w.dropShadow(N,j)}var U=1;!this.radialDataLabels.total.show&&v.globals.series.length>1&&(U=0);var q=null;if(this.radialDataLabels.show){var J=v.globals.dom.Paper.select(".apexcharts-datalabels-group").members[0];q=this.renderInnerDataLabels(J,this.radialDataLabels,{hollowSize:P,centerX:d.centerX,centerY:d.centerY,opacity:U})}v.config.plotOptions.radialBar.hollow.position==="back"&&(k.add(N),q&&k.add(q));var rt=!1;v.config.plotOptions.radialBar.inverseOrder&&(rt=!0);for(var A=rt?d.series.length-1:0;rt?A>=0:A100?100:d.series[A])/100,wt=Math.round(this.totalAngle*ct)+this.startAngle,xt=void 0;v.globals.dataChanged&&(nt=this.startAngle,xt=Math.round(this.totalAngle*E.negToZero(v.globals.previousPaths[A])/100)+nt),Math.abs(wt)+Math.abs(ot)>=360&&(wt-=.01),Math.abs(xt)+Math.abs(nt)>=360&&(xt-=.01);var jt=wt-ot,ee=Array.isArray(v.config.stroke.dashArray)?v.config.stroke.dashArray[A]:v.config.stroke.dashArray,Nt=m.drawPath({d:"",stroke:X,strokeWidth:L,fill:"none",fillOpacity:v.config.fill.opacity,classes:"apexcharts-radialbar-area apexcharts-radialbar-slice-"+A,strokeDashArray:ee});if($.setAttrs(Nt.node,{"data:angle":jt,"data:value":d.series[A]}),v.config.chart.dropShadow.enabled){var Zt=v.config.chart.dropShadow;w.dropShadow(Nt,Zt,A)}if(w.setSelectionFilter(Nt,0,A),this.addListeners(Nt,this.radialDataLabels),O.add(Nt),Nt.attr({index:0,j:A}),this.barLabels.enabled){var ze=E.polarToCartesian(d.centerX,d.centerY,d.size,ot),Te=this.barLabels.formatter(v.globals.seriesNames[A],{seriesIndex:A,w:v}),Ge=["apexcharts-radialbar-label"];this.barLabels.onClick||Ge.push("apexcharts-no-click");var Ye=this.barLabels.useSeriesColors?v.globals.colors[A]:v.config.chart.foreColor;Ye||(Ye=v.config.chart.foreColor);var l1=ze.x+this.barLabels.offsetX,i1=ze.y+this.barLabels.offsetY,y1=m.drawText({x:l1,y:i1,text:Te,textAnchor:"end",dominantBaseline:"middle",fontFamily:this.barLabels.fontFamily,fontWeight:this.barLabels.fontWeight,fontSize:this.barLabels.fontSize,foreColor:Ye,cssClass:Ge.join(" ")});y1.on("click",this.onBarLabelClick),y1.attr({rel:A+1}),ot!==0&&y1.attr({"transform-origin":"".concat(l1," ").concat(i1),transform:"rotate(".concat(ot," 0 0)")}),O.add(y1)}var xr=0;!this.initialAnim||v.globals.resized||v.globals.dataChanged||(xr=v.config.chart.animations.speed),v.globals.dataChanged&&(xr=v.config.chart.animations.dynamicAnimation.speed),this.animDur=xr/(1.2*d.series.length)+this.animDur,this.animBeginArr.push(this.animDur),this.animatePaths(Nt,{centerX:d.centerX,centerY:d.centerY,endAngle:wt,startAngle:ot,prevEndAngle:xt,prevStartAngle:nt,size:d.size,i:A,totalItems:2,animBeginArr:this.animBeginArr,dur:xr,shouldSetPrevPaths:!0,easing:v.globals.easing})}return{g:k,elHollow:N,dataLabels:q}}},{key:"drawHollow",value:function(d){var v=new $(this.ctx).drawCircle(2*d.size);return v.attr({class:"apexcharts-radialbar-hollow",cx:d.centerX,cy:d.centerY,r:d.size,fill:d.fill}),v}},{key:"drawHollowImage",value:function(d,v,m,x){var w=this.w,k=new At(this.ctx),L=E.randomId(),D=w.config.plotOptions.radialBar.hollow.image;if(w.config.plotOptions.radialBar.hollow.imageClipped)k.clippedImgArea({width:m,height:m,image:D,patternID:"pattern".concat(w.globals.cuid).concat(L)}),x="url(#pattern".concat(w.globals.cuid).concat(L,")");else{var P=w.config.plotOptions.radialBar.hollow.imageWidth,V=w.config.plotOptions.radialBar.hollow.imageHeight;if(P===void 0&&V===void 0){var N=w.globals.dom.Paper.image(D).loaded(function(U){this.move(d.centerX-U.width/2+w.config.plotOptions.radialBar.hollow.imageOffsetX,d.centerY-U.height/2+w.config.plotOptions.radialBar.hollow.imageOffsetY)});v.add(N)}else{var j=w.globals.dom.Paper.image(D).loaded(function(U){this.move(d.centerX-P/2+w.config.plotOptions.radialBar.hollow.imageOffsetX,d.centerY-V/2+w.config.plotOptions.radialBar.hollow.imageOffsetY),this.size(P,V)});v.add(j)}}return x}},{key:"getStrokeWidth",value:function(d){var v=this.w;return d.size*(100-parseInt(v.config.plotOptions.radialBar.hollow.size,10))/100/(d.series.length+1)-this.margin}},{key:"onBarLabelClick",value:function(d){var v=parseInt(d.target.getAttribute("rel"),10)-1,m=this.barLabels.onClick,x=this.w;m&&m(x.globals.seriesNames[v],{w:x,seriesIndex:v})}}]),u}(),zr=function(Q){p(u,te);var c=z(u);function u(){return a(this,u),c.apply(this,arguments)}return l(u,[{key:"draw",value:function(d,v){var m=this.w,x=new $(this.ctx);this.rangeBarOptions=this.w.config.plotOptions.rangeBar,this.series=d,this.seriesRangeStart=m.globals.seriesRangeStart,this.seriesRangeEnd=m.globals.seriesRangeEnd,this.barHelpers.initVariables(d);for(var w=x.group({class:"apexcharts-rangebar-series apexcharts-plot-series"}),k=0;k0&&(this.visibleI=this.visibleI+1);var rt=0,A=0,O=0;this.yRatio.length>1&&(this.yaxisIndex=m.globals.seriesYAxisReverseMap[U][0],O=U);var X=this.barHelpers.initialPositions();j=X.y,V=X.zeroW,N=X.x,A=X.barWidth,rt=X.barHeight,L=X.xDivision,D=X.yDivision,P=X.zeroH;for(var ot=x.group({class:"apexcharts-datalabels","data:realIndex":U}),nt=x.group({class:"apexcharts-rangebar-goals-markers"}),ct=0;ct0});return this.isHorizontal?(x=U.config.plotOptions.bar.rangeBarGroupRows?k+V*O:k+D*this.visibleI+V*O,X>-1&&!U.config.plotOptions.bar.rangeBarOverlap&&(q=U.globals.seriesRange[v][X].overlaps).indexOf(J)>-1&&(x=(D=j.barHeight/q.length)*this.visibleI+V*(100-parseInt(this.barOptions.barHeight,10))/100/2+D*(this.visibleI+q.indexOf(J))+V*O)):(O>-1&&!U.globals.timescaleLabels.length&&(w=U.config.plotOptions.bar.rangeBarGroupRows?L+N*O:L+P*this.visibleI+N*O),X>-1&&!U.config.plotOptions.bar.rangeBarOverlap&&(q=U.globals.seriesRange[v][X].overlaps).indexOf(J)>-1&&(w=(P=j.barWidth/q.length)*this.visibleI+N*(100-parseInt(this.barOptions.barWidth,10))/100/2+P*(this.visibleI+q.indexOf(J))+N*O)),{barYPosition:x,barXPosition:w,barHeight:D,barWidth:P}}},{key:"drawRangeColumnPaths",value:function(d){var v=d.indexes,m=d.x,x=d.xDivision,w=d.barWidth,k=d.barXPosition,L=d.zeroH,D=this.w,P=v.i,V=v.j,N=v.realIndex,j=v.translationsIndex,U=this.yRatio[j],q=this.getRangeValue(N,V),J=Math.min(q.start,q.end),rt=Math.max(q.start,q.end);this.series[P][V]===void 0||this.series[P][V]===null?J=L:(J=L-J/U,rt=L-rt/U);var A=Math.abs(rt-J),O=this.barHelpers.getColumnPaths({barXPosition:k,barWidth:w,y1:J,y2:rt,strokeWidth:this.strokeWidth,series:this.seriesRangeEnd,realIndex:N,i:N,j:V,w:D});if(D.globals.isXNumeric){var X=this.getBarXForNumericXAxis({x:m,j:V,realIndex:N,barWidth:w});m=X.x,k=X.barXPosition}else m+=x;return{pathTo:O.pathTo,pathFrom:O.pathFrom,barHeight:A,x:m,y:q.start<0&&q.end<0?J:rt,goalY:this.barHelpers.getGoalValues("y",null,L,P,V,j),barXPosition:k}}},{key:"preventBarOverflow",value:function(d){var v=this.w;return d<0&&(d=0),d>v.globals.gridWidth&&(d=v.globals.gridWidth),d}},{key:"drawRangeBarPaths",value:function(d){var v=d.indexes,m=d.y,x=d.y1,w=d.y2,k=d.yDivision,L=d.barHeight,D=d.barYPosition,P=d.zeroW,V=this.w,N=v.realIndex,j=v.j,U=this.preventBarOverflow(P+x/this.invertedYRatio),q=this.preventBarOverflow(P+w/this.invertedYRatio),J=this.getRangeValue(N,j),rt=Math.abs(q-U),A=this.barHelpers.getBarpaths({barYPosition:D,barHeight:L,x1:U,x2:q,strokeWidth:this.strokeWidth,series:this.seriesRangeEnd,i:N,realIndex:N,j,w:V});return V.globals.isXNumeric||(m+=k),{pathTo:A.pathTo,pathFrom:A.pathFrom,barWidth:rt,x:J.start<0&&J.end<0?U:q,goalX:this.barHelpers.getGoalValues("x",P,null,N,j),y:m}}},{key:"getRangeValue",value:function(d,v){var m=this.w;return{start:m.globals.seriesRangeStart[d][v],end:m.globals.seriesRangeEnd[d][v]}}}]),u}(),Xr=function(){function Q(c){a(this,Q),this.w=c.w,this.lineCtx=c}return l(Q,[{key:"sameValueSeriesFix",value:function(c,u){var d=this.w;if((d.config.fill.type==="gradient"||d.config.fill.type[c]==="gradient")&&new G(this.lineCtx.ctx,d).seriesHaveSameValues(c)){var v=u[c].slice();v[v.length-1]=v[v.length-1]+1e-6,u[c]=v}return u}},{key:"calculatePoints",value:function(c){var u=c.series,d=c.realIndex,v=c.x,m=c.y,x=c.i,w=c.j,k=c.prevY,L=this.w,D=[],P=[];if(w===0){var V=this.lineCtx.categoryAxisCorrection+L.config.markers.offsetX;L.globals.isXNumeric&&(V=(L.globals.seriesX[d][0]-L.globals.minX)/this.lineCtx.xRatio+L.config.markers.offsetX),D.push(V),P.push(E.isNumber(u[x][0])?k+L.config.markers.offsetY:null),D.push(v+L.config.markers.offsetX),P.push(E.isNumber(u[x][w+1])?m+L.config.markers.offsetY:null)}else D.push(v+L.config.markers.offsetX),P.push(E.isNumber(u[x][w+1])?m+L.config.markers.offsetY:null);return{x:D,y:P}}},{key:"checkPreviousPaths",value:function(c){for(var u=c.pathFromLine,d=c.pathFromArea,v=c.realIndex,m=this.w,x=0;x0&&parseInt(w.realIndex,10)===parseInt(v,10)&&(w.type==="line"?(this.lineCtx.appendPathFrom=!1,u=m.globals.previousPaths[x].paths[0].d):w.type==="area"&&(this.lineCtx.appendPathFrom=!1,d=m.globals.previousPaths[x].paths[0].d,m.config.stroke.show&&m.globals.previousPaths[x].paths[1]&&(u=m.globals.previousPaths[x].paths[1].d)))}return{pathFromLine:u,pathFromArea:d}}},{key:"determineFirstPrevY",value:function(c){var u,d,v,m=c.i,x=c.realIndex,w=c.series,k=c.prevY,L=c.lineYPosition,D=c.translationsIndex,P=this.w,V=P.config.chart.stacked&&!P.globals.comboCharts||P.config.chart.stacked&&P.globals.comboCharts&&(!this.w.config.chart.stackOnlyBar||((u=this.w.config.series[x])===null||u===void 0?void 0:u.type)==="bar"||((d=this.w.config.series[x])===null||d===void 0?void 0:d.type)==="column");if(((v=w[m])===null||v===void 0?void 0:v[0])!==void 0)k=(L=V&&m>0?this.lineCtx.prevSeriesY[m-1][0]:this.lineCtx.zeroY)-w[m][0]/this.lineCtx.yRatio[D]+2*(this.lineCtx.isReversed?w[m][0]/this.lineCtx.yRatio[D]:0);else if(V&&m>0&&w[m][0]===void 0){for(var N=m-1;N>=0;N--)if(w[N][0]!==null&&w[N][0]!==void 0){k=L=this.lineCtx.prevSeriesY[N][0];break}}return{prevY:k,lineYPosition:L}}}]),Q}(),jn=function(Q){for(var c,u,d,v,m=function(D){for(var P=[],V=D[0],N=D[1],j=P[0]=ps(V,N),U=1,q=D.length-1;U9&&(v=3*d/Math.sqrt(v),m[k]=v*c,m[k+1]=v*u);for(var L=0;L<=x;L++)v=(Q[Math.min(x,L+1)][0]-Q[Math.max(0,L-1)][0])/(6*(1+m[L]*m[L])),w.push([v||0,m[L]*v||0]);return w},Gn=function(Q){var c=jn(Q),u=Q[1],d=Q[0],v=[],m=c[1],x=c[0];v.push(d,[d[0]+x[0],d[1]+x[1],u[0]-m[0],u[1]-m[1],u[0],u[1]]);for(var w=2,k=c.length;w1&&d[1].length<6){var v=d[0].length;d[1]=[2*d[0][v-2]-d[0][v-4],2*d[0][v-1]-d[0][v-3]].concat(d[1])}d[0]=d[0].slice(-2)}return d};function ps(Q,c){return(c[1]-Q[1])/(c[0]-Q[0])}var ds=function(){function Q(c,u,d){a(this,Q),this.ctx=c,this.w=c.w,this.xyRatios=u,this.pointsChart=!(this.w.config.chart.type!=="bubble"&&this.w.config.chart.type!=="scatter")||d,this.scatter=new Bt(this.ctx),this.noNegatives=this.w.globals.minX===Number.MAX_VALUE,this.lineHelpers=new Xr(this),this.markers=new Ft(this.ctx),this.prevSeriesY=[],this.categoryAxisCorrection=0,this.yaxisIndex=0}return l(Q,[{key:"draw",value:function(c,u,d,v){var m,x=this.w,w=new $(this.ctx),k=x.globals.comboCharts?u:x.config.chart.type,L=w.group({class:"apexcharts-".concat(k,"-series apexcharts-plot-series")}),D=new G(this.ctx,x);this.yRatio=this.xyRatios.yRatio,this.zRatio=this.xyRatios.zRatio,this.xRatio=this.xyRatios.xRatio,this.baseLineY=this.xyRatios.baseLineY,c=D.getLogSeries(c),this.yRatio=D.getLogYRatios(this.yRatio),this.prevSeriesY=[];for(var P=[],V=0;V1?N:0;this._initSerieVariables(c,V,N);var U=[],q=[],J=[],rt=x.globals.padHorizontal+this.categoryAxisCorrection;this.ctx.series.addCollapsedClassToSeries(this.elSeries,N),x.globals.isXNumeric&&x.globals.seriesX.length>0&&(rt=(x.globals.seriesX[N][0]-x.globals.minX)/this.xRatio),J.push(rt);var A,O=rt,X=void 0,ot=O,nt=this.zeroY,ct=this.zeroY;nt=this.lineHelpers.determineFirstPrevY({i:V,realIndex:N,series:c,prevY:nt,lineYPosition:0,translationsIndex:j}).prevY,x.config.stroke.curve==="monotoneCubic"&&c[V][0]===null?U.push(null):U.push(nt),A=nt,k==="rangeArea"&&(X=ct=this.lineHelpers.determineFirstPrevY({i:V,realIndex:N,series:v,prevY:ct,lineYPosition:0,translationsIndex:j}).prevY,q.push(U[0]!==null?ct:null));var wt=this._calculatePathsFrom({type:k,series:c,i:V,realIndex:N,translationsIndex:j,prevX:ot,prevY:nt,prevY2:ct}),xt=[U[0]],jt=[q[0]],ee={type:k,series:c,realIndex:N,translationsIndex:j,i:V,x:rt,y:1,pX:O,pY:A,pathsFrom:wt,linePaths:[],areaPaths:[],seriesIndex:d,lineYPosition:0,xArrj:J,yArrj:U,y2Arrj:q,seriesRangeEnd:v},Nt=this._iterateOverDataPoints(i(i({},ee),{},{iterations:k==="rangeArea"?c[V].length-1:void 0,isRangeStart:!0}));if(k==="rangeArea"){for(var Zt=this._calculatePathsFrom({series:v,i:V,realIndex:N,prevX:ot,prevY:ct}),ze=this._iterateOverDataPoints(i(i({},ee),{},{series:v,xArrj:[rt],yArrj:xt,y2Arrj:jt,pY:X,areaPaths:Nt.areaPaths,pathsFrom:Zt,iterations:v[V].length-1,isRangeStart:!1})),Te=Nt.linePaths.length/2,Ge=0;Ge=0;Ye--)L.add(P[Ye]);else for(var l1=0;l11&&(this.yaxisIndex=v.globals.seriesYAxisReverseMap[d],x=d),this.isReversed=v.config.yaxis[this.yaxisIndex]&&v.config.yaxis[this.yaxisIndex].reversed,this.zeroY=v.globals.gridHeight-this.baseLineY[x]-(this.isReversed?v.globals.gridHeight:0)+(this.isReversed?2*this.baseLineY[x]:0),this.areaBottomY=this.zeroY,(this.zeroY>v.globals.gridHeight||v.config.plotOptions.area.fillTo==="end")&&(this.areaBottomY=v.globals.gridHeight),this.categoryAxisCorrection=this.xDivision/2,this.elSeries=m.group({class:"apexcharts-series",zIndex:v.config.series[d].zIndex!==void 0?v.config.series[d].zIndex:d,seriesName:E.escapeString(v.globals.seriesNames[d])}),this.elPointsMain=m.group({class:"apexcharts-series-markers-wrap","data:realIndex":d}),this.elDataLabelsWrap=m.group({class:"apexcharts-datalabels","data:realIndex":d});var w=c[u].length===v.globals.dataPoints;this.elSeries.attr({"data:longestSeries":w,rel:u+1,"data:realIndex":d}),this.appendPathFrom=!0}},{key:"_calculatePathsFrom",value:function(c){var u,d,v,m,x=c.type,w=c.series,k=c.i,L=c.realIndex,D=c.translationsIndex,P=c.prevX,V=c.prevY,N=c.prevY2,j=this.w,U=new $(this.ctx);if(w[k][0]===null){for(var q=0;q0){var J=this.lineHelpers.checkPreviousPaths({pathFromLine:v,pathFromArea:m,realIndex:L});v=J.pathFromLine,m=J.pathFromArea}return{prevX:P,prevY:V,linePath:u,areaPath:d,pathFromLine:v,pathFromArea:m}}},{key:"_handlePaths",value:function(c){var u=c.type,d=c.realIndex,v=c.i,m=c.paths,x=this.w,w=new $(this.ctx),k=new At(this.ctx);this.prevSeriesY.push(m.yArrj),x.globals.seriesXvalues[d]=m.xArrj,x.globals.seriesYvalues[d]=m.yArrj;var L=x.config.forecastDataPoints;if(L.count>0&&u!=="rangeArea"){var D=x.globals.seriesXvalues[d][x.globals.seriesXvalues[d].length-L.count-1],P=w.drawRect(D,0,x.globals.gridWidth,x.globals.gridHeight,0);x.globals.dom.elForecastMask.appendChild(P.node);var V=w.drawRect(0,0,D,x.globals.gridHeight,0);x.globals.dom.elNonForecastMask.appendChild(V.node)}this.pointsChart||x.globals.delayedElements.push({el:this.elPointsMain.node,index:d});var N={i:v,realIndex:d,animationDelay:v,initialSpeed:x.config.chart.animations.speed,dataChangeSpeed:x.config.chart.animations.dynamicAnimation.speed,className:"apexcharts-".concat(u)};if(u==="area")for(var j=k.fillPath({seriesNumber:d}),U=0;U0&&u!=="rangeArea"){var nt=w.renderPaths(X);nt.node.setAttribute("stroke-dasharray",L.dashArray),L.strokeWidth&&nt.node.setAttribute("stroke-width",L.strokeWidth),this.elSeries.add(nt),nt.attr("clip-path","url(#forecastMask".concat(x.globals.cuid,")")),ot.attr("clip-path","url(#nonForecastMask".concat(x.globals.cuid,")"))}}}}},{key:"_iterateOverDataPoints",value:function(c){var u,d,v=this,m=c.type,x=c.series,w=c.iterations,k=c.realIndex,L=c.translationsIndex,D=c.i,P=c.x,V=c.y,N=c.pX,j=c.pY,U=c.pathsFrom,q=c.linePaths,J=c.areaPaths,rt=c.seriesIndex,A=c.lineYPosition,O=c.xArrj,X=c.yArrj,ot=c.y2Arrj,nt=c.isRangeStart,ct=c.seriesRangeEnd,wt=this.w,xt=new $(this.ctx),jt=this.yRatio,ee=U.prevY,Nt=U.linePath,Zt=U.areaPath,ze=U.pathFromLine,Te=U.pathFromArea,Ge=E.isNumber(wt.globals.minYArr[k])?wt.globals.minYArr[k]:wt.globals.minY;w||(w=wt.globals.dataPoints>1?wt.globals.dataPoints-1:wt.globals.dataPoints);var Ye=function(mi,ri){return ri-mi/jt[L]+2*(v.isReversed?mi/jt[L]:0)},l1=V,i1=wt.config.chart.stacked&&!wt.globals.comboCharts||wt.config.chart.stacked&&wt.globals.comboCharts&&(!this.w.config.chart.stackOnlyBar||((u=this.w.config.series[k])===null||u===void 0?void 0:u.type)==="bar"||((d=this.w.config.series[k])===null||d===void 0?void 0:d.type)==="column"),y1=wt.config.stroke.curve;Array.isArray(y1)&&(y1=Array.isArray(rt)?y1[rt[D]]:y1[D]);for(var xr,Lr=0,dr=0;dr0&&wt.globals.collapsedSeries.length0;ri--){if(!(wt.globals.collapsedSeriesIndices.indexOf((rt==null?void 0:rt[ri])||ri)>-1))return ri;ri--}return 0}(D-1)][dr+1]:A=this.zeroY:A=this.zeroY,Bi?V=Ye(Ge,A):(V=Ye(x[D][dr+1],A),m==="rangeArea"&&(l1=Ye(ct[D][dr+1],A))),O.push(P),!Bi||wt.config.stroke.curve!=="smooth"&&wt.config.stroke.curve!=="monotoneCubic"?(X.push(V),ot.push(l1)):(X.push(null),ot.push(null));var O1=this.lineHelpers.calculatePoints({series:x,x:P,y:V,realIndex:k,i:D,j:dr,prevY:ee}),G1=this._createPaths({type:m,series:x,i:D,realIndex:k,j:dr,x:P,y:V,y2:l1,xArrj:O,yArrj:X,y2Arrj:ot,pX:N,pY:j,pathState:Lr,segmentStartX:xr,linePath:Nt,areaPath:Zt,linePaths:q,areaPaths:J,curve:y1,isRangeStart:nt});J=G1.areaPaths,q=G1.linePaths,N=G1.pX,j=G1.pY,Lr=G1.pathState,xr=G1.segmentStartX,Zt=G1.areaPath,Nt=G1.linePath,!this.appendPathFrom||y1==="monotoneCubic"&&m==="rangeArea"||(ze+=xt.line(P,this.zeroY),Te+=xt.line(P,this.zeroY)),this.handleNullDataPoints(x,O1,D,dr,k),this._handleMarkersAndLabels({type:m,pointsPos:O1,i:D,j:dr,realIndex:k,isRangeStart:nt})}return{yArrj:X,xArrj:O,pathFromArea:Te,areaPaths:J,pathFromLine:ze,linePaths:q,linePath:Nt,areaPath:Zt}}},{key:"_handleMarkersAndLabels",value:function(c){var u=c.type,d=c.pointsPos,v=c.isRangeStart,m=c.i,x=c.j,w=c.realIndex,k=this.w,L=new Ut(this.ctx);if(this.pointsChart)this.scatter.draw(this.elSeries,x,{realIndex:w,pointsPos:d,zRatio:this.zRatio,elParent:this.elPointsMain});else{k.globals.series[m].length>1&&this.elPointsMain.node.classList.add("apexcharts-element-hidden");var D=this.markers.plotChartMarkers(d,w,x+1);D!==null&&this.elPointsMain.add(D)}var P=L.drawDataLabel({type:u,isRangeStart:v,pos:d,i:w,j:x+1});P!==null&&this.elDataLabelsWrap.add(P)}},{key:"_createPaths",value:function(c){var u=c.type,d=c.series,v=c.i;c.realIndex;var m=c.j,x=c.x,w=c.y,k=c.xArrj,L=c.yArrj,D=c.y2,P=c.y2Arrj,V=c.pX,N=c.pY,j=c.pathState,U=c.segmentStartX,q=c.linePath,J=c.areaPath,rt=c.linePaths,A=c.areaPaths,O=c.curve,X=c.isRangeStart;this.w;var ot,nt=new $(this.ctx),ct=this.areaBottomY,wt=u==="rangeArea",xt=u==="rangeArea"&&X;switch(O){case"monotoneCubic":var jt=X?L:P;switch(j){case 0:if(jt[m+1]===null)break;j=1;case 1:if(!(wt?k.length===d[v].length:m===d[v].length-2))break;case 2:var ee=X?k:k.slice().reverse(),Nt=X?jt:jt.slice().reverse(),Zt=(ot=Nt,ee.map(function(N1,O1){return[N1,ot[O1]]}).filter(function(N1){return N1[1]!==null})),ze=Zt.length>1?Gn(Zt):Zt,Te=[];wt&&(xt?A=Zt:Te=A.reverse());var Ge=0,Ye=0;if(function(N1,O1){for(var G1=function(I4){var Ai=[],Z2=0;return I4.forEach(function(hd){hd!==null?Z2++:Z2>0&&(Ai.push(Z2),Z2=0)}),Z2>0&&Ai.push(Z2),Ai}(N1),mi=[],ri=0,y2=0;ri4?(y2+="C".concat(Ai[0],", ").concat(Ai[1]),y2+=", ".concat(Ai[2],", ").concat(Ai[3]),y2+=", ".concat(Ai[4],", ").concat(Ai[5])):Z2>2&&(y2+="S".concat(Ai[0],", ").concat(Ai[1]),y2+=", ".concat(Ai[2],", ").concat(Ai[3]))}return y2}(N1),G1=Ye,mi=(Ye+=N1.length)-1;xt?q=nt.move(Zt[G1][0],Zt[G1][1])+O1:wt?q=nt.move(Te[G1][0],Te[G1][1])+nt.line(Zt[G1][0],Zt[G1][1])+O1+nt.line(Te[mi][0],Te[mi][1]):(q=nt.move(Zt[G1][0],Zt[G1][1])+O1,J=q+nt.line(Zt[mi][0],ct)+nt.line(Zt[G1][0],ct)+"z",A.push(J)),rt.push(q)}),wt&&Ge>1&&!xt){var l1=rt.slice(Ge).reverse();rt.splice(Ge),l1.forEach(function(N1){return rt.push(N1)})}j=0}break;case"smooth":var i1=.35*(x-V);if(d[v][m]===null)j=0;else switch(j){case 0:if(U=V,q=xt?nt.move(V,P[m])+nt.line(V,N):nt.move(V,N),J=nt.move(V,N),j=1,m=d[v].length-2&&(xt&&(q+=nt.curve(x,w,x,w,x,D)+nt.move(x,D)),J+=nt.curve(x,w,x,w,x,ct)+nt.line(U,ct)+"z",rt.push(q),A.push(J),j=-1)}}V=x,N=w;break;default:var Lr=function(N1,O1,G1){var mi=[];switch(N1){case"stepline":mi=nt.line(O1,null,"H")+nt.line(null,G1,"V");break;case"linestep":mi=nt.line(null,G1,"V")+nt.line(O1,null,"H");break;case"straight":mi=nt.line(O1,G1)}return mi};if(d[v][m]===null)j=0;else switch(j){case 0:if(U=V,q=xt?nt.move(V,P[m])+nt.line(V,N):nt.move(V,N),J=nt.move(V,N),j=1,m=d[v].length-2&&(xt&&(q+=nt.line(x,D)),J+=nt.line(x,ct)+nt.line(U,ct)+"z",rt.push(q),A.push(J),j=-1)}}V=x,N=w}return{linePaths:rt,areaPaths:A,pX:V,pY:N,pathState:j,segmentStartX:U,linePath:q,areaPath:J}}},{key:"handleNullDataPoints",value:function(c,u,d,v,m){var x=this.w;if(c[d][v]===null&&x.config.markers.showNullDataPoints||c[d].length===1){var w=this.strokeWidth-x.config.markers.strokeWidth/2;w>0||(w=0);var k=this.markers.plotChartMarkers(u,m,v+1,w,!0);k!==null&&this.elPointsMain.add(k)}}}]),Q}();window.TreemapSquared={},window.TreemapSquared.generate=function(){function Q(w,k,L,D){this.xoffset=w,this.yoffset=k,this.height=D,this.width=L,this.shortestEdge=function(){return Math.min(this.height,this.width)},this.getCoordinates=function(P){var V,N=[],j=this.xoffset,U=this.yoffset,q=m(P)/this.height,J=m(P)/this.width;if(this.width>=this.height)for(V=0;V=this.height){var N=P/this.height,j=this.width-N;V=new Q(this.xoffset+N,this.yoffset,j,this.height)}else{var U=P/this.width,q=this.height-U;V=new Q(this.xoffset,this.yoffset+U,this.width,q)}return V}}function c(w,k,L,D,P){D=D===void 0?0:D,P=P===void 0?0:P;var V=u(function(N,j){var U,q=[],J=j/m(N);for(U=0;U=A}(k,V=w[0],P)?(k.push(V),u(w.slice(1),k,L,D)):(N=L.cutArea(m(k),D),D.push(L.getCoordinates(k)),u(w,[],N,D)),D;D.push(L.getCoordinates(k))}function d(w,k){var L=Math.min.apply(Math,w),D=Math.max.apply(Math,w),P=m(w);return Math.max(Math.pow(k,2)*D/Math.pow(P,2),Math.pow(P,2)/(Math.pow(k,2)*L))}function v(w){return w&&w.constructor===Array}function m(w){var k,L=0;for(k=0;kx-v&&L.width<=w-m){var D=k.rotateAroundCenter(c.node);c.node.setAttribute("transform","rotate(-90 ".concat(D.x," ").concat(D.y,") translate(").concat(L.height/3,")"))}}},{key:"truncateLabels",value:function(c,u,d,v,m,x){var w=new $(this.ctx),k=w.getTextRects(c,u).width+this.w.config.stroke.width+5>m-d&&x-v>m-d?x-v:m-d,L=w.getTextBasedOnMaxWidth({text:c,maxWidth:k,fontSize:u});return c.length!==L.length&&k/u<5?"":L}},{key:"animateTreemap",value:function(c,u,d,v){var m=new R(this.ctx);m.animateRect(c,{x:u.x,y:u.y,width:u.width,height:u.height},{x:d.x,y:d.y,width:d.width,height:d.height},v,function(){m.animationCompleted(c)})}}]),Q}(),K0=86400,ca=10/K0,q0=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w,this.timeScaleArray=[],this.utc=this.w.config.xaxis.labels.datetimeUTC}return l(Q,[{key:"calculateTimeScaleTicks",value:function(c,u){var d=this,v=this.w;if(v.globals.allSeriesCollapsed)return v.globals.labels=[],v.globals.timescaleLabels=[],[];var m=new et(this.ctx),x=(u-c)/864e5;this.determineInterval(x),v.globals.disableZoomIn=!1,v.globals.disableZoomOut=!1,x5e4&&(v.globals.disableZoomOut=!0);var w=m.getTimeUnitsfromTimestamp(c,u,this.utc),k=v.globals.gridWidth/x,L=k/24,D=L/60,P=D/60,V=Math.floor(24*x),N=Math.floor(1440*x),j=Math.floor(x*K0),U=Math.floor(x),q=Math.floor(x/30),J=Math.floor(x/365),rt={minMillisecond:w.minMillisecond,minSecond:w.minSecond,minMinute:w.minMinute,minHour:w.minHour,minDate:w.minDate,minMonth:w.minMonth,minYear:w.minYear},A={firstVal:rt,currentMillisecond:rt.minMillisecond,currentSecond:rt.minSecond,currentMinute:rt.minMinute,currentHour:rt.minHour,currentMonthDate:rt.minDate,currentDate:rt.minDate,currentMonth:rt.minMonth,currentYear:rt.minYear,daysWidthOnXAxis:k,hoursWidthOnXAxis:L,minutesWidthOnXAxis:D,secondsWidthOnXAxis:P,numberOfSeconds:j,numberOfMinutes:N,numberOfHours:V,numberOfDays:U,numberOfMonths:q,numberOfYears:J};switch(this.tickInterval){case"years":this.generateYearScale(A);break;case"months":case"half_year":this.generateMonthScale(A);break;case"months_days":case"months_fortnight":case"days":case"week_days":this.generateDayScale(A);break;case"hours":this.generateHourScale(A);break;case"minutes_fives":case"minutes":this.generateMinuteScale(A);break;case"seconds_tens":case"seconds_fives":case"seconds":this.generateSecondScale(A)}var O=this.timeScaleArray.map(function(X){var ot={position:X.position,unit:X.unit,year:X.year,day:X.day?X.day:1,hour:X.hour?X.hour:0,month:X.month+1};return X.unit==="month"?i(i({},ot),{},{day:1,value:X.value+1}):X.unit==="day"||X.unit==="hour"?i(i({},ot),{},{value:X.value}):X.unit==="minute"?i(i({},ot),{},{value:X.value,minute:X.value}):X.unit==="second"?i(i({},ot),{},{value:X.value,minute:X.minute,second:X.second}):X});return O.filter(function(X){var ot=1,nt=Math.ceil(v.globals.gridWidth/120),ct=X.value;v.config.xaxis.tickAmount!==void 0&&(nt=v.config.xaxis.tickAmount),O.length>nt&&(ot=Math.floor(O.length/nt));var wt=!1,xt=!1;switch(d.tickInterval){case"years":X.unit==="year"&&(wt=!0);break;case"half_year":ot=7,X.unit==="year"&&(wt=!0);break;case"months":ot=1,X.unit==="year"&&(wt=!0);break;case"months_fortnight":ot=15,X.unit!=="year"&&X.unit!=="month"||(wt=!0),ct===30&&(xt=!0);break;case"months_days":ot=10,X.unit==="month"&&(wt=!0),ct===30&&(xt=!0);break;case"week_days":ot=8,X.unit==="month"&&(wt=!0);break;case"days":ot=1,X.unit==="month"&&(wt=!0);break;case"hours":X.unit==="day"&&(wt=!0);break;case"minutes_fives":case"seconds_fives":ct%5!=0&&(xt=!0);break;case"seconds_tens":ct%10!=0&&(xt=!0)}if(d.tickInterval==="hours"||d.tickInterval==="minutes_fives"||d.tickInterval==="seconds_tens"||d.tickInterval==="seconds_fives"){if(!xt)return!0}else if((ct%ot==0||wt)&&!xt)return!0})}},{key:"recalcDimensionsBasedOnFormat",value:function(c,u){var d=this.w,v=this.formatDates(c),m=this.removeOverlappingTS(v);d.globals.timescaleLabels=m.slice(),new Pe(this.ctx).plotCoords()}},{key:"determineInterval",value:function(c){var u=24*c,d=60*u;switch(!0){case c/365>5:this.tickInterval="years";break;case c>800:this.tickInterval="half_year";break;case c>180:this.tickInterval="months";break;case c>90:this.tickInterval="months_fortnight";break;case c>60:this.tickInterval="months_days";break;case c>30:this.tickInterval="week_days";break;case c>2:this.tickInterval="days";break;case u>2.4:this.tickInterval="hours";break;case d>15:this.tickInterval="minutes_fives";break;case d>5:this.tickInterval="minutes";break;case d>1:this.tickInterval="seconds_tens";break;case 60*d>20:this.tickInterval="seconds_fives";break;default:this.tickInterval="seconds"}}},{key:"generateYearScale",value:function(c){var u=c.firstVal,d=c.currentMonth,v=c.currentYear,m=c.daysWidthOnXAxis,x=c.numberOfYears,w=u.minYear,k=0,L=new et(this.ctx),D="year";if(u.minDate>1||u.minMonth>0){var P=L.determineRemainingDaysOfYear(u.minYear,u.minMonth,u.minDate);k=(L.determineDaysOfYear(u.minYear)-P+1)*m,w=u.minYear+1,this.timeScaleArray.push({position:k,value:w,unit:D,year:w,month:E.monthMod(d+1)})}else u.minDate===1&&u.minMonth===0&&this.timeScaleArray.push({position:k,value:w,unit:D,year:v,month:E.monthMod(d+1)});for(var V=w,N=k,j=0;j1){L=(D.determineDaysOfMonths(v+1,u.minYear)-d+1)*x,k=E.monthMod(v+1);var N=m+V,j=E.monthMod(k),U=k;k===0&&(P="year",U=N,j=1,N+=V+=1),this.timeScaleArray.push({position:L,value:U,unit:P,year:N,month:j})}else this.timeScaleArray.push({position:L,value:k,unit:P,year:m,month:E.monthMod(v)});for(var q=k+1,J=L,rt=0,A=1;rtw.determineDaysOfMonths(O+1,X)&&(D=1,k="month",N=O+=1),O},V=(24-u.minHour)*m,N=L,j=P(D,d,v);u.minHour===0&&u.minDate===1?(V=0,N=E.monthMod(u.minMonth),k="month",D=u.minDate):u.minDate!==1&&u.minHour===0&&u.minMinute===0&&(V=0,L=u.minDate,N=L,j=P(D=L,d,v)),this.timeScaleArray.push({position:V,value:N,unit:k,year:this._getYear(v,j,0),month:E.monthMod(j),day:D});for(var U=V,q=0;qk.determineDaysOfMonths(nt+1,m)&&(q=1,nt+=1),{month:nt,date:q}},P=function(ot,nt){return ot>k.determineDaysOfMonths(nt+1,m)?nt+=1:nt},V=60-(u.minMinute+u.minSecond/60),N=V*x,j=u.minHour+1,U=j;V===60&&(N=0,U=j=u.minHour);var q=d;U>=24&&(U=0,q+=1,L="day");var J=D(q,v).month;J=P(q,J),this.timeScaleArray.push({position:N,value:j,unit:L,day:q,hour:U,year:m,month:E.monthMod(J)}),U++;for(var rt=N,A=0;A=24&&(U=0,L="day",J=D(q+=1,J).month,J=P(q,J));var O=this._getYear(m,J,0);rt=60*x+rt;var X=U===0?q:U;this.timeScaleArray.push({position:rt,value:X,unit:L,hour:U,day:q,year:O,month:E.monthMod(J)}),U++}}},{key:"generateMinuteScale",value:function(c){for(var u=c.currentMillisecond,d=c.currentSecond,v=c.currentMinute,m=c.currentHour,x=c.currentDate,w=c.currentMonth,k=c.currentYear,L=c.minutesWidthOnXAxis,D=c.secondsWidthOnXAxis,P=c.numberOfMinutes,V=v+1,N=x,j=w,U=k,q=m,J=(60-d-u/1e3)*D,rt=0;rt=60&&(V=0,(q+=1)===24&&(q=0)),this.timeScaleArray.push({position:J,value:V,unit:"minute",hour:q,minute:V,day:N,year:this._getYear(U,j,0),month:E.monthMod(j)}),J+=L,V++}},{key:"generateSecondScale",value:function(c){for(var u=c.currentMillisecond,d=c.currentSecond,v=c.currentMinute,m=c.currentHour,x=c.currentDate,w=c.currentMonth,k=c.currentYear,L=c.secondsWidthOnXAxis,D=c.numberOfSeconds,P=d+1,V=v,N=x,j=w,U=k,q=m,J=(1e3-u)/1e3*L,rt=0;rt=60&&(P=0,++V>=60&&(V=0,++q===24&&(q=0))),this.timeScaleArray.push({position:J,value:P,unit:"second",hour:q,minute:V,second:P,day:N,year:this._getYear(U,j,0),month:E.monthMod(j)}),J+=L,P++}},{key:"createRawDateString",value:function(c,u){var d=c.year;return c.month===0&&(c.month=1),d+="-"+("0"+c.month.toString()).slice(-2),c.unit==="day"?d+=c.unit==="day"?"-"+("0"+u).slice(-2):"-01":d+="-"+("0"+(c.day?c.day:"1")).slice(-2),c.unit==="hour"?d+=c.unit==="hour"?"T"+("0"+u).slice(-2):"T00":d+="T"+("0"+(c.hour?c.hour:"0")).slice(-2),c.unit==="minute"?d+=":"+("0"+u).slice(-2):d+=":"+(c.minute?("0"+c.minute).slice(-2):"00"),c.unit==="second"?d+=":"+("0"+u).slice(-2):d+=":00",this.utc&&(d+=".000Z"),d}},{key:"formatDates",value:function(c){var u=this,d=this.w;return c.map(function(v){var m=v.value.toString(),x=new et(u.ctx),w=u.createRawDateString(v,m),k=x.getDate(x.parseDate(w));if(u.utc||(k=x.getDate(x.parseDateWithTimezone(w))),d.config.xaxis.labels.format===void 0){var L="dd MMM",D=d.config.xaxis.labels.datetimeFormatter;v.unit==="year"&&(L=D.year),v.unit==="month"&&(L=D.month),v.unit==="day"&&(L=D.day),v.unit==="hour"&&(L=D.hour),v.unit==="minute"&&(L=D.minute),v.unit==="second"&&(L=D.second),m=x.formatDate(k,L)}else m=x.formatDate(k,d.config.xaxis.labels.format);return{dateString:w,position:v.position,value:m,unit:v.unit,year:v.year,month:v.month}})}},{key:"removeOverlappingTS",value:function(c){var u,d=this,v=new $(this.ctx),m=!1;c.length>0&&c[0].value&&c.every(function(k){return k.value.length===c[0].value.length})&&(m=!0,u=v.getTextRects(c[0].value).width);var x=0,w=c.map(function(k,L){if(L>0&&d.w.config.xaxis.labels.hideOverlappingLabels){var D=m?u:v.getTextRects(c[x].value).width,P=c[x].position;return k.position>P+D+10?(x=L,k):null}return k});return w=w.filter(function(k){return k!==null})}},{key:"_getYear",value:function(c,u,d){return c+Math.floor(u/12)+d}}]),Q}(),r1=function(){function Q(c,u){a(this,Q),this.ctx=u,this.w=u.w,this.el=c}return l(Q,[{key:"setupElements",value:function(){var c=this.w.globals,u=this.w.config,d=u.chart.type;c.axisCharts=["line","area","bar","rangeBar","rangeArea","candlestick","boxPlot","scatter","bubble","radar","heatmap","treemap"].indexOf(d)>-1,c.xyCharts=["line","area","bar","rangeBar","rangeArea","candlestick","boxPlot","scatter","bubble"].indexOf(d)>-1,c.isBarHorizontal=(u.chart.type==="bar"||u.chart.type==="rangeBar"||u.chart.type==="boxPlot")&&u.plotOptions.bar.horizontal,c.chartClass=".apexcharts"+c.chartID,c.dom.baseEl=this.el,c.dom.elWrap=document.createElement("div"),$.setAttrs(c.dom.elWrap,{id:c.chartClass.substring(1),class:"apexcharts-canvas "+c.chartClass.substring(1)}),this.el.appendChild(c.dom.elWrap),c.dom.Paper=new window.SVG.Doc(c.dom.elWrap),c.dom.Paper.attr({class:"apexcharts-svg","xmlns:data":"ApexChartsNS",transform:"translate(".concat(u.chart.offsetX,", ").concat(u.chart.offsetY,")")}),c.dom.Paper.node.style.background=u.theme.mode!=="dark"||u.chart.background?u.theme.mode!=="light"||u.chart.background?u.chart.background:"#fff":"#424242",this.setSVGDimensions(),c.dom.elLegendForeign=document.createElementNS(c.SVGNS,"foreignObject"),$.setAttrs(c.dom.elLegendForeign,{x:0,y:0,width:c.svgWidth,height:c.svgHeight}),c.dom.elLegendWrap=document.createElement("div"),c.dom.elLegendWrap.classList.add("apexcharts-legend"),c.dom.elLegendWrap.setAttribute("xmlns","http://www.w3.org/1999/xhtml"),c.dom.elLegendForeign.appendChild(c.dom.elLegendWrap),c.dom.Paper.node.appendChild(c.dom.elLegendForeign),c.dom.elGraphical=c.dom.Paper.group().attr({class:"apexcharts-inner apexcharts-graphical"}),c.dom.elDefs=c.dom.Paper.defs(),c.dom.Paper.add(c.dom.elGraphical),c.dom.elGraphical.add(c.dom.elDefs)}},{key:"plotChartType",value:function(c,u){var d=this.w,v=d.config,m=d.globals,x={series:[],i:[]},w={series:[],i:[]},k={series:[],i:[]},L={series:[],i:[]},D={series:[],i:[]},P={series:[],i:[]},V={series:[],i:[]},N={series:[],i:[]},j={series:[],seriesRangeEnd:[],i:[]},U=v.chart.type!==void 0?v.chart.type:"line",q=null,J=0;m.series.forEach(function(Nt,Zt){var ze=c[Zt].type||U;switch(ze){case"column":case"bar":D.series.push(Nt),D.i.push(Zt),d.globals.columnSeries=D;break;case"area":w.series.push(Nt),w.i.push(Zt);break;case"line":x.series.push(Nt),x.i.push(Zt);break;case"scatter":k.series.push(Nt),k.i.push(Zt);break;case"bubble":L.series.push(Nt),L.i.push(Zt);break;case"candlestick":P.series.push(Nt),P.i.push(Zt);break;case"boxPlot":V.series.push(Nt),V.i.push(Zt);break;case"rangeBar":N.series.push(Nt),N.i.push(Zt);break;case"rangeArea":j.series.push(m.seriesRangeStart[Zt]),j.seriesRangeEnd.push(m.seriesRangeEnd[Zt]),j.i.push(Zt);break;case"heatmap":case"treemap":case"pie":case"donut":case"polarArea":case"radialBar":case"radar":q=ze;break;default:console.warn("You have specified an unrecognized series type (",ze,").")}U!==ze&&ze!=="scatter"&&J++}),J>0&&(q!==null&&console.warn("Chart or series type ",q," can not appear with other chart or series types."),D.series.length>0&&v.plotOptions.bar.horizontal&&(J-=D.length,D={series:[],i:[]},d.globals.columnSeries={series:[],i:[]},console.warn("Horizontal bars are not supported in a mixed/combo chart. Please turn off `plotOptions.bar.horizontal`"))),m.comboCharts||(m.comboCharts=J>0);var rt=new ds(this.ctx,u),A=new He(this.ctx,u);this.ctx.pie=new h1(this.ctx);var O=new Z1(this.ctx);this.ctx.rangeBar=new zr(this.ctx,u);var X=new M1(this.ctx),ot=[];if(m.comboCharts){var nt,ct,wt=new G(this.ctx);if(w.series.length>0&&(nt=ot).push.apply(nt,I(wt.drawSeriesByGroup(w,m.areaGroups,"area",rt))),D.series.length>0)if(d.config.chart.stacked){var xt=new Ve(this.ctx,u);ot.push(xt.draw(D.series,D.i))}else this.ctx.bar=new te(this.ctx,u),ot.push(this.ctx.bar.draw(D.series,D.i));if(j.series.length>0&&ot.push(rt.draw(j.series,"rangeArea",j.i,j.seriesRangeEnd)),x.series.length>0&&(ct=ot).push.apply(ct,I(wt.drawSeriesByGroup(x,m.lineGroups,"line",rt))),P.series.length>0&&ot.push(A.draw(P.series,"candlestick",P.i)),V.series.length>0&&ot.push(A.draw(V.series,"boxPlot",V.i)),N.series.length>0&&ot.push(this.ctx.rangeBar.draw(N.series,N.i)),k.series.length>0){var jt=new ds(this.ctx,u,!0);ot.push(jt.draw(k.series,"scatter",k.i))}if(L.series.length>0){var ee=new ds(this.ctx,u,!0);ot.push(ee.draw(L.series,"bubble",L.i))}}else switch(v.chart.type){case"line":ot=rt.draw(m.series,"line");break;case"area":ot=rt.draw(m.series,"area");break;case"bar":v.chart.stacked?ot=new Ve(this.ctx,u).draw(m.series):(this.ctx.bar=new te(this.ctx,u),ot=this.ctx.bar.draw(m.series));break;case"candlestick":ot=new He(this.ctx,u).draw(m.series,"candlestick");break;case"boxPlot":ot=new He(this.ctx,u).draw(m.series,v.chart.type);break;case"rangeBar":ot=this.ctx.rangeBar.draw(m.series);break;case"rangeArea":ot=rt.draw(m.seriesRangeStart,"rangeArea",void 0,m.seriesRangeEnd);break;case"heatmap":ot=new Le(this.ctx,u).draw(m.series);break;case"treemap":ot=new f6(this.ctx,u).draw(m.series);break;case"pie":case"donut":case"polarArea":ot=this.ctx.pie.draw(m.series);break;case"radialBar":ot=O.draw(m.series);break;case"radar":ot=X.draw(m.series);break;default:ot=rt.draw(m.series)}return ot}},{key:"setSVGDimensions",value:function(){var c=this.w.globals,u=this.w.config;u.chart.width||(u.chart.width="100%"),u.chart.height||(u.chart.height="auto"),c.svgWidth=u.chart.width,c.svgHeight=u.chart.height;var d=E.getDimensions(this.el),v=u.chart.width.toString().split(/[0-9]+/g).pop();v==="%"?E.isNumber(d[0])&&(d[0].width===0&&(d=E.getDimensions(this.el.parentNode)),c.svgWidth=d[0]*parseInt(u.chart.width,10)/100):v!=="px"&&v!==""||(c.svgWidth=parseInt(u.chart.width,10));var m=String(u.chart.height).toString().split(/[0-9]+/g).pop();if(c.svgHeight!=="auto"&&c.svgHeight!=="")if(m==="%"){var x=E.getDimensions(this.el.parentNode);c.svgHeight=x[1]*parseInt(u.chart.height,10)/100}else c.svgHeight=parseInt(u.chart.height,10);else c.axisCharts?c.svgHeight=c.svgWidth/1.61:c.svgHeight=c.svgWidth/1.2;if(c.svgWidth<0&&(c.svgWidth=0),c.svgHeight<0&&(c.svgHeight=0),$.setAttrs(c.dom.Paper.node,{width:c.svgWidth,height:c.svgHeight}),m!=="%"){var w=u.chart.sparkline.enabled?0:c.axisCharts?u.chart.parentHeightOffset:0;c.dom.Paper.node.parentNode.parentNode.style.minHeight=c.svgHeight+w+"px"}c.dom.elWrap.style.width=c.svgWidth+"px",c.dom.elWrap.style.height=c.svgHeight+"px"}},{key:"shiftGraphPosition",value:function(){var c=this.w.globals,u=c.translateY,d={transform:"translate("+c.translateX+", "+u+")"};$.setAttrs(c.dom.elGraphical.node,d)}},{key:"resizeNonAxisCharts",value:function(){var c=this.w,u=c.globals,d=0,v=c.config.chart.sparkline.enabled?1:15;v+=c.config.grid.padding.bottom,c.config.legend.position!=="top"&&c.config.legend.position!=="bottom"||!c.config.legend.show||c.config.legend.floating||(d=new st(this.ctx).legendHelpers.getLegendDimensions().clwh+10);var m=c.globals.dom.baseEl.querySelector(".apexcharts-radialbar, .apexcharts-pie"),x=2.05*c.globals.radialSize;if(m&&!c.config.chart.sparkline.enabled&&c.config.plotOptions.radialBar.startAngle!==0){var w=E.getBoundingClientRect(m);x=w.bottom;var k=w.bottom-w.top;x=Math.max(2.05*c.globals.radialSize,k)}var L=x+u.translateY+d+v;u.dom.elLegendForeign&&u.dom.elLegendForeign.setAttribute("height",L),c.config.chart.height&&String(c.config.chart.height).indexOf("%")>0||(u.dom.elWrap.style.height=L+"px",$.setAttrs(u.dom.Paper.node,{height:L}),u.dom.Paper.node.parentNode.parentNode.style.minHeight=L+"px")}},{key:"coreCalculations",value:function(){new we(this.ctx).init()}},{key:"resetGlobals",value:function(){var c=this,u=function(){return c.w.config.series.map(function(m){return[]})},d=new bt,v=this.w.globals;d.initGlobalVars(v),v.seriesXvalues=u(),v.seriesYvalues=u()}},{key:"isMultipleY",value:function(){if(this.w.config.yaxis.constructor===Array&&this.w.config.yaxis.length>1)return this.w.globals.isMultipleYAxis=!0,!0}},{key:"xySettings",value:function(){var c=null,u=this.w;if(u.globals.axisCharts){if(u.config.xaxis.crosshairs.position==="back"&&new fe(this.ctx).drawXCrosshairs(),u.config.yaxis[0].crosshairs.position==="back"&&new fe(this.ctx).drawYCrosshairs(),u.config.xaxis.type==="datetime"&&u.config.xaxis.labels.formatter===void 0){this.ctx.timeScale=new q0(this.ctx);var d=[];isFinite(u.globals.minX)&&isFinite(u.globals.maxX)&&!u.globals.isBarHorizontal?d=this.ctx.timeScale.calculateTimeScaleTicks(u.globals.minX,u.globals.maxX):u.globals.isBarHorizontal&&(d=this.ctx.timeScale.calculateTimeScaleTicks(u.globals.minY,u.globals.maxY)),this.ctx.timeScale.recalcDimensionsBasedOnFormat(d)}c=new G(this.ctx).getCalculatedRatios()}return c}},{key:"updateSourceChart",value:function(c){this.ctx.w.globals.selection=void 0,this.ctx.updateHelpers._updateOptions({chart:{selection:{xaxis:{min:c.w.globals.minX,max:c.w.globals.maxX}}}},!1,!1)}},{key:"setupBrushHandler",value:function(){var c=this,u=this.w;if(u.config.chart.brush.enabled&&typeof u.config.chart.events.selection!="function"){var d=Array.isArray(u.config.chart.brush.targets)?u.config.chart.brush.targets:[u.config.chart.brush.target];d.forEach(function(v){var m=ApexCharts.getChartByID(v);m.w.globals.brushSource=c.ctx,typeof m.w.config.chart.events.zoomed!="function"&&(m.w.config.chart.events.zoomed=function(){c.updateSourceChart(m)}),typeof m.w.config.chart.events.scrolled!="function"&&(m.w.config.chart.events.scrolled=function(){c.updateSourceChart(m)})}),u.config.chart.events.selection=function(v,m){d.forEach(function(x){ApexCharts.getChartByID(x).ctx.updateHelpers._updateOptions({xaxis:{min:m.xaxis.min,max:m.xaxis.max}},!1,!1,!1,!1)})}}}}]),Q}(),s1=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w}return l(Q,[{key:"_updateOptions",value:function(c){var u=this,d=arguments.length>1&&arguments[1]!==void 0&&arguments[1],v=!(arguments.length>2&&arguments[2]!==void 0)||arguments[2],m=!(arguments.length>3&&arguments[3]!==void 0)||arguments[3],x=arguments.length>4&&arguments[4]!==void 0&&arguments[4];return new Promise(function(w){var k=[u.ctx];m&&(k=u.ctx.getSyncedCharts()),u.ctx.w.globals.isExecCalled&&(k=[u.ctx],u.ctx.w.globals.isExecCalled=!1),k.forEach(function(L,D){var P=L.w;if(P.globals.shouldAnimate=v,d||(P.globals.resized=!0,P.globals.dataChanged=!0,v&&L.series.getPreviousPaths()),c&&o(c)==="object"&&(L.config=new _t(c),c=G.extendArrayProps(L.config,c,P),L.w.globals.chartID!==u.ctx.w.globals.chartID&&delete c.series,P.config=E.extend(P.config,c),x&&(P.globals.lastXAxis=c.xaxis?E.clone(c.xaxis):[],P.globals.lastYAxis=c.yaxis?E.clone(c.yaxis):[],P.globals.initialConfig=E.extend({},P.config),P.globals.initialSeries=E.clone(P.config.series),c.series))){for(var V=0;V2&&arguments[2]!==void 0&&arguments[2];return new Promise(function(m){var x,w=d.w;return w.globals.shouldAnimate=u,w.globals.dataChanged=!0,u&&d.ctx.series.getPreviousPaths(),w.globals.axisCharts?((x=c.map(function(k,L){return d._extendSeries(k,L)})).length===0&&(x=[{data:[]}]),w.config.series=x):w.config.series=c.slice(),v&&(w.globals.initialConfig.series=E.clone(w.config.series),w.globals.initialSeries=E.clone(w.config.series)),d.ctx.update().then(function(){m(d.ctx)})})}},{key:"_extendSeries",value:function(c,u){var d=this.w,v=d.config.series[u];return i(i({},d.config.series[u]),{},{name:c.name?c.name:v==null?void 0:v.name,color:c.color?c.color:v==null?void 0:v.color,type:c.type?c.type:v==null?void 0:v.type,group:c.group?c.group:v==null?void 0:v.group,data:c.data?c.data:v==null?void 0:v.data,zIndex:c.zIndex!==void 0?c.zIndex:u})}},{key:"toggleDataPointSelection",value:function(c,u){var d=this.w,v=null,m=".apexcharts-series[data\\:realIndex='".concat(c,"']");return d.globals.axisCharts?v=d.globals.dom.Paper.select("".concat(m," path[j='").concat(u,"'], ").concat(m," circle[j='").concat(u,"'], ").concat(m," rect[j='").concat(u,"']")).members[0]:u===void 0&&(v=d.globals.dom.Paper.select("".concat(m," path[j='").concat(c,"']")).members[0],d.config.chart.type!=="pie"&&d.config.chart.type!=="polarArea"&&d.config.chart.type!=="donut"||this.ctx.pie.pieClicked(c)),v?(new $(this.ctx).pathMouseDown(v,null),v.node?v.node:null):(console.warn("toggleDataPointSelection: Element not found"),null)}},{key:"forceXAxisUpdate",value:function(c){var u=this.w;if(["min","max"].forEach(function(v){c.xaxis[v]!==void 0&&(u.config.xaxis[v]=c.xaxis[v],u.globals.lastXAxis[v]=c.xaxis[v])}),c.xaxis.categories&&c.xaxis.categories.length&&(u.config.xaxis.categories=c.xaxis.categories),u.config.xaxis.convertedCatToNumeric){var d=new kt(c);c=d.convertCatToNumericXaxis(c,this.ctx)}return c}},{key:"forceYAxisUpdate",value:function(c){return c.chart&&c.chart.stacked&&c.chart.stackType==="100%"&&(Array.isArray(c.yaxis)?c.yaxis.forEach(function(u,d){c.yaxis[d].min=0,c.yaxis[d].max=100}):(c.yaxis.min=0,c.yaxis.max=100)),c}},{key:"revertDefaultAxisMinMax",value:function(c){var u=this,d=this.w,v=d.globals.lastXAxis,m=d.globals.lastYAxis;c&&c.xaxis&&(v=c.xaxis),c&&c.yaxis&&(m=c.yaxis),d.config.xaxis.min=v.min,d.config.xaxis.max=v.max;var x=function(w){m[w]!==void 0&&(d.config.yaxis[w].min=m[w].min,d.config.yaxis[w].max=m[w].max)};d.config.yaxis.map(function(w,k){d.globals.zoomed||m[k]!==void 0?x(k):u.ctx.opts.yaxis[k]!==void 0&&(w.min=u.ctx.opts.yaxis[k].min,w.max=u.ctx.opts.yaxis[k].max)})}}]),Q}();m2=typeof window<"u"?window:void 0,fs=function(Q,c){var u=(this!==void 0?this:Q).SVG=function(A){if(u.supported)return A=new u.Doc(A),u.parser.draw||u.prepare(),A};if(u.ns="http://www.w3.org/2000/svg",u.xmlns="http://www.w3.org/2000/xmlns/",u.xlink="http://www.w3.org/1999/xlink",u.svgjs="http://svgjs.dev",u.supported=!0,!u.supported)return!1;u.did=1e3,u.eid=function(A){return"Svgjs"+D(A)+u.did++},u.create=function(A){var O=c.createElementNS(this.ns,A);return O.setAttribute("id",this.eid(A)),O},u.extend=function(){var A,O;O=(A=[].slice.call(arguments)).pop();for(var X=A.length-1;X>=0;X--)if(A[X])for(var ot in O)A[X].prototype[ot]=O[ot];u.Set&&u.Set.inherit&&u.Set.inherit()},u.invent=function(A){var O=typeof A.create=="function"?A.create:function(){this.constructor.call(this,u.create(A.create))};return A.inherit&&(O.prototype=new A.inherit),A.extend&&u.extend(O,A.extend),A.construct&&u.extend(A.parent||u.Container,A.construct),O},u.adopt=function(A){return A?A.instance?A.instance:((O=A.nodeName=="svg"?A.parentNode instanceof Q.SVGElement?new u.Nested:new u.Doc:A.nodeName=="linearGradient"?new u.Gradient("linear"):A.nodeName=="radialGradient"?new u.Gradient("radial"):u[D(A.nodeName)]?new u[D(A.nodeName)]:new u.Element(A)).type=A.nodeName,O.node=A,A.instance=O,O instanceof u.Doc&&O.namespace().defs(),O.setData(JSON.parse(A.getAttribute("svgjs:data"))||{}),O):null;var O},u.prepare=function(){var A=c.getElementsByTagName("body")[0],O=(A?new u.Doc(A):u.adopt(c.documentElement).nested()).size(2,0);u.parser={body:A||c.documentElement,draw:O.style("opacity:0;position:absolute;left:-100%;top:-100%;overflow:hidden").node,poly:O.polyline().node,path:O.path().node,native:u.create("svg")}},u.parser={native:u.create("svg")},c.addEventListener("DOMContentLoaded",function(){u.parser.draw||u.prepare()},!1),u.regex={numberAndUnit:/^([+-]?(\d+(\.\d*)?|\.\d+)(e[+-]?\d+)?)([a-z%]*)$/i,hex:/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i,rgb:/rgb\((\d+),(\d+),(\d+)\)/,reference:/#([a-z0-9\-_]+)/i,transforms:/\)\s*,?\s*/,whitespace:/\s/g,isHex:/^#[a-f0-9]{3,6}$/i,isRgb:/^rgb\(/,isCss:/[^:]+:[^;]+;?/,isBlank:/^(\s+)?$/,isNumber:/^[+-]?(\d+(\.\d*)?|\.\d+)(e[+-]?\d+)?$/i,isPercent:/^-?[\d\.]+%$/,isImage:/\.(jpg|jpeg|png|gif|svg)(\?[^=]+.*)?/i,delimiter:/[\s,]+/,hyphen:/([^e])\-/gi,pathLetters:/[MLHVCSQTAZ]/gi,isPathLetter:/[MLHVCSQTAZ]/i,numbersWithDots:/((\d?\.\d+(?:e[+-]?\d+)?)((?:\.\d+(?:e[+-]?\d+)?)+))+/gi,dots:/\./g},u.utils={map:function(A,O){for(var X=A.length,ot=[],nt=0;nt1?1:A,new u.Color({r:~~(this.r+(this.destination.r-this.r)*A),g:~~(this.g+(this.destination.g-this.g)*A),b:~~(this.b+(this.destination.b-this.b)*A)})):this}}),u.Color.test=function(A){return A+="",u.regex.isHex.test(A)||u.regex.isRgb.test(A)},u.Color.isRgb=function(A){return A&&typeof A.r=="number"&&typeof A.g=="number"&&typeof A.b=="number"},u.Color.isColor=function(A){return u.Color.isRgb(A)||u.Color.test(A)},u.Array=function(A,O){(A=(A||[]).valueOf()).length==0&&O&&(A=O.valueOf()),this.value=this.parse(A)},u.extend(u.Array,{toString:function(){return this.value.join(" ")},valueOf:function(){return this.value},parse:function(A){return A=A.valueOf(),Array.isArray(A)?A:this.split(A)}}),u.PointArray=function(A,O){u.Array.call(this,A,O||[[0,0]])},u.PointArray.prototype=new u.Array,u.PointArray.prototype.constructor=u.PointArray;for(var d={M:function(A,O,X){return O.x=X.x=A[0],O.y=X.y=A[1],["M",O.x,O.y]},L:function(A,O){return O.x=A[0],O.y=A[1],["L",A[0],A[1]]},H:function(A,O){return O.x=A[0],["H",A[0]]},V:function(A,O){return O.y=A[0],["V",A[0]]},C:function(A,O){return O.x=A[4],O.y=A[5],["C",A[0],A[1],A[2],A[3],A[4],A[5]]},Q:function(A,O){return O.x=A[2],O.y=A[3],["Q",A[0],A[1],A[2],A[3]]},S:function(A,O){return O.x=A[2],O.y=A[3],["S",A[0],A[1],A[2],A[3]]},Z:function(A,O,X){return O.x=X.x,O.y=X.y,["Z"]}},v="mlhvqtcsaz".split(""),m=0,x=v.length;mwt);return ot},bbox:function(){return u.parser.draw||u.prepare(),u.parser.path.setAttribute("d",this.toString()),u.parser.path.getBBox()}}),u.Number=u.invent({create:function(A,O){this.value=0,this.unit=O||"",typeof A=="number"?this.value=isNaN(A)?0:isFinite(A)?A:A<0?-34e37:34e37:typeof A=="string"?(O=A.match(u.regex.numberAndUnit))&&(this.value=parseFloat(O[1]),O[5]=="%"?this.value/=100:O[5]=="s"&&(this.value*=1e3),this.unit=O[5]):A instanceof u.Number&&(this.value=A.valueOf(),this.unit=A.unit)},extend:{toString:function(){return(this.unit=="%"?~~(1e8*this.value)/1e6:this.unit=="s"?this.value/1e3:this.value)+this.unit},toJSON:function(){return this.toString()},valueOf:function(){return this.value},plus:function(A){return A=new u.Number(A),new u.Number(this+A,this.unit||A.unit)},minus:function(A){return A=new u.Number(A),new u.Number(this-A,this.unit||A.unit)},times:function(A){return A=new u.Number(A),new u.Number(this*A,this.unit||A.unit)},divide:function(A){return A=new u.Number(A),new u.Number(this/A,this.unit||A.unit)},to:function(A){var O=new u.Number(this);return typeof A=="string"&&(O.unit=A),O},morph:function(A){return this.destination=new u.Number(A),A.relative&&(this.destination.value+=this.value),this},at:function(A){return this.destination?new u.Number(this.destination).minus(this).times(A).plus(this):this}}}),u.Element=u.invent({create:function(A){this._stroke=u.defaults.attrs.stroke,this._event=null,this.dom={},(this.node=A)&&(this.type=A.nodeName,this.node.instance=this,this._stroke=A.getAttribute("stroke")||this._stroke)},extend:{x:function(A){return this.attr("x",A)},y:function(A){return this.attr("y",A)},cx:function(A){return A==null?this.x()+this.width()/2:this.x(A-this.width()/2)},cy:function(A){return A==null?this.y()+this.height()/2:this.y(A-this.height()/2)},move:function(A,O){return this.x(A).y(O)},center:function(A,O){return this.cx(A).cy(O)},width:function(A){return this.attr("width",A)},height:function(A){return this.attr("height",A)},size:function(A,O){var X=V(this,A,O);return this.width(new u.Number(X.width)).height(new u.Number(X.height))},clone:function(A){this.writeDataToDom();var O=U(this.node.cloneNode(!0));return A?A.add(O):this.after(O),O},remove:function(){return this.parent()&&this.parent().removeElement(this),this},replace:function(A){return this.after(A).remove(),A},addTo:function(A){return A.put(this)},putIn:function(A){return A.add(this)},id:function(A){return this.attr("id",A)},show:function(){return this.style("display","")},hide:function(){return this.style("display","none")},visible:function(){return this.style("display")!="none"},toString:function(){return this.attr("id")},classes:function(){var A=this.attr("class");return A==null?[]:A.trim().split(u.regex.delimiter)},hasClass:function(A){return this.classes().indexOf(A)!=-1},addClass:function(A){if(!this.hasClass(A)){var O=this.classes();O.push(A),this.attr("class",O.join(" "))}return this},removeClass:function(A){return this.hasClass(A)&&this.attr("class",this.classes().filter(function(O){return O!=A}).join(" ")),this},toggleClass:function(A){return this.hasClass(A)?this.removeClass(A):this.addClass(A)},reference:function(A){return u.get(this.attr(A))},parent:function(A){var O=this;if(!O.node.parentNode)return null;if(O=u.adopt(O.node.parentNode),!A)return O;for(;O&&O.node instanceof Q.SVGElement;){if(typeof A=="string"?O.matches(A):O instanceof A)return O;if(!O.node.parentNode||O.node.parentNode.nodeName=="#document")return null;O=u.adopt(O.node.parentNode)}},doc:function(){return this instanceof u.Doc?this:this.parent(u.Doc)},parents:function(A){var O=[],X=this;do{if(!(X=X.parent(A))||!X.node)break;O.push(X)}while(X.parent);return O},matches:function(A){return function(O,X){return(O.matches||O.matchesSelector||O.msMatchesSelector||O.mozMatchesSelector||O.webkitMatchesSelector||O.oMatchesSelector).call(O,X)}(this.node,A)},native:function(){return this.node},svg:function(A){var O=c.createElementNS("http://www.w3.org/2000/svg","svg");if(!(A&&this instanceof u.Parent))return O.appendChild(A=c.createElementNS("http://www.w3.org/2000/svg","svg")),this.writeDataToDom(),A.appendChild(this.node.cloneNode(!0)),O.innerHTML.replace(/^/,"").replace(/<\/svg>$/,"");O.innerHTML=""+A.replace(/\n/,"").replace(/<([\w:-]+)([^<]+?)\/>/g,"<$1$2>")+"";for(var X=0,ot=O.firstChild.childNodes.length;X":function(A){return-Math.cos(A*Math.PI)/2+.5},">":function(A){return Math.sin(A*Math.PI/2)},"<":function(A){return 1-Math.cos(A*Math.PI/2)}},u.morph=function(A){return function(O,X){return new u.MorphObj(O,X).at(A)}},u.Situation=u.invent({create:function(A){this.init=!1,this.reversed=!1,this.reversing=!1,this.duration=new u.Number(A.duration).valueOf(),this.delay=new u.Number(A.delay).valueOf(),this.start=+new Date+this.delay,this.finish=this.start+this.duration,this.ease=A.ease,this.loop=0,this.loops=!1,this.animations={},this.attrs={},this.styles={},this.transforms=[],this.once={}}}),u.FX=u.invent({create:function(A){this._target=A,this.situations=[],this.active=!1,this.situation=null,this.paused=!1,this.lastPos=0,this.pos=0,this.absPos=0,this._speed=1},extend:{animate:function(A,O,X){o(A)==="object"&&(O=A.ease,X=A.delay,A=A.duration);var ot=new u.Situation({duration:A||1e3,delay:X||0,ease:u.easing[O||"-"]||O});return this.queue(ot),this},target:function(A){return A&&A instanceof u.Element?(this._target=A,this):this._target},timeToAbsPos:function(A){return(A-this.situation.start)/(this.situation.duration/this._speed)},absPosToTime:function(A){return this.situation.duration/this._speed*A+this.situation.start},startAnimFrame:function(){this.stopAnimFrame(),this.animationFrame=Q.requestAnimationFrame((function(){this.step()}).bind(this))},stopAnimFrame:function(){Q.cancelAnimationFrame(this.animationFrame)},start:function(){return!this.active&&this.situation&&(this.active=!0,this.startCurrent()),this},startCurrent:function(){return this.situation.start=+new Date+this.situation.delay/this._speed,this.situation.finish=this.situation.start+this.situation.duration/this._speed,this.initAnimations().step()},queue:function(A){return(typeof A=="function"||A instanceof u.Situation)&&this.situations.push(A),this.situation||(this.situation=this.situations.shift()),this},dequeue:function(){return this.stop(),this.situation=this.situations.shift(),this.situation&&(this.situation instanceof u.Situation?this.start():this.situation.call(this)),this},initAnimations:function(){var A,O=this.situation;if(O.init)return this;for(var X in O.animations){A=this.target()[X](),Array.isArray(A)||(A=[A]),Array.isArray(O.animations[X])||(O.animations[X]=[O.animations[X]]);for(var ot=A.length;ot--;)O.animations[X][ot]instanceof u.Number&&(A[ot]=new u.Number(A[ot])),O.animations[X][ot]=A[ot].morph(O.animations[X][ot])}for(var X in O.attrs)O.attrs[X]=new u.MorphObj(this.target().attr(X),O.attrs[X]);for(var X in O.styles)O.styles[X]=new u.MorphObj(this.target().style(X),O.styles[X]);return O.initialTransformation=this.target().matrixify(),O.init=!0,this},clearQueue:function(){return this.situations=[],this},clearCurrent:function(){return this.situation=null,this},stop:function(A,O){var X=this.active;return this.active=!1,O&&this.clearQueue(),A&&this.situation&&(!X&&this.startCurrent(),this.atEnd()),this.stopAnimFrame(),this.clearCurrent()},after:function(A){var O=this.last();return this.target().on("finished.fx",function X(ot){ot.detail.situation==O&&(A.call(this,O),this.off("finished.fx",X))}),this._callStart()},during:function(A){var O=this.last(),X=function(ot){ot.detail.situation==O&&A.call(this,ot.detail.pos,u.morph(ot.detail.pos),ot.detail.eased,O)};return this.target().off("during.fx",X).on("during.fx",X),this.after(function(){this.off("during.fx",X)}),this._callStart()},afterAll:function(A){var O=function X(ot){A.call(this),this.off("allfinished.fx",X)};return this.target().off("allfinished.fx",O).on("allfinished.fx",O),this._callStart()},last:function(){return this.situations.length?this.situations[this.situations.length-1]:this.situation},add:function(A,O,X){return this.last()[X||"animations"][A]=O,this._callStart()},step:function(A){var O,X,ot;A||(this.absPos=this.timeToAbsPos(+new Date)),this.situation.loops!==!1?(O=Math.max(this.absPos,0),X=Math.floor(O),this.situation.loops===!0||Xthis.lastPos&&ct<=nt&&(this.situation.once[ct].call(this.target(),this.pos,nt),delete this.situation.once[ct]);return this.active&&this.target().fire("during",{pos:this.pos,eased:nt,fx:this,situation:this.situation}),this.situation?(this.eachAt(),this.pos==1&&!this.situation.reversed||this.situation.reversed&&this.pos==0?(this.stopAnimFrame(),this.target().fire("finished",{fx:this,situation:this.situation}),this.situations.length||(this.target().fire("allfinished"),this.situations.length||(this.target().off(".fx"),this.active=!1)),this.active?this.dequeue():this.clearCurrent()):!this.paused&&this.active&&this.startAnimFrame(),this.lastPos=nt,this):this},eachAt:function(){var A,O=this,X=this.target(),ot=this.situation;for(var nt in ot.animations)A=[].concat(ot.animations[nt]).map(function(xt){return typeof xt!="string"&&xt.at?xt.at(ot.ease(O.pos),O.pos):xt}),X[nt].apply(X,A);for(var nt in ot.attrs)A=[nt].concat(ot.attrs[nt]).map(function(jt){return typeof jt!="string"&&jt.at?jt.at(ot.ease(O.pos),O.pos):jt}),X.attr.apply(X,A);for(var nt in ot.styles)A=[nt].concat(ot.styles[nt]).map(function(jt){return typeof jt!="string"&&jt.at?jt.at(ot.ease(O.pos),O.pos):jt}),X.style.apply(X,A);if(ot.transforms.length){A=ot.initialTransformation,nt=0;for(var ct=ot.transforms.length;nt=0;--X)this[J[X]]=A[J[X]]!=null?A[J[X]]:O[J[X]]},extend:{extract:function(){var A=N(this,0,1);N(this,1,0);var O=180/Math.PI*Math.atan2(A.y,A.x)-90;return{x:this.e,y:this.f,transformedX:(this.e*Math.cos(O*Math.PI/180)+this.f*Math.sin(O*Math.PI/180))/Math.sqrt(this.a*this.a+this.b*this.b),transformedY:(this.f*Math.cos(O*Math.PI/180)+this.e*Math.sin(-O*Math.PI/180))/Math.sqrt(this.c*this.c+this.d*this.d),rotation:O,a:this.a,b:this.b,c:this.c,d:this.d,e:this.e,f:this.f,matrix:new u.Matrix(this)}},clone:function(){return new u.Matrix(this)},morph:function(A){return this.destination=new u.Matrix(A),this},multiply:function(A){return new u.Matrix(this.native().multiply(function(O){return O instanceof u.Matrix||(O=new u.Matrix(O)),O}(A).native()))},inverse:function(){return new u.Matrix(this.native().inverse())},translate:function(A,O){return new u.Matrix(this.native().translate(A||0,O||0))},native:function(){for(var A=u.parser.native.createSVGMatrix(),O=J.length-1;O>=0;O--)A[J[O]]=this[J[O]];return A},toString:function(){return"matrix("+q(this.a)+","+q(this.b)+","+q(this.c)+","+q(this.d)+","+q(this.e)+","+q(this.f)+")"}},parent:u.Element,construct:{ctm:function(){return new u.Matrix(this.node.getCTM())},screenCTM:function(){if(this instanceof u.Nested){var A=this.rect(1,1),O=A.node.getScreenCTM();return A.remove(),new u.Matrix(O)}return new u.Matrix(this.node.getScreenCTM())}}}),u.Point=u.invent({create:function(A,O){var X;X=Array.isArray(A)?{x:A[0],y:A[1]}:o(A)==="object"?{x:A.x,y:A.y}:A!=null?{x:A,y:O??A}:{x:0,y:0},this.x=X.x,this.y=X.y},extend:{clone:function(){return new u.Point(this)},morph:function(A,O){return this.destination=new u.Point(A,O),this}}}),u.extend(u.Element,{point:function(A,O){return new u.Point(A,O).transform(this.screenCTM().inverse())}}),u.extend(u.Element,{attr:function(A,O,X){if(A==null){for(A={},X=(O=this.node.attributes).length-1;X>=0;X--)A[O[X].nodeName]=u.regex.isNumber.test(O[X].nodeValue)?parseFloat(O[X].nodeValue):O[X].nodeValue;return A}if(o(A)==="object")for(var ot in A)this.attr(ot,A[ot]);else if(O===null)this.node.removeAttribute(A);else{if(O==null)return(O=this.node.getAttribute(A))==null?u.defaults.attrs[A]:u.regex.isNumber.test(O)?parseFloat(O):O;A=="stroke-width"?this.attr("stroke",parseFloat(O)>0?this._stroke:null):A=="stroke"&&(this._stroke=O),A!="fill"&&A!="stroke"||(u.regex.isImage.test(O)&&(O=this.doc().defs().image(O,0,0)),O instanceof u.Image&&(O=this.doc().defs().pattern(0,0,function(){this.add(O)}))),typeof O=="number"?O=new u.Number(O):u.Color.isColor(O)?O=new u.Color(O):Array.isArray(O)&&(O=new u.Array(O)),A=="leading"?this.leading&&this.leading(O):typeof X=="string"?this.node.setAttributeNS(X,A,O.toString()):this.node.setAttribute(A,O.toString()),!this.rebuild||A!="font-size"&&A!="x"||this.rebuild(A,O)}return this}}),u.extend(u.Element,{transform:function(A,O){var X;return o(A)!=="object"?(X=new u.Matrix(this).extract(),typeof A=="string"?X[A]:X):(X=new u.Matrix(this),O=!!O||!!A.relative,A.a!=null&&(X=O?X.multiply(new u.Matrix(A)):new u.Matrix(A)),this.attr("transform",X))}}),u.extend(u.Element,{untransform:function(){return this.attr("transform",null)},matrixify:function(){return(this.attr("transform")||"").split(u.regex.transforms).slice(0,-1).map(function(A){var O=A.trim().split("(");return[O[0],O[1].split(u.regex.delimiter).map(function(X){return parseFloat(X)})]}).reduce(function(A,O){return O[0]=="matrix"?A.multiply(j(O[1])):A[O[0]].apply(A,O[1])},new u.Matrix)},toParent:function(A){if(this==A)return this;var O=this.screenCTM(),X=A.screenCTM().inverse();return this.addTo(A).untransform().transform(X.multiply(O)),this},toDoc:function(){return this.toParent(this.doc())}}),u.Transformation=u.invent({create:function(A,O){if(arguments.length>1&&typeof O!="boolean")return this.constructor.call(this,[].slice.call(arguments));if(Array.isArray(A))for(var X=0,ot=this.arguments.length;X=0},index:function(A){return[].slice.call(this.node.childNodes).indexOf(A.node)},get:function(A){return u.adopt(this.node.childNodes[A])},first:function(){return this.get(0)},last:function(){return this.get(this.node.childNodes.length-1)},each:function(A,O){for(var X=this.children(),ot=0,nt=X.length;otd.globals.gridHeight&&(L=d.globals.gridHeight),d.globals.isBarHorizontal||this.moveXCrosshairs(k),v.fixedTooltip||this.moveTooltip(k,L||d.globals.gridHeight)}}]),Q}(),ae=function(){function Q(c){a(this,Q),this.w=c.w,this.ttCtx=c,this.ctx=c.ctx,this.tooltipPosition=new Zt(c)}return l(Q,[{key:"drawDynamicPoints",value:function(){var c=this.w,u=new $(this.ctx),d=new Vt(this.ctx),v=c.globals.dom.baseEl.querySelectorAll(".apexcharts-series");v=I(v),c.config.chart.stacked&&v.sort(function(P,V){return parseFloat(P.getAttribute("data:realIndex"))-parseFloat(V.getAttribute("data:realIndex"))});for(var m=0;m2&&arguments[2]!==void 0?arguments[2]:null,v=arguments.length>3&&arguments[3]!==void 0?arguments[3]:null,m=this.w;m.config.chart.type!=="bubble"&&this.newPointSize(c,u);var x=u.getAttribute("cx"),w=u.getAttribute("cy");if(d!==null&&v!==null&&(x=d,w=v),this.tooltipPosition.moveXCrosshairs(x),!this.fixedTooltip){if(m.config.chart.type==="radar"){var k=this.ttCtx.getElGrid().getBoundingClientRect();x=this.ttCtx.e.clientX-k.left}this.tooltipPosition.moveTooltip(x,w,m.config.markers.hover.size)}}},{key:"enlargePoints",value:function(c){for(var u=this.w,d=this,v=this.ttCtx,m=c,x=u.globals.dom.baseEl.querySelectorAll(".apexcharts-series:not(.apexcharts-series-collapsed) .apexcharts-marker"),w=u.config.markers.hover.size,k=0;k=0){var v=this.ttCtx.tooltipUtil.getPathFromPoint(c[u],d);c[u].setAttribute("d",v)}else c[u].setAttribute("d","M0,0")}}}]),Q}(),ee=function(){function Q(c){a(this,Q),this.w=c.w;var u=this.w;this.ttCtx=c,this.isVerticalGroupedRangeBar=!u.globals.isBarHorizontal&&u.config.chart.type==="rangeBar"&&u.config.plotOptions.bar.rangeBarGroupRows}return l(Q,[{key:"getAttr",value:function(c,u){return parseFloat(c.target.getAttribute(u))}},{key:"handleHeatTreeTooltip",value:function(c){var u=c.e,d=c.opt,v=c.x,m=c.y,x=c.type,w=this.ttCtx,k=this.w;if(u.target.classList.contains("apexcharts-".concat(x,"-rect"))){var L=this.getAttr(u,"i"),D=this.getAttr(u,"j"),P=this.getAttr(u,"cx"),V=this.getAttr(u,"cy"),N=this.getAttr(u,"width"),j=this.getAttr(u,"height");if(w.tooltipLabels.drawSeriesTexts({ttItems:d.ttItems,i:L,j:D,shared:!1,e:u}),k.globals.capturedSeriesIndex=L,k.globals.capturedDataPointIndex=D,v=P+w.tooltipRect.ttWidth/2+N,m=V+w.tooltipRect.ttHeight/2-j/2,w.tooltipPosition.moveXCrosshairs(P+N/2),v>k.globals.gridWidth/2&&(v=P-w.tooltipRect.ttWidth/2+N),w.w.config.tooltip.followCursor){var U=k.globals.dom.elWrap.getBoundingClientRect();v=k.globals.clientX-U.left-(v>k.globals.gridWidth/2?w.tooltipRect.ttWidth:0),m=k.globals.clientY-U.top-(m>k.globals.gridHeight/2?w.tooltipRect.ttHeight:0)}}return{x:v,y:m}}},{key:"handleMarkerTooltip",value:function(c){var u,d,v=c.e,m=c.opt,x=c.x,w=c.y,k=this.w,L=this.ttCtx;if(v.target.classList.contains("apexcharts-marker")){var D=parseInt(m.paths.getAttribute("cx"),10),P=parseInt(m.paths.getAttribute("cy"),10),V=parseFloat(m.paths.getAttribute("val"));if(d=parseInt(m.paths.getAttribute("rel"),10),u=parseInt(m.paths.parentNode.parentNode.parentNode.getAttribute("rel"),10)-1,L.intersect){var N=E.findAncestor(m.paths,"apexcharts-series");N&&(u=parseInt(N.getAttribute("data:realIndex"),10))}if(L.tooltipLabels.drawSeriesTexts({ttItems:m.ttItems,i:u,j:d,shared:!L.showOnIntersect&&k.config.tooltip.shared,e:v}),v.type==="mouseup"&&L.markerClick(v,u,d),k.globals.capturedSeriesIndex=u,k.globals.capturedDataPointIndex=d,x=D,w=P+k.globals.translateY-1.4*L.tooltipRect.ttHeight,L.w.config.tooltip.followCursor){var j=L.getElGrid().getBoundingClientRect();w=L.e.clientY+k.globals.translateY-j.top}V<0&&(w=P),L.marker.enlargeCurrentPoint(d,m.paths,x,w)}return{x,y:w}}},{key:"handleBarTooltip",value:function(c){var u,d,v=c.e,m=c.opt,x=this.w,w=this.ttCtx,k=w.getElTooltip(),L=0,D=0,P=0,V=this.getBarTooltipXY({e:v,opt:m});u=V.i,V.barHeight;var N=V.j;x.globals.capturedSeriesIndex=u,x.globals.capturedDataPointIndex=N,x.globals.isBarHorizontal&&w.tooltipUtil.hasBars()||!x.config.tooltip.shared?(D=V.x,P=V.y,d=Array.isArray(x.config.stroke.width)?x.config.stroke.width[u]:x.config.stroke.width,L=D):x.globals.comboCharts||x.config.tooltip.shared||(L/=2),isNaN(P)&&(P=x.globals.svgHeight-w.tooltipRect.ttHeight);var j=parseInt(m.paths.parentNode.getAttribute("data:realIndex"),10);if(x.globals.isMultipleYAxis?x.config.yaxis[j]&&x.config.yaxis[j].reversed:x.config.yaxis[0].reversed,D+w.tooltipRect.ttWidth>x.globals.gridWidth?D-=w.tooltipRect.ttWidth:D<0&&(D=0),w.w.config.tooltip.followCursor){var U=w.getElGrid().getBoundingClientRect();P=w.e.clientY-U.top}w.tooltip===null&&(w.tooltip=x.globals.dom.baseEl.querySelector(".apexcharts-tooltip")),x.config.tooltip.shared||(x.globals.comboBarCount>0?w.tooltipPosition.moveXCrosshairs(L+d/2):w.tooltipPosition.moveXCrosshairs(L)),!w.fixedTooltip&&(!x.config.tooltip.shared||x.globals.isBarHorizontal&&w.tooltipUtil.hasBars())&&(P=P+x.globals.translateY-w.tooltipRect.ttHeight/2,k.style.left=D+x.globals.translateX+"px",k.style.top=P+"px")}},{key:"getBarTooltipXY",value:function(c){var u=this,d=c.e,v=c.opt,m=this.w,x=null,w=this.ttCtx,k=0,L=0,D=0,P=0,V=0,N=d.target.classList;if(N.contains("apexcharts-bar-area")||N.contains("apexcharts-candlestick-area")||N.contains("apexcharts-boxPlot-area")||N.contains("apexcharts-rangebar-area")){var j=d.target,U=j.getBoundingClientRect(),q=v.elGrid.getBoundingClientRect(),J=U.height;V=U.height;var rt=U.width,A=parseInt(j.getAttribute("cx"),10),O=parseInt(j.getAttribute("cy"),10);P=parseFloat(j.getAttribute("barWidth"));var X=d.type==="touchmove"?d.touches[0].clientX:d.clientX;x=parseInt(j.getAttribute("j"),10),k=parseInt(j.parentNode.getAttribute("rel"),10)-1;var ot=j.getAttribute("data-range-y1"),nt=j.getAttribute("data-range-y2");m.globals.comboCharts&&(k=parseInt(j.parentNode.getAttribute("data:realIndex"),10));var ct=function(xt){return m.globals.isXNumeric?A-rt/2:u.isVerticalGroupedRangeBar?A+rt/2:A-w.dataPointsDividedWidth+rt/2},Ct=function(){return O-w.dataPointsDividedHeight+J/2-w.tooltipRect.ttHeight/2};w.tooltipLabels.drawSeriesTexts({ttItems:v.ttItems,i:k,j:x,y1:ot?parseInt(ot,10):null,y2:nt?parseInt(nt,10):null,shared:!w.showOnIntersect&&m.config.tooltip.shared,e:d}),m.config.tooltip.followCursor?m.globals.isBarHorizontal?(L=X-q.left+15,D=Ct()):(L=ct(),D=d.clientY-q.top-w.tooltipRect.ttHeight/2-15):m.globals.isBarHorizontal?((L=A)0&&d.setAttribute("width",u.xcrosshairsWidth)}},{key:"handleYCrosshair",value:function(){var c=this.w,u=this.ttCtx;u.ycrosshairs=c.globals.dom.baseEl.querySelector(".apexcharts-ycrosshairs"),u.ycrosshairsHidden=c.globals.dom.baseEl.querySelector(".apexcharts-ycrosshairs-hidden")}},{key:"drawYaxisTooltipText",value:function(c,u,d){var v=this.ttCtx,m=this.w,x=m.globals,w=x.seriesYAxisMap[c];if(v.yaxisTooltips[c]&&w.length>0){var k=x.yLabelFormatters[c],L=v.getElGrid().getBoundingClientRect(),D=w[0],P=0;d.yRatio.length>1&&(P=D);var V=(u-L.top)*d.yRatio[P],N=x.maxYArr[D]-x.minYArr[D],j=x.minYArr[D]+(N-V);m.config.yaxis[c].reversed&&(j=x.maxYArr[D]-(N-V)),v.tooltipPosition.moveYCrosshairs(u-L.top),v.yaxisTooltipText[c].innerHTML=k(j),v.tooltipPosition.moveYAxisTooltip(c)}}}]),Q}(),_e=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w;var u=this.w;this.tConfig=u.config.tooltip,this.tooltipUtil=new Pt(this),this.tooltipLabels=new Yt(this),this.tooltipPosition=new Zt(this),this.marker=new ae(this),this.intersect=new ee(this),this.axesTooltip=new jt(this),this.showOnIntersect=this.tConfig.intersect,this.showTooltipTitle=this.tConfig.x.show,this.fixedTooltip=this.tConfig.fixed.enabled,this.xaxisTooltip=null,this.yaxisTTEls=null,this.isBarShared=!u.globals.isBarHorizontal&&this.tConfig.shared,this.lastHoverTime=Date.now()}return l(Q,[{key:"getElTooltip",value:function(c){return c||(c=this),c.w.globals.dom.baseEl?c.w.globals.dom.baseEl.querySelector(".apexcharts-tooltip"):null}},{key:"getElXCrosshairs",value:function(){return this.w.globals.dom.baseEl.querySelector(".apexcharts-xcrosshairs")}},{key:"getElGrid",value:function(){return this.w.globals.dom.baseEl.querySelector(".apexcharts-grid")}},{key:"drawTooltip",value:function(c){var u=this.w;this.xyRatios=c,this.isXAxisTooltipEnabled=u.config.xaxis.tooltip.enabled&&u.globals.axisCharts,this.yaxisTooltips=u.config.yaxis.map(function(x,w){return!!(x.show&&x.tooltip.enabled&&u.globals.axisCharts)}),this.allTooltipSeriesGroups=[],u.globals.axisCharts||(this.showTooltipTitle=!1);var d=document.createElement("div");if(d.classList.add("apexcharts-tooltip"),u.config.tooltip.cssClass&&d.classList.add(u.config.tooltip.cssClass),d.classList.add("apexcharts-theme-".concat(this.tConfig.theme)),u.globals.dom.elWrap.appendChild(d),u.globals.axisCharts){this.axesTooltip.drawXaxisTooltip(),this.axesTooltip.drawYaxisTooltip(),this.axesTooltip.setXCrosshairWidth(),this.axesTooltip.handleYCrosshair();var v=new Bt(this.ctx);this.xAxisTicksPositions=v.getXAxisTicksPositions()}if(!u.globals.comboCharts&&!this.tConfig.intersect&&u.config.chart.type!=="rangeBar"||this.tConfig.shared||(this.showOnIntersect=!0),u.config.markers.size!==0&&u.globals.markers.largestSize!==0||this.marker.drawDynamicPoints(this),u.globals.collapsedSeries.length!==u.globals.series.length){this.dataPointsDividedHeight=u.globals.gridHeight/u.globals.dataPoints,this.dataPointsDividedWidth=u.globals.gridWidth/u.globals.dataPoints,this.showTooltipTitle&&(this.tooltipTitle=document.createElement("div"),this.tooltipTitle.classList.add("apexcharts-tooltip-title"),this.tooltipTitle.style.fontFamily=this.tConfig.style.fontFamily||u.config.chart.fontFamily,this.tooltipTitle.style.fontSize=this.tConfig.style.fontSize,d.appendChild(this.tooltipTitle));var m=u.globals.series.length;(u.globals.xyCharts||u.globals.comboCharts)&&this.tConfig.shared&&(m=this.showOnIntersect?1:u.globals.series.length),this.legendLabels=u.globals.dom.baseEl.querySelectorAll(".apexcharts-legend-text"),this.ttItems=this.createTTElements(m),this.addSVGEvents()}}},{key:"createTTElements",value:function(c){for(var u=this,d=this.w,v=[],m=this.getElTooltip(),x=function(k){var L=document.createElement("div");L.classList.add("apexcharts-tooltip-series-group","apexcharts-tooltip-series-group-".concat(k)),L.style.order=d.config.tooltip.inverseOrder?c-k:k+1;var D=document.createElement("span");D.classList.add("apexcharts-tooltip-marker"),D.style.backgroundColor=d.globals.colors[k],L.appendChild(D);var P=document.createElement("div");P.classList.add("apexcharts-tooltip-text"),P.style.fontFamily=u.tConfig.style.fontFamily||d.config.chart.fontFamily,P.style.fontSize=u.tConfig.style.fontSize,["y","goals","z"].forEach(function(V){var N=document.createElement("div");N.classList.add("apexcharts-tooltip-".concat(V,"-group"));var j=document.createElement("span");j.classList.add("apexcharts-tooltip-text-".concat(V,"-label")),N.appendChild(j);var U=document.createElement("span");U.classList.add("apexcharts-tooltip-text-".concat(V,"-value")),N.appendChild(U),P.appendChild(N)}),L.appendChild(P),m.appendChild(L),v.push(L)},w=0;w0&&this.addPathsEventListeners(j,P),this.tooltipUtil.hasBars()&&!this.tConfig.shared&&this.addDatapointEventsListeners(P)}}},{key:"drawFixedTooltipRect",value:function(){var c=this.w,u=this.getElTooltip(),d=u.getBoundingClientRect(),v=d.width+10,m=d.height+10,x=this.tConfig.fixed.offsetX,w=this.tConfig.fixed.offsetY,k=this.tConfig.fixed.position.toLowerCase();return k.indexOf("right")>-1&&(x=x+c.globals.svgWidth-v+10),k.indexOf("bottom")>-1&&(w=w+c.globals.svgHeight-m-10),u.style.left=x+"px",u.style.top=w+"px",{x,y:w,ttWidth:v,ttHeight:m}}},{key:"addDatapointEventsListeners",value:function(c){var u=this.w.globals.dom.baseEl.querySelectorAll(".apexcharts-series-markers .apexcharts-marker, .apexcharts-bar-area, .apexcharts-candlestick-area, .apexcharts-boxPlot-area, .apexcharts-rangebar-area");this.addPathsEventListeners(u,c)}},{key:"addPathsEventListeners",value:function(c,u){for(var d=this,v=function(x){var w={paths:c[x],tooltipEl:u.tooltipEl,tooltipY:u.tooltipY,tooltipX:u.tooltipX,elGrid:u.elGrid,hoverArea:u.hoverArea,ttItems:u.ttItems};["mousemove","mouseup","touchmove","mouseout","touchend"].map(function(k){return c[x].addEventListener(k,d.onSeriesHover.bind(d,w),{capture:!1,passive:!0})})},m=0;m=100?this.seriesHover(c,u):(clearTimeout(this.seriesHoverTimeout),this.seriesHoverTimeout=setTimeout(function(){d.seriesHover(c,u)},100-v))}},{key:"seriesHover",value:function(c,u){var d=this;this.lastHoverTime=Date.now();var v=[],m=this.w;m.config.chart.group&&(v=this.ctx.getGroupedCharts()),m.globals.axisCharts&&(m.globals.minX===-1/0&&m.globals.maxX===1/0||m.globals.dataPoints===0)||(v.length?v.forEach(function(x){var w=d.getElTooltip(x),k={paths:c.paths,tooltipEl:w,tooltipY:c.tooltipY,tooltipX:c.tooltipX,elGrid:c.elGrid,hoverArea:c.hoverArea,ttItems:x.w.globals.tooltip.ttItems};x.w.globals.minX===d.w.globals.minX&&x.w.globals.maxX===d.w.globals.maxX&&x.w.globals.tooltip.seriesHoverByContext({chartCtx:x,ttCtx:x.w.globals.tooltip,opt:k,e:u})}):this.seriesHoverByContext({chartCtx:this.ctx,ttCtx:this.w.globals.tooltip,opt:c,e:u}))}},{key:"seriesHoverByContext",value:function(c){var u=c.chartCtx,d=c.ttCtx,v=c.opt,m=c.e,x=u.w,w=this.getElTooltip();w&&(d.tooltipRect={x:0,y:0,ttWidth:w.getBoundingClientRect().width,ttHeight:w.getBoundingClientRect().height},d.e=m,d.tooltipUtil.hasBars()&&!x.globals.comboCharts&&!d.isBarShared&&this.tConfig.onDatasetHover.highlightDataSeries&&new Kt(u).toggleSeriesOnHover(m,m.target.parentNode),d.fixedTooltip&&d.drawFixedTooltipRect(),x.globals.axisCharts?d.axisChartsTooltips({e:m,opt:v,tooltipRect:d.tooltipRect}):d.nonAxisChartsTooltips({e:m,opt:v,tooltipRect:d.tooltipRect}))}},{key:"axisChartsTooltips",value:function(c){var u,d,v=c.e,m=c.opt,x=this.w,w=m.elGrid.getBoundingClientRect(),k=v.type==="touchmove"?v.touches[0].clientX:v.clientX,L=v.type==="touchmove"?v.touches[0].clientY:v.clientY;if(this.clientY=L,this.clientX=k,x.globals.capturedSeriesIndex=-1,x.globals.capturedDataPointIndex=-1,Lw.top+w.height)this.handleMouseOut(m);else{if(Array.isArray(this.tConfig.enabledOnSeries)&&!x.config.tooltip.shared){var D=parseInt(m.paths.getAttribute("index"),10);if(this.tConfig.enabledOnSeries.indexOf(D)<0)return void this.handleMouseOut(m)}var P=this.getElTooltip(),V=this.getElXCrosshairs(),N=x.globals.xyCharts||x.config.chart.type==="bar"&&!x.globals.isBarHorizontal&&this.tooltipUtil.hasBars()&&this.tConfig.shared||x.globals.comboCharts&&this.tooltipUtil.hasBars();if(v.type==="mousemove"||v.type==="touchmove"||v.type==="mouseup"){if(x.globals.collapsedSeries.length+x.globals.ancillaryCollapsedSeries.length===x.globals.series.length)return;V!==null&&V.classList.add("apexcharts-active");var j=this.yaxisTooltips.filter(function(J){return J===!0});if(this.ycrosshairs!==null&&j.length&&this.ycrosshairs.classList.add("apexcharts-active"),N&&!this.showOnIntersect)this.handleStickyTooltip(v,k,L,m);else if(x.config.chart.type==="heatmap"||x.config.chart.type==="treemap"){var U=this.intersect.handleHeatTreeTooltip({e:v,opt:m,x:u,y:d,type:x.config.chart.type});u=U.x,d=U.y,P.style.left=u+"px",P.style.top=d+"px"}else this.tooltipUtil.hasBars()&&this.intersect.handleBarTooltip({e:v,opt:m}),this.tooltipUtil.hasMarkers()&&this.intersect.handleMarkerTooltip({e:v,opt:m,x:u,y:d});if(this.yaxisTooltips.length)for(var q=0;qL.width)this.handleMouseOut(v);else if(k!==null)this.handleStickyCapturedSeries(c,k,v,w);else if(this.tooltipUtil.isXoverlap(w)||m.globals.isBarHorizontal){var D=m.globals.series.findIndex(function(P,V){return!m.globals.collapsedSeriesIndices.includes(V)});this.create(c,this,D,w,v.ttItems)}}},{key:"handleStickyCapturedSeries",value:function(c,u,d,v){var m=this.w;if(!this.tConfig.shared&&m.globals.series[u][v]===null)return void this.handleMouseOut(d);if(m.globals.series[u][v]!==void 0)this.tConfig.shared&&this.tooltipUtil.isXoverlap(v)&&this.tooltipUtil.isInitialSeriesSameLen()?this.create(c,this,u,v,d.ttItems):this.create(c,this,u,v,d.ttItems,!1);else if(this.tooltipUtil.isXoverlap(v)){var x=m.globals.series.findIndex(function(w,k){return!m.globals.collapsedSeriesIndices.includes(k)});this.create(c,this,x,v,d.ttItems)}}},{key:"deactivateHoverFilter",value:function(){for(var c=this.w,u=new $(this.ctx),d=c.globals.dom.Paper.select(".apexcharts-bar-area"),v=0;v5&&arguments[5]!==void 0?arguments[5]:null,nt=this.w,ct=u;c.type==="mouseup"&&this.markerClick(c,d,v),ot===null&&(ot=this.tConfig.shared);var Ct=this.tooltipUtil.hasMarkers(d),xt=this.tooltipUtil.getElBars();if(nt.config.legend.tooltipHoverFormatter){var $t=nt.config.legend.tooltipHoverFormatter,re=Array.from(this.legendLabels);re.forEach(function(yr){var _r=yr.getAttribute("data:default-text");yr.innerHTML=decodeURIComponent(_r)});for(var Ot=0;Ot0?ct.marker.enlargePoints(v):ct.tooltipPosition.moveDynamicPointsOnHover(v);else if(this.tooltipUtil.hasBars()&&(this.barSeriesHeight=this.tooltipUtil.getBarsHeight(xt),this.barSeriesHeight>0)){var l1=new $(this.ctx),i1=nt.globals.dom.Paper.select(".apexcharts-bar-area[j='".concat(v,"']"));this.deactivateHoverFilter(),this.tooltipPosition.moveStickyTooltipOverBars(v,d);for(var g1=0;g10&&u.config.plotOptions.bar.hideZeroBarsWhenGrouped&&(N-=D*nt)),ot&&(N=N+V.height/2-rt/2-2);var Ct=u.globals.series[d][v]<0,xt=k;switch(this.barCtx.isReversed&&(xt=k+(Ct?P:-P)),q.position){case"center":j=ot?Ct?xt-P/2+O:xt+P/2-O:Ct?xt-P/2+V.height/2+O:xt+P/2+V.height/2-O;break;case"bottom":j=ot?Ct?xt-P+O:xt+P-O:Ct?xt-P+V.height+rt+O:xt+P-V.height/2+rt-O;break;case"top":j=ot?Ct?xt+O:xt-O:Ct?xt-V.height/2-O:xt+V.height+O}if(this.barCtx.lastActiveBarSerieIndex===m&&J.enabled){var $t=new $(this.barCtx.ctx).getTextRects(this.getStackedTotalDataLabel({realIndex:m,j:v}),U.fontSize);x=Ct?xt-$t.height/2-O-J.offsetY+18:xt+$t.height+O+J.offsetY-18;var re=ct;w=X+(u.globals.isXNumeric?-D*u.globals.barGroups.length/2:u.globals.barGroups.length*D/2-(u.globals.barGroups.length-1)*D-re)+J.offsetX}return u.config.chart.stacked||(j<0?j=0+rt:j+V.height/3>u.globals.gridHeight&&(j=u.globals.gridHeight-rt)),{bcx:L,bcy:k,dataLabelsX:N,dataLabelsY:j,totalDataLabelsX:w,totalDataLabelsY:x,totalDataLabelsAnchor:"middle"}}},{key:"calculateBarsDataLabelsPosition",value:function(c){var u=this.w,d=c.x,v=c.i,m=c.j,x=c.realIndex;c.columnGroupIndex;var w=c.bcy,k=c.barHeight,L=c.barWidth,D=c.textRects,P=c.dataLabelsX,V=c.strokeWidth,N=c.dataLabelsConfig,j=c.barDataLabelsConfig,U=c.barTotalDataLabelsConfig,q=c.offX,J=c.offY,rt=u.globals.gridHeight/u.globals.dataPoints;L=Math.abs(L);var A,O,X=w-(this.barCtx.isRangeBar?0:rt)+k/2+D.height/2+J-3,ot="start",nt=u.globals.series[v][m]<0,ct=d;switch(this.barCtx.isReversed&&(ct=d+(nt?-L:L),ot=nt?"start":"end"),j.position){case"center":P=nt?ct+L/2-q:Math.max(D.width/2,ct-L/2)+q;break;case"bottom":P=nt?ct+L-V-Math.round(D.width/2)-q:ct-L+V+Math.round(D.width/2)+q;break;case"top":P=nt?ct-V+Math.round(D.width/2)-q:ct-V-Math.round(D.width/2)+q}if(this.barCtx.lastActiveBarSerieIndex===x&&U.enabled){var Ct=new $(this.barCtx.ctx).getTextRects(this.getStackedTotalDataLabel({realIndex:x,j:m}),N.fontSize);nt?(A=ct-V-q-U.offsetX,ot="end"):A=ct+q+U.offsetX+(this.barCtx.isReversed?-(L+V):V),O=X-D.height/2+Ct.height/2+U.offsetY+V}return u.config.chart.stacked||(P<0?P=P+D.width+V:P+D.width/2>u.globals.gridWidth&&(P=u.globals.gridWidth-D.width-V)),{bcx:d,bcy:w,dataLabelsX:P,dataLabelsY:X,totalDataLabelsX:A,totalDataLabelsY:O,totalDataLabelsAnchor:ot}}},{key:"drawCalculatedDataLabels",value:function(c){var u=c.x,d=c.y,v=c.val,m=c.i,x=c.j,w=c.textRects,k=c.barHeight,L=c.barWidth,D=c.dataLabelsConfig,P=this.w,V="rotate(0)";P.config.plotOptions.bar.dataLabels.orientation==="vertical"&&(V="rotate(-90, ".concat(u,", ").concat(d,")"));var N=new Ut(this.barCtx.ctx),j=new $(this.barCtx.ctx),U=D.formatter,q=null,J=P.globals.collapsedSeriesIndices.indexOf(m)>-1;if(D.enabled&&!J){q=j.group({class:"apexcharts-data-labels",transform:V});var rt="";v!==void 0&&(rt=U(v,i(i({},P),{},{seriesIndex:m,dataPointIndex:x,w:P}))),!v&&P.config.plotOptions.bar.hideZeroBarsWhenGrouped&&(rt="");var A=P.globals.series[m][x]<0,O=P.config.plotOptions.bar.dataLabels.position;P.config.plotOptions.bar.dataLabels.orientation==="vertical"&&(O==="top"&&(D.textAnchor=A?"end":"start"),O==="center"&&(D.textAnchor="middle"),O==="bottom"&&(D.textAnchor=A?"end":"start")),this.barCtx.isRangeBar&&this.barCtx.barOptions.dataLabels.hideOverflowingLabels&&LMath.abs(L)&&(rt=""):w.height/1.6>Math.abs(k)&&(rt=""));var X=i({},D);this.barCtx.isHorizontal&&v<0&&(D.textAnchor==="start"?X.textAnchor="end":D.textAnchor==="end"&&(X.textAnchor="start")),N.plotDataLabelsText({x:u,y:d,text:rt,i:m,j:x,parent:q,dataLabelsConfig:X,alwaysDrawDataLabel:!0,offsetCorrection:!0})}return q}},{key:"drawTotalDataLabels",value:function(c){var u=c.x,d=c.y,v=c.val;c.barWidth,c.barHeight;var m=c.realIndex,x=c.textAnchor,w=c.barTotalDataLabelsConfig;this.w;var k,L=new $(this.barCtx.ctx);return w.enabled&&u!==void 0&&d!==void 0&&this.barCtx.lastActiveBarSerieIndex===m&&(k=L.drawText({x:u,y:d,foreColor:w.style.color,text:v,textAnchor:x,fontFamily:w.style.fontFamily,fontSize:w.style.fontSize,fontWeight:w.style.fontWeight})),k}}]),Q}(),Gt=function(){function Q(c){a(this,Q),this.w=c.w,this.barCtx=c}return l(Q,[{key:"initVariables",value:function(c){var u=this.w;this.barCtx.series=c,this.barCtx.totalItems=0,this.barCtx.seriesLen=0,this.barCtx.visibleI=-1,this.barCtx.visibleItems=1;for(var d=0;d0&&(this.barCtx.seriesLen=this.barCtx.seriesLen+1,this.barCtx.totalItems+=c[d].length),u.globals.isXNumeric)for(var v=0;vu.globals.minX&&u.globals.seriesX[d][v]0&&(v=L.globals.minXDiff/V),(x=v/P*parseInt(this.barCtx.barOptions.columnWidth,10)/100)<1&&(x=1)}String(this.barCtx.barOptions.columnWidth).indexOf("%")===-1&&(x=parseInt(this.barCtx.barOptions.columnWidth,10)),w=L.globals.gridHeight-this.barCtx.baseLineY[this.barCtx.translationsIndex]-(this.barCtx.isReversed?L.globals.gridHeight:0)+(this.barCtx.isReversed?2*this.barCtx.baseLineY[this.barCtx.translationsIndex]:0),c=L.globals.padHorizontal+(v-x*this.barCtx.seriesLen)/2}return L.globals.barHeight=m,L.globals.barWidth=x,{x:c,y:u,yDivision:d,xDivision:v,barHeight:m,barWidth:x,zeroH:w,zeroW:k}}},{key:"initializeStackedPrevVars",value:function(c){c.w.globals.seriesGroups.forEach(function(u){c[u]||(c[u]={}),c[u].prevY=[],c[u].prevX=[],c[u].prevYF=[],c[u].prevXF=[],c[u].prevYVal=[],c[u].prevXVal=[]})}},{key:"initializeStackedXYVars",value:function(c){c.w.globals.seriesGroups.forEach(function(u){c[u]||(c[u]={}),c[u].xArrj=[],c[u].xArrjF=[],c[u].xArrjVal=[],c[u].yArrj=[],c[u].yArrjF=[],c[u].yArrjVal=[]})}},{key:"getPathFillColor",value:function(c,u,d,v){var m,x,w,k,L,D=this.w,P=new Lt(this.barCtx.ctx),V=null,N=this.barCtx.barOptions.distributed?d:u;return this.barCtx.barOptions.colors.ranges.length>0&&this.barCtx.barOptions.colors.ranges.map(function(j){c[u][d]>=j.from&&c[u][d]<=j.to&&(V=j.color)}),(m=D.config.series[u].data[d])!==null&&m!==void 0&&m.fillColor&&(V=D.config.series[u].data[d].fillColor),P.fillPath({seriesNumber:this.barCtx.barOptions.distributed?N:v,dataPointIndex:d,color:V,value:c[u][d],fillConfig:(x=D.config.series[u].data[d])===null||x===void 0?void 0:x.fill,fillType:(w=D.config.series[u].data[d])!==null&&w!==void 0&&(k=w.fill)!==null&&k!==void 0&&k.type?(L=D.config.series[u].data[d])===null||L===void 0?void 0:L.fill.type:Array.isArray(D.config.fill.type)?D.config.fill.type[v]:D.config.fill.type})}},{key:"getStrokeWidth",value:function(c,u,d){var v=0,m=this.w;return this.barCtx.series[c][u]===void 0||this.barCtx.series[c][u]===null?this.barCtx.isNullValue=!0:this.barCtx.isNullValue=!1,m.config.stroke.show&&(this.barCtx.isNullValue||(v=Array.isArray(this.barCtx.strokeWidth)?this.barCtx.strokeWidth[d]:this.barCtx.strokeWidth)),v}},{key:"shouldApplyRadius",value:function(c){var u=this.w,d=!1;return u.config.plotOptions.bar.borderRadius>0&&(u.config.chart.stacked&&u.config.plotOptions.bar.borderRadiusWhenStacked==="last"?this.barCtx.lastActiveBarSerieIndex===c&&(d=!0):d=!0),d}},{key:"barBackground",value:function(c){var u=c.j,d=c.i,v=c.x1,m=c.x2,x=c.y1,w=c.y2,k=c.elSeries,L=this.w,D=new $(this.barCtx.ctx),P=new Kt(this.barCtx.ctx).getActiveConfigSeriesIndex();if(this.barCtx.barOptions.colors.backgroundBarColors.length>0&&P===d){u>=this.barCtx.barOptions.colors.backgroundBarColors.length&&(u%=this.barCtx.barOptions.colors.backgroundBarColors.length);var V=this.barCtx.barOptions.colors.backgroundBarColors[u],N=D.drawRect(v!==void 0?v:0,x!==void 0?x:0,m!==void 0?m:L.globals.gridWidth,w!==void 0?w:L.globals.gridHeight,this.barCtx.barOptions.colors.backgroundBarRadius,V,this.barCtx.barOptions.colors.backgroundBarOpacity);k.add(N),N.node.classList.add("apexcharts-backgroundBar")}}},{key:"getColumnPaths",value:function(c){var u,d=c.barWidth,v=c.barXPosition,m=c.y1,x=c.y2,w=c.strokeWidth,k=c.seriesGroup,L=c.realIndex,D=c.i,P=c.j,V=c.w,N=new $(this.barCtx.ctx);(w=Array.isArray(w)?w[L]:w)||(w=0);var j=d,U=v;(u=V.config.series[L].data[P])!==null&&u!==void 0&&u.columnWidthOffset&&(U=v-V.config.series[L].data[P].columnWidthOffset/2,j=d+V.config.series[L].data[P].columnWidthOffset);var q=w/2,J=U+q,rt=U+j-q;m+=.001-q,x+=.001+q;var A=N.move(J,m),O=N.move(J,m),X=N.line(rt,m);if(V.globals.previousPaths.length>0&&(O=this.barCtx.getPreviousPath(L,P,!1)),A=A+N.line(J,x)+N.line(rt,x)+N.line(rt,m)+(V.config.plotOptions.bar.borderRadiusApplication==="around"?" Z":" z"),O=O+N.line(J,m)+X+X+X+X+X+N.line(J,m)+(V.config.plotOptions.bar.borderRadiusApplication==="around"?" Z":" z"),this.shouldApplyRadius(L)&&(A=N.roundPathCorners(A,V.config.plotOptions.bar.borderRadius)),V.config.chart.stacked){var ot=this.barCtx;(ot=this.barCtx[k]).yArrj.push(x-q),ot.yArrjF.push(Math.abs(m-x+w)),ot.yArrjVal.push(this.barCtx.series[D][P])}return{pathTo:A,pathFrom:O}}},{key:"getBarpaths",value:function(c){var u,d=c.barYPosition,v=c.barHeight,m=c.x1,x=c.x2,w=c.strokeWidth,k=c.seriesGroup,L=c.realIndex,D=c.i,P=c.j,V=c.w,N=new $(this.barCtx.ctx);(w=Array.isArray(w)?w[L]:w)||(w=0);var j=d,U=v;(u=V.config.series[L].data[P])!==null&&u!==void 0&&u.barHeightOffset&&(j=d-V.config.series[L].data[P].barHeightOffset/2,U=v+V.config.series[L].data[P].barHeightOffset);var q=w/2,J=j+q,rt=j+U-q;m+=.001-q,x+=.001+q;var A=N.move(m,J),O=N.move(m,J);V.globals.previousPaths.length>0&&(O=this.barCtx.getPreviousPath(L,P,!1));var X=N.line(m,rt);if(A=A+N.line(x,J)+N.line(x,rt)+X+(V.config.plotOptions.bar.borderRadiusApplication==="around"?" Z":" z"),O=O+N.line(m,J)+X+X+X+X+X+N.line(m,J)+(V.config.plotOptions.bar.borderRadiusApplication==="around"?" Z":" z"),this.shouldApplyRadius(L)&&(A=N.roundPathCorners(A,V.config.plotOptions.bar.borderRadius)),V.config.chart.stacked){var ot=this.barCtx;(ot=this.barCtx[k]).xArrj.push(x+q),ot.xArrjF.push(Math.abs(m-x)),ot.xArrjVal.push(this.barCtx.series[D][P])}return{pathTo:A,pathFrom:O}}},{key:"checkZeroSeries",value:function(c){for(var u=c.series,d=this.w,v=0;v2&&arguments[2]!==void 0)||arguments[2]?u:null;return c!=null&&(d=u+c/this.barCtx.invertedYRatio-2*(this.barCtx.isReversed?c/this.barCtx.invertedYRatio:0)),d}},{key:"getYForValue",value:function(c,u,d){var v=!(arguments.length>3&&arguments[3]!==void 0)||arguments[3]?u:null;return c!=null&&(v=u-c/this.barCtx.yRatio[d]+2*(this.barCtx.isReversed?c/this.barCtx.yRatio[d]:0)),v}},{key:"getGoalValues",value:function(c,u,d,v,m,x){var w=this,k=this.w,L=[],D=function(N,j){var U;L.push((h(U={},c,c==="x"?w.getXForValue(N,u,!1):w.getYForValue(N,d,x,!1)),h(U,"attrs",j),U))};if(k.globals.seriesGoals[v]&&k.globals.seriesGoals[v][m]&&Array.isArray(k.globals.seriesGoals[v][m])&&k.globals.seriesGoals[v][m].forEach(function(N){D(N.value,N)}),this.barCtx.barOptions.isDumbbell&&k.globals.seriesRange.length){var P=this.barCtx.barOptions.dumbbellColors?this.barCtx.barOptions.dumbbellColors:k.globals.colors,V={strokeHeight:c==="x"?0:k.globals.markers.size[v],strokeWidth:c==="x"?k.globals.markers.size[v]:0,strokeDashArray:0,strokeLineCap:"round",strokeColor:Array.isArray(P[v])?P[v][0]:P[v]};D(k.globals.seriesRangeStart[v][m],V),D(k.globals.seriesRangeEnd[v][m],i(i({},V),{},{strokeColor:Array.isArray(P[v])?P[v][1]:P[v]}))}return L}},{key:"drawGoalLine",value:function(c){var u=c.barXPosition,d=c.barYPosition,v=c.goalX,m=c.goalY,x=c.barWidth,w=c.barHeight,k=new $(this.barCtx.ctx),L=k.group({className:"apexcharts-bar-goals-groups"});L.node.classList.add("apexcharts-element-hidden"),this.barCtx.w.globals.delayedElements.push({el:L.node}),L.attr("clip-path","url(#gridRectMarkerMask".concat(this.barCtx.w.globals.cuid,")"));var D=null;return this.barCtx.isHorizontal?Array.isArray(v)&&v.forEach(function(P){if(P.x>=-1&&P.x<=k.w.globals.gridWidth+1){var V=P.attrs.strokeHeight!==void 0?P.attrs.strokeHeight:w/2,N=d+V+w/2;D=k.drawLine(P.x,N-2*V,P.x,N,P.attrs.strokeColor?P.attrs.strokeColor:void 0,P.attrs.strokeDashArray,P.attrs.strokeWidth?P.attrs.strokeWidth:2,P.attrs.strokeLineCap),L.add(D)}}):Array.isArray(m)&&m.forEach(function(P){if(P.y>=-1&&P.y<=k.w.globals.gridHeight+1){var V=P.attrs.strokeWidth!==void 0?P.attrs.strokeWidth:x/2,N=u+V+x/2;D=k.drawLine(N-2*V,P.y,N,P.y,P.attrs.strokeColor?P.attrs.strokeColor:void 0,P.attrs.strokeDashArray,P.attrs.strokeHeight?P.attrs.strokeHeight:2,P.attrs.strokeLineCap),L.add(D)}}),L}},{key:"drawBarShadow",value:function(c){var u=c.prevPaths,d=c.currPaths,v=c.color,m=this.w,x=u.x,w=u.x1,k=u.barYPosition,L=d.x,D=d.x1,P=d.barYPosition,V=k+d.barHeight,N=new $(this.barCtx.ctx),j=new E,U=N.move(w,V)+N.line(x,V)+N.line(L,P)+N.line(D,P)+N.line(w,V)+(m.config.plotOptions.bar.borderRadiusApplication==="around"?" Z":" z");return N.drawPath({d:U,fill:j.shadeColor(.5,E.rgb2hex(v)),stroke:"none",strokeWidth:0,fillOpacity:1,classes:"apexcharts-bar-shadows"})}},{key:"getZeroValueEncounters",value:function(c){var u,d=c.i,v=c.j,m=this.w,x=0,w=0;return(m.config.plotOptions.bar.horizontal?m.globals.series.map(function(k,L){return L}):((u=m.globals.columnSeries)===null||u===void 0?void 0:u.i.map(function(k){return k}))||[]).forEach(function(k){var L=m.globals.seriesPercent[k][v];L&&x++,k-1}),v=this.barCtx.columnGroupIndices,m=v.indexOf(d);return m<0&&(v.push(d),m=v.length-1),{groupIndex:d,columnGroupIndex:m}}}]),Q}(),Re=function(){function Q(c,u){a(this,Q),this.ctx=c,this.w=c.w;var d=this.w;this.barOptions=d.config.plotOptions.bar,this.isHorizontal=this.barOptions.horizontal,this.strokeWidth=d.config.stroke.width,this.isNullValue=!1,this.isRangeBar=d.globals.seriesRange.length&&this.isHorizontal,this.isVerticalGroupedRangeBar=!d.globals.isBarHorizontal&&d.globals.seriesRange.length&&d.config.plotOptions.bar.rangeBarGroupRows,this.isFunnel=this.barOptions.isFunnel,this.xyRatios=u,this.xyRatios!==null&&(this.xRatio=u.xRatio,this.yRatio=u.yRatio,this.invertedXRatio=u.invertedXRatio,this.invertedYRatio=u.invertedYRatio,this.baseLineY=u.baseLineY,this.baseLineInvertedY=u.baseLineInvertedY),this.yaxisIndex=0,this.translationsIndex=0,this.seriesLen=0,this.pathArr=[];var v=new Kt(this.ctx);this.lastActiveBarSerieIndex=v.getActiveConfigSeriesIndex("desc",["bar","column"]),this.columnGroupIndices=[];var m=v.getBarSeriesIndices(),x=new G(this.ctx);this.stackedSeriesTotals=x.getStackedSeriesTotals(this.w.config.series.map(function(w,k){return m.indexOf(k)===-1?k:-1}).filter(function(w){return w!==-1})),this.barHelpers=new Gt(this)}return l(Q,[{key:"draw",value:function(c,u){var d=this.w,v=new $(this.ctx),m=new G(this.ctx,d);c=m.getLogSeries(c),this.series=c,this.yRatio=m.getLogYRatios(this.yRatio),this.barHelpers.initVariables(c);var x=v.group({class:"apexcharts-bar-series apexcharts-plot-series"});d.config.dataLabels.enabled&&this.totalItems>this.barOptions.dataLabels.maxItems&&console.warn("WARNING: DataLabels are enabled but there are too many to display. This may cause performance issue when rendering - ApexCharts");for(var w=0,k=0;w0&&(this.visibleI=this.visibleI+1);var O=0,X=0;this.yRatio.length>1&&(this.yaxisIndex=d.globals.seriesYAxisReverseMap[J],this.translationsIndex=J);var ot=this.translationsIndex;this.isReversed=d.config.yaxis[this.yaxisIndex]&&d.config.yaxis[this.yaxisIndex].reversed;var nt=this.barHelpers.initialPositions();j=nt.y,O=nt.barHeight,D=nt.yDivision,V=nt.zeroW,N=nt.x,X=nt.barWidth,L=nt.xDivision,P=nt.zeroH,this.horizontal||q.push(N+X/2);var ct=v.group({class:"apexcharts-datalabels","data:realIndex":J});d.globals.delayedElements.push({el:ct.node}),ct.node.classList.add("apexcharts-element-hidden");var Ct=v.group({class:"apexcharts-bar-goals-markers"}),xt=v.group({class:"apexcharts-bar-shadows"});d.globals.delayedElements.push({el:xt.node}),xt.node.classList.add("apexcharts-element-hidden");for(var $t=0;$t0){var Te=this.barHelpers.drawBarShadow({color:typeof Me=="string"&&(Me==null?void 0:Me.indexOf("url"))===-1?Me:E.hexToRgba(d.globals.colors[w]),prevPaths:this.pathArr[this.pathArr.length-1],currPaths:Ot});Te&&xt.add(Te)}this.pathArr.push(Ot);var Ge=this.barHelpers.drawGoalLine({barXPosition:Ot.barXPosition,barYPosition:Ot.barYPosition,goalX:Ot.goalX,goalY:Ot.goalY,barHeight:O,barWidth:X});Ge&&Ct.add(Ge),j=Ot.y,N=Ot.x,$t>0&&q.push(N+X/2),U.push(j),this.renderSeries({realIndex:J,pathFill:Me,j:$t,i:w,columnGroupIndex:rt,pathFrom:Ot.pathFrom,pathTo:Ot.pathTo,strokeWidth:re,elSeries:A,x:N,y:j,series:c,barHeight:Math.abs(Ot.barHeight?Ot.barHeight:O),barWidth:Math.abs(Ot.barWidth?Ot.barWidth:X),elDataLabelsWrap:ct,elGoalsMarkers:Ct,elBarShadows:xt,visibleSeries:this.visibleI,type:"bar"})}d.globals.seriesXvalues[J]=q,d.globals.seriesYvalues[J]=U,x.add(A)}return x}},{key:"renderSeries",value:function(c){var u=c.realIndex,d=c.pathFill,v=c.lineFill,m=c.j,x=c.i,w=c.columnGroupIndex,k=c.pathFrom,L=c.pathTo,D=c.strokeWidth,P=c.elSeries,V=c.x,N=c.y,j=c.y1,U=c.y2,q=c.series,J=c.barHeight,rt=c.barWidth,A=c.barXPosition,O=c.barYPosition,X=c.elDataLabelsWrap,ot=c.elGoalsMarkers,nt=c.elBarShadows,ct=c.visibleSeries,Ct=c.type,xt=this.w,$t=new $(this.ctx);if(!v){var re=typeof xt.globals.stroke.colors[u]=="function"?function(Ge){var Ye,l1=xt.config.stroke.colors;return Array.isArray(l1)&&l1.length>0&&((Ye=l1[Ge])||(Ye=""),typeof Ye=="function")?Ye({value:xt.globals.series[Ge][m],dataPointIndex:m,w:xt}):Ye}(u):xt.globals.stroke.colors[u];v=this.barOptions.distributed?xt.globals.stroke.colors[m]:re}xt.config.series[x].data[m]&&xt.config.series[x].data[m].strokeColor&&(v=xt.config.series[x].data[m].strokeColor),this.isNullValue&&(d="none");var Ot=m/xt.config.chart.animations.animateGradually.delay*(xt.config.chart.animations.speed/xt.globals.dataPoints)/2.4,Qt=$t.renderPaths({i:x,j:m,realIndex:u,pathFrom:k,pathTo:L,stroke:v,strokeWidth:D,strokeLineCap:xt.config.stroke.lineCap,fill:d,animationDelay:Ot,initialSpeed:xt.config.chart.animations.speed,dataChangeSpeed:xt.config.chart.animations.dynamicAnimation.speed,className:"apexcharts-".concat(Ct,"-area")});Qt.attr("clip-path","url(#gridRectMask".concat(xt.globals.cuid,")"));var Me=xt.config.forecastDataPoints;Me.count>0&&m>=xt.globals.dataPoints-Me.count&&(Qt.node.setAttribute("stroke-dasharray",Me.dashArray),Qt.node.setAttribute("stroke-width",Me.strokeWidth),Qt.node.setAttribute("fill-opacity",Me.fillOpacity)),j!==void 0&&U!==void 0&&(Qt.attr("data-range-y1",j),Qt.attr("data-range-y2",U)),new W(this.ctx).setSelectionFilter(Qt,u,m),P.add(Qt);var Te=new ze(this).handleBarDataLabels({x:V,y:N,y1:j,y2:U,i:x,j:m,series:q,realIndex:u,columnGroupIndex:w,barHeight:J,barWidth:rt,barXPosition:A,barYPosition:O,renderedPath:Qt,visibleSeries:ct});return Te.dataLabels!==null&&X.add(Te.dataLabels),Te.totalDataLabels&&X.add(Te.totalDataLabels),P.add(X),ot&&P.add(ot),nt&&P.add(nt),P}},{key:"drawBarPaths",value:function(c){var u,d=c.indexes,v=c.barHeight,m=c.strokeWidth,x=c.zeroW,w=c.x,k=c.y,L=c.yDivision,D=c.elSeries,P=this.w,V=d.i,N=d.j;if(P.globals.isXNumeric)u=(k=(P.globals.seriesX[V][N]-P.globals.minX)/this.invertedXRatio-v)+v*this.visibleI;else if(P.config.plotOptions.bar.hideZeroBarsWhenGrouped){var j=0,U=0;P.globals.seriesPercent.forEach(function(J,rt){J[N]&&j++,rt0&&(v=this.seriesLen*v/j),u=k+v*this.visibleI,u-=v*U}else u=k+v*this.visibleI;this.isFunnel&&(x-=(this.barHelpers.getXForValue(this.series[V][N],x)-x)/2),w=this.barHelpers.getXForValue(this.series[V][N],x);var q=this.barHelpers.getBarpaths({barYPosition:u,barHeight:v,x1:x,x2:w,strokeWidth:m,series:this.series,realIndex:d.realIndex,i:V,j:N,w:P});return P.globals.isXNumeric||(k+=L),this.barHelpers.barBackground({j:N,i:V,y1:u-v*this.visibleI,y2:v*this.seriesLen,elSeries:D}),{pathTo:q.pathTo,pathFrom:q.pathFrom,x1:x,x:w,y:k,goalX:this.barHelpers.getGoalValues("x",x,null,V,N),barYPosition:u,barHeight:v}}},{key:"drawColumnPaths",value:function(c){var u,d=c.indexes,v=c.x,m=c.y,x=c.xDivision,w=c.barWidth,k=c.zeroH,L=c.strokeWidth,D=c.elSeries,P=this.w,V=d.realIndex,N=d.translationsIndex,j=d.i,U=d.j,q=d.bc;if(P.globals.isXNumeric){var J=this.getBarXForNumericXAxis({x:v,j:U,realIndex:V,barWidth:w});v=J.x,u=J.barXPosition}else if(P.config.plotOptions.bar.hideZeroBarsWhenGrouped){var rt=this.barHelpers.getZeroValueEncounters({i:j,j:U}),A=rt.nonZeroColumns,O=rt.zeroEncounters;A>0&&(w=this.seriesLen*w/A),u=v+w*this.visibleI,u-=w*O}else u=v+w*this.visibleI;m=this.barHelpers.getYForValue(this.series[j][U],k,N);var X=this.barHelpers.getColumnPaths({barXPosition:u,barWidth:w,y1:k,y2:m,strokeWidth:L,series:this.series,realIndex:V,i:j,j:U,w:P});return P.globals.isXNumeric||(v+=x),this.barHelpers.barBackground({bc:q,j:U,i:j,x1:u-L/2-w*this.visibleI,x2:w*this.seriesLen+L/2,elSeries:D}),{pathTo:X.pathTo,pathFrom:X.pathFrom,x:v,y:m,goalY:this.barHelpers.getGoalValues("y",null,k,j,U,N),barXPosition:u,barWidth:w}}},{key:"getBarXForNumericXAxis",value:function(c){var u=c.x,d=c.barWidth,v=c.realIndex,m=c.j,x=this.w,w=v;return x.globals.seriesX[v].length||(w=x.globals.maxValsInArrayIndex),x.globals.seriesX[w][m]&&(u=(x.globals.seriesX[w][m]-x.globals.minX)/this.xRatio-d*this.seriesLen/2),{barXPosition:u+d*this.visibleI,x:u}}},{key:"getPreviousPath",value:function(c,u){for(var d,v=this.w,m=0;m0&&parseInt(x.realIndex,10)===parseInt(c,10)&&v.globals.previousPaths[m].paths[u]!==void 0&&(d=v.globals.previousPaths[m].paths[u].d)}return d}}]),Q}(),je=function(Q){p(u,Re);var c=z(u);function u(){return a(this,u),c.apply(this,arguments)}return l(u,[{key:"draw",value:function(d,v){var m=this,x=this.w;this.graphics=new $(this.ctx),this.bar=new Re(this.ctx,this.xyRatios);var w=new G(this.ctx,x);d=w.getLogSeries(d),this.yRatio=w.getLogYRatios(this.yRatio),this.barHelpers.initVariables(d),x.config.chart.stackType==="100%"&&(d=x.globals.comboCharts?v.map(function(j){return x.globals.seriesPercent[j]}):x.globals.seriesPercent.slice()),this.series=d,this.barHelpers.initializeStackedPrevVars(this);for(var k=this.graphics.group({class:"apexcharts-bar-series apexcharts-plot-series"}),L=0,D=0,P=function(j,U){var q=void 0,J=void 0,rt=void 0,A=void 0,O=x.globals.comboCharts?v[j]:j,X=m.barHelpers.getGroupIndex(O),ot=X.groupIndex,nt=X.columnGroupIndex;m.groupCtx=m[x.globals.seriesGroups[ot]];var ct=[],Ct=[],xt=0;m.yRatio.length>1&&(m.yaxisIndex=x.globals.seriesYAxisReverseMap[O][0],xt=O),m.isReversed=x.config.yaxis[m.yaxisIndex]&&x.config.yaxis[m.yaxisIndex].reversed;var $t=m.graphics.group({class:"apexcharts-series",seriesName:E.escapeString(x.globals.seriesNames[O]),rel:j+1,"data:realIndex":O});m.ctx.series.addCollapsedClassToSeries($t,O);var re=m.graphics.group({class:"apexcharts-datalabels","data:realIndex":O}),Ot=m.graphics.group({class:"apexcharts-bar-goals-markers"}),Qt=0,Me=0,Te=m.initialPositions(L,D,q,J,rt,A,xt);D=Te.y,Qt=Te.barHeight,J=Te.yDivision,A=Te.zeroW,L=Te.x,Me=Te.barWidth,q=Te.xDivision,rt=Te.zeroH,x.globals.barHeight=Qt,x.globals.barWidth=Me,m.barHelpers.initializeStackedXYVars(m),m.groupCtx.prevY.length===1&&m.groupCtx.prevY[0].every(function(_r){return isNaN(_r)})&&(m.groupCtx.prevY[0]=m.groupCtx.prevY[0].map(function(){return rt}),m.groupCtx.prevYF[0]=m.groupCtx.prevYF[0].map(function(){return 0}));for(var Ge=0;Ge1?P=(m=V.globals.minXDiff/this.xRatio)*parseInt(this.barOptions.columnWidth,10)/100:String(j).indexOf("%")===-1?P=parseInt(j,10):P*=parseInt(j,10)/100,w=V.globals.gridHeight-this.baseLineY[L]-(this.isReversed?V.globals.gridHeight:0),d=V.globals.padHorizontal+(m-P)/2}var U=V.globals.barGroups.length||1;return{x:d,y:v,yDivision:x,xDivision:m,barHeight:D/U,barWidth:P/U,zeroH:w,zeroW:k}}},{key:"drawStackedBarPaths",value:function(d){for(var v,m=d.indexes,x=d.barHeight,w=d.strokeWidth,k=d.zeroW,L=d.x,D=d.y,P=d.columnGroupIndex,V=d.seriesGroup,N=d.yDivision,j=d.elSeries,U=this.w,q=D+P*x,J=m.i,rt=m.j,A=m.realIndex,O=m.translationsIndex,X=0,ot=0;ot0){var ct=k;this.groupCtx.prevXVal[nt-1][rt]<0?ct=this.series[J][rt]>=0?this.groupCtx.prevX[nt-1][rt]+X-2*(this.isReversed?X:0):this.groupCtx.prevX[nt-1][rt]:this.groupCtx.prevXVal[nt-1][rt]>=0&&(ct=this.series[J][rt]>=0?this.groupCtx.prevX[nt-1][rt]:this.groupCtx.prevX[nt-1][rt]-X+2*(this.isReversed?X:0)),v=ct}else v=k;L=this.series[J][rt]===null?v:v+this.series[J][rt]/this.invertedYRatio-2*(this.isReversed?this.series[J][rt]/this.invertedYRatio:0);var Ct=this.barHelpers.getBarpaths({barYPosition:q,barHeight:x,x1:v,x2:L,strokeWidth:w,series:this.series,realIndex:m.realIndex,seriesGroup:V,i:J,j:rt,w:U});return this.barHelpers.barBackground({j:rt,i:J,y1:q,y2:x,elSeries:j}),D+=N,{pathTo:Ct.pathTo,pathFrom:Ct.pathFrom,goalX:this.barHelpers.getGoalValues("x",k,null,J,rt,O),barXPosition:v,barYPosition:q,x:L,y:D}}},{key:"drawStackedColumnPaths",value:function(d){var v=d.indexes,m=d.x,x=d.y,w=d.xDivision,k=d.barWidth,L=d.zeroH,D=d.columnGroupIndex,P=d.seriesGroup,V=d.elSeries,N=this.w,j=v.i,U=v.j,q=v.bc,J=v.realIndex,rt=v.translationsIndex;if(N.globals.isXNumeric){var A=N.globals.seriesX[J][U];A||(A=0),m=(A-N.globals.minX)/this.xRatio-k/2*N.globals.barGroups.length}for(var O,X=m+D*k,ot=0,nt=0;nt0&&!N.globals.isXNumeric||ct>0&&N.globals.isXNumeric&&N.globals.seriesX[J-1][U]===N.globals.seriesX[J][U]){var Ct,xt,$t,re=Math.min(this.yRatio.length+1,J+1);if(this.groupCtx.prevY[ct-1]!==void 0&&this.groupCtx.prevY[ct-1].length)for(var Ot=1;Ot=0?$t-ot+2*(this.isReversed?ot:0):$t;break}if(((Ge=this.groupCtx.prevYVal[ct-Me])===null||Ge===void 0?void 0:Ge[U])>=0){xt=this.series[j][U]>=0?$t:$t+ot-2*(this.isReversed?ot:0);break}}xt===void 0&&(xt=N.globals.gridHeight),O=(Ct=this.groupCtx.prevYF[0])!==null&&Ct!==void 0&&Ct.every(function(l1){return l1===0})&&this.groupCtx.prevYF.slice(1,ct).every(function(l1){return l1.every(function(i1){return isNaN(i1)})})?L:xt}else O=L;x=this.series[j][U]?O-this.series[j][U]/this.yRatio[rt]+2*(this.isReversed?this.series[j][U]/this.yRatio[rt]:0):O;var Ye=this.barHelpers.getColumnPaths({barXPosition:X,barWidth:k,y1:O,y2:x,yRatio:this.yRatio[rt],strokeWidth:this.strokeWidth,series:this.series,seriesGroup:P,realIndex:v.realIndex,i:j,j:U,w:N});return this.barHelpers.barBackground({bc:q,j:U,i:j,x1:X,x2:k,elSeries:V}),{pathTo:Ye.pathTo,pathFrom:Ye.pathFrom,goalY:this.barHelpers.getGoalValues("y",null,L,j,U),barXPosition:X,x:N.globals.isXNumeric?m:m+w,y:x}}}]),u}(),d1=function(Q){p(u,Re);var c=z(u);function u(){return a(this,u),c.apply(this,arguments)}return l(u,[{key:"draw",value:function(d,v,m){var x=this,w=this.w,k=new $(this.ctx),L=w.globals.comboCharts?v:w.config.chart.type,D=new Lt(this.ctx);this.candlestickOptions=this.w.config.plotOptions.candlestick,this.boxOptions=this.w.config.plotOptions.boxPlot,this.isHorizontal=w.config.plotOptions.bar.horizontal;var P=new G(this.ctx,w);d=P.getLogSeries(d),this.series=d,this.yRatio=P.getLogYRatios(this.yRatio),this.barHelpers.initVariables(d);for(var V=k.group({class:"apexcharts-".concat(L,"-series apexcharts-plot-series")}),N=function(U){x.isBoxPlot=w.config.chart.type==="boxPlot"||w.config.series[U].type==="boxPlot";var q,J,rt,A,O=void 0,X=void 0,ot=[],nt=[],ct=w.globals.comboCharts?m[U]:U,Ct=x.barHelpers.getGroupIndex(ct).columnGroupIndex,xt=k.group({class:"apexcharts-series",seriesName:E.escapeString(w.globals.seriesNames[ct]),rel:U+1,"data:realIndex":ct});x.ctx.series.addCollapsedClassToSeries(xt,ct),d[U].length>0&&(x.visibleI=x.visibleI+1);var $t,re,Ot=0;x.yRatio.length>1&&(x.yaxisIndex=w.globals.seriesYAxisReverseMap[ct][0],Ot=ct);var Qt=x.barHelpers.initialPositions();X=Qt.y,$t=Qt.barHeight,J=Qt.yDivision,A=Qt.zeroW,O=Qt.x,re=Qt.barWidth,q=Qt.xDivision,rt=Qt.zeroH,nt.push(O+re/2);for(var Me=k.group({class:"apexcharts-datalabels","data:realIndex":ct}),Te=function(Ye){var l1=x.barHelpers.getStrokeWidth(U,Ye,ct),i1=null,g1={indexes:{i:U,j:Ye,realIndex:ct,translationsIndex:Ot},x:O,y:X,strokeWidth:l1,elSeries:xt};i1=x.isHorizontal?x.drawHorizontalBoxPaths(i(i({},g1),{},{yDivision:J,barHeight:$t,zeroW:A})):x.drawVerticalBoxPaths(i(i({},g1),{},{xDivision:q,barWidth:re,zeroH:rt})),X=i1.y,O=i1.x,Ye>0&&nt.push(O+re/2),ot.push(X),i1.pathTo.forEach(function(yr,_r){var pr=!x.isBoxPlot&&x.candlestickOptions.wick.useFillColor?i1.color[_r]:w.globals.stroke.colors[U],Ri=D.fillPath({seriesNumber:ct,dataPointIndex:Ye,color:i1.color[_r],value:d[U][Ye]});x.renderSeries({realIndex:ct,pathFill:Ri,lineFill:pr,j:Ye,i:U,pathFrom:i1.pathFrom,pathTo:yr,strokeWidth:l1,elSeries:xt,x:O,y:X,series:d,columnGroupIndex:Ct,barHeight:$t,barWidth:re,elDataLabelsWrap:Me,visibleSeries:x.visibleI,type:w.config.chart.type})})},Ge=0;GeO.c&&(j=!1);var nt=Math.min(O.o,O.c),ct=Math.max(O.o,O.c),Ct=O.m;D.globals.isXNumeric&&(m=(D.globals.seriesX[A][N]-D.globals.minX)/this.xRatio-w/2);var xt=m+w*this.visibleI;this.series[V][N]===void 0||this.series[V][N]===null?(nt=k,ct=k):(nt=k-nt/rt,ct=k-ct/rt,X=k-O.h/rt,ot=k-O.l/rt,Ct=k-O.m/rt);var $t=P.move(xt,k),re=P.move(xt+w/2,nt);return D.globals.previousPaths.length>0&&(re=this.getPreviousPath(A,N,!0)),$t=this.isBoxPlot?[P.move(xt,nt)+P.line(xt+w/2,nt)+P.line(xt+w/2,X)+P.line(xt+w/4,X)+P.line(xt+w-w/4,X)+P.line(xt+w/2,X)+P.line(xt+w/2,nt)+P.line(xt+w,nt)+P.line(xt+w,Ct)+P.line(xt,Ct)+P.line(xt,nt+L/2),P.move(xt,Ct)+P.line(xt+w,Ct)+P.line(xt+w,ct)+P.line(xt+w/2,ct)+P.line(xt+w/2,ot)+P.line(xt+w-w/4,ot)+P.line(xt+w/4,ot)+P.line(xt+w/2,ot)+P.line(xt+w/2,ct)+P.line(xt,ct)+P.line(xt,Ct)+"z"]:[P.move(xt,ct)+P.line(xt+w/2,ct)+P.line(xt+w/2,X)+P.line(xt+w/2,ct)+P.line(xt+w,ct)+P.line(xt+w,nt)+P.line(xt+w/2,nt)+P.line(xt+w/2,ot)+P.line(xt+w/2,nt)+P.line(xt,nt)+P.line(xt,ct-L/2)],re+=P.move(xt,nt),D.globals.isXNumeric||(m+=x),{pathTo:$t,pathFrom:re,x:m,y:ct,barXPosition:xt,color:this.isBoxPlot?J:j?[U]:[q]}}},{key:"drawHorizontalBoxPaths",value:function(d){var v=d.indexes;d.x;var m=d.y,x=d.yDivision,w=d.barHeight,k=d.zeroW,L=d.strokeWidth,D=this.w,P=new $(this.ctx),V=v.i,N=v.j,j=this.boxOptions.colors.lower;this.isBoxPlot&&(j=[this.boxOptions.colors.lower,this.boxOptions.colors.upper]);var U=this.invertedYRatio,q=v.realIndex,J=this.getOHLCValue(q,N),rt=k,A=k,O=Math.min(J.o,J.c),X=Math.max(J.o,J.c),ot=J.m;D.globals.isXNumeric&&(m=(D.globals.seriesX[q][N]-D.globals.minX)/this.invertedXRatio-w/2);var nt=m+w*this.visibleI;this.series[V][N]===void 0||this.series[V][N]===null?(O=k,X=k):(O=k+O/U,X=k+X/U,rt=k+J.h/U,A=k+J.l/U,ot=k+J.m/U);var ct=P.move(k,nt),Ct=P.move(O,nt+w/2);return D.globals.previousPaths.length>0&&(Ct=this.getPreviousPath(q,N,!0)),ct=[P.move(O,nt)+P.line(O,nt+w/2)+P.line(rt,nt+w/2)+P.line(rt,nt+w/2-w/4)+P.line(rt,nt+w/2+w/4)+P.line(rt,nt+w/2)+P.line(O,nt+w/2)+P.line(O,nt+w)+P.line(ot,nt+w)+P.line(ot,nt)+P.line(O+L/2,nt),P.move(ot,nt)+P.line(ot,nt+w)+P.line(X,nt+w)+P.line(X,nt+w/2)+P.line(A,nt+w/2)+P.line(A,nt+w-w/4)+P.line(A,nt+w/4)+P.line(A,nt+w/2)+P.line(X,nt+w/2)+P.line(X,nt)+P.line(ot,nt)+"z"],Ct+=P.move(O,nt),D.globals.isXNumeric||(m+=x),{pathTo:ct,pathFrom:Ct,x:X,y:m,barYPosition:nt,color:j}}},{key:"getOHLCValue",value:function(d,v){var m=this.w;return{o:this.isBoxPlot?m.globals.seriesCandleH[d][v]:m.globals.seriesCandleO[d][v],h:this.isBoxPlot?m.globals.seriesCandleO[d][v]:m.globals.seriesCandleH[d][v],m:m.globals.seriesCandleM[d][v],l:this.isBoxPlot?m.globals.seriesCandleC[d][v]:m.globals.seriesCandleL[d][v],c:this.isBoxPlot?m.globals.seriesCandleL[d][v]:m.globals.seriesCandleC[d][v]}}}]),u}(),K1=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w}return l(Q,[{key:"checkColorRange",value:function(){var c=this.w,u=!1,d=c.config.plotOptions[c.config.chart.type];return d.colorScale.ranges.length>0&&d.colorScale.ranges.map(function(v,m){v.from<=0&&(u=!0)}),u}},{key:"getShadeColor",value:function(c,u,d,v){var m=this.w,x=1,w=m.config.plotOptions[c].shadeIntensity,k=this.determineColor(c,u,d);m.globals.hasNegs||v?x=m.config.plotOptions[c].reverseNegativeShade?k.percent<0?k.percent/100*(1.25*w):(1-k.percent/100)*(1.25*w):k.percent<=0?1-(1+k.percent/100)*w:(1-k.percent/100)*w:(x=1-k.percent/100,c==="treemap"&&(x=(1-k.percent/100)*(1.25*w)));var L=k.color,D=new E;return m.config.plotOptions[c].enableShades&&(L=this.w.config.theme.mode==="dark"?E.hexToRgba(D.shadeColor(-1*x,k.color),m.config.fill.opacity):E.hexToRgba(D.shadeColor(x,k.color),m.config.fill.opacity)),{color:L,colorProps:k}}},{key:"determineColor",value:function(c,u,d){var v=this.w,m=v.globals.series[u][d],x=v.config.plotOptions[c],w=x.colorScale.inverse?d:u;x.distributed&&v.config.chart.type==="treemap"&&(w=d);var k=v.globals.colors[w],L=null,D=Math.min.apply(Math,I(v.globals.series[u])),P=Math.max.apply(Math,I(v.globals.series[u]));x.distributed||c!=="heatmap"||(D=v.globals.minY,P=v.globals.maxY),x.colorScale.min!==void 0&&(D=x.colorScale.minv.globals.maxY?x.colorScale.max:v.globals.maxY);var V=Math.abs(P)+Math.abs(D),N=100*m/(V===0?V-1e-6:V);return x.colorScale.ranges.length>0&&x.colorScale.ranges.map(function(j,U){if(m>=j.from&&m<=j.to){k=j.color,L=j.foreColor?j.foreColor:null,D=j.from,P=j.to;var q=Math.abs(P)+Math.abs(D);N=100*m/(q===0?q-1e-6:q)}}),{color:k,foreColor:L,percent:N}}},{key:"calculateDataLabels",value:function(c){var u=c.text,d=c.x,v=c.y,m=c.i,x=c.j,w=c.colorProps,k=c.fontSize,L=this.w.config.dataLabels,D=new $(this.ctx),P=new Ut(this.ctx),V=null;if(L.enabled){V=D.group({class:"apexcharts-data-labels"});var N=L.offsetX,j=L.offsetY,U=d+N,q=v+parseFloat(L.style.fontSize)/3+j;P.plotDataLabelsText({x:U,y:q,text:u,i:m,j:x,color:w.foreColor,parent:V,fontSize:k,dataLabelsConfig:L})}return V}},{key:"addListeners",value:function(c){var u=new $(this.ctx);c.node.addEventListener("mouseenter",u.pathMouseEnter.bind(this,c)),c.node.addEventListener("mouseleave",u.pathMouseLeave.bind(this,c)),c.node.addEventListener("mousedown",u.pathMouseDown.bind(this,c))}}]),Q}(),Oe=function(){function Q(c,u){a(this,Q),this.ctx=c,this.w=c.w,this.xRatio=u.xRatio,this.yRatio=u.yRatio,this.dynamicAnim=this.w.config.chart.animations.dynamicAnimation,this.helpers=new K1(c),this.rectRadius=this.w.config.plotOptions.heatmap.radius,this.strokeWidth=this.w.config.stroke.show?this.w.config.stroke.width:0}return l(Q,[{key:"draw",value:function(c){var u=this.w,d=new $(this.ctx),v=d.group({class:"apexcharts-heatmap"});v.attr("clip-path","url(#gridRectMask".concat(u.globals.cuid,")"));var m=u.globals.gridWidth/u.globals.dataPoints,x=u.globals.gridHeight/u.globals.series.length,w=0,k=!1;this.negRange=this.helpers.checkColorRange();var L=c.slice();u.config.yaxis[0].reversed&&(k=!0,L.reverse());for(var D=k?0:L.length-1;k?D=0;k?D++:D--){var P=d.group({class:"apexcharts-series apexcharts-heatmap-series",seriesName:E.escapeString(u.globals.seriesNames[D]),rel:D+1,"data:realIndex":D});if(this.ctx.series.addCollapsedClassToSeries(P,D),u.config.chart.dropShadow.enabled){var V=u.config.chart.dropShadow;new W(this.ctx).dropShadow(P,V,D)}for(var N=0,j=u.config.plotOptions.heatmap.shadeIntensity,U=0;U-1&&this.pieClicked(V),d.config.dataLabels.enabled){var X=A.x,ot=A.y,nt=100*j/this.fullAngle+"%";if(j!==0&&d.config.plotOptions.pie.dataLabels.minAngleToShowLabelthis.fullAngle?u.endAngle=u.endAngle-(v+w):v+w=this.fullAngle+this.w.config.plotOptions.pie.startAngle%this.fullAngle&&(D=this.fullAngle+this.w.config.plotOptions.pie.startAngle%this.fullAngle-.01),Math.ceil(D)>this.fullAngle&&(D-=this.fullAngle);var P=Math.PI*(D-90)/180,V=d.centerX+x*Math.cos(L),N=d.centerY+x*Math.sin(L),j=d.centerX+x*Math.cos(P),U=d.centerY+x*Math.sin(P),q=E.polarToCartesian(d.centerX,d.centerY,d.donutSize,D),J=E.polarToCartesian(d.centerX,d.centerY,d.donutSize,k),rt=m>180?1:0,A=["M",V,N,"A",x,x,0,rt,1,j,U];return u=d.chartType==="donut"?[].concat(A,["L",q.x,q.y,"A",d.donutSize,d.donutSize,0,rt,0,J.x,J.y,"L",V,N,"z"]).join(" "):d.chartType==="pie"||d.chartType==="polarArea"?[].concat(A,["L",d.centerX,d.centerY,"L",V,N]).join(" "):[].concat(A).join(" "),w.roundPathCorners(u,2*this.strokeWidth)}},{key:"drawPolarElements",value:function(c){var u=this.w,d=new Ft(this.ctx),v=new $(this.ctx),m=new Ae(this.ctx),x=v.group(),w=v.group(),k=d.niceScale(0,Math.ceil(this.maxY),0),L=k.result.reverse(),D=k.result.length;this.maxY=k.niceMax;for(var P=u.globals.radialSize,V=P/(D-1),N=0;N1&&c.total.show&&(m=c.total.color);var w=x.globals.dom.baseEl.querySelector(".apexcharts-datalabel-label"),k=x.globals.dom.baseEl.querySelector(".apexcharts-datalabel-value");d=(0,c.value.formatter)(d,x),v||typeof c.total.formatter!="function"||(d=c.total.formatter(x));var L=u===c.total.label;u=c.name.formatter(u,L,x),w!==null&&(w.textContent=u),k!==null&&(k.textContent=d),w!==null&&(w.style.fill=m)}},{key:"printDataLabelsInner",value:function(c,u){var d=this.w,v=c.getAttribute("data:value"),m=d.globals.seriesNames[parseInt(c.parentNode.getAttribute("rel"),10)-1];d.globals.series.length>1&&this.printInnerLabels(u,m,v,c);var x=d.globals.dom.baseEl.querySelector(".apexcharts-datalabels-group");x!==null&&(x.style.opacity=1)}},{key:"drawSpokes",value:function(c){var u=this,d=this.w,v=new $(this.ctx),m=d.config.plotOptions.polarArea.spokes;if(m.strokeWidth!==0){for(var x=[],w=360/d.globals.series.length,k=0;k0&&(ot=u.getPreviousPath(J));for(var nt=0;nt=10?c.x>0?(d="start",v+=10):c.x<0&&(d="end",v-=10):d="middle",Math.abs(c.y)>=u-10&&(c.y<0?m-=10:c.y>0&&(m+=10)),{textAnchor:d,newX:v,newY:m}}},{key:"getPreviousPath",value:function(c){for(var u=this.w,d=null,v=0;v0&&parseInt(m.realIndex,10)===parseInt(c,10)&&u.globals.previousPaths[v].paths[0]!==void 0&&(d=u.globals.previousPaths[v].paths[0].d)}return d}},{key:"getDataPointsPos",value:function(c,u){var d=arguments.length>2&&arguments[2]!==void 0?arguments[2]:this.dataPointsLen;c=c||[],u=u||[];for(var v=[],m=0;m=360&&(U=360-Math.abs(this.startAngle)-.1);var q=m.drawPath({d:"",stroke:N,strokeWidth:L*parseInt(V.strokeWidth,10)/100,fill:"none",strokeOpacity:V.opacity,classes:"apexcharts-radialbar-area"});if(V.dropShadow.enabled){var J=V.dropShadow;w.dropShadow(q,J)}P.add(q),q.attr("id","apexcharts-radialbarTrack-"+D),this.animatePaths(q,{centerX:d.centerX,centerY:d.centerY,endAngle:U,startAngle:j,size:d.size,i:D,totalItems:2,animBeginArr:0,dur:0,isTrack:!0,easing:v.globals.easing})}return x}},{key:"drawArcs",value:function(d){var v=this.w,m=new $(this.ctx),x=new Lt(this.ctx),w=new W(this.ctx),k=m.group(),L=this.getStrokeWidth(d);d.size=d.size-L/2;var D=v.config.plotOptions.radialBar.hollow.background,P=d.size-L*d.series.length-this.margin*d.series.length-L*parseInt(v.config.plotOptions.radialBar.track.strokeWidth,10)/100/2,V=P-v.config.plotOptions.radialBar.hollow.margin;v.config.plotOptions.radialBar.hollow.image!==void 0&&(D=this.drawHollowImage(d,k,P,D));var N=this.drawHollow({size:V,centerX:d.centerX,centerY:d.centerY,fill:D||"transparent"});if(v.config.plotOptions.radialBar.hollow.dropShadow.enabled){var j=v.config.plotOptions.radialBar.hollow.dropShadow;w.dropShadow(N,j)}var U=1;!this.radialDataLabels.total.show&&v.globals.series.length>1&&(U=0);var q=null;if(this.radialDataLabels.show){var J=v.globals.dom.Paper.select(".apexcharts-datalabels-group").members[0];q=this.renderInnerDataLabels(J,this.radialDataLabels,{hollowSize:P,centerX:d.centerX,centerY:d.centerY,opacity:U})}v.config.plotOptions.radialBar.hollow.position==="back"&&(k.add(N),q&&k.add(q));var rt=!1;v.config.plotOptions.radialBar.inverseOrder&&(rt=!0);for(var A=rt?d.series.length-1:0;rt?A>=0:A100?100:d.series[A])/100,Ct=Math.round(this.totalAngle*ct)+this.startAngle,xt=void 0;v.globals.dataChanged&&(nt=this.startAngle,xt=Math.round(this.totalAngle*E.negToZero(v.globals.previousPaths[A])/100)+nt),Math.abs(Ct)+Math.abs(ot)>=360&&(Ct-=.01),Math.abs(xt)+Math.abs(nt)>=360&&(xt-=.01);var $t=Ct-ot,re=Array.isArray(v.config.stroke.dashArray)?v.config.stroke.dashArray[A]:v.config.stroke.dashArray,Ot=m.drawPath({d:"",stroke:X,strokeWidth:L,fill:"none",fillOpacity:v.config.fill.opacity,classes:"apexcharts-radialbar-area apexcharts-radialbar-slice-"+A,strokeDashArray:re});if($.setAttrs(Ot.node,{"data:angle":$t,"data:value":d.series[A]}),v.config.chart.dropShadow.enabled){var Qt=v.config.chart.dropShadow;w.dropShadow(Ot,Qt,A)}if(w.setSelectionFilter(Ot,0,A),this.addListeners(Ot,this.radialDataLabels),O.add(Ot),Ot.attr({index:0,j:A}),this.barLabels.enabled){var Me=E.polarToCartesian(d.centerX,d.centerY,d.size,ot),Te=this.barLabels.formatter(v.globals.seriesNames[A],{seriesIndex:A,w:v}),Ge=["apexcharts-radialbar-label"];this.barLabels.onClick||Ge.push("apexcharts-no-click");var Ye=this.barLabels.useSeriesColors?v.globals.colors[A]:v.config.chart.foreColor;Ye||(Ye=v.config.chart.foreColor);var l1=Me.x+this.barLabels.offsetX,i1=Me.y+this.barLabels.offsetY,g1=m.drawText({x:l1,y:i1,text:Te,textAnchor:"end",dominantBaseline:"middle",fontFamily:this.barLabels.fontFamily,fontWeight:this.barLabels.fontWeight,fontSize:this.barLabels.fontSize,foreColor:Ye,cssClass:Ge.join(" ")});g1.on("click",this.onBarLabelClick),g1.attr({rel:A+1}),ot!==0&&g1.attr({"transform-origin":"".concat(l1," ").concat(i1),transform:"rotate(".concat(ot," 0 0)")}),O.add(g1)}var yr=0;!this.initialAnim||v.globals.resized||v.globals.dataChanged||(yr=v.config.chart.animations.speed),v.globals.dataChanged&&(yr=v.config.chart.animations.dynamicAnimation.speed),this.animDur=yr/(1.2*d.series.length)+this.animDur,this.animBeginArr.push(this.animDur),this.animatePaths(Ot,{centerX:d.centerX,centerY:d.centerY,endAngle:Ct,startAngle:ot,prevEndAngle:xt,prevStartAngle:nt,size:d.size,i:A,totalItems:2,animBeginArr:this.animBeginArr,dur:yr,shouldSetPrevPaths:!0,easing:v.globals.easing})}return{g:k,elHollow:N,dataLabels:q}}},{key:"drawHollow",value:function(d){var v=new $(this.ctx).drawCircle(2*d.size);return v.attr({class:"apexcharts-radialbar-hollow",cx:d.centerX,cy:d.centerY,r:d.size,fill:d.fill}),v}},{key:"drawHollowImage",value:function(d,v,m,x){var w=this.w,k=new Lt(this.ctx),L=E.randomId(),D=w.config.plotOptions.radialBar.hollow.image;if(w.config.plotOptions.radialBar.hollow.imageClipped)k.clippedImgArea({width:m,height:m,image:D,patternID:"pattern".concat(w.globals.cuid).concat(L)}),x="url(#pattern".concat(w.globals.cuid).concat(L,")");else{var P=w.config.plotOptions.radialBar.hollow.imageWidth,V=w.config.plotOptions.radialBar.hollow.imageHeight;if(P===void 0&&V===void 0){var N=w.globals.dom.Paper.image(D).loaded(function(U){this.move(d.centerX-U.width/2+w.config.plotOptions.radialBar.hollow.imageOffsetX,d.centerY-U.height/2+w.config.plotOptions.radialBar.hollow.imageOffsetY)});v.add(N)}else{var j=w.globals.dom.Paper.image(D).loaded(function(U){this.move(d.centerX-P/2+w.config.plotOptions.radialBar.hollow.imageOffsetX,d.centerY-V/2+w.config.plotOptions.radialBar.hollow.imageOffsetY),this.size(P,V)});v.add(j)}}return x}},{key:"getStrokeWidth",value:function(d){var v=this.w;return d.size*(100-parseInt(v.config.plotOptions.radialBar.hollow.size,10))/100/(d.series.length+1)-this.margin}},{key:"onBarLabelClick",value:function(d){var v=parseInt(d.target.getAttribute("rel"),10)-1,m=this.barLabels.onClick,x=this.w;m&&m(x.globals.seriesNames[v],{w:x,seriesIndex:v})}}]),u}(),ti=function(Q){p(u,Re);var c=z(u);function u(){return a(this,u),c.apply(this,arguments)}return l(u,[{key:"draw",value:function(d,v){var m=this.w,x=new $(this.ctx);this.rangeBarOptions=this.w.config.plotOptions.rangeBar,this.series=d,this.seriesRangeStart=m.globals.seriesRangeStart,this.seriesRangeEnd=m.globals.seriesRangeEnd,this.barHelpers.initVariables(d);for(var w=x.group({class:"apexcharts-rangebar-series apexcharts-plot-series"}),k=0;k0&&(this.visibleI=this.visibleI+1);var rt=0,A=0,O=0;this.yRatio.length>1&&(this.yaxisIndex=m.globals.seriesYAxisReverseMap[U][0],O=U);var X=this.barHelpers.initialPositions();j=X.y,V=X.zeroW,N=X.x,A=X.barWidth,rt=X.barHeight,L=X.xDivision,D=X.yDivision,P=X.zeroH;for(var ot=x.group({class:"apexcharts-datalabels","data:realIndex":U}),nt=x.group({class:"apexcharts-rangebar-goals-markers"}),ct=0;ct0});return this.isHorizontal?(x=U.config.plotOptions.bar.rangeBarGroupRows?k+V*O:k+D*this.visibleI+V*O,X>-1&&!U.config.plotOptions.bar.rangeBarOverlap&&(q=U.globals.seriesRange[v][X].overlaps).indexOf(J)>-1&&(x=(D=j.barHeight/q.length)*this.visibleI+V*(100-parseInt(this.barOptions.barHeight,10))/100/2+D*(this.visibleI+q.indexOf(J))+V*O)):(O>-1&&!U.globals.timescaleLabels.length&&(w=U.config.plotOptions.bar.rangeBarGroupRows?L+N*O:L+P*this.visibleI+N*O),X>-1&&!U.config.plotOptions.bar.rangeBarOverlap&&(q=U.globals.seriesRange[v][X].overlaps).indexOf(J)>-1&&(w=(P=j.barWidth/q.length)*this.visibleI+N*(100-parseInt(this.barOptions.barWidth,10))/100/2+P*(this.visibleI+q.indexOf(J))+N*O)),{barYPosition:x,barXPosition:w,barHeight:D,barWidth:P}}},{key:"drawRangeColumnPaths",value:function(d){var v=d.indexes,m=d.x,x=d.xDivision,w=d.barWidth,k=d.barXPosition,L=d.zeroH,D=this.w,P=v.i,V=v.j,N=v.realIndex,j=v.translationsIndex,U=this.yRatio[j],q=this.getRangeValue(N,V),J=Math.min(q.start,q.end),rt=Math.max(q.start,q.end);this.series[P][V]===void 0||this.series[P][V]===null?J=L:(J=L-J/U,rt=L-rt/U);var A=Math.abs(rt-J),O=this.barHelpers.getColumnPaths({barXPosition:k,barWidth:w,y1:J,y2:rt,strokeWidth:this.strokeWidth,series:this.seriesRangeEnd,realIndex:N,i:N,j:V,w:D});if(D.globals.isXNumeric){var X=this.getBarXForNumericXAxis({x:m,j:V,realIndex:N,barWidth:w});m=X.x,k=X.barXPosition}else m+=x;return{pathTo:O.pathTo,pathFrom:O.pathFrom,barHeight:A,x:m,y:q.start<0&&q.end<0?J:rt,goalY:this.barHelpers.getGoalValues("y",null,L,P,V,j),barXPosition:k}}},{key:"preventBarOverflow",value:function(d){var v=this.w;return d<0&&(d=0),d>v.globals.gridWidth&&(d=v.globals.gridWidth),d}},{key:"drawRangeBarPaths",value:function(d){var v=d.indexes,m=d.y,x=d.y1,w=d.y2,k=d.yDivision,L=d.barHeight,D=d.barYPosition,P=d.zeroW,V=this.w,N=v.realIndex,j=v.j,U=this.preventBarOverflow(P+x/this.invertedYRatio),q=this.preventBarOverflow(P+w/this.invertedYRatio),J=this.getRangeValue(N,j),rt=Math.abs(q-U),A=this.barHelpers.getBarpaths({barYPosition:D,barHeight:L,x1:U,x2:q,strokeWidth:this.strokeWidth,series:this.seriesRangeEnd,i:N,realIndex:N,j,w:V});return V.globals.isXNumeric||(m+=k),{pathTo:A.pathTo,pathFrom:A.pathFrom,barWidth:rt,x:J.start<0&&J.end<0?U:q,goalX:this.barHelpers.getGoalValues("x",P,null,N,j),y:m}}},{key:"getRangeValue",value:function(d,v){var m=this.w;return{start:m.globals.seriesRangeStart[d][v],end:m.globals.seriesRangeEnd[d][v]}}}]),u}(),us=function(){function Q(c){a(this,Q),this.w=c.w,this.lineCtx=c}return l(Q,[{key:"sameValueSeriesFix",value:function(c,u){var d=this.w;if((d.config.fill.type==="gradient"||d.config.fill.type[c]==="gradient")&&new G(this.lineCtx.ctx,d).seriesHaveSameValues(c)){var v=u[c].slice();v[v.length-1]=v[v.length-1]+1e-6,u[c]=v}return u}},{key:"calculatePoints",value:function(c){var u=c.series,d=c.realIndex,v=c.x,m=c.y,x=c.i,w=c.j,k=c.prevY,L=this.w,D=[],P=[];if(w===0){var V=this.lineCtx.categoryAxisCorrection+L.config.markers.offsetX;L.globals.isXNumeric&&(V=(L.globals.seriesX[d][0]-L.globals.minX)/this.lineCtx.xRatio+L.config.markers.offsetX),D.push(V),P.push(E.isNumber(u[x][0])?k+L.config.markers.offsetY:null),D.push(v+L.config.markers.offsetX),P.push(E.isNumber(u[x][w+1])?m+L.config.markers.offsetY:null)}else D.push(v+L.config.markers.offsetX),P.push(E.isNumber(u[x][w+1])?m+L.config.markers.offsetY:null);return{x:D,y:P}}},{key:"checkPreviousPaths",value:function(c){for(var u=c.pathFromLine,d=c.pathFromArea,v=c.realIndex,m=this.w,x=0;x0&&parseInt(w.realIndex,10)===parseInt(v,10)&&(w.type==="line"?(this.lineCtx.appendPathFrom=!1,u=m.globals.previousPaths[x].paths[0].d):w.type==="area"&&(this.lineCtx.appendPathFrom=!1,d=m.globals.previousPaths[x].paths[0].d,m.config.stroke.show&&m.globals.previousPaths[x].paths[1]&&(u=m.globals.previousPaths[x].paths[1].d)))}return{pathFromLine:u,pathFromArea:d}}},{key:"determineFirstPrevY",value:function(c){var u,d,v,m=c.i,x=c.realIndex,w=c.series,k=c.prevY,L=c.lineYPosition,D=c.translationsIndex,P=this.w,V=P.config.chart.stacked&&!P.globals.comboCharts||P.config.chart.stacked&&P.globals.comboCharts&&(!this.w.config.chart.stackOnlyBar||((u=this.w.config.series[x])===null||u===void 0?void 0:u.type)==="bar"||((d=this.w.config.series[x])===null||d===void 0?void 0:d.type)==="column");if(((v=w[m])===null||v===void 0?void 0:v[0])!==void 0)k=(L=V&&m>0?this.lineCtx.prevSeriesY[m-1][0]:this.lineCtx.zeroY)-w[m][0]/this.lineCtx.yRatio[D]+2*(this.lineCtx.isReversed?w[m][0]/this.lineCtx.yRatio[D]:0);else if(V&&m>0&&w[m][0]===void 0){for(var N=m-1;N>=0;N--)if(w[N][0]!==null&&w[N][0]!==void 0){k=L=this.lineCtx.prevSeriesY[N][0];break}}return{prevY:k,lineYPosition:L}}}]),Q}(),Mo=function(Q){for(var c,u,d,v,m=function(D){for(var P=[],V=D[0],N=D[1],j=P[0]=ps(V,N),U=1,q=D.length-1;U9&&(v=3*d/Math.sqrt(v),m[k]=v*c,m[k+1]=v*u);for(var L=0;L<=x;L++)v=(Q[Math.min(x,L+1)][0]-Q[Math.max(0,L-1)][0])/(6*(1+m[L]*m[L])),w.push([v||0,m[L]*v||0]);return w},ko=function(Q){var c=Mo(Q),u=Q[1],d=Q[0],v=[],m=c[1],x=c[0];v.push(d,[d[0]+x[0],d[1]+x[1],u[0]-m[0],u[1]-m[1],u[0],u[1]]);for(var w=2,k=c.length;w1&&d[1].length<6){var v=d[0].length;d[1]=[2*d[0][v-2]-d[0][v-4],2*d[0][v-1]-d[0][v-3]].concat(d[1])}d[0]=d[0].slice(-2)}return d};function ps(Q,c){return(c[1]-Q[1])/(c[0]-Q[0])}var ds=function(){function Q(c,u,d){a(this,Q),this.ctx=c,this.w=c.w,this.xyRatios=u,this.pointsChart=!(this.w.config.chart.type!=="bubble"&&this.w.config.chart.type!=="scatter")||d,this.scatter=new Rt(this.ctx),this.noNegatives=this.w.globals.minX===Number.MAX_VALUE,this.lineHelpers=new us(this),this.markers=new Vt(this.ctx),this.prevSeriesY=[],this.categoryAxisCorrection=0,this.yaxisIndex=0}return l(Q,[{key:"draw",value:function(c,u,d,v){var m,x=this.w,w=new $(this.ctx),k=x.globals.comboCharts?u:x.config.chart.type,L=w.group({class:"apexcharts-".concat(k,"-series apexcharts-plot-series")}),D=new G(this.ctx,x);this.yRatio=this.xyRatios.yRatio,this.zRatio=this.xyRatios.zRatio,this.xRatio=this.xyRatios.xRatio,this.baseLineY=this.xyRatios.baseLineY,c=D.getLogSeries(c),this.yRatio=D.getLogYRatios(this.yRatio),this.prevSeriesY=[];for(var P=[],V=0;V1?N:0;this._initSerieVariables(c,V,N);var U=[],q=[],J=[],rt=x.globals.padHorizontal+this.categoryAxisCorrection;this.ctx.series.addCollapsedClassToSeries(this.elSeries,N),x.globals.isXNumeric&&x.globals.seriesX.length>0&&(rt=(x.globals.seriesX[N][0]-x.globals.minX)/this.xRatio),J.push(rt);var A,O=rt,X=void 0,ot=O,nt=this.zeroY,ct=this.zeroY;nt=this.lineHelpers.determineFirstPrevY({i:V,realIndex:N,series:c,prevY:nt,lineYPosition:0,translationsIndex:j}).prevY,x.config.stroke.curve==="monotoneCubic"&&c[V][0]===null?U.push(null):U.push(nt),A=nt,k==="rangeArea"&&(X=ct=this.lineHelpers.determineFirstPrevY({i:V,realIndex:N,series:v,prevY:ct,lineYPosition:0,translationsIndex:j}).prevY,q.push(U[0]!==null?ct:null));var Ct=this._calculatePathsFrom({type:k,series:c,i:V,realIndex:N,translationsIndex:j,prevX:ot,prevY:nt,prevY2:ct}),xt=[U[0]],$t=[q[0]],re={type:k,series:c,realIndex:N,translationsIndex:j,i:V,x:rt,y:1,pX:O,pY:A,pathsFrom:Ct,linePaths:[],areaPaths:[],seriesIndex:d,lineYPosition:0,xArrj:J,yArrj:U,y2Arrj:q,seriesRangeEnd:v},Ot=this._iterateOverDataPoints(i(i({},re),{},{iterations:k==="rangeArea"?c[V].length-1:void 0,isRangeStart:!0}));if(k==="rangeArea"){for(var Qt=this._calculatePathsFrom({series:v,i:V,realIndex:N,prevX:ot,prevY:ct}),Me=this._iterateOverDataPoints(i(i({},re),{},{series:v,xArrj:[rt],yArrj:xt,y2Arrj:$t,pY:X,areaPaths:Ot.areaPaths,pathsFrom:Qt,iterations:v[V].length-1,isRangeStart:!1})),Te=Ot.linePaths.length/2,Ge=0;Ge=0;Ye--)L.add(P[Ye]);else for(var l1=0;l11&&(this.yaxisIndex=v.globals.seriesYAxisReverseMap[d],x=d),this.isReversed=v.config.yaxis[this.yaxisIndex]&&v.config.yaxis[this.yaxisIndex].reversed,this.zeroY=v.globals.gridHeight-this.baseLineY[x]-(this.isReversed?v.globals.gridHeight:0)+(this.isReversed?2*this.baseLineY[x]:0),this.areaBottomY=this.zeroY,(this.zeroY>v.globals.gridHeight||v.config.plotOptions.area.fillTo==="end")&&(this.areaBottomY=v.globals.gridHeight),this.categoryAxisCorrection=this.xDivision/2,this.elSeries=m.group({class:"apexcharts-series",zIndex:v.config.series[d].zIndex!==void 0?v.config.series[d].zIndex:d,seriesName:E.escapeString(v.globals.seriesNames[d])}),this.elPointsMain=m.group({class:"apexcharts-series-markers-wrap","data:realIndex":d}),this.elDataLabelsWrap=m.group({class:"apexcharts-datalabels","data:realIndex":d});var w=c[u].length===v.globals.dataPoints;this.elSeries.attr({"data:longestSeries":w,rel:u+1,"data:realIndex":d}),this.appendPathFrom=!0}},{key:"_calculatePathsFrom",value:function(c){var u,d,v,m,x=c.type,w=c.series,k=c.i,L=c.realIndex,D=c.translationsIndex,P=c.prevX,V=c.prevY,N=c.prevY2,j=this.w,U=new $(this.ctx);if(w[k][0]===null){for(var q=0;q0){var J=this.lineHelpers.checkPreviousPaths({pathFromLine:v,pathFromArea:m,realIndex:L});v=J.pathFromLine,m=J.pathFromArea}return{prevX:P,prevY:V,linePath:u,areaPath:d,pathFromLine:v,pathFromArea:m}}},{key:"_handlePaths",value:function(c){var u=c.type,d=c.realIndex,v=c.i,m=c.paths,x=this.w,w=new $(this.ctx),k=new Lt(this.ctx);this.prevSeriesY.push(m.yArrj),x.globals.seriesXvalues[d]=m.xArrj,x.globals.seriesYvalues[d]=m.yArrj;var L=x.config.forecastDataPoints;if(L.count>0&&u!=="rangeArea"){var D=x.globals.seriesXvalues[d][x.globals.seriesXvalues[d].length-L.count-1],P=w.drawRect(D,0,x.globals.gridWidth,x.globals.gridHeight,0);x.globals.dom.elForecastMask.appendChild(P.node);var V=w.drawRect(0,0,D,x.globals.gridHeight,0);x.globals.dom.elNonForecastMask.appendChild(V.node)}this.pointsChart||x.globals.delayedElements.push({el:this.elPointsMain.node,index:d});var N={i:v,realIndex:d,animationDelay:v,initialSpeed:x.config.chart.animations.speed,dataChangeSpeed:x.config.chart.animations.dynamicAnimation.speed,className:"apexcharts-".concat(u)};if(u==="area")for(var j=k.fillPath({seriesNumber:d}),U=0;U0&&u!=="rangeArea"){var nt=w.renderPaths(X);nt.node.setAttribute("stroke-dasharray",L.dashArray),L.strokeWidth&&nt.node.setAttribute("stroke-width",L.strokeWidth),this.elSeries.add(nt),nt.attr("clip-path","url(#forecastMask".concat(x.globals.cuid,")")),ot.attr("clip-path","url(#nonForecastMask".concat(x.globals.cuid,")"))}}}}},{key:"_iterateOverDataPoints",value:function(c){var u,d,v=this,m=c.type,x=c.series,w=c.iterations,k=c.realIndex,L=c.translationsIndex,D=c.i,P=c.x,V=c.y,N=c.pX,j=c.pY,U=c.pathsFrom,q=c.linePaths,J=c.areaPaths,rt=c.seriesIndex,A=c.lineYPosition,O=c.xArrj,X=c.yArrj,ot=c.y2Arrj,nt=c.isRangeStart,ct=c.seriesRangeEnd,Ct=this.w,xt=new $(this.ctx),$t=this.yRatio,re=U.prevY,Ot=U.linePath,Qt=U.areaPath,Me=U.pathFromLine,Te=U.pathFromArea,Ge=E.isNumber(Ct.globals.minYArr[k])?Ct.globals.minYArr[k]:Ct.globals.minY;w||(w=Ct.globals.dataPoints>1?Ct.globals.dataPoints-1:Ct.globals.dataPoints);var Ye=function(gi,ei){return ei-gi/$t[L]+2*(v.isReversed?gi/$t[L]:0)},l1=V,i1=Ct.config.chart.stacked&&!Ct.globals.comboCharts||Ct.config.chart.stacked&&Ct.globals.comboCharts&&(!this.w.config.chart.stackOnlyBar||((u=this.w.config.series[k])===null||u===void 0?void 0:u.type)==="bar"||((d=this.w.config.series[k])===null||d===void 0?void 0:d.type)==="column"),g1=Ct.config.stroke.curve;Array.isArray(g1)&&(g1=Array.isArray(rt)?g1[rt[D]]:g1[D]);for(var yr,_r=0,pr=0;pr0&&Ct.globals.collapsedSeries.length0;ei--){if(!(Ct.globals.collapsedSeriesIndices.indexOf((rt==null?void 0:rt[ei])||ei)>-1))return ei;ei--}return 0}(D-1)][pr+1]:A=this.zeroY:A=this.zeroY,Ri?V=Ye(Ge,A):(V=Ye(x[D][pr+1],A),m==="rangeArea"&&(l1=Ye(ct[D][pr+1],A))),O.push(P),!Ri||Ct.config.stroke.curve!=="smooth"&&Ct.config.stroke.curve!=="monotoneCubic"?(X.push(V),ot.push(l1)):(X.push(null),ot.push(null));var F1=this.lineHelpers.calculatePoints({series:x,x:P,y:V,realIndex:k,i:D,j:pr,prevY:re}),W1=this._createPaths({type:m,series:x,i:D,realIndex:k,j:pr,x:P,y:V,y2:l1,xArrj:O,yArrj:X,y2Arrj:ot,pX:N,pY:j,pathState:_r,segmentStartX:yr,linePath:Ot,areaPath:Qt,linePaths:q,areaPaths:J,curve:g1,isRangeStart:nt});J=W1.areaPaths,q=W1.linePaths,N=W1.pX,j=W1.pY,_r=W1.pathState,yr=W1.segmentStartX,Qt=W1.areaPath,Ot=W1.linePath,!this.appendPathFrom||g1==="monotoneCubic"&&m==="rangeArea"||(Me+=xt.line(P,this.zeroY),Te+=xt.line(P,this.zeroY)),this.handleNullDataPoints(x,F1,D,pr,k),this._handleMarkersAndLabels({type:m,pointsPos:F1,i:D,j:pr,realIndex:k,isRangeStart:nt})}return{yArrj:X,xArrj:O,pathFromArea:Te,areaPaths:J,pathFromLine:Me,linePaths:q,linePath:Ot,areaPath:Qt}}},{key:"_handleMarkersAndLabels",value:function(c){var u=c.type,d=c.pointsPos,v=c.isRangeStart,m=c.i,x=c.j,w=c.realIndex,k=this.w,L=new Ut(this.ctx);if(this.pointsChart)this.scatter.draw(this.elSeries,x,{realIndex:w,pointsPos:d,zRatio:this.zRatio,elParent:this.elPointsMain});else{k.globals.series[m].length>1&&this.elPointsMain.node.classList.add("apexcharts-element-hidden");var D=this.markers.plotChartMarkers(d,w,x+1);D!==null&&this.elPointsMain.add(D)}var P=L.drawDataLabel({type:u,isRangeStart:v,pos:d,i:w,j:x+1});P!==null&&this.elDataLabelsWrap.add(P)}},{key:"_createPaths",value:function(c){var u=c.type,d=c.series,v=c.i;c.realIndex;var m=c.j,x=c.x,w=c.y,k=c.xArrj,L=c.yArrj,D=c.y2,P=c.y2Arrj,V=c.pX,N=c.pY,j=c.pathState,U=c.segmentStartX,q=c.linePath,J=c.areaPath,rt=c.linePaths,A=c.areaPaths,O=c.curve,X=c.isRangeStart;this.w;var ot,nt=new $(this.ctx),ct=this.areaBottomY,Ct=u==="rangeArea",xt=u==="rangeArea"&&X;switch(O){case"monotoneCubic":var $t=X?L:P;switch(j){case 0:if($t[m+1]===null)break;j=1;case 1:if(!(Ct?k.length===d[v].length:m===d[v].length-2))break;case 2:var re=X?k:k.slice().reverse(),Ot=X?$t:$t.slice().reverse(),Qt=(ot=Ot,re.map(function(O1,F1){return[O1,ot[F1]]}).filter(function(O1){return O1[1]!==null})),Me=Qt.length>1?ko(Qt):Qt,Te=[];Ct&&(xt?A=Qt:Te=A.reverse());var Ge=0,Ye=0;if(function(O1,F1){for(var W1=function(I4){var ki=[],Y2=0;return I4.forEach(function(hd){hd!==null?Y2++:Y2>0&&(ki.push(Y2),Y2=0)}),Y2>0&&ki.push(Y2),ki}(O1),gi=[],ei=0,f2=0;ei4?(f2+="C".concat(ki[0],", ").concat(ki[1]),f2+=", ".concat(ki[2],", ").concat(ki[3]),f2+=", ".concat(ki[4],", ").concat(ki[5])):Y2>2&&(f2+="S".concat(ki[0],", ").concat(ki[1]),f2+=", ".concat(ki[2],", ").concat(ki[3]))}return f2}(O1),W1=Ye,gi=(Ye+=O1.length)-1;xt?q=nt.move(Qt[W1][0],Qt[W1][1])+F1:Ct?q=nt.move(Te[W1][0],Te[W1][1])+nt.line(Qt[W1][0],Qt[W1][1])+F1+nt.line(Te[gi][0],Te[gi][1]):(q=nt.move(Qt[W1][0],Qt[W1][1])+F1,J=q+nt.line(Qt[gi][0],ct)+nt.line(Qt[W1][0],ct)+"z",A.push(J)),rt.push(q)}),Ct&&Ge>1&&!xt){var l1=rt.slice(Ge).reverse();rt.splice(Ge),l1.forEach(function(O1){return rt.push(O1)})}j=0}break;case"smooth":var i1=.35*(x-V);if(d[v][m]===null)j=0;else switch(j){case 0:if(U=V,q=xt?nt.move(V,P[m])+nt.line(V,N):nt.move(V,N),J=nt.move(V,N),j=1,m=d[v].length-2&&(xt&&(q+=nt.curve(x,w,x,w,x,D)+nt.move(x,D)),J+=nt.curve(x,w,x,w,x,ct)+nt.line(U,ct)+"z",rt.push(q),A.push(J),j=-1)}}V=x,N=w;break;default:var _r=function(O1,F1,W1){var gi=[];switch(O1){case"stepline":gi=nt.line(F1,null,"H")+nt.line(null,W1,"V");break;case"linestep":gi=nt.line(null,W1,"V")+nt.line(F1,null,"H");break;case"straight":gi=nt.line(F1,W1)}return gi};if(d[v][m]===null)j=0;else switch(j){case 0:if(U=V,q=xt?nt.move(V,P[m])+nt.line(V,N):nt.move(V,N),J=nt.move(V,N),j=1,m=d[v].length-2&&(xt&&(q+=nt.line(x,D)),J+=nt.line(x,ct)+nt.line(U,ct)+"z",rt.push(q),A.push(J),j=-1)}}V=x,N=w}return{linePaths:rt,areaPaths:A,pX:V,pY:N,pathState:j,segmentStartX:U,linePath:q,areaPath:J}}},{key:"handleNullDataPoints",value:function(c,u,d,v,m){var x=this.w;if(c[d][v]===null&&x.config.markers.showNullDataPoints||c[d].length===1){var w=this.strokeWidth-x.config.markers.strokeWidth/2;w>0||(w=0);var k=this.markers.plotChartMarkers(u,m,v+1,w,!0);k!==null&&this.elPointsMain.add(k)}}}]),Q}();window.TreemapSquared={},window.TreemapSquared.generate=function(){function Q(w,k,L,D){this.xoffset=w,this.yoffset=k,this.height=D,this.width=L,this.shortestEdge=function(){return Math.min(this.height,this.width)},this.getCoordinates=function(P){var V,N=[],j=this.xoffset,U=this.yoffset,q=m(P)/this.height,J=m(P)/this.width;if(this.width>=this.height)for(V=0;V=this.height){var N=P/this.height,j=this.width-N;V=new Q(this.xoffset+N,this.yoffset,j,this.height)}else{var U=P/this.width,q=this.height-U;V=new Q(this.xoffset,this.yoffset+U,this.width,q)}return V}}function c(w,k,L,D,P){D=D===void 0?0:D,P=P===void 0?0:P;var V=u(function(N,j){var U,q=[],J=j/m(N);for(U=0;U=A}(k,V=w[0],P)?(k.push(V),u(w.slice(1),k,L,D)):(N=L.cutArea(m(k),D),D.push(L.getCoordinates(k)),u(w,[],N,D)),D;D.push(L.getCoordinates(k))}function d(w,k){var L=Math.min.apply(Math,w),D=Math.max.apply(Math,w),P=m(w);return Math.max(Math.pow(k,2)*D/Math.pow(P,2),Math.pow(P,2)/(Math.pow(k,2)*L))}function v(w){return w&&w.constructor===Array}function m(w){var k,L=0;for(k=0;kx-v&&L.width<=w-m){var D=k.rotateAroundCenter(c.node);c.node.setAttribute("transform","rotate(-90 ".concat(D.x," ").concat(D.y,") translate(").concat(L.height/3,")"))}}},{key:"truncateLabels",value:function(c,u,d,v,m,x){var w=new $(this.ctx),k=w.getTextRects(c,u).width+this.w.config.stroke.width+5>m-d&&x-v>m-d?x-v:m-d,L=w.getTextBasedOnMaxWidth({text:c,maxWidth:k,fontSize:u});return c.length!==L.length&&k/u<5?"":L}},{key:"animateTreemap",value:function(c,u,d,v){var m=new R(this.ctx);m.animateRect(c,{x:u.x,y:u.y,width:u.width,height:u.height},{x:d.x,y:d.y,width:d.width,height:d.height},v,function(){m.animationCompleted(c)})}}]),Q}(),K0=86400,la=10/K0,q0=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w,this.timeScaleArray=[],this.utc=this.w.config.xaxis.labels.datetimeUTC}return l(Q,[{key:"calculateTimeScaleTicks",value:function(c,u){var d=this,v=this.w;if(v.globals.allSeriesCollapsed)return v.globals.labels=[],v.globals.timescaleLabels=[],[];var m=new et(this.ctx),x=(u-c)/864e5;this.determineInterval(x),v.globals.disableZoomIn=!1,v.globals.disableZoomOut=!1,x5e4&&(v.globals.disableZoomOut=!0);var w=m.getTimeUnitsfromTimestamp(c,u,this.utc),k=v.globals.gridWidth/x,L=k/24,D=L/60,P=D/60,V=Math.floor(24*x),N=Math.floor(1440*x),j=Math.floor(x*K0),U=Math.floor(x),q=Math.floor(x/30),J=Math.floor(x/365),rt={minMillisecond:w.minMillisecond,minSecond:w.minSecond,minMinute:w.minMinute,minHour:w.minHour,minDate:w.minDate,minMonth:w.minMonth,minYear:w.minYear},A={firstVal:rt,currentMillisecond:rt.minMillisecond,currentSecond:rt.minSecond,currentMinute:rt.minMinute,currentHour:rt.minHour,currentMonthDate:rt.minDate,currentDate:rt.minDate,currentMonth:rt.minMonth,currentYear:rt.minYear,daysWidthOnXAxis:k,hoursWidthOnXAxis:L,minutesWidthOnXAxis:D,secondsWidthOnXAxis:P,numberOfSeconds:j,numberOfMinutes:N,numberOfHours:V,numberOfDays:U,numberOfMonths:q,numberOfYears:J};switch(this.tickInterval){case"years":this.generateYearScale(A);break;case"months":case"half_year":this.generateMonthScale(A);break;case"months_days":case"months_fortnight":case"days":case"week_days":this.generateDayScale(A);break;case"hours":this.generateHourScale(A);break;case"minutes_fives":case"minutes":this.generateMinuteScale(A);break;case"seconds_tens":case"seconds_fives":case"seconds":this.generateSecondScale(A)}var O=this.timeScaleArray.map(function(X){var ot={position:X.position,unit:X.unit,year:X.year,day:X.day?X.day:1,hour:X.hour?X.hour:0,month:X.month+1};return X.unit==="month"?i(i({},ot),{},{day:1,value:X.value+1}):X.unit==="day"||X.unit==="hour"?i(i({},ot),{},{value:X.value}):X.unit==="minute"?i(i({},ot),{},{value:X.value,minute:X.value}):X.unit==="second"?i(i({},ot),{},{value:X.value,minute:X.minute,second:X.second}):X});return O.filter(function(X){var ot=1,nt=Math.ceil(v.globals.gridWidth/120),ct=X.value;v.config.xaxis.tickAmount!==void 0&&(nt=v.config.xaxis.tickAmount),O.length>nt&&(ot=Math.floor(O.length/nt));var Ct=!1,xt=!1;switch(d.tickInterval){case"years":X.unit==="year"&&(Ct=!0);break;case"half_year":ot=7,X.unit==="year"&&(Ct=!0);break;case"months":ot=1,X.unit==="year"&&(Ct=!0);break;case"months_fortnight":ot=15,X.unit!=="year"&&X.unit!=="month"||(Ct=!0),ct===30&&(xt=!0);break;case"months_days":ot=10,X.unit==="month"&&(Ct=!0),ct===30&&(xt=!0);break;case"week_days":ot=8,X.unit==="month"&&(Ct=!0);break;case"days":ot=1,X.unit==="month"&&(Ct=!0);break;case"hours":X.unit==="day"&&(Ct=!0);break;case"minutes_fives":case"seconds_fives":ct%5!=0&&(xt=!0);break;case"seconds_tens":ct%10!=0&&(xt=!0)}if(d.tickInterval==="hours"||d.tickInterval==="minutes_fives"||d.tickInterval==="seconds_tens"||d.tickInterval==="seconds_fives"){if(!xt)return!0}else if((ct%ot==0||Ct)&&!xt)return!0})}},{key:"recalcDimensionsBasedOnFormat",value:function(c,u){var d=this.w,v=this.formatDates(c),m=this.removeOverlappingTS(v);d.globals.timescaleLabels=m.slice(),new Pe(this.ctx).plotCoords()}},{key:"determineInterval",value:function(c){var u=24*c,d=60*u;switch(!0){case c/365>5:this.tickInterval="years";break;case c>800:this.tickInterval="half_year";break;case c>180:this.tickInterval="months";break;case c>90:this.tickInterval="months_fortnight";break;case c>60:this.tickInterval="months_days";break;case c>30:this.tickInterval="week_days";break;case c>2:this.tickInterval="days";break;case u>2.4:this.tickInterval="hours";break;case d>15:this.tickInterval="minutes_fives";break;case d>5:this.tickInterval="minutes";break;case d>1:this.tickInterval="seconds_tens";break;case 60*d>20:this.tickInterval="seconds_fives";break;default:this.tickInterval="seconds"}}},{key:"generateYearScale",value:function(c){var u=c.firstVal,d=c.currentMonth,v=c.currentYear,m=c.daysWidthOnXAxis,x=c.numberOfYears,w=u.minYear,k=0,L=new et(this.ctx),D="year";if(u.minDate>1||u.minMonth>0){var P=L.determineRemainingDaysOfYear(u.minYear,u.minMonth,u.minDate);k=(L.determineDaysOfYear(u.minYear)-P+1)*m,w=u.minYear+1,this.timeScaleArray.push({position:k,value:w,unit:D,year:w,month:E.monthMod(d+1)})}else u.minDate===1&&u.minMonth===0&&this.timeScaleArray.push({position:k,value:w,unit:D,year:v,month:E.monthMod(d+1)});for(var V=w,N=k,j=0;j1){L=(D.determineDaysOfMonths(v+1,u.minYear)-d+1)*x,k=E.monthMod(v+1);var N=m+V,j=E.monthMod(k),U=k;k===0&&(P="year",U=N,j=1,N+=V+=1),this.timeScaleArray.push({position:L,value:U,unit:P,year:N,month:j})}else this.timeScaleArray.push({position:L,value:k,unit:P,year:m,month:E.monthMod(v)});for(var q=k+1,J=L,rt=0,A=1;rtw.determineDaysOfMonths(O+1,X)&&(D=1,k="month",N=O+=1),O},V=(24-u.minHour)*m,N=L,j=P(D,d,v);u.minHour===0&&u.minDate===1?(V=0,N=E.monthMod(u.minMonth),k="month",D=u.minDate):u.minDate!==1&&u.minHour===0&&u.minMinute===0&&(V=0,L=u.minDate,N=L,j=P(D=L,d,v)),this.timeScaleArray.push({position:V,value:N,unit:k,year:this._getYear(v,j,0),month:E.monthMod(j),day:D});for(var U=V,q=0;qk.determineDaysOfMonths(nt+1,m)&&(q=1,nt+=1),{month:nt,date:q}},P=function(ot,nt){return ot>k.determineDaysOfMonths(nt+1,m)?nt+=1:nt},V=60-(u.minMinute+u.minSecond/60),N=V*x,j=u.minHour+1,U=j;V===60&&(N=0,U=j=u.minHour);var q=d;U>=24&&(U=0,q+=1,L="day");var J=D(q,v).month;J=P(q,J),this.timeScaleArray.push({position:N,value:j,unit:L,day:q,hour:U,year:m,month:E.monthMod(J)}),U++;for(var rt=N,A=0;A=24&&(U=0,L="day",J=D(q+=1,J).month,J=P(q,J));var O=this._getYear(m,J,0);rt=60*x+rt;var X=U===0?q:U;this.timeScaleArray.push({position:rt,value:X,unit:L,hour:U,day:q,year:O,month:E.monthMod(J)}),U++}}},{key:"generateMinuteScale",value:function(c){for(var u=c.currentMillisecond,d=c.currentSecond,v=c.currentMinute,m=c.currentHour,x=c.currentDate,w=c.currentMonth,k=c.currentYear,L=c.minutesWidthOnXAxis,D=c.secondsWidthOnXAxis,P=c.numberOfMinutes,V=v+1,N=x,j=w,U=k,q=m,J=(60-d-u/1e3)*D,rt=0;rt=60&&(V=0,(q+=1)===24&&(q=0)),this.timeScaleArray.push({position:J,value:V,unit:"minute",hour:q,minute:V,day:N,year:this._getYear(U,j,0),month:E.monthMod(j)}),J+=L,V++}},{key:"generateSecondScale",value:function(c){for(var u=c.currentMillisecond,d=c.currentSecond,v=c.currentMinute,m=c.currentHour,x=c.currentDate,w=c.currentMonth,k=c.currentYear,L=c.secondsWidthOnXAxis,D=c.numberOfSeconds,P=d+1,V=v,N=x,j=w,U=k,q=m,J=(1e3-u)/1e3*L,rt=0;rt=60&&(P=0,++V>=60&&(V=0,++q===24&&(q=0))),this.timeScaleArray.push({position:J,value:P,unit:"second",hour:q,minute:V,second:P,day:N,year:this._getYear(U,j,0),month:E.monthMod(j)}),J+=L,P++}},{key:"createRawDateString",value:function(c,u){var d=c.year;return c.month===0&&(c.month=1),d+="-"+("0"+c.month.toString()).slice(-2),c.unit==="day"?d+=c.unit==="day"?"-"+("0"+u).slice(-2):"-01":d+="-"+("0"+(c.day?c.day:"1")).slice(-2),c.unit==="hour"?d+=c.unit==="hour"?"T"+("0"+u).slice(-2):"T00":d+="T"+("0"+(c.hour?c.hour:"0")).slice(-2),c.unit==="minute"?d+=":"+("0"+u).slice(-2):d+=":"+(c.minute?("0"+c.minute).slice(-2):"00"),c.unit==="second"?d+=":"+("0"+u).slice(-2):d+=":00",this.utc&&(d+=".000Z"),d}},{key:"formatDates",value:function(c){var u=this,d=this.w;return c.map(function(v){var m=v.value.toString(),x=new et(u.ctx),w=u.createRawDateString(v,m),k=x.getDate(x.parseDate(w));if(u.utc||(k=x.getDate(x.parseDateWithTimezone(w))),d.config.xaxis.labels.format===void 0){var L="dd MMM",D=d.config.xaxis.labels.datetimeFormatter;v.unit==="year"&&(L=D.year),v.unit==="month"&&(L=D.month),v.unit==="day"&&(L=D.day),v.unit==="hour"&&(L=D.hour),v.unit==="minute"&&(L=D.minute),v.unit==="second"&&(L=D.second),m=x.formatDate(k,L)}else m=x.formatDate(k,d.config.xaxis.labels.format);return{dateString:w,position:v.position,value:m,unit:v.unit,year:v.year,month:v.month}})}},{key:"removeOverlappingTS",value:function(c){var u,d=this,v=new $(this.ctx),m=!1;c.length>0&&c[0].value&&c.every(function(k){return k.value.length===c[0].value.length})&&(m=!0,u=v.getTextRects(c[0].value).width);var x=0,w=c.map(function(k,L){if(L>0&&d.w.config.xaxis.labels.hideOverlappingLabels){var D=m?u:v.getTextRects(c[x].value).width,P=c[x].position;return k.position>P+D+10?(x=L,k):null}return k});return w=w.filter(function(k){return k!==null})}},{key:"_getYear",value:function(c,u,d){return c+Math.floor(u/12)+d}}]),Q}(),r1=function(){function Q(c,u){a(this,Q),this.ctx=u,this.w=u.w,this.el=c}return l(Q,[{key:"setupElements",value:function(){var c=this.w.globals,u=this.w.config,d=u.chart.type;c.axisCharts=["line","area","bar","rangeBar","rangeArea","candlestick","boxPlot","scatter","bubble","radar","heatmap","treemap"].indexOf(d)>-1,c.xyCharts=["line","area","bar","rangeBar","rangeArea","candlestick","boxPlot","scatter","bubble"].indexOf(d)>-1,c.isBarHorizontal=(u.chart.type==="bar"||u.chart.type==="rangeBar"||u.chart.type==="boxPlot")&&u.plotOptions.bar.horizontal,c.chartClass=".apexcharts"+c.chartID,c.dom.baseEl=this.el,c.dom.elWrap=document.createElement("div"),$.setAttrs(c.dom.elWrap,{id:c.chartClass.substring(1),class:"apexcharts-canvas "+c.chartClass.substring(1)}),this.el.appendChild(c.dom.elWrap),c.dom.Paper=new window.SVG.Doc(c.dom.elWrap),c.dom.Paper.attr({class:"apexcharts-svg","xmlns:data":"ApexChartsNS",transform:"translate(".concat(u.chart.offsetX,", ").concat(u.chart.offsetY,")")}),c.dom.Paper.node.style.background=u.theme.mode!=="dark"||u.chart.background?u.theme.mode!=="light"||u.chart.background?u.chart.background:"#fff":"#424242",this.setSVGDimensions(),c.dom.elLegendForeign=document.createElementNS(c.SVGNS,"foreignObject"),$.setAttrs(c.dom.elLegendForeign,{x:0,y:0,width:c.svgWidth,height:c.svgHeight}),c.dom.elLegendWrap=document.createElement("div"),c.dom.elLegendWrap.classList.add("apexcharts-legend"),c.dom.elLegendWrap.setAttribute("xmlns","http://www.w3.org/1999/xhtml"),c.dom.elLegendForeign.appendChild(c.dom.elLegendWrap),c.dom.Paper.node.appendChild(c.dom.elLegendForeign),c.dom.elGraphical=c.dom.Paper.group().attr({class:"apexcharts-inner apexcharts-graphical"}),c.dom.elDefs=c.dom.Paper.defs(),c.dom.Paper.add(c.dom.elGraphical),c.dom.elGraphical.add(c.dom.elDefs)}},{key:"plotChartType",value:function(c,u){var d=this.w,v=d.config,m=d.globals,x={series:[],i:[]},w={series:[],i:[]},k={series:[],i:[]},L={series:[],i:[]},D={series:[],i:[]},P={series:[],i:[]},V={series:[],i:[]},N={series:[],i:[]},j={series:[],seriesRangeEnd:[],i:[]},U=v.chart.type!==void 0?v.chart.type:"line",q=null,J=0;m.series.forEach(function(Ot,Qt){var Me=c[Qt].type||U;switch(Me){case"column":case"bar":D.series.push(Ot),D.i.push(Qt),d.globals.columnSeries=D;break;case"area":w.series.push(Ot),w.i.push(Qt);break;case"line":x.series.push(Ot),x.i.push(Qt);break;case"scatter":k.series.push(Ot),k.i.push(Qt);break;case"bubble":L.series.push(Ot),L.i.push(Qt);break;case"candlestick":P.series.push(Ot),P.i.push(Qt);break;case"boxPlot":V.series.push(Ot),V.i.push(Qt);break;case"rangeBar":N.series.push(Ot),N.i.push(Qt);break;case"rangeArea":j.series.push(m.seriesRangeStart[Qt]),j.seriesRangeEnd.push(m.seriesRangeEnd[Qt]),j.i.push(Qt);break;case"heatmap":case"treemap":case"pie":case"donut":case"polarArea":case"radialBar":case"radar":q=Me;break;default:console.warn("You have specified an unrecognized series type (",Me,").")}U!==Me&&Me!=="scatter"&&J++}),J>0&&(q!==null&&console.warn("Chart or series type ",q," can not appear with other chart or series types."),D.series.length>0&&v.plotOptions.bar.horizontal&&(J-=D.length,D={series:[],i:[]},d.globals.columnSeries={series:[],i:[]},console.warn("Horizontal bars are not supported in a mixed/combo chart. Please turn off `plotOptions.bar.horizontal`"))),m.comboCharts||(m.comboCharts=J>0);var rt=new ds(this.ctx,u),A=new d1(this.ctx,u);this.ctx.pie=new E1(this.ctx);var O=new Qr(this.ctx);this.ctx.rangeBar=new ti(this.ctx,u);var X=new ur(this.ctx),ot=[];if(m.comboCharts){var nt,ct,Ct=new G(this.ctx);if(w.series.length>0&&(nt=ot).push.apply(nt,I(Ct.drawSeriesByGroup(w,m.areaGroups,"area",rt))),D.series.length>0)if(d.config.chart.stacked){var xt=new je(this.ctx,u);ot.push(xt.draw(D.series,D.i))}else this.ctx.bar=new Re(this.ctx,u),ot.push(this.ctx.bar.draw(D.series,D.i));if(j.series.length>0&&ot.push(rt.draw(j.series,"rangeArea",j.i,j.seriesRangeEnd)),x.series.length>0&&(ct=ot).push.apply(ct,I(Ct.drawSeriesByGroup(x,m.lineGroups,"line",rt))),P.series.length>0&&ot.push(A.draw(P.series,"candlestick",P.i)),V.series.length>0&&ot.push(A.draw(V.series,"boxPlot",V.i)),N.series.length>0&&ot.push(this.ctx.rangeBar.draw(N.series,N.i)),k.series.length>0){var $t=new ds(this.ctx,u,!0);ot.push($t.draw(k.series,"scatter",k.i))}if(L.series.length>0){var re=new ds(this.ctx,u,!0);ot.push(re.draw(L.series,"bubble",L.i))}}else switch(v.chart.type){case"line":ot=rt.draw(m.series,"line");break;case"area":ot=rt.draw(m.series,"area");break;case"bar":v.chart.stacked?ot=new je(this.ctx,u).draw(m.series):(this.ctx.bar=new Re(this.ctx,u),ot=this.ctx.bar.draw(m.series));break;case"candlestick":ot=new d1(this.ctx,u).draw(m.series,"candlestick");break;case"boxPlot":ot=new d1(this.ctx,u).draw(m.series,v.chart.type);break;case"rangeBar":ot=this.ctx.rangeBar.draw(m.series);break;case"rangeArea":ot=rt.draw(m.seriesRangeStart,"rangeArea",void 0,m.seriesRangeEnd);break;case"heatmap":ot=new Oe(this.ctx,u).draw(m.series);break;case"treemap":ot=new f6(this.ctx,u).draw(m.series);break;case"pie":case"donut":case"polarArea":ot=this.ctx.pie.draw(m.series);break;case"radialBar":ot=O.draw(m.series);break;case"radar":ot=X.draw(m.series);break;default:ot=rt.draw(m.series)}return ot}},{key:"setSVGDimensions",value:function(){var c=this.w.globals,u=this.w.config;u.chart.width||(u.chart.width="100%"),u.chart.height||(u.chart.height="auto"),c.svgWidth=u.chart.width,c.svgHeight=u.chart.height;var d=E.getDimensions(this.el),v=u.chart.width.toString().split(/[0-9]+/g).pop();v==="%"?E.isNumber(d[0])&&(d[0].width===0&&(d=E.getDimensions(this.el.parentNode)),c.svgWidth=d[0]*parseInt(u.chart.width,10)/100):v!=="px"&&v!==""||(c.svgWidth=parseInt(u.chart.width,10));var m=String(u.chart.height).toString().split(/[0-9]+/g).pop();if(c.svgHeight!=="auto"&&c.svgHeight!=="")if(m==="%"){var x=E.getDimensions(this.el.parentNode);c.svgHeight=x[1]*parseInt(u.chart.height,10)/100}else c.svgHeight=parseInt(u.chart.height,10);else c.axisCharts?c.svgHeight=c.svgWidth/1.61:c.svgHeight=c.svgWidth/1.2;if(c.svgWidth<0&&(c.svgWidth=0),c.svgHeight<0&&(c.svgHeight=0),$.setAttrs(c.dom.Paper.node,{width:c.svgWidth,height:c.svgHeight}),m!=="%"){var w=u.chart.sparkline.enabled?0:c.axisCharts?u.chart.parentHeightOffset:0;c.dom.Paper.node.parentNode.parentNode.style.minHeight=c.svgHeight+w+"px"}c.dom.elWrap.style.width=c.svgWidth+"px",c.dom.elWrap.style.height=c.svgHeight+"px"}},{key:"shiftGraphPosition",value:function(){var c=this.w.globals,u=c.translateY,d={transform:"translate("+c.translateX+", "+u+")"};$.setAttrs(c.dom.elGraphical.node,d)}},{key:"resizeNonAxisCharts",value:function(){var c=this.w,u=c.globals,d=0,v=c.config.chart.sparkline.enabled?1:15;v+=c.config.grid.padding.bottom,c.config.legend.position!=="top"&&c.config.legend.position!=="bottom"||!c.config.legend.show||c.config.legend.floating||(d=new st(this.ctx).legendHelpers.getLegendDimensions().clwh+10);var m=c.globals.dom.baseEl.querySelector(".apexcharts-radialbar, .apexcharts-pie"),x=2.05*c.globals.radialSize;if(m&&!c.config.chart.sparkline.enabled&&c.config.plotOptions.radialBar.startAngle!==0){var w=E.getBoundingClientRect(m);x=w.bottom;var k=w.bottom-w.top;x=Math.max(2.05*c.globals.radialSize,k)}var L=x+u.translateY+d+v;u.dom.elLegendForeign&&u.dom.elLegendForeign.setAttribute("height",L),c.config.chart.height&&String(c.config.chart.height).indexOf("%")>0||(u.dom.elWrap.style.height=L+"px",$.setAttrs(u.dom.Paper.node,{height:L}),u.dom.Paper.node.parentNode.parentNode.style.minHeight=L+"px")}},{key:"coreCalculations",value:function(){new we(this.ctx).init()}},{key:"resetGlobals",value:function(){var c=this,u=function(){return c.w.config.series.map(function(m){return[]})},d=new bt,v=this.w.globals;d.initGlobalVars(v),v.seriesXvalues=u(),v.seriesYvalues=u()}},{key:"isMultipleY",value:function(){if(this.w.config.yaxis.constructor===Array&&this.w.config.yaxis.length>1)return this.w.globals.isMultipleYAxis=!0,!0}},{key:"xySettings",value:function(){var c=null,u=this.w;if(u.globals.axisCharts){if(u.config.xaxis.crosshairs.position==="back"&&new ge(this.ctx).drawXCrosshairs(),u.config.yaxis[0].crosshairs.position==="back"&&new ge(this.ctx).drawYCrosshairs(),u.config.xaxis.type==="datetime"&&u.config.xaxis.labels.formatter===void 0){this.ctx.timeScale=new q0(this.ctx);var d=[];isFinite(u.globals.minX)&&isFinite(u.globals.maxX)&&!u.globals.isBarHorizontal?d=this.ctx.timeScale.calculateTimeScaleTicks(u.globals.minX,u.globals.maxX):u.globals.isBarHorizontal&&(d=this.ctx.timeScale.calculateTimeScaleTicks(u.globals.minY,u.globals.maxY)),this.ctx.timeScale.recalcDimensionsBasedOnFormat(d)}c=new G(this.ctx).getCalculatedRatios()}return c}},{key:"updateSourceChart",value:function(c){this.ctx.w.globals.selection=void 0,this.ctx.updateHelpers._updateOptions({chart:{selection:{xaxis:{min:c.w.globals.minX,max:c.w.globals.maxX}}}},!1,!1)}},{key:"setupBrushHandler",value:function(){var c=this,u=this.w;if(u.config.chart.brush.enabled&&typeof u.config.chart.events.selection!="function"){var d=Array.isArray(u.config.chart.brush.targets)?u.config.chart.brush.targets:[u.config.chart.brush.target];d.forEach(function(v){var m=ApexCharts.getChartByID(v);m.w.globals.brushSource=c.ctx,typeof m.w.config.chart.events.zoomed!="function"&&(m.w.config.chart.events.zoomed=function(){c.updateSourceChart(m)}),typeof m.w.config.chart.events.scrolled!="function"&&(m.w.config.chart.events.scrolled=function(){c.updateSourceChart(m)})}),u.config.chart.events.selection=function(v,m){d.forEach(function(x){ApexCharts.getChartByID(x).ctx.updateHelpers._updateOptions({xaxis:{min:m.xaxis.min,max:m.xaxis.max}},!1,!1,!1,!1)})}}}}]),Q}(),s1=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w}return l(Q,[{key:"_updateOptions",value:function(c){var u=this,d=arguments.length>1&&arguments[1]!==void 0&&arguments[1],v=!(arguments.length>2&&arguments[2]!==void 0)||arguments[2],m=!(arguments.length>3&&arguments[3]!==void 0)||arguments[3],x=arguments.length>4&&arguments[4]!==void 0&&arguments[4];return new Promise(function(w){var k=[u.ctx];m&&(k=u.ctx.getSyncedCharts()),u.ctx.w.globals.isExecCalled&&(k=[u.ctx],u.ctx.w.globals.isExecCalled=!1),k.forEach(function(L,D){var P=L.w;if(P.globals.shouldAnimate=v,d||(P.globals.resized=!0,P.globals.dataChanged=!0,v&&L.series.getPreviousPaths()),c&&o(c)==="object"&&(L.config=new At(c),c=G.extendArrayProps(L.config,c,P),L.w.globals.chartID!==u.ctx.w.globals.chartID&&delete c.series,P.config=E.extend(P.config,c),x&&(P.globals.lastXAxis=c.xaxis?E.clone(c.xaxis):[],P.globals.lastYAxis=c.yaxis?E.clone(c.yaxis):[],P.globals.initialConfig=E.extend({},P.config),P.globals.initialSeries=E.clone(P.config.series),c.series))){for(var V=0;V2&&arguments[2]!==void 0&&arguments[2];return new Promise(function(m){var x,w=d.w;return w.globals.shouldAnimate=u,w.globals.dataChanged=!0,u&&d.ctx.series.getPreviousPaths(),w.globals.axisCharts?((x=c.map(function(k,L){return d._extendSeries(k,L)})).length===0&&(x=[{data:[]}]),w.config.series=x):w.config.series=c.slice(),v&&(w.globals.initialConfig.series=E.clone(w.config.series),w.globals.initialSeries=E.clone(w.config.series)),d.ctx.update().then(function(){m(d.ctx)})})}},{key:"_extendSeries",value:function(c,u){var d=this.w,v=d.config.series[u];return i(i({},d.config.series[u]),{},{name:c.name?c.name:v==null?void 0:v.name,color:c.color?c.color:v==null?void 0:v.color,type:c.type?c.type:v==null?void 0:v.type,group:c.group?c.group:v==null?void 0:v.group,data:c.data?c.data:v==null?void 0:v.data,zIndex:c.zIndex!==void 0?c.zIndex:u})}},{key:"toggleDataPointSelection",value:function(c,u){var d=this.w,v=null,m=".apexcharts-series[data\\:realIndex='".concat(c,"']");return d.globals.axisCharts?v=d.globals.dom.Paper.select("".concat(m," path[j='").concat(u,"'], ").concat(m," circle[j='").concat(u,"'], ").concat(m," rect[j='").concat(u,"']")).members[0]:u===void 0&&(v=d.globals.dom.Paper.select("".concat(m," path[j='").concat(c,"']")).members[0],d.config.chart.type!=="pie"&&d.config.chart.type!=="polarArea"&&d.config.chart.type!=="donut"||this.ctx.pie.pieClicked(c)),v?(new $(this.ctx).pathMouseDown(v,null),v.node?v.node:null):(console.warn("toggleDataPointSelection: Element not found"),null)}},{key:"forceXAxisUpdate",value:function(c){var u=this.w;if(["min","max"].forEach(function(v){c.xaxis[v]!==void 0&&(u.config.xaxis[v]=c.xaxis[v],u.globals.lastXAxis[v]=c.xaxis[v])}),c.xaxis.categories&&c.xaxis.categories.length&&(u.config.xaxis.categories=c.xaxis.categories),u.config.xaxis.convertedCatToNumeric){var d=new _t(c);c=d.convertCatToNumericXaxis(c,this.ctx)}return c}},{key:"forceYAxisUpdate",value:function(c){return c.chart&&c.chart.stacked&&c.chart.stackType==="100%"&&(Array.isArray(c.yaxis)?c.yaxis.forEach(function(u,d){c.yaxis[d].min=0,c.yaxis[d].max=100}):(c.yaxis.min=0,c.yaxis.max=100)),c}},{key:"revertDefaultAxisMinMax",value:function(c){var u=this,d=this.w,v=d.globals.lastXAxis,m=d.globals.lastYAxis;c&&c.xaxis&&(v=c.xaxis),c&&c.yaxis&&(m=c.yaxis),d.config.xaxis.min=v.min,d.config.xaxis.max=v.max;var x=function(w){m[w]!==void 0&&(d.config.yaxis[w].min=m[w].min,d.config.yaxis[w].max=m[w].max)};d.config.yaxis.map(function(w,k){d.globals.zoomed||m[k]!==void 0?x(k):u.ctx.opts.yaxis[k]!==void 0&&(w.min=u.ctx.opts.yaxis[k].min,w.max=u.ctx.opts.yaxis[k].max)})}}]),Q}();d2=typeof window<"u"?window:void 0,fs=function(Q,c){var u=(this!==void 0?this:Q).SVG=function(A){if(u.supported)return A=new u.Doc(A),u.parser.draw||u.prepare(),A};if(u.ns="http://www.w3.org/2000/svg",u.xmlns="http://www.w3.org/2000/xmlns/",u.xlink="http://www.w3.org/1999/xlink",u.svgjs="http://svgjs.dev",u.supported=!0,!u.supported)return!1;u.did=1e3,u.eid=function(A){return"Svgjs"+D(A)+u.did++},u.create=function(A){var O=c.createElementNS(this.ns,A);return O.setAttribute("id",this.eid(A)),O},u.extend=function(){var A,O;O=(A=[].slice.call(arguments)).pop();for(var X=A.length-1;X>=0;X--)if(A[X])for(var ot in O)A[X].prototype[ot]=O[ot];u.Set&&u.Set.inherit&&u.Set.inherit()},u.invent=function(A){var O=typeof A.create=="function"?A.create:function(){this.constructor.call(this,u.create(A.create))};return A.inherit&&(O.prototype=new A.inherit),A.extend&&u.extend(O,A.extend),A.construct&&u.extend(A.parent||u.Container,A.construct),O},u.adopt=function(A){return A?A.instance?A.instance:((O=A.nodeName=="svg"?A.parentNode instanceof Q.SVGElement?new u.Nested:new u.Doc:A.nodeName=="linearGradient"?new u.Gradient("linear"):A.nodeName=="radialGradient"?new u.Gradient("radial"):u[D(A.nodeName)]?new u[D(A.nodeName)]:new u.Element(A)).type=A.nodeName,O.node=A,A.instance=O,O instanceof u.Doc&&O.namespace().defs(),O.setData(JSON.parse(A.getAttribute("svgjs:data"))||{}),O):null;var O},u.prepare=function(){var A=c.getElementsByTagName("body")[0],O=(A?new u.Doc(A):u.adopt(c.documentElement).nested()).size(2,0);u.parser={body:A||c.documentElement,draw:O.style("opacity:0;position:absolute;left:-100%;top:-100%;overflow:hidden").node,poly:O.polyline().node,path:O.path().node,native:u.create("svg")}},u.parser={native:u.create("svg")},c.addEventListener("DOMContentLoaded",function(){u.parser.draw||u.prepare()},!1),u.regex={numberAndUnit:/^([+-]?(\d+(\.\d*)?|\.\d+)(e[+-]?\d+)?)([a-z%]*)$/i,hex:/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i,rgb:/rgb\((\d+),(\d+),(\d+)\)/,reference:/#([a-z0-9\-_]+)/i,transforms:/\)\s*,?\s*/,whitespace:/\s/g,isHex:/^#[a-f0-9]{3,6}$/i,isRgb:/^rgb\(/,isCss:/[^:]+:[^;]+;?/,isBlank:/^(\s+)?$/,isNumber:/^[+-]?(\d+(\.\d*)?|\.\d+)(e[+-]?\d+)?$/i,isPercent:/^-?[\d\.]+%$/,isImage:/\.(jpg|jpeg|png|gif|svg)(\?[^=]+.*)?/i,delimiter:/[\s,]+/,hyphen:/([^e])\-/gi,pathLetters:/[MLHVCSQTAZ]/gi,isPathLetter:/[MLHVCSQTAZ]/i,numbersWithDots:/((\d?\.\d+(?:e[+-]?\d+)?)((?:\.\d+(?:e[+-]?\d+)?)+))+/gi,dots:/\./g},u.utils={map:function(A,O){for(var X=A.length,ot=[],nt=0;nt1?1:A,new u.Color({r:~~(this.r+(this.destination.r-this.r)*A),g:~~(this.g+(this.destination.g-this.g)*A),b:~~(this.b+(this.destination.b-this.b)*A)})):this}}),u.Color.test=function(A){return A+="",u.regex.isHex.test(A)||u.regex.isRgb.test(A)},u.Color.isRgb=function(A){return A&&typeof A.r=="number"&&typeof A.g=="number"&&typeof A.b=="number"},u.Color.isColor=function(A){return u.Color.isRgb(A)||u.Color.test(A)},u.Array=function(A,O){(A=(A||[]).valueOf()).length==0&&O&&(A=O.valueOf()),this.value=this.parse(A)},u.extend(u.Array,{toString:function(){return this.value.join(" ")},valueOf:function(){return this.value},parse:function(A){return A=A.valueOf(),Array.isArray(A)?A:this.split(A)}}),u.PointArray=function(A,O){u.Array.call(this,A,O||[[0,0]])},u.PointArray.prototype=new u.Array,u.PointArray.prototype.constructor=u.PointArray;for(var d={M:function(A,O,X){return O.x=X.x=A[0],O.y=X.y=A[1],["M",O.x,O.y]},L:function(A,O){return O.x=A[0],O.y=A[1],["L",A[0],A[1]]},H:function(A,O){return O.x=A[0],["H",A[0]]},V:function(A,O){return O.y=A[0],["V",A[0]]},C:function(A,O){return O.x=A[4],O.y=A[5],["C",A[0],A[1],A[2],A[3],A[4],A[5]]},Q:function(A,O){return O.x=A[2],O.y=A[3],["Q",A[0],A[1],A[2],A[3]]},S:function(A,O){return O.x=A[2],O.y=A[3],["S",A[0],A[1],A[2],A[3]]},Z:function(A,O,X){return O.x=X.x,O.y=X.y,["Z"]}},v="mlhvqtcsaz".split(""),m=0,x=v.length;mCt);return ot},bbox:function(){return u.parser.draw||u.prepare(),u.parser.path.setAttribute("d",this.toString()),u.parser.path.getBBox()}}),u.Number=u.invent({create:function(A,O){this.value=0,this.unit=O||"",typeof A=="number"?this.value=isNaN(A)?0:isFinite(A)?A:A<0?-34e37:34e37:typeof A=="string"?(O=A.match(u.regex.numberAndUnit))&&(this.value=parseFloat(O[1]),O[5]=="%"?this.value/=100:O[5]=="s"&&(this.value*=1e3),this.unit=O[5]):A instanceof u.Number&&(this.value=A.valueOf(),this.unit=A.unit)},extend:{toString:function(){return(this.unit=="%"?~~(1e8*this.value)/1e6:this.unit=="s"?this.value/1e3:this.value)+this.unit},toJSON:function(){return this.toString()},valueOf:function(){return this.value},plus:function(A){return A=new u.Number(A),new u.Number(this+A,this.unit||A.unit)},minus:function(A){return A=new u.Number(A),new u.Number(this-A,this.unit||A.unit)},times:function(A){return A=new u.Number(A),new u.Number(this*A,this.unit||A.unit)},divide:function(A){return A=new u.Number(A),new u.Number(this/A,this.unit||A.unit)},to:function(A){var O=new u.Number(this);return typeof A=="string"&&(O.unit=A),O},morph:function(A){return this.destination=new u.Number(A),A.relative&&(this.destination.value+=this.value),this},at:function(A){return this.destination?new u.Number(this.destination).minus(this).times(A).plus(this):this}}}),u.Element=u.invent({create:function(A){this._stroke=u.defaults.attrs.stroke,this._event=null,this.dom={},(this.node=A)&&(this.type=A.nodeName,this.node.instance=this,this._stroke=A.getAttribute("stroke")||this._stroke)},extend:{x:function(A){return this.attr("x",A)},y:function(A){return this.attr("y",A)},cx:function(A){return A==null?this.x()+this.width()/2:this.x(A-this.width()/2)},cy:function(A){return A==null?this.y()+this.height()/2:this.y(A-this.height()/2)},move:function(A,O){return this.x(A).y(O)},center:function(A,O){return this.cx(A).cy(O)},width:function(A){return this.attr("width",A)},height:function(A){return this.attr("height",A)},size:function(A,O){var X=V(this,A,O);return this.width(new u.Number(X.width)).height(new u.Number(X.height))},clone:function(A){this.writeDataToDom();var O=U(this.node.cloneNode(!0));return A?A.add(O):this.after(O),O},remove:function(){return this.parent()&&this.parent().removeElement(this),this},replace:function(A){return this.after(A).remove(),A},addTo:function(A){return A.put(this)},putIn:function(A){return A.add(this)},id:function(A){return this.attr("id",A)},show:function(){return this.style("display","")},hide:function(){return this.style("display","none")},visible:function(){return this.style("display")!="none"},toString:function(){return this.attr("id")},classes:function(){var A=this.attr("class");return A==null?[]:A.trim().split(u.regex.delimiter)},hasClass:function(A){return this.classes().indexOf(A)!=-1},addClass:function(A){if(!this.hasClass(A)){var O=this.classes();O.push(A),this.attr("class",O.join(" "))}return this},removeClass:function(A){return this.hasClass(A)&&this.attr("class",this.classes().filter(function(O){return O!=A}).join(" ")),this},toggleClass:function(A){return this.hasClass(A)?this.removeClass(A):this.addClass(A)},reference:function(A){return u.get(this.attr(A))},parent:function(A){var O=this;if(!O.node.parentNode)return null;if(O=u.adopt(O.node.parentNode),!A)return O;for(;O&&O.node instanceof Q.SVGElement;){if(typeof A=="string"?O.matches(A):O instanceof A)return O;if(!O.node.parentNode||O.node.parentNode.nodeName=="#document")return null;O=u.adopt(O.node.parentNode)}},doc:function(){return this instanceof u.Doc?this:this.parent(u.Doc)},parents:function(A){var O=[],X=this;do{if(!(X=X.parent(A))||!X.node)break;O.push(X)}while(X.parent);return O},matches:function(A){return function(O,X){return(O.matches||O.matchesSelector||O.msMatchesSelector||O.mozMatchesSelector||O.webkitMatchesSelector||O.oMatchesSelector).call(O,X)}(this.node,A)},native:function(){return this.node},svg:function(A){var O=c.createElementNS("http://www.w3.org/2000/svg","svg");if(!(A&&this instanceof u.Parent))return O.appendChild(A=c.createElementNS("http://www.w3.org/2000/svg","svg")),this.writeDataToDom(),A.appendChild(this.node.cloneNode(!0)),O.innerHTML.replace(/^/,"").replace(/<\/svg>$/,"");O.innerHTML=""+A.replace(/\n/,"").replace(/<([\w:-]+)([^<]+?)\/>/g,"<$1$2>")+"";for(var X=0,ot=O.firstChild.childNodes.length;X":function(A){return-Math.cos(A*Math.PI)/2+.5},">":function(A){return Math.sin(A*Math.PI/2)},"<":function(A){return 1-Math.cos(A*Math.PI/2)}},u.morph=function(A){return function(O,X){return new u.MorphObj(O,X).at(A)}},u.Situation=u.invent({create:function(A){this.init=!1,this.reversed=!1,this.reversing=!1,this.duration=new u.Number(A.duration).valueOf(),this.delay=new u.Number(A.delay).valueOf(),this.start=+new Date+this.delay,this.finish=this.start+this.duration,this.ease=A.ease,this.loop=0,this.loops=!1,this.animations={},this.attrs={},this.styles={},this.transforms=[],this.once={}}}),u.FX=u.invent({create:function(A){this._target=A,this.situations=[],this.active=!1,this.situation=null,this.paused=!1,this.lastPos=0,this.pos=0,this.absPos=0,this._speed=1},extend:{animate:function(A,O,X){o(A)==="object"&&(O=A.ease,X=A.delay,A=A.duration);var ot=new u.Situation({duration:A||1e3,delay:X||0,ease:u.easing[O||"-"]||O});return this.queue(ot),this},target:function(A){return A&&A instanceof u.Element?(this._target=A,this):this._target},timeToAbsPos:function(A){return(A-this.situation.start)/(this.situation.duration/this._speed)},absPosToTime:function(A){return this.situation.duration/this._speed*A+this.situation.start},startAnimFrame:function(){this.stopAnimFrame(),this.animationFrame=Q.requestAnimationFrame((function(){this.step()}).bind(this))},stopAnimFrame:function(){Q.cancelAnimationFrame(this.animationFrame)},start:function(){return!this.active&&this.situation&&(this.active=!0,this.startCurrent()),this},startCurrent:function(){return this.situation.start=+new Date+this.situation.delay/this._speed,this.situation.finish=this.situation.start+this.situation.duration/this._speed,this.initAnimations().step()},queue:function(A){return(typeof A=="function"||A instanceof u.Situation)&&this.situations.push(A),this.situation||(this.situation=this.situations.shift()),this},dequeue:function(){return this.stop(),this.situation=this.situations.shift(),this.situation&&(this.situation instanceof u.Situation?this.start():this.situation.call(this)),this},initAnimations:function(){var A,O=this.situation;if(O.init)return this;for(var X in O.animations){A=this.target()[X](),Array.isArray(A)||(A=[A]),Array.isArray(O.animations[X])||(O.animations[X]=[O.animations[X]]);for(var ot=A.length;ot--;)O.animations[X][ot]instanceof u.Number&&(A[ot]=new u.Number(A[ot])),O.animations[X][ot]=A[ot].morph(O.animations[X][ot])}for(var X in O.attrs)O.attrs[X]=new u.MorphObj(this.target().attr(X),O.attrs[X]);for(var X in O.styles)O.styles[X]=new u.MorphObj(this.target().style(X),O.styles[X]);return O.initialTransformation=this.target().matrixify(),O.init=!0,this},clearQueue:function(){return this.situations=[],this},clearCurrent:function(){return this.situation=null,this},stop:function(A,O){var X=this.active;return this.active=!1,O&&this.clearQueue(),A&&this.situation&&(!X&&this.startCurrent(),this.atEnd()),this.stopAnimFrame(),this.clearCurrent()},after:function(A){var O=this.last();return this.target().on("finished.fx",function X(ot){ot.detail.situation==O&&(A.call(this,O),this.off("finished.fx",X))}),this._callStart()},during:function(A){var O=this.last(),X=function(ot){ot.detail.situation==O&&A.call(this,ot.detail.pos,u.morph(ot.detail.pos),ot.detail.eased,O)};return this.target().off("during.fx",X).on("during.fx",X),this.after(function(){this.off("during.fx",X)}),this._callStart()},afterAll:function(A){var O=function X(ot){A.call(this),this.off("allfinished.fx",X)};return this.target().off("allfinished.fx",O).on("allfinished.fx",O),this._callStart()},last:function(){return this.situations.length?this.situations[this.situations.length-1]:this.situation},add:function(A,O,X){return this.last()[X||"animations"][A]=O,this._callStart()},step:function(A){var O,X,ot;A||(this.absPos=this.timeToAbsPos(+new Date)),this.situation.loops!==!1?(O=Math.max(this.absPos,0),X=Math.floor(O),this.situation.loops===!0||Xthis.lastPos&&ct<=nt&&(this.situation.once[ct].call(this.target(),this.pos,nt),delete this.situation.once[ct]);return this.active&&this.target().fire("during",{pos:this.pos,eased:nt,fx:this,situation:this.situation}),this.situation?(this.eachAt(),this.pos==1&&!this.situation.reversed||this.situation.reversed&&this.pos==0?(this.stopAnimFrame(),this.target().fire("finished",{fx:this,situation:this.situation}),this.situations.length||(this.target().fire("allfinished"),this.situations.length||(this.target().off(".fx"),this.active=!1)),this.active?this.dequeue():this.clearCurrent()):!this.paused&&this.active&&this.startAnimFrame(),this.lastPos=nt,this):this},eachAt:function(){var A,O=this,X=this.target(),ot=this.situation;for(var nt in ot.animations)A=[].concat(ot.animations[nt]).map(function(xt){return typeof xt!="string"&&xt.at?xt.at(ot.ease(O.pos),O.pos):xt}),X[nt].apply(X,A);for(var nt in ot.attrs)A=[nt].concat(ot.attrs[nt]).map(function($t){return typeof $t!="string"&&$t.at?$t.at(ot.ease(O.pos),O.pos):$t}),X.attr.apply(X,A);for(var nt in ot.styles)A=[nt].concat(ot.styles[nt]).map(function($t){return typeof $t!="string"&&$t.at?$t.at(ot.ease(O.pos),O.pos):$t}),X.style.apply(X,A);if(ot.transforms.length){A=ot.initialTransformation,nt=0;for(var ct=ot.transforms.length;nt=0;--X)this[J[X]]=A[J[X]]!=null?A[J[X]]:O[J[X]]},extend:{extract:function(){var A=N(this,0,1);N(this,1,0);var O=180/Math.PI*Math.atan2(A.y,A.x)-90;return{x:this.e,y:this.f,transformedX:(this.e*Math.cos(O*Math.PI/180)+this.f*Math.sin(O*Math.PI/180))/Math.sqrt(this.a*this.a+this.b*this.b),transformedY:(this.f*Math.cos(O*Math.PI/180)+this.e*Math.sin(-O*Math.PI/180))/Math.sqrt(this.c*this.c+this.d*this.d),rotation:O,a:this.a,b:this.b,c:this.c,d:this.d,e:this.e,f:this.f,matrix:new u.Matrix(this)}},clone:function(){return new u.Matrix(this)},morph:function(A){return this.destination=new u.Matrix(A),this},multiply:function(A){return new u.Matrix(this.native().multiply(function(O){return O instanceof u.Matrix||(O=new u.Matrix(O)),O}(A).native()))},inverse:function(){return new u.Matrix(this.native().inverse())},translate:function(A,O){return new u.Matrix(this.native().translate(A||0,O||0))},native:function(){for(var A=u.parser.native.createSVGMatrix(),O=J.length-1;O>=0;O--)A[J[O]]=this[J[O]];return A},toString:function(){return"matrix("+q(this.a)+","+q(this.b)+","+q(this.c)+","+q(this.d)+","+q(this.e)+","+q(this.f)+")"}},parent:u.Element,construct:{ctm:function(){return new u.Matrix(this.node.getCTM())},screenCTM:function(){if(this instanceof u.Nested){var A=this.rect(1,1),O=A.node.getScreenCTM();return A.remove(),new u.Matrix(O)}return new u.Matrix(this.node.getScreenCTM())}}}),u.Point=u.invent({create:function(A,O){var X;X=Array.isArray(A)?{x:A[0],y:A[1]}:o(A)==="object"?{x:A.x,y:A.y}:A!=null?{x:A,y:O??A}:{x:0,y:0},this.x=X.x,this.y=X.y},extend:{clone:function(){return new u.Point(this)},morph:function(A,O){return this.destination=new u.Point(A,O),this}}}),u.extend(u.Element,{point:function(A,O){return new u.Point(A,O).transform(this.screenCTM().inverse())}}),u.extend(u.Element,{attr:function(A,O,X){if(A==null){for(A={},X=(O=this.node.attributes).length-1;X>=0;X--)A[O[X].nodeName]=u.regex.isNumber.test(O[X].nodeValue)?parseFloat(O[X].nodeValue):O[X].nodeValue;return A}if(o(A)==="object")for(var ot in A)this.attr(ot,A[ot]);else if(O===null)this.node.removeAttribute(A);else{if(O==null)return(O=this.node.getAttribute(A))==null?u.defaults.attrs[A]:u.regex.isNumber.test(O)?parseFloat(O):O;A=="stroke-width"?this.attr("stroke",parseFloat(O)>0?this._stroke:null):A=="stroke"&&(this._stroke=O),A!="fill"&&A!="stroke"||(u.regex.isImage.test(O)&&(O=this.doc().defs().image(O,0,0)),O instanceof u.Image&&(O=this.doc().defs().pattern(0,0,function(){this.add(O)}))),typeof O=="number"?O=new u.Number(O):u.Color.isColor(O)?O=new u.Color(O):Array.isArray(O)&&(O=new u.Array(O)),A=="leading"?this.leading&&this.leading(O):typeof X=="string"?this.node.setAttributeNS(X,A,O.toString()):this.node.setAttribute(A,O.toString()),!this.rebuild||A!="font-size"&&A!="x"||this.rebuild(A,O)}return this}}),u.extend(u.Element,{transform:function(A,O){var X;return o(A)!=="object"?(X=new u.Matrix(this).extract(),typeof A=="string"?X[A]:X):(X=new u.Matrix(this),O=!!O||!!A.relative,A.a!=null&&(X=O?X.multiply(new u.Matrix(A)):new u.Matrix(A)),this.attr("transform",X))}}),u.extend(u.Element,{untransform:function(){return this.attr("transform",null)},matrixify:function(){return(this.attr("transform")||"").split(u.regex.transforms).slice(0,-1).map(function(A){var O=A.trim().split("(");return[O[0],O[1].split(u.regex.delimiter).map(function(X){return parseFloat(X)})]}).reduce(function(A,O){return O[0]=="matrix"?A.multiply(j(O[1])):A[O[0]].apply(A,O[1])},new u.Matrix)},toParent:function(A){if(this==A)return this;var O=this.screenCTM(),X=A.screenCTM().inverse();return this.addTo(A).untransform().transform(X.multiply(O)),this},toDoc:function(){return this.toParent(this.doc())}}),u.Transformation=u.invent({create:function(A,O){if(arguments.length>1&&typeof O!="boolean")return this.constructor.call(this,[].slice.call(arguments));if(Array.isArray(A))for(var X=0,ot=this.arguments.length;X=0},index:function(A){return[].slice.call(this.node.childNodes).indexOf(A.node)},get:function(A){return u.adopt(this.node.childNodes[A])},first:function(){return this.get(0)},last:function(){return this.get(this.node.childNodes.length-1)},each:function(A,O){for(var X=this.children(),ot=0,nt=X.length;ot=0;O--)A.childNodes[O]instanceof Q.SVGElement&&U(A.childNodes[O]);return u.adopt(A).id(u.eid(A.nodeName))}function q(A){return Math.abs(A)>1e-37?A:0}["fill","stroke"].forEach(function(A){var O={};O[A]=function(X){if(X===void 0)return this;if(typeof X=="string"||u.Color.isRgb(X)||X&&typeof X.fill=="function")this.attr(A,X);else for(var ot=w[A].length-1;ot>=0;ot--)X[w[A][ot]]!=null&&this.attr(w.prefix(A,w[A][ot]),X[w[A][ot]]);return this},u.extend(u.Element,u.FX,O)}),u.extend(u.Element,u.FX,{translate:function(A,O){return this.transform({x:A,y:O})},matrix:function(A){return this.attr("transform",new u.Matrix(arguments.length==6?[].slice.call(arguments):A))},opacity:function(A){return this.attr("opacity",A)},dx:function(A){return this.x(new u.Number(A).plus(this instanceof u.FX?0:this.x()),!0)},dy:function(A){return this.y(new u.Number(A).plus(this instanceof u.FX?0:this.y()),!0)}}),u.extend(u.Path,{length:function(){return this.node.getTotalLength()},pointAt:function(A){return this.node.getPointAtLength(A)}}),u.Set=u.invent({create:function(A){Array.isArray(A)?this.members=A:this.clear()},extend:{add:function(){for(var A=[].slice.call(arguments),O=0,X=A.length;O-1&&this.members.splice(O,1),this},each:function(A){for(var O=0,X=this.members.length;O=0},index:function(A){return this.members.indexOf(A)},get:function(A){return this.members[A]},first:function(){return this.get(0)},last:function(){return this.get(this.members.length-1)},valueOf:function(){return this.members}},construct:{set:function(A){return new u.Set(A)}}}),u.FX.Set=u.invent({create:function(A){this.set=A}}),u.Set.inherit=function(){var A=[];for(var O in u.Shape.prototype)typeof u.Shape.prototype[O]=="function"&&typeof u.Set.prototype[O]!="function"&&A.push(O);for(var O in A.forEach(function(ot){u.Set.prototype[ot]=function(){for(var nt=0,ct=this.members.length;nt=0;A--)delete this.memory()[arguments[A]];return this},memory:function(){return this._memory||(this._memory={})}}),u.get=function(A){var O=c.getElementById(function(X){var ot=(X||"").toString().match(u.regex.reference);if(ot)return ot[1]}(A)||A);return u.adopt(O)},u.select=function(A,O){return new u.Set(u.utils.map((O||c).querySelectorAll(A),function(X){return u.adopt(X)}))},u.extend(u.Parent,{select:function(A){return u.select(A,this.node)}});var J="abcdef".split("");if(typeof Q.CustomEvent!="function"){var rt=function(A,O){O=O||{bubbles:!1,cancelable:!1,detail:void 0};var X=c.createEvent("CustomEvent");return X.initCustomEvent(A,O.bubbles,O.cancelable,O.detail),X};rt.prototype=Q.Event.prototype,u.CustomEvent=rt}else u.CustomEvent=Q.CustomEvent;return u},o(r)==="object"?t.exports=m2.document?fs(m2,m2.document):function(Q){return fs(Q,Q.document)}:m2.SVG=fs(m2,m2.document),(function(){SVG.Filter=SVG.invent({create:"filter",inherit:SVG.Parent,extend:{source:"SourceGraphic",sourceAlpha:"SourceAlpha",background:"BackgroundImage",backgroundAlpha:"BackgroundAlpha",fill:"FillPaint",stroke:"StrokePaint",autoSetIn:!0,put:function(x,w){return this.add(x,w),!x.attr("in")&&this.autoSetIn&&x.attr("in",this.source),x.attr("result")||x.attr("result",x),x},blend:function(x,w,k){return this.put(new SVG.BlendEffect(x,w,k))},colorMatrix:function(x,w){return this.put(new SVG.ColorMatrixEffect(x,w))},convolveMatrix:function(x){return this.put(new SVG.ConvolveMatrixEffect(x))},componentTransfer:function(x){return this.put(new SVG.ComponentTransferEffect(x))},composite:function(x,w,k){return this.put(new SVG.CompositeEffect(x,w,k))},flood:function(x,w){return this.put(new SVG.FloodEffect(x,w))},offset:function(x,w){return this.put(new SVG.OffsetEffect(x,w))},image:function(x){return this.put(new SVG.ImageEffect(x))},merge:function(){var x=[void 0];for(var w in arguments)x.push(arguments[w]);return this.put(new(SVG.MergeEffect.bind.apply(SVG.MergeEffect,x)))},gaussianBlur:function(x,w){return this.put(new SVG.GaussianBlurEffect(x,w))},morphology:function(x,w){return this.put(new SVG.MorphologyEffect(x,w))},diffuseLighting:function(x,w,k){return this.put(new SVG.DiffuseLightingEffect(x,w,k))},displacementMap:function(x,w,k,L,D){return this.put(new SVG.DisplacementMapEffect(x,w,k,L,D))},specularLighting:function(x,w,k,L){return this.put(new SVG.SpecularLightingEffect(x,w,k,L))},tile:function(){return this.put(new SVG.TileEffect)},turbulence:function(x,w,k,L,D){return this.put(new SVG.TurbulenceEffect(x,w,k,L,D))},toString:function(){return"url(#"+this.attr("id")+")"}}}),SVG.extend(SVG.Defs,{filter:function(x){var w=this.put(new SVG.Filter);return typeof x=="function"&&x.call(w,w),w}}),SVG.extend(SVG.Container,{filter:function(x){return this.defs().filter(x)}}),SVG.extend(SVG.Element,SVG.G,SVG.Nested,{filter:function(x){return this.filterer=x instanceof SVG.Element?x:this.doc().filter(x),this.doc()&&this.filterer.doc()!==this.doc()&&this.doc().defs().add(this.filterer),this.attr("filter",this.filterer),this.filterer},unfilter:function(x){return this.filterer&&x===!0&&this.filterer.remove(),delete this.filterer,this.attr("filter",null)}}),SVG.Effect=SVG.invent({create:function(){this.constructor.call(this)},inherit:SVG.Element,extend:{in:function(x){return x==null?this.parent()&&this.parent().select('[result="'+this.attr("in")+'"]').get(0)||this.attr("in"):this.attr("in",x)},result:function(x){return x==null?this.attr("result"):this.attr("result",x)},toString:function(){return this.result()}}}),SVG.ParentEffect=SVG.invent({create:function(){this.constructor.call(this)},inherit:SVG.Parent,extend:{in:function(x){return x==null?this.parent()&&this.parent().select('[result="'+this.attr("in")+'"]').get(0)||this.attr("in"):this.attr("in",x)},result:function(x){return x==null?this.attr("result"):this.attr("result",x)},toString:function(){return this.result()}}});var Q={blend:function(x,w){return this.parent()&&this.parent().blend(this,x,w)},colorMatrix:function(x,w){return this.parent()&&this.parent().colorMatrix(x,w).in(this)},convolveMatrix:function(x){return this.parent()&&this.parent().convolveMatrix(x).in(this)},componentTransfer:function(x){return this.parent()&&this.parent().componentTransfer(x).in(this)},composite:function(x,w){return this.parent()&&this.parent().composite(this,x,w)},flood:function(x,w){return this.parent()&&this.parent().flood(x,w)},offset:function(x,w){return this.parent()&&this.parent().offset(x,w).in(this)},image:function(x){return this.parent()&&this.parent().image(x)},merge:function(){return this.parent()&&this.parent().merge.apply(this.parent(),[this].concat(arguments))},gaussianBlur:function(x,w){return this.parent()&&this.parent().gaussianBlur(x,w).in(this)},morphology:function(x,w){return this.parent()&&this.parent().morphology(x,w).in(this)},diffuseLighting:function(x,w,k){return this.parent()&&this.parent().diffuseLighting(x,w,k).in(this)},displacementMap:function(x,w,k,L){return this.parent()&&this.parent().displacementMap(this,x,w,k,L)},specularLighting:function(x,w,k,L){return this.parent()&&this.parent().specularLighting(x,w,k,L).in(this)},tile:function(){return this.parent()&&this.parent().tile().in(this)},turbulence:function(x,w,k,L,D){return this.parent()&&this.parent().turbulence(x,w,k,L,D).in(this)}};SVG.extend(SVG.Effect,Q),SVG.extend(SVG.ParentEffect,Q),SVG.ChildEffect=SVG.invent({create:function(){this.constructor.call(this)},inherit:SVG.Element,extend:{in:function(x){this.attr("in",x)}}});var c={blend:function(x,w,k){this.attr({in:x,in2:w,mode:k||"normal"})},colorMatrix:function(x,w){x=="matrix"&&(w=v(w)),this.attr({type:x,values:w===void 0?null:w})},convolveMatrix:function(x){x=v(x),this.attr({order:Math.sqrt(x.split(" ").length),kernelMatrix:x})},composite:function(x,w,k){this.attr({in:x,in2:w,operator:k})},flood:function(x,w){this.attr("flood-color",x),w!=null&&this.attr("flood-opacity",w)},offset:function(x,w){this.attr({dx:x,dy:w})},image:function(x){this.attr("href",x,SVG.xlink)},displacementMap:function(x,w,k,L,D){this.attr({in:x,in2:w,scale:k,xChannelSelector:L,yChannelSelector:D})},gaussianBlur:function(x,w){x!=null||w!=null?this.attr("stdDeviation",function(k){if(!Array.isArray(k))return k;for(var L=0,D=k.length,P=[];L1&&(l1*=D=Math.sqrt(D),i1*=D),P=new SVG.Matrix().rotate(y1).scale(1/l1,1/i1).rotate(-y1),N1=N1.transform(P),O1=O1.transform(P),V=[O1.x-N1.x,O1.y-N1.y],j=V[0]*V[0]+V[1]*V[1],N=Math.sqrt(j),V[0]/=N,V[1]/=N,U=j<4?Math.sqrt(1-j/4):0,xr===Lr&&(U*=-1),q=new SVG.Point((O1.x+N1.x)/2+U*-V[1],(O1.y+N1.y)/2+U*V[0]),J=new SVG.Point(N1.x-q.x,N1.y-q.y),rt=new SVG.Point(O1.x-q.x,O1.y-q.y),A=Math.acos(J.x/Math.sqrt(J.x*J.x+J.y*J.y)),J.y<0&&(A*=-1),O=Math.acos(rt.x/Math.sqrt(rt.x*rt.x+rt.y*rt.y)),rt.y<0&&(O*=-1),Lr&&A>O&&(O+=2*Math.PI),!Lr&&Ax.maxX-u.width&&(w=(v=x.maxX-u.width)-this.startPoints.box.x),x.minY!=null&&mx.maxY-u.height&&(k=(m=x.maxY-u.height)-this.startPoints.box.y),x.snapToGrid!=null&&(v-=v%x.snapToGrid,m-=m%x.snapToGrid,w-=w%x.snapToGrid,k-=k%x.snapToGrid),this.el instanceof SVG.G?this.el.matrix(this.startPoints.transform).transform({x:w,y:k},!0):this.el.move(v,m));return d},Q.prototype.end=function(c){var u=this.drag(c);this.el.fire("dragend",{event:c,p:u,m:this.m,handler:this}),SVG.off(window,"mousemove.drag"),SVG.off(window,"touchmove.drag"),SVG.off(window,"mouseup.drag"),SVG.off(window,"touchend.drag")},SVG.extend(SVG.Element,{draggable:function(c,u){typeof c!="function"&&typeof c!="object"||(u=c,c=!0);var d=this.remember("_draggable")||new Q(this);return(c=c===void 0||c)?d.init(u||{},c):(this.off("mousedown.drag"),this.off("touchstart.drag")),this}})}).call(void 0),function(){function Q(c){this.el=c,c.remember("_selectHandler",this),this.pointSelection={isSelected:!1},this.rectSelection={isSelected:!1},this.pointsList={lt:[0,0],rt:["width",0],rb:["width","height"],lb:[0,"height"],t:["width",0],r:["width","height"],b:["width","height"],l:[0,"height"]},this.pointCoord=function(u,d,v){var m=typeof u!="string"?u:d[u];return v?m/2:m},this.pointCoords=function(u,d){var v=this.pointsList[u];return{x:this.pointCoord(v[0],d,u==="t"||u==="b"),y:this.pointCoord(v[1],d,u==="r"||u==="l")}}}Q.prototype.init=function(c,u){var d=this.el.bbox();this.options={};var v=this.el.selectize.defaults.points;for(var m in this.el.selectize.defaults)this.options[m]=this.el.selectize.defaults[m],u[m]!==void 0&&(this.options[m]=u[m]);var x=["points","pointsExclude"];for(var m in x){var w=this.options[x[m]];typeof w=="string"?w=w.length>0?w.split(/\s*,\s*/i):[]:typeof w=="boolean"&&x[m]==="points"&&(w=w?v:[]),this.options[x[m]]=w}this.options.points=[v,this.options.points].reduce(function(k,L){return k.filter(function(D){return L.indexOf(D)>-1})}),this.options.points=[this.options.points,this.options.pointsExclude].reduce(function(k,L){return k.filter(function(D){return L.indexOf(D)<0})}),this.parent=this.el.parent(),this.nested=this.nested||this.parent.group(),this.nested.matrix(new SVG.Matrix(this.el).translate(d.x,d.y)),this.options.deepSelect&&["line","polyline","polygon"].indexOf(this.el.type)!==-1?this.selectPoints(c):this.selectRect(c),this.observe(),this.cleanup()},Q.prototype.selectPoints=function(c){return this.pointSelection.isSelected=c,this.pointSelection.set||(this.pointSelection.set=this.parent.set(),this.drawPoints()),this},Q.prototype.getPointArray=function(){var c=this.el.bbox();return this.el.array().valueOf().map(function(u){return[u[0]-c.x,u[1]-c.y]})},Q.prototype.drawPoints=function(){for(var c=this,u=this.getPointArray(),d=0,v=u.length;d0&&this.parameters.box.height-w[1]>0){if(this.parameters.type==="text")return this.el.move(this.parameters.box.x+w[0],this.parameters.box.y),void this.el.attr("font-size",this.parameters.fontSize-w[0]);w=this.checkAspectRatio(w),this.el.move(this.parameters.box.x+w[0],this.parameters.box.y+w[1]).size(this.parameters.box.width-w[0],this.parameters.box.height-w[1])}};break;case"rt":this.calc=function(m,x){var w=this.snapToGrid(m,x,2);if(this.parameters.box.width+w[0]>0&&this.parameters.box.height-w[1]>0){if(this.parameters.type==="text")return this.el.move(this.parameters.box.x-w[0],this.parameters.box.y),void this.el.attr("font-size",this.parameters.fontSize+w[0]);w=this.checkAspectRatio(w,!0),this.el.move(this.parameters.box.x,this.parameters.box.y+w[1]).size(this.parameters.box.width+w[0],this.parameters.box.height-w[1])}};break;case"rb":this.calc=function(m,x){var w=this.snapToGrid(m,x,0);if(this.parameters.box.width+w[0]>0&&this.parameters.box.height+w[1]>0){if(this.parameters.type==="text")return this.el.move(this.parameters.box.x-w[0],this.parameters.box.y),void this.el.attr("font-size",this.parameters.fontSize+w[0]);w=this.checkAspectRatio(w),this.el.move(this.parameters.box.x,this.parameters.box.y).size(this.parameters.box.width+w[0],this.parameters.box.height+w[1])}};break;case"lb":this.calc=function(m,x){var w=this.snapToGrid(m,x,1);if(this.parameters.box.width-w[0]>0&&this.parameters.box.height+w[1]>0){if(this.parameters.type==="text")return this.el.move(this.parameters.box.x+w[0],this.parameters.box.y),void this.el.attr("font-size",this.parameters.fontSize-w[0]);w=this.checkAspectRatio(w,!0),this.el.move(this.parameters.box.x+w[0],this.parameters.box.y).size(this.parameters.box.width-w[0],this.parameters.box.height+w[1])}};break;case"t":this.calc=function(m,x){var w=this.snapToGrid(m,x,2);if(this.parameters.box.height-w[1]>0){if(this.parameters.type==="text")return;this.el.move(this.parameters.box.x,this.parameters.box.y+w[1]).height(this.parameters.box.height-w[1])}};break;case"r":this.calc=function(m,x){var w=this.snapToGrid(m,x,0);if(this.parameters.box.width+w[0]>0){if(this.parameters.type==="text")return;this.el.move(this.parameters.box.x,this.parameters.box.y).width(this.parameters.box.width+w[0])}};break;case"b":this.calc=function(m,x){var w=this.snapToGrid(m,x,0);if(this.parameters.box.height+w[1]>0){if(this.parameters.type==="text")return;this.el.move(this.parameters.box.x,this.parameters.box.y).height(this.parameters.box.height+w[1])}};break;case"l":this.calc=function(m,x){var w=this.snapToGrid(m,x,1);if(this.parameters.box.width-w[0]>0){if(this.parameters.type==="text")return;this.el.move(this.parameters.box.x+w[0],this.parameters.box.y).width(this.parameters.box.width-w[0])}};break;case"rot":this.calc=function(m,x){var w=m+this.parameters.p.x,k=x+this.parameters.p.y,L=Math.atan2(this.parameters.p.y-this.parameters.box.y-this.parameters.box.height/2,this.parameters.p.x-this.parameters.box.x-this.parameters.box.width/2),D=Math.atan2(k-this.parameters.box.y-this.parameters.box.height/2,w-this.parameters.box.x-this.parameters.box.width/2),P=this.parameters.rotation+180*(D-L)/Math.PI+this.options.snapToAngle/2;this.el.center(this.parameters.box.cx,this.parameters.box.cy).rotate(P-P%this.options.snapToAngle,this.parameters.box.cx,this.parameters.box.cy)};break;case"point":this.calc=function(m,x){var w=this.snapToGrid(m,x,this.parameters.pointCoords[0],this.parameters.pointCoords[1]),k=this.el.array().valueOf();k[this.parameters.i][0]=this.parameters.pointCoords[0]+w[0],k[this.parameters.i][1]=this.parameters.pointCoords[1]+w[1],this.el.plot(k)}}this.el.fire("resizestart",{dx:this.parameters.x,dy:this.parameters.y,event:c}),SVG.on(window,"touchmove.resize",function(m){u.update(m||window.event)}),SVG.on(window,"touchend.resize",function(){u.done()}),SVG.on(window,"mousemove.resize",function(m){u.update(m||window.event)}),SVG.on(window,"mouseup.resize",function(){u.done()})},Q.prototype.update=function(c){if(c){var u=this._extractPosition(c),d=this.transformPoint(u.x,u.y),v=d.x-this.parameters.p.x,m=d.y-this.parameters.p.y;this.lastUpdateCall=[v,m],this.calc(v,m),this.el.fire("resizing",{dx:v,dy:m,event:c})}else this.lastUpdateCall&&this.calc(this.lastUpdateCall[0],this.lastUpdateCall[1])},Q.prototype.done=function(){this.lastUpdateCall=null,SVG.off(window,"mousemove.resize"),SVG.off(window,"mouseup.resize"),SVG.off(window,"touchmove.resize"),SVG.off(window,"touchend.resize"),this.el.fire("resizedone")},Q.prototype.snapToGrid=function(c,u,d,v){var m;return v!==void 0?m=[(d+c)%this.options.snapToGrid,(v+u)%this.options.snapToGrid]:(d=d??3,m=[(this.parameters.box.x+c+(1&d?0:this.parameters.box.width))%this.options.snapToGrid,(this.parameters.box.y+u+(2&d?0:this.parameters.box.height))%this.options.snapToGrid]),c<0&&(m[0]-=this.options.snapToGrid),u<0&&(m[1]-=this.options.snapToGrid),c-=Math.abs(m[0])w.maxX&&(c=w.maxX-m),w.minY!==void 0&&x+uw.maxY&&(u=w.maxY-x),[c,u]},Q.prototype.checkAspectRatio=function(c,u){if(!this.options.saveAspectRatio)return c;var d=c.slice(),v=this.parameters.box.width/this.parameters.box.height,m=this.parameters.box.width+c[0],x=this.parameters.box.height-c[1],w=m/x;return wv&&(d[0]=this.parameters.box.width-x*v,u&&(d[0]=-d[0])),d},SVG.extend(SVG.Element,{resize:function(c){return(this.remember("_resizeHandler")||new Q(this)).init(c||{}),this}}),SVG.Element.prototype.resize.defaults={snapToAngle:.1,snapToGrid:1,constraint:{},saveAspectRatio:!1}}).call(this)}(),window.Apex===void 0&&(window.Apex={});var I1=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w}return l(Q,[{key:"initModules",value:function(){this.ctx.publicMethods=["updateOptions","updateSeries","appendData","appendSeries","isSeriesHidden","toggleSeries","showSeries","hideSeries","setLocale","resetSeries","zoomX","toggleDataPointSelection","dataURI","exportToCSV","addXaxisAnnotation","addYaxisAnnotation","addPointAnnotation","clearAnnotations","removeAnnotation","paper","destroy"],this.ctx.eventList=["click","mousedown","mousemove","mouseleave","touchstart","touchmove","touchleave","mouseup","touchend"],this.ctx.animations=new R(this.ctx),this.ctx.axes=new Kt(this.ctx),this.ctx.core=new r1(this.ctx.el,this.ctx),this.ctx.config=new _t({}),this.ctx.data=new It(this.ctx),this.ctx.grid=new ue(this.ctx),this.ctx.graphics=new $(this.ctx),this.ctx.coreUtils=new G(this.ctx),this.ctx.crosshairs=new fe(this.ctx),this.ctx.events=new se(this.ctx),this.ctx.exports=new ae(this.ctx),this.ctx.localization=new Se(this.ctx),this.ctx.options=new lt,this.ctx.responsive=new ne(this.ctx),this.ctx.series=new Xt(this.ctx),this.ctx.theme=new ce(this.ctx),this.ctx.formatters=new at(this.ctx),this.ctx.titleSubtitle=new xe(this.ctx),this.ctx.legend=new st(this.ctx),this.ctx.toolbar=new Et(this.ctx),this.ctx.tooltip=new c1(this.ctx),this.ctx.dimensions=new Pe(this.ctx),this.ctx.updateHelpers=new s1(this.ctx),this.ctx.zoomPanSelection=new zt(this.ctx),this.ctx.w.globals.tooltip=new c1(this.ctx)}}]),Q}(),Nr=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w}return l(Q,[{key:"clear",value:function(c){var u=c.isUpdating;this.ctx.zoomPanSelection&&this.ctx.zoomPanSelection.destroy(),this.ctx.toolbar&&this.ctx.toolbar.destroy(),this.ctx.animations=null,this.ctx.axes=null,this.ctx.annotations=null,this.ctx.core=null,this.ctx.data=null,this.ctx.grid=null,this.ctx.series=null,this.ctx.responsive=null,this.ctx.theme=null,this.ctx.formatters=null,this.ctx.titleSubtitle=null,this.ctx.legend=null,this.ctx.dimensions=null,this.ctx.options=null,this.ctx.crosshairs=null,this.ctx.zoomPanSelection=null,this.ctx.updateHelpers=null,this.ctx.toolbar=null,this.ctx.localization=null,this.ctx.w.globals.tooltip=null,this.clearDomElements({isUpdating:u})}},{key:"killSVG",value:function(c){c.each(function(u,d){this.removeClass("*"),this.off(),this.stop()},!0),c.ungroup(),c.clear()}},{key:"clearDomElements",value:function(c){var u=this,d=c.isUpdating,v=this.w.globals.dom.Paper.node;v.parentNode&&v.parentNode.parentNode&&!d&&(v.parentNode.parentNode.style.minHeight="unset");var m=this.w.globals.dom.baseEl;m&&this.ctx.eventList.forEach(function(w){m.removeEventListener(w,u.ctx.events.documentEvent)});var x=this.w.globals.dom;if(this.ctx.el!==null)for(;this.ctx.el.firstChild;)this.ctx.el.removeChild(this.ctx.el.firstChild);this.killSVG(x.Paper),x.Paper.remove(),x.elWrap=null,x.elGraphical=null,x.elLegendWrap=null,x.elLegendForeign=null,x.baseEl=null,x.elGridRect=null,x.elGridRectMask=null,x.elGridRectMarkerMask=null,x.elForecastMask=null,x.elNonForecastMask=null,x.elDefs=null}}]),Q}(),Cn=new WeakMap,v6=function(){function Q(c,u){a(this,Q),this.opts=u,this.ctx=this,this.w=new Mt(u).init(),this.el=c,this.w.globals.cuid=E.randomId(),this.w.globals.chartID=this.w.config.chart.id?E.escapeString(this.w.config.chart.id):this.w.globals.cuid,new I1(this).initModules(),this.create=E.bind(this.create,this),this.windowResizeHandler=this._windowResizeHandler.bind(this),this.parentResizeHandler=this._parentResizeCallback.bind(this)}return l(Q,[{key:"render",value:function(){var c=this;return new Promise(function(u,d){if(c.el!==null){Apex._chartInstances===void 0&&(Apex._chartInstances=[]),c.w.config.chart.id&&Apex._chartInstances.push({id:c.w.globals.chartID,group:c.w.config.chart.group,chart:c}),c.setLocale(c.w.config.chart.defaultLocale);var v=c.w.config.chart.events.beforeMount;typeof v=="function"&&v(c,c.w),c.events.fireEvent("beforeMount",[c,c.w]),window.addEventListener("resize",c.windowResizeHandler),function(V,N){var j=!1;if(V.nodeType!==Node.DOCUMENT_FRAGMENT_NODE){var U=V.getBoundingClientRect();V.style.display!=="none"&&U.width!==0||(j=!0)}var q=new ResizeObserver(function(J){j&&N.call(V,J),j=!0});V.nodeType===Node.DOCUMENT_FRAGMENT_NODE?Array.from(V.children).forEach(function(J){return q.observe(J)}):q.observe(V),Cn.set(N,q)}(c.el.parentNode,c.parentResizeHandler);var m=c.el.getRootNode&&c.el.getRootNode(),x=E.is("ShadowRoot",m),w=c.el.ownerDocument,k=x?m.getElementById("apexcharts-css"):w.getElementById("apexcharts-css");if(!k){var L;(k=document.createElement("style")).id="apexcharts-css",k.textContent=`@keyframes opaque { +`:""):(typeof A=="function"?A.call(this,this):this.plain(A),this)},dx:function(A){return this.attr("dx",A)},dy:function(A){return this.attr("dy",A)},newLine:function(){var A=this.parent(u.Text);return this.dom.newLined=!0,this.dy(A.dom.leading*A.attr("font-size")).attr("x",A.x())}}}),u.extend(u.Text,u.Tspan,{plain:function(A){return this._build===!1&&this.clear(),this.node.appendChild(c.createTextNode(A)),this},tspan:function(A){var O=(this.textPath&&this.textPath()||this).node,X=new u.Tspan;return this._build===!1&&this.clear(),O.appendChild(X.node),X.text(A)},clear:function(){for(var A=(this.textPath&&this.textPath()||this).node;A.hasChildNodes();)A.removeChild(A.lastChild);return this},length:function(){return this.node.getComputedTextLength()}}),u.TextPath=u.invent({create:"textPath",inherit:u.Parent,parent:u.Text,construct:{morphArray:u.PathArray,array:function(){var A=this.track();return A?A.array():null},plot:function(A){var O=this.track(),X=null;return O&&(X=O.plot(A)),A==null?X:this},track:function(){var A=this.textPath();if(A)return A.reference("href")},textPath:function(){if(this.node.firstChild&&this.node.firstChild.nodeName=="textPath")return u.adopt(this.node.firstChild)}}}),u.Nested=u.invent({create:function(){this.constructor.call(this,u.create("svg")),this.style("overflow","visible")},inherit:u.Container,construct:{nested:function(){return this.put(new u.Nested)}}});var w={stroke:["color","width","opacity","linecap","linejoin","miterlimit","dasharray","dashoffset"],fill:["color","opacity","rule"],prefix:function(A,O){return O=="color"?A:A+"-"+O}};function k(A,O,X,ot){return X+ot.replace(u.regex.dots," .")}function L(A){return A.toLowerCase().replace(/-(.)/g,function(O,X){return X.toUpperCase()})}function D(A){return A.charAt(0).toUpperCase()+A.slice(1)}function P(A){var O=A.toString(16);return O.length==1?"0"+O:O}function V(A,O,X){if(O==null||X==null){var ot=A.bbox();O==null?O=ot.width/ot.height*X:X==null&&(X=ot.height/ot.width*O)}return{width:O,height:X}}function N(A,O,X){return{x:O*A.a+X*A.c+0,y:O*A.b+X*A.d+0}}function j(A){return{a:A[0],b:A[1],c:A[2],d:A[3],e:A[4],f:A[5]}}function U(A){for(var O=A.childNodes.length-1;O>=0;O--)A.childNodes[O]instanceof Q.SVGElement&&U(A.childNodes[O]);return u.adopt(A).id(u.eid(A.nodeName))}function q(A){return Math.abs(A)>1e-37?A:0}["fill","stroke"].forEach(function(A){var O={};O[A]=function(X){if(X===void 0)return this;if(typeof X=="string"||u.Color.isRgb(X)||X&&typeof X.fill=="function")this.attr(A,X);else for(var ot=w[A].length-1;ot>=0;ot--)X[w[A][ot]]!=null&&this.attr(w.prefix(A,w[A][ot]),X[w[A][ot]]);return this},u.extend(u.Element,u.FX,O)}),u.extend(u.Element,u.FX,{translate:function(A,O){return this.transform({x:A,y:O})},matrix:function(A){return this.attr("transform",new u.Matrix(arguments.length==6?[].slice.call(arguments):A))},opacity:function(A){return this.attr("opacity",A)},dx:function(A){return this.x(new u.Number(A).plus(this instanceof u.FX?0:this.x()),!0)},dy:function(A){return this.y(new u.Number(A).plus(this instanceof u.FX?0:this.y()),!0)}}),u.extend(u.Path,{length:function(){return this.node.getTotalLength()},pointAt:function(A){return this.node.getPointAtLength(A)}}),u.Set=u.invent({create:function(A){Array.isArray(A)?this.members=A:this.clear()},extend:{add:function(){for(var A=[].slice.call(arguments),O=0,X=A.length;O-1&&this.members.splice(O,1),this},each:function(A){for(var O=0,X=this.members.length;O=0},index:function(A){return this.members.indexOf(A)},get:function(A){return this.members[A]},first:function(){return this.get(0)},last:function(){return this.get(this.members.length-1)},valueOf:function(){return this.members}},construct:{set:function(A){return new u.Set(A)}}}),u.FX.Set=u.invent({create:function(A){this.set=A}}),u.Set.inherit=function(){var A=[];for(var O in u.Shape.prototype)typeof u.Shape.prototype[O]=="function"&&typeof u.Set.prototype[O]!="function"&&A.push(O);for(var O in A.forEach(function(ot){u.Set.prototype[ot]=function(){for(var nt=0,ct=this.members.length;nt=0;A--)delete this.memory()[arguments[A]];return this},memory:function(){return this._memory||(this._memory={})}}),u.get=function(A){var O=c.getElementById(function(X){var ot=(X||"").toString().match(u.regex.reference);if(ot)return ot[1]}(A)||A);return u.adopt(O)},u.select=function(A,O){return new u.Set(u.utils.map((O||c).querySelectorAll(A),function(X){return u.adopt(X)}))},u.extend(u.Parent,{select:function(A){return u.select(A,this.node)}});var J="abcdef".split("");if(typeof Q.CustomEvent!="function"){var rt=function(A,O){O=O||{bubbles:!1,cancelable:!1,detail:void 0};var X=c.createEvent("CustomEvent");return X.initCustomEvent(A,O.bubbles,O.cancelable,O.detail),X};rt.prototype=Q.Event.prototype,u.CustomEvent=rt}else u.CustomEvent=Q.CustomEvent;return u},o(r)==="object"?t.exports=d2.document?fs(d2,d2.document):function(Q){return fs(Q,Q.document)}:d2.SVG=fs(d2,d2.document),(function(){SVG.Filter=SVG.invent({create:"filter",inherit:SVG.Parent,extend:{source:"SourceGraphic",sourceAlpha:"SourceAlpha",background:"BackgroundImage",backgroundAlpha:"BackgroundAlpha",fill:"FillPaint",stroke:"StrokePaint",autoSetIn:!0,put:function(x,w){return this.add(x,w),!x.attr("in")&&this.autoSetIn&&x.attr("in",this.source),x.attr("result")||x.attr("result",x),x},blend:function(x,w,k){return this.put(new SVG.BlendEffect(x,w,k))},colorMatrix:function(x,w){return this.put(new SVG.ColorMatrixEffect(x,w))},convolveMatrix:function(x){return this.put(new SVG.ConvolveMatrixEffect(x))},componentTransfer:function(x){return this.put(new SVG.ComponentTransferEffect(x))},composite:function(x,w,k){return this.put(new SVG.CompositeEffect(x,w,k))},flood:function(x,w){return this.put(new SVG.FloodEffect(x,w))},offset:function(x,w){return this.put(new SVG.OffsetEffect(x,w))},image:function(x){return this.put(new SVG.ImageEffect(x))},merge:function(){var x=[void 0];for(var w in arguments)x.push(arguments[w]);return this.put(new(SVG.MergeEffect.bind.apply(SVG.MergeEffect,x)))},gaussianBlur:function(x,w){return this.put(new SVG.GaussianBlurEffect(x,w))},morphology:function(x,w){return this.put(new SVG.MorphologyEffect(x,w))},diffuseLighting:function(x,w,k){return this.put(new SVG.DiffuseLightingEffect(x,w,k))},displacementMap:function(x,w,k,L,D){return this.put(new SVG.DisplacementMapEffect(x,w,k,L,D))},specularLighting:function(x,w,k,L){return this.put(new SVG.SpecularLightingEffect(x,w,k,L))},tile:function(){return this.put(new SVG.TileEffect)},turbulence:function(x,w,k,L,D){return this.put(new SVG.TurbulenceEffect(x,w,k,L,D))},toString:function(){return"url(#"+this.attr("id")+")"}}}),SVG.extend(SVG.Defs,{filter:function(x){var w=this.put(new SVG.Filter);return typeof x=="function"&&x.call(w,w),w}}),SVG.extend(SVG.Container,{filter:function(x){return this.defs().filter(x)}}),SVG.extend(SVG.Element,SVG.G,SVG.Nested,{filter:function(x){return this.filterer=x instanceof SVG.Element?x:this.doc().filter(x),this.doc()&&this.filterer.doc()!==this.doc()&&this.doc().defs().add(this.filterer),this.attr("filter",this.filterer),this.filterer},unfilter:function(x){return this.filterer&&x===!0&&this.filterer.remove(),delete this.filterer,this.attr("filter",null)}}),SVG.Effect=SVG.invent({create:function(){this.constructor.call(this)},inherit:SVG.Element,extend:{in:function(x){return x==null?this.parent()&&this.parent().select('[result="'+this.attr("in")+'"]').get(0)||this.attr("in"):this.attr("in",x)},result:function(x){return x==null?this.attr("result"):this.attr("result",x)},toString:function(){return this.result()}}}),SVG.ParentEffect=SVG.invent({create:function(){this.constructor.call(this)},inherit:SVG.Parent,extend:{in:function(x){return x==null?this.parent()&&this.parent().select('[result="'+this.attr("in")+'"]').get(0)||this.attr("in"):this.attr("in",x)},result:function(x){return x==null?this.attr("result"):this.attr("result",x)},toString:function(){return this.result()}}});var Q={blend:function(x,w){return this.parent()&&this.parent().blend(this,x,w)},colorMatrix:function(x,w){return this.parent()&&this.parent().colorMatrix(x,w).in(this)},convolveMatrix:function(x){return this.parent()&&this.parent().convolveMatrix(x).in(this)},componentTransfer:function(x){return this.parent()&&this.parent().componentTransfer(x).in(this)},composite:function(x,w){return this.parent()&&this.parent().composite(this,x,w)},flood:function(x,w){return this.parent()&&this.parent().flood(x,w)},offset:function(x,w){return this.parent()&&this.parent().offset(x,w).in(this)},image:function(x){return this.parent()&&this.parent().image(x)},merge:function(){return this.parent()&&this.parent().merge.apply(this.parent(),[this].concat(arguments))},gaussianBlur:function(x,w){return this.parent()&&this.parent().gaussianBlur(x,w).in(this)},morphology:function(x,w){return this.parent()&&this.parent().morphology(x,w).in(this)},diffuseLighting:function(x,w,k){return this.parent()&&this.parent().diffuseLighting(x,w,k).in(this)},displacementMap:function(x,w,k,L){return this.parent()&&this.parent().displacementMap(this,x,w,k,L)},specularLighting:function(x,w,k,L){return this.parent()&&this.parent().specularLighting(x,w,k,L).in(this)},tile:function(){return this.parent()&&this.parent().tile().in(this)},turbulence:function(x,w,k,L,D){return this.parent()&&this.parent().turbulence(x,w,k,L,D).in(this)}};SVG.extend(SVG.Effect,Q),SVG.extend(SVG.ParentEffect,Q),SVG.ChildEffect=SVG.invent({create:function(){this.constructor.call(this)},inherit:SVG.Element,extend:{in:function(x){this.attr("in",x)}}});var c={blend:function(x,w,k){this.attr({in:x,in2:w,mode:k||"normal"})},colorMatrix:function(x,w){x=="matrix"&&(w=v(w)),this.attr({type:x,values:w===void 0?null:w})},convolveMatrix:function(x){x=v(x),this.attr({order:Math.sqrt(x.split(" ").length),kernelMatrix:x})},composite:function(x,w,k){this.attr({in:x,in2:w,operator:k})},flood:function(x,w){this.attr("flood-color",x),w!=null&&this.attr("flood-opacity",w)},offset:function(x,w){this.attr({dx:x,dy:w})},image:function(x){this.attr("href",x,SVG.xlink)},displacementMap:function(x,w,k,L,D){this.attr({in:x,in2:w,scale:k,xChannelSelector:L,yChannelSelector:D})},gaussianBlur:function(x,w){x!=null||w!=null?this.attr("stdDeviation",function(k){if(!Array.isArray(k))return k;for(var L=0,D=k.length,P=[];L1&&(l1*=D=Math.sqrt(D),i1*=D),P=new SVG.Matrix().rotate(g1).scale(1/l1,1/i1).rotate(-g1),O1=O1.transform(P),F1=F1.transform(P),V=[F1.x-O1.x,F1.y-O1.y],j=V[0]*V[0]+V[1]*V[1],N=Math.sqrt(j),V[0]/=N,V[1]/=N,U=j<4?Math.sqrt(1-j/4):0,yr===_r&&(U*=-1),q=new SVG.Point((F1.x+O1.x)/2+U*-V[1],(F1.y+O1.y)/2+U*V[0]),J=new SVG.Point(O1.x-q.x,O1.y-q.y),rt=new SVG.Point(F1.x-q.x,F1.y-q.y),A=Math.acos(J.x/Math.sqrt(J.x*J.x+J.y*J.y)),J.y<0&&(A*=-1),O=Math.acos(rt.x/Math.sqrt(rt.x*rt.x+rt.y*rt.y)),rt.y<0&&(O*=-1),_r&&A>O&&(O+=2*Math.PI),!_r&&Ax.maxX-u.width&&(w=(v=x.maxX-u.width)-this.startPoints.box.x),x.minY!=null&&mx.maxY-u.height&&(k=(m=x.maxY-u.height)-this.startPoints.box.y),x.snapToGrid!=null&&(v-=v%x.snapToGrid,m-=m%x.snapToGrid,w-=w%x.snapToGrid,k-=k%x.snapToGrid),this.el instanceof SVG.G?this.el.matrix(this.startPoints.transform).transform({x:w,y:k},!0):this.el.move(v,m));return d},Q.prototype.end=function(c){var u=this.drag(c);this.el.fire("dragend",{event:c,p:u,m:this.m,handler:this}),SVG.off(window,"mousemove.drag"),SVG.off(window,"touchmove.drag"),SVG.off(window,"mouseup.drag"),SVG.off(window,"touchend.drag")},SVG.extend(SVG.Element,{draggable:function(c,u){typeof c!="function"&&typeof c!="object"||(u=c,c=!0);var d=this.remember("_draggable")||new Q(this);return(c=c===void 0||c)?d.init(u||{},c):(this.off("mousedown.drag"),this.off("touchstart.drag")),this}})}).call(void 0),function(){function Q(c){this.el=c,c.remember("_selectHandler",this),this.pointSelection={isSelected:!1},this.rectSelection={isSelected:!1},this.pointsList={lt:[0,0],rt:["width",0],rb:["width","height"],lb:[0,"height"],t:["width",0],r:["width","height"],b:["width","height"],l:[0,"height"]},this.pointCoord=function(u,d,v){var m=typeof u!="string"?u:d[u];return v?m/2:m},this.pointCoords=function(u,d){var v=this.pointsList[u];return{x:this.pointCoord(v[0],d,u==="t"||u==="b"),y:this.pointCoord(v[1],d,u==="r"||u==="l")}}}Q.prototype.init=function(c,u){var d=this.el.bbox();this.options={};var v=this.el.selectize.defaults.points;for(var m in this.el.selectize.defaults)this.options[m]=this.el.selectize.defaults[m],u[m]!==void 0&&(this.options[m]=u[m]);var x=["points","pointsExclude"];for(var m in x){var w=this.options[x[m]];typeof w=="string"?w=w.length>0?w.split(/\s*,\s*/i):[]:typeof w=="boolean"&&x[m]==="points"&&(w=w?v:[]),this.options[x[m]]=w}this.options.points=[v,this.options.points].reduce(function(k,L){return k.filter(function(D){return L.indexOf(D)>-1})}),this.options.points=[this.options.points,this.options.pointsExclude].reduce(function(k,L){return k.filter(function(D){return L.indexOf(D)<0})}),this.parent=this.el.parent(),this.nested=this.nested||this.parent.group(),this.nested.matrix(new SVG.Matrix(this.el).translate(d.x,d.y)),this.options.deepSelect&&["line","polyline","polygon"].indexOf(this.el.type)!==-1?this.selectPoints(c):this.selectRect(c),this.observe(),this.cleanup()},Q.prototype.selectPoints=function(c){return this.pointSelection.isSelected=c,this.pointSelection.set||(this.pointSelection.set=this.parent.set(),this.drawPoints()),this},Q.prototype.getPointArray=function(){var c=this.el.bbox();return this.el.array().valueOf().map(function(u){return[u[0]-c.x,u[1]-c.y]})},Q.prototype.drawPoints=function(){for(var c=this,u=this.getPointArray(),d=0,v=u.length;d0&&this.parameters.box.height-w[1]>0){if(this.parameters.type==="text")return this.el.move(this.parameters.box.x+w[0],this.parameters.box.y),void this.el.attr("font-size",this.parameters.fontSize-w[0]);w=this.checkAspectRatio(w),this.el.move(this.parameters.box.x+w[0],this.parameters.box.y+w[1]).size(this.parameters.box.width-w[0],this.parameters.box.height-w[1])}};break;case"rt":this.calc=function(m,x){var w=this.snapToGrid(m,x,2);if(this.parameters.box.width+w[0]>0&&this.parameters.box.height-w[1]>0){if(this.parameters.type==="text")return this.el.move(this.parameters.box.x-w[0],this.parameters.box.y),void this.el.attr("font-size",this.parameters.fontSize+w[0]);w=this.checkAspectRatio(w,!0),this.el.move(this.parameters.box.x,this.parameters.box.y+w[1]).size(this.parameters.box.width+w[0],this.parameters.box.height-w[1])}};break;case"rb":this.calc=function(m,x){var w=this.snapToGrid(m,x,0);if(this.parameters.box.width+w[0]>0&&this.parameters.box.height+w[1]>0){if(this.parameters.type==="text")return this.el.move(this.parameters.box.x-w[0],this.parameters.box.y),void this.el.attr("font-size",this.parameters.fontSize+w[0]);w=this.checkAspectRatio(w),this.el.move(this.parameters.box.x,this.parameters.box.y).size(this.parameters.box.width+w[0],this.parameters.box.height+w[1])}};break;case"lb":this.calc=function(m,x){var w=this.snapToGrid(m,x,1);if(this.parameters.box.width-w[0]>0&&this.parameters.box.height+w[1]>0){if(this.parameters.type==="text")return this.el.move(this.parameters.box.x+w[0],this.parameters.box.y),void this.el.attr("font-size",this.parameters.fontSize-w[0]);w=this.checkAspectRatio(w,!0),this.el.move(this.parameters.box.x+w[0],this.parameters.box.y).size(this.parameters.box.width-w[0],this.parameters.box.height+w[1])}};break;case"t":this.calc=function(m,x){var w=this.snapToGrid(m,x,2);if(this.parameters.box.height-w[1]>0){if(this.parameters.type==="text")return;this.el.move(this.parameters.box.x,this.parameters.box.y+w[1]).height(this.parameters.box.height-w[1])}};break;case"r":this.calc=function(m,x){var w=this.snapToGrid(m,x,0);if(this.parameters.box.width+w[0]>0){if(this.parameters.type==="text")return;this.el.move(this.parameters.box.x,this.parameters.box.y).width(this.parameters.box.width+w[0])}};break;case"b":this.calc=function(m,x){var w=this.snapToGrid(m,x,0);if(this.parameters.box.height+w[1]>0){if(this.parameters.type==="text")return;this.el.move(this.parameters.box.x,this.parameters.box.y).height(this.parameters.box.height+w[1])}};break;case"l":this.calc=function(m,x){var w=this.snapToGrid(m,x,1);if(this.parameters.box.width-w[0]>0){if(this.parameters.type==="text")return;this.el.move(this.parameters.box.x+w[0],this.parameters.box.y).width(this.parameters.box.width-w[0])}};break;case"rot":this.calc=function(m,x){var w=m+this.parameters.p.x,k=x+this.parameters.p.y,L=Math.atan2(this.parameters.p.y-this.parameters.box.y-this.parameters.box.height/2,this.parameters.p.x-this.parameters.box.x-this.parameters.box.width/2),D=Math.atan2(k-this.parameters.box.y-this.parameters.box.height/2,w-this.parameters.box.x-this.parameters.box.width/2),P=this.parameters.rotation+180*(D-L)/Math.PI+this.options.snapToAngle/2;this.el.center(this.parameters.box.cx,this.parameters.box.cy).rotate(P-P%this.options.snapToAngle,this.parameters.box.cx,this.parameters.box.cy)};break;case"point":this.calc=function(m,x){var w=this.snapToGrid(m,x,this.parameters.pointCoords[0],this.parameters.pointCoords[1]),k=this.el.array().valueOf();k[this.parameters.i][0]=this.parameters.pointCoords[0]+w[0],k[this.parameters.i][1]=this.parameters.pointCoords[1]+w[1],this.el.plot(k)}}this.el.fire("resizestart",{dx:this.parameters.x,dy:this.parameters.y,event:c}),SVG.on(window,"touchmove.resize",function(m){u.update(m||window.event)}),SVG.on(window,"touchend.resize",function(){u.done()}),SVG.on(window,"mousemove.resize",function(m){u.update(m||window.event)}),SVG.on(window,"mouseup.resize",function(){u.done()})},Q.prototype.update=function(c){if(c){var u=this._extractPosition(c),d=this.transformPoint(u.x,u.y),v=d.x-this.parameters.p.x,m=d.y-this.parameters.p.y;this.lastUpdateCall=[v,m],this.calc(v,m),this.el.fire("resizing",{dx:v,dy:m,event:c})}else this.lastUpdateCall&&this.calc(this.lastUpdateCall[0],this.lastUpdateCall[1])},Q.prototype.done=function(){this.lastUpdateCall=null,SVG.off(window,"mousemove.resize"),SVG.off(window,"mouseup.resize"),SVG.off(window,"touchmove.resize"),SVG.off(window,"touchend.resize"),this.el.fire("resizedone")},Q.prototype.snapToGrid=function(c,u,d,v){var m;return v!==void 0?m=[(d+c)%this.options.snapToGrid,(v+u)%this.options.snapToGrid]:(d=d??3,m=[(this.parameters.box.x+c+(1&d?0:this.parameters.box.width))%this.options.snapToGrid,(this.parameters.box.y+u+(2&d?0:this.parameters.box.height))%this.options.snapToGrid]),c<0&&(m[0]-=this.options.snapToGrid),u<0&&(m[1]-=this.options.snapToGrid),c-=Math.abs(m[0])w.maxX&&(c=w.maxX-m),w.minY!==void 0&&x+uw.maxY&&(u=w.maxY-x),[c,u]},Q.prototype.checkAspectRatio=function(c,u){if(!this.options.saveAspectRatio)return c;var d=c.slice(),v=this.parameters.box.width/this.parameters.box.height,m=this.parameters.box.width+c[0],x=this.parameters.box.height-c[1],w=m/x;return wv&&(d[0]=this.parameters.box.width-x*v,u&&(d[0]=-d[0])),d},SVG.extend(SVG.Element,{resize:function(c){return(this.remember("_resizeHandler")||new Q(this)).init(c||{}),this}}),SVG.Element.prototype.resize.defaults={snapToAngle:.1,snapToGrid:1,constraint:{},saveAspectRatio:!1}}).call(this)}(),window.Apex===void 0&&(window.Apex={});var A1=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w}return l(Q,[{key:"initModules",value:function(){this.ctx.publicMethods=["updateOptions","updateSeries","appendData","appendSeries","isSeriesHidden","toggleSeries","showSeries","hideSeries","setLocale","resetSeries","zoomX","toggleDataPointSelection","dataURI","exportToCSV","addXaxisAnnotation","addYaxisAnnotation","addPointAnnotation","clearAnnotations","removeAnnotation","paper","destroy"],this.ctx.eventList=["click","mousedown","mousemove","mouseleave","touchstart","touchmove","touchleave","mouseup","touchend"],this.ctx.animations=new R(this.ctx),this.ctx.axes=new qt(this.ctx),this.ctx.core=new r1(this.ctx.el,this.ctx),this.ctx.config=new At({}),this.ctx.data=new It(this.ctx),this.ctx.grid=new de(this.ctx),this.ctx.graphics=new $(this.ctx),this.ctx.coreUtils=new G(this.ctx),this.ctx.crosshairs=new ge(this.ctx),this.ctx.events=new ce(this.ctx),this.ctx.exports=new le(this.ctx),this.ctx.localization=new Se(this.ctx),this.ctx.options=new lt,this.ctx.responsive=new oe(this.ctx),this.ctx.series=new Kt(this.ctx),this.ctx.theme=new ue(this.ctx),this.ctx.formatters=new at(this.ctx),this.ctx.titleSubtitle=new xe(this.ctx),this.ctx.legend=new st(this.ctx),this.ctx.toolbar=new Mt(this.ctx),this.ctx.tooltip=new _e(this.ctx),this.ctx.dimensions=new Pe(this.ctx),this.ctx.updateHelpers=new s1(this.ctx),this.ctx.zoomPanSelection=new wt(this.ctx),this.ctx.w.globals.tooltip=new _e(this.ctx)}}]),Q}(),Or=function(){function Q(c){a(this,Q),this.ctx=c,this.w=c.w}return l(Q,[{key:"clear",value:function(c){var u=c.isUpdating;this.ctx.zoomPanSelection&&this.ctx.zoomPanSelection.destroy(),this.ctx.toolbar&&this.ctx.toolbar.destroy(),this.ctx.animations=null,this.ctx.axes=null,this.ctx.annotations=null,this.ctx.core=null,this.ctx.data=null,this.ctx.grid=null,this.ctx.series=null,this.ctx.responsive=null,this.ctx.theme=null,this.ctx.formatters=null,this.ctx.titleSubtitle=null,this.ctx.legend=null,this.ctx.dimensions=null,this.ctx.options=null,this.ctx.crosshairs=null,this.ctx.zoomPanSelection=null,this.ctx.updateHelpers=null,this.ctx.toolbar=null,this.ctx.localization=null,this.ctx.w.globals.tooltip=null,this.clearDomElements({isUpdating:u})}},{key:"killSVG",value:function(c){c.each(function(u,d){this.removeClass("*"),this.off(),this.stop()},!0),c.ungroup(),c.clear()}},{key:"clearDomElements",value:function(c){var u=this,d=c.isUpdating,v=this.w.globals.dom.Paper.node;v.parentNode&&v.parentNode.parentNode&&!d&&(v.parentNode.parentNode.style.minHeight="unset");var m=this.w.globals.dom.baseEl;m&&this.ctx.eventList.forEach(function(w){m.removeEventListener(w,u.ctx.events.documentEvent)});var x=this.w.globals.dom;if(this.ctx.el!==null)for(;this.ctx.el.firstChild;)this.ctx.el.removeChild(this.ctx.el.firstChild);this.killSVG(x.Paper),x.Paper.remove(),x.elWrap=null,x.elGraphical=null,x.elLegendWrap=null,x.elLegendForeign=null,x.baseEl=null,x.elGridRect=null,x.elGridRectMask=null,x.elGridRectMarkerMask=null,x.elForecastMask=null,x.elNonForecastMask=null,x.elDefs=null}}]),Q}(),bn=new WeakMap,v6=function(){function Q(c,u){a(this,Q),this.opts=u,this.ctx=this,this.w=new kt(u).init(),this.el=c,this.w.globals.cuid=E.randomId(),this.w.globals.chartID=this.w.config.chart.id?E.escapeString(this.w.config.chart.id):this.w.globals.cuid,new A1(this).initModules(),this.create=E.bind(this.create,this),this.windowResizeHandler=this._windowResizeHandler.bind(this),this.parentResizeHandler=this._parentResizeCallback.bind(this)}return l(Q,[{key:"render",value:function(){var c=this;return new Promise(function(u,d){if(c.el!==null){Apex._chartInstances===void 0&&(Apex._chartInstances=[]),c.w.config.chart.id&&Apex._chartInstances.push({id:c.w.globals.chartID,group:c.w.config.chart.group,chart:c}),c.setLocale(c.w.config.chart.defaultLocale);var v=c.w.config.chart.events.beforeMount;typeof v=="function"&&v(c,c.w),c.events.fireEvent("beforeMount",[c,c.w]),window.addEventListener("resize",c.windowResizeHandler),function(V,N){var j=!1;if(V.nodeType!==Node.DOCUMENT_FRAGMENT_NODE){var U=V.getBoundingClientRect();V.style.display!=="none"&&U.width!==0||(j=!0)}var q=new ResizeObserver(function(J){j&&N.call(V,J),j=!0});V.nodeType===Node.DOCUMENT_FRAGMENT_NODE?Array.from(V.children).forEach(function(J){return q.observe(J)}):q.observe(V),bn.set(N,q)}(c.el.parentNode,c.parentResizeHandler);var m=c.el.getRootNode&&c.el.getRootNode(),x=E.is("ShadowRoot",m),w=c.el.ownerDocument,k=x?m.getElementById("apexcharts-css"):w.getElementById("apexcharts-css");if(!k){var L;(k=document.createElement("style")).id="apexcharts-css",k.textContent=`@keyframes opaque { 0% { opacity: 0 } @@ -1818,229 +1818,229 @@ rect.legend-mouseover-inactive, .apexcharts-rangebar-goals-markers { pointer-events: none -}`;var D=((L=c.opts.chart)===null||L===void 0?void 0:L.nonce)||c.w.config.chart.nonce;D&&k.setAttribute("nonce",D),x?m.prepend(k):w.head.appendChild(k)}var P=c.create(c.w.config.series,{});if(!P)return u(c);c.mount(P).then(function(){typeof c.w.config.chart.events.mounted=="function"&&c.w.config.chart.events.mounted(c,c.w),c.events.fireEvent("mounted",[c,c.w]),u(P)}).catch(function(V){d(V)})}else d(new Error("Element not found"))})}},{key:"create",value:function(c,u){var d=this.w;new I1(this).initModules();var v=this.w.globals;if(v.noData=!1,v.animationEnded=!1,this.responsive.checkResponsiveConfig(u),d.config.xaxis.convertedCatToNumeric&&new kt(d.config).convertCatToNumericXaxis(d.config,this.ctx),this.el===null||(this.core.setupElements(),d.config.chart.type==="treemap"&&(d.config.grid.show=!1,d.config.yaxis[0].show=!1),v.svgWidth===0))return v.animationEnded=!0,null;var m=G.checkComboSeries(c,d.config.chart.type);v.comboCharts=m.comboCharts,v.comboBarCount=m.comboBarCount;var x=c.every(function(D){return D.data&&D.data.length===0});(c.length===0||x&&v.collapsedSeries.length<1)&&this.series.handleNoData(),this.events.setupEventHandlers(),this.data.parseData(c),this.theme.init(),new Ft(this).setGlobalMarkerSize(),this.formatters.setLabelFormatters(),this.titleSubtitle.draw(),v.noData&&v.collapsedSeries.length!==v.series.length&&!d.config.legend.showForSingleSeries||this.legend.init(),this.series.hasAllSeriesEqualX(),v.axisCharts&&(this.core.coreCalculations(),d.config.xaxis.type!=="category"&&this.formatters.setLabelFormatters(),this.ctx.toolbar.minX=d.globals.minX,this.ctx.toolbar.maxX=d.globals.maxX),this.formatters.heatmapLabelFormatters(),new G(this).getLargestMarkerSize(),this.dimensions.plotCoords();var w=this.core.xySettings();this.grid.createGridMask();var k=this.core.plotChartType(c,w),L=new Ut(this);return L.bringForward(),d.config.dataLabels.background.enabled&&L.dataLabelsBackground(),this.core.shiftGraphPosition(),{elGraph:k,xyRatios:w,dimensions:{plot:{left:d.globals.translateX,top:d.globals.translateY,width:d.globals.gridWidth,height:d.globals.gridHeight}}}}},{key:"mount",value:function(){var c=this,u=arguments.length>0&&arguments[0]!==void 0?arguments[0]:null,d=this,v=d.w;return new Promise(function(m,x){if(d.el===null)return x(new Error("Not enough data to display or target element not found"));(u===null||v.globals.allSeriesCollapsed)&&d.series.handleNoData(),d.grid=new ue(d);var w,k,L=d.grid.drawGrid();if(d.annotations=new yt(d),d.annotations.drawImageAnnos(),d.annotations.drawTextAnnos(),v.config.grid.position==="back"&&(L&&v.globals.dom.elGraphical.add(L.el),L!=null&&(w=L.elGridBorders)!==null&&w!==void 0&&w.node&&v.globals.dom.elGraphical.add(L.elGridBorders)),Array.isArray(u.elGraph))for(var D=0;D0&&v.globals.memory.methodsToExec.forEach(function(j){j.method(j.params,!1,j.context)}),v.globals.axisCharts||v.globals.noData||d.core.resizeNonAxisCharts(),m(d)})}},{key:"destroy",value:function(){var c,u;window.removeEventListener("resize",this.windowResizeHandler),this.el.parentNode,c=this.parentResizeHandler,(u=Cn.get(c))&&(u.disconnect(),Cn.delete(c));var d=this.w.config.chart.id;d&&Apex._chartInstances.forEach(function(v,m){v.id===E.escapeString(d)&&Apex._chartInstances.splice(m,1)}),new Nr(this.ctx).clear({isUpdating:!1})}},{key:"updateOptions",value:function(c){var u=this,d=arguments.length>1&&arguments[1]!==void 0&&arguments[1],v=!(arguments.length>2&&arguments[2]!==void 0)||arguments[2],m=!(arguments.length>3&&arguments[3]!==void 0)||arguments[3],x=!(arguments.length>4&&arguments[4]!==void 0)||arguments[4],w=this.w;return w.globals.selection=void 0,c.series&&(this.series.resetSeries(!1,!0,!1),c.series.length&&c.series[0].data&&(c.series=c.series.map(function(k,L){return u.updateHelpers._extendSeries(k,L)})),this.updateHelpers.revertDefaultAxisMinMax()),c.xaxis&&(c=this.updateHelpers.forceXAxisUpdate(c)),c.yaxis&&(c=this.updateHelpers.forceYAxisUpdate(c)),w.globals.collapsedSeriesIndices.length>0&&this.series.clearPreviousPaths(),c.theme&&(c=this.theme.updateThemeOptions(c)),this.updateHelpers._updateOptions(c,d,v,m,x)}},{key:"updateSeries",value:function(){var c=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],u=!(arguments.length>1&&arguments[1]!==void 0)||arguments[1],d=!(arguments.length>2&&arguments[2]!==void 0)||arguments[2];return this.series.resetSeries(!1),this.updateHelpers.revertDefaultAxisMinMax(),this.updateHelpers._updateSeries(c,u,d)}},{key:"appendSeries",value:function(c){var u=!(arguments.length>1&&arguments[1]!==void 0)||arguments[1],d=!(arguments.length>2&&arguments[2]!==void 0)||arguments[2],v=this.w.config.series.slice();return v.push(c),this.series.resetSeries(!1),this.updateHelpers.revertDefaultAxisMinMax(),this.updateHelpers._updateSeries(v,u,d)}},{key:"appendData",value:function(c){var u=!(arguments.length>1&&arguments[1]!==void 0)||arguments[1],d=this;d.w.globals.dataChanged=!0,d.series.getPreviousPaths();for(var v=d.w.config.series.slice(),m=0;m0&&arguments[0]!==void 0)||arguments[0],u=!(arguments.length>1&&arguments[1]!==void 0)||arguments[1];this.series.resetSeries(c,u)}},{key:"addEventListener",value:function(c,u){this.events.addEventListener(c,u)}},{key:"removeEventListener",value:function(c,u){this.events.removeEventListener(c,u)}},{key:"addXaxisAnnotation",value:function(c){var u=!(arguments.length>1&&arguments[1]!==void 0)||arguments[1],d=arguments.length>2&&arguments[2]!==void 0?arguments[2]:void 0,v=this;d&&(v=d),v.annotations.addXaxisAnnotationExternal(c,u,v)}},{key:"addYaxisAnnotation",value:function(c){var u=!(arguments.length>1&&arguments[1]!==void 0)||arguments[1],d=arguments.length>2&&arguments[2]!==void 0?arguments[2]:void 0,v=this;d&&(v=d),v.annotations.addYaxisAnnotationExternal(c,u,v)}},{key:"addPointAnnotation",value:function(c){var u=!(arguments.length>1&&arguments[1]!==void 0)||arguments[1],d=arguments.length>2&&arguments[2]!==void 0?arguments[2]:void 0,v=this;d&&(v=d),v.annotations.addPointAnnotationExternal(c,u,v)}},{key:"clearAnnotations",value:function(){var c=arguments.length>0&&arguments[0]!==void 0?arguments[0]:void 0,u=this;c&&(u=c),u.annotations.clearAnnotations(u)}},{key:"removeAnnotation",value:function(c){var u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:void 0,d=this;u&&(d=u),d.annotations.removeAnnotation(d,c)}},{key:"getChartArea",value:function(){return this.w.globals.dom.baseEl.querySelector(".apexcharts-inner")}},{key:"getSeriesTotalXRange",value:function(c,u){return this.coreUtils.getSeriesTotalsXRange(c,u)}},{key:"getHighestValueInSeries",value:function(){var c=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0;return new we(this.ctx).getMinYMaxY(c).highestY}},{key:"getLowestValueInSeries",value:function(){var c=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0;return new we(this.ctx).getMinYMaxY(c).lowestY}},{key:"getSeriesTotal",value:function(){return this.w.globals.seriesTotals}},{key:"toggleDataPointSelection",value:function(c,u){return this.updateHelpers.toggleDataPointSelection(c,u)}},{key:"zoomX",value:function(c,u){this.ctx.toolbar.zoomUpdateOptions(c,u)}},{key:"setLocale",value:function(c){this.localization.setCurrentLocaleValues(c)}},{key:"dataURI",value:function(c){return new ae(this.ctx).dataURI(c)}},{key:"exportToCSV",value:function(){var c=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};return new ae(this.ctx).exportToCSV(c)}},{key:"paper",value:function(){return this.w.globals.dom.Paper}},{key:"_parentResizeCallback",value:function(){this.w.globals.animationEnded&&this.w.config.chart.redrawOnParentResize&&this._windowResize()}},{key:"_windowResize",value:function(){var c=this;clearTimeout(this.w.globals.resizeTimer),this.w.globals.resizeTimer=window.setTimeout(function(){c.w.globals.resized=!0,c.w.globals.dataChanged=!1,c.ctx.update()},150)}},{key:"_windowResizeHandler",value:function(){var c=this.w.config.chart.redrawOnWindowResize;typeof c=="function"&&(c=c()),c&&this._windowResize()}}],[{key:"getChartByID",value:function(c){var u=E.escapeString(c);if(Apex._chartInstances){var d=Apex._chartInstances.filter(function(v){return v.id===u})[0];return d&&d.chart}}},{key:"initOnLoad",value:function(){for(var c=document.querySelectorAll("[data-apexcharts]"),u=0;u2?m-2:0),w=2;w{const{Options:r,Posn:n,Series:i,Size:o,ChartType:a,Event:s,CSS:l}=t==null?void 0:t.Properties,[h,p]=_.useState(null),{socket:f,handleData:g}=w1(),b=j1(l),z=Yr(t==null?void 0:t.Properties),M=_.useRef(null);_.useEffect(()=>{M.current&&setTimeout(()=>{const E=M.current.chart.paper().svg();E&&(p(E),localStorage.setItem(t.ID,JSON.stringify(E)),g({ID:t==null?void 0:t.ID,Properties:{SVG:E}},"WS"))},500)},[M.current]);const I=(H,E,R,W)=>{var Z,K,et;const $={dataPointIndex:W==null?void 0:W.dataPointIndex,seriesIndex:W==null?void 0:W.seriesIndex,series:(Z=W==null?void 0:W.config)==null?void 0:Z.series,xaxis:(K=W==null?void 0:W.config)==null?void 0:K.xaxis,yaxis:(et=W==null?void 0:W.config)==null?void 0:et.yaxis},G=JSON.stringify({Event:{ID:t==null?void 0:t.ID,EventName:H,Info:[JSON.stringify($)]}});console.log(G),f.send(G)};console.log("chart",h);const F={...r,chart:{events:{...(s==null?void 0:s.some(H=>H[0]==="click"))&&{click:(H,E,R)=>I("click",H,E,R)},...(s==null?void 0:s.some(H=>H[0]==="legendclick"))&&{legendClick:(H,E,R)=>I("legendclick",H,E,R)}}}};return vt.jsx("div",{style:{position:"absolute",top:n&&n[0],left:n&&n[1],...z,...b},children:vt.jsx(FO,{ref:M,options:F,width:o&&o[1],height:o&&o[0],type:a,series:i})})};function xFt(t){return C({tag:"svg",attr:{viewBox:"0 0 256 256",fill:"currentColor"},child:[{tag:"path",attr:{d:"M236.8,188.09,149.35,36.22h0a24.76,24.76,0,0,0-42.7,0L19.2,188.09a23.51,23.51,0,0,0,0,23.72A24.35,24.35,0,0,0,40.55,224h174.9a24.35,24.35,0,0,0,21.33-12.19A23.51,23.51,0,0,0,236.8,188.09ZM120,104a8,8,0,0,1,16,0v40a8,8,0,0,1-16,0Zm8,88a12,12,0,1,1,12-12A12,12,0,0,1,128,192Z"}}]})(t)}function bFt(t){return C({tag:"svg",attr:{viewBox:"0 0 16 16",fill:"currentColor"},child:[{tag:"path",attr:{fillRule:"evenodd",clipRule:"evenodd",d:"M8.6 1c1.6.1 3.1.9 4.2 2 1.3 1.4 2 3.1 2 5.1 0 1.6-.6 3.1-1.6 4.4-1 1.2-2.4 2.1-4 2.4-1.6.3-3.2.1-4.6-.7-1.4-.8-2.5-2-3.1-3.5C.9 9.2.8 7.5 1.3 6c.5-1.6 1.4-2.9 2.8-3.8C5.4 1.3 7 .9 8.6 1zm.5 12.9c1.3-.3 2.5-1 3.4-2.1.8-1.1 1.3-2.4 1.2-3.8 0-1.6-.6-3.2-1.7-4.3-1-1-2.2-1.6-3.6-1.7-1.3-.1-2.7.2-3.8 1-1.1.8-1.9 1.9-2.3 3.3-.4 1.3-.4 2.7.2 4 .6 1.3 1.5 2.3 2.7 3 1.2.7 2.6.9 3.9.6zM7.9 7.5L10.3 5l.7.7-2.4 2.5 2.4 2.5-.7.7-2.4-2.5-2.4 2.5-.7-.7 2.4-2.5-2.4-2.5.7-.7 2.4 2.5z"}}]})(t)}function wFt(t){return C({tag:"svg",attr:{viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true"},child:[{tag:"path",attr:{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-8-3a1 1 0 00-.867.5 1 1 0 11-1.731-1A3 3 0 0113 8a3.001 3.001 0 01-2 2.83V11a1 1 0 11-2 0v-1a1 1 0 011-1 1 1 0 100-2zm0 8a1 1 0 100-2 1 1 0 000 2z",clipRule:"evenodd"}}]})(t)}const BO=({data:t,onClose:r,isDesktop:n,options:i})=>{const{Caption:o,Text:a,Style:s,Btns:l}=t==null?void 0:t.Properties,h=()=>{switch(s){case"Info":return vt.jsx(Oxt,{className:"icon info-icon"});case"Query":return vt.jsx(wFt,{className:"icon question-icon"});case"Warn":return vt.jsx(xFt,{className:"icon warning-icon"});case"Error":return vt.jsx(bFt,{className:"icon error-icon"});default:return""}};let p=i.Desktop!==1;return vt.jsx("div",{className:"msgbox-overlay",children:vt.jsxs("div",{className:`msgbox-container ${p?"with-border":""}`,children:[p&&vt.jsx("div",{className:"msgbox-header with-border",children:o}),vt.jsxs("div",{className:"msgbox-body",children:[s&&s!=="Msg"&&vt.jsx(h,{}),vt.jsx("span",{children:a})]}),vt.jsx("div",{className:"msgbox-footer with-border",children:Array.isArray(l)?l.map((f,g)=>vt.jsx("button",{className:"rounded-button ",onClick:()=>r(`MsgBtn${g+1}`,t==null?void 0:t.ID),children:f==="OK"?"OK":f.charAt(0).toUpperCase()+f.slice(1).toLowerCase()},g)):vt.jsx("button",{className:"rounded-button",onClick:()=>r("MsgBtn1",t==null?void 0:t.ID),children:l})})]})})},CFt=({data:t})=>{var n,i,o;const r=Yr(t.Properties);return vt.jsx("div",{children:vt.jsx("a",{id:t.ID,href:t.Properties.Href,target:((n=t.Properties)==null?void 0:n.Target)||"_blank",download:((i=t.Properties)==null?void 0:i.Download)===1,style:{...r},children:((o=t.Properties)==null?void 0:o.Label)!==void 0?t.Properties.Label:t.Properties.Href})})},SFt=(t,r)=>{const i=(t.Properties||[]).filter(o=>!r.Defaults.hasOwnProperty(o));return i.length==0?null:{NotSupported:i}},zFt=(t,r)=>{const n={};return t.Properties.forEach(i=>{r.hasOwnProperty(i)&&(n[i]=r[i])}),n},Ev=(t,r,n)=>({WG:{ID:t.ID,WGID:t.WGID,Properties:zFt(t,{...r.Defaults,...n}),...SFt(t,r)}}),n0=({data:t})=>vt.jsx("div",{children:vt.jsx("input",{id:t.ID,type:"file"})});n0.Defaults={LastModified:-1,FileName:"",FileSize:-1,FileType:"",FileBytes:""};n0.WG=(t,r)=>{var a;let n=(a=document.getElementById(r.ID))==null?void 0:a.files[0];if(!n)return t(Ev(r,n0,{}));const i={LastModified:n.lastModified,FileName:n.name,FileSize:n.size,FileType:n.type};r.Properties.includes("FileBytes")||(n=n.slice(0,1));const o=new FileReader;o.onload=s=>{i.FileBytes=btoa(s.target.result),t(Ev(r,n0,i))},o.onerror=s=>{t(Ev(r,n0,{}))},o.readAsBinaryString(n)};const MFt=({data:t})=>{const{Options:r,Posn:n,Series:i,Size:o,ChartType:a,Event:s}=t==null?void 0:t.Properties;w1();const l=["#ff6358","#ffd246","#78d237","#28b4c8","#2d73f5","#aa46be"];return vt.jsx("div",{style:{position:"absolute",top:n&&n[0],left:n&&n[1]},children:vt.jsx(rVt,{style:{width:o&&o[1],height:o&&o[0]},seriesColors:l,pannable:!0,zoomable:!0,children:vt.jsx(DO,{children:i.map((h,p)=>vt.jsx(vC,{data:h.data,type:"column",name:"series-"+p},p))})})})};var rn=function(t){return t!=null},x9=function(t){return t==null},NO=function(t){return Array.isArray(t)},fE=function(t){return typeof t=="function"},yC=function(t){return typeof t=="string"},kFt=function(t){return x9(t)||t.trim().length===0},_Ft=function(t){return!kFt(t)},AFt=function(t){return!isNaN(t-parseFloat(t))},b9=function(t){return t&&t.getTime},w8=function(t){return rn(t.filters)},$O=function(t,r,n){return function(i){return t(i)?r(i):n(i)}},la=function(){for(var t=[],r=0;r":"gt",">=":"gte",equal:"eq",equals:"eq",equalto:"eq",ge:"gte",greater:"gt",greaterthan:"gt",greaterthanequal:"gte",isempty:"isempty",isequalto:"eq",isgreaterthan:"gt",isgreaterthanorequalto:"gte",islessthan:"lt",islessthanorequalto:"lte",isnotempty:"isnotempty",isnotequalto:"neq",isnull:"isnull",le:"lte",less:"lt",lessthan:"lt",lessthanequal:"lte",ne:"neq",notequal:"neq",notequals:"neq",notequalto:"neq",notsubstringof:"doesnotcontain"}[t.toLowerCase()]||t},WO=function(t){t.filters&&(t.filters=t.filters.map(function(r){var n=Object.assign({},r);return!w8(r)&&yC(r.operator)&&(n.operator=IFt(r.operator)),w8(r)&&WO(n),n}))},HFt=function(t){return w8(t)?Object.assign({},t):{filters:NO(t)?t:[t],logic:"and"}},DFt=function(t){return rn(t)&&(t=HFt(t),WO(t)),t},dc={},PFt=/\[(?:(\d+)|['"](.*?)['"])\]|((?:(?!\[.*?\]|\.).)+)/g;dc.undefined=function(t){return t};var X0=function(t,r){var n=t+r;if(dc[n])return dc[n];var i=[];return t.replace(PFt,function(o,a,s,l){i.push(rn(a)?a:s||l)}),dc[n]=function(o){for(var a=o,s=0;s0},FFt=function(t){return function(r){return VFt(t(r))}},RFt=function(t,r){return $O(t,r,TFt)},OFt=function(t){var r=t.skip,n=t.take;return Math.floor((r||0)/n)+1},xC=function(t,r){return function(n){return t(n).map(r).join("~")}},BFt=function(t){return function(r){return r.slice(0,r.indexOf(t))}},NFt=function(t){return la.apply(void 0,t.map(function(r){var n=r[0],i=r[1];return function(o){return o.replace(new RegExp(n,"g"),i)}}))},$Ft=NFt([['"',""],[":","-"]]),WFt=BFt("."),jO=function(t){var r=t.field,n=t.dir,i=n===void 0?"asc":n;return r+"-"+i},jFt=function(t){var r=t.field,n=t.aggregate;return r+"-"+n},GFt=X0("take"),UFt=X0("aggregates");X0("skip");var YFt=X0("group"),bC=X0("sort",!0),XFt=xC(bC,jO),KFt=xC(YFt,jO),qFt=xC(UFt,jFt),ZFt=function(t){return"datetime'"+t+"'"},JFt=la(ZFt,WFt,$Ft,JSON.stringify,LFt),QFt=function(t){var r=t.field,n=t.value,i=t.ignoreCase,o=t.operator;return{value:JFt(n),field:r,ignoreCase:i,operator:o}},tRt=function(t){return Object.assign({},t,{sort:(bC(t)||[]).filter(function(r){var n=r.dir;return _Ft(n)})})};la(f5("page"),OFt);la(f5("pageSize"),GFt);la(f5("group"),KFt);var eRt=la(f5("sort"),XFt);la(f5("aggregate"),qFt);la(RFt(FFt(bC),eRt),tRt);var vE=function(t){var r=t.field,n=t.operator,i=t.value;return r+"~"+n+"~"+i};$O(EFt,la(vE,QFt),vE);var GO=function(t,r,n){return r[t]=n,r},UO=function(t){return function(r){return Object.keys(r).reduce(t.bind(null,r),{})}},rRt=UO(function(t,r,n){return GO(n.toLowerCase(),r,t[n])}),iRt=UO(function(t,r,n){return GO(n,r,rRt(t[n]))}),gE=function(t,r){return rn(t)?t:r},nRt=function(t){return{aggregates:t.Aggregates||t.aggregates,field:t.Member||t.member||t.field,hasSubgroups:t.HasSubgroups||t.hasSubgroups||!1,items:t.Items||t.items,value:gE(t.Key,gE(t.key,t.value))}},oRt=la(function(t){var r=t.field,n=t.hasSubgroups,i=t.value,o=t.aggregates,a=t.items;return{aggregates:iRt(o),field:r,items:n?a.map(oRt):a,value:i}},nRt),YO=function(t,r){return x9(t)?t===r?0:-1:x9(r)?1:t.localeCompare?t.localeCompare(r):t>r?1:t=0},doesnotcontain:function(t,r){return(t||"").indexOf(r)===-1},doesnotendwith:function(t,r){return(t||"").indexOf(r,(t||"").length-(r||"").length)<0},doesnotstartwith:function(t,r){return(t||"").lastIndexOf(r,0)===-1},endswith:function(t,r){return(t||"").indexOf(r,(t||"").length-(r||"").length)>=0},eq:function(t,r){return t===r},gt:function(t,r){return t>r},gte:function(t,r){return t>=r},isempty:function(t){return t===""},isnotempty:function(t){return t!==""},isnotnull:function(t){return rn(t)},isnull:function(t){return x9(t)},lt:function(t,r){return t0&&arguments[0]!==void 0?arguments[0]:null,d=this,v=d.w;return new Promise(function(m,x){if(d.el===null)return x(new Error("Not enough data to display or target element not found"));(u===null||v.globals.allSeriesCollapsed)&&d.series.handleNoData(),d.grid=new de(d);var w,k,L=d.grid.drawGrid();if(d.annotations=new yt(d),d.annotations.drawImageAnnos(),d.annotations.drawTextAnnos(),v.config.grid.position==="back"&&(L&&v.globals.dom.elGraphical.add(L.el),L!=null&&(w=L.elGridBorders)!==null&&w!==void 0&&w.node&&v.globals.dom.elGraphical.add(L.elGridBorders)),Array.isArray(u.elGraph))for(var D=0;D0&&v.globals.memory.methodsToExec.forEach(function(j){j.method(j.params,!1,j.context)}),v.globals.axisCharts||v.globals.noData||d.core.resizeNonAxisCharts(),m(d)})}},{key:"destroy",value:function(){var c,u;window.removeEventListener("resize",this.windowResizeHandler),this.el.parentNode,c=this.parentResizeHandler,(u=bn.get(c))&&(u.disconnect(),bn.delete(c));var d=this.w.config.chart.id;d&&Apex._chartInstances.forEach(function(v,m){v.id===E.escapeString(d)&&Apex._chartInstances.splice(m,1)}),new Or(this.ctx).clear({isUpdating:!1})}},{key:"updateOptions",value:function(c){var u=this,d=arguments.length>1&&arguments[1]!==void 0&&arguments[1],v=!(arguments.length>2&&arguments[2]!==void 0)||arguments[2],m=!(arguments.length>3&&arguments[3]!==void 0)||arguments[3],x=!(arguments.length>4&&arguments[4]!==void 0)||arguments[4],w=this.w;return w.globals.selection=void 0,c.series&&(this.series.resetSeries(!1,!0,!1),c.series.length&&c.series[0].data&&(c.series=c.series.map(function(k,L){return u.updateHelpers._extendSeries(k,L)})),this.updateHelpers.revertDefaultAxisMinMax()),c.xaxis&&(c=this.updateHelpers.forceXAxisUpdate(c)),c.yaxis&&(c=this.updateHelpers.forceYAxisUpdate(c)),w.globals.collapsedSeriesIndices.length>0&&this.series.clearPreviousPaths(),c.theme&&(c=this.theme.updateThemeOptions(c)),this.updateHelpers._updateOptions(c,d,v,m,x)}},{key:"updateSeries",value:function(){var c=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],u=!(arguments.length>1&&arguments[1]!==void 0)||arguments[1],d=!(arguments.length>2&&arguments[2]!==void 0)||arguments[2];return this.series.resetSeries(!1),this.updateHelpers.revertDefaultAxisMinMax(),this.updateHelpers._updateSeries(c,u,d)}},{key:"appendSeries",value:function(c){var u=!(arguments.length>1&&arguments[1]!==void 0)||arguments[1],d=!(arguments.length>2&&arguments[2]!==void 0)||arguments[2],v=this.w.config.series.slice();return v.push(c),this.series.resetSeries(!1),this.updateHelpers.revertDefaultAxisMinMax(),this.updateHelpers._updateSeries(v,u,d)}},{key:"appendData",value:function(c){var u=!(arguments.length>1&&arguments[1]!==void 0)||arguments[1],d=this;d.w.globals.dataChanged=!0,d.series.getPreviousPaths();for(var v=d.w.config.series.slice(),m=0;m0&&arguments[0]!==void 0)||arguments[0],u=!(arguments.length>1&&arguments[1]!==void 0)||arguments[1];this.series.resetSeries(c,u)}},{key:"addEventListener",value:function(c,u){this.events.addEventListener(c,u)}},{key:"removeEventListener",value:function(c,u){this.events.removeEventListener(c,u)}},{key:"addXaxisAnnotation",value:function(c){var u=!(arguments.length>1&&arguments[1]!==void 0)||arguments[1],d=arguments.length>2&&arguments[2]!==void 0?arguments[2]:void 0,v=this;d&&(v=d),v.annotations.addXaxisAnnotationExternal(c,u,v)}},{key:"addYaxisAnnotation",value:function(c){var u=!(arguments.length>1&&arguments[1]!==void 0)||arguments[1],d=arguments.length>2&&arguments[2]!==void 0?arguments[2]:void 0,v=this;d&&(v=d),v.annotations.addYaxisAnnotationExternal(c,u,v)}},{key:"addPointAnnotation",value:function(c){var u=!(arguments.length>1&&arguments[1]!==void 0)||arguments[1],d=arguments.length>2&&arguments[2]!==void 0?arguments[2]:void 0,v=this;d&&(v=d),v.annotations.addPointAnnotationExternal(c,u,v)}},{key:"clearAnnotations",value:function(){var c=arguments.length>0&&arguments[0]!==void 0?arguments[0]:void 0,u=this;c&&(u=c),u.annotations.clearAnnotations(u)}},{key:"removeAnnotation",value:function(c){var u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:void 0,d=this;u&&(d=u),d.annotations.removeAnnotation(d,c)}},{key:"getChartArea",value:function(){return this.w.globals.dom.baseEl.querySelector(".apexcharts-inner")}},{key:"getSeriesTotalXRange",value:function(c,u){return this.coreUtils.getSeriesTotalsXRange(c,u)}},{key:"getHighestValueInSeries",value:function(){var c=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0;return new we(this.ctx).getMinYMaxY(c).highestY}},{key:"getLowestValueInSeries",value:function(){var c=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0;return new we(this.ctx).getMinYMaxY(c).lowestY}},{key:"getSeriesTotal",value:function(){return this.w.globals.seriesTotals}},{key:"toggleDataPointSelection",value:function(c,u){return this.updateHelpers.toggleDataPointSelection(c,u)}},{key:"zoomX",value:function(c,u){this.ctx.toolbar.zoomUpdateOptions(c,u)}},{key:"setLocale",value:function(c){this.localization.setCurrentLocaleValues(c)}},{key:"dataURI",value:function(c){return new le(this.ctx).dataURI(c)}},{key:"exportToCSV",value:function(){var c=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};return new le(this.ctx).exportToCSV(c)}},{key:"paper",value:function(){return this.w.globals.dom.Paper}},{key:"_parentResizeCallback",value:function(){this.w.globals.animationEnded&&this.w.config.chart.redrawOnParentResize&&this._windowResize()}},{key:"_windowResize",value:function(){var c=this;clearTimeout(this.w.globals.resizeTimer),this.w.globals.resizeTimer=window.setTimeout(function(){c.w.globals.resized=!0,c.w.globals.dataChanged=!1,c.ctx.update()},150)}},{key:"_windowResizeHandler",value:function(){var c=this.w.config.chart.redrawOnWindowResize;typeof c=="function"&&(c=c()),c&&this._windowResize()}}],[{key:"getChartByID",value:function(c){var u=E.escapeString(c);if(Apex._chartInstances){var d=Apex._chartInstances.filter(function(v){return v.id===u})[0];return d&&d.chart}}},{key:"initOnLoad",value:function(){for(var c=document.querySelectorAll("[data-apexcharts]"),u=0;u2?m-2:0),w=2;w{const{Options:r,Posn:n,Series:i,Size:o,ChartType:a,Event:s,CSS:l}=t==null?void 0:t.Properties,[h,p]=_.useState(null),{socket:f,handleData:g}=x1(),b=$1(l),z=Gr(t==null?void 0:t.Properties),M=_.useRef(null);_.useEffect(()=>{M.current&&setTimeout(()=>{const E=M.current.chart.paper().svg();E&&(p(E),localStorage.setItem(t.ID,JSON.stringify(E)),g({ID:t==null?void 0:t.ID,Properties:{SVG:E}},"WS"))},500)},[M.current]);const I=(H,E,R,W)=>{var Z,K,et;const $={dataPointIndex:W==null?void 0:W.dataPointIndex,seriesIndex:W==null?void 0:W.seriesIndex,series:(Z=W==null?void 0:W.config)==null?void 0:Z.series,xaxis:(K=W==null?void 0:W.config)==null?void 0:K.xaxis,yaxis:(et=W==null?void 0:W.config)==null?void 0:et.yaxis},G=JSON.stringify({Event:{ID:t==null?void 0:t.ID,EventName:H,Info:[JSON.stringify($)]}});console.log(G),f.send(G)};console.log("chart",h);const F={...r,chart:{events:{...(s==null?void 0:s.some(H=>H[0]==="click"))&&{click:(H,E,R)=>I("click",H,E,R)},...(s==null?void 0:s.some(H=>H[0]==="legendclick"))&&{legendClick:(H,E,R)=>I("legendclick",H,E,R)}}}};return vt.jsx("div",{style:{position:"absolute",top:n&&n[0],left:n&&n[1],...z,...b},children:vt.jsx(RO,{ref:M,options:F,width:o&&o[1],height:o&&o[0],type:a,series:i})})};function bFt(t){return C({tag:"svg",attr:{viewBox:"0 0 256 256",fill:"currentColor"},child:[{tag:"path",attr:{d:"M236.8,188.09,149.35,36.22h0a24.76,24.76,0,0,0-42.7,0L19.2,188.09a23.51,23.51,0,0,0,0,23.72A24.35,24.35,0,0,0,40.55,224h174.9a24.35,24.35,0,0,0,21.33-12.19A23.51,23.51,0,0,0,236.8,188.09ZM120,104a8,8,0,0,1,16,0v40a8,8,0,0,1-16,0Zm8,88a12,12,0,1,1,12-12A12,12,0,0,1,128,192Z"}}]})(t)}function wFt(t){return C({tag:"svg",attr:{viewBox:"0 0 16 16",fill:"currentColor"},child:[{tag:"path",attr:{fillRule:"evenodd",clipRule:"evenodd",d:"M8.6 1c1.6.1 3.1.9 4.2 2 1.3 1.4 2 3.1 2 5.1 0 1.6-.6 3.1-1.6 4.4-1 1.2-2.4 2.1-4 2.4-1.6.3-3.2.1-4.6-.7-1.4-.8-2.5-2-3.1-3.5C.9 9.2.8 7.5 1.3 6c.5-1.6 1.4-2.9 2.8-3.8C5.4 1.3 7 .9 8.6 1zm.5 12.9c1.3-.3 2.5-1 3.4-2.1.8-1.1 1.3-2.4 1.2-3.8 0-1.6-.6-3.2-1.7-4.3-1-1-2.2-1.6-3.6-1.7-1.3-.1-2.7.2-3.8 1-1.1.8-1.9 1.9-2.3 3.3-.4 1.3-.4 2.7.2 4 .6 1.3 1.5 2.3 2.7 3 1.2.7 2.6.9 3.9.6zM7.9 7.5L10.3 5l.7.7-2.4 2.5 2.4 2.5-.7.7-2.4-2.5-2.4 2.5-.7-.7 2.4-2.5-2.4-2.5.7-.7 2.4 2.5z"}}]})(t)}function CFt(t){return C({tag:"svg",attr:{viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true"},child:[{tag:"path",attr:{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-8-3a1 1 0 00-.867.5 1 1 0 11-1.731-1A3 3 0 0113 8a3.001 3.001 0 01-2 2.83V11a1 1 0 11-2 0v-1a1 1 0 011-1 1 1 0 100-2zm0 8a1 1 0 100-2 1 1 0 000 2z",clipRule:"evenodd"}}]})(t)}const NO=({data:t,onClose:r,isDesktop:n,options:i})=>{const{Caption:o,Text:a,Style:s,Btns:l}=t==null?void 0:t.Properties,h=()=>{switch(s){case"Info":return vt.jsx(Bxt,{className:"icon info-icon"});case"Query":return vt.jsx(CFt,{className:"icon question-icon"});case"Warn":return vt.jsx(bFt,{className:"icon warning-icon"});case"Error":return vt.jsx(wFt,{className:"icon error-icon"});default:return""}};let p=i.Desktop!==1;return vt.jsx("div",{className:"msgbox-overlay",children:vt.jsxs("div",{className:`msgbox-container ${p?"with-border":""}`,children:[p&&vt.jsx("div",{className:"msgbox-header with-border",children:o}),vt.jsxs("div",{className:"msgbox-body",children:[s&&s!=="Msg"&&vt.jsx(h,{}),vt.jsx("span",{children:a})]}),vt.jsx("div",{className:"msgbox-footer with-border",children:Array.isArray(l)?l.map((f,g)=>vt.jsx("button",{className:"rounded-button ",onClick:()=>r(`MsgBtn${g+1}`,t==null?void 0:t.ID),children:f==="OK"?"OK":f.charAt(0).toUpperCase()+f.slice(1).toLowerCase()},g)):vt.jsx("button",{className:"rounded-button",onClick:()=>r("MsgBtn1",t==null?void 0:t.ID),children:l})})]})})},SFt=({data:t})=>{var n,i,o;const r=Gr(t.Properties);return vt.jsx("div",{children:vt.jsx("a",{id:t.ID,href:t.Properties.Href,target:((n=t.Properties)==null?void 0:n.Target)||"_blank",download:((i=t.Properties)==null?void 0:i.Download)===1,style:{...r},children:((o=t.Properties)==null?void 0:o.Label)!==void 0?t.Properties.Label:t.Properties.Href})})},zFt=(t,r)=>{const i=(t.Properties||[]).filter(o=>!r.Defaults.hasOwnProperty(o));return i.length==0?null:{NotSupported:i}},MFt=(t,r)=>{const n={};return t.Properties.forEach(i=>{r.hasOwnProperty(i)&&(n[i]=r[i])}),n},Ev=(t,r,n)=>({WG:{ID:t.ID,WGID:t.WGID,Properties:MFt(t,{...r.Defaults,...n}),...zFt(t,r)}}),n0=({data:t})=>vt.jsx("div",{children:vt.jsx("input",{id:t.ID,type:"file"})});n0.Defaults={LastModified:-1,FileName:"",FileSize:-1,FileType:"",FileBytes:""};n0.WG=(t,r)=>{var a;let n=(a=document.getElementById(r.ID))==null?void 0:a.files[0];if(!n)return t(Ev(r,n0,{}));const i={LastModified:n.lastModified,FileName:n.name,FileSize:n.size,FileType:n.type};r.Properties.includes("FileBytes")||(n=n.slice(0,1));const o=new FileReader;o.onload=s=>{i.FileBytes=btoa(s.target.result),t(Ev(r,n0,i))},o.onerror=s=>{t(Ev(r,n0,{}))},o.readAsBinaryString(n)};const kFt=({data:t})=>{const{Options:r,Posn:n,Series:i,Size:o,ChartType:a,Event:s}=t==null?void 0:t.Properties;x1();const l=["#ff6358","#ffd246","#78d237","#28b4c8","#2d73f5","#aa46be"];return vt.jsx("div",{style:{position:"absolute",top:n&&n[0],left:n&&n[1]},children:vt.jsx(iVt,{style:{width:o&&o[1],height:o&&o[0]},seriesColors:l,pannable:!0,zoomable:!0,children:vt.jsx(PO,{children:i.map((h,p)=>vt.jsx(gC,{data:h.data,type:"column",name:"series-"+p},p))})})})};var tn=function(t){return t!=null},x9=function(t){return t==null},$O=function(t){return Array.isArray(t)},vE=function(t){return typeof t=="function"},xC=function(t){return typeof t=="string"},_Ft=function(t){return x9(t)||t.trim().length===0},AFt=function(t){return!_Ft(t)},LFt=function(t){return!isNaN(t-parseFloat(t))},b9=function(t){return t&&t.getTime},w8=function(t){return tn(t.filters)},WO=function(t,r,n){return function(i){return t(i)?r(i):n(i)}},aa=function(){for(var t=[],r=0;r":"gt",">=":"gte",equal:"eq",equals:"eq",equalto:"eq",ge:"gte",greater:"gt",greaterthan:"gt",greaterthanequal:"gte",isempty:"isempty",isequalto:"eq",isgreaterthan:"gt",isgreaterthanorequalto:"gte",islessthan:"lt",islessthanorequalto:"lte",isnotempty:"isnotempty",isnotequalto:"neq",isnull:"isnull",le:"lte",less:"lt",lessthan:"lt",lessthanequal:"lte",ne:"neq",notequal:"neq",notequals:"neq",notequalto:"neq",notsubstringof:"doesnotcontain"}[t.toLowerCase()]||t},jO=function(t){t.filters&&(t.filters=t.filters.map(function(r){var n=Object.assign({},r);return!w8(r)&&xC(r.operator)&&(n.operator=HFt(r.operator)),w8(r)&&jO(n),n}))},DFt=function(t){return w8(t)?Object.assign({},t):{filters:$O(t)?t:[t],logic:"and"}},PFt=function(t){return tn(t)&&(t=DFt(t),jO(t)),t},dc={},TFt=/\[(?:(\d+)|['"](.*?)['"])\]|((?:(?!\[.*?\]|\.).)+)/g;dc.undefined=function(t){return t};var X0=function(t,r){var n=t+r;if(dc[n])return dc[n];var i=[];return t.replace(TFt,function(o,a,s,l){i.push(tn(a)?a:s||l)}),dc[n]=function(o){for(var a=o,s=0;s0},RFt=function(t){return function(r){return FFt(t(r))}},OFt=function(t,r){return WO(t,r,VFt)},BFt=function(t){var r=t.skip,n=t.take;return Math.floor((r||0)/n)+1},bC=function(t,r){return function(n){return t(n).map(r).join("~")}},NFt=function(t){return function(r){return r.slice(0,r.indexOf(t))}},$Ft=function(t){return aa.apply(void 0,t.map(function(r){var n=r[0],i=r[1];return function(o){return o.replace(new RegExp(n,"g"),i)}}))},WFt=$Ft([['"',""],[":","-"]]),jFt=NFt("."),GO=function(t){var r=t.field,n=t.dir,i=n===void 0?"asc":n;return r+"-"+i},GFt=function(t){var r=t.field,n=t.aggregate;return r+"-"+n},UFt=X0("take"),YFt=X0("aggregates");X0("skip");var XFt=X0("group"),wC=X0("sort",!0),KFt=bC(wC,GO),qFt=bC(XFt,GO),ZFt=bC(YFt,GFt),JFt=function(t){return"datetime'"+t+"'"},QFt=aa(JFt,jFt,WFt,JSON.stringify,EFt),tRt=function(t){var r=t.field,n=t.value,i=t.ignoreCase,o=t.operator;return{value:QFt(n),field:r,ignoreCase:i,operator:o}},eRt=function(t){return Object.assign({},t,{sort:(wC(t)||[]).filter(function(r){var n=r.dir;return AFt(n)})})};aa(f5("page"),BFt);aa(f5("pageSize"),UFt);aa(f5("group"),qFt);var rRt=aa(f5("sort"),KFt);aa(f5("aggregate"),ZFt);aa(OFt(RFt(wC),rRt),eRt);var gE=function(t){var r=t.field,n=t.operator,i=t.value;return r+"~"+n+"~"+i};WO(IFt,aa(gE,tRt),gE);var UO=function(t,r,n){return r[t]=n,r},YO=function(t){return function(r){return Object.keys(r).reduce(t.bind(null,r),{})}},iRt=YO(function(t,r,n){return UO(n.toLowerCase(),r,t[n])}),nRt=YO(function(t,r,n){return UO(n,r,iRt(t[n]))}),mE=function(t,r){return tn(t)?t:r},oRt=function(t){return{aggregates:t.Aggregates||t.aggregates,field:t.Member||t.member||t.field,hasSubgroups:t.HasSubgroups||t.hasSubgroups||!1,items:t.Items||t.items,value:mE(t.Key,mE(t.key,t.value))}},aRt=aa(function(t){var r=t.field,n=t.hasSubgroups,i=t.value,o=t.aggregates,a=t.items;return{aggregates:nRt(o),field:r,items:n?a.map(aRt):a,value:i}},oRt),XO=function(t,r){return x9(t)?t===r?0:-1:x9(r)?1:t.localeCompare?t.localeCompare(r):t>r?1:t=0},doesnotcontain:function(t,r){return(t||"").indexOf(r)===-1},doesnotendwith:function(t,r){return(t||"").indexOf(r,(t||"").length-(r||"").length)<0},doesnotstartwith:function(t,r){return(t||"").lastIndexOf(r,0)===-1},endswith:function(t,r){return(t||"").indexOf(r,(t||"").length-(r||"").length)>=0},eq:function(t,r){return t===r},gt:function(t,r){return t>r},gte:function(t,r){return t>=r},isempty:function(t){return t===""},isnotempty:function(t){return t!==""},isnotnull:function(t){return tn(t)},isnull:function(t){return x9(t)},lt:function(t,r){return t{r.preventDefault(),this.props.pageChange(n,r)},this.handleSelectPageChange=r=>{r.preventDefault(),this.props.pageChange(r.target.value,r)}}render(){const r=si(this),{messagesMap:n,size:i,totalPages:o,currentPage:a,type:s,navigatable:l}=this.props,h=n?n(G7):{messageKey:G7,defaultMessage:xi[G7]},p=n?n(Xo):{messageKey:Xo,defaultMessage:xi[Xo]},f=n?n(U7):{messageKey:U7,defaultMessage:xi[U7]},g=r.toLanguageString(f.messageKey,f.defaultMessage),b=this.start>1&&this.renderDots(this.start-1,g),z=this.end1&&this.renderOptionDots(this.start-1),I=this.end_.createElement(ei,{className:Me({"k-selected":a===R}),key:R,fillMode:"flat",themeColor:"primary",size:i,rounded:null,role:"button","aria-label":r.toLanguageString(p.messageKey,p.defaultMessage)+" "+R,"aria-current":a===R?!0:void 0,onClick:W=>this.handlePageChange(W,R),tabIndex:l?-1:void 0},R)),E=F.map(R=>_.createElement("option",{key:R},R));return _.createElement(_.Fragment,null,_.createElement("select",{style:{width:"5em",margin:"0px 1em",display:"inline-flex"},className:Me("k-picker k-dropdown-list k-dropdown k-rounded-md k-picker-solid",{[`k-picker-${Gr.sizeMap[i]||i}`]:i,"k-hidden":s!=="dropdown"}),"aria-label":r.toLanguageString(h.messageKey,h.defaultMessage),value:a,onChange:R=>this.handleSelectPageChange(R)},M,E,I),_.createElement("div",{className:"k-pager-numbers",style:{display:s==="numbers"?"":"none"}},b,H,z))}get end(){return Math.min(this.start+this.props.buttonCount-1,this.props.totalPages)}get start(){const r=this.props.currentPage,n=this.props.buttonCount;if(r>n){const i=r%n;return i===0?r-n+1:r-i+1}return 1}renderDots(r,n){return _.createElement(ei,{fillMode:"flat",themeColor:"primary",size:this.props.size,rounded:null,role:"button","aria-label":n,onClick:i=>this.handlePageChange(i,r),tabIndex:this.props.navigatable?-1:void 0},yE)}renderOptionDots(r){return _.createElement("option",{value:r},yE)}};/** + */const xE="...";let AOt=class extends _.Component{constructor(){super(...arguments),this.handlePageChange=(r,n)=>{r.preventDefault(),this.props.pageChange(n,r)},this.handleSelectPageChange=r=>{r.preventDefault(),this.props.pageChange(r.target.value,r)}}render(){const r=ai(this),{messagesMap:n,size:i,totalPages:o,currentPage:a,type:s,navigatable:l}=this.props,h=n?n(G7):{messageKey:G7,defaultMessage:yi[G7]},p=n?n(Uo):{messageKey:Uo,defaultMessage:yi[Uo]},f=n?n(U7):{messageKey:U7,defaultMessage:yi[U7]},g=r.toLanguageString(f.messageKey,f.defaultMessage),b=this.start>1&&this.renderDots(this.start-1,g),z=this.end1&&this.renderOptionDots(this.start-1),I=this.end_.createElement(Jr,{className:ke({"k-selected":a===R}),key:R,fillMode:"flat",themeColor:"primary",size:i,rounded:null,role:"button","aria-label":r.toLanguageString(p.messageKey,p.defaultMessage)+" "+R,"aria-current":a===R?!0:void 0,onClick:W=>this.handlePageChange(W,R),tabIndex:l?-1:void 0},R)),E=F.map(R=>_.createElement("option",{key:R},R));return _.createElement(_.Fragment,null,_.createElement("select",{style:{width:"5em",margin:"0px 1em",display:"inline-flex"},className:ke("k-picker k-dropdown-list k-dropdown k-rounded-md k-picker-solid",{[`k-picker-${Wr.sizeMap[i]||i}`]:i,"k-hidden":s!=="dropdown"}),"aria-label":r.toLanguageString(h.messageKey,h.defaultMessage),value:a,onChange:R=>this.handleSelectPageChange(R)},M,E,I),_.createElement("div",{className:"k-pager-numbers",style:{display:s==="numbers"?"":"none"}},b,H,z))}get end(){return Math.min(this.start+this.props.buttonCount-1,this.props.totalPages)}get start(){const r=this.props.currentPage,n=this.props.buttonCount;if(r>n){const i=r%n;return i===0?r-n+1:r-i+1}return 1}renderDots(r,n){return _.createElement(Jr,{fillMode:"flat",themeColor:"primary",size:this.props.size,rounded:null,role:"button","aria-label":n,onClick:i=>this.handlePageChange(i,r),tabIndex:this.props.navigatable?-1:void 0},xE)}renderOptionDots(r){return _.createElement("option",{value:r},xE)}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const fy="labels.optional",AOt={[fy]:"(Optional)"};/** + */const fy="labels.optional",LOt={[fy]:"(Optional)"};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const LOt={name:"@progress/kendo-react-labels",productName:"KendoReact",productCodes:["KENDOUIREACT","KENDOUICOMPLETE"],publishDate:1722843867,version:"",licensingDocsUrl:"https://www.telerik.com/kendo-react-ui/components/my-license/"};/** + */const EOt={name:"@progress/kendo-react-labels",productName:"KendoReact",productCodes:["KENDOUIREACT","KENDOUICOMPLETE"],publishDate:1722843867,version:"",licensingDocsUrl:"https://www.telerik.com/kendo-react-ui/components/my-license/"};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const qO=class extends _.Component{constructor(r){super(r),this.state={focused:!1},this.handleFocus=n=>{this.setState({focused:!0})},this.handleBlur=n=>{this.setState({focused:!1})},gi(LOt)}render(){const{label:r,editorId:n,className:i,labelClassName:o,editorValue:a,editorPlaceholder:s,editorValid:l,editorDisabled:h,style:p,id:f,optional:g,...b}=this.props,z=si(this),M=g?z.toLanguageString(fy,AOt[fy]):"",I=M&&_.createElement("span",{className:"k-label-optional"},M),F=Me({"k-floating-label-container":!0,"k-focus":this.state.focused,"k-empty":!s&&!a&&a!==0,"k-text-disabled":h,"k-rtl":this.props.dir==="rtl"},i),H=Me({"k-floating-label":!0,"k-text-error":l===!1,"k-text-disabled":h},o);return _.createElement("span",{...b,id:this.props.id,className:F,onFocus:this.handleFocus,onBlur:this.handleBlur,style:p,dir:this.props.dir},this.props.children,r?n?_.createElement("label",{id:f,htmlFor:n,className:H},r,I):_.createElement("span",{id:f,className:H},r,I):null)}};qO.propTypes={label:B.string,editorId:B.string,editorValue:B.oneOfType([B.string,B.bool,B.number]),editorPlaceholder:B.string,editorValid:B.bool,editorDisabled:B.bool,id:B.string,style:B.object,className:B.string,labelClassName:B.string,optional:B.bool};let v5=qO;Ri(v5);/** + */const ZO=class extends _.Component{constructor(r){super(r),this.state={focused:!1},this.handleFocus=n=>{this.setState({focused:!0})},this.handleBlur=n=>{this.setState({focused:!1})},vi(EOt)}render(){const{label:r,editorId:n,className:i,labelClassName:o,editorValue:a,editorPlaceholder:s,editorValid:l,editorDisabled:h,style:p,id:f,optional:g,...b}=this.props,z=ai(this),M=g?z.toLanguageString(fy,LOt[fy]):"",I=M&&_.createElement("span",{className:"k-label-optional"},M),F=ke({"k-floating-label-container":!0,"k-focus":this.state.focused,"k-empty":!s&&!a&&a!==0,"k-text-disabled":h,"k-rtl":this.props.dir==="rtl"},i),H=ke({"k-floating-label":!0,"k-text-error":l===!1,"k-text-disabled":h},o);return _.createElement("span",{...b,id:this.props.id,className:F,onFocus:this.handleFocus,onBlur:this.handleBlur,style:p,dir:this.props.dir},this.props.children,r?n?_.createElement("label",{id:f,htmlFor:n,className:H},r,I):_.createElement("span",{id:f,className:H},r,I):null)}};ZO.propTypes={label:B.string,editorId:B.string,editorValue:B.oneOfType([B.string,B.bool,B.number]),editorPlaceholder:B.string,editorValid:B.bool,editorDisabled:B.bool,id:B.string,style:B.object,className:B.string,labelClassName:B.string,optional:B.bool};let v5=ZO;Vi(v5);/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const ZO={name:"@progress/kendo-react-inputs",productName:"KendoReact",productCodes:["KENDOUIREACT","KENDOUICOMPLETE"],publishDate:1722843933,version:"",licensingDocsUrl:"https://www.telerik.com/kendo-react-ui/components/my-license/"};/** + */const JO={name:"@progress/kendo-react-inputs",productName:"KendoReact",productCodes:["KENDOUIREACT","KENDOUICOMPLETE"],publishDate:1722843933,version:"",licensingDocsUrl:"https://www.telerik.com/kendo-react-ui/components/my-license/"};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const fc="numerictextbox.increment",vc="numerictextbox.decrement",EOt="slider.increment",IOt="slider.decrement",HOt="slider.dragTitle",DOt="colorGradient.r",POt="colorGradient.g",TOt="colorGradient.b",VOt="colorGradient.a",FOt="colorGradient.hex",ROt="colorGradient.contrastRatio",OOt="colorGradient.colorGradientAALevel",BOt="colorGradient.colorGradientAAALevel",NOt="colorGradient.colorGradientPass",$Ot="colorGradient.colorGradientFail",WOt="colorGradient.hueSliderLabel",jOt="colorGradient.alphaSliderLabel",GOt="colorGradient.toggleInputsButton",UOt="flatColorPicker.cancelBtn",YOt="flatColorPicker.applyBtn",XOt="flatColorPicker.colorGradientBtn",KOt="flatColorPicker.colorPaletteBtn",qOt="flatColorPicker.clearBtn",ZOt="checkbox.validation",JOt="checkbox.optionalText",QOt="radioButton.validation",tBt="switch.validation",eBt="colorPicker.dropdownButtonAriaLabel",rBt="rating.ariaLabel",iBt="signature.clear",nBt="signature.maximize",oBt="signature.minimize",Qh={[fc]:"Increase value",[vc]:"Decrease value",[EOt]:"Increase",[IOt]:"Decrease",[HOt]:"Drag",[DOt]:"r",[POt]:"g",[TOt]:"b",[VOt]:"a",[FOt]:"hex",[ROt]:"Contrast ratio",[OOt]:"AA",[BOt]:"AAA",[NOt]:"Pass",[$Ot]:"Fail",[WOt]:"Hue slider",[jOt]:"Alpha slider",[GOt]:"Toggle colorgradient inputs",[UOt]:"Cancel",[YOt]:"Apply",[XOt]:"Color Gradient view",[KOt]:"Color Palette view",[qOt]:"Clear color value",[ZOt]:"Please check this box if you want to proceed!",[JOt]:"(Optional)",[QOt]:"Please select option if you want to proceed!",[tBt]:"Please turn on if you want to proceed!",[eBt]:"Select",[rBt]:"Rating",[iBt]:"Clear",[nBt]:"Maximize",[oBt]:"Minimize"};/** + */const fc="numerictextbox.increment",vc="numerictextbox.decrement",IOt="slider.increment",HOt="slider.decrement",DOt="slider.dragTitle",POt="colorGradient.r",TOt="colorGradient.g",VOt="colorGradient.b",FOt="colorGradient.a",ROt="colorGradient.hex",OOt="colorGradient.contrastRatio",BOt="colorGradient.colorGradientAALevel",NOt="colorGradient.colorGradientAAALevel",$Ot="colorGradient.colorGradientPass",WOt="colorGradient.colorGradientFail",jOt="colorGradient.hueSliderLabel",GOt="colorGradient.alphaSliderLabel",UOt="colorGradient.toggleInputsButton",YOt="flatColorPicker.cancelBtn",XOt="flatColorPicker.applyBtn",KOt="flatColorPicker.colorGradientBtn",qOt="flatColorPicker.colorPaletteBtn",ZOt="flatColorPicker.clearBtn",JOt="checkbox.validation",QOt="checkbox.optionalText",tBt="radioButton.validation",eBt="switch.validation",rBt="colorPicker.dropdownButtonAriaLabel",iBt="rating.ariaLabel",nBt="signature.clear",oBt="signature.maximize",aBt="signature.minimize",Qh={[fc]:"Increase value",[vc]:"Decrease value",[IOt]:"Increase",[HOt]:"Decrease",[DOt]:"Drag",[POt]:"r",[TOt]:"g",[VOt]:"b",[FOt]:"a",[ROt]:"hex",[OOt]:"Contrast ratio",[BOt]:"AA",[NOt]:"AAA",[$Ot]:"Pass",[WOt]:"Fail",[jOt]:"Hue slider",[GOt]:"Alpha slider",[UOt]:"Toggle colorgradient inputs",[YOt]:"Cancel",[XOt]:"Apply",[KOt]:"Color Gradient view",[qOt]:"Color Palette view",[ZOt]:"Clear color value",[JOt]:"Please check this box if you want to proceed!",[QOt]:"(Optional)",[tBt]:"Please select option if you want to proceed!",[eBt]:"Please turn on if you want to proceed!",[rBt]:"Select",[iBt]:"Rating",[nBt]:"Clear",[oBt]:"Maximize",[aBt]:"Minimize"};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const w9=11111111111111e-7,aBt=.31111111111111117,sBt=1,JO=1,QO=0,P2=/\d/,tB=15,xE=()=>({eventValue:null,prevLooseValue:"",currentLooseValue:"",focused:!1,selectionStart:void 0,selectionEnd:void 0,decimalSelect:!1,valueIsCorrected:!1,valueIsOutOfRange:!1}),Iv=(t,r)=>t!==void 0?t:r,pn=(t,r,n)=>t===null&&t===void 0?"":typeof t=="string"?t:n.formatNumber(t,r),bE=t=>(String(t).split(".")[1]||"").length,eB=(t,r)=>Math.max(bE(t),bE(r)),lBt=t=>Math.min(t,tB),rB=(t,r)=>{const n=lBt(r);return parseFloat(t.toFixed(n))},wE=(t,r,n,i,o,a,s)=>{const l=eB(t||0,n||0),h=Z3(rB((t||0)+(n||0),l),i,o);r.eventValue=h,r.currentLooseValue=pn(h,a,s),r.selectionStart=r.selectionEnd=C8(r.currentLooseValue,P2)},CE=(t,r,n,i,o,a,s)=>{const l=eB(t||0,n||0),h=Z3(rB((t||0)-(n||0),l),i,o);r.eventValue=h,r.currentLooseValue=pn(h,a,s),r.selectionStart=r.selectionEnd=C8(r.currentLooseValue,P2)},Z3=(t,r,n)=>t==null?t:!(t>1||t<1||t===1)||n!==void 0&&r!==void 0&&nn&&(t=n),r!==void 0&&t{const n=r.findIndex(([o,a])=>!!a&&t.indexOf(a)===t.length-a.length);if(n===-1)return-1;const i=r[n][1];return t.length-i.length},hBt=(t,r)=>{const n=r.findIndex(([i,o])=>!!i&&t.indexOf(i)===0);return n===-1?-1:r[n][0].length},uBt=(t,r,n)=>{const i=cBt(t,r);if(i!==-1&&n.selectionStart>i){n.selectionStart=n.selectionEnd=i;return}n.selectionStart>t.length&&(n.selectionStart=n.selectionEnd=t.length);const o=hBt(t,r);o!==-1&&n.selectionStart{t.selectionStart=t.selectionEnd=r,uBt(n,i,t)},SE=(t,r,n,i)=>{t.eventValue=i.parseNumber(t.prevLooseValue,r),t.currentLooseValue=t.prevLooseValue,t.valueIsCorrected=!0,ka(t,t.selectionStart,t.currentLooseValue,n)},Hv=(t,r,n)=>r.split(t).length!==n.split(t).length&&r.length===n.length+t.length,pBt=(t,r)=>{const n=String(t.currentLooseValue),i=String(t.prevLooseValue);return Hv(r.minusSign,n,i)||Hv("-",n,i)||Hv("−",n,i)},dBt=(t,r)=>{const n=String(t.currentLooseValue),i=String(t.prevLooseValue);return n.indexOf(r.minusSign)===-1&&i.indexOf(r.minusSign)!==-1},fBt=(t,r)=>String(t.currentLooseValue).split(r.decimal).length>2,vBt=(t,r)=>{const n=r.formatNumber(w9,t),i=r.formatNumber(-w9,t),o=r.formatNumber(QO,t),a=r.formatNumber(JO,t),s=t7(n),l=t7(i),h=t7(o),p=t7(a),f=e7(n),g=e7(i),b=e7(o),z=e7(a);return{positiveInfo:[s,f],negativeInfo:[l,g],zeroInfo:[h,b],oneInfo:[p,z]}},gBt=(t,r)=>{const n=r.formatNumber(w9,t),i=r.formatNumber(-w9,t),o=r.formatNumber(QO,t),a=r.formatNumber(JO,t),s=r.numberSymbols(),l=new RegExp(`[\\d\\${s.decimal}${s.group}]`,"g");return[n,i,o,a].map(h=>h.replace(l,"")).join("").split("").filter((h,p,f)=>f.indexOf(h)===p).join("")},Dv=(t,r)=>{const n=t.indexOf(r.decimal);return n>-1?n:C8(t,P2)},vy=t=>t.split("").reverse().join(""),C8=(t,r)=>t.length-vy(t).search(r),t7=t=>t.split(t[t.search(P2)])[0],e7=t=>{const r=vy(t);return vy(r.split(r[r.search(P2)])[0])},Pv=(t,r)=>t.search(r),zE=(t,r)=>{const n=t.indexOf(r);return n>-1?t.length-n-1:0},ME=(t,r,n,i,o)=>{const a=t.replace(o,"")[0]==="0",s=r.replace(o,"")[0]==="0";if(a&&!s)return n-1;if(s&&i)return n+1;let l=0;for(let p=0;p0&&r.length>h;)P2.test(r.charAt(h))&&l--,h++;return h},kE=(t,r,n)=>{const i={...t},{prevLooseValue:o}=i,a=n.numberSymbols(),s=gBt(r,n),l=String(i.currentLooseValue),h=String(o),p=new RegExp(`[^\\d\\${a.decimal}]`,"g"),f=new RegExp(`[^\\d\\${a.decimal}\\${a.group}]`,"g"),g=new RegExp(`[\\d\\${a.decimal}\\${a.group}]`),b=l.replace(p,""),z=Pv(l,P2),M=z===-1?-1:C8(l,P2),I=l.indexOf(a.decimal),F=(l.substring(0,z)+l.substring(z,M).replace(f,"")+l.substring(M,l.length)).split("").filter(lt=>s.indexOf(lt)!==-1||lt.search(g)!==-1).join(""),H=n.formatNumber(aBt,r).replace(p,""),E=H.indexOf(a.decimal),R=E>-1?H.length-E-1:0,W=n.formatNumber(sBt,r).replace(p,""),$=W.indexOf(a.decimal),G=$>-1?W.length-$-1:0,{positiveInfo:Z,negativeInfo:K,zeroInfo:et,oneInfo:at}=vBt(r,n),tt=[Z,K,et,at],ft=tt.findIndex(lt=>lt.findIndex(yt=>!!yt)!==-1)!==1,dt=l.length>0&&l.length0){const gt=C8(mt,P2);i.currentLooseValue=mt.substring(0,gt)+a.decimal+mt.substring(gt)}else i.currentLooseValue=mt;return ka(i,Dv(i.currentLooseValue,a)+1,i.currentLooseValue,tt),i}if(pBt(i,a)){const mt=n.parseNumber(o,r);i.eventValue=-(mt!==null?mt:0),i.currentLooseValue=pn(i.eventValue,r,n);const gt=Pv(i.currentLooseValue,P2),kt=Pv(h,P2);return ka(i,i.selectionEnd-1+(gt-kt),i.currentLooseValue,tt),i}if(dBt(i,a))return i.eventValue=n.parseNumber(i.currentLooseValue,r),ka(i,i.selectionStart,i.currentLooseValue,tt),i;if(fBt(i,a))return SE(i,r,tt,n),i;if(ht)return i.eventValue=n.parseNumber(l,r)/100,i.currentLooseValue=pn(i.eventValue,r,n),i;if(String(i.currentLooseValue).replace(/[^\d]/g,"").length>tB||b!==l&&l&&ft&&tt.findIndex(([mt,gt])=>{const kt=l.indexOf(mt),_t=l.indexOf(gt),bt=kt===0,Mt=_t===l.length-gt.length,At=kt+mt.length!==z&&z!==-1&&l[kt+mt.length]!==a.decimal,Ft=_t!==M&&M!==-1&&l[_t-1]!==a.decimal;return mt&>?At||Ft?!1:bt&&Mt:mt?At?!1:bt:gt?Ft?!1:Mt:!1})===-1)return SE(i,r,tt,n),i;if(b[b.length-1]===a.decimal&&R>0)return i.eventValue=n.parseNumber(l,r),i.currentLooseValue=F,i;if(i.currentLooseValue&&o&&(s+a.decimal+a.group).split("").findIndex(mt=>l.split("").filter(gt=>gt===mt).lengthgt===mt).length&&l.length+1===h.length?!(mt===a.decimal&&zE(h.replace(p,""),a.decimal)===0):!1)>-1)return i.eventValue=n.parseNumber(t.prevLooseValue,r),i.currentLooseValue=t.prevLooseValue,i;const lt=zE(b,a.decimal),yt=b[b.length-1]==="0";if(dt&&yt&<0){const mt=l.substring(0,I);if(yt&&(!mt||h.indexOf(mt)!==0)){i.eventValue=n.parseNumber(i.currentLooseValue,r);const gt=pn(i.eventValue,r,n);return ka(i,ME(l,gt,i.selectionEnd,dt,p),gt,tt),i.currentLooseValue=gt,i}if(lt>R){const gt=l.indexOf(a.decimal),kt=l.substring(0,gt)+l.substring(gt,gt+1+R)+l.substring(M,String(i.currentLooseValue).length);return i.eventValue=n.parseNumber(kt,r),i.currentLooseValue=kt,ka(i,i.selectionStart,kt,tt),i}if(G!==R&<<=R&&yt)return i.eventValue=n.parseNumber(i.currentLooseValue,r),i.currentLooseValue=F,i;if(lt({eventValue:null,prevLooseValue:"",currentLooseValue:"",focused:!1,selectionStart:void 0,selectionEnd:void 0,decimalSelect:!1,valueIsCorrected:!1,valueIsOutOfRange:!1}),Iv=(t,r)=>t!==void 0?t:r,hn=(t,r,n)=>t===null&&t===void 0?"":typeof t=="string"?t:n.formatNumber(t,r),wE=t=>(String(t).split(".")[1]||"").length,rB=(t,r)=>Math.max(wE(t),wE(r)),cBt=t=>Math.min(t,eB),iB=(t,r)=>{const n=cBt(r);return parseFloat(t.toFixed(n))},CE=(t,r,n,i,o,a,s)=>{const l=rB(t||0,n||0),h=Z3(iB((t||0)+(n||0),l),i,o);r.eventValue=h,r.currentLooseValue=hn(h,a,s),r.selectionStart=r.selectionEnd=C8(r.currentLooseValue,E2)},SE=(t,r,n,i,o,a,s)=>{const l=rB(t||0,n||0),h=Z3(iB((t||0)-(n||0),l),i,o);r.eventValue=h,r.currentLooseValue=hn(h,a,s),r.selectionStart=r.selectionEnd=C8(r.currentLooseValue,E2)},Z3=(t,r,n)=>t==null?t:!(t>1||t<1||t===1)||n!==void 0&&r!==void 0&&nn&&(t=n),r!==void 0&&t{const n=r.findIndex(([o,a])=>!!a&&t.indexOf(a)===t.length-a.length);if(n===-1)return-1;const i=r[n][1];return t.length-i.length},uBt=(t,r)=>{const n=r.findIndex(([i,o])=>!!i&&t.indexOf(i)===0);return n===-1?-1:r[n][0].length},pBt=(t,r,n)=>{const i=hBt(t,r);if(i!==-1&&n.selectionStart>i){n.selectionStart=n.selectionEnd=i;return}n.selectionStart>t.length&&(n.selectionStart=n.selectionEnd=t.length);const o=uBt(t,r);o!==-1&&n.selectionStart{t.selectionStart=t.selectionEnd=r,pBt(n,i,t)},zE=(t,r,n,i)=>{t.eventValue=i.parseNumber(t.prevLooseValue,r),t.currentLooseValue=t.prevLooseValue,t.valueIsCorrected=!0,Ma(t,t.selectionStart,t.currentLooseValue,n)},Hv=(t,r,n)=>r.split(t).length!==n.split(t).length&&r.length===n.length+t.length,dBt=(t,r)=>{const n=String(t.currentLooseValue),i=String(t.prevLooseValue);return Hv(r.minusSign,n,i)||Hv("-",n,i)||Hv("−",n,i)},fBt=(t,r)=>{const n=String(t.currentLooseValue),i=String(t.prevLooseValue);return n.indexOf(r.minusSign)===-1&&i.indexOf(r.minusSign)!==-1},vBt=(t,r)=>String(t.currentLooseValue).split(r.decimal).length>2,gBt=(t,r)=>{const n=r.formatNumber(w9,t),i=r.formatNumber(-w9,t),o=r.formatNumber(tB,t),a=r.formatNumber(QO,t),s=t7(n),l=t7(i),h=t7(o),p=t7(a),f=e7(n),g=e7(i),b=e7(o),z=e7(a);return{positiveInfo:[s,f],negativeInfo:[l,g],zeroInfo:[h,b],oneInfo:[p,z]}},mBt=(t,r)=>{const n=r.formatNumber(w9,t),i=r.formatNumber(-w9,t),o=r.formatNumber(tB,t),a=r.formatNumber(QO,t),s=r.numberSymbols(),l=new RegExp(`[\\d\\${s.decimal}${s.group}]`,"g");return[n,i,o,a].map(h=>h.replace(l,"")).join("").split("").filter((h,p,f)=>f.indexOf(h)===p).join("")},Dv=(t,r)=>{const n=t.indexOf(r.decimal);return n>-1?n:C8(t,E2)},vy=t=>t.split("").reverse().join(""),C8=(t,r)=>t.length-vy(t).search(r),t7=t=>t.split(t[t.search(E2)])[0],e7=t=>{const r=vy(t);return vy(r.split(r[r.search(E2)])[0])},Pv=(t,r)=>t.search(r),ME=(t,r)=>{const n=t.indexOf(r);return n>-1?t.length-n-1:0},kE=(t,r,n,i,o)=>{const a=t.replace(o,"")[0]==="0",s=r.replace(o,"")[0]==="0";if(a&&!s)return n-1;if(s&&i)return n+1;let l=0;for(let p=0;p0&&r.length>h;)E2.test(r.charAt(h))&&l--,h++;return h},_E=(t,r,n)=>{const i={...t},{prevLooseValue:o}=i,a=n.numberSymbols(),s=mBt(r,n),l=String(i.currentLooseValue),h=String(o),p=new RegExp(`[^\\d\\${a.decimal}]`,"g"),f=new RegExp(`[^\\d\\${a.decimal}\\${a.group}]`,"g"),g=new RegExp(`[\\d\\${a.decimal}\\${a.group}]`),b=l.replace(p,""),z=Pv(l,E2),M=z===-1?-1:C8(l,E2),I=l.indexOf(a.decimal),F=(l.substring(0,z)+l.substring(z,M).replace(f,"")+l.substring(M,l.length)).split("").filter(lt=>s.indexOf(lt)!==-1||lt.search(g)!==-1).join(""),H=n.formatNumber(sBt,r).replace(p,""),E=H.indexOf(a.decimal),R=E>-1?H.length-E-1:0,W=n.formatNumber(lBt,r).replace(p,""),$=W.indexOf(a.decimal),G=$>-1?W.length-$-1:0,{positiveInfo:Z,negativeInfo:K,zeroInfo:et,oneInfo:at}=gBt(r,n),tt=[Z,K,et,at],ft=tt.findIndex(lt=>lt.findIndex(yt=>!!yt)!==-1)!==1,dt=l.length>0&&l.length0){const gt=C8(mt,E2);i.currentLooseValue=mt.substring(0,gt)+a.decimal+mt.substring(gt)}else i.currentLooseValue=mt;return Ma(i,Dv(i.currentLooseValue,a)+1,i.currentLooseValue,tt),i}if(dBt(i,a)){const mt=n.parseNumber(o,r);i.eventValue=-(mt!==null?mt:0),i.currentLooseValue=hn(i.eventValue,r,n);const gt=Pv(i.currentLooseValue,E2),_t=Pv(h,E2);return Ma(i,i.selectionEnd-1+(gt-_t),i.currentLooseValue,tt),i}if(fBt(i,a))return i.eventValue=n.parseNumber(i.currentLooseValue,r),Ma(i,i.selectionStart,i.currentLooseValue,tt),i;if(vBt(i,a))return zE(i,r,tt,n),i;if(ht)return i.eventValue=n.parseNumber(l,r)/100,i.currentLooseValue=hn(i.eventValue,r,n),i;if(String(i.currentLooseValue).replace(/[^\d]/g,"").length>eB||b!==l&&l&&ft&&tt.findIndex(([mt,gt])=>{const _t=l.indexOf(mt),At=l.indexOf(gt),bt=_t===0,kt=At===l.length-gt.length,Lt=_t+mt.length!==z&&z!==-1&&l[_t+mt.length]!==a.decimal,Vt=At!==M&&M!==-1&&l[At-1]!==a.decimal;return mt&>?Lt||Vt?!1:bt&&kt:mt?Lt?!1:bt:gt?Vt?!1:kt:!1})===-1)return zE(i,r,tt,n),i;if(b[b.length-1]===a.decimal&&R>0)return i.eventValue=n.parseNumber(l,r),i.currentLooseValue=F,i;if(i.currentLooseValue&&o&&(s+a.decimal+a.group).split("").findIndex(mt=>l.split("").filter(gt=>gt===mt).lengthgt===mt).length&&l.length+1===h.length?!(mt===a.decimal&&ME(h.replace(p,""),a.decimal)===0):!1)>-1)return i.eventValue=n.parseNumber(t.prevLooseValue,r),i.currentLooseValue=t.prevLooseValue,i;const lt=ME(b,a.decimal),yt=b[b.length-1]==="0";if(dt&&yt&<0){const mt=l.substring(0,I);if(yt&&(!mt||h.indexOf(mt)!==0)){i.eventValue=n.parseNumber(i.currentLooseValue,r);const gt=hn(i.eventValue,r,n);return Ma(i,kE(l,gt,i.selectionEnd,dt,p),gt,tt),i.currentLooseValue=gt,i}if(lt>R){const gt=l.indexOf(a.decimal),_t=l.substring(0,gt)+l.substring(gt,gt+1+R)+l.substring(M,String(i.currentLooseValue).length);return i.eventValue=n.parseNumber(_t,r),i.currentLooseValue=_t,Ma(i,i.selectionStart,_t,tt),i}if(G!==R&<<=R&&yt)return i.eventValue=n.parseNumber(i.currentLooseValue,r),i.currentLooseValue=F,i;if(lt{gi(ZO);const n=tT(yBt,t),{className:i,value:o,defaultValue:a,format:s,width:l,tabIndex:h,accessKey:p,title:f,placeholder:g,min:b,max:z,dir:M,name:I,label:F,id:H,ariaDescribedBy:E,ariaLabelledBy:R,ariaLabel:W,inputType:$,readOnly:G,validationMessage:Z,children:K,style:et,inputStyle:at,valid:tt,step:ft=cn.step,spinners:dt=cn.spinners,disabled:ht=cn.disabled,required:lt=cn.required,validityStyles:yt=cn.validityStyles,prefix:mt=cn.prefix,suffix:gt=cn.suffix,onChange:kt=cn.onChange,onFocus:_t=cn.onFocus,onBlur:bt=cn.onBlur,rangeOnEnter:Mt=cn.rangeOnEnter,size:At=cn.size,rounded:Ft=cn.rounded,fillMode:Bt=cn.fillMode,autoFocus:Ut=cn.autoFocus,...Xt}=n,It=pp(),ae=H||It,$t=oT(),ue=jl(),Ot=_.useRef(null),we=_.useRef(),[Ht,se]=_.useState(!1),Se=_.useRef(xE()),Kt=_.useRef(!1),fe=_.useRef(),ne=_.useRef(a),ce=pn(Se.current.focused&&!ht?Se.current.currentLooseValue:Iv(o,ne.current),s,$t);fe.current=ce;const[xe]=Vu(mt),[Wt]=Vu(gt);_.useEffect(()=>{Ot.current&&Ot.current.setCustomValidity&&Ot.current.setCustomValidity(Yt().valid?"":Z||mBt)});const qt=_.useCallback(()=>{Ot.current&&Ot.current.focus()},[]),Ee=_.useCallback(()=>we.current!==void 0?we.current:Iv(o,ne.current),[o]),Ie=_.useCallback(()=>I,[I]),Pe=_.useCallback(()=>lt,[lt]),Yt=_.useCallback(()=>{const Le=Z!==void 0,ge=Ee(),h1=tt!==void 0?tt:!Se.current.valueIsOutOfRange&&(!Pe()||ge!=null);return{customError:Le,valid:h1,valueMissing:ge==null}},[Z,tt,Ee,Pe]),st=_.useCallback(()=>yt,[yt]),Et=_.useCallback(()=>n,[n]),zt=_.useCallback(()=>{const Le={element:Ot.current,focus:qt};return Object.defineProperty(Le,"name",{get:Ie}),Object.defineProperty(Le,"value",{get:Ee}),Object.defineProperty(Le,"validity",{get:Yt}),Object.defineProperty(Le,"validityStyles",{get:st}),Object.defineProperty(Le,"required",{get:Pe}),Object.defineProperty(Le,"props",{get:Et}),Le},[Ie,Ee,Yt,st,Pe,qt,Et]);_.useImperativeHandle(r,zt);const Rt=_.useCallback(()=>({eventValue:Iv(o,ne.current),prevLooseValue:fe.current,currentLooseValue:Ot.current.value,selectionStart:Ot.current.selectionStart,selectionEnd:Ot.current.selectionEnd,decimalSelect:!1,valueIsCorrected:!1,valueIsOutOfRange:!1,isPaste:Kt.current,focused:Se.current.focused}),[o]),Vt=_.useCallback((Le,ge)=>{if(ht)return;we.current=ge.eventValue,ne.current=ge.eventValue;const h1=pn(Z3(ge.eventValue,b,z),s,$t),M1=Z3($t.parseNumber(h1,s),b,z);M1!==ge.eventValue&&(ge.valueIsOutOfRange=!0,ge.eventValue=M1,ne.current=M1),o!==ge.eventValue&&fn(kt,Le,zt(),{value:ge.eventValue}),we.current=void 0,Se.current=ge,se(Z1=>!Z1)},[o,kt,ht,se,zt]),Qt=_.useCallback(Le=>{const ge=Rt();Kt.current=!1,Vt(Le,kE(ge,s,$t))},[s,kt,$t,Vt,Rt]),ve=_.useCallback(Le=>{let ge=Rt();const h1=$t.parseNumber(String(ge.currentLooseValue),s);if(ge.selectionEnd>ge.selectionStart&&ge.selectionEnd-ge.selectionStart===String(ge.currentLooseValue).length){const M1=$t.numberSymbols(),Z1=M1&&Le.key===M1.minusSign,zr=M1&&Le.key===M1.decimal;Kt.current=!Z1&&!zr;return}switch(Le.keyCode){case 38:wE(h1,ge,ft,b,z,s,$t);break;case 40:CE(h1,ge,ft,b,z,s,$t);break;case 13:{if(Mt===!1)return;const M1=pn(Z3(h1,b,z),s,$t),Z1=Z3($t.parseNumber(M1,s),b,z);ge.eventValue=Z1,ge.currentLooseValue=pn(Z1,s,$t),ge.selectionStart=ge.selectionEnd=ge.currentLooseValue.length;break}case 110:{const M1=Ot.current,Z1=$t.numberSymbols();M1&&(ge.currentLooseValue=ge.currentLooseValue.slice(0,ge.selectionStart)+Z1.decimal+ge.currentLooseValue.slice(ge.selectionEnd),ge.selectionStart=ge.selectionEnd=ge.selectionStart+1,ge=kE(ge,s,$t));break}default:return}Le.preventDefault(),Vt(Le,ge)},[s,b,z,ft,kt,Mt,Vt,Rt]),je=_.useCallback(()=>{Kt.current=!0},[]),ke=_.useCallback(Le=>{if(G||ht)return;const ge=Rt();wE($t.parseNumber(String(ge.currentLooseValue),s),ge,ft,b,z,s,$t),Vt(Le,ge)},[s,b,z,ft,kt,G,ht,Vt,Rt]),c1=_.useCallback(Le=>{if(G||ht)return;const ge=Rt();CE($t.parseNumber(String(ge.currentLooseValue),s),ge,ft,b,z,s,$t),Vt(Le,ge)},[s,b,z,ft,kt,G,ht,Vt,Rt]),Oe=_.useCallback(Le=>{const ge=Ki(document);!document||ge!==Ot.current||!Ot.current||G||ht||(Le.nativeEvent.deltaY<0&&ke(Le),Le.nativeEvent.deltaY>0&&c1(Le))},[ke,c1,ht,G]),Tt=_.useCallback(Le=>{Se.current.currentLooseValue=fe.current,Se.current.focused=!0,fn(_t,Le,zt(),{}),se(ge=>!ge)},[_t,se,zt]),te=_.useCallback(Le=>{Se.current=xE(),fn(bt,Le,zt(),{}),se(ge=>!ge)},[bt,se,zt]),Ve=_.useCallback(Le=>{if(document&&Ot.current){const ge=Ki(document);Le.preventDefault(),ge!==Ot.current&&Ot.current.focus()}},[]);yb(()=>{Ot.current&&Ot.current.type!=="number"&&Se.current.selectionStart!==void 0&&Se.current.selectionEnd!==void 0&&(Ot.current.selectionStart=Se.current.selectionStart,Ot.current.selectionEnd=Se.current.selectionEnd,Se.current.selectionStart=void 0,Se.current.selectionEnd=void 0)},[Ht]);const He=!st()||Yt().valid,d1=_.createElement("span",{dir:M,style:F?et:{width:l,...et},className:Me("k-input","k-numerictextbox",{[`k-input-${Gr.sizeMap[At]||At}`]:At,[`k-input-${Bt}`]:Bt,[`k-rounded-${Gr.roundedMap[Ft]||Ft}`]:Ft,"k-invalid":!He,"k-required":lt,"k-disabled":ht},i),"aria-disabled":ht?"true":void 0,...F?{}:Xt},_.createElement(xe,null),_.createElement("input",{role:"spinbutton",value:ce===null?"":ce,tabIndex:XP(h,ht),accessKey:p,disabled:ht,title:f,"aria-disabled":ht?"true":void 0,"aria-valuemin":b,"aria-valuemax":z,"aria-label":W,"aria-labelledby":R,"aria-describedby":E,placeholder:g,spellCheck:!1,autoComplete:"off",autoCorrect:"off",autoFocus:Ut,type:$||"tel",className:"k-input-inner",id:ae,name:I,readOnly:G,style:at,onChange:Qt,onFocus:Tt,onBlur:te,onKeyDown:ve,onPaste:je,onWheel:Oe,ref:Ot}),_.createElement(Wt,null),K,dt&&_.createElement("span",{className:"k-input-spinner k-spin-button",onMouseDown:Ve},_.createElement(ei,{tabIndex:-1,type:"button",icon:"caret-alt-up",svgIcon:uC,rounded:null,fillMode:Bt,className:"k-spinner-increase","aria-label":ue.toLanguageString(fc,Qh[fc]),title:ue.toLanguageString(fc,Qh[fc]),onClick:ke}),_.createElement(ei,{tabIndex:-1,type:"button",icon:"caret-alt-down",svgIcon:Y0,rounded:null,fillMode:Bt,className:"k-spinner-decrease","aria-label":ue.toLanguageString(vc,Qh[vc]),title:ue.toLanguageString(vc,Qh[vc]),onClick:c1})));return F?_.createElement(v5,{label:F,editorId:ae,editorValue:ce===null?"":ce,editorValid:He,editorDisabled:ht,editorPlaceholder:g,children:d1,style:{width:l},dir:M,...Xt}):d1});g5.propTypes={value:B.number,defaultValue:B.number,step:B.number,format:B.oneOfType([B.string,B.shape({style:B.oneOf(["decimal","currency","percent","scientific","accounting"]),currency:B.string,currencyDisplay:B.oneOf(["symbol","code","name"]),useGrouping:B.bool,minimumIntegerDigits:B.number,minimumFractionDigits:B.number,maximumFractionDigits:B.number})]),width:B.oneOfType([B.string,B.number]),tabIndex:B.number,accessKey:B.string,title:B.string,placeholder:B.string,min:B.number,max:B.number,spinners:B.bool,disabled:B.bool,readOnly:B.bool,dir:B.string,name:B.string,label:B.string,validationMessage:B.string,required:B.bool,id:B.string,rangeOnEnter:B.bool,ariaLabelledBy:B.string,ariaDescribedBy:B.string,ariaLabel:B.string,onChange:B.func,onFocus:B.func,onBlur:B.func,size:B.oneOf([null,"small","medium","large"]),rounded:B.oneOf([null,"small","medium","large","full"]),fillMode:B.oneOf([null,"solid","flat","outline"])};const cn={prefix:t=>null,suffix:t=>null,step:1,spinners:!0,disabled:!1,required:!1,validityStyles:!0,rangeOnEnter:!0,autoFocus:!1,onChange:t=>{},onFocus:t=>{},onBlur:t=>{},size:"medium",rounded:"medium",fillMode:"solid"};g5.displayName="KendoNumericTextBox";/** + */const yBt="Please enter a valid value!",xBt=R8(),g5=_.forwardRef((t,r)=>{vi(JO);const n=eT(xBt,t),{className:i,value:o,defaultValue:a,format:s,width:l,tabIndex:h,accessKey:p,title:f,placeholder:g,min:b,max:z,dir:M,name:I,label:F,id:H,ariaDescribedBy:E,ariaLabelledBy:R,ariaLabel:W,inputType:$,readOnly:G,validationMessage:Z,children:K,style:et,inputStyle:at,valid:tt,step:ft=sn.step,spinners:dt=sn.spinners,disabled:ht=sn.disabled,required:lt=sn.required,validityStyles:yt=sn.validityStyles,prefix:mt=sn.prefix,suffix:gt=sn.suffix,onChange:_t=sn.onChange,onFocus:At=sn.onFocus,onBlur:bt=sn.onBlur,rangeOnEnter:kt=sn.rangeOnEnter,size:Lt=sn.size,rounded:Vt=sn.rounded,fillMode:Rt=sn.fillMode,autoFocus:Ut=sn.autoFocus,...Kt}=n,It=pp(),le=H||It,Bt=aT(),de=jl(),Ft=_.useRef(null),we=_.useRef(),[Ht,ce]=_.useState(!1),Se=_.useRef(bE()),qt=_.useRef(!1),ge=_.useRef(),oe=_.useRef(a),ue=hn(Se.current.focused&&!ht?Se.current.currentLooseValue:Iv(o,oe.current),s,Bt);ge.current=ue;const[xe]=Vu(mt),[Nt]=Vu(gt);_.useEffect(()=>{Ft.current&&Ft.current.setCustomValidity&&Ft.current.setCustomValidity(Xt().valid?"":Z||yBt)});const Jt=_.useCallback(()=>{Ft.current&&Ft.current.focus()},[]),Ie=_.useCallback(()=>we.current!==void 0?we.current:Iv(o,oe.current),[o]),He=_.useCallback(()=>I,[I]),Pe=_.useCallback(()=>lt,[lt]),Xt=_.useCallback(()=>{const Oe=Z!==void 0,Ae=Ie(),E1=tt!==void 0?tt:!Se.current.valueIsOutOfRange&&(!Pe()||Ae!=null);return{customError:Oe,valid:E1,valueMissing:Ae==null}},[Z,tt,Ie,Pe]),st=_.useCallback(()=>yt,[yt]),Mt=_.useCallback(()=>n,[n]),wt=_.useCallback(()=>{const Oe={element:Ft.current,focus:Jt};return Object.defineProperty(Oe,"name",{get:He}),Object.defineProperty(Oe,"value",{get:Ie}),Object.defineProperty(Oe,"validity",{get:Xt}),Object.defineProperty(Oe,"validityStyles",{get:st}),Object.defineProperty(Oe,"required",{get:Pe}),Object.defineProperty(Oe,"props",{get:Mt}),Oe},[He,Ie,Xt,st,Pe,Jt,Mt]);_.useImperativeHandle(r,wt);const Pt=_.useCallback(()=>({eventValue:Iv(o,oe.current),prevLooseValue:ge.current,currentLooseValue:Ft.current.value,selectionStart:Ft.current.selectionStart,selectionEnd:Ft.current.selectionEnd,decimalSelect:!1,valueIsCorrected:!1,valueIsOutOfRange:!1,isPaste:qt.current,focused:Se.current.focused}),[o]),Yt=_.useCallback((Oe,Ae)=>{if(ht)return;we.current=Ae.eventValue,oe.current=Ae.eventValue;const E1=hn(Z3(Ae.eventValue,b,z),s,Bt),ur=Z3(Bt.parseNumber(E1,s),b,z);ur!==Ae.eventValue&&(Ae.valueIsOutOfRange=!0,Ae.eventValue=ur,oe.current=ur),o!==Ae.eventValue&&pn(_t,Oe,wt(),{value:Ae.eventValue}),we.current=void 0,Se.current=Ae,ce(Qr=>!Qr)},[o,_t,ht,ce,wt]),Zt=_.useCallback(Oe=>{const Ae=Pt();qt.current=!1,Yt(Oe,_E(Ae,s,Bt))},[s,_t,Bt,Yt,Pt]),ae=_.useCallback(Oe=>{let Ae=Pt();const E1=Bt.parseNumber(String(Ae.currentLooseValue),s);if(Ae.selectionEnd>Ae.selectionStart&&Ae.selectionEnd-Ae.selectionStart===String(Ae.currentLooseValue).length){const ur=Bt.numberSymbols(),Qr=ur&&Oe.key===ur.minusSign,ti=ur&&Oe.key===ur.decimal;qt.current=!Qr&&!ti;return}switch(Oe.keyCode){case 38:CE(E1,Ae,ft,b,z,s,Bt);break;case 40:SE(E1,Ae,ft,b,z,s,Bt);break;case 13:{if(kt===!1)return;const ur=hn(Z3(E1,b,z),s,Bt),Qr=Z3(Bt.parseNumber(ur,s),b,z);Ae.eventValue=Qr,Ae.currentLooseValue=hn(Qr,s,Bt),Ae.selectionStart=Ae.selectionEnd=Ae.currentLooseValue.length;break}case 110:{const ur=Ft.current,Qr=Bt.numberSymbols();ur&&(Ae.currentLooseValue=Ae.currentLooseValue.slice(0,Ae.selectionStart)+Qr.decimal+Ae.currentLooseValue.slice(Ae.selectionEnd),Ae.selectionStart=Ae.selectionEnd=Ae.selectionStart+1,Ae=_E(Ae,s,Bt));break}default:return}Oe.preventDefault(),Yt(Oe,Ae)},[s,b,z,ft,_t,kt,Yt,Pt]),ee=_.useCallback(()=>{qt.current=!0},[]),jt=_.useCallback(Oe=>{if(G||ht)return;const Ae=Pt();CE(Bt.parseNumber(String(Ae.currentLooseValue),s),Ae,ft,b,z,s,Bt),Yt(Oe,Ae)},[s,b,z,ft,_t,G,ht,Yt,Pt]),_e=_.useCallback(Oe=>{if(G||ht)return;const Ae=Pt();SE(Bt.parseNumber(String(Ae.currentLooseValue),s),Ae,ft,b,z,s,Bt),Yt(Oe,Ae)},[s,b,z,ft,_t,G,ht,Yt,Pt]),ze=_.useCallback(Oe=>{const Ae=Yi(document);!document||Ae!==Ft.current||!Ft.current||G||ht||(Oe.nativeEvent.deltaY<0&&jt(Oe),Oe.nativeEvent.deltaY>0&&_e(Oe))},[jt,_e,ht,G]),Gt=_.useCallback(Oe=>{Se.current.currentLooseValue=ge.current,Se.current.focused=!0,pn(At,Oe,wt(),{}),ce(Ae=>!Ae)},[At,ce,wt]),Re=_.useCallback(Oe=>{Se.current=bE(),pn(bt,Oe,wt(),{}),ce(Ae=>!Ae)},[bt,ce,wt]),je=_.useCallback(Oe=>{if(document&&Ft.current){const Ae=Yi(document);Oe.preventDefault(),Ae!==Ft.current&&Ft.current.focus()}},[]);xb(()=>{Ft.current&&Ft.current.type!=="number"&&Se.current.selectionStart!==void 0&&Se.current.selectionEnd!==void 0&&(Ft.current.selectionStart=Se.current.selectionStart,Ft.current.selectionEnd=Se.current.selectionEnd,Se.current.selectionStart=void 0,Se.current.selectionEnd=void 0)},[Ht]);const d1=!st()||Xt().valid,K1=_.createElement("span",{dir:M,style:F?et:{width:l,...et},className:ke("k-input","k-numerictextbox",{[`k-input-${Wr.sizeMap[Lt]||Lt}`]:Lt,[`k-input-${Rt}`]:Rt,[`k-rounded-${Wr.roundedMap[Vt]||Vt}`]:Vt,"k-invalid":!d1,"k-required":lt,"k-disabled":ht},i),"aria-disabled":ht?"true":void 0,...F?{}:Kt},_.createElement(xe,null),_.createElement("input",{role:"spinbutton",value:ue===null?"":ue,tabIndex:KP(h,ht),accessKey:p,disabled:ht,title:f,"aria-disabled":ht?"true":void 0,"aria-valuemin":b,"aria-valuemax":z,"aria-label":W,"aria-labelledby":R,"aria-describedby":E,placeholder:g,spellCheck:!1,autoComplete:"off",autoCorrect:"off",autoFocus:Ut,type:$||"tel",className:"k-input-inner",id:le,name:I,readOnly:G,style:at,onChange:Zt,onFocus:Gt,onBlur:Re,onKeyDown:ae,onPaste:ee,onWheel:ze,ref:Ft}),_.createElement(Nt,null),K,dt&&_.createElement("span",{className:"k-input-spinner k-spin-button",onMouseDown:je},_.createElement(Jr,{tabIndex:-1,type:"button",icon:"caret-alt-up",svgIcon:pC,rounded:null,fillMode:Rt,className:"k-spinner-increase","aria-label":de.toLanguageString(fc,Qh[fc]),title:de.toLanguageString(fc,Qh[fc]),onClick:jt}),_.createElement(Jr,{tabIndex:-1,type:"button",icon:"caret-alt-down",svgIcon:Y0,rounded:null,fillMode:Rt,className:"k-spinner-decrease","aria-label":de.toLanguageString(vc,Qh[vc]),title:de.toLanguageString(vc,Qh[vc]),onClick:_e})));return F?_.createElement(v5,{label:F,editorId:le,editorValue:ue===null?"":ue,editorValid:d1,editorDisabled:ht,editorPlaceholder:g,children:K1,style:{width:l},dir:M,...Kt}):K1});g5.propTypes={value:B.number,defaultValue:B.number,step:B.number,format:B.oneOfType([B.string,B.shape({style:B.oneOf(["decimal","currency","percent","scientific","accounting"]),currency:B.string,currencyDisplay:B.oneOf(["symbol","code","name"]),useGrouping:B.bool,minimumIntegerDigits:B.number,minimumFractionDigits:B.number,maximumFractionDigits:B.number})]),width:B.oneOfType([B.string,B.number]),tabIndex:B.number,accessKey:B.string,title:B.string,placeholder:B.string,min:B.number,max:B.number,spinners:B.bool,disabled:B.bool,readOnly:B.bool,dir:B.string,name:B.string,label:B.string,validationMessage:B.string,required:B.bool,id:B.string,rangeOnEnter:B.bool,ariaLabelledBy:B.string,ariaDescribedBy:B.string,ariaLabel:B.string,onChange:B.func,onFocus:B.func,onBlur:B.func,size:B.oneOf([null,"small","medium","large"]),rounded:B.oneOf([null,"small","medium","large","full"]),fillMode:B.oneOf([null,"solid","flat","outline"])};const sn={prefix:t=>null,suffix:t=>null,step:1,spinners:!0,disabled:!1,required:!1,validityStyles:!0,rangeOnEnter:!0,autoFocus:!1,onChange:t=>{},onFocus:t=>{},onBlur:t=>{},size:"medium",rounded:"medium",fillMode:"solid"};g5.displayName="KendoNumericTextBox";/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const nd=_.forwardRef((t,r)=>{gi(ZO);const n=_.useRef(null),i=_.useRef(null),o=_.useRef(),a=_.useCallback(()=>{var dt;return o.current!==void 0?o.current:(dt=n.current)==null?void 0:dt.value},[]);_.useImperativeHandle(i,()=>({get element(){return n.current},get name(){return n.current&&n.current.name},get value(){return a()}})),_.useImperativeHandle(r,()=>i.current);const{size:s=b3.size,fillMode:l=b3.fillMode,rounded:h=b3.rounded,autoFocus:p=b3.autoFocus,className:f,dir:g,style:b,prefix:z=b3.prefix,suffix:M=b3.suffix,valid:I,modified:F,touched:H,visited:E,...R}=t,[W]=Vu(z),[$]=Vu(M),[G,Z]=_.useState(!1),K=dt=>{Z(!0)},et=dt=>{Z(!1)},at=_.useCallback(dt=>{o.current=dt.target.value,t.onChange&&t.onChange.call(void 0,{syntheticEvent:dt,nativeEvent:dt.nativeEvent,value:dt.target.value,target:i.current}),o.current=void 0},[t.onChange]),{onFocus:tt,onBlur:ft}=JP({onFocus:K,onBlur:et,onSyncFocus:t.onFocus,onSyncBlur:t.onBlur});return _.createElement("span",{style:b,dir:g,className:Me("k-textbox k-input",{[`k-input-${Gr.sizeMap[s]||s}`]:s,[`k-input-${l}`]:l,[`k-rounded-${Gr.roundedMap[h]||h}`]:h},{"k-focus":G,"k-required":t.required,"k-disabled":t.disabled,"k-invalid":t.valid===!1},f),onFocus:tt,onBlur:ft},_.createElement(W,null),_.createElement("input",{ref:n,className:"k-input-inner",autoFocus:p,...R,onChange:at}),_.createElement($,null))}),b3={prefix:t=>null,suffix:t=>null,size:"medium",rounded:"medium",fillMode:"solid",autoFocus:!1};nd.propTypes={size:B.oneOf([null,"small","medium","large"]),rounded:B.oneOf([null,"small","medium","large","full"]),fillMode:B.oneOf([null,"solid","flat","outline"]),autoFocus:B.bool};nd.displayName="KendoReactTextBoxComponent";/** + */const nd=_.forwardRef((t,r)=>{vi(JO);const n=_.useRef(null),i=_.useRef(null),o=_.useRef(),a=_.useCallback(()=>{var dt;return o.current!==void 0?o.current:(dt=n.current)==null?void 0:dt.value},[]);_.useImperativeHandle(i,()=>({get element(){return n.current},get name(){return n.current&&n.current.name},get value(){return a()}})),_.useImperativeHandle(r,()=>i.current);const{size:s=b3.size,fillMode:l=b3.fillMode,rounded:h=b3.rounded,autoFocus:p=b3.autoFocus,className:f,dir:g,style:b,prefix:z=b3.prefix,suffix:M=b3.suffix,valid:I,modified:F,touched:H,visited:E,...R}=t,[W]=Vu(z),[$]=Vu(M),[G,Z]=_.useState(!1),K=dt=>{Z(!0)},et=dt=>{Z(!1)},at=_.useCallback(dt=>{o.current=dt.target.value,t.onChange&&t.onChange.call(void 0,{syntheticEvent:dt,nativeEvent:dt.nativeEvent,value:dt.target.value,target:i.current}),o.current=void 0},[t.onChange]),{onFocus:tt,onBlur:ft}=QP({onFocus:K,onBlur:et,onSyncFocus:t.onFocus,onSyncBlur:t.onBlur});return _.createElement("span",{style:b,dir:g,className:ke("k-textbox k-input",{[`k-input-${Wr.sizeMap[s]||s}`]:s,[`k-input-${l}`]:l,[`k-rounded-${Wr.roundedMap[h]||h}`]:h},{"k-focus":G,"k-required":t.required,"k-disabled":t.disabled,"k-invalid":t.valid===!1},f),onFocus:tt,onBlur:ft},_.createElement(W,null),_.createElement("input",{ref:n,className:"k-input-inner",autoFocus:p,...R,onChange:at}),_.createElement($,null))}),b3={prefix:t=>null,suffix:t=>null,size:"medium",rounded:"medium",fillMode:"solid",autoFocus:!1};nd.propTypes={size:B.oneOf([null,"small","medium","large"]),rounded:B.oneOf([null,"small","medium","large","full"]),fillMode:B.oneOf([null,"solid","flat","outline"]),autoFocus:B.bool};nd.displayName="KendoReactTextBoxComponent";/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const iB=_.forwardRef(({orientation:t="horizontal",...r},n)=>{const i=_.useRef(null),o=_.useRef(null);return _.useImperativeHandle(i,()=>({element:o.current})),_.useImperativeHandle(n,()=>i.current),_.createElement("span",{...r,className:Me("k-input-prefix",r.className,`k-input-prefix-${t}`)})});iB.displayName="KendoReactInputPrefix";/** + */const nB=_.forwardRef(({orientation:t="horizontal",...r},n)=>{const i=_.useRef(null),o=_.useRef(null);return _.useImperativeHandle(i,()=>({element:o.current})),_.useImperativeHandle(n,()=>i.current),_.createElement("span",{...r,className:ke("k-input-prefix",r.className,`k-input-prefix-${t}`)})});nB.displayName="KendoReactInputPrefix";/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const nB=_.forwardRef(({orientation:t="vertical",...r},n)=>{const i=_.useRef(null),o=_.useRef(null);return _.useImperativeHandle(i,()=>({element:o.current})),_.useImperativeHandle(n,()=>i.current),_.createElement("span",{...r,className:Me("k-input-separator",r.className,`k-input-separator-${t}`)})});nB.displayName="KendoReactInputSeparator";/** + */const oB=_.forwardRef(({orientation:t="vertical",...r},n)=>{const i=_.useRef(null),o=_.useRef(null);return _.useImperativeHandle(i,()=>({element:o.current})),_.useImperativeHandle(n,()=>i.current),_.createElement("span",{...r,className:ke("k-input-separator",r.className,`k-input-separator-${t}`)})});oB.displayName="KendoReactInputSeparator";/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let oB=class extends _.Component{constructor(){super(...arguments),this.state={page:this.props.currentPage},this.handleOnChange=r=>{this.setState({page:r.target.value}),r.target.value&&this.props.pageChange(r.target.value,r)}}render(){const r=Ka(this),n=si(this),i=this.props.messagesMap?this.props.messagesMap(Xo):{messageKey:Xo,defaultMessage:xi[Xo]},o=this.props.messagesMap?this.props.messagesMap(g0):{messageKey:g0,defaultMessage:xi[g0]},a=this.props.messagesMap?this.props.messagesMap(Ws):{messageKey:Ws,defaultMessage:xi[Ws]},s=this.props.messagesMap?this.props.messagesMap(Ws):{messageKey:dy,defaultMessage:xi[dy]};return _.createElement("span",{className:"k-pager-input"},_.createElement("span",null,n.toLanguageString(i.messageKey,i.defaultMessage)),_.createElement(g5,{value:this.props.currentPage!==void 0?this.props.currentPage:this.state.page,onChange:this.handleOnChange,min:1,spinners:!1,ariaLabel:n.toLanguageString(s.messageKey,s.defaultMessage),tabIndex:this.props.navigatable?-1:void 0}),_.createElement("span",null,`${n.toLanguageString(o.messageKey,o.defaultMessage)} ${r.format(n.toLanguageString(a.messageKey,a.defaultMessage),[this.props.totalPages])}`))}};Ri(oB);/** + */let aB=class extends _.Component{constructor(){super(...arguments),this.state={page:this.props.currentPage},this.handleOnChange=r=>{this.setState({page:r.target.value}),r.target.value&&this.props.pageChange(r.target.value,r)}}render(){const r=Xa(this),n=ai(this),i=this.props.messagesMap?this.props.messagesMap(Uo):{messageKey:Uo,defaultMessage:yi[Uo]},o=this.props.messagesMap?this.props.messagesMap(g0):{messageKey:g0,defaultMessage:yi[g0]},a=this.props.messagesMap?this.props.messagesMap(Ws):{messageKey:Ws,defaultMessage:yi[Ws]},s=this.props.messagesMap?this.props.messagesMap(Ws):{messageKey:dy,defaultMessage:yi[dy]};return _.createElement("span",{className:"k-pager-input"},_.createElement("span",null,n.toLanguageString(i.messageKey,i.defaultMessage)),_.createElement(g5,{value:this.props.currentPage!==void 0?this.props.currentPage:this.state.page,onChange:this.handleOnChange,min:1,spinners:!1,ariaLabel:n.toLanguageString(s.messageKey,s.defaultMessage),tabIndex:this.props.navigatable?-1:void 0}),_.createElement("span",null,`${n.toLanguageString(o.messageKey,o.defaultMessage)} ${r.format(n.toLanguageString(a.messageKey,a.defaultMessage),[this.props.totalPages])}`))}};Vi(aB);/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let xBt=class extends _.Component{render(){const{children:r,width:n,dir:i,itemsCount:o,popupSettings:a}=this.props;return _.createElement(A4,{style:{width:n,direction:i},contentKey:o&&o.join(),...a},r)}};/** + */let bBt=class extends _.Component{render(){const{children:r,width:n,dir:i,itemsCount:o,popupSettings:a}=this.props;return _.createElement(A4,{style:{width:n,direction:i},contentKey:o&&o.join(),...a},r)}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const wC=_.forwardRef((t,r)=>{const n=_.useRef(null),{renderListFilterWrapper:i=!1,renderPrefixSeparator:o=!1,...a}=t;_.useImperativeHandle(r,()=>n.current);const s=()=>_.createElement(_.Fragment,null,_.createElement(iB,null,_.createElement(en,{name:"search",icon:kVt,className:"k-input-icon"})),o&&_.createElement(nB,null)),l=_.createElement(nd,{...a,ref:n,className:"k-searchbox",value:t.value||"",onChange:t.onChange,onKeyDown:t.onKeyDown,tabIndex:t.tabIndex,onClick:h=>h.stopPropagation(),size:t.size,fillMode:t.fillMode,rounded:t.rounded,prefix:s});return i?_.createElement("div",{className:"k-list-filter"}," ",l," "):l});wC.propTypes={value:B.oneOfType([B.string,B.number,B.array]),tabIndex:B.number,onChange:B.func,onKeyDown:B.func,size:B.oneOf([null,"small","medium","large"]),rounded:B.oneOf([null,"small","medium","large","full"]),fillMode:B.oneOf([null,"solid","flat","outline"]),renderListFilterWrapper:B.bool,renderPrefixSeparator:B.bool};wC.displayName="KendoReactListFilter";const bBt=wC;/** + */const CC=_.forwardRef((t,r)=>{const n=_.useRef(null),{renderListFilterWrapper:i=!1,renderPrefixSeparator:o=!1,...a}=t;_.useImperativeHandle(r,()=>n.current);const s=()=>_.createElement(_.Fragment,null,_.createElement(nB,null,_.createElement(Qi,{name:"search",icon:_Vt,className:"k-input-icon"})),o&&_.createElement(oB,null)),l=_.createElement(nd,{...a,ref:n,className:"k-searchbox",value:t.value||"",onChange:t.onChange,onKeyDown:t.onKeyDown,tabIndex:t.tabIndex,onClick:h=>h.stopPropagation(),size:t.size,fillMode:t.fillMode,rounded:t.rounded,prefix:s});return i?_.createElement("div",{className:"k-list-filter"}," ",l," "):l});CC.propTypes={value:B.oneOfType([B.string,B.number,B.array]),tabIndex:B.number,onChange:B.func,onKeyDown:B.func,size:B.oneOf([null,"small","medium","large"]),rounded:B.oneOf([null,"small","medium","large","full"]),fillMode:B.oneOf([null,"solid","flat","outline"]),renderListFilterWrapper:B.bool,renderPrefixSeparator:B.bool};CC.displayName="KendoReactListFilter";const wBt=CC;/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let _E=class extends _.Component{render(){const{group:r,groupMode:n,render:i}=this.props,o=_.createElement("div",{className:"k-list-group-sticky-header"},n==="classic"?r:_.createElement("div",{className:"k-list-header-text"},r));return i!==void 0?i.call(void 0,o,this.props):o}};/** + */let AE=class extends _.Component{render(){const{group:r,groupMode:n,render:i}=this.props,o=_.createElement("div",{className:"k-list-group-sticky-header"},n==="classic"?r:_.createElement("div",{className:"k-list-header-text"},r));return i!==void 0?i.call(void 0,o,this.props):o}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const H0=t=>t!=null,wBt=(t,r)=>{for(let n=0;n{let i=t;return n&&(i=[n].concat(i)),i.slice(r).concat(i.slice(0,r))},AE=(t,r,n)=>{if(!H0(t))return!1;let i=String(t);return n&&(i=i.toLowerCase()),i.indexOf(r)===0},SBt=(t,r,n,i,o)=>{const a=t.offsetHeight,s=r.children.item(n),l=s.offsetTop+(o?i-t.scrollTop:0),h=s.offsetHeight;if(o){let p=0;l+h>a?p=l+h-a:l<0&&(p=l),p!==0?t.scrollTop+=p:t.scrollTop===0&&i!==0&&(t.scrollTop=i)}else l+h>a+t.scrollTop?t.scrollTop=l+h-a:l{let i=-1;if(r){r=r.toLowerCase();for(let o=0;o{if(r&&H0(t)){const n=r.split(".");let i=t;return n.forEach(o=>{i=i?i[o]:void 0}),i}return t},Gi=(t,r,n)=>t===r||H0(t)===H0(r)&&po(t,n)===po(r,n);/** + */const H0=t=>t!=null,CBt=(t,r)=>{for(let n=0;n{let i=t;return n&&(i=[n].concat(i)),i.slice(r).concat(i.slice(0,r))},LE=(t,r,n)=>{if(!H0(t))return!1;let i=String(t);return n&&(i=i.toLowerCase()),i.indexOf(r)===0},zBt=(t,r,n,i,o)=>{const a=t.offsetHeight,s=r.children.item(n),l=s.offsetTop+(o?i-t.scrollTop:0),h=s.offsetHeight;if(o){let p=0;l+h>a?p=l+h-a:l<0&&(p=l),p!==0?t.scrollTop+=p:t.scrollTop===0&&i!==0&&(t.scrollTop=i)}else l+h>a+t.scrollTop?t.scrollTop=l+h-a:l{let i=-1;if(r){r=r.toLowerCase();for(let o=0;o{if(r&&H0(t)){const n=r.split(".");let i=t;return n.forEach(o=>{i=i?i[o]:void 0}),i}return t},Wi=(t,r,n)=>t===r||H0(t)===H0(r)&&lo(t,n)===lo(r,n);/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const MBt=t=>t.preventDefault();let kBt=class extends _.Component{render(){const{selected:r,defaultItem:n,textField:i}=this.props;return _.createElement("div",{onClick:this.props.onClick,onMouseDown:MBt,style:{position:"unset"},className:Me("k-list-optionlabel",{"k-selected":r})},po(n,i)||"")}};/** + */const kBt=t=>t.preventDefault();let _Bt=class extends _.Component{render(){const{selected:r,defaultItem:n,textField:i}=this.props;return _.createElement("div",{onClick:this.props.onClick,onMouseDown:kBt,style:{position:"unset"},className:ke("k-list-optionlabel",{"k-selected":r})},lo(n,i)||"")}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let _Bt=class extends _.Component{constructor(){super(...arguments),this.handleClick=r=>this.props.onClick(this.props.index,r)}render(){const{selected:r,group:n,dataItem:i,virtual:o,groupMode:a,disabled:s,render:l}=this.props,h=_.createElement("li",{id:this.props.id,role:"option","aria-selected":r,"aria-disabled":s?!0:void 0,className:Me("k-list-item",{"k-selected":r,"k-focus":this.props.focused,"k-first":!!n&&a==="classic","k-disabled":s}),onClick:this.handleClick,style:{position:o?"relative":"unset"}},_.createElement("span",{className:"k-list-item-text"},po(i,this.props.textField).toString()),n!==void 0&&a==="classic"?_.createElement("div",{className:"k-list-item-group-label"},n):null);return l!==void 0?l.call(void 0,h,this.props):h}};/** + */let ABt=class extends _.Component{constructor(){super(...arguments),this.handleClick=r=>this.props.onClick(this.props.index,r)}render(){const{selected:r,group:n,dataItem:i,virtual:o,groupMode:a,disabled:s,render:l}=this.props,h=_.createElement("li",{id:this.props.id,role:"option","aria-selected":r,"aria-disabled":s?!0:void 0,className:ke("k-list-item",{"k-selected":r,"k-focus":this.props.focused,"k-first":!!n&&a==="classic","k-disabled":s}),onClick:this.handleClick,style:{position:o?"relative":"unset"}},_.createElement("span",{className:"k-list-item-text"},lo(i,this.props.textField).toString()),n!==void 0&&a==="classic"?_.createElement("div",{className:"k-list-item-group-label"},n):null);return l!==void 0?l.call(void 0,h,this.props):h}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let ABt=class extends _.Component{render(){const{group:r,virtual:n,render:i,isMultiColumn:o=!1}=this.props,a=_.createElement("li",{id:this.props.id,role:"group",className:o?"k-table-group-row":"k-list-group-item",style:o?{boxSizing:"inherit"}:{position:n?"relative":"unset"}},_.createElement("span",{className:i?void 0:o?"k-table-th":"k-list-item-text"},r));return i!==void 0?i.call(void 0,a,this.props):a}};/** + */let LBt=class extends _.Component{render(){const{group:r,virtual:n,render:i,isMultiColumn:o=!1}=this.props,a=_.createElement("li",{id:this.props.id,role:"group",className:o?"k-table-group-row":"k-list-group-item",style:o?{boxSizing:"inherit"}:{position:n?"relative":"unset"}},_.createElement("span",{className:i?void 0:o?"k-table-th":"k-list-item-text"},r));return i!==void 0?i.call(void 0,a,this.props):a}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const gy="dropdowns.nodata",LBt="dropdowns.clear",EBt="dropdowns.comboArrowBtnAriaLabelExpand",IBt="dropdowns.comboArrowBtnAriaLabelCollapse",my="dropdowns.dropDownListArrowBtnAriaLabel",HBt="dropdowns.apply",DBt="dropdowns.cancel",aB={[LBt]:"clear",[gy]:"NO DATA FOUND.",[EBt]:"expand combobox",[IBt]:"collapse combobox",[my]:"select",[HBt]:"Apply",[DBt]:"Cancel"};/** + */const gy="dropdowns.nodata",EBt="dropdowns.clear",IBt="dropdowns.comboArrowBtnAriaLabelExpand",HBt="dropdowns.comboArrowBtnAriaLabelCollapse",my="dropdowns.dropDownListArrowBtnAriaLabel",DBt="dropdowns.apply",PBt="dropdowns.cancel",sB={[EBt]:"clear",[gy]:"NO DATA FOUND.",[IBt]:"expand combobox",[HBt]:"collapse combobox",[my]:"select",[DBt]:"Apply",[PBt]:"Cancel"};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let sB=class extends _.Component{renderItems(){const{textField:r,valueField:n,groupField:i,groupMode:o,isMultiColumn:a,optionsGuid:s,skip:l=0,virtual:h,focusedIndex:p,hasDuplicates:f,highlightSelected:g=!0,value:b,data:z,itemRender:M,groupHeaderItemRender:I}=this.props,F=Array.isArray(b);let H=0;return z.map((E,R)=>{const W=l+R,$=l+R+H,G=f?b?p===R:!1:E.disabled?!1:g&&(!F&&Gi(E,b,n)||F&&b.findIndex(at=>Gi(at,E,n))!==-1);let Z,K,et;return R>0&&i!==void 0&&(K=po(E,i),et=po(z[R-1],i),K&&et&&K!==et&&(Z=K)),Z!==void 0&&o==="modern"&&(H+=1),[Z!==void 0&&o==="modern"&&_.createElement(ABt,{id:`option-${s}-${$}`,virtual:h,key:W+"-group-item",group:Z,isMultiColumn:a,render:I}),_.createElement(_Bt,{id:`option-${s}-${Z!==void 0&&o==="modern"?$+1:$}`,virtual:h,dataItem:E,groupMode:o,selected:G,focused:p===R,index:W,key:W,onClick:this.props.onClick,textField:r,group:Z,render:M,disabled:E.disabled})]})}renderNoValueElement(r){const n=this.props.noDataRender,i=_.createElement("div",{className:"k-nodata"},_.createElement("div",null,r.toLanguageString(gy,aB[gy])));return n?n.call(void 0,i):i}render(){const r=si(this),{id:n,show:i,wrapperCssClass:o,wrapperStyle:a,listStyle:s,listRef:l,wrapperRef:h,listClassName:p="k-list-ul",ariaSetSize:f}=this.props,g=this.renderItems();return g.length?_.createElement("div",{className:o,style:a,ref:h,onMouseDown:this.props.onMouseDown,onBlur:this.props.onBlur,onScroll:this.props.onScroll,unselectable:"on"},_.createElement("ul",{id:n,role:"listbox","aria-hidden":i?void 0:!0,"aria-setsize":f,className:p,ref:l,style:s},g),this.props.scroller&&_.createElement("div",{className:"k-height-container"},this.props.scroller)):this.renderNoValueElement(r)}};Ri(sB);/** + */let lB=class extends _.Component{renderItems(){const{textField:r,valueField:n,groupField:i,groupMode:o,isMultiColumn:a,optionsGuid:s,skip:l=0,virtual:h,focusedIndex:p,hasDuplicates:f,highlightSelected:g=!0,value:b,data:z,itemRender:M,groupHeaderItemRender:I}=this.props,F=Array.isArray(b);let H=0;return z.map((E,R)=>{const W=l+R,$=l+R+H,G=f?b?p===R:!1:E.disabled?!1:g&&(!F&&Wi(E,b,n)||F&&b.findIndex(at=>Wi(at,E,n))!==-1);let Z,K,et;return R>0&&i!==void 0&&(K=lo(E,i),et=lo(z[R-1],i),K&&et&&K!==et&&(Z=K)),Z!==void 0&&o==="modern"&&(H+=1),[Z!==void 0&&o==="modern"&&_.createElement(LBt,{id:`option-${s}-${$}`,virtual:h,key:W+"-group-item",group:Z,isMultiColumn:a,render:I}),_.createElement(ABt,{id:`option-${s}-${Z!==void 0&&o==="modern"?$+1:$}`,virtual:h,dataItem:E,groupMode:o,selected:G,focused:p===R,index:W,key:W,onClick:this.props.onClick,textField:r,group:Z,render:M,disabled:E.disabled})]})}renderNoValueElement(r){const n=this.props.noDataRender,i=_.createElement("div",{className:"k-nodata"},_.createElement("div",null,r.toLanguageString(gy,sB[gy])));return n?n.call(void 0,i):i}render(){const r=ai(this),{id:n,show:i,wrapperCssClass:o,wrapperStyle:a,listStyle:s,listRef:l,wrapperRef:h,listClassName:p="k-list-ul",ariaSetSize:f}=this.props,g=this.renderItems();return g.length?_.createElement("div",{className:o,style:a,ref:h,onMouseDown:this.props.onMouseDown,onBlur:this.props.onBlur,onScroll:this.props.onScroll,unselectable:"on"},_.createElement("ul",{id:n,role:"listbox","aria-hidden":i?void 0:!0,"aria-setsize":f,className:p,ref:l,style:s},g),this.props.scroller&&_.createElement("div",{className:"k-height-container"},this.props.scroller)):this.renderNoValueElement(r)}};Vi(lB);/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const PBt=17895697,LE=typeof window<"u"&&/Firefox/.test(window.navigator.userAgent);let TBt=class{constructor(){this.table=null,this.total=0,this.enabled=!1,this.skip=0,this.pageSize=0,this.PageChange=null,this.scrollElement=null,this.listTransform="",this.itemHeight=0,this.containerHeight=0,this.reactVersion=Number.parseFloat(_.version),this.scrollSyncing=!1,this.lastLoaded=0,this.firstLoaded=0,this.lastScrollTop=0,this.listTranslate=0,this.list=null,this.container=null,this.calcScrollElementHeight=()=>{var r;this.scrollSyncing=!0;let n=!1;this.itemHeight=this.list?this.list.children[0].offsetHeight:this.itemHeight;const i=this.itemHeight*this.total-(((r=this.list)==null?void 0:r.offsetHeight)||0);this.containerHeight=LE?Math.min(PBt,i):i;const o=this.containerHeight;return this.scrollElement&&(n=this.scrollElement.style.height!==o+"px",n&&(this.scrollElement.style.height=o+"px")),this.scrollSyncing=!1,n},this.scrollerRef=r=>{this.container=r,r&&(r.setAttribute("unselectable","on"),window.setTimeout(this.calcScrollElementHeight.bind(this),0))},this.getRowHeightService=za((r,n)=>new Fu(n,r,0)),this.firstLoaded=this.pageSize,this.lastLoaded=this.skip+this.pageSize,this.scrollHandler=this.scrollHandler.bind(this)}get translate(){return this.listTranslate}translateTo(r,n){this.listTranslate=r,this.enabled&&this.list&&(LE||this.reactVersion<=17||n?this.list.style.transform="translateY("+r+"px)":this.listTransform="translateY("+r+"px)")}changePage(r,n){const i=Math.min(Math.max(0,r),this.total-this.pageSize);i!==this.skip&&this.PageChange&&this.PageChange({skip:i,take:this.pageSize},n)}reset(){this.container&&(this.calcScrollElementHeight(),this.container.scrollTop=0,this.translateTo(0,!0))}scrollToEnd(){if(this.container&&this.list){this.calcScrollElementHeight();const{scrollHeight:r,offsetHeight:n}=this.container;this.container.scrollTop=r,this.translateTo(r-n,!0)}}scrollHandler(r){if(!this.enabled||!this.container||!this.list)return;if(this.scrollSyncing){this.scrollSyncing=!1;return}this.rowHeightService=this.getRowHeightService(this.itemHeight,this.total);const n=this.container.scrollTop,i=this.lastScrollTop>=n,o=!i,a=Math.abs(n-this.lastScrollTop);this.lastScrollTop=n;let s=this.rowHeightService.index(n),l=this.rowHeightService.offset(s);const{offsetHeight:h}=this.container,p=this.rowHeightService.index(n+h);if(o&&p>=this.lastLoaded&&this.lastLoaded0&&(s=s-f,l=this.rowHeightService.offset(s)),this.firstLoaded=s,this.translateTo(l);const g=this.firstLoaded+this.pageSize;this.lastLoaded=Math.min(g,this.total),this.changePage(this.firstLoaded,r)}else if(i&&s-1<=this.firstLoaded){const f=a===this.itemHeight;if(this.skip===0&&f)this.lastScrollTop=0,this.firstLoaded=0,this.lastLoaded=this.pageSize,this.container.scrollTop=0,this.translateTo(0,!0);else{const g=Math.floor(this.pageSize*.3);this.firstLoaded=Math.max(s-g,0),this.translateTo(this.rowHeightService.offset(this.firstLoaded)),this.lastLoaded=Math.min(this.firstLoaded+this.pageSize,this.total),this.changePage(this.firstLoaded,r)}}}};/** + */const TBt=17895697,EE=typeof window<"u"&&/Firefox/.test(window.navigator.userAgent);let VBt=class{constructor(){this.table=null,this.total=0,this.enabled=!1,this.skip=0,this.pageSize=0,this.PageChange=null,this.scrollElement=null,this.listTransform="",this.itemHeight=0,this.containerHeight=0,this.reactVersion=Number.parseFloat(_.version),this.scrollSyncing=!1,this.lastLoaded=0,this.firstLoaded=0,this.lastScrollTop=0,this.listTranslate=0,this.list=null,this.container=null,this.calcScrollElementHeight=()=>{var r;this.scrollSyncing=!0;let n=!1;this.itemHeight=this.list?this.list.children[0].offsetHeight:this.itemHeight;const i=this.itemHeight*this.total-(((r=this.list)==null?void 0:r.offsetHeight)||0);this.containerHeight=EE?Math.min(TBt,i):i;const o=this.containerHeight;return this.scrollElement&&(n=this.scrollElement.style.height!==o+"px",n&&(this.scrollElement.style.height=o+"px")),this.scrollSyncing=!1,n},this.scrollerRef=r=>{this.container=r,r&&(r.setAttribute("unselectable","on"),window.setTimeout(this.calcScrollElementHeight.bind(this),0))},this.getRowHeightService=Sa((r,n)=>new Fu(n,r,0)),this.firstLoaded=this.pageSize,this.lastLoaded=this.skip+this.pageSize,this.scrollHandler=this.scrollHandler.bind(this)}get translate(){return this.listTranslate}translateTo(r,n){this.listTranslate=r,this.enabled&&this.list&&(EE||this.reactVersion<=17||n?this.list.style.transform="translateY("+r+"px)":this.listTransform="translateY("+r+"px)")}changePage(r,n){const i=Math.min(Math.max(0,r),this.total-this.pageSize);i!==this.skip&&this.PageChange&&this.PageChange({skip:i,take:this.pageSize},n)}reset(){this.container&&(this.calcScrollElementHeight(),this.container.scrollTop=0,this.translateTo(0,!0))}scrollToEnd(){if(this.container&&this.list){this.calcScrollElementHeight();const{scrollHeight:r,offsetHeight:n}=this.container;this.container.scrollTop=r,this.translateTo(r-n,!0)}}scrollHandler(r){if(!this.enabled||!this.container||!this.list)return;if(this.scrollSyncing){this.scrollSyncing=!1;return}this.rowHeightService=this.getRowHeightService(this.itemHeight,this.total);const n=this.container.scrollTop,i=this.lastScrollTop>=n,o=!i,a=Math.abs(n-this.lastScrollTop);this.lastScrollTop=n;let s=this.rowHeightService.index(n),l=this.rowHeightService.offset(s);const{offsetHeight:h}=this.container,p=this.rowHeightService.index(n+h);if(o&&p>=this.lastLoaded&&this.lastLoaded0&&(s=s-f,l=this.rowHeightService.offset(s)),this.firstLoaded=s,this.translateTo(l);const g=this.firstLoaded+this.pageSize;this.lastLoaded=Math.min(g,this.total),this.changePage(this.firstLoaded,r)}else if(i&&s-1<=this.firstLoaded){const f=a===this.itemHeight;if(this.skip===0&&f)this.lastScrollTop=0,this.firstLoaded=0,this.lastLoaded=this.pageSize,this.container.scrollTop=0,this.translateTo(0,!0);else{const g=Math.floor(this.pageSize*.3);this.firstLoaded=Math.max(s-g,0),this.translateTo(this.rowHeightService.offset(this.firstLoaded)),this.lastLoaded=Math.min(this.firstLoaded+this.pageSize,this.total),this.changePage(this.firstLoaded,r)}}}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let VBt=class{navigate(r){const n=r.keyCode;if(n===Jt.up||n===Jt.left)return this.next({current:r.current,min:r.min,max:r.max,step:r.skipItems?r.skipItems:-1});if(n===Jt.down||n===Jt.right)return this.next({current:r.current,min:r.min,max:r.max,step:r.skipItems?r.skipItems:1});if(n===Jt.home)return 0;if(n===Jt.end)return r.max}next(r){return H0(r.current)?Math.min(r.max,Math.max(r.current+r.step,r.min)):r.min}};/** + */let FBt=class{navigate(r){const n=r.keyCode;if(n===te.up||n===te.left)return this.next({current:r.current,min:r.min,max:r.max,step:r.skipItems?r.skipItems:-1});if(n===te.down||n===te.right)return this.next({current:r.current,min:r.min,max:r.max,step:r.skipItems?r.skipItems:1});if(n===te.home)return 0;if(n===te.end)return r.max}next(r){return H0(r.current)?Math.min(r.max,Math.max(r.current+r.step,r.min)):r.min}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const gc=class lB{constructor(r){this.wrapper=null,this.list=null,this.vs=new TBt,this.navigation=new VBt,this.handleItemClick=(n,i)=>{const o=this.initState();o.syntheticEvent=i,i.stopPropagation(),this.component.handleItemSelect(n,o),this.togglePopup(o),this.applyState(o)},this.handleFocus=n=>{if(!this.component.state.focused){const i=this.initState();i.data.focused=!0,i.events.push({type:"onFocus"}),i.syntheticEvent=n,this.applyState(i)}},this.filterChanged=(n,i)=>{const{textField:o,filterable:a}=this.component.props;a&&i.events.push({type:"onFilterChange",filter:{field:o,operator:"contains",ignoreCase:!0,value:n}})},this.togglePopup=n=>{const i=this.component.props,o=i.opened!==void 0?i.opened:this.component.state.opened;i.opened===void 0&&(n.data.opened=!o),o?n.events.push({type:"onClose"}):(n.events.push({type:"onOpen"}),this.calculatePopupWidth())},this.pageChange=(n,i)=>{const o=this.initState();o.syntheticEvent=i,this.triggerOnPageChange(o,n.skip,n.take),this.applyState(o)},this.scrollToVirtualItem=(n,i)=>{const o=this.vs;if(n.skip===0)o.reset();else{let a=o.translate;a===0&&(o.calcScrollElementHeight(),a=o.itemHeight*n.skip,o.translateTo(a,!0)),i<0&&a>0&&(a+=o.itemHeight*(n.pageSize/4)),o.container&&(o.container.scrollTop=a),this.scrollToItem(i,!0)}},this.scrollPopupByPageSize=n=>{var i,o,a,s,l,h;const p=this.vs,f=(o=(i=this.list)==null?void 0:i.parentElement)==null?void 0:o.scrollTop,g=p.enabled&&p.itemHeight?p.itemHeight:this.list?this.list.children[0].offsetHeight:0,b=(s=(a=this.list)==null?void 0:a.parentElement)==null?void 0:s.offsetHeight;f!==void 0&&b!==void 0&&((h=(l=this.list)==null?void 0:l.parentElement)==null||h.scroll({top:f+n*Math.floor(b/g)*g}))},this.renderScrollElement=()=>{const n=this.vs;return n.enabled&&_.createElement("div",{ref:i=>n.scrollElement=i,key:"scrollElementKey"})},this.resetGroupStickyHeader=(n,i)=>{n!==i.state.group&&i.setState({...i.state,group:n})},this.listBoxId=r.props.id+"list",this.guid=r.props.id,this.component=r,this.vs.PageChange=this.pageChange}didUpdate(){this.vs.listTransform&&this.vs.list&&(this.vs.list.style.transform=this.vs.listTransform,this.vs.listTransform="")}didMount(){const r=this.component.props,n=r.popupSettings||{},i=r.style||{},o=n.width;let a=r.opened===!0;o===void 0&&this.calculatePopupWidth(),r.dir===void 0&&i.direction===void 0&&(this.calculateDir(),a=!0),a&&this.component.forceUpdate()}calculateDir(){const r=this.component.element;r&&r.ownerDocument&&r.ownerDocument.defaultView&&(this.dirCalculated=r.ownerDocument.defaultView.getComputedStyle(r).direction||void 0)}calculatePopupWidth(){this.wrapper&&(this.popupWidth=this.wrapper.offsetWidth+"px")}scrollToItem(r,n,i){const o=this.list||this.vs.list;if(!o&&!i&&setTimeout(()=>{this.scrollToItem(r,n,!0)},10),r===0&&n&&this.vs.skip===0){this.vs.reset();return}if(o&&r>=0){const a=this.vs,s=a.container||o.parentNode,l=n!==void 0?n:a.enabled;SBt(s,o,r,a.translate,l)}}initState(){return{data:{},events:[],syntheticEvent:void 0}}applyState(r){Object.keys(r.data).length>0&&this.component.setState(r.data);const n={syntheticEvent:r.syntheticEvent,nativeEvent:r.syntheticEvent?r.syntheticEvent.nativeEvent:void 0,target:this.component,value:this.component.value};r.events.forEach(i=>{const o=i.type;delete i.type;const a=o&&this.component.props[o];a&&a.call(void 0,{...n,...i})})}triggerOnPageChange(r,n,i){const o=this.component.props.virtual;if(o){const a=Math.min(Math.max(0,n),Math.max(0,o.total-i));a!==o.skip&&r.events.push({type:"onPageChange",page:{skip:a,take:i}})}}triggerPageChangeCornerItems(r,n){const i=this.component.props,{data:o=[],dataItemKey:a,virtual:s}=i,l=i.opened!==void 0?i.opened:this.component.state.opened;r&&s&&this.vs.enabled&&(s.skip>0&&Gi(r,o[0],a)?this.triggerOnPageChange(n,s.skip-1,s.pageSize):!l&&s.skip+s.pageSize{r[a-1]&&o[n]!==r[a-1][n]&&i.push({[n]:o[n]}),i.push(r[a])}),i}};gc.basicPropTypes={opened:B.bool,disabled:B.bool,dir:B.string,tabIndex:B.number,accessKey:B.string,data:B.array,textField:B.string,className:B.string,label:B.string,loading:B.bool,popupSettings:B.shape({animate:B.oneOfType([B.bool,B.shape({openDuration:B.number,closeDuration:B.number})]),popupClass:B.string,className:B.string,appendTo:B.any,width:B.oneOfType([B.string,B.number]),height:B.oneOfType([B.string,B.number])}),onOpen:B.func,onClose:B.func,onFocus:B.func,onBlur:B.func,onChange:B.func,itemRender:B.func,listNoDataRender:B.func,focusedItemIndex:B.func,header:B.node,footer:B.node},gc.propTypes={...gc.basicPropTypes,value:B.any,defaultValue:B.any,filterable:B.bool,filter:B.string,virtual:B.shape({pageSize:B.number.isRequired,skip:B.number.isRequired,total:B.number.isRequired}),onFilterChange:B.func,onPageChange:B.func},gc.defaultProps={popupSettings:{height:"200px"},required:!1,validityStyles:!0};let yy=gc;/** + */const gc=class cB{constructor(r){this.wrapper=null,this.list=null,this.vs=new VBt,this.navigation=new FBt,this.handleItemClick=(n,i)=>{const o=this.initState();o.syntheticEvent=i,i.stopPropagation(),this.component.handleItemSelect(n,o),this.togglePopup(o),this.applyState(o)},this.handleFocus=n=>{if(!this.component.state.focused){const i=this.initState();i.data.focused=!0,i.events.push({type:"onFocus"}),i.syntheticEvent=n,this.applyState(i)}},this.filterChanged=(n,i)=>{const{textField:o,filterable:a}=this.component.props;a&&i.events.push({type:"onFilterChange",filter:{field:o,operator:"contains",ignoreCase:!0,value:n}})},this.togglePopup=n=>{const i=this.component.props,o=i.opened!==void 0?i.opened:this.component.state.opened;i.opened===void 0&&(n.data.opened=!o),o?n.events.push({type:"onClose"}):(n.events.push({type:"onOpen"}),this.calculatePopupWidth())},this.pageChange=(n,i)=>{const o=this.initState();o.syntheticEvent=i,this.triggerOnPageChange(o,n.skip,n.take),this.applyState(o)},this.scrollToVirtualItem=(n,i)=>{const o=this.vs;if(n.skip===0)o.reset();else{let a=o.translate;a===0&&(o.calcScrollElementHeight(),a=o.itemHeight*n.skip,o.translateTo(a,!0)),i<0&&a>0&&(a+=o.itemHeight*(n.pageSize/4)),o.container&&(o.container.scrollTop=a),this.scrollToItem(i,!0)}},this.scrollPopupByPageSize=n=>{var i,o,a,s,l,h;const p=this.vs,f=(o=(i=this.list)==null?void 0:i.parentElement)==null?void 0:o.scrollTop,g=p.enabled&&p.itemHeight?p.itemHeight:this.list?this.list.children[0].offsetHeight:0,b=(s=(a=this.list)==null?void 0:a.parentElement)==null?void 0:s.offsetHeight;f!==void 0&&b!==void 0&&((h=(l=this.list)==null?void 0:l.parentElement)==null||h.scroll({top:f+n*Math.floor(b/g)*g}))},this.renderScrollElement=()=>{const n=this.vs;return n.enabled&&_.createElement("div",{ref:i=>n.scrollElement=i,key:"scrollElementKey"})},this.resetGroupStickyHeader=(n,i)=>{n!==i.state.group&&i.setState({...i.state,group:n})},this.listBoxId=r.props.id+"list",this.guid=r.props.id,this.component=r,this.vs.PageChange=this.pageChange}didUpdate(){this.vs.listTransform&&this.vs.list&&(this.vs.list.style.transform=this.vs.listTransform,this.vs.listTransform="")}didMount(){const r=this.component.props,n=r.popupSettings||{},i=r.style||{},o=n.width;let a=r.opened===!0;o===void 0&&this.calculatePopupWidth(),r.dir===void 0&&i.direction===void 0&&(this.calculateDir(),a=!0),a&&this.component.forceUpdate()}calculateDir(){const r=this.component.element;r&&r.ownerDocument&&r.ownerDocument.defaultView&&(this.dirCalculated=r.ownerDocument.defaultView.getComputedStyle(r).direction||void 0)}calculatePopupWidth(){this.wrapper&&(this.popupWidth=this.wrapper.offsetWidth+"px")}scrollToItem(r,n,i){const o=this.list||this.vs.list;if(!o&&!i&&setTimeout(()=>{this.scrollToItem(r,n,!0)},10),r===0&&n&&this.vs.skip===0){this.vs.reset();return}if(o&&r>=0){const a=this.vs,s=a.container||o.parentNode,l=n!==void 0?n:a.enabled;zBt(s,o,r,a.translate,l)}}initState(){return{data:{},events:[],syntheticEvent:void 0}}applyState(r){Object.keys(r.data).length>0&&this.component.setState(r.data);const n={syntheticEvent:r.syntheticEvent,nativeEvent:r.syntheticEvent?r.syntheticEvent.nativeEvent:void 0,target:this.component,value:this.component.value};r.events.forEach(i=>{const o=i.type;delete i.type;const a=o&&this.component.props[o];a&&a.call(void 0,{...n,...i})})}triggerOnPageChange(r,n,i){const o=this.component.props.virtual;if(o){const a=Math.min(Math.max(0,n),Math.max(0,o.total-i));a!==o.skip&&r.events.push({type:"onPageChange",page:{skip:a,take:i}})}}triggerPageChangeCornerItems(r,n){const i=this.component.props,{data:o=[],dataItemKey:a,virtual:s}=i,l=i.opened!==void 0?i.opened:this.component.state.opened;r&&s&&this.vs.enabled&&(s.skip>0&&Wi(r,o[0],a)?this.triggerOnPageChange(n,s.skip-1,s.pageSize):!l&&s.skip+s.pageSize{r[a-1]&&o[n]!==r[a-1][n]&&i.push({[n]:o[n]}),i.push(r[a])}),i}};gc.basicPropTypes={opened:B.bool,disabled:B.bool,dir:B.string,tabIndex:B.number,accessKey:B.string,data:B.array,textField:B.string,className:B.string,label:B.string,loading:B.bool,popupSettings:B.shape({animate:B.oneOfType([B.bool,B.shape({openDuration:B.number,closeDuration:B.number})]),popupClass:B.string,className:B.string,appendTo:B.any,width:B.oneOfType([B.string,B.number]),height:B.oneOfType([B.string,B.number])}),onOpen:B.func,onClose:B.func,onFocus:B.func,onBlur:B.func,onChange:B.func,itemRender:B.func,listNoDataRender:B.func,focusedItemIndex:B.func,header:B.node,footer:B.node},gc.propTypes={...gc.basicPropTypes,value:B.any,defaultValue:B.any,filterable:B.bool,filter:B.string,virtual:B.shape({pageSize:B.number.isRequired,skip:B.number.isRequired,total:B.number.isRequired}),onFilterChange:B.func,onPageChange:B.func},gc.defaultProps={popupSettings:{height:"200px"},required:!1,validityStyles:!0};let yy=gc;/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const FBt={name:"@progress/kendo-react-dropdowns",productName:"KendoReact",productCodes:["KENDOUIREACT","KENDOUICOMPLETE"],publishDate:1722843969,version:"",licensingDocsUrl:"https://www.telerik.com/kendo-react-ui/components/my-license/?utm_medium=product&utm_source=kendoreact&utm_campaign=kendo-ui-react-purchase-license-keys-warning"};/** + */const RBt={name:"@progress/kendo-react-dropdowns",productName:"KendoReact",productCodes:["KENDOUIREACT","KENDOUICOMPLETE"],publishDate:1722843969,version:"",licensingDocsUrl:"https://www.telerik.com/kendo-react-ui/components/my-license/?utm_medium=product&utm_source=kendoreact&utm_campaign=kendo-ui-react-purchase-license-keys-warning"};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const EE=500,IE=768;/** + */const IE=500,HE=768;/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const RBt="Please select a value from the list!",{sizeMap:Tv,roundedMap:OBt}=Gr,Y7=class xy extends _.Component{constructor(r){super(r),this.state={},this._element=null,this.base=new yy(this),this.searchState={word:"",last:""},this._select=null,this._skipFocusEvent=!1,this._filterInput=null,this._navigated=!1,this._lastKeypressIsFilter=!1,this.itemHeight=0,this.focus=()=>{this.base.wrapper&&this.base.wrapper.focus({preventScroll:!0})},this.handleItemSelect=(n,i)=>{const{data:o=[],virtual:a,dataItemKey:s,defaultItem:l}=this.props,h=a?a.skip:0,p=n===-1&&l!==void 0?l:o[n-h],f=!Gi(p,this.value,s);this.triggerOnChange(p,i),f&&this.base.triggerPageChangeCornerItems(p,i)},this.componentRef=n=>{this._element=n,this.base.wrapper=n},this.dummySelect=n=>_.createElement("select",{name:this.props.name,ref:i=>{this._select=i},tabIndex:-1,"aria-hidden":!0,title:this.props.label,style:{opacity:0,width:1,border:0,zIndex:-1,position:"absolute",left:"50%"}},_.createElement("option",{value:this.props.valueMap?this.props.valueMap.call(void 0,n):n})),this.renderListContainer=()=>{const{header:n,footer:i,dir:o,data:a=[],size:s,groupField:l,groupStickyHeaderItemRender:h,list:p}=this.props,f=this.base,g=f.getPopupSettings(),b=this.props.opened!==void 0?this.props.opened:this.state.opened,z=g.width!==void 0?g.width:f.popupWidth,M={dir:o!==void 0?o:f.dirCalculated,width:z,popupSettings:{...g,popupClass:Me(g.popupClass,"k-list-container","k-dropdownlist-popup"),anchor:g.anchor||this.element,show:b,onOpen:this.onPopupOpened,onClose:this.onPopupClosed},itemsCount:[a.length]};let{group:I}=this.state;return I===void 0&&l!==void 0&&(I=po(a[0],l)),_.createElement(xBt,{...M},this.renderListFilter(),n&&_.createElement("div",{className:"k-list-header"},n),_.createElement("div",{className:Me("k-list",{[`k-list-${Tv[s]||s}`]:s,"k-virtual-list":this.base.vs.enabled})},this.renderDefaultItem(),!p&&I&&a.length!==0&&_.createElement(_E,{group:I,groupMode:"modern",render:h}),this.renderList()),i&&_.createElement("div",{className:"k-list-footer"},i))},this.renderList=()=>{const{data:n=[],textField:i,dataItemKey:o,virtual:a={skip:0,total:void 0},groupHeaderItemRender:s,listNoDataRender:l,itemRender:h}=this.props,p=this.base.vs,f=a.skip,g=this.props.opened!==void 0?this.props.opened:this.state.opened,b=this.base.getPopupSettings(),z=`translateY(${p.translate}px)`;return _.createElement(sB,{id:this._listboxId,show:g,data:n.slice(),focusedIndex:this.getFocusedIndex(),value:this.value,textField:i,valueField:o,optionsGuid:this._guid,groupField:this.props.groupField,groupMode:"modern",listRef:M=>p.list=this.base.list=M,wrapperStyle:{maxHeight:b.height},wrapperCssClass:"k-list-content",listStyle:p.enabled?{transform:z}:void 0,key:"listkey",skip:f,onClick:this.handleItemClick,itemRender:h,groupHeaderItemRender:s,noDataRender:l,onScroll:this.onScroll,wrapperRef:p.scrollerRef,scroller:this.base.renderScrollElement(),ariaSetSize:a.total})},this.onScroll=n=>{const{vs:i,list:o}=this.base;i.scrollHandler(n);const{groupField:a}=this.props;let{data:s=[]}=this.props;if(!(!a||!s.length)&&a){const l=this.itemHeight=this.itemHeight||(i.enabled?i.itemHeight:o?o.children[0].offsetHeight:0),h=n.target.scrollTop-i.skip*l;s=this.base.getGroupedDataModernMode(s,a);let p=s[0][a];for(let f=1;fh);f++)s[f]&&s[f][a]&&(p=s[f][a]);p!==this.state.group&&this.setState({group:p})}},this.renderListFilter=()=>{const n=this.props.filter!==void 0?this.props.filter:this.state.text;return this.props.filterable&&_.createElement(bBt,{value:n,ref:i=>this._filterInput=i&&i.element,onChange:this.handleListFilterChange,onKeyDown:this.handleKeyDown,size:this.props.size,rounded:this.props.rounded,fillMode:this.props.fillMode,renderListFilterWrapper:!0})},this.renderDefaultItem=()=>{const{textField:n,defaultItem:i,dataItemKey:o}=this.props;return i!==void 0&&_.createElement(kBt,{defaultItem:i,textField:n,selected:Gi(this.value,i,o),key:"defaultitemkey",onClick:this.handleDefaultItemClick})},this.search=n=>{clearTimeout(this._typingTimeout),this.props.filterable||(this._typingTimeout=window.setTimeout(()=>this.searchState.word="",this.props.delay),this.selectNext(n))},this.selectNext=n=>{const{data:i=[],dataItemKey:o}=this.props;let a=i.map((E,R)=>({item:E,itemIndex:R}));const s=this.searchState.word,l=this.searchState.last,h=wBt(s,l);let p=a.length,f=Math.max(0,i.findIndex(E=>Gi(E,this.value,o))),g;this.props.defaultItem&&(g={item:this.props.defaultItem,itemIndex:-1},p+=1,f+=1),f+=h?1:0,a=CBt(a,f,g);let b,z,M,I=0;const{textField:F,ignoreCase:H}=this.props;for(;I{n&&n.target instanceof Element&&n.target.nodeName==="INPUT"&&n.stopPropagation&&n.stopPropagation();const{data:i=[],filterable:o,disabled:a,defaultItem:s,leftRightKeysNavigation:l=!0,virtual:h={skip:0,total:0,pageSize:0},dataItemKey:p,groupField:f="",textField:g,skipDisabledItems:b=!0}=this.props,z=this.value,M=i.findIndex(K=>Gi(K,z,p)),I=this.props.opened!==void 0?this.props.opened:this.state.opened,F=n.keyCode,H=F===Jt.home||F===Jt.end,E=F===Jt.up||F===Jt.down,R=!I&&(n.altKey&&F===Jt.down||F===Jt.enter||F===Jt.space),W=I&&(n.altKey&&F===Jt.up||F===Jt.esc),$=l&&(F===Jt.left||F===Jt.right),G=E||$&&!o||H,Z=this.base.initState();if(Z.syntheticEvent=n,!a){if(H&&this.base.vs.enabled)F===Jt.home?h.skip!==0?(this.base.triggerOnPageChange(Z,0,h.pageSize),this._navigated=!0):this.triggerOnChange(i[0],Z):h.skip!at.disabled&&at[g]);K=et&&i.findIndex(at=>at[g]===et[g])}else if(F===Jt.up||F===Jt.left){let et;if(M===0&&s)K=-1;else if(M===-1)et=i,K=i.findIndex(at=>!at.disabled&&at[g]);else{et=i.slice(0,M);let at=et.pop();for(;at&&at.disabled;)at=et.pop();K=at&&i.findIndex(tt=>tt[g]===at[g])}}if(K!==void 0){const et=K-M;this.onNavigate(Z,F,et)}else K===void 0&&i.findIndex(et=>et[g]===z[g])===i.length-1&&this.onNavigate(Z,F)}else if(!b&&I||H)this.onNavigate(Z,F);else if(g){let K;if(F===Jt.down||F===Jt.right){const et=i.slice(M+1).find(at=>!at.disabled&&at[g]);K=et&&i.findIndex(at=>at[g]===et[g])}else if(F===Jt.up||F===Jt.left){let et;if(M===0&&s)K=-1;else if(M===-1)et=i,K=i.find(at=>!at.disabled&&at[g]);else{et=i.slice(0,M);let at=et.pop();for(;at&&at.disabled;)at=et.pop();K=at&&i.findIndex(tt=>tt[g]===at[g])}}if(K!==void 0){const et=K-M;this.onNavigate(Z,F,et)}else K===void 0&&i.findIndex(et=>et[g]===z[g])===i.length-1&&this.onNavigate(Z,F)}else this.onNavigate(Z,F);n.preventDefault()}this.applyState(Z)}},this.handleItemClick=(n,i)=>{this.base.handleItemClick(n,i),this._valueDuringOnChange=void 0},this.handleFocus=n=>{this._skipFocusEvent||this.base.handleFocus(n)},this.handleBlur=n=>{if(this._skipFocusEvent||!this.state.focused)return;const i=this.props.opened!==void 0?this.props.opened:this.state.opened,{adaptive:o}=this.props,{windowWidth:a=0}=this.state,s=a<=IE&&o,l=this.base.initState();l.syntheticEvent=n,l.data.focused=!1,l.events.push({type:"onBlur"}),i&&this.resetValueIfDisabledItem(),i&&!s&&this.base.togglePopup(l),this.applyState(l)},this.handleDefaultItemClick=n=>{const i=this.base.initState();i.syntheticEvent=n,this.base.togglePopup(i),this.triggerOnChange(this.props.defaultItem,i),this.applyState(i)},this.handleWrapperClick=n=>{if(n.isPropagationStopped())return;const i=this.base.initState();i.syntheticEvent=n,this.state.focused||(i.data.focused=!0),this.resetValueIfDisabledItem(),this.base.togglePopup(i),this.applyState(i)},this.handleKeyPress=n=>{if(this.props.filterable||n.which===0||n.keyCode===Jt.enter)return;let i=String.fromCharCode(n.charCode||n.keyCode);this.props.ignoreCase&&(i=i.toLowerCase()),i===" "&&n.preventDefault(),this.searchState={word:this.searchState.word+i,last:this.searchState.last+i},this.search(n)},this.handleListFilterChange=n=>{const i=this.base.initState();i.syntheticEvent=n.syntheticEvent,this.props.filter===void 0&&(i.data.text=n.target.value),this.base.filterChanged(n.target.value,i),this._lastKeypressIsFilter=!0,this.applyState(i),this.setState({group:void 0})},this.onPopupOpened=()=>{this._filterInput&&this.focusElement(this._filterInput),this.props.adaptive&&setTimeout(()=>{this._filterInput&&this.focusElement(this._filterInput)},300)},this.onPopupClosed=()=>{this.state.focused&&window.setTimeout(()=>{this.state.focused&&this.base.wrapper&&this.focusElement(this.base.wrapper)})},this.setValidity=()=>{this._select&&this._select.setCustomValidity&&this._select.setCustomValidity(this.validity.valid?"":this.props.validationMessage||RBt)},gi(FBt)}get _inputId(){return this.props.id+"-accessibility-id"}get _listboxId(){return this.props.id+"-listbox-id"}get _guid(){return this.props.id+"-guid"}get document(){if(ai)return this.element&&this.element.ownerDocument||document}get element(){return this._element}get value(){let r;return this._valueDuringOnChange!==void 0?r=this._valueDuringOnChange:this.props.value!==void 0?r=this.props.value:this.state.value!==void 0?r=this.state.value:this.props.defaultValue!==void 0&&(r=this.props.defaultValue),!H0(r)&&this.props.defaultItem!==void 0&&(r=this.props.defaultItem),r}get index(){const{data:r=[],dataItemKey:n}=this.props,i=this.value;return r.findIndex(o=>Gi(o,i,n))}get name(){return this.props.name}get validity(){const r=this.props.validationMessage!==void 0,n=!this.required||this.value!==null&&this.value!==""&&this.value!==void 0,i=this.props.valid!==void 0?this.props.valid:n;return{customError:r,valid:i,valueMissing:this.value===null}}get validityStyles(){return this.props.validityStyles!==void 0?this.props.validityStyles:xy.defaultProps.validityStyles}get required(){return this.props.required!==void 0?this.props.required:xy.defaultProps.required}componentDidUpdate(r,n){var i;const{dataItemKey:o,virtual:a,groupField:s="",textField:l}=this.props,{data:h=[]}=this.props,p=r.virtual?r.virtual.total:0,f=this.props.opened!==void 0?this.props.opened:this.state.opened,g=r.opened!==void 0?r.opened:n.opened,b=!g&&f;if(this.base.didUpdate(),this.base.getPopupSettings().animate||b&&this.onPopupOpened(),a&&a.total!==p)this.base.vs.calcScrollElementHeight(),this.base.vs.reset();else{const z=this.value,M=r.value!==void 0?r.value:n.value;let I=h.findIndex(H=>Gi(H,z,o));s!==""&&z&&l&&(I=(i=this.base.getGroupedDataModernMode(h,s))==null?void 0:i.map(H=>H[l]).indexOf(z[l]));const F=!Gi(M,z,o);b&&a?this.base.scrollToVirtualItem(a,I):b&&!a?(this.onPopupOpened(),h&&h.length!==0&&this.base.resetGroupStickyHeader(h[0][s],this),this.base.scrollToItem(I)):f&&g&&z&&F&&!this._navigated?this.base.scrollToItem(I,this.base.vs.enabled):f&&g&&this._navigated&&(this._navigated&&a&&a.skip===0?this.base.vs.reset():this._navigated&&a&&a.skip===a.total-a.pageSize&&this.base.vs.scrollToEnd())}this._navigated=!1,this.setValidity()}componentDidMount(){var r;this.observerResize=ai&&window.ResizeObserver&&new window.ResizeObserver(this.calculateMedia.bind(this)),this.base.didMount(),this.setValidity(),(r=this.document)!=null&&r.body&&this.observerResize&&this.observerResize.observe(this.document.body)}componentWillUnmount(){var r;(r=this.document)!=null&&r.body&&this.observerResize&&this.observerResize.disconnect()}render(){const r=si(this).toLanguageString(my,aB[my]),{style:n,className:i,label:o,dir:a,virtual:s,size:l,rounded:h,fillMode:p,adaptive:f}=this.props,{windowWidth:g=0}=this.state,b=this.props.opened!==void 0?this.props.opened:this.state.opened,z=this.value,M=po(z,this.props.textField),I=!this.validityStyles||this.validity.valid,F=this.base,H=F.vs,E=g<=IE&&f;H.enabled=s!==void 0,s!==void 0&&(F.vs.skip=s.skip,F.vs.total=s.total,F.vs.pageSize=s.pageSize);const{dataItemKey:R,data:W=[],disabled:$,tabIndex:G,loading:Z,iconClassName:K,svgIcon:et,valueRender:at}=this.props,{focused:tt}=this.state,ft=W.findIndex(yt=>Gi(yt,z,R)),dt=_.createElement("span",{id:this._inputId,className:"k-input-inner"},M&&_.createElement("span",{className:"k-input-value-text"},M)),ht=at!==void 0?at.call(void 0,dt,z):dt,lt=_.createElement(_.Fragment,null,_.createElement("span",{ref:this.componentRef,className:Me("k-dropdownlist k-picker",i,{[`k-picker-${Tv[l]||l}`]:l,[`k-rounded-${OBt[h]||h}`]:h,[`k-picker-${p}`]:p,"k-focus":tt,"k-disabled":$,"k-invalid":!I,"k-loading":Z,"k-required":this.required}),style:o?{...n,width:void 0}:n,dir:a,onMouseDown:b?yt=>{yt.target.nodeName!=="INPUT"&&(this.focusElement(this.base.wrapper),yt.preventDefault())}:void 0,onFocus:this.handleFocus,onBlur:this.handleBlur,tabIndex:XP(G,$),accessKey:this.props.accessKey,onKeyDown:this.handleKeyDown,onKeyPress:this.handleKeyPress,onClick:$?void 0:this.handleWrapperClick,role:"combobox","aria-required":this.required,"aria-disabled":$||void 0,"aria-haspopup":"listbox","aria-expanded":b||!1,"aria-owns":this._listboxId,"aria-activedescendant":b?"option-"+this._guid+"-"+(ft+(s?s.skip:0)):void 0,"aria-label":this.props.ariaLabel||this.props.label,"aria-labelledby":this.props.ariaLabelledBy,"aria-describedby":this.props.ariaDescribedBy||this._inputId,id:this.props.id,title:this.props.title},ht,Z&&_.createElement(en,{className:"k-input-loading-icon",name:"loading"}),_.createElement(ei,{tabIndex:-1,type:"button","aria-label":r,"aria-hidden":!0,size:l,fillMode:p,iconClass:K,className:"k-input-button",rounded:null,themeColor:"base",icon:K?void 0:"caret-alt-down",svgIcon:et||Y0,onMouseDown:yt=>this.state.focused&&yt.preventDefault()}),this.dummySelect(z),!E&&this.renderListContainer()),E&&this.renderAdaptiveListContainer());return o?_.createElement(v5,{label:o,editorValue:M,editorValid:I,editorDisabled:this.props.disabled,style:{width:n?n.width:void 0},children:lt}):lt}onNavigate(r,n,i){const{data:o=[],defaultItem:a,dataItemKey:s,virtual:l={skip:0,total:0,pageSize:0}}=this.props,h=this.base.vs,p=this.value,f=o.findIndex(b=>Gi(b,p,s)),g=this.base.navigation.navigate({current:l.skip+f,max:(h.enabled?l.total:o.length)-1,min:a!==void 0?-1:0,keyCode:n,skipItems:i||void 0});g!==void 0&&this.handleItemSelect(g,r),this.applyState(r)}renderAdaptiveListContainer(){const{windowWidth:r=0}=this.state,{header:n,footer:i,size:o,adaptiveTitle:a,groupField:s,groupStickyHeaderItemRender:l,list:h,data:p=[]}=this.props,f=this.props.opened!==void 0?this.props.opened:this.state.opened,g={navigatable:!1,navigatableElements:[],expand:f,animation:!0,onClose:z=>this.handleWrapperClick(z),animationStyles:r<=EE?{top:0,width:"100%",height:"100%"}:void 0,className:r<=EE?"k-adaptive-actionsheet k-actionsheet-fullscreen":"k-adaptive-actionsheet k-actionsheet-bottom"};let{group:b}=this.state;return b===void 0&&s!==void 0&&(b=po(p[0],s)),_.createElement(IO,{...g},_.createElement(p5,{className:"k-text-center"},_.createElement("div",{className:"k-actionsheet-titlebar-group k-hbox"},_.createElement("div",{className:"k-actionsheet-title"},_.createElement("div",null,a)),_.createElement("div",{className:"k-actionsheet-actions"},_.createElement(ei,{tabIndex:0,"aria-label":"Cancel","aria-disabled":"false",type:"button",fillMode:"flat",onClick:this.handleWrapperClick,icon:"x",svgIcon:pC}))),_.createElement("div",{className:"k-actionsheet-titlebar-group k-actionsheet-filter"},this.renderListFilter())),_.createElement(d5,{className:"!k-overflow-hidden"},n&&_.createElement("div",{className:"k-list-header"},n),_.createElement("div",{className:Me("k-list",{[`k-list-${Tv[o]||o}`]:o,"k-virtual-list":this.base.vs.enabled})},this.renderDefaultItem(),!h&&b&&p.length!==0&&_.createElement(_E,{group:b,groupMode:"modern",render:l}),this.renderList()),i&&_.createElement("div",{className:"k-list-footer"},i)))}getFocusedIndex(){const r=this.value,{data:n=[],textField:i,dataItemKey:o,virtual:a={skip:0},focusedItemIndex:s=zBt,filterable:l,skipDisabledItems:h=!0}=this.props,p=this.props.filter?this.props.filter:this.state.text;return h&&i&&!p&&!r?n.findIndex(f=>!f.disabled&&f[i]):H0(r)&&p===void 0||l&&p===""?n.findIndex(f=>Gi(f,r,o)):p?this._lastKeypressIsFilter?s(n,p,i):n.findIndex(f=>Gi(f,r,o)):a.skip===0?0:-1}focusElement(r){this._skipFocusEvent=!0,r.focus(),window.setTimeout(()=>this._skipFocusEvent=!1,30)}triggerOnChange(r,n){Gi(this.value,r,this.props.dataItemKey)||(this.props.value===void 0&&(n.data.value=r),this._valueDuringOnChange=r,n.events.push({type:"onChange"}))}applyState(r){this.base.applyState(r),this._valueDuringOnChange=void 0}calculateMedia(r){for(const n of r)this.setState({windowWidth:n.target.clientWidth})}resetValueIfDisabledItem(){const{data:r=[]}=this.props,n=this.base.initState(),i=this.getFocusedIndex();this.haveFocusedItemAndDataNotEmpty(r,i)&&(this.triggerOnChange(null,n),this.applyState(n))}haveFocusedItemAndDataNotEmpty(r,n){return n!==void 0&&n!==-1&&r&&r.length>0&&r[n].disabled}};Y7.displayName="DropDownList",Y7.propTypes={delay:B.number,ignoreCase:B.bool,iconClassName:B.string,svgIcon:dp,defaultItem:B.any,valueRender:B.func,valueMap:B.func,validationMessage:B.string,required:B.bool,id:B.string,ariaLabelledBy:B.string,ariaDescribedBy:B.string,ariaLabel:B.string,leftRightKeysNavigation:B.bool,title:B.string,groupField:B.string,list:B.any,skipDisabledItems:B.bool,renderListFilterWrapper:B.bool,...yy.propTypes},Y7.defaultProps={delay:500,tabIndex:0,ignoreCase:!0,...yy.defaultProps,required:!1,size:"medium",rounded:"medium",fillMode:"solid",groupMode:"modern"};let BBt=Y7;const NBt=R8(),C9=na(up(NBt,BBt));C9.displayName="KendoReactDropDownList";/** + */const OBt="Please select a value from the list!",{sizeMap:Tv,roundedMap:BBt}=Wr,Y7=class xy extends _.Component{constructor(r){super(r),this.state={},this._element=null,this.base=new yy(this),this.searchState={word:"",last:""},this._select=null,this._skipFocusEvent=!1,this._filterInput=null,this._navigated=!1,this._lastKeypressIsFilter=!1,this.itemHeight=0,this.focus=()=>{this.base.wrapper&&this.base.wrapper.focus({preventScroll:!0})},this.handleItemSelect=(n,i)=>{const{data:o=[],virtual:a,dataItemKey:s,defaultItem:l}=this.props,h=a?a.skip:0,p=n===-1&&l!==void 0?l:o[n-h],f=!Wi(p,this.value,s);this.triggerOnChange(p,i),f&&this.base.triggerPageChangeCornerItems(p,i)},this.componentRef=n=>{this._element=n,this.base.wrapper=n},this.dummySelect=n=>_.createElement("select",{name:this.props.name,ref:i=>{this._select=i},tabIndex:-1,"aria-hidden":!0,title:this.props.label,style:{opacity:0,width:1,border:0,zIndex:-1,position:"absolute",left:"50%"}},_.createElement("option",{value:this.props.valueMap?this.props.valueMap.call(void 0,n):n})),this.renderListContainer=()=>{const{header:n,footer:i,dir:o,data:a=[],size:s,groupField:l,groupStickyHeaderItemRender:h,list:p}=this.props,f=this.base,g=f.getPopupSettings(),b=this.props.opened!==void 0?this.props.opened:this.state.opened,z=g.width!==void 0?g.width:f.popupWidth,M={dir:o!==void 0?o:f.dirCalculated,width:z,popupSettings:{...g,popupClass:ke(g.popupClass,"k-list-container","k-dropdownlist-popup"),anchor:g.anchor||this.element,show:b,onOpen:this.onPopupOpened,onClose:this.onPopupClosed},itemsCount:[a.length]};let{group:I}=this.state;return I===void 0&&l!==void 0&&(I=lo(a[0],l)),_.createElement(bBt,{...M},this.renderListFilter(),n&&_.createElement("div",{className:"k-list-header"},n),_.createElement("div",{className:ke("k-list",{[`k-list-${Tv[s]||s}`]:s,"k-virtual-list":this.base.vs.enabled})},this.renderDefaultItem(),!p&&I&&a.length!==0&&_.createElement(AE,{group:I,groupMode:"modern",render:h}),this.renderList()),i&&_.createElement("div",{className:"k-list-footer"},i))},this.renderList=()=>{const{data:n=[],textField:i,dataItemKey:o,virtual:a={skip:0,total:void 0},groupHeaderItemRender:s,listNoDataRender:l,itemRender:h}=this.props,p=this.base.vs,f=a.skip,g=this.props.opened!==void 0?this.props.opened:this.state.opened,b=this.base.getPopupSettings(),z=`translateY(${p.translate}px)`;return _.createElement(lB,{id:this._listboxId,show:g,data:n.slice(),focusedIndex:this.getFocusedIndex(),value:this.value,textField:i,valueField:o,optionsGuid:this._guid,groupField:this.props.groupField,groupMode:"modern",listRef:M=>p.list=this.base.list=M,wrapperStyle:{maxHeight:b.height},wrapperCssClass:"k-list-content",listStyle:p.enabled?{transform:z}:void 0,key:"listkey",skip:f,onClick:this.handleItemClick,itemRender:h,groupHeaderItemRender:s,noDataRender:l,onScroll:this.onScroll,wrapperRef:p.scrollerRef,scroller:this.base.renderScrollElement(),ariaSetSize:a.total})},this.onScroll=n=>{const{vs:i,list:o}=this.base;i.scrollHandler(n);const{groupField:a}=this.props;let{data:s=[]}=this.props;if(!(!a||!s.length)&&a){const l=this.itemHeight=this.itemHeight||(i.enabled?i.itemHeight:o?o.children[0].offsetHeight:0),h=n.target.scrollTop-i.skip*l;s=this.base.getGroupedDataModernMode(s,a);let p=s[0][a];for(let f=1;fh);f++)s[f]&&s[f][a]&&(p=s[f][a]);p!==this.state.group&&this.setState({group:p})}},this.renderListFilter=()=>{const n=this.props.filter!==void 0?this.props.filter:this.state.text;return this.props.filterable&&_.createElement(wBt,{value:n,ref:i=>this._filterInput=i&&i.element,onChange:this.handleListFilterChange,onKeyDown:this.handleKeyDown,size:this.props.size,rounded:this.props.rounded,fillMode:this.props.fillMode,renderListFilterWrapper:!0})},this.renderDefaultItem=()=>{const{textField:n,defaultItem:i,dataItemKey:o}=this.props;return i!==void 0&&_.createElement(_Bt,{defaultItem:i,textField:n,selected:Wi(this.value,i,o),key:"defaultitemkey",onClick:this.handleDefaultItemClick})},this.search=n=>{clearTimeout(this._typingTimeout),this.props.filterable||(this._typingTimeout=window.setTimeout(()=>this.searchState.word="",this.props.delay),this.selectNext(n))},this.selectNext=n=>{const{data:i=[],dataItemKey:o}=this.props;let a=i.map((E,R)=>({item:E,itemIndex:R}));const s=this.searchState.word,l=this.searchState.last,h=CBt(s,l);let p=a.length,f=Math.max(0,i.findIndex(E=>Wi(E,this.value,o))),g;this.props.defaultItem&&(g={item:this.props.defaultItem,itemIndex:-1},p+=1,f+=1),f+=h?1:0,a=SBt(a,f,g);let b,z,M,I=0;const{textField:F,ignoreCase:H}=this.props;for(;I{n&&n.target instanceof Element&&n.target.nodeName==="INPUT"&&n.stopPropagation&&n.stopPropagation();const{data:i=[],filterable:o,disabled:a,defaultItem:s,leftRightKeysNavigation:l=!0,virtual:h={skip:0,total:0,pageSize:0},dataItemKey:p,groupField:f="",textField:g,skipDisabledItems:b=!0}=this.props,z=this.value,M=i.findIndex(K=>Wi(K,z,p)),I=this.props.opened!==void 0?this.props.opened:this.state.opened,F=n.keyCode,H=F===te.home||F===te.end,E=F===te.up||F===te.down,R=!I&&(n.altKey&&F===te.down||F===te.enter||F===te.space),W=I&&(n.altKey&&F===te.up||F===te.esc),$=l&&(F===te.left||F===te.right),G=E||$&&!o||H,Z=this.base.initState();if(Z.syntheticEvent=n,!a){if(H&&this.base.vs.enabled)F===te.home?h.skip!==0?(this.base.triggerOnPageChange(Z,0,h.pageSize),this._navigated=!0):this.triggerOnChange(i[0],Z):h.skip!at.disabled&&at[g]);K=et&&i.findIndex(at=>at[g]===et[g])}else if(F===te.up||F===te.left){let et;if(M===0&&s)K=-1;else if(M===-1)et=i,K=i.findIndex(at=>!at.disabled&&at[g]);else{et=i.slice(0,M);let at=et.pop();for(;at&&at.disabled;)at=et.pop();K=at&&i.findIndex(tt=>tt[g]===at[g])}}if(K!==void 0){const et=K-M;this.onNavigate(Z,F,et)}else K===void 0&&i.findIndex(et=>et[g]===z[g])===i.length-1&&this.onNavigate(Z,F)}else if(!b&&I||H)this.onNavigate(Z,F);else if(g){let K;if(F===te.down||F===te.right){const et=i.slice(M+1).find(at=>!at.disabled&&at[g]);K=et&&i.findIndex(at=>at[g]===et[g])}else if(F===te.up||F===te.left){let et;if(M===0&&s)K=-1;else if(M===-1)et=i,K=i.find(at=>!at.disabled&&at[g]);else{et=i.slice(0,M);let at=et.pop();for(;at&&at.disabled;)at=et.pop();K=at&&i.findIndex(tt=>tt[g]===at[g])}}if(K!==void 0){const et=K-M;this.onNavigate(Z,F,et)}else K===void 0&&i.findIndex(et=>et[g]===z[g])===i.length-1&&this.onNavigate(Z,F)}else this.onNavigate(Z,F);n.preventDefault()}this.applyState(Z)}},this.handleItemClick=(n,i)=>{this.base.handleItemClick(n,i),this._valueDuringOnChange=void 0},this.handleFocus=n=>{this._skipFocusEvent||this.base.handleFocus(n)},this.handleBlur=n=>{if(this._skipFocusEvent||!this.state.focused)return;const i=this.props.opened!==void 0?this.props.opened:this.state.opened,{adaptive:o}=this.props,{windowWidth:a=0}=this.state,s=a<=HE&&o,l=this.base.initState();l.syntheticEvent=n,l.data.focused=!1,l.events.push({type:"onBlur"}),i&&this.resetValueIfDisabledItem(),i&&!s&&this.base.togglePopup(l),this.applyState(l)},this.handleDefaultItemClick=n=>{const i=this.base.initState();i.syntheticEvent=n,this.base.togglePopup(i),this.triggerOnChange(this.props.defaultItem,i),this.applyState(i)},this.handleWrapperClick=n=>{if(n.isPropagationStopped())return;const i=this.base.initState();i.syntheticEvent=n,this.state.focused||(i.data.focused=!0),this.resetValueIfDisabledItem(),this.base.togglePopup(i),this.applyState(i)},this.handleKeyPress=n=>{if(this.props.filterable||n.which===0||n.keyCode===te.enter)return;let i=String.fromCharCode(n.charCode||n.keyCode);this.props.ignoreCase&&(i=i.toLowerCase()),i===" "&&n.preventDefault(),this.searchState={word:this.searchState.word+i,last:this.searchState.last+i},this.search(n)},this.handleListFilterChange=n=>{const i=this.base.initState();i.syntheticEvent=n.syntheticEvent,this.props.filter===void 0&&(i.data.text=n.target.value),this.base.filterChanged(n.target.value,i),this._lastKeypressIsFilter=!0,this.applyState(i),this.setState({group:void 0})},this.onPopupOpened=()=>{this._filterInput&&this.focusElement(this._filterInput),this.props.adaptive&&setTimeout(()=>{this._filterInput&&this.focusElement(this._filterInput)},300)},this.onPopupClosed=()=>{this.state.focused&&window.setTimeout(()=>{this.state.focused&&this.base.wrapper&&this.focusElement(this.base.wrapper)})},this.setValidity=()=>{this._select&&this._select.setCustomValidity&&this._select.setCustomValidity(this.validity.valid?"":this.props.validationMessage||OBt)},vi(RBt)}get _inputId(){return this.props.id+"-accessibility-id"}get _listboxId(){return this.props.id+"-listbox-id"}get _guid(){return this.props.id+"-guid"}get document(){if(oi)return this.element&&this.element.ownerDocument||document}get element(){return this._element}get value(){let r;return this._valueDuringOnChange!==void 0?r=this._valueDuringOnChange:this.props.value!==void 0?r=this.props.value:this.state.value!==void 0?r=this.state.value:this.props.defaultValue!==void 0&&(r=this.props.defaultValue),!H0(r)&&this.props.defaultItem!==void 0&&(r=this.props.defaultItem),r}get index(){const{data:r=[],dataItemKey:n}=this.props,i=this.value;return r.findIndex(o=>Wi(o,i,n))}get name(){return this.props.name}get validity(){const r=this.props.validationMessage!==void 0,n=!this.required||this.value!==null&&this.value!==""&&this.value!==void 0,i=this.props.valid!==void 0?this.props.valid:n;return{customError:r,valid:i,valueMissing:this.value===null}}get validityStyles(){return this.props.validityStyles!==void 0?this.props.validityStyles:xy.defaultProps.validityStyles}get required(){return this.props.required!==void 0?this.props.required:xy.defaultProps.required}componentDidUpdate(r,n){var i;const{dataItemKey:o,virtual:a,groupField:s="",textField:l}=this.props,{data:h=[]}=this.props,p=r.virtual?r.virtual.total:0,f=this.props.opened!==void 0?this.props.opened:this.state.opened,g=r.opened!==void 0?r.opened:n.opened,b=!g&&f;if(this.base.didUpdate(),this.base.getPopupSettings().animate||b&&this.onPopupOpened(),a&&a.total!==p)this.base.vs.calcScrollElementHeight(),this.base.vs.reset();else{const z=this.value,M=r.value!==void 0?r.value:n.value;let I=h.findIndex(H=>Wi(H,z,o));s!==""&&z&&l&&(I=(i=this.base.getGroupedDataModernMode(h,s))==null?void 0:i.map(H=>H[l]).indexOf(z[l]));const F=!Wi(M,z,o);b&&a?this.base.scrollToVirtualItem(a,I):b&&!a?(this.onPopupOpened(),h&&h.length!==0&&this.base.resetGroupStickyHeader(h[0][s],this),this.base.scrollToItem(I)):f&&g&&z&&F&&!this._navigated?this.base.scrollToItem(I,this.base.vs.enabled):f&&g&&this._navigated&&(this._navigated&&a&&a.skip===0?this.base.vs.reset():this._navigated&&a&&a.skip===a.total-a.pageSize&&this.base.vs.scrollToEnd())}this._navigated=!1,this.setValidity()}componentDidMount(){var r;this.observerResize=oi&&window.ResizeObserver&&new window.ResizeObserver(this.calculateMedia.bind(this)),this.base.didMount(),this.setValidity(),(r=this.document)!=null&&r.body&&this.observerResize&&this.observerResize.observe(this.document.body)}componentWillUnmount(){var r;(r=this.document)!=null&&r.body&&this.observerResize&&this.observerResize.disconnect()}render(){const r=ai(this).toLanguageString(my,sB[my]),{style:n,className:i,label:o,dir:a,virtual:s,size:l,rounded:h,fillMode:p,adaptive:f}=this.props,{windowWidth:g=0}=this.state,b=this.props.opened!==void 0?this.props.opened:this.state.opened,z=this.value,M=lo(z,this.props.textField),I=!this.validityStyles||this.validity.valid,F=this.base,H=F.vs,E=g<=HE&&f;H.enabled=s!==void 0,s!==void 0&&(F.vs.skip=s.skip,F.vs.total=s.total,F.vs.pageSize=s.pageSize);const{dataItemKey:R,data:W=[],disabled:$,tabIndex:G,loading:Z,iconClassName:K,svgIcon:et,valueRender:at}=this.props,{focused:tt}=this.state,ft=W.findIndex(yt=>Wi(yt,z,R)),dt=_.createElement("span",{id:this._inputId,className:"k-input-inner"},M&&_.createElement("span",{className:"k-input-value-text"},M)),ht=at!==void 0?at.call(void 0,dt,z):dt,lt=_.createElement(_.Fragment,null,_.createElement("span",{ref:this.componentRef,className:ke("k-dropdownlist k-picker",i,{[`k-picker-${Tv[l]||l}`]:l,[`k-rounded-${BBt[h]||h}`]:h,[`k-picker-${p}`]:p,"k-focus":tt,"k-disabled":$,"k-invalid":!I,"k-loading":Z,"k-required":this.required}),style:o?{...n,width:void 0}:n,dir:a,onMouseDown:b?yt=>{yt.target.nodeName!=="INPUT"&&(this.focusElement(this.base.wrapper),yt.preventDefault())}:void 0,onFocus:this.handleFocus,onBlur:this.handleBlur,tabIndex:KP(G,$),accessKey:this.props.accessKey,onKeyDown:this.handleKeyDown,onKeyPress:this.handleKeyPress,onClick:$?void 0:this.handleWrapperClick,role:"combobox","aria-required":this.required,"aria-disabled":$||void 0,"aria-haspopup":"listbox","aria-expanded":b||!1,"aria-owns":this._listboxId,"aria-activedescendant":b?"option-"+this._guid+"-"+(ft+(s?s.skip:0)):void 0,"aria-label":this.props.ariaLabel||this.props.label,"aria-labelledby":this.props.ariaLabelledBy,"aria-describedby":this.props.ariaDescribedBy||this._inputId,id:this.props.id,title:this.props.title},ht,Z&&_.createElement(Qi,{className:"k-input-loading-icon",name:"loading"}),_.createElement(Jr,{tabIndex:-1,type:"button","aria-label":r,"aria-hidden":!0,size:l,fillMode:p,iconClass:K,className:"k-input-button",rounded:null,themeColor:"base",icon:K?void 0:"caret-alt-down",svgIcon:et||Y0,onMouseDown:yt=>this.state.focused&&yt.preventDefault()}),this.dummySelect(z),!E&&this.renderListContainer()),E&&this.renderAdaptiveListContainer());return o?_.createElement(v5,{label:o,editorValue:M,editorValid:I,editorDisabled:this.props.disabled,style:{width:n?n.width:void 0},children:lt}):lt}onNavigate(r,n,i){const{data:o=[],defaultItem:a,dataItemKey:s,virtual:l={skip:0,total:0,pageSize:0}}=this.props,h=this.base.vs,p=this.value,f=o.findIndex(b=>Wi(b,p,s)),g=this.base.navigation.navigate({current:l.skip+f,max:(h.enabled?l.total:o.length)-1,min:a!==void 0?-1:0,keyCode:n,skipItems:i||void 0});g!==void 0&&this.handleItemSelect(g,r),this.applyState(r)}renderAdaptiveListContainer(){const{windowWidth:r=0}=this.state,{header:n,footer:i,size:o,adaptiveTitle:a,groupField:s,groupStickyHeaderItemRender:l,list:h,data:p=[]}=this.props,f=this.props.opened!==void 0?this.props.opened:this.state.opened,g={navigatable:!1,navigatableElements:[],expand:f,animation:!0,onClose:z=>this.handleWrapperClick(z),animationStyles:r<=IE?{top:0,width:"100%",height:"100%"}:void 0,className:r<=IE?"k-adaptive-actionsheet k-actionsheet-fullscreen":"k-adaptive-actionsheet k-actionsheet-bottom"};let{group:b}=this.state;return b===void 0&&s!==void 0&&(b=lo(p[0],s)),_.createElement(HO,{...g},_.createElement(p5,{className:"k-text-center"},_.createElement("div",{className:"k-actionsheet-titlebar-group k-hbox"},_.createElement("div",{className:"k-actionsheet-title"},_.createElement("div",null,a)),_.createElement("div",{className:"k-actionsheet-actions"},_.createElement(Jr,{tabIndex:0,"aria-label":"Cancel","aria-disabled":"false",type:"button",fillMode:"flat",onClick:this.handleWrapperClick,icon:"x",svgIcon:dC}))),_.createElement("div",{className:"k-actionsheet-titlebar-group k-actionsheet-filter"},this.renderListFilter())),_.createElement(d5,{className:"!k-overflow-hidden"},n&&_.createElement("div",{className:"k-list-header"},n),_.createElement("div",{className:ke("k-list",{[`k-list-${Tv[o]||o}`]:o,"k-virtual-list":this.base.vs.enabled})},this.renderDefaultItem(),!h&&b&&p.length!==0&&_.createElement(AE,{group:b,groupMode:"modern",render:l}),this.renderList()),i&&_.createElement("div",{className:"k-list-footer"},i)))}getFocusedIndex(){const r=this.value,{data:n=[],textField:i,dataItemKey:o,virtual:a={skip:0},focusedItemIndex:s=MBt,filterable:l,skipDisabledItems:h=!0}=this.props,p=this.props.filter?this.props.filter:this.state.text;return h&&i&&!p&&!r?n.findIndex(f=>!f.disabled&&f[i]):H0(r)&&p===void 0||l&&p===""?n.findIndex(f=>Wi(f,r,o)):p?this._lastKeypressIsFilter?s(n,p,i):n.findIndex(f=>Wi(f,r,o)):a.skip===0?0:-1}focusElement(r){this._skipFocusEvent=!0,r.focus(),window.setTimeout(()=>this._skipFocusEvent=!1,30)}triggerOnChange(r,n){Wi(this.value,r,this.props.dataItemKey)||(this.props.value===void 0&&(n.data.value=r),this._valueDuringOnChange=r,n.events.push({type:"onChange"}))}applyState(r){this.base.applyState(r),this._valueDuringOnChange=void 0}calculateMedia(r){for(const n of r)this.setState({windowWidth:n.target.clientWidth})}resetValueIfDisabledItem(){const{data:r=[]}=this.props,n=this.base.initState(),i=this.getFocusedIndex();this.haveFocusedItemAndDataNotEmpty(r,i)&&(this.triggerOnChange(null,n),this.applyState(n))}haveFocusedItemAndDataNotEmpty(r,n){return n!==void 0&&n!==-1&&r&&r.length>0&&r[n].disabled}};Y7.displayName="DropDownList",Y7.propTypes={delay:B.number,ignoreCase:B.bool,iconClassName:B.string,svgIcon:dp,defaultItem:B.any,valueRender:B.func,valueMap:B.func,validationMessage:B.string,required:B.bool,id:B.string,ariaLabelledBy:B.string,ariaDescribedBy:B.string,ariaLabel:B.string,leftRightKeysNavigation:B.bool,title:B.string,groupField:B.string,list:B.any,skipDisabledItems:B.bool,renderListFilterWrapper:B.bool,...yy.propTypes},Y7.defaultProps={delay:500,tabIndex:0,ignoreCase:!0,...yy.defaultProps,required:!1,size:"medium",rounded:"medium",fillMode:"solid",groupMode:"modern"};let NBt=Y7;const $Bt=R8(),C9=ra(up($Bt,NBt));C9.displayName="KendoReactDropDownList";/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let cB=class extends _.Component{constructor(){super(...arguments),this.pageSizeChange=r=>{this.props.pageChange&&this.props.pageChange({skip:0,take:parseInt(r.target.value,10)},r)}}render(){const{value:r,pageSizes:n,pageSize:i,messagesMap:o,size:a,navigatable:s}=this.props,l=n.slice();r===void 0&&l.filter(f=>f===i).length===0&&l.unshift(i);const h=o?o($7):{messageKey:$7,defaultMessage:xi[$7]},p=o?o(j7):{messageKey:j7,defaultMessage:xi[j7]};return _.createElement("span",{className:"k-pager-sizes"},_.createElement(C9,{value:r!==void 0?r:i,data:l,onChange:this.pageSizeChange,ariaLabel:si(this).toLanguageString(p.messageKey,p.defaultMessage),size:a,tabIndex:s?-1:void 0}),_.createElement("span",null,si(this).toLanguageString(h.messageKey,h.defaultMessage)))}};Ri(cB);/** + */let hB=class extends _.Component{constructor(){super(...arguments),this.pageSizeChange=r=>{this.props.pageChange&&this.props.pageChange({skip:0,take:parseInt(r.target.value,10)},r)}}render(){const{value:r,pageSizes:n,pageSize:i,messagesMap:o,size:a,navigatable:s}=this.props,l=n.slice();r===void 0&&l.filter(f=>f===i).length===0&&l.unshift(i);const h=o?o($7):{messageKey:$7,defaultMessage:yi[$7]},p=o?o(j7):{messageKey:j7,defaultMessage:yi[j7]};return _.createElement("span",{className:"k-pager-sizes"},_.createElement(C9,{value:r!==void 0?r:i,data:l,onChange:this.pageSizeChange,ariaLabel:ai(this).toLanguageString(p.messageKey,p.defaultMessage),size:a,tabIndex:s?-1:void 0}),_.createElement("span",null,ai(this).toLanguageString(h.messageKey,h.defaultMessage)))}};Vi(hB);/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const $Bt={name:"@progress/kendo-react-data-tools",productName:"KendoReact",productCodes:["KENDOUIREACT","KENDOUICOMPLETE"],publishDate:1722844030,version:"",licensingDocsUrl:"https://www.telerik.com/kendo-react-ui/components/my-license/"};/** + */const WBt={name:"@progress/kendo-react-data-tools",productName:"KendoReact",productCodes:["KENDOUIREACT","KENDOUICOMPLETE"],publishDate:1722844030,version:"",licensingDocsUrl:"https://www.telerik.com/kendo-react-ui/components/my-license/"};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const HE=600,WBt=768,by=class extends _.Component{constructor(r){super(r),this._element=null,this.onPageChange=(n,i)=>{const o={target:this,syntheticEvent:i.syntheticEvent,nativeEvent:i.nativeEvent,targetEvent:i,...n};this.props.onPageChange&&this.props.onPageChange.call(void 0,o)},this.changePage=(n,i)=>{this.props.onPageChange&&n>0&&n<=this.totalPages&&this.props.onPageChange({target:this,skip:(n-1)*this.props.take,take:this.props.take,syntheticEvent:i,nativeEvent:i.nativeEvent,targetEvent:i})},this.onWindowResize=()=>{const n=this.element;if(!n||!this.props.responsive)return;const i=n.offsetWidth;i=HE&&i{const i=this.element,o=n.keyCode;!i||!this.props.navigatable||((o===Jt.home||n.metaKey&&o===Jt.left)&&this.changePage(1,n),(o===Jt.end||n.metaKey&&o===Jt.right)&&this.changePage(this.totalPages,n),document.activeElement===i?(o===Jt.enter&&(SCt(i),fb(i)),(o===Jt.left||o===Jt.up)&&this.changePage(this.currentPage-1,n),(o===Jt.right||o===Jt.down)&&this.changePage(this.currentPage+1,n)):(o===Jt.esc&&(i.focus(),vb(i)),YP(n,i,cp)))},gi($Bt),this.state={showPagerSizes:!0,showPagerInfo:!0,innerNavigateActive:!1}}get isRtl(){return this.props.dir==="rtl"}get currentPage(){return Math.floor(this.props.skip/this.props.take)+1}get element(){return this._element}componentDidMount(){window.addEventListener("resize",this.onWindowResize),this.onWindowResize()}componentWillUnmount(){window.removeEventListener("resize",this.onWindowResize)}render(){const{showPagerSizes:r,showPagerInfo:n}=this.state,{skip:i,take:o,total:a,pageSizes:s,size:l,responsive:h,messagesMap:p,dir:f,style:g,pageSizeValue:b,previousNext:z,className:M,navigatable:I,disabled:F}=this.props,H=si(this),E=Ka(this),R=this.currentPage,W=this.props.type==="numeric"?_.createElement(_Ot,{type:h&&!r?"dropdown":"numbers",buttonCount:this.props.buttonCount||0,totalPages:this.totalPages,currentPage:this.currentPage,pageChange:this.changePage,messagesMap:this.props.messagesMap,size:l,navigatable:I}):_.createElement(oB,{buttonCount:this.props.buttonCount||0,totalPages:this.totalPages,currentPage:R,pageChange:this.changePage,messagesMap:p,size:l,navigatable:I}),$=p?p(R7):{messageKey:R7,defaultMessage:xi[R7]},G=p?p(O7):{messageKey:O7,defaultMessage:xi[O7]},Z=p?p(B7):{messageKey:B7,defaultMessage:xi[B7]},K=p?p(N7):{messageKey:N7,defaultMessage:xi[N7]},et=p?p(F7):{messageKey:F7,defaultMessage:xi[F7]},at=p?p(W7):{messageKey:W7,defaultMessage:xi[W7]},tt=p?p(Xo):{messageKey:Xo,defaultMessage:xi[Xo]},ft=p?p(g0):{messageKey:g0,defaultMessage:xi[g0]},dt=p?p(Ws):{messageKey:Ws,defaultMessage:xi[Ws]},ht=`${H.toLanguageString(tt.messageKey,tt.defaultMessage)} ${E.format(H.toLanguageString(dt.messageKey,dt.defaultMessage),[R])} ${H.toLanguageString(ft.messageKey,ft.defaultMessage)} ${E.format(H.toLanguageString(dt.messageKey,dt.defaultMessage),[this.totalPages])}`;let lt,yt,mt,gt;z&&(lt=this.renderButton(1,"k-pager-nav k-pager-first"+(R===1&&!F?" k-disabled":""),H.toLanguageString($.messageKey,$.defaultMessage),this.isRtl?"caret-alt-to-right":"caret-alt-to-left",this.isRtl?aE:sE,R===1?!0:void 0),yt=this.renderButton(R-1,"k-pager-nav"+(R===1&&!F?" k-disabled":""),H.toLanguageString(G.messageKey,G.defaultMessage),this.isRtl?"caret-alt-right":"caret-alt-left",this.isRtl?Dl:Pl,R===1?!0:void 0),mt=this.renderButton(R+1,"k-pager-nav"+(R>=this.totalPages&&!F?" k-disabled":""),H.toLanguageString(Z.messageKey,Z.defaultMessage),this.isRtl?"caret-alt-left":"caret-alt-right",this.isRtl?Pl:Dl,R>=this.totalPages?!0:void 0),gt=this.renderButton(this.totalPages,"k-pager-nav k-pager-last"+(R>=this.totalPages&&!F?" k-disabled":""),H.toLanguageString(K.messageKey,K.defaultMessage),this.isRtl?"caret-alt-to-left":"caret-alt-to-right",this.isRtl?sE:aE,R>=this.totalPages?!0:void 0));const kt=s&&_.createElement(cB,{pageChange:this.onPageChange,pageSize:o,pageSizes:s,value:b,messagesMap:p,size:l,navigatable:I}),_t=this.props.info&&_.createElement("span",{className:"k-pager-info"},E.format(H.toLanguageString(et.messageKey,et.defaultMessage),[Math.min(i+1,a),Math.min(i+o,a),a]));return _.createElement("div",{className:Me("k-pager",{[`k-pager-${Gr.sizeMap[l]||l}`]:l,"k-disabled":F},M),style:g,role:"application","aria-roledescription":"pager",dir:f,"aria-keyshortcuts":H.toLanguageString(at.messageKey,at.defaultMessage),"aria-label":ht,ref:bt=>this._element=bt,tabIndex:I?0:void 0,onKeyDown:this.onKeyDown},_.createElement("div",{className:Me("k-pager-numbers-wrap")},lt,yt,W,mt,gt),h?r&&kt:kt,h?n&&_t:_t)}renderButton(r,n,i,o,a,s){return _.createElement(ei,{fillMode:"flat",themeColor:"base",size:this.props.size,rounded:null,className:n,icon:o,svgIcon:a,title:i,role:"button","aria-disabled":s,tabIndex:this.props.navigatable?-1:void 0,onClick:l=>{l.preventDefault(),this.changePage(r,l)}})}get totalPages(){return Math.ceil((this.props.total||0)/this.props.take)}};by.propTypes={className:B.string,style:B.object,total:B.number.isRequired,skip:B.number.isRequired,take:B.number.isRequired,buttonCount:B.number,info:B.bool,type:B.oneOf(["numeric","input"]),pageSizes:B.arrayOf(B.oneOfType([B.string,B.number])),previousNext:B.bool,onPageChange:B.func,messagesMap:B.func,size:B.oneOf([null,"small","medium","large"]),dir:B.string,disabled:B.bool},by.defaultProps={buttonCount:10,info:!0,type:"numeric",size:"medium",disabled:!1};let CC=by;Wl(CC);Ri(CC);/** + */const DE=600,jBt=768,by=class extends _.Component{constructor(r){super(r),this._element=null,this.onPageChange=(n,i)=>{const o={target:this,syntheticEvent:i.syntheticEvent,nativeEvent:i.nativeEvent,targetEvent:i,...n};this.props.onPageChange&&this.props.onPageChange.call(void 0,o)},this.changePage=(n,i)=>{this.props.onPageChange&&n>0&&n<=this.totalPages&&this.props.onPageChange({target:this,skip:(n-1)*this.props.take,take:this.props.take,syntheticEvent:i,nativeEvent:i.nativeEvent,targetEvent:i})},this.onWindowResize=()=>{const n=this.element;if(!n||!this.props.responsive)return;const i=n.offsetWidth;i=DE&&i{const i=this.element,o=n.keyCode;!i||!this.props.navigatable||((o===te.home||n.metaKey&&o===te.left)&&this.changePage(1,n),(o===te.end||n.metaKey&&o===te.right)&&this.changePage(this.totalPages,n),document.activeElement===i?(o===te.enter&&(zCt(i),vb(i)),(o===te.left||o===te.up)&&this.changePage(this.currentPage-1,n),(o===te.right||o===te.down)&&this.changePage(this.currentPage+1,n)):(o===te.esc&&(i.focus(),gb(i)),XP(n,i,cp)))},vi(WBt),this.state={showPagerSizes:!0,showPagerInfo:!0,innerNavigateActive:!1}}get isRtl(){return this.props.dir==="rtl"}get currentPage(){return Math.floor(this.props.skip/this.props.take)+1}get element(){return this._element}componentDidMount(){window.addEventListener("resize",this.onWindowResize),this.onWindowResize()}componentWillUnmount(){window.removeEventListener("resize",this.onWindowResize)}render(){const{showPagerSizes:r,showPagerInfo:n}=this.state,{skip:i,take:o,total:a,pageSizes:s,size:l,responsive:h,messagesMap:p,dir:f,style:g,pageSizeValue:b,previousNext:z,className:M,navigatable:I,disabled:F}=this.props,H=ai(this),E=Xa(this),R=this.currentPage,W=this.props.type==="numeric"?_.createElement(AOt,{type:h&&!r?"dropdown":"numbers",buttonCount:this.props.buttonCount||0,totalPages:this.totalPages,currentPage:this.currentPage,pageChange:this.changePage,messagesMap:this.props.messagesMap,size:l,navigatable:I}):_.createElement(aB,{buttonCount:this.props.buttonCount||0,totalPages:this.totalPages,currentPage:R,pageChange:this.changePage,messagesMap:p,size:l,navigatable:I}),$=p?p(R7):{messageKey:R7,defaultMessage:yi[R7]},G=p?p(O7):{messageKey:O7,defaultMessage:yi[O7]},Z=p?p(B7):{messageKey:B7,defaultMessage:yi[B7]},K=p?p(N7):{messageKey:N7,defaultMessage:yi[N7]},et=p?p(F7):{messageKey:F7,defaultMessage:yi[F7]},at=p?p(W7):{messageKey:W7,defaultMessage:yi[W7]},tt=p?p(Uo):{messageKey:Uo,defaultMessage:yi[Uo]},ft=p?p(g0):{messageKey:g0,defaultMessage:yi[g0]},dt=p?p(Ws):{messageKey:Ws,defaultMessage:yi[Ws]},ht=`${H.toLanguageString(tt.messageKey,tt.defaultMessage)} ${E.format(H.toLanguageString(dt.messageKey,dt.defaultMessage),[R])} ${H.toLanguageString(ft.messageKey,ft.defaultMessage)} ${E.format(H.toLanguageString(dt.messageKey,dt.defaultMessage),[this.totalPages])}`;let lt,yt,mt,gt;z&&(lt=this.renderButton(1,"k-pager-nav k-pager-first"+(R===1&&!F?" k-disabled":""),H.toLanguageString($.messageKey,$.defaultMessage),this.isRtl?"caret-alt-to-right":"caret-alt-to-left",this.isRtl?sE:lE,R===1?!0:void 0),yt=this.renderButton(R-1,"k-pager-nav"+(R===1&&!F?" k-disabled":""),H.toLanguageString(G.messageKey,G.defaultMessage),this.isRtl?"caret-alt-right":"caret-alt-left",this.isRtl?Dl:Pl,R===1?!0:void 0),mt=this.renderButton(R+1,"k-pager-nav"+(R>=this.totalPages&&!F?" k-disabled":""),H.toLanguageString(Z.messageKey,Z.defaultMessage),this.isRtl?"caret-alt-left":"caret-alt-right",this.isRtl?Pl:Dl,R>=this.totalPages?!0:void 0),gt=this.renderButton(this.totalPages,"k-pager-nav k-pager-last"+(R>=this.totalPages&&!F?" k-disabled":""),H.toLanguageString(K.messageKey,K.defaultMessage),this.isRtl?"caret-alt-to-left":"caret-alt-to-right",this.isRtl?lE:sE,R>=this.totalPages?!0:void 0));const _t=s&&_.createElement(hB,{pageChange:this.onPageChange,pageSize:o,pageSizes:s,value:b,messagesMap:p,size:l,navigatable:I}),At=this.props.info&&_.createElement("span",{className:"k-pager-info"},E.format(H.toLanguageString(et.messageKey,et.defaultMessage),[Math.min(i+1,a),Math.min(i+o,a),a]));return _.createElement("div",{className:ke("k-pager",{[`k-pager-${Wr.sizeMap[l]||l}`]:l,"k-disabled":F},M),style:g,role:"application","aria-roledescription":"pager",dir:f,"aria-keyshortcuts":H.toLanguageString(at.messageKey,at.defaultMessage),"aria-label":ht,ref:bt=>this._element=bt,tabIndex:I?0:void 0,onKeyDown:this.onKeyDown},_.createElement("div",{className:ke("k-pager-numbers-wrap")},lt,yt,W,mt,gt),h?r&&_t:_t,h?n&&At:At)}renderButton(r,n,i,o,a,s){return _.createElement(Jr,{fillMode:"flat",themeColor:"base",size:this.props.size,rounded:null,className:n,icon:o,svgIcon:a,title:i,role:"button","aria-disabled":s,tabIndex:this.props.navigatable?-1:void 0,onClick:l=>{l.preventDefault(),this.changePage(r,l)}})}get totalPages(){return Math.ceil((this.props.total||0)/this.props.take)}};by.propTypes={className:B.string,style:B.object,total:B.number.isRequired,skip:B.number.isRequired,take:B.number.isRequired,buttonCount:B.number,info:B.bool,type:B.oneOf(["numeric","input"]),pageSizes:B.arrayOf(B.oneOfType([B.string,B.number])),previousNext:B.bool,onPageChange:B.func,messagesMap:B.func,size:B.oneOf([null,"small","medium","large"]),dir:B.string,disabled:B.bool},by.defaultProps={buttonCount:10,info:!0,type:"numeric",size:"medium",disabled:!1};let SC=by;Wl(SC);Vi(SC);/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let jBt=class extends _.Component{constructor(){super(...arguments),this.draggable=null,this.isDragged=!1,this.onDrag=r=>{this.isDragged=!0;const n=this.draggable&&this.draggable.element;n&&this.props.resize(r.event,n,!1)},this.onRelease=r=>{if(!this.isDragged)return;const n=this.draggable&&this.draggable.element;n&&this.props.resize(r.event,n,!0),this.isDragged=!1},this.onDoubleClick=r=>{if(this.isDragged)return;const n=this.draggable&&this.draggable.element;n&&this.props.autofit&&this.props.autofit(r,n)}}render(){return _.createElement(O8,{onPress:r=>{r.event.originalEvent.stopPropagation()},onDrag:this.onDrag,onRelease:this.onRelease,autoScroll:{direction:{vertical:!1,horizontal:!0}},ref:r=>{this.draggable=r}},_.createElement("span",{className:"k-column-resizer",style:{touchAction:"none"},draggable:!1,onDoubleClick:this.onDoubleClick}))}};/** + */let GBt=class extends _.Component{constructor(){super(...arguments),this.draggable=null,this.isDragged=!1,this.onDrag=r=>{this.isDragged=!0;const n=this.draggable&&this.draggable.element;n&&this.props.resize(r.event,n,!1)},this.onRelease=r=>{if(!this.isDragged)return;const n=this.draggable&&this.draggable.element;n&&this.props.resize(r.event,n,!0),this.isDragged=!1},this.onDoubleClick=r=>{if(this.isDragged)return;const n=this.draggable&&this.draggable.element;n&&this.props.autofit&&this.props.autofit(r,n)}}render(){return _.createElement(O8,{onPress:r=>{r.event.originalEvent.stopPropagation()},onDrag:this.onDrag,onRelease:this.onRelease,autoScroll:{direction:{vertical:!1,horizontal:!0}},ref:r=>{this.draggable=r}},_.createElement("span",{className:"k-column-resizer",style:{touchAction:"none"},draggable:!1,onDoubleClick:this.onDoubleClick}))}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const d6="data-keyboardnavlevel",hB="data-keyboardnavscope",uB="data-keyboardnavheader",pB="data-keyboardnavbody",m5="data-keyboardnavid",GBt="_filter",UBt="k-grid-cancel-command",YBt="k-grid-edit-command",DE={[hB]:!0},PE={[uB]:!0},TE={[pB]:!0};/** + */const d6="data-keyboardnavlevel",uB="data-keyboardnavscope",pB="data-keyboardnavheader",dB="data-keyboardnavbody",m5="data-keyboardnavid",UBt="_filter",YBt="k-grid-cancel-command",XBt="k-grid-edit-command",PE={[uB]:!0},TE={[pB]:!0},VE={[dB]:!0};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const XBt=(t,r,n="cell")=>`${r}_${t}_${n}`,KBt=t=>{if(t)return parseInt(t.getAttribute(d6)||"",10)},SC=t=>t&&t.getAttribute(m5)||void 0,wy=t=>t?!!t.getAttribute(m5):!1,qBt=(t,r={level:0})=>t.querySelector(`[${d6}='${r.level}']`),dB=t=>t&&t.parentElement&&t.parentElement.closest(`[${d6}]`),fB=(t,r)=>t.querySelector(`[${m5}='${r}']`),ZBt=t=>t&&t.parentElement&&t.parentElement.closest(`[${hB}]`),JBt=t=>{const r=t&&t.parentElement&&t.parentElement.closest(".k-grid-edit-row");return r&&r.querySelector("."+UBt)},QBt=t=>document.querySelector(`[aria-rowindex="${t}"] .k-grid-remove-command`),S8=t=>document.querySelector(`[data-keyboardnavid="${t}"]`),tNt=t=>{var r;const n=t&&t.parentElement&&t.parentElement.closest(".k-table-row");let i;return(r=n==null?void 0:n.parentElement)==null||r.childNodes.forEach(o=>{if(n===o){const a=o.previousSibling;i={current:n.getAttribute("aria-rowindex"),prev:a&&a.getAttribute("aria-rowindex")}}}),i};async function vB(t,r,n=5e3){const i=Date.now();if(r)for(;Date.now()-isetTimeout(a,20))}return!1}const eNt=async t=>{const r=t&&t.parentElement&&t.parentElement.closest(".k-grid-edit-row");return await vB("."+YBt,r)},rNt=t=>(t==null?void 0:t.closest(".k-table-td"))||null,gB=t=>t.querySelector(`[${uB}]`),mB=t=>t.querySelector(`[${pB}]`),iNt=t=>t.querySelector(".k-grid-norecords"),nNt=t=>{const r=t.querySelector(".k-grid-edit-cell"),n=r&&r.querySelector("input");n?n.focus():(r==null?void 0:r.firstChild).focus()},od=(t,r)=>{const{scope:n,navigationStateRef:i,contextStateRef:o}=t;if(!i.current||!n)return;const a=zC(i.current.navigationMatrix),s=fB(n,a);yB({elementForFocus:s,contextStateRef:o,event:r})},oNt=(t,r={focusable:!1})=>{const n=r.focusable?T0:cp;return Array.from(t.querySelectorAll(n.join(",")))},aNt=(t,r={level:0})=>{if(!t)return[];const n=T0.map(i=>i+`[${d6}='${r.level}']`).join(",");return Array.from(t.querySelectorAll(n))},sNt=(t={level:0})=>{const r=T0.map(n=>n+`[${d6}='${t.level}']`).join(",");return n=>n.matches(r)},yB=t=>{const{elementForFocus:r,event:n,contextStateRef:i,prevElement:o}=t;if(i.current&&r&&r.focus){n==null||n.preventDefault();const a=r.querySelector(".k-checkbox-wrap .k-checkbox");a&&a.focus?a.focus():r.focus(),wy(r)&&(r.setAttribute("tabIndex","0"),i.current.activeId=SC(r)),o&&wy(o)&&o.setAttribute("tabIndex","-1")}},lNt=t=>t.current?t.current.idPrefix:"",Cy=(t,r,n,i,o)=>{if(!n)return[];let a=t+(o?-1:1);for(;a>=0&&a{if(!n)return[];let a=r+(o?-1:1);for(;a>=0&&i[t]&&a{if(r){for(let n=0;n{let i;do if(t=t+1,i=r[n-t],i&&i.editable)break;while(n-t>=0);return i},cNt=(t,r,n,i)=>{var o;let a;const[s,l]=t;let h;const p=0,f=r.length;return h=VE(p,r,l),h?a=Tl(s,h.ariaColumnIndex,n,i,!0):(h=VE(p,r,f),a=Tl(s-1,h.ariaColumnIndex,n,i,!0)),{prevCell:a&&a[0]&&S8(a[0]),elementToFocus:a&&a[0]&&((o=S8(a[0]))==null?void 0:o.getAttribute("role"))}},FE=(t,r,n)=>{let i;do if(t=t+1,i=r[n+t],i&&i.editable)break;while(n+t-1{var o;let a;if(t){const[s,l]=t;let h,p=0;h=FE(p,r,l),h?a=Tl(s,h.ariaColumnIndex,n,i,!0):(p=-1,h=FE(p,r,0),a=Tl(s+1,h.ariaColumnIndex,n,i,!0))}return{nextCell:a&&a[0]&&S8(a[0]),elementToFocus:a&&a[0]&&((o=S8(a[0]))==null?void 0:o.getAttribute("role"))}},uNt=t=>t.current?t.current.navigationMatrix.length:0,zC=t=>t.flat().find(r=>r.endsWith("cell")),pNt=t=>t.flat().reverse().find(r=>r.endsWith("cell")),dNt=(t,r)=>t[r][0],fNt=(t,r)=>Array.from(t[r]).reverse()[0],vNt=t=>t?`${t}${GBt}`:"",gNt=(t,r,n)=>{let i;if(t.current&&t.current.prevNavigationIndexes){const[o,a]=t.current.prevNavigationIndexes,s=r[o];s&&s[a]===n?i=t.current.prevNavigationIndexes:i=Sy(r,n)}else i=Sy(r,n);return i},mNt=t=>{var r;return((r=dB(t))==null?void 0:r.getAttribute("data-keyboardnavid"))||t.getAttribute("data-keyboardnavid")},Je={generateNavigatableId:XBt,getNavigatableId:SC,getNavigatableLevel:KBt,getNavigatableElement:qBt,getClosestNavigatableElement:dB,getActiveNavDataElement:fB,getClosestScope:ZBt,getHeaderElement:gB,getBodyElement:mB,getFocusableElements:oNt,getNavigatableElements:aNt,filterNavigatableElements:sNt,focusElement:yB,getIdPrefix:lNt,isNavigatable:wy,findNextIdByRowIndex:Cy,findNextIdByCellIndex:Tl,findId:Sy,getNextNavigationIndex:uNt,getFilterColumnId:vNt,focusFirstDataElement:od,getClosestCancelButton:JBt,getClosestEditButton:eNt,getRowAriaRowIndex:tNt,getRemoveButtonByAriaRowIndex:QBt,getTableCellByKeyboardNavId:S8,getParentCell:rNt,waitForElementToBeVisible:vB,getNextEditableCell:hNt,getPrevEditableCell:cNt,getClosestCellNavId:mNt};/** + */const KBt=(t,r,n="cell")=>`${r}_${t}_${n}`,qBt=t=>{if(t)return parseInt(t.getAttribute(d6)||"",10)},zC=t=>t&&t.getAttribute(m5)||void 0,wy=t=>t?!!t.getAttribute(m5):!1,ZBt=(t,r={level:0})=>t.querySelector(`[${d6}='${r.level}']`),fB=t=>t&&t.parentElement&&t.parentElement.closest(`[${d6}]`),vB=(t,r)=>t.querySelector(`[${m5}='${r}']`),JBt=t=>t&&t.parentElement&&t.parentElement.closest(`[${uB}]`),QBt=t=>{const r=t&&t.parentElement&&t.parentElement.closest(".k-grid-edit-row");return r&&r.querySelector("."+YBt)},tNt=t=>document.querySelector(`[aria-rowindex="${t}"] .k-grid-remove-command`),S8=t=>document.querySelector(`[data-keyboardnavid="${t}"]`),eNt=t=>{var r;const n=t&&t.parentElement&&t.parentElement.closest(".k-table-row");let i;return(r=n==null?void 0:n.parentElement)==null||r.childNodes.forEach(o=>{if(n===o){const a=o.previousSibling;i={current:n.getAttribute("aria-rowindex"),prev:a&&a.getAttribute("aria-rowindex")}}}),i};async function gB(t,r,n=5e3){const i=Date.now();if(r)for(;Date.now()-isetTimeout(a,20))}return!1}const rNt=async t=>{const r=t&&t.parentElement&&t.parentElement.closest(".k-grid-edit-row");return await gB("."+XBt,r)},iNt=t=>(t==null?void 0:t.closest(".k-table-td"))||null,mB=t=>t.querySelector(`[${pB}]`),yB=t=>t.querySelector(`[${dB}]`),nNt=t=>t.querySelector(".k-grid-norecords"),oNt=t=>{const r=t.querySelector(".k-grid-edit-cell"),n=r&&r.querySelector("input");n?n.focus():(r==null?void 0:r.firstChild).focus()},od=(t,r)=>{const{scope:n,navigationStateRef:i,contextStateRef:o}=t;if(!i.current||!n)return;const a=MC(i.current.navigationMatrix),s=vB(n,a);xB({elementForFocus:s,contextStateRef:o,event:r})},aNt=(t,r={focusable:!1})=>{const n=r.focusable?T0:cp;return Array.from(t.querySelectorAll(n.join(",")))},sNt=(t,r={level:0})=>{if(!t)return[];const n=T0.map(i=>i+`[${d6}='${r.level}']`).join(",");return Array.from(t.querySelectorAll(n))},lNt=(t={level:0})=>{const r=T0.map(n=>n+`[${d6}='${t.level}']`).join(",");return n=>n.matches(r)},xB=t=>{const{elementForFocus:r,event:n,contextStateRef:i,prevElement:o}=t;if(i.current&&r&&r.focus){n==null||n.preventDefault();const a=r.querySelector(".k-checkbox-wrap .k-checkbox");a&&a.focus?a.focus():r.focus(),wy(r)&&(r.setAttribute("tabIndex","0"),i.current.activeId=zC(r)),o&&wy(o)&&o.setAttribute("tabIndex","-1")}},cNt=t=>t.current?t.current.idPrefix:"",Cy=(t,r,n,i,o)=>{if(!n)return[];let a=t+(o?-1:1);for(;a>=0&&a{if(!n)return[];let a=r+(o?-1:1);for(;a>=0&&i[t]&&a{if(r){for(let n=0;n{let i;do if(t=t+1,i=r[n-t],i&&i.editable)break;while(n-t>=0);return i},hNt=(t,r,n,i)=>{var o;let a;const[s,l]=t;let h;const p=0,f=r.length;return h=FE(p,r,l),h?a=Tl(s,h.ariaColumnIndex,n,i,!0):(h=FE(p,r,f),a=Tl(s-1,h.ariaColumnIndex,n,i,!0)),{prevCell:a&&a[0]&&S8(a[0]),elementToFocus:a&&a[0]&&((o=S8(a[0]))==null?void 0:o.getAttribute("role"))}},RE=(t,r,n)=>{let i;do if(t=t+1,i=r[n+t],i&&i.editable)break;while(n+t-1{var o;let a;if(t){const[s,l]=t;let h,p=0;h=RE(p,r,l),h?a=Tl(s,h.ariaColumnIndex,n,i,!0):(p=-1,h=RE(p,r,0),a=Tl(s+1,h.ariaColumnIndex,n,i,!0))}return{nextCell:a&&a[0]&&S8(a[0]),elementToFocus:a&&a[0]&&((o=S8(a[0]))==null?void 0:o.getAttribute("role"))}},pNt=t=>t.current?t.current.navigationMatrix.length:0,MC=t=>t.flat().find(r=>r.endsWith("cell")),dNt=t=>t.flat().reverse().find(r=>r.endsWith("cell")),fNt=(t,r)=>t[r][0],vNt=(t,r)=>Array.from(t[r]).reverse()[0],gNt=t=>t?`${t}${UBt}`:"",mNt=(t,r,n)=>{let i;if(t.current&&t.current.prevNavigationIndexes){const[o,a]=t.current.prevNavigationIndexes,s=r[o];s&&s[a]===n?i=t.current.prevNavigationIndexes:i=Sy(r,n)}else i=Sy(r,n);return i},yNt=t=>{var r;return((r=fB(t))==null?void 0:r.getAttribute("data-keyboardnavid"))||t.getAttribute("data-keyboardnavid")},Je={generateNavigatableId:KBt,getNavigatableId:zC,getNavigatableLevel:qBt,getNavigatableElement:ZBt,getClosestNavigatableElement:fB,getActiveNavDataElement:vB,getClosestScope:JBt,getHeaderElement:mB,getBodyElement:yB,getFocusableElements:aNt,getNavigatableElements:sNt,filterNavigatableElements:lNt,focusElement:xB,getIdPrefix:cNt,isNavigatable:wy,findNextIdByRowIndex:Cy,findNextIdByCellIndex:Tl,findId:Sy,getNextNavigationIndex:pNt,getFilterColumnId:gNt,focusFirstDataElement:od,getClosestCancelButton:QBt,getClosestEditButton:rNt,getRowAriaRowIndex:eNt,getRemoveButtonByAriaRowIndex:tNt,getTableCellByKeyboardNavId:S8,getParentCell:iNt,waitForElementToBeVisible:gB,getNextEditableCell:uNt,getPrevEditableCell:hNt,getClosestCellNavId:yNt};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */function yNt(t,r){const n=t[r].depth;let i=null;for(let o=r+1;o{let r=t.width?parseFloat(t.width.toString()):0;return!r&&t.children&&t.children.length&&(r=t.children.reduce((n,i)=>MC(i)+n,0)),r};function xNt(t,r){const n=[[]];let i=0;for(let s=t.length-1;s>=0;s--)i=Math.max(i,t[s].depth),t[s].colSpan=t[s].colSpan||1,t[s].children.length>0&&(t[s].colSpan=t[s].children.reduce((l,h)=>h.hidden?l:l+h.colSpan,0));const o=[];let a=1;return t.forEach((s,l)=>{n[s.depth]=n[s.depth]||[];let h=!1;n[s.depth].length===0&&(a<=1?a=1+(s.children.length>0?0:i-s.depth):(a--,h=!0)),s.rowSpan=1+(s.children.length>0?0:i-s.depth),s.kFirst=h,s.index=n[s.depth].length,n[s.depth].push(l),s.ariaColumnIndex=o[s.depth]?o[s.depth]+1:1;for(let p=s.depth;p{if(a.locked&&(!a.left||n))if(a.left=i[a.depth],o=MC(a),a.children.length===0)for(let s=a.depth;s=0;a--){const s=r[a];if(s.locked&&(!s.right||n)){if(s.right=o[s.depth],i=MC(s),s.children.length===0)for(let h=s.depth;h{const l=s.getBoundingClientRect();return n.x>l.left&&n.xl.top&&n.y{let r=t.width?parseFloat(t.width.toString()):0;return!r&&t.children&&t.children.length&&(r=t.children.reduce((n,i)=>kC(i)+n,0)),r};function bNt(t,r){const n=[[]];let i=0;for(let s=t.length-1;s>=0;s--)i=Math.max(i,t[s].depth),t[s].colSpan=t[s].colSpan||1,t[s].children.length>0&&(t[s].colSpan=t[s].children.reduce((l,h)=>h.hidden?l:l+h.colSpan,0));const o=[];let a=1;return t.forEach((s,l)=>{n[s.depth]=n[s.depth]||[];let h=!1;n[s.depth].length===0&&(a<=1?a=1+(s.children.length>0?0:i-s.depth):(a--,h=!0)),s.rowSpan=1+(s.children.length>0?0:i-s.depth),s.kFirst=h,s.index=n[s.depth].length,n[s.depth].push(l),s.ariaColumnIndex=o[s.depth]?o[s.depth]+1:1;for(let p=s.depth;p{if(a.locked&&(!a.left||n))if(a.left=i[a.depth],o=kC(a),a.children.length===0)for(let s=a.depth;s=0;a--){const s=r[a];if(s.locked&&(!s.right||n)){if(s.right=o[s.depth],i=kC(s),s.children.length===0)for(let h=s.depth;h{const l=s.getBoundingClientRect();return n.x>l.left&&n.xl.top&&n.y{const{navigatable:r,contextStateRef:n,navigationStateRef:i,idPrefix:o}=t;r&&(n.current={activeId:"",level:0},i.current={activeElementIsFocused:!1,prevNavigationIndexes:void 0,idPrefix:o||w7(),navigationMatrix:[],lastHeaderIndex:-1})},SB=t=>{const{scope:r,contextStateRef:n,navigationStateRef:i}=t;if(n.current&&i.current&&r){kC(t);const o=zC(i.current.navigationMatrix);if(o){const a=Je.getActiveNavDataElement(r,o);a&&(n.current.activeId=o,a.setAttribute("tabIndex","0"))}}},bNt=t=>{const{contextStateRef:r,navigationStateRef:n,document:i}=t;if(r.current&&n.current&&i){const o=Ki(i),a=Je.getNavigatableId(o);a&&a===r.current.activeId&&(n.current.activeElementIsFocused=!0)}},wNt=t=>{const{scope:r,contextStateRef:n,navigationStateRef:i,focusFirst:o,newEditableRow:a,singleEditRow:s,lastActiveElement:l,navigatable:h}=t;if(o&&(CB(t),SB(t),od(t)),(!h||h&&h.mode===M8.inline)&&(a&&!s||a&&s&&!l)?nNt(a):h&&h.mode===M8.inline&&a&&s&&l&&l.focus(),kC(t),n.current&&i.current&&r){if(!Je.getActiveNavDataElement(r,n.current.activeId)){const p=r.className.indexOf("k-treelist")===-1?zC(i.current.navigationMatrix):i.current.navigationMatrix[0][0],f=Je.getActiveNavDataElement(r,p);p&&f&&(n.current.activeId=p,f.setAttribute("tabIndex","0"),i.current.activeElementIsFocused&&f.focus())}i.current.activeElementIsFocused=!1}},CNt=(t,r)=>{const{contextStateRef:n}=r;if(t.isDefaultPrevented()||!n.current)return;const i=t.target,o=Je.getNavigatableId(i);if(o&&o!==n.current.activeId){const a=Je.getClosestScope(i);if(!a)return;const s=Je.getActiveNavDataElement(a,n.current.activeId);s&&!t.target.classList.contains("k-table-td")&&!t.target.classList.contains("k-detail-cell")&&s.setAttribute("tabIndex","-1"),i.setAttribute("tabIndex","0"),n.current.activeId=o}else if(i.closest(".k-filtercell")&&r.navigatable){const a=i.closest(".k-table-th");fb(a)}},SNt=async(t,r)=>{var n,i,o,a;const{contextStateRef:s,navigationStateRef:l,onNavigationAction:h,columns:p}=r;if(t.isDefaultPrevented()||!s.current||!l.current)return;let f;if(t.keyCode===Jt.esc&&!r.navigatable.mode){f=Je.getClosestNavigatableElement(t.target),Je.focusElement({elementForFocus:f,event:t,contextStateRef:s}),t.target.closest(".k-filtercell")&&f&&r.navigatable&&vb(f);return}const g=t.target,b=g.className.indexOf("k-checkbox")===-1?g:Je.getClosestNavigatableElement(g),z=Je.getNavigatableId(b)||((n=Je.getParentCell(b))==null?void 0:n.getAttribute("data-keyboardnavid")),M=z==null?void 0:z.endsWith("column"),I=Je.getNavigatableLevel(b),F=Je.getClosestScope(b),H=l.current.navigationMatrix,E=t.metaKey||t.ctrlKey,R=gNt(l,H,z),W=b.closest(".k-table-th");if(r.navigatable&&r.navigatable.mode===M8.inline){if(t.keyCode===Jt.enter){const $=b.classList.contains("k-grid-remove-command"),G=b.classList.contains("k-grid-cancel-command"),Z=Je.getRowAriaRowIndex(b);if($){setTimeout(()=>{const K=Je.getRemoveButtonByAriaRowIndex(Z.current)||Je.getRemoveButtonByAriaRowIndex(Z.prev);K&&K.focus()});return}else if(G&&b.parentElement){const K=(i=Je.getClosestNavigatableElement(b))==null?void 0:i.getAttribute("data-keyboardnavid");setTimeout(()=>{K&&Je.getTableCellByKeyboardNavId(K).focus()});return}}if(t.keyCode===Jt.esc){const $=Je.getClosestCancelButton(b);$&&$.click();const G=await Je.getClosestEditButton(b);G&&G.focus();return}}else if(r.navigatable&&r.navigatable.mode===M8.incell){const $=(o=b.closest(".k-table-td"))==null?void 0:o.classList.contains("k-grid-edit-cell");if(t.keyCode===Jt.esc){b.focus(),b.blur();const G=g&&g.parentElement&&g.parentElement.closest(".k-grid-edit-row"),Z=Je.getClosestCellNavId(b),K=await Je.waitForElementToBeVisible(`[data-keyboardnavid='${Z}']:not(.k-grid-edit-cell)`,G);K&&K.focus()}else if(t.keyCode===Jt.enter){let G;if(R){const[Z,K]=R;G=Cy(Z,K,z,H,!1)}if(!$)(a=Je.getParentCell(b))==null||a.click();else if($&&G){const Z=G&&G[0]&&Je.getTableCellByKeyboardNavId(G[0]);Z&&Z.click()}}else if(t.keyCode===Jt.left){if($)return}else if(t.keyCode===Jt.right){if($)return}else if(t.keyCode===Jt.up){if($)return}else if(t.keyCode===Jt.down){if($)return}else if(t.keyCode===Jt.tab&&$){if(t.shiftKey){const G=R&&p&&Je.getPrevEditableCell(R,p,z,H);if(G&&G.prevCell&&G.prevCell.click(),G&&G.elementToFocus!=="gridcell"){b.blur();const Z=Je.getClosestCellNavId(b);setTimeout(()=>{Z&&Je.getTableCellByKeyboardNavId(Z).focus()})}t.preventDefault()}else{const G=R&&p&&Je.getNextEditableCell(R,p,z,H);if(G&&G.nextCell&&G.elementToFocus==="gridcell"&&G.nextCell.click(),G&&G.elementToFocus!=="gridcell"){b.blur();const Z=Je.getClosestCellNavId(b);Z&&Je.getTableCellByKeyboardNavId(Z).focus();return}t.preventDefault()}t.preventDefault()}}if(b.closest(".k-filtercell")&&W&&r.navigatable&&YP(t,W,cp),I!==void 0&&F){if(t.keyCode===Jt.enter){const $=Je.getNavigatableElement(b,{level:I+1});if($){Je.focusElement({elementForFocus:$,event:t,contextStateRef:s,prevElement:b});return}else{b.querySelector(".k-filtercell")&&r.navigatable&&fb(b),f=Je.getFocusableElements(b)[0],Je.focusElement({elementForFocus:f,event:t,contextStateRef:s,prevElement:b});return}}if(t.keyCode===Jt.home&&R)if(E)od({scope:F,navigationStateRef:l,contextStateRef:s},t);else{const $=dNt(l.current.navigationMatrix,R[0]);f=Je.getActiveNavDataElement(F,$),Je.focusElement({elementForFocus:f,event:t,contextStateRef:s})}if(t.keyCode===Jt.end&&R)if(E){const $=pNt(l.current.navigationMatrix);f=Je.getActiveNavDataElement(F,$),Je.focusElement({elementForFocus:f,event:t,contextStateRef:s})}else{const $=fNt(l.current.navigationMatrix,R[0]);f=Je.getActiveNavDataElement(F,$),Je.focusElement({elementForFocus:f,event:t,contextStateRef:s})}if(t.keyCode===Jt.up||t.keyCode===Jt.down||t.keyCode===Jt.left||t.keyCode===Jt.right){const $=t.keyCode===Jt.up||t.keyCode===Jt.left,G=t.keyCode===Jt.up||t.keyCode===Jt.down;if(R){const[Z,K]=R,[et,at]=G?Cy(Z,K,z,H,$):Tl(Z,K,z,H,$);et&&(f=Je.getActiveNavDataElement(F,et),Je.focusElement({elementForFocus:f,event:t,contextStateRef:s,prevElement:b}),l.current.prevNavigationIndexes=at)}}if(E&&t.keyCode===Jt.left&&M){h&&h({focusElement:b,event:t,action:"reorderToLeft"}),t.preventDefault();return}if(E&&t.keyCode===Jt.right&&M){h&&h({focusElement:b,event:t,action:"reorderToRight"}),t.preventDefault();return}if(t.keyCode===Jt.pageUp){h&&h({focusElement:f,event:t,action:"moveToNextPage"}),t.preventDefault();return}if(t.keyCode===Jt.pageDown){h&&h({focusElement:f,event:t,action:"moveToPrevPage"}),t.preventDefault();return}h&&h({focusElement:f,event:t})}},kC=t=>{const{navigationStateRef:r,scope:n}=t;if(!r.current||!n)return;const i=[],o=gB(n),a=mB(n),s=iNt(n)||{children:[]};if(!o||!a)return;const l=Array.from(o.children),h=Array.from(a.children);[...l,...h,s].forEach((p,f)=>{Array.from(p.children).forEach(g=>{const b=SC(g);if(!b)return;const z=g.rowSpan||1,M=g.colSpan||1;let I;for(let F=f,H=f+z;F!R);I=E>-1?E:i[F].length}i[F][I]=b||""}for(let F=I+1,H=I+M;F!!p),r.current.lastHeaderIndex=l.length-1},w3={onConstructor:CB,onComponentDidMount:SB,onGetSnapshotBeforeUpdate:bNt,onComponentDidUpdate:wNt,onFocus:CNt,onKeyDown:SNt,generateMatrix:kC,focusFirstDataElement:od};/** + */const SB=t=>{const{navigatable:r,contextStateRef:n,navigationStateRef:i,idPrefix:o}=t;r&&(n.current={activeId:"",level:0},i.current={activeElementIsFocused:!1,prevNavigationIndexes:void 0,idPrefix:o||w7(),navigationMatrix:[],lastHeaderIndex:-1})},zB=t=>{const{scope:r,contextStateRef:n,navigationStateRef:i}=t;if(n.current&&i.current&&r){_C(t);const o=MC(i.current.navigationMatrix);if(o){const a=Je.getActiveNavDataElement(r,o);a&&(n.current.activeId=o,a.setAttribute("tabIndex","0"))}}},wNt=t=>{const{contextStateRef:r,navigationStateRef:n,document:i}=t;if(r.current&&n.current&&i){const o=Yi(i),a=Je.getNavigatableId(o);a&&a===r.current.activeId&&(n.current.activeElementIsFocused=!0)}},CNt=t=>{const{scope:r,contextStateRef:n,navigationStateRef:i,focusFirst:o,newEditableRow:a,singleEditRow:s,lastActiveElement:l,navigatable:h}=t;if(o&&(SB(t),zB(t),od(t)),(!h||h&&h.mode===M8.inline)&&(a&&!s||a&&s&&!l)?oNt(a):h&&h.mode===M8.inline&&a&&s&&l&&l.focus(),_C(t),n.current&&i.current&&r){if(!Je.getActiveNavDataElement(r,n.current.activeId)){const p=r.className.indexOf("k-treelist")===-1?MC(i.current.navigationMatrix):i.current.navigationMatrix[0][0],f=Je.getActiveNavDataElement(r,p);p&&f&&(n.current.activeId=p,f.setAttribute("tabIndex","0"),i.current.activeElementIsFocused&&f.focus())}i.current.activeElementIsFocused=!1}},SNt=(t,r)=>{const{contextStateRef:n}=r;if(t.isDefaultPrevented()||!n.current)return;const i=t.target,o=Je.getNavigatableId(i);if(o&&o!==n.current.activeId){const a=Je.getClosestScope(i);if(!a)return;const s=Je.getActiveNavDataElement(a,n.current.activeId);s&&!t.target.classList.contains("k-table-td")&&!t.target.classList.contains("k-detail-cell")&&s.setAttribute("tabIndex","-1"),i.setAttribute("tabIndex","0"),n.current.activeId=o}else if(i.closest(".k-filtercell")&&r.navigatable){const a=i.closest(".k-table-th");vb(a)}},zNt=async(t,r)=>{var n,i,o,a;const{contextStateRef:s,navigationStateRef:l,onNavigationAction:h,columns:p}=r;if(t.isDefaultPrevented()||!s.current||!l.current)return;let f;if(t.keyCode===te.esc&&!r.navigatable.mode){f=Je.getClosestNavigatableElement(t.target),Je.focusElement({elementForFocus:f,event:t,contextStateRef:s}),t.target.closest(".k-filtercell")&&f&&r.navigatable&&gb(f);return}const g=t.target,b=g.className.indexOf("k-checkbox")===-1?g:Je.getClosestNavigatableElement(g),z=Je.getNavigatableId(b)||((n=Je.getParentCell(b))==null?void 0:n.getAttribute("data-keyboardnavid")),M=z==null?void 0:z.endsWith("column"),I=Je.getNavigatableLevel(b),F=Je.getClosestScope(b),H=l.current.navigationMatrix,E=t.metaKey||t.ctrlKey,R=mNt(l,H,z),W=b.closest(".k-table-th");if(r.navigatable&&r.navigatable.mode===M8.inline){if(t.keyCode===te.enter){const $=b.classList.contains("k-grid-remove-command"),G=b.classList.contains("k-grid-cancel-command"),Z=Je.getRowAriaRowIndex(b);if($){setTimeout(()=>{const K=Je.getRemoveButtonByAriaRowIndex(Z.current)||Je.getRemoveButtonByAriaRowIndex(Z.prev);K&&K.focus()});return}else if(G&&b.parentElement){const K=(i=Je.getClosestNavigatableElement(b))==null?void 0:i.getAttribute("data-keyboardnavid");setTimeout(()=>{K&&Je.getTableCellByKeyboardNavId(K).focus()});return}}if(t.keyCode===te.esc){const $=Je.getClosestCancelButton(b);$&&$.click();const G=await Je.getClosestEditButton(b);G&&G.focus();return}}else if(r.navigatable&&r.navigatable.mode===M8.incell){const $=(o=b.closest(".k-table-td"))==null?void 0:o.classList.contains("k-grid-edit-cell");if(t.keyCode===te.esc){b.focus(),b.blur();const G=g&&g.parentElement&&g.parentElement.closest(".k-grid-edit-row"),Z=Je.getClosestCellNavId(b),K=await Je.waitForElementToBeVisible(`[data-keyboardnavid='${Z}']:not(.k-grid-edit-cell)`,G);K&&K.focus()}else if(t.keyCode===te.enter){let G;if(R){const[Z,K]=R;G=Cy(Z,K,z,H,!1)}if(!$)(a=Je.getParentCell(b))==null||a.click();else if($&&G){const Z=G&&G[0]&&Je.getTableCellByKeyboardNavId(G[0]);Z&&Z.click()}}else if(t.keyCode===te.left){if($)return}else if(t.keyCode===te.right){if($)return}else if(t.keyCode===te.up){if($)return}else if(t.keyCode===te.down){if($)return}else if(t.keyCode===te.tab&&$){if(t.shiftKey){const G=R&&p&&Je.getPrevEditableCell(R,p,z,H);if(G&&G.prevCell&&G.prevCell.click(),G&&G.elementToFocus!=="gridcell"){b.blur();const Z=Je.getClosestCellNavId(b);setTimeout(()=>{Z&&Je.getTableCellByKeyboardNavId(Z).focus()})}t.preventDefault()}else{const G=R&&p&&Je.getNextEditableCell(R,p,z,H);if(G&&G.nextCell&&G.elementToFocus==="gridcell"&&G.nextCell.click(),G&&G.elementToFocus!=="gridcell"){b.blur();const Z=Je.getClosestCellNavId(b);Z&&Je.getTableCellByKeyboardNavId(Z).focus();return}t.preventDefault()}t.preventDefault()}}if(b.closest(".k-filtercell")&&W&&r.navigatable&&XP(t,W,cp),I!==void 0&&F){if(t.keyCode===te.enter){const $=Je.getNavigatableElement(b,{level:I+1});if($){Je.focusElement({elementForFocus:$,event:t,contextStateRef:s,prevElement:b});return}else{b.querySelector(".k-filtercell")&&r.navigatable&&vb(b),f=Je.getFocusableElements(b)[0],Je.focusElement({elementForFocus:f,event:t,contextStateRef:s,prevElement:b});return}}if(t.keyCode===te.home&&R)if(E)od({scope:F,navigationStateRef:l,contextStateRef:s},t);else{const $=fNt(l.current.navigationMatrix,R[0]);f=Je.getActiveNavDataElement(F,$),Je.focusElement({elementForFocus:f,event:t,contextStateRef:s})}if(t.keyCode===te.end&&R)if(E){const $=dNt(l.current.navigationMatrix);f=Je.getActiveNavDataElement(F,$),Je.focusElement({elementForFocus:f,event:t,contextStateRef:s})}else{const $=vNt(l.current.navigationMatrix,R[0]);f=Je.getActiveNavDataElement(F,$),Je.focusElement({elementForFocus:f,event:t,contextStateRef:s})}if(t.keyCode===te.up||t.keyCode===te.down||t.keyCode===te.left||t.keyCode===te.right){const $=t.keyCode===te.up||t.keyCode===te.left,G=t.keyCode===te.up||t.keyCode===te.down;if(R){const[Z,K]=R,[et,at]=G?Cy(Z,K,z,H,$):Tl(Z,K,z,H,$);et&&(f=Je.getActiveNavDataElement(F,et),Je.focusElement({elementForFocus:f,event:t,contextStateRef:s,prevElement:b}),l.current.prevNavigationIndexes=at)}}if(E&&t.keyCode===te.left&&M){h&&h({focusElement:b,event:t,action:"reorderToLeft"}),t.preventDefault();return}if(E&&t.keyCode===te.right&&M){h&&h({focusElement:b,event:t,action:"reorderToRight"}),t.preventDefault();return}if(t.keyCode===te.pageUp){h&&h({focusElement:f,event:t,action:"moveToNextPage"}),t.preventDefault();return}if(t.keyCode===te.pageDown){h&&h({focusElement:f,event:t,action:"moveToPrevPage"}),t.preventDefault();return}h&&h({focusElement:f,event:t})}},_C=t=>{const{navigationStateRef:r,scope:n}=t;if(!r.current||!n)return;const i=[],o=mB(n),a=yB(n),s=nNt(n)||{children:[]};if(!o||!a)return;const l=Array.from(o.children),h=Array.from(a.children);[...l,...h,s].forEach((p,f)=>{Array.from(p.children).forEach(g=>{const b=zC(g);if(!b)return;const z=g.rowSpan||1,M=g.colSpan||1;let I;for(let F=f,H=f+z;F!R);I=E>-1?E:i[F].length}i[F][I]=b||""}for(let F=I+1,H=I+M;F!!p),r.current.lastHeaderIndex=l.length-1},w3={onConstructor:SB,onComponentDidMount:zB,onGetSnapshotBeforeUpdate:wNt,onComponentDidUpdate:CNt,onFocus:SNt,onKeyDown:zNt,generateMatrix:_C,focusFirstDataElement:od};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const zB="data-grid-row-index",MB="data-grid-col-index",X7="data-prevent-selection";/** + */const MB="data-grid-row-index",kB="data-grid-col-index",X7="data-prevent-selection";/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const zNt=t=>{let r=t;for(;r;){if(r.hasAttribute(X7))return!0;r=r.parentElement}return!1},C3=(t,r)=>{let n=t;for(;n;){if(n.tagName===r)return n;if(n.tagName==="TABLE")return null;n=n.parentElement}return null},Vv=t=>{if(!t)return;const r=t.getAttribute(zB);return r?parseInt(r,10):void 0},Fv=t=>{if(!t)return;const r=t.getAttribute(MB);return r?parseInt(r,10):void 0},MNt=ICt(),kNt=t=>{if(!t||!MNt)return null;let r=t.parentElement;for(;r;){if(window.getComputedStyle(r).transform!=="none")return r;r=r.parentElement}},_Nt=t=>{if(t&&t.ownerDocument&&t!==t.ownerDocument.body){const r=t.getBoundingClientRect();return{left:r.left-t.scrollLeft,top:r.top-t.scrollTop}}return{left:0,top:0}},zy=t=>{const r=t?typeof t.enabled=="boolean"?t.enabled:!0:!1,n=t?!!t.drag:!1,i=t&&t.mode?t.mode:"multiple",o=!!(t&&t.cell);return{enabled:r,drag:n,mode:i,cell:o}};/** + */const MNt=t=>{let r=t;for(;r;){if(r.hasAttribute(X7))return!0;r=r.parentElement}return!1},C3=(t,r)=>{let n=t;for(;n;){if(n.tagName===r)return n;if(n.tagName==="TABLE")return null;n=n.parentElement}return null},Vv=t=>{if(!t)return;const r=t.getAttribute(MB);return r?parseInt(r,10):void 0},Fv=t=>{if(!t)return;const r=t.getAttribute(kB);return r?parseInt(r,10):void 0},kNt=HCt(),_Nt=t=>{if(!t||!kNt)return null;let r=t.parentElement;for(;r;){if(window.getComputedStyle(r).transform!=="none")return r;r=r.parentElement}},ANt=t=>{if(t&&t.ownerDocument&&t!==t.ownerDocument.body){const r=t.getBoundingClientRect();return{left:r.left-t.scrollLeft,top:r.top-t.scrollTop}}return{left:0,top:0}},zy=t=>{const r=t?typeof t.enabled=="boolean"?t.enabled:!0:!1,n=t?!!t.drag:!1,i=t&&t.mode?t.mode:"multiple",o=!!(t&&t.cell);return{enabled:r,drag:n,mode:i,cell:o}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const NE=t=>{var r;const{onRelease:n,childRef:i}=t,{enabled:o,drag:a,mode:s,cell:l}=zy(t.selectable),h=_.useRef(null),p=_.useRef(null),f=_.useRef({clientX:0,clientY:0,scrollX:0,scrollY:0,pressedElement:null}),[g,b]=_.useState(null),z=_.useRef(),M=_.useRef(!1),I=_.useRef(!1),F=_.useCallback(W=>{const{event:$}=W;if(I.current=zNt($.originalEvent.target),I.current||!h.current)return;z.current=kNt(h.current.element);const G=h.current.element&&h.current.element.ownerDocument;if(!G)return;const Z=G.elementFromPoint($.clientX,$.clientY);f.current={clientY:$.clientY,clientX:$.clientX,scrollX:$.scrollX,scrollY:$.scrollY,pressedElement:Z}},[]),H=_.useCallback(W=>{const{event:$}=W,{clientX:G,clientY:Z}=f.current;if(!I.current&&!(!a||s==="single")&&((Math.abs(Z-$.clientY)>5||Math.abs(G-$.clientX)>5)&&(M.current=!0),M.current)){const K=_Nt(z.current);b({top:Math.min(Z,$.clientY)-K.top,left:Math.min(G,$.clientX)-K.left,width:Math.abs($.clientX-G),height:Math.abs($.clientY-Z)})}},[b,a,s]),E=_.useCallback(W=>{const{event:$}=W,{clientX:G,clientY:Z,scrollX:K,scrollY:et,pressedElement:at}=f.current;if(I.current||!h.current)return;const tt=h.current.element&&h.current.element.ownerDocument;if(tt){if(M.current){const ft=$.scrollY-et,dt=$.scrollX-K,ht=Math.min(Z,$.clientY),lt=Math.min(G,$.clientX),yt=Math.max(Z,$.clientY),mt=Math.max(G,$.clientX),gt=p.current;if(!gt)return;gt.style.visibility="hidden";const kt=tt.elementFromPoint(lt,ht),_t=ft>0||dt>0?at:kt,bt=tt.elementFromPoint(mt,yt);if(gt.style.visibility="",!_t||!bt)return;const Mt=C3(_t,"TD"),At=C3(Mt,"TR"),Ft=C3(bt,"TD"),Bt=C3(Ft,"TR"),Ut=Fv(Mt),Xt=Vv(At),It=Fv(Ft),ae=Vv(Bt);Ut!==void 0&&Xt!==void 0&&It!==void 0&&ae!==void 0&&n({nativeEvent:$.originalEvent,startRowIndex:Xt,startColIndex:Ut,endRowIndex:ae,endColIndex:It,altKey:$.altKey,shiftKey:$.shiftKey,ctrlKey:$.ctrlKey,metaKey:$.metaKey,mode:s,cell:l,isDrag:!0})}else{const ft=tt.elementFromPoint(G,Z);if(!ft)return;const dt=C3(ft,"TD"),ht=C3(ft,"TR"),lt=Fv(dt),yt=Vv(ht);dt&&ht&&yt!==void 0&<!==void 0&&n({nativeEvent:$.originalEvent,startRowIndex:yt,startColIndex:lt,endRowIndex:yt,endColIndex:lt,altKey:$.altKey,shiftKey:$.shiftKey,ctrlKey:$.ctrlKey,metaKey:$.metaKey,mode:s,cell:l,isDrag:!1})}b(null),M.current=!1,f.current={clientX:0,clientY:0,scrollX:0,scrollY:0,pressedElement:null}}},[b,s,l,n]),R=VCt(p);return o?_.createElement(_.Fragment,null,_.createElement(O8,{onPress:F,onDrag:H,onRelease:E,ref:h,childRef:i},t.children),g&&Xa.createPortal(_.createElement("div",{ref:p,style:{...g,position:"fixed"},className:"k-marquee k-marquee-color"}),(r=R())==null?void 0:r.body)):_.cloneElement(_.Children.only(t.children),{ref:i})};/** + */const $E=t=>{var r;const{onRelease:n,childRef:i}=t,{enabled:o,drag:a,mode:s,cell:l}=zy(t.selectable),h=_.useRef(null),p=_.useRef(null),f=_.useRef({clientX:0,clientY:0,scrollX:0,scrollY:0,pressedElement:null}),[g,b]=_.useState(null),z=_.useRef(),M=_.useRef(!1),I=_.useRef(!1),F=_.useCallback(W=>{const{event:$}=W;if(I.current=MNt($.originalEvent.target),I.current||!h.current)return;z.current=_Nt(h.current.element);const G=h.current.element&&h.current.element.ownerDocument;if(!G)return;const Z=G.elementFromPoint($.clientX,$.clientY);f.current={clientY:$.clientY,clientX:$.clientX,scrollX:$.scrollX,scrollY:$.scrollY,pressedElement:Z}},[]),H=_.useCallback(W=>{const{event:$}=W,{clientX:G,clientY:Z}=f.current;if(!I.current&&!(!a||s==="single")&&((Math.abs(Z-$.clientY)>5||Math.abs(G-$.clientX)>5)&&(M.current=!0),M.current)){const K=ANt(z.current);b({top:Math.min(Z,$.clientY)-K.top,left:Math.min(G,$.clientX)-K.left,width:Math.abs($.clientX-G),height:Math.abs($.clientY-Z)})}},[b,a,s]),E=_.useCallback(W=>{const{event:$}=W,{clientX:G,clientY:Z,scrollX:K,scrollY:et,pressedElement:at}=f.current;if(I.current||!h.current)return;const tt=h.current.element&&h.current.element.ownerDocument;if(tt){if(M.current){const ft=$.scrollY-et,dt=$.scrollX-K,ht=Math.min(Z,$.clientY),lt=Math.min(G,$.clientX),yt=Math.max(Z,$.clientY),mt=Math.max(G,$.clientX),gt=p.current;if(!gt)return;gt.style.visibility="hidden";const _t=tt.elementFromPoint(lt,ht),At=ft>0||dt>0?at:_t,bt=tt.elementFromPoint(mt,yt);if(gt.style.visibility="",!At||!bt)return;const kt=C3(At,"TD"),Lt=C3(kt,"TR"),Vt=C3(bt,"TD"),Rt=C3(Vt,"TR"),Ut=Fv(kt),Kt=Vv(Lt),It=Fv(Vt),le=Vv(Rt);Ut!==void 0&&Kt!==void 0&&It!==void 0&&le!==void 0&&n({nativeEvent:$.originalEvent,startRowIndex:Kt,startColIndex:Ut,endRowIndex:le,endColIndex:It,altKey:$.altKey,shiftKey:$.shiftKey,ctrlKey:$.ctrlKey,metaKey:$.metaKey,mode:s,cell:l,isDrag:!0})}else{const ft=tt.elementFromPoint(G,Z);if(!ft)return;const dt=C3(ft,"TD"),ht=C3(ft,"TR"),lt=Fv(dt),yt=Vv(ht);dt&&ht&&yt!==void 0&<!==void 0&&n({nativeEvent:$.originalEvent,startRowIndex:yt,startColIndex:lt,endRowIndex:yt,endColIndex:lt,altKey:$.altKey,shiftKey:$.shiftKey,ctrlKey:$.ctrlKey,metaKey:$.metaKey,mode:s,cell:l,isDrag:!1})}b(null),M.current=!1,f.current={clientX:0,clientY:0,scrollX:0,scrollY:0,pressedElement:null}}},[b,s,l,n]),R=FCt(p);return o?_.createElement(_.Fragment,null,_.createElement(O8,{onPress:F,onDrag:H,onRelease:E,ref:h,childRef:i},t.children),g&&Ya.createPortal(_.createElement("div",{ref:p,style:{...g,position:"fixed"},className:"k-marquee k-marquee-color"}),(r=R())==null?void 0:r.body)):_.cloneElement(_.Children.only(t.children),{ref:i})};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */var Fo=(t=>(t.copy="copy",t.cut="cut",t.paste="paste",t))(Fo||{});/** + */var To=(t=>(t.copy="copy",t.cut="cut",t.paste="paste",t))(To||{});/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let ANt=class{constructor(r){this.copyHandler=n=>{this.clipboardEvent(Fo.copy,n)},this.cutHandler=n=>{this.clipboardEvent(Fo.cut,n)},this.pasteHandler=n=>{this.clipboardEvent(Fo.paste,n)},this.addEventListeners=n=>{n&&(n.addEventListener(Fo.copy,this.copyHandler),n.addEventListener(Fo.cut,this.cutHandler),n.addEventListener(Fo.paste,this.pasteHandler))},this.removeEventListeners=n=>{n&&(n.removeEventListener(Fo.copy,this.copyHandler),n.removeEventListener(Fo.cut,this.cutHandler),n.removeEventListener(Fo.paste,this.pasteHandler))},this.clipboardEvent=r}};var W1=function(t){return t?new Date(t.getTime()):null},y5=function(t,r){var n=W1(t);return r===0&&n.getHours()===23&&n.setHours(n.getHours()+2),n},wo=function(t,r){var n=W1(t);return n.setDate(n.getDate()+r),y5(n,t.getHours())},Ko=function(t,r,n,i,o,a,s){i===void 0&&(i=0),o===void 0&&(o=0),a===void 0&&(a=0),s===void 0&&(s=0);var l=new Date(t,r,n,i,o,a,s);return t>-1&&t<100&&l.setFullYear(l.getFullYear()-1900),y5(l,i)},f4=function(t){var r=Ko(t.getFullYear(),t.getMonth()+1,1,t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds());return wo(r,-1)},Rv=12,LNt=function(t,r){return t.getMonth()!==r?f4(Ti(t,-1)):t},Ti=function(t,r){var n=W1(t),i=(n.getMonth()+r)%Rv,o=(Rv+i)%Rv;return n.setMonth(n.getMonth()+r),LNt(y5(n,t.getHours()),o)},kB=function(t,r){var n=t.getMonth(),i=Ko(r,n,t.getDate(),t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds());return i.getMonth()===n?i:f4(Ti(i,-1))},a2=function(t,r){return y5(kB(t,t.getFullYear()+r),t.getHours())},Vc=function(t,r){return a2(t,100*r)},fo=function(t,r){return a2(t,10*r)},$E=function(t,r){return wo(t,r*7)},ENt=864e5,S9;(function(t){t[t.Forward=1]="Forward",t[t.Backward=-1]="Backward"})(S9||(S9={}));var _B=function(t,r,n){n===void 0&&(n=S9.Forward);var i=W1(t),o=(r-i.getDay()+7*n)%7;return i.setDate(i.getDate()+o),y5(i,t.getHours())},z9;(function(t){t[t.Sunday=0]="Sunday",t[t.Monday=1]="Monday",t[t.Tuesday=2]="Tuesday",t[t.Wednesday=3]="Wednesday",t[t.Thursday=4]="Thursday",t[t.Friday=5]="Friday",t[t.Saturday=6]="Saturday"})(z9||(z9={}));var ad=function(t,r){return kB(t,r(t.getFullYear()))},ll=function(t){return ad(t,function(r){return r-r%100})},r7=function(t,r){return(ll(r).getFullYear()-ll(t).getFullYear())/100},e2=function(t){return ad(t,function(r){return r-r%10})},i7=function(t,r){return(e2(r).getFullYear()-e2(t).getFullYear())/10},n7=function(t,r){return(r.getFullYear()-t.getFullYear())*12+(r.getMonth()-t.getMonth())},o7=function(t,r){return r.getFullYear()-t.getFullYear()},My=function(t){return Ko(t.getFullYear(),t.getMonth(),1,t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds())},AB=function(t,r){var n=t.getDate(),i=Ko(t.getFullYear(),r,n,t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds());return i.getDate()===n?i:f4(Ti(i,-1))},LB=function(t){return AB(t,0)},fr=function(t){return Ko(t.getFullYear(),t.getMonth(),t.getDate(),0,0,0)},sd=function(t,r){return!t&&!r?!0:t&&r&&t.getTime()===r.getTime()},K7=function(t,r){return!t&&!r?!0:t&&r&&sd(fr(t),fr(r))},ky=function(t){return ad(t,function(r){return r-r%100+90})},EB=function(t){return AB(t,11)},_y=function(t){return ad(t,function(r){return r-r%10+9})},INt=function(t,r){return _B(t,r,S9.Backward)},HNt=function(t,r){return r!==z9.Monday?wo(INt(t,r),4):wo(t,4-(t.getDay()||7))},Ov=function(t,r){var n=Ko(t.getFullYear(),0,1,-6),i=HNt(t,r),o=i.getTime()-n.getTime(),a=Math.floor(o/ENt);return 1+Math.floor(a/7)},DNt=function(t,r){r===void 0&&(r=z9.Monday),t=fr(t);var n=wo(t,-7),i=wo(t,7),o=Ov(t,r);return o===0?Ov(n,r)+1:o===53&&Ov(i,r)>1?1:o};/** + */let LNt=class{constructor(r){this.copyHandler=n=>{this.clipboardEvent(To.copy,n)},this.cutHandler=n=>{this.clipboardEvent(To.cut,n)},this.pasteHandler=n=>{this.clipboardEvent(To.paste,n)},this.addEventListeners=n=>{n&&(n.addEventListener(To.copy,this.copyHandler),n.addEventListener(To.cut,this.cutHandler),n.addEventListener(To.paste,this.pasteHandler))},this.removeEventListeners=n=>{n&&(n.removeEventListener(To.copy,this.copyHandler),n.removeEventListener(To.cut,this.cutHandler),n.removeEventListener(To.paste,this.pasteHandler))},this.clipboardEvent=r}};var N1=function(t){return t?new Date(t.getTime()):null},y5=function(t,r){var n=N1(t);return r===0&&n.getHours()===23&&n.setHours(n.getHours()+2),n},mo=function(t,r){var n=N1(t);return n.setDate(n.getDate()+r),y5(n,t.getHours())},Yo=function(t,r,n,i,o,a,s){i===void 0&&(i=0),o===void 0&&(o=0),a===void 0&&(a=0),s===void 0&&(s=0);var l=new Date(t,r,n,i,o,a,s);return t>-1&&t<100&&l.setFullYear(l.getFullYear()-1900),y5(l,i)},f4=function(t){var r=Yo(t.getFullYear(),t.getMonth()+1,1,t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds());return mo(r,-1)},Rv=12,ENt=function(t,r){return t.getMonth()!==r?f4(Di(t,-1)):t},Di=function(t,r){var n=N1(t),i=(n.getMonth()+r)%Rv,o=(Rv+i)%Rv;return n.setMonth(n.getMonth()+r),ENt(y5(n,t.getHours()),o)},_B=function(t,r){var n=t.getMonth(),i=Yo(r,n,t.getDate(),t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds());return i.getMonth()===n?i:f4(Di(i,-1))},r2=function(t,r){return y5(_B(t,t.getFullYear()+r),t.getHours())},Vc=function(t,r){return r2(t,100*r)},co=function(t,r){return r2(t,10*r)},WE=function(t,r){return mo(t,r*7)},INt=864e5,S9;(function(t){t[t.Forward=1]="Forward",t[t.Backward=-1]="Backward"})(S9||(S9={}));var AB=function(t,r,n){n===void 0&&(n=S9.Forward);var i=N1(t),o=(r-i.getDay()+7*n)%7;return i.setDate(i.getDate()+o),y5(i,t.getHours())},z9;(function(t){t[t.Sunday=0]="Sunday",t[t.Monday=1]="Monday",t[t.Tuesday=2]="Tuesday",t[t.Wednesday=3]="Wednesday",t[t.Thursday=4]="Thursday",t[t.Friday=5]="Friday",t[t.Saturday=6]="Saturday"})(z9||(z9={}));var ad=function(t,r){return _B(t,r(t.getFullYear()))},ll=function(t){return ad(t,function(r){return r-r%100})},r7=function(t,r){return(ll(r).getFullYear()-ll(t).getFullYear())/100},Zn=function(t){return ad(t,function(r){return r-r%10})},i7=function(t,r){return(Zn(r).getFullYear()-Zn(t).getFullYear())/10},n7=function(t,r){return(r.getFullYear()-t.getFullYear())*12+(r.getMonth()-t.getMonth())},o7=function(t,r){return r.getFullYear()-t.getFullYear()},My=function(t){return Yo(t.getFullYear(),t.getMonth(),1,t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds())},LB=function(t,r){var n=t.getDate(),i=Yo(t.getFullYear(),r,n,t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds());return i.getDate()===n?i:f4(Di(i,-1))},EB=function(t){return LB(t,0)},dr=function(t){return Yo(t.getFullYear(),t.getMonth(),t.getDate(),0,0,0)},sd=function(t,r){return!t&&!r?!0:t&&r&&t.getTime()===r.getTime()},K7=function(t,r){return!t&&!r?!0:t&&r&&sd(dr(t),dr(r))},ky=function(t){return ad(t,function(r){return r-r%100+90})},IB=function(t){return LB(t,11)},_y=function(t){return ad(t,function(r){return r-r%10+9})},HNt=function(t,r){return AB(t,r,S9.Backward)},DNt=function(t,r){return r!==z9.Monday?mo(HNt(t,r),4):mo(t,4-(t.getDay()||7))},Ov=function(t,r){var n=Yo(t.getFullYear(),0,1,-6),i=DNt(t,r),o=i.getTime()-n.getTime(),a=Math.floor(o/INt);return 1+Math.floor(a/7)},PNt=function(t,r){r===void 0&&(r=z9.Monday),t=dr(t);var n=mo(t,-7),i=mo(t,7),o=Ov(t,r);return o===0?Ov(n,r)+1:o===53&&Ov(i,r)>1?1:o};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const _C={name:"@progress/kendo-react-dateinputs",productName:"KendoReact",productCodes:["KENDOUIREACT","KENDOUICOMPLETE"],publishDate:1722843994,version:"",licensingDocsUrl:"https://www.telerik.com/kendo-react-ui/components/my-license/?utm_medium=product&utm_source=kendoreact&utm_campaign=kendo-ui-react-purchase-license-keys-warning"};/** + */const AC={name:"@progress/kendo-react-dateinputs",productName:"KendoReact",productCodes:["KENDOUIREACT","KENDOUICOMPLETE"],publishDate:1722843994,version:"",licensingDocsUrl:"https://www.telerik.com/kendo-react-ui/components/my-license/?utm_medium=product&utm_source=kendoreact&utm_campaign=kendo-ui-react-purchase-license-keys-warning"};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const a7=t=>Math.max(t,0);let Bv=class{constructor(r){this.offset=r}},Nv=class{constructor(r){this.skip=r}},PNt=class{constructor(r,n){this.onScrollAction=r,this.onPageAction=n,this.direction="vertical",this.firstLoaded=0,this.lastLoaded=0,this.lastScrollTop=0,this.take=0,this.total=0,this.rowHeightService=null,this.bottomOffset=0,this.topOffset=0}create(r,n,i,o,a=0,s=0,l="vertical"){this.rowHeightService=r,this.firstLoaded=n,this.lastLoaded=n+i,this.take=i,this.total=o,this.lastScrollTop=0,this.topOffset=a,this.bottomOffset=s,this.direction=l;const h=this.rowsForHeight(a),p=a7(n-h);this.onScrollAction(new Bv(this.rowOffset(p))),this.onPageAction(new Nv(p))}onScroll({scrollLeft:r,scrollTop:n,offsetHeight:i,offsetWidth:o}){const a=this.direction==="vertical"?n:r,s=this.direction==="vertical"?i:o;if(this.lastScrollTop===a||!this.rowHeightService)return;const l=this.lastScrollTop>=a;this.lastScrollTop=a;const h=this.rowHeightService.index(a7(a-this.topOffset)),p=this.rowHeightService.index(a7(a+s-this.bottomOffset));if(!l&&p>=this.lastLoaded&&this.lastLoadedMath.max(t,0);let Bv=class{constructor(r){this.offset=r}},Nv=class{constructor(r){this.skip=r}},TNt=class{constructor(r,n){this.onScrollAction=r,this.onPageAction=n,this.direction="vertical",this.firstLoaded=0,this.lastLoaded=0,this.lastScrollTop=0,this.take=0,this.total=0,this.rowHeightService=null,this.bottomOffset=0,this.topOffset=0}create(r,n,i,o,a=0,s=0,l="vertical"){this.rowHeightService=r,this.firstLoaded=n,this.lastLoaded=n+i,this.take=i,this.total=o,this.lastScrollTop=0,this.topOffset=a,this.bottomOffset=s,this.direction=l;const h=this.rowsForHeight(a),p=a7(n-h);this.onScrollAction(new Bv(this.rowOffset(p))),this.onPageAction(new Nv(p))}onScroll({scrollLeft:r,scrollTop:n,offsetHeight:i,offsetWidth:o}){const a=this.direction==="vertical"?n:r,s=this.direction==="vertical"?i:o;if(this.lastScrollTop===a||!this.rowHeightService)return;const l=this.lastScrollTop>=a;this.lastScrollTop=a;const h=this.rowHeightService.index(a7(a-this.topOffset)),p=this.rowHeightService.index(a7(a+s-this.bottomOffset));if(!l&&p>=this.lastLoaded&&this.lastLoadedMath.min(Math.abs(r-t),n),VNt=17,FNt=10,RNt={1:t=>r=>r+t,0:t=>r=>r-t},ONt={1:t=>r=>Math.min(r,t),0:t=>r=>Math.max(r,t)},BNt={1:t=>r=>rr=>r>t},Ay=class q7 extends _.Component{constructor(r){super(r),this.rowHeightService=null,this.scrollContainer=null,this.lastDirection=null,this.lastTotal=0,this.lastTake=0,this.animationInProgress=!1,this.restrictScroll=!1,this.scrollTo=n=>{const i=this.direction==="vertical"?"scrollTop":"scrollLeft";if(!this.scrollContainer)return;const o=this.scrollContainer[i];this.restrictScroll&&i==="scrollTop"&&(!Number.isInteger(o)||!Number.isInteger(n))&&Math.abs(o-n){this.animationInProgress=!1,this.rowHeightService&&this.scrollTo(this.rowHeightService.offset(n))},this.animateToIndex=n=>{if(!this.rowHeightService||!window)return;window.cancelAnimationFrame(this.cancelAnimation);const i=this.rowHeightService.offset(n),o=this.getContainerScrollDirection(i);let{start:a,end:s}=this.scrollRange(i,o);if(a===s)return;const l=this.scrollStep(a,s),h=RNt[o](l),p=ONt[o](s),f=BNt[o](h(s)),g=b=>{this.animationInProgress=!0;const z=h(b);this.scrollTo(p(z)),f(z)?this.cancelAnimation=window.requestAnimationFrame(()=>{g(z)}):this.animationInProgress=!1};this.cancelAnimation=window.requestAnimationFrame(()=>{g(a)})},this.scrollToBottom=()=>{this.rowHeightService&&this.scrollTo(this.rowHeightService.totalHeight()+this.props.bottomOffset)},this.scrollStep=(n,i)=>{const o=this.props.scrollDuration||q7.defaultProps.scrollDuration;return Math.abs(i-n)/(o/VNt)},this.scrollRange=(n,i)=>{const o=this.containerScrollPosition;if(parseInt(`${n}`,10)===parseInt(`${o}`,10))return{start:n,end:n};const a=this.containerMaxScroll(),s=i===0?1:-1,l=TNt(o,n,this.props.maxScrollDifference||0),h=Math.min(n,a);return{start:Math.min(Math.max(h+s*l,0),a),end:h}},this.containerMaxScroll=()=>this.containerScrollSize-this.containerOffsetSize,this.getContainerScrollDirection=n=>n{const i=this.direction==="vertical"?n.itemHeight:n.itemWidth;i!==void 0&&(this.rowHeightService=new Fu(n.total,i,0),this.scrollerService.create(this.rowHeightService,n.skip,n.take,n.total,n.topOffset,this.scrollOffsetSize,this.direction))},this.getContainerProperty=n=>this.scrollContainer?this.scrollContainer[n]:0,this.handleScroll=n=>{if(!this.scrollContainer||!this.rowHeightService)return;const i=n.target;this.scrollerService.onScroll({scrollLeft:i.scrollLeft,scrollTop:i.scrollTop,offsetHeight:i.offsetHeight,offsetWidth:i.offsetWidth});const o=this.rowHeightService.index(this.containerScrollPosition-this.props.topOffset),{onScrollAction:a}=this.props,s={index:o,target:i,scrollAction:this.scrollAction,pageAction:this.pageAction,animationInProgress:this.animationInProgress};this.props.onScroll&&this.props.onScroll.call(void 0,n),a&&a.call(void 0,s),this.scrollAction=void 0,this.pageAction=void 0},this.handleScrollAction=n=>{this.scrollAction=n},this.handlePageAction=n=>{this.pageAction=n},this.scrollerService=new PNt(this.handleScrollAction,this.handlePageAction),this.restrictScroll=Number.parseFloat(_.version)>17}get element(){return this.scrollContainer}get containerOffsetSize(){return this.getContainerProperty(this.direction==="vertical"?"offsetHeight":"offsetWidth")}get containerScrollSize(){return this.getContainerProperty(this.direction==="vertical"?"scrollHeight":"scrollWidth")}get containerScrollPosition(){return this.getContainerProperty(this.direction==="vertical"?"scrollTop":"scrollLeft")}get direction(){return this.props.direction!==void 0?this.props.direction:q7.defaultProps.direction}get scrollOffsetSize(){return this.props.scrollOffsetSize!==void 0?this.props.scrollOffsetSize:q7.defaultProps.scrollOffsetSize}activeIndex(){return this.itemIndex(Math.ceil(this.containerScrollPosition))}itemIndex(r){return this.rowHeightService?this.rowHeightService.index(r):0}itemOffset(r){return this.rowHeightService?this.rowHeightService.offset(r):0}isIndexVisible(r){if(!this.rowHeightService)return!1;const n=this.containerScrollPosition,i=n+this.containerOffsetSize,o=this.rowHeightService.offset(r),a=o+this.rowHeightService.height(r);return o>=n&&a<=i}isListScrolled(r){return this.rowHeightService?this.containerScrollPosition!==this.rowHeightService.offset(r):!1}componentDidMount(){const{onMount:r}=this.props;r&&r.call(void 0,this)}render(){(this.lastTotal!==this.props.total||this.lastDirection!==this.direction||this.lastTake!==this.props.take)&&(this.initServices(),this.lastTotal=this.props.total,this.lastDirection=this.direction,this.lastTake=this.props.take);const r=`${(this.rowHeightService?this.rowHeightService.totalHeight():0)+this.props.bottomOffset}`,n=this.direction==="vertical"?{height:`${r}px`}:{width:`${r}px`},i=Me("k-content k-scrollable",{"k-scrollable-horizontal":this.direction==="horizontal"},this.props.className),o=Me("k-scrollable-placeholder",{"k-scrollable-horizontal-placeholder":this.direction==="horizontal"});return _.createElement("div",{ref:a=>{this.scrollContainer=a},onScroll:this.handleScroll,className:i,tabIndex:this.props.tabIndex,role:this.props.role},this.props.children,_.createElement("div",{style:n,className:o}))}};Ay.propTypes={bottomOffset:B.number.isRequired,className:B.string,direction:B.oneOf(["horizontal","vertical"]),forceScroll:B.bool,itemHeight:B.number,itemWidth:B.number,maxScrollDifference:B.number,onScroll:B.func,onScrollAction:B.func,scrollDuration:B.number,scrollOffsetSize:B.number,skip:B.number.isRequired,tabIndex:B.number,take:B.number.isRequired,topOffset:B.number.isRequired,total:B.number.isRequired,role:B.string},Ay.defaultProps={direction:"vertical",forceScroll:!1,scrollOffsetSize:0,maxScrollDifference:100,scrollDuration:100};let IB=Ay;/** + */const VNt=(t,r,n)=>Math.min(Math.abs(r-t),n),FNt=17,RNt=10,ONt={1:t=>r=>r+t,0:t=>r=>r-t},BNt={1:t=>r=>Math.min(r,t),0:t=>r=>Math.max(r,t)},NNt={1:t=>r=>rr=>r>t},Ay=class q7 extends _.Component{constructor(r){super(r),this.rowHeightService=null,this.scrollContainer=null,this.lastDirection=null,this.lastTotal=0,this.lastTake=0,this.animationInProgress=!1,this.restrictScroll=!1,this.scrollTo=n=>{const i=this.direction==="vertical"?"scrollTop":"scrollLeft";if(!this.scrollContainer)return;const o=this.scrollContainer[i];this.restrictScroll&&i==="scrollTop"&&(!Number.isInteger(o)||!Number.isInteger(n))&&Math.abs(o-n){this.animationInProgress=!1,this.rowHeightService&&this.scrollTo(this.rowHeightService.offset(n))},this.animateToIndex=n=>{if(!this.rowHeightService||!window)return;window.cancelAnimationFrame(this.cancelAnimation);const i=this.rowHeightService.offset(n),o=this.getContainerScrollDirection(i);let{start:a,end:s}=this.scrollRange(i,o);if(a===s)return;const l=this.scrollStep(a,s),h=ONt[o](l),p=BNt[o](s),f=NNt[o](h(s)),g=b=>{this.animationInProgress=!0;const z=h(b);this.scrollTo(p(z)),f(z)?this.cancelAnimation=window.requestAnimationFrame(()=>{g(z)}):this.animationInProgress=!1};this.cancelAnimation=window.requestAnimationFrame(()=>{g(a)})},this.scrollToBottom=()=>{this.rowHeightService&&this.scrollTo(this.rowHeightService.totalHeight()+this.props.bottomOffset)},this.scrollStep=(n,i)=>{const o=this.props.scrollDuration||q7.defaultProps.scrollDuration;return Math.abs(i-n)/(o/FNt)},this.scrollRange=(n,i)=>{const o=this.containerScrollPosition;if(parseInt(`${n}`,10)===parseInt(`${o}`,10))return{start:n,end:n};const a=this.containerMaxScroll(),s=i===0?1:-1,l=VNt(o,n,this.props.maxScrollDifference||0),h=Math.min(n,a);return{start:Math.min(Math.max(h+s*l,0),a),end:h}},this.containerMaxScroll=()=>this.containerScrollSize-this.containerOffsetSize,this.getContainerScrollDirection=n=>n{const i=this.direction==="vertical"?n.itemHeight:n.itemWidth;i!==void 0&&(this.rowHeightService=new Fu(n.total,i,0),this.scrollerService.create(this.rowHeightService,n.skip,n.take,n.total,n.topOffset,this.scrollOffsetSize,this.direction))},this.getContainerProperty=n=>this.scrollContainer?this.scrollContainer[n]:0,this.handleScroll=n=>{if(!this.scrollContainer||!this.rowHeightService)return;const i=n.target;this.scrollerService.onScroll({scrollLeft:i.scrollLeft,scrollTop:i.scrollTop,offsetHeight:i.offsetHeight,offsetWidth:i.offsetWidth});const o=this.rowHeightService.index(this.containerScrollPosition-this.props.topOffset),{onScrollAction:a}=this.props,s={index:o,target:i,scrollAction:this.scrollAction,pageAction:this.pageAction,animationInProgress:this.animationInProgress};this.props.onScroll&&this.props.onScroll.call(void 0,n),a&&a.call(void 0,s),this.scrollAction=void 0,this.pageAction=void 0},this.handleScrollAction=n=>{this.scrollAction=n},this.handlePageAction=n=>{this.pageAction=n},this.scrollerService=new TNt(this.handleScrollAction,this.handlePageAction),this.restrictScroll=Number.parseFloat(_.version)>17}get element(){return this.scrollContainer}get containerOffsetSize(){return this.getContainerProperty(this.direction==="vertical"?"offsetHeight":"offsetWidth")}get containerScrollSize(){return this.getContainerProperty(this.direction==="vertical"?"scrollHeight":"scrollWidth")}get containerScrollPosition(){return this.getContainerProperty(this.direction==="vertical"?"scrollTop":"scrollLeft")}get direction(){return this.props.direction!==void 0?this.props.direction:q7.defaultProps.direction}get scrollOffsetSize(){return this.props.scrollOffsetSize!==void 0?this.props.scrollOffsetSize:q7.defaultProps.scrollOffsetSize}activeIndex(){return this.itemIndex(Math.ceil(this.containerScrollPosition))}itemIndex(r){return this.rowHeightService?this.rowHeightService.index(r):0}itemOffset(r){return this.rowHeightService?this.rowHeightService.offset(r):0}isIndexVisible(r){if(!this.rowHeightService)return!1;const n=this.containerScrollPosition,i=n+this.containerOffsetSize,o=this.rowHeightService.offset(r),a=o+this.rowHeightService.height(r);return o>=n&&a<=i}isListScrolled(r){return this.rowHeightService?this.containerScrollPosition!==this.rowHeightService.offset(r):!1}componentDidMount(){const{onMount:r}=this.props;r&&r.call(void 0,this)}render(){(this.lastTotal!==this.props.total||this.lastDirection!==this.direction||this.lastTake!==this.props.take)&&(this.initServices(),this.lastTotal=this.props.total,this.lastDirection=this.direction,this.lastTake=this.props.take);const r=`${(this.rowHeightService?this.rowHeightService.totalHeight():0)+this.props.bottomOffset}`,n=this.direction==="vertical"?{height:`${r}px`}:{width:`${r}px`},i=ke("k-content k-scrollable",{"k-scrollable-horizontal":this.direction==="horizontal"},this.props.className),o=ke("k-scrollable-placeholder",{"k-scrollable-horizontal-placeholder":this.direction==="horizontal"});return _.createElement("div",{ref:a=>{this.scrollContainer=a},onScroll:this.handleScroll,className:i,tabIndex:this.props.tabIndex,role:this.props.role},this.props.children,_.createElement("div",{style:n,className:o}))}};Ay.propTypes={bottomOffset:B.number.isRequired,className:B.string,direction:B.oneOf(["horizontal","vertical"]),forceScroll:B.bool,itemHeight:B.number,itemWidth:B.number,maxScrollDifference:B.number,onScroll:B.func,onScrollAction:B.func,scrollDuration:B.number,scrollOffsetSize:B.number,skip:B.number.isRequired,tabIndex:B.number,take:B.number.isRequired,topOffset:B.number.isRequired,total:B.number.isRequired,role:B.string},Ay.defaultProps={direction:"vertical",forceScroll:!1,scrollOffsetSize:0,maxScrollDifference:100,scrollDuration:100};let HB=Ay;/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const NNt=(t,r)=>{const n=Object.getOwnPropertyNames(t),i=Object.getOwnPropertyNames(r);if(n.length!==i.length)return!1;for(let o=0;o{const{onClick:n,value:i}=this.props;n&&n.call(void 0,i,r)},this.handleMouseEnter=()=>{const{onMouseEnter:r,value:n}=this.props;r&&r.call(void 0,n)},this.handleMouseLeave=()=>{const{onMouseLeave:r,value:n}=this.props;r&&r.call(void 0,n)}}shouldComponentUpdate(r){const{value:n,...i}=this.props,{value:o,...a}=r;return!((!(n&&o)||n.getTime()===o.getTime())&&NNt(i,a))}render(){const{className:r,formattedValue:n,isWeekend:i,isFocused:o,isInRange:a,isSelected:s,isRangeStart:l,isRangeMid:h,isRangeEnd:p,isRangeSplitStart:f,isRangeSplitEnd:g,isToday:b,isDisabled:z,view:M,value:I,isOtherMonth:F,showOtherMonthDays:H,allowReverse:E,...R}=this.props,W=this.props.activeRangeEnd==="end"&&p,$=this.props.activeRangeEnd==="start"&&l,G=Me("k-calendar-td",{"k-range-start":!F&&!E&&l,"k-range-end":!F&&!E&&p,"k-range-mid":!F&&h,"k-range-split-end":!F&&g,"k-range-split-start":!F&&f,"k-active":$||W,"k-state-pending-focus":o,"k-selected":!F&&(s||l||p),"k-today":!F&&b,"k-weekend":i,"k-disabled":z,"k-other-month":F},r);return!H&&F?_.createElement("td",{role:"gridcell",className:"k-empty k-calendar-td"}):_.createElement("td",{...R,className:G,onClick:this.handleClick,onMouseEnter:this.handleMouseEnter,onMouseLeave:this.handleMouseLeave},_.createElement("span",{className:"k-link"},this.props.children))}};/** + */const $Nt=(t,r)=>{const n=Object.getOwnPropertyNames(t),i=Object.getOwnPropertyNames(r);if(n.length!==i.length)return!1;for(let o=0;o{const{onClick:n,value:i}=this.props;n&&n.call(void 0,i,r)},this.handleMouseEnter=()=>{const{onMouseEnter:r,value:n}=this.props;r&&r.call(void 0,n)},this.handleMouseLeave=()=>{const{onMouseLeave:r,value:n}=this.props;r&&r.call(void 0,n)}}shouldComponentUpdate(r){const{value:n,...i}=this.props,{value:o,...a}=r;return!((!(n&&o)||n.getTime()===o.getTime())&&$Nt(i,a))}render(){const{className:r,formattedValue:n,isWeekend:i,isFocused:o,isInRange:a,isSelected:s,isRangeStart:l,isRangeMid:h,isRangeEnd:p,isRangeSplitStart:f,isRangeSplitEnd:g,isToday:b,isDisabled:z,view:M,value:I,isOtherMonth:F,showOtherMonthDays:H,allowReverse:E,...R}=this.props,W=this.props.activeRangeEnd==="end"&&p,$=this.props.activeRangeEnd==="start"&&l,G=ke("k-calendar-td",{"k-range-start":!F&&!E&&l,"k-range-end":!F&&!E&&p,"k-range-mid":!F&&h,"k-range-split-end":!F&&g,"k-range-split-start":!F&&f,"k-active":$||W,"k-state-pending-focus":o,"k-selected":!F&&(s||l||p),"k-today":!F&&b,"k-weekend":i,"k-disabled":z,"k-other-month":F},r);return!H&&F?_.createElement("td",{role:"gridcell",className:"k-empty k-calendar-td"}):_.createElement("td",{...R,className:G,onClick:this.handleClick,onMouseEnter:this.handleMouseEnter,onMouseLeave:this.handleMouseLeave},_.createElement("span",{className:"k-link"},this.props.children))}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let WNt=class extends _.Component{constructor(){super(...arguments),this.handleClick=r=>{const{onClick:n,firstDate:i,weekDays:o}=this.props;n&&r&&n.call(void 0,i,o||[],r)}}render(){const{className:r,firstDate:n,weekDays:i,...o}=this.props;return _.createElement("td",{className:Me("k-calendar-td",r),...o,onClick:this.handleClick},this.props.children)}};/** + */let jNt=class extends _.Component{constructor(){super(...arguments),this.handleClick=r=>{const{onClick:n,firstDate:i,weekDays:o}=this.props;n&&r&&n.call(void 0,i,o||[],r)}}render(){const{className:r,firstDate:n,weekDays:i,...o}=this.props;return _.createElement("td",{className:ke("k-calendar-td",r),...o,onClick:this.handleClick},this.props.children)}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */var K1=(t=>(t[t.month=0]="month",t[t.year=1]="year",t[t.decade=2]="decade",t[t.century=3]="century",t))(K1||{});/** + */var Y1=(t=>(t[t.month=0]="month",t[t.year=1]="year",t[t.decade=2]="decade",t[t.century=3]="century",t))(Y1||{});/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. @@ -2142,422 +2142,422 @@ rect.legend-mouseover-inactive, * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const WE=(t,r,n)=>r===void 0||n===void 0||r<=t&&t<=n?t:t{const n=W1(t);return n.setHours(r.getHours(),r.getMinutes(),r.getSeconds(),r.getMilliseconds()),n},Co=()=>fr(new Date),Zi=(t,r,n)=>!t||!(r&&r>t||n&&nt===null||!(r&&fr(r)>fr(t)||n&&fr(n){const{start:n,end:i}=r||x5;return!n||!i?!1:n{const i=[];for(let o=t;or.getTime()<=t.getTime()&&t.getTime()<=n.getTime(),YNt=(t,r)=>t.slice(r).concat(t.slice(0,r)),Ra=(t,r,n)=>t&&(r&&tn?W1(n):t),Sa=t=>(r,n="",i={})=>{const o=document.createElement(t);return o.className=n,Object.keys(i).map(a=>o.style[a]=i[a]),typeof r=="string"?o.innerHTML=r||"":(r||[]).forEach(a=>a&&o.appendChild(a)),o};/** + */const jE=(t,r,n)=>r===void 0||n===void 0||r<=t&&t<=n?t:t{const n=N1(t);return n.setHours(r.getHours(),r.getMinutes(),r.getSeconds(),r.getMilliseconds()),n},yo=()=>dr(new Date),Ki=(t,r,n)=>!t||!(r&&r>t||n&&nt===null||!(r&&dr(r)>dr(t)||n&&dr(n){const{start:n,end:i}=r||x5;return!n||!i?!1:n{const i=[];for(let o=t;or.getTime()<=t.getTime()&&t.getTime()<=n.getTime(),XNt=(t,r)=>t.slice(r).concat(t.slice(0,r)),Fa=(t,r,n)=>t&&(r&&tn?N1(n):t),Ca=t=>(r,n="",i={})=>{const o=document.createElement(t);return o.className=n,Object.keys(i).map(a=>o.style[a]=i[a]),typeof r=="string"?o.innerHTML=r||"":(r||[]).forEach(a=>a&&o.appendChild(a)),o};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let DB=class{constructor(r){this.intl=r}getWeekNames(r=!1,n){const i=YNt(this.intl.dateFormatNames({nameType:n??"short",type:"days"}),this.intl.firstDay());return r?[""].concat(i):i}};/** + */let PB=class{constructor(r){this.intl=r}getWeekNames(r=!1,n){const i=XNt(this.intl.dateFormatNames({nameType:n??"short",type:"days"}),this.intl.firstDay());return r?[""].concat(i):i}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const jE=t=>_.createElement("td",{key:t,className:"k-calendar-td k-empty"}," "),Ly=class PB extends _.Component{constructor(){super(...arguments),this.intl=null,this.weekService=null,this.buildWeekNumber=(r,n)=>{if(!this.firstDate(r))return jE(`week-cell-${n}`);const i=this.firstDate(r),o=this.getWeekNumber(i),a=`kendo-react-calendar-week-cell-${o}`,s={className:"k-alt",value:o,firstDate:i,weekDays:r,onClick:this.handleWeekCellClick};return this.props.weekCell?_.createElement(this.props.weekCell,{...s,key:a},o):_.createElement(WNt,{...s,key:a},o)},this.buildRow=r=>r.map((n,i)=>{if(!n)return jE(i);const o={"aria-selected":n.isSelected},a=`kendo-react-calendar-cell-${n.value.getTime()}`,s={...o,...n,isDisabled:!n.isInRange,view:this.props.activeView,showOtherMonthDays:this.props.showOtherMonthDays,allowReverse:this.props.allowReverse,onClick:this.handleClick,onMouseEnter:this.handleMouseEnter,onMouseLeave:this.handleMouseLeave};return this.props.cell?_.createElement(this.props.cell,{...s,key:a},n.formattedValue):_.createElement($Nt,{...s,key:a},n.formattedValue)}),this.firstDate=r=>{const n=this.firstWeekDateContext(r);return n?n.value:null},this.firstWeekDateContext=r=>{if(!this.weekNumber)return null;let n=0,i=r[n];for(;!i&&n{const{onChange:i}=this.props;if(i&&n){const o={value:W1(r),target:this,nativeEvent:n&&n.nativeEvent,syntheticEvent:n};i.call(void 0,o)}},this.handleWeekCellClick=(r,n,i)=>{const{onWeekSelect:o}=this.props,a=n.findIndex(s=>s&&s.value===r);o&&i&&o.call(void 0,r,a,i)},this.handleMouseEnter=r=>{const{onCellEnter:n}=this.props;n&&n.call(void 0,W1(r))},this.handleMouseLeave=r=>{const{onCellLeave:n}=this.props;n&&n.call(void 0,W1(r))}}get min(){return this.props.min}get max(){return this.props.max}get isHorizontal(){return this.props.direction==="horizontal"}get isMonthView(){return this.props.activeView===K1.month}get weekNumber(){return!!(this.props.showWeekNumbers&&this.props.activeView===K1.month)}get selectedDate(){return this.props.selectedDate!==void 0?this.props.selectedDate:PB.defaultProps.selectedDate}render(){this.intl=Ka(this),this.weekService=new DB(this.intl);const r=this.weekService.getWeekNames(this.weekNumber,this.props.weekDaysFormat),n=this.props.service.rowLength(this.weekNumber),i=this.props.service.title(this.props.viewDate),o=Co(),a=Fc(this.props.viewDate,o),s=this.props.service.data({cellUID:this.props.cellUID,min:this.min,max:this.max,focusedDate:this.props.focusedDate,isActiveView:!this.props.bus.canMoveDown(this.props.activeView),selectedDate:this.selectedDate,selectionRange:this.props.selectionRange,viewDate:a});return _.createElement(_.Fragment,null,this.isMonthView&&this.isHorizontal&&_.createElement("thead",{role:"rowgroup",className:"k-calendar-thead"},_.createElement("tr",{role:"row",className:"k-calendar-tr"},r.map((l,h)=>_.createElement("th",{key:h,className:"k-calendar-th"},l)))),_.createElement("tbody",{role:"rowgroup",className:"k-calendar-tbody"},!this.isHorizontal&&_.createElement("tr",{role:"presentation",className:"k-calendar-tr"},_.createElement("th",{scope:"col",colSpan:n,className:"k-calendar-caption"},i)),s.map((l,h)=>_.createElement("tr",{role:"row",className:"k-calendar-tr",key:h},this.weekNumber&&this.buildWeekNumber(l,h),this.buildRow(l)))))}getWeekNumber(r){return!this.weekNumber||!this.intl?null:DNt(r,this.intl.firstDay())}};Ly.propTypes={activeRangeEnd:B.oneOf(["start","end",null]),activeView:B.number.isRequired,cellUID:B.string.isRequired,direction:B.oneOf(["horizontal","vertical"]),focusedDate:B.instanceOf(Date).isRequired,max:B.instanceOf(Date).isRequired,min:B.instanceOf(Date).isRequired,onChange:B.func,selectedDate:B.oneOfType([B.instanceOf(Date),B.arrayOf(B.instanceOf(Date))]),showWeekNumbers:B.bool,showOtherMonthDays:B.bool,viewDate:B.instanceOf(Date).isRequired},Ly.defaultProps={direction:"vertical",selectedDate:Co(),showWeekNumbers:!1};let TB=Ly;Wl(TB);/** + */const GE=t=>_.createElement("td",{key:t,className:"k-calendar-td k-empty"}," "),Ly=class TB extends _.Component{constructor(){super(...arguments),this.intl=null,this.weekService=null,this.buildWeekNumber=(r,n)=>{if(!this.firstDate(r))return GE(`week-cell-${n}`);const i=this.firstDate(r),o=this.getWeekNumber(i),a=`kendo-react-calendar-week-cell-${o}`,s={className:"k-alt",value:o,firstDate:i,weekDays:r,onClick:this.handleWeekCellClick};return this.props.weekCell?_.createElement(this.props.weekCell,{...s,key:a},o):_.createElement(jNt,{...s,key:a},o)},this.buildRow=r=>r.map((n,i)=>{if(!n)return GE(i);const o={"aria-selected":n.isSelected},a=`kendo-react-calendar-cell-${n.value.getTime()}`,s={...o,...n,isDisabled:!n.isInRange,view:this.props.activeView,showOtherMonthDays:this.props.showOtherMonthDays,allowReverse:this.props.allowReverse,onClick:this.handleClick,onMouseEnter:this.handleMouseEnter,onMouseLeave:this.handleMouseLeave};return this.props.cell?_.createElement(this.props.cell,{...s,key:a},n.formattedValue):_.createElement(WNt,{...s,key:a},n.formattedValue)}),this.firstDate=r=>{const n=this.firstWeekDateContext(r);return n?n.value:null},this.firstWeekDateContext=r=>{if(!this.weekNumber)return null;let n=0,i=r[n];for(;!i&&n{const{onChange:i}=this.props;if(i&&n){const o={value:N1(r),target:this,nativeEvent:n&&n.nativeEvent,syntheticEvent:n};i.call(void 0,o)}},this.handleWeekCellClick=(r,n,i)=>{const{onWeekSelect:o}=this.props,a=n.findIndex(s=>s&&s.value===r);o&&i&&o.call(void 0,r,a,i)},this.handleMouseEnter=r=>{const{onCellEnter:n}=this.props;n&&n.call(void 0,N1(r))},this.handleMouseLeave=r=>{const{onCellLeave:n}=this.props;n&&n.call(void 0,N1(r))}}get min(){return this.props.min}get max(){return this.props.max}get isHorizontal(){return this.props.direction==="horizontal"}get isMonthView(){return this.props.activeView===Y1.month}get weekNumber(){return!!(this.props.showWeekNumbers&&this.props.activeView===Y1.month)}get selectedDate(){return this.props.selectedDate!==void 0?this.props.selectedDate:TB.defaultProps.selectedDate}render(){this.intl=Xa(this),this.weekService=new PB(this.intl);const r=this.weekService.getWeekNames(this.weekNumber,this.props.weekDaysFormat),n=this.props.service.rowLength(this.weekNumber),i=this.props.service.title(this.props.viewDate),o=yo(),a=Fc(this.props.viewDate,o),s=this.props.service.data({cellUID:this.props.cellUID,min:this.min,max:this.max,focusedDate:this.props.focusedDate,isActiveView:!this.props.bus.canMoveDown(this.props.activeView),selectedDate:this.selectedDate,selectionRange:this.props.selectionRange,viewDate:a});return _.createElement(_.Fragment,null,this.isMonthView&&this.isHorizontal&&_.createElement("thead",{role:"rowgroup",className:"k-calendar-thead"},_.createElement("tr",{role:"row",className:"k-calendar-tr"},r.map((l,h)=>_.createElement("th",{key:h,className:"k-calendar-th"},l)))),_.createElement("tbody",{role:"rowgroup",className:"k-calendar-tbody"},!this.isHorizontal&&_.createElement("tr",{role:"presentation",className:"k-calendar-tr"},_.createElement("th",{scope:"col",colSpan:n,className:"k-calendar-caption"},i)),s.map((l,h)=>_.createElement("tr",{role:"row",className:"k-calendar-tr",key:h},this.weekNumber&&this.buildWeekNumber(l,h),this.buildRow(l)))))}getWeekNumber(r){return!this.weekNumber||!this.intl?null:PNt(r,this.intl.firstDay())}};Ly.propTypes={activeRangeEnd:B.oneOf(["start","end",null]),activeView:B.number.isRequired,cellUID:B.string.isRequired,direction:B.oneOf(["horizontal","vertical"]),focusedDate:B.instanceOf(Date).isRequired,max:B.instanceOf(Date).isRequired,min:B.instanceOf(Date).isRequired,onChange:B.func,selectedDate:B.oneOfType([B.instanceOf(Date),B.arrayOf(B.instanceOf(Date))]),showWeekNumbers:B.bool,showOtherMonthDays:B.bool,viewDate:B.instanceOf(Date).isRequired},Ly.defaultProps={direction:"vertical",selectedDate:yo(),showWeekNumbers:!1};let VB=Ly;Wl(VB);/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let XNt=class extends _.PureComponent{render(){const{view:r,...n}=this.props;return _.createElement(ei,{type:"button",fillMode:"flat",themeColor:"primary",...n},this.props.children)}};/** + */let KNt=class extends _.PureComponent{render(){const{view:r,...n}=this.props;return _.createElement(Jr,{type:"button",fillMode:"flat",themeColor:"primary",...n},this.props.children)}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const Ey=class Z7 extends _.Component{constructor(){super(...arguments),this.getTitle=()=>{if(!this.props.currentDate)return"";const r=this.rangeLength-1,n=this.props.service.title(this.props.currentDate),i=this.props.service.addToDate(this.props.currentDate,r);return r<1||!this.props.service.isInRange(i,this.min,this.max)?n:`${n} - ${this.props.service.title(i)}`},this.handleTitleClick=r=>{this.canMoveUp&&this.props.bus.moveUp(this.props.activeView,r)}}get min(){return this.props.min!==void 0?this.props.min:Z7.defaultProps.min}get max(){return this.props.max!==void 0?this.props.max:Z7.defaultProps.max}get rangeLength(){return this.props.rangeLength!==void 0?this.props.rangeLength:Z7.defaultProps.rangeLength}get canMoveUp(){return this.props.bus.canMoveUp(this.props.activeView)}render(){const r=this.getTitle(),n=Me("k-calendar-title"),i={children:r,value:r,view:this.props.activeView,className:n,onClick:this.handleTitleClick,disabled:!this.canMoveUp},o={headerTitleProps:i,commands:this.props.commands},a=this.props.headerTitle?_.createElement(this.props.headerTitle,{...i},r):_.createElement(XNt,{...i},r),s=this.props.header?_.createElement(this.props.header,{...o}):_.createElement(_.Fragment,null,a,_.createElement("span",{className:"k-spacer"}),_.createElement("span",{className:"k-calendar-nav"},this.props.commands));return _.createElement("div",{className:Me("k-calendar-header",{"k-vstack":this.props.verticalView})},s)}};Ey.propTypes={activeView:B.number.isRequired,currentDate:B.instanceOf(Date).isRequired,max:B.instanceOf(Date).isRequired,min:B.instanceOf(Date).isRequired,rangeLength:B.number},Ey.defaultProps={rangeLength:1,min:b5,max:w5};let VB=Ey;Ri(VB);/** + */const Ey=class Z7 extends _.Component{constructor(){super(...arguments),this.getTitle=()=>{if(!this.props.currentDate)return"";const r=this.rangeLength-1,n=this.props.service.title(this.props.currentDate),i=this.props.service.addToDate(this.props.currentDate,r);return r<1||!this.props.service.isInRange(i,this.min,this.max)?n:`${n} - ${this.props.service.title(i)}`},this.handleTitleClick=r=>{this.canMoveUp&&this.props.bus.moveUp(this.props.activeView,r)}}get min(){return this.props.min!==void 0?this.props.min:Z7.defaultProps.min}get max(){return this.props.max!==void 0?this.props.max:Z7.defaultProps.max}get rangeLength(){return this.props.rangeLength!==void 0?this.props.rangeLength:Z7.defaultProps.rangeLength}get canMoveUp(){return this.props.bus.canMoveUp(this.props.activeView)}render(){const r=this.getTitle(),n=ke("k-calendar-title"),i={children:r,value:r,view:this.props.activeView,className:n,onClick:this.handleTitleClick,disabled:!this.canMoveUp},o={headerTitleProps:i,commands:this.props.commands},a=this.props.headerTitle?_.createElement(this.props.headerTitle,{...i},r):_.createElement(KNt,{...i},r),s=this.props.header?_.createElement(this.props.header,{...o}):_.createElement(_.Fragment,null,a,_.createElement("span",{className:"k-spacer"}),_.createElement("span",{className:"k-calendar-nav"},this.props.commands));return _.createElement("div",{className:ke("k-calendar-header",{"k-vstack":this.props.verticalView})},s)}};Ey.propTypes={activeView:B.number.isRequired,currentDate:B.instanceOf(Date).isRequired,max:B.instanceOf(Date).isRequired,min:B.instanceOf(Date).isRequired,rangeLength:B.number},Ey.defaultProps={rangeLength:1,min:b5,max:w5};let FB=Ey;Vi(FB);/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const KNt="multiviewcalendar.prevView",qNt="multiviewcalendar.nextView",mc="dateinput.increment",yc="dateinput.decrement",Iy="dateinput.clear",Hy="calendar.today",Dy="datepicker.toggleCalendar",ZNt="daterangepicker.swapStartEnd",JNt="daterangepicker.start",QNt="daterangepicker.end",t$t="daterangepicker.separator",e$t="datetimepicker.toggleDateTimeSelector",r$t="timepicker.now",i$t="timepicker.selectNow",n$t="timepicker.cancel",o$t="timepicker.set",a$t="timepicker.toggleTimeSelector",s$t="timepicker.toggleClock",l$t="datetimepicker.date",c$t="datetimepicker.time",h$t="datetimepicker.cancel",u$t="datetimepicker.set",p$t="daterangepicker.cancel",d$t="daterangepicker.set",o0={[Hy]:"Today",[r$t]:"NOW",[o$t]:"Set",[n$t]:"Cancel",[l$t]:"Date",[c$t]:"Time",[h$t]:"Cancel",[u$t]:"Set",[p$t]:"Cancel",[d$t]:"Set",[JNt]:"Start",[QNt]:"End",[t$t]:" ",[i$t]:"Select Now",[a$t]:"Toggle TimeSelector",[s$t]:"Toggle Clock",[mc]:"Increase value",[yc]:"Decrease value",[Iy]:"clear",[Dy]:"Toggle calendar",[KNt]:"Navigate to previous view",[qNt]:"Navigate to next view",[ZNt]:"Swap start and end values",[e$t]:"Toggle date-time selector"};/** + */const qNt="multiviewcalendar.prevView",ZNt="multiviewcalendar.nextView",mc="dateinput.increment",yc="dateinput.decrement",Iy="dateinput.clear",Hy="calendar.today",Dy="datepicker.toggleCalendar",JNt="daterangepicker.swapStartEnd",QNt="daterangepicker.start",t$t="daterangepicker.end",e$t="daterangepicker.separator",r$t="datetimepicker.toggleDateTimeSelector",i$t="timepicker.now",n$t="timepicker.selectNow",o$t="timepicker.cancel",a$t="timepicker.set",s$t="timepicker.toggleTimeSelector",l$t="timepicker.toggleClock",c$t="datetimepicker.date",h$t="datetimepicker.time",u$t="datetimepicker.cancel",p$t="datetimepicker.set",d$t="daterangepicker.cancel",f$t="daterangepicker.set",o0={[Hy]:"Today",[i$t]:"NOW",[a$t]:"Set",[o$t]:"Cancel",[c$t]:"Date",[h$t]:"Time",[u$t]:"Cancel",[p$t]:"Set",[d$t]:"Cancel",[f$t]:"Set",[QNt]:"Start",[t$t]:"End",[e$t]:" ",[n$t]:"Select Now",[s$t]:"Toggle TimeSelector",[l$t]:"Toggle Clock",[mc]:"Increase value",[yc]:"Decrease value",[Iy]:"clear",[Dy]:"Toggle calendar",[qNt]:"Navigate to previous view",[ZNt]:"Navigate to next view",[JNt]:"Swap start and end values",[r$t]:"Toggle date-time selector"};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const Py=class Ty extends _.Component{constructor(){super(...arguments),this.localization=null,this.handleClick=r=>{if(this.todayIsInRange&&this.props.onClick){const n={syntheticEvent:r,nativeEvent:r.nativeEvent,value:Ra(Co(),this.min,this.max),target:this,isTodayClick:!0};this.props.onClick.call(void 0,n)}}}get min(){return this.props.min!==void 0?this.props.min:Ty.defaultProps.min}get max(){return this.props.max!==void 0?this.props.max:Ty.defaultProps.max}get todayIsInRange(){return Zi(Co(),fr(this.min),fr(this.max))}render(){this.localization=si(this);const r=this.localization.toLanguageString(Hy,o0[Hy]),n=Me("k-calendar-nav-today",{"k-disabled":this.props.disabled});return _.createElement(ei,{className:n,onClick:this.handleClick,tabIndex:this.props.tabIndex,fillMode:"flat",themeColor:"base",role:"link"},r)}};Py.propTypes={max:B.instanceOf(Date).isRequired,min:B.instanceOf(Date).isRequired,onClick:B.func,disabled:B.bool},Py.defaultProps={min:b5,max:w5};let FB=Py;Ri(FB);/** + */const Py=class Ty extends _.Component{constructor(){super(...arguments),this.localization=null,this.handleClick=r=>{if(this.todayIsInRange&&this.props.onClick){const n={syntheticEvent:r,nativeEvent:r.nativeEvent,value:Fa(yo(),this.min,this.max),target:this,isTodayClick:!0};this.props.onClick.call(void 0,n)}}}get min(){return this.props.min!==void 0?this.props.min:Ty.defaultProps.min}get max(){return this.props.max!==void 0?this.props.max:Ty.defaultProps.max}get todayIsInRange(){return Ki(yo(),dr(this.min),dr(this.max))}render(){this.localization=ai(this);const r=this.localization.toLanguageString(Hy,o0[Hy]),n=ke("k-calendar-nav-today",{"k-disabled":this.props.disabled});return _.createElement(Jr,{className:n,onClick:this.handleClick,tabIndex:this.props.tabIndex,fillMode:"flat",themeColor:"base",role:"link"},r)}};Py.propTypes={max:B.instanceOf(Date).isRequired,min:B.instanceOf(Date).isRequired,onClick:B.func,disabled:B.bool},Py.defaultProps={min:b5,max:w5};let RB=Py;Vi(RB);/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const f$t=5,Vy=class RB extends _.Component{constructor(r){super(r),this.virtualization=null,this.calendarView=null,this.table=null,this.intl=null,this.bottomOffset=0,this.viewOffset=0,this.viewHeight=0,this._element=null,this.isActive=!1,this.animateToIndex=!0,this.shouldScroll=!1,this.weekService=null,this.focusActiveDate=()=>{if(!this._element)return;const n=this._element.querySelector("td.k-focus"),i=this._element.querySelector(".k-state-pending-focus");n&&n[0]&&n[0].classList.remove("k-focus"),i&&i.classList.add("k-focus"),this.isActive=!0},this.blurActiveDate=()=>{if(!this._element)return;const n=this._element.querySelector("td.k-focus");n&&n.classList.remove("k-focus"),this.isActive=!1},this.handleVirtualizationMount=n=>{if(this.virtualization=n,this.virtualization&&this.table){this.table.style.transform=`translateY(${this.viewOffset}px)`;const i=Ra(this.props.focusedDate,this.props.min,this.props.max),o=this.props.service.skip(i,this.props.min);this.virtualization.scrollToIndex(o)}},this.buildMonthView=(n,i)=>_.createElement("table",{key:"calendar-view-list-weekdays",className:"k-calendar-table k-calendar-weekdays",role:"grid",tabIndex:this.props.tabIndex},_.createElement("colgroup",null,n.map((o,a)=>_.createElement("col",{key:a}))),_.createElement("thead",{className:"k-calendar-thead"},_.createElement("tr",{className:"k-calendar-tr"},i.map((o,a)=>_.createElement("th",{key:a,className:"k-calendar-th"},o))))),this.buildDates=(n,i)=>{const o=this.props.cellUID;return _.createElement("table",{className:"k-calendar-table",ref:a=>this.table=a,role:"grid",tabIndex:this.props.tabIndex,"aria-activedescendant":o+this.props.focusedDate.getTime()},_.createElement("colgroup",null,n.map((a,s)=>_.createElement("col",{key:s}))),i.map(a=>_.createElement(TB,{ref:s=>{this.calendarView||(this.calendarView=s)},key:a.getTime(),activeView:this.props.activeView,viewDate:a,min:this.props.min,max:this.props.max,cellUID:o,focusedDate:this.props.focusedDate,cell:this.props.cell,selectedDate:this.props.value,showWeekNumbers:this.weekNumber,onChange:this.handleDateChange,bus:this.props.bus,service:this.props.service,weekCell:this.props.weekCell,showOtherMonthDays:this.props.showOtherMonthDays})))},this.calculateHeights=()=>{if(!this.props.dom)return;const n=this.props.activeView===K1.month?this.props.dom.scrollableContentHeight:this.props.dom.scrollableYearContentHeight;this.bottomOffset=n-this.props.dom.viewHeight(this.props.activeView),this.viewOffset=-1*this.props.dom.headerHeight,this.viewHeight=this.props.dom.viewHeight(this.props.activeView)||1},this.getTake=(n,i)=>Math.min(i-n,this.take),this.handleScrollAction=({index:n,scrollAction:i,pageAction:o})=>{const a=o?o.skip:this.state.skip;if((this.state.index!==n||this.state.skip!==a)&&this.setState({index:n,skip:a}),this.table&&i){const s=`translateY(${i.offset}px)`;this.table.style.transform=s}},this.handleTodayClick=n=>{this.shouldScroll=!0,this.handleDateChange.call(void 0,n,!0)},this.handleDateChange=(n,i=!1)=>{const{onChange:o}=this.props;if(o){const a={syntheticEvent:n.syntheticEvent,nativeEvent:n.nativeEvent,value:W1(n.value),target:this,isTodayClick:i};o.call(void 0,a)}},this.lastView=this.props.activeView,this.lastFocus=this.props.focusedDate,this.state={skip:this.props.service.skip(this.props.focusedDate,this.props.min),index:this.props.service.skip(this.props.focusedDate,this.props.min)}}get element(){return this._element}get weekNames(){return this.intl=Ka(this),this.weekService=new DB(this.intl),this.weekService.getWeekNames(this.weekNumber,this.props.weekDaysFormat)}get weekNumber(){return!!(this.props.showWeekNumbers&&this.props.activeView===K1.month)}get take(){return this.props.take!==void 0?this.props.take:RB.defaultProps.take}get animate(){return!!(this.props.smoothScroll&&this.animateToIndex)}get todayIsInRange(){return Zi(Co(),fr(this.props.min),fr(this.props.max))}componentDidUpdate(r,n){this.shouldScroll=!1,this.indexToScroll!==void 0&&this.virtualization&&this.virtualization[this.animate?"animateToIndex":"scrollToIndex"](this.indexToScroll),this.isActive&&this.focusActiveDate(),this.lastView=this.props.activeView,this.indexToScroll=void 0}render(){this.calculateHeights();const r=this.lastView!==this.props.activeView,n=Ra(this.props.focusedDate,this.props.min,this.props.max),i=r?this.props.service.skip(n,this.props.min):this.state.skip,o=this.props.service.total(this.props.min,this.props.max),a=this.getTake(i,o),s=this.props.service.addToDate(this.props.min,i),l=this.props.service.addToDate(this.props.min,this.state.index),h=new Array(this.props.service.rowLength(this.weekNumber)).fill(""),p=this.props.activeView!==this.lastView;this.animateToIndex=!p,(p||!K7(this.lastFocus,n)||this.shouldScroll||!this.props.shouldScroll||this.props.shouldScroll())&&(this.indexToScroll=this.props.service.skip(n,this.props.min)),this.lastFocus=n;const f=Me("k-calendar-view k-vstack",{"k-calendar-monthview":this.props.activeView===K1.month,"k-calendar-yearview":this.props.activeView===K1.year,"k-calendar-decadeview":this.props.activeView===K1.decade,"k-calendar-centuryview":this.props.activeView===K1.century}),g=this.buildDates(h,this.props.service.datesList(s,a)),b=_.createElement(_.Fragment,null,_.createElement(VB,{key:"calendar-view-list-header",currentDate:l,min:this.props.min,max:this.props.max,activeView:this.props.activeView,bus:this.props.bus,service:this.props.service,headerTitle:this.props.headerTitle,header:this.props.header,commands:_.createElement(_.Fragment,null,_.createElement(FB,{min:this.props.min,max:this.props.max,onClick:this.handleTodayClick,disabled:!this.todayIsInRange,tabIndex:this.props.tabIndex}))}),this.props.activeView===K1.month&&this.buildMonthView(h,this.weekNames),_.createElement(IB,{key:"calendar-view-list-content",skip:i,take:this.take,total:o,itemHeight:this.viewHeight,topOffset:this.viewOffset,bottomOffset:this.bottomOffset,scrollOffsetSize:this.viewOffset,maxScrollDifference:this.viewHeight,onScroll:this.props.onScroll,onScrollAction:this.handleScrollAction,onMount:this.handleVirtualizationMount,children:g,tabIndex:this.props.tabIndex}));return _.createElement("div",{ref:z=>{this._element=z},className:f},this.props.dom.didCalculate?b:null)}};Vy.propTypes={activeView:B.number.isRequired,bottomOffset:B.number,cellUID:B.string.isRequired,focusedDate:B.instanceOf(Date).isRequired,max:B.instanceOf(Date).isRequired,min:B.instanceOf(Date).isRequired,onChange:B.func,showWeekNumbers:B.bool,smoothScroll:B.bool,take:B.number,value:B.instanceOf(Date),viewHeight:B.number,viewOffset:B.number,weekDaysFormat:B.oneOf(["short","abbreviated","narrow"]),tabIndex:B.number},Vy.defaultProps={take:f$t,showWeekNumbers:!1,weekDaysFormat:"short",smoothScroll:!0};let OB=Vy;Wl(OB);/** + */const v$t=5,Vy=class OB extends _.Component{constructor(r){super(r),this.virtualization=null,this.calendarView=null,this.table=null,this.intl=null,this.bottomOffset=0,this.viewOffset=0,this.viewHeight=0,this._element=null,this.isActive=!1,this.animateToIndex=!0,this.shouldScroll=!1,this.weekService=null,this.focusActiveDate=()=>{if(!this._element)return;const n=this._element.querySelector("td.k-focus"),i=this._element.querySelector(".k-state-pending-focus");n&&n[0]&&n[0].classList.remove("k-focus"),i&&i.classList.add("k-focus"),this.isActive=!0},this.blurActiveDate=()=>{if(!this._element)return;const n=this._element.querySelector("td.k-focus");n&&n.classList.remove("k-focus"),this.isActive=!1},this.handleVirtualizationMount=n=>{if(this.virtualization=n,this.virtualization&&this.table){this.table.style.transform=`translateY(${this.viewOffset}px)`;const i=Fa(this.props.focusedDate,this.props.min,this.props.max),o=this.props.service.skip(i,this.props.min);this.virtualization.scrollToIndex(o)}},this.buildMonthView=(n,i)=>_.createElement("table",{key:"calendar-view-list-weekdays",className:"k-calendar-table k-calendar-weekdays",role:"grid",tabIndex:this.props.tabIndex},_.createElement("colgroup",null,n.map((o,a)=>_.createElement("col",{key:a}))),_.createElement("thead",{className:"k-calendar-thead"},_.createElement("tr",{className:"k-calendar-tr"},i.map((o,a)=>_.createElement("th",{key:a,className:"k-calendar-th"},o))))),this.buildDates=(n,i)=>{const o=this.props.cellUID;return _.createElement("table",{className:"k-calendar-table",ref:a=>this.table=a,role:"grid",tabIndex:this.props.tabIndex,"aria-activedescendant":o+this.props.focusedDate.getTime()},_.createElement("colgroup",null,n.map((a,s)=>_.createElement("col",{key:s}))),i.map(a=>_.createElement(VB,{ref:s=>{this.calendarView||(this.calendarView=s)},key:a.getTime(),activeView:this.props.activeView,viewDate:a,min:this.props.min,max:this.props.max,cellUID:o,focusedDate:this.props.focusedDate,cell:this.props.cell,selectedDate:this.props.value,showWeekNumbers:this.weekNumber,onChange:this.handleDateChange,bus:this.props.bus,service:this.props.service,weekCell:this.props.weekCell,showOtherMonthDays:this.props.showOtherMonthDays})))},this.calculateHeights=()=>{if(!this.props.dom)return;const n=this.props.activeView===Y1.month?this.props.dom.scrollableContentHeight:this.props.dom.scrollableYearContentHeight;this.bottomOffset=n-this.props.dom.viewHeight(this.props.activeView),this.viewOffset=-1*this.props.dom.headerHeight,this.viewHeight=this.props.dom.viewHeight(this.props.activeView)||1},this.getTake=(n,i)=>Math.min(i-n,this.take),this.handleScrollAction=({index:n,scrollAction:i,pageAction:o})=>{const a=o?o.skip:this.state.skip;if((this.state.index!==n||this.state.skip!==a)&&this.setState({index:n,skip:a}),this.table&&i){const s=`translateY(${i.offset}px)`;this.table.style.transform=s}},this.handleTodayClick=n=>{this.shouldScroll=!0,this.handleDateChange.call(void 0,n,!0)},this.handleDateChange=(n,i=!1)=>{const{onChange:o}=this.props;if(o){const a={syntheticEvent:n.syntheticEvent,nativeEvent:n.nativeEvent,value:N1(n.value),target:this,isTodayClick:i};o.call(void 0,a)}},this.lastView=this.props.activeView,this.lastFocus=this.props.focusedDate,this.state={skip:this.props.service.skip(this.props.focusedDate,this.props.min),index:this.props.service.skip(this.props.focusedDate,this.props.min)}}get element(){return this._element}get weekNames(){return this.intl=Xa(this),this.weekService=new PB(this.intl),this.weekService.getWeekNames(this.weekNumber,this.props.weekDaysFormat)}get weekNumber(){return!!(this.props.showWeekNumbers&&this.props.activeView===Y1.month)}get take(){return this.props.take!==void 0?this.props.take:OB.defaultProps.take}get animate(){return!!(this.props.smoothScroll&&this.animateToIndex)}get todayIsInRange(){return Ki(yo(),dr(this.props.min),dr(this.props.max))}componentDidUpdate(r,n){this.shouldScroll=!1,this.indexToScroll!==void 0&&this.virtualization&&this.virtualization[this.animate?"animateToIndex":"scrollToIndex"](this.indexToScroll),this.isActive&&this.focusActiveDate(),this.lastView=this.props.activeView,this.indexToScroll=void 0}render(){this.calculateHeights();const r=this.lastView!==this.props.activeView,n=Fa(this.props.focusedDate,this.props.min,this.props.max),i=r?this.props.service.skip(n,this.props.min):this.state.skip,o=this.props.service.total(this.props.min,this.props.max),a=this.getTake(i,o),s=this.props.service.addToDate(this.props.min,i),l=this.props.service.addToDate(this.props.min,this.state.index),h=new Array(this.props.service.rowLength(this.weekNumber)).fill(""),p=this.props.activeView!==this.lastView;this.animateToIndex=!p,(p||!K7(this.lastFocus,n)||this.shouldScroll||!this.props.shouldScroll||this.props.shouldScroll())&&(this.indexToScroll=this.props.service.skip(n,this.props.min)),this.lastFocus=n;const f=ke("k-calendar-view k-vstack",{"k-calendar-monthview":this.props.activeView===Y1.month,"k-calendar-yearview":this.props.activeView===Y1.year,"k-calendar-decadeview":this.props.activeView===Y1.decade,"k-calendar-centuryview":this.props.activeView===Y1.century}),g=this.buildDates(h,this.props.service.datesList(s,a)),b=_.createElement(_.Fragment,null,_.createElement(FB,{key:"calendar-view-list-header",currentDate:l,min:this.props.min,max:this.props.max,activeView:this.props.activeView,bus:this.props.bus,service:this.props.service,headerTitle:this.props.headerTitle,header:this.props.header,commands:_.createElement(_.Fragment,null,_.createElement(RB,{min:this.props.min,max:this.props.max,onClick:this.handleTodayClick,disabled:!this.todayIsInRange,tabIndex:this.props.tabIndex}))}),this.props.activeView===Y1.month&&this.buildMonthView(h,this.weekNames),_.createElement(HB,{key:"calendar-view-list-content",skip:i,take:this.take,total:o,itemHeight:this.viewHeight,topOffset:this.viewOffset,bottomOffset:this.bottomOffset,scrollOffsetSize:this.viewOffset,maxScrollDifference:this.viewHeight,onScroll:this.props.onScroll,onScrollAction:this.handleScrollAction,onMount:this.handleVirtualizationMount,children:g,tabIndex:this.props.tabIndex}));return _.createElement("div",{ref:z=>{this._element=z},className:f},this.props.dom.didCalculate?b:null)}};Vy.propTypes={activeView:B.number.isRequired,bottomOffset:B.number,cellUID:B.string.isRequired,focusedDate:B.instanceOf(Date).isRequired,max:B.instanceOf(Date).isRequired,min:B.instanceOf(Date).isRequired,onChange:B.func,showWeekNumbers:B.bool,smoothScroll:B.bool,take:B.number,value:B.instanceOf(Date),viewHeight:B.number,viewOffset:B.number,weekDaysFormat:B.oneOf(["short","abbreviated","narrow"]),tabIndex:B.number},Vy.defaultProps={take:v$t,showWeekNumbers:!1,weekDaysFormat:"short",smoothScroll:!0};let BB=Vy;Wl(BB);/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let v$t=class extends _.Component{constructor(){super(...arguments),this.handleClick=r=>{const{onClick:n,value:i}=this.props;n&&n.call(void 0,i,r)}}render(){const{isRangeStart:r,value:n,text:i,...o}=this.props;return _.createElement("li",{...o,onClick:this.handleClick},_.createElement("span",{className:Me({"k-calendar-navigation-marker":r})},this.props.children))}};/** + */let g$t=class extends _.Component{constructor(){super(...arguments),this.handleClick=r=>{const{onClick:n,value:i}=this.props;n&&n.call(void 0,i,r)}}render(){const{isRangeStart:r,value:n,text:i,...o}=this.props;return _.createElement("li",{...o,onClick:this.handleClick},_.createElement("span",{className:ke({"k-calendar-navigation-marker":r})},this.props.children))}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const g$t=30,Fy=class BB extends _.Component{constructor(r){super(r),this.virtualization=null,this.list=null,this.itemHeight=0,this.topOffset=0,this.maxViewHeight=0,this.bottomOffset=0,this.handleVirtualizationMount=o=>{if(this.virtualization=o,this.virtualization&&this.list){this.list.style.transform=`translateY(${this.topOffset}px)`;const a=Ra(this.props.focusedDate,this.props.min,this.props.max),s=this.props.service.skip(a,this.props.min);this.virtualization.scrollToIndex(s)}},this.buildNavigationItem=o=>{const a=this.props.service.navigationTitle(o),s=this.props.service.isRangeStart(o),l=`kendo-react-calendar-nav-item-${o.getTime()}`,h={text:a,value:o,isRangeStart:s,view:this.props.activeView,onClick:this.handleDateChange};return this.props.navigationItem?_.createElement(this.props.navigationItem,{...h,key:l},a):_.createElement(v$t,{...h,key:l},a)},this.calculateHeights=()=>{const o=this.props.dom.calendarHeight;this.itemHeight=this.props.dom.navigationItemHeight||1,this.maxViewHeight=this.props.dom.monthViewHeight,this.topOffset=(o-this.itemHeight)/2,this.bottomOffset=o-this.itemHeight},this.handleDateChange=(o,a)=>{const{onChange:s}=this.props;if(s&&a){const l={value:W1(o),target:this,nativeEvent:a&&a.nativeEvent,syntheticEvent:a};s.call(void 0,l)}},this.handleScrollAction=({scrollAction:o,pageAction:a})=>{const s=a?a.skip:this.state.skip;if(this.state.skip!==s&&this.setState({skip:s}),this.list&&o){const l=`translateY(${o.offset}px)`;this.list.style.transform=l}},this.lastView=this.props.activeView,this.lastFocus=this.props.focusedDate;const n=this.props.service.skip(this.props.focusedDate,this.props.min),i=this.props.service.total(this.props.min,this.props.max);this.state={skip:n-this.getTake(n,i)>0?n:0}}get take(){return this.props.take!==void 0?this.props.take:BB.defaultProps.take}componentDidUpdate(r,n){this.indexToScroll!==void 0&&this.virtualization&&this.virtualization.scrollToIndex(this.indexToScroll),this.lastView=this.props.activeView,this.lastFocus=this.props.focusedDate,this.indexToScroll=void 0}render(){this.calculateHeights();const r=this.lastView!==this.props.activeView,n=Ra(this.props.focusedDate,this.props.min,this.props.max),i=r?this.props.service.skip(n,this.props.min):this.state.skip,o=this.props.service.total(this.props.min,this.props.max),a=this.getTake(i,o),s=this.props.service.addToDate(this.props.min,i),l=this.props.service.datesList(s,a);(this.props.activeView!==this.lastView||!sd(n,this.lastFocus))&&(this.indexToScroll=this.props.service.skip(n,this.props.min));const h=_.createElement(IB,{skip:i,take:this.take,total:o,itemHeight:this.itemHeight,topOffset:this.topOffset,bottomOffset:this.bottomOffset,onScroll:this.props.onScroll,maxScrollDifference:this.maxViewHeight,onScrollAction:this.handleScrollAction,onMount:this.handleVirtualizationMount,tabIndex:this.props.tabIndex},_.createElement("ul",{ref:p=>{this.list=p},className:"k-reset"},l.map(p=>this.buildNavigationItem(p))));return _.createElement("div",{className:"k-calendar-navigation"},_.createElement("span",{className:"k-calendar-navigation-highlight"}),this.props.dom.didCalculate?h:null)}getTake(r,n){return Math.min(n-r,this.take)}};Fy.propTypes={activeView:B.number.isRequired,focusedDate:B.instanceOf(Date).isRequired,max:B.instanceOf(Date).isRequired,min:B.instanceOf(Date).isRequired,onChange:B.func,take:B.number,tabIndex:B.number},Fy.defaultProps={take:g$t};let m$t=Fy;/** + */const m$t=30,Fy=class NB extends _.Component{constructor(r){super(r),this.virtualization=null,this.list=null,this.itemHeight=0,this.topOffset=0,this.maxViewHeight=0,this.bottomOffset=0,this.handleVirtualizationMount=o=>{if(this.virtualization=o,this.virtualization&&this.list){this.list.style.transform=`translateY(${this.topOffset}px)`;const a=Fa(this.props.focusedDate,this.props.min,this.props.max),s=this.props.service.skip(a,this.props.min);this.virtualization.scrollToIndex(s)}},this.buildNavigationItem=o=>{const a=this.props.service.navigationTitle(o),s=this.props.service.isRangeStart(o),l=`kendo-react-calendar-nav-item-${o.getTime()}`,h={text:a,value:o,isRangeStart:s,view:this.props.activeView,onClick:this.handleDateChange};return this.props.navigationItem?_.createElement(this.props.navigationItem,{...h,key:l},a):_.createElement(g$t,{...h,key:l},a)},this.calculateHeights=()=>{const o=this.props.dom.calendarHeight;this.itemHeight=this.props.dom.navigationItemHeight||1,this.maxViewHeight=this.props.dom.monthViewHeight,this.topOffset=(o-this.itemHeight)/2,this.bottomOffset=o-this.itemHeight},this.handleDateChange=(o,a)=>{const{onChange:s}=this.props;if(s&&a){const l={value:N1(o),target:this,nativeEvent:a&&a.nativeEvent,syntheticEvent:a};s.call(void 0,l)}},this.handleScrollAction=({scrollAction:o,pageAction:a})=>{const s=a?a.skip:this.state.skip;if(this.state.skip!==s&&this.setState({skip:s}),this.list&&o){const l=`translateY(${o.offset}px)`;this.list.style.transform=l}},this.lastView=this.props.activeView,this.lastFocus=this.props.focusedDate;const n=this.props.service.skip(this.props.focusedDate,this.props.min),i=this.props.service.total(this.props.min,this.props.max);this.state={skip:n-this.getTake(n,i)>0?n:0}}get take(){return this.props.take!==void 0?this.props.take:NB.defaultProps.take}componentDidUpdate(r,n){this.indexToScroll!==void 0&&this.virtualization&&this.virtualization.scrollToIndex(this.indexToScroll),this.lastView=this.props.activeView,this.lastFocus=this.props.focusedDate,this.indexToScroll=void 0}render(){this.calculateHeights();const r=this.lastView!==this.props.activeView,n=Fa(this.props.focusedDate,this.props.min,this.props.max),i=r?this.props.service.skip(n,this.props.min):this.state.skip,o=this.props.service.total(this.props.min,this.props.max),a=this.getTake(i,o),s=this.props.service.addToDate(this.props.min,i),l=this.props.service.datesList(s,a);(this.props.activeView!==this.lastView||!sd(n,this.lastFocus))&&(this.indexToScroll=this.props.service.skip(n,this.props.min));const h=_.createElement(HB,{skip:i,take:this.take,total:o,itemHeight:this.itemHeight,topOffset:this.topOffset,bottomOffset:this.bottomOffset,onScroll:this.props.onScroll,maxScrollDifference:this.maxViewHeight,onScrollAction:this.handleScrollAction,onMount:this.handleVirtualizationMount,tabIndex:this.props.tabIndex},_.createElement("ul",{ref:p=>{this.list=p},className:"k-reset"},l.map(p=>this.buildNavigationItem(p))));return _.createElement("div",{className:"k-calendar-navigation"},_.createElement("span",{className:"k-calendar-navigation-highlight"}),this.props.dom.didCalculate?h:null)}getTake(r,n){return Math.min(n-r,this.take)}};Fy.propTypes={activeView:B.number.isRequired,focusedDate:B.instanceOf(Date).isRequired,max:B.instanceOf(Date).isRequired,min:B.instanceOf(Date).isRequired,onChange:B.func,take:B.number,tabIndex:B.number},Fy.defaultProps={take:m$t};let y$t=Fy;/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */var p1=(t=>(t[t.Left=0]="Left",t[t.Right=1]="Right",t[t.Up=2]="Up",t[t.Down=3]="Down",t[t.PrevView=4]="PrevView",t[t.NextView=5]="NextView",t[t.FirstInView=6]="FirstInView",t[t.LastInView=7]="LastInView",t[t.LowerView=8]="LowerView",t[t.UpperView=9]="UpperView",t))(p1||{});/** + */var h1=(t=>(t[t.Left=0]="Left",t[t.Right=1]="Right",t[t.Up=2]="Up",t[t.Down=3]="Down",t[t.PrevView=4]="PrevView",t[t.NextView=5]="NextView",t[t.FirstInView=6]="FirstInView",t[t.LastInView=7]="LastInView",t[t.LowerView=8]="LowerView",t[t.UpperView=9]="UpperView",t))(h1||{});/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const y$t=[[]],Wv=4,x$t=3,b$t={[p1.Left]:t=>fo(t,-1),[p1.Up]:t=>fo(t,-5),[p1.Right]:t=>fo(t,1),[p1.Down]:t=>fo(t,5),[p1.PrevView]:t=>Vc(t,-1),[p1.NextView]:t=>Vc(t,1),[p1.FirstInView]:t=>ll(t),[p1.LastInView]:t=>ky(t)};class w$t{addToDate(r,n){return Vc(r,n)}datesList(r,n){return $2(0,n).map(i=>Vc(r,i))}data(r){const{cellUID:n,focusedDate:i,isActiveView:o,max:a,min:s,selectedDate:l,selectionRange:h=x5,viewDate:p}=r;if(!p)return y$t;const f=$2(0,Wv),g=ll(p),b=ky(p),z=Co();return $2(0,x$t).map(M=>{const I=fo(g,M*Wv);return f.map(F=>{const H=this.normalize(fo(I,F),s,a),E=this.isEqual(H,h.start),R=this.isEqual(H,h.end),W=!E&&!R&&ld(H,h),$=o&&(Array.isArray(l)?this.isSelectedFromArray(H,l,s,a):Zi(l,s,a)&&this.isEqual(H,l));return HB(H,g,b)?{formattedValue:this.value(H),id:`${n}${H.getTime()}`,isFocused:this.isEqual(H,i),isSelected:$,isWeekend:!1,isInRange:Zi(H,s,a),isRangeStart:E,isRangeMid:W,isRangeEnd:R,isRangeSplitEnd:W&&this.isEqual(H,b),isRangeSplitStart:W&&this.isEqual(H,g),isToday:this.isEqual(H,z),title:this.cellTitle(H),value:H}:null})})}isSelectedFromArray(r,n,i,o){let a=!1;return n.forEach(s=>{Zi(r,i,o)&&this.isEqual(r,s)&&(a=!0)}),a}isEqual(r,n){return!r||!n?!1:e2(r).getFullYear()===e2(n).getFullYear()}isInArray(r,n){if(!n.length)return!1;const i=r.getFullYear();return n[0].getFullYear()<=i&&i<=n[n.length-1].getFullYear()+99}isInRange(r,n,i){const o=e2(r).getFullYear(),a=!n||e2(n).getFullYear()<=o,s=!i||o<=e2(i).getFullYear();return a&&s}isInSameView(r,n){return r7(r,n)===0}isRangeStart(r){return r.getFullYear()%1e3===0}move(r,n){const i=b$t[n];return i?i(r):r}cellTitle(r){return e2(r).getFullYear().toString()}navigationTitle(r){return r?ll(r).getFullYear().toString():""}title(r){return r?`${ll(r).getFullYear()} - ${ky(r).getFullYear()}`:""}rowLength(r){return Wv}skip(r,n){return r7(n,r)}total(r,n){return r7(r,n)+1}value(r){return r?e2(r).getFullYear().toString():""}viewDate(r,n,i=1){return r7(r,n)i&&this.isEqual(r,i)?W1(i):r}}/** + */const x$t=[[]],Wv=4,b$t=3,w$t={[h1.Left]:t=>co(t,-1),[h1.Up]:t=>co(t,-5),[h1.Right]:t=>co(t,1),[h1.Down]:t=>co(t,5),[h1.PrevView]:t=>Vc(t,-1),[h1.NextView]:t=>Vc(t,1),[h1.FirstInView]:t=>ll(t),[h1.LastInView]:t=>ky(t)};class C$t{addToDate(r,n){return Vc(r,n)}datesList(r,n){return R2(0,n).map(i=>Vc(r,i))}data(r){const{cellUID:n,focusedDate:i,isActiveView:o,max:a,min:s,selectedDate:l,selectionRange:h=x5,viewDate:p}=r;if(!p)return x$t;const f=R2(0,Wv),g=ll(p),b=ky(p),z=yo();return R2(0,b$t).map(M=>{const I=co(g,M*Wv);return f.map(F=>{const H=this.normalize(co(I,F),s,a),E=this.isEqual(H,h.start),R=this.isEqual(H,h.end),W=!E&&!R&&ld(H,h),$=o&&(Array.isArray(l)?this.isSelectedFromArray(H,l,s,a):Ki(l,s,a)&&this.isEqual(H,l));return DB(H,g,b)?{formattedValue:this.value(H),id:`${n}${H.getTime()}`,isFocused:this.isEqual(H,i),isSelected:$,isWeekend:!1,isInRange:Ki(H,s,a),isRangeStart:E,isRangeMid:W,isRangeEnd:R,isRangeSplitEnd:W&&this.isEqual(H,b),isRangeSplitStart:W&&this.isEqual(H,g),isToday:this.isEqual(H,z),title:this.cellTitle(H),value:H}:null})})}isSelectedFromArray(r,n,i,o){let a=!1;return n.forEach(s=>{Ki(r,i,o)&&this.isEqual(r,s)&&(a=!0)}),a}isEqual(r,n){return!r||!n?!1:Zn(r).getFullYear()===Zn(n).getFullYear()}isInArray(r,n){if(!n.length)return!1;const i=r.getFullYear();return n[0].getFullYear()<=i&&i<=n[n.length-1].getFullYear()+99}isInRange(r,n,i){const o=Zn(r).getFullYear(),a=!n||Zn(n).getFullYear()<=o,s=!i||o<=Zn(i).getFullYear();return a&&s}isInSameView(r,n){return r7(r,n)===0}isRangeStart(r){return r.getFullYear()%1e3===0}move(r,n){const i=w$t[n];return i?i(r):r}cellTitle(r){return Zn(r).getFullYear().toString()}navigationTitle(r){return r?ll(r).getFullYear().toString():""}title(r){return r?`${ll(r).getFullYear()} - ${ky(r).getFullYear()}`:""}rowLength(r){return Wv}skip(r,n){return r7(n,r)}total(r,n){return r7(r,n)+1}value(r){return r?Zn(r).getFullYear().toString():""}viewDate(r,n,i=1){return r7(r,n)i&&this.isEqual(r,i)?N1(i):r}}/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const C$t=[[]],jv=4,S$t=3,z$t={[p1.Left]:t=>a2(t,-1),[p1.Up]:t=>a2(t,-5),[p1.Right]:t=>a2(t,1),[p1.Down]:t=>a2(t,5),[p1.PrevView]:t=>fo(t,-1),[p1.NextView]:t=>fo(t,1),[p1.FirstInView]:t=>e2(t),[p1.LastInView]:t=>_y(t)};let M$t=class{addToDate(r,n){return fo(r,n)}datesList(r,n){return $2(0,n).map(i=>fo(r,i))}data(r){const{cellUID:n,focusedDate:i,isActiveView:o,max:a,min:s,selectedDate:l,selectionRange:h=x5,viewDate:p}=r;if(!p)return C$t;const f=$2(0,jv),g=e2(p),b=_y(p),z=Co();return $2(0,S$t).map(M=>{const I=a2(g,M*jv);return f.map(F=>{const H=this.normalize(a2(I,F),s,a),E=this.isEqual(H,h.start),R=this.isEqual(H,h.end),W=!E&&!R&&ld(H,h),$=o&&(Array.isArray(l)?this.isSelectedFromArray(H,l,s,a):Zi(l,s,a)&&this.isEqual(H,l));return HB(H,g,b)?{formattedValue:this.value(H),id:`${n}${H.getTime()}`,isFocused:this.isEqual(H,i),isSelected:$,isWeekend:!1,isInRange:Zi(H,s,a),isRangeStart:E,isRangeMid:W,isRangeEnd:R,isRangeSplitEnd:W&&this.isEqual(H,b),isRangeSplitStart:W&&this.isEqual(H,g),isToday:this.isEqual(H,z),title:this.cellTitle(H),value:H}:null})})}isSelectedFromArray(r,n,i,o){let a=!1;return n.forEach(s=>{Zi(r,i,o)&&this.isEqual(r,s)&&(a=!0)}),a}isEqual(r,n){return!r||!n?!1:r.getFullYear()===n.getFullYear()}isInArray(r,n){if(!n.length)return!1;const i=r.getFullYear();return n[0].getFullYear()<=i&&i<=n[n.length-1].getFullYear()+9}isInRange(r,n,i){const o=r.getFullYear(),a=!n||n.getFullYear()<=o,s=!i||o<=i.getFullYear();return a&&s}isRangeStart(r){return r.getFullYear()%100===0}isInSameView(r,n){return i7(r,n)===0}move(r,n){const i=z$t[n];return i?i(r):r}cellTitle(r){return r.getFullYear().toString()}navigationTitle(r){return r?e2(r).getFullYear().toString():""}title(r){return r?`${e2(r).getFullYear()} - ${_y(r).getFullYear()}`:""}rowLength(r){return jv}skip(r,n){return i7(n,r)}total(r,n){return i7(r,n)+1}value(r){return r?r.getFullYear().toString():""}viewDate(r,n,i=1){return i7(r,n)i&&this.isEqual(r,i)?W1(i):r}};/** + */const S$t=[[]],jv=4,z$t=3,M$t={[h1.Left]:t=>r2(t,-1),[h1.Up]:t=>r2(t,-5),[h1.Right]:t=>r2(t,1),[h1.Down]:t=>r2(t,5),[h1.PrevView]:t=>co(t,-1),[h1.NextView]:t=>co(t,1),[h1.FirstInView]:t=>Zn(t),[h1.LastInView]:t=>_y(t)};let k$t=class{addToDate(r,n){return co(r,n)}datesList(r,n){return R2(0,n).map(i=>co(r,i))}data(r){const{cellUID:n,focusedDate:i,isActiveView:o,max:a,min:s,selectedDate:l,selectionRange:h=x5,viewDate:p}=r;if(!p)return S$t;const f=R2(0,jv),g=Zn(p),b=_y(p),z=yo();return R2(0,z$t).map(M=>{const I=r2(g,M*jv);return f.map(F=>{const H=this.normalize(r2(I,F),s,a),E=this.isEqual(H,h.start),R=this.isEqual(H,h.end),W=!E&&!R&&ld(H,h),$=o&&(Array.isArray(l)?this.isSelectedFromArray(H,l,s,a):Ki(l,s,a)&&this.isEqual(H,l));return DB(H,g,b)?{formattedValue:this.value(H),id:`${n}${H.getTime()}`,isFocused:this.isEqual(H,i),isSelected:$,isWeekend:!1,isInRange:Ki(H,s,a),isRangeStart:E,isRangeMid:W,isRangeEnd:R,isRangeSplitEnd:W&&this.isEqual(H,b),isRangeSplitStart:W&&this.isEqual(H,g),isToday:this.isEqual(H,z),title:this.cellTitle(H),value:H}:null})})}isSelectedFromArray(r,n,i,o){let a=!1;return n.forEach(s=>{Ki(r,i,o)&&this.isEqual(r,s)&&(a=!0)}),a}isEqual(r,n){return!r||!n?!1:r.getFullYear()===n.getFullYear()}isInArray(r,n){if(!n.length)return!1;const i=r.getFullYear();return n[0].getFullYear()<=i&&i<=n[n.length-1].getFullYear()+9}isInRange(r,n,i){const o=r.getFullYear(),a=!n||n.getFullYear()<=o,s=!i||o<=i.getFullYear();return a&&s}isRangeStart(r){return r.getFullYear()%100===0}isInSameView(r,n){return i7(r,n)===0}move(r,n){const i=M$t[n];return i?i(r):r}cellTitle(r){return r.getFullYear().toString()}navigationTitle(r){return r?Zn(r).getFullYear().toString():""}title(r){return r?`${Zn(r).getFullYear()} - ${_y(r).getFullYear()}`:""}rowLength(r){return jv}skip(r,n){return i7(n,r)}total(r,n){return i7(r,n)+1}value(r){return r?r.getFullYear().toString():""}viewDate(r,n,i=1){return i7(r,n)i&&this.isEqual(r,i)?N1(i):r}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const k$t=[[]],Gv=7,_$t=6,A$t=6,L$t=0,E$t={[p1.Left]:t=>wo(t,-1),[p1.Up]:t=>$E(t,-1),[p1.Right]:t=>wo(t,1),[p1.Down]:t=>$E(t,1),[p1.PrevView]:t=>Ti(t,-1),[p1.NextView]:t=>Ti(t,1),[p1.FirstInView]:t=>My(t),[p1.LastInView]:t=>f4(t)};class I$t{constructor(r){this.intl=r}addToDate(r,n){return Ti(r,n)}datesList(r,n){return $2(0,n).map(i=>Ti(r,i))}data(r){const{cellUID:n,focusedDate:i,isActiveView:o,max:a,min:s,selectedDate:l,selectionRange:h=x5,viewDate:p}=r;if(!p)return k$t;const f=My(p),g=f4(p),b=_B(f,this.intl.firstDay(),-1),z=$2(0,Gv),M=Co();return $2(0,_$t).map(I=>{const F=wo(b,I*Gv);return z.map(H=>{const E=this.normalize(wo(F,H),s,a),R=Eg,W=this.isEqual(E,h.start),$=this.isEqual(E,h.end),G=!W&&!$&&ld(E,h),Z=o&&(Array.isArray(l)?this.isSelectedFromArray(E,l,s,a):Zi(l,s,a)&&this.isEqual(E,l));return{formattedValue:this.value(E),id:`${n}${E.getTime()}`,isFocused:this.isEqual(E,i),isSelected:Z,isInRange:Zi(E,s,a),isWeekend:this.isWeekend(E),isRangeStart:W,isRangeMid:G,isRangeEnd:$,isRangeSplitStart:G&&this.isEqual(E,f),isRangeSplitEnd:G&&this.isEqual(E,g),isToday:this.isEqual(E,M),title:this.cellTitle(E),value:E,isOtherMonth:R}})})}isEqual(r,n){return!r||!n?!1:fr(r).getTime()===fr(n).getTime()}isSelectedFromArray(r,n,i,o){let a=!1;return n.forEach(s=>{Zi(r,i,o)&&this.isEqual(r,s)&&(a=!0)}),a}isInArray(r,n){return!!n.length&&My(n[0])<=r&&r<=f4(n[n.length-1])}isInRange(r,n,i){const o=fr(r),a=!n||fr(n)<=o,s=!i||o<=fr(i);return a&&s}isInSameView(r,n){return n7(r,n)===0}isRangeStart(r){return!r.getMonth()}move(r,n){const i=E$t[n];return i?i(r):r}cellTitle(r){return this.intl.formatDate(r,"D")}navigationTitle(r){return r?this.isRangeStart(r)?r.getFullYear().toString():this.abbrMonthNames()[r.getMonth()]:""}title(r){return`${this.wideMonthNames()[r.getMonth()]} ${r.getFullYear()}`}rowLength(r){return Gv+(r?1:0)}skip(r,n){return n7(n,r)}total(r,n){return n7(r,n)+1}value(r){return r?r.getDate().toString():""}viewDate(r,n,i=1){return n7(r,n)i&&this.isEqual(r,i)?fr(i):r}wideMonthNames(){return this.intl.dateFormatNames({nameType:"wide",type:"months",standAlone:!0})}}/** + */const _$t=[[]],Gv=7,A$t=6,L$t=6,E$t=0,I$t={[h1.Left]:t=>mo(t,-1),[h1.Up]:t=>WE(t,-1),[h1.Right]:t=>mo(t,1),[h1.Down]:t=>WE(t,1),[h1.PrevView]:t=>Di(t,-1),[h1.NextView]:t=>Di(t,1),[h1.FirstInView]:t=>My(t),[h1.LastInView]:t=>f4(t)};class H$t{constructor(r){this.intl=r}addToDate(r,n){return Di(r,n)}datesList(r,n){return R2(0,n).map(i=>Di(r,i))}data(r){const{cellUID:n,focusedDate:i,isActiveView:o,max:a,min:s,selectedDate:l,selectionRange:h=x5,viewDate:p}=r;if(!p)return _$t;const f=My(p),g=f4(p),b=AB(f,this.intl.firstDay(),-1),z=R2(0,Gv),M=yo();return R2(0,A$t).map(I=>{const F=mo(b,I*Gv);return z.map(H=>{const E=this.normalize(mo(F,H),s,a),R=Eg,W=this.isEqual(E,h.start),$=this.isEqual(E,h.end),G=!W&&!$&&ld(E,h),Z=o&&(Array.isArray(l)?this.isSelectedFromArray(E,l,s,a):Ki(l,s,a)&&this.isEqual(E,l));return{formattedValue:this.value(E),id:`${n}${E.getTime()}`,isFocused:this.isEqual(E,i),isSelected:Z,isInRange:Ki(E,s,a),isWeekend:this.isWeekend(E),isRangeStart:W,isRangeMid:G,isRangeEnd:$,isRangeSplitStart:G&&this.isEqual(E,f),isRangeSplitEnd:G&&this.isEqual(E,g),isToday:this.isEqual(E,M),title:this.cellTitle(E),value:E,isOtherMonth:R}})})}isEqual(r,n){return!r||!n?!1:dr(r).getTime()===dr(n).getTime()}isSelectedFromArray(r,n,i,o){let a=!1;return n.forEach(s=>{Ki(r,i,o)&&this.isEqual(r,s)&&(a=!0)}),a}isInArray(r,n){return!!n.length&&My(n[0])<=r&&r<=f4(n[n.length-1])}isInRange(r,n,i){const o=dr(r),a=!n||dr(n)<=o,s=!i||o<=dr(i);return a&&s}isInSameView(r,n){return n7(r,n)===0}isRangeStart(r){return!r.getMonth()}move(r,n){const i=I$t[n];return i?i(r):r}cellTitle(r){return this.intl.formatDate(r,"D")}navigationTitle(r){return r?this.isRangeStart(r)?r.getFullYear().toString():this.abbrMonthNames()[r.getMonth()]:""}title(r){return`${this.wideMonthNames()[r.getMonth()]} ${r.getFullYear()}`}rowLength(r){return Gv+(r?1:0)}skip(r,n){return n7(n,r)}total(r,n){return n7(r,n)+1}value(r){return r?r.getDate().toString():""}viewDate(r,n,i=1){return n7(r,n)i&&this.isEqual(r,i)?dr(i):r}wideMonthNames(){return this.intl.dateFormatNames({nameType:"wide",type:"months",standAlone:!0})}}/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const H$t=[[]],Uv=4,D$t=3,P$t=t=>t>4?-5:t<2?-2:-7,T$t=t=>t<7?5:t<10?7:2,V$t={[p1.Left]:t=>Ti(t,-1),[p1.Up]:t=>Ti(t,P$t(t.getMonth())),[p1.Right]:t=>Ti(t,1),[p1.Down]:t=>Ti(t,T$t(t.getMonth())),[p1.PrevView]:t=>a2(t,-1),[p1.NextView]:t=>a2(t,1),[p1.FirstInView]:t=>LB(t),[p1.LastInView]:t=>EB(t)};class F$t{constructor(r){this._intl=r}addToDate(r,n){return a2(r,n)}datesList(r,n){return $2(0,n).map(i=>a2(r,i))}data(r){const{cellUID:n,focusedDate:i,isActiveView:o,max:a,min:s,selectedDate:l,selectionRange:h=x5,viewDate:p}=r;if(!p)return H$t;const f=this.abbrMonthNames(),g=LB(p),b=EB(p),z=g.getFullYear(),M=$2(0,Uv),I=Co();return $2(0,D$t).map(F=>{const H=Ti(g,F*Uv);return M.map(E=>{const R=this.normalize(Ti(H,E),s,a);if(z{Zi(r,i,o)&&this.isEqual(r,s)&&(a=!0)}),a}isEqual(r,n){return!r||!n?!1:r.getFullYear()===n.getFullYear()&&r.getMonth()===n.getMonth()}isInArray(r,n){if(!n.length)return!1;const i=r.getFullYear();return n[0].getFullYear()<=i&&i<=n[n.length-1].getFullYear()}isInRange(r,n,i){const o=Ko(r.getFullYear(),r.getMonth(),1),a=!n||Ko(n.getFullYear(),n.getMonth(),1)<=o,s=!i||o<=Ko(i.getFullYear(),i.getMonth(),1);return a&&s}isInSameView(r,n){return o7(r,n)===0}isRangeStart(r){return r.getFullYear()%10===0}move(r,n){const i=V$t[n];return i?i(r):r}cellTitle(r){return`${r.getFullYear()} ${this.value(r)}`}navigationTitle(r){return this.title(r)}title(r){return r?r.getFullYear().toString():""}rowLength(r){return Uv}skip(r,n){return o7(n,r)}total(r,n){return o7(r,n)+1}value(r){return r?this.abbrMonthNames()[r.getMonth()]:""}viewDate(r,n,i=1){return o7(r,n)i&&this.isEqual(r,i)?W1(i):r}}/** + */const D$t=[[]],Uv=4,P$t=3,T$t=t=>t>4?-5:t<2?-2:-7,V$t=t=>t<7?5:t<10?7:2,F$t={[h1.Left]:t=>Di(t,-1),[h1.Up]:t=>Di(t,T$t(t.getMonth())),[h1.Right]:t=>Di(t,1),[h1.Down]:t=>Di(t,V$t(t.getMonth())),[h1.PrevView]:t=>r2(t,-1),[h1.NextView]:t=>r2(t,1),[h1.FirstInView]:t=>EB(t),[h1.LastInView]:t=>IB(t)};class R$t{constructor(r){this._intl=r}addToDate(r,n){return r2(r,n)}datesList(r,n){return R2(0,n).map(i=>r2(r,i))}data(r){const{cellUID:n,focusedDate:i,isActiveView:o,max:a,min:s,selectedDate:l,selectionRange:h=x5,viewDate:p}=r;if(!p)return D$t;const f=this.abbrMonthNames(),g=EB(p),b=IB(p),z=g.getFullYear(),M=R2(0,Uv),I=yo();return R2(0,P$t).map(F=>{const H=Di(g,F*Uv);return M.map(E=>{const R=this.normalize(Di(H,E),s,a);if(z{Ki(r,i,o)&&this.isEqual(r,s)&&(a=!0)}),a}isEqual(r,n){return!r||!n?!1:r.getFullYear()===n.getFullYear()&&r.getMonth()===n.getMonth()}isInArray(r,n){if(!n.length)return!1;const i=r.getFullYear();return n[0].getFullYear()<=i&&i<=n[n.length-1].getFullYear()}isInRange(r,n,i){const o=Yo(r.getFullYear(),r.getMonth(),1),a=!n||Yo(n.getFullYear(),n.getMonth(),1)<=o,s=!i||o<=Yo(i.getFullYear(),i.getMonth(),1);return a&&s}isInSameView(r,n){return o7(r,n)===0}isRangeStart(r){return r.getFullYear()%10===0}move(r,n){const i=F$t[n];return i?i(r):r}cellTitle(r){return`${r.getFullYear()} ${this.value(r)}`}navigationTitle(r){return this.title(r)}title(r){return r?r.getFullYear().toString():""}rowLength(r){return Uv}skip(r,n){return o7(n,r)}total(r,n){return o7(r,n)+1}value(r){return r?this.abbrMonthNames()[r.getMonth()]:""}viewDate(r,n,i=1){return o7(r,n)i&&this.isEqual(r,i)?N1(i):r}}/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const R$t={[K1.month]:I$t,[K1.year]:F$t,[K1.decade]:M$t,[K1.century]:w$t},O$t=(t,r)=>{const n=K1[K1[t+r]];return n!==void 0?n:t};let B$t=class{constructor(r){this.bottom=K1.month,this.top=K1.century,this.onViewChanged=r}configure(r,n){this.bottom=r,this.top=n}service(r,n){return new R$t[`${r}`](n)}moveDown(r,n){this.move(r,-1,n)}moveUp(r,n){this.move(r,1,n)}moveToBottom(r){r!==this.bottom&&this.onViewChanged({view:this.bottom})}canMoveDown(r){return this.bottomthis.top?this.top:r}move(r,n,i){const o=this.clamp(O$t(r,n));o!==r&&this.onViewChanged({view:o},i)}};/** + */const O$t={[Y1.month]:H$t,[Y1.year]:R$t,[Y1.decade]:k$t,[Y1.century]:C$t},B$t=(t,r)=>{const n=Y1[Y1[t+r]];return n!==void 0?n:t};let N$t=class{constructor(r){this.bottom=Y1.month,this.top=Y1.century,this.onViewChanged=r}configure(r,n){this.bottom=r,this.top=n}service(r,n){return new O$t[`${r}`](n)}moveDown(r,n){this.move(r,-1,n)}moveUp(r,n){this.move(r,1,n)}moveToBottom(r){r!==this.bottom&&this.onViewChanged({view:this.bottom})}canMoveDown(r){return this.bottomthis.top?this.top:r}move(r,n,i){const o=this.clamp(B$t(r,n));o!==r&&this.onViewChanged({view:o},i)}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let N$t=class{constructor(){this.calendarHeight=0,this.headerHeight=0,this.monthViewHeight=0,this.yearViewHeight=0,this.decadeViewHeight=0,this.centuryViewHeight=0,this.navigationItemHeight=0,this.scrollableContentHeight=0,this.scrollableYearContentHeight=0,this.calendarWidth=0,this.monthViewWidth=0,this.yearViewWidth=0,this.decadeViewWidth=0,this.centuryViewWidth=0,this.scrollableContentWidth=0,this.didCalculate=!1,this.hostContainer=null}ensureHeights(){this.calendarHeight===void 0&&this.calculateHeights()}calculateHeights(r){if(!ai)return;const n=Sa("div"),i=Sa("ul"),o=Sa("li"),a=Sa("td"),s=Sa("th"),l=Sa("tr"),h=Sa("tbody"),p=Sa("thead"),f=Sa("table"),g=()=>n(` + */let $$t=class{constructor(){this.calendarHeight=0,this.headerHeight=0,this.monthViewHeight=0,this.yearViewHeight=0,this.decadeViewHeight=0,this.centuryViewHeight=0,this.navigationItemHeight=0,this.scrollableContentHeight=0,this.scrollableYearContentHeight=0,this.calendarWidth=0,this.monthViewWidth=0,this.yearViewWidth=0,this.decadeViewWidth=0,this.centuryViewWidth=0,this.scrollableContentWidth=0,this.didCalculate=!1,this.hostContainer=null}ensureHeights(){this.calendarHeight===void 0&&this.calculateHeights()}calculateHeights(r){if(!oi)return;const n=Ca("div"),i=Ca("ul"),o=Ca("li"),a=Ca("td"),s=Ca("th"),l=Ca("tr"),h=Ca("tbody"),p=Ca("thead"),f=Ca("table"),g=()=>n(` March 2017 - `,"k-calendar-header k-hstack"),b=()=>f([p([l([s("MO","k-calendar-th")],"k-calendar-tr")],"k-calendar-thead")],"k-calendar-table k-calendar-weekdays"),z=(ht,lt)=>new Array(ht).fill("1").map(lt),M=(ht,lt=1)=>f([h([l([a("1","k-calendar-td k-alt")])].concat(z(ht,()=>l(z(lt,yt=>a(`${yt}`,"k-calendar-td")),"k-calendar-tr"))),"k-calendar-tbody")],"k-calendar-table"),I=ht=>n(ht,"k-content k-scrollable"),F=(ht,lt,yt)=>n(yt?[g(),b(),I([ht,ht])]:[g(),I([ht,ht])],lt,{left:"-10000px",position:"absolute"}),H=(()=>{let ht;return()=>ai?(ht||(ht=n([I([i([o("FEB")])])],"k-calendar-navigation",{left:"0px",position:"absolute"})),ht):null})(),E=({cells:ht,rows:lt},yt,mt)=>{let gt;return()=>ai?(gt||(gt=F(M(lt,ht),yt,mt)),gt):null},R=ht=>ht.querySelector(".k-scrollable"),W=ht=>{const lt=R(ht);return lt.className=`${lt.className} k-scrollable-horizontal`,ht},$=E({cells:7,rows:6},"k-calendar-view k-calendar-monthview k-vstack",!0),G=E({cells:5,rows:3},"k-calendar-view k-calendar-yearview",!1),Z=E({cells:5,rows:2},"k-calendar-view k-calendar-decadeview",!1),K=()=>W($()),et=()=>W(G()),at=()=>W(Z()),tt=ht=>parseFloat(window.getComputedStyle(ht).height)||ht.offsetHeight,ft=ht=>{const lt=window.getComputedStyle(ht);return parseFloat(lt.width)+parseFloat(lt.paddingLeft)+parseFloat(lt.paddingRight)||ht.offsetWidth},dt=ht=>ht.querySelector("tbody");this.didCalculate=!0,r&&(this.hostContainer=r),this.batch($(),ht=>{const lt=dt(ht);this.calendarHeight=tt(ht),this.monthViewHeight=tt(lt),this.headerHeight=tt(lt.children[0]),this.scrollableContentHeight=tt(R(ht))}),this.batch(K(),ht=>{const lt=dt(ht);this.calendarWidth=ft(ht),this.monthViewWidth=ft(lt),this.scrollableContentWidth=ft(R(ht))}),this.batch(G(),ht=>{this.yearViewHeight=tt(dt(ht)),this.scrollableYearContentHeight=tt(R(ht))}),this.batch(et(),ht=>{this.yearViewWidth=ft(dt(ht))}),this.batch(Z(),ht=>{this.decadeViewHeight=tt(dt(ht)),this.centuryViewHeight=this.decadeViewHeight}),this.batch(at(),ht=>{this.decadeViewWidth=ft(dt(ht)),this.centuryViewWidth=this.decadeViewWidth}),this.batch(H(),ht=>{this.navigationItemHeight=tt(ht.querySelector("li"))})}viewHeight(r){return this.viewDimension(r,"height")}viewWidth(r){return this.viewDimension(r,"width")}viewDimension(r,n){const i=n==="height"?"ViewHeight":"ViewWidth";switch(r){case K1.month:return this[`month${i}`];case K1.year:return this[`year${i}`];case K1.decade:return this[`decade${i}`];case K1.century:return this[`century${i}`];default:return 1}}batch(r,n){const i=this.hostContainer||document.body,o=i.appendChild(r);n(o),i.removeChild(o)}};/** + `,"k-calendar-header k-hstack"),b=()=>f([p([l([s("MO","k-calendar-th")],"k-calendar-tr")],"k-calendar-thead")],"k-calendar-table k-calendar-weekdays"),z=(ht,lt)=>new Array(ht).fill("1").map(lt),M=(ht,lt=1)=>f([h([l([a("1","k-calendar-td k-alt")])].concat(z(ht,()=>l(z(lt,yt=>a(`${yt}`,"k-calendar-td")),"k-calendar-tr"))),"k-calendar-tbody")],"k-calendar-table"),I=ht=>n(ht,"k-content k-scrollable"),F=(ht,lt,yt)=>n(yt?[g(),b(),I([ht,ht])]:[g(),I([ht,ht])],lt,{left:"-10000px",position:"absolute"}),H=(()=>{let ht;return()=>oi?(ht||(ht=n([I([i([o("FEB")])])],"k-calendar-navigation",{left:"0px",position:"absolute"})),ht):null})(),E=({cells:ht,rows:lt},yt,mt)=>{let gt;return()=>oi?(gt||(gt=F(M(lt,ht),yt,mt)),gt):null},R=ht=>ht.querySelector(".k-scrollable"),W=ht=>{const lt=R(ht);return lt.className=`${lt.className} k-scrollable-horizontal`,ht},$=E({cells:7,rows:6},"k-calendar-view k-calendar-monthview k-vstack",!0),G=E({cells:5,rows:3},"k-calendar-view k-calendar-yearview",!1),Z=E({cells:5,rows:2},"k-calendar-view k-calendar-decadeview",!1),K=()=>W($()),et=()=>W(G()),at=()=>W(Z()),tt=ht=>parseFloat(window.getComputedStyle(ht).height)||ht.offsetHeight,ft=ht=>{const lt=window.getComputedStyle(ht);return parseFloat(lt.width)+parseFloat(lt.paddingLeft)+parseFloat(lt.paddingRight)||ht.offsetWidth},dt=ht=>ht.querySelector("tbody");this.didCalculate=!0,r&&(this.hostContainer=r),this.batch($(),ht=>{const lt=dt(ht);this.calendarHeight=tt(ht),this.monthViewHeight=tt(lt),this.headerHeight=tt(lt.children[0]),this.scrollableContentHeight=tt(R(ht))}),this.batch(K(),ht=>{const lt=dt(ht);this.calendarWidth=ft(ht),this.monthViewWidth=ft(lt),this.scrollableContentWidth=ft(R(ht))}),this.batch(G(),ht=>{this.yearViewHeight=tt(dt(ht)),this.scrollableYearContentHeight=tt(R(ht))}),this.batch(et(),ht=>{this.yearViewWidth=ft(dt(ht))}),this.batch(Z(),ht=>{this.decadeViewHeight=tt(dt(ht)),this.centuryViewHeight=this.decadeViewHeight}),this.batch(at(),ht=>{this.decadeViewWidth=ft(dt(ht)),this.centuryViewWidth=this.decadeViewWidth}),this.batch(H(),ht=>{this.navigationItemHeight=tt(ht.querySelector("li"))})}viewHeight(r){return this.viewDimension(r,"height")}viewWidth(r){return this.viewDimension(r,"width")}viewDimension(r,n){const i=n==="height"?"ViewHeight":"ViewWidth";switch(r){case Y1.month:return this[`month${i}`];case Y1.year:return this[`year${i}`];case Y1.decade:return this[`decade${i}`];case Y1.century:return this[`century${i}`];default:return 1}}batch(r,n){const i=this.hostContainer||document.body,o=i.appendChild(r);n(o),i.removeChild(o)}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const $$t={33:p1.PrevView,34:p1.NextView,35:p1.LastInView,36:p1.FirstInView,37:p1.Left,38:p1.Up,39:p1.Right,40:p1.Down,"meta+38":p1.UpperView,"meta+40":p1.LowerView};let W$t=class{constructor(r){this.bus=r}action(r){const n=`${r.ctrlKey||r.metaKey?"meta+":""}${r.keyCode}`;return $$t[n]}move(r,n,i,o,a){return o?n===p1.UpperView&&this.bus.canMoveUp(i)?(this.bus.moveUp(i,a),r):n===p1.LowerView&&this.bus.canMoveDown(i)?(this.bus.moveDown(i,a),r):o.move(r,n):r}};/** + */const W$t={33:h1.PrevView,34:h1.NextView,35:h1.LastInView,36:h1.FirstInView,37:h1.Left,38:h1.Up,39:h1.Right,40:h1.Down,"meta+38":h1.UpperView,"meta+40":h1.LowerView};let j$t=class{constructor(r){this.bus=r}action(r){const n=`${r.ctrlKey||r.metaKey?"meta+":""}${r.keyCode}`;return W$t[n]}move(r,n,i,o,a){return o?n===h1.UpperView&&this.bus.canMoveUp(i)?(this.bus.moveUp(i,a),r):n===h1.LowerView&&this.bus.canMoveDown(i)?(this.bus.moveDown(i,a),r):o.move(r,n):r}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const j$t=t=>r=>Math.floor(r/t),G$t=t=>r=>r*t;let U$t=class{constructor(r){this.dom=r,this.divideByMagnitude=null,this.powerByMagnitude=null,this.navigator=null,this.view=null,this.monthScrolled=!1,this.navScrolled=!1}configure(r){const n=Math.max(this.dom.viewHeight(r)/this.dom.navigationItemHeight,1);this.divideByMagnitude=j$t(n),this.powerByMagnitude=G$t(n)}sync(r,n,i){if(!(!r||!n)){if(this.navigator=r,this.view=n,i.target===this.navigator.element){if(this.monthScrolled){this.monthScrolled=!1;return}this.navScrolled=!0,this.scrollSiblingOf(this.navigator.element)}if(i.target===this.view.element){if(this.navScrolled){this.navScrolled=!1;return}this.monthScrolled=!0,this.scrollSiblingOf(this.view.element)}}}scrollSiblingOf(r){const n=this.siblingComponent(r),i=this.calculateScroll(n,r.scrollTop);n.scrollTo(i)}siblingComponent(r){return this.navigator.element===r?this.view:this.navigator}calculateScroll(r,n){const i=r===this.navigator?this.divideByMagnitude:this.powerByMagnitude;return i?i(n):0}};/** + */const G$t=t=>r=>Math.floor(r/t),U$t=t=>r=>r*t;let Y$t=class{constructor(r){this.dom=r,this.divideByMagnitude=null,this.powerByMagnitude=null,this.navigator=null,this.view=null,this.monthScrolled=!1,this.navScrolled=!1}configure(r){const n=Math.max(this.dom.viewHeight(r)/this.dom.navigationItemHeight,1);this.divideByMagnitude=G$t(n),this.powerByMagnitude=U$t(n)}sync(r,n,i){if(!(!r||!n)){if(this.navigator=r,this.view=n,i.target===this.navigator.element){if(this.monthScrolled){this.monthScrolled=!1;return}this.navScrolled=!0,this.scrollSiblingOf(this.navigator.element)}if(i.target===this.view.element){if(this.navScrolled){this.navScrolled=!1;return}this.monthScrolled=!0,this.scrollSiblingOf(this.view.element)}}}scrollSiblingOf(r){const n=this.siblingComponent(r),i=this.calculateScroll(n,r.scrollTop);n.scrollTo(i)}siblingComponent(r){return this.navigator.element===r?this.view:this.navigator}calculateScroll(r,n){const i=r===this.navigator?this.divideByMagnitude:this.powerByMagnitude;return i?i(n):0}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const Yv=t=>t?t.virtualization:null,GE=(t=M9.defaultProps.min,r=M9.defaultProps.max,n,i)=>i!==void 0?i!==null&&Zi(fr(i),t,r)?i:null:n!==null&&Zi(fr(n),t,r)?n:null,J7=class Ls extends _.Component{constructor(r){super(r),this.scrollSyncService=null,this.focusedDate=null,this.Navigation=null,this.calendarViewList=null,this._element=null,this.intl=null,this.service=null,this.isActive=!1,this.didNavigationChange=!1,this.focus=()=>{this._element&&this._element.focus()},this.shouldScroll=()=>this.didNavigationChange,this.handleScroll=i=>{this.scrollSyncService&&this.scrollSyncService.sync(Yv(this.Navigation),Yv(this.calendarViewList),i)},this.handleNavigationChange=i=>{if(this.props.disabled)return;this.didNavigationChange=!0;const o=W1(i.value);this.setState({focusedDate:o})},this.handleViewChange=({view:i})=>{this.scrollSyncService&&this.scrollSyncService.configure(i),this.setState({activeView:i})},this.handleDateChange=i=>{const o=W1(i.value),a=W1(i.value),s=this.bus.canMoveDown(this.state.activeView);if(this.props.disabled)return;if(s)if(i.isTodayClick)this.bus.moveToBottom(this.state.activeView);else{this.bus.moveDown(this.state.activeView,i.syntheticEvent),this.setState({focusedDate:a});return}this.setState({value:o,focusedDate:a}),this.valueDuringOnChange=o;const{onChange:l}=this.props;if(l){const h={syntheticEvent:i.syntheticEvent,nativeEvent:i.nativeEvent,value:o,target:this};l.call(void 0,h)}this.valueDuringOnChange=void 0},this.handleFocus=i=>{if(this.isActive=!0,!this.calendarViewList)return;this.calendarViewList.focusActiveDate();const{onFocus:o}=this.props;o&&o.call(void 0,i)},this.handleBlur=i=>{if(this.isActive=!1,!this.calendarViewList)return;this.calendarViewList.blurActiveDate();const{onBlur:o}=this.props;o&&o.call(void 0,i)},this.handleKeyDown=i=>{const{keyCode:o,ctrlKey:a,metaKey:s}=i;if(!(!this.focusedDate||!this.service)){if(o===84&&this.setState({focusedDate:Co()}),(a||s)&&(o===Jt.left||o===Jt.right)){if(this.props.disabled)return;this.didNavigationChange=!0,this.focusedDate.getDate()===31&&this.focusedDate.setDate(30);const l=o===Jt.left?this.focusedDate.getMonth()-1:this.focusedDate.getMonth()+1,h=new Date(this.focusedDate.setMonth(l)),p=W1(h);this.setState({focusedDate:p})}if(o===Jt.enter){if(this.value!==null&&K7(this.focusedDate,this.value)){const h=Ra(this.focusedDate,this.min,this.max);Yv(this.calendarViewList).scrollToIndex(this.service.skip(h,this.min))}const l={syntheticEvent:i,nativeEvent:i.nativeEvent,value:this.focusedDate,target:this};this.handleDateChange(l)}else{const l=Ra(this.navigation.move(this.focusedDate,this.navigation.action(i),this.state.activeView,this.service,i),this.min,this.max);if(K7(this.focusedDate,l))return;this.setState({focusedDate:l})}i.preventDefault()}},this.handleMouseDown=i=>{i.preventDefault()},this.handleClick=i=>{this._element&&this._element.focus({preventScroll:!0})},gi(_C);const n=GE(this.min,this.max,this.props.defaultValue||Ls.defaultProps.defaultValue,this.props.value);this.state={value:n,activeView:WE(K1[r.defaultActiveView],this.bottomView,this.topView),focusedDate:Ra(r.focusedDate||n||Co(),this.min,this.max)},this.dom=new N$t,this.bus=new B$t(this.handleViewChange),this.navigation=new W$t(this.bus),this.oldValue=n}get cellUID(){return this.props.id+"-cell-uid"}get id(){return this.props.id+"-id"}get element(){return this._element}get value(){return this.valueDuringOnChange!==void 0?this.valueDuringOnChange:this.props.value!==void 0?this.props.value:this.state.value}get min(){return fr(this.props.min!==void 0?this.props.min:Ls.defaultProps.min)}get max(){return fr(this.props.max!==void 0?this.props.max:Ls.defaultProps.max)}get bottomView(){return K1[this.props.bottomView!==void 0?this.props.bottomView:Ls.defaultProps.bottomView]}get topView(){return K1[this.props.topView!==void 0?this.props.topView:Ls.defaultProps.topView]}componentDidMount(){Promise.resolve().then(()=>{Tu(),this._element&&(this.dom.calculateHeights(this._element),this.scrollSyncService=new U$t(this.dom),this.scrollSyncService.configure(this.state.activeView),this.forceUpdate())})}componentDidUpdate(r,n){Tu(),n.activeView!==this.state.activeView&&this.scrollSyncService&&this.scrollSyncService.configure(this.state.activeView),this.calendarViewList&&(this.isActive?this.calendarViewList.focusActiveDate:this.calendarViewList.blurActiveDate)(),this.didNavigationChange=!1,this.isActive&&(this.oldValue=this.value)}render(){this.props._ref&&this.props._ref(this);const r=this.value!==null&&this.oldValue!==null?!K7(this.value,this.oldValue):this.value!==this.oldValue,n=WE(this.state.activeView,K1[this.props.bottomView!==void 0?this.props.bottomView:Ls.defaultProps.bottomView],K1[this.props.topView!==void 0?this.props.topView:Ls.defaultProps.topView]),i=GE(this.min,this.max,this.value,this.value),o=i?fr(i):null;this.focusedDate=fr(Ra(r&&i!==null?i:this.state.focusedDate,this.min,this.max)),this.intl=Ka(this),this.bus.configure(this.bottomView,this.topView),this.service=this.bus.service(n,this.intl);const{smoothScroll:a=Number.parseFloat(_.version)<18}=this.props,s=Me("k-calendar k-calendar-infinite",{"k-disabled":this.props.disabled,"k-week-number":this.props.weekNumber},this.props.mobileMode?"k-calendar-lg":"k-calendar-md",this.props.className),l=[this.props.navigation&&_.createElement(m$t,{key:0,ref:h=>{this.Navigation=h},activeView:this.state.activeView,focusedDate:this.focusedDate,min:this.min,max:this.max,onScroll:this.handleScroll,onChange:this.handleNavigationChange,service:this.service,dom:this.dom,navigationItem:this.props.navigationItem,tabIndex:this.props.tabIndex}),_.createElement(OB,{key:1,ref:h=>{this.calendarViewList=h},activeView:this.state.activeView,focusedDate:this.focusedDate,min:this.min,max:this.max,bus:this.bus,shouldScroll:this.shouldScroll,onScroll:this.handleScroll,service:this.service,cell:this.props.cell,weekCell:this.props.weekCell,dom:this.dom,smoothScroll:a,showWeekNumbers:this.props.weekNumber,onChange:this.handleDateChange,value:o,cellUID:this.cellUID,headerTitle:this.props.headerTitle,header:this.props.header,tabIndex:this.props.tabIndex,weekDaysFormat:this.props.weekDaysFormat,showOtherMonthDays:this.props.showOtherMonthDays})];return _.createElement("div",{ref:h=>{this._element=h},className:s,id:this.props.id||this.id,"aria-labelledby":this.props.ariaLabelledBy,"aria-describedby":this.props.ariaDescribedBy,"aria-disabled":this.props.disabled,tabIndex:this.props.disabled?void 0:this.props.tabIndex||0,onFocus:this.handleFocus,onBlur:this.handleBlur,onKeyDown:this.handleKeyDown,onMouseDown:this.handleMouseDown,onClick:this.handleClick},l)}};J7.displayName="Calendar",J7.propTypes={className:B.string,defaultActiveView:B.oneOf(["month","year","decade","century"]),defaultValue:B.instanceOf(Date),disabled:B.bool,focusedDate:B.instanceOf(Date),id:B.string,ariaLabelledBy:B.string,ariaDescribedBy:B.string,weekDaysFormat:B.oneOf(["short","abbreviated","narrow"]),max:B.instanceOf(Date),min:B.instanceOf(Date),navigation:B.bool,smoothScroll:B.bool,onBlur:B.func,onChange:B.func,onFocus:B.func,tabIndex:B.number,value:B.instanceOf(Date),weekNumber:B.bool,topView:(t,r,n)=>{const i=t[r],o=t.bottomView;return i&&o&&K1[i]t?t.virtualization:null,UE=(t=M9.defaultProps.min,r=M9.defaultProps.max,n,i)=>i!==void 0?i!==null&&Ki(dr(i),t,r)?i:null:n!==null&&Ki(dr(n),t,r)?n:null,J7=class Ls extends _.Component{constructor(r){super(r),this.scrollSyncService=null,this.focusedDate=null,this.Navigation=null,this.calendarViewList=null,this._element=null,this.intl=null,this.service=null,this.isActive=!1,this.didNavigationChange=!1,this.focus=()=>{this._element&&this._element.focus()},this.shouldScroll=()=>this.didNavigationChange,this.handleScroll=i=>{this.scrollSyncService&&this.scrollSyncService.sync(Yv(this.Navigation),Yv(this.calendarViewList),i)},this.handleNavigationChange=i=>{if(this.props.disabled)return;this.didNavigationChange=!0;const o=N1(i.value);this.setState({focusedDate:o})},this.handleViewChange=({view:i})=>{this.scrollSyncService&&this.scrollSyncService.configure(i),this.setState({activeView:i})},this.handleDateChange=i=>{const o=N1(i.value),a=N1(i.value),s=this.bus.canMoveDown(this.state.activeView);if(this.props.disabled)return;if(s)if(i.isTodayClick)this.bus.moveToBottom(this.state.activeView);else{this.bus.moveDown(this.state.activeView,i.syntheticEvent),this.setState({focusedDate:a});return}this.setState({value:o,focusedDate:a}),this.valueDuringOnChange=o;const{onChange:l}=this.props;if(l){const h={syntheticEvent:i.syntheticEvent,nativeEvent:i.nativeEvent,value:o,target:this};l.call(void 0,h)}this.valueDuringOnChange=void 0},this.handleFocus=i=>{if(this.isActive=!0,!this.calendarViewList)return;this.calendarViewList.focusActiveDate();const{onFocus:o}=this.props;o&&o.call(void 0,i)},this.handleBlur=i=>{if(this.isActive=!1,!this.calendarViewList)return;this.calendarViewList.blurActiveDate();const{onBlur:o}=this.props;o&&o.call(void 0,i)},this.handleKeyDown=i=>{const{keyCode:o,ctrlKey:a,metaKey:s}=i;if(!(!this.focusedDate||!this.service)){if(o===84&&this.setState({focusedDate:yo()}),(a||s)&&(o===te.left||o===te.right)){if(this.props.disabled)return;this.didNavigationChange=!0,this.focusedDate.getDate()===31&&this.focusedDate.setDate(30);const l=o===te.left?this.focusedDate.getMonth()-1:this.focusedDate.getMonth()+1,h=new Date(this.focusedDate.setMonth(l)),p=N1(h);this.setState({focusedDate:p})}if(o===te.enter){if(this.value!==null&&K7(this.focusedDate,this.value)){const h=Fa(this.focusedDate,this.min,this.max);Yv(this.calendarViewList).scrollToIndex(this.service.skip(h,this.min))}const l={syntheticEvent:i,nativeEvent:i.nativeEvent,value:this.focusedDate,target:this};this.handleDateChange(l)}else{const l=Fa(this.navigation.move(this.focusedDate,this.navigation.action(i),this.state.activeView,this.service,i),this.min,this.max);if(K7(this.focusedDate,l))return;this.setState({focusedDate:l})}i.preventDefault()}},this.handleMouseDown=i=>{i.preventDefault()},this.handleClick=i=>{this._element&&this._element.focus({preventScroll:!0})},vi(AC);const n=UE(this.min,this.max,this.props.defaultValue||Ls.defaultProps.defaultValue,this.props.value);this.state={value:n,activeView:jE(Y1[r.defaultActiveView],this.bottomView,this.topView),focusedDate:Fa(r.focusedDate||n||yo(),this.min,this.max)},this.dom=new $$t,this.bus=new N$t(this.handleViewChange),this.navigation=new j$t(this.bus),this.oldValue=n}get cellUID(){return this.props.id+"-cell-uid"}get id(){return this.props.id+"-id"}get element(){return this._element}get value(){return this.valueDuringOnChange!==void 0?this.valueDuringOnChange:this.props.value!==void 0?this.props.value:this.state.value}get min(){return dr(this.props.min!==void 0?this.props.min:Ls.defaultProps.min)}get max(){return dr(this.props.max!==void 0?this.props.max:Ls.defaultProps.max)}get bottomView(){return Y1[this.props.bottomView!==void 0?this.props.bottomView:Ls.defaultProps.bottomView]}get topView(){return Y1[this.props.topView!==void 0?this.props.topView:Ls.defaultProps.topView]}componentDidMount(){Promise.resolve().then(()=>{Tu(),this._element&&(this.dom.calculateHeights(this._element),this.scrollSyncService=new Y$t(this.dom),this.scrollSyncService.configure(this.state.activeView),this.forceUpdate())})}componentDidUpdate(r,n){Tu(),n.activeView!==this.state.activeView&&this.scrollSyncService&&this.scrollSyncService.configure(this.state.activeView),this.calendarViewList&&(this.isActive?this.calendarViewList.focusActiveDate:this.calendarViewList.blurActiveDate)(),this.didNavigationChange=!1,this.isActive&&(this.oldValue=this.value)}render(){this.props._ref&&this.props._ref(this);const r=this.value!==null&&this.oldValue!==null?!K7(this.value,this.oldValue):this.value!==this.oldValue,n=jE(this.state.activeView,Y1[this.props.bottomView!==void 0?this.props.bottomView:Ls.defaultProps.bottomView],Y1[this.props.topView!==void 0?this.props.topView:Ls.defaultProps.topView]),i=UE(this.min,this.max,this.value,this.value),o=i?dr(i):null;this.focusedDate=dr(Fa(r&&i!==null?i:this.state.focusedDate,this.min,this.max)),this.intl=Xa(this),this.bus.configure(this.bottomView,this.topView),this.service=this.bus.service(n,this.intl);const{smoothScroll:a=Number.parseFloat(_.version)<18}=this.props,s=ke("k-calendar k-calendar-infinite",{"k-disabled":this.props.disabled,"k-week-number":this.props.weekNumber},this.props.mobileMode?"k-calendar-lg":"k-calendar-md",this.props.className),l=[this.props.navigation&&_.createElement(y$t,{key:0,ref:h=>{this.Navigation=h},activeView:this.state.activeView,focusedDate:this.focusedDate,min:this.min,max:this.max,onScroll:this.handleScroll,onChange:this.handleNavigationChange,service:this.service,dom:this.dom,navigationItem:this.props.navigationItem,tabIndex:this.props.tabIndex}),_.createElement(BB,{key:1,ref:h=>{this.calendarViewList=h},activeView:this.state.activeView,focusedDate:this.focusedDate,min:this.min,max:this.max,bus:this.bus,shouldScroll:this.shouldScroll,onScroll:this.handleScroll,service:this.service,cell:this.props.cell,weekCell:this.props.weekCell,dom:this.dom,smoothScroll:a,showWeekNumbers:this.props.weekNumber,onChange:this.handleDateChange,value:o,cellUID:this.cellUID,headerTitle:this.props.headerTitle,header:this.props.header,tabIndex:this.props.tabIndex,weekDaysFormat:this.props.weekDaysFormat,showOtherMonthDays:this.props.showOtherMonthDays})];return _.createElement("div",{ref:h=>{this._element=h},className:s,id:this.props.id||this.id,"aria-labelledby":this.props.ariaLabelledBy,"aria-describedby":this.props.ariaDescribedBy,"aria-disabled":this.props.disabled,tabIndex:this.props.disabled?void 0:this.props.tabIndex||0,onFocus:this.handleFocus,onBlur:this.handleBlur,onKeyDown:this.handleKeyDown,onMouseDown:this.handleMouseDown,onClick:this.handleClick},l)}};J7.displayName="Calendar",J7.propTypes={className:B.string,defaultActiveView:B.oneOf(["month","year","decade","century"]),defaultValue:B.instanceOf(Date),disabled:B.bool,focusedDate:B.instanceOf(Date),id:B.string,ariaLabelledBy:B.string,ariaDescribedBy:B.string,weekDaysFormat:B.oneOf(["short","abbreviated","narrow"]),max:B.instanceOf(Date),min:B.instanceOf(Date),navigation:B.bool,smoothScroll:B.bool,onBlur:B.func,onChange:B.func,onFocus:B.func,tabIndex:B.number,value:B.instanceOf(Date),weekNumber:B.bool,topView:(t,r,n)=>{const i=t[r],o=t.bottomView;return i&&o&&Y1[i]{const i=t[r],o=t.topView;return i&&o&&K1[i]>K1[o]?new Error(`Invalid prop + ${r} suplied to ${n}. + `):null},bottomView:(t,r,n)=>{const i=t[r],o=t.topView;return i&&o&&Y1[i]>Y1[o]?new Error(`Invalid prop + ${r} suplied to ${n}. ${r} can not be bigger than topView. - `):null}},J7.defaultProps={disabled:!1,min:b5,max:w5,weekDaysFormat:"short",navigation:!0,defaultActiveView:"month",defaultValue:null,topView:"century",bottomView:"month",showOtherMonthDays:!1};let M9=J7;const Y$t=R8(),NB=na(up(Y$t,M9));NB.displayName="KendoReactCalendar";Wl(M9);/** + `):null}},J7.defaultProps={disabled:!1,min:b5,max:w5,weekDaysFormat:"short",navigation:!0,defaultActiveView:"month",defaultValue:null,topView:"century",bottomView:"month",showOtherMonthDays:!1};let M9=J7;const X$t=R8(),$B=ra(up(X$t,M9));$B.displayName="KendoReactCalendar";Wl(M9);/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let X$t=class{constructor(){this.symbols="",this.partMap=[]}};/** + */let K$t=class{constructor(){this.symbols="",this.partMap=[]}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const K$t="d",q$t="wide",Z$t=(t,r,n,i)=>{const o=t[i+t.length-n.length],a=t.substring(0,i+t.length-n.length),s=n.substring(0,i),l=[];if(a===s&&i>0)return l.push([r[i-1],s[i-1]]),l;if(a.indexOf(s)===0&&(s.length===0||r[s.length-1]!==r[s.length])){let h="";s.length===1&&l.push([r[0],s[0]]);for(let p=s.length;p(t[r.pattern[0]]=r.type,t),Q$t=(t,r,n)=>t===null||!(r&&r>t||n&&n{const o=t[i+t.length-n.length],a=t.substring(0,i+t.length-n.length),s=n.substring(0,i),l=[];if(a===s&&i>0)return l.push([r[i-1],s[i-1]]),l;if(a.indexOf(s)===0&&(s.length===0||r[s.length-1]!==r[s.length])){let h="";s.length===1&&l.push([r[0],s[0]]);for(let p=s.length;p(t[r.pattern[0]]=r.type,t),tWt=(t,r,n)=>t===null||!(r&&r>t||n&&nn||i.type!=="literal"&&i.type!=="dayperiod"&&this.getExisting(i.pattern[0]);return this.intl.splitDateFormat(this.format).reduce(r,!1)}getDateObject(){for(let r=0;r0&&h.charAt(0)==="0";)h=h.slice(1);h.length>=4&&(h="");for(let b=0;b<2;b++){let z=h+n,M=parseInt(z,10);if(f=this.intl.parseDate(l+z+p,this.format),!f&&!isNaN(M)&&!isNaN(parseInt(n,10))){if(r==="M"&&!g){const I=M-1;I>-1&&I<12&&(f=W1(this.value),f.setMonth(I),f.getMonth()!==I&&(f=f4(Ti(f,-1))))}r==="y"&&(f=Ko(parseInt(z,10),this.month?this.value.getMonth():0,this.date?this.value.getDate():1,this.hours?this.value.getHours():0,this.minutes?this.value.getMinutes():0,this.seconds?this.value.getSeconds():0,this.milliseconds?this.value.getMilliseconds():0),this.date&&f.getDate()!==this.value.getDate()&&(f=f4(Ti(f,-1))))}if(f)return this._value=f,this.setExisting(r,!0),{value:this.value};h=""}return g&&(f=this.intl.parseDate(l+g+p,this.format),f)?(this._value=f,this.setExisting(r,!0),{value:this.value}):(n==="0"&&(this.leadingZero=this.isAbbrMonth(o.partMap,r)?null:{[r]:!0},this.setExisting(r,!1)),{value:null})}symbolMap(r){return this.intl.splitDateFormat(this.format).reduce(J$t,{})[r]}resetLeadingZero(){const r=this.leadingZero!==null;return this.leadingZero=null,r}isAbbrMonth(r,n){const i=this.partPattern(r,n);return i.type==="month"&&i.names}partPattern(r,n){return r.filter(i=>i.pattern.indexOf(n)!==-1)[0]}matchMonth(r){if(this.typedMonthPart+=r.toLowerCase(),this.monthNames.length===0)return"";for(;this.typedMonthPart.length>0;){for(let i=0;i=1&&n<=12&&n.toString()===this.typedMonthPart)return this.monthNames[n-1];this.typedMonthPart=this.typedMonthPart.substring(1,this.typedMonthPart.length)}return""}allFormatedMonths(){const r=this.intl.splitDateFormat(this.format);for(let n=0;n0;)o.push(this.symbols[i[l].pattern[0]]||"_"),a.push(i[l]),h--}const s=new X$t;return s.symbols=o.join(""),s.partMap=a,s}merge(r,n){let i="",o="",a=n.symbols;for(let s=a.length-1;s>=0;s--)if(this.knownParts.indexOf(a[s])===-1||this.getExisting(a[s]))i=r[s]+i,o=a[s]+o;else{const l=a[s];for(;s>=0&&l===a[s];)s--;for(s++,this.leadingZero&&this.leadingZero[l]?i="0"+i:i=this.dateFieldName(n.partMap[s])+i;o.lengthn||i.type!=="literal"&&i.type!=="dayperiod"&&this.getExisting(i.pattern[0]);return this.intl.splitDateFormat(this.format).reduce(r,!1)}getDateObject(){for(let r=0;r0&&h.charAt(0)==="0";)h=h.slice(1);h.length>=4&&(h="");for(let b=0;b<2;b++){let z=h+n,M=parseInt(z,10);if(f=this.intl.parseDate(l+z+p,this.format),!f&&!isNaN(M)&&!isNaN(parseInt(n,10))){if(r==="M"&&!g){const I=M-1;I>-1&&I<12&&(f=N1(this.value),f.setMonth(I),f.getMonth()!==I&&(f=f4(Di(f,-1))))}r==="y"&&(f=Yo(parseInt(z,10),this.month?this.value.getMonth():0,this.date?this.value.getDate():1,this.hours?this.value.getHours():0,this.minutes?this.value.getMinutes():0,this.seconds?this.value.getSeconds():0,this.milliseconds?this.value.getMilliseconds():0),this.date&&f.getDate()!==this.value.getDate()&&(f=f4(Di(f,-1))))}if(f)return this._value=f,this.setExisting(r,!0),{value:this.value};h=""}return g&&(f=this.intl.parseDate(l+g+p,this.format),f)?(this._value=f,this.setExisting(r,!0),{value:this.value}):(n==="0"&&(this.leadingZero=this.isAbbrMonth(o.partMap,r)?null:{[r]:!0},this.setExisting(r,!1)),{value:null})}symbolMap(r){return this.intl.splitDateFormat(this.format).reduce(Q$t,{})[r]}resetLeadingZero(){const r=this.leadingZero!==null;return this.leadingZero=null,r}isAbbrMonth(r,n){const i=this.partPattern(r,n);return i.type==="month"&&i.names}partPattern(r,n){return r.filter(i=>i.pattern.indexOf(n)!==-1)[0]}matchMonth(r){if(this.typedMonthPart+=r.toLowerCase(),this.monthNames.length===0)return"";for(;this.typedMonthPart.length>0;){for(let i=0;i=1&&n<=12&&n.toString()===this.typedMonthPart)return this.monthNames[n-1];this.typedMonthPart=this.typedMonthPart.substring(1,this.typedMonthPart.length)}return""}allFormatedMonths(){const r=this.intl.splitDateFormat(this.format);for(let n=0;n0;)o.push(this.symbols[i[l].pattern[0]]||"_"),a.push(i[l]),h--}const s=new K$t;return s.symbols=o.join(""),s.partMap=a,s}merge(r,n){let i="",o="",a=n.symbols;for(let s=a.length-1;s>=0;s--)if(this.knownParts.indexOf(a[s])===-1||this.getExisting(a[s]))i=r[s]+i,o=a[s]+o;else{const l=a[s];for(;s>=0&&l===a[s];)s--;for(s++,this.leadingZero&&this.leadingZero[l]?i="0"+i:i=this.dateFieldName(n.partMap[s])+i;o.length({candidateValue:Fc($v,t),maxValue:wo(Fc($v,n),r.getHours(){if(!t||!r||!n)return!0;const{candidateValue:i,minValue:o,maxValue:a}=rWt(t,r,n);return o<=i&&i<=a};/** + */const iWt=(t,r,n)=>({candidateValue:Fc($v,t),maxValue:mo(Fc($v,n),r.getHours(){if(!t||!r||!n)return!0;const{candidateValue:i,minValue:o,maxValue:a}=iWt(t,r,n);return o<=i&&i<=a};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let $B=class extends _.Component{constructor(){super(...arguments),this.handelClick=r=>{r.stopPropagation();const{onClick:n}=this.props;n&&n.call(void 0,r)}}render(){const r=si(this).toLanguageString(Iy,o0[Iy]);return _.createElement("span",{className:"k-clear-value",role:"button",onClick:this.handelClick,tabIndex:this.props.tabindex||-1,title:r,key:"clearbutton"},_.createElement(en,{name:"x",icon:pC}))}};Ri($B);/** + */let WB=class extends _.Component{constructor(){super(...arguments),this.handelClick=r=>{r.stopPropagation();const{onClick:n}=this.props;n&&n.call(void 0,r)}}render(){const r=ai(this).toLanguageString(Iy,o0[Iy]);return _.createElement("span",{className:"k-clear-value",role:"button",onClick:this.handelClick,tabIndex:this.props.tabindex||-1,title:r,key:"clearbutton"},_.createElement(Qi,{name:"x",icon:dC}))}};Vi(WB);/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const nWt="Please enter a valid value!",Q7=class Jn extends _.Component{constructor(r){super(r),this.kendoDate=null,this.currentFormat="",this.paste=!1,this._element=null,this._wrapper=null,this._lastSelectedSymbol="",this.focus=()=>{this._element&&this._element.focus()},this.setValidity=()=>{this.element&&this.element.setCustomValidity&&this.element.setCustomValidity(this.validity.valid?"":this.props.validationMessage||Jn.defaultProps.validationMessage)},this.updateOnPaste=n=>{if(!this.element||!this.kendoDate)return;const i=Ka(this).parseDate(this.element.value,this.props.format)||this.value,o=this.value;this.kendoDate.setValue(i),this.triggerChange(n,o)},this.spinnersMouseDown=n=>{n.preventDefault();const i=Ki(document);this.element&&i!==this.element&&this.element.focus({preventScroll:!0})},this.handlePaste=()=>{this.paste=!0},this.handleClick=n=>{this.props.onChange&&this.props.onChange(n)},this.elementChange=n=>{if(!this.element||!this.kendoDate)return;if(this.paste){this.updateOnPaste(n),this.paste=!1;return}const{text:i,format:o}=this.kendoDate.getTextAndFormat();this.currentFormat=o;const a=this.value,s=Z$t(i,this.currentFormat,this.element.value,this.selection.start),l=s.length===1&&s[0][1]==="_";if(!l)for(let h=0;h{this.setSelection(this.selectionByIndex(this.selection.start))},this.nativeWheel=n=>{Ki(document)===this.element&&n.preventDefault()},this.wheel=n=>{Ki(document)===this.element&&(n.nativeEvent.deltaY<0&&this.increasePart(n),n.nativeEvent.deltaY>0&&this.decreasePart(n))},this.increasePart=n=>{this.modifyDateSegmentValue(1,n)},this.decreasePart=n=>{this.modifyDateSegmentValue(-1,n)},this.elementKeyDown=n=>{if(!n.altKey){switch(n.keyCode){case 37:this.switchDateSegment(-1);break;case 38:this.modifyDateSegmentValue(1,n);break;case 39:this.switchDateSegment(1);break;case 40:this.modifyDateSegmentValue(-1,n);break;default:return}n.preventDefault()}},this.elementOnFocus=n=>{this.wrapper&&this.wrapper.classList.add("k-focus"),this.setState({focused:!0})},this.elementOnBlur=n=>{this.wrapper&&this.wrapper.classList.remove("k-focus"),this.setState({focused:!1})},gi(_C),this.state={focused:!1}}get _inputId(){return this.props.id+"-accessibility-id"}componentDidMount(){this.setValidity(),this.wrapper&&this.wrapper.addEventListener("wheel",this.nativeWheel,{passive:!1})}componentDidUpdate(r,n){this._lastSelectedSymbol&&n.focused===this.state.focused?this.setSelection(this.selectionBySymbol(this._lastSelectedSymbol)):this.props.placeholder!==void 0&&this.selection.start===this.selection.end&&this.setSelection({start:0,end:this.currentFormat.length}),this.setValidity()}componentWillUnmount(){this.wrapper&&this.wrapper.removeEventListener("wheel",this.nativeWheel)}render(){const{size:r=Jn.defaultProps.size,fillMode:n=Jn.defaultProps.fillMode,rounded:i=Jn.defaultProps.rounded,autoFocus:o=Jn.defaultProps.autoFocus}=this.props;this.props._ref&&(this.props._ref.current=this);const a=si(this),s={...Jn.defaultProps,...this.props},{name:l,label:h,id:p}=s,f=this.text,g=f===this.props.placeholder?"":f,b=f===this.props.placeholder?f:void 0,z=p||this._inputId,M=!this.validityStyles||this.validity.valid,I=[...tWt];this.props.className&&I.push(this.props.className);const F=_.createElement(QP,{onFocus:this.elementOnFocus,onBlur:this.elementOnBlur},({onFocus:H,onBlur:E})=>_.createElement("span",{ref:R=>{this._wrapper=R},style:h?void 0:{width:this.props.width},dir:this.props.dir,className:Me("k-dateinput","k-input",{[`k-input-${Gr.sizeMap[r]||r}`]:r,[`k-input-${n}`]:n,[`k-rounded-${Gr.roundedMap[i]||i}`]:i,"k-invalid":!M,"k-required":this.required,"k-disabled":this.props.disabled},this.props.className),onFocus:H,onBlur:E},_.createElement("input",{role:this.props.ariaRole||"textbox",readOnly:this.props.readonly,tabIndex:this.props.tabIndex,disabled:this.props.disabled,title:this.props.title!==void 0?this.props.title:f,type:"text",spellCheck:!1,autoComplete:"off",autoCorrect:"off",autoFocus:o,className:"k-input-inner",id:z,"aria-label":this.props.ariaLabel,"aria-labelledby":this.props.ariaLabelledBy,"aria-describedby":this.props.ariaDescribedBy,"aria-haspopup":this.props.ariaHasPopup,"aria-disabled":this.props.disabled,"aria-expanded":this.props.ariaExpanded,"aria-controls":this.props.ariaControls,onWheel:this.wheel,onClick:this.elementClick,onInput:this.elementChange,onPaste:this.handlePaste,onKeyDown:this.elementKeyDown,onChange:Zr,value:g,placeholder:b,name:l,ref:R=>this._element=R}),this.props.children,this.props.clearButton&&this.props.value&&_.createElement($B,{onClick:this.handleClick,key:"clearbutton"}),this.props.spinners&&_.createElement("span",{className:"k-input-spinner k-spin-button",onMouseDown:this.spinnersMouseDown},_.createElement(ei,{tabIndex:-1,type:"button",rounded:null,className:"k-spinner-increase",icon:"caret-alt-up",svgIcon:uC,"aria-label":a.toLanguageString(mc,o0[mc]),title:a.toLanguageString(mc,o0[mc]),onClick:this.increasePart}),_.createElement(ei,{tabIndex:-1,type:"button",rounded:null,className:"k-spinner-decrease",icon:"caret-alt-down",svgIcon:Y0,"aria-label":a.toLanguageString(yc,o0[yc]),title:a.toLanguageString(yc,o0[yc]),onClick:this.decreasePart}))));return h?_.createElement(v5,{label:h,editorId:z,editorValue:f,editorValid:M,editorDisabled:this.props.disabled,children:F,style:{width:this.props.width}}):F}get value(){return this.valueDuringOnChange!==void 0?this.valueDuringOnChange:this.kendoDate&&this.kendoDate.getDateObject()}get name(){return this.props.name}get min(){return this.props.min!==void 0?this.props.min:Jn.defaultProps.min}get max(){return this.props.max!==void 0?this.props.max:Jn.defaultProps.max}get text(){const r={...LC.defaultProps,...this.props},{formatPlaceholder:n=Jn.defaultProps.formatPlaceholder,format:i=Jn.defaultProps.format,value:o,defaultValue:a}=r;this.kendoDate===null?(this.kendoDate=new eWt(this.intl.bind(this),n,i),this.kendoDate.setValue(o||a||null)):(this.kendoDate.format=i,this.kendoDate.formatPlaceholder=n),o!==void 0&&this.value!==o&&this.kendoDate.setValue(o);const{text:s,format:l}=this.kendoDate.getTextAndFormat();return this.currentFormat=l,r.placeholder!==null&&r.placeholder!==void 0&&!this.state.focused&&!this.kendoDate.hasValue()?r.placeholder:s}get validity(){const r=Q$t(this.value,this.min,this.max)&&iWt(this.value,this.props.minTime,this.props.maxTime),n=this.props.validationMessage!==void 0,i=(!this.required||this.value!==null)&&r,o=this.props.valid!==void 0?this.props.valid:i;return{customError:n,rangeOverflow:this.value&&this.max.getTime(){const n=Ki(document);this.element&&n===this.element&&!this.props.disableSelection&&this.element.setSelectionRange(r.start,r.end)})}triggerChange(r,n){this.valueDuringOnChange=this.value,this.forceUpdate(),this.props.onChange&&!sd(n,this.value)&&this.props.onChange.call(void 0,{syntheticEvent:r,nativeEvent:r.nativeEvent,value:this.value,target:this}),this.valueDuringOnChange=void 0}selectionBySymbol(r){let n=-1,i=0;for(let o=0;o=0;i++,o--){if(i=0&&this.currentFormat[o]!=="_"){n=this.selectionBySymbol(this.currentFormat[o]);break}}return n}switchDateSegment(r){const{start:n,end:i}=this.selection;if(n0?n:i-1));return}const o=this.currentFormat[n];let a=n+r;for(;a>0&&a=0&&ss&&(s+1!==n||a+1!==i)?this.setSelection({start:s+1,end:a+1}):a{this._element&&this._element.focus()},this.setValidity=()=>{this.element&&this.element.setCustomValidity&&this.element.setCustomValidity(this.validity.valid?"":this.props.validationMessage||Xn.defaultProps.validationMessage)},this.updateOnPaste=n=>{if(!this.element||!this.kendoDate)return;const i=Xa(this).parseDate(this.element.value,this.props.format)||this.value,o=this.value;this.kendoDate.setValue(i),this.triggerChange(n,o)},this.spinnersMouseDown=n=>{n.preventDefault();const i=Yi(document);this.element&&i!==this.element&&this.element.focus({preventScroll:!0})},this.handlePaste=()=>{this.paste=!0},this.handleClick=n=>{this.props.onChange&&this.props.onChange(n)},this.elementChange=n=>{if(!this.element||!this.kendoDate)return;if(this.paste){this.updateOnPaste(n),this.paste=!1;return}const{text:i,format:o}=this.kendoDate.getTextAndFormat();this.currentFormat=o;const a=this.value,s=J$t(i,this.currentFormat,this.element.value,this.selection.start),l=s.length===1&&s[0][1]==="_";if(!l)for(let h=0;h{this.setSelection(this.selectionByIndex(this.selection.start))},this.nativeWheel=n=>{Yi(document)===this.element&&n.preventDefault()},this.wheel=n=>{Yi(document)===this.element&&(n.nativeEvent.deltaY<0&&this.increasePart(n),n.nativeEvent.deltaY>0&&this.decreasePart(n))},this.increasePart=n=>{this.modifyDateSegmentValue(1,n)},this.decreasePart=n=>{this.modifyDateSegmentValue(-1,n)},this.elementKeyDown=n=>{if(!n.altKey){switch(n.keyCode){case 37:this.switchDateSegment(-1);break;case 38:this.modifyDateSegmentValue(1,n);break;case 39:this.switchDateSegment(1);break;case 40:this.modifyDateSegmentValue(-1,n);break;default:return}n.preventDefault()}},this.elementOnFocus=n=>{this.wrapper&&this.wrapper.classList.add("k-focus"),this.setState({focused:!0})},this.elementOnBlur=n=>{this.wrapper&&this.wrapper.classList.remove("k-focus"),this.setState({focused:!1})},vi(AC),this.state={focused:!1}}get _inputId(){return this.props.id+"-accessibility-id"}componentDidMount(){this.setValidity(),this.wrapper&&this.wrapper.addEventListener("wheel",this.nativeWheel,{passive:!1})}componentDidUpdate(r,n){this._lastSelectedSymbol&&n.focused===this.state.focused?this.setSelection(this.selectionBySymbol(this._lastSelectedSymbol)):this.props.placeholder!==void 0&&this.selection.start===this.selection.end&&this.setSelection({start:0,end:this.currentFormat.length}),this.setValidity()}componentWillUnmount(){this.wrapper&&this.wrapper.removeEventListener("wheel",this.nativeWheel)}render(){const{size:r=Xn.defaultProps.size,fillMode:n=Xn.defaultProps.fillMode,rounded:i=Xn.defaultProps.rounded,autoFocus:o=Xn.defaultProps.autoFocus}=this.props;this.props._ref&&(this.props._ref.current=this);const a=ai(this),s={...Xn.defaultProps,...this.props},{name:l,label:h,id:p}=s,f=this.text,g=f===this.props.placeholder?"":f,b=f===this.props.placeholder?f:void 0,z=p||this._inputId,M=!this.validityStyles||this.validity.valid,I=[...eWt];this.props.className&&I.push(this.props.className);const F=_.createElement(tT,{onFocus:this.elementOnFocus,onBlur:this.elementOnBlur},({onFocus:H,onBlur:E})=>_.createElement("span",{ref:R=>{this._wrapper=R},style:h?void 0:{width:this.props.width},dir:this.props.dir,className:ke("k-dateinput","k-input",{[`k-input-${Wr.sizeMap[r]||r}`]:r,[`k-input-${n}`]:n,[`k-rounded-${Wr.roundedMap[i]||i}`]:i,"k-invalid":!M,"k-required":this.required,"k-disabled":this.props.disabled},this.props.className),onFocus:H,onBlur:E},_.createElement("input",{role:this.props.ariaRole||"textbox",readOnly:this.props.readonly,tabIndex:this.props.tabIndex,disabled:this.props.disabled,title:this.props.title!==void 0?this.props.title:f,type:"text",spellCheck:!1,autoComplete:"off",autoCorrect:"off",autoFocus:o,className:"k-input-inner",id:z,"aria-label":this.props.ariaLabel,"aria-labelledby":this.props.ariaLabelledBy,"aria-describedby":this.props.ariaDescribedBy,"aria-haspopup":this.props.ariaHasPopup,"aria-disabled":this.props.disabled,"aria-expanded":this.props.ariaExpanded,"aria-controls":this.props.ariaControls,onWheel:this.wheel,onClick:this.elementClick,onInput:this.elementChange,onPaste:this.handlePaste,onKeyDown:this.elementKeyDown,onChange:Xr,value:g,placeholder:b,name:l,ref:R=>this._element=R}),this.props.children,this.props.clearButton&&this.props.value&&_.createElement(WB,{onClick:this.handleClick,key:"clearbutton"}),this.props.spinners&&_.createElement("span",{className:"k-input-spinner k-spin-button",onMouseDown:this.spinnersMouseDown},_.createElement(Jr,{tabIndex:-1,type:"button",rounded:null,className:"k-spinner-increase",icon:"caret-alt-up",svgIcon:pC,"aria-label":a.toLanguageString(mc,o0[mc]),title:a.toLanguageString(mc,o0[mc]),onClick:this.increasePart}),_.createElement(Jr,{tabIndex:-1,type:"button",rounded:null,className:"k-spinner-decrease",icon:"caret-alt-down",svgIcon:Y0,"aria-label":a.toLanguageString(yc,o0[yc]),title:a.toLanguageString(yc,o0[yc]),onClick:this.decreasePart}))));return h?_.createElement(v5,{label:h,editorId:z,editorValue:f,editorValid:M,editorDisabled:this.props.disabled,children:F,style:{width:this.props.width}}):F}get value(){return this.valueDuringOnChange!==void 0?this.valueDuringOnChange:this.kendoDate&&this.kendoDate.getDateObject()}get name(){return this.props.name}get min(){return this.props.min!==void 0?this.props.min:Xn.defaultProps.min}get max(){return this.props.max!==void 0?this.props.max:Xn.defaultProps.max}get text(){const r={...EC.defaultProps,...this.props},{formatPlaceholder:n=Xn.defaultProps.formatPlaceholder,format:i=Xn.defaultProps.format,value:o,defaultValue:a}=r;this.kendoDate===null?(this.kendoDate=new rWt(this.intl.bind(this),n,i),this.kendoDate.setValue(o||a||null)):(this.kendoDate.format=i,this.kendoDate.formatPlaceholder=n),o!==void 0&&this.value!==o&&this.kendoDate.setValue(o);const{text:s,format:l}=this.kendoDate.getTextAndFormat();return this.currentFormat=l,r.placeholder!==null&&r.placeholder!==void 0&&!this.state.focused&&!this.kendoDate.hasValue()?r.placeholder:s}get validity(){const r=tWt(this.value,this.min,this.max)&&nWt(this.value,this.props.minTime,this.props.maxTime),n=this.props.validationMessage!==void 0,i=(!this.required||this.value!==null)&&r,o=this.props.valid!==void 0?this.props.valid:i;return{customError:n,rangeOverflow:this.value&&this.max.getTime(){const n=Yi(document);this.element&&n===this.element&&!this.props.disableSelection&&this.element.setSelectionRange(r.start,r.end)})}triggerChange(r,n){this.valueDuringOnChange=this.value,this.forceUpdate(),this.props.onChange&&!sd(n,this.value)&&this.props.onChange.call(void 0,{syntheticEvent:r,nativeEvent:r.nativeEvent,value:this.value,target:this}),this.valueDuringOnChange=void 0}selectionBySymbol(r){let n=-1,i=0;for(let o=0;o=0;i++,o--){if(i=0&&this.currentFormat[o]!=="_"){n=this.selectionBySymbol(this.currentFormat[o]);break}}return n}switchDateSegment(r){const{start:n,end:i}=this.selection;if(n0?n:i-1));return}const o=this.currentFormat[n];let a=n+r;for(;a>0&&a=0&&ss&&(s+1!==n||a+1!==i)?this.setSelection({start:s+1,end:a+1}):a{const{_ref:n}=t,i=_.useRef(null);_.useImperativeHandle(r,()=>i.current),_.useImperativeHandle(n,()=>i.current);const o=_.useMemo(()=>Me(t.className,"k-picker-wrap"),[t.className]);return _.createElement("span",{ref:i,id:t.id,style:t.style,className:o,tabIndex:t.tabIndex},t.children)});/** + */const lWt=_.forwardRef((t,r)=>{const{_ref:n}=t,i=_.useRef(null);_.useImperativeHandle(r,()=>i.current),_.useImperativeHandle(n,()=>i.current);const o=_.useMemo(()=>ke(t.className,"k-picker-wrap"),[t.className]);return _.createElement("span",{ref:i,id:t.id,style:t.style,className:o,tabIndex:t.tabIndex},t.children)});/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const lWt=t=>{const[r,n]=_.useState(!1),i=()=>{t.current&&n(!!t.current.text)};return _.useEffect(i),{editorValue:r}},cWt=t=>{const{dateInput:r,...n}=t,i=lWt(r);return _.createElement(v5,{...n,...i})};/** + */const cWt=t=>{const[r,n]=_.useState(!1),i=()=>{t.current&&n(!!t.current.text)};return _.useEffect(i),{editorValue:r}},hWt=t=>{const{dateInput:r,...n}=t,i=cWt(r);return _.createElement(v5,{...n,...i})};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const UE=500,hWt=t=>{const{footer:r,children:n,windowWidth:i=0,navigatable:o,navigatableElements:a,expand:s,animation:l,onClose:h,adaptiveTitle:p,mobileFilter:f}=t,g={navigatable:o||!1,navigatableElements:a||[],expand:s,animation:l!==!1,onClose:h,animationStyles:i<=UE?{top:0,width:"100%",height:"100%"}:void 0,className:i<=UE?"k-adaptive-actionsheet k-actionsheet-fullscreen":"k-adaptive-actionsheet k-actionsheet-bottom"};return _.createElement(IO,{...g},_.createElement(p5,{className:"k-text-center"},_.createElement("div",{className:"k-actionsheet-titlebar-group k-hbox"},_.createElement("div",{className:"k-actionsheet-title"},_.createElement("div",null,p)),_.createElement("div",{className:"k-actionsheet-actions"},_.createElement(ei,{tabIndex:0,"aria-label":"Cancel","aria-disabled":"false",type:"button",fillMode:"flat",icon:"x",svgIcon:pC,onClick:h}))),f&&_.createElement("div",{className:"k-actionsheet-titlebar-group k-actionsheet-filter"},f)),n,r&&_.createElement(id,{className:"k-actions k-actions-stretched"},_.createElement(ei,{size:"large",tabIndex:0,"aria-label":r.cancelText,"aria-disabled":"false",type:"button",onClick:r.onCancel},r.cancelText),_.createElement(ei,{tabIndex:0,themeColor:"primary",size:"large","aria-label":r.applyText,"aria-disabled":"false",type:"button",onClick:r.onApply},r.applyText)))};/** + */const YE=500,uWt=t=>{const{footer:r,children:n,windowWidth:i=0,navigatable:o,navigatableElements:a,expand:s,animation:l,onClose:h,adaptiveTitle:p,mobileFilter:f}=t,g={navigatable:o||!1,navigatableElements:a||[],expand:s,animation:l!==!1,onClose:h,animationStyles:i<=YE?{top:0,width:"100%",height:"100%"}:void 0,className:i<=YE?"k-adaptive-actionsheet k-actionsheet-fullscreen":"k-adaptive-actionsheet k-actionsheet-bottom"};return _.createElement(HO,{...g},_.createElement(p5,{className:"k-text-center"},_.createElement("div",{className:"k-actionsheet-titlebar-group k-hbox"},_.createElement("div",{className:"k-actionsheet-title"},_.createElement("div",null,p)),_.createElement("div",{className:"k-actionsheet-actions"},_.createElement(Jr,{tabIndex:0,"aria-label":"Cancel","aria-disabled":"false",type:"button",fillMode:"flat",icon:"x",svgIcon:dC,onClick:h}))),f&&_.createElement("div",{className:"k-actionsheet-titlebar-group k-actionsheet-filter"},f)),n,r&&_.createElement(id,{className:"k-actions k-actions-stretched"},_.createElement(Jr,{size:"large",tabIndex:0,"aria-label":r.cancelText,"aria-disabled":"false",type:"button",onClick:r.onCancel},r.cancelText),_.createElement(Jr,{tabIndex:0,themeColor:"primary",size:"large","aria-label":r.applyText,"aria-disabled":"false",type:"button",onClick:r.onApply},r.applyText)))};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const uWt=768;/** + */const pWt=768;/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const tu=class hn extends _.Component{constructor(r){super(r),this._element=null,this._dateInput=_.createRef(),this._calendar=null,this.shouldFocusDateInput=!1,this.prevShow=!1,this.focus=()=>{this.dateInput&&this.dateInput.focus()},this.setCalendarRef=n=>{this._calendar=n},this.nextValue=(n,i)=>n.value!==void 0?n.value:i.value,this.nextShow=(n,i)=>n.show!==void 0?n.show:i.show,this.renderPopup=()=>{const{disabled:n,min:i,max:o,weekNumber:a,focusedDate:s,popupSettings:l}=this.props,{popupClass:h,...p}=l,f=this.show,g=this.value,b=g&&fr(g),z=Me(h),M={popupClass:"k-datepicker-popup",show:f,anchor:this._element,className:z,id:this._popupId,anchorAlign:{horizontal:"left",vertical:"bottom"},popupAlign:{horizontal:"left",vertical:"top"},...p},I={disabled:n,value:b,min:i,max:o,weekNumber:a,focusedDate:s,className:this.mobileMode?"k-calendar-lg":"",navigation:!this.mobileMode,onChange:this.handleCalendarValueChange};return this.mobileMode?_.createElement(this.calendarComp,{_ref:this.setCalendarRef,...I}):_.createElement(this.popupComp,{...M},_.createElement(this.calendarComp,{_ref:this.setCalendarRef,...I}))},this.renderAdaptivePopup=()=>{const{windowWidth:n=0}=this.state,i={expand:this.show,onClose:this.handleBlur,adaptiveTitle:this.props.adaptiveTitle,windowWidth:n};return _.createElement(hWt,{...i},_.createElement(d5,{className:"!k-overflow-hidden"},this.renderPopup()))},this.handleInputValueChange=n=>{this.handleValueChange(n.value,n)},this.handleCalendarValueChange=n=>{const i=this.mergeTime(n.value);this.handleValueChange(i,n)},this.handleValueChange=(n,i)=>{this.setState({value:W1(n||void 0)}),this.valueDuringOnChange=n,this.showDuringOnChange=!1,this.mobileMode||(this.shouldFocusDateInput=!0);const{onChange:o}=this.props;o&&o.call(void 0,{syntheticEvent:i.syntheticEvent,nativeEvent:i.nativeEvent,value:this.value,show:this.show,target:this}),this.valueDuringOnChange=void 0,this.showDuringOnChange=void 0,this.setShow(!1)},this.handleFocus=()=>{this.setState({focused:!0})},this.handleBlur=()=>{this.setState({focused:!1}),this.setShow(!1)},this.handleIconClick=()=>{this.props.disabled||(this.shouldFocusDateInput=!0,this.setShow(!this.show))},this.handleIconMouseDown=n=>{n.preventDefault()},this.handleKeyDown=n=>{const{altKey:i,keyCode:o}=n;if(o===Jt.esc&&this.show){this.shouldFocusDateInput=!0,this.setShow(!1);return}i&&(o===Jt.up||o===Jt.down)&&(n.preventDefault(),n.stopPropagation(),this.shouldFocusDateInput=o===Jt.up,this.setShow(o===Jt.down))},gi(_C),this.state={value:this.props.defaultValue||hn.defaultProps.defaultValue,show:this.props.defaultShow||hn.defaultProps.defaultShow,focused:!1}}get _popupId(){return this.props.id+"-popup-id"}get document(){if(ai)return this.element&&this.element.ownerDocument||document}get element(){return this._element}get mobileMode(){return!!(this.state.windowWidth&&this.state.windowWidth<=uWt&&this.props.adaptive)}get dateInput(){return this._dateInput.current}get calendar(){return this._calendar}get value(){const r=this.valueDuringOnChange!==void 0?this.valueDuringOnChange:this.props.value!==void 0?this.props.value:this.state.value;return r!==null?W1(r):null}get show(){return this.showDuringOnChange!==void 0?this.showDuringOnChange:this.props.show!==void 0?this.props.show:this.state.show}get name(){return this.props.name}get min(){return this.props.min!==void 0?this.props.min:hn.defaultProps.min}get max(){return this.props.max!==void 0?this.props.max:hn.defaultProps.max}get dateInputComp(){return this.props.dateInput||hn.defaultProps.dateInput}get toggleButtonComp(){return this.props.toggleButton||hn.defaultProps.toggleButton}get calendarComp(){return this.props.calendar||hn.defaultProps.calendar}get popupComp(){return this.props.popup||hn.defaultProps.popup}get pickerWrapComp(){return this.props.pickerWrap||hn.defaultProps.pickerWrap}get validity(){const r=UNt(this.value,this.min,this.max),n=this.props.validationMessage!==void 0,i=(!this.required||this.value!==null)&&r,o=this.props.valid!==void 0?this.props.valid:i;return{customError:n,rangeOverflow:this.value&&this.max.getTime()_.createElement(_.Fragment,null,_.createElement("span",{...G?{}:ae,ref:Se=>{this._element=Se},className:Me("k-input","k-datepicker",{[`k-input-${Gr.sizeMap[r]||r}`]:r,[`k-rounded-${Gr.roundedMap[n]||n}`]:n,[`k-input-${i}`]:i,"k-invalid":!ue,"k-required":this.required,"k-disabled":o},b),onKeyDown:this.handleKeyDown,style:{width:z},onFocus:se.onFocus,onBlur:se.onBlur,onClick:this.mobileMode?this.handleIconClick:void 0},_.createElement(this.dateInputComp,{_ref:this._dateInput,ariaRole:"combobox",readonly:this.mobileMode,ariaExpanded:this.show,ariaControls:this._popupId,autoFocus:Bt,...Ot}),_.createElement(this.toggleButtonComp,{type:"button",icon:"calendar",svgIcon:bVt,title:we,className:"k-input-button",rounded:null,onClick:this.mobileMode?void 0:this.handleIconClick,"aria-label":we,fillMode:i,onMouseDown:this.handleIconMouseDown}),!this.mobileMode&&this.renderPopup()),this.mobileMode&&this.renderAdaptivePopup()));return G?_.createElement(cWt,{dateInput:this._dateInput,label:G,editorId:l,editorValid:ue,editorDisabled:o,children:Ht,style:{width:z},...ae}):Ht}setShow(r){const{onOpen:n,onClose:i}=this.props;this.show!==r&&(this.setState({show:r}),r&&n&&n.call(void 0,{target:this}),!r&&i&&i.call(void 0,{target:this}))}mergeTime(r){return this.value&&r?Fc(r,this.value):r}nextTick(r){clearTimeout(this.nextTickId),this.nextTickId=window.setTimeout(()=>r())}calculateMedia(r){for(let n of r)this.setState({windowWidth:n.target.clientWidth})}};tu.displayName="DatePicker",tu.propTypes={className:B.string,defaultShow:B.bool,defaultValue:B.instanceOf(Date),disabled:B.bool,focusedDate:B.instanceOf(Date),format:B.oneOfType([B.string,B.shape({skeleton:B.string,pattern:B.string,date:B.oneOf(["short","medium","long","full"]),time:B.oneOf(["short","medium","long","full"]),datetime:B.oneOf(["short","medium","long","full"]),era:B.oneOf(["narrow","short","long"]),year:B.oneOf(["numeric","2-digit"]),month:B.oneOf(["numeric","2-digit","narrow","short","long"]),day:B.oneOf(["numeric","2-digit"]),weekday:B.oneOf(["narrow","short","long"]),hour:B.oneOf(["numeric","2-digit"]),hour12:B.bool,minute:B.oneOf(["numeric","2-digit"]),second:B.oneOf(["numeric","2-digit"]),timeZoneName:B.oneOf(["short","long"])})]),formatPlaceholder:B.oneOfType([B.oneOf(["wide","narrow","short","formatPattern"]),B.shape({year:B.string,month:B.string,day:B.string,hour:B.string,minute:B.string,second:B.string})]),id:B.string,ariaLabelledBy:B.string,ariaDescribedBy:B.string,ariaLabel:B.string,min:B.instanceOf(Date),max:B.instanceOf(Date),name:B.string,popupSettings:B.shape({animate:B.bool,appendTo:B.any,popupClass:B.string}),show:B.bool,tabIndex:B.number,title:B.string,value:B.instanceOf(Date),weekNumber:B.bool,width:B.oneOfType([B.number,B.string]),validationMessage:B.string,required:B.bool,validate:B.bool,valid:B.bool,size:B.oneOf([null,"small","medium","large"]),rounded:B.oneOf([null,"small","medium","large","full"]),fillMode:B.oneOf([null,"solid","flat","outline"]),adaptive:B.bool,adaptiveTitle:B.string,autoFocus:B.bool},tu.defaultProps={defaultShow:!1,defaultValue:null,dateInput:LC,calendar:NB,toggleButton:aWt,popup:A4,pickerWrap:sWt,disabled:!1,format:"d",max:w5,min:b5,popupSettings:{},tabIndex:0,weekNumber:!1,required:!1,validityStyles:!0,size:"medium",rounded:"medium",fillMode:"solid",autoFocus:!1};let WB=tu;const pWt=R8(),EC=na(up(pWt,WB));EC.displayName="KendoReactDatePicker";Ri(WB);/** + */const tu=class ln extends _.Component{constructor(r){super(r),this._element=null,this._dateInput=_.createRef(),this._calendar=null,this.shouldFocusDateInput=!1,this.prevShow=!1,this.focus=()=>{this.dateInput&&this.dateInput.focus()},this.setCalendarRef=n=>{this._calendar=n},this.nextValue=(n,i)=>n.value!==void 0?n.value:i.value,this.nextShow=(n,i)=>n.show!==void 0?n.show:i.show,this.renderPopup=()=>{const{disabled:n,min:i,max:o,weekNumber:a,focusedDate:s,popupSettings:l}=this.props,{popupClass:h,...p}=l,f=this.show,g=this.value,b=g&&dr(g),z=ke(h),M={popupClass:"k-datepicker-popup",show:f,anchor:this._element,className:z,id:this._popupId,anchorAlign:{horizontal:"left",vertical:"bottom"},popupAlign:{horizontal:"left",vertical:"top"},...p},I={disabled:n,value:b,min:i,max:o,weekNumber:a,focusedDate:s,className:this.mobileMode?"k-calendar-lg":"",navigation:!this.mobileMode,onChange:this.handleCalendarValueChange};return this.mobileMode?_.createElement(this.calendarComp,{_ref:this.setCalendarRef,...I}):_.createElement(this.popupComp,{...M},_.createElement(this.calendarComp,{_ref:this.setCalendarRef,...I}))},this.renderAdaptivePopup=()=>{const{windowWidth:n=0}=this.state,i={expand:this.show,onClose:this.handleBlur,adaptiveTitle:this.props.adaptiveTitle,windowWidth:n};return _.createElement(uWt,{...i},_.createElement(d5,{className:"!k-overflow-hidden"},this.renderPopup()))},this.handleInputValueChange=n=>{this.handleValueChange(n.value,n)},this.handleCalendarValueChange=n=>{const i=this.mergeTime(n.value);this.handleValueChange(i,n)},this.handleValueChange=(n,i)=>{this.setState({value:N1(n||void 0)}),this.valueDuringOnChange=n,this.showDuringOnChange=!1,this.mobileMode||(this.shouldFocusDateInput=!0);const{onChange:o}=this.props;o&&o.call(void 0,{syntheticEvent:i.syntheticEvent,nativeEvent:i.nativeEvent,value:this.value,show:this.show,target:this}),this.valueDuringOnChange=void 0,this.showDuringOnChange=void 0,this.setShow(!1)},this.handleFocus=()=>{this.setState({focused:!0})},this.handleBlur=()=>{this.setState({focused:!1}),this.setShow(!1)},this.handleIconClick=()=>{this.props.disabled||(this.shouldFocusDateInput=!0,this.setShow(!this.show))},this.handleIconMouseDown=n=>{n.preventDefault()},this.handleKeyDown=n=>{const{altKey:i,keyCode:o}=n;if(o===te.esc&&this.show){this.shouldFocusDateInput=!0,this.setShow(!1);return}i&&(o===te.up||o===te.down)&&(n.preventDefault(),n.stopPropagation(),this.shouldFocusDateInput=o===te.up,this.setShow(o===te.down))},vi(AC),this.state={value:this.props.defaultValue||ln.defaultProps.defaultValue,show:this.props.defaultShow||ln.defaultProps.defaultShow,focused:!1}}get _popupId(){return this.props.id+"-popup-id"}get document(){if(oi)return this.element&&this.element.ownerDocument||document}get element(){return this._element}get mobileMode(){return!!(this.state.windowWidth&&this.state.windowWidth<=pWt&&this.props.adaptive)}get dateInput(){return this._dateInput.current}get calendar(){return this._calendar}get value(){const r=this.valueDuringOnChange!==void 0?this.valueDuringOnChange:this.props.value!==void 0?this.props.value:this.state.value;return r!==null?N1(r):null}get show(){return this.showDuringOnChange!==void 0?this.showDuringOnChange:this.props.show!==void 0?this.props.show:this.state.show}get name(){return this.props.name}get min(){return this.props.min!==void 0?this.props.min:ln.defaultProps.min}get max(){return this.props.max!==void 0?this.props.max:ln.defaultProps.max}get dateInputComp(){return this.props.dateInput||ln.defaultProps.dateInput}get toggleButtonComp(){return this.props.toggleButton||ln.defaultProps.toggleButton}get calendarComp(){return this.props.calendar||ln.defaultProps.calendar}get popupComp(){return this.props.popup||ln.defaultProps.popup}get pickerWrapComp(){return this.props.pickerWrap||ln.defaultProps.pickerWrap}get validity(){const r=YNt(this.value,this.min,this.max),n=this.props.validationMessage!==void 0,i=(!this.required||this.value!==null)&&r,o=this.props.valid!==void 0?this.props.valid:i;return{customError:n,rangeOverflow:this.value&&this.max.getTime()_.createElement(_.Fragment,null,_.createElement("span",{...G?{}:le,ref:Se=>{this._element=Se},className:ke("k-input","k-datepicker",{[`k-input-${Wr.sizeMap[r]||r}`]:r,[`k-rounded-${Wr.roundedMap[n]||n}`]:n,[`k-input-${i}`]:i,"k-invalid":!de,"k-required":this.required,"k-disabled":o},b),onKeyDown:this.handleKeyDown,style:{width:z},onFocus:ce.onFocus,onBlur:ce.onBlur,onClick:this.mobileMode?this.handleIconClick:void 0},_.createElement(this.dateInputComp,{_ref:this._dateInput,ariaRole:"combobox",readonly:this.mobileMode,ariaExpanded:this.show,ariaControls:this._popupId,autoFocus:Rt,...Ft}),_.createElement(this.toggleButtonComp,{type:"button",icon:"calendar",svgIcon:wVt,title:we,className:"k-input-button",rounded:null,onClick:this.mobileMode?void 0:this.handleIconClick,"aria-label":we,fillMode:i,onMouseDown:this.handleIconMouseDown}),!this.mobileMode&&this.renderPopup()),this.mobileMode&&this.renderAdaptivePopup()));return G?_.createElement(hWt,{dateInput:this._dateInput,label:G,editorId:l,editorValid:de,editorDisabled:o,children:Ht,style:{width:z},...le}):Ht}setShow(r){const{onOpen:n,onClose:i}=this.props;this.show!==r&&(this.setState({show:r}),r&&n&&n.call(void 0,{target:this}),!r&&i&&i.call(void 0,{target:this}))}mergeTime(r){return this.value&&r?Fc(r,this.value):r}nextTick(r){clearTimeout(this.nextTickId),this.nextTickId=window.setTimeout(()=>r())}calculateMedia(r){for(let n of r)this.setState({windowWidth:n.target.clientWidth})}};tu.displayName="DatePicker",tu.propTypes={className:B.string,defaultShow:B.bool,defaultValue:B.instanceOf(Date),disabled:B.bool,focusedDate:B.instanceOf(Date),format:B.oneOfType([B.string,B.shape({skeleton:B.string,pattern:B.string,date:B.oneOf(["short","medium","long","full"]),time:B.oneOf(["short","medium","long","full"]),datetime:B.oneOf(["short","medium","long","full"]),era:B.oneOf(["narrow","short","long"]),year:B.oneOf(["numeric","2-digit"]),month:B.oneOf(["numeric","2-digit","narrow","short","long"]),day:B.oneOf(["numeric","2-digit"]),weekday:B.oneOf(["narrow","short","long"]),hour:B.oneOf(["numeric","2-digit"]),hour12:B.bool,minute:B.oneOf(["numeric","2-digit"]),second:B.oneOf(["numeric","2-digit"]),timeZoneName:B.oneOf(["short","long"])})]),formatPlaceholder:B.oneOfType([B.oneOf(["wide","narrow","short","formatPattern"]),B.shape({year:B.string,month:B.string,day:B.string,hour:B.string,minute:B.string,second:B.string})]),id:B.string,ariaLabelledBy:B.string,ariaDescribedBy:B.string,ariaLabel:B.string,min:B.instanceOf(Date),max:B.instanceOf(Date),name:B.string,popupSettings:B.shape({animate:B.bool,appendTo:B.any,popupClass:B.string}),show:B.bool,tabIndex:B.number,title:B.string,value:B.instanceOf(Date),weekNumber:B.bool,width:B.oneOfType([B.number,B.string]),validationMessage:B.string,required:B.bool,validate:B.bool,valid:B.bool,size:B.oneOf([null,"small","medium","large"]),rounded:B.oneOf([null,"small","medium","large","full"]),fillMode:B.oneOf([null,"solid","flat","outline"]),adaptive:B.bool,adaptiveTitle:B.string,autoFocus:B.bool},tu.defaultProps={defaultShow:!1,defaultValue:null,dateInput:EC,calendar:$B,toggleButton:sWt,popup:A4,pickerWrap:lWt,disabled:!1,format:"d",max:w5,min:b5,popupSettings:{},tabIndex:0,weekNumber:!1,required:!1,validityStyles:!0,size:"medium",rounded:"medium",fillMode:"solid",autoFocus:!1};let jB=tu;const dWt=R8(),IC=ra(up(dWt,jB));IC.displayName="KendoReactDatePicker";Vi(jB);/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const IC=t=>{const{ariaSort:r,colSpan:n,rowSpan:i,columnId:o,navigatable:a,ariaColumnIndex:s,ariaLabel:l,ariaSelected:h,ariaDescription:p,...f}=t,g=L4(o,a),b=_.useRef(null);return _.useEffect(()=>{b.current&&a&&vb(b.current)},[a]),_.createElement("th",{ref:b,"aria-sort":r,"aria-label":l,"aria-colindex":s,"aria-selected":h,colSpan:n,rowSpan:i,...g,...f},t.children)};IC.displayName="KendoReactHeaderThElement";/** + */const HC=t=>{const{ariaSort:r,colSpan:n,rowSpan:i,columnId:o,navigatable:a,ariaColumnIndex:s,ariaLabel:l,ariaSelected:h,ariaDescription:p,...f}=t,g=L4(o,a),b=_.useRef(null);return _.useEffect(()=>{b.current&&a&&gb(b.current)},[a]),_.createElement("th",{ref:b,"aria-sort":r,"aria-label":l,"aria-colindex":s,"aria-selected":h,colSpan:n,rowSpan:i,...g,...f},t.children)};HC.displayName="KendoReactHeaderThElement";/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */function dWt(t){const{enabled:r,columns:n=[],tableViewPortWidth:i,scrollLeft:o}=t,a=n.map(()=>1),s=n.map(()=>!1);if(!r)return{colSpans:a,hiddenColumns:s};const l=n.map(H=>parseFloat((H.width||"").toString())||10);let h=0;for(let H=0;HH+E,0);h=0;for(let H=n.length-1;H>=0;H--)if(!n[H].locked)if(h+2*l[H]H;let b=f.lastIndexOf(!1),z=f.some(g),M=f.every(g),I,F;for(;z&&f.length&&(b!==-1||M);){for(b1),s=n.map(()=>!1);if(!r)return{colSpans:a,hiddenColumns:s};const l=n.map(H=>parseFloat((H.width||"").toString())||10);let h=0;for(let H=0;HH+E,0);h=0;for(let H=n.length-1;H>=0;H--)if(!n[H].locked)if(h+2*l[H]H;let b=f.lastIndexOf(!1),z=f.some(g),M=f.every(g),I,F;for(;z&&f.length&&(b!==-1||M);){for(bnull;HC.displayName="KendoReactGridColumn";const jB={filterable:!0,editable:!0,sortable:!0,resizable:!0,reorderable:!0,groupable:!0};HC.propTypes={field:B.string,title:B.string,editable:B.bool,sortable:B.oneOfType([B.bool,B.shape({allowUnsort:B.bool.isRequired})]),cell:B.any,filterCell:B.any,filterTitle:B.string,filterable:B.bool,filter:B.oneOf(["text","numeric","boolean","date"]),editor:B.oneOf(["text","numeric","boolean","date"]),width:B.oneOfType([B.string,B.number]),minResizableWidth:B.number,headerCell:B.any,footerCell:B.any,headerSelectionValue:B.bool,format:B.string,headerClassName:B.string,className:B.string,reorderable:B.bool,resizable:B.bool,orderIndex:B.number,groupable:B.bool,columnMenu:B.any,menuIcon:B.any,locked:B.bool,hidden:B.bool,media:B.string};/** + */const DC=t=>null;DC.displayName="KendoReactGridColumn";const GB={filterable:!0,editable:!0,sortable:!0,resizable:!0,reorderable:!0,groupable:!0};DC.propTypes={field:B.string,title:B.string,editable:B.bool,sortable:B.oneOfType([B.bool,B.shape({allowUnsort:B.bool.isRequired})]),cell:B.any,filterCell:B.any,filterTitle:B.string,filterable:B.bool,filter:B.oneOf(["text","numeric","boolean","date"]),editor:B.oneOf(["text","numeric","boolean","date"]),width:B.oneOfType([B.string,B.number]),minResizableWidth:B.number,headerCell:B.any,footerCell:B.any,headerSelectionValue:B.bool,format:B.string,headerClassName:B.string,className:B.string,reorderable:B.bool,resizable:B.bool,orderIndex:B.number,groupable:B.bool,columnMenu:B.any,menuIcon:B.any,locked:B.bool,hidden:B.bool,media:B.string};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */function Wa(t,r){const n=(t||"").split(".");let i=r;return n.forEach(o=>{i=i?i[o]:void 0}),i}function GB(t,r,n,i,o,a,s=0){let l=s;for(let h=0;hs&&s.props?!s.props.hidden:!s.hidden).forEach((s,l)=>{s=s.props?s.props:s;const h=r[l]||null,p=UB(s.children,h&&h.children||[],n,i+1);o.push(Object.assign({depth:i},jB,p.length?{cell:()=>null,filterCell:()=>null}:{},h?{width:h.width,orderIndex:h.orderIndex}:{},s,{id:s.id?s.id:Je.generateNavigatableId(`${n.prevId++}`,n.idPrefix,"column"),declarationIndex:o.length,children:p,rowSpan:0,colSpan:0,isAccessible:!0,left:h&&Math.floor(h.left),right:h&&Math.floor(h.right)}))});const a=(s,l)=>s.orderIndex===l.orderIndex?s.declarationIndex-l.declarationIndex:(s.orderIndex||0)-(l.orderIndex||0);if(o.sort(a),i===0){let s=[];const l=(h,p)=>h.forEach(f=>{f.parentIndex=p,l(f.children,s.push(f)-1)});return l(o,-1),s}return o}function fWt(t,r,n,i){let o=[];Array.isArray(t)?o=t:t&&(o=t.data);const a=[];if(o.length>0){let s=o[0];if(r)for(let l=0;l{l!==n&&a.push(Object.assign({id:Je.generateNavigatableId(`${i.prevId++}`,i.idPrefix,"column"),declarationIndex:-1,parentIndex:-1,depth:0,colSpan:0,rowSpan:0,index:0,left:0,right:0,rightBorder:!1,children:[],ariaColumnIndex:0,isAccessible:!0},jB,{field:l}))})}return a}const vWt=(t,r)=>{let n=t[r.parentIndex];for(;n;){if(n.footerCell)return!0;n=t[n.parentIndex]}return!1},gWt=t=>t.filter(r=>vWt(t,r)?!1:!!r.footerCell||!(r.children&&r.children.length>0)),Xv=t=>t.width!==void 0?Math.floor(parseFloat(t.width.toString()))+"px":void 0,YB=t=>(t.sort((r,n)=>r.declarationIndex-n.declarationIndex),t.map(r=>{const{declarationIndex:n,parentIndex:i,depth:o,colSpan:a,rowSpan:s,index:l,kFirst:h,children:p,...f}=r;return p.length?{children:YB(p),...f}:f})),Ry=typeof window<"u"&&/Firefox/.test(window.navigator.userAgent),YE=17895697,cd=(t,r)=>{if(!(!t&&!r))return r?t?{...t,...r,select:{...t.select||{},...r.select||{}},hierarchy:{...t.hierarchy||{},...r.hierarchy||{}},group:{...t.group||{},...r.group||{}},edit:{...t.edit||{},...r.edit||{}}}:r:t};/** + */function $a(t,r){const n=(t||"").split(".");let i=r;return n.forEach(o=>{i=i?i[o]:void 0}),i}function UB(t,r,n,i,o,a,s=0){let l=s;for(let h=0;hs&&s.props?!s.props.hidden:!s.hidden).forEach((s,l)=>{s=s.props?s.props:s;const h=r[l]||null,p=YB(s.children,h&&h.children||[],n,i+1);o.push(Object.assign({depth:i},GB,p.length?{cell:()=>null,filterCell:()=>null}:{},h?{width:h.width,orderIndex:h.orderIndex}:{},s,{id:s.id?s.id:Je.generateNavigatableId(`${n.prevId++}`,n.idPrefix,"column"),declarationIndex:o.length,children:p,rowSpan:0,colSpan:0,isAccessible:!0,left:h&&Math.floor(h.left),right:h&&Math.floor(h.right)}))});const a=(s,l)=>s.orderIndex===l.orderIndex?s.declarationIndex-l.declarationIndex:(s.orderIndex||0)-(l.orderIndex||0);if(o.sort(a),i===0){let s=[];const l=(h,p)=>h.forEach(f=>{f.parentIndex=p,l(f.children,s.push(f)-1)});return l(o,-1),s}return o}function vWt(t,r,n,i){let o=[];Array.isArray(t)?o=t:t&&(o=t.data);const a=[];if(o.length>0){let s=o[0];if(r)for(let l=0;l{l!==n&&a.push(Object.assign({id:Je.generateNavigatableId(`${i.prevId++}`,i.idPrefix,"column"),declarationIndex:-1,parentIndex:-1,depth:0,colSpan:0,rowSpan:0,index:0,left:0,right:0,rightBorder:!1,children:[],ariaColumnIndex:0,isAccessible:!0},GB,{field:l}))})}return a}const gWt=(t,r)=>{let n=t[r.parentIndex];for(;n;){if(n.footerCell)return!0;n=t[n.parentIndex]}return!1},mWt=t=>t.filter(r=>gWt(t,r)?!1:!!r.footerCell||!(r.children&&r.children.length>0)),Xv=t=>t.width!==void 0?Math.floor(parseFloat(t.width.toString()))+"px":void 0,XB=t=>(t.sort((r,n)=>r.declarationIndex-n.declarationIndex),t.map(r=>{const{declarationIndex:n,parentIndex:i,depth:o,colSpan:a,rowSpan:s,index:l,kFirst:h,children:p,...f}=r;return p.length?{children:XB(p),...f}:f})),Ry=typeof window<"u"&&/Firefox/.test(window.navigator.userAgent),XE=17895697,cd=(t,r)=>{if(!(!t&&!r))return r?t?{...t,...r,select:{...t.select||{},...r.select||{}},hierarchy:{...t.hierarchy||{},...r.hierarchy||{}},group:{...t.group||{},...r.group||{}},edit:{...t.edit||{},...r.edit||{}}}:r:t};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const Oy="grid.noRecords",mWt="grid.pagerInfo",yWt="grid.pagerFirstPage",xWt="grid.pagerPreviousPage",bWt="grid.pagerNextPage",wWt="grid.pagerLastPage",CWt="grid.pagerItemsPerPage",SWt="grid.pagerPage",zWt="grid.pagerPageSizeAriaLabel",MWt="grid.pagerOf",kWt="grid.pagerTotalPages",By="grid.groupPanelEmpty",_Wt="grid.groupColumn",AWt="grid.ungroupColumn",Ny="grid.columnMenu",$y="grid.filterClearButton",LWt="grid.filterSubmitButton",EWt="grid.filterTitle",IWt="grid.sortAscending",HWt="grid.sortDescending",DWt="grid.searchPlaceholder",PWt="grid.filterCheckAll",Wy="grid.filterChooseOperator",TWt="grid.filterSelectedItems",jy="grid.sortAriaLabel",Gy="grid.filterAriaLabel",Uy="grid.groupPanelAriaLabel",XB="grid.groupExpand",KB="grid.groupCollapse",qB="grid.detailExpand",ZB="grid.detailCollapse",k8="grid.selectRow",Yy="grid.gridAriaLabel",xn={[qB]:"Expand detail row",[ZB]:"Collapse detail row",[XB]:"Expand group",[KB]:"Collapse Group",[Oy]:"No records available",[By]:"Drag a column header and drop it here to group by that column",[$y]:"Clear",[LWt]:"Filter",[EWt]:"Filter",[IWt]:"Sort Ascending",[HWt]:"Sort Descending",[jy]:"Sortable",[_Wt]:"Group Column",[AWt]:"Ungroup Column",[Ny]:"Column menu",[CWt]:"items per page",[mWt]:"{0} - {1} of {2} items",[yWt]:"Go to the first page",[xWt]:"Go to the previous page",[bWt]:"Go to the next page",[wWt]:"Go to the last page",[SWt]:"Page",[zWt]:"Page size",[MWt]:"of",[kWt]:"{0}",[DWt]:"Search",[PWt]:"Check All",[Wy]:"Choose Operator",[TWt]:"selected items",[Gy]:"Filter",[Uy]:"Group panel",[Yy]:"Table",[k8]:"Select Row","grid.filterEqOperator":"Is equal to","grid.filterNotEqOperator":"Is not equal to","grid.filterIsNullOperator":"Is null","grid.filterIsNotNullOperator":"Is not null","grid.filterIsEmptyOperator":"Is empty","grid.filterIsNotEmptyOperator":"Is not empty","grid.filterStartsWithOperator":"Starts with","grid.filterContainsOperator":"Contains","grid.filterNotContainsOperator":"Does not contain","grid.filterEndsWithOperator":"Ends with","grid.filterGteOperator":"Is greater than or equal to","grid.filterGtOperator":"Is greater than","grid.filterLteOperator":"Is less than or equal to","grid.filterLtOperator":"Is less than","grid.filterIsTrue":"Is true","grid.filterIsFalse":"Is false","grid.filterBooleanAll":"(All)","grid.filterAfterOrEqualOperator":"Is after or equal to","grid.filterAfterOperator":"Is after","grid.filterBeforeOperator":"Is before","grid.filterBeforeOrEqualOperator":"Is before or equal to","grid.filterAndLogic":"And","grid.filterOrLogic":"Or"};function VWt(t){const r=t.replace(/^pager\.([a-z])/,(n,i)=>"grid.pager"+i.toUpperCase());return{messageKey:r,defaultMessage:xn[r]}}/** + */const Oy="grid.noRecords",yWt="grid.pagerInfo",xWt="grid.pagerFirstPage",bWt="grid.pagerPreviousPage",wWt="grid.pagerNextPage",CWt="grid.pagerLastPage",SWt="grid.pagerItemsPerPage",zWt="grid.pagerPage",MWt="grid.pagerPageSizeAriaLabel",kWt="grid.pagerOf",_Wt="grid.pagerTotalPages",By="grid.groupPanelEmpty",AWt="grid.groupColumn",LWt="grid.ungroupColumn",Ny="grid.columnMenu",$y="grid.filterClearButton",EWt="grid.filterSubmitButton",IWt="grid.filterTitle",HWt="grid.sortAscending",DWt="grid.sortDescending",PWt="grid.searchPlaceholder",TWt="grid.filterCheckAll",Wy="grid.filterChooseOperator",VWt="grid.filterSelectedItems",jy="grid.sortAriaLabel",Gy="grid.filterAriaLabel",Uy="grid.groupPanelAriaLabel",KB="grid.groupExpand",qB="grid.groupCollapse",ZB="grid.detailExpand",JB="grid.detailCollapse",k8="grid.selectRow",Yy="grid.gridAriaLabel",mn={[ZB]:"Expand detail row",[JB]:"Collapse detail row",[KB]:"Expand group",[qB]:"Collapse Group",[Oy]:"No records available",[By]:"Drag a column header and drop it here to group by that column",[$y]:"Clear",[EWt]:"Filter",[IWt]:"Filter",[HWt]:"Sort Ascending",[DWt]:"Sort Descending",[jy]:"Sortable",[AWt]:"Group Column",[LWt]:"Ungroup Column",[Ny]:"Column menu",[SWt]:"items per page",[yWt]:"{0} - {1} of {2} items",[xWt]:"Go to the first page",[bWt]:"Go to the previous page",[wWt]:"Go to the next page",[CWt]:"Go to the last page",[zWt]:"Page",[MWt]:"Page size",[kWt]:"of",[_Wt]:"{0}",[PWt]:"Search",[TWt]:"Check All",[Wy]:"Choose Operator",[VWt]:"selected items",[Gy]:"Filter",[Uy]:"Group panel",[Yy]:"Table",[k8]:"Select Row","grid.filterEqOperator":"Is equal to","grid.filterNotEqOperator":"Is not equal to","grid.filterIsNullOperator":"Is null","grid.filterIsNotNullOperator":"Is not null","grid.filterIsEmptyOperator":"Is empty","grid.filterIsNotEmptyOperator":"Is not empty","grid.filterStartsWithOperator":"Starts with","grid.filterContainsOperator":"Contains","grid.filterNotContainsOperator":"Does not contain","grid.filterEndsWithOperator":"Ends with","grid.filterGteOperator":"Is greater than or equal to","grid.filterGtOperator":"Is greater than","grid.filterLteOperator":"Is less than or equal to","grid.filterLtOperator":"Is less than","grid.filterIsTrue":"Is true","grid.filterIsFalse":"Is false","grid.filterBooleanAll":"(All)","grid.filterAfterOrEqualOperator":"Is after or equal to","grid.filterAfterOperator":"Is after","grid.filterBeforeOperator":"Is before","grid.filterBeforeOrEqualOperator":"Is before or equal to","grid.filterAndLogic":"And","grid.filterOrLogic":"Or"};function FWt(t){const r=t.replace(/^pager\.([a-z])/,(n,i)=>"grid.pager"+i.toUpperCase());return{messageKey:r,defaultMessage:mn[r]}}/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const FWt=t=>{const{selectionChange:r,field:n,dataItem:i,id:o,className:a,colSpan:s,style:l,ariaColumnIndex:h,rowType:p,cells:f,render:g}=t,b=jl(),z=_.useCallback(K=>{r&&r({syntheticEvent:K})},[r]),M=pp(),I=Wa(n,i),F=L4(o),H=Me("k-table-td",a),E={colSpan:s,style:l,className:H,"aria-colindex":h,role:"gridcell",...F},R=typeof I=="boolean"&&I,W=_.createElement("span",{key:1,className:"k-checkbox-wrap"},_.createElement("input",{id:M,tabIndex:-1,type:"checkbox",className:"k-checkbox k-checkbox-md k-rounded-md","aria-label":b.toLanguageString(k8,xn[k8]),"aria-checked":R,checked:R,onChange:z})),$=p!=="groupHeader"?_.createElement("td",{...E},W):null,G=p||"data",Z=f;if(Z&&Z.select&&Z.select[G]){const K=Z.select[G];return _.createElement(K,{...t,tdProps:E},W)}return g?g.call(void 0,$,t):$};/** + */const RWt=t=>{const{selectionChange:r,field:n,dataItem:i,id:o,className:a,colSpan:s,style:l,ariaColumnIndex:h,rowType:p,cells:f,render:g}=t,b=jl(),z=_.useCallback(K=>{r&&r({syntheticEvent:K})},[r]),M=pp(),I=$a(n,i),F=L4(o),H=ke("k-table-td",a),E={colSpan:s,style:l,className:H,"aria-colindex":h,role:"gridcell",...F},R=typeof I=="boolean"&&I,W=_.createElement("span",{key:1,className:"k-checkbox-wrap"},_.createElement("input",{id:M,tabIndex:-1,type:"checkbox",className:"k-checkbox k-checkbox-md k-rounded-md","aria-label":b.toLanguageString(k8,mn[k8]),"aria-checked":R,checked:R,onChange:z})),$=p!=="groupHeader"?_.createElement("td",{...E},W):null,G=p||"data",Z=f;if(Z&&Z.select&&Z.select[G]){const K=Z.select[G];return _.createElement(K,{...t,tdProps:E},W)}return g?g.call(void 0,$,t):$};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const RWt=t=>{let r=null,n=null,i=null;const o=Wa(t.field,t.dataItem),a=L4(t.id),s=jl(),l=_.useCallback(f=>{f.isDefaultPrevented()||f.keyCode===Jt.enter&&t.onChange&&(f.preventDefault(),t.onChange({dataItem:t.dataItem,dataIndex:t.dataIndex,syntheticEvent:f,field:t.field,value:!o}))},[t.dataItem,t.dataIndex,t.field,t.onChange,o]);if(t.rowType==="groupFooter")n={className:"k-table-td k-hierarchy-cell",role:"gridcell",...a},r=_.createElement("td",{...n});else if(t.rowType!=="groupHeader"){const f=o?ZB:qB,g=s.toLanguageString(f,xn[f]);n={className:"k-table-td k-hierarchy-cell",onKeyDown:l,"aria-expanded":!!o,role:"gridcell","aria-colindex":t.ariaColumnIndex,...a},i=_.createElement("a",{onClick:b=>{b.preventDefault(),t.onChange&&t.onChange({dataItem:t.dataItem,dataIndex:t.dataIndex,syntheticEvent:b,field:t.field,value:!o})},"aria-label":g,href:"#",tabIndex:-1},_.createElement(en,{name:o?"minus":"plus",icon:o?SVt:fO})),r=_.createElement("td",{...n},i)}const h=t.rowType||"data",p=t.cells;if(p&&p.hierarchy&&p.hierarchy[h]){const f=p.hierarchy[h];return _.createElement(f,{...t,tdProps:n},i)}return t.render?t.render.call(void 0,r,t):r};/** + */const OWt=t=>{let r=null,n=null,i=null;const o=$a(t.field,t.dataItem),a=L4(t.id),s=jl(),l=_.useCallback(f=>{f.isDefaultPrevented()||f.keyCode===te.enter&&t.onChange&&(f.preventDefault(),t.onChange({dataItem:t.dataItem,dataIndex:t.dataIndex,syntheticEvent:f,field:t.field,value:!o}))},[t.dataItem,t.dataIndex,t.field,t.onChange,o]);if(t.rowType==="groupFooter")n={className:"k-table-td k-hierarchy-cell",role:"gridcell",...a},r=_.createElement("td",{...n});else if(t.rowType!=="groupHeader"){const f=o?JB:ZB,g=s.toLanguageString(f,mn[f]);n={className:"k-table-td k-hierarchy-cell",onKeyDown:l,"aria-expanded":!!o,role:"gridcell","aria-colindex":t.ariaColumnIndex,...a},i=_.createElement("a",{onClick:b=>{b.preventDefault(),t.onChange&&t.onChange({dataItem:t.dataItem,dataIndex:t.dataIndex,syntheticEvent:b,field:t.field,value:!o})},"aria-label":g,href:"#",tabIndex:-1},_.createElement(Qi,{name:o?"minus":"plus",icon:o?zVt:vO})),r=_.createElement("td",{...n},i)}const h=t.rowType||"data",p=t.cells;if(p&&p.hierarchy&&p.hierarchy[h]){const f=p.hierarchy[h];return _.createElement(f,{...t,tdProps:n},i)}return t.render?t.render.call(void 0,r,t):r};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const OWt=zB,xc=MB,BWt=/^(?!.*\bChrome).*\bSafari/i;/** + */const BWt=MB,xc=kB,NWt=/^(?!.*\bChrome).*\bSafari/i;/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const NWt=t=>{const r=Wa(t.field,t.dataItem);let n=null;const i=Me("k-table-td","k-grid-edit-cell",{"k-selected":t.isSelected},t.className),o=pp(),a=L4(t.id);let s=null,l=null;const h=_.useCallback(z=>{if(t.onChange){const M=z.target.type==="checkbox"?z.target.checked:z.target.value;t.onChange({dataItem:t.dataItem,dataIndex:t.dataIndex,field:t.field,syntheticEvent:z,value:M})}},[t.onChange,t.dataItem,t.dataIndex,t.field]),p=_.useCallback(z=>{t.onContextMenu&&t.onContextMenu.call(void 0,z,t.dataItem,t.field)},[t.onContextMenu,t.dataItem,t.field]),f=_.useCallback(z=>{t.onChange&&t.onChange({dataItem:t.dataItem,dataIndex:t.dataIndex,field:t.field,syntheticEvent:z.syntheticEvent,value:z.value})},[t.onChange,t.dataItem,t.dataIndex,t.field]);switch(t.editor){case"numeric":{s={onContextMenu:p,colSpan:t.colSpan,style:t.style,className:i,"aria-colindex":t.ariaColumnIndex,"aria-selected":t.isSelected,[xc]:t.columnIndex,role:"gridcell",...a},l=_.createElement(g5,{value:r===void 0?null:r,onChange:f,[X7]:!0}),n=_.createElement("td",{...s},l);break}case"date":s={onContextMenu:p,colSpan:t.colSpan,style:t.style,className:i,"aria-colindex":t.ariaColumnIndex,"aria-selected":t.isSelected,[xc]:t.columnIndex,role:"gridcell",...a},l=_.createElement(EC,{value:r,onChange:f,[X7]:!0}),n=_.createElement("td",{...s},l);break;case"boolean":s={onContextMenu:p,colSpan:t.colSpan,style:t.style,className:i,"aria-colindex":t.ariaColumnIndex,"aria-selected":t.isSelected,[xc]:t.columnIndex,role:"gridcell",...a},l=[_.createElement("span",{key:1,className:"k-checkbox-wrap"},_.createElement("input",{checked:r||!1,id:o,type:"checkbox",className:"k-checkbox k-checkbox-md k-rounded-md",onChange:h})),_.createElement("label",{className:"k-checkbox-label",htmlFor:o,key:2})],n=_.createElement("td",{...s},l);break;default:s={onContextMenu:p,colSpan:t.colSpan,style:t.style,className:i,"aria-colindex":t.ariaColumnIndex,"aria-selected":t.isSelected,[xc]:t.columnIndex,role:"gridcell",...a},l=_.createElement("input",{style:{width:"100%"},className:"k-input",value:r||"",onChange:h,[X7]:!0}),n=_.createElement("td",{...s},l)}const g=t.editor||"text",b=t.cells;if(b){let z;return b.edit&&b.edit[g]?z=b.edit[g]:b.data&&(z=b.data),_.createElement(z,{...t,tdProps:s},l)}return t.render?t.render.call(void 0,n,t):n};/** + */const $Wt=t=>{const r=$a(t.field,t.dataItem);let n=null;const i=ke("k-table-td","k-grid-edit-cell",{"k-selected":t.isSelected},t.className),o=pp(),a=L4(t.id);let s=null,l=null;const h=_.useCallback(z=>{if(t.onChange){const M=z.target.type==="checkbox"?z.target.checked:z.target.value;t.onChange({dataItem:t.dataItem,dataIndex:t.dataIndex,field:t.field,syntheticEvent:z,value:M})}},[t.onChange,t.dataItem,t.dataIndex,t.field]),p=_.useCallback(z=>{t.onContextMenu&&t.onContextMenu.call(void 0,z,t.dataItem,t.field)},[t.onContextMenu,t.dataItem,t.field]),f=_.useCallback(z=>{t.onChange&&t.onChange({dataItem:t.dataItem,dataIndex:t.dataIndex,field:t.field,syntheticEvent:z.syntheticEvent,value:z.value})},[t.onChange,t.dataItem,t.dataIndex,t.field]);switch(t.editor){case"numeric":{s={onContextMenu:p,colSpan:t.colSpan,style:t.style,className:i,"aria-colindex":t.ariaColumnIndex,"aria-selected":t.isSelected,[xc]:t.columnIndex,role:"gridcell",...a},l=_.createElement(g5,{value:r===void 0?null:r,onChange:f,[X7]:!0}),n=_.createElement("td",{...s},l);break}case"date":s={onContextMenu:p,colSpan:t.colSpan,style:t.style,className:i,"aria-colindex":t.ariaColumnIndex,"aria-selected":t.isSelected,[xc]:t.columnIndex,role:"gridcell",...a},l=_.createElement(IC,{value:r,onChange:f,[X7]:!0}),n=_.createElement("td",{...s},l);break;case"boolean":s={onContextMenu:p,colSpan:t.colSpan,style:t.style,className:i,"aria-colindex":t.ariaColumnIndex,"aria-selected":t.isSelected,[xc]:t.columnIndex,role:"gridcell",...a},l=[_.createElement("span",{key:1,className:"k-checkbox-wrap"},_.createElement("input",{checked:r||!1,id:o,type:"checkbox",className:"k-checkbox k-checkbox-md k-rounded-md",onChange:h})),_.createElement("label",{className:"k-checkbox-label",htmlFor:o,key:2})],n=_.createElement("td",{...s},l);break;default:s={onContextMenu:p,colSpan:t.colSpan,style:t.style,className:i,"aria-colindex":t.ariaColumnIndex,"aria-selected":t.isSelected,[xc]:t.columnIndex,role:"gridcell",...a},l=_.createElement("input",{style:{width:"100%"},className:"k-input",value:r||"",onChange:h,[X7]:!0}),n=_.createElement("td",{...s},l)}const g=t.editor||"text",b=t.cells;if(b){let z;return b.edit&&b.edit[g]?z=b.edit[g]:b.data&&(z=b.data),_.createElement(z,{...t,tdProps:s},l)}return t.render?t.render.call(void 0,n,t):n};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let $Wt=class extends _.Component{constructor(){super(...arguments),this.headerWrap=null,this.table=null,this.syncScroll=!1,this.scrollbarWidth=KP(),this.onScroll=r=>{if(this.syncScroll){this.syncScroll=!1;return}if(!this.headerWrap)return;const n=this.headerWrap.scrollLeft,i=this.props.scrollableDataElement();i&&i.scrollLeft!==n&&(i.scrollLeft=n)}}get element(){return this.props.elemRef.current}componentDidMount(){const r=wB(this.element);this.props.columnResize&&this.props.columnResize.setIsRtl(r),this.forceUpdate()}setScrollLeft(r){this.headerWrap&&this.headerWrap.scrollLeft!==r&&(this.syncScroll=!0,this.headerWrap.scrollLeft=r)}setWidth(r){this.table&&(this.table.style.width=r+"px")}render(){return this.props.staticHeaders?_.createElement("div",{ref:this.props.elemRef,className:Me("k-grid-header",this.props.className,{"k-grid-draggable-header":this.props.draggable}),role:"presentation"},_.createElement("div",{ref:r=>{this.headerWrap=r},className:"k-grid-header-wrap",style:this.props.hasScrollbarWidth?{}:{borderWidth:0},onScroll:this.onScroll,role:"presentation"},_.createElement("table",{ref:r=>{this.table=r},className:Me("k-table k-grid-header-table",{"k-table-md":!this.props.size,[`k-table-${Gr.sizeMap[this.props.size]||this.props.size}`]:this.props.size},this.props.className),role:"presentation"},_.createElement("colgroup",{ref:r=>{this.props.columnResize.colGroupHeader=r}},this.props.cols),_.createElement("thead",{className:"k-table-thead",role:"rowgroup",...PE},this.props.headerRow,this.props.filterRow)))):_.createElement("thead",{role:"presentation",className:Me("k-table-thead",this.props.className,{"k-grid-draggable-header":this.props.draggable}),...PE},this.props.headerRow,this.props.filterRow)}};/** + */let WWt=class extends _.Component{constructor(){super(...arguments),this.headerWrap=null,this.table=null,this.syncScroll=!1,this.scrollbarWidth=qP(),this.onScroll=r=>{if(this.syncScroll){this.syncScroll=!1;return}if(!this.headerWrap)return;const n=this.headerWrap.scrollLeft,i=this.props.scrollableDataElement();i&&i.scrollLeft!==n&&(i.scrollLeft=n)}}get element(){return this.props.elemRef.current}componentDidMount(){const r=CB(this.element);this.props.columnResize&&this.props.columnResize.setIsRtl(r),this.forceUpdate()}setScrollLeft(r){this.headerWrap&&this.headerWrap.scrollLeft!==r&&(this.syncScroll=!0,this.headerWrap.scrollLeft=r)}setWidth(r){this.table&&(this.table.style.width=r+"px")}render(){return this.props.staticHeaders?_.createElement("div",{ref:this.props.elemRef,className:ke("k-grid-header",this.props.className,{"k-grid-draggable-header":this.props.draggable}),role:"presentation"},_.createElement("div",{ref:r=>{this.headerWrap=r},className:"k-grid-header-wrap",style:this.props.hasScrollbarWidth?{}:{borderWidth:0},onScroll:this.onScroll,role:"presentation"},_.createElement("table",{ref:r=>{this.table=r},className:ke("k-table k-grid-header-table",{"k-table-md":!this.props.size,[`k-table-${Wr.sizeMap[this.props.size]||this.props.size}`]:this.props.size},this.props.className),role:"presentation"},_.createElement("colgroup",{ref:r=>{this.props.columnResize.colGroupHeader=r}},this.props.cols),_.createElement("thead",{className:"k-table-thead",role:"rowgroup",...TE},this.props.headerRow,this.props.filterRow)))):_.createElement("thead",{role:"presentation",className:ke("k-table-thead",this.props.className,{"k-grid-draggable-header":this.props.draggable}),...TE},this.props.headerRow,this.props.filterRow)}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const WWt=(...t)=>Object.assign({allowUnsort:!0,mode:"single"},...t);/** + */const jWt=(...t)=>Object.assign({allowUnsort:!0,mode:"single"},...t);/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let jWt=class extends _.PureComponent{constructor(){super(...arguments),this.draggable=null,this.onPress=r=>{const n=this.draggable&&this.draggable.element;n&&this.props.pressHandler&&this.props.pressHandler(r.event,n)},this.onDrag=r=>{const n=this.draggable&&this.draggable.element;n&&this.props.dragHandler&&this.props.dragHandler(r.event,n)},this.onRelease=r=>{this.draggable&&this.draggable.element&&this.props.releaseHandler&&this.props.releaseHandler(r.event)}}render(){return _.createElement(O8,{onPress:this.onPress,onDrag:this.onDrag,onRelease:this.onRelease,hint:this.props.dragClue,autoScroll:{boundaryElementRef:this.props.headerRef,direction:{horizontal:!0,vertical:!1}},scrollContainer:this.props.containerRef||void 0,ref:r=>{this.draggable=r}},_.createElement("tr",{className:"k-table-row",style:{touchAction:"none"},role:"row","aria-rowindex":this.props.ariaRowIndex},this.props.children))}};/** + */let GWt=class extends _.PureComponent{constructor(){super(...arguments),this.draggable=null,this.onPress=r=>{const n=this.draggable&&this.draggable.element;n&&this.props.pressHandler&&this.props.pressHandler(r.event,n)},this.onDrag=r=>{const n=this.draggable&&this.draggable.element;n&&this.props.dragHandler&&this.props.dragHandler(r.event,n)},this.onRelease=r=>{this.draggable&&this.draggable.element&&this.props.releaseHandler&&this.props.releaseHandler(r.event)}}render(){return _.createElement(O8,{onPress:this.onPress,onDrag:this.onDrag,onRelease:this.onRelease,hint:this.props.dragClue,autoScroll:{boundaryElementRef:this.props.headerRef,direction:{horizontal:!0,vertical:!1}},scrollContainer:this.props.containerRef||void 0,ref:r=>{this.draggable=r}},_.createElement("tr",{className:"k-table-row",style:{touchAction:"none"},role:"row","aria-rowindex":this.props.ariaRowIndex},this.props.children))}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const GWt=[".k-columnmenu-item-content",".k-filter-menu-container"].map(t=>cp.map(r=>`${t} ${r}`)),UWt=[[".k-tabstrip-items"],[".k-columnmenu-item"],...GWt],JB=t=>{const[r,n]=_.useState(!1),i=_.useRef(null),o=_.useRef(null),a=_.useRef(null),s=_.useRef(0),{columnMenu:l,...h}=t,{column:p,columnMenuIcon:f}=t,g=jl(),b=p.title||p.field,z=b?`${b} `:"",M="#",I=tt=>{const ft=Ki(document);clearTimeout(s.current),s.current=window.setTimeout(()=>{ft&&tt.relatedTarget!==i.current&&o.current&&!o.current.contains(ft)&&E()})},F=()=>{clearTimeout(s.current)},H=tt=>{tt.preventDefault(),r&&t.onCloseMenu&&t.onCloseMenu(),n(!r)},E=()=>{t.onCloseMenu&&t.onCloseMenu(),n(!1),!t.navigatable&&i.current&&i.current.focus()},R=tt=>{var ft;if(tt.keyCode===Jt.tab){const dt=tt.target,ht=dt&&((ft=dt.closest(".k-grid"))==null?void 0:ft.getElementsByClassName("k-grid-content")[0]);ht&&ht.scrollWidth>ht.clientWidth&&dt.scrollIntoView({inline:"center"})}},W=_.useMemo(()=>t.show!==void 0?t.show:r,[t.show,r]),$=tt=>{var ft;(ft=a.current)==null||ft.triggerKeyboardEvent(tt)},G=tt=>{var ft;(ft=a.current)==null||ft.triggerMouseEvent(tt)},Z=(tt,ft,dt)=>{dt.preventDefault(),dt.shiftKey?ft.focusPrevious(tt):ft.focusNext(tt)},K=(tt,ft,dt)=>{tt&&tt.click()},et=(tt,ft,dt)=>{dt.preventDefault(),E()},at=(tt,ft,dt)=>{dt.preventDefault(),ft.focusElement(tt)};return _.useEffect(()=>(W&&o.current&&(a.current=new Sb({tabIndex:0,root:o,selectors:UWt,keyboardEvents:{keydown:{Tab:Z,Enter:K,Escape:et}},mouseEvents:{mousedown:at}}),a.current.focusElement(a.current.first,null)),()=>{a.current&&(a.current=null)}),[W]),_.createElement(_.Fragment,null,_.createElement("a",{className:"k-grid-header-menu k-grid-column-menu",ref:i,onClick:H,onKeyDown:R,href:M,tabIndex:t.navigatable?-1:void 0,"aria-label":`${z}${g.toLanguageString(Ny,xn[Ny])}`},f?_.createElement(en,{name:f.name,icon:f}):_.createElement(en,{name:"more-vertical",icon:xVt})),_.createElement(A4,{anchor:i.current,show:W,popupClass:"k-column-menu k-column-menu-popup k-grid-columnmenu-popup"},_.createElement("div",{ref:o,onBlur:I,onFocus:F,onMouseDown:G,onKeyDown:$,style:{outline:"none"}},l&&_.createElement(l,{...h,onCloseMenu:E}))))};/** + */const UWt=[".k-columnmenu-item-content",".k-filter-menu-container"].map(t=>cp.map(r=>`${t} ${r}`)),YWt=[[".k-tabstrip-items"],[".k-columnmenu-item"],...UWt],QB=t=>{const[r,n]=_.useState(!1),i=_.useRef(null),o=_.useRef(null),a=_.useRef(null),s=_.useRef(0),{columnMenu:l,...h}=t,{column:p,columnMenuIcon:f}=t,g=jl(),b=p.title||p.field,z=b?`${b} `:"",M="#",I=tt=>{const ft=Yi(document);clearTimeout(s.current),s.current=window.setTimeout(()=>{ft&&tt.relatedTarget!==i.current&&o.current&&!o.current.contains(ft)&&E()})},F=()=>{clearTimeout(s.current)},H=tt=>{tt.preventDefault(),r&&t.onCloseMenu&&t.onCloseMenu(),n(!r)},E=()=>{t.onCloseMenu&&t.onCloseMenu(),n(!1),!t.navigatable&&i.current&&i.current.focus()},R=tt=>{var ft;if(tt.keyCode===te.tab){const dt=tt.target,ht=dt&&((ft=dt.closest(".k-grid"))==null?void 0:ft.getElementsByClassName("k-grid-content")[0]);ht&&ht.scrollWidth>ht.clientWidth&&dt.scrollIntoView({inline:"center"})}},W=_.useMemo(()=>t.show!==void 0?t.show:r,[t.show,r]),$=tt=>{var ft;(ft=a.current)==null||ft.triggerKeyboardEvent(tt)},G=tt=>{var ft;(ft=a.current)==null||ft.triggerMouseEvent(tt)},Z=(tt,ft,dt)=>{dt.preventDefault(),dt.shiftKey?ft.focusPrevious(tt):ft.focusNext(tt)},K=(tt,ft,dt)=>{tt&&tt.click()},et=(tt,ft,dt)=>{dt.preventDefault(),E()},at=(tt,ft,dt)=>{dt.preventDefault(),ft.focusElement(tt)};return _.useEffect(()=>(W&&o.current&&(a.current=new zb({tabIndex:0,root:o,selectors:YWt,keyboardEvents:{keydown:{Tab:Z,Enter:K,Escape:et}},mouseEvents:{mousedown:at}}),a.current.focusElement(a.current.first,null)),()=>{a.current&&(a.current=null)}),[W]),_.createElement(_.Fragment,null,_.createElement("a",{className:"k-grid-header-menu k-grid-column-menu",ref:i,onClick:H,onKeyDown:R,href:M,tabIndex:t.navigatable?-1:void 0,"aria-label":`${z}${g.toLanguageString(Ny,mn[Ny])}`},f?_.createElement(Qi,{name:f.name,icon:f}):_.createElement(Qi,{name:"more-vertical",icon:bVt})),_.createElement(A4,{anchor:i.current,show:W,popupClass:"k-column-menu k-column-menu-popup k-grid-columnmenu-popup"},_.createElement("div",{ref:o,onBlur:I,onFocus:F,onMouseDown:G,onKeyDown:$,style:{outline:"none"}},l&&_.createElement(l,{...h,onCloseMenu:E}))))};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let YWt=class extends _.Component{render(){const{columnMenuWrapperProps:r}=this.props,n=this.props.onClick?{onClick:this.props.onClick}:{},i=_.createElement("span",{className:"k-cell-inner"},_.createElement("span",{className:Me("k-link",{"!k-cursor-default":!this.props.columnMenuWrapperProps.sortable}),...n},_.createElement("span",{className:"k-column-title"},this.props.title||this.props.field||" "),this.props.children),r.columnMenu&&_.createElement(JB,{...r}));return this.props.render?this.props.render.call(void 0,i,this.props):i}};/** + */let XWt=class extends _.Component{render(){const{columnMenuWrapperProps:r}=this.props,n=this.props.onClick?{onClick:this.props.onClick}:{},i=_.createElement("span",{className:"k-cell-inner"},_.createElement("span",{className:ke("k-link",{"!k-cursor-default":!this.props.columnMenuWrapperProps.sortable}),...n},_.createElement("span",{className:"k-column-title"},this.props.title||this.props.field||" "),this.props.children),r.columnMenu&&_.createElement(QB,{...r}));return this.props.render?this.props.render.call(void 0,i,this.props):i}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const XWt={true:{asc:"desc",desc:"","":"asc"},false:{asc:"desc",desc:"asc","":"asc"}},KWt={none:"none",asc:"ascending",desc:"descending"},qWt=t=>{const[r,n]=_.useState(),i=jl(),o=_.useRef(null);let a=0,s=-1;const l=(b,z)=>{if(b.preventDefault(),!t.sortChange)return;const{allowUnsort:M,mode:I}=WWt(t.sortable||!1,z.sortable||!1),F=(t.sort||[]).filter(R=>R.field===z.field)[0],H=XWt[M][F&&F.dir||""],E=I==="single"?[]:(t.sort||[]).filter(R=>R.field!==z.field);H!==""&&z.field&&E.push({field:z.field,dir:H}),t.sortChange(E,b)},h=(b,z)=>{if(b.isDefaultPrevented())return;const{keyCode:M,metaKey:I,ctrlKey:F,altKey:H}=b,E=t.sortable&&z.sortable,R=b.target;if(E&&b.keyCode===Jt.enter&&R.className.indexOf("k-table-th")!==-1&&l(b,z),t.navigatable){if(t.groupable&&(I&&M===Jt.enter||F&&M===Jt.space)){b.preventDefault();const W=t.columns.findIndex($=>$.field===z.field);t.columnGroupChange&&t.columnGroupChange(W,b)}H&&M===Jt.down&&(b.preventDefault(),n(z.field),o.current=R)}},p=()=>{n(void 0),o.current&&o.current.getAttribute("tabindex")!=="-1"&&o.current.focus()},f=b=>t.sort?b>=0&&[_.createElement("span",{key:1,className:"k-sort-icon"},_.createElement(en,{name:"sort-"+t.sort[b].dir+"-small",icon:t.sort[b].dir==="asc"?vO:gO})),t.sort.length>1&&_.createElement("span",{key:2,className:"k-sort-icon"},_.createElement("span",{className:"k-sort-order"},b+1))]:null,g=b=>b.map(z=>{const M=t.columns[z],I=t.sortable&&M.sortable,F=t.sort?t.sort.findIndex(ht=>ht.field===M.field):-1,H=F>=0&&t.sort[F].dir||"none",E=M.columnMenu===null?null:M.columnMenu||t.columnMenu,R=M.menuIcon||t.columnMenuIcon,W=Me({"k-first":M.kFirst,"k-filterable":!!E,"k-table-th":!0,"k-header":!0,"k-grid-header-sticky":M.locked,"k-sorted":t.sort&&t.sort.some(ht=>ht.field===M.field)},M.headerClassName);M.locked===!1&&(M.left=0);const $=M.left!==void 0?t.isRtl?{left:M.right,right:M.left}:{left:M.left,right:M.right}:{},G=i.toLanguageString(jy,xn[jy]),Z=M.isAccessible?{ariaSort:KWt[H],role:"columnheader",ariaColumnIndex:M.ariaColumnIndex,ariaSelected:!1,ariaDescription:I?G:""}:{role:"presentation"},K=M.declarationIndex>=0?++s:--a,et=M.headerCell?M.headerCell:YWt,at=_.createElement(et,{key:1,field:M.field,onClick:I&&(ht=>l(ht,M))||void 0,selectionChange:t.selectionChange,title:M.title,selectionValue:M.headerSelectionValue,render:t.cellRender,children:f(F),columnMenuWrapperProps:{column:{field:M.field,title:M.title,locked:M.locked,filter:M.filter,id:M.id},sortable:I&&t.sortable,sort:t.sort,onSortChange:t.sortChange,filter:t.filter,filterable:t.filterable&&M.filterable,filterOperators:t.filterOperators,onFilterChange:t.filterChange,show:r===M.field?!0:void 0,onCloseMenu:p,navigatable:t.navigatable,group:t.group,groupable:t.groupable,onGroupChange:t.groupChange,columnMenu:E,columnMenuIcon:R}}),tt={...Z,key:K,colSpan:M.colSpan,rowSpan:M.rowSpan,className:W,style:$,columnId:M.id,navigatable:M.navigatable,onKeyDown:ht=>h(ht,M),role:"columnheader"},ft=[at,t.columnResize&&t.columnResize.resizable&&M.resizable&&_.createElement(jBt,{key:2,resize:(ht,lt,yt)=>t.columnResize&&t.columnResize.dragHandler(ht,M,lt,yt),autofit:ht=>t.columnResize&&t.columnResize.dblClickHandler(ht,[M.id])})],dt=cd(t.cells,M.cells);if(dt&&dt.headerCell){const ht=dt.headerCell;return _.createElement(ht,{...at.props,key:K,thProps:tt,index:z},ft)}return _.createElement(IC,{...tt,key:K},ft)});return t.columnsMap.map((b,z)=>t.pressHandler&&_.createElement(jWt,{key:z,pressHandler:t.pressHandler,dragHandler:t.dragHandler,releaseHandler:t.releaseHandler,ariaRowIndex:z+1,dragClue:t.dragClue,headerRef:t.headerRef,containerRef:t.containerRef},g(b))||_.createElement("tr",{key:z,className:"k-table-row",role:"row","aria-rowindex":z+1},g(b)))};/** + */const KWt={true:{asc:"desc",desc:"","":"asc"},false:{asc:"desc",desc:"asc","":"asc"}},qWt={none:"none",asc:"ascending",desc:"descending"},ZWt=t=>{const[r,n]=_.useState(),i=jl(),o=_.useRef(null);let a=0,s=-1;const l=(b,z)=>{if(b.preventDefault(),!t.sortChange)return;const{allowUnsort:M,mode:I}=jWt(t.sortable||!1,z.sortable||!1),F=(t.sort||[]).filter(R=>R.field===z.field)[0],H=KWt[M][F&&F.dir||""],E=I==="single"?[]:(t.sort||[]).filter(R=>R.field!==z.field);H!==""&&z.field&&E.push({field:z.field,dir:H}),t.sortChange(E,b)},h=(b,z)=>{if(b.isDefaultPrevented())return;const{keyCode:M,metaKey:I,ctrlKey:F,altKey:H}=b,E=t.sortable&&z.sortable,R=b.target;if(E&&b.keyCode===te.enter&&R.className.indexOf("k-table-th")!==-1&&l(b,z),t.navigatable){if(t.groupable&&(I&&M===te.enter||F&&M===te.space)){b.preventDefault();const W=t.columns.findIndex($=>$.field===z.field);t.columnGroupChange&&t.columnGroupChange(W,b)}H&&M===te.down&&(b.preventDefault(),n(z.field),o.current=R)}},p=()=>{n(void 0),o.current&&o.current.getAttribute("tabindex")!=="-1"&&o.current.focus()},f=b=>t.sort?b>=0&&[_.createElement("span",{key:1,className:"k-sort-icon"},_.createElement(Qi,{name:"sort-"+t.sort[b].dir+"-small",icon:t.sort[b].dir==="asc"?gO:mO})),t.sort.length>1&&_.createElement("span",{key:2,className:"k-sort-icon"},_.createElement("span",{className:"k-sort-order"},b+1))]:null,g=b=>b.map(z=>{const M=t.columns[z],I=t.sortable&&M.sortable,F=t.sort?t.sort.findIndex(ht=>ht.field===M.field):-1,H=F>=0&&t.sort[F].dir||"none",E=M.columnMenu===null?null:M.columnMenu||t.columnMenu,R=M.menuIcon||t.columnMenuIcon,W=ke({"k-first":M.kFirst,"k-filterable":!!E,"k-table-th":!0,"k-header":!0,"k-grid-header-sticky":M.locked,"k-sorted":t.sort&&t.sort.some(ht=>ht.field===M.field)},M.headerClassName);M.locked===!1&&(M.left=0);const $=M.left!==void 0?t.isRtl?{left:M.right,right:M.left}:{left:M.left,right:M.right}:{},G=i.toLanguageString(jy,mn[jy]),Z=M.isAccessible?{ariaSort:qWt[H],role:"columnheader",ariaColumnIndex:M.ariaColumnIndex,ariaSelected:!1,ariaDescription:I?G:""}:{role:"presentation"},K=M.declarationIndex>=0?++s:--a,et=M.headerCell?M.headerCell:XWt,at=_.createElement(et,{key:1,field:M.field,onClick:I&&(ht=>l(ht,M))||void 0,selectionChange:t.selectionChange,title:M.title,selectionValue:M.headerSelectionValue,render:t.cellRender,children:f(F),columnMenuWrapperProps:{column:{field:M.field,title:M.title,locked:M.locked,filter:M.filter,id:M.id},sortable:I&&t.sortable,sort:t.sort,onSortChange:t.sortChange,filter:t.filter,filterable:t.filterable&&M.filterable,filterOperators:t.filterOperators,onFilterChange:t.filterChange,show:r===M.field?!0:void 0,onCloseMenu:p,navigatable:t.navigatable,group:t.group,groupable:t.groupable,onGroupChange:t.groupChange,columnMenu:E,columnMenuIcon:R}}),tt={...Z,key:K,colSpan:M.colSpan,rowSpan:M.rowSpan,className:W,style:$,columnId:M.id,navigatable:M.navigatable,onKeyDown:ht=>h(ht,M),role:"columnheader"},ft=[at,t.columnResize&&t.columnResize.resizable&&M.resizable&&_.createElement(GBt,{key:2,resize:(ht,lt,yt)=>t.columnResize&&t.columnResize.dragHandler(ht,M,lt,yt),autofit:ht=>t.columnResize&&t.columnResize.dblClickHandler(ht,[M.id])})],dt=cd(t.cells,M.cells);if(dt&&dt.headerCell){const ht=dt.headerCell;return _.createElement(ht,{...at.props,key:K,thProps:tt,index:z},ft)}return _.createElement(HC,{...tt,key:K},ft)});return t.columnsMap.map((b,z)=>t.pressHandler&&_.createElement(GWt,{key:z,pressHandler:t.pressHandler,dragHandler:t.dragHandler,releaseHandler:t.releaseHandler,ariaRowIndex:z+1,dragClue:t.dragClue,headerRef:t.headerRef,containerRef:t.containerRef},g(b))||_.createElement("tr",{key:z,className:"k-table-row",role:"row","aria-rowindex":z+1},g(b)))};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const XE={text:[{text:"grid.filterContainsOperator",operator:"contains"},{text:"grid.filterNotContainsOperator",operator:"doesnotcontain"},{text:"grid.filterEqOperator",operator:"eq"},{text:"grid.filterNotEqOperator",operator:"neq"},{text:"grid.filterStartsWithOperator",operator:"startswith"},{text:"grid.filterEndsWithOperator",operator:"endswith"},{text:"grid.filterIsNullOperator",operator:"isnull"},{text:"grid.filterIsNotNullOperator",operator:"isnotnull"},{text:"grid.filterIsEmptyOperator",operator:"isempty"},{text:"grid.filterIsNotEmptyOperator",operator:"isnotempty"}],numeric:[{text:"grid.filterEqOperator",operator:"eq"},{text:"grid.filterNotEqOperator",operator:"neq"},{text:"grid.filterGteOperator",operator:"gte"},{text:"grid.filterGtOperator",operator:"gt"},{text:"grid.filterLteOperator",operator:"lte"},{text:"grid.filterLtOperator",operator:"lt"},{text:"grid.filterIsNullOperator",operator:"isnull"},{text:"grid.filterIsNotNullOperator",operator:"isnotnull"}],date:[{text:"grid.filterEqOperator",operator:"eq"},{text:"grid.filterNotEqOperator",operator:"neq"},{text:"grid.filterAfterOrEqualOperator",operator:"gte"},{text:"grid.filterAfterOperator",operator:"gt"},{text:"grid.filterBeforeOperator",operator:"lt"},{text:"grid.filterBeforeOrEqualOperator",operator:"lte"},{text:"grid.filterIsNullOperator",operator:"isnull"},{text:"grid.filterIsNotNullOperator",operator:"isnotnull"}],boolean:[{text:"grid.filterEqOperator",operator:"eq"}]},Rc=t=>t==="isnull"||t==="isnotnull"||t==="isempty"||t==="isnotempty",KE=(t,r)=>t.map(n=>({text:r.toLanguageString(n.text,xn[n.text]),operator:n.operator})),ZWt="eq",JWt=[{text:"grid.filterBooleanAll",operator:""},{text:"grid.filterIsTrue",operator:!0},{text:"grid.filterIsFalse",operator:!1}],QWt=(t,r,n)=>{const i=tjt(n.operators);let o=n.operator;switch(n.filterType){case"numeric":(!o||Rc(o))&&(o=i),t===null&&o===i&&(o="");break;case"date":(!o||Rc(o))&&(o=i),t===null&&o===i&&(o="");break;case"text":(!o||Rc(o))&&(o=i),!t&&o===i&&(o="");break;default:return}n.onChange({value:t,operator:o,syntheticEvent:r})},tjt=(t,r)=>r?t[r][0].operator:t[0].operator,ejt=t=>t||"text",rjt=(t,r)=>{const n=t.target.value;r({value:n.operator,operator:n.operator===""?"":ZWt,syntheticEvent:t.syntheticEvent})},ijt=(t,r,n)=>{let i=r;const o=t.target.value;t.target.state.opened&&(Rc(o.operator)&&(i=null),r===null&&!Rc(o.operator)&&(i=void 0),n({value:i,operator:o.operator,syntheticEvent:t.syntheticEvent}))};/** + */const KE={text:[{text:"grid.filterContainsOperator",operator:"contains"},{text:"grid.filterNotContainsOperator",operator:"doesnotcontain"},{text:"grid.filterEqOperator",operator:"eq"},{text:"grid.filterNotEqOperator",operator:"neq"},{text:"grid.filterStartsWithOperator",operator:"startswith"},{text:"grid.filterEndsWithOperator",operator:"endswith"},{text:"grid.filterIsNullOperator",operator:"isnull"},{text:"grid.filterIsNotNullOperator",operator:"isnotnull"},{text:"grid.filterIsEmptyOperator",operator:"isempty"},{text:"grid.filterIsNotEmptyOperator",operator:"isnotempty"}],numeric:[{text:"grid.filterEqOperator",operator:"eq"},{text:"grid.filterNotEqOperator",operator:"neq"},{text:"grid.filterGteOperator",operator:"gte"},{text:"grid.filterGtOperator",operator:"gt"},{text:"grid.filterLteOperator",operator:"lte"},{text:"grid.filterLtOperator",operator:"lt"},{text:"grid.filterIsNullOperator",operator:"isnull"},{text:"grid.filterIsNotNullOperator",operator:"isnotnull"}],date:[{text:"grid.filterEqOperator",operator:"eq"},{text:"grid.filterNotEqOperator",operator:"neq"},{text:"grid.filterAfterOrEqualOperator",operator:"gte"},{text:"grid.filterAfterOperator",operator:"gt"},{text:"grid.filterBeforeOperator",operator:"lt"},{text:"grid.filterBeforeOrEqualOperator",operator:"lte"},{text:"grid.filterIsNullOperator",operator:"isnull"},{text:"grid.filterIsNotNullOperator",operator:"isnotnull"}],boolean:[{text:"grid.filterEqOperator",operator:"eq"}]},Rc=t=>t==="isnull"||t==="isnotnull"||t==="isempty"||t==="isnotempty",qE=(t,r)=>t.map(n=>({text:r.toLanguageString(n.text,mn[n.text]),operator:n.operator})),JWt="eq",QWt=[{text:"grid.filterBooleanAll",operator:""},{text:"grid.filterIsTrue",operator:!0},{text:"grid.filterIsFalse",operator:!1}],tjt=(t,r,n)=>{const i=ejt(n.operators);let o=n.operator;switch(n.filterType){case"numeric":(!o||Rc(o))&&(o=i),t===null&&o===i&&(o="");break;case"date":(!o||Rc(o))&&(o=i),t===null&&o===i&&(o="");break;case"text":(!o||Rc(o))&&(o=i),!t&&o===i&&(o="");break;default:return}n.onChange({value:t,operator:o,syntheticEvent:r})},ejt=(t,r)=>r?t[r][0].operator:t[0].operator,rjt=t=>t||"text",ijt=(t,r)=>{const n=t.target.value;r({value:n.operator,operator:n.operator===""?"":JWt,syntheticEvent:t.syntheticEvent})},njt=(t,r,n)=>{let i=r;const o=t.target.value;t.target.state.opened&&(Rc(o.operator)&&(i=null),r===null&&!Rc(o.operator)&&(i=void 0),n({value:i,operator:o.operator,syntheticEvent:t.syntheticEvent}))};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */class QB extends _.Component{constructor(r){super(r),this._inputRef=_.createRef(),this.renderOperatorEditor=n=>{if(this.props.filterType==="boolean")return;const i=this.props.operators.find(o=>o.operator===this.props.operator)||null;return _.createElement(C9,{size:this.props.size,value:i,onChange:this.operatorChange,className:"k-dropdown-operator",iconClassName:"k-i-filter k-icon",svgIcon:zVt,data:this.props.operators,textField:"text",title:n.toLanguageString(Wy,xn[Wy]),popupSettings:{width:""}})},this.inputChange=this.inputChange.bind(this),this.clear=this.clear.bind(this),this.operatorChange=this.operatorChange.bind(this),this.boolDropdownChange=this.boolDropdownChange.bind(this)}render(){const r=si(this),n=_.createElement("div",{className:"k-filtercell"},_.createElement("div",{className:"k-filtercell-wrapper"},this.filterComponent(this.props.filterType,this.props.value,this.props.booleanValues),_.createElement("div",{className:"k-filtercell-operator"},this.renderOperatorEditor(r)," ",_.createElement(ei,{size:this.props.size,icon:"filter-clear",svgIcon:MVt,className:Me({"k-clear-button-visible":!!(!(this.props.value===null||this.props.value==="")||this.props.operator)}),title:r.toLanguageString($y,xn[$y]),type:"button",onClick:this.clear,disabled:!(!(this.props.value===null||this.props.value==="")||this.props.operator)}))));return this.props.render?this.props.render.call(void 0,n,this.props):n}inputChange(r,n){QWt(r,n,this.props)}operatorChange(r){ijt(r,this.props.value,this.props.onChange)}boolDropdownChange(r){rjt(r,this.props.onChange)}clear(r){r.preventDefault(),this.props.onChange({value:"",operator:"",syntheticEvent:r}),this._inputRef.current&&(this._inputRef.current.element.value="",setTimeout(()=>{this._inputRef.current.element.focus()},0))}filterComponent(r,n,i){switch(r){case"numeric":return _.createElement(g5,{ref:this._inputRef,size:this.props.size,value:n,onChange:o=>{this.inputChange(o.value,o.syntheticEvent)},title:this.props.title,ariaLabel:this.props.ariaLabel});case"date":return _.createElement(EC,{ref:this._inputRef,size:this.props.size,value:n,onChange:o=>{this.inputChange(o.value,o.syntheticEvent)},title:this.props.title,ariaLabel:this.props.ariaLabel});case"boolean":{const o=a=>a==null;return _.createElement(C9,{ref:this._inputRef,size:this.props.size,onChange:this.boolDropdownChange,value:i.find(a=>a.operator===(o(n)?"":n)),data:i,textField:"text",title:this.props.title,ariaLabel:this.props.ariaLabel})}default:return _.createElement(nd,{ref:this._inputRef,size:this.props.size,value:n||"",onChange:o=>{this.inputChange(o.target.value,o.syntheticEvent)},title:this.props.title,"aria-label":this.props.ariaLabel})}}}Ri(QB);/** + */class tN extends _.Component{constructor(r){super(r),this._inputRef=_.createRef(),this.renderOperatorEditor=n=>{if(this.props.filterType==="boolean")return;const i=this.props.operators.find(o=>o.operator===this.props.operator)||null;return _.createElement(C9,{size:this.props.size,value:i,onChange:this.operatorChange,className:"k-dropdown-operator",iconClassName:"k-i-filter k-icon",svgIcon:MVt,data:this.props.operators,textField:"text",title:n.toLanguageString(Wy,mn[Wy]),popupSettings:{width:""}})},this.inputChange=this.inputChange.bind(this),this.clear=this.clear.bind(this),this.operatorChange=this.operatorChange.bind(this),this.boolDropdownChange=this.boolDropdownChange.bind(this)}render(){const r=ai(this),n=_.createElement("div",{className:"k-filtercell"},_.createElement("div",{className:"k-filtercell-wrapper"},this.filterComponent(this.props.filterType,this.props.value,this.props.booleanValues),_.createElement("div",{className:"k-filtercell-operator"},this.renderOperatorEditor(r)," ",_.createElement(Jr,{size:this.props.size,icon:"filter-clear",svgIcon:kVt,className:ke({"k-clear-button-visible":!!(!(this.props.value===null||this.props.value==="")||this.props.operator)}),title:r.toLanguageString($y,mn[$y]),type:"button",onClick:this.clear,disabled:!(!(this.props.value===null||this.props.value==="")||this.props.operator)}))));return this.props.render?this.props.render.call(void 0,n,this.props):n}inputChange(r,n){tjt(r,n,this.props)}operatorChange(r){njt(r,this.props.value,this.props.onChange)}boolDropdownChange(r){ijt(r,this.props.onChange)}clear(r){r.preventDefault(),this.props.onChange({value:"",operator:"",syntheticEvent:r}),this._inputRef.current&&(this._inputRef.current.element.value="",setTimeout(()=>{this._inputRef.current.element.focus()},0))}filterComponent(r,n,i){switch(r){case"numeric":return _.createElement(g5,{ref:this._inputRef,size:this.props.size,value:n,onChange:o=>{this.inputChange(o.value,o.syntheticEvent)},title:this.props.title,ariaLabel:this.props.ariaLabel});case"date":return _.createElement(IC,{ref:this._inputRef,size:this.props.size,value:n,onChange:o=>{this.inputChange(o.value,o.syntheticEvent)},title:this.props.title,ariaLabel:this.props.ariaLabel});case"boolean":{const o=a=>a==null;return _.createElement(C9,{ref:this._inputRef,size:this.props.size,onChange:this.boolDropdownChange,value:i.find(a=>a.operator===(o(n)?"":n)),data:i,textField:"text",title:this.props.title,ariaLabel:this.props.ariaLabel})}default:return _.createElement(nd,{ref:this._inputRef,size:this.props.size,value:n||"",onChange:o=>{this.inputChange(o.target.value,o.syntheticEvent)},title:this.props.title,"aria-label":this.props.ariaLabel})}}}Vi(tN);/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const njt="k-table-row k-filter-row";let tN=class extends _.Component{headerCellClassName(r,n){let i=`${n?"k-grid-header-sticky":""}`;return this.props.sort&&this.props.sort.filter(o=>o.field===r).length>0&&(i+=" k-sorted"),i}setFilter(r,n,i,o){if(!this.props.filterChange)return;const a=[];(r!==""&&r!==null||n!=="")&&a.push({field:i,operator:n,value:r}),this.props.filter&&this.props.filter.filters&&(this.props.filter.filters||[]).forEach(l=>{const h=l;h&&h.field!==i&&a.push(h)});const s=this.props.filter&&this.props.filter.logic?this.props.filter.logic:"and";this.props.filterChange(a.length>0?{logic:s,filters:a}:null,o)}render(){const r=si(this),n=this.props.filter&&this.props.filter.filters||[],i=l=>{if(l===void 0)return;const h=n.filter(p=>p.field===l);return h.length?h[0]:void 0};let o=0,a=-1;const s=this.props.columns.filter(l=>l.children.length===0).map(l=>{const h=ejt(l.filter),p=i(l.field),f=l.filterable?r.toLanguageString(Gy,xn[Gy]):void 0;let g=p&&p.value;g===void 0&&(g=h==="text"?"":null);const b=l.filterable&&{render:this.props.cellRender,field:l.field,title:l.filterTitle,value:g,operator:p&&p.operator,operators:KE(this.props.filterOperators[h]||[],r),booleanValues:KE(JWt,r),filterType:h,ariaLabel:f,onChange:R=>{this.setFilter(R.value,R.operator,l.field,R.syntheticEvent)}},z=l.declarationIndex>=0?++a:--o,M={ariaLabel:f,ariaColumnIndex:l.ariaColumnIndex},I=l.left!==void 0?this.props.isRtl?{left:l.right,right:l.left}:{left:l.left,right:l.right}:{},F={columnId:Je.getFilterColumnId(l.id),navigatable:l.navigatable||this.props.navigatable,style:I,className:Me("k-table-th",this.headerCellClassName(l.field,l.locked)||void 0),role:"columnheader",...M},H=b&&(l.filterCell?_.createElement(l.filterCell,{...b}):_.createElement(QB,{size:this.props.size,...b})),E=cd(this.props.cells,l.cells);if(E&&E.filterCell){const R=E.filterCell;return _.createElement(R,{key:z,...b,thProps:F,index:a},H)}return _.createElement(IC,{key:z,...F},H)});return _.createElement("tr",{className:njt,"aria-rowindex":this.props.ariaRowIndex,role:"row"},s)}};Ri(tN);/** + */const ojt="k-table-row k-filter-row";let eN=class extends _.Component{headerCellClassName(r,n){let i=`${n?"k-grid-header-sticky":""}`;return this.props.sort&&this.props.sort.filter(o=>o.field===r).length>0&&(i+=" k-sorted"),i}setFilter(r,n,i,o){if(!this.props.filterChange)return;const a=[];(r!==""&&r!==null||n!=="")&&a.push({field:i,operator:n,value:r}),this.props.filter&&this.props.filter.filters&&(this.props.filter.filters||[]).forEach(l=>{const h=l;h&&h.field!==i&&a.push(h)});const s=this.props.filter&&this.props.filter.logic?this.props.filter.logic:"and";this.props.filterChange(a.length>0?{logic:s,filters:a}:null,o)}render(){const r=ai(this),n=this.props.filter&&this.props.filter.filters||[],i=l=>{if(l===void 0)return;const h=n.filter(p=>p.field===l);return h.length?h[0]:void 0};let o=0,a=-1;const s=this.props.columns.filter(l=>l.children.length===0).map(l=>{const h=rjt(l.filter),p=i(l.field),f=l.filterable?r.toLanguageString(Gy,mn[Gy]):void 0;let g=p&&p.value;g===void 0&&(g=h==="text"?"":null);const b=l.filterable&&{render:this.props.cellRender,field:l.field,title:l.filterTitle,value:g,operator:p&&p.operator,operators:qE(this.props.filterOperators[h]||[],r),booleanValues:qE(QWt,r),filterType:h,ariaLabel:f,onChange:R=>{this.setFilter(R.value,R.operator,l.field,R.syntheticEvent)}},z=l.declarationIndex>=0?++a:--o,M={ariaLabel:f,ariaColumnIndex:l.ariaColumnIndex},I=l.left!==void 0?this.props.isRtl?{left:l.right,right:l.left}:{left:l.left,right:l.right}:{},F={columnId:Je.getFilterColumnId(l.id),navigatable:l.navigatable||this.props.navigatable,style:I,className:ke("k-table-th",this.headerCellClassName(l.field,l.locked)||void 0),role:"columnheader",...M},H=b&&(l.filterCell?_.createElement(l.filterCell,{...b}):_.createElement(tN,{size:this.props.size,...b})),E=cd(this.props.cells,l.cells);if(E&&E.filterCell){const R=E.filterCell;return _.createElement(R,{key:z,...b,thProps:F,index:a},H)}return _.createElement(HC,{key:z,...F},H)});return _.createElement("tr",{className:ojt,"aria-rowindex":this.props.ariaRowIndex,role:"row"},s)}};Vi(eN);/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */class eN extends _.Component{constructor(){super(...arguments),this.draggable=null,this.onPress=r=>{const n=this.draggable&&this.draggable.element;n&&this.props.onPress&&this.props.onPress(r.event,n)},this.onDrag=r=>{const n=this.draggable&&this.draggable.element;n&&this.props.onDrag&&this.props.onDrag(r.event,n)},this.onRelease=r=>{this.draggable&&this.draggable.element&&this.props.onRelease&&this.props.onRelease(r.event)},this.sortChange=r=>{if(r.preventDefault(),this.props.onSortChange){const n=this.props.dir==="asc"?"desc":"asc";this.props.onSortChange(r,n)}},this.handleKeyDown=r=>{(r.keyCode===Jt.delete||r.keyCode===Jt.backspace)&&(r.preventDefault(),r.stopPropagation(),this.props.onRemove&&this.props.onRemove(r))},this.groupRemove=r=>{r.preventDefault(),r.stopPropagation(),this.props.onRemove&&this.props.onRemove(r)},this.onContextMenu=r=>{const n={title:this.props.title,dir:this.props.dir,index:this.props.index};this.props.onContextMenu&&this.props.onContextMenu.call(void 0,r,{dataItem:{...n}})}}render(){const{dir:r}=this.props;return _.createElement(O8,{onPress:this.onPress,onDrag:this.onDrag,onRelease:this.onRelease,ref:n=>{this.draggable=n}},_.createElement("div",{className:"k-chip k-chip-md k-chip-solid k-chip-solid-base k-rounded-md",onClick:this.sortChange,onContextMenu:this.onContextMenu,onKeyDown:this.handleKeyDown,tabIndex:0,role:"button",style:{touchAction:"none"}},_.createElement("span",null,_.createElement(en,{name:"sort-"+r+"-small",icon:r==="asc"?vO:gO,size:"small"})),_.createElement("span",{className:"k-chip-content"},this.props.title),_.createElement("span",{className:"k-chip-actions"},_.createElement("span",{className:"k-chip-action k-chip-remove-action",onClick:this.groupRemove},_.createElement(en,{name:"x-circle",icon:CVt,size:"small"})))))}}Ri(eN);/** + */class rN extends _.Component{constructor(){super(...arguments),this.draggable=null,this.onPress=r=>{const n=this.draggable&&this.draggable.element;n&&this.props.onPress&&this.props.onPress(r.event,n)},this.onDrag=r=>{const n=this.draggable&&this.draggable.element;n&&this.props.onDrag&&this.props.onDrag(r.event,n)},this.onRelease=r=>{this.draggable&&this.draggable.element&&this.props.onRelease&&this.props.onRelease(r.event)},this.sortChange=r=>{if(r.preventDefault(),this.props.onSortChange){const n=this.props.dir==="asc"?"desc":"asc";this.props.onSortChange(r,n)}},this.handleKeyDown=r=>{(r.keyCode===te.delete||r.keyCode===te.backspace)&&(r.preventDefault(),r.stopPropagation(),this.props.onRemove&&this.props.onRemove(r))},this.groupRemove=r=>{r.preventDefault(),r.stopPropagation(),this.props.onRemove&&this.props.onRemove(r)},this.onContextMenu=r=>{const n={title:this.props.title,dir:this.props.dir,index:this.props.index};this.props.onContextMenu&&this.props.onContextMenu.call(void 0,r,{dataItem:{...n}})}}render(){const{dir:r}=this.props;return _.createElement(O8,{onPress:this.onPress,onDrag:this.onDrag,onRelease:this.onRelease,ref:n=>{this.draggable=n}},_.createElement("div",{className:"k-chip k-chip-md k-chip-solid k-chip-solid-base k-rounded-md",onClick:this.sortChange,onContextMenu:this.onContextMenu,onKeyDown:this.handleKeyDown,tabIndex:0,role:"button",style:{touchAction:"none"}},_.createElement("span",null,_.createElement(Qi,{name:"sort-"+r+"-small",icon:r==="asc"?gO:mO,size:"small"})),_.createElement("span",{className:"k-chip-content"},this.props.title),_.createElement("span",{className:"k-chip-actions"},_.createElement("span",{className:"k-chip-action k-chip-remove-action",onClick:this.groupRemove},_.createElement(Qi,{name:"x-circle",icon:SVt,size:"small"})))))}}Vi(rN);/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */class rN extends _.Component{constructor(){super(...arguments),this.onGroupRemove=(r,n)=>{const i=this.props.group.slice();i.splice(n,1),this.props.groupChange(i,r)},this.onGroupSortChange=(r,n,i,o)=>{const a=Object.assign({},i,{dir:o}),s=this.props.group.slice();s.splice(n,1,a),this.props.groupChange(s,r)}}render(){const r=(this.props.group||[]).map((n,i)=>_.createElement(eN,{key:i,index:i,dir:n.dir||"asc",title:this.props.resolveTitle(n.field),onRemove:o=>{this.onGroupRemove(o,i)},onSortChange:(o,a)=>{this.onGroupSortChange(o,i,n,a)},onPress:this.props.pressHandler,onDrag:this.props.dragHandler,onRelease:this.props.releaseHandler,onContextMenu:this.props.onContextMenu}));return _.createElement("div",{ref:this.props.refCallback,className:"k-grouping-header",role:"toolbar","aria-label":si(this).toLanguageString(Uy,xn[Uy]),"aria-controls":this.props.ariaControls||""},_.createElement("div",{className:"k-chip-list k-chip-list-md",role:"none"},r),_.createElement("div",{className:"k-grouping-drop-container"},!r.length&&si(this).toLanguageString(By,xn[By])," "))}}Ri(rN);/** + */class iN extends _.Component{constructor(){super(...arguments),this.onGroupRemove=(r,n)=>{const i=this.props.group.slice();i.splice(n,1),this.props.groupChange(i,r)},this.onGroupSortChange=(r,n,i,o)=>{const a=Object.assign({},i,{dir:o}),s=this.props.group.slice();s.splice(n,1,a),this.props.groupChange(s,r)}}render(){const r=(this.props.group||[]).map((n,i)=>_.createElement(rN,{key:i,index:i,dir:n.dir||"asc",title:this.props.resolveTitle(n.field),onRemove:o=>{this.onGroupRemove(o,i)},onSortChange:(o,a)=>{this.onGroupSortChange(o,i,n,a)},onPress:this.props.pressHandler,onDrag:this.props.dragHandler,onRelease:this.props.releaseHandler,onContextMenu:this.props.onContextMenu}));return _.createElement("div",{ref:this.props.refCallback,className:"k-grouping-header",role:"toolbar","aria-label":ai(this).toLanguageString(Uy,mn[Uy]),"aria-controls":this.props.ariaControls||""},_.createElement("div",{className:"k-chip-list k-chip-list-md",role:"none"},r),_.createElement("div",{className:"k-grouping-drop-container"},!r.length&&ai(this).toLanguageString(By,mn[By])," "))}}Vi(iN);/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let ojt=class extends _.Component{constructor(){super(...arguments),this.footerWrap=null,this.table=null}componentDidMount(){this.setState({})}setScrollLeft(r){this.footerWrap&&(this.footerWrap.scrollLeft=r)}setWidth(r){this.table&&(this.table.style.width=r+"px")}render(){return this.props.staticHeaders?_.createElement("div",{className:"k-grid-footer",role:"presentation"},_.createElement("div",{ref:r=>{this.footerWrap=r},className:"k-grid-footer-wrap",style:this.props.hasScrollbarWidth?{}:{borderWidth:0},role:"presentation"},_.createElement("table",{ref:r=>{this.table=r},className:Me("k-table k-grid-footer-table",{"k-table-md":!this.props.size,[`k-table-${Gr.sizeMap[this.props.size]||this.props.size}`]:this.props.size},this.props.className),role:"presentation"},_.createElement("colgroup",{ref:r=>{this.props.columnResize.colGroupFooter=r},role:"presentation"},this.props.cols),_.createElement("tfoot",{className:"k-table-tfoot",role:"presentation"},this.props.row)))):_.createElement("tfoot",{className:"k-table-tfoot"},this.props.row)}};/** + */let ajt=class extends _.Component{constructor(){super(...arguments),this.footerWrap=null,this.table=null}componentDidMount(){this.setState({})}setScrollLeft(r){this.footerWrap&&(this.footerWrap.scrollLeft=r)}setWidth(r){this.table&&(this.table.style.width=r+"px")}render(){return this.props.staticHeaders?_.createElement("div",{className:"k-grid-footer",role:"presentation"},_.createElement("div",{ref:r=>{this.footerWrap=r},className:"k-grid-footer-wrap",style:this.props.hasScrollbarWidth?{}:{borderWidth:0},role:"presentation"},_.createElement("table",{ref:r=>{this.table=r},className:ke("k-table k-grid-footer-table",{"k-table-md":!this.props.size,[`k-table-${Wr.sizeMap[this.props.size]||this.props.size}`]:this.props.size},this.props.className),role:"presentation"},_.createElement("colgroup",{ref:r=>{this.props.columnResize.colGroupFooter=r},role:"presentation"},this.props.cols),_.createElement("tfoot",{className:"k-table-tfoot",role:"presentation"},this.props.row)))):_.createElement("tfoot",{className:"k-table-tfoot"},this.props.row)}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */let ajt=class{constructor(r){this.table=null,this.containerHeight=0,this.topCacheCount=0,this.attendedSkip=0,this.propsSkip=0,this.total=0,this.scrollableVirtual=!1,this.realSkip=0,this.pageSize=0,this.PageChange=null,this.tableBodyRef=_.createRef(),this.fixedScroll=!1,this.askedSkip=void 0,this.containerRef=_.createRef(),this.tableTransform="",this.prevScrollPos=0,this.tableTranslate=0,this.scrollSyncing=!1,this.reactVersion=Number.parseFloat(_.version),this.topItems=(n,i)=>{if(!this.container||i)return{topItemsCount:0,topItemsHeight:0};const o=this.container.clientHeight,a=Math.ceil(o/n[0].line),s=Math.ceil((n.length-a)/2);let l=0;for(let h=0;hthis.container?this.container.offsetHeight-this.container.clientHeight:0,r&&(this.topCacheCount=4,this.attendedSkip=-this.topCacheCount),this.scrollHandler=this.scrollHandler.bind(this)}get container(){return this.containerRef.current}get rowHeights(){const r=[],n=this.tableBodyRef.current&&this.tableBodyRef.current.children||[];let i=0;for(let o=0;o-1){i+=n[o].scrollHeight;continue}n[o].className.indexOf("k-detail-row")>-1?r[r.length-1].line+=n[o].scrollHeight:(r.push({line:n[o].scrollHeight,acc:i}),i=0)}return r}changePage(r,n){this.attendedSkip=r-this.topCacheCount,this.PageChange&&this.PageChange({skip:Math.max(0,r-this.topCacheCount),take:this.pageSize},n)}translate(r,n){this.tableTranslate=r,this.scrollableVirtual&&this.table&&(this.reactVersion<=17||n?this.table.style.transform="translateY("+r+"px)":this.tableTransform="translateY("+r+"px)")}reset(){this.scrollSyncing=!0,!this.fixedScroll&&(this.container&&(this.container.scrollTop=0),this.translate(0,!0))}localScrollUp(r){if(!this.container)return;const n=this.rowHeights,i=this.container.scrollTop;let o=this.tableTranslate,a=0;const{topItemsCount:s,topItemsHeight:l,itemsNeededOnScreen:h}=this.topItems(n,!!this.topCacheCount),p=i-o;if(!(p>l||n.length<=h)){for(;a0&&!(o+(n[n.length-1-a].line+n[n.length-1-a].acc)+p<=i);)o-=n[n.length-1-a].line+n[n.length-1-a].acc,a++;if(a===0&&this.topCacheCount===0&&this.attendedSkip>0&&(o=Math.max(o-n[0].line,0),a=1),this.propsSkip-a<=0&&o>i){this.translate(0),this.changePage(0,r),this.container.scrollTop=0;return}if(o>i&&(o=i),o!==this.tableTranslate){this.translate(Math.max(0,o-l));const f=Math.max(0,this.propsSkip-a-s);this.changePage(f,r)}}}localScrollDown(r){if(!this.container)return;const n=this.rowHeights,i=this.container.scrollTop;let o=this.tableTranslate,a=0;const{topItemsCount:s,topItemsHeight:l,itemsNeededOnScreen:h}=this.topItems(n,!!this.topCacheCount);for(;ai);)o+=n[a].line+n[a].acc,a++;s>this.propsSkip+a||n.length<=h||(a>=n.length-this.topCacheCount&&this.propsSkip+a>=this.total?(this.translate(o-l),this.changePage(this.total-1-s,r)):o!==this.tableTranslate&&this.propsSkip+a-s!==this.propsSkip&&(this.translate(o-l),this.changePage(this.propsSkip+a-s,r)))}scrollNonStrict(r){const n=this.total*this.prevScrollPos/this.containerHeight;let i=Math.floor(n);i>=this.total&&(i=this.total-1);const o=Math.min(n-i,1);let a=0;const s=i-this.propsSkip,l=this.rowHeights;s>=0&&s<=1?a=-((l[0].line+l[0].acc)*o):s===-1&&(a=-((l[l.length-1].line+l[l.length-1].acc)*o));const{topItemsCount:h,topItemsHeight:p}=this.topItems(l,!!this.topCacheCount);this.translate(Math.max(0,a-p-this.horizontalScrollbarHeight()+this.containerHeight*n/this.total)),this.changePage(i-h,r)}scrollHandler(r){if(!this.scrollableVirtual)return;if(this.scrollSyncing||!this.container||!this.table){this.scrollSyncing=!1;return}const n=this.container.scrollTop,i=this.prevScrollPos;if(this.prevScrollPos=n,this.askedSkip!==void 0){this.translate(this.containerHeight*this.askedSkip/this.total),this.changePage(this.askedSkip,r),this.prevScrollPos=n,this.askedSkip=void 0;return}n-i<0&&n>this.tableTranslate-this.table.scrollHeight/10?this.localScrollUp(r):n-i>0&&n{if(!this.container||i)return{topItemsCount:0,topItemsHeight:0};const o=this.container.clientHeight,a=Math.ceil(o/n[0].line),s=Math.ceil((n.length-a)/2);let l=0;for(let h=0;hthis.container?this.container.offsetHeight-this.container.clientHeight:0,r&&(this.topCacheCount=4,this.attendedSkip=-this.topCacheCount),this.scrollHandler=this.scrollHandler.bind(this)}get container(){return this.containerRef.current}get rowHeights(){const r=[],n=this.tableBodyRef.current&&this.tableBodyRef.current.children||[];let i=0;for(let o=0;o-1){i+=n[o].scrollHeight;continue}n[o].className.indexOf("k-detail-row")>-1?r[r.length-1].line+=n[o].scrollHeight:(r.push({line:n[o].scrollHeight,acc:i}),i=0)}return r}changePage(r,n){this.attendedSkip=r-this.topCacheCount,this.PageChange&&this.PageChange({skip:Math.max(0,r-this.topCacheCount),take:this.pageSize},n)}translate(r,n){this.tableTranslate=r,this.scrollableVirtual&&this.table&&(this.reactVersion<=17||n?this.table.style.transform="translateY("+r+"px)":this.tableTransform="translateY("+r+"px)")}reset(){this.scrollSyncing=!0,!this.fixedScroll&&(this.container&&(this.container.scrollTop=0),this.translate(0,!0))}localScrollUp(r){if(!this.container)return;const n=this.rowHeights,i=this.container.scrollTop;let o=this.tableTranslate,a=0;const{topItemsCount:s,topItemsHeight:l,itemsNeededOnScreen:h}=this.topItems(n,!!this.topCacheCount),p=i-o;if(!(p>l||n.length<=h)){for(;a0&&!(o+(n[n.length-1-a].line+n[n.length-1-a].acc)+p<=i);)o-=n[n.length-1-a].line+n[n.length-1-a].acc,a++;if(a===0&&this.topCacheCount===0&&this.attendedSkip>0&&(o=Math.max(o-n[0].line,0),a=1),this.propsSkip-a<=0&&o>i){this.translate(0),this.changePage(0,r),this.container.scrollTop=0;return}if(o>i&&(o=i),o!==this.tableTranslate){this.translate(Math.max(0,o-l));const f=Math.max(0,this.propsSkip-a-s);this.changePage(f,r)}}}localScrollDown(r){if(!this.container)return;const n=this.rowHeights,i=this.container.scrollTop;let o=this.tableTranslate,a=0;const{topItemsCount:s,topItemsHeight:l,itemsNeededOnScreen:h}=this.topItems(n,!!this.topCacheCount);for(;ai);)o+=n[a].line+n[a].acc,a++;s>this.propsSkip+a||n.length<=h||(a>=n.length-this.topCacheCount&&this.propsSkip+a>=this.total?(this.translate(o-l),this.changePage(this.total-1-s,r)):o!==this.tableTranslate&&this.propsSkip+a-s!==this.propsSkip&&(this.translate(o-l),this.changePage(this.propsSkip+a-s,r)))}scrollNonStrict(r){const n=this.total*this.prevScrollPos/this.containerHeight;let i=Math.floor(n);i>=this.total&&(i=this.total-1);const o=Math.min(n-i,1);let a=0;const s=i-this.propsSkip,l=this.rowHeights;s>=0&&s<=1?a=-((l[0].line+l[0].acc)*o):s===-1&&(a=-((l[l.length-1].line+l[l.length-1].acc)*o));const{topItemsCount:h,topItemsHeight:p}=this.topItems(l,!!this.topCacheCount);this.translate(Math.max(0,a-p-this.horizontalScrollbarHeight()+this.containerHeight*n/this.total)),this.changePage(i-h,r)}scrollHandler(r){if(!this.scrollableVirtual)return;if(this.scrollSyncing||!this.container||!this.table){this.scrollSyncing=!1;return}const n=this.container.scrollTop,i=this.prevScrollPos;if(this.prevScrollPos=n,this.askedSkip!==void 0){this.translate(this.containerHeight*this.askedSkip/this.total),this.changePage(this.askedSkip,r),this.prevScrollPos=n,this.askedSkip=void 0;return}n-i<0&&n>this.tableTranslate-this.table.scrollHeight/10?this.localScrollUp(r):n-i>0&&n=n,o=!i;this.lastScrollTop=n;let a=this.rowHeightService.index(n),s=this.rowHeightService.offset(a);const{offsetHeight:l}=this.containerRef.current,h=this.rowHeightService.index(n+l);if(o&&h>=this.lastLoaded&&this.lastLoaded0&&(a=a-p,s=this.rowHeightService.offset(a)),this.firstLoaded=a,this.translate(s);const f=this.firstLoaded+this.pageSize;this.lastLoaded=Math.min(f,this.total),this.changePage(this.firstLoaded,r)}else if(i&&a=n,o=!i;this.lastScrollTop=n;let a=this.rowHeightService.index(n),s=this.rowHeightService.offset(a);const{offsetHeight:l}=this.containerRef.current,h=this.rowHeightService.index(n+l);if(o&&h>=this.lastLoaded&&this.lastLoaded0&&(a=a-p,s=this.rowHeightService.offset(a)),this.firstLoaded=a,this.translate(s);const f=this.firstLoaded+this.pageSize;this.lastLoaded=Math.min(f,this.total),this.changePage(this.firstLoaded,r)}else if(i&&a{this.isRtl=n},this.dragHandler=(n,i,o,a)=>{const s=n.originalEvent;a||(s.preventDefault(),s.stopPropagation(),s.stopImmediatePropagation());const l=o.closest("th");if(!l||!l)return;const h=l.clientWidth;let p=h;if(this.isRtl?p+=o.getBoundingClientRect().right-o.offsetWidth/2-n.clientX:p+=n.clientX-o.getBoundingClientRect().left-o.offsetWidth/2,!a&&Math.abs(p-h)<1)return;this.fixateInitialWidths(l.parentElement.clientWidth),this.setWidths(i,Math.floor(p)/h);const f=this.columns.filter(g=>!g.children.length).findIndex(g=>g.id===i.id);this.onResize(f,h,p,s,a,i.id)},this.dblClickHandler=(n,i)=>{const o=this.columns.filter(b=>i.indexOf(b.id)>-1);if(!this.colGroupMain||!o.length)return;const a={},s=o;for(;s.length>0;){const b=s.pop();if(!b)break;b.children.length?s.push(...b.children):a[b.id]=b}const l=this.columns.filter(b=>!b.children.length),h=[];l.forEach((b,z)=>{a[b.id]&&h.push(z)});const p=[this.colGroupMain.parentElement],f=[this.colGroupMain];this.colGroupHeader&&(p.push(this.colGroupHeader.parentElement),f.push(this.colGroupHeader)),this.colGroupFooter&&(p.push(this.colGroupFooter.parentElement),f.push(this.colGroupFooter)),p.forEach(b=>b.classList.add("k-autofitting"));let g=[];f.forEach(b=>{h.forEach(z=>{b.children[z]&&(b.children[z].width="",g[z]=Math.max(g[z]||0,b.children[z].offsetWidth+1))})}),f.forEach(b=>{h.forEach(z=>{b.children[z]&&(b.children[z].width=g[z]+"px",l[z].width=g[z])})}),p.forEach(b=>b.classList.remove("k-autofitting")),this.onResize(h[0],0,0,n,!0,i[0])},this.updateColElements=n=>{const i=this.columns.filter(a=>!a.children.length);let o=1e-10;for(let a=0;ag.id===s.id),h=parseFloat((s.width||0).toString()),p=Math.floor(h);o+=h-p;const f=p+Math.floor(o);if(o-=Math.floor(o),this.colGroupMain&&this.colGroupMain.children[l]){const g=parseInt(this.colGroupMain.children[l].width,10);this.colGroupMain.children[l].width=f+"px",this.updateNextLockedCol(this.colGroupMain.parentElement,s,g-f)}if(this.colGroupHeader&&this.colGroupHeader.children[l]){const g=parseInt(this.colGroupHeader.children[l].width,10);this.colGroupHeader.children[l].width=f+"px",this.updateNextLockedCol(this.colGroupHeader.parentElement,s,g-f)}if(this.colGroupFooter&&this.colGroupFooter.children[l]){const g=parseInt(this.colGroupFooter.children[l].width,10);this.colGroupFooter.children[l].width=f+"px",this.updateNextLockedCol(this.colGroupFooter.parentElement,s,g-f)}}},this.onResize=r}fixateInitialWidths(r){const n=this.columns.filter(s=>!s.children.length);let i=0,o=this.colGroupMain?this.colGroupMain.children:[];for(let s=0;ss.id===r.id),o=[];let a=r.children.length;for(let s=i+1;a>0&&s{let l=s.width?parseFloat(s.width.toString())*n:0;const h=s.minResizableWidth===void 0?10:s.minResizableWidth;lh.locked).map(h=>parseInt(h.width+"",10)).reduce((h,p)=>h+p,0);!n.locked||s<=l+20||this.columns.forEach(h=>{if(h!=null&&h.locked&&i){const p=r==null?void 0:r.querySelectorAll('[aria-colindex="'+h.ariaColumnIndex+'"]');p==null||p.forEach(f=>{const g=f.style;this.isRtl?(h.index>o&&g&&g.right&&(g.right=parseInt(g.right,10)-i+"px"),h.indexo&&g&&g.left&&(g.left=parseInt(g.left,10)-i+"px"),h.index{this.isRtl=n},this.dragHandler=(n,i,o,a)=>{const s=n.originalEvent;a||(s.preventDefault(),s.stopPropagation(),s.stopImmediatePropagation());const l=o.closest("th");if(!l||!l)return;const h=l.clientWidth;let p=h;if(this.isRtl?p+=o.getBoundingClientRect().right-o.offsetWidth/2-n.clientX:p+=n.clientX-o.getBoundingClientRect().left-o.offsetWidth/2,!a&&Math.abs(p-h)<1)return;this.fixateInitialWidths(l.parentElement.clientWidth),this.setWidths(i,Math.floor(p)/h);const f=this.columns.filter(g=>!g.children.length).findIndex(g=>g.id===i.id);this.onResize(f,h,p,s,a,i.id)},this.dblClickHandler=(n,i)=>{const o=this.columns.filter(b=>i.indexOf(b.id)>-1);if(!this.colGroupMain||!o.length)return;const a={},s=o;for(;s.length>0;){const b=s.pop();if(!b)break;b.children.length?s.push(...b.children):a[b.id]=b}const l=this.columns.filter(b=>!b.children.length),h=[];l.forEach((b,z)=>{a[b.id]&&h.push(z)});const p=[this.colGroupMain.parentElement],f=[this.colGroupMain];this.colGroupHeader&&(p.push(this.colGroupHeader.parentElement),f.push(this.colGroupHeader)),this.colGroupFooter&&(p.push(this.colGroupFooter.parentElement),f.push(this.colGroupFooter)),p.forEach(b=>b.classList.add("k-autofitting"));let g=[];f.forEach(b=>{h.forEach(z=>{b.children[z]&&(b.children[z].width="",g[z]=Math.max(g[z]||0,b.children[z].offsetWidth+1))})}),f.forEach(b=>{h.forEach(z=>{b.children[z]&&(b.children[z].width=g[z]+"px",l[z].width=g[z])})}),p.forEach(b=>b.classList.remove("k-autofitting")),this.onResize(h[0],0,0,n,!0,i[0])},this.updateColElements=n=>{const i=this.columns.filter(a=>!a.children.length);let o=1e-10;for(let a=0;ag.id===s.id),h=parseFloat((s.width||0).toString()),p=Math.floor(h);o+=h-p;const f=p+Math.floor(o);if(o-=Math.floor(o),this.colGroupMain&&this.colGroupMain.children[l]){const g=parseInt(this.colGroupMain.children[l].width,10);this.colGroupMain.children[l].width=f+"px",this.updateNextLockedCol(this.colGroupMain.parentElement,s,g-f)}if(this.colGroupHeader&&this.colGroupHeader.children[l]){const g=parseInt(this.colGroupHeader.children[l].width,10);this.colGroupHeader.children[l].width=f+"px",this.updateNextLockedCol(this.colGroupHeader.parentElement,s,g-f)}if(this.colGroupFooter&&this.colGroupFooter.children[l]){const g=parseInt(this.colGroupFooter.children[l].width,10);this.colGroupFooter.children[l].width=f+"px",this.updateNextLockedCol(this.colGroupFooter.parentElement,s,g-f)}}},this.onResize=r}fixateInitialWidths(r){const n=this.columns.filter(s=>!s.children.length);let i=0,o=this.colGroupMain?this.colGroupMain.children:[];for(let s=0;ss.id===r.id),o=[];let a=r.children.length;for(let s=i+1;a>0&&s{let l=s.width?parseFloat(s.width.toString())*n:0;const h=s.minResizableWidth===void 0?10:s.minResizableWidth;lh.locked).map(h=>parseInt(h.width+"",10)).reduce((h,p)=>h+p,0);!n.locked||s<=l+20||this.columns.forEach(h=>{if(h!=null&&h.locked&&i){const p=r==null?void 0:r.querySelectorAll('[aria-colindex="'+h.ariaColumnIndex+'"]');p==null||p.forEach(f=>{const g=f.style;this.isRtl?(h.index>o&&g&&g.right&&(g.right=parseInt(g.right,10)-i+"px"),h.indexo&&g&&g.left&&(g.left=parseInt(g.left,10)-i+"px"),h.index{this.groupPanelDivElement=o&&o.children?o.children[0]:o},this.pressHandler=(o,a)=>{const s=this.getColumnIndex(o,a);if(this.startGroup=this.getGroupIndex(o),s>=0){const l=this.columns[s];(l.reorderable&&this.reorderable||l.groupable&&this.groupable)&&(this.startColumn=s)}},this.dragHandler=(o,a)=>{if(o.isTouch||o.originalEvent.preventDefault(),o.originalEvent.stopPropagation(),this.startColumn===-1&&this.startGroup===-1)return;this.currentColumn=this.getColumnIndex(o,a),this.currentGroup=this.isTargetGroupingContainer(o)?this.getCurrentGroupsLength:this.getGroupIndex(o);const s=!this.isValid();s&&(this.currentColumn=-1,this.currentGroup=-1);const l=this.currentColumn>=0?a.children[this.columns[this.currentColumn].index]:this.isTargetGroupingContainer(o)?o.originalEvent.target:this.groupPanelDivElement&&this.groupPanelDivElement.children[this.currentGroup];this.updateDragElementClue(o,a,l,s),this.updateDropElementClue(o,a,l,s)},this.releaseHandler=o=>{const a=this.startColumn,s=this.currentColumn,l=this.startGroup,h=this.currentGroup;o.originalEvent.preventDefault(),this.dropElementClue&&this.dropElementClue.setState({visible:!1}),this.dragElementClue&&this.dragElementClue.setState({visible:!1});const p=this.isValid();this.startColumn=this.startGroup=this.currentColumn=this.currentGroup=-1,p&&(a>=0&&s>=0?this.columnReorder(a,s,o.originalEvent):l>=0&&h>=0?this.groupReorder(l,h,o.originalEvent):a>=0&&h>=0&&this.columnToGroup(a,h,o.originalEvent))},this.columnReorder=r,this.groupReorder=n,this.columnToGroup=i}get dragClueRef(){return this.refDragElementClue}get dropClueRef(){return this.refDropElementClue}get getCurrentGroupsLength(){const r=this.groupPanelDivElement&&this.groupPanelDivElement.children;return r&&r.length||0}get dragElementClue(){return this.refDragElementClue.current}get dropElementClue(){return this.refDropElementClue.current}getColumnIndex(r,n){if(!n||n.parentElement===this.groupPanelDivElement)return-1;const i=RE(r,n);if(i===-1)return-1;for(let o=0;oa.index===i&&a.depth===o);return-1}isTargetGroupingContainer(r){const n=r.originalEvent.target;return n.className.indexOf?n.className.indexOf("k-grouping-drop-container")!==-1:!1}getGroupIndex(r){return RE(r,this.groupPanelDivElement)}isValid(){return this.startGroup>=0?this.currentGroup>=0&&this.currentGroup!==this.startGroup:this.startColumn===-1?!1:this.currentGroup>=0?this.columns[this.startColumn].groupable===!0&&this.groupable===!0:this.reorderable===!0&&this.currentColumn>=0&&this.currentColumn!==this.startColumn&&this.columns[this.startColumn].reorderable===!0&&this.columns[this.currentColumn].parentIndex===this.columns[this.startColumn].parentIndex}updateDragElementClue(r,n,i,o){if(!this.dragElementClue)return;const a=this.startColumn>=0?n.children[this.columns[this.startColumn].index].innerText:n.innerText;this.dragElementClue.setState({visible:!0,top:r.pageY+10,left:r.pageX,innerText:a,status:o||!i?"k-i-cancel":"k-i-plus"})}updateDropElementClue(r,n,i,o){if(!this.dropElementClue)return;if(o||!i){this.dropElementClue.setState({visible:!1});return}const a=i.getBoundingClientRect(),s=(i.closest(".k-grouping-header")||i).getBoundingClientRect();let l=a.left+r.pageX-r.clientX-6;!this.isTargetGroupingContainer(r)&&(this.currentColumn>this.startColumn||this.currentGroup>this.startGroup&&this.startGroup!==-1)&&(l+=a.width);const h=s.top+r.pageY-r.clientY;this.dropElementClue.setState({visible:!0,top:h,left:l,height:this.currentColumn>=0?n.clientHeight:s.height})}};/** + */let cjt=class{constructor(r,n,i){this.refDragElementClue=_.createRef(),this.refDropElementClue=_.createRef(),this.columns=[],this.reorderable=!1,this.groupable=!1,this.startColumn=-1,this.startGroup=-1,this.currentColumn=-1,this.currentGroup=-1,this.groupPanelDivElement=null,this.refGroupPanelDiv=o=>{this.groupPanelDivElement=o&&o.children?o.children[0]:o},this.pressHandler=(o,a)=>{const s=this.getColumnIndex(o,a);if(this.startGroup=this.getGroupIndex(o),s>=0){const l=this.columns[s];(l.reorderable&&this.reorderable||l.groupable&&this.groupable)&&(this.startColumn=s)}},this.dragHandler=(o,a)=>{if(o.isTouch||o.originalEvent.preventDefault(),o.originalEvent.stopPropagation(),this.startColumn===-1&&this.startGroup===-1)return;this.currentColumn=this.getColumnIndex(o,a),this.currentGroup=this.isTargetGroupingContainer(o)?this.getCurrentGroupsLength:this.getGroupIndex(o);const s=!this.isValid();s&&(this.currentColumn=-1,this.currentGroup=-1);const l=this.currentColumn>=0?a.children[this.columns[this.currentColumn].index]:this.isTargetGroupingContainer(o)?o.originalEvent.target:this.groupPanelDivElement&&this.groupPanelDivElement.children[this.currentGroup];this.updateDragElementClue(o,a,l,s),this.updateDropElementClue(o,a,l,s)},this.releaseHandler=o=>{const a=this.startColumn,s=this.currentColumn,l=this.startGroup,h=this.currentGroup;o.originalEvent.preventDefault(),this.dropElementClue&&this.dropElementClue.setState({visible:!1}),this.dragElementClue&&this.dragElementClue.setState({visible:!1});const p=this.isValid();this.startColumn=this.startGroup=this.currentColumn=this.currentGroup=-1,p&&(a>=0&&s>=0?this.columnReorder(a,s,o.originalEvent):l>=0&&h>=0?this.groupReorder(l,h,o.originalEvent):a>=0&&h>=0&&this.columnToGroup(a,h,o.originalEvent))},this.columnReorder=r,this.groupReorder=n,this.columnToGroup=i}get dragClueRef(){return this.refDragElementClue}get dropClueRef(){return this.refDropElementClue}get getCurrentGroupsLength(){const r=this.groupPanelDivElement&&this.groupPanelDivElement.children;return r&&r.length||0}get dragElementClue(){return this.refDragElementClue.current}get dropElementClue(){return this.refDropElementClue.current}getColumnIndex(r,n){if(!n||n.parentElement===this.groupPanelDivElement)return-1;const i=OE(r,n);if(i===-1)return-1;for(let o=0;oa.index===i&&a.depth===o);return-1}isTargetGroupingContainer(r){const n=r.originalEvent.target;return n.className.indexOf?n.className.indexOf("k-grouping-drop-container")!==-1:!1}getGroupIndex(r){return OE(r,this.groupPanelDivElement)}isValid(){return this.startGroup>=0?this.currentGroup>=0&&this.currentGroup!==this.startGroup:this.startColumn===-1?!1:this.currentGroup>=0?this.columns[this.startColumn].groupable===!0&&this.groupable===!0:this.reorderable===!0&&this.currentColumn>=0&&this.currentColumn!==this.startColumn&&this.columns[this.startColumn].reorderable===!0&&this.columns[this.currentColumn].parentIndex===this.columns[this.startColumn].parentIndex}updateDragElementClue(r,n,i,o){if(!this.dragElementClue)return;const a=this.startColumn>=0?n.children[this.columns[this.startColumn].index].innerText:n.innerText;this.dragElementClue.setState({visible:!0,top:r.pageY+10,left:r.pageX,innerText:a,status:o||!i?"k-i-cancel":"k-i-plus"})}updateDropElementClue(r,n,i,o){if(!this.dropElementClue)return;if(o||!i){this.dropElementClue.setState({visible:!1});return}const a=i.getBoundingClientRect(),s=(i.closest(".k-grouping-header")||i).getBoundingClientRect();let l=a.left+r.pageX-r.clientX-6;!this.isTargetGroupingContainer(r)&&(this.currentColumn>this.startColumn||this.currentGroup>this.startGroup&&this.startGroup!==-1)&&(l+=a.width);const h=s.top+r.pageY-r.clientY;this.dropElementClue.setState({visible:!0,top:h,left:l,height:this.currentColumn>=0?n.clientHeight:s.height})}};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const cjt=t=>{let r=null;const n=oT(),i=L4(t.id),o=_.useCallback(p=>{t.onContextMenu&&t.onContextMenu.call(void 0,p,t.dataItem,t.field)},[t.onContextMenu,t.dataItem,t.field]);let a=null,s=null;if(t.rowType==="groupFooter")a={onContextMenu:o,className:t.className,...i},r=_.createElement("td",{...a});else if(t.rowType!=="groupHeader"){if(t.field!==void 0){const f=Wa(t.field,t.dataItem);f!=null&&(s=t.format?n.format(t.format,f):f.toString())}const p=Me("k-table-td",t.className,{"k-selected":t.isSelected});a={onContextMenu:o,colSpan:t.colSpan,style:t.style,className:p,role:"gridcell","aria-colindex":t.ariaColumnIndex,"aria-selected":t.isSelected,[xc]:t.columnIndex,...i},r=_.createElement("td",{...a},s)}const l=t.rowType||"data",h=t.cells;if(h&&h[l]){const p=h[l];return _.createElement(p,{...t,tdProps:a},s)}return t.render?t.render.call(void 0,r,t):r};/** + */const hjt=t=>{let r=null;const n=aT(),i=L4(t.id),o=_.useCallback(p=>{t.onContextMenu&&t.onContextMenu.call(void 0,p,t.dataItem,t.field)},[t.onContextMenu,t.dataItem,t.field]);let a=null,s=null;if(t.rowType==="groupFooter")a={onContextMenu:o,className:t.className,...i},r=_.createElement("td",{...a});else if(t.rowType!=="groupHeader"){if(t.field!==void 0){const f=$a(t.field,t.dataItem);f!=null&&(s=t.format?n.format(t.format,f):f.toString())}const p=ke("k-table-td",t.className,{"k-selected":t.isSelected});a={onContextMenu:o,colSpan:t.colSpan,style:t.style,className:p,role:"gridcell","aria-colindex":t.ariaColumnIndex,"aria-selected":t.isSelected,[xc]:t.columnIndex,...i},r=_.createElement("td",{...a},s)}const l=t.rowType||"data",h=t.cells;if(h&&h[l]){const p=h[l];return _.createElement(p,{...t,tdProps:a},s)}return t.render?t.render.call(void 0,r,t):r};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const ZE=t=>{let r=null;const{columnIndex:n,level:i,columnsCount:o,rowType:a,dataItem:s,field:l,onChange:h,expanded:p,render:f,dataIndex:g,ariaColumnIndex:b,isRtl:z}=t,M=l||"",I=L4(t.id),F=jl();let H=null,E=null,R=null;const W=_.useCallback(et=>{et.isDefaultPrevented()||et.keyCode===Jt.enter&&h&&(et.preventDefault(),h({dataItem:s,dataIndex:g,syntheticEvent:et,field:void 0,value:!p}))},[p,h,s,g]),$=_.useCallback(et=>{t.onContextMenu&&t.onContextMenu.call(void 0,et,t.dataItem,t.field)},[t.onContextMenu,t.dataItem,t.field]),G=(et,at)=>{const tt=p?KB:XB,ft=F.toLanguageString(tt,xn[tt]);return H={className:"k-table-td",style:{...t.style,...at},colSpan:et,key:"g-colspan",role:"gridcell","aria-selected":!1,"aria-expanded":p,"aria-colindex":b,onKeyDown:W,onContextMenu:$,...I},R=_.createElement("p",{className:"k-reset"},_.createElement("a",{onClick:dt=>{dt.preventDefault(),h&&h({dataItem:s,dataIndex:g,syntheticEvent:dt,field:void 0,value:!p})},href:"#",tabIndex:-1,"aria-label":ft},_.createElement(en,{name:p?"caret-alt-down":z?"caret-alt-left":"caret-alt-right",icon:p?Y0:z?Pl:Dl})),s[M]instanceof Date&&s[M].toString?s[M].toString():s[M]),_.createElement("td",{...H,key:H.key},R)};n===void 0||i===void 0||n{let r=null;const{columnIndex:n,level:i,columnsCount:o,rowType:a,dataItem:s,field:l,onChange:h,expanded:p,render:f,dataIndex:g,ariaColumnIndex:b,isRtl:z}=t,M=l||"",I=L4(t.id),F=jl();let H=null,E=null,R=null;const W=_.useCallback(et=>{et.isDefaultPrevented()||et.keyCode===te.enter&&h&&(et.preventDefault(),h({dataItem:s,dataIndex:g,syntheticEvent:et,field:void 0,value:!p}))},[p,h,s,g]),$=_.useCallback(et=>{t.onContextMenu&&t.onContextMenu.call(void 0,et,t.dataItem,t.field)},[t.onContextMenu,t.dataItem,t.field]),G=(et,at)=>{const tt=p?qB:KB,ft=F.toLanguageString(tt,mn[tt]);return H={className:"k-table-td",style:{...t.style,...at},colSpan:et,key:"g-colspan",role:"gridcell","aria-selected":!1,"aria-expanded":p,"aria-colindex":b,onKeyDown:W,onContextMenu:$,...I},R=_.createElement("p",{className:"k-reset"},_.createElement("a",{onClick:dt=>{dt.preventDefault(),h&&h({dataItem:s,dataIndex:g,syntheticEvent:dt,field:void 0,value:!p})},href:"#",tabIndex:-1,"aria-label":ft},_.createElement(Qi,{name:p?"caret-alt-down":z?"caret-alt-left":"caret-alt-right",icon:p?Y0:z?Pl:Dl})),s[M]instanceof Date&&s[M].toString?s[M].toString():s[M]),_.createElement("td",{...H,key:H.key},R)};n===void 0||i===void 0||nthis.props.selectionChange({field:this.props.field,syntheticEvent:o})})),n.columnMenu&&_.createElement(JB,{...n})];return this.props.render?this.props.render.call(void 0,i,this.props):i}}Ri(iN);const ujt=na(iN);/** + */class nN extends _.Component{get _inputId(){return this.props.id}render(){const r=ai(this),{columnMenuWrapperProps:n}=this.props,i=[_.createElement("span",{key:0,className:"k-checkbox-wrap"},_.createElement("input",{id:this._inputId,type:"checkbox",tabIndex:-1,className:"k-checkbox k-checkbox-md k-rounded-md","aria-label":r.toLanguageString(k8,mn[k8]),"aria-checked":this.props.selectionValue,checked:this.props.selectionValue,onChange:o=>this.props.selectionChange({field:this.props.field,syntheticEvent:o})})),n.columnMenu&&_.createElement(QB,{...n})];return this.props.render?this.props.render.call(void 0,i,this.props):i}}Vi(nN);const pjt=ra(nN);/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const nN=class extends _.Component{render(){return this.props.children||si(this).toLanguageString(Oy,xn[Oy])}};nN.displayName="KendoReactGridNoRecords";let oN=nN;Ri(oN);/** + */const oN=class extends _.Component{render(){return this.props.children||ai(this).toLanguageString(Oy,mn[Oy])}};oN.displayName="KendoReactGridNoRecords";let aN=oN;Vi(aN);/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const pjt=t=>{const{column:r,index:n,isRtl:i,id:o,cells:a}=t,s=L4(o),l={colSpan:r.colSpan!==1?r.colSpan:void 0,style:r.left!==void 0?i?{left:r.right,right:r.left}:{left:r.left,right:r.right}:{},className:Me("k-table-td",r.locked&&r.left!==void 0?"k-grid-footer-sticky":""),key:n,role:"gridcell","aria-colindex":r.ariaColumnIndex,...s},h={field:r.field,ariaColumnIndex:r.ariaColumnIndex,...l},p=cd(a,r.cells);if(p&&p.footerCell){const f=p.footerCell;return _.createElement(f,{...h,tdProps:l,index:n})}return r.footerCell&&_.createElement(r.footerCell,{...h,key:n})||_.createElement("td",{...l})},djt=t=>_.createElement("tr",{className:"k-table-row",role:"row","aria-rowindex":t.ariaRowIndex},gWt(t.columns).map((r,n)=>{const i=Je.generateNavigatableId(`${n}-footercell`,t.idPrefix,"nodata");return _.createElement(pjt,{key:i,column:r,id:i,index:n,cells:t.cells,isRtl:t.isRtl})}));/** + */const djt=t=>{const{column:r,index:n,isRtl:i,id:o,cells:a}=t,s=L4(o),l={colSpan:r.colSpan!==1?r.colSpan:void 0,style:r.left!==void 0?i?{left:r.right,right:r.left}:{left:r.left,right:r.right}:{},className:ke("k-table-td",r.locked&&r.left!==void 0?"k-grid-footer-sticky":""),key:n,role:"gridcell","aria-colindex":r.ariaColumnIndex,...s},h={field:r.field,ariaColumnIndex:r.ariaColumnIndex,...l},p=cd(a,r.cells);if(p&&p.footerCell){const f=p.footerCell;return _.createElement(f,{...h,tdProps:l,index:n})}return r.footerCell&&_.createElement(r.footerCell,{...h,key:n})||_.createElement("td",{...l})},fjt=t=>_.createElement("tr",{className:"k-table-row",role:"row","aria-rowindex":t.ariaRowIndex},mWt(t.columns).map((r,n)=>{const i=Je.generateNavigatableId(`${n}-footercell`,t.idPrefix,"nodata");return _.createElement(djt,{key:i,column:r,id:i,index:n,cells:t.cells,isRtl:t.isRtl})}));/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const fjt=({buttonCount:t=10,info:r=!0,type:n="numeric",pageSizes:i=void 0,previousNext:o=!0,responsive:a=void 0,navigatable:s=void 0,pageSizeValue:l=void 0})=>({buttonCount:t,info:r,pageSizes:i===!0?[5,10,20]:i||void 0,previousNext:o,responsive:a!==!1,navigatable:s!==!1,type:n,pageSizeValue:l}),vjt=t=>fjt(t===!0?{}:t);/** + */const vjt=({buttonCount:t=10,info:r=!0,type:n="numeric",pageSizes:i=void 0,previousNext:o=!0,responsive:a=void 0,navigatable:s=void 0,pageSizeValue:l=void 0})=>({buttonCount:t,info:r,pageSizes:i===!0?[5,10,20]:i||void 0,previousNext:o,responsive:a!==!1,navigatable:s!==!1,type:n,pageSizeValue:l}),gjt=t=>vjt(t===!0?{}:t);/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const JE={name:"@progress/kendo-react-grid",productName:"KendoReact",productCodes:["KENDOUIREACT","KENDOUICOMPLETE"],publishDate:1722844128,version:"",licensingDocsUrl:"https://www.telerik.com/kendo-react-ui/components/my-license/"};/** + */const QE={name:"@progress/kendo-react-grid",productName:"KendoReact",productCodes:["KENDOUIREACT","KENDOUICOMPLETE"],publishDate:1722844128,version:"",licensingDocsUrl:"https://www.telerik.com/kendo-react-ui/components/my-license/"};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const gjt=t=>{const{colSpan:r,ariaColIndex:n,dataItem:i,dataIndex:o,id:a}=t,s=L4(a),l=_.useCallback(h=>{t.onContextMenu&&t.onContextMenu.call(void 0,h,t.dataItem)},[t.onContextMenu,t.dataItem]);return _.createElement("td",{onContextMenu:l,className:"k-table-td k-detail-cell",colSpan:r,"aria-colindex":n,role:"gridcell",...s},_.createElement(t.detail,{dataItem:i,dataIndex:o}))};/** + */const mjt=t=>{const{colSpan:r,ariaColIndex:n,dataItem:i,dataIndex:o,id:a}=t,s=L4(a),l=_.useCallback(h=>{t.onContextMenu&&t.onContextMenu.call(void 0,h,t.dataItem)},[t.onContextMenu,t.dataItem]);return _.createElement("td",{onContextMenu:l,className:"k-table-td k-detail-cell",colSpan:r,"aria-colindex":n,role:"gridcell",...s},_.createElement(t.detail,{dataItem:i,dataIndex:o}))};/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const mjt=t=>_.createElement("td",{className:"k-table-td k-hierarchy-cell",role:"gridcell"});/** + */const yjt=t=>_.createElement("td",{className:"k-table-td k-hierarchy-cell",role:"gridcell"});/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- - */const bc=class extends _.Component{constructor(r){super(r),this._columns=[],this._columnsMap=[[]],this._columnsMutations=0,this._resized=!1,this._focusFirst=!1,this._singleEditRow=!1,this._shouldUpdateLeftRight=!0,this._scrollbarWidth=void 0,this.contextStateRef={current:void 0},this.navigationStateRef={current:void 0},this._data=[],this._slicedData=void 0,this.wrapperScrollTop=0,this.showLicenseWatermark=!1,this.headerRef=_.createRef(),this.headerElementRef=_.createRef(),this._element=null,this.tableElement=null,this.containerRef=_.createRef(),this.tableBodyRef=_.createRef(),this._footer=null,this.forceUpdateTimeout=void 0,this.isRtl=!1,this.headTable=null,this.rowsInEdit=[],this.observer=null,this.handleIntersection=o=>{const a={rowIndex:this.rowIndex};o.forEach(s=>{s.isIntersecting||this.setCurrentOnTop(a)})},this.setCurrentOnTop=o=>{if(!this.vs.container||this.props.scrollable==="none")return;this.observer&&this.observer.disconnect();const{rowIndex:a}=o;if(this.props.scrollable==="virtual")this.vs.askedSkip=a,this.vs.container.scroll(0,Math.round(this.vs.askedSkip/this.vs.total*this.vs.container.scrollHeight));else if(this.element){const s=a<1?this.element.querySelector("tbody > tr:nth-child(1)"):this.element.querySelector(`tbody > tr:nth-child(${a+1})`);s&&this.containerRef.current&&(this.containerRef.current.scrollTop=s.offsetTop)}},this.scrollIntoView=o=>{if(!this.vs.container||this.props.scrollable==="none")return;this.rowIndex=o.rowIndex;const{rowIndex:a}=o,s=this.element;if(this.observer&&s){this.observer.disconnect();const l=s.querySelector(`[absolute-row-index="${a}"]`);l?this.observer.observe(l):this.setCurrentOnTop(o)}},this.fitColumns=o=>{this.columnResize.dblClickHandler(null,o)},this.getColumnsEssentialProps=o=>JSON.stringify(o.map(a=>({id:a.id,field:a.field,title:a.title,children:a.children}))),this.checkMatchMediaColumnsDifferece=()=>{const o=this.childrenToArray(this.props.children);return this.getColumnsEssentialProps(o)===this.getColumnsEssentialProps(this._columns)},this.onContextMenu=(o,a,s)=>{if(this.props.onContextMenu){const l={target:this,syntheticEvent:o,nativeEvent:o.nativeEvent,dataItem:a,field:s};this.props.onContextMenu.call(void 0,l)}},this.getVirtualScroll=o=>{const{rowHeight:a,detailRowHeight:s,detail:l,expandField:h,groupable:p}=o,f=this.isAllData(),g=a!==void 0&&a>0,b=s!==void 0&&s>0,z=p===!0||typeof p=="object"&&p.enabled!==!1;return!g||z&&!f||l&&h&&(!b||!f)?ajt:qE},this.isAllData=()=>{const{data:o,total:a}=this.props;return Array.isArray(o)?o.length===a:o?a===o.total:!1},this.initializeVirtualization=(o,a)=>{if(this.reInitVirtualization(this.props.scrollable==="virtual",this.props.total,this.props.filter,this.props.group,this.props.sort,a||this.props.rowHeight===void 0||this.props.rowHeight===0),this.vs.fixedScroll=this.props.fixedScroll||!1,this.vs.PageChange=this.pageChange,this.vs.realSkip=this.props.skip||0,this.vs.pageSize=(this.props.take!==void 0?this.props.take:this.props.pageSize)||0,this.vs.scrollableVirtual=this.props.scrollable==="virtual",this.vs.total=o,this.vs.propsSkip=(this.props.skip||0)+(this.props.scrollable==="virtual"?this.vs.topCacheCount+(this.vs.attendedSkip-(this.props.skip||0)):0),this.props.rowHeight!==void 0&&this.props.rowHeight>0&&!a){const s=this.props.rowHeight*o;this.vs.containerHeight=Ry?Math.min(YE,s):s}else this.vs.containerHeight=1533915;if(this.vs.containerRef=this.containerRef,this.vs.tableBodyRef=this.tableBodyRef,this.vs.table=this.tableElement,this._slicedData=void 0,this.vs instanceof qE){const{rowHeight:s=0,detail:l,expandField:h}=this.props;let{detailRowHeight:p=0}=this.props;p=l&&h?p:s,this.isAllData()?(this.vs.total=this._data.length,this._slicedData=this._data.slice(this.vs.realSkip,this.vs.realSkip+this.vs.pageSize),this.vs.rowHeightService=this.rowHeightService(this.vs,this._data.length,s,p,this._data)):this.vs.rowHeightService=new Fu(o,s,p);const f=this.vs.rowHeightService.totalHeight();this.vs.containerHeight=Ry?Math.min(YE,f):f}},this.getCachedScrollbarWidth=()=>(this._scrollbarWidth||(this._scrollbarWidth=KP()||void 0),this._scrollbarWidth),this.scrollHandler=o=>{if(o.target!==o.currentTarget)return;clearTimeout(this.forceUpdateTimeout),this.vs.table=this.tableElement;const a=o.currentTarget.scrollLeft,s=o.currentTarget.scrollTop;this.props.columnVirtualization&&(!this.vs.scrollableVirtual||s===this.wrapperScrollTop)&&(this.forceUpdateTimeout=window.setTimeout(()=>{this.forceUpdate()},0)),this._header&&this._header.setScrollLeft(a),this._footer&&this._footer.setScrollLeft(a),this.vs&&s!==this.wrapperScrollTop&&this.vs.scrollHandler(o),fn(this.props.onScroll,o,this,void 0),this.wrapperScrollTop=s},this.onKeyDown=o=>{if(w3.onKeyDown(o,{navigatable:this.props.navigatable||!1,contextStateRef:this.contextStateRef,navigationStateRef:this.navigationStateRef,onNavigationAction:this.onNavigationAction,columns:this.columns}),this.props.onKeyDown){const{mode:a,cell:s}=zy(this.props.selectable),l={dataItems:this.getLeafDataItems(),mode:a,cell:s,componentId:this._gridId,selectedField:this.props.selectedField,...this.getArguments(o)};this.props.onKeyDown.call(void 0,l)}},this.onFocus=o=>{w3.onFocus(o,{navigatable:!!this.props.navigatable,contextStateRef:this.contextStateRef})},this.onNavigationAction=o=>{if(o.action==="moveToNextPage"&&this.moveToNextPage(o.event),o.action==="moveToPrevPage"&&this.moveToPrevPage(o.event),o.focusElement&&o.action==="reorderToRight"){const a=parseInt(o.focusElement.ariaColIndex,10)-1;a0&&this.columnReorder(a,a-1,o.event)}if(this.props.onNavigationAction){const a={focusElement:o.focusElement,...this.getArguments(o.event)};this.props.onNavigationAction.call(void 0,a)}},this.rowClick=(o,a)=>{this.props.onRowClick&&o.target.nodeName==="TD"&&this.props.onRowClick.call(void 0,{dataItem:a.dataItem,...this.getArguments(o)})},this.rowDblClick=(o,a)=>{this.props.onRowDoubleClick&&o.target.nodeName==="TD"&&this.props.onRowDoubleClick.call(void 0,{dataItem:a.dataItem,...this.getArguments(o)})},this.itemChange=o=>{const a=this.props.onItemChange;if(o.field===this.props.expandField||this.props.group&&o.field===void 0){const s=this.props.onExpandChange;s&&s.call(void 0,{...this.getArguments(o.syntheticEvent),dataItem:o.dataItem,dataIndex:o.dataIndex,value:o.value});return}a&&a.call(void 0,{...this.getArguments(o.syntheticEvent),dataItem:o.dataItem,field:o.field,value:o.value})},this.onHeaderSelectionChange=o=>{this.props.onHeaderSelectionChange&&this.props.onHeaderSelectionChange.call(void 0,{field:o.field,nativeEvent:o.syntheticEvent&&o.syntheticEvent.nativeEvent,syntheticEvent:o.syntheticEvent,target:this,dataItems:this.getLeafDataItems(),selectedField:this.props.selectedField})},this.selectionRelease=o=>{if(this.props.onSelectionChange){const a=this.getSlicedLeafDataItems()[o.startRowIndex],s=this.getSlicedLeafDataItems()[o.endRowIndex],l={syntheticEvent:void 0,target:this,selectedField:this.props.selectedField||"",componentId:this._gridId,dataItems:this.getLeafDataItems(),dataItem:null,startDataItem:a,endDataItem:s,...o};this.props.onSelectionChange.call(void 0,l)}},this.pageChange=(o,a,s)=>{this.raiseDataEvent(this.props.onPageChange,{page:o},{skip:o.skip,take:o.take},a,s)},this.getTotal=()=>{let o=this.props.total||0;return Array.isArray(this.props.data)?o=o||this.props.data.length:this.props.data&&(o=o||this.props.data.total),o},this.moveToNextPage=o=>{const a=this.props.take||0,s=(this.props.skip||0)+a,l=this.getTotal();s{const a=this.props.take||0,s=(this.props.skip||0)-a;s>=0&&this.pageChange({skip:s,take:a},o)},this.pagerPageChange=o=>{this.pageChange({skip:o.skip,take:o.take},o.syntheticEvent,o.targetEvent)},this.sortChange=(o,a)=>{this.raiseDataEvent(this.props.onSortChange,{sort:o},{sort:o,...this.props.scrollable==="virtual"?{skip:0}:{}},a)},this.filterChange=(o,a)=>{this.raiseDataEvent(this.props.onFilterChange,{filter:o},{filter:o||void 0,skip:0},a)},this.groupChange=(o,a)=>{const s=a.nativeEvent?a:{nativeEvent:a.nativeEvent||a.originalEvent};o.length===0&&this.props.navigatable&&(this._focusFirst=!0),this._columnsMutations++,this.raiseDataEvent(this.props.onGroupChange,{group:o},{group:o,skip:0},s)},this.onClipboard=(o,a)=>{if(this.props.onClipboard){if(!this.inActiveElement()||!o)return;this.props.onClipboard.call(void 0,{type:o,nativeEvent:a,columns:this._columns,dataItemKey:this.props.dataItemKey||"",...typeof this.props.clipboard!="boolean"?this.props.clipboard:{}})}},this.inActiveElement=()=>{var o,a,s;if(!ai)return!1;const l=Ki(this.document),h=l?l.matches(".k-table-td")?l:(o=this.document)==null?void 0:o.body:(a=this.document)==null?void 0:a.body,p=h.closest(".k-grid-container"),f=h&&((s=this._element)==null?void 0:s.contains(h));return!!(h&&f&&p)},this.onResize=(o,a,s,l,h,p)=>{this.resetTableWidth(),this._shouldUpdateLeftRight=!0,this._resized=!0,this._columnsMutations++,this.props.onColumnResize&&this.props.onColumnResize.call(void 0,{columns:this.columns,nativeEvent:l,targetColumnId:p,index:o,newWidth:a,oldWidth:s,end:h,target:this})},this.reInitVirtualization=za((o,a,s,l,h,p)=>{this.vs.reset();const f=this.getVirtualScroll(this.props);this.vs=new f(p)}),this.flatData=za((o,a,s,l,h,p,f)=>{const g=[],b=GB(g,o,a,{index:s},l!==void 0,h);return{flattedData:g,resolvedGroupsCount:b}}),this.rowHeightService=za((o,a,s,l,h)=>new Fu(a,s,l,h)),this.childrenToArray=za(o=>_.Children.toArray(o)),this.readColumns=za((o,a,s)=>{const l=o.filter(h=>h&&h.type&&h.type.displayName==="KendoReactGridColumn");return UB(l,this.columns,{prevId:0,idPrefix:a})}),this.mapColumns=za((o,a)=>xNt(o,!0)),this.filterColumnsByMediaProp=o=>o.filter(a=>ai&&a&&a.media?window.matchMedia(a.media).matches:a),this.configureColumns=za((o,a,s)=>{this.props.selectedField&&o.filter(p=>p.field===this.props.selectedField).forEach(p=>{p.width=p.width||"50px",p.cell=p.cell||FWt,p.headerCell=p.headerCell||ujt});const l={id:"",resizable:!0,width:"32px",title:" ",declarationIndex:-1,orderIndex:-1,children:[],parentIndex:-1,depth:0,colSpan:0,rowSpan:0,left:0,right:0,index:0,rightBorder:!1,ariaColumnIndex:0,isAccessible:!0};let h=0;this.props.expandField&&this.props.onExpandChange&&this.props.detail&&(o.unshift({...l,cell:RWt,field:this.props.expandField,headerClassName:"k-hierarchy-cell k-header"}),h++);for(let p=0;pp.parentIndex>=0&&(p.parentIndex+=h))}),this.getHeaderRow=za((o,a,s,l,h,p,f,g,b,z,M,I,F)=>_.createElement(qWt,{cells:this.props.cells,sort:o,sortable:a,sortChange:this.sortChange,group:s||[],groupable:l,groupChange:this.groupChange,filter:h,filterable:p,filterOperators:f,filterChange:this.filterChange,columnMenu:b,columnMenuIcon:z,selectionChange:this.onHeaderSelectionChange,columns:M,columnResize:this.columnResize,pressHandler:this.dragLogic.pressHandler,dragHandler:this.dragLogic.dragHandler,releaseHandler:this.dragLogic.releaseHandler,columnsMap:I,cellRender:g,isRtl:F,dragClue:this.dragLogic.dragClueRef,headerRef:this.headerElementRef,containerRef:this.containerRef,navigatable:!!this.props.navigatable,columnGroupChange:this.columnGroupChange})),this.resolveTitle=o=>{const a=this._columns.find(l=>l.field===o),s=a&&(a.title||a.field);return s===void 0?o:s},this.getLeafDataItems=()=>this._data.filter(o=>o.rowType==="data").map(o=>o.dataItem),this.getSlicedLeafDataItems=()=>(this._slicedData||this._data).filter(o=>o.rowType==="data").map(o=>o.dataItem),this.handleFocusInEditableRows=()=>{var o,a,s;if(this.tableBodyRef.current&&((o=this.tableBodyRef.current)==null?void 0:o.getElementsByClassName("k-grid-edit-row").length)>0){this._singleEditRow=!1,(a=document.activeElement)!=null&&a.closest(".k-grid-edit-row")?this._lastActiveElement=document.activeElement:this._lastActiveElement=void 0;const l=Array.from((s=this.tableBodyRef.current)==null?void 0:s.getElementsByClassName("k-grid-edit-row"));l.length>this.rowsInEdit.length?this._newEditableRow=l.filter(h=>!this.rowsInEdit.includes(h))[0]:l.length===1&&(this._newEditableRow=l[0],this._singleEditRow=!0),this.rowsInEdit=l}},gi(JE),this.showLicenseWatermark=gb(JE);const n=this.props.groupable===!0||typeof this.props.groupable=="object"&&this.props.groupable.enabled!==!1,i=this.getVirtualScroll(r);this.vs=new i(n||r.rowHeight===void 0||r.rowHeight===0),this.dragLogic=new ljt(this.columnReorder.bind(this),this.groupReorder.bind(this),this.columnToGroup.bind(this)),this.columnGroupChange=this.columnGroupChange.bind(this),this.columnResize=new sjt(this.onResize),this.props.clipboard&&(this.clipboardService=new ANt(this.onClipboard)),w3.onConstructor({navigatable:!!r.navigatable,contextStateRef:this.contextStateRef,navigationStateRef:this.navigationStateRef,idPrefix:this._gridId})}get columns(){const r=this._columns.filter(n=>n.declarationIndex>=0&&n.parentIndex===-1);return YB(r)}get element(){return this._element}get document(){if(ai)return this.element&&this.element.ownerDocument||document}get _header(){return this.headerRef.current}get _gridId(){return this.props.id+"-role-element-id"}componentDidMount(){var r;this.props.columnVirtualization&&!navigator.userAgent.match(BWt)&&(this.headTable&&(this.headTable.style.display="block"),this.tableElement&&(this.tableElement.style.display="block")),this.resetTableWidth(),Tu(this.getCachedScrollbarWidth());const n=wB(this.element);this.isRtl=n,w3.onComponentDidMount({scope:this.element||void 0,contextStateRef:this.contextStateRef,navigationStateRef:this.navigationStateRef}),this.isRtl&&this.forceUpdate();const i={rootMargin:"0px",threshold:.9};this.clipboardService&&this.clipboardService.addEventListeners(this.document),this.observer=ai&&window.IntersectionObserver&&new window.IntersectionObserver(this.handleIntersection,i)||null,this.resizeObserver=ai&&window.ResizeObserver&&new window.ResizeObserver(this.calculateMedia.bind(this)),(r=this.document)!=null&&r.body&&this.resizeObserver&&this.resizeObserver.observe(this.document.body)}getSnapshotBeforeUpdate(){return w3.onGetSnapshotBeforeUpdate({document:this.document,contextStateRef:this.contextStateRef,navigationStateRef:this.navigationStateRef}),null}componentDidUpdate(){this.resetTableWidth(),Tu(this.getCachedScrollbarWidth()),this.vs.tableTransform&&this.vs.table&&(this.vs.table.style.transform=this.vs.tableTransform,this.vs.tableTransform=""),this.handleFocusInEditableRows(),w3.onComponentDidUpdate({scope:this.element||void 0,contextStateRef:this.contextStateRef,navigationStateRef:this.navigationStateRef,focusFirst:this._focusFirst,newEditableRow:this._newEditableRow,singleEditRow:this._singleEditRow,lastActiveElement:this._lastActiveElement,navigatable:this.props.navigatable}),this._focusFirst=!1,this._newEditableRow=void 0}componentWillUnmount(){var r;clearTimeout(this.forceUpdateTimeout),this.clipboardService&&this.clipboardService.removeEventListeners(this.document),(r=this.document)!=null&&r.body&&this.resizeObserver&&this.resizeObserver.disconnect()}render(){var r;let n=this.props.total||0;const i=Je.getIdPrefix(this.navigationStateRef),o=si(this);let a=[];Array.isArray(this.props.data)?(a=this.props.data,n=n||this.props.data.length):this.props.data&&(a=this.props.data.data,n=n||this.props.data.total);const s=typeof this.props.groupable=="object"&&this.props.groupable.footer||"none",l=this.props.scrollable==="virtual",{resolvedGroupsCount:h,flattedData:p}=this.flatData(a,s,this.props.skip||0,this.props.group,this.props.expandField,this.props.filter,this.props.sort);this._data=p;const f=this.props.groupable===!0||typeof this.props.groupable=="object"&&this.props.groupable.enabled!==!1;this.columnResize.resizable=this.props.resizable||!1,this.dragLogic.reorderable=this.props.reorderable||!1,this.dragLogic.groupable=f;const g=this.props.selectable&&this.props.selectable.drag?"none":void 0;this.initializeVirtualization(n,f);const b=this.childrenToArray(this.props.children);this.initColumns(b,h);const z=b.map(Ht=>Ht&&Ht.type&&Ht.type.displayName==="KendoReactGridToolbar"?_.cloneElement(Ht,{...Ht.props,ariaControls:this._gridId}):null),M=b.filter(Ht=>Ht&&Ht.type&&Ht.type.displayName==="KendoReactGridNoRecords"),I=b.filter(Ht=>Ht&&Ht.type&&Ht.type.displayName==="KendoReactGridStatusBar"),F=this._columns.filter(Ht=>Ht.children.length===0),H=f&&_.createElement(rN,{group:this.props.group||[],groupChange:this.groupChange,pressHandler:this.dragLogic.pressHandler,dragHandler:this.dragLogic.dragHandler,releaseHandler:this.dragLogic.releaseHandler,refCallback:this.dragLogic.refGroupPanelDiv,resolveTitle:this.resolveTitle,ariaControls:this._gridId,onContextMenu:this.onContextMenu}),{sort:E,sortable:R,group:W,filter:$,filterable:G,filterOperators:Z=XE,headerCellRender:K,columnMenu:et,columnMenuIcon:at}=this.props,tt=_.createElement($Wt,{size:this.props.size,columnResize:this.columnResize,staticHeaders:this.props.scrollable!=="none",scrollableDataElement:()=>this.vs.container,hasScrollbarWidth:!!this.getCachedScrollbarWidth(),draggable:this.props.reorderable||f,ref:this.headerRef,elemRef:this.headerElementRef,className:this.props.headerClassName,headerRow:this.getHeaderRow(E,R,W,f,$,G,Z,K,et,at,this._columns,this._columnsMap,this.isRtl),filterRow:this.props.filterable&&_.createElement(tN,{cells:this.props.cells,size:this.props.size,columns:this._columns,filter:this.props.filter,filterOperators:this.props.filterOperators||XE,filterChange:this.filterChange,sort:this.props.sort,cellRender:this.props.filterCellRender,isRtl:this.isRtl,navigatable:!!this.props.navigatable,ariaRowIndex:this._columnsMap.length+1})||void 0,cols:F.map((Ht,se)=>_.createElement("col",{key:se.toString(),width:Xv(Ht)}))}),ft=this.vs&&this.vs.container&&this.vs.container.scrollLeft||0,dt=parseFloat(((this.props.style||{}).width||"").toString()),{colSpans:ht,hiddenColumns:lt}=dWt({enabled:this.props.columnVirtualization,columns:F,tableViewPortWidth:dt,scrollLeft:ft}),yt=(Ht,se,Se)=>{let Kt=!1;const fe=this.props.selectedField?Wa(this.props.selectedField,Ht.dataItem):void 0;return{row:F.map((ne,ce)=>{if(lt[ce])return null;const xe=ne.id?ne.id:ce,Wt=`${ne.className?ne.className+" ":""}${ne.locked?"k-grid-content-sticky":""}`,qt=ne.left!==void 0?this.isRtl?{left:ne.right,right:ne.left}:{left:ne.left,right:ne.right}:{};let Ee=!1;if(ne.editable&&this.props.editField){const Yt=Wa(this.props.editField,Ht.dataItem);Yt&&(Yt===!0||Yt===ne.field)&&(Kt=!0,Ee=!0)}const Ie=ne.cell||Ee&&NWt||cjt,Pe=this.props.expandField&&this.props.detail&&ne.field===this.props.expandField;return _.createElement(Ie,{onContextMenu:this.onContextMenu,key:xe,locked:this.props.lockGroups,id:Je.generateNavigatableId(`${se}-${String(ce)}`,i,Pe||Ht.rowType==="groupHeader"||Ht.rowType==="groupFooter"||ne.field==="value"?"nodata":"cell"),colSpan:ht[ce],dataItem:Ht.dataItem,field:ne.field,editor:ne.editor,format:ne.format,className:Wt,render:this.props.cellRender,cells:cd(this.props.cells,ne.cells),onChange:this.itemChange,selectionChange:this.props.onSelectionChange?Yt=>{this.selectionChange({event:Yt,dataItem:Ht.dataItem,dataIndex:Se,columnIndex:ce})}:void 0,columnIndex:ce,columnsCount:F.length,rowType:Ht.rowType,level:Ht.level,expanded:Ht.expanded,dataIndex:Ht.dataIndex,style:qt,ariaColumnIndex:ne.ariaColumnIndex,isSelected:Array.isArray(fe)&&fe.indexOf(ce)>-1})}),isInEdit:Kt,isSelected:typeof fe=="boolean"&&fe}};let mt=0;if(l)for(let Ht=0;HtHt>=this._data.length-mt;let kt=this.vs.realSkip||0;const _t=[];let bt=!1;const Mt=this._columnsMap.length+(this.props.filterable?1:0)+1;let At=0;if(this._data.length){let Ht=-1,se=0;(this._slicedData||this._data).forEach((Se,Kt)=>{Se.rowType==="data"&&(kt++,Ht++);const fe=kt%2===0,ne=this.props.dataItemKey&&MCt(this.props.dataItemKey)(Se.dataItem),ce=Kt+(this.vs.realSkip||0),xe=ne||"ai"+ce,Wt=xe+"_1",qt=yt(Se,xe,Ht);if(At=ce+Mt+se,_t.push(_.createElement(hjt,{key:xe,dataItem:Se.dataItem,isAltRow:fe,isInEdit:qt.isInEdit,rowType:Se.rowType,isHidden:gt(Kt),onClick:Ee=>this.rowClick(Ee,Se),onDoubleClick:Ee=>this.rowDblClick(Ee,Se),selectedField:this.props.selectedField,rowHeight:this.props.rowHeight,render:this.props.rowRender,ariaRowIndex:At,absoluteRowIndex:ce,dataIndex:this.vs.scrollableVirtual&&!this.props.groupable?ce:Ht,isSelected:qt.isSelected},qt.row)),this.props.detail&&Se.rowType==="data"&&Se.expanded){const Ee=F.length-(this.props.expandField?1:0)-(this.props.group?this.props.group.length:0)||1;se++,At=ce+Mt+se,_t.push(_.createElement("tr",{key:Wt,className:Me("k-table-row",fe?"k-detail-row k-table-alt-row k-alt":"k-detail-row"),style:{visibility:gt(Kt)?"hidden":"",height:this.props.detailRowHeight},role:"row","aria-rowindex":At},this.props.group&&this.props.group.map((Ie,Pe)=>{var Yt;const st=(Yt=qt==null?void 0:qt.row[Pe])==null?void 0:Yt.props.style,Et=st?this.isRtl?{left:st.right,right:st.left}:{left:st.left,right:st.right}:{};return _.createElement(ZE,{id:"",dataIndex:Se.dataIndex,field:Ie.field,dataItem:Se.dataItem,key:Pe,style:Et,ariaColumnIndex:1+Pe,isSelected:!1,locked:this.props.lockGroups,isRtl:this.isRtl,cells:this.props.cells})}),this.props.expandField&&_.createElement(mjt,{id:Je.generateNavigatableId(`${Wt}-dhcell`,i)}),_.createElement(gjt,{onContextMenu:this.onContextMenu,dataItem:Se.dataItem,dataIndex:Se.dataIndex,colSpan:Ee,ariaColIndex:2+(this.props.group?this.props.group.length:0),detail:this.props.detail,id:Je.generateNavigatableId(`${Wt}-dcell`,i)})))}})}else bt=!0;const Ft=()=>{const Ht=this._header;return Ht&&Ht.table&&Ht.table.clientWidth},Bt=()=>_.createElement("div",{key:"no-records",className:"k-grid-norecords",style:{width:Ft()}},_.createElement("div",{className:"k-grid-norecords-template",[m5]:Je.generateNavigatableId("no-records",i)},M.length?M:_.createElement(oN,null))),Ut={size:this.props.size,onPageChange:this.pagerPageChange,total:n,dir:this.isRtl?"rtl":void 0,skip:this.vs.propsSkip||0,take:(this.props.take!==void 0?this.props.take:this.props.pageSize)||10,messagesMap:VWt,...vjt(this.props.pageable||{})},Xt=this.props.pager?_.createElement(this.props.pager,{...Ut}):_.createElement(CC,{className:"k-grid-pager",...Ut}),It=Ht=>this.props.sort&&this.props.sort.filter(se=>se.field===Ht).length>0,ae=(Ht,se)=>_.createElement("col",{key:se.toString(),width:Xv(Ht)}),$t=(r=this.props.cells)!=null&&r.footerCell||this._columns.some(Ht=>{var se;return!!(Ht.footerCell||(se=Ht.cells)!=null&&se.footerCell)})?_.createElement(ojt,{size:this.props.size,columnResize:this.columnResize,staticHeaders:this.props.scrollable!=="none",hasScrollbarWidth:!!this.getCachedScrollbarWidth(),ref:Ht=>this._footer=Ht,row:_.createElement(djt,{cells:this.props.cells,idPrefix:i,columns:this._columns,isRtl:this.isRtl,ariaRowIndex:At+1}),cols:F.map(ae)}):null,ue=_.createElement("colgroup",{ref:Ht=>{this.columnResize.colGroupMain=Ht}},F.map((Ht,se)=>_.createElement("col",{key:se.toString(),className:It(Ht.field)?"k-sorted":void 0,width:Xv(Ht)}))),Ot=this.dragLogic.reorderable||this.dragLogic.groupable;if(this.props.scrollable==="none")return _.createElement(z8.Provider,{value:this.contextStateRef.current},_.createElement("div",{id:this.props.id,style:this.props.style,className:Me("k-grid",{"k-grid-md":!this.props.size,[`k-grid-${Gr.sizeMap[this.props.size]||this.props.size}`]:this.props.size},this.props.className),ref:Ht=>{this._element=Ht},"aria-label":this.props.ariaLabel,onKeyDown:this.onKeyDown,onFocus:this.onFocus,...DE},z,H,_.createElement(NE,{selectable:this.props.selectable,onRelease:this.selectionRelease,childRef:Ht=>{this.tableElement=Ht,this.headTable=Ht}},_.createElement("table",{ref:Ht=>this.headTable=Ht,className:Me("k-table k-grid-table",{[`k-table-${Gr.sizeMap[this.props.size]||this.props.size}`]:this.props.size}),style:{userSelect:g}},ue,tt,_.createElement("tbody",{role:"rowgroup",className:"k-table-tbody",...TE},_t),$t)),bt&&Bt(),Ot&&_.createElement(_.Fragment,null,_.createElement(BE,{ref:this.dragLogic.refDropElementClue}),_.createElement(OE,{ref:this.dragLogic.refDragElementClue}))),I,this.props.pageable&&Xt);let we=this.props.style||{};return l&&(we.height||(we=Object.assign({},we,{height:"450px"}))),_.createElement(z8.Provider,{value:this.contextStateRef.current},_.createElement("div",{id:this.props.id,style:we,className:Me("k-grid",{"k-grid-md":!this.props.size,[`k-grid-${Gr.sizeMap[this.props.size]||this.props.size}`]:this.props.size,"k-grid-virtual":l},this.props.className),ref:Ht=>{this._element=Ht},"aria-label":this.props.ariaLabel,onKeyDown:this.onKeyDown,onFocus:this.onFocus,...DE},z,H,_.createElement("div",{className:"k-grid-aria-root",role:"grid","aria-colcount":F.length,"aria-rowcount":n,id:this._gridId,"aria-label":o.toLanguageString(Yy,xn[Yy])},tt,_.createElement("div",{className:"k-grid-container",role:"presentation"},_.createElement("div",{ref:this.containerRef,className:"k-grid-content k-virtual-content",onScroll:this.scrollHandler,role:"presentation"},_.createElement("div",{className:"k-grid-table-wrap",role:"presentation"},_.createElement(NE,{selectable:this.props.selectable,onRelease:this.selectionRelease,childRef:Ht=>{this.tableElement=Ht}},_.createElement("table",{ref:Ht=>this.tableElement=Ht,className:Me("k-table k-grid-table",{"k-table-md":!this.props.size,[`k-table-${Gr.sizeMap[this.props.size]||this.props.size}`]:this.props.size}),role:"presentation",style:{userSelect:g}},ue,_.createElement("tbody",{className:"k-table-tbody",ref:this.tableBodyRef,role:"rowgroup",...TE},_t))),bt&&Bt()),l&&_.createElement("div",{className:"k-height-container",role:"presentation"},_.createElement("div",{style:l?{height:this.vs.containerHeight+"px"}:{}})))),$t,Ot&&_.createElement(_.Fragment,null,_.createElement(BE,{ref:this.dragLogic.refDropElementClue}),_.createElement(OE,{ref:this.dragLogic.refDragElementClue})),this.showLicenseWatermark&&_.createElement(mb,null)),I,this.props.pageable&&Xt))}calculateMedia(){this.checkMatchMediaColumnsDifferece()||this.forceUpdate()}selectionChange(r){if(this.props.onSelectionChange){const{event:n,dataItem:i,dataIndex:o,columnIndex:a}=r,{mode:s,cell:l}=zy(this.props.selectable),h={...this.getArguments(n.syntheticEvent),dataItem:i,startColIndex:a,endColIndex:a,startRowIndex:o,endRowIndex:o,dataItems:this.getLeafDataItems(),altKey:!1,ctrlKey:!1,shiftKey:!1,metaKey:!1,mode:s,cell:l,isDrag:!1,componentId:this._gridId,selectedField:this.props.selectedField||""};this.props.onSelectionChange.call(void 0,h)}}raiseDataEvent(r,n,i,o,a){const s=this.props.onDataStateChange;if(r){const l={...this.getArguments(o),...n,targetEvent:a};r.call(void 0,l)}else s&&s.call(void 0,{...this.getArguments(o),targetEvent:a||{},dataState:{...this.getDataState(),...i}})}columnReorder(r,n,i){const o=this._columns[r],a=o.depth,s=f=>{do f++;while(fa);return f},l=this._columns.splice(r,s(r)-r);this._columns.splice(rf.declarationIndex>=0).forEach((f,g)=>f.orderIndex=g),this._columnsMutations++;const h=this._columns[r].locked&&this._columns[n].locked;xB(this._columnsMap,this._columns,h||this._shouldUpdateLeftRight),bB(this._columnsMap,this._columns,h||this._shouldUpdateLeftRight),this._resized&&(this._shouldUpdateLeftRight=!1,this._resized=!1);const p=this.columns;if(this.forceUpdate(),this.props.onColumnReorder){const f={target:this,columns:p,columnId:o.id,nativeEvent:i};this.props.onColumnReorder.call(void 0,f)}}groupReorder(r,n,i){if(this.props.group===void 0)return;const o=this.props.group.slice();o.splice(n,0,...o.splice(r,1)),this.groupChange(o,i)}columnToGroup(r,n,i){const o=this._columns[r].field;if(!o)return;const a=(this.props.group||[]).slice();a.splice(n,0,{field:o}),this.groupChange(a,i)}columnGroupChange(r,n){const i=this.dragLogic.getCurrentGroupsLength;this.columnToGroup(r,i,n)}resetTableWidth(){let r=0;if(!this.columnResize.colGroupMain)return;const n=this.columnResize.colGroupMain.children;for(let i=0;i{const a={rowIndex:this.rowIndex};o.forEach(s=>{s.isIntersecting||this.setCurrentOnTop(a)})},this.setCurrentOnTop=o=>{if(!this.vs.container||this.props.scrollable==="none")return;this.observer&&this.observer.disconnect();const{rowIndex:a}=o;if(this.props.scrollable==="virtual")this.vs.askedSkip=a,this.vs.container.scroll(0,Math.round(this.vs.askedSkip/this.vs.total*this.vs.container.scrollHeight));else if(this.element){const s=a<1?this.element.querySelector("tbody > tr:nth-child(1)"):this.element.querySelector(`tbody > tr:nth-child(${a+1})`);s&&this.containerRef.current&&(this.containerRef.current.scrollTop=s.offsetTop)}},this.scrollIntoView=o=>{if(!this.vs.container||this.props.scrollable==="none")return;this.rowIndex=o.rowIndex;const{rowIndex:a}=o,s=this.element;if(this.observer&&s){this.observer.disconnect();const l=s.querySelector(`[absolute-row-index="${a}"]`);l?this.observer.observe(l):this.setCurrentOnTop(o)}},this.fitColumns=o=>{this.columnResize.dblClickHandler(null,o)},this.getColumnsEssentialProps=o=>JSON.stringify(o.map(a=>({id:a.id,field:a.field,title:a.title,children:a.children}))),this.checkMatchMediaColumnsDifferece=()=>{const o=this.childrenToArray(this.props.children);return this.getColumnsEssentialProps(o)===this.getColumnsEssentialProps(this._columns)},this.onContextMenu=(o,a,s)=>{if(this.props.onContextMenu){const l={target:this,syntheticEvent:o,nativeEvent:o.nativeEvent,dataItem:a,field:s};this.props.onContextMenu.call(void 0,l)}},this.getVirtualScroll=o=>{const{rowHeight:a,detailRowHeight:s,detail:l,expandField:h,groupable:p}=o,f=this.isAllData(),g=a!==void 0&&a>0,b=s!==void 0&&s>0,z=p===!0||typeof p=="object"&&p.enabled!==!1;return!g||z&&!f||l&&h&&(!b||!f)?sjt:ZE},this.isAllData=()=>{const{data:o,total:a}=this.props;return Array.isArray(o)?o.length===a:o?a===o.total:!1},this.initializeVirtualization=(o,a)=>{if(this.reInitVirtualization(this.props.scrollable==="virtual",this.props.total,this.props.filter,this.props.group,this.props.sort,a||this.props.rowHeight===void 0||this.props.rowHeight===0),this.vs.fixedScroll=this.props.fixedScroll||!1,this.vs.PageChange=this.pageChange,this.vs.realSkip=this.props.skip||0,this.vs.pageSize=(this.props.take!==void 0?this.props.take:this.props.pageSize)||0,this.vs.scrollableVirtual=this.props.scrollable==="virtual",this.vs.total=o,this.vs.propsSkip=(this.props.skip||0)+(this.props.scrollable==="virtual"?this.vs.topCacheCount+(this.vs.attendedSkip-(this.props.skip||0)):0),this.props.rowHeight!==void 0&&this.props.rowHeight>0&&!a){const s=this.props.rowHeight*o;this.vs.containerHeight=Ry?Math.min(XE,s):s}else this.vs.containerHeight=1533915;if(this.vs.containerRef=this.containerRef,this.vs.tableBodyRef=this.tableBodyRef,this.vs.table=this.tableElement,this._slicedData=void 0,this.vs instanceof ZE){const{rowHeight:s=0,detail:l,expandField:h}=this.props;let{detailRowHeight:p=0}=this.props;p=l&&h?p:s,this.isAllData()?(this.vs.total=this._data.length,this._slicedData=this._data.slice(this.vs.realSkip,this.vs.realSkip+this.vs.pageSize),this.vs.rowHeightService=this.rowHeightService(this.vs,this._data.length,s,p,this._data)):this.vs.rowHeightService=new Fu(o,s,p);const f=this.vs.rowHeightService.totalHeight();this.vs.containerHeight=Ry?Math.min(XE,f):f}},this.getCachedScrollbarWidth=()=>(this._scrollbarWidth||(this._scrollbarWidth=qP()||void 0),this._scrollbarWidth),this.scrollHandler=o=>{if(o.target!==o.currentTarget)return;clearTimeout(this.forceUpdateTimeout),this.vs.table=this.tableElement;const a=o.currentTarget.scrollLeft,s=o.currentTarget.scrollTop;this.props.columnVirtualization&&(!this.vs.scrollableVirtual||s===this.wrapperScrollTop)&&(this.forceUpdateTimeout=window.setTimeout(()=>{this.forceUpdate()},0)),this._header&&this._header.setScrollLeft(a),this._footer&&this._footer.setScrollLeft(a),this.vs&&s!==this.wrapperScrollTop&&this.vs.scrollHandler(o),pn(this.props.onScroll,o,this,void 0),this.wrapperScrollTop=s},this.onKeyDown=o=>{if(w3.onKeyDown(o,{navigatable:this.props.navigatable||!1,contextStateRef:this.contextStateRef,navigationStateRef:this.navigationStateRef,onNavigationAction:this.onNavigationAction,columns:this.columns}),this.props.onKeyDown){const{mode:a,cell:s}=zy(this.props.selectable),l={dataItems:this.getLeafDataItems(),mode:a,cell:s,componentId:this._gridId,selectedField:this.props.selectedField,...this.getArguments(o)};this.props.onKeyDown.call(void 0,l)}},this.onFocus=o=>{w3.onFocus(o,{navigatable:!!this.props.navigatable,contextStateRef:this.contextStateRef})},this.onNavigationAction=o=>{if(o.action==="moveToNextPage"&&this.moveToNextPage(o.event),o.action==="moveToPrevPage"&&this.moveToPrevPage(o.event),o.focusElement&&o.action==="reorderToRight"){const a=parseInt(o.focusElement.ariaColIndex,10)-1;a0&&this.columnReorder(a,a-1,o.event)}if(this.props.onNavigationAction){const a={focusElement:o.focusElement,...this.getArguments(o.event)};this.props.onNavigationAction.call(void 0,a)}},this.rowClick=(o,a)=>{this.props.onRowClick&&o.target.nodeName==="TD"&&this.props.onRowClick.call(void 0,{dataItem:a.dataItem,...this.getArguments(o)})},this.rowDblClick=(o,a)=>{this.props.onRowDoubleClick&&o.target.nodeName==="TD"&&this.props.onRowDoubleClick.call(void 0,{dataItem:a.dataItem,...this.getArguments(o)})},this.itemChange=o=>{const a=this.props.onItemChange;if(o.field===this.props.expandField||this.props.group&&o.field===void 0){const s=this.props.onExpandChange;s&&s.call(void 0,{...this.getArguments(o.syntheticEvent),dataItem:o.dataItem,dataIndex:o.dataIndex,value:o.value});return}a&&a.call(void 0,{...this.getArguments(o.syntheticEvent),dataItem:o.dataItem,field:o.field,value:o.value})},this.onHeaderSelectionChange=o=>{this.props.onHeaderSelectionChange&&this.props.onHeaderSelectionChange.call(void 0,{field:o.field,nativeEvent:o.syntheticEvent&&o.syntheticEvent.nativeEvent,syntheticEvent:o.syntheticEvent,target:this,dataItems:this.getLeafDataItems(),selectedField:this.props.selectedField})},this.selectionRelease=o=>{if(this.props.onSelectionChange){const a=this.getSlicedLeafDataItems()[o.startRowIndex],s=this.getSlicedLeafDataItems()[o.endRowIndex],l={syntheticEvent:void 0,target:this,selectedField:this.props.selectedField||"",componentId:this._gridId,dataItems:this.getLeafDataItems(),dataItem:null,startDataItem:a,endDataItem:s,...o};this.props.onSelectionChange.call(void 0,l)}},this.pageChange=(o,a,s)=>{this.raiseDataEvent(this.props.onPageChange,{page:o},{skip:o.skip,take:o.take},a,s)},this.getTotal=()=>{let o=this.props.total||0;return Array.isArray(this.props.data)?o=o||this.props.data.length:this.props.data&&(o=o||this.props.data.total),o},this.moveToNextPage=o=>{const a=this.props.take||0,s=(this.props.skip||0)+a,l=this.getTotal();s{const a=this.props.take||0,s=(this.props.skip||0)-a;s>=0&&this.pageChange({skip:s,take:a},o)},this.pagerPageChange=o=>{this.pageChange({skip:o.skip,take:o.take},o.syntheticEvent,o.targetEvent)},this.sortChange=(o,a)=>{this.raiseDataEvent(this.props.onSortChange,{sort:o},{sort:o,...this.props.scrollable==="virtual"?{skip:0}:{}},a)},this.filterChange=(o,a)=>{this.raiseDataEvent(this.props.onFilterChange,{filter:o},{filter:o||void 0,skip:0},a)},this.groupChange=(o,a)=>{const s=a.nativeEvent?a:{nativeEvent:a.nativeEvent||a.originalEvent};o.length===0&&this.props.navigatable&&(this._focusFirst=!0),this._columnsMutations++,this.raiseDataEvent(this.props.onGroupChange,{group:o},{group:o,skip:0},s)},this.onClipboard=(o,a)=>{if(this.props.onClipboard){if(!this.inActiveElement()||!o)return;this.props.onClipboard.call(void 0,{type:o,nativeEvent:a,columns:this._columns,dataItemKey:this.props.dataItemKey||"",...typeof this.props.clipboard!="boolean"?this.props.clipboard:{}})}},this.inActiveElement=()=>{var o,a,s;if(!oi)return!1;const l=Yi(this.document),h=l?l.matches(".k-table-td")?l:(o=this.document)==null?void 0:o.body:(a=this.document)==null?void 0:a.body,p=h.closest(".k-grid-container"),f=h&&((s=this._element)==null?void 0:s.contains(h));return!!(h&&f&&p)},this.onResize=(o,a,s,l,h,p)=>{this.resetTableWidth(),this._shouldUpdateLeftRight=!0,this._resized=!0,this._columnsMutations++,this.props.onColumnResize&&this.props.onColumnResize.call(void 0,{columns:this.columns,nativeEvent:l,targetColumnId:p,index:o,newWidth:a,oldWidth:s,end:h,target:this})},this.reInitVirtualization=Sa((o,a,s,l,h,p)=>{this.vs.reset();const f=this.getVirtualScroll(this.props);this.vs=new f(p)}),this.flatData=Sa((o,a,s,l,h,p,f)=>{const g=[],b=UB(g,o,a,{index:s},l!==void 0,h);return{flattedData:g,resolvedGroupsCount:b}}),this.rowHeightService=Sa((o,a,s,l,h)=>new Fu(a,s,l,h)),this.childrenToArray=Sa(o=>_.Children.toArray(o)),this.readColumns=Sa((o,a,s)=>{const l=o.filter(h=>h&&h.type&&h.type.displayName==="KendoReactGridColumn");return YB(l,this.columns,{prevId:0,idPrefix:a})}),this.mapColumns=Sa((o,a)=>bNt(o,!0)),this.filterColumnsByMediaProp=o=>o.filter(a=>oi&&a&&a.media?window.matchMedia(a.media).matches:a),this.configureColumns=Sa((o,a,s)=>{this.props.selectedField&&o.filter(p=>p.field===this.props.selectedField).forEach(p=>{p.width=p.width||"50px",p.cell=p.cell||RWt,p.headerCell=p.headerCell||pjt});const l={id:"",resizable:!0,width:"32px",title:" ",declarationIndex:-1,orderIndex:-1,children:[],parentIndex:-1,depth:0,colSpan:0,rowSpan:0,left:0,right:0,index:0,rightBorder:!1,ariaColumnIndex:0,isAccessible:!0};let h=0;this.props.expandField&&this.props.onExpandChange&&this.props.detail&&(o.unshift({...l,cell:OWt,field:this.props.expandField,headerClassName:"k-hierarchy-cell k-header"}),h++);for(let p=0;pp.parentIndex>=0&&(p.parentIndex+=h))}),this.getHeaderRow=Sa((o,a,s,l,h,p,f,g,b,z,M,I,F)=>_.createElement(ZWt,{cells:this.props.cells,sort:o,sortable:a,sortChange:this.sortChange,group:s||[],groupable:l,groupChange:this.groupChange,filter:h,filterable:p,filterOperators:f,filterChange:this.filterChange,columnMenu:b,columnMenuIcon:z,selectionChange:this.onHeaderSelectionChange,columns:M,columnResize:this.columnResize,pressHandler:this.dragLogic.pressHandler,dragHandler:this.dragLogic.dragHandler,releaseHandler:this.dragLogic.releaseHandler,columnsMap:I,cellRender:g,isRtl:F,dragClue:this.dragLogic.dragClueRef,headerRef:this.headerElementRef,containerRef:this.containerRef,navigatable:!!this.props.navigatable,columnGroupChange:this.columnGroupChange})),this.resolveTitle=o=>{const a=this._columns.find(l=>l.field===o),s=a&&(a.title||a.field);return s===void 0?o:s},this.getLeafDataItems=()=>this._data.filter(o=>o.rowType==="data").map(o=>o.dataItem),this.getSlicedLeafDataItems=()=>(this._slicedData||this._data).filter(o=>o.rowType==="data").map(o=>o.dataItem),this.handleFocusInEditableRows=()=>{var o,a,s;if(this.tableBodyRef.current&&((o=this.tableBodyRef.current)==null?void 0:o.getElementsByClassName("k-grid-edit-row").length)>0){this._singleEditRow=!1,(a=document.activeElement)!=null&&a.closest(".k-grid-edit-row")?this._lastActiveElement=document.activeElement:this._lastActiveElement=void 0;const l=Array.from((s=this.tableBodyRef.current)==null?void 0:s.getElementsByClassName("k-grid-edit-row"));l.length>this.rowsInEdit.length?this._newEditableRow=l.filter(h=>!this.rowsInEdit.includes(h))[0]:l.length===1&&(this._newEditableRow=l[0],this._singleEditRow=!0),this.rowsInEdit=l}},vi(QE),this.showLicenseWatermark=mb(QE);const n=this.props.groupable===!0||typeof this.props.groupable=="object"&&this.props.groupable.enabled!==!1,i=this.getVirtualScroll(r);this.vs=new i(n||r.rowHeight===void 0||r.rowHeight===0),this.dragLogic=new cjt(this.columnReorder.bind(this),this.groupReorder.bind(this),this.columnToGroup.bind(this)),this.columnGroupChange=this.columnGroupChange.bind(this),this.columnResize=new ljt(this.onResize),this.props.clipboard&&(this.clipboardService=new LNt(this.onClipboard)),w3.onConstructor({navigatable:!!r.navigatable,contextStateRef:this.contextStateRef,navigationStateRef:this.navigationStateRef,idPrefix:this._gridId})}get columns(){const r=this._columns.filter(n=>n.declarationIndex>=0&&n.parentIndex===-1);return XB(r)}get element(){return this._element}get document(){if(oi)return this.element&&this.element.ownerDocument||document}get _header(){return this.headerRef.current}get _gridId(){return this.props.id+"-role-element-id"}componentDidMount(){var r;this.props.columnVirtualization&&!navigator.userAgent.match(NWt)&&(this.headTable&&(this.headTable.style.display="block"),this.tableElement&&(this.tableElement.style.display="block")),this.resetTableWidth(),Tu(this.getCachedScrollbarWidth());const n=CB(this.element);this.isRtl=n,w3.onComponentDidMount({scope:this.element||void 0,contextStateRef:this.contextStateRef,navigationStateRef:this.navigationStateRef}),this.isRtl&&this.forceUpdate();const i={rootMargin:"0px",threshold:.9};this.clipboardService&&this.clipboardService.addEventListeners(this.document),this.observer=oi&&window.IntersectionObserver&&new window.IntersectionObserver(this.handleIntersection,i)||null,this.resizeObserver=oi&&window.ResizeObserver&&new window.ResizeObserver(this.calculateMedia.bind(this)),(r=this.document)!=null&&r.body&&this.resizeObserver&&this.resizeObserver.observe(this.document.body)}getSnapshotBeforeUpdate(){return w3.onGetSnapshotBeforeUpdate({document:this.document,contextStateRef:this.contextStateRef,navigationStateRef:this.navigationStateRef}),null}componentDidUpdate(){this.resetTableWidth(),Tu(this.getCachedScrollbarWidth()),this.vs.tableTransform&&this.vs.table&&(this.vs.table.style.transform=this.vs.tableTransform,this.vs.tableTransform=""),this.handleFocusInEditableRows(),w3.onComponentDidUpdate({scope:this.element||void 0,contextStateRef:this.contextStateRef,navigationStateRef:this.navigationStateRef,focusFirst:this._focusFirst,newEditableRow:this._newEditableRow,singleEditRow:this._singleEditRow,lastActiveElement:this._lastActiveElement,navigatable:this.props.navigatable}),this._focusFirst=!1,this._newEditableRow=void 0}componentWillUnmount(){var r;clearTimeout(this.forceUpdateTimeout),this.clipboardService&&this.clipboardService.removeEventListeners(this.document),(r=this.document)!=null&&r.body&&this.resizeObserver&&this.resizeObserver.disconnect()}render(){var r;let n=this.props.total||0;const i=Je.getIdPrefix(this.navigationStateRef),o=ai(this);let a=[];Array.isArray(this.props.data)?(a=this.props.data,n=n||this.props.data.length):this.props.data&&(a=this.props.data.data,n=n||this.props.data.total);const s=typeof this.props.groupable=="object"&&this.props.groupable.footer||"none",l=this.props.scrollable==="virtual",{resolvedGroupsCount:h,flattedData:p}=this.flatData(a,s,this.props.skip||0,this.props.group,this.props.expandField,this.props.filter,this.props.sort);this._data=p;const f=this.props.groupable===!0||typeof this.props.groupable=="object"&&this.props.groupable.enabled!==!1;this.columnResize.resizable=this.props.resizable||!1,this.dragLogic.reorderable=this.props.reorderable||!1,this.dragLogic.groupable=f;const g=this.props.selectable&&this.props.selectable.drag?"none":void 0;this.initializeVirtualization(n,f);const b=this.childrenToArray(this.props.children);this.initColumns(b,h);const z=b.map(Ht=>Ht&&Ht.type&&Ht.type.displayName==="KendoReactGridToolbar"?_.cloneElement(Ht,{...Ht.props,ariaControls:this._gridId}):null),M=b.filter(Ht=>Ht&&Ht.type&&Ht.type.displayName==="KendoReactGridNoRecords"),I=b.filter(Ht=>Ht&&Ht.type&&Ht.type.displayName==="KendoReactGridStatusBar"),F=this._columns.filter(Ht=>Ht.children.length===0),H=f&&_.createElement(iN,{group:this.props.group||[],groupChange:this.groupChange,pressHandler:this.dragLogic.pressHandler,dragHandler:this.dragLogic.dragHandler,releaseHandler:this.dragLogic.releaseHandler,refCallback:this.dragLogic.refGroupPanelDiv,resolveTitle:this.resolveTitle,ariaControls:this._gridId,onContextMenu:this.onContextMenu}),{sort:E,sortable:R,group:W,filter:$,filterable:G,filterOperators:Z=KE,headerCellRender:K,columnMenu:et,columnMenuIcon:at}=this.props,tt=_.createElement(WWt,{size:this.props.size,columnResize:this.columnResize,staticHeaders:this.props.scrollable!=="none",scrollableDataElement:()=>this.vs.container,hasScrollbarWidth:!!this.getCachedScrollbarWidth(),draggable:this.props.reorderable||f,ref:this.headerRef,elemRef:this.headerElementRef,className:this.props.headerClassName,headerRow:this.getHeaderRow(E,R,W,f,$,G,Z,K,et,at,this._columns,this._columnsMap,this.isRtl),filterRow:this.props.filterable&&_.createElement(eN,{cells:this.props.cells,size:this.props.size,columns:this._columns,filter:this.props.filter,filterOperators:this.props.filterOperators||KE,filterChange:this.filterChange,sort:this.props.sort,cellRender:this.props.filterCellRender,isRtl:this.isRtl,navigatable:!!this.props.navigatable,ariaRowIndex:this._columnsMap.length+1})||void 0,cols:F.map((Ht,ce)=>_.createElement("col",{key:ce.toString(),width:Xv(Ht)}))}),ft=this.vs&&this.vs.container&&this.vs.container.scrollLeft||0,dt=parseFloat(((this.props.style||{}).width||"").toString()),{colSpans:ht,hiddenColumns:lt}=fWt({enabled:this.props.columnVirtualization,columns:F,tableViewPortWidth:dt,scrollLeft:ft}),yt=(Ht,ce,Se)=>{let qt=!1;const ge=this.props.selectedField?$a(this.props.selectedField,Ht.dataItem):void 0;return{row:F.map((oe,ue)=>{if(lt[ue])return null;const xe=oe.id?oe.id:ue,Nt=`${oe.className?oe.className+" ":""}${oe.locked?"k-grid-content-sticky":""}`,Jt=oe.left!==void 0?this.isRtl?{left:oe.right,right:oe.left}:{left:oe.left,right:oe.right}:{};let Ie=!1;if(oe.editable&&this.props.editField){const Xt=$a(this.props.editField,Ht.dataItem);Xt&&(Xt===!0||Xt===oe.field)&&(qt=!0,Ie=!0)}const He=oe.cell||Ie&&$Wt||hjt,Pe=this.props.expandField&&this.props.detail&&oe.field===this.props.expandField;return _.createElement(He,{onContextMenu:this.onContextMenu,key:xe,locked:this.props.lockGroups,id:Je.generateNavigatableId(`${ce}-${String(ue)}`,i,Pe||Ht.rowType==="groupHeader"||Ht.rowType==="groupFooter"||oe.field==="value"?"nodata":"cell"),colSpan:ht[ue],dataItem:Ht.dataItem,field:oe.field,editor:oe.editor,format:oe.format,className:Nt,render:this.props.cellRender,cells:cd(this.props.cells,oe.cells),onChange:this.itemChange,selectionChange:this.props.onSelectionChange?Xt=>{this.selectionChange({event:Xt,dataItem:Ht.dataItem,dataIndex:Se,columnIndex:ue})}:void 0,columnIndex:ue,columnsCount:F.length,rowType:Ht.rowType,level:Ht.level,expanded:Ht.expanded,dataIndex:Ht.dataIndex,style:Jt,ariaColumnIndex:oe.ariaColumnIndex,isSelected:Array.isArray(ge)&&ge.indexOf(ue)>-1})}),isInEdit:qt,isSelected:typeof ge=="boolean"&&ge}};let mt=0;if(l)for(let Ht=0;HtHt>=this._data.length-mt;let _t=this.vs.realSkip||0;const At=[];let bt=!1;const kt=this._columnsMap.length+(this.props.filterable?1:0)+1;let Lt=0;if(this._data.length){let Ht=-1,ce=0;(this._slicedData||this._data).forEach((Se,qt)=>{Se.rowType==="data"&&(_t++,Ht++);const ge=_t%2===0,oe=this.props.dataItemKey&&kCt(this.props.dataItemKey)(Se.dataItem),ue=qt+(this.vs.realSkip||0),xe=oe||"ai"+ue,Nt=xe+"_1",Jt=yt(Se,xe,Ht);if(Lt=ue+kt+ce,At.push(_.createElement(ujt,{key:xe,dataItem:Se.dataItem,isAltRow:ge,isInEdit:Jt.isInEdit,rowType:Se.rowType,isHidden:gt(qt),onClick:Ie=>this.rowClick(Ie,Se),onDoubleClick:Ie=>this.rowDblClick(Ie,Se),selectedField:this.props.selectedField,rowHeight:this.props.rowHeight,render:this.props.rowRender,ariaRowIndex:Lt,absoluteRowIndex:ue,dataIndex:this.vs.scrollableVirtual&&!this.props.groupable?ue:Ht,isSelected:Jt.isSelected},Jt.row)),this.props.detail&&Se.rowType==="data"&&Se.expanded){const Ie=F.length-(this.props.expandField?1:0)-(this.props.group?this.props.group.length:0)||1;ce++,Lt=ue+kt+ce,At.push(_.createElement("tr",{key:Nt,className:ke("k-table-row",ge?"k-detail-row k-table-alt-row k-alt":"k-detail-row"),style:{visibility:gt(qt)?"hidden":"",height:this.props.detailRowHeight},role:"row","aria-rowindex":Lt},this.props.group&&this.props.group.map((He,Pe)=>{var Xt;const st=(Xt=Jt==null?void 0:Jt.row[Pe])==null?void 0:Xt.props.style,Mt=st?this.isRtl?{left:st.right,right:st.left}:{left:st.left,right:st.right}:{};return _.createElement(JE,{id:"",dataIndex:Se.dataIndex,field:He.field,dataItem:Se.dataItem,key:Pe,style:Mt,ariaColumnIndex:1+Pe,isSelected:!1,locked:this.props.lockGroups,isRtl:this.isRtl,cells:this.props.cells})}),this.props.expandField&&_.createElement(yjt,{id:Je.generateNavigatableId(`${Nt}-dhcell`,i)}),_.createElement(mjt,{onContextMenu:this.onContextMenu,dataItem:Se.dataItem,dataIndex:Se.dataIndex,colSpan:Ie,ariaColIndex:2+(this.props.group?this.props.group.length:0),detail:this.props.detail,id:Je.generateNavigatableId(`${Nt}-dcell`,i)})))}})}else bt=!0;const Vt=()=>{const Ht=this._header;return Ht&&Ht.table&&Ht.table.clientWidth},Rt=()=>_.createElement("div",{key:"no-records",className:"k-grid-norecords",style:{width:Vt()}},_.createElement("div",{className:"k-grid-norecords-template",[m5]:Je.generateNavigatableId("no-records",i)},M.length?M:_.createElement(aN,null))),Ut={size:this.props.size,onPageChange:this.pagerPageChange,total:n,dir:this.isRtl?"rtl":void 0,skip:this.vs.propsSkip||0,take:(this.props.take!==void 0?this.props.take:this.props.pageSize)||10,messagesMap:FWt,...gjt(this.props.pageable||{})},Kt=this.props.pager?_.createElement(this.props.pager,{...Ut}):_.createElement(SC,{className:"k-grid-pager",...Ut}),It=Ht=>this.props.sort&&this.props.sort.filter(ce=>ce.field===Ht).length>0,le=(Ht,ce)=>_.createElement("col",{key:ce.toString(),width:Xv(Ht)}),Bt=(r=this.props.cells)!=null&&r.footerCell||this._columns.some(Ht=>{var ce;return!!(Ht.footerCell||(ce=Ht.cells)!=null&&ce.footerCell)})?_.createElement(ajt,{size:this.props.size,columnResize:this.columnResize,staticHeaders:this.props.scrollable!=="none",hasScrollbarWidth:!!this.getCachedScrollbarWidth(),ref:Ht=>this._footer=Ht,row:_.createElement(fjt,{cells:this.props.cells,idPrefix:i,columns:this._columns,isRtl:this.isRtl,ariaRowIndex:Lt+1}),cols:F.map(le)}):null,de=_.createElement("colgroup",{ref:Ht=>{this.columnResize.colGroupMain=Ht}},F.map((Ht,ce)=>_.createElement("col",{key:ce.toString(),className:It(Ht.field)?"k-sorted":void 0,width:Xv(Ht)}))),Ft=this.dragLogic.reorderable||this.dragLogic.groupable;if(this.props.scrollable==="none")return _.createElement(z8.Provider,{value:this.contextStateRef.current},_.createElement("div",{id:this.props.id,style:this.props.style,className:ke("k-grid",{"k-grid-md":!this.props.size,[`k-grid-${Wr.sizeMap[this.props.size]||this.props.size}`]:this.props.size},this.props.className),ref:Ht=>{this._element=Ht},"aria-label":this.props.ariaLabel,onKeyDown:this.onKeyDown,onFocus:this.onFocus,...PE},z,H,_.createElement($E,{selectable:this.props.selectable,onRelease:this.selectionRelease,childRef:Ht=>{this.tableElement=Ht,this.headTable=Ht}},_.createElement("table",{ref:Ht=>this.headTable=Ht,className:ke("k-table k-grid-table",{[`k-table-${Wr.sizeMap[this.props.size]||this.props.size}`]:this.props.size}),style:{userSelect:g}},de,tt,_.createElement("tbody",{role:"rowgroup",className:"k-table-tbody",...VE},At),Bt)),bt&&Rt(),Ft&&_.createElement(_.Fragment,null,_.createElement(NE,{ref:this.dragLogic.refDropElementClue}),_.createElement(BE,{ref:this.dragLogic.refDragElementClue}))),I,this.props.pageable&&Kt);let we=this.props.style||{};return l&&(we.height||(we=Object.assign({},we,{height:"450px"}))),_.createElement(z8.Provider,{value:this.contextStateRef.current},_.createElement("div",{id:this.props.id,style:we,className:ke("k-grid",{"k-grid-md":!this.props.size,[`k-grid-${Wr.sizeMap[this.props.size]||this.props.size}`]:this.props.size,"k-grid-virtual":l},this.props.className),ref:Ht=>{this._element=Ht},"aria-label":this.props.ariaLabel,onKeyDown:this.onKeyDown,onFocus:this.onFocus,...PE},z,H,_.createElement("div",{className:"k-grid-aria-root",role:"grid","aria-colcount":F.length,"aria-rowcount":n,id:this._gridId,"aria-label":o.toLanguageString(Yy,mn[Yy])},tt,_.createElement("div",{className:"k-grid-container",role:"presentation"},_.createElement("div",{ref:this.containerRef,className:"k-grid-content k-virtual-content",onScroll:this.scrollHandler,role:"presentation"},_.createElement("div",{className:"k-grid-table-wrap",role:"presentation"},_.createElement($E,{selectable:this.props.selectable,onRelease:this.selectionRelease,childRef:Ht=>{this.tableElement=Ht}},_.createElement("table",{ref:Ht=>this.tableElement=Ht,className:ke("k-table k-grid-table",{"k-table-md":!this.props.size,[`k-table-${Wr.sizeMap[this.props.size]||this.props.size}`]:this.props.size}),role:"presentation",style:{userSelect:g}},de,_.createElement("tbody",{className:"k-table-tbody",ref:this.tableBodyRef,role:"rowgroup",...VE},At))),bt&&Rt()),l&&_.createElement("div",{className:"k-height-container",role:"presentation"},_.createElement("div",{style:l?{height:this.vs.containerHeight+"px"}:{}})))),Bt,Ft&&_.createElement(_.Fragment,null,_.createElement(NE,{ref:this.dragLogic.refDropElementClue}),_.createElement(BE,{ref:this.dragLogic.refDragElementClue})),this.showLicenseWatermark&&_.createElement(yb,null)),I,this.props.pageable&&Kt))}calculateMedia(){this.checkMatchMediaColumnsDifferece()||this.forceUpdate()}selectionChange(r){if(this.props.onSelectionChange){const{event:n,dataItem:i,dataIndex:o,columnIndex:a}=r,{mode:s,cell:l}=zy(this.props.selectable),h={...this.getArguments(n.syntheticEvent),dataItem:i,startColIndex:a,endColIndex:a,startRowIndex:o,endRowIndex:o,dataItems:this.getLeafDataItems(),altKey:!1,ctrlKey:!1,shiftKey:!1,metaKey:!1,mode:s,cell:l,isDrag:!1,componentId:this._gridId,selectedField:this.props.selectedField||""};this.props.onSelectionChange.call(void 0,h)}}raiseDataEvent(r,n,i,o,a){const s=this.props.onDataStateChange;if(r){const l={...this.getArguments(o),...n,targetEvent:a};r.call(void 0,l)}else s&&s.call(void 0,{...this.getArguments(o),targetEvent:a||{},dataState:{...this.getDataState(),...i}})}columnReorder(r,n,i){const o=this._columns[r],a=o.depth,s=f=>{do f++;while(fa);return f},l=this._columns.splice(r,s(r)-r);this._columns.splice(rf.declarationIndex>=0).forEach((f,g)=>f.orderIndex=g),this._columnsMutations++;const h=this._columns[r].locked&&this._columns[n].locked;bB(this._columnsMap,this._columns,h||this._shouldUpdateLeftRight),wB(this._columnsMap,this._columns,h||this._shouldUpdateLeftRight),this._resized&&(this._shouldUpdateLeftRight=!1,this._resized=!1);const p=this.columns;if(this.forceUpdate(),this.props.onColumnReorder){const f={target:this,columns:p,columnId:o.id,nativeEvent:i};this.props.onColumnReorder.call(void 0,f)}}groupReorder(r,n,i){if(this.props.group===void 0)return;const o=this.props.group.slice();o.splice(n,0,...o.splice(r,1)),this.groupChange(o,i)}columnToGroup(r,n,i){const o=this._columns[r].field;if(!o)return;const a=(this.props.group||[]).slice();a.splice(n,0,{field:o}),this.groupChange(a,i)}columnGroupChange(r,n){const i=this.dragLogic.getCurrentGroupsLength;this.columnToGroup(r,i,n)}resetTableWidth(){let r=0;if(!this.columnResize.colGroupMain)return;const n=this.columnResize.colGroupMain.children;for(let i=0;i{const r={};return t.forEach(n=>{r[n[0]]=n[1]}),r},yjt=({data:t})=>{const{ColTitles:r,Values:n,Posn:i,Options:o}=t==null?void 0:t.Properties,a=n.map(R=>{let W={};return r.forEach(($,G)=>W[$]=R[G]),W}),s={logic:"and",filters:[]},[l,h]=_.useState(s),p=[],[f,g]=_.useState(p),b=QE(o.columnTypes),z=QE(o.filterableCols),M=o.sortableCols,E={Image:R=>R.dataItem[R.field]?vt.jsx("td",{children:vt.jsx("img",{src:Qi()+R.dataItem[R.field]})}):vt.jsx("td",{}),Button:R=>vt.jsx("td",{children:vt.jsx(ei,{onClick:()=>alert(R.dataItem[R.field]),children:R.dataItem[R.field]})}),Video:R=>{const W=R.dataItem[R.field];return W?vt.jsx("td",{children:vt.jsx("video",{controls:!0,children:vt.jsx("source",{src:Qi()+W,type:"video/mp4"})})}):vt.jsx("td",{})}};return vt.jsx("div",{style:{position:"absolute",top:i&&i[0],left:i&&i[1]},children:vt.jsx(sN,{data:mRt(gRt(a,l),f),navigatable:!0,filterable:o.filterable==1,filter:l,onFilterChange:R=>h(R.filter),sortable:o.sortable==1?{allowUnsort:!0,mode:"multiple"}:void 0,sort:f,onSortChange:R=>g(R.sort),children:r.map((R,W)=>vt.jsx(HC,{field:R,title:R,cells:{data:E[b[R]]},filterable:z.hasOwnProperty(R),filter:z[R]===""?void 0:z[R],sortable:M.includes(R)}))})})};function lN(t){return C({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M5.22 8.22a.749.749 0 0 0 0 1.06l6.25 6.25a.749.749 0 0 0 1.06 0l6.25-6.25a.749.749 0 1 0-1.06-1.06L12 13.939 6.28 8.22a.749.749 0 0 0-1.06 0Z"}}]})(t)}function xjt(t){return C({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M18.78 15.78a.749.749 0 0 1-1.06 0L12 10.061 6.28 15.78a.749.749 0 1 1-1.06-1.06l6.25-6.25a.749.749 0 0 1 1.06 0l6.25 6.25a.749.749 0 0 1 0 1.06Z"}}]})(t)}const bjt=({data:t,startIndex:r,menuLength:n,handleSelectEvent:i,fontProperties:o})=>{const{findDesiredData:a,fontScale:s}=w1(),{Caption:l,Event:h,ImageIndex:p,ImageListObj:f}=t.Properties,g=a(f);let b=null,z=null;if(g){const{Files:M,Size:I}=g.Properties;b=Qi()+M[p-1],z=I}return vt.jsxs("div",{className:"custom-dropdown-item d-flex gap-1",style:{padding:"8px 16px",cursor:"pointer",borderBottom:ri(t.ID,h),children:[b&&vt.jsx("img",{src:b,style:{width:z[0],height:z[1]}}),vt.jsx("div",{style:{fontFamily:o==null?void 0:o.PName,fontSize:o!=null&&o.Size?`${o.Size*s}px`:`${12*s}px`},children:l})]},r)},wjt=({data:t})=>{var G,Z,K,et,at;const r=t.ImageList,{socket:n,findCurrentData:i,fontScale:o}=w1(),a=i(t.FontObj&&t.FontObj),s=a&&(a==null?void 0:a.Properties),{Icon:l,Caption:h,ImageIndex:p,CSS:f,ImageListObj:g}=t==null?void 0:t.Properties,b=j1(f),[z,M]=_.useState(!1),I=_.useRef(null),F=i(g),H=gD(F,p),E=(tt,ft)=>{const dt=JSON.stringify({Event:{EventName:"Select",ID:tt}});ft&&ft.some(lt=>lt[0]==="Select")&&(console.log(dt),n.send(dt),M(!1))},R=c0[l]?c0[l]:ib,W=Object.keys(t).filter(tt=>tt.startsWith("MItem")).map(tt=>t[tt]);_.useEffect(()=>{const tt=ft=>{I.current&&!I.current.contains(ft.target)&&M(!1)};return document.addEventListener("mousedown",tt),()=>{document.removeEventListener("mousedown",tt)}},[]);const $=tt=>{tt.stopPropagation(),M(ft=>!ft)};return vt.jsx("div",{ref:I,children:vt.jsx(Jx,{children:vt.jsxs(ip,{md:12,children:[vt.jsxs("div",{id:t==null?void 0:t.ID,className:"d-flex align-items-center flex-column justify-content-center",style:{cursor:"pointer",...b},onClick:tt=>{tt.stopPropagation(),$(tt)},children:[H?vt.jsx("img",{style:{width:H.imageSize[1],height:H.imageSize[0]},src:`${Qi()}${H.imageUrl}`,alt:"Image"}):p?vt.jsx("img",{style:{width:((G=r==null?void 0:r.Properties)==null?void 0:G.Size)&&((Z=r==null?void 0:r.Properties)==null?void 0:Z.Size[1]),height:((K=r==null?void 0:r.Properties)==null?void 0:K.Size)&&((et=r==null?void 0:r.Properties)==null?void 0:et.Size[0])},src:`${Qi()}${(at=r==null?void 0:r.Properties)==null?void 0:at.Files[p-1]}`,alt:"Image"}):vt.jsx(R,{size:35}),vt.jsx("div",{className:"text-center",style:{fontFamily:s==null?void 0:s.PName,fontSize:s!=null&&s.Size?`${s.Size*o}px`:`${12*o}px`},children:h}),vt.jsx(lN,{size:s!=null&&s.Size?`${s.Size*o}`:`${12*o}`})]}),z&&vt.jsx("div",{className:"custom-dropdown-menu",style:{position:"absolute",background:"#fff",borderRadius:"5px",boxShadow:"0 2px 10px rgba(0, 0, 0, 0.1)",marginTop:"5px",zIndex:1e3},children:W.map((tt,ft)=>vt.jsx(bjt,{data:tt,handleSelectEvent:E,menuLength:W.length,startIndex:ft,fontProperties:s},ft))})]})})})};function Cjt(t){return C({tag:"svg",attr:{fill:"currentColor",viewBox:"0 0 16 16"},child:[{tag:"path",attr:{fillRule:"evenodd",d:"M1 3.5a.5.5 0 0 1 .5-.5h13a.5.5 0 0 1 0 1h-13a.5.5 0 0 1-.5-.5zM8 6a.5.5 0 0 1 .5.5v5.793l2.146-2.147a.5.5 0 0 1 .708.708l-3 3a.5.5 0 0 1-.708 0l-3-3a.5.5 0 0 1 .708-.708L7.5 12.293V6.5A.5.5 0 0 1 8 6z"}}]})(t)}const tI=({data:t,startIndex:r,handleSelectEvent:n,className:i,ItemHeight:o,ItemWidth:a,fontProperties:s})=>{const{findDesiredData:l,fontScale:h}=w1(),{Caption:p,Event:f,ImageIndex:g,ImageListObj:b}=t.Properties,z=l(b);let M=null,I=null;if(z){const{Files:F,Size:H}=z.Properties;M=Qi()+F[g-1],I=H}return vt.jsx("div",{className:i,onClick:()=>n(t.ID,f),style:{minWidth:"max-content"},id:"gallery-Item",title:p,children:vt.jsxs("div",{className:"item-preview",style:{minWidth:"max-content",width:a+"px",height:o+"px"},children:[M&&vt.jsx("img",{src:M,style:{width:I[0],height:I[1]}}),vt.jsx("div",{style:{fontFamily:s==null?void 0:s.PName,fontSize:s!=null&&s.Size?`${s.Size*h}px`:`${12*h}px`},children:p})]})},r)},Sjt=({data:t})=>{const{socket:r,findCurrentData:n}=w1(),{Cols:i,ItemHeight:o,ItemWidth:a}=t.Properties,[s,l]=_.useState(0),[h,p]=_.useState(!1),f=_.useRef(null),g=_.useRef(null),[b,z]=_.useState(0),M=n(t.FontObj&&t.FontObj),I=M&&(M==null?void 0:M.Properties),F=Object.keys(t).filter(ht=>ht.startsWith("MItem")).map(ht=>t[ht]),H=F.length,E=H%i,W=H-(E===0?i:E),$=()=>{l(ht=>Math.max(ht-i,0))},G=()=>{l(ht=>Math.min(ht+i,W))},Z=()=>{p(ht=>!ht)},K=(ht,lt)=>{const yt=JSON.stringify({Event:{EventName:"Select",ID:ht}});lt&<.some(gt=>gt[0]==="Select")&&(console.log(yt),r.send(yt),p(!1))};_.useEffect(()=>{setTimeout(()=>{if(g.current){const lt=g.current.children;let yt=0;console.log("Child elements for maxWidth calculation:",lt),Array.from(lt).forEach((mt,gt)=>{const kt=mt.getBoundingClientRect().width;console.log(`Child ${gt} width:`,kt),yt=Math.max(yt,kt)}),console.log("Calculated widest width:",yt),z(yt)}},100)},[F]),_.useEffect(()=>{const ht=lt=>{h&&f.current&&!f.current.contains(lt.target)&&p(!1)};return document.addEventListener("mousedown",ht),()=>{document.removeEventListener("mousedown",ht)}},[h]);const et=F.slice(s,s+i),at=s===0,tt=s>=W,ft=b||a||50,dt=o||40;return console.log("Final maxWidth value:",b,b*i+i*5+22),vt.jsxs("div",{className:"ribbon-gallery",ref:f,style:{minWidth:"max-content",width:b*i+i*5+22,height:`${dt+8}px`,justifyContent:"start",margin:"5px"},children:[!h&&vt.jsxs("div",{className:"d-flex",style:{justifyContent:`${et.lengthvt.jsx(tI,{data:ht,className:"",startIndex:lt+s,handleSelectEvent:K,ItemWidth:b,ItemHeight:dt-2,fontProperties:I},lt))}),vt.jsxs("div",{className:"gallery-buttons",style:{position:"absolute",right:0},children:[vt.jsx("button",{className:"gallery-button",onClick:$,disabled:at,title:"Scroll Left",children:vt.jsx(xjt,{size:12})}),vt.jsx("button",{className:"gallery-button",onClick:G,disabled:tt,title:"Scroll Right",children:vt.jsx(lN,{size:12})}),vt.jsx("button",{className:"gallery-button",onClick:Z,title:"More Styles",children:vt.jsx(Cjt,{size:12})})]})]}),h&&vt.jsx(vt.Fragment,{children:vt.jsx("div",{className:"dropdown-content",style:{width:`${ft*i}px`,height:`${dt}px`},children:vt.jsx("div",{className:"dropdown-grid",style:{display:"grid",gridTemplateColumns:`repeat(${i}, 1fr)`,gap:"4px"},children:F.map((ht,lt)=>vt.jsx(tI,{data:ht,handleSelectEvent:K,startIndex:lt,className:"ribbon-dropdown-item",ItemWidth:ft,ItemHeight:dt},lt))})})})]})},E4=({data:t,inputValue:r="",event:n="",row:i="",column:o="",location:a,inSplitter:s=null,values:l=[],formatString:h="",activeTab:p=null,bgColor:f=null,fontColor:g=null,activebgColor:b=null,handleTabClick:z=()=>{}})=>{var I,F,H,E,R,W,$,G,Z,K,et,at,tt,ft,dt,ht,lt,yt,mt,gt,kt,_t,bt,Mt,At,Ft,Bt,Ut,Xt,It,ae,$t,ue,Ot,we,Ht,se,Se,Kt,fe,ne,ce,xe,Wt;const{dataRef:M}=w1();if(((I=t==null?void 0:t.Properties)==null?void 0:I.Type)=="Form")return vt.jsx(zjt,{data:t});if(((F=t==null?void 0:t.Properties)==null?void 0:F.Type)=="MenuBar")return vt.jsx("div",{style:{top:0,left:0,position:"absolute",width:"100%"},children:vt.jsx(Pq,{data:t})});if(((H=t==null?void 0:t.Properties)==null?void 0:H.Type)=="Menu")return vt.jsx(Fq,{data:t});if(((E=t==null?void 0:t.Properties)==null?void 0:E.Type)=="Grid")return vt.jsx(gZ,{data:t});if(((R=t==null?void 0:t.Properties)==null?void 0:R.Type)=="Edit"&&((W=t==null?void 0:t.Properties)==null?void 0:W.Style)!=="Multi")return vt.jsx("div",{style:a=="inGrid"?{display:"flex",justifyContent:(($=t==null?void 0:t.Properties)==null?void 0:$.FieldType)=="Numeric"||((G=t==null?void 0:t.Properties)==null?void 0:G.FieldType)=="LongNumeric"?"end":"start"}:null,children:vt.jsx(mZ,{values:l,location:a,data:t,value:r,event:n,row:i,column:o,formatString:h})});if(((Z=t==null?void 0:t.Properties)==null?void 0:Z.Type)=="Button")return vt.jsx(yZ,{data:t,location:a,inputValue:r,event:n,row:i,column:o,values:l});if(((K=t==null?void 0:t.Properties)==null?void 0:K.Type)=="Combo")return vt.jsx(xZ,{data:t,location:a,value:r,event:n,row:i,column:o,values:l});if(((et=t==null?void 0:t.Properties)==null?void 0:et.Type)=="Label")return vt.jsx(bZ,{location:a,gridValue:r,data:t});if(((at=t==null?void 0:t.Properties)==null?void 0:at.Type)=="TreeView")return vt.jsx(kQ,{data:t});if(((tt=t==null?void 0:t.Properties)==null?void 0:tt.Type)=="List")return vt.jsx(_Q,{data:t});if(((ft=t==null?void 0:t.Properties)==null?void 0:ft.Type)=="Splitter")return vt.jsx(EQ,{data:t});if(((dt=t==null?void 0:t.Properties)==null?void 0:dt.Type)=="Group")return vt.jsx(IQ,{data:t});if(((ht=t==null?void 0:t.Properties)==null?void 0:ht.Type)=="Scroll")return vt.jsx(Ext,{data:t});if(((lt=t==null?void 0:t.Properties)==null?void 0:lt.Type)=="TabControl")return vt.jsx(Ixt,{data:t});if(((yt=t==null?void 0:t.Properties)==null?void 0:yt.Type)=="TabButton")return vt.jsx(pP,{activeTab:p,handleTabClick:z,data:t,bgColor:f,fontColor:g,activebgColor:b});if(((mt=t==null?void 0:t.Properties)==null?void 0:mt.Type)=="Edit"&&((gt=t==null?void 0:t.Properties)==null?void 0:gt.Style)=="Multi")return vt.jsx(Hxt,{data:t});if(((kt=t==null?void 0:t.Properties)==null?void 0:kt.Type)=="Ribbon")return vt.jsx(Dxt,{data:t});if(((_t=t==null?void 0:t.Properties)==null?void 0:_t.Type)=="RibbonGroup")return vt.jsx(Pxt,{data:t});if(((bt=t==null?void 0:t.Properties)==null?void 0:bt.Type)=="RibbonGroupItem")return vt.jsx(Txt,{data:t});if(((Mt=t==null?void 0:t.Properties)==null?void 0:Mt.Type)=="RibbonButton")return vt.jsx(_bt,{data:t});if(((At=t==null?void 0:t.Properties)==null?void 0:At.Type)=="RibbonButtonGroup")return vt.jsx(Abt,{data:t});if(((Ft=t==null?void 0:t.Properties)==null?void 0:Ft.Type)=="RibbonDropDownButton")return vt.jsx(wjt,{data:t});if(((Bt=t==null?void 0:t.Properties)==null?void 0:Bt.Type)=="RibbonGallery")return vt.jsx(Sjt,{data:t});if(((Ut=t==null?void 0:t.Properties)==null?void 0:Ut.Type)=="Poly")return vt.jsx(Lbt,{data:t});if(((Xt=t==null?void 0:t.Properties)==null?void 0:Xt.Type)=="Rect")return vt.jsx(JVt,{data:t});if(((It=t==null?void 0:t.Properties)==null?void 0:It.Type)=="SubForm")return vt.jsx(uP,{data:t});if(((ae=t==null?void 0:t.Properties)==null?void 0:ae.Type)=="Text"){const qt=JSON.parse(Ui(M==null?void 0:M.current,($t=t==null?void 0:t.Properties)==null?void 0:$t.FontObj));return vt.jsx(gC,{data:t,fontProperties:qt==null?void 0:qt.Properties})}if(((ue=t==null?void 0:t.Properties)==null?void 0:ue.Type)=="Timer")return vt.jsx(nFt,{data:t});if(((Ot=t==null?void 0:t.Properties)==null?void 0:Ot.Type)=="ListView")return vt.jsx(oFt,{data:t});if(((we=t==null?void 0:t.Properties)==null?void 0:we.Type)=="Image")return vt.jsx(aFt,{data:t});if(((Ht=t==null?void 0:t.Properties)==null?void 0:Ht.Type)=="Ellipse")return vt.jsx(QVt,{data:t});if(((se=t==null?void 0:t.Properties)==null?void 0:se.Type)=="Circle")return vt.jsx(tFt,{data:t});if(((Se=t==null?void 0:t.Properties)==null?void 0:Se.Type)=="ApexChart")return vt.jsx(yFt,{data:t});if(((Kt=t==null?void 0:t.Properties)==null?void 0:Kt.Type)=="MsgBox")return vt.jsx(BO,{data:t});if(((fe=t==null?void 0:t.Properties)==null?void 0:fe.Type)=="KendoChart")return vt.jsx(MFt,{data:t});if(((ne=t==null?void 0:t.Properties)==null?void 0:ne.Type)=="KendoGrid")return vt.jsx(yjt,{data:t});if(((ce=t==null?void 0:t.Properties)==null?void 0:ce.Type)=="Link")return vt.jsx(CFt,{data:t});if(((xe=t==null?void 0:t.Properties)==null?void 0:xe.Type)=="Upload")return vt.jsx(n0,{data:t});console.log("UNKNOWN: "+((Wt=t==null?void 0:t.Properties)==null?void 0:Wt.Type))},zjt=({data:t})=>{Tq();const{findDesiredData:r,socket:n,isDesktop:i}=w1();console.log("Desktop is as",!i);const[o,a]=_.useState({}),s=y4(document.getElementById(t==null?void 0:t.ID)),{BCol:l,Picture:h,Size:p,Visible:f,Posn:g,Flex:b=0,Event:z,CSS:M}=t==null?void 0:t.Properties;console.log("Dtaa is as",t,g);const I=j1(M);console.log("form after parsing",{styles:I,CSS:M,Flex:b});const F=ra(t),H=r(h&&h[0]);let E=$9(h&&h[1],H);const R=()=>{const $=JSON.stringify({Event:{EventName:"Configure",ID:t==null?void 0:t.ID,Info:[g&&g[0],g&&g[1],p&&p[0],p&&p[1]]}}),G=z&&z.some(Z=>Z[0]==="Configure");console.log("Event is as in Form",$),G&&n.send($)},W=()=>{console.log("Coming here in devive capabilities");let $=Math.round(window.devicePixelRatio*100),G=JSON.stringify({DeviceCapabilities:{ViewPort:[window.innerHeight,window.innerWidth],ScreenSize:[window.screen.height,window.screen.width],DPR:$/100,PPI:200}});console.log("Event sent is as",G),n.send(G)};return _.useEffect(()=>{localStorage.setItem("current-focus",t.ID)},[]),_.useEffect(()=>{var K;const $=(K=t==null?void 0:t.Properties)==null?void 0:K.hasOwnProperty("Size"),G=Math.round(window.innerWidth/2),Z=Math.round(window.innerHeight/2);localStorage.setItem("formDimension",JSON.stringify($?p:[Z,G])),localStorage.setItem("formPositions",JSON.stringify([g&&g[0],g&&g[1]])),localStorage.setItem(t==null?void 0:t.ID,JSON.stringify({Size:$?p:[Z,G],Posn:g})),a(Yr({...t==null?void 0:t.Properties,...$?{Size:p}:{Size:[Z,G]}},"relative",b))},[t]),_.useEffect(()=>{R(),W()},[s]),vt.jsx("div",{onMouseDown:$=>{er($,n,z,t==null?void 0:t.ID)},onMouseUp:$=>{rr($,n,z,t==null?void 0:t.ID)},onMouseEnter:$=>{ir($,n,z,t==null?void 0:t.ID)},onMouseMove:$=>{or($,n,z,t==null?void 0:t.ID)},onMouseLeave:$=>{nr($,n,z,t==null?void 0:t.ID)},onWheel:$=>{hr($,n,z,t==null?void 0:t.ID)},onDoubleClick:$=>{mr($,n,z,t==null?void 0:t.ID)},id:t==null?void 0:t.ID,style:{...o,...I,background:l?Hr(l):"#F0F0F0",position:"relative",border:"1px solid #F0F0F0",display:f==0?"none":t!=null&&t.Properties.hasOwnProperty("Flex")?"flex":"block",...E},onKeyDown:$=>{},children:Object.keys(F).map(($,G)=>vt.jsx(E4,{data:F[$]},G))})};const Mjt="0.2.3",kjt="EWC Client",eI={version:Mjt,name:kjt};function _jt(){const[t,r]=_.useState(!0);return{reRender:()=>{r(i=>!i)}}}const Ajt=()=>{var bt,Mt,At,Ft,Bt,Ut,Xt;const[t,r]=_.useState([]),[n,i]=_.useState(null),[o,a]=_.useState(!1),[s,l]=_.useState([]),[h,p]=_.useState([]),[f,g]=_.useState("Initialise"),b=_.useRef(null),[z,M]=_.useState(null),{reRender:I}=_jt(),[F,H]=_.useState(null),[E,R]=_.useState(null),[W,$]=_.useState(null);let G={};const Z=_.useRef({curEvent:"",eventID:"",keyEvent:""}),K=It=>{Z.current={...Z.current,...It}},et=_.useRef({}),at=_.useRef(null),tt=It=>b.current.send(JSON.stringify(It));window.EWC||(window.EWC={}),(bt=window.EWC)!=null&&bt.ping||(window.EWC.pingMS=0,window.EWC.ping=()=>{window.setTimeout(()=>{window.EWC.pingMS>0&&b.current.send('{"Event":{"EventName":"Ping","ID":""}}'),window.EWC.ping()},window.EWC.pingMS==0?1e3:window.EWC.pingMS)},window.EWC.ping()),_.useEffect(()=>{et.current={},r([]),localStorage.clear(),yt();const It=()=>{b.current&&b.current.send(JSON.stringify({Signal:{Name:"Close"}}))};return window.addEventListener("beforeunload",It),()=>{window.removeEventListener("beforeunload",It),b.current&&b.current.readyState===WebSocket.OPEN&&b.current.close()}},[f]),_.useEffect(()=>{const It=at.current;return It&&It.addEventListener("click",mt),()=>{It&&It.removeEventListener("click",mt)}},[]),W&&localStorage.setItem("fontscale",W);function ft(It,ae){return(G==null?void 0:G[It])||ae}function dt(It){return typeof It=="number"&&(It=[It]),It==null?void 0:It.map($t=>Array.isArray($t)&&($t!=null&&$t.every(Ot=>typeof Ot=="number"&&Ot>=0))?$t:typeof $t=="number"&&$t<0?ft($t):typeof $t=="number"&&$t>=0?$t:$t==null?void 0:$t.map(Ot=>Array.isArray(Ot)?Ot.map(we=>typeof we=="number"&&we<0?ft(we):we):typeof Ot=="number"&&Ot<0?ft(Ot):Ot))}const ht=(It,ae)=>{var we,Ht,se,Se,Kt,fe,ne,ce;console.log("handleData",It,ae);const $t=It.ID.split("."),ue=KM(et.current,It.ID),Ot=$t[$t.length-1];if(ue.hasOwnProperty(Ot)){if(ae==="WC")It.Properties&&It.Properties.Type==="Form"&&localStorage.clear(),ue[Ot]={ID:It.ID,...It};else if(ae==="WS"){const xe=Wt=>{var qt,Ee;return((qt=Wt.Properties)==null?void 0:qt.Type)=="Button"&&((Ee=Wt.Properties)==null?void 0:Ee.Style)=="Radio"};if(xe(ue[Ot])){const Wt=KM(et.current,It.ID),qt=Aq(It.ID);Object.keys(ra(Wt)).forEach(Ee=>{xe(Wt[Ee])&&(Wt[Ee].Properties.State=0)}),Wt[qt].Properties.State=It.Properties.State}ue[Ot]={ID:It.ID,...ue[Ot],Properties:{...ue[Ot].Properties||{},...It.Properties||{}}}}}else{let xe=JSON.parse(JSON.stringify(It));console.log("New data is assss",xe);try{if(It.Properties.hasOwnProperty("FillCol")||It.Properties.hasOwnProperty("FCol")||It.Properties.hasOwnProperty("BCol")||It.Properties.hasOwnProperty("BodyHeight")||It.Properties.hasOwnProperty("MaxButtonWidth"))xe={...It,Properties:{...It==null?void 0:It.Properties,...((we=It==null?void 0:It.Properties)==null?void 0:we.FillCol)&&{FillCol:dt(It.Properties.FillCol)},...((Ht=It==null?void 0:It.Properties)==null?void 0:Ht.FCol)&&{FCol:dt(It.Properties.FCol)},...((se=It==null?void 0:It.Properties)==null?void 0:se.BCol)&&{BCol:dt(It.Properties.BCol)},...((Se=It==null?void 0:It.Properties)==null?void 0:Se.BodyHeight)&&{BodyHeight:dt(It.Properties.BodyHeight)},...((Kt=It==null?void 0:It.Properties)==null?void 0:Kt.MaxButtonWidth)&&{MaxButtonWidth:dt(It.Properties.MaxButtonWidth)}}};else if(((fe=It==null?void 0:It.Properties)==null?void 0:fe.Type)==="TabControl"){const Wt={Size:(ne=It==null?void 0:It.Properties)==null?void 0:ne.Size,Posn:(ce=It==null?void 0:It.Properties)==null?void 0:ce.Posn};localStorage.setItem("TabControlData",JSON.stringify(Wt))}}catch(Wt){console.log({error:Wt})}ue[Ot]={ID:It.ID,...xe},console.log("compare",{data:It,newData:xe})}I()};function lt(It,ae){ae.forEach($t=>{((Ot,we)=>{if(Ot.hasOwnProperty(we))delete Ot[we];else{const Ht=we.split(".");let se=Ot;for(let Se=0;Se{let It=Math.round(window.devicePixelRatio*100);const ae=Qi(),$t=URL.parse(ae),ue=$t.protocol==="https:"?"wss":"ws",Ot=$t.port&&$t.protocol!=="https:"?`:${$t.port}`:"",we=$t.pathname||"/";b.current=new WebSocket(`${ue}://${$t.hostname}${Ot}${we}`);const Ht=b.current;i(Ht),Ht.onopen=()=>{let se=JSON.stringify({DeviceCapabilities:{ViewPort:[window.innerHeight,window.innerWidth],ScreenSize:[window.screen.height,window.screen.width],DPR:It/100,PPI:200}});Ht.send(se);const Se=JSON.stringify({[f]:{Version:eI.version,Name:eI.name,URL:window.location.href}});Ht.send(Se)},Ht.onmessage=se=>{var Kt,fe,ne,ce,xe,Wt,qt,Ee,Ie,Pe,Yt;const Se=Object.keys(JSON.parse(se.data));if(Se[0]=="WC"){let st=JSON.parse(se.data).WC;if(((Kt=st==null?void 0:st.Properties)==null?void 0:Kt.Type)=="Form"){localStorage.clear();const Et=wq(et.current);et.current={},et.current=Et,ht(JSON.parse(se.data).WC,"WC");return}if(((fe=st==null?void 0:st.Properties)==null?void 0:fe.Type)=="MsgBox"){H(st);return}r(Et=>[...Et,JSON.parse(se.data).WC]),ht(JSON.parse(se.data).WC,"WC")}else if(Se[0]=="WS"){const st=JSON.parse(se.data).WS;let Et=null;const zt=JSON.parse(Ui(et.current,st.ID));if(console.log("WSSocket",{serverEvent:st,data:zt}),((ne=zt==null?void 0:zt.Properties)==null?void 0:ne.Type)=="Edit"){st!=null&&st.Properties.hasOwnProperty("Text")?Et=st==null?void 0:st.Properties.Text:st!=null&&st.Properties.hasOwnProperty("Value")?Et=st==null?void 0:st.Properties.Value:st!=null&&st.Properties.hasOwnProperty("SelText")&&(Et=st==null?void 0:st.Properties.SelText);const Rt={...zt==null?void 0:zt.Properties,...st==null?void 0:st.Properties};return ht({ID:st.ID,Properties:Rt},"WS")}if(((ce=zt==null?void 0:zt.Properties)==null?void 0:ce.Type)=="Combo"&&st!=null&&st.Properties.hasOwnProperty("SelItems")){r(Qt=>[...Qt,JSON.parse(se.data).WS]),Et=st==null?void 0:st.Properties.SelItems;const Rt=Et.indexOf(1);let Vt=(xe=zt==null?void 0:zt.Properties)==null?void 0:xe.Items[Rt];return ht({ID:st.ID,Properties:{...zt==null?void 0:zt.Properties,SelItems:Et,Text:Vt}},"WS")}r(Rt=>[...Rt,JSON.parse(se.data).WS]),ht(JSON.parse(se.data).WS,"WS")}else if(Se[0]=="WG"){console.log("Data is as",JSON.parse(se.data).WG);const st=JSON.parse(se.data).WG,Et=document.getElementById(st.ID.split(".")[0]).getBoundingClientRect(),Rt=(document.getElementById(st.ID+".$CONTAINER")||document.getElementById(st.ID)).getBoundingClientRect(),Vt=Qt=>{var ve;return(ve=Qt.WG)!=null&&ve.Properties&&(st.Properties.includes("Posn")&&Qt.WG.Properties.Posn===void 0&&(Qt.WG.Properties.Posn=[Rt.y-Et.y-1,Rt.x-Et.x-1]),st.Properties.includes("Size")&&Qt.WG.Properties.Size===void 0&&(Qt.WG.Properties.Size=[Rt.height,Rt.width])),JSON.stringify(Qt)};try{const Qt=JSON.parse(Ui(et.current,st==null?void 0:st.ID)),ve=(Wt=Qt==null?void 0:Qt.Properties)==null?void 0:Wt.Type,je=JSON.stringify({WG:{ID:st==null?void 0:st.ID,Error:{Code:1,Message:"ID not found",WGID:st==null?void 0:st.WGID}}});if(!ve)return Ht.send(je);const{Properties:ke}=Qt;if(console.log("Reference adata a",Qt,ke),console.log("Reffffffff",ke),ve=="Grid"){const{Values:Oe,CurCell:Tt}=ke;console.log("250 values",{Values:Oe,CurCell:Tt});const Ve=_2(["Values","CurCell"],st==null?void 0:st.Properties);if(!localStorage.getItem(st.ID)){const Le={};st.Properties.map(h1=>Le[h1]=ke[h1]);const ge=Vt({WG:{ID:st.ID,Properties:Le,WGID:st.WGID,...Ve&&Ve.NotSupported&&Ve.NotSupported.length>0?{NotSupported:Ve.NotSupported}:null}});return Ht.send(ge)}const{Event:He}=JSON.parse(localStorage.getItem(st.ID)),d1={};st.Properties.map(Le=>{var ge;Le==="CurCell"?d1[Le]=Tt:d1[Le]=He[Le]||((ge=Qt==null?void 0:Qt.Properties)==null?void 0:ge[Le])}),console.log("250",Vt({WG:{ID:st.ID,Properties:d1,WGID:st.WGID,...Ve&&Ve.NotSupported&&Ve.NotSupported.length>0?{NotSupported:Ve.NotSupported}:null}})),r(Le=>[...Le,{ID:st.ID,Properties:{...ke,Values:Oe}}]),ht({ID:st.ID,Properties:{...ke,Values:Oe}}),Ht.send(Vt({WG:{ID:st.ID,Properties:d1,WGID:st.WGID,...Ve&&Ve.NotSupported&&Ve.NotSupported.length>0?{NotSupported:Ve.NotSupported}:null}}))}if(ve=="Form"){console.log("Coming in forms");const Oe=["Posn","Size"];console.log("Server isssue is as",st);const Tt=_2(Oe,st==null?void 0:st.Properties);console.log("Server event is assss",st,Tt);const te={},Ve=JSON.parse(localStorage.getItem(st.ID));if(console.log("Value of form is",ke,Ve),!localStorage.getItem(st.ID)){const d1={};st.Properties.map(ge=>(console.log("Properties key is",ke[ge]),d1[ge]=ke[ge])),console.log("Valllll===>"),console.log("+++++++",st,d1);const Le=Vt({WG:{ID:st.ID,Properties:d1,WGID:st.WGID,...Tt&&Tt.NotSupported&&Tt.NotSupported.length>0?{NotSupported:Tt.NotSupported}:null}});console.log("server event is as2",Le),Ht.send(Le);return}console.log("Coming outside"),st.Properties.map(d1=>te[d1]=Ve[d1]);const He=Vt({WG:{ID:st.ID,Properties:te,WGID:st.WGID,...Tt&&Tt.NotSupported&&Tt.NotSupported.length>0?{NotSupported:Tt.NotSupported}:null}});console.log("server event is as2",He),Ht.send(He);return}if(ve=="Edit"){const{Text:Oe="",Value:Tt,SelText:te}=ke,Ve=["Text","Value","SelText"];console.log("edit",{serverEvent:st,Properties:ke,Text:Oe,local:localStorage.getItem(st.ID)});const He=_2(Ve,st==null?void 0:st.Properties);if(!localStorage.getItem(st.ID)){const h1=Oe||Tt,M1=(qt=Qt==null?void 0:Qt.Properties)==null?void 0:qt.hasOwnProperty("FieldType"),Z1={};return st.Properties.forEach(zr=>{zr==="Text"?Z1[zr]=h1?h1.toString():"":zr==="Value"?Z1[zr]=M1?parseInt(h1):h1:zr==="SelText"?Z1[zr]=ke[zr]?ke[zr]:[1,1]:Z1[zr]=h1}),console.log(Vt({WG:{ID:st.ID,Properties:Z1,WGID:st.WGID,...He&&He.NotSupported&&He.NotSupported.length>0?{NotSupported:He.NotSupported}:null}})),Ht.send(Vt({WG:{ID:st.ID,Properties:Z1,WGID:st.WGID,...He&&He.NotSupported&&He.NotSupported.length>0?{NotSupported:He.NotSupported}:null}}))}const{Event:d1}=JSON.parse(localStorage.getItem(st==null?void 0:st.ID)),{Info:Le}=d1,ge={};console.log("edit 2",{serverPropertiesObj:ge}),st.Properties.forEach(h1=>{var M1;if(h1==="Value")ge[h1]=Le;else if(h1==="SelText")ge[h1]=te;else if(h1==="Text"){console.log("edit 3 hrere");const Z1=(M1=JSON.parse(localStorage.getItem(st==null?void 0:st.ID)))==null?void 0:M1.Text;ge[h1]=Array.isArray(Oe||Z1)?Oe||Z1:Oe||"2"}else ge[h1]=Le.toString()}),console.log(Vt({WG:{ID:st.ID,Properties:ge,WGID:st.WGID,...He&&He.NotSupported&&He.NotSupported.length>0?{NotSupported:He.NotSupported}:null}})),Ht.send(Vt({WG:{ID:st.ID,Properties:ge,WGID:st.WGID,...He&&He.NotSupported&&He.NotSupported.length>0?{NotSupported:He.NotSupported}:null}}))}if(ve=="Combo"){console.log("Properties are",ke);const{SelItems:Oe,Items:Tt,Text:te}=ke;console.log("Coming in form but combo");const Ve=["Text","SelItems","Posn","Size"];console.log("server event is as",st);const He=_2(Ve,st==null?void 0:st.Properties);if(console.log("RESULT IS AS",He),console.log("rESULT IS AS",He),console.log("rESULT IS AS2",localStorage.getItem(st.ID)),!localStorage.getItem(st.ID)){console.log("server event is as",st);let Xr=Oe||new Array(Tt.length).fill(0);if(te){const _i=Tt.indexOf(te);_i>=0&&(Xr.fill(0),Xr[_i]=1)}const jn={};st.Properties.map(_i=>{jn[_i]=_i==="SelItems"?Xr:_i==="Text"?te:ke[_i]});const Gn={WG:{ID:st.ID,Properties:jn,WGID:st.WGID,...((Ee=He==null?void 0:He.NotSupported)==null?void 0:Ee.length)>0?{NotSupported:He.NotSupported}:null}};return console.log("server event is as2",Gn),Ht.send(Vt(Gn))}console.log("rESULT IS AS4");const{Event:d1}=JSON.parse(localStorage.getItem(st==null?void 0:st.ID));console.log("EVENY IS AS",d1,st.WGID);const{Info:Le,Size:ge,Posn:h1}=d1;let M1=Oe||new Array(Tt.length).fill(0);if(te){const Xr=Tt.indexOf(te);Xr>=0&&(M1.fill(0),M1[Xr]=1)}const Z1={};console.log("Server eveny is as",st.Properties),st.Properties.map(Xr=>{Z1[Xr]=Xr==="SelItems"?M1:Xr==="Text"?te:Xr==="Items"?Tt[Le]:d1[Xr]});const zr={WG:{ID:st.ID,Properties:Z1,WGID:st.WGID,...((Ie=He==null?void 0:He.NotSupported)==null?void 0:Ie.length)>0?{NotSupported:He.NotSupported}:null}};return console.log("server event is as2",zr),Ht.send(Vt(zr))}if(console.log("Coming here in nnnnn"),ve=="List"){console.log("Coming here");const{SelItems:Oe}=ke,te=_2(["SelItems"],st==null?void 0:st.Properties);if(!localStorage.getItem(st.ID))return console.log(Vt({WG:{ID:st.ID,Properties:{SelItems:Oe},...te&&te.NotSupported&&te.NotSupported.length>0?{NotSupported:te.NotSupported}:null,WGID:st.WGID}})),Ht.send(Vt({WG:{ID:st.ID,Properties:{SelItems:Oe},...te&&te.NotSupported&&te.NotSupported.length>0?{NotSupported:te.NotSupported}:null,WGID:st.WGID}}));const{Event:Ve}=JSON.parse(localStorage.getItem(st==null?void 0:st.ID));return console.log(Vt({WG:{ID:st.ID,Properties:{SelItems:Ve.SelItems},...te&&te.NotSupported&&te.NotSupported.length>0?{NotSupported:te.NotSupported}:null,WGID:st.WGID}})),Ht.send(Vt({WG:{ID:st.ID,Properties:{SelItems:Ve.SelItems},...te&&te.NotSupported&&te.NotSupported.length>0?{NotSupported:te.NotSupported}:null,WGID:st.WGID}}))}if(ve=="Scroll"){const{Thumb:Oe=1}=ke,Tt=["Thumb"];console.log("300",Oe);const te=_2(Tt,st==null?void 0:st.Properties);if(!localStorage.getItem(st.ID))return console.log(Vt({WG:{ID:st.ID,Properties:{Thumb:Oe},WGID:st.WGID,...te&&te.NotSupported&&te.NotSupported.length>0?{NotSupported:te.NotSupported}:null}})),Ht.send(Vt({WG:{ID:st.ID,Properties:{Thumb:Oe},WGID:st.WGID,...te&&te.NotSupported&&te.NotSupported.length>0?{NotSupported:te.NotSupported}:null}}));const{Event:Ve}=JSON.parse(localStorage.getItem(st==null?void 0:st.ID)),{Info:He}=Ve;return console.log(Vt({WG:{ID:st.ID,Properties:{Thumb:He[1]},WGID:st.WGID,...te&&te.NotSupported&&te.NotSupported.length>0?{NotSupported:te.NotSupported}:null}})),Ht.send(Vt({WG:{ID:st.ID,Properties:{Thumb:Oe},WGID:st.WGID,...te&&te.NotSupported&&te.NotSupported.length>0?{NotSupported:te.NotSupported}:null}}))}if(ve=="Splitter"){console.log("Coming in form but splitter");const{Posn:Oe}=ke,te=_2(["Posn","Size"],st==null?void 0:st.Properties);if(!localStorage.getItem(st.ID)){const ge={};return st.Properties.map(h1=>ge[h1]=ke[h1]),console.log(Vt({WG:{ID:st.ID,Properties:ge,WGID:st.WGID,...te&&te.NotSupported&&te.NotSupported.length>0?{NotSupported:te.NotSupported}:null}})),Ht.send(Vt({WG:{ID:st.ID,Properties:ge,WGID:st.WGID,...te&&te.NotSupported&&te.NotSupported.length>0?{NotSupported:te.NotSupported}:null}}))}const{Event:Ve}=JSON.parse(localStorage.getItem(st.ID)),{Info:He,Size:d1}=Ve,Le={};return st.Properties.map(ge=>Le[ge]=ge=="Posn"?He:d1),console.log(Vt({WG:{ID:st.ID,Properties:Le,WGID:st.WGID,...te&&te.NotSupported&&te.NotSupported.length>0?{NotSupported:te.NotSupported}:null}})),Ht.send(Vt({WG:{ID:st.ID,Properties:Le,WGID:st.WGID,...te&&te.NotSupported&&te.NotSupported.length>0?{NotSupported:te.NotSupported}:null}}))}if(ve=="SubForm"){console.log("Coming in form but suss");const Tt=_2(["Posn","Size"],st==null?void 0:st.Properties);if(console.log("Valuuuuuuuu",Tt),console.log("Servere event is ",st),!localStorage.getItem(st.ID)){console.log("Coming in form but su1");const He={};return console.log("Properiessss",st.Properties,ke),st.Properties.map(d1=>(console.log("Propertiesss2",ke[d1]),He[d1]=ke[d1])),console.log("Server propertoes aew,",He),console.log(Vt({WG:{ID:st.ID,Properties:He,WGID:st.WGID,...Tt&&Tt.NotSupported&&Tt.NotSupported.length>0?{NotSupported:Tt.NotSupported}:null}})),Ht.send(Vt({WG:{ID:st.ID,Properties:He,WGID:st.WGID,...Tt&&Tt.NotSupported&&Tt.NotSupported.length>0?{NotSupported:Tt.NotSupported}:null}}))}console.log("Coming in form but su2");const te={};console.log("Serverrrrrr",st.ID);const Ve=JSON.parse(localStorage.getItem(st.ID));return console.log("Value of subform is as",Ve),st.Properties.map(He=>(console.log("Keyyy",He),te[He]=Ve[He])),console.log("Server properties are",te),console.log(Vt({WG:{ID:st.ID,Properties:te,WGID:st.WGID,...Tt&&Tt.NotSupported&&Tt.NotSupported.length>0?{NotSupported:Tt.NotSupported}:null}})),Ht.send(Vt({WG:{ID:st.ID,Properties:te,WGID:st.WGID,...Tt&&Tt.NotSupported&&Tt.NotSupported.length>0?{NotSupported:Tt.NotSupported}:null}}))}if(ve=="Button"){console.log("Coming here in buttons");const{State:Oe}=ke,te=_2(["State","Posn","Size"],st==null?void 0:st.Properties);if(!localStorage.getItem(st.ID)){const ge={};st.Properties.map(M1=>ge[M1]=M1=="State"?Oe||0:ke[M1]);const h1=Vt({WG:{ID:st.ID,Properties:ge,WGID:st.WGID,...te&&te.NotSupported&&te.NotSupported.length>0?{NotSupported:te.NotSupported}:null}});return console.log(h1),Ht.send(h1)}const{Event:Ve}=JSON.parse(localStorage.getItem(st.ID)),{Value:He}=Ve,d1={};st.Properties.map(ge=>d1[ge]=ge=="State"?He:Ve[ge]);const Le=Vt({WG:{ID:st.ID,Properties:d1,WGID:st.WGID,...te&&te.NotSupported&&te.NotSupported.length>0?{NotSupported:te.NotSupported}:null}});return console.log(Le),Ht.send(Le)}if(ve=="TreeView"){const Tt=_2(["SelItems"],st==null?void 0:st.Properties),{Event:te}=JSON.parse(localStorage.getItem(st.ID)),{SelItems:Ve}=te,He=Vt({WG:{ID:st.ID,Properties:{SelItems:Ve},WGID:st.WGID,...Tt&&Tt.NotSupported&&Tt.NotSupported.length>0?{NotSupported:Tt.NotSupported}:null}});return console.log(He),Ht.send(He)}if(ve=="Timer"){const Tt=_2(["FireOnce"],st==null?void 0:st.Properties),{Event:te}=JSON.parse(localStorage.getItem(st.ID)),{FireOnce:Ve}=te,He=Vt({WG:{ID:st.ID,Properties:{FireOnce:Ve},WGID:st.WGID,...Tt&&Tt.NotSupported&&Tt.NotSupported.length>0?{NotSupported:Tt.NotSupported}:null}});return console.log(He),Ht.send(He)}if(ve=="ListView"){const Tt=_2(["SelItems"],st==null?void 0:st.Properties),{Event:te}=JSON.parse(localStorage.getItem(st.ID)),{SelItems:Ve}=te,He=Vt({WG:{ID:st.ID,Properties:{SelItems:Ve},WGID:st.WGID,...Tt&&Tt.NotSupported&&Tt.NotSupported.length>0?{NotSupported:Tt.NotSupported}:null}});return console.log(He),Ht.send(He)}if(ve==="ApexChart"){const Oe=["SVG"],{SVG:Tt}=ke,te=JSON.parse(Ui(et.current,st.ID)),Ve=Vt({WG:{ID:st.ID,WGID:st.WGID,Properties:{SVG:Tt}}});return Ht.send(Ve)}if(ve==="Upload")return n0.WG(tt,st);const c1={};for(const Oe in st.Properties)Qt.Properties[Oe]&&(c1[Oe]=Qt[Oe]);return Ht.send(Vt({WG:{ID:st.ID,Properties:c1,WGID:st.WGID}}))}catch(Qt){console.error("WG Error: ",Qt)}}else if(Se[0]=="NQ"){const st=JSON.parse(se.data).NQ;console.log("300",st,st.ID,st.Event,st.Info);const{Event:Et,ID:zt,Info:Rt,NoCallback:Vt=0}=st,Qt=Ui(et.current,zt);if(Et&&Et=="Configure"){ht({ID:zt,Properties:{...Qt==null?void 0:Qt.Properties,Posn:[Rt[0],Rt[1]],Size:[Rt[2],Rt[3]]}},"WS");const ke=JSON.stringify({Event:{EventName:st.Event,ID:st.ID,Info:st.Info}});Ht.send(ke);return}else if(Et=="SetPing"){window.EWC.pingMS=Rt[0]*1e3;return}else if(Et&&Et=="ItemDown"||Et&&Et=="GotFocus"){Et&&Et=="GotFocus"&&localStorage.setItem("current-focus",zt);const ke=JSON.parse(Ui(et.current,zt));if(!(((Pe=ke==null?void 0:ke.Properties)==null?void 0:Pe.Event)&&((Yt=ke==null?void 0:ke.Properties)==null?void 0:Yt.Event.some(Tt=>Tt[0]===Et))))return;const Oe=JSON.stringify({Event:{EventName:Et,ID:zt,Info:Rt}});console.log(Oe),Vt==0&&Ht.send(Oe);return}else if(Et=="CellMove"){console.log("296",{nqEvent:st}),p([...h,st]),localStorage.setItem(zt,JSON.stringify({Event:{CurCell:[Rt[0],Rt[1]]}})),localStorage.setItem("nqCurCell",JSON.stringify({ID:zt,Info:Rt}));return}else if(Et=="Select"){const ke=document.getElementById(st.ID);ke&&ke.click(),Ht.send(JSON.stringify({Event:{EventName:"Select",ID:zt}}))}else Et=="Scroll"&&Ht.send(JSON.stringify({Event:{EventName:"Scroll",ID:zt,Info:[Rt[0],Rt[1]]}}));const ve=Rt[1];console.log("300",{thumbValue:ve}),ht({ID:zt,Properties:{Thumb:ve}},"WS");const je=document.getElementById(st.ID);je&&je.focus()}else if(Se[0]=="EC"){const st=JSON.parse(se.data).EC,{EventID:Et,Proceed:zt}=st;l(Rt=>(console.log("use effect",Z.current),Object.keys(Rt).some(Vt=>Vt.includes(Et)),{...Rt,[`${Et}${Z.current.curEvent}`]:zt})),a(zt)}else if(Se[0]=="EX"){const st=JSON.parse(se.data).EX;lt(et.current,st==null?void 0:st.ID)}else if(Se[0]=="WX"){const st=JSON.parse(se.data).WX,{Method:Et,Info:zt,WGID:Rt,ID:Vt}=st;if(Et=="GetTextSize"){const Qt=zt&&zt[0],ve=JSON.parse(Ui(et.current,zt&&zt[1])),je=ve&&(ve==null?void 0:ve.Properties),ke=gC.calculateTextDimensions(Qt,je==null?void 0:je.Size),c1=JSON.stringify({WX:{Info:ke,WGID:Rt}});return console.log(c1),Ht.send(c1)}else if(Et=="OnlyDQ"){let Qt;zt!=null&&zt[0]?Qt=JSON.stringify({WX:{Info:[[Vt,150,300]],WGID:Rt}}):Qt=JSON.stringify({WX:{Info:[],WGID:Rt}}),Ht.send(Qt)}else if(Et=="GetFocus"){const Qt=localStorage.getItem("current-focus"),ve=JSON.stringify({WX:{Info:Qt?[Qt]:[],WGID:Rt}});console.log(ve),Ht.send(ve)}else if(Et=="SetCookie")zt.forEach(Qt=>{document.cookie=Qt}),Ht.send(JSON.stringify({WX:{Info:[],WGID:Rt}}));else if(Et=="GetCookie"){const Qt=document.cookie.split("; ").map(ve=>ve.split("=")).filter(ve=>zt.includes(ve[0]));Ht.send(JSON.stringify({WX:{Info:Qt,WGID:Rt}}))}else if(Et=="SetTitle")document.title=zt[0],Ht.send(JSON.stringify({WX:{Info:[],WGID:Rt}}));else if(Et=="GetTitle")Ht.send(JSON.stringify({WX:{Info:[document.title],WGID:Rt}}));else if(Et=="EvalJS"){const Qt=zt.map(ve=>{try{return[0,eval==null?void 0:(0,eval)(ve)]}catch(je){return[-1,je.toString()]}});Ht.send(JSON.stringify({WX:{Info:Qt,WGID:Rt}}))}}else if(Se[0]=="Options")ht(JSON.parse(se.data).Options,"WC"),console.log("label",JSON.parse(se.data).Options),JSON.parse(se.data).Options.ID=="Fonts"&&$(JSON.parse(se.data).Options.Properties.Scale),JSON.parse(se.data).Options.ID=="Fonts"&&console.log("label",JSON.parse(se.data).Options.Properties.Scale),JSON.parse(se.data).Options.ID=="Mode"&&R(JSON.parse(se.data).Options.Properties),JSON.parse(se.data).Options.ID=="Colors"&>(JSON.parse(se.data).Options.Properties.Standard);else if(Se[0]=="FormatCell"){const st=JSON.parse(se.data),{FormatCell:Et}=st,zt=JSON.parse(Ui(et.current,Et==null?void 0:Et.ID)),{Properties:Rt}=zt,Vt=Rt==null?void 0:Rt.FormattedValues;Vt[Et.Cell[0]-1][Et.Cell[1]-1]=Et==null?void 0:Et.FormattedValue,ht({ID:Et==null?void 0:Et.ID,Properties:{...zt==null?void 0:zt.Properties,FormattedValues:Vt}},"WS")}}},mt=It=>{const ae=ZM(et.current);if(localStorage.getItem("change-event")){const{Event:$t}=JSON.parse(localStorage.getItem("change-event")),ue={...$t,Info:[It.target.id?It.target.id:ae]};b.current.send(JSON.stringify({Event:{...ue}})),localStorage.removeItem("change-event")}};console.log("App",et.current);const gt=It=>{G={...It==null?void 0:It.reduce(($t,ue)=>({...$t,[ue==null?void 0:ue[0]]:ue[2]}),{})}},kt=ZM(et.current),_t=(It,ae)=>{H(null),n.send(JSON.stringify({Event:{EventName:It,ID:ae}}))};return vt.jsxs("div",{children:[vt.jsx(fD.Provider,{value:{socketData:t,dataRef:et,socket:n,handleData:ht,focusedElement:z,reRender:I,proceed:o,setProceed:a,proceedEventArray:s,setProceedEventArray:l,colors:G,fontScale:W,nqEvents:h,setNqEvents:p,currentEventRef:Z.current,updateCurrentEvent:K,isDesktop:(Ft=(At=(Mt=et==null?void 0:et.current)==null?void 0:Mt.Mode)==null?void 0:At.Properties)==null?void 0:Ft.Desktop},children:et&&kt&&vt.jsx(E4,{data:et.current[kt]})}),F&&vt.jsx(BO,{data:F,options:E,onClose:_t,isDesktop:(Xt=(Ut=(Bt=et==null?void 0:et.current)==null?void 0:Bt.Mode)==null?void 0:Ut.Properties)==null?void 0:Xt.Desktop})]})};Kv.createRoot(document.getElementById("root")).render(vt.jsx(Ajt,{})); + */const lN=ra(sN);lN.displayName="KendoReactGrid";const tI=t=>{const r={};return t.forEach(n=>{r[n[0]]=n[1]}),r},xjt=({data:t})=>{const{ColTitles:r,Values:n,Posn:i,Options:o}=t==null?void 0:t.Properties,a=n.map(R=>{let W={};return r.forEach(($,G)=>W[$]=R[G]),W}),s={logic:"and",filters:[]},[l,h]=_.useState(s),p=[],[f,g]=_.useState(p),b=tI(o.columnTypes),z=tI(o.filterableCols),M=o.sortableCols,E={Image:R=>R.dataItem[R.field]?vt.jsx("td",{children:vt.jsx("img",{src:Zi()+R.dataItem[R.field]})}):vt.jsx("td",{}),Button:R=>vt.jsx("td",{children:vt.jsx(Jr,{onClick:()=>alert(R.dataItem[R.field]),children:R.dataItem[R.field]})}),Video:R=>{const W=R.dataItem[R.field];return W?vt.jsx("td",{children:vt.jsx("video",{controls:!0,children:vt.jsx("source",{src:Zi()+W,type:"video/mp4"})})}):vt.jsx("td",{})}};return vt.jsx("div",{style:{position:"absolute",top:i&&i[0],left:i&&i[1]},children:vt.jsx(lN,{data:yRt(mRt(a,l),f),navigatable:!0,filterable:o.filterable==1,filter:l,onFilterChange:R=>h(R.filter),sortable:o.sortable==1?{allowUnsort:!0,mode:"multiple"}:void 0,sort:f,onSortChange:R=>g(R.sort),children:r.map((R,W)=>vt.jsx(DC,{field:R,title:R,cells:{data:E[b[R]]},filterable:z.hasOwnProperty(R),filter:z[R]===""?void 0:z[R],sortable:M.includes(R)}))})})};function cN(t){return C({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M5.22 8.22a.749.749 0 0 0 0 1.06l6.25 6.25a.749.749 0 0 0 1.06 0l6.25-6.25a.749.749 0 1 0-1.06-1.06L12 13.939 6.28 8.22a.749.749 0 0 0-1.06 0Z"}}]})(t)}function bjt(t){return C({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M18.78 15.78a.749.749 0 0 1-1.06 0L12 10.061 6.28 15.78a.749.749 0 1 1-1.06-1.06l6.25-6.25a.749.749 0 0 1 1.06 0l6.25 6.25a.749.749 0 0 1 0 1.06Z"}}]})(t)}const wjt=({data:t,startIndex:r,menuLength:n,handleSelectEvent:i,fontProperties:o})=>{const{findDesiredData:a,fontScale:s}=x1(),{Caption:l,Event:h,ImageIndex:p,ImageListObj:f}=t.Properties,g=a(f);let b=null,z=null;if(g){const{Files:M,Size:I}=g.Properties;b=Zi()+M[p-1],z=I}return vt.jsxs("div",{className:"custom-dropdown-item d-flex gap-1",style:{padding:"8px 16px",cursor:"pointer",borderBottom:ri(t.ID,h),children:[b&&vt.jsx("img",{src:b,style:{width:z[0],height:z[1]}}),vt.jsx("div",{style:{fontFamily:o==null?void 0:o.PName,fontSize:o!=null&&o.Size?`${o.Size*s}px`:`${12*s}px`},children:l})]},r)},Cjt=({data:t})=>{var G,Z,K,et,at;const r=t.ImageList,{socket:n,findCurrentData:i,fontScale:o}=x1(),a=i(t.FontObj&&t.FontObj),s=a&&(a==null?void 0:a.Properties),{Icon:l,Caption:h,ImageIndex:p,CSS:f,ImageListObj:g}=t==null?void 0:t.Properties,b=$1(f),[z,M]=_.useState(!1),I=_.useRef(null),F=i(g),H=mD(F,p),E=(tt,ft)=>{const dt=JSON.stringify({Event:{EventName:"Select",ID:tt}});ft&&ft.some(lt=>lt[0]==="Select")&&(console.log(dt),n.send(dt),M(!1))},R=c0[l]?c0[l]:nb,W=Object.keys(t).filter(tt=>tt.startsWith("MItem")).map(tt=>t[tt]);_.useEffect(()=>{const tt=ft=>{I.current&&!I.current.contains(ft.target)&&M(!1)};return document.addEventListener("mousedown",tt),()=>{document.removeEventListener("mousedown",tt)}},[]);const $=tt=>{tt.stopPropagation(),M(ft=>!ft)};return vt.jsx("div",{ref:I,children:vt.jsx(Qx,{children:vt.jsxs(ip,{md:12,children:[vt.jsxs("div",{id:t==null?void 0:t.ID,className:"d-flex align-items-center flex-column justify-content-center",style:{cursor:"pointer",...b},onClick:tt=>{tt.stopPropagation(),$(tt)},children:[H?vt.jsx("img",{style:{width:H.imageSize[1],height:H.imageSize[0]},src:`${Zi()}${H.imageUrl}`,alt:"Image"}):p?vt.jsx("img",{style:{width:((G=r==null?void 0:r.Properties)==null?void 0:G.Size)&&((Z=r==null?void 0:r.Properties)==null?void 0:Z.Size[1]),height:((K=r==null?void 0:r.Properties)==null?void 0:K.Size)&&((et=r==null?void 0:r.Properties)==null?void 0:et.Size[0])},src:`${Zi()}${(at=r==null?void 0:r.Properties)==null?void 0:at.Files[p-1]}`,alt:"Image"}):vt.jsx(R,{size:35}),vt.jsx("div",{className:"text-center",style:{fontFamily:s==null?void 0:s.PName,fontSize:s!=null&&s.Size?`${s.Size*o}px`:`${12*o}px`},children:h}),vt.jsx(cN,{size:s!=null&&s.Size?`${s.Size*o}`:`${12*o}`})]}),z&&vt.jsx("div",{className:"custom-dropdown-menu",style:{position:"absolute",background:"#fff",borderRadius:"5px",boxShadow:"0 2px 10px rgba(0, 0, 0, 0.1)",marginTop:"5px",zIndex:1e3},children:W.map((tt,ft)=>vt.jsx(wjt,{data:tt,handleSelectEvent:E,menuLength:W.length,startIndex:ft,fontProperties:s},ft))})]})})})};function Sjt(t){return C({tag:"svg",attr:{fill:"currentColor",viewBox:"0 0 16 16"},child:[{tag:"path",attr:{fillRule:"evenodd",d:"M1 3.5a.5.5 0 0 1 .5-.5h13a.5.5 0 0 1 0 1h-13a.5.5 0 0 1-.5-.5zM8 6a.5.5 0 0 1 .5.5v5.793l2.146-2.147a.5.5 0 0 1 .708.708l-3 3a.5.5 0 0 1-.708 0l-3-3a.5.5 0 0 1 .708-.708L7.5 12.293V6.5A.5.5 0 0 1 8 6z"}}]})(t)}const eI=({data:t,startIndex:r,handleSelectEvent:n,className:i,ItemHeight:o,ItemWidth:a,fontProperties:s})=>{const{findDesiredData:l,fontScale:h}=x1(),{Caption:p,Event:f,ImageIndex:g,ImageListObj:b}=t.Properties,z=l(b);let M=null,I=null;if(z){const{Files:F,Size:H}=z.Properties;M=Zi()+F[g-1],I=H}return vt.jsx("div",{className:i,onClick:()=>n(t.ID,f),style:{minWidth:"max-content"},id:"gallery-Item",title:p,children:vt.jsxs("div",{className:"item-preview",style:{minWidth:"max-content",width:a+"px",height:o+"px"},children:[M&&vt.jsx("img",{src:M,style:{width:I[0],height:I[1]}}),vt.jsx("div",{style:{fontFamily:s==null?void 0:s.PName,fontSize:s!=null&&s.Size?`${s.Size*h}px`:`${12*h}px`},children:p})]})},r)},zjt=({data:t})=>{const{socket:r,findCurrentData:n}=x1(),{Cols:i,ItemHeight:o,ItemWidth:a}=t.Properties,[s,l]=_.useState(0),[h,p]=_.useState(!1),f=_.useRef(null),g=_.useRef(null),[b,z]=_.useState(0),M=n(t.FontObj&&t.FontObj),I=M&&(M==null?void 0:M.Properties),F=Object.keys(t).filter(ht=>ht.startsWith("MItem")).map(ht=>t[ht]),H=F.length,E=H%i,W=H-(E===0?i:E),$=()=>{l(ht=>Math.max(ht-i,0))},G=()=>{l(ht=>Math.min(ht+i,W))},Z=()=>{p(ht=>!ht)},K=(ht,lt)=>{const yt=JSON.stringify({Event:{EventName:"Select",ID:ht}});lt&<.some(gt=>gt[0]==="Select")&&(console.log(yt),r.send(yt),p(!1))};_.useEffect(()=>{setTimeout(()=>{if(g.current){const lt=g.current.children;let yt=0;console.log("Child elements for maxWidth calculation:",lt),Array.from(lt).forEach((mt,gt)=>{const _t=mt.getBoundingClientRect().width;console.log(`Child ${gt} width:`,_t),yt=Math.max(yt,_t)}),console.log("Calculated widest width:",yt),z(yt)}},100)},[F]),_.useEffect(()=>{const ht=lt=>{h&&f.current&&!f.current.contains(lt.target)&&p(!1)};return document.addEventListener("mousedown",ht),()=>{document.removeEventListener("mousedown",ht)}},[h]);const et=F.slice(s,s+i),at=s===0,tt=s>=W,ft=b||a||50,dt=o||40;return console.log("Final maxWidth value:",b,b*i+i*5+22),vt.jsxs("div",{className:"ribbon-gallery",ref:f,style:{minWidth:"max-content",width:b*i+i*5+22,height:`${dt+8}px`,justifyContent:"start",margin:"5px"},children:[!h&&vt.jsxs("div",{className:"d-flex",style:{justifyContent:`${et.lengthvt.jsx(eI,{data:ht,className:"",startIndex:lt+s,handleSelectEvent:K,ItemWidth:b,ItemHeight:dt-2,fontProperties:I},lt))}),vt.jsxs("div",{className:"gallery-buttons",style:{position:"absolute",right:0},children:[vt.jsx("button",{className:"gallery-button",onClick:$,disabled:at,title:"Scroll Left",children:vt.jsx(bjt,{size:12})}),vt.jsx("button",{className:"gallery-button",onClick:G,disabled:tt,title:"Scroll Right",children:vt.jsx(cN,{size:12})}),vt.jsx("button",{className:"gallery-button",onClick:Z,title:"More Styles",children:vt.jsx(Sjt,{size:12})})]})]}),h&&vt.jsx(vt.Fragment,{children:vt.jsx("div",{className:"dropdown-content",style:{width:`${ft*i}px`,height:`${dt}px`},children:vt.jsx("div",{className:"dropdown-grid",style:{display:"grid",gridTemplateColumns:`repeat(${i}, 1fr)`,gap:"4px"},children:F.map((ht,lt)=>vt.jsx(eI,{data:ht,handleSelectEvent:K,startIndex:lt,className:"ribbon-dropdown-item",ItemWidth:ft,ItemHeight:dt},lt))})})})]})},E4=({data:t,inputValue:r="",event:n="",row:i="",column:o="",location:a,inSplitter:s=null,values:l=[],formatString:h="",activeTab:p=null,bgColor:f=null,fontColor:g=null,activebgColor:b=null,handleTabClick:z=()=>{}})=>{var I,F,H,E,R,W,$,G,Z,K,et,at,tt,ft,dt,ht,lt,yt,mt,gt,_t,At,bt,kt,Lt,Vt,Rt,Ut,Kt,It,le,Bt,de,Ft,we,Ht,ce,Se,qt,ge,oe,ue,xe,Nt;const{dataRef:M}=x1();if(((I=t==null?void 0:t.Properties)==null?void 0:I.Type)=="Form")return vt.jsx(Mjt,{data:t});if(((F=t==null?void 0:t.Properties)==null?void 0:F.Type)=="MenuBar")return vt.jsx("div",{style:{top:0,left:0,position:"absolute",width:"100%"},children:vt.jsx(Tq,{data:t})});if(((H=t==null?void 0:t.Properties)==null?void 0:H.Type)=="Menu")return vt.jsx(Rq,{data:t});if(((E=t==null?void 0:t.Properties)==null?void 0:E.Type)=="Grid")return vt.jsx(mZ,{data:t});if(((R=t==null?void 0:t.Properties)==null?void 0:R.Type)=="Edit"&&((W=t==null?void 0:t.Properties)==null?void 0:W.Style)!=="Multi")return vt.jsx("div",{style:a=="inGrid"?{display:"flex",justifyContent:(($=t==null?void 0:t.Properties)==null?void 0:$.FieldType)=="Numeric"||((G=t==null?void 0:t.Properties)==null?void 0:G.FieldType)=="LongNumeric"?"end":"start"}:null,children:vt.jsx(yZ,{values:l,location:a,data:t,value:r,event:n,row:i,column:o,formatString:h})});if(((Z=t==null?void 0:t.Properties)==null?void 0:Z.Type)=="Button")return vt.jsx(xZ,{data:t,location:a,inputValue:r,event:n,row:i,column:o,values:l});if(((K=t==null?void 0:t.Properties)==null?void 0:K.Type)=="Combo")return vt.jsx(bZ,{data:t,location:a,value:r,event:n,row:i,column:o,values:l});if(((et=t==null?void 0:t.Properties)==null?void 0:et.Type)=="Label")return vt.jsx(wZ,{location:a,gridValue:r,data:t});if(((at=t==null?void 0:t.Properties)==null?void 0:at.Type)=="TreeView")return vt.jsx(_Q,{data:t});if(((tt=t==null?void 0:t.Properties)==null?void 0:tt.Type)=="List")return vt.jsx(AQ,{data:t});if(((ft=t==null?void 0:t.Properties)==null?void 0:ft.Type)=="Splitter")return vt.jsx(IQ,{data:t});if(((dt=t==null?void 0:t.Properties)==null?void 0:dt.Type)=="Group")return vt.jsx(HQ,{data:t});if(((ht=t==null?void 0:t.Properties)==null?void 0:ht.Type)=="Scroll")return vt.jsx(Ixt,{data:t});if(((lt=t==null?void 0:t.Properties)==null?void 0:lt.Type)=="TabControl")return vt.jsx(Hxt,{data:t});if(((yt=t==null?void 0:t.Properties)==null?void 0:yt.Type)=="TabButton")return vt.jsx(dP,{activeTab:p,handleTabClick:z,data:t,bgColor:f,fontColor:g,activebgColor:b});if(((mt=t==null?void 0:t.Properties)==null?void 0:mt.Type)=="Edit"&&((gt=t==null?void 0:t.Properties)==null?void 0:gt.Style)=="Multi")return vt.jsx(Dxt,{data:t});if(((_t=t==null?void 0:t.Properties)==null?void 0:_t.Type)=="Ribbon")return vt.jsx(Pxt,{data:t});if(((At=t==null?void 0:t.Properties)==null?void 0:At.Type)=="RibbonGroup")return vt.jsx(Txt,{data:t});if(((bt=t==null?void 0:t.Properties)==null?void 0:bt.Type)=="RibbonGroupItem")return vt.jsx(Vxt,{data:t});if(((kt=t==null?void 0:t.Properties)==null?void 0:kt.Type)=="RibbonButton")return vt.jsx(Abt,{data:t});if(((Lt=t==null?void 0:t.Properties)==null?void 0:Lt.Type)=="RibbonButtonGroup")return vt.jsx(Lbt,{data:t});if(((Vt=t==null?void 0:t.Properties)==null?void 0:Vt.Type)=="RibbonDropDownButton")return vt.jsx(Cjt,{data:t});if(((Rt=t==null?void 0:t.Properties)==null?void 0:Rt.Type)=="RibbonGallery")return vt.jsx(zjt,{data:t});if(((Ut=t==null?void 0:t.Properties)==null?void 0:Ut.Type)=="Poly")return vt.jsx(Ebt,{data:t});if(((Kt=t==null?void 0:t.Properties)==null?void 0:Kt.Type)=="Rect")return vt.jsx(QVt,{data:t});if(((It=t==null?void 0:t.Properties)==null?void 0:It.Type)=="SubForm")return vt.jsx(pP,{data:t});if(((le=t==null?void 0:t.Properties)==null?void 0:le.Type)=="Text"){const Jt=JSON.parse(ji(M==null?void 0:M.current,(Bt=t==null?void 0:t.Properties)==null?void 0:Bt.FontObj));return vt.jsx(mC,{data:t,fontProperties:Jt==null?void 0:Jt.Properties})}if(((de=t==null?void 0:t.Properties)==null?void 0:de.Type)=="Timer")return vt.jsx(oFt,{data:t});if(((Ft=t==null?void 0:t.Properties)==null?void 0:Ft.Type)=="ListView")return vt.jsx(aFt,{data:t});if(((we=t==null?void 0:t.Properties)==null?void 0:we.Type)=="Image")return vt.jsx(sFt,{data:t});if(((Ht=t==null?void 0:t.Properties)==null?void 0:Ht.Type)=="Ellipse")return vt.jsx(tFt,{data:t});if(((ce=t==null?void 0:t.Properties)==null?void 0:ce.Type)=="Circle")return vt.jsx(eFt,{data:t});if(((Se=t==null?void 0:t.Properties)==null?void 0:Se.Type)=="ApexChart")return vt.jsx(xFt,{data:t});if(((qt=t==null?void 0:t.Properties)==null?void 0:qt.Type)=="MsgBox")return vt.jsx(NO,{data:t});if(((ge=t==null?void 0:t.Properties)==null?void 0:ge.Type)=="KendoChart")return vt.jsx(kFt,{data:t});if(((oe=t==null?void 0:t.Properties)==null?void 0:oe.Type)=="KendoGrid")return vt.jsx(xjt,{data:t});if(((ue=t==null?void 0:t.Properties)==null?void 0:ue.Type)=="Link")return vt.jsx(SFt,{data:t});if(((xe=t==null?void 0:t.Properties)==null?void 0:xe.Type)=="Upload")return vt.jsx(n0,{data:t});console.log("UNKNOWN: "+((Nt=t==null?void 0:t.Properties)==null?void 0:Nt.Type))},Mjt=({data:t})=>{Vq();const{findDesiredData:r,socket:n,isDesktop:i}=x1();console.log("Desktop is as",!i);const[o,a]=_.useState({}),s=y4(document.getElementById(t==null?void 0:t.ID)),{BCol:l,Picture:h,Size:p,Visible:f,Posn:g,Flex:b=0,Event:z,CSS:M}=t==null?void 0:t.Properties;console.log("Dtaa is as",t,g);const I=$1(M);console.log("form after parsing",{styles:I,CSS:M,Flex:b});const F=ta(t),H=r(h&&h[0]);let E=$9(h&&h[1],H);const R=()=>{const $=JSON.stringify({Event:{EventName:"Configure",ID:t==null?void 0:t.ID,Info:[g&&g[0],g&&g[1],p&&p[0],p&&p[1]]}}),G=z&&z.some(Z=>Z[0]==="Configure");console.log("Event is as in Form",$),G&&n.send($)},W=()=>{console.log("Coming here in devive capabilities");let $=Math.round(window.devicePixelRatio*100),G=JSON.stringify({DeviceCapabilities:{ViewPort:[window.innerHeight,window.innerWidth],ScreenSize:[window.screen.height,window.screen.width],DPR:$/100,PPI:200}});console.log("Event sent is as",G),n.send(G)};return _.useEffect(()=>{localStorage.setItem("current-focus",t.ID)},[]),_.useEffect(()=>{var K;const $=(K=t==null?void 0:t.Properties)==null?void 0:K.hasOwnProperty("Size"),G=Math.round(window.innerWidth/2),Z=Math.round(window.innerHeight/2);localStorage.setItem("formDimension",JSON.stringify($?p:[Z,G])),localStorage.setItem("formPositions",JSON.stringify([g&&g[0],g&&g[1]])),localStorage.setItem(t==null?void 0:t.ID,JSON.stringify({Size:$?p:[Z,G],Posn:g})),a(Gr({...t==null?void 0:t.Properties,...$?{Size:p}:{Size:[Z,G]}},"relative",b))},[t]),_.useEffect(()=>{R(),W()},[s]),vt.jsx("div",{onMouseDown:$=>{Q1($,n,z,t==null?void 0:t.ID)},onMouseUp:$=>{tr($,n,z,t==null?void 0:t.ID)},onMouseEnter:$=>{er($,n,z,t==null?void 0:t.ID)},onMouseMove:$=>{ir($,n,z,t==null?void 0:t.ID)},onMouseLeave:$=>{rr($,n,z,t==null?void 0:t.ID)},onWheel:$=>{lr($,n,z,t==null?void 0:t.ID)},onDoubleClick:$=>{gr($,n,z,t==null?void 0:t.ID)},id:t==null?void 0:t.ID,style:{...o,...I,background:l?Er(l):"#F0F0F0",position:"relative",border:"1px solid #F0F0F0",display:f==0?"none":t!=null&&t.Properties.hasOwnProperty("Flex")?"flex":"block",...E},onKeyDown:$=>{},children:Object.keys(F).map(($,G)=>vt.jsx(E4,{data:F[$]},G))})};const kjt="0.2.3",_jt="EWC Client",rI={version:kjt,name:_jt};function Xy(t){const r=document.getElementById(t+".$CONTAINER")||document.getElementById(t);return r===null?null:r.getBoundingClientRect()}function Ajt(t){const r=t.split(".");return r.length===1?null:r.slice(0,-1).join(".")}function Ljt(t){const r=Xy(t);if(r===null)return[0,0];const n=Ajt(t);if(n===null)return[r.y,r.x];const i=Xy(n);return[r.y-i.y-1,r.x-i.x-1]}function Ejt(t){const r=Xy(t);return r===null?[0,0]:[r.height,r.width]}function Ijt(){const[t,r]=_.useState(!0);return{reRender:()=>{r(i=>!i)}}}const Hjt=()=>{var bt,kt,Lt,Vt,Rt,Ut,Kt;const[t,r]=_.useState([]),[n,i]=_.useState(null),[o,a]=_.useState(!1),[s,l]=_.useState([]),[h,p]=_.useState([]),[f,g]=_.useState("Initialise"),b=_.useRef(null),[z,M]=_.useState(null),{reRender:I}=Ijt(),[F,H]=_.useState(null),[E,R]=_.useState(null),[W,$]=_.useState(null);let G={};const Z=_.useRef({curEvent:"",eventID:"",keyEvent:""}),K=It=>{Z.current={...Z.current,...It}},et=_.useRef({});window.ewcDataRef=et;const at=_.useRef(null),tt=It=>b.current.send(JSON.stringify(It));window.EWC||(window.EWC={}),(bt=window.EWC)!=null&&bt.ping||(window.EWC.pingMS=0,window.EWC.ping=()=>{window.setTimeout(()=>{window.EWC.pingMS>0&&b.current.send('{"Event":{"EventName":"Ping","ID":""}}'),window.EWC.ping()},window.EWC.pingMS==0?1e3:window.EWC.pingMS)},window.EWC.ping()),_.useEffect(()=>{et.current={},r([]),localStorage.clear(),yt();const It=()=>{b.current&&b.current.send(JSON.stringify({Signal:{Name:"Close"}}))};return window.addEventListener("beforeunload",It),()=>{window.removeEventListener("beforeunload",It),b.current&&b.current.readyState===WebSocket.OPEN&&b.current.close()}},[f]),_.useEffect(()=>{const It=at.current;return It&&It.addEventListener("click",mt),()=>{It&&It.removeEventListener("click",mt)}},[]),W&&localStorage.setItem("fontscale",W);function ft(It,le){return(G==null?void 0:G[It])||le}function dt(It){return typeof It=="number"&&(It=[It]),It==null?void 0:It.map(Bt=>Array.isArray(Bt)&&(Bt!=null&&Bt.every(Ft=>typeof Ft=="number"&&Ft>=0))?Bt:typeof Bt=="number"&&Bt<0?ft(Bt):typeof Bt=="number"&&Bt>=0?Bt:Bt==null?void 0:Bt.map(Ft=>Array.isArray(Ft)?Ft.map(we=>typeof we=="number"&&we<0?ft(we):we):typeof Ft=="number"&&Ft<0?ft(Ft):Ft))}const ht=(It,le)=>{var we,Ht,ce,Se,qt,ge,oe,ue;console.log("handleData",It,le);const Bt=It.ID.split("."),de=qM(et.current,It.ID),Ft=Bt[Bt.length-1];if(de.hasOwnProperty(Ft)){if(le==="WC")It.Properties&&It.Properties.Type==="Form"&&localStorage.clear(),de[Ft]={ID:It.ID,...It};else if(le==="WS"){const xe=Nt=>{var Jt,Ie;return((Jt=Nt.Properties)==null?void 0:Jt.Type)=="Button"&&((Ie=Nt.Properties)==null?void 0:Ie.Style)=="Radio"};if(xe(de[Ft])){const Nt=qM(et.current,It.ID),Jt=Lq(It.ID);Object.keys(ta(Nt)).forEach(Ie=>{xe(Nt[Ie])&&(Nt[Ie].Properties.State=0)}),Nt[Jt].Properties.State=It.Properties.State}de[Ft]={ID:It.ID,...de[Ft],Properties:{...de[Ft].Properties||{},...It.Properties||{}}}}}else{let xe=JSON.parse(JSON.stringify(It));console.log("New data is assss",xe);try{if(It.Properties.hasOwnProperty("FillCol")||It.Properties.hasOwnProperty("FCol")||It.Properties.hasOwnProperty("BCol")||It.Properties.hasOwnProperty("BodyHeight")||It.Properties.hasOwnProperty("MaxButtonWidth"))xe={...It,Properties:{...It==null?void 0:It.Properties,...((we=It==null?void 0:It.Properties)==null?void 0:we.FillCol)&&{FillCol:dt(It.Properties.FillCol)},...((Ht=It==null?void 0:It.Properties)==null?void 0:Ht.FCol)&&{FCol:dt(It.Properties.FCol)},...((ce=It==null?void 0:It.Properties)==null?void 0:ce.BCol)&&{BCol:dt(It.Properties.BCol)},...((Se=It==null?void 0:It.Properties)==null?void 0:Se.BodyHeight)&&{BodyHeight:dt(It.Properties.BodyHeight)},...((qt=It==null?void 0:It.Properties)==null?void 0:qt.MaxButtonWidth)&&{MaxButtonWidth:dt(It.Properties.MaxButtonWidth)}}};else if(((ge=It==null?void 0:It.Properties)==null?void 0:ge.Type)==="TabControl"){const Nt={Size:(oe=It==null?void 0:It.Properties)==null?void 0:oe.Size,Posn:(ue=It==null?void 0:It.Properties)==null?void 0:ue.Posn};localStorage.setItem("TabControlData",JSON.stringify(Nt))}}catch(Nt){console.log({error:Nt})}de[Ft]={ID:It.ID,...xe},console.log("compare",{data:It,newData:xe})}I()};function lt(It,le){le.forEach(Bt=>{((Ft,we)=>{if(Ft.hasOwnProperty(we))delete Ft[we];else{const Ht=we.split(".");let ce=Ft;for(let Se=0;Se{let It=Math.round(window.devicePixelRatio*100);const le=Zi(),Bt=URL.parse(le),de=Bt.protocol==="https:"?"wss":"ws",Ft=Bt.port&&Bt.protocol!=="https:"?`:${Bt.port}`:"",we=Bt.pathname||"/";b.current=new WebSocket(`${de}://${Bt.hostname}${Ft}${we}`);const Ht=b.current;i(Ht),Ht.onopen=()=>{let ce=JSON.stringify({DeviceCapabilities:{ViewPort:[window.innerHeight,window.innerWidth],ScreenSize:[window.screen.height,window.screen.width],DPR:It/100,PPI:200}});Ht.send(ce);const Se=JSON.stringify({[f]:{Version:rI.version,Name:rI.name,URL:window.location.href}});Ht.send(Se)},Ht.onmessage=ce=>{var qt,ge,oe,ue,xe,Nt,Jt,Ie,He,Pe,Xt;const Se=Object.keys(JSON.parse(ce.data));if(Se[0]=="WC"){let st=JSON.parse(ce.data).WC;if(((qt=st==null?void 0:st.Properties)==null?void 0:qt.Type)=="Form"){localStorage.clear();const Mt=Cq(et.current);et.current={},et.current=Mt,ht(JSON.parse(ce.data).WC,"WC");return}if(((ge=st==null?void 0:st.Properties)==null?void 0:ge.Type)=="MsgBox"){H(st);return}r(Mt=>[...Mt,JSON.parse(ce.data).WC]),ht(JSON.parse(ce.data).WC,"WC")}else if(Se[0]=="WS"){const st=JSON.parse(ce.data).WS;let Mt=null;const wt=JSON.parse(ji(et.current,st.ID));if(console.log("WSSocket",{serverEvent:st,data:wt}),((oe=wt==null?void 0:wt.Properties)==null?void 0:oe.Type)=="Edit"){st!=null&&st.Properties.hasOwnProperty("Text")?Mt=st==null?void 0:st.Properties.Text:st!=null&&st.Properties.hasOwnProperty("Value")?Mt=st==null?void 0:st.Properties.Value:st!=null&&st.Properties.hasOwnProperty("SelText")&&(Mt=st==null?void 0:st.Properties.SelText);const Pt={...wt==null?void 0:wt.Properties,...st==null?void 0:st.Properties};return ht({ID:st.ID,Properties:Pt},"WS")}if(((ue=wt==null?void 0:wt.Properties)==null?void 0:ue.Type)=="Combo"&&st!=null&&st.Properties.hasOwnProperty("SelItems")){r(Zt=>[...Zt,JSON.parse(ce.data).WS]),Mt=st==null?void 0:st.Properties.SelItems;const Pt=Mt.indexOf(1);let Yt=(xe=wt==null?void 0:wt.Properties)==null?void 0:xe.Items[Pt];return ht({ID:st.ID,Properties:{...wt==null?void 0:wt.Properties,SelItems:Mt,Text:Yt}},"WS")}r(Pt=>[...Pt,JSON.parse(ce.data).WS]),ht(JSON.parse(ce.data).WS,"WS")}else if(Se[0]=="WG"){console.log("Data is as",JSON.parse(ce.data).WG);const st=JSON.parse(ce.data).WG,Mt=wt=>{var Pt;return(Pt=wt.WG)!=null&&Pt.Properties&&(st.Properties.includes("Posn")&&wt.WG.Properties.Posn===void 0&&(wt.WG.Properties.Posn=Ljt(st.ID)),st.Properties.includes("Size")&&wt.WG.Properties.Size===void 0&&(wt.WG.Properties.Size=Ejt(st.ID))),JSON.stringify(wt)};try{const wt=JSON.parse(ji(et.current,st==null?void 0:st.ID)),Pt=(Nt=wt==null?void 0:wt.Properties)==null?void 0:Nt.Type,Yt=JSON.stringify({WG:{ID:st==null?void 0:st.ID,Error:{Code:1,Message:"ID not found",WGID:st==null?void 0:st.WGID}}});if(!Pt)return Ht.send(Yt);const{Properties:Zt}=wt;if(console.log("Reference adata a",wt,Zt),console.log("Reffffffff",Zt),Pt=="Grid"){const{Values:ae,CurCell:ee}=Zt;console.log("250 values",{Values:ae,CurCell:ee});const _e=S2(["Values","CurCell"],st==null?void 0:st.Properties);if(!localStorage.getItem(st.ID)){const Re={};st.Properties.map(d1=>Re[d1]=Zt[d1]);const je=Mt({WG:{ID:st.ID,Properties:Re,WGID:st.WGID,..._e&&_e.NotSupported&&_e.NotSupported.length>0?{NotSupported:_e.NotSupported}:null}});return Ht.send(je)}const{Event:ze}=JSON.parse(localStorage.getItem(st.ID)),Gt={};st.Properties.map(Re=>{var je;Re==="CurCell"?Gt[Re]=ee:Gt[Re]=ze[Re]||((je=wt==null?void 0:wt.Properties)==null?void 0:je[Re])}),console.log("250",Mt({WG:{ID:st.ID,Properties:Gt,WGID:st.WGID,..._e&&_e.NotSupported&&_e.NotSupported.length>0?{NotSupported:_e.NotSupported}:null}})),r(Re=>[...Re,{ID:st.ID,Properties:{...Zt,Values:ae}}]),ht({ID:st.ID,Properties:{...Zt,Values:ae}}),Ht.send(Mt({WG:{ID:st.ID,Properties:Gt,WGID:st.WGID,..._e&&_e.NotSupported&&_e.NotSupported.length>0?{NotSupported:_e.NotSupported}:null}}))}else if(Pt=="Form"){console.log("Coming in forms");const ae=["Posn","Size"];console.log("Server isssue is as",st);const ee=S2(ae,st==null?void 0:st.Properties);console.log("Server event is assss",st,ee);const jt={},_e=JSON.parse(localStorage.getItem(st.ID));if(console.log("Value of form is",Zt,_e),!localStorage.getItem(st.ID)){const Gt={};st.Properties.map(je=>(console.log("Properties key is",Zt[je]),Gt[je]=Zt[je])),console.log("Valllll===>"),console.log("+++++++",st,Gt);const Re=Mt({WG:{ID:st.ID,Properties:Gt,WGID:st.WGID,...ee&&ee.NotSupported&&ee.NotSupported.length>0?{NotSupported:ee.NotSupported}:null}});console.log("server event is as2",Re),Ht.send(Re);return}console.log("Coming outside"),st.Properties.map(Gt=>jt[Gt]=_e[Gt]);const ze=Mt({WG:{ID:st.ID,Properties:jt,WGID:st.WGID,...ee&&ee.NotSupported&&ee.NotSupported.length>0?{NotSupported:ee.NotSupported}:null}});console.log("server event is as2",ze),Ht.send(ze);return}else if(Pt=="Edit"){const{Text:ae="",Value:ee,SelText:jt}=Zt,_e=["Text","Value","SelText"];console.log("edit",{serverEvent:st,Properties:Zt,Text:ae,local:localStorage.getItem(st.ID)});const ze=S2(_e,st==null?void 0:st.Properties);if(!localStorage.getItem(st.ID)){const d1=ae||ee,K1=(Jt=wt==null?void 0:wt.Properties)==null?void 0:Jt.hasOwnProperty("FieldType"),Oe={};return st.Properties.forEach(Ae=>{Ae==="Text"?Oe[Ae]=d1?d1.toString():"":Ae==="Value"?Oe[Ae]=K1?parseInt(d1):d1:Ae==="SelText"?Oe[Ae]=Zt[Ae]?Zt[Ae]:[1,1]:Oe[Ae]=d1}),console.log(Mt({WG:{ID:st.ID,Properties:Oe,WGID:st.WGID,...ze&&ze.NotSupported&&ze.NotSupported.length>0?{NotSupported:ze.NotSupported}:null}})),Ht.send(Mt({WG:{ID:st.ID,Properties:Oe,WGID:st.WGID,...ze&&ze.NotSupported&&ze.NotSupported.length>0?{NotSupported:ze.NotSupported}:null}}))}const{Event:Gt}=JSON.parse(localStorage.getItem(st==null?void 0:st.ID)),{Info:Re}=Gt,je={};console.log("edit 2",{serverPropertiesObj:je}),st.Properties.forEach(d1=>{var K1;if(d1==="Value")je[d1]=Re;else if(d1==="SelText")je[d1]=jt;else if(d1==="Text"){console.log("edit 3 hrere");const Oe=(K1=JSON.parse(localStorage.getItem(st==null?void 0:st.ID)))==null?void 0:K1.Text;je[d1]=Array.isArray(ae||Oe)?ae||Oe:ae||"2"}else je[d1]=Re.toString()}),console.log(Mt({WG:{ID:st.ID,Properties:je,WGID:st.WGID,...ze&&ze.NotSupported&&ze.NotSupported.length>0?{NotSupported:ze.NotSupported}:null}})),Ht.send(Mt({WG:{ID:st.ID,Properties:je,WGID:st.WGID,...ze&&ze.NotSupported&&ze.NotSupported.length>0?{NotSupported:ze.NotSupported}:null}}))}else if(Pt=="Combo"){console.log("Properties are",Zt);const{SelItems:ae,Items:ee,Text:jt}=Zt;console.log("Coming in form but combo");const _e=["Text","SelItems","Posn","Size"];console.log("server event is as",st);const ze=S2(_e,st==null?void 0:st.Properties);if(console.log("RESULT IS AS",ze),console.log("rESULT IS AS",ze),console.log("rESULT IS AS2",localStorage.getItem(st.ID)),!localStorage.getItem(st.ID)){console.log("server event is as",st);let E1=ae||new Array(ee.length).fill(0);if(jt){const ti=ee.indexOf(jt);ti>=0&&(E1.fill(0),E1[ti]=1)}const ur={};st.Properties.map(ti=>{ur[ti]=ti==="SelItems"?E1:ti==="Text"?jt:Zt[ti]});const Qr={WG:{ID:st.ID,Properties:ur,WGID:st.WGID,...((Ie=ze==null?void 0:ze.NotSupported)==null?void 0:Ie.length)>0?{NotSupported:ze.NotSupported}:null}};return console.log("server event is as2",Qr),Ht.send(Mt(Qr))}console.log("rESULT IS AS4");const{Event:Gt}=JSON.parse(localStorage.getItem(st==null?void 0:st.ID));console.log("EVENY IS AS",Gt,st.WGID);const{Info:Re,Size:je,Posn:d1}=Gt;let K1=ae||new Array(ee.length).fill(0);if(jt){const E1=ee.indexOf(jt);E1>=0&&(K1.fill(0),K1[E1]=1)}const Oe={};console.log("Server eveny is as",st.Properties),st.Properties.map(E1=>{Oe[E1]=E1==="SelItems"?K1:E1==="Text"?jt:E1==="Items"?ee[Re]:Gt[E1]});const Ae={WG:{ID:st.ID,Properties:Oe,WGID:st.WGID,...((He=ze==null?void 0:ze.NotSupported)==null?void 0:He.length)>0?{NotSupported:ze.NotSupported}:null}};return console.log("server event is as2",Ae),Ht.send(Mt(Ae))}else if(Pt=="List"){console.log("Coming here");const{SelItems:ae}=Zt,jt=S2(["SelItems"],st==null?void 0:st.Properties);if(!localStorage.getItem(st.ID))return console.log(Mt({WG:{ID:st.ID,Properties:{SelItems:ae},...jt&&jt.NotSupported&&jt.NotSupported.length>0?{NotSupported:jt.NotSupported}:null,WGID:st.WGID}})),Ht.send(Mt({WG:{ID:st.ID,Properties:{SelItems:ae},...jt&&jt.NotSupported&&jt.NotSupported.length>0?{NotSupported:jt.NotSupported}:null,WGID:st.WGID}}));const{Event:_e}=JSON.parse(localStorage.getItem(st==null?void 0:st.ID));return console.log(Mt({WG:{ID:st.ID,Properties:{SelItems:_e.SelItems},...jt&&jt.NotSupported&&jt.NotSupported.length>0?{NotSupported:jt.NotSupported}:null,WGID:st.WGID}})),Ht.send(Mt({WG:{ID:st.ID,Properties:{SelItems:_e.SelItems},...jt&&jt.NotSupported&&jt.NotSupported.length>0?{NotSupported:jt.NotSupported}:null,WGID:st.WGID}}))}else if(Pt=="Scroll"){const{Thumb:ae=1}=Zt,ee=["Thumb"];console.log("300",ae);const jt=S2(ee,st==null?void 0:st.Properties);if(!localStorage.getItem(st.ID))return console.log(Mt({WG:{ID:st.ID,Properties:{Thumb:ae},WGID:st.WGID,...jt&&jt.NotSupported&&jt.NotSupported.length>0?{NotSupported:jt.NotSupported}:null}})),Ht.send(Mt({WG:{ID:st.ID,Properties:{Thumb:ae},WGID:st.WGID,...jt&&jt.NotSupported&&jt.NotSupported.length>0?{NotSupported:jt.NotSupported}:null}}));const{Event:_e}=JSON.parse(localStorage.getItem(st==null?void 0:st.ID)),{Info:ze}=_e;return console.log(Mt({WG:{ID:st.ID,Properties:{Thumb:ze[1]},WGID:st.WGID,...jt&&jt.NotSupported&&jt.NotSupported.length>0?{NotSupported:jt.NotSupported}:null}})),Ht.send(Mt({WG:{ID:st.ID,Properties:{Thumb:ae},WGID:st.WGID,...jt&&jt.NotSupported&&jt.NotSupported.length>0?{NotSupported:jt.NotSupported}:null}}))}else if(Pt=="Splitter"){console.log("Coming in form but splitter");const{Posn:ae}=Zt,jt=S2(["Posn","Size"],st==null?void 0:st.Properties);if(!localStorage.getItem(st.ID)){const je={};return st.Properties.map(d1=>je[d1]=Zt[d1]),console.log(Mt({WG:{ID:st.ID,Properties:je,WGID:st.WGID,...jt&&jt.NotSupported&&jt.NotSupported.length>0?{NotSupported:jt.NotSupported}:null}})),Ht.send(Mt({WG:{ID:st.ID,Properties:je,WGID:st.WGID,...jt&&jt.NotSupported&&jt.NotSupported.length>0?{NotSupported:jt.NotSupported}:null}}))}const{Event:_e}=JSON.parse(localStorage.getItem(st.ID)),{Info:ze,Size:Gt}=_e,Re={};return st.Properties.map(je=>Re[je]=je=="Posn"?ze:Gt),console.log(Mt({WG:{ID:st.ID,Properties:Re,WGID:st.WGID,...jt&&jt.NotSupported&&jt.NotSupported.length>0?{NotSupported:jt.NotSupported}:null}})),Ht.send(Mt({WG:{ID:st.ID,Properties:Re,WGID:st.WGID,...jt&&jt.NotSupported&&jt.NotSupported.length>0?{NotSupported:jt.NotSupported}:null}}))}else if(Pt=="SubForm"){console.log("Coming in form but suss");const ee=S2(["Posn","Size"],st==null?void 0:st.Properties);if(console.log("Valuuuuuuuu",ee),console.log("Servere event is ",st),!localStorage.getItem(st.ID)){console.log("Coming in form but su1");const ze={};return console.log("Properiessss",st.Properties,Zt),st.Properties.map(Gt=>(console.log("Propertiesss2",Zt[Gt]),ze[Gt]=Zt[Gt])),console.log("Server propertoes aew,",ze),console.log(Mt({WG:{ID:st.ID,Properties:ze,WGID:st.WGID,...ee&&ee.NotSupported&&ee.NotSupported.length>0?{NotSupported:ee.NotSupported}:null}})),Ht.send(Mt({WG:{ID:st.ID,Properties:ze,WGID:st.WGID,...ee&&ee.NotSupported&&ee.NotSupported.length>0?{NotSupported:ee.NotSupported}:null}}))}console.log("Coming in form but su2");const jt={};console.log("Serverrrrrr",st.ID);const _e=JSON.parse(localStorage.getItem(st.ID));return console.log("Value of subform is as",_e),st.Properties.map(ze=>(console.log("Keyyy",ze),jt[ze]=_e[ze])),console.log("Server properties are",jt),console.log(Mt({WG:{ID:st.ID,Properties:jt,WGID:st.WGID,...ee&&ee.NotSupported&&ee.NotSupported.length>0?{NotSupported:ee.NotSupported}:null}})),Ht.send(Mt({WG:{ID:st.ID,Properties:jt,WGID:st.WGID,...ee&&ee.NotSupported&&ee.NotSupported.length>0?{NotSupported:ee.NotSupported}:null}}))}else if(Pt=="Button"){console.log("Coming here in buttons");const{State:ae}=Zt,jt=S2(["State","Posn","Size"],st==null?void 0:st.Properties);if(!localStorage.getItem(st.ID)){const je={};st.Properties.map(K1=>je[K1]=K1=="State"?ae||0:Zt[K1]);const d1=Mt({WG:{ID:st.ID,Properties:je,WGID:st.WGID,...jt&&jt.NotSupported&&jt.NotSupported.length>0?{NotSupported:jt.NotSupported}:null}});return console.log(d1),Ht.send(d1)}const{Event:_e}=JSON.parse(localStorage.getItem(st.ID)),{Value:ze}=_e,Gt={};st.Properties.map(je=>Gt[je]=je=="State"?ze:_e[je]);const Re=Mt({WG:{ID:st.ID,Properties:Gt,WGID:st.WGID,...jt&&jt.NotSupported&&jt.NotSupported.length>0?{NotSupported:jt.NotSupported}:null}});return console.log(Re),Ht.send(Re)}else if(Pt=="TreeView"){const ee=S2(["SelItems"],st==null?void 0:st.Properties),{Event:jt}=JSON.parse(localStorage.getItem(st.ID)),{SelItems:_e}=jt,ze=Mt({WG:{ID:st.ID,Properties:{SelItems:_e},WGID:st.WGID,...ee&&ee.NotSupported&&ee.NotSupported.length>0?{NotSupported:ee.NotSupported}:null}});return console.log(ze),Ht.send(ze)}else if(Pt=="Timer"){const ee=S2(["FireOnce"],st==null?void 0:st.Properties),{Event:jt}=JSON.parse(localStorage.getItem(st.ID)),{FireOnce:_e}=jt,ze=Mt({WG:{ID:st.ID,Properties:{FireOnce:_e},WGID:st.WGID,...ee&&ee.NotSupported&&ee.NotSupported.length>0?{NotSupported:ee.NotSupported}:null}});return console.log(ze),Ht.send(ze)}else if(Pt=="ListView"){const ee=S2(["SelItems"],st==null?void 0:st.Properties),{Event:jt}=JSON.parse(localStorage.getItem(st.ID)),{SelItems:_e}=jt,ze=Mt({WG:{ID:st.ID,Properties:{SelItems:_e},WGID:st.WGID,...ee&&ee.NotSupported&&ee.NotSupported.length>0?{NotSupported:ee.NotSupported}:null}});return console.log(ze),Ht.send(ze)}else if(Pt==="ApexChart"){const ae=["SVG"],{SVG:ee}=Zt,jt=JSON.parse(ji(et.current,st.ID)),_e=Mt({WG:{ID:st.ID,WGID:st.WGID,Properties:{SVG:ee}}});return Ht.send(_e)}else{if(Pt==="Upload")return n0.WG(tt,st);{const ae={};for(const ee in st.Properties)wt.Properties[ee]&&(ae[ee]=wt[ee]);return Ht.send(Mt({WG:{ID:st.ID,Properties:ae,WGID:st.WGID}}))}}}catch(wt){console.error("WG Error: ",wt)}}else if(Se[0]=="NQ"){const st=JSON.parse(ce.data).NQ;console.log("300",st,st.ID,st.Event,st.Info);const{Event:Mt,ID:wt,Info:Pt,NoCallback:Yt=0}=st,Zt=ji(et.current,wt);if(Mt&&Mt=="Configure"){ht({ID:wt,Properties:{...Zt==null?void 0:Zt.Properties,Posn:[Pt[0],Pt[1]],Size:[Pt[2],Pt[3]]}},"WS");const jt=JSON.stringify({Event:{EventName:st.Event,ID:st.ID,Info:st.Info}});Ht.send(jt);return}else if(Mt=="SetPing"){window.EWC.pingMS=Pt[0]*1e3;return}else if(Mt&&Mt=="ItemDown"||Mt&&Mt=="GotFocus"){Mt&&Mt=="GotFocus"&&localStorage.setItem("current-focus",wt);const jt=JSON.parse(ji(et.current,wt));if(!(((Pe=jt==null?void 0:jt.Properties)==null?void 0:Pe.Event)&&((Xt=jt==null?void 0:jt.Properties)==null?void 0:Xt.Event.some(Gt=>Gt[0]===Mt))))return;const ze=JSON.stringify({Event:{EventName:Mt,ID:wt,Info:Pt}});console.log(ze),Yt==0&&Ht.send(ze);return}else if(Mt=="CellMove"){console.log("296",{nqEvent:st}),p([...h,st]),localStorage.setItem(wt,JSON.stringify({Event:{CurCell:[Pt[0],Pt[1]]}})),localStorage.setItem("nqCurCell",JSON.stringify({ID:wt,Info:Pt}));return}else if(Mt=="Select"){const jt=document.getElementById(st.ID);jt&&jt.click(),Ht.send(JSON.stringify({Event:{EventName:"Select",ID:wt}}))}else Mt=="Scroll"&&Ht.send(JSON.stringify({Event:{EventName:"Scroll",ID:wt,Info:[Pt[0],Pt[1]]}}));const ae=Pt[1];console.log("300",{thumbValue:ae}),ht({ID:wt,Properties:{Thumb:ae}},"WS");const ee=document.getElementById(st.ID);ee&&ee.focus()}else if(Se[0]=="EC"){const st=JSON.parse(ce.data).EC,{EventID:Mt,Proceed:wt}=st;l(Pt=>(console.log("use effect",Z.current),Object.keys(Pt).some(Yt=>Yt.includes(Mt)),{...Pt,[`${Mt}${Z.current.curEvent}`]:wt})),a(wt)}else if(Se[0]=="EX"){const st=JSON.parse(ce.data).EX;lt(et.current,st==null?void 0:st.ID)}else if(Se[0]=="WX"){const st=JSON.parse(ce.data).WX,{Method:Mt,Info:wt,WGID:Pt,ID:Yt}=st;if(Mt=="GetTextSize"){const Zt=wt&&wt[0],ae=JSON.parse(ji(et.current,wt&&wt[1])),ee=ae&&(ae==null?void 0:ae.Properties),jt=mC.calculateTextDimensions(Zt,ee==null?void 0:ee.Size),_e=JSON.stringify({WX:{Info:jt,WGID:Pt}});return console.log(_e),Ht.send(_e)}else if(Mt=="OnlyDQ"){let Zt;wt!=null&&wt[0]?Zt=JSON.stringify({WX:{Info:[[Yt,150,300]],WGID:Pt}}):Zt=JSON.stringify({WX:{Info:[],WGID:Pt}}),Ht.send(Zt)}else if(Mt=="GetFocus"){const Zt=localStorage.getItem("current-focus"),ae=JSON.stringify({WX:{Info:Zt?[Zt]:[],WGID:Pt}});console.log(ae),Ht.send(ae)}else if(Mt=="SetCookie")wt.forEach(Zt=>{document.cookie=Zt}),Ht.send(JSON.stringify({WX:{Info:[],WGID:Pt}}));else if(Mt=="GetCookie"){const Zt=document.cookie.split("; ").map(ae=>ae.split("=")).filter(ae=>wt.includes(ae[0]));Ht.send(JSON.stringify({WX:{Info:Zt,WGID:Pt}}))}else if(Mt=="SetTitle")document.title=wt[0],Ht.send(JSON.stringify({WX:{Info:[],WGID:Pt}}));else if(Mt=="GetTitle")Ht.send(JSON.stringify({WX:{Info:[document.title],WGID:Pt}}));else if(Mt=="EvalJS"){const Zt=wt.map(ae=>{try{return[0,eval==null?void 0:(0,eval)(ae)]}catch(ee){return[-1,ee.toString()]}});Ht.send(JSON.stringify({WX:{Info:Zt,WGID:Pt}}))}}else if(Se[0]=="Options")ht(JSON.parse(ce.data).Options,"WC"),console.log("label",JSON.parse(ce.data).Options),JSON.parse(ce.data).Options.ID=="Fonts"&&$(JSON.parse(ce.data).Options.Properties.Scale),JSON.parse(ce.data).Options.ID=="Fonts"&&console.log("label",JSON.parse(ce.data).Options.Properties.Scale),JSON.parse(ce.data).Options.ID=="Mode"&&R(JSON.parse(ce.data).Options.Properties),JSON.parse(ce.data).Options.ID=="Colors"&>(JSON.parse(ce.data).Options.Properties.Standard);else if(Se[0]=="FormatCell"){const st=JSON.parse(ce.data),{FormatCell:Mt}=st,wt=JSON.parse(ji(et.current,Mt==null?void 0:Mt.ID)),{Properties:Pt}=wt,Yt=Pt==null?void 0:Pt.FormattedValues;Yt[Mt.Cell[0]-1][Mt.Cell[1]-1]=Mt==null?void 0:Mt.FormattedValue,ht({ID:Mt==null?void 0:Mt.ID,Properties:{...wt==null?void 0:wt.Properties,FormattedValues:Yt}},"WS")}}},mt=It=>{const le=JM(et.current);if(localStorage.getItem("change-event")){const{Event:Bt}=JSON.parse(localStorage.getItem("change-event")),de={...Bt,Info:[It.target.id?It.target.id:le]};b.current.send(JSON.stringify({Event:{...de}})),localStorage.removeItem("change-event")}};console.log("App",et.current);const gt=It=>{G={...It==null?void 0:It.reduce((Bt,de)=>({...Bt,[de==null?void 0:de[0]]:de[2]}),{})}},_t=JM(et.current),At=(It,le)=>{H(null),n.send(JSON.stringify({Event:{EventName:It,ID:le}}))};return vt.jsxs("div",{children:[vt.jsx(vD.Provider,{value:{socketData:t,dataRef:et,socket:n,handleData:ht,focusedElement:z,reRender:I,proceed:o,setProceed:a,proceedEventArray:s,setProceedEventArray:l,colors:G,fontScale:W,nqEvents:h,setNqEvents:p,currentEventRef:Z.current,updateCurrentEvent:K,isDesktop:(Vt=(Lt=(kt=et==null?void 0:et.current)==null?void 0:kt.Mode)==null?void 0:Lt.Properties)==null?void 0:Vt.Desktop},children:et&&_t&&vt.jsx(E4,{data:et.current[_t]})}),F&&vt.jsx(NO,{data:F,options:E,onClose:At,isDesktop:(Kt=(Ut=(Rt=et==null?void 0:et.current)==null?void 0:Rt.Mode)==null?void 0:Ut.Properties)==null?void 0:Kt.Desktop})]})};Kv.createRoot(document.getElementById("root")).render(vt.jsx(Hjt,{})); diff --git a/dist/index.html b/dist/index.html index 14158d2..911d784 100644 --- a/dist/index.html +++ b/dist/index.html @@ -4,7 +4,7 @@ EWC - + diff --git a/src/App.jsx b/src/App.jsx index df933d9..4930836 100644 --- a/src/App.jsx +++ b/src/App.jsx @@ -48,6 +48,9 @@ const App = () => { }; const dataRef = useRef({}); + // Convenience for being able to check the current state of the tree in the + // browser console. + window.ewcDataRef = dataRef; const appRef = useRef(null); const wsSend = (d) => webSocketRef.current.send(JSON.stringify(d)); @@ -660,8 +663,7 @@ const App = () => { }, }) ); - } - if (Type == "Form") { + } else if (Type == "Form") { console.log("Coming in forms"); const supportedProperties = ["Posn", "Size"]; @@ -724,9 +726,7 @@ const App = () => { console.log("server event is as2", event); webSocket.send(event); return; - } - - if (Type == "Edit") { + } else if (Type == "Edit") { const { Text = "", Value, SelText } = Properties; const supportedProperties = ["Text", "Value", "SelText"]; // setTimeout(() => {},100) @@ -847,9 +847,7 @@ const App = () => { }, }) ); - } - - if (Type == "Combo") { + } else if (Type == "Combo") { console.log("Properties are", Properties); const { SelItems, Items, Text } = Properties; console.log("Coming in form but combo"); @@ -969,10 +967,7 @@ const App = () => { console.log("server event is as2", message); return webSocket.send(updateAndStringify(message)); - } - console.log("Coming here in nnnnn"); - - if (Type == "List") { + } else if (Type == "List") { console.log("Coming here"); const { SelItems } = Properties; @@ -1055,9 +1050,7 @@ const App = () => { }, }) ); - } - - if (Type == "Scroll") { + } else if (Type == "Scroll") { const { Thumb = 1 } = Properties; const supportedProperties = ["Thumb"]; @@ -1138,9 +1131,7 @@ const App = () => { }, }) ); - } - - if (Type == "Splitter") { + } else if (Type == "Splitter") { console.log("Coming in form but splitter"); const { Posn } = Properties; @@ -1223,9 +1214,7 @@ const App = () => { }, }) ); - } - - if (Type == "SubForm") { + } else if (Type == "SubForm") { console.log("Coming in form but suss"); const supportedProperties = ["Posn", "Size"]; @@ -1343,9 +1332,7 @@ const App = () => { }, }) ); - } - - if (Type == "Button") { + } else if (Type == "Button") { console.log("Coming here in buttons") const { State } = Properties; const supportedProperties = ["State", "Posn", "Size"]; @@ -1405,9 +1392,7 @@ const App = () => { console.log(event); return webSocket.send(event); - } - - if (Type == "TreeView") { + } else if (Type == "TreeView") { const supportedProperties = ["SelItems"]; const result = checkSupportedProperties( supportedProperties, @@ -1433,9 +1418,7 @@ const App = () => { console.log(event); return webSocket.send(event); - } - - if (Type == "Timer") { + } else if (Type == "Timer") { const supportedProperties = ["FireOnce"]; const result = checkSupportedProperties( supportedProperties, @@ -1460,9 +1443,7 @@ const App = () => { }); console.log(event); return webSocket.send(event); - } - - if (Type == "ListView") { + } else if (Type == "ListView") { const supportedProperties = ["SelItems"]; const result = checkSupportedProperties( supportedProperties, @@ -1488,8 +1469,7 @@ const App = () => { console.log(event); return webSocket.send(event); - } - if (Type === "ApexChart") { + } else if (Type === "ApexChart") { const supportedProperties = ["SVG"]; const { SVG } = Properties; const data = JSON.parse( @@ -1509,24 +1489,25 @@ const App = () => { // console.log(event); return webSocket.send(event); - } - // TODO size and posn - if (Type === "Upload") return Upload.WG(wsSend, serverEvent); - // Generic WG - const replyProps = {}; - for (const prop in serverEvent.Properties) { - if (refData.Properties[prop]) { - replyProps[prop] = refData[prop]; + } else if (Type === "Upload") { + // TODO size and posn + return Upload.WG(wsSend, serverEvent); + } else { + const replyProps = {}; + for (const prop in serverEvent.Properties) { + if (refData.Properties[prop]) { + replyProps[prop] = refData[prop]; + } } - } - return webSocket.send(updateAndStringify({ - WG: { - ID: serverEvent.ID, - Properties: replyProps, - WGID: serverEvent.WGID, - } - })); + return webSocket.send(updateAndStringify({ + WG: { + ID: serverEvent.ID, + Properties: replyProps, + WGID: serverEvent.WGID, + } + })); + } } catch (e) { // There should be a proper error response here, but for now, we just log. // This is because we know something failed, but APL doesn't and diff --git a/src/utils/sizeposn.js b/src/utils/sizeposn.js index 53afd08..16eb03f 100644 --- a/src/utils/sizeposn.js +++ b/src/utils/sizeposn.js @@ -1,5 +1,6 @@ function boundingBox(id) { const el = document.getElementById(id + ".$CONTAINER") || document.getElementById(id); + if (el === null) return null; return el.getBoundingClientRect(); } @@ -11,6 +12,7 @@ function parentId(id) { function posn(id) { const bb = boundingBox(id); + if (bb === null) return [0, 0]; const pid = parentId(id); if (pid === null) return [bb.y, bb.x]; const pbb = boundingBox(pid); @@ -19,6 +21,7 @@ function posn(id) { function size(id) { const bb = boundingBox(id); + if (bb === null) return [0, 0]; return [bb.height, bb.width]; }